Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
Burdock

(possible bug?) Strange behavior updating rotate tweens.

Recommended Posts

I have been working on a 2d/3d transition effect module, and I have been running into some issues integrating with gsap (TweenLite).
 
Most of the Tweens require updating on every $("window").resize() function if they have any media queries. Unfortunately I have been running into issues overwriting TweenLite.to's that involve rotations. 

 

A good example of this is a simple "hamburger" icon animation. In the below codepen is a decent example of the issue. If you resize the window while the button is in the X state (or navState = 1) the rotation tween acts as though its stuck in the tween.progress=0 state;

 

 

By changing rotationZ: to rotation: the tween rotation get stuck in the tween.progress=1 state.

 

See the Pen MwYmxa by anon (@anon) on CodePen

 

If anyone can shed some light on this issue it would be much appreciated. 

 

Thanks, 

  Daniel 

See the Pen MwYmVW by anon (@anon) on CodePen

Link to comment
Share on other sites

@Diaco.AW

 

Thanks for the fast reply, I was unaware of clearProps existence.

Is it documented anywhere?  

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×