- From: Benjamin Hawkes-Lewis <bhawkeslewis@googlemail.com>
- Date: Sat, 28 Apr 2012 21:39:55 +0100
- To: Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no>
- Cc: HTML Accessibility Task Force <public-html-a11y@w3.org>, John Foliot <john@foliot.ca>
On Fri, Apr 27, 2012 at 2:01 AM, Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no> wrote: > Benjamin Hawkes-Lewis, Thu, 26 Apr 2012 22:33:40 +0100: [snip] >> But it's also plausible that such authors might use @hidden with the >> intent of hiding elements even from accessible names and descriptions. >> For example, @aria-describedby might reference text that has the >> @hidden attribute until it is relevant to the state of the >> application, for example error text. Consider the following example >> >> <label for=username>Username:</label> >> <input id=username name=username aria-describedby=error> >> <div hidden id=error>Invalid username. Must be six or more >> alphanumeric characters.</div> >> >> If "hidden" means never ever render the content, then the error >> message doesn't get included in accessible description calculation >> until the error occurs and the "hidden" attribute removed. >> >> If "hidden" means do not render the content except for ARIA name and >> description calculation, then the error message is inappropriately >> included regardless of the actual state of the application. > > To make the above not work, one must change ARIA so that > aria-describedBY="section-where-aria-hidden-is-set-to-true" > does not work. Or for HTML to define the "text alternative" of elements with @hidden to be the empty string. Host languages define how text alternatives is computed from their native semantics. > One could of course try to help by flagging it as an error to make > aria-describedby point to @hidden and @aria-hidden="true" sections. Jonas is trying to help users of content written by authors who don't use conformance checkers. > However, ARIA *also* says that one MUST do > <p style="display:none" aria-hidden="true">Hidden text.</p> I've queried the appropriateness of that requirement: http://lists.w3.org/Archives/Public/public-pfwg-comments/2012AprJun/0007.html > the use of @hidden does lead to > some undpredictability too: The element could be made visible, via CSS, > despite the @hidden attribute. What happens then? As the spec stands, user agents should render it. See especially: http://dev.w3.org/html5/spec/rendering.html#hidden-elements (Personally, I think it would be simpler if, like <noscript> with JS enabled, it was never rendered.) > When I read the rest of that letter, the I came to think that it > perhaps should be forbidden to do > aria-describedby=hidden-anchor-element. Based on how aria-describedby is currently specified and implemented, maybe. -- Benjamin Hawkes-Lewis
Received on Saturday, 28 April 2012 20:40:44 UTC