- From: Romain Menke via GitHub <sysbot+gh@w3.org>
- Date: Thu, 16 May 2024 21:18:14 +0000
- To: public-design-tokens-log@w3.org
> My question to color experts here is: can we support both polar and rectangular color spaces with the spec showed above? Yes Both rectangular and polar color spaces use 3 channels each and you can define unambiguous value definitions for both rectangular and polar color spaces. ```json { "my-token": { "$type": "color", "$value": { "hex": "#xxxxxx", "colorSpace": "hsl", "channels": [270, 0.5, 0.3], "alpha": 0.6 } } } ``` Could be equivalent to `hsl(270deg 50 30)`. That is to say, these are all just numbers and as long as there is a clear definition of what the numbers mean it will work out fine. I would suggest staying close to the CSS value definitions : https://drafts.csswg.org/css-color-4/#the-hsl-notation Staying close to CSS makes it possible to use more of the shelf tooling around color and facilitates copy/pasting of values. ----- I would suggest using a different term than `colorSpace` if the intention is to adopt such a wide range of possible notations. Since not every notation might be a color space. Maybe `colorScheme`? -- GitHub Notification of comment by romainmenke Please view or discuss this issue at https://github.com/design-tokens/community-group/issues/137#issuecomment-2116202071 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 16 May 2024 21:18:14 UTC