Example app: icon-only IconButtons on the Icon Button screen have no accessible name

Open Beginner friendly
#5,182 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
1-3 hours
Newbie friendliness
86/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
react-native, typescript

Research direction

Open example/src/Examples/IconButtonExample.tsx and inspect each icon-only IconButton. Add an aria-label that describes its action, then run the example app on web and check /icon-button with axe-core. Done when axe reports no button-name violation on that screen.

Written by the indexing model from the issue text.

Description

Accessibility example app good first task
Current behaviour

On the example app's Icon Button screen (example/src/Examples/IconButtonExample.tsx), no IconButton passes an aria-label, so the icon-only ones render as buttons with no text, and a screen reader announces them only as "button". On the web axe-core reports button-name (critical): "Buttons must have discernible text".

Expected behaviour

Every icon-only IconButton in the example has an aria-label that says what it does, and axe reports no button-name violation on the screen.

How to reproduce?
  1. Run the example app on the web from main (yarn install, then npx expo start --web in example/).
  2. Open the Icon Button example (/icon-button).
  3. Run axe-core on the page.
Preview
What have you tried so far?
Your Environment
software version
react-native-paper main (8cb344b)
browser Chromium 153
Dominant language
TypeScript
Stars
14.5k
Forks
2.3k
Avg merge
2d 12h
Merged PRs (30d)
22

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from callstack/react-native-paper

All issues in callstack/react-native-paper

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.