Closed jonathanlinat closed 7 years ago
This test proves that wrapping input
element with label
element is safe. I write this practice based on this test.
Your quoted paragraph was written on 2012. It’s too old. If you find at least one assistive technology that does not support this markup, tell me here and re-open this issue. I’ll fix this practive. Thanks!
Hey Kim :)
Your quoted paragraph was written on 2012.
YOUR quoted test is old (2012) and use old versions of assistive technologies. My quoted doc has been last updated on May 17, 2017.
Here proper docs about label and input and their association:
And the most updated test you can find nowadays.
Yes, test is old. However, there is no regression here (for now).
WCAG Note, WebAIM document, and the test you refer proves that label
element with for
attribute is OK, but does not proves that wrapping input
element with label
element is not OK.
Is there a platform that does not support this markup?
As titled, omitting
for
attribute ininput
element ISN'T a good practice.As mentioned by MDN, you should use this attribute because some assistive technologies do not understand implicit relationships between labels and widgets.