Open oliverjarvis opened 6 months ago
Hey @oliverjarvis , Thanks for flagging this issue.
I have reproduced it on an Android device.
The tooltip is indeed triggered while dragging the view across the screen.
We use setOnLongClickListener
in the native component, so I believe the problem lies between the gesture handlers and the native view implementation.
I can revisit this issue later, but I cannot promise a quick fix.
If it's critical to you, you may want to consider building your own custom view to display a gif url.
I'll do as you advise and implement a solution myself. Thank you replicating it Alexander!
🐛 Bug Report
Android Simulator: The attribution tooltip that appears on long presses over the MediaViews appears when the object is panned, rotated, pinched etc. This may be caused somehow by React-Native-Gesture-Handler, but I don't think so; A long press gesture handler attached to the component fires before the attribution bubble appears.
To Reproduce
Wrap the GiphyMediaView component in an Animated.View with a react-native-gesture-handler gesture component attached to it. Example shown in the code at the bottom.
Expected behavior
I expect the attribution tooltip to appear exclusively on longpress gestures, and not count longpress gestures that stem from pans, rotations, pinches.
The same code works fine on iOS.
Actual Behavior
The tooltip appears on any gestures. Pans, Rotations, Pinches obviously result in holding down the object for a longer period of time, which on android seems to trigger the long press gesture detector.
Your Environment
Reproducible Demo