UNPKG

react-native-gesture-handler

Version:

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

28 lines (25 loc) 923 B
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent'; import type { Int32, WithDefault, Float, } from 'react-native/Libraries/Types/CodegenTypes'; import type { ViewProps, ColorValue } from 'react-native'; // @ts-ignore - Redefining pointerEvents with WithDefault for codegen, conflicts with ViewProps type but codegen needs it interface NativeProps extends ViewProps { exclusive?: WithDefault<boolean, true>; foreground?: boolean; borderless?: boolean; enabled?: WithDefault<boolean, true>; rippleColor?: ColorValue; rippleRadius?: Int32; touchSoundDisabled?: WithDefault<boolean, false>; borderWidth?: Float; borderColor?: ColorValue; borderStyle?: WithDefault<string, 'solid'>; pointerEvents?: WithDefault< 'box-none' | 'none' | 'box-only' | 'auto', 'auto' >; } export default codegenNativeComponent<NativeProps>('RNGestureHandlerButton');