Jump to content
GreenSock

marsi

Creating vertical carousel

Go to solution Solved by marsi,

Recommended Posts

  • Solution

Are there any methods of creating a vertical carousel, with the selected item fixed in the center of the screen? I've tried something based on this project, but the results have been unsuccessful. Found alternatives on the forum, codepen didn't give any results either 


Modifiers Plugin for Infinite Image Carousel - GSAP - GreenSock
 

 

275283083_1.png.32fb157cdb1eef41064c75c68cf29750.png

 

Link to comment
Share on other sites

Thank you, your answer makes a great contribution to solving my question, but I would like to know if there are any code examples with vertical card display?

Link to comment
Share on other sites

9 hours ago, marsi said:

I would like to know if there are any code examples with vertical card display?

 

What's wrong the example @mikel linked to? Vertical behavior would be the exact same, just in a different direction. You just need to modify the code so it works on the y axis instead of the x axis.

  • Like 1
Link to comment
Share on other sites

Yes, thank you, it all worked out, if anyone needs an example of a vertical carousel:  

See the Pen KKWYRrE by irtexfree (@irtexfree) on CodePen

  • Like 1
Link to comment
Share on other sites

  • 1 year later...

Hi, i try to use the same function, but unfortunately the scroll/next/prev actions are always regarding to the body.
If i want to implement it inside div on a page, it always scrolls if the body scroll, and the body jumps up and down, if i click the next or prev button.

Is there a way to reduce this animation only inside a div?

Link to comment
Share on other sites

  • 4 weeks later...

Was following all the codepen example above but looks like all of them have this same weird issue, could be something broke from recent gsap update? I have replicated the codepen in our project and has the similar issue

image.thumb.png.896abc3da98ebe30caff5db6c1e81f1c.pngimage.png.685b65688eb3679029275e3b267680ad.png

Link to comment
Share on other sites

Yes indeed, I believe that's fixed in the upcoming release which you can preview at: 

Sorry about the confusion! Let us know if you still see any problems with the beta files in place. 

Link to comment
Share on other sites

 GSAP 3.11.2 is officially live and should resolve this issue. The CDN may take a little extra time to update, but Github, NPM, and the file downloads are all updated now. 🥳

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