Skip to main content
Lukas_Oppermann
January 29, 2021

Use styles in other styles

  • January 29, 2021
  • 45 replies
  • 9129 views

Problem
Currently you can’t use color styles in other styles like grid or effect styles.
However this is very helpful for building design systems. Otherwise when changing a color that is used in effect styles you have to manually change it in all effect styles (which is a lot of work and can lead to bugs by forgetting it).

Solution
One possible solution would be to allow us to use color styles within the other styles.

Am I the only person who feels this pain or do others run into this as well?

45 replies

Vesno
May 30, 2022

this would be super helpful - immense help when creating a design system and sharing it with devs

Marc7
June 1, 2022

For it will make sense to can use style colors to create another one. For example, in code, I have neutrals and branding colors as base colors and these CSS variables are used to create other variables → --xx-color-text-primary: --neutral-100; This will be amazing!

Glenn3
June 14, 2022

We need this feature asap!
image

Ludwig_T
New Member
June 17, 2022

Nested Styles are a must for anyone making a design system.

Zack_Davenport
June 30, 2022

+1, need this feature asap.

Whatislove
July 16, 2022

+1, it would be very helpful!

MFR
July 16, 2022
MFR
July 16, 2022

I just explored a solution. You can use a BASE colour and then apply styles this way. It’s also useful for changing an entire theme of a design at once.

You could make the shades different variants of the same component and swap them easily as states. Changing the base colour on the component would allow you to theme it.

Ludwig_T
New Member
September 13, 2022

I have found that “Figma Design Token” plugin works well to do this and has good video tutorial on YouTube.

Ludwig_T
New Member
September 13, 2022

This is a very interesting approach, that’s for sharing it I will give it a try and see if it fits for me as well
❤️