diff --git a/html/index.html b/html/index.html
index 5c495e2..147469f 100755
--- a/html/index.html
+++ b/html/index.html
@@ -140,6 +140,10 @@
const element = document.getElementById(id);
if (element) {
element.innerHTML = data;
+ // Apply translations after loading dynamic content
+ if (window.i18n && typeof window.i18n.applyTranslations === 'function') {
+ window.i18n.applyTranslations();
+ }
}
})
.catch(error => console.error(`Error loading ${file}:`, error));
diff --git a/html/screen.html b/html/screen.html
index 86e68c1..7716c80 100644
--- a/html/screen.html
+++ b/html/screen.html
@@ -121,14 +121,15 @@
const element = document.getElementById(id);
if (element) {
element.innerHTML = data;
- // Ensure the screen tab is visible here as well if we are on this page,
- // though index.html handles it globally, sidebar load might reset it.
- // Ideally sidebar logic should be consistent.
- // For now, if we are ON screen.html, we should show the nav item.
+ // Apply translations after loading dynamic content
+ if (window.i18n && typeof window.i18n.applyTranslations === 'function') {
+ window.i18n.applyTranslations();
+ }
+ // Ensure the screen tab is visible here as well
if (id.includes('sidebar')) {
setTimeout(() => {
- const navScreen = element.querySelector('#nav-screen');
- if (navScreen) navScreen.style.display = 'flex'; // or block
+ const navScreenElements = element.querySelectorAll('.nav-screen-item');
+ navScreenElements.forEach(el => el.style.display = 'flex');
}, 100);
}
}
diff --git a/html/sensors.html b/html/sensors.html
index 945bc56..963b778 100755
--- a/html/sensors.html
+++ b/html/sensors.html
@@ -1,5 +1,6 @@
+
@@ -9,204 +10,217 @@
body {
overflow-x: hidden;
}
+
#sidebar a.nav-link {
- position: relative;
- display: flex;
- align-items: center;
+ position: relative;
+ display: flex;
+ align-items: center;
}
+
#sidebar a.nav-link:hover {
- background-color: rgba(0, 0, 0, 0.5);
+ background-color: rgba(0, 0, 0, 0.5);
}
+
#sidebar a.nav-link svg {
- margin-right: 8px; /* Add spacing between icons and text */
+ margin-right: 8px;
+ /* Add spacing between icons and text */
}
+
#sidebar {
transition: transform 0.3s ease-in-out;
}
+
.offcanvas-backdrop {
z-index: 1040;
}
+
-
+
-