Allow referencing of color variables for points of gradient values

First of all, love the new variable system! Simplifies so many of my complex component systems.

However, the big miss for me was not being able to reference color variables in individual points of a gradient style.

Here’s an example of how this simple addition would help:

I have a component which has fixed gradient positions and tokenized logic for the construction of the gradient styles, which swaps out 42 different color themes (why we have 42 themes is a separate discussion haha)

Right now, I am having to create 4 variants for each theme - light-resting, light-pressed, dark-resting, dark-pressed

If I was able to swap out the tokens for the gradient construction, I could set up the 42 themes as modes in the base variable system, and create 4 total variants for the component

Hopefully this functionality can be brought into Figma soon!


9 posts were merged into an existing topic: Allow gradients in color variables

26 votes have been moved. 31 votes could not be moved because their users already voted in the other topic.