csswg-drafts
csswg-drafts copied to clipboard
[css-cascade] Allow declarations directly in @scope?
Currently, @scope
only accepts rules in its body. If you want to apply something to the scoping root itself, you need to use a :scope
rule:
@scope (div) {
:scope {
color: green;
}
}
However, ever since relaxed nesting was introduced (where we first try to parse something as a declaration, and otherwise try it as a nested rule), we should be unblocked if we wanted to support direct declarations in the rule.