Skip to main content
Question

Useing variables for hover

  • February 11, 2025
  • 2 replies
  • 407 views

Brett_Taylor1

Hi,

I was trying to use variables to change the hover color of a button, but the problem is I can select the color of the base button using the tokens, the change to field only allows for hex colors; I can’t point to the hover token.

It works for a single mode, light or dark, because I can just put the hover hex color, but that’s not great when using light and dark.

 

 

2 replies

Damian_Summersall

I was wanting to do the same. It’d be great if Figma let us use variables as well as hexes. Would drastically cut down on component variants!


William_Mincher1

This would be a massive quality of life improvement.

 

If ‘Set variable’ doesn’t make sense, from a development perspective, then something like ‘Set instance property’ (and being able to override with another variable value) would be good.

It’s a temporary override of a component property when running the prototype. Figma already does this for interactions like ‘while hovering’ so it must be possible.