RE: Making ARIA and native HTML play better together

I like the idea in the sense that if someone has a div as a button, you
could just say to add the role and the problem is solved.

But, I thought the line between native HTML semantics and WAI-ARIA was that
native HTML semantics had the advantage of these automatic features and the
WAI-ARIA was to be used when you wanted to create your own custom behavior.
If WAI-ARIA takes on a lot of built in behavior, a few questions:

·         How far does it go? What about role=”dialog” – does that
automatically add the focus behaviors?

·         How do developers memorize which roles have automatic effects –
right now, it is JUST info for AT and there’s a fairly clear line of
responsibility

·         What happens when, for whatever reason, the developer doesn’t
want the automatic effects? Do they go outside WAI-ARIA, just like they
have in the past gone outside native HTML? What if I’m using
role=”checkbox” because this checkbox has a bunch of states and I want
clicking the label to show a help dialog box, not check the box. What if
I’m using role=”button” because I want these things to be announced as
buttons, but I only want them to be accessed with the arrow keys inside a
particular widget – now I need to add code to un-do the effects, just as is
the case with native controls.

·         What then is the advantage of the native HTML semantic?



*From:* Richard Schwerdtfeger [mailto:schwer@us.ibm.com]
*Sent:* Thursday, May 07, 2015 8:43 AM
*To:* Steve Faulkner
*Cc:* Alice Boxhall; Chaals from Yandex; Léonie Watson; HTMLWG WG
*Subject:* Re: Making ARIA and native HTML play better together



That would be great if the browser manufacturers sign off.


Rich Schwerdtfeger

[image: Inactive hide details for Steve Faulkner ---05/07/2015 12:43:50
AM---On another thread recent thread, leonie and chaals [3] tal]Steve
Faulkner ---05/07/2015 12:43:50 AM---On another thread recent thread,
leonie and chaals [3] talked about adding behaviours to ARIA. Here

From: Steve Faulkner <faulkner.steve@gmail.com>
To: HTMLWG WG <public-html@w3.org>
Cc: Chaals from Yandex <chaals@yandex-team.ru>, Léonie Watson <
lwatson@paciellogroup.com>, Richard Schwerdtfeger/Austin/IBM@IBMUS, Alice
Boxhall <aboxhall@google.com>
Date: 05/07/2015 12:43 AM
Subject: Making ARIA and native HTML play better together
------------------------------




On another thread recent thread, leonie and chaals [3] talked about adding
behaviours to ARIA. Here are a few ideas:

1. When a role is used that matches the default implicit semantics of
labelable HTML elements [1] use of the label element will result in the
same behaviour as the native element and a <label>.
Example:

<span role="checkbox" id="customcheck"></span> <label for="customcheck">i
like this idea</label>

User able to click on label to check/uncheck

2. roles that match the default implicit semantics of interactive elements
are focusable (without need to explicitly set tabindex)

Example:
<div role="button">press me</div>

will be included in the focus order.

3. roles that match the default implicit semantics of interactive elements
[2] inherit the interaction behaviour of the native elements
example:

<div role=button>press me</div>
can be activated the same way a html <button> element can be:.
via space, enter ,click , touch or whatever.

Why? reduce manual labour of web devs. provide more consistent cross
browser behaviours for custom UI. Make custom UI more robust out of the box..

Review at your leisure, respond at will.

[1] http://www.w3.org/TR/html51/semantics.html#category-label
[2] http://www.w3.org/TR/html51/dom.html#interactive-content-2
[3]
https://lists.w3.org/Archives/Public/public-html/2015May/thread.html#msg0
--

Regards

SteveF
HTML 5.1 <http://www.w3.org/html/wg/drafts/html/master/>

Received on Thursday, 7 May 2015 16:36:59 UTC