-
Notifications
You must be signed in to change notification settings - Fork 125
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
[html-aam PR 540] Clarify li element role mapping #2212
base: main
Are you sure you want to change the base?
Conversation
The intent of this text change is to clarify that a list item that is still a child of a list, but has intervening generic elements should still be exposed as a listitem. e.g., ``` <li>with no list ancestor = generic</li> <ul> <div> <!-- invalid html, but SHOULD be ignored since generic --> <li> since this has 'accessibility parent' of list, it should remain exposed as a list item </li> </div> </ul> ```
Co-authored-by: Valerie Young <[email protected]>
my manual test results - https://codepen.io/scottohara/pen/LEPRRNd |
related to w3c/aria#2212
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Though I have no problem with this minor editorial change) I recall a conversation (perhaps with @twilco, @nmlapre, and @jcsteh) that downgrading the orphaned roles had no user benefit, and had implementation cost, so the related WPT tests were rolled back or moved to tentative. I think that means this line should be removed from the spec, too.
@cookiecrook that convo definitely happened regarding the use of explicit aria roles that weren’t children of their required parents, but html’s li element contextual role was separate to that. Firefox has been treating an orphan li element as generic for 12 years now. If Firefox is willing to undo this and then all browsers consistently expose the li element as a list item, even when not within a required ul, ol, menu or role=list parent - then it can become a screen reader’s decision on how to handle these author errors, or not. Maybe this is even the way Firefox can resolve the failing tests for |
I came across a case yesterday which would break if we removed the rule for orphaned
If the
Chrome exposes listitem. But if you do this:
Chrome excludes the |
Moved from w3c/html-aam#540
edit:
closes #2173
approving reviewers from migrated HTML AAM PR: @smhigley, @cookiecrook, @spectranaut
edit again:
pointing back to the original HTML AAM PR that this is one is clarifying - w3c/html-aam#476