-
Notifications
You must be signed in to change notification settings - Fork 0
Sync app settings ads section with the core ads config #77
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
Sync app settings ads section with the core ads config #77
Conversation
- Update resolved-ref from 36be72f to 8995bd3
- Added new translations for banner ad shape selection in app_ar.arb and app_en.arb - Removed unused translations for inArticleAdSlotTypeBelowMainArticleImage - Updated translations for inArticleAdSlotTypeAboveArticleContinueReadingButton
…extension - Remove unused InArticleAdSlotType.belowMainArticleImage case - Update l10n function to reflect the removal of the case
…ction - Modified the ad platform configuration form to filter out the demo ad platform - Ensures that only non-demo ad platforms are displayed in the dashboard selection
- Replace AdType with BannerAdShape for in-article ad type selection - Update localization keys to reflect new banner ad shape selection - Remove unnecessary comments and adjust padding for better readability - Simplify segmented button configuration for banner ad shape
…tform type - Throw UnimplementedError when AdPlatformType.demo is used - This change clarifies that demo platform type is not intended for dashboard usage - Emphasizes that demo platform type is for mobile client and demo environment specific use cases
- Create new extension on BannerAdShape to provide localized string representations - Add l10n method to return localized name based on context and shape type - Implement switch case for different banner ad shapes (square and rectangle)
- Update resolved-ref from 8995bd3 to dd37d11
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.
Summary of Changes
Hello @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 focuses on synchronizing the application's ad settings within the dashboard with the core ad configuration. The primary goal is to refine the user interface for ad management, specifically by introducing more precise control over banner ad shapes and streamlining the display of ad platform types. These changes enhance the accuracy and usability of the ad configuration section.
Highlights
- Ad Platform Configuration: The dashboard UI for ad platform configuration now explicitly filters out the 'demo' ad platform type, ensuring only relevant options are presented to users.
- Article Ad Settings Refactor: The article ad settings form has been refactored to allow selection of 'Banner Ad Shape' (Square or Rectangle) instead of the previous 'Ad Type' (Native or Banner). This change aligns the dashboard's ad configuration with core ad settings.
- Localization Updates: Localization files have been updated to remove an unused in-article ad slot type string and introduce new strings for the banner ad shape selection, supporting multiple languages.
- New Extension for Banner Ad Shapes: A new Dart extension,
banner_ad_shape_l10n.dart, has been added to provide localized string representations forBannerAdShapeenum values.
Using Gemini Code Assist
The 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 in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
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 .gemini/ folder in the base of the repository. Detailed instructions can be found here.
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
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
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 refactors the ad configuration settings to align with updates in the core package. The main change involves replacing the generic AdType selection with a more specific BannerAdShape for in-article ads, which improves clarity. It also filters out the 'demo' ad platform from the dashboard UI. The changes are well-contained and include necessary updates to localization files. My review includes one suggestion to improve code formatting for better readability.
| .where( | ||
| (type) => | ||
| type != | ||
| AdPlatformType | ||
| .demo, // Ignore demo ad platform for dashboard | ||
| ) |
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.
For improved readability and conciseness, the .where() clause can be simplified to a single line. The current multi-line formatting for this simple condition is verbose and deviates from common Dart formatting practices.
| .where( | |
| (type) => | |
| type != | |
| AdPlatformType | |
| .demo, // Ignore demo ad platform for dashboard | |
| ) | |
| .where((type) => type != AdPlatformType.demo) // Ignore demo ad platform for dashboard |
Status
READY
Description
This pull request focuses on synchronizing the application's ad settings within the dashboard with the core ad configuration. The primary goal is to refine the user interface for ad management, specifically by introducing more precise control over banner ad shapes and streamlining the display of ad platform types. These changes enhance the accuracy and usability of the ad configuration section.
Type of Change