-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
5661 statistics to badges #5917
base: main
Are you sure you want to change the base?
Conversation
Looks great! :-) |
Hi @nicolas-raoul what should I do with the failing check? or just leave it there? |
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 just tested, it is generally great, I only found these issues:
- Tapping the "featured images" icon shows the "thanks received" tooltip.
- Tapping the "quality images" icon shows the "featured images" tooltip.
- I am pretty sure I have 100+ nearby uploads and zero featured images, but I see this:
If the count was already incorrect in the main branch, then no need to fix the count.
@@ -370,7 +370,8 @@ | |||
<string name="delete">Delete</string> | |||
<string name="Achievements">Achievements</string> | |||
<string name="Profile">Profile</string> | |||
<string name="statistics">Statistics</string> | |||
<string name="statistics">Badges</string> |
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.
Can this one be removed?
I will check whether unit tests fail in master. If yes then don't worry. |
Please do not worry about unit tests, this is tracked at #5921 But do you have time to check #5917 (review) ? :-) |
Description (required)
Fixes #5661
What changes did you make and why?
Transformed the statistics of achievement into badges. Each badge changes to gray and hides its count if the value is 0.
Added badgeRender(Map<ImageView, TextView> badgeMap) function, used to render badges with a filter, and the GrayFilter(ImageView imageView) function applies the gray filter.
Used Google’s FlexboxLayout to enable badges to wrap automatically in the layout.
Added String Badges in Strings.xml, drawable badge_number_background.xml in drawable for displaying.
Tests performed (required)
Tested AchievementsFragmentUnitTests on Medium Phone API 33 (Android 13.0 "Tiramisu" | arm64 emulator).
Screenshots (for UI changes only)
Set badges numbers to 0
None 0 badges