This is a read-only archive of the Framer Community on Facebook.

What is Framer? Join the Community
Return to index
Édouard Urcades
Posted Jul 02 - Read on Facebook

For those of you with a second to spare, I'm having issues with a prototype I'm working on, linked here:

Basically if you look around lines 56-59, I'm trying to build an if...else statement that sets my animateOptions to switch depending of the state of the animated object.

First problem:

The prototype works perfectly the first time around (clicking the button results in the drawer sliding out slowly, clicking the drawer header results in the drawer receding quickly), but after that, it gets stuck with the quicker animationOptions

Second problem:

Apparently the "else..." portion of the code is having very stupid issues with indentation, not sure what the exact issue is here, but I've attached an image with the problem I'm having.


Édouard Urcades

also the time property is .2 for each statement in the image only. Ignore that :) the prototype linked works as intended

Édouard Urcades

rookie mistake. forgot for a moment else statements don't work that way

George Kedenburg III

not sure if this will fix everything, but just glancing at that code the curve and time should be indented a level below the animation options

Édouard Urcades

^ it totally worked with and without the indentation, this whole issue is solved at the moment! Not sure if I should delete this :v

Read the entire post on Facebook