From 1b74e5793c7fbcdb2e21f2f182269d58d06e8287 Mon Sep 17 00:00:00 2001 From: Quanysh Date: Thu, 3 Sep 2026 12:33:11 +0000 Subject: [PATCH] Fix i18n: prevent duplicate text updates --- script.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/script.js b/script.js index f497671..5a75127 100644 --- a/script.js +++ b/script.js @@ -1415,7 +1415,10 @@ function updateTexts() { document.querySelectorAll('[data-i18n]').forEach(el => { const key = el.dataset.i18n; if (t[key]) { - el.textContent = t[key]; + // Only update if text is different to avoid unnecessary DOM changes + if (el.textContent !== t[key]) { + el.textContent = t[key]; + } } });