--- id: TASK-135 title: PWA — offline support (SW + IndexedDB) status: Done assignee: [] created_date: '2026-03-29 20:52' labels: - pwa - offline milestone: m-2 dependencies: [] priority: medium --- ## Description Write sw.js (service worker with 3 cache buckets: shell/guides/mediapipe, cache-first for shell+CDN, network-first for guides, offline fallback) and manifest.json (PWA install metadata). ## Acceptance Criteria - [ ] #1 Three versioned cache buckets - [ ] #2 Shell pre-cached on install, old caches cleaned on activate - [ ] #3 CACHE_GUIDE_URL message handler for dynamic guide caching - [ ] #4 Offline fallback: cached index.html for nav, error JSON for guides - [ ] #5 PWA manifest with standalone display and portrait orientation ## Final Summary sw.js (210 lines): 3 cache buckets, pre-cache on install, clients.claim(), offline fallback. manifest.json with simulator shortcut.