| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <title>Laddr Dashboard</title> | |
| <!-- Favicon with theme detection --> | |
| <link rel="icon" type="image/svg+xml" href="/favicon-light.svg" media="(prefers-color-scheme: light)" /> | |
| <link rel="icon" type="image/svg+xml" href="/favicon-dark.svg" media="(prefers-color-scheme: dark)" /> | |
| <link rel="icon" type="image/svg+xml" href="/favicon-light.svg" /> | |
| <!-- Theme detection script --> | |
| <script> | |
| // Update favicon based on system theme | |
| const updateFavicon = () => { | |
| const isDark = window.matchMedia('(prefers-color-scheme: dark)').matches; | |
| const favicon = document.querySelector('link[rel="icon"]:not([media])'); | |
| if (favicon) { | |
| favicon.href = isDark ? '/favicon-dark.svg' : '/favicon-light.svg'; | |
| } | |
| }; | |
| // Listen for theme changes | |
| window.matchMedia('(prefers-color-scheme: dark)').addEventListener('change', updateFavicon); | |
| updateFavicon(); | |
| </script> | |
| </head> | |
| <body> | |
| <div id="root"></div> | |
| <script type="module" src="/src/main.tsx"></script> | |
| </body> | |
| </html> | |