CollectionSwipeAnimator
This class only tracks WHICH keys are involved in the active gesture and at WHAT distance from its origin. It does not know about, or dispatch to, capabilities.
Calls to this controller and the supplied coroutine scope must be confined to the same dispatcher. The Compose helper provides this confinement by default. visibleKeys must return unique keys. Gestures may only start from a returned key.
Constructors
Functions
Capability + its distance from the gesture's origin, for every key still tracked by the active gesture. Call this from your own dispatcher to decide what to do with each one — this class never calls capability methods itself.
Ends the active gesture. When preservePositionForKey is supplied, that key's current animated position is kept so an action surface revealed by the gesture remains interactive; all other affected keys settle normally.
Call when your capability's own "snap back" logic decides a key should stop tracking the active gesture (equivalent to the old snapBack callback in the prototype).