diff --git a/_rules/aria-state-or-property-permitted-5c01ea.md b/_rules/aria-state-or-property-permitted-5c01ea.md index 06223184130..703c1aed390 100755 --- a/_rules/aria-state-or-property-permitted-5c01ea.md +++ b/_rules/aria-state-or-property-permitted-5c01ea.md @@ -32,9 +32,11 @@ This rule applies to any [WAI-ARIA state or property][] that is specified on an ## Expectation -Each test target is either an [inherited][], [supported][], or [required][] [state][] or [property][] of the [semantic role][] of the element on which the attribute is specified. If the element has no [semantic role][], the attribute must be a [global state or property][global]. +For each test target, one of the following is true: -**Note:** Assessing the value of the attribute is out of scope for this rule. +- **global**: the test target is a [global state or property][global]; or +- **semantic Role**: the test target is an [inherited][], [supported][], or [required][] [state][] or [property][] of the [semantic role][] of the element on which the test target is specified; or +- **language feature**: the test target is specified on an HTML element and is allowed on that element. Which ARIA states or properties may be used on which element is described in [ARIA in HTML](https://w3c.github.io/html-aria/). ## Assumptions @@ -46,12 +48,17 @@ Implementation of [Presentational Roles Conflict Resolution][] varies from one b ## Background +In HTML, there are language features that do not have corresponding implicit WAI-ARIA semantics. As per [ARIA in HTML Editor's Draft](https://www.w3.org/TR/html-aria/), those elements can have [global states or properties][global]. Some of those elements can also have [inherited][], [supported][], or [required][] [states][state] or [properties][property] that correspond to a [WAI-ARIA role](https://www.w3.org/TR/wai-aria-1.1/#usage_intro). For example, the `audio` element has no corresponding ARIA semantics but it can have [inherited][], [supported][], or [required][] [states][state] or [properties][property] of the [`application` role](https://www.w3.org/TR/wai-aria-1.1/#application). + +Assessing the value of the attribute is out of scope for this rule. + - [ARIA state or property has valid value](https://act-rules.github.io/rules/6a7281) - [Understanding Success Criterion 4.1.1: Parsing](https://www.w3.org/WAI/WCAG21/Understanding/parsing.html) - [Understanding Success Criterion 4.1.2: Name, Role, Value](https://www.w3.org/WAI/WCAG21/Understanding/name-role-value.html) - [WAI-ARIA 1.1, Supported States and Properties](https://www.w3.org/TR/wai-aria-1.1/#states_and_properties) - [WAI-ARIA 1.1, Global States and Properties](https://www.w3.org/TR/wai-aria-1.1/#global_states) - [ARIA5: Using WAI-ARIA state and property attributes to expose the state of a user interface component](https://www.w3.org/WAI/WCAG21/Techniques/aria/ARIA5) +- [Document conformance requirements for use of ARIA attributes in HTML](https://www.w3.org/TR/html-aria/#docconformance) ## Test Cases @@ -139,6 +146,14 @@ This `button` element has an [explicit role][] of `none`. However, it is [focusa ``` +#### Passed Example 11 + +This `input` element does not have an [explicit role][] of `textbox`, but the `aria-required` property may be used on an `input` element with a `type` [attribute value][] of `password`. + +```html + +``` + ### Failed #### Failed Example 1 @@ -149,6 +164,14 @@ The `aria-sort` [property][] is neither [inherited][], [supported][], nor [requi ``` +#### Failed Example 2 + +The `aria-orientation` property may not be used on `audio` element, nor it can be used on `application` (the [semantic role][] for which [inherited][], [supported][], or [required][] [states][state] or [properties][property] are also applicable to `audio` element). + +```html + +``` + ### Inapplicable #### Inapplicable Example 1 @@ -167,6 +190,7 @@ This `div` element is not [included in the accessibility tree][], hence its [WAI
``` +[attribute value]: #attribute-value 'Definition of attribute value' [explicit role]: #explicit-role 'Definition of Explicit Role' [focusable]: #focusable 'Definition of focusable' [global]: https://www.w3.org/TR/wai-aria-1.1/#global_states 'Definition of Global ARIA States and Properties'