player token list return false on token name click (keeps page from scrolling to top)

This commit is contained in:
Iris Lightshard 2023-07-13 20:34:55 -06:00
parent 9d2f442c30
commit ba3b6a782f
Signed by: Iris Lightshard
GPG key ID: 3B7FBC22144E6398

View file

@ -79,7 +79,7 @@ function renderTokenSelect() {
const tokenSelect = document.getElementById("token_select");
let tokenSelectHTML = "<ul class='single_btn_list'>";
for (const t of tokens) {
tokenSelectHTML += `<li><a href="#" onclick="initSpritePreviewById('${t.t.id}')">${t.t.name}</a><button onclick="toggleActive('${t.t.id}')">${(t.t.active ? "Deactivate" : "Activate")}</button></li>\n`;
tokenSelectHTML += `<li><a href="#" onclick="initSpritePreviewById('${t.t.id}')">${t.t.name}</a><button onclick="toggleActive('${t.t.id}');return false">${(t.t.active ? "Deactivate" : "Activate")}</button></li>\n`;
}
tokenSelectHTML += "</ul>";
tokenSelect.innerHTML = tokenSelectHTML;