Re: [csswg-drafts] [css-variables-2] Custom shorthands with `@property` (#7879)

As I replied to @Loirooriol earlier, this:

```css
sufficiently general selector {
 padding: var(--foo);
}

.foo {
 --foo: 10px;
}
```

Is *not* equivalent to:

```css
.foo {
 --shorthand-with-padding: 10px;
}
```

In the former, if *anything*, even with the tiniest specificity overrides `padding`, no amount of setting `--foo` to anything will affect the padding, whereas in the latter, the declaration will expand to something that includes `padding`, and can override other `padding` declarations.

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


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

Received on Saturday, 15 October 2022 17:28:11 UTC