Re: ARIA 1.1: primary button attribute proposal

Hi James,

On 2015-12-04 9:45 PM, James Craig wrote:
>> n Dec 4, 2015, at 12:31 PM, Joseph Scheuhammer<clown@alum.mit.edu>  wrote:
>> >
>> >On 2015-12-04 8:07 AM, Alexander Surkov wrote:
>>> >>I agree that ARIA would benefit of having a way to provide the semantics of a default button. I would replace though a long aria-primaryaction name on short aria-default. That would look like:
>>> >>
>>> >><div role='button' aria-default>
>>> >>
>>> >>The naming is similar to MSAA's STATE_SYSTEM_DEFAULT state exposed on default buttons.
>> >
>> >Similarly, ATK_STATE_DEFAULT [1] and ATSPI_STATE_IS_DEFAULT [2].
>> >
>> >OS X has an AXDefaultButton property, but, there, it's a property of the AXDialog, not the button itself.  (Note: determined via the Accessibility Inspector).
> The ARIA equivalent would be an IDREF attr on a dialog, pointing to one of the contained buttons.
>
> <div role="dialog" aria-labelledby="label_text" aria-default="cancel_button">
>    <h1 id="label_text">Are you sure you want to delete your irreplaceable photos?</h1>
>    <button>Delete</button>
>    <button id="cancel_button">Cancel</button>
> </div>
>
Brain-storming ahead:

This feels like a special case of aria-controls, where the default 
button controls the acceptance and/or dismissal of the 
dialog/landmark.   A possibility along those lines is to have 
@aria-default as in your example above pointing from the dialog to the 
button, and add @aria-controls on the default button to establish the 
controller-for/controlled-by relationship between the button and the 
enclosing dialog.

The problem with that is it invites author errors.  Both attributes have 
to be in sync.  Another possibility is to leave that job to the 
browser.  Since @aria-default is a pointer from the dialog to the 
button, the relationship is there implicitly, and the browser could add 
in the controller-for/by relationship itself.

It's as if there needs to be a more specific two-way relationship than 
controller-for/by,  such as "default-is/default-for", where the former 
is a reference from the dialog to the button, and the latter from the 
button to the dialog.

-- 
;;;;joseph.

'Array(16).join("wat" - 1) + " Batman!"'
            - G. Bernhardt -

Received on Monday, 7 December 2015 15:32:26 UTC