Add progressive web app companion for cross-platform access

Vite + TypeScript PWA that mirrors the Android app's core features:
- Pre-processed shelter data (build-time UTM33N→WGS84 conversion)
- Leaflet map with shelter markers, user location, and offline tiles
- Canvas compass arrow (ported from DirectionArrowView.kt)
- IndexedDB shelter cache with 7-day staleness check
- Service worker with CacheFirst tiles and precached app shell
- i18n for en, nb, nn (ported from Android strings.xml)
- iOS/Android compass handling with low-pass filter
- Respects user map interaction (no auto-snap on pan/zoom)
- Build revision cache-breaker for reliable SW updates

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Ole-Morten Duesund 2026-03-08 17:41:38 +01:00
commit e8428de775
12051 changed files with 1799735 additions and 0 deletions

View file

@ -0,0 +1,36 @@
{
"name": "@surma/rollup-plugin-off-main-thread",
"version": "2.2.3",
"description": "Use Rollup with workers and ES6 modules today.",
"main": "index.js",
"scripts": {
"fmt": "prettier --write 'tests/**/*.js' *.js *.md *.json",
"test": "node ./run_tests.js"
},
"author": "Surma <surma@google.com>",
"license": "Apache-2.0",
"devDependencies": {
"chai": "4.2.0",
"chalk": "^2.4.2",
"karma": "4.2.0",
"karma-chai": "0.1.0",
"karma-chrome-launcher": "3.0.0",
"karma-firefox-launcher": "1.1.0",
"karma-mocha": "1.3.0",
"karma-safari-launcher": "1.0.0",
"karma-safaritechpreview-launcher": "2.0.2",
"mocha": "6.1.4",
"prettier": "1.18.2",
"rollup": "2.2.0"
},
"repository": {
"type": "git",
"url": "https://github.com/surma/rollup-plugin-off-main-thread"
},
"dependencies": {
"ejs": "^3.1.6",
"json5": "^2.2.0",
"magic-string": "^0.25.0",
"string.prototype.matchall": "^4.0.6"
}
}