aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2023-12-04 04:21:15 +0300
committerGravatar Vitaly Takmazov2023-12-04 04:21:15 +0300
commit65ad66155d35a7f74e67556f111e0e9c2213f4cc (patch)
treee8c179eef2af73527772d6150da9d237bf21746c /src/main
parentfa89377ea880c2fc6f382ba988675fe159ad85fc (diff)
scripts: fix camera icon
Diffstat (limited to 'src/main')
-rw-r--r--src/main/assets/scripts.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/assets/scripts.js b/src/main/assets/scripts.js
index 94f79424..f3aea835 100644
--- a/src/main/assets/scripts.js
+++ b/src/main/assets/scripts.js
@@ -27,7 +27,7 @@ function autosize(el) {
* @returns {string} HTML markup for the selected icon
*/
function evilIcon(name) {
- return `<div class="icon icon--${name}"><svg class="icon__cnt"><use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/sprite.svg#${name}-icon"></use></svg></div>`
+ return `<div data-icon="${name}" data-size="s"></div>`
}
/* eslint-disable only-ascii/only-ascii */
@@ -284,7 +284,7 @@ function showCommentForm(mid, rid) {
</form>`
formTarget.insertAdjacentHTML('afterend', formHtml)
formTarget.remove()
-
+ renderIcons()
let form = /** @type {HTMLFormElement} */ (reply.querySelector('form'))
let submitButton = /** @type {HTMLInputElement} */ (form.querySelector('input[type="submit"]'))
@@ -395,6 +395,7 @@ function openDialog(html, image) {
document.addEventListener('keydown', closeDialogListener)
document.querySelector('#dialogb').addEventListener('click', closeDialog)
document.querySelector('#dialogc').addEventListener('click', closeDialog)
+ renderIcons()
}
function closeDialog() {