-
Notifications
You must be signed in to change notification settings - Fork 27
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
Define "scoped" or reuse another existing term? #375
Comments
scoped defined in css - https://drafts.csswg.org/css-contain-2/#property-scoped |
The CL for the changes to aside (#350) on Chromium hasn't landed yet, and the question of scope has been brought up! So here is a question 4: does "scoped to" role obey In the CL, we did implement question 2 above, which is to say an aria role (like |
hi @spectranaut that's a good catch and yes, we did talk about if someone had an element like blockquote, but then gave it a role=none, that then the ancestor aside could then still map to complementary. e.g.,
If an aside were aria-owned by another element, then as that essentially makes it behave as if it was a descendant of that element, then ideally its role would be exposed in the manner of if it were a true child of that element. I have no idea how often people are actually doing that, especially since aria-owns is still not supported with webkit. but... meh. I'll be sure to include this use case. thank you |
Ok @scottaohara we are still working getting this idea of "scoped" implemented in Chrome. I checked the status of this for all browsers, using "header" as an example, on a Mac. Unfortunately all implementations use only the pre-aria html tree for calculation the role of the header element in all cases:
|
Yes that is not surprising as previously this had been only implemented based entirely on the html element and did not consider if the role was modified to something else |
Hey @scottaohara another few question on scope and aria overrides
In this case, the
The algorithm in chromium COULD check the dom and always check for the |
so we should definitely sync up on this because while I can give you answers to your questions, there is also the effort in the HTML spec to revise/remove aspects of the outline algorithm that actually removes the concept of sectioning roots from the HTML spec. If you have any time over the next few days this week, we could try to talk this out again and see what might need changing per the updates going on in HTML? |
From our conversation, it seems that there is no need to actually use "sectioning roots" other than For those reading this: the reason is that the best practices for an html document is to have all content in a landmark. It seems weird to prohibit a landmark in a "sectioning root" when the "sectioning root" element should already be contained within "sectioning content" element anyway. |
and for further clarity here, sectioning roots are identified as the following elements: with the exception of @spectranaut i'd make the change now. I'll get a PR setup for the sectioning root removal from where it's mentioned in the spec. |
ping @scottaohara I wouldn't mind that PR because I don't want to change my |
sorry, need to get some blocked off time to work on this again. |
Hey @scottaohara ^^ Just a heads up that there might be a typo in this sentence. Did you mean a descendant (or direct child) of the |
Hey @scottaohara maybe I can take this one off your plate and give it a try? |
closes #375 The purpose of this proposal is both to resolve the issue that "scoped" was an undefined term that was used to indicate when certain elements would expose particular ARIA roles or not. However, in the year of noodling on this, other activities to revise what "owned" means in ARIA, the idea of a minimum role, as well as the fact there were other elements in HTML that have "scoped" or "contextual roles" that are based on heuristics, rather than defined standards, became relevant. A change to hopefully help simplify the implementations of contextual roles is that this proposal is aiming to tie the role of an element based on its a11y tree ancestry, rather than based on specific HTML elements in the DOM. This PR represents the initial draft of the proposal. Other work to explicitly call out the elements that have contextual roles, what roles they need to adjust to, and other wording revisions to replace "scoped" with the new term would still need to be made.
This is follow on work to #350 as HTML AAM (and ARIA in HTML) use the term 'scoped' to indicate when a
header
,footer
andaside
have an implicit ARIA landmark role, or not. "Scoped" in this context essentially means that they are an ancestor of thebody
element (or thebody
ormain
element, inaside
's case), with no intervening sectioning content or sectioning root elements.There are a few things that need to be addressed with this term:
div
) - which is fine for the scoping rule, but gives it an explicit ARIA role which effectively exposes it as an element which should break the scoping rule.header
,footer
andaside
. There are other elements that have similar behavior of becoming 'generic' or having their role 'ignored' under certain circumstances. But as far as i can tell, this isn't actually specified so much as it just is accepted behavior. e.g., a list item is not exposed as a list item if not contained within a list. Or if a table's implicit role is overwritten, all its direct table descendants become generics... and if you say use atd
outside of the context of a table, browsers don't even render the element - its contents are just rendered instead.Interested in people's thoughts on this.
The text was updated successfully, but these errors were encountered: