openspacelabs / react-native-zoomable-view

A view component for react-native with pinch to zoom, tap to move and double tap to zoom capability.
MIT License
189 stars 57 forks source link

_couldCallSwipeEvent() returns false when not all props are provided #96

Closed jaredbothwell closed 3 months ago

jaredbothwell commented 3 months ago

onSwipe, onSwipeUp, onSwipeDown, onSwipeLeft, and onSwipeRight are all optional props for ReactNativeZoomableViewWithGestures but this line returns false if any one of these props is not provided. Since these props are optional would it make sense to not require them for _couldCallSwipeEvent() to return true by using || instead of &&

elliottkember commented 3 months ago

That sounds right to me. Would you mind making a quick PR for that?

jaredbothwell commented 3 months ago

Yeah I can make PR for it