summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2024-08-13 00:16:19 +0200
committerTor Andersson <tor@ccxvii.net>2024-08-13 00:17:27 +0200
commit05faf1474e39ae79d12bb4a23330b3231225f6f7 (patch)
treece77dab37ab2a3b91139e6cd275579293be1b5a5
parentc973a889d0003db3213a8c91cbb2b3705c6f8814 (diff)
downloadserver-05faf1474e39ae79d12bb4a23330b3231225f6f7.tar.gz
Allow HTML syntax in action button labels.
-rw-r--r--public/common/client.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/public/common/client.js b/public/common/client.js
index 2ce568f..b39642c 100644
--- a/public/common/client.js
+++ b/public/common/client.js
@@ -662,7 +662,7 @@ function action_button_with_argument(verb, noun, label) {
if (!button) {
button = document.createElement("button")
button.id = id
- button.textContent = label
+ button.innerHTML = label
button.addEventListener("click", evt => send_action(verb, noun))
document.getElementById("actions").prepend(button)
}
@@ -681,7 +681,7 @@ function action_button_imp(action, label, callback) {
if (!button) {
button = document.createElement("button")
button.id = id
- button.textContent = label
+ button.innerHTML = label
button.addEventListener("click", callback)
document.getElementById("actions").prepend(button)
}