When using an element with drag and dragConstraints enabled, the element gets stuck if it is quickly clicked while moving back inside its constraints after being dragged outside the defined boundaries.
This can also happen when not using dragConstraints but instead animating the element onDragEnd.
2. Describe the bug
When using an element with drag and dragConstraints enabled, the element gets stuck if it is quickly clicked while moving back inside its constraints after being dragged outside the defined boundaries. This can also happen when not using dragConstraints but instead animating the element onDragEnd.
3. IMPORTANT: Provide a CodeSandbox reproduction of the bug example without dragConstraints
example with dragConstraints
4. Steps to reproduce
Steps to reproduce the behavior:
5. Expected behavior
The element should continue moving inside its constraints after the mouse is released
6. Video or screenshots
https://github.com/framer/motion/assets/68615332/b0035081-b1bf-4eef-951a-6709d0650042
7. Environment details
Chrome 125, macOS 14.5