-
Notifications
You must be signed in to change notification settings - Fork 3
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
Unify text & icon colour tokens? #313
Comments
They are not 1:1... Text colour styles include:
Whereas icon colour styles use:
In application, two use cases for separate semantic tokens come to mind:
Does this help? |
@americanrefugee thx for the input! So for the alpha variants, we could also maintain them, so e.g. we could end up with:
And then in the descriptors we could just note that the alpha variants wouldn't pass a11y if used for text. Would you have concerns about this? For badges - can you link to the hover states somewhere? I'm struggling to grok the use in practise. |
Actually, let's discuss badge semantic tokens separately because that would include many more colours (e.x. green, blue) for a very limited use case. What you've proposed above should cover the vast majority of use cases. |
This change sounds positive to me given it felt like in practice, text and icon were being used interchangeably at times. It will be massively breaking given these tokens are used everywhere, but seems worthwhile to me and (at least on iOS) we can use a workaround until we're ready to adopt it properly) |
That's true @pixlwave, there will be lots of breaking changes... @nadonomy Is it at least possible to merge the old styles into the new ones in Token Studio so that the changes are applied automatically to all components in Figma? Or would we need to apply new color tokens to every single component again?? If we would need to update everything manually, especially on both sides, then I wonder if we should just keep it like it is now??? Also, nobody is confused about the current semantics, which is another argument for NOT changing anything. |
Notes from our discussion this morning (please add anything I missed!):
|
Merging these sets of tokens will definitely be a breaking change for Web, but I believe it's one we can manage: The downstream products using Compound don't have to upgrade to the new token sets at the same time, so EW and EC can do this independently. We haven't set up our tooling in those products to detect and flag broken token references, so there is some risk of regressions, but the migration process sounds simple enough that I'm not too concerned. The name |
I noticed that we maintain the exact same colour values across 2 sets of semantic tokens in
color/text/*
&color/icon/*
.Does anyone have a strong rationale for why we should maintain both of these? Why not just have one set (
color/fill/*
?) which can be used to style whatever's needed?The text was updated successfully, but these errors were encountered: