oppia / oppia-android

A free, online & offline learning platform to make quality education accessible for all.
https://www.oppia.org
Apache License 2.0
320 stars 521 forks source link

No meaningful label of the revision screen navigation cards during talkback #4737

Closed JishnuGoyal closed 1 year ago

JishnuGoyal commented 2 years ago

Describe the bug

Talkback should have better description for the navigation cards. The talkback is expected to read out an appropriate description for the navigation cards on the revision screen (such as "navigation button"). Currently, the talkback only reads the title text of this nav cards. Add an appropriate description for the navigation cards.

To Reproduce Steps to reproduce the behavior:

  1. Go to the revision screen with talkback turned on.
  2. Swipe to scroll to the navigation cards.

Current Output

https://github.com/oppia/oppia-android/assets/9396084/ebd0e1bd-70f2-41ab-830c-13eaf51a989e

Expected Output In above video, talkback outputs Fractions of a Group and Adding Fractions but thats incorrect because in interpretation it should be following: The previous subtopic is Fractions of a Group and The next subtopic is Adding Fractions. So basically this makes it clear that user can visit the previous subtopic or next subtopic. Note: The exact sentence can be a bit different.

Environment

BenHenning commented 2 years ago

A11y nice-to-have, doesn't need to be release blocking.

adhiamboperes commented 1 year ago

Hi @JishnuGoyal, I do not actually understand what you mean by navigation cards. Please clarify? Can you provide an example of "this should be read as x but it is being read as y" and maybe a screengrab of the same.

JishnuGoyal commented 1 year ago

Hey @adhiamboperes, this is what a navigation card looks like (the bottom UI element that is used to view the next revision card):

image

During talkback, the screen reader should tell the user that clicking on the revision card will take them to the next/previous screen. Please let me know if you have further questions.

rt4914 commented 1 year ago

@adhiamboperes I have updated the issue description to add more details.

adhiamboperes commented 1 year ago

Thanks @rt4914. This is now clear.

chrislee115 commented 1 year ago

May I be assigned this issue?

I think a solution would involve overriding onInitializeAccessibilityNodeInfo - https://stackoverflow.com/a/41496367 and retrieving a custom field (named talkback_text or something of the like) or reuse the field content_description from the view to set the talkback message when clicked upon.

I'm still currently reading through the codebase and am not particularly sure where to override (I think app/view/ViewComponent?) - are there specific areas I should be looking at?

adhiamboperes commented 1 year ago

Hi @chrislee115, sorry I missed this.

Typically, we use the content description field to set talkback text, and that should be the most straightforward way to go.

We use the databinding for passing dynamic text to views in the app, and you can look at how a fragment like the AdministratorControlsFragmentPresenter.kt binds it's data, if you're looking to understand how that works.

Please let me know if you have any questions.

ayush290104 commented 1 year ago

@Akshatkamboj14 what we have to do in this issue as of now should we change the talk back or not

Akshatkamboj14 commented 1 year ago

Yes, we have to change the text that talkback speaks.

ayush290104 commented 1 year ago

@Akshatkamboj14, Are you working on this issue ?

Akshatkamboj14 commented 1 year ago

Yes, you can take another issue that is not assigned to anyone https://github.com/oppia/oppia-android/issues?q=is%3Aissue+is%3Aopen+no%3Aassignee and if you are new then you can check this wiki https://github.com/oppia/oppia-android/wiki/Contributing-to-Oppia-Android