Skip to content

Feature: Bookmark Sheet Integration#701

Merged
yusufnasserdev merged 20 commits intodevelopfrom
feature/snackbar-host
Aug 19, 2025
Merged

Feature: Bookmark Sheet Integration#701
yusufnasserdev merged 20 commits intodevelopfrom
feature/snackbar-host

Conversation

@yusufnasserdev
Copy link
Collaborator

Navigation Host Wrapping & Bookmark Sheet Integration

Summary

This PR introduces a comprehensive navigation host wrapping implementation and integrates the bookmark sheet functionality across multiple screens. The changes include architectural improvements, UI enhancements, and bug fixes to provide a consistent user experience for managing bookmarks throughout the application.

Key Changes

1. Navigation Host Wrapping

  • Replaced basic Scaffold with ScaffoldWithSnackbar in NavHostGraph.kt
  • Added snackbar controller composition local provider for global snackbar management
  • Enhanced navigation structure to support consistent UI patterns

2. Bookmark Sheet Integration

Integrated the bookmark bottom sheet across multiple screens:

  • Movie Category Screen - Added bookmark management for category movies
  • Movie Details Screen - Replaced simple save icon with full bookmark functionality
  • Continue Watching Screen - Added bookmark support for movies in continue watching
  • Top Rated Screen - Enabled bookmark management for top-rated content
  • Trending Movies Screen - Integrated bookmark functionality
  • Search Screen - Added bookmark support in search results and recent items

3. Architectural Improvements

  • Enhanced CustomMovieListRepository with better error handling and caching
  • Fixed API endpoint for account lists (GET_ACCOUNT_LISTS_PATH)
  • Added cache clearing on logout and sync metadata management
  • Improved data synchronization with periodic sync scheduling moved to MainActivity

4. UI/UX Enhancements

  • Consistent snackbar implementation across all screens
  • Improved empty states with better messaging for no lists available
  • Fixed localization issues in Arabic strings
  • Enhanced onboarding screen padding and insets handling

Technical Details

New Components

  • ScaffoldWithSnackbar: Wrapper component that provides snackbar functionality
  • LocalSnackbarController: Composition local for global snackbar access
  • BookmarkBottomSheet: Reusable component for managing bookmarks

Refactored Components

  • Media grid components now support conditional save icons
  • HomeCard component updated with hasSaveIcon parameter
  • Navigation handlers improved for better type safety

Bug Fixes

  • Fixed movie list synchronization on authentication changes
  • Resolved cache invalidation issues when adding/removing items
  • Fixed API path for account lists retrieval
  • Improved error handling throughout the bookmark flow

Impact

  • ✅ Provides consistent bookmarking experience across all screens
  • ✅ Improves navigation structure and UI consistency
  • ✅ Enhances performance with better caching strategies
  • ✅ Fixes several edge cases in list management
  • ✅ Maintains backward compatibility with existing functionality

This implementation provides a solid foundation for the bookmarking system while maintaining the app's performance and user experience standards.

# Conflicts:
#	app/src/main/java/com/london/app/navigation/NavHostGraph.kt
- Implement a global snackbar using `ScaffoldWithSnackbar` and `SnackbarController` to display messages across the app.
- Refactor movie list caching logic in `CustomMovieListRepositoryImpl` for improved efficiency and error handling.
- Clear `SyncMetadataDao` cache on logout in `AuthenticationRepositoryImpl`.
- Update `BookmarkSheet` to use the new global snackbar.
- Adjust UI padding in `OnboardingScreen` for better system bar handling.
- Modify "no lists available" string for clarity.
- Ensure `MovieListSyncWorker` is scheduled in `MainActivity`.
# Conflicts:
#	data/src/main/java/com/london/data/remote/service/list/CustomMovieListsApiService.kt
#	data/src/main/java/com/london/data/repository/list/CustomMovieListRepositoryImpl.kt
#	presentation/src/main/java/com/london/presentation/feature/search/SearchScreen.kt
# Conflicts:
#	app/src/main/java/com/london/app/navigation/graph/mainNavGraph.kt
@yusufnasserdev yusufnasserdev self-assigned this Aug 19, 2025
@yusufnasserdev yusufnasserdev requested review from a team August 19, 2025 20:22
@london-bot
Copy link
Contributor

london-bot bot commented Aug 19, 2025

[London Bot] Metrics Update Status

❌ An error occurred while updating PR metrics.

@london-bot
Copy link
Contributor

london-bot bot commented Aug 19, 2025

[London Bot] Auto-update Status

✅ Branch successfully updated from develop.

@marwanqashwa marwanqashwa self-requested a review August 19, 2025 21:37
Copy link
Contributor

@BassantM BassantM left a comment

Choose a reason for hiding this comment

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

image it was not clickable in actor details screen

Copy link
Contributor

@marwanqashwa marwanqashwa left a comment

Choose a reason for hiding this comment

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

great job

@github-actions
Copy link

github-actions bot commented Aug 19, 2025

@yusufnasserdev yusufnasserdev merged commit 2253ef3 into develop Aug 19, 2025
14 of 20 checks passed
@yusufnasserdev yusufnasserdev deleted the feature/snackbar-host branch August 19, 2025 23:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants