KamoCRM

Cancel inherited drag velocity on release

Fixkamo-internal
Shipped
29 ஏப்ரல், 2026 அன்று 11:10 PM UTC
Author
kamo
Commit
b399696

The drag handler updates the head's motion value with rapid mx.set(nx) calls, which framer-motion uses to compute velocity. When the release path triggered a soft-push (because the dropped position grazed an edge or overlapped a tool window), the corrective spring inherited the drag's high velocity and overshot wildly — heads would "shoot across the page" and land elsewhere, sometimes off-screen. A stationary release worked because velocity decayed to zero first. Pass velocity: 0 in animateAnchorTo so every anchor placement starts from a clean velocity state. Also reset velocity for a follower's initial flight into a cluster (where the head being added may have just been a dragged anchor with momentum).

All changes

Like what you see shipping?

All of it arrives in your workspace on its own. Start on the free plan and read this page again in a month.

Start Free ForeverView Pricing