data-loc-info from -inc with no imcompatible text

This commit is contained in:
AlexisinGit 2025-08-30 21:12:41 +08:00
parent 0cc56c6387
commit 31e121ab22

View File

@ -220,6 +220,13 @@ function updateLocElements() {
.join(", ");
elm.title = `${loc("worldState_incompatibleWith")} ${incWith}`;
});
document.querySelectorAll("[data-loc-info]").forEach(elm => {
const incWith = elm
.getAttribute("data-loc-info")
.split("|")
.map(key => loc(key));
elm.title = `${incWith}`;
});
document.querySelectorAll("[data-loc-replace]").forEach(elm => {
elm.innerHTML = elm.innerHTML.replace("|VAL|", elm.getAttribute("data-loc-replace"));
});