Accordions violate accessibility requirements of WCAG 2.1
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 11.3k
- Forks
- 5.2k
- PR merge metrics
- No merged PRs in 30d
Description
When I run a scan with axe-core DevTools on a page containing an accordion made with your widget, I get a critical error indicating that for the element with a 'tablist' role "Element has children which are not allowed: [role=tabpanel]". The ARIA Authoring Practices Guide (APG) examples at https://www.w3.org/WAI/ARIA/apg/patterns/accordion/examples/accordion/ seems to show accordions shouldn't use tab roles at all.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the accordion widget and compare its ARIA roles with the W3C ARIA Authoring Practices Guide accordion example. Reproduce the issue by scanning a page containing an accordion with axe-core DevTools, then verify that the scan no longer reports the tablist/tabpanel violation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, jquery
- Domain
- accessibility, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100