From 9e290e54b7323c0c1fe6e3cd0cdebed049d5b01b Mon Sep 17 00:00:00 2001
From: James Nurthen When the ARIA attribute definition includes a table enumerating the attribute's allowed values, that attribute is an enumerated attribute. Each value in the table is a keyword for the attribute, mapping to a state of the same name. When the values table notates one of the values as "(default)", that default value is the missing value default and invalid value default for the attribute. As noted in Mapping WAI-ARIA Value Types to Languages, attributes are included in host languages, and the syntax for representation of enumerated value types is governed by the host language. All enumerated attribute getters and setters use string values, including the boolean-like enumerated true/false type.Value
Enumerated Attribute Values
- Example Enumerated Attribute Usage
-
Unlike IDL reflection, operating system accessibility API mappings of ARIA enumerated attributes do have defaults. + The default values from the ARIA values tables are exposed to the operating system accessibility API as described in + [[[#supportedState]]], and in [[[CORE-AAM]]].
+As noted in [[[#typemapping]]], attributes are included in host languages, and the syntax for representation of enumerated value types is governed by the host language.
+When the host language is HTML, ARIA enumerated attributes MUST follow the HTML rules for reflecting [=nullable type|nullable=] {{DOMString}} IDL attributes current as of September 3, 2021.
+Below is a copy of the HTML specification text for [=nullable type|nullable=] {{DOMString}} IDL attributes as of September 3, 2021. + The HTML spec is a living document, and this section may have changed since. Refer to the link above for the most current version.
+ ++ a reflecting IDL attribute is a nullable {{DOMString}} + attribute whose content attribute is an enumerated attribute, then, on getting, if + the corresponding content attribute is in its missing value default state then the IDL + attribute must return null, otherwise, the IDL attribute must return the keyword value associated + with the state the attribute is in. If there are multiple keyword values for the state, then + return the conforming one. If there are multiple conforming keyword values, then one will be + designated the canonical keyword; choose that one. On setting, if the new value is + null, the content attribute must be removed, and otherwise, the content attribute must be set to + the specified new value. ++
interface mixin ARIAMixin {
attribute DOMString? role;
-
-
- attribute DOMString ariaAtomic;
- attribute DOMString ariaAutoComplete;
- attribute DOMString ariaBusy;
- attribute DOMString ariaChecked;
- attribute DOMString ariaColCount;
- attribute DOMString ariaColIndex;
- attribute DOMString ariaColIndexText;
- attribute DOMString ariaColSpan;
-
- attribute DOMString ariaCurrent;
-
- attribute DOMString ariaDescription;
-
- attribute DOMString ariaDisabled;
-
- attribute DOMString ariaExpanded;
-
- attribute DOMString ariaHasPopup;
- attribute DOMString ariaHidden;
- attribute DOMString ariaInvalid;
- attribute DOMString ariaKeyShortcuts;
- attribute DOMString ariaLabel;
-
- attribute DOMString ariaLevel;
- attribute DOMString ariaLive;
- attribute DOMString ariaModal;
- attribute DOMString ariaMultiLine;
- attribute DOMString ariaMultiSelectable;
- attribute DOMString ariaOrientation;
-
- attribute DOMString ariaPlaceholder;
- attribute DOMString ariaPosInSet;
- attribute DOMString ariaPressed;
- attribute DOMString ariaReadOnly;
-
- attribute DOMString ariaRequired;
- attribute DOMString ariaRoleDescription;
- attribute DOMString ariaRowCount;
- attribute DOMString ariaRowIndex;
- attribute DOMString ariaRowIndexText;
- attribute DOMString ariaRowSpan;
- attribute DOMString ariaSelected;
- attribute DOMString ariaSetSize;
- attribute DOMString ariaSort;
- attribute DOMString ariaValueMax;
- attribute DOMString ariaValueMin;
- attribute DOMString ariaValueNow;
- attribute DOMString ariaValueText;
+
+ attribute DOMString? ariaAtomic;
+ attribute DOMString? ariaAutoComplete;
+ attribute DOMString? ariaBusy;
+ attribute DOMString? ariaChecked;
+ attribute DOMString? ariaColCount;
+ attribute DOMString? ariaColIndex;
+ attribute DOMString? ariaColIndexText;
+ attribute DOMString? ariaColSpan;
+
+ attribute DOMString? ariaCurrent;
+
+ attribute DOMString? ariaDescription;
+
+ attribute DOMString? ariaDisabled;
+
+ attribute DOMString? ariaExpanded;
+
+ attribute DOMString? ariaHasPopup;
+ attribute DOMString? ariaHidden;
+ attribute DOMString? ariaInvalid;
+ attribute DOMString? ariaKeyShortcuts;
+ attribute DOMString? ariaLabel;
+
+ attribute DOMString? ariaLevel;
+ attribute DOMString? ariaLive;
+ attribute DOMString? ariaModal;
+ attribute DOMString? ariaMultiLine;
+ attribute DOMString? ariaMultiSelectable;
+ attribute DOMString? ariaOrientation;
+
+ attribute DOMString? ariaPlaceholder;
+ attribute DOMString? ariaPosInSet;
+ attribute DOMString? ariaPressed;
+ attribute DOMString? ariaReadOnly;
+
+ attribute DOMString? ariaRequired;
+ attribute DOMString? ariaRoleDescription;
+ attribute DOMString? ariaRowCount;
+ attribute DOMString? ariaRowIndex;
+ attribute DOMString? ariaRowIndexText;
+ attribute DOMString? ariaRowSpan;
+ attribute DOMString? ariaSelected;
+ attribute DOMString? ariaSetSize;
+ attribute DOMString? ariaSort;
+ attribute DOMString? ariaValueMax;
+ attribute DOMString? ariaValueMin;
+ attribute DOMString? ariaValueNow;
+ attribute DOMString? ariaValueText;
};
From d61f6fee8a3dd82ff111852d8b06b3ab6e93cea0 Mon Sep 17 00:00:00 2001
From: James Nurthen