Bug 151429 - AX: aria-owns attribute does not work as expected
Summary: AX: aria-owns attribute does not work as expected
Status: RESOLVED DUPLICATE of bug 151498
Alias: None
Product: WebKit
Classification: Unclassified
Component: Accessibility (show other bugs)
Version: Safari 9
Hardware: Mac OS X 10.11
: P2 Normal
Assignee: Jonathan Dallas
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2015-11-18 19:48 PST by Jonathan Dallas
Modified: 2015-11-20 09:41 PST (History)
2 users (show)

See Also:


Attachments
This is the simple test case shown above. (559 bytes, text/html)
2015-11-18 19:49 PST, Jonathan Dallas
no flags Details
Single state input group (2.28 KB, text/html)
2015-11-18 19:53 PST, Jonathan Dallas
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Dallas 2015-11-18 19:48:34 PST
Hello, my expectation for aria-owns is that a developer can use it to group controls that are not otherwise grouped in DOM. My understanding is it’s a way to achieve and extend similar functionality as native radio controls using the name attribute. The developer can put radio buttons anywhere on the page but if the name property matches they are grouped together and announced as such in assistive technology.

Spec for of aria-owns (which is brief and a little vague): http://www.w3.org/TR/wai-aria-1.1/#aria-owns


Here is a test case:
    <div role="group" id="group">
        <h1>Single state inputs with descriptions</h1>
        <div role="textbox" aria-selected="false" aria-owns="group">Alpha</div>
        <div>Description</div>
        <div role="textbox" aria-selected="true" aria-owns="group">Beta</div>
        <div>Description</div>
        <div role="textbox" aria-selected="false" aria-owns="group">Gamma</div>
        <div>Description</div>
    </div>

I would expect the elements with role="textbook" to announce that they are part of a group of three textbooks and state whether or not this textbook is the selected one. Currently VoiceOver does not do this, likely because this information is not added to the accessibility tree.

Attaching code for the example above.
Comment 1 Radar WebKit Bug Importer 2015-11-18 19:49:01 PST
<rdar://problem/23606298>
Comment 2 Jonathan Dallas 2015-11-18 19:49:36 PST
Created attachment 265839 [details]
This is the simple test case shown above.

Adding the code for the test case in my message above.
Comment 3 Jonathan Dallas 2015-11-18 19:53:39 PST
Created attachment 265840 [details]
Single state input group

Attaching and a more complex example usecase for aria-owns.

Each item should be announced similarly to a radio group (e.g. number of items in the group, and whether or not the current item is selected).
Comment 4 James Craig 2015-11-19 14:53:01 PST
The aria-owns relationship is backwards in your example. I expect you meant to do this:

<div role="radiogroup" aria-owns="r1 r2 r3">
   <div role="radio" id="r1">Alpha</div>
   <div role="radio" id="r1">Beta</div>
</div>
<!-- this one, too. -->
<div role="radio" id="r3">Gamma</div>


I would recommend re-filing with the corrected test case, and duping this one out to the new bug.
Comment 5 James Craig 2015-11-19 14:53:50 PST
(In reply to comment #4)
>    <div role="radio" id="r1">Beta</div>

Typo: r1 should be r2, here.
<div role="radio" id="r2">Beta</div>
Comment 6 Jonathan Dallas 2015-11-20 09:41:56 PST
Multiple issues with this bug. Refiled as https://bugs.webkit.org/show_bug.cgi?id=151498

Thanks!

*** This bug has been marked as a duplicate of bug 151498 ***