Jump to content
GreenSock

Mukhriddin

How can I able to scroll horizontally in a limited place?

Recommended Posts

Hey Mukhriddin,

 

You'd need to listen for scroll/wheel events over that panel and then link the animation up to that. Or just use native horizontal scrolling I guess!

If you want to listen for events you can use our observer plugin to make your life easier.
Here's the link to the docs, https://greensock.com/docs/v3/Plugins/Observer

Why don't you give it  go - we're here if you have questions!

Link to comment
Share on other sites

could you please show a demo in the codesandbox I shared?

P.s: I don't think the thing I need is observer. Because, as I understand it triggers one action, and it is not related to scroll width in horizontal scrolling

Link to comment
Share on other sites

You're right, observer isn't directly related to horizontal scrolling. But it's a way to capture pretty events, get data back and then you can do whatever you want with that data.

This thread should give you a hand!
 

 

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