From 10e426be137f4665d2c4beeb4251380e43217bd2 Mon Sep 17 00:00:00 2001 From: "alexei.dolgolyov" Date: Thu, 19 Feb 2026 02:02:02 +0300 Subject: [PATCH] Fix dashboard perf section not localizing on language change The persistent perf section was created once and never rebuilt, so switching language left stale text. Now updateAllText() removes the persistent element and reloads the dashboard to recreate it with the new locale. Co-Authored-By: Claude Opus 4.6 --- server/src/wled_controller/static/js/core/i18n.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/server/src/wled_controller/static/js/core/i18n.js b/server/src/wled_controller/static/js/core/i18n.js index aa37a66..b8a4e46 100644 --- a/server/src/wled_controller/static/js/core/i18n.js +++ b/server/src/wled_controller/static/js/core/i18n.js @@ -105,5 +105,9 @@ export function updateAllText() { import('../core/api.js').then(({ loadDisplays }) => loadDisplays()); if (typeof window.loadTargetsTab === 'function') window.loadTargetsTab(); if (typeof window.loadPictureSources === 'function') window.loadPictureSources(); + // Force perf section rebuild with new locale + const perfEl = document.querySelector('.dashboard-perf-persistent'); + if (perfEl) perfEl.remove(); + if (typeof window.loadDashboard === 'function') window.loadDashboard(); } }