UNPKG

react-native-gesture-handler

Version:

Declarative API exposing native platform touch and gesture system to React Native

27 lines (26 loc) 844 B
import createHandler from './createHandler'; import { baseGestureHandlerProps, } from './gestureHandlerCommon'; export const tapGestureHandlerProps = [ 'maxDurationMs', 'maxDelayMs', 'numberOfTaps', 'maxDeltaX', 'maxDeltaY', 'maxDist', 'minPointers', ]; export const tapHandlerName = 'TapGestureHandler'; /** * @deprecated TapGestureHandler will be removed in the future version of Gesture Handler. Use `Gesture.Tap()` instead. */ // eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; see description on the top of gestureHandlerCommon.ts file export const TapGestureHandler = createHandler({ name: tapHandlerName, allowedProps: [ ...baseGestureHandlerProps, ...tapGestureHandlerProps, ], config: { shouldCancelWhenOutside: true, }, });