Re: [csswg-drafts] map-get function proposal for customising web component styles (#7273)

Love the idea to control component styles based on a custom property.

There's already a discussion on [higher level custom properties](https://github.com/w3c/csswg-drafts/issues/5624) that might solve the use case.

Container queries could also solve part of the use case:
https://github.com/w3c/csswg-drafts/issues/5624#issuecomment-849091911
https://drafts.csswg.org/css-contain-3/#container-rule

```
my-button {
  container: my-button / style;
}

@container my-button style(--size = regular) {
  /* styles */
}
```

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


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

Received on Friday, 13 May 2022 07:21:12 UTC