The React hook over createTrackDrag: owns the dragMode state and stops the hold timer on unmount. The getters and onStart are read live through a ref, so consumers' closures over changing values (thumb state, offsets) need no handler rebuild.
dragMode
onStart
The React hook over createTrackDrag: owns the
dragModestate and stops the hold timer on unmount. The getters andonStartare read live through a ref, so consumers' closures over changing values (thumb state, offsets) need no handler rebuild.