Add description attributes to all app texts for sight impaired a11y support#649
Add description attributes to all app texts for sight impaired a11y support#649prince-0408 wants to merge 7 commits into
Conversation
Thank you for the pull request! 💙🩵The Scribe-Android team will do our best to address your contribution as soon as we can. The following are some important points:
Note Scribe uses Conventional Comments in reviews to make sure that communication is as clear as possible. |
Maintainer ChecklistThe following is a checklist for maintainers to make sure this process goes as well as possible. Feel free to address the points below yourself in further commits if you realize that actions are needed :)
|
|
@prince-0408, would you be able to fix the CI errors that are occurring on this PR? |
DeleMike
left a comment
There was a problem hiding this comment.
Hi @prince-0408 , thanks for the PR! 🌟
All looks good to me! And I think it is ready bar the merge conflict.
Could you please look into the merge conflicts? Thanks.
DeleMike
left a comment
There was a problem hiding this comment.
I think all is good from my end!
Thanks for resolving the merge conflicts. Thanks for the great work @prince-0408 🚀
|
Looking into this a bit more and responding the the question for me above:
For the tutorial screen, let's not worry about it as @ashb155 should have those covered in scribe-org/Scribe-i18n#117 that's being brought over to #618. Any other strings would ideally be localized and not hard coded. We should also move them over to Scribe-i18n and then bring them in over here. Ideally @prince-0408, do you want to open a PR up in Scribe-i18n with the strings that we need for sight impaired users and any other strings that are needed based on what's on the current |
Hi @andrewtavis! Thanks for the thorough review and the deep dive. That makes total sense. I completely agree with keeping strings.xml clean and reusing the descriptive labels for alt texts to avoid duplicating work in Weblate. I'd be happy to open a PR in the Scribe-i18n repository to add these accessibility strings and move the hardcoded ones over. I'll get that opened up and link it here once it's ready, and then we can pull the submodule updates into this PR afterwards! |
|
Thanks so much for your efforts, @prince-0408! |
Hi @andrewtavis! Everything is now ready for your review:
Let me know if this looks good to merge! |
Description
Resolves #641
This PR introduces foundational accessibility support for sight-impaired users by adding
contentDescriptionattributes to the prioritized elements across the app.Following the initial guidance in the issue, this PR prioritizes the menu options, tab bar, and the texts in the about tab submenus.
Changes Made
ScribeItembase class and its sub-classes (ClickableItem,SwitchableItem,ExternalLinkItem,CustomItem) to accept an optionalaltText: Int?string resource.ClickableItemComp,SwitchableItemComp, andAboutPageItemCompto applyModifier.semantics(mergeDescendants = true) { contentDescription = altText }when analtTextstring is provided, ensuring screen readers treat the entire row as a single actionable item.BottomBarScreenandScribeBottomBarto resolve and use string resources for their tab labels and alt texts (labelResandaltTextRes)._alt_textlabels instring.xmlfor all tabs and all menu items within the Settings and About screens._alt_textstring resources to all instantiatedScribeItemconfigurations insideSettingsScreen.kt,LanguageSettingsScreen.kt, andAboutUtil.kt.Question for @andrewtavis
While doing a deep dive to verify the accessibility tags across the app, I noticed there are still quite a few hardcoded English strings being used for
contentDescriptionon icons across other screens (e.g.,"Back","Right Arrow","Search","Clear"inInstallationScreen,ConjugateScreen, andTutorialscreens).I wanted to ask: Would you like me to tackle replacing these remaining hardcoded
contentDescriptiontags in this PR, or should we leave them for a follow-up issue?