aria-hidden-focus does not account for inputs being inside a disabled <fieldset>
See original GitHub issueProduct: axe Extension
Expectation: An input that is inside a <fieldset>
that has been disabled should not be treated as focusable by the aria-hidden-focus rule
Actual: An input that is inside a <fieldset>
that has been disabled is still treated as focusable by the aria-hidden-focus rule
Motivation: The aria-hidden-focus rule returns a false positive when aria-hidden is used with a disabled fieldset
Example: The aria-hidden-focus rule flags the following as a serious issue, despite the input not actually being focusable.
<fieldset disabled="disabled" aria-hidden="true">
<input />
</fieldset>
axe-core version: 4.2.0
axe extension version: 4.9.3
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
aria-hidden elements do not contain focusable elements
A focusable element with aria-hidden="true" is ignored as part of the reading order, but still part of the focus order, making it's state...
Read more >aria-hidden - Accessibility - MDN Web Docs - Mozilla
The aria-hidden state indicates whether the element is exposed to an accessibility API.
Read more >False positive in aria-hidden focusable rule #3430 - GitHub
False positive aria-hidden focusable failure is being reported on focus "bumpers", which are meant to send focus back into the modal/focus ...
Read more >aria-hidden-focus - Accessibility Insights
In some browsers, the attribute aria-hidden="true" hides an element and all its children from assistive technologies. Users can still use the keyboard to ......
Read more >Form field has non-empty accessible name | ACT Rule | WAI
This rule checks that each form field element has a non-empty accessible name. ... <div>last name</div> <input aria-label="last name" disabled /> ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Nope. Closing was intended. The issue has been resolved and should be available in the latest release.
Thank you for reporting the issue. We’ll be sure to fix it. I think the problem is in dom.focusDisabled, which do https://github.com/dequelabs/axe-core/blob/develop/lib/commons/dom/focus-disabled.js#L10
To fix this we’ll need to have i check walk up the tree to see if there’s a disabled fieldset. Should be fairly straightforward. The one thing to be mindful of in fixing this is to check how this interacts with shadow DOM. I recall that
disable
only works on descendants in the same DOM tree. We should test it to make sure.