Per spec, a positioned {}-block is allowed for a custom property, but not for @property/initial-value:
- [...] Otherwise, if
decl’s value contains a top-level simple block with an associated token of <{-token>, and also contains any other non-<whitespace-token> value, return nothing. (That is, a top-level {}-block is only allowed as the entire value of a non-custom property.)
A possible solution could be to apply this only "if decls name is a supported CSS property".
However, I think the intention of step 9 is to allow reparsing a:hover {} / avoid reparsing --custom: var(1) {}, as a qualified rule. But it indifferently returns "nothing". So it could return an "invalid declaration error" instead. Consume a block's contents would also need to be updated accordingly.
Per spec, a positioned {}-block is allowed for a custom property, but not for
@property/initial-value:A possible solution could be to apply this only "if
decls name is a supported CSS property".However, I think the intention of step 9 is to allow reparsing
a:hover {}/ avoid reparsing--custom: var(1) {}, as a qualified rule. But it indifferently returns "nothing". So it could return an "invalid declaration error" instead. Consume a block's contents would also need to be updated accordingly.