From fa894183fcbd224d28575660ce55ff182b6b4799 Mon Sep 17 00:00:00 2001 From: Shawn Date: Mon, 25 May 2026 18:55:20 -0400 Subject: [PATCH] =?UTF-8?q?Add=20FEATURE=5FPLAN.md=20=E2=80=94=20full=20sp?= =?UTF-8?q?ec=20for=2011=20features=20(Offline=20Queue,=20Export,=20Inline?= =?UTF-8?q?=20Edit,=20Proximity,=20Walk-Path,=20Batch=20Assign,=20Sessions?= =?UTF-8?q?,=20Drift=20Check,=20Heatmap)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- FEATURE_PLAN.md | 629 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 629 insertions(+) create mode 100644 FEATURE_PLAN.md diff --git a/FEATURE_PLAN.md b/FEATURE_PLAN.md new file mode 100644 index 0000000..0d941e1 --- /dev/null +++ b/FEATURE_PLAN.md @@ -0,0 +1,629 @@ +# EXIF Scanner β€” Feature Roadmap + +> Living feature specification document. Covers all proposed features for the photo +> upload / OCR / GPS-push app at `~/projects/exif-test/`. + +**Legend:** βœ… build queue Β· πŸ’‘ proposed Β· πŸ—οΈ in progress + +--- + +## 1. βœ… Offline Queue β€” Service Worker + IndexedDB + +### Use Case + +Facility audits happen in warehouses, basements, parking lots, and rural sites β€” all +places with unreliable or zero cellular signal. Currently if the server is unreachable +the app shows nothing useful and queued photos are lost on page refresh. The user needs +to "fire and forget": snap photos, move to the next machine, and have the uploads drain +silently when signal returns. + +### User Experience + +1. Open the app β€” service worker installs, page loads from cache instantly +2. If online: everything works as today (live upload via fetch to `/api/analyze`) +3. If offline (navigator.onLine === false or fetch fails): + - Photo thumbnails still generate (client-side EXIF via exifr.js works offline) + - The gallery, summary, filter chips all work from IndexedDB-local + - "Bulk Process" button changes to "πŸ“‘ Queue for Upload (N pending)" + - A small banner at the top: "πŸ“‘ Offline β€” N photos queued" +4. When signal returns (online event or periodic background sync): + - Queue drains FIFO, one at a time, with retry (3 attempts, exponential backoff) + - Banner updates: "πŸ“‘ Syncing… (3/12 remaining)" + - On completion: banner disappears, results load from server `/api/photos` +5. Page refresh mid-queue: IndexedDB persists the queue, resumes on next load + +### Spec + +``` +IndexedDB schema β€” "photos-queue" store: + { id: auto_inc, file_blob: Blob, filename: string, timestamp: number, + retries: number, status: 'queued'|'uploading'|'done'|'failed' } + +Service worker: + - Cache-first strategy for static assets (/, /static/*) + - Network-first for /api/* (falls back to cached error page) + - Listen for 'sync' events from periodicSync API if available +``` + +### Tech + +- **Service Worker registration** in `