A proper form already has the form role thanks to its own native semantics. Do not change native semantics, unless you really have to.
Description
Details
Subject | Repo | Branch | Lines +/- | |
---|---|---|---|---|
Move `role="search"` from <form> to <div> element | mediawiki/skins/Blueprint | master | +6 -4 |
Event Timeline
Change 242440 had a related patch set uploaded (by Pastakhov):
remove role 'searsh' from form element
Asking, because to my knowledge (supported explicitly here at WCAG within W3C, here and abstracted here) role="search" "is a specialized version of 'form' so you do not need to label this section with the role of 'form.'"
It helps users of assistive technology to navigate the page more easily.
@Volker_E: I'm new to this aspect, and for me it is very confusing.
I checked it through the validator and found the error:
Element form does not need a role attribute.
I read Notes on Using ARIA in HTML and there is 2.2 Second rule of ARIA use that says:
Do not change native semantics, unless you really have to.
and item 2.6 What does adding a role do to the native semantics? explains why.
I found detailed description of the problem and surprised by such differences in the documentation.
Thanks for bringing this up, it seems like specification insanity, ahem ambiguity. Following from the links: https://github.com/w3c/aria/issues/85 -- I'll look further into it tomorrow.
I will merge your patch for now, @Pastakhov, as long as the conversation over at w3c/wcag is still ongoing. We might revisit this if W3C is deciding not to rely on an extra <div> for role="search".