Resolving user agent must not statement and whitespace defs#1778
Merged
Resolving user agent must not statement and whitespace defs#1778
Conversation
Related to w3c/core-aam#128 Fixes #1476 - link to definition of whitespace in the aria-braillelabel and aria-brailleroledescription, aria-roledescription sections - remove reference to whitespace from user agents must not aria-roledescription requirement - remove author error correction User Agents MUST NOT expose prohibited ARIA attributes statement from correcting for author errors section. - adds authors MUST NOT specify aria-roledescription on elements with roles where the attribute is prohibited. - removed non-normative "should" from aria-brailleroledescription - adds authors MUST NOT use aria-brailleroledescription where prohibited - adds authors MUST NOT use aria-label and aria-labelledby where prohibited
Member
|
@jcsteh can you please review this. |
spectranaut
reviewed
Aug 18, 2022
jnurthen
approved these changes
Aug 24, 2022
cookiecrook
approved these changes
Aug 25, 2022
Contributor
cookiecrook
left a comment
There was a problem hiding this comment.
approving after comment threads resolved
index.html
Outdated
| <p><a>Defines</a> a string value that labels the current element. See related <pref>aria-labelledby</pref>.</p> | ||
| <p>The purpose of <pref>aria-label</pref> is the same as that of <pref>aria-labelledby</pref>. It provides the user with a recognizable name of the object. The most common <a>accessibility <abbr title="Application Programing Interfaces">API</abbr></a> mapping for a label is the <a>accessible name</a> property.</p> | ||
| <p>If the label text is available in the DOM (i.e. typically visible text content), authors SHOULD use <pref>aria-labelledby</pref> and SHOULD NOT use <pref>aria-label</pref>. There may be instances where the name of an element cannot be determined programmatically from the DOM, and there are cases where referencing DOM content is not the desired user experience. Most host languages provide an attribute that could be used to name the element (e.g., the <code>title</code> attribute in [[HTML]]), yet this could present a browser tooltip. In the cases where DOM content or a tooltip is undesirable, authors MAY set the accessible name of the element using <pref>aria-label</pref>. As required by the <a href="#textalternativecomputation">accessible name and description computation</a>, user agents give precedence to <pref>aria-labelledby</pref> over <pref>aria-label</pref> when computing the accessible name property.</p> | ||
| <p>If the label text is available in the DOM (i.e. typically visible text content), authors SHOULD use <pref>aria-labelledby</pref> and SHOULD NOT use <pref>aria-label</pref>. There may be instances where the name of an element cannot be determined programmatically from the DOM, and there are cases where referencing DOM content is not the desired user experience. Most host languages provide an attribute that could be used to name the element (e.g., the <code>title</code> attribute in [[HTML]]), yet this could present a browser tooltip. In the cases where DOM content or a tooltip is undesirable, authors MAY set the accessible name of the element using <pref>aria-label</pref>, if the element does not <a href="#prohibitedattributes">prohibit</a> use of the attribute. Authors MUST NOT specify <code>aria-label</code> on an element which has an explicit or implicit WAI-ARIA role where <code>aria-label</code> is <a href="#prohibitedattributes">prohibited</a>. As required by the <a href="#textalternativecomputation">accessible name and description computation</a>, user agents give precedence to <pref>aria-labelledby</pref> over <pref>aria-label</pref> when computing the accessible name property.</p> |
Contributor
There was a problem hiding this comment.
In the cases where DOM content or a tooltip is undesirable, authors MAY set the accessible name of the element using <pref>aria-label</pref>, if the element does not <a href="#prohibitedattributes">prohibit</a> use of the attribute. Authors MUST NOT specify <code>aria-label</code> on an element which has an explicit or implicit WAI-ARIA role where <code>aria-label</code> is <a href="#prohibitedattributes">prohibited</a>.
This felt redundant while reading... I looked back and realized it was not.
Reversing the two sentence may resolve it? E.g. list the rule first then exception, rather than exception before the rule.
Member
Author
There was a problem hiding this comment.
made a commit to try to address this - 7f6baae
Co-authored-by: James Craig <cookiecrook@users.noreply.github.com>
Co-authored-by: James Craig <cookiecrook@users.noreply.github.com>
@cookiecrook does this reordering help? I think it does, but just wanted to verify. Thank you.
spectranaut
approved these changes
Aug 25, 2022
jnurthen
pushed a commit
that referenced
this pull request
Oct 10, 2023
- link to definition of whitespace in the aria-braillelabel and aria-brailleroledescription, aria-roledescription sections - remove reference to whitespace from user agents must not aria-roledescription requirement - remove author error correction User Agents MUST NOT expose prohibited ARIA attributes statement from correcting for author errors section. - adds authors MUST NOT specify aria-roledescription on elements with roles where the attribute is prohibited. - removed non-normative "should" from aria-brailleroledescription - adds authors MUST NOT use aria-brailleroledescription where prohibited - adds authors MUST NOT use aria-label and aria-labelledby where prohibited Co-authored-by: James Craig <cookiecrook@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related to w3c/core-aam#128
Fixes #1476
Preview | Diff