Skip to content
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

[css-scoping] Tree-scoped names in User and UserAgent origins #6318

Open
lilles opened this issue May 27, 2021 · 2 comments
Open

[css-scoping] Tree-scoped names in User and UserAgent origins #6318

lilles opened this issue May 27, 2021 · 2 comments
Labels
css-scoping-1 Current Work

Comments

@lilles
Copy link
Member

lilles commented May 27, 2021

When implementing tree-scoped names/references, there was a question about how to handle tree-scoped names in the User and UserAgent origins as they are not associated with a tree-scope. The spec [1] should describe the interactions with user and UA origins.

[1] https://drafts.csswg.org/css-scoping-1/#shadow-names

@lilles lilles added the css-scoping-1 Current Work label May 27, 2021
@tabatkins
Copy link
Member

Those stylesheets exist in every tree scope, right? (That... might not actually be defined anywhere.)

If it's not defined anywhere, it should be, so the behavior would just fall out.

@lilles
Copy link
Member Author

lilles commented May 31, 2021

I haven't found a definition for that. There is a description along those lines for default styles for custom elements: https://drafts.csswg.org/css-scoping/#default-element-styles

So, since they exist in all tree-scopes, I assume the tree-scoped names would then have the tree-scope of the element?

Then there's the question where in the search order for at-rules the UA and user rules would end up:

  1. After the author rules in the element's scope
  2. After looking up the nested scopes for author rules

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
css-scoping-1 Current Work
Projects
None yet
Development

No branches or pull requests

2 participants