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 <noreply@anthropic.com>
This commit is contained in:
2026-02-19 02:02:02 +03:00
parent 81afa6cfaf
commit 10e426be13

View File

@@ -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();
}
}