Skip to content
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

Mobile: Accessibility: Improve note list accessibility #11419

Conversation

personalizedrefrigerator
Copy link
Collaborator

@personalizedrefrigerator personalizedrefrigerator commented Nov 19, 2024

Summary

This pull request improves the accessibility of the mobile app's note list by:

  • Hiding the checkbox icon from accessibility tools.
    • It uses react-native-vector-icons, which uses an icon font. Previously, accessibility tools would attempt to read the checkbox icon as a character (unpronounceable with my current TalkBack settings).
  • Marking note buttons as buttons.
  • Adding aria-checked to checkboxes (for web).
    • react-native-web seems to require aria-checked for accessibility tools to read a checked checkbox as checked.
    • React Native Android seems to require accessibilityState={{ checked: true }} for a checked checkbox to be read as checked.
  • Adding accessibilityHint to note list buttons to describe the effect of clicking one of the buttons.

Related to #10795.

Known unresolved issues

  • iOS: Tasks can't be toggled from the note list with VoiceOver (it's necessary to open the note).
    • This is because the <Checkbox> is contained within a <TouchableOpacity>. VoiceOver only makes the parent TouchableOpacity focusable.

Testing plan

Android 13:

  1. Setup: Open/create a notebook with the following notes/tasks:
    • Note: Example
    • Note: Test
    • Task (complete): Test
  2. Enable the screen reader and move accessibility focus to Example.
  3. Verify that TalkBack reads Example, Button, Opens note
  4. Move accessibility focus to the next item (swipe right).
  5. Verify that TalkBack reads Test, Button, Opens note.
  6. Wait 1-2 seconds.
  7. Verify that TalkBack reads Double-tap to activate.
  8. Move accessibility focus to the next item (swipe right).
  9. Verify that TalkBack reads Test, Button, Opens note.
    • Optional: Perhaps this should read "Opens to-do" for tasks?
  10. Move accessibility focus to the next item.
  11. Verify that TalkBack reads checked, to-do: Test, checkbox.
  12. Wait 1-2 seconds.
  13. Verify that TalkBack reads Double-tap to toggle.
  14. Double-tap.
  15. Verify that TalkBack reads Not checked.

@personalizedrefrigerator personalizedrefrigerator added mobile All mobile platforms accessibility Related to accessibility labels Nov 19, 2024
@laurent22 laurent22 merged commit 5d7d248 into laurent22:dev Nov 20, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accessibility Related to accessibility mobile All mobile platforms
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants