diff --git a/backend/main.py b/backend/main.py index 69fbf78..376e2c1 100644 --- a/backend/main.py +++ b/backend/main.py @@ -410,7 +410,7 @@ async def serve_media(path: str, request: _Request): raise _HE(404, "Nicht gefunden.") return _media_response(filepath) -APP_VER = "1084" # muss mit APP_VER in app.js übereinstimmen +APP_VER = "1085" # muss mit APP_VER in app.js übereinstimmen @app.get("/.well-known/assetlinks.json") async def assetlinks(): diff --git a/backend/static/css/components.css b/backend/static/css/components.css index a26655f..45c313a 100644 --- a/backend/static/css/components.css +++ b/backend/static/css/components.css @@ -8872,12 +8872,11 @@ svg.empty-state-icon { (Default = weiß auf orange, filled = grün auf orange) ============================================================ */ #worlds-fab .offline-paw .paw-elem { - color: #fff; - transition: stroke 0.4s ease, fill 0.4s ease; + color: #fff; /* stroke via currentColor — fill bleibt 'none' aus HTML */ + transition: stroke 0.4s ease; } #worlds-fab .offline-paw .paw-elem.filled { - color: #16a34a; /* leuchtendes Grün, klar sichtbar auf orange */ - fill: #16a34a; + color: #16a34a; /* nur Linie grün, kein Ausfüllen */ } .offline-status-row { diff --git a/backend/static/index.html b/backend/static/index.html index 8d4f29d..30114e6 100644 --- a/backend/static/index.html +++ b/backend/static/index.html @@ -101,9 +101,9 @@ - - - + + + @@ -625,11 +625,11 @@ - - - - - + + + + + diff --git a/backend/static/js/app.js b/backend/static/js/app.js index 720ee0f..1375f40 100644 --- a/backend/static/js/app.js +++ b/backend/static/js/app.js @@ -3,7 +3,7 @@ Router, State-Management, Navigation, Initialisierung. ============================================================ */ -const APP_VER = '1084'; // ← bei jedem Deploy mit Frontend-Änderungen erhöhen +const APP_VER = '1085'; // ← bei jedem Deploy mit Frontend-Änderungen erhöhen const APP_VERSION = '1.6.0'; // ← semantische Version, wird bei make release gesetzt window.APP_VER = APP_VER; // global verfügbar für andere Module (z.B. offline-indicator) window.APP_VERSION = APP_VERSION; diff --git a/backend/static/js/offline-indicator.js b/backend/static/js/offline-indicator.js index ea81ebb..48f2566 100644 --- a/backend/static/js/offline-indicator.js +++ b/backend/static/js/offline-indicator.js @@ -31,11 +31,11 @@ window.OfflineIndicator = (() => { } }, { step: 2, title: 'Wichtige Seiten', - detail: 'Tagebuch, Karte, Gassi, Erste Hilfe', + detail: 'Tagebuch, Karte, Gassi, Erste Hilfe, Notizblock, Ausgaben, Routen', probe: async () => { const c = await _staticCache(); if (!c) return false; - const must = ['diary.js','map.js','walks.js','erste-hilfe.js']; + const must = ['diary.js','map.js','walks.js','erste-hilfe.js','notes.js','expenses.js','routes.js']; const urls = (await c.keys()).map(r => r.url); return must.every(name => urls.some(u => u.includes('/js/pages/' + name))); } }, @@ -141,7 +141,7 @@ window.OfflineIndicator = (() => { const tasks = []; for (const m of missing) { if (m.step === 2) { - ['diary.js','map.js','walks.js','erste-hilfe.js'].forEach(p => + ['diary.js','map.js','walks.js','erste-hilfe.js','notes.js','expenses.js','routes.js'].forEach(p => tasks.push(fetch(`/js/pages/${p}?v=${window.APP_VER}`).catch(() => {}))); } else if (m.step === 3) { const dogId = window._appState?.activeDog?.id; diff --git a/backend/static/sw.js b/backend/static/sw.js index 5dd52bb..19811d7 100644 --- a/backend/static/sw.js +++ b/backend/static/sw.js @@ -4,19 +4,22 @@ ============================================================ */ // ← EINZIGE Stelle für die Version — STATIC_ASSETS und CACHE_VERSION leiten sich ab -const VER = '1084'; +const VER = '1085'; const CACHE_VERSION = `by-v${VER}`; const CACHE_STATIC = `${CACHE_VERSION}-static`; const CACHE_TILES = 'ban-yaro-tiles-v1'; // bleibt über SW-Updates erhalten const CACHE_API = 'ban-yaro-api-v1'; // API-Response-Cache // Prioritäts-Seiten: werden nach Install im Hintergrund gecacht (nicht blockierend) +// Diese Seiten MÜSSEN offline funktionieren — auch wenn der User sie noch nie geöffnet hat. const PRIORITY_PAGES = [ - '/js/pages/admin.js', - '/js/pages/erste-hilfe.js', '/js/pages/diary.js', + '/js/pages/health.js', '/js/pages/map.js', '/js/pages/walks.js', + '/js/pages/erste-hilfe.js', + '/js/pages/notes.js', + '/js/pages/expenses.js', '/js/pages/routes.js', '/js/pages/poison.js', '/js/pages/lost.js',