Introduces legacyDevicesProvider as the canonical AsyncNotifier owning
the devices list, with semantic mutation methods (removeDevice,
renameDevice, refresh) instead of ref.invalidate from outside.
selectedDeviceProvider becomes an AsyncNotifier that persists the
selected device id in SharedPreferences and resolves it against the
shared list at build time, surviving cold starts.
ControlPanelViewModel and LocationViewModel are converted to
AsyncNotifier and react to selection changes, refetching positions /
geofences / frequent_places automatically. Screens use .when with
skipLoadingOnReload to avoid flicker.
Multi-device fixes:
- DeviceBanner cards now look up positions per device by identificator
- LocationMap recenters the camera on device swipe
- Country-level fallback zoom when no position is available
- Banner shows each device's own info while swiping
linked_devices and device_setup feed mutations through the new notifier
methods. 30+ legacy view models updated to read selectedDeviceProvider
via .value (AsyncNotifier shape).
- Add DeviceSettingsSync extension on Ref to centralize device provider
updates after settings changes (sound, volume, language, timezone,
battery, disable functions, alerts, pedometer, heart rate freq,
location freq, background image)
- Add photo capture countdown with Lottie animation in remote camera
- Replace Image.network with Image.memory for photo display
- Fix commands datasource to handle text/html responses (post<dynamic>)
- Add typed error/success events to RemoteConnectionViewModel
- Add background image active indicator and backgroundImageId to device settings
- Change photos endpoint from /devices/identificator/:id/photos/files to /photos/files
- Remove dead deviceId param from getBackgroundImage chain
- Relax PictureEntity required fields to @Default for API compatibility
- Fix LocationViewModel rebuild crash (ref.watch → ref.read)
- Use .select() in RemoteCameraScreen for optimized rebuilds
- Increase health measure countdown to 60s
- Fix upload flow: capture photo ID from POST /photos response
- Fix endpoint: use /devices/identificator/{id}/photos/files for listing
- Fix setBackgroundImage: use device.id (UUID) instead of identificator
- Redesign screen as photo gallery with grid view
- Add image compression on pick (maxWidth: 800, quality: 80%)
- Fix multipart upload: remove content-type header for FormData auto-detection
- Replace hardcoded Spanish text with i18n in 6 languages
- Add typed error/success enums (BackgroundImageErrorEvent, BackgroundImageSuccessEvent)
- Revert initialLocation to splash
- Add missing translations for contacts and background-image features
- Type device.settings and device.capabilities from untyped maps to Freezed models
- Centralize all device settings updates through shared DeviceSettingsUpdateDatasource
- Add frequency selectors for location and heart rate, pedometer toggle, and health measurement countdown with Lottie animation
- Replace raw backend error messages with typed i18n error events across location, health, and activity meter
- Fix silent error swallowing in commands datasource and stuck dialog in locate device
- Add REQUEST_HEART_RATE command with measure button in health screen
- Add ref.mounted checks and fix early return in measure()
- Remove unused SET_LANGUAGE from DeviceCommand enum
- Implement photos API (GET /devices/identificator/{id}/photos)
- Fix deviceId empty in commands (set before async load)
- Fix missing await in call() method
- Add ref.mounted checks on all async operations
- Reload photos after REQUEST_PHOTO command
- Add CountryPrefixPicker to spy call dialog
- Add loading state and topSnackbar feedback on call
- Handle empty photos list in gallery
- Fix Expanded overflow in remote camera screen
- Change keyboard to phone type in spy call
- Remove unnecessary use cases
- Add GetPicturesResponseModel with freezed
- Add volume control screen with sliders for media, ringtone, and alarm
- Update device settings via PUT /devices with CSV (same as language)
- Extract DeviceCsvBuilder to legacy_shared (shared between language and volume)
- Create Riverpod provider for DeviceUpdateDatasource
- Extract VolumeThumbShape to separate widget file
- Merge sound mode feature (SET_SOUND_MODE command, pending backend whitelist)
- Fix sound screen overflow with SingleChildScrollView
- Change language update from POST /commands to PUT /devices with CSV
- Add CSV escape for JSON fields (doubled quotes)
- Move device payload construction to datasource layer
- Add loading indicator on save button
- Fix 401 redirect to legacy login
- Remove debug print from commands datasource
- Fix position address model nullability (province field missing from API)
- Fix health query order to sortDirection to match backend API
- Add pagination to health chart queries to prevent backend timeout
- Align GetDevicesResponseModel with full backend schema
- Add route history with gradient polyline, direction arrows, and clustering
- Add animated map movements
- Add follow mode with auto-refresh
- Add share location via Google Maps link
- Add fit bounds on history load
- Add expandable action buttons panel
- Add location list bottom sheet with type filters
- Add whitelist sync alongside secondary contacts
- Add loading state to linked devices screen
- Refactor location_map.dart: extract RouteHistoryLayer, MapActionsPanel
- Migrate setState to LocationMapViewModel
- Position history with polyline trail and date range picker
- Map style selector (standard, voyager, light, dark, satellite) persisted via SharedPreferences
- Geofence and frequent place CRUD with info cards
- Device banner with swipeable carousel
- Refresh position button
- Widget extraction: map controls, info cards, device banner, modal overlay
Device management:
- Activity meter with steps charts and history
- Apps usage with daily breakdown and top apps
- Health monitoring (heart rate, oxygen, blood pressure)
- Scheduled activities with timeline and CRUD
- Contacts sync to device via contact-lists
- Locate device, rewards refactor
Settings (new module):
- Block phone
- SOS contacts
- WiFi networks
- Alarm refactor with full CRUD
- Settings menu with feature stubs
Account:
- Personal data and account settings refactor
Shared:
- 100+ i18n keys in 6 languages
- New routes in app_router
- WeekDayChips, TimeRangeSelector shared widgets
- Legacy dashboard shell simplified