Change theme
Help
Press space for more information.
Show links for this issue (Shortcut: i, l)
Copy issue ID
Previous Issue (Shortcut: k)
Next Issue (Shortcut: j)
Sign in to use full features.
Vote: I am impacted
Notification menu
Refresh (Shortcut: Shift+r)
Go home (Shortcut: u)
Pending code changes (auto-populated)
View issue level access limits(Press Alt + Right arrow for more information)
Unintended behavior
View staffing
Description
Jetpack Compose version: BOM 2025.02.00
Jetpack Compose component(s) used: Foundation, UI, Runtime, Animation
Android Studio Build: Android Studio Meerkat, 2023.3.1 Canary 8
Kotlin version: 2.1.10
Steps to Reproduce or Code Sample to Reproduce:
Here's a simple draggable slider, with two anchors, START and END. The
positionalThreshold
is set todistance * 0.8f
, which I would expect to mean that the thumb only snaps to the END anchor after dragging for at least 80% of the width. The actual behavior however is that the thumb snaps to START and END exactly up until the center of the track. I intentionally setvelocityThreshold
toFloat.MAX_VALUE
so that no flinging behavior should have an effect on the snapping.Is this an issue with the code or a bug in the
AnchoredDraggableState
?