Switch moz-radio markup to use input + label rather than an input wrapped in a label
Categories
(Toolkit :: UI Widgets, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox129 | --- | fixed |
People
(Reporter: hjones, Assigned: hjones)
References
(Blocks 1 open bug)
Details
(Keywords: access, Whiteboard: [recomp])
Attachments
(1 file, 1 obsolete file)
Based on this review comment on the initial patch it sounds like this markup:
<input type="radio" name="greeting" value="Hello" id="hello" />
<label for="hello">Hello</label>
works better with certain screen readers compared with having the label wrap the input. Based on that feedback we should update the markup. There are a couple of questions we should get answered that may impact the scope of the bug and/or represent other bugs we should file:
- Is it important to have the space between the label and the input be clickable? This was the main motivation for using the input wrapped in a label markup. There are other ways of achieving this, though they are less clean/tidy.
- Is this an issue that needs to be addressed with our
moz-toggle
andmoz-checkbox
inputs as well, since they use similar markup?
Updated•4 months ago
|
Assignee | ||
Comment 1•3 months ago
|
||
This change should make it so that screen readers only announce the label once while maintaining the ability for mouse users to hover/click on the whitespace around the label text.
Updated•3 months ago
|
Comment 2•3 months ago
|
||
This revision adjusts the styling of moz-radio to avoid block, flex display
styling that can cause screen readers to perceive the button, label as "on
different lines" even though they are grouped visually. This revision maintains
the ability to click the interstice between the button and the label.
Updated•3 months ago
|
Updated•3 months ago
|
Updated•3 months ago
|
Comment 4•3 months ago
|
||
bugherder |
Description
•