Should I use variants for this or no?

I’m trying to better understand variants and make my life much easier, but I’m unsure if I am doing the right thing!

What I basically want: I have a frame that has a State field, once the user clicks on it, a menu will move in the same frame from the bottom.

What I did: I made the field as a component, same for the menu but also made it as a variant. I added the button inside the same variant grouping and I am trying to connect all of them together to make this happen but it does not happen.

Can someone explain why or what is the best way to do it?


Hi there @Shani_S

I don’t think you’re using it correctly.
Variants are there to make your component logic comprehensive, not your frame logic

Make each element separate components (use variant components with the use component properties if your elements have different states) then create a frame and reuse those components and connect their child together.

This is a good tutorial to fully understand variants: