False negative a11y check for custom checkbox element from a link
Categories
(DevTools :: Accessibility Tools, defect, P3)
Tracking
(firefox71 affected, firefox72 affected, firefox73 affected)
People
(Reporter: egil, Unassigned)
Details
Attachments
(2 files)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:71.0) Gecko/20100101 Firefox/71.0
Steps to reproduce:
- I have this HTML:
<a aria-checked="true" role="checkbox" href="#">Choice 1</a>
<a aria-checked="true" role="checkbox" href="#">Choice 2</a>
- I run accessibility check in devtools.
Actual results:
I get "Form elements should have a visible text label".
Expected results:
I think there is no problem here. The text is always visible.
Note that onclick aria-checked
is toggle in an even listener so that seems fine to me.
Reporter | ||
Updated•5 years ago
|
Comment 1•5 years ago
|
||
Hi Maciej,
Could you attach me a test case like it was done in this bug, please? https://bugzilla.mozilla.org/show_bug.cgi?id=1576010
Thanks in advance, Flor.
Reporter | ||
Comment 2•5 years ago
|
||
Sure. Attaching a test html which should show what I mean.
I made it functional in a very basic way (it's a bit raw 😉).
Comment 3•5 years ago
|
||
Hi Maciej,
I got the same message. Thanks so much for the example! I was able to reproduce the bug on Windows 10 on the following versions:
Release 71.0 (64-bit), Beta 72.0b8 (64-bit) and Nightly 73.0a1 (2020-01-02) (64-bit).
I've chosen a component.
Best regards, Flor.
Updated•5 years ago
|
Comment 4•5 years ago
|
||
The priority flag is not set for this bug.
:Jamie, could you have a look please?
For more information, please visit auto_nag documentation.
Updated•5 years ago
|
Updated•5 years ago
|
Comment 5•5 years ago
|
||
I'm happy to mentor this bug, Florencia!
This is the rule where this check flags this particular markup: https://searchfox.org/mozilla-central/source/devtools/server/actors/accessibility/audit/text-label.js#177-189
I think we can have an additional "strict" condition for when the form role is an aria role (not native element), it's name comes from an inner text and the inner text is visible.
Let me know if you need any additional pointers.
Comment 6•2 years ago
|
||
The bug assignee didn't login in Bugzilla in the last 7 months.
:Jamie, could you have a look please?
For more information, please visit auto_nag documentation.
Updated•2 years ago
|
Updated•2 years ago
|
Description
•