-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
Hi!
First of all, thank you! formBuilder works great! :)
We've received an issue from one of our users that we think is important enough for you to know about.
Resumed here:
Current formBuilder render output
<div class="formbuilder-radio-group form-group field-radio-group-1631271361249">
<label for="radio-group-1631271361249">
Rate the quality of content
</label>
<div class="radio-group">
<div class="formbuilder-radio-inline">
<input name="radio-group-1631271361249" id="radio-group-1631271361249-0" value="1" type="radio">
<label for="radio-group-1631271361249-0">1</label>
</div>
<div class="formbuilder-radio-inline">
<input name="radio-group-1631271361249" id="radio-group-1631271361249-1" value="2" type="radio">
<label for="radio-group-1631271361249-1">2</label>
</div>
...
</div>
</div>
Our user observes that: The use of the for the overarching legend is incorrect, and does NOT result in screen readers announcing/associating that with the group. As a result, navigating with a screen reader, if you TAB to a radio button there you just hear its label (e.g. "1") without any further context.
This would be solve by explicitly define the roles/relationships using ARIA
<div role="group" aria-labelledby="radio-group-1631271361249-legend" class="...">
<label id="radio-group-1631271361249-legend">
Rate the quality of content
</label>
...
</div>
I looked through the docs and READMEs in the code and I can't see a way for me to add aria-labelledby to the outer div
If you find time, could you look into this please?
Thanks again!