Conversation
- **New Feature: Seen Repositories**
- Implement a tracking system to mark GitHub repositories as "seen" once viewed in the details screen.
- Add a toggle in Profile settings to hide previously seen repositories from discovery and search feeds.
- Provide a "Clear Seen History" option in settings to reset the seen status of all repositories.
- Update `HomeViewModel`, `SearchViewModel`, and `DetailsViewModel` to handle seen repository state and filtering logic.
- **Database & Data Layer**
- Perform a Room database migration (version 5 to 6) to add the `seen_repos` table.
- Create `SeenRepoDao`, `SeenRepoEntity`, and `SeenReposRepository` to manage persistent seen status.
- Update `TweaksRepository` to store the "Hide Seen" user preference.
- **Flatpak Packaging**
- Add initial Flatpak packaging support including build manifest (`.yml`), AppStream metadata, desktop entry, and launcher scripts.
- Include a comprehensive `README.md` in the packaging directory detailing build requirements and local installation steps.
- **UI & Localization**
- Add localized strings for "Hide Seen Repositories" and "Clear Seen History" features.
- Enhance the Profile screen with new toggle and action cards for managing seen repository history.
- Add localized strings for "Hide seen repositories", "Clear seen history", and related descriptions. - Provide translations for Arabic, Bengali, Spanish, French, Hindi, Italian, Japanese, Korean, Polish, Russian, Turkish, and Chinese (Simplified). - Include status message for "Seen history cleared" notification.
- Add `isSeen` property to `DiscoveryRepositoryUi` to track if a repository has been viewed. - Update `HomeViewModel` and `SearchViewModel` to observe seen repository IDs and reactively update the UI state. - Initialize the `isSeen` status when mapping repository data in both home and search flows. - Implement `SeenBadge` component in `RepositoryCard` to display a "Viewed" label with a visibility icon. - Add "Viewed" localized string resource. - Refactor `RepositoryCard` to display multiple badges (Installation status and Seen status) using a `Row` layout.
…ages - Add localized string for `seen_badge` to provide a "Seen" or "Viewed" label. - Update translations for Bengali, Hindi, Italian, Spanish, Arabic, French, Polish, Russian, Japanese, Korean, Turkish, and Chinese (Simplified).
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (42)
WalkthroughA new "seen repositories" feature is introduced, tracking which repositories users have viewed. It adds database persistence (new Changes
Sequence Diagram(s)sequenceDiagram
actor User
participant DetailsScreen
participant DetailsVM as DetailsViewModel
participant SeenRepo as SeenReposRepository
participant SeenDAO as SeenRepoDAO
participant DB as Database
User->>DetailsScreen: Views repository details
DetailsScreen->>DetailsVM: Repository loaded (repo.id)
DetailsVM->>SeenRepo: markAsSeen(repoId)
SeenRepo->>SeenDAO: insert(SeenRepoEntity)
SeenDAO->>DB: INSERT INTO seen_repos
DB-->>SeenDAO: Success
Note over DetailsVM: Concurrently observing seen repos
DetailsVM->>SeenRepo: getAllSeenRepoIds()
SeenRepo->>SeenDAO: Query all seenRepoIds
SeenDAO->>DB: SELECT repoId FROM seen_repos
DB-->>SeenDAO: List of repoIds
SeenDAO-->>SeenRepo: Flow<Set<Long>>
SeenRepo-->>DetailsVM: Update state.seenRepoIds
participant HomeVM as HomeViewModel
participant HomeScreen
HomeVM->>HomeVM: Observe seenRepoIds & isHideSeenEnabled
HomeVM->>HomeVM: Compute visibleRepos = repos.filter()
HomeVM-->>HomeScreen: Update state with filtered repos
HomeScreen->>RepositoryCard: Render each repo with isSeen flag
RepositoryCard->>RepositoryCard: Show SeenBadge if isSeen
HomeScreen-->>User: Display filtered list
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Possibly related PRs
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
New Feature: Seen Repositories
HomeViewModel,SearchViewModel, andDetailsViewModelto handle seen repository state and filtering logic.Database & Data Layer
seen_repostable.SeenRepoDao,SeenRepoEntity, andSeenReposRepositoryto manage persistent seen status.TweaksRepositoryto store the "Hide Seen" user preference.Flatpak Packaging
.yml), AppStream metadata, desktop entry, and launcher scripts.README.mdin the packaging directory detailing build requirements and local installation steps.UI & Localization
Summary by CodeRabbit
Release Notes
New Features
UI/UX Improvements
Localization
Documentation