-
Notifications
You must be signed in to change notification settings - Fork 0
Refactor/enhance headlines table UI #141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Add Arabic and English translations for breaking news tooltip - Update app_ar.arb and app_en
- Replace Stack with RichText for better layout and performance - Add tooltip for breaking news icon to aid screen readers - Adjust icon size and spacing for better visual consistency - Ensure text and icon alignment across different screen sizes
- Add Arabic and English translations for the breaking news filter description - Extend app_ar.arb and app_en.arb files with new subtitle for the breaking news filter switch
- Replace `BreakingNewsFilterStatus` enum with a simple boolean `isBreaking` flag - Update default value from `BreakingNewsFilterStatus.all` to `false` - Adjust property and constructor parameter names accordingly
- Change HeadlinesBreakingNewsFilterChanged to use bool instead of BreakingNewsFilterStatus - Update HeadlinesFilterApplied to use bool for isBreaking - Simplify props list in both events
perf- Remove(content_management unused Breaking): optimizeNewsFilter breaking newsStatus filter logic enum -- Simpl Simplifyify is theBreaking breaking filter news logic filter to by only removing include unused ' enumtrue values' condition- Improve- query Improve performance code by readability only and adding ' reduceis complexityBreaking '
- Change `isBreaking` from BreakingNewsFilterStatus to bool - Update default value from BreakingNewsFilterStatus.all to false - Remove outdated comments explaining the previous enum-based logic
- Update type of isBreaking parameter in FilterDialogBreakingNewsChanged event from BreakingNewsFilterStatus to bool
- Remove unused import statement - Modify reset logic to set isBreaking to false - Improve code readability by using copyWith method
- Remove unused import of BreakingNewsFilterStatus - Simplify isBreaking filter condition - Update comments and documentation
- Remove BreakingNewsFilterStatus enum - Replace with a simple boolean isBreaking - Update UI to use SwitchListTile instead of ChoiceChip - Update localization keys and remove unused ones - Adjust layout and spacing
- Add Arabic and English translations for publishing, archiving, restoring, and deleting items - Include titles and content for confirmation dialogs related to item actions
- Add confirmation dialog for publish, archive, restore, and delete actions - Refactor content action handling
…nackbar message - Add Arabic translations for item action confirmations in app_ar.arb - Update app_en.arb to include item deletion snackbar message - Modify existing confirmation messages for consistency across both languages
…gDeletion - Remove snackbarMessage field from ContentManagementState - Add itemPendingDeletion field of type FeedItem? - Update copyWith method to use new field - Update props list in Equatable to include new field
- Replace snackbarMessage with itemPendingDeletion in state - Remove messageBuilder from undo deletions - Clear itemPendingDeletion on undo or deletion completion - Update comments to explain changes in snackbar logic
- Replace generic snackbar message with specific item-related message - Add logic to determine deleted item type and name - Update UI to display customized snackbar message for deleted items
- Add message field to DeletionEvent class - Add messageBuilder parameter to requestDeletion method - Implement message building in PendingDeletionsServiceImpl - Update _PendingDeletion class to include message field
…n switch statement - Add a case for DeletionStatus.requested in the switch statement - Include a comment explaining that this case is now handled by the optimistic UI update in specific delete handlers - Mention that the itemPendingDeletion is set in those handlers, which the UI uses to build the snackbar message
…nding deletions - Add DeletionStatus.requested enum value to represent a pending deletion request - Implement functionality to immediately notify listeners when a deletion is requested - Update PendingDeletionsServiceImpl to send a DeletionEvent with requested status upon request
- Add Arabic translations for 'headline', 'topic', and 'source' - Include descriptions for new labels in both Arabic and English files - Maintain consistency in translation style and formatting
- Change 'headlines' to 'headline' - Change 'topics' to 'topic' - Change 'sources' to 'source'
- Add placeholders for item type in confirmation dialog messages - Update translations for publish, archive, restore, and delete actions - Improve clarity of messages, especially for delete action
…nt types - Introduce type-specific confirmation dialogs for publish, archive, restore, and delete actions - Replace generic item-related messages with type (headline, topic, or source) specific messages - Improve user experience by providing more context in confirmation dialogs
Summary of ChangesHello @fulleni, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request refactors and enhances the user interface and underlying logic for content management, specifically focusing on the headlines table. The changes simplify the breaking news filter, improve the user feedback for deletion actions by providing more contextual and localized snackbar messages, and introduce confirmation dialogs for critical content operations. Additionally, the visual presentation of breaking news headlines has been refined for better clarity and user experience. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request introduces a significant and well-executed refactoring of the content management UI and its underlying logic. The simplification of the 'breaking news' filter from an enum to a boolean improves clarity and simplifies the UI. The refactoring of the deletion flow, moving snackbar message creation to the UI layer and enhancing the PendingDeletionsService, is a great architectural improvement that enhances separation of concerns. Furthermore, the UI for displaying breaking news headlines has been improved using RichText, and the addition of confirmation dialogs for actions is a welcome UX enhancement. I've found one critical issue where delete functionality for Topics and Sources has been unintentionally removed during the refactor. Apart from that, the changes are excellent and improve the codebase's quality and maintainability.
Status
READY
Description
This pull request refactors and enhances the user interface and underlying logic for content management, specifically focusing on the headlines table. The changes simplify the breaking news filter, improve the user feedback for deletion actions by providing more contextual and localized snackbar messages, and introduce confirmation dialogs for critical content operations. Additionally, the visual presentation of breaking news headlines has been refined for better clarity and user experience.
Type of Change