diff --git a/third_party/aria-practices/src/content/patterns/button/examples/button_idl.html b/third_party/aria-practices/src/content/patterns/button/examples/button_idl.html index 8b7ab3047e381..9f813a2b7e371 100644 --- a/third_party/aria-practices/src/content/patterns/button/examples/button_idl.html +++ b/third_party/aria-practices/src/content/patterns/button/examples/button_idl.html @@ -2,51 +2,13 @@ - Button Examples (IDL Version) - - - - - - - - - - -
-

Button Examples (IDL Version)

- -
-

About This example

- -

The following examples of the Button Pattern demonstrate a new JavaScript syntax for coding ARIA attributes.

-

- The JavaScript for the example buttons on this page uses the IDL Interface defined in ARIA 1.2. - The purpose of these examples is to illustrate how to use ARIA Attribute Reflection and provide a test case for browser and assistive technology interoperability. - Specifically, the role and ariaPressed attributes are accessed using dot notation instead of setAttribute() and getAttribute(). - In all other respects, these examples are identical to the Button Examples. -

-
- -
-
-

Example

-
- - -

Important

@@ -85,131 +47,5 @@
- - -
- -
-

Keyboard Support

- - - - - - - - - - - - - - - - - - -
KeyFunction
EnterActivates the button.
SpaceActivates the button.
-
- -
-

Role, Property, State, and Tabindex Attributes

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
RoleAttributeElementUsage
buttondiv, a -
    -
  • Set in javascript with element.role = 'button';.
  • -
  • Identifies the element as a button widget.
  • -
  • Accessible name for the button is defined by the text content of the element.
  • -
-
- tabindex="0" - div, a -
    -
  • Includes the element in the tab sequence.
  • -
  • Needed on the a element because it does not have a href attribute.
  • -
-
aria-pressed="false"a -
    -
  • Set in javascript with button.ariaPressed = 'false';.
  • -
  • Identifies the button as a toggle button.
  • -
  • Indicates the toggle button is not pressed.
  • -
-
aria-pressed="true"a -
    -
  • Set in javascript with button.ariaPressed = 'true';.
  • -
  • Identifies the button as a toggle button.
  • -
  • Indicates the toggle button is pressed.
  • -
-
aria-hidden="true"svgExcludes SVG from accessible name calculation for the button.
-
- -
-

JavaScript and CSS Source Code

- - -
- -
-

HTML Source Code

-

To copy the following HTML code, please open it in CodePen.

- -
- - -
-