JedWatson / react-tappable

Tappable component for React
http://jedwatson.github.io/react-tappable/
MIT License
863 stars 90 forks source link

Make difference between taps and holds #57

Closed geritol closed 6 years ago

geritol commented 9 years ago

Tap event fires after release hold (holded for more than 2-5 secs). Is there a way to prevent onTap firing after releasing holds? So adding some time span that determines what should be considered tap vs hold (time between touch start and end).

Thanks a lot!

hilkeheremans commented 9 years ago

@geritol I forked & made some experimental changes to avoid sending an onTap after an onPress is triggered. I'll be testing it with some users next week. (Not ready to PR it yet since I'll likely have made mistakes after a crazy and exhausting coding week.

@JedWatson Any specific guidelines for a PR?

hilkeheremans commented 9 years ago

My changes seem to work fine, currently using it in production.

@JedWatson Still hungry for PR guidelines. Thanks. :-)

dcousens commented 6 years ago

@hilkeheremans PR's accepted, I don't think there is any specific guidelines. Tests are appreciated.