Skip to content

Remove VIDEO tab; implement app-scoped Gallery, static map overlay, Settings & Account - #22

Merged
krishna3554 merged 1 commit into
mainfrom
codex/remove-video-tab-from-bottom-bar
May 14, 2026
Merged

krishna3554 merged 1 commit into
mainfrom
codex/remove-video-tab-from-bottom-bar

Conversation

@krishna3554

Copy link
Copy Markdown
Owner

Motivation

  • Remove the unused VIDEO mode and simplify the camera UX to a single PHOTO capture flow.
  • Keep an app-scoped gallery that only shows photos produced by this app and support full-screen viewing, sharing and deletion.
  • Fix the live-map-in-camera preview reliability by replacing the embedded live map with a pre-fetched static map image and persist map/overlay settings.
  • Provide a persistent Settings screen and a production-style Account screen (local/guest scaffold) so users can configure app behavior and view stats.

Description

  • Removed video mode UI and related state from the camera screen and bottom bar, kept a centered PHOTO selector and replaced the Template button with Account (camera now initializes with AppSettings.resolutionPreset).
  • Added app-scoped photo model and persistence: created AppPhoto and AppPhotoStore backed by shared_preferences to save/restore only photos created by this app and to delete files when requested.
  • Reworked Gallery to show only app-saved photos (lib/features/gallery/screen/gallery_screen.dart) with a 3-column GridView, long-press bottom sheet (View / Share), full-screen AppPhotoViewer showing metadata and offering Share and Delete actions via share_plus.
  • On result/save flow the app now composes the geo-tagged image, optionally saves to the system gallery via GalleryService and always records the photo in the app store (AppPhotoStore) so the gallery is scoped to app photos (lib/features/result/screen/result_screen.dart).
  • Replaced the live embedded map preview widget with a static Google Static Maps URL image (via GoogleMapService.staticMapUri) and pre-fetch/caching support; moved overlay rendering to LocationStampCard which now consults SettingsService for mapStyle, mapZoomLevel, showCoordinates, and showCompassSpeedAltitude (lib/core/widgets/location_stamp_card.dart, lib/services/google_map_service.dart).
  • Implemented persisted app settings and bindings: AppSettings model, SettingsService using shared_preferences, and a SettingsScreen UI exposing map style, overlay position, coordinates toggles, photo quality, auto-save toggle, date format, map zoom and theme toggles (lib/models/app_settings.dart, lib/services/settings_service.dart, lib/features/settings/screen/settings_screen.dart).
  • Added an AccountScreen with editable local profile sheet, guest-mode banner, photos/locations/member-stats and a backup scaffold plus a BackupService placeholder for future Firebase integration (lib/features/account/screen/account_screen.dart, lib/services/backup_service.dart).
  • Small thematic polish: added a dark theme entry in AppTheme and wired MyApp to honour the saved theme mode; added shared_preferences to pubspec.yaml.

Testing

  • Ran git diff --check to verify the working tree changes (no whitespace/patch errors) and inspected diffs manually; this passed in the environment used for development.
  • Attempted flutter pub get but it failed because the Flutter SDK is not installed in the container (flutter: command not found).
  • Attempted dart --version / formatting but the Dart SDK is not installed in the container (dart: command not found).
  • Attempted to run flutter test but this was skipped because the Flutter SDK is not available in the environment.
  • Manual static inspection and lightweight runtime reasoning were used to ensure the new flows connect (camera -> result -> app photo store -> gallery), and feature toggles are persisted via SettingsService.

Codex Task

@krishna3554
krishna3554 merged commit 028dc42 into main May 14, 2026
0 of 3 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 68dbe7a730

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

const GalleryScreen({super.key, this.filteredAssets});

final List<AssetEntity>? filteredAssets;
const GalleryScreen({super.key});

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Keep the GalleryScreen filtered constructor

Removing the filteredAssets parameter breaks the existing Locations flow: lib/features/locations/screen/locations_screen.dart still pushes GalleryScreen(filteredAssets: entry.value) when a location group is tapped, so this commit no longer builds until that caller is migrated or the constructor support is retained.

Useful? React with 👍 / 👎.

await _photoStore.addPhoto(
AppPhoto(
id: DateTime.now().microsecondsSinceEpoch.toString(),
filePath: finalResult.filePath,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Store app photos outside the temp directory

This persists finalResult.filePath in the app gallery, but ImageOverlayService.composeGeoTaggedImage writes that path under getTemporaryDirectory(). On devices that clear app caches, or after routine cache cleanup, the app-scoped Gallery will silently lose saved captures even when the user expects them to remain in “My Photos”; use a durable app-documents path or copy the generated image before adding it to AppPhotoStore.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant