Theme-aware SVG favicon; SW cache v13

- Add sim-analyser-light.svg (#2563eb, light-theme accent); dark
  keeps the existing #3b82f6 variant.
- applyTheme() now swaps the favicon href alongside data-theme and
  theme-color, so the icon follows toggle click, saved theme on
  load, and OS-preference fallback (all route through applyTheme).
- Precache the new asset in the service worker.
This commit is contained in:
catarrh committed 2026-08-22 12:13:16 +03:00
1 parent d9133ffa57
commit 0f4f5e4e95
3 files changed
+51 -2

No files matched your search

+2 -1
View File
@@ -1,4 +1,4 @@
const CACHE = 'simtrace-analyser-v12';
const CACHE = 'simtrace-analyser-v13';
const PRECACHE = [
'index.html',
@@ -7,6 +7,7 @@ const PRECACHE = [
'icon-512.png',
'favicon.png',
'sim-analyser.svg',
'sim-analyser-light.svg',
];
self.addEventListener('install', e => {