Appearance
Story 4: Work Offline and Sync
Available Now
This feature is fully implemented in the current version.
As a field worker I want to add elements and inspections without internet So that I can work anywhere on the property
User Journey
Wireframes
State 1: Online (normal)
┌─────────────────────────┐
│ Waterworks [+] │
├─────────────────────────┤
│ │
│ (map content) │
│ │
├─────────────────────────┤
│ ● Online │
└─────────────────────────┘State 2: Offline with pending changes
┌─────────────────────────┐
│ Waterworks [+] │
├───────────────┬─────────┤
│ │ Offline │
│ (map) │ 🟠 │
│ │ │
├───────────────┴─────────┤
│ ⏳ 3 changes pending │
└─────────────────────────┘State 3: Syncing
┌─────────────────────────┐
│ Waterworks [+] │
├─────────────────────────┤
│ │
│ (map content) │
│ │
├─────────────────────────┤
│ ↻ Syncing 3 changes... │
└─────────────────────────┘State 4: Sync complete (toast)
┌─────────────────────────┐
│ Waterworks [+] │
├─────────────────────────┤
│ │
│ (map content) │
│ │
├─────────────────────────┤
│ ✓ All changes synced │
│ ● Online │
└─────────────────────────┘Steps
- Lose signal - App detects offline state
- Continue working - Add elements, record inspections
- See pending count - Badge shows queued changes
- Regain signal - App auto-detects connectivity
- Auto-sync - Changes push to cloud
- Confirmation - Toast shows sync complete
Key Behaviors
Offline Capabilities
All features work without internet:
- ✅ Capture photos
- ✅ AI classification (on-device)
- ✅ GPS location capture
- ✅ Create elements
- ✅ View existing data
- ✅ Search and filter
Sync Behavior
| Action | Behavior |
|---|---|
| Lose connection | Auto-detects, shows offline indicator |
| Create element | Saves locally, increments pending count |
| Regain connection | Auto-starts sync |
| Sync in progress | Shows progress indicator |
| Sync complete | Toast notification, counter clears |
Conflict Resolution
When multiple devices edit the same element offline:
- Last-write-wins with timestamps
- Photos are never lost (all kept)
- User notified of conflicts if detected
Implementation Status
✅ Partially Implemented - Local persistence with SwiftData works fully offline (M0-M4). Cloud sync to backend is in progress (M5). Currently, all data stays on-device. Multi-device sync will be available once M5 is complete.
Your Data Is Safe
Don't worry about losing work. When you're offline:
- Every element you create is saved immediately to your device
- Every photo you capture is stored locally
- Every edit you make is preserved
When connectivity returns, the app automatically syncs everything. You don't need to do anything—just keep working.
What if sync fails? If there's an error during sync, the app will retry automatically. Your pending changes stay queued until they're successfully uploaded. You'll see the count of pending changes in the Settings tab.
Related Features
- Settings — View sync status and pending changes
- Installation — Detailed offline operation guide
- Camera-First Capture — How offline capture works