0

I have a problem in my code with container's width, when I scrolling. For example, I don't see my las item in the list. I can't understand why there is this problem. I use ScrollTrigger and GSAP for this horizontal scroll. Also active element is wrong, because I can't scroll to end of list

``https://codepen.io/afonin_vlad/pen/BadoYqM```

1 Answer 1

1

Your getMaxWidth() only adds the offsetWidth, but forgets to add the 30px margin-left.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.