When a container is scrolled and set to visible when drag starts the draggable element is offset to the mouse cursor. I created a small demo to show this:
https://stackblitz.com/edit/gsap-react-basic-f48716-w6gvjb?file=src%2FBoxItem.js
(drag the boxes that are visible after the container is scrolled).
Is there a way to avoid this behaviour? The reason that I'm doing the overflow: auto/visible is that the draggables cannot be dragged while the overflow is auto or hidden.
Awesome, thank you so much! I've been stack at this for hours, but I knew there had to be a solution for something so trivial. GSAP is the best!