Supported Accessibility Roles
Accessibility roles from the WAI-ARIA specification that are supported in Safari are described here.
Accessibility Roles
WebKit now has elementary support for the WAI-ARIA specification. Developers can assign a value to the role
attribute of a div
or span
element, indicating the purpose of a custom interface element on a webpage. This enables accessibility utilities to interact with these elements as they would with standard inputs and menus. The following example shows an image that is recognized by accessibility utilities as a button:
<div role="button" tabindex="0" onkeydown="return buttonEvent(event);" onclick="return buttonEvent(event);"> |
<img src="myimage.jpg"> |
</div> |
More information on the WAI-ARIA specification can be found at http://www.w3.org/TR/wai-aria/.
button
A standard button.
checkbox
A standard checkbox.
group
A group of elements that should not be included individually in a page summary or table of contents.
heading
The heading for a section of a page.
img
A collection of elements that compose an image.
link
A hyperlink.
listbox
A dropdown list of options.
listitem
A list item.
menu
A standard menu.
menubar
A container of menus.
menuitem
An option in a menu.
menuitemcheckbox
A checkable menu item.
menuitemradio
A radio button menu item in a group of mutually exclusive choices.
option
An item in a dropdown list.
progressbar
A visual indicator of the progress of a task.
radio
A radio button in a group of mutually exclusive choices.
textbox
A text input field.
Copyright © 2014 Apple Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2014-07-15