-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
fix(accessibility): add contentDescription to Add Deck FAB #20120
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
base: main
Are you sure you want to change the base?
fix(accessibility): add contentDescription to Add Deck FAB #20120
Conversation
|
Important Maintainers: This PR contains Strings changes
|
|
@david-allison Thanks for taking a look when you have time. |
|
@Chiraggupta0 no need to ping, thanks for the PR, I'll get around to it when I have time Typically: give people 48 hours to respond, 24 is fine for me |
| @@ -0,0 +1,3 @@ | |||
| { | |||
| "java.compile.nullAnalysis.mode": "disabled" | |||
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.
What does this do? Why was it added?
| android:layout_margin="16dp" | ||
| android:layout_marginBottom="40dp" | ||
| android:src="@drawable/ic_add_white" /> | ||
| android:src="@drawable/ic_add_white" |
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.
How did you test the before/after? This doesn't appear to be the correct file.
| <string name="app_not_initialized_new">AnkiDroid is not initialized yet. Please open AnkiDroid and try again</string> | ||
|
|
||
| <!-- Deck Creation --> | ||
| <string name="add_deck">Add deck</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.
Use TR.actionsAddDeck with a sentence case modifier
Purpose / Description
This PR fixes an accessibility issue on the Home screen when the collection is empty.
The Add Deck FloatingActionButton did not have a content description, causing TalkBack and other screen readers to announce it as “Unlabelled”. This makes it difficult for users relying on assistive technologies to understand the purpose of the control.
Fixes
Approach
Adds a localized contentDescription to the Add Deck FAB
Introduces a new string resource (add_deck) for proper accessibility support
No visual or behavioral changes for sighted users
How Has This Been Tested?
Ran the app locally on an emulator
Verified the layout change
Confirmed using Accessibility Scanner that the FAB is now properly labeled
Test Video
ankidroid.issue.20110.mp4
Checklist
Please, go through these checks before submitting the PR.