W3C home > Mailing lists > Public > wai-xtech@w3.org > May 2012

Re: Clarify what an "empty" aria-labelledby attribute/property is, especially for the purposes of accessible name computation

From: James Craig <jcraig@apple.com>
Date: Wed, 30 May 2012 22:30:56 -0700
Cc: W3C WAI-XTECH <wai-xtech@w3.org>, James Nurthen <james.nurthen@oracle.com>
Message-id: <1F65E5F2-113C-474D-A980-C49C3D1D5BE5@apple.com>
To: Benjamin Hawkes-Lewis <bhawkeslewis@googlemail.com>
Removing the public comments alias.

Benjamin Hawkes-Lewis wrote:

> This is a message in a bottle about:
> Accessible Rich Internet Applications (WAI-ARIA) 1.0
> Editors' Draft 7 May 2012

Thanks for this comment, Ben.

> Not sure why the algorithm is discussing _attributes_ (properly the
> remit of host languages) rather than _properties_ (properly the remit
> of ARIA) here but anyways…

Just as an FYI, it was because both states and properties are defined as attributes in ARIA and, most readers won't have to care what the difference between a state or property is. Since they are both always defined in the DOM as content attributes, we refer to them in the spec as attributes, except where its necessary to make a distinction between a state vs a property.

> WAI-ARIA should either define what happens in these cases or require
> host languages to ensure that the property mapped from their markup is
> conforming in this respect, even the markup is not conforming.
> For example, what should happen if @aria-labelledby is a list of three
> ID references, and the second reference is to an element that is not
> in the same document?

The IDREF format is an unprefixed identifier in the same document, not a hash-prefixed fragment link to any document. 

In other words, this is valid:
	aria-labelledby="id1 id2"

But neither of these are:
	aria-labelledby="#id1 #id2"

Is there another way to use an IDREF to point outside the document?

I think we're covered here in that "foo.html#id2" is not a valid IDREF in the current document, so that does not contribute to the text alternative.

> The progressive rendering of documents must be accounted for here,
> since elements might be parsed or inserted by script later in the
> markup of the same document. HTTP server push implies progressive
> rendering could take some time - what should user agents do when asked
> to yield an @aria-labelledby property?
> WAI-ARIA should clarify the text computation algorithm to make it
> clear whether it is talking about the @aria-labelledby property being
> set to an empty list or about the text alternative calculated via its
> list. For example, with the markup:
> <label for="i">Name</label><input id="i" aria-labelledby="e"><div id="e"></div>
> Is the accessible name of the input "Name" or the the empty string?

The empty string. aria-labelledby trumps the native host language label mechanism, which in this case is [label@for/input@id]

As James Nurthen mentioned in the thread: http://lists.w3.org/Archives/Public/w3c-wai-ig/2012AprJun/0146.html
>> It reads "if aria-labelledby or aria-label is empty or undefined". It does not mention anything about aria-labelledby pointing to a valid element which contains no content.

I agree that we could clarify that prose a bit though. Perhaps "If *the attribute value of* aria-labelledby or aria-label is empty or undefined…" 

Received on Thursday, 31 May 2012 05:31:31 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:51:46 UTC