Jump to content
Search Community

using multiple labels and .from/.to in a timeline

timdt test
Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

Your CodePen doesn't work because jQuery wasn't loaded.

 

I'm not sure I understand your question. Are you talking about bringing all the boxes back to x:0 and autoAlpha:1 at the end? If that's the case, you can target all three with a .to() tween at the end like this:

 

.to([blokkie1, blokkie2, blokkie3], 2, {x:0, autoAlpha:1, ease:Power1.easeIn});

 

Is that what you meant?

 

Happy tweening.

:)

  • Like 1
Link to comment
Share on other sites

@PointC What i am trying to achieve is that the 3 blocks all go out of the border ( out of vieuw ) to opacity 0. and return to their starting position all at the same time. I will try your code and see what happens :)  Also will do a quick google search on how to include jquery on codepen.

 

thanks for helping me out once again <3

Link to comment
Share on other sites

@timdt can you instead post drawings of what you are doing? I looked at your question yesterday it sounded very simple but when I looked at your pen you are using too many tweens for something that sounds very simple. I think you will get answer a lot quicker if you post mockups at different time frame.

Link to comment
Share on other sites

See the Pen mBPKOB by timdt (@timdt) on CodePen

 

Above is the version i do not want. For some reason it puts the .from first.

 

This is the second version without the second.add that does work. In this pen i added a new element. I want this to happen not the the new element but to the blocks. i want them to come back from out of vieuw back to their starting positions. @Sahil

See the Pen wrGXdx by timdt (@timdt) on CodePen

 

 

Sketch :20170920_103301.thumb.jpg.891a971b5bc77321f0c21c0ad3165ec9.jpg

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.
×
×
  • Create New...