-
Notifications
You must be signed in to change notification settings - Fork 140
Clarify Accessibility Parent-Child Relationships for menu, group, and menuitem #2483
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 2 commits
269e806
e980d4b
6ff9aad
6678aef
c5ee99a
0237660
6e9a04b
79f6da9
db5ed08
d14eff8
cecd778
2b66bd0
e155a27
35bfe75
7048eb6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -792,9 +792,9 @@ <h2>Non-interference with the Host Language</h2> | |
| language. | ||
| </p> | ||
| <p> | ||
| If a CSS selector includes a WAI-ARIA attribute (e.g., <code class="highlight css">input[aria-invalid="true"]</code>), user agents MUST update the visual display of any elements | ||
| matching (or no longer matching) the selector any time the attribute is added/changed/removed in the <abbr title="Document Object Model">DOM</abbr>. The user agent MAY alter the mapping of | ||
| the host language features into an <a>accessibility <abbr title="Application Programming Interface">API</abbr></a | ||
| If a CSS selector includes a WAI-ARIA attribute (e.g., <code class="highlight css">input[aria-invalid="true"]</code>), user agents MUST update the visual display of any elements matching (or | ||
| no longer matching) the selector any time the attribute is added/changed/removed in the <abbr title="Document Object Model">DOM</abbr>. The user agent MAY alter the mapping of the host | ||
| language features into an <a>accessibility <abbr title="Application Programming Interface">API</abbr></a | ||
| >, but the user agent MUST NOT alter the <abbr title="Document Object Model">DOM</abbr> in order to remap <abbr title="Accessible Rich Internet Applications">WAI-ARIA</abbr> markup into host | ||
| language features. | ||
| </p> | ||
|
|
@@ -6200,6 +6200,11 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| </p> | ||
| <p>To be <a>keyboard accessible</a>, authors SHOULD manage focus of descendants for all instances of this <a>role</a>, as described in <a href="#managingfocus">Managing Focus</a>.</p> | ||
| <p>Elements with the role <code>menu</code> have an implicit <pref>aria-orientation</pref> value of <code>vertical</code>.</p> | ||
| <p class="note"> | ||
| The <code>menu</code> <a>role</a> doesn't allow for accessibility children roles other than <rref>menuitem</rref>, <rref>menuitemcheckbox</rref>, <rref>menuitemradio</rref>, | ||
| <rref>separator</rref>, and <rref>group</rref>. In this context, the role <rref>group</rref> allows only <a>accessibility children</a> with a role <rref>group</rref>, | ||
giacomo-petri marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <rref>menuitem</rref>, <rref>menuitemcheckbox</rref>, <rref>menuitemradio</rref> or <rref>separator</rref>. | ||
| </p> | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I admit I'm still unhappy with this. I don't like how the second sentence contradicts the first sentence's "allows only roles". I don't like "structural" in "structural element" nor how generics are mentioned (which can always be added after all so here a reader might wonder what is special about mentioning them again). I also do not like the duplication of this language in menubar; it will invariably fall out of sync. I realize we cannot get to something as tight as we have for trees, but I think we should work on this concept rather than adding more complicated language like this throughout the spec. Still, I don't want to keep blocking this. |
||
| </div> | ||
| <table class="def"> | ||
| <caption> | ||
|
|
@@ -6245,9 +6250,11 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <td class="role-mustcontain"> | ||
| <ul> | ||
| <!-- keep in sync with #menubar --> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>group</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>menuitem</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>menuitemradio</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>menuitemcheckbox</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>separator</rref></li> | ||
| <li><rref>menuitem</rref></li> | ||
| <li><rref>menuitemcheckbox</rref></li> | ||
| <li><rref>menuitemradio</rref></li> | ||
|
|
@@ -6304,6 +6311,11 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| </p> | ||
| <p>To be <a>keyboard accessible</a>, authors SHOULD manage focus of descendants for all instances of this <a>role</a>, as described in <a href="#managingfocus">Managing Focus</a>.</p> | ||
| <p>Elements with the role <code>menubar</code> have an implicit <pref>aria-orientation</pref> value of <code>horizontal</code>.</p> | ||
| <p class="note"> | ||
| The <code>menubar</code> <a>role</a> doesn't allow for accessibility children roles other than <rref>menuitem</rref>, <rref>menuitemcheckbox</rref>, <rref>menuitemradio</rref>, | ||
giacomo-petri marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <rref>separator</rref>, and <rref>group</rref>. In this context, the role <rref>group</rref> allows only <a>accessibility children</a> with a role <rref>group</rref>, | ||
giacomo-petri marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <rref>menuitem</rref>, <rref>menuitemcheckbox</rref>, <rref>menuitemradio</rref> or <rref>separator</rref>. | ||
| </p> | ||
| </div> | ||
| <table class="def"> | ||
| <caption> | ||
|
|
@@ -6345,9 +6357,11 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <td class="role-mustcontain"> | ||
| <ul> | ||
| <!-- keep in sync with #menu --> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>group</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>menuitem</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>menuitemradio</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>menuitemcheckbox</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility child</a> <rref>separator</rref></li> | ||
|
||
| <li><rref>menuitem</rref></li> | ||
| <li><rref>menuitemcheckbox</rref></li> | ||
| <li><rref>menuitemradio</rref></li> | ||
|
|
@@ -6400,7 +6414,7 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <p>An option in a set of choices contained by a <rref>menu</rref> or <rref>menubar</rref>.</p> | ||
| <p> | ||
| Authors MUST ensure [=elements=] with <a>role</a> <code>menuitem</code> are <a>accessibility children</a> of an element with role <rref>menu</rref>, <rref>menubar</rref>, or an element | ||
| with role <rref>group</rref> that is an <a>accessibility child</a> of an element with role <rref>menu</rref> or <rref>menubar</rref>. | ||
| with role <rref>group</rref> that is an <a>accessibility child</a> of an element with role <rref>group</rref>, <rref>menu</rref> or <rref>menubar</rref>. | ||
| </p> | ||
| <p> | ||
| Authors MAY disable a menu item with the <sref>aria-disabled</sref> attribute. If the menu item has its <pref>aria-haspopup</pref> attribute set to <code>true</code>, it indicates that | ||
|
|
@@ -6457,6 +6471,7 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <ul> | ||
| <li><rref>menu</rref></li> | ||
| <li><rref>menubar</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>group</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>menu</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>menubar</rref></li> | ||
| </ul> | ||
|
|
@@ -6520,7 +6535,7 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <p>A <rref>menuitem</rref> with a checkable state whose possible <span>values</span> are <code>true</code>, <code>false</code>, or <code>mixed</code>.</p> | ||
| <p> | ||
| Authors MUST ensure [=elements=] with <a>role</a> <code>menuitemcheckbox</code> are <a>accessibility children</a> of an element with role <rref>menu</rref>, <rref>menubar</rref>, or an | ||
| element with role <rref>group</rref> that is an <a>accessibility child</a> of an element with role <rref>menu</rref> or <rref>menubar</rref>. | ||
| element with role <rref>group</rref> that is an <a>accessibility child</a> of an element with role <rref>group</rref>, <rref>menu</rref> or <rref>menubar</rref>. | ||
giacomo-petri marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| </p> | ||
| <p> | ||
| The <sref>aria-checked</sref> <a>attribute</a> of a <code>menuitemcheckbox</code> indicates whether the menu item is checked (<code>true</code>), unchecked (<code>false</code>), or | ||
|
|
@@ -6573,6 +6588,7 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <ul> | ||
| <li><rref>menu</rref></li> | ||
| <li><rref>menubar</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>group</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>menu</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>menubar</rref></li> | ||
| </ul> | ||
|
|
@@ -6632,7 +6648,7 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <p>A checkable <rref>menuitem</rref> in a set of elements with the same role, only one of which can be checked at a time.</p> | ||
| <p> | ||
| Authors MUST ensure [=elements=] with <a>role</a> <code>menuitemradio</code> are <a>accessibility children</a> of an element with role <rref>menu</rref>, <rref>menubar</rref>, or an | ||
| element with role <rref>group</rref> that is an <a>accessibility child</a> of an element with role <rref>menu</rref> or <rref>menubar</rref>. | ||
| element with role <rref>group</rref> that is an <a>accessibility child</a> of an element with role <rref>group</rref>, <rref>menu</rref> or <rref>menubar</rref>. | ||
giacomo-petri marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| </p> | ||
| <p> | ||
| Authors SHOULD enforce that only one <code>menuitemradio</code> in a group can be checked at the same time. When one item in the group is checked, the previously checked item becomes | ||
|
|
@@ -6690,6 +6706,7 @@ <h4>Plain HTML or Polyfill DOM Result of the MathML Quadratic Formula</h4> | |
| <ul> | ||
| <li><rref>menu</rref></li> | ||
| <li><rref>menubar</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>group</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>menu</rref></li> | ||
| <li><rref>group</rref> with <a>accessibility parent</a> <rref>menubar</rref></li> | ||
| </ul> | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.