https://drafts.csswg.org/selectors/#the-scope-pseudo
Currently, if used in regular CSS but outside an @scope rule, :scope resolves to :root. However, this is not super useful within shadow CSS. :host would be a lot more natural.
This would be a breaking change, but I’d wager the prevalence of :scope outside @scope in shadow CSS is so low that we can still make it.
This means the same CSS can be used within Shadow DOM to style the component, as well as using @import ... scope(...) to style light DOM elements.
https://drafts.csswg.org/selectors/#the-scope-pseudo
Currently, if used in regular CSS but outside an
@scoperule,:scoperesolves to:root. However, this is not super useful within shadow CSS.:hostwould be a lot more natural.This would be a breaking change, but I’d wager the prevalence of
:scopeoutside@scopein shadow CSS is so low that we can still make it.This means the same CSS can be used within Shadow DOM to style the component, as well as using
@import ... scope(...)to style light DOM elements.