Skip to main content
Andrea_Monfrini
New Participant
November 29, 2023
Solved

Trouble setting a component that changes the state of its parent

  • November 29, 2023
  • 1 reply
  • 388 views

I’m having trouble setting a component that changes the state of its parent.
I have done this flux:

  • Create component A with default and hover variant
  • Create component B with two variants (dropdown closed and open)
  • Add component A as a child of component B. Add an On click → Change to interaction to the instance of component A. The two variants of component B will show up as options under the variant drop-down; you can open the drop-down, but you cannot select any variant besides the one that is already selected

Is this a bug of Figma? Or is my fault?

This topic has been closed for replies.
Best answer by djv

Hey Andrea, thanks for reaching out!

It’s hard to be sure without seeing your file, but from what you’ve described, you might be better off using multiple action variables instead:

Figma Learn - Help Center

1 reply

djv
Figmate
djvAnswer
Community Support
November 29, 2023

Hey Andrea, thanks for reaching out!

It’s hard to be sure without seeing your file, but from what you’ve described, you might be better off using multiple action variables instead:

Figma Learn - Help Center