Restricting colour tokens per property #3425
Unanswered
loicplaire
asked this question in
Q&A
Replies: 1 comment
-
|
This is an interesting idea that might be worth implementing. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, thanks for Panda CSS, it has been great to work with so far!
I have colour tokens that are roughly structured like this:
{ "grey-50": { "value": "#ffffff", "type": "color" }, "grey-500": { "value": "#dfe0e6", "type": "color" }, "purple-900": { "value": "#3d1cba", "type": "color" }, "surface-color": { "value": "{grey-50}", "type": "color", }, "surface-color-accent": { "value": "{purple-900}", "type": "color", }, "border-color": { "value": "{grey-500}", "type": "color", }, "border-color-accent": { "value": "{purple-900}", "type": "color", }, "text-color": { "value": "#1e163c", "type": "color", }, "text-color-danger": { "value": "{red-900}", "type": "color", } }Ideally I would like:
surface-*tokensborder-*tokenstext-*tokensFor example:
Is this kind of per property restriction currently possible in Panda, based on the token name or group? Or are all colour tokens always treated as part of a single colours space?
Thanks a lot for your help!
Beta Was this translation helpful? Give feedback.
All reactions