Share Posted December 4, 2013 Hey all, I'm currently playing with the timeline and setting up a sequence of animations. So far i've used tl.to in my sequencing and all went good. I then wanted to implement .fromTo however that seemed to mess up my timeline. My objective is fairly simple, summarized in the following steps. 1. I do some initial CSS tweening 2. I fade up some text 3. I tween my div to the outer right 4. I change up some text 5. ISSUE: I now want to re-position my div to the outer left and tween it into center again. Ive set up an illustrative codepen example here: See the Pen IeLrF by mrsgs (@mrsgs) on CodePen Note: uncomment line 15 to see the issue apply Link to comment Share on other sites More sharing options...
Share Posted December 4, 2013 Thanks so much for providing the codepen example along with your clear description. The issue is that from() and fromTo() tweens have their immediateRender property set to true by default. To fix the issue just set immediateRender:false in the troublesome tween like so: .fromTo("#html5-entry-timeline", 1.5, {left:-800}, {left:100, immediateRender:false}); fixed: http://codepen.io/GreenSock/pen/ChqvA The short story of why immediateRender is set to true for from() and fromTo() tweens by default can be witnessed here: http://codepen.io/GreenSock/pen/Amnrc In your case your fromTo() tween at the end had immediateRender set to true so the left position was set immediately, thus messing with your animation. For the most part, immediateRender's default value of true only really becomes an issue if you are doing multiple from() tweens on the same properties of the same object. 3 Link to comment Share on other sites More sharing options...
Author Share Posted December 6, 2013 Hi Carl - never got back to you on this one. Thanks for contributing with your throughout description of the "issue", it makes sence to me and your "fix" got my timeline going as intended now - i'd probably never figured that out if you hadn't come a long Again thanks - you're doing some overwhelming quick support here! A good weekend to you sir! 1 Link to comment Share on other sites More sharing options...
Share Posted December 6, 2013 Thank you Mr Sam. Its always good to know when our support is appreciated. Fortunately we have a strong community of folks that pitch in, help lighten the load, and provide world-class support. 2 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now