Jump to content
Search Community

Gsap Reverse animation issue

Adesh test
Moderator Tag

Recommended Posts

How can i do reverse animation on text out animation?

 

After the click on next or prev button, I need change order of slide down aniamtion which need to start from the button.

 

Can anyone help me on this??

 

Also I am facing 3 more issue on same slider which is listed below.
1) I need to add slider dots to jump slides but i am getting error.
2) I need to add prev, next arrow HTML into all separate slides, Because i need to add text instead of arrow and it will change based on slide.

3) I need to change slide using drag.

I am beginner on the Greensock, Please help me on the above points, It's a lot to me!
Thanks,

See the Pen yLEMVbZ by Adesh-Evince (@Adesh-Evince) on CodePen

Link to comment
Share on other sites

Sliders are really complicated and need a lot of Javascript logic to function correctly. 

 

I've build a starter template for my self which has next/prev buttons, dots navigation and its draggable. I've made this as a jumping off point to modify when I need to, maybe it helps you find a solution for your problem.

 

See the Pen GREebPK by mvaneijgen (@mvaneijgen) on CodePen

 

Here is an example with a more fancy animation, but the logic is the same.

 

See the Pen YzQZBgr by mvaneijgen (@mvaneijgen) on CodePen

 

I've tried and placed comments in my code to make it more readable, hope it helps and happy tweening! 

 

  • Like 1
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...