Spaces:
Sleeping
Sleeping
DmitrMakeev
commited on
Update se_mes_im2.html
Browse files- se_mes_im2.html +3 -38
se_mes_im2.html
CHANGED
@@ -19,39 +19,7 @@
|
|
19 |
margin: 0;
|
20 |
border-bottom: 2px solid #388E3C;
|
21 |
}
|
22 |
-
|
23 |
-
display: flex;
|
24 |
-
justify-content: center;
|
25 |
-
gap: 10px;
|
26 |
-
margin-top: 20px;
|
27 |
-
}
|
28 |
-
.input-row input, .input-row textarea {
|
29 |
-
padding: 10px;
|
30 |
-
font-size: 16px;
|
31 |
-
border: 1px solid #ccc;
|
32 |
-
border-radius: 5px;
|
33 |
-
}
|
34 |
-
#messageInput, #urlFileInput, #fileNameInput {
|
35 |
-
width: 80%;
|
36 |
-
margin-top: 20px;
|
37 |
-
}
|
38 |
-
#progressBarContainer {
|
39 |
-
width: 80%;
|
40 |
-
margin: 20px auto;
|
41 |
-
}
|
42 |
-
#progressBar {
|
43 |
-
width: 100%;
|
44 |
-
background-color: #ddd;
|
45 |
-
}
|
46 |
-
#progress {
|
47 |
-
width: 0%;
|
48 |
-
height: 30px;
|
49 |
-
background-color: #4CAF50;
|
50 |
-
text-align: center;
|
51 |
-
line-height: 30px;
|
52 |
-
color: white;
|
53 |
-
}
|
54 |
-
#sendButton, button[type="submit"] {
|
55 |
color: white;
|
56 |
background-color: #4CAF50;
|
57 |
border: none;
|
@@ -61,7 +29,7 @@
|
|
61 |
border-radius: 5px;
|
62 |
margin-top: 20px;
|
63 |
}
|
64 |
-
|
65 |
background-color: #388E3C;
|
66 |
}
|
67 |
#cameraImage {
|
@@ -80,8 +48,6 @@
|
|
80 |
</head>
|
81 |
<body>
|
82 |
<h1>Upload Image</h1>
|
83 |
-
<div id="message"></div>
|
84 |
-
<h1>Latest Image</h1>
|
85 |
<img id="cameraImage" src="/image" alt="Image">
|
86 |
<div id="imageUrl" onclick="copyToClipboard(this)">Click to copy URL</div>
|
87 |
<form id="uploadForm" enctype="multipart/form-data" method="post" action="/upload">
|
@@ -103,14 +69,13 @@
|
|
103 |
throw new Error('Network response was not ok.');
|
104 |
})
|
105 |
.then(data => {
|
106 |
-
document.getElementById('message').innerText = data;
|
107 |
var image = document.getElementById("cameraImage");
|
108 |
var fullUrl = data.split('saved to ')[1];
|
109 |
image.src = fullUrl + "?" + new Date().getTime();
|
110 |
document.getElementById('imageUrl').innerText = fullUrl;
|
111 |
})
|
112 |
.catch(error => {
|
113 |
-
|
114 |
});
|
115 |
});
|
116 |
|
|
|
19 |
margin: 0;
|
20 |
border-bottom: 2px solid #388E3C;
|
21 |
}
|
22 |
+
button[type="submit"] {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
color: white;
|
24 |
background-color: #4CAF50;
|
25 |
border: none;
|
|
|
29 |
border-radius: 5px;
|
30 |
margin-top: 20px;
|
31 |
}
|
32 |
+
button[type="submit"]:hover {
|
33 |
background-color: #388E3C;
|
34 |
}
|
35 |
#cameraImage {
|
|
|
48 |
</head>
|
49 |
<body>
|
50 |
<h1>Upload Image</h1>
|
|
|
|
|
51 |
<img id="cameraImage" src="/image" alt="Image">
|
52 |
<div id="imageUrl" onclick="copyToClipboard(this)">Click to copy URL</div>
|
53 |
<form id="uploadForm" enctype="multipart/form-data" method="post" action="/upload">
|
|
|
69 |
throw new Error('Network response was not ok.');
|
70 |
})
|
71 |
.then(data => {
|
|
|
72 |
var image = document.getElementById("cameraImage");
|
73 |
var fullUrl = data.split('saved to ')[1];
|
74 |
image.src = fullUrl + "?" + new Date().getTime();
|
75 |
document.getElementById('imageUrl').innerText = fullUrl;
|
76 |
})
|
77 |
.catch(error => {
|
78 |
+
console.error('Error:', error);
|
79 |
});
|
80 |
});
|
81 |
|