Re: [csswg-drafts] [css-contain-3] Nesting Context (side effect / enhancement) (#7209)

This is a use-case that I've considered as well. I think there might be use-cases for simply checking that you are in a named container, without additional query info. There's a lot of overlap with the use-cases for style queries or higher level custom properties – checking to see if you are in a particular style context, and adjusting to match it. This would basically be syntax sugar for a style query of the `container-name` property, which in some cases could be used instead of creating a new custom property to query.

To summarize:
- I think this has totally reasonable use-cases that are distinct from nesting, but those use-cases can already be achieved
- The existing solutions provide the same functionality with only a little more explicit code
- If we find that it's a very common use-case, this seems like a change we could make down the road without compat issues

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


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

Received on Friday, 27 January 2023 18:57:59 UTC