- From: Quentin Albert via GitHub <sysbot+gh@w3.org>
- Date: Thu, 09 Nov 2023 15:44:57 +0000
- To: public-css-archive@w3.org
Que-tin has just created a new issue for https://github.com/w3c/csswg-drafts: == [css-properties-values-api] Allow scoped @property rules == There currently is no way to define `@property`-Rules on a non global level. When people want to leverage the `syntax` especially in combination with `|` this will be handy e.g.: ```css .card { @property --size { syntax: "default | big"; inherits: false; initial-value: default; } } .button { @property --size { syntax: "small | default"; inherits: false; initial-value: default; } } ``` The current implementation would lead to all custom properties being globally scoped and therefore the need of unique names e.g: ```css @property --card-size { syntax: "default | big"; inherits: false; initial-value: default; } @property --button-size { syntax: "small | default"; inherits: false; initial-value: default; } ``` This can quickly get out of hand and become chaotic. This feature will become even more useful when Style Queries grow in adoption. Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9580 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 9 November 2023 15:44:59 UTC