Loadingアイコン表示
Browse files- index.html +7 -1
index.html
CHANGED
|
@@ -368,6 +368,10 @@
|
|
| 368 |
let height = window.document.documentElement.clientHeight;
|
| 369 |
result.classList.remove("d-none");
|
| 370 |
result.textContent = "";
|
|
|
|
|
|
|
|
|
|
|
|
|
| 371 |
createEditor();
|
| 372 |
setTimeout(function () {
|
| 373 |
html2canvas(document.getElementById("edit"), {
|
|
@@ -391,6 +395,7 @@
|
|
| 391 |
return x;
|
| 392 |
}
|
| 393 |
}).then(canvas => {
|
|
|
|
| 394 |
let i = document.createElement("img");
|
| 395 |
i.setAttribute("src", canvas.toDataURL('image/png'));
|
| 396 |
result.appendChild(i);
|
|
@@ -493,10 +498,11 @@
|
|
| 493 |
document.getElementById("textShadowToggleB").addEventListener("click", function () {
|
| 494 |
document.getElementById("textShadowToggleA").classList.add("opacity-50");
|
| 495 |
this.classList.toggle("opacity-50");
|
|
|
|
| 496 |
if (this.classList.contains("opacity-50")) {
|
| 497 |
document.getElementById("text-shadow").textContent = "";
|
| 498 |
} else {
|
| 499 |
-
document.getElementById("text-shadow").textContent = '#mainMassage input, .shadow-text {-webkit-text-stroke:
|
| 500 |
}
|
| 501 |
});
|
| 502 |
document.getElementById("userInterfaceToggle").addEventListener("click", function () {
|
|
|
|
| 368 |
let height = window.document.documentElement.clientHeight;
|
| 369 |
result.classList.remove("d-none");
|
| 370 |
result.textContent = "";
|
| 371 |
+
let loading = document.createElement("div");
|
| 372 |
+
result.appendChild(loading);
|
| 373 |
+
loading.classList.add("spinner-border");
|
| 374 |
+
loading.classList.add("text-primary");
|
| 375 |
createEditor();
|
| 376 |
setTimeout(function () {
|
| 377 |
html2canvas(document.getElementById("edit"), {
|
|
|
|
| 395 |
return x;
|
| 396 |
}
|
| 397 |
}).then(canvas => {
|
| 398 |
+
result.textContent = "";
|
| 399 |
let i = document.createElement("img");
|
| 400 |
i.setAttribute("src", canvas.toDataURL('image/png'));
|
| 401 |
result.appendChild(i);
|
|
|
|
| 498 |
document.getElementById("textShadowToggleB").addEventListener("click", function () {
|
| 499 |
document.getElementById("textShadowToggleA").classList.add("opacity-50");
|
| 500 |
this.classList.toggle("opacity-50");
|
| 501 |
+
let strokeSize = Math.ceil(document.querySelector("#left input").style.fontSize.replace("px", "") / 10);
|
| 502 |
if (this.classList.contains("opacity-50")) {
|
| 503 |
document.getElementById("text-shadow").textContent = "";
|
| 504 |
} else {
|
| 505 |
+
document.getElementById("text-shadow").textContent = '#mainMassage input, .shadow-text {-webkit-text-stroke: ' + strokeSize + 'px black;paint-order: stroke fill;}';
|
| 506 |
}
|
| 507 |
});
|
| 508 |
document.getElementById("userInterfaceToggle").addEventListener("click", function () {
|