Skip to main content

If you create a button component with a variant for a pressed state and add a "Change to" action to make it interactive, the placed instance will remain in its pressed state when an "On click" action is applied.

Steps to reproduce:

1. Create a component with 2 variants
2. Add a "While pressing" action to the first variant that switches to the second.
3. Place two instances of the component in a frame.
4. Add an "On Click" action to one instance (e.g. setting a variable).
5. Test the prototype.

Result:

The instance with the “On click” action stays pressed, while the other doesn't.

Link sample:

 

Hi ​@Karsten_Muller1, Thank you for reporting this issue and for providing the sample file.

 

I've been able to reproduce the behavior you described.

Here's what I did: I added an "On click" → "Set variable" interaction to an object that already had a variant interaction set to "While pressing" → "Change to."

When I click the object, here's what happens:

  1. The variant interaction ("While pressing" → "Change to") kicks in.
  2. Then interaction the "On click" → "Set variable" interaction runs.

Upon releasing the mouse button, the object stays in the current variant, but I understand you'd expect it to go back to the original.

I'll check with the team to see if this is how it's supposed to work. Once I learn anything, I'll let you know.

 

Thanks again for reaching out!


Hi there,

 

Looks like we've encountered a bug that our engineering team is working on. I've shared your post with them.

While we can't give you an exact timeline for when it'll be fixed, but we really appreciate you letting us know about this.

 

Thanks again for your help!


Reply