Skip to content

TouchableHighlights appear overly sensitive #335

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ThomasRedstone opened this issue Jan 20, 2017 · 7 comments
Closed

TouchableHighlights appear overly sensitive #335

ThomasRedstone opened this issue Jan 20, 2017 · 7 comments
Labels
needs: more information Issue is missing actionable information

Comments

@ThomasRedstone
Copy link

What is the current behavior?

When scrolling in Chrome on Android, it's very easy to mis-click a TouchableHighlight.

Link to minimal test case: https://pastebin.com/Nrb0ZLAu

What is the expected behaviour?

Touching a TouchableHighlight requires a more deliberate action (with some period of pressing without moving required).

Steps to reproduce

  1. Swipe clumsily on a mobile device.
  2. Have touch even triggered.

Environment (include versions)

OS: Android
Device: Galaxy S7
Browser: Android
React Native for Web (version): 0.0.68
React (version): 15.4.1

@necolas
Copy link
Owner

necolas commented Jan 20, 2017

Are you saying this is more sensitive than it is in React Native? If not, there are press delay props: http://facebook.github.io/react-native/releases/0.40/docs/touchablewithoutfeedback.html#delaypressin

@necolas necolas added the needs: more information Issue is missing actionable information label Jan 24, 2017
@necolas
Copy link
Owner

necolas commented Jan 28, 2017

Closing due to no follow up.

@necolas necolas closed this as completed Jan 28, 2017
@wjielim
Copy link

wjielim commented Dec 4, 2017

Hi there, I have a similar problem. The touchables are too sensitive -- by this I mean the button onPress function is triggered by just doing a swiping gesture on the button, which is unintentional when trying to scroll down a web page. This can be reproduced by simply attempting to scroll down web page by swiping on the touchable on a mobile browser.

@necolas
Copy link
Owner

necolas commented Dec 4, 2017

To prevent that you should put your app in a scroll view

@dennishansen
Copy link

Hi @necolas, is there a way to fix this without using a react-native-web scroll view? I'm asking because we are using react-native-web components from an external library and do not have react-native-web as an explicit dependency in our project.

@necolas
Copy link
Owner

necolas commented Jan 25, 2019

You can look through this issue for ideas, but realistically you need to be using ScrollView I'm afraid. I'm starting to explore options but this is tied to the event systems in React, which are being rewritten in both React DOM and React Native.

@tafelito
Copy link

tafelito commented Feb 11, 2019

@necolas what do you mean by wrapping the app in a scrollview? I'm using a FlatList and I'm still having this issue.

I wrapped all my App component inside a ScrollView and nothing changed. Is there any workaround for this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs: more information Issue is missing actionable information
Projects
None yet
Development

No branches or pull requests

5 participants