Re: [csswg-drafts] [css-variables?] Higher level custom properties that control multiple declarations (#5624)

Regarding Tab's proposal, we can do slightly better, and copy the value preceding the `@if` as a fallback:
```
my-input {
        color: blue;
 @if (var(--pill) = on) {
  color: green;
 }
}
```
would be either `blue` or `green`, by filling the fallback part of the `cond` with the already-existing value in the declaration (and only in the declaration, not across another selector, so that would still be a limitation, just a more convenient one because it allows to specify a default.

-- 
GitHub Notification of comment by FremyCompany
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5624#issuecomment-741943631 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 9 December 2020 17:52:19 UTC