Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Figma toolkit color tokens to use variables #10

Open
daviddossett opened this issue Sep 11, 2023 · 2 comments
Open

Update Figma toolkit color tokens to use variables #10

daviddossett opened this issue Sep 11, 2023 · 2 comments
Assignees

Comments

@daviddossett
Copy link

daviddossett commented Sep 11, 2023

Currently the Figma toolkit uses a raw set of color values via shared styles. This makes it difficult for consumers of the toolkit to use colors given that there's no semantic meaning associated with them.

For example, a designer building a VS Code extension would have no way of knowing which color was used for input backgrounds unless they manually cross-referenced the hex value with the colors in colorRegistry.ts

Ideally we could use variables to expose a list of semantic tokens that match the list used in VS Code itself. These variables would referenced the raw "Base " or "Accent " colors as they exist today, updated to use the latest themes.

Image

@spartanatreyu
Copy link

If vscode is switching to color variables, it's worth looking into defining colors in oklch() instead of the older hex rgb values.

Oklch pros:

@daviddossett
Copy link
Author

This is related to our Figma toolkit, not the vscode repo, just in case that wasn't clear. I don't believe Figma supports formats other than those pictured below but cool to read about oklch()!

CleanShot 2023-09-13 at 07 31 20@2x

@daviddossett daviddossett changed the title Update color tokens to use variables Update Figma toolkit color tokens to use variables Sep 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants