airbnb / rheostat

Rheostat is a www, mobile, and accessible slider component built with React
MIT License
1.69k stars 189 forks source link

Bug: A second onChange fires and replaces the correct value after dragging #193

Open nicknish opened 5 years ago

nicknish commented 5 years ago

Hey there! Thanks for a great lib, and all the awesome open-source work y'all do.

I recently ran into this issue on mobile web with Rheostat.

Issue

On mobile web, when you drag the Rheostat handle a short distance, the correct value gets set, but then an additional value overwrites it and sends the handle back to the original position.

Steps to Recreate

  1. View rheostat component on mobile web
  2. Touch and drag the handle a short distance (and slowly) forward
  3. Let go and view the handle bounce back to its original position or slightly off

Screenshot

https://cl.ly/74a9e76fc229/IMG_5545.TRIM.MOV (Will post gif shortly)