-
Notifications
You must be signed in to change notification settings - Fork 8.9k
Add Badge to highlight new Extensions Page #18813
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
Add Badge to highlight new Extensions Page #18813
Conversation
f650f45 to
b963d60
Compare
5c34eb7 to
641b654
Compare
b963d60 to
f25e6fe
Compare
641b654 to
87946e9
Compare
|
Based on @cinnamon-msft's work over in microsoft/PowerToys#36939: |
| </data> | ||
| <data name="NewInfoBadgeTextBlock.Text" xml:space="preserve"> | ||
| <value>NEW</value> | ||
| <comment>Text is used on an info badge for new navigation items. Must be all caps.</comment> |
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.
I do not believe the translators actually read these. or exist.
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.
I think it may be beneficial for us long-term if we replaced the comments with ones like
"NEW" as in "New item!"
in this case. Even if there aren't always human translators, the potential LLM translators may be "thankful"? for it. 😅




Summary of the Pull Request
Adds a badge to the Extensions Page in the SUI's navigation pane to highlight that it's new!
References and Relevant Issues
Targets #18633
Detailed Description of the Pull Request / Additional comments
ApplicationStateclass to track which badges have been dismissed and prevent them from appearing againstd::unordered_set, but exposed agetandappendfunction via the IDLNewInfoBadgestyle that is just an InfoBadge with "NEW" in it instead of a number or an icon. Based on Add "new" labels to navigation PowerToys#36939getcall to theApplicationStateconducted via theExtensionsPageViewModel. The VM is also responsible for updating the state.Long-term, we can reuse this system and make the following minor changes:
SettingContainer: display the badge. and add logic to read/writeApplicationStateappropriately (similarly to above)XPageViewModel:NewInfoBadgestyleValidation Steps Performed
✅ Extensions page nav item displays a badge if page hasn't been visited
✅ The badge is dismissed when the user visits the page