I’ve just applied variables to all our project’s text styles.
It all works as expected.
However, in inspect mode, font weight it still displayed as normal css value and not with css-variable.
See screenshots.
Is this a bug or me messing up things?
Devs need to know what token to use, otherwise they may hard-code the value which may not be the same between modes. How do we request this be fixed?
This is the main concern I have when working with variables, and it goes against proposed specs for design tokens in the industry. This is Figma making an implementation judgment on behalf of an organization rather than allowing for an organization to define the Tokens/Variables that work for them.
Additionally, focusing only on CSS implementation here leaves out other platforms that are represented elsewhere in Dev Mode.
I just found out this problem, as our devs are starting to implement our design system.
It’s a really big problem: figma already displays the wrong font-weights (600 when I selected 700, 400 when i select 300), and now this? How can it be possible? If I select a variable as font-weight, it’s supposed to show that variable. Who cares if it’s a number, a string or a boolean?
There are fonts that have “solid” as font-weight and other that use “300 italic” for their italic. How am I supposed to represent it as number?
It’s really concerning: Figma is focusing mostly on the shiny features, rather than core important features like this.
I agree... for my design system, I had to abandon variables and revert to using styles, and subsequently use an external plugin to generate a JSON file with the text styles, otherwise the developers would have had a lot of difficulty
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.