react-native-gesture-handler 2.27.0 → 2.27.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/ActionType.js +15 -0
- package/lib/commonjs/ActionType.js.map +1 -0
- package/lib/commonjs/Directions.js +31 -0
- package/lib/commonjs/Directions.js.map +1 -0
- package/lib/commonjs/EnableNewWebImplementation.js +40 -0
- package/lib/commonjs/EnableNewWebImplementation.js.map +1 -0
- package/lib/commonjs/GestureHandlerRootViewContext.js +10 -0
- package/lib/commonjs/GestureHandlerRootViewContext.js.map +1 -0
- package/lib/commonjs/PlatformConstants.js +9 -0
- package/lib/commonjs/PlatformConstants.js.map +1 -0
- package/lib/commonjs/PlatformConstants.web.js +12 -0
- package/lib/commonjs/PlatformConstants.web.js.map +1 -0
- package/lib/commonjs/PointerType.js +15 -0
- package/lib/commonjs/PointerType.js.map +1 -0
- package/lib/commonjs/RNGestureHandlerModule.js +12 -0
- package/lib/commonjs/RNGestureHandlerModule.js.map +1 -0
- package/lib/commonjs/RNGestureHandlerModule.web.js +95 -0
- package/lib/commonjs/RNGestureHandlerModule.web.js.map +1 -0
- package/lib/commonjs/RNGestureHandlerModule.windows.js +56 -0
- package/lib/commonjs/RNGestureHandlerModule.windows.js.map +1 -0
- package/lib/commonjs/RNRenderer.js +14 -0
- package/lib/commonjs/RNRenderer.js.map +1 -0
- package/lib/commonjs/RNRenderer.web.js +10 -0
- package/lib/commonjs/RNRenderer.web.js.map +1 -0
- package/lib/commonjs/State.js +19 -0
- package/lib/commonjs/State.js.map +1 -0
- package/lib/commonjs/TouchEventType.js +16 -0
- package/lib/commonjs/TouchEventType.js.map +1 -0
- package/lib/commonjs/components/DrawerLayout.js +548 -0
- package/lib/commonjs/components/DrawerLayout.js.map +1 -0
- package/lib/commonjs/components/GestureButtons.js +211 -0
- package/lib/commonjs/components/GestureButtons.js.map +1 -0
- package/lib/commonjs/components/GestureButtonsProps.js +6 -0
- package/lib/commonjs/components/GestureButtonsProps.js.map +1 -0
- package/lib/commonjs/components/GestureComponents.js +106 -0
- package/lib/commonjs/components/GestureComponents.js.map +1 -0
- package/lib/commonjs/components/GestureComponents.web.js +39 -0
- package/lib/commonjs/components/GestureComponents.web.js.map +1 -0
- package/lib/commonjs/components/GestureHandlerButton.js +10 -0
- package/lib/commonjs/components/GestureHandlerButton.js.map +1 -0
- package/lib/commonjs/components/GestureHandlerButton.web.js +16 -0
- package/lib/commonjs/components/GestureHandlerButton.web.js.map +1 -0
- package/lib/commonjs/components/GestureHandlerRootView.android.js +36 -0
- package/lib/commonjs/components/GestureHandlerRootView.android.js.map +1 -0
- package/lib/commonjs/components/GestureHandlerRootView.js +35 -0
- package/lib/commonjs/components/GestureHandlerRootView.js.map +1 -0
- package/lib/commonjs/components/GestureHandlerRootView.web.js +30 -0
- package/lib/commonjs/components/GestureHandlerRootView.web.js.map +1 -0
- package/lib/commonjs/components/Pressable/Pressable.js +275 -0
- package/lib/commonjs/components/Pressable/Pressable.js.map +1 -0
- package/lib/commonjs/components/Pressable/PressableProps.js +6 -0
- package/lib/commonjs/components/Pressable/PressableProps.js.map +1 -0
- package/lib/commonjs/components/Pressable/StateMachine.js +38 -0
- package/lib/commonjs/components/Pressable/StateMachine.js.map +1 -0
- package/lib/commonjs/components/Pressable/index.js +14 -0
- package/lib/commonjs/components/Pressable/index.js.map +1 -0
- package/lib/commonjs/components/Pressable/stateDefinitions.js +88 -0
- package/lib/commonjs/components/Pressable/stateDefinitions.js.map +1 -0
- package/lib/commonjs/components/Pressable/utils.js +92 -0
- package/lib/commonjs/components/Pressable/utils.js.map +1 -0
- package/lib/commonjs/components/ReanimatedDrawerLayout.js +357 -0
- package/lib/commonjs/components/ReanimatedDrawerLayout.js.map +1 -0
- package/lib/commonjs/components/ReanimatedSwipeable.js +346 -0
- package/lib/commonjs/components/ReanimatedSwipeable.js.map +1 -0
- package/lib/commonjs/components/Swipeable.js +370 -0
- package/lib/commonjs/components/Swipeable.js.map +1 -0
- package/lib/commonjs/components/Text.js +60 -0
- package/lib/commonjs/components/Text.js.map +1 -0
- package/lib/commonjs/components/gestureHandlerRootHOC.js +34 -0
- package/lib/commonjs/components/gestureHandlerRootHOC.js.map +1 -0
- package/lib/commonjs/components/touchables/ExtraButtonProps.js +2 -0
- package/lib/commonjs/components/touchables/ExtraButtonProps.js.map +1 -0
- package/lib/commonjs/components/touchables/GenericTouchable.js +245 -0
- package/lib/commonjs/components/touchables/GenericTouchable.js.map +1 -0
- package/lib/commonjs/components/touchables/GenericTouchableProps.js +6 -0
- package/lib/commonjs/components/touchables/GenericTouchableProps.js.map +1 -0
- package/lib/commonjs/components/touchables/TouchableHighlight.js +93 -0
- package/lib/commonjs/components/touchables/TouchableHighlight.js.map +1 -0
- package/lib/commonjs/components/touchables/TouchableNativeFeedback.android.js +84 -0
- package/lib/commonjs/components/touchables/TouchableNativeFeedback.android.js.map +1 -0
- package/lib/commonjs/components/touchables/TouchableNativeFeedback.js +13 -0
- package/lib/commonjs/components/touchables/TouchableNativeFeedback.js.map +1 -0
- package/lib/commonjs/components/touchables/TouchableNativeFeedbackProps.js +6 -0
- package/lib/commonjs/components/touchables/TouchableNativeFeedbackProps.js.map +1 -0
- package/lib/commonjs/components/touchables/TouchableOpacity.js +65 -0
- package/lib/commonjs/components/touchables/TouchableOpacity.js.map +1 -0
- package/lib/commonjs/components/touchables/TouchableWithoutFeedback.js +33 -0
- package/lib/commonjs/components/touchables/TouchableWithoutFeedback.js.map +1 -0
- package/lib/commonjs/components/touchables/index.js +35 -0
- package/lib/commonjs/components/touchables/index.js.map +1 -0
- package/lib/commonjs/components/utils.js +17 -0
- package/lib/commonjs/components/utils.js.map +1 -0
- package/lib/commonjs/findNodeHandle.js +9 -0
- package/lib/commonjs/findNodeHandle.js.map +1 -0
- package/lib/commonjs/findNodeHandle.web.js +39 -0
- package/lib/commonjs/findNodeHandle.web.js.map +1 -0
- package/lib/commonjs/getShadowNodeFromRef.js +51 -0
- package/lib/commonjs/getShadowNodeFromRef.js.map +1 -0
- package/lib/commonjs/getShadowNodeFromRef.web.js +14 -0
- package/lib/commonjs/getShadowNodeFromRef.web.js.map +1 -0
- package/lib/commonjs/ghQueueMicrotask.js +10 -0
- package/lib/commonjs/ghQueueMicrotask.js.map +1 -0
- package/lib/commonjs/handlers/FlingGestureHandler.js +31 -0
- package/lib/commonjs/handlers/FlingGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/ForceTouchGestureHandler.js +46 -0
- package/lib/commonjs/handlers/ForceTouchGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/GestureHandlerEventPayload.js +6 -0
- package/lib/commonjs/handlers/GestureHandlerEventPayload.js.map +1 -0
- package/lib/commonjs/handlers/LongPressGestureHandler.js +33 -0
- package/lib/commonjs/handlers/LongPressGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/NativeViewGestureHandler.ts +59 -0
- package/lib/commonjs/handlers/PanGestureHandler.js +112 -0
- package/lib/commonjs/handlers/PanGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/PinchGestureHandler.js +29 -0
- package/lib/commonjs/handlers/PinchGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/PressabilityDebugView.js +13 -0
- package/lib/commonjs/handlers/PressabilityDebugView.js.map +1 -0
- package/lib/commonjs/handlers/PressabilityDebugView.web.js +11 -0
- package/lib/commonjs/handlers/PressabilityDebugView.web.js.map +1 -0
- package/lib/commonjs/handlers/RotationGestureHandler.js +29 -0
- package/lib/commonjs/handlers/RotationGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/TapGestureHandler.js +33 -0
- package/lib/commonjs/handlers/TapGestureHandler.js.map +1 -0
- package/lib/commonjs/handlers/createHandler.js +393 -0
- package/lib/commonjs/handlers/createHandler.js.map +1 -0
- package/lib/commonjs/handlers/createNativeWrapper.js +78 -0
- package/lib/commonjs/handlers/createNativeWrapper.js.map +1 -0
- package/lib/commonjs/handlers/customDirectEventTypes.js +13 -0
- package/lib/commonjs/handlers/customDirectEventTypes.js.map +1 -0
- package/lib/commonjs/handlers/customDirectEventTypes.web.js +10 -0
- package/lib/commonjs/handlers/customDirectEventTypes.web.js.map +1 -0
- package/lib/commonjs/handlers/gestureHandlerCommon.js +27 -0
- package/lib/commonjs/handlers/gestureHandlerCommon.js.map +1 -0
- package/lib/commonjs/handlers/gestureHandlerTypesCompat.js +6 -0
- package/lib/commonjs/handlers/gestureHandlerTypesCompat.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.js +32 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.web.js +41 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.web.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/attachHandlers.js +67 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/attachHandlers.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/dropHandlers.js +20 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/dropHandlers.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/index.js +125 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/index.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/needsToReattach.js +22 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/needsToReattach.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/types.js +6 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/types.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/updateHandlers.js +66 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/updateHandlers.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useAnimatedGesture.js +143 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useAnimatedGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useDetectorUpdater.js +47 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useDetectorUpdater.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useMountReactions.js +41 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useMountReactions.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useViewRefHandler.js +41 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/useViewRefHandler.js.map +1 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/utils.js +143 -0
- package/lib/commonjs/handlers/gestures/GestureDetector/utils.js.map +1 -0
- package/lib/commonjs/handlers/gestures/eventReceiver.js +106 -0
- package/lib/commonjs/handlers/gestures/eventReceiver.js.map +1 -0
- package/lib/commonjs/handlers/gestures/flingGesture.js +37 -0
- package/lib/commonjs/handlers/gestures/flingGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/forceTouchGesture.js +80 -0
- package/lib/commonjs/handlers/gestures/forceTouchGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/gesture.js +338 -0
- package/lib/commonjs/handlers/gestures/gesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/gestureComposition.js +90 -0
- package/lib/commonjs/handlers/gestures/gestureComposition.js.map +1 -0
- package/lib/commonjs/handlers/gestures/gestureObjects.js +132 -0
- package/lib/commonjs/handlers/gestures/gestureObjects.js.map +1 -0
- package/lib/commonjs/handlers/gestures/gestureStateManager.js +69 -0
- package/lib/commonjs/handlers/gestures/gestureStateManager.js.map +1 -0
- package/lib/commonjs/handlers/gestures/gestureStateManager.web.js +27 -0
- package/lib/commonjs/handlers/gestures/gestureStateManager.web.js.map +1 -0
- package/lib/commonjs/handlers/gestures/hoverGesture.js +57 -0
- package/lib/commonjs/handlers/gestures/hoverGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/longPressGesture.js +46 -0
- package/lib/commonjs/handlers/gestures/longPressGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/manualGesture.js +25 -0
- package/lib/commonjs/handlers/gestures/manualGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/nativeGesture.ts +33 -0
- package/lib/commonjs/handlers/gestures/panGesture.js +197 -0
- package/lib/commonjs/handlers/gestures/panGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/pinchGesture.js +38 -0
- package/lib/commonjs/handlers/gestures/pinchGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/reanimatedWrapper.js +29 -0
- package/lib/commonjs/handlers/gestures/reanimatedWrapper.js.map +1 -0
- package/lib/commonjs/handlers/gestures/rotationGesture.js +38 -0
- package/lib/commonjs/handlers/gestures/rotationGesture.js.map +1 -0
- package/lib/commonjs/handlers/gestures/tapGesture.js +87 -0
- package/lib/commonjs/handlers/gestures/tapGesture.js.map +1 -0
- package/lib/commonjs/handlers/getNextHandlerTag.js +11 -0
- package/lib/commonjs/handlers/getNextHandlerTag.js.map +1 -0
- package/lib/commonjs/handlers/handlersRegistry.js +50 -0
- package/lib/commonjs/handlers/handlersRegistry.js.map +1 -0
- package/lib/commonjs/handlers/utils.js +69 -0
- package/lib/commonjs/handlers/utils.js.map +1 -0
- package/lib/commonjs/index.js +269 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/init.js +25 -0
- package/lib/commonjs/init.js.map +1 -0
- package/lib/commonjs/jestUtils/index.js +19 -0
- package/lib/commonjs/jestUtils/index.js.map +1 -0
- package/lib/commonjs/jestUtils/jestUtils.js +316 -0
- package/lib/commonjs/jestUtils/jestUtils.js.map +1 -0
- package/lib/commonjs/mocks.js +73 -0
- package/lib/commonjs/mocks.js.map +1 -0
- package/lib/commonjs/mountRegistry.js +37 -0
- package/lib/commonjs/mountRegistry.js.map +1 -0
- package/lib/commonjs/package.json +1 -0
- package/lib/commonjs/specs/NativeRNGestureHandlerModule.ts +26 -0
- package/lib/commonjs/specs/RNGestureHandlerButtonNativeComponent.ts +22 -0
- package/lib/commonjs/specs/RNGestureHandlerRootViewNativeComponent.ts +6 -0
- package/lib/commonjs/typeUtils.js +2 -0
- package/lib/commonjs/typeUtils.js.map +1 -0
- package/lib/commonjs/utils.js +95 -0
- package/lib/commonjs/utils.js.map +1 -0
- package/lib/commonjs/web/Gestures.js +48 -0
- package/lib/commonjs/web/Gestures.js.map +1 -0
- package/lib/commonjs/web/constants.js +9 -0
- package/lib/commonjs/web/constants.js.map +1 -0
- package/lib/commonjs/web/detectors/RotationGestureDetector.js +124 -0
- package/lib/commonjs/web/detectors/RotationGestureDetector.js.map +1 -0
- package/lib/commonjs/web/detectors/ScaleGestureDetector.js +111 -0
- package/lib/commonjs/web/detectors/ScaleGestureDetector.js.map +1 -0
- package/lib/commonjs/web/handlers/FlingGestureHandler.js +143 -0
- package/lib/commonjs/web/handlers/FlingGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/GestureHandler.js +686 -0
- package/lib/commonjs/web/handlers/GestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/HoverGestureHandler.js +45 -0
- package/lib/commonjs/web/handlers/HoverGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/IGestureHandler.js +2 -0
- package/lib/commonjs/web/handlers/IGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/LongPressGestureHandler.js +146 -0
- package/lib/commonjs/web/handlers/LongPressGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/ManualGestureHandler.js +38 -0
- package/lib/commonjs/web/handlers/ManualGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/NativeViewGestureHandler.ts +175 -0
- package/lib/commonjs/web/handlers/PanGestureHandler.js +399 -0
- package/lib/commonjs/web/handlers/PanGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/PinchGestureHandler.js +122 -0
- package/lib/commonjs/web/handlers/PinchGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/RotationGestureHandler.js +129 -0
- package/lib/commonjs/web/handlers/RotationGestureHandler.js.map +1 -0
- package/lib/commonjs/web/handlers/TapGestureHandler.js +215 -0
- package/lib/commonjs/web/handlers/TapGestureHandler.js.map +1 -0
- package/lib/commonjs/web/interfaces.js +32 -0
- package/lib/commonjs/web/interfaces.js.map +1 -0
- package/lib/commonjs/web/tools/CircularBuffer.js +40 -0
- package/lib/commonjs/web/tools/CircularBuffer.js.map +1 -0
- package/lib/commonjs/web/tools/EventManager.js +94 -0
- package/lib/commonjs/web/tools/EventManager.js.map +1 -0
- package/lib/commonjs/web/tools/GestureHandlerDelegate.js +6 -0
- package/lib/commonjs/web/tools/GestureHandlerDelegate.js.map +1 -0
- package/lib/commonjs/web/tools/GestureHandlerOrchestrator.js +267 -0
- package/lib/commonjs/web/tools/GestureHandlerOrchestrator.js.map +1 -0
- package/lib/commonjs/web/tools/GestureHandlerWebDelegate.js +170 -0
- package/lib/commonjs/web/tools/GestureHandlerWebDelegate.js.map +1 -0
- package/lib/commonjs/web/tools/InteractionManager.js +96 -0
- package/lib/commonjs/web/tools/InteractionManager.js.map +1 -0
- package/lib/commonjs/web/tools/KeyboardEventManager.js +82 -0
- package/lib/commonjs/web/tools/KeyboardEventManager.js.map +1 -0
- package/lib/commonjs/web/tools/LeastSquareSolver.js +159 -0
- package/lib/commonjs/web/tools/LeastSquareSolver.js.map +1 -0
- package/lib/commonjs/web/tools/NodeManager.js +39 -0
- package/lib/commonjs/web/tools/NodeManager.js.map +1 -0
- package/lib/commonjs/web/tools/PointerEventManager.js +189 -0
- package/lib/commonjs/web/tools/PointerEventManager.js.map +1 -0
- package/lib/commonjs/web/tools/PointerTracker.js +192 -0
- package/lib/commonjs/web/tools/PointerTracker.js.map +1 -0
- package/lib/commonjs/web/tools/Vector.js +37 -0
- package/lib/commonjs/web/tools/Vector.js.map +1 -0
- package/lib/commonjs/web/tools/VelocityTracker.js +85 -0
- package/lib/commonjs/web/tools/VelocityTracker.js.map +1 -0
- package/lib/commonjs/web/tools/WheelEventManager.js +55 -0
- package/lib/commonjs/web/tools/WheelEventManager.js.map +1 -0
- package/lib/commonjs/web/utils.js +235 -0
- package/lib/commonjs/web/utils.js.map +1 -0
- package/lib/commonjs/web_hammer/DiscreteGestureHandler.js +93 -0
- package/lib/commonjs/web_hammer/DiscreteGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/DraggingGestureHandler.js +43 -0
- package/lib/commonjs/web_hammer/DraggingGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/Errors.js +13 -0
- package/lib/commonjs/web_hammer/Errors.js.map +1 -0
- package/lib/commonjs/web_hammer/FlingGestureHandler.js +139 -0
- package/lib/commonjs/web_hammer/FlingGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/GestureHandler.js +484 -0
- package/lib/commonjs/web_hammer/GestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/IndiscreteGestureHandler.js +45 -0
- package/lib/commonjs/web_hammer/IndiscreteGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/LongPressGestureHandler.js +57 -0
- package/lib/commonjs/web_hammer/LongPressGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/NativeViewGestureHandler.ts +47 -0
- package/lib/commonjs/web_hammer/NodeManager.js +41 -0
- package/lib/commonjs/web_hammer/NodeManager.js.map +1 -0
- package/lib/commonjs/web_hammer/PanGestureHandler.js +167 -0
- package/lib/commonjs/web_hammer/PanGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/PinchGestureHandler.js +31 -0
- package/lib/commonjs/web_hammer/PinchGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/PressGestureHandler.js +153 -0
- package/lib/commonjs/web_hammer/PressGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/RotationGestureHandler.js +32 -0
- package/lib/commonjs/web_hammer/RotationGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/TapGestureHandler.js +165 -0
- package/lib/commonjs/web_hammer/TapGestureHandler.js.map +1 -0
- package/lib/commonjs/web_hammer/constants.js +51 -0
- package/lib/commonjs/web_hammer/constants.js.map +1 -0
- package/lib/commonjs/web_hammer/utils.js +32 -0
- package/lib/commonjs/web_hammer/utils.js.map +1 -0
- package/lib/module/ActionType.js +11 -0
- package/lib/module/ActionType.js.map +1 -0
- package/lib/module/Directions.js +27 -0
- package/lib/module/Directions.js.map +1 -0
- package/lib/module/EnableNewWebImplementation.js +34 -0
- package/lib/module/EnableNewWebImplementation.js.map +1 -0
- package/lib/module/GestureHandlerRootViewContext.js +5 -0
- package/lib/module/GestureHandlerRootViewContext.js.map +1 -0
- package/lib/module/PlatformConstants.js +5 -0
- package/lib/module/PlatformConstants.js.map +1 -0
- package/lib/module/PlatformConstants.web.js +8 -0
- package/lib/module/PlatformConstants.web.js.map +1 -0
- package/lib/module/PointerType.js +11 -0
- package/lib/module/PointerType.js.map +1 -0
- package/lib/module/RNGestureHandlerModule.js +8 -0
- package/lib/module/RNGestureHandlerModule.js.map +1 -0
- package/lib/module/RNGestureHandlerModule.web.js +90 -0
- package/lib/module/RNGestureHandlerModule.web.js.map +1 -0
- package/lib/module/RNGestureHandlerModule.windows.js +50 -0
- package/lib/module/RNGestureHandlerModule.windows.js.map +1 -0
- package/lib/module/RNRenderer.js +6 -0
- package/lib/module/RNRenderer.js.map +1 -0
- package/lib/module/RNRenderer.web.js +6 -0
- package/lib/module/RNRenderer.web.js.map +1 -0
- package/lib/module/State.js +15 -0
- package/lib/module/State.js.map +1 -0
- package/lib/module/TouchEventType.js +12 -0
- package/lib/module/TouchEventType.js.map +1 -0
- package/lib/module/components/DrawerLayout.js +541 -0
- package/lib/module/components/DrawerLayout.js.map +1 -0
- package/lib/module/components/GestureButtons.js +199 -0
- package/lib/module/components/GestureButtons.js.map +1 -0
- package/lib/module/components/GestureButtonsProps.js +4 -0
- package/lib/module/components/GestureButtonsProps.js.map +1 -0
- package/lib/module/components/GestureComponents.js +100 -0
- package/lib/module/components/GestureComponents.js.map +1 -0
- package/lib/module/components/GestureComponents.web.js +32 -0
- package/lib/module/components/GestureComponents.web.js.map +1 -0
- package/lib/module/components/GestureHandlerButton.js +5 -0
- package/lib/module/components/GestureHandlerButton.js.map +1 -0
- package/lib/module/components/GestureHandlerButton.web.js +11 -0
- package/lib/module/components/GestureHandlerButton.web.js.map +1 -0
- package/lib/module/components/GestureHandlerRootView.android.js +30 -0
- package/lib/module/components/GestureHandlerRootView.android.js.map +1 -0
- package/lib/module/components/GestureHandlerRootView.js +29 -0
- package/lib/module/components/GestureHandlerRootView.js.map +1 -0
- package/lib/module/components/GestureHandlerRootView.web.js +24 -0
- package/lib/module/components/GestureHandlerRootView.web.js.map +1 -0
- package/lib/module/components/Pressable/Pressable.js +269 -0
- package/lib/module/components/Pressable/Pressable.js.map +1 -0
- package/lib/module/components/Pressable/PressableProps.js +4 -0
- package/lib/module/components/Pressable/PressableProps.js.map +1 -0
- package/lib/module/components/Pressable/StateMachine.js +34 -0
- package/lib/module/components/Pressable/StateMachine.js.map +1 -0
- package/lib/module/components/Pressable/index.js +4 -0
- package/lib/module/components/Pressable/index.js.map +1 -0
- package/lib/module/components/Pressable/stateDefinitions.js +83 -0
- package/lib/module/components/Pressable/stateDefinitions.js.map +1 -0
- package/lib/module/components/Pressable/utils.js +84 -0
- package/lib/module/components/Pressable/utils.js.map +1 -0
- package/lib/module/components/ReanimatedDrawerLayout.js +352 -0
- package/lib/module/components/ReanimatedDrawerLayout.js.map +1 -0
- package/lib/module/components/ReanimatedSwipeable.js +341 -0
- package/lib/module/components/ReanimatedSwipeable.js.map +1 -0
- package/lib/module/components/Swipeable.js +364 -0
- package/lib/module/components/Swipeable.js.map +1 -0
- package/lib/module/components/Text.js +55 -0
- package/lib/module/components/Text.js.map +1 -0
- package/lib/module/components/gestureHandlerRootHOC.js +28 -0
- package/lib/module/components/gestureHandlerRootHOC.js.map +1 -0
- package/lib/module/components/touchables/ExtraButtonProps.js +2 -0
- package/lib/module/components/touchables/ExtraButtonProps.js.map +1 -0
- package/lib/module/components/touchables/GenericTouchable.js +239 -0
- package/lib/module/components/touchables/GenericTouchable.js.map +1 -0
- package/lib/module/components/touchables/GenericTouchableProps.js +4 -0
- package/lib/module/components/touchables/GenericTouchableProps.js.map +1 -0
- package/lib/module/components/touchables/TouchableHighlight.js +87 -0
- package/lib/module/components/touchables/TouchableHighlight.js.map +1 -0
- package/lib/module/components/touchables/TouchableNativeFeedback.android.js +77 -0
- package/lib/module/components/touchables/TouchableNativeFeedback.android.js.map +1 -0
- package/lib/module/components/touchables/TouchableNativeFeedback.js +10 -0
- package/lib/module/components/touchables/TouchableNativeFeedback.js.map +1 -0
- package/lib/module/components/touchables/TouchableNativeFeedbackProps.js +4 -0
- package/lib/module/components/touchables/TouchableNativeFeedbackProps.js.map +1 -0
- package/lib/module/components/touchables/TouchableOpacity.js +59 -0
- package/lib/module/components/touchables/TouchableOpacity.js.map +1 -0
- package/lib/module/components/touchables/TouchableWithoutFeedback.js +27 -0
- package/lib/module/components/touchables/TouchableWithoutFeedback.js.map +1 -0
- package/lib/module/components/touchables/index.js +7 -0
- package/lib/module/components/touchables/index.js.map +1 -0
- package/lib/module/components/utils.js +13 -0
- package/lib/module/components/utils.js.map +1 -0
- package/lib/module/findNodeHandle.js +5 -0
- package/lib/module/findNodeHandle.js.map +1 -0
- package/lib/module/findNodeHandle.web.js +35 -0
- package/lib/module/findNodeHandle.web.js.map +1 -0
- package/lib/module/getShadowNodeFromRef.js +47 -0
- package/lib/module/getShadowNodeFromRef.js.map +1 -0
- package/lib/module/getShadowNodeFromRef.web.js +10 -0
- package/lib/module/getShadowNodeFromRef.web.js.map +1 -0
- package/lib/module/ghQueueMicrotask.js +6 -0
- package/lib/module/ghQueueMicrotask.js.map +1 -0
- package/lib/module/handlers/FlingGestureHandler.js +26 -0
- package/lib/module/handlers/FlingGestureHandler.js.map +1 -0
- package/lib/module/handlers/ForceTouchGestureHandler.js +41 -0
- package/lib/module/handlers/ForceTouchGestureHandler.js.map +1 -0
- package/lib/module/handlers/GestureHandlerEventPayload.js +4 -0
- package/lib/module/handlers/GestureHandlerEventPayload.js.map +1 -0
- package/lib/module/handlers/LongPressGestureHandler.js +28 -0
- package/lib/module/handlers/LongPressGestureHandler.js.map +1 -0
- package/lib/module/handlers/NativeViewGestureHandler.ts +59 -0
- package/lib/module/handlers/PanGestureHandler.js +105 -0
- package/lib/module/handlers/PanGestureHandler.js.map +1 -0
- package/lib/module/handlers/PinchGestureHandler.js +25 -0
- package/lib/module/handlers/PinchGestureHandler.js.map +1 -0
- package/lib/module/handlers/PressabilityDebugView.js +5 -0
- package/lib/module/handlers/PressabilityDebugView.js.map +1 -0
- package/lib/module/handlers/PressabilityDebugView.web.js +7 -0
- package/lib/module/handlers/PressabilityDebugView.web.js.map +1 -0
- package/lib/module/handlers/RotationGestureHandler.js +25 -0
- package/lib/module/handlers/RotationGestureHandler.js.map +1 -0
- package/lib/module/handlers/TapGestureHandler.js +28 -0
- package/lib/module/handlers/TapGestureHandler.js.map +1 -0
- package/lib/module/handlers/createHandler.js +387 -0
- package/lib/module/handlers/createHandler.js.map +1 -0
- package/lib/module/handlers/createNativeWrapper.js +75 -0
- package/lib/module/handlers/createNativeWrapper.js.map +1 -0
- package/lib/module/handlers/customDirectEventTypes.js +5 -0
- package/lib/module/handlers/customDirectEventTypes.js.map +1 -0
- package/lib/module/handlers/customDirectEventTypes.web.js +7 -0
- package/lib/module/handlers/customDirectEventTypes.web.js.map +1 -0
- package/lib/module/handlers/gestureHandlerCommon.js +26 -0
- package/lib/module/handlers/gestureHandlerCommon.js.map +1 -0
- package/lib/module/handlers/gestureHandlerTypesCompat.js +4 -0
- package/lib/module/handlers/gestureHandlerTypesCompat.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/Wrap.js +26 -0
- package/lib/module/handlers/gestures/GestureDetector/Wrap.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/Wrap.web.js +36 -0
- package/lib/module/handlers/gestures/GestureDetector/Wrap.web.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/attachHandlers.js +62 -0
- package/lib/module/handlers/gestures/GestureDetector/attachHandlers.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/dropHandlers.js +15 -0
- package/lib/module/handlers/gestures/GestureDetector/dropHandlers.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/index.js +117 -0
- package/lib/module/handlers/gestures/GestureDetector/index.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/needsToReattach.js +18 -0
- package/lib/module/handlers/gestures/GestureDetector/needsToReattach.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/types.js +4 -0
- package/lib/module/handlers/gestures/GestureDetector/types.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/updateHandlers.js +61 -0
- package/lib/module/handlers/gestures/GestureDetector/updateHandlers.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/useAnimatedGesture.js +139 -0
- package/lib/module/handlers/gestures/GestureDetector/useAnimatedGesture.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/useDetectorUpdater.js +43 -0
- package/lib/module/handlers/gestures/GestureDetector/useDetectorUpdater.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/useMountReactions.js +37 -0
- package/lib/module/handlers/gestures/GestureDetector/useMountReactions.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/useViewRefHandler.js +36 -0
- package/lib/module/handlers/gestures/GestureDetector/useViewRefHandler.js.map +1 -0
- package/lib/module/handlers/gestures/GestureDetector/utils.js +134 -0
- package/lib/module/handlers/gestures/GestureDetector/utils.js.map +1 -0
- package/lib/module/handlers/gestures/eventReceiver.js +100 -0
- package/lib/module/handlers/gestures/eventReceiver.js.map +1 -0
- package/lib/module/handlers/gestures/flingGesture.js +32 -0
- package/lib/module/handlers/gestures/flingGesture.js.map +1 -0
- package/lib/module/handlers/gestures/forceTouchGesture.js +76 -0
- package/lib/module/handlers/gestures/forceTouchGesture.js.map +1 -0
- package/lib/module/handlers/gestures/gesture.js +332 -0
- package/lib/module/handlers/gestures/gesture.js.map +1 -0
- package/lib/module/handlers/gestures/gestureComposition.js +83 -0
- package/lib/module/handlers/gestures/gestureComposition.js.map +1 -0
- package/lib/module/handlers/gestures/gestureObjects.js +129 -0
- package/lib/module/handlers/gestures/gestureObjects.js.map +1 -0
- package/lib/module/handlers/gestures/gestureStateManager.js +65 -0
- package/lib/module/handlers/gestures/gestureStateManager.js.map +1 -0
- package/lib/module/handlers/gestures/gestureStateManager.web.js +22 -0
- package/lib/module/handlers/gestures/gestureStateManager.web.js.map +1 -0
- package/lib/module/handlers/gestures/hoverGesture.js +52 -0
- package/lib/module/handlers/gestures/hoverGesture.js.map +1 -0
- package/lib/module/handlers/gestures/longPressGesture.js +41 -0
- package/lib/module/handlers/gestures/longPressGesture.js.map +1 -0
- package/lib/module/handlers/gestures/manualGesture.js +20 -0
- package/lib/module/handlers/gestures/manualGesture.js.map +1 -0
- package/lib/module/handlers/gestures/nativeGesture.ts +33 -0
- package/lib/module/handlers/gestures/panGesture.js +192 -0
- package/lib/module/handlers/gestures/panGesture.js.map +1 -0
- package/lib/module/handlers/gestures/pinchGesture.js +33 -0
- package/lib/module/handlers/gestures/pinchGesture.js.map +1 -0
- package/lib/module/handlers/gestures/reanimatedWrapper.js +26 -0
- package/lib/module/handlers/gestures/reanimatedWrapper.js.map +1 -0
- package/lib/module/handlers/gestures/rotationGesture.js +33 -0
- package/lib/module/handlers/gestures/rotationGesture.js.map +1 -0
- package/lib/module/handlers/gestures/tapGesture.js +82 -0
- package/lib/module/handlers/gestures/tapGesture.js.map +1 -0
- package/lib/module/handlers/getNextHandlerTag.js +7 -0
- package/lib/module/handlers/getNextHandlerTag.js.map +1 -0
- package/lib/module/handlers/handlersRegistry.js +39 -0
- package/lib/module/handlers/handlersRegistry.js.map +1 -0
- package/lib/module/handlers/utils.js +61 -0
- package/lib/module/handlers/utils.js.map +1 -0
- package/lib/module/index.js +31 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/init.js +19 -0
- package/lib/module/init.js.map +1 -0
- package/lib/module/jestUtils/index.js +4 -0
- package/lib/module/jestUtils/index.js.map +1 -0
- package/lib/module/jestUtils/jestUtils.js +311 -0
- package/lib/module/jestUtils/jestUtils.js.map +1 -0
- package/lib/module/mocks.js +68 -0
- package/lib/module/mocks.js.map +1 -0
- package/lib/module/mountRegistry.js +32 -0
- package/lib/module/mountRegistry.js.map +1 -0
- package/lib/module/specs/NativeRNGestureHandlerModule.ts +26 -0
- package/lib/module/specs/RNGestureHandlerButtonNativeComponent.ts +22 -0
- package/lib/module/specs/RNGestureHandlerRootViewNativeComponent.ts +6 -0
- package/lib/module/typeUtils.js +2 -0
- package/lib/module/typeUtils.js.map +1 -0
- package/lib/module/utils.js +81 -0
- package/lib/module/utils.js.map +1 -0
- package/lib/module/web/Gestures.js +42 -0
- package/lib/module/web/Gestures.js.map +1 -0
- package/lib/module/web/constants.js +5 -0
- package/lib/module/web/constants.js.map +1 -0
- package/lib/module/web/detectors/RotationGestureDetector.js +119 -0
- package/lib/module/web/detectors/RotationGestureDetector.js.map +1 -0
- package/lib/module/web/detectors/ScaleGestureDetector.js +106 -0
- package/lib/module/web/detectors/ScaleGestureDetector.js.map +1 -0
- package/lib/module/web/handlers/FlingGestureHandler.js +137 -0
- package/lib/module/web/handlers/FlingGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/GestureHandler.js +679 -0
- package/lib/module/web/handlers/GestureHandler.js.map +1 -0
- package/lib/module/web/handlers/HoverGestureHandler.js +39 -0
- package/lib/module/web/handlers/HoverGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/IGestureHandler.js +2 -0
- package/lib/module/web/handlers/IGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/LongPressGestureHandler.js +140 -0
- package/lib/module/web/handlers/LongPressGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/ManualGestureHandler.js +32 -0
- package/lib/module/web/handlers/ManualGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/NativeViewGestureHandler.ts +175 -0
- package/lib/module/web/handlers/PanGestureHandler.js +393 -0
- package/lib/module/web/handlers/PanGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/PinchGestureHandler.js +116 -0
- package/lib/module/web/handlers/PinchGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/RotationGestureHandler.js +123 -0
- package/lib/module/web/handlers/RotationGestureHandler.js.map +1 -0
- package/lib/module/web/handlers/TapGestureHandler.js +209 -0
- package/lib/module/web/handlers/TapGestureHandler.js.map +1 -0
- package/lib/module/web/interfaces.js +28 -0
- package/lib/module/web/interfaces.js.map +1 -0
- package/lib/module/web/tools/CircularBuffer.js +35 -0
- package/lib/module/web/tools/CircularBuffer.js.map +1 -0
- package/lib/module/web/tools/EventManager.js +89 -0
- package/lib/module/web/tools/EventManager.js.map +1 -0
- package/lib/module/web/tools/GestureHandlerDelegate.js +4 -0
- package/lib/module/web/tools/GestureHandlerDelegate.js.map +1 -0
- package/lib/module/web/tools/GestureHandlerOrchestrator.js +261 -0
- package/lib/module/web/tools/GestureHandlerOrchestrator.js.map +1 -0
- package/lib/module/web/tools/GestureHandlerWebDelegate.js +164 -0
- package/lib/module/web/tools/GestureHandlerWebDelegate.js.map +1 -0
- package/lib/module/web/tools/InteractionManager.js +91 -0
- package/lib/module/web/tools/InteractionManager.js.map +1 -0
- package/lib/module/web/tools/KeyboardEventManager.js +76 -0
- package/lib/module/web/tools/KeyboardEventManager.js.map +1 -0
- package/lib/module/web/tools/LeastSquareSolver.js +154 -0
- package/lib/module/web/tools/LeastSquareSolver.js.map +1 -0
- package/lib/module/web/tools/NodeManager.js +34 -0
- package/lib/module/web/tools/NodeManager.js.map +1 -0
- package/lib/module/web/tools/PointerEventManager.js +183 -0
- package/lib/module/web/tools/PointerEventManager.js.map +1 -0
- package/lib/module/web/tools/PointerTracker.js +186 -0
- package/lib/module/web/tools/PointerTracker.js.map +1 -0
- package/lib/module/web/tools/Vector.js +32 -0
- package/lib/module/web/tools/Vector.js.map +1 -0
- package/lib/module/web/tools/VelocityTracker.js +79 -0
- package/lib/module/web/tools/VelocityTracker.js.map +1 -0
- package/lib/module/web/tools/WheelEventManager.js +49 -0
- package/lib/module/web/tools/WheelEventManager.js.map +1 -0
- package/lib/module/web/utils.js +223 -0
- package/lib/module/web/utils.js.map +1 -0
- package/lib/module/web_hammer/DiscreteGestureHandler.js +87 -0
- package/lib/module/web_hammer/DiscreteGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/DraggingGestureHandler.js +37 -0
- package/lib/module/web_hammer/DraggingGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/Errors.js +8 -0
- package/lib/module/web_hammer/Errors.js.map +1 -0
- package/lib/module/web_hammer/FlingGestureHandler.js +133 -0
- package/lib/module/web_hammer/FlingGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/GestureHandler.js +478 -0
- package/lib/module/web_hammer/GestureHandler.js.map +1 -0
- package/lib/module/web_hammer/IndiscreteGestureHandler.js +41 -0
- package/lib/module/web_hammer/IndiscreteGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/LongPressGestureHandler.js +51 -0
- package/lib/module/web_hammer/LongPressGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/NativeViewGestureHandler.ts +47 -0
- package/lib/module/web_hammer/NodeManager.js +33 -0
- package/lib/module/web_hammer/NodeManager.js.map +1 -0
- package/lib/module/web_hammer/PanGestureHandler.js +162 -0
- package/lib/module/web_hammer/PanGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/PinchGestureHandler.js +26 -0
- package/lib/module/web_hammer/PinchGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/PressGestureHandler.js +148 -0
- package/lib/module/web_hammer/PressGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/RotationGestureHandler.js +27 -0
- package/lib/module/web_hammer/RotationGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/TapGestureHandler.js +160 -0
- package/lib/module/web_hammer/TapGestureHandler.js.map +1 -0
- package/lib/module/web_hammer/constants.js +46 -0
- package/lib/module/web_hammer/constants.js.map +1 -0
- package/lib/module/web_hammer/utils.js +21 -0
- package/lib/module/web_hammer/utils.js.map +1 -0
- package/lib/typescript/ActionType.d.ts +7 -0
- package/lib/typescript/ActionType.d.ts.map +1 -0
- package/lib/typescript/ActionType.js +6 -0
- package/lib/typescript/Directions.d.ts +14 -0
- package/lib/typescript/Directions.d.ts.map +1 -0
- package/lib/typescript/Directions.js +18 -0
- package/lib/typescript/EnableNewWebImplementation.d.ts +9 -0
- package/lib/typescript/EnableNewWebImplementation.d.ts.map +1 -0
- package/lib/typescript/EnableNewWebImplementation.js +30 -0
- package/lib/typescript/GestureHandlerRootViewContext.d.ts +3 -0
- package/lib/typescript/GestureHandlerRootViewContext.d.ts.map +1 -0
- package/lib/typescript/GestureHandlerRootViewContext.js +2 -0
- package/lib/typescript/PlatformConstants.d.ts +5 -0
- package/lib/typescript/PlatformConstants.d.ts.map +1 -0
- package/lib/typescript/PlatformConstants.js +3 -0
- package/lib/typescript/PlatformConstants.web.d.ts +4 -0
- package/lib/typescript/PlatformConstants.web.d.ts.map +1 -0
- package/lib/typescript/PlatformConstants.web.js +5 -0
- package/lib/typescript/PointerType.d.ts +7 -0
- package/lib/typescript/PointerType.d.ts.map +1 -0
- package/lib/typescript/PointerType.js +8 -0
- package/lib/typescript/RNGestureHandlerModule.d.ts +2 -0
- package/lib/typescript/RNGestureHandlerModule.d.ts.map +1 -0
- package/lib/typescript/RNGestureHandlerModule.js +4 -0
- package/lib/typescript/RNGestureHandlerModule.web.d.ts +15 -0
- package/lib/typescript/RNGestureHandlerModule.web.d.ts.map +1 -0
- package/lib/typescript/RNGestureHandlerModule.web.js +92 -0
- package/lib/typescript/RNGestureHandlerModule.windows.d.ts +32 -0
- package/lib/typescript/RNGestureHandlerModule.windows.d.ts.map +1 -0
- package/lib/typescript/RNGestureHandlerModule.windows.js +47 -0
- package/lib/typescript/RNRenderer.d.ts +1 -0
- package/lib/typescript/RNRenderer.d.ts.map +1 -0
- package/lib/typescript/RNRenderer.js +3 -0
- package/lib/typescript/RNRenderer.web.d.ts +3 -0
- package/lib/typescript/RNRenderer.web.d.ts.map +1 -0
- package/lib/typescript/RNRenderer.web.js +3 -0
- package/lib/typescript/State.d.ts +9 -0
- package/lib/typescript/State.d.ts.map +1 -0
- package/lib/typescript/State.js +9 -0
- package/lib/typescript/TouchEventType.d.ts +8 -0
- package/lib/typescript/TouchEventType.d.ts.map +1 -0
- package/lib/typescript/TouchEventType.js +7 -0
- package/lib/typescript/components/DrawerLayout.d.ts +185 -0
- package/lib/typescript/components/DrawerLayout.d.ts.map +1 -0
- package/lib/typescript/components/DrawerLayout.js +417 -0
- package/lib/typescript/components/GestureButtons.d.ts +7 -0
- package/lib/typescript/components/GestureButtons.d.ts.map +1 -0
- package/lib/typescript/components/GestureButtons.js +165 -0
- package/lib/typescript/components/GestureButtonsProps.d.ts +115 -0
- package/lib/typescript/components/GestureButtonsProps.d.ts.map +1 -0
- package/lib/typescript/components/GestureButtonsProps.js +1 -0
- package/lib/typescript/components/GestureComponents.d.ts +22 -0
- package/lib/typescript/components/GestureComponents.d.ts.map +1 -0
- package/lib/typescript/components/GestureComponents.js +67 -0
- package/lib/typescript/components/GestureComponents.web.d.ts +8 -0
- package/lib/typescript/components/GestureComponents.web.d.ts.map +1 -0
- package/lib/typescript/components/GestureComponents.web.js +21 -0
- package/lib/typescript/components/GestureHandlerButton.d.ts +4 -0
- package/lib/typescript/components/GestureHandlerButton.d.ts.map +1 -0
- package/lib/typescript/components/GestureHandlerButton.js +2 -0
- package/lib/typescript/components/GestureHandlerButton.web.d.ts +4 -0
- package/lib/typescript/components/GestureHandlerButton.web.d.ts.map +1 -0
- package/lib/typescript/components/GestureHandlerButton.web.js +3 -0
- package/lib/typescript/components/GestureHandlerRootView.android.d.ts +6 -0
- package/lib/typescript/components/GestureHandlerRootView.android.d.ts.map +1 -0
- package/lib/typescript/components/GestureHandlerRootView.android.js +17 -0
- package/lib/typescript/components/GestureHandlerRootView.d.ts +6 -0
- package/lib/typescript/components/GestureHandlerRootView.d.ts.map +1 -0
- package/lib/typescript/components/GestureHandlerRootView.js +16 -0
- package/lib/typescript/components/GestureHandlerRootView.web.d.ts +6 -0
- package/lib/typescript/components/GestureHandlerRootView.web.d.ts.map +1 -0
- package/lib/typescript/components/GestureHandlerRootView.web.js +11 -0
- package/lib/typescript/components/Pressable/Pressable.d.ts +4 -0
- package/lib/typescript/components/Pressable/Pressable.d.ts.map +1 -0
- package/lib/typescript/components/Pressable/Pressable.js +231 -0
- package/lib/typescript/components/Pressable/PressableProps.d.ts +138 -0
- package/lib/typescript/components/Pressable/PressableProps.d.ts.map +1 -0
- package/lib/typescript/components/Pressable/PressableProps.js +1 -0
- package/lib/typescript/components/Pressable/StateMachine.d.ts +14 -0
- package/lib/typescript/components/Pressable/StateMachine.d.ts.map +1 -0
- package/lib/typescript/components/Pressable/StateMachine.js +34 -0
- package/lib/typescript/components/Pressable/index.d.ts +2 -0
- package/lib/typescript/components/Pressable/index.d.ts.map +1 -0
- package/lib/typescript/components/Pressable/index.js +1 -0
- package/lib/typescript/components/Pressable/stateDefinitions.d.ts +9 -0
- package/lib/typescript/components/Pressable/stateDefinitions.d.ts.map +1 -0
- package/lib/typescript/components/Pressable/stateDefinitions.js +104 -0
- package/lib/typescript/components/Pressable/utils.d.ts +10 -0
- package/lib/typescript/components/Pressable/utils.d.ts.map +1 -0
- package/lib/typescript/components/Pressable/utils.js +80 -0
- package/lib/typescript/components/ReanimatedDrawerLayout.d.ts +167 -0
- package/lib/typescript/components/ReanimatedDrawerLayout.d.ts.map +1 -0
- package/lib/typescript/components/ReanimatedDrawerLayout.js +364 -0
- package/lib/typescript/components/ReanimatedSwipeable.d.ts +147 -0
- package/lib/typescript/components/ReanimatedSwipeable.d.ts.map +1 -0
- package/lib/typescript/components/ReanimatedSwipeable.js +400 -0
- package/lib/typescript/components/Swipeable.d.ts +183 -0
- package/lib/typescript/components/Swipeable.d.ts.map +1 -0
- package/lib/typescript/components/Swipeable.js +287 -0
- package/lib/typescript/components/Text.d.ts +4 -0
- package/lib/typescript/components/Text.d.ts.map +1 -0
- package/lib/typescript/components/Text.js +38 -0
- package/lib/typescript/components/gestureHandlerRootHOC.d.ts +3 -0
- package/lib/typescript/components/gestureHandlerRootHOC.d.ts.map +1 -0
- package/lib/typescript/components/gestureHandlerRootHOC.js +18 -0
- package/lib/typescript/components/touchables/ExtraButtonProps.d.ts +7 -0
- package/lib/typescript/components/touchables/ExtraButtonProps.d.ts.map +1 -0
- package/lib/typescript/components/touchables/ExtraButtonProps.js +1 -0
- package/lib/typescript/components/touchables/GenericTouchable.d.ts +55 -0
- package/lib/typescript/components/touchables/GenericTouchable.d.ts.map +1 -0
- package/lib/typescript/components/touchables/GenericTouchable.js +221 -0
- package/lib/typescript/components/touchables/GenericTouchableProps.d.ts +16 -0
- package/lib/typescript/components/touchables/GenericTouchableProps.d.ts.map +1 -0
- package/lib/typescript/components/touchables/GenericTouchableProps.js +1 -0
- package/lib/typescript/components/touchables/TouchableHighlight.d.ts +41 -0
- package/lib/typescript/components/touchables/TouchableHighlight.d.ts.map +1 -0
- package/lib/typescript/components/touchables/TouchableHighlight.js +75 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedback.android.d.ts +40 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedback.android.d.ts.map +1 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedback.android.js +65 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedback.d.ts +6 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedback.d.ts.map +1 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedback.js +6 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedbackProps.d.ts +8 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedbackProps.d.ts.map +1 -0
- package/lib/typescript/components/touchables/TouchableNativeFeedbackProps.js +1 -0
- package/lib/typescript/components/touchables/TouchableOpacity.d.ts +30 -0
- package/lib/typescript/components/touchables/TouchableOpacity.d.ts.map +1 -0
- package/lib/typescript/components/touchables/TouchableOpacity.js +51 -0
- package/lib/typescript/components/touchables/TouchableWithoutFeedback.d.ts +14 -0
- package/lib/typescript/components/touchables/TouchableWithoutFeedback.d.ts.map +1 -0
- package/lib/typescript/components/touchables/TouchableWithoutFeedback.js +10 -0
- package/lib/typescript/components/touchables/index.d.ts +7 -0
- package/lib/typescript/components/touchables/index.d.ts.map +1 -0
- package/lib/typescript/components/touchables/index.js +4 -0
- package/lib/typescript/components/utils.d.ts +4 -0
- package/lib/typescript/components/utils.d.ts.map +1 -0
- package/lib/typescript/components/utils.js +11 -0
- package/lib/typescript/findNodeHandle.d.ts +2 -0
- package/lib/typescript/findNodeHandle.d.ts.map +1 -0
- package/lib/typescript/findNodeHandle.js +2 -0
- package/lib/typescript/findNodeHandle.web.d.ts +2 -0
- package/lib/typescript/findNodeHandle.web.d.ts.map +1 -0
- package/lib/typescript/findNodeHandle.web.js +31 -0
- package/lib/typescript/getShadowNodeFromRef.d.ts +1 -0
- package/lib/typescript/getShadowNodeFromRef.d.ts.map +1 -0
- package/lib/typescript/getShadowNodeFromRef.js +45 -0
- package/lib/typescript/getShadowNodeFromRef.web.d.ts +1 -0
- package/lib/typescript/getShadowNodeFromRef.web.d.ts.map +1 -0
- package/lib/typescript/getShadowNodeFromRef.web.js +7 -0
- package/lib/typescript/ghQueueMicrotask.d.ts +1 -0
- package/lib/typescript/ghQueueMicrotask.d.ts.map +1 -0
- package/lib/typescript/ghQueueMicrotask.js +7 -0
- package/lib/typescript/handlers/FlingGestureHandler.d.ts +38 -0
- package/lib/typescript/handlers/FlingGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/FlingGestureHandler.js +19 -0
- package/lib/typescript/handlers/ForceTouchGestureHandler.d.ts +44 -0
- package/lib/typescript/handlers/ForceTouchGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/ForceTouchGestureHandler.js +37 -0
- package/lib/typescript/handlers/GestureHandlerEventPayload.d.ts +197 -0
- package/lib/typescript/handlers/GestureHandlerEventPayload.d.ts.map +1 -0
- package/lib/typescript/handlers/GestureHandlerEventPayload.js +1 -0
- package/lib/typescript/handlers/LongPressGestureHandler.d.ts +35 -0
- package/lib/typescript/handlers/LongPressGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/LongPressGestureHandler.js +22 -0
- package/lib/typescript/handlers/NativeViewGestureHandler.d.ts +32 -0
- package/lib/typescript/handlers/NativeViewGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/NativeViewGestureHandler.js +20 -0
- package/lib/typescript/handlers/PanGestureHandler.d.ts +99 -0
- package/lib/typescript/handlers/PanGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/PanGestureHandler.js +128 -0
- package/lib/typescript/handlers/PinchGestureHandler.d.ts +16 -0
- package/lib/typescript/handlers/PinchGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/PinchGestureHandler.js +12 -0
- package/lib/typescript/handlers/PressabilityDebugView.d.ts +1 -0
- package/lib/typescript/handlers/PressabilityDebugView.d.ts.map +1 -0
- package/lib/typescript/handlers/PressabilityDebugView.js +2 -0
- package/lib/typescript/handlers/PressabilityDebugView.web.d.ts +1 -0
- package/lib/typescript/handlers/PressabilityDebugView.web.d.ts.map +1 -0
- package/lib/typescript/handlers/PressabilityDebugView.web.js +4 -0
- package/lib/typescript/handlers/RotationGestureHandler.d.ts +16 -0
- package/lib/typescript/handlers/RotationGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/RotationGestureHandler.js +12 -0
- package/lib/typescript/handlers/TapGestureHandler.d.ts +61 -0
- package/lib/typescript/handlers/TapGestureHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/TapGestureHandler.js +26 -0
- package/lib/typescript/handlers/createHandler.d.ts +11 -0
- package/lib/typescript/handlers/createHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/createHandler.js +375 -0
- package/lib/typescript/handlers/createNativeWrapper.d.ts +3 -0
- package/lib/typescript/handlers/createNativeWrapper.d.ts.map +1 -0
- package/lib/typescript/handlers/createNativeWrapper.js +67 -0
- package/lib/typescript/handlers/customDirectEventTypes.d.ts +1 -0
- package/lib/typescript/handlers/customDirectEventTypes.d.ts.map +1 -0
- package/lib/typescript/handlers/customDirectEventTypes.js +2 -0
- package/lib/typescript/handlers/customDirectEventTypes.web.d.ts +2 -0
- package/lib/typescript/handlers/customDirectEventTypes.web.d.ts.map +1 -0
- package/lib/typescript/handlers/customDirectEventTypes.web.js +4 -0
- package/lib/typescript/handlers/gestureHandlerCommon.d.ts +78 -0
- package/lib/typescript/handlers/gestureHandlerCommon.d.ts.map +1 -0
- package/lib/typescript/handlers/gestureHandlerCommon.js +42 -0
- package/lib/typescript/handlers/gestureHandlerTypesCompat.d.ts +52 -0
- package/lib/typescript/handlers/gestureHandlerTypesCompat.d.ts.map +1 -0
- package/lib/typescript/handlers/gestureHandlerTypesCompat.js +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/Wrap.d.ts +13 -0
- package/lib/typescript/handlers/gestures/GestureDetector/Wrap.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/Wrap.js +22 -0
- package/lib/typescript/handlers/gestures/GestureDetector/Wrap.web.d.ts +7 -0
- package/lib/typescript/handlers/gestures/GestureDetector/Wrap.web.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/Wrap.web.js +24 -0
- package/lib/typescript/handlers/gestures/GestureDetector/attachHandlers.d.ts +13 -0
- package/lib/typescript/handlers/gestures/GestureDetector/attachHandlers.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/attachHandlers.js +55 -0
- package/lib/typescript/handlers/gestures/GestureDetector/dropHandlers.d.ts +2 -0
- package/lib/typescript/handlers/gestures/GestureDetector/dropHandlers.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/dropHandlers.js +12 -0
- package/lib/typescript/handlers/gestures/GestureDetector/index.d.ts +49 -0
- package/lib/typescript/handlers/gestures/GestureDetector/index.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/index.js +114 -0
- package/lib/typescript/handlers/gestures/GestureDetector/needsToReattach.d.ts +3 -0
- package/lib/typescript/handlers/gestures/GestureDetector/needsToReattach.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/needsToReattach.js +18 -0
- package/lib/typescript/handlers/gestures/GestureDetector/types.d.ts +20 -0
- package/lib/typescript/handlers/gestures/GestureDetector/types.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/types.js +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/updateHandlers.d.ts +4 -0
- package/lib/typescript/handlers/gestures/GestureDetector/updateHandlers.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/updateHandlers.js +54 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useAnimatedGesture.d.ts +2 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useAnimatedGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useAnimatedGesture.js +137 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useDetectorUpdater.d.ts +5 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useDetectorUpdater.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useDetectorUpdater.js +48 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useMountReactions.d.ts +2 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useMountReactions.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useMountReactions.js +35 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useViewRefHandler.d.ts +3 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useViewRefHandler.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/useViewRefHandler.js +32 -0
- package/lib/typescript/handlers/gestures/GestureDetector/utils.d.ts +12 -0
- package/lib/typescript/handlers/gestures/GestureDetector/utils.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/GestureDetector/utils.js +140 -0
- package/lib/typescript/handlers/gestures/eventReceiver.d.ts +4 -0
- package/lib/typescript/handlers/gestures/eventReceiver.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/eventReceiver.js +105 -0
- package/lib/typescript/handlers/gestures/flingGesture.d.ts +21 -0
- package/lib/typescript/handlers/gestures/flingGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/flingGesture.js +27 -0
- package/lib/typescript/handlers/gestures/forceTouchGesture.d.ts +39 -0
- package/lib/typescript/handlers/gestures/forceTouchGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/forceTouchGesture.js +57 -0
- package/lib/typescript/handlers/gestures/gesture.d.ts +217 -0
- package/lib/typescript/handlers/gestures/gesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/gesture.js +303 -0
- package/lib/typescript/handlers/gestures/gestureComposition.d.ts +21 -0
- package/lib/typescript/handlers/gestures/gestureComposition.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/gestureComposition.js +78 -0
- package/lib/typescript/handlers/gestures/gestureObjects.d.ts +100 -0
- package/lib/typescript/handlers/gestures/gestureObjects.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/gestureObjects.js +125 -0
- package/lib/typescript/handlers/gestures/gestureStateManager.d.ts +11 -0
- package/lib/typescript/handlers/gestures/gestureStateManager.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/gestureStateManager.js +60 -0
- package/lib/typescript/handlers/gestures/gestureStateManager.web.d.ts +4 -0
- package/lib/typescript/handlers/gestures/gestureStateManager.web.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/gestureStateManager.web.js +19 -0
- package/lib/typescript/handlers/gestures/hoverGesture.d.ts +27 -0
- package/lib/typescript/handlers/gestures/hoverGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/hoverGesture.js +45 -0
- package/lib/typescript/handlers/gestures/longPressGesture.d.ts +25 -0
- package/lib/typescript/handlers/gestures/longPressGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/longPressGesture.js +35 -0
- package/lib/typescript/handlers/gestures/manualGesture.d.ts +7 -0
- package/lib/typescript/handlers/gestures/manualGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/manualGesture.js +16 -0
- package/lib/typescript/handlers/gestures/nativeGesture.d.ts +18 -0
- package/lib/typescript/handlers/gestures/nativeGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/nativeGesture.js +24 -0
- package/lib/typescript/handlers/gestures/panGesture.d.ts +90 -0
- package/lib/typescript/handlers/gestures/panGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/panGesture.js +181 -0
- package/lib/typescript/handlers/gestures/pinchGesture.d.ts +11 -0
- package/lib/typescript/handlers/gestures/pinchGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/pinchGesture.js +27 -0
- package/lib/typescript/handlers/gestures/reanimatedWrapper.d.ts +14 -0
- package/lib/typescript/handlers/gestures/reanimatedWrapper.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/reanimatedWrapper.js +23 -0
- package/lib/typescript/handlers/gestures/rotationGesture.d.ts +12 -0
- package/lib/typescript/handlers/gestures/rotationGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/rotationGesture.js +27 -0
- package/lib/typescript/handlers/gestures/tapGesture.d.ts +50 -0
- package/lib/typescript/handlers/gestures/tapGesture.d.ts.map +1 -0
- package/lib/typescript/handlers/gestures/tapGesture.js +72 -0
- package/lib/typescript/handlers/getNextHandlerTag.d.ts +1 -0
- package/lib/typescript/handlers/getNextHandlerTag.d.ts.map +1 -0
- package/lib/typescript/handlers/getNextHandlerTag.js +4 -0
- package/lib/typescript/handlers/handlersRegistry.d.ts +14 -0
- package/lib/typescript/handlers/handlersRegistry.d.ts.map +1 -0
- package/lib/typescript/handlers/handlersRegistry.js +36 -0
- package/lib/typescript/handlers/utils.d.ts +7 -0
- package/lib/typescript/handlers/utils.d.ts.map +1 -0
- package/lib/typescript/handlers/utils.js +58 -0
- package/lib/typescript/index.d.ts +58 -0
- package/lib/typescript/index.d.ts.map +1 -0
- package/lib/typescript/index.js +28 -0
- package/lib/typescript/init.d.ts +2 -0
- package/lib/typescript/init.d.ts.map +1 -0
- package/lib/typescript/init.js +15 -0
- package/lib/typescript/jestUtils/index.d.ts +1 -0
- package/lib/typescript/jestUtils/index.d.ts.map +1 -0
- package/lib/typescript/jestUtils/index.js +1 -0
- package/lib/typescript/jestUtils/jestUtils.d.ts +29 -0
- package/lib/typescript/jestUtils/jestUtils.d.ts.map +1 -0
- package/lib/typescript/jestUtils/jestUtils.js +290 -0
- package/lib/typescript/mocks.d.ts +46 -0
- package/lib/typescript/mocks.d.ts.map +1 -0
- package/lib/typescript/mocks.js +59 -0
- package/lib/typescript/mountRegistry.d.ts +16 -0
- package/lib/typescript/mountRegistry.d.ts.map +1 -0
- package/lib/typescript/mountRegistry.js +29 -0
- package/lib/typescript/specs/NativeRNGestureHandlerModule.d.ts +14 -0
- package/lib/typescript/specs/NativeRNGestureHandlerModule.d.ts.map +1 -0
- package/lib/typescript/specs/NativeRNGestureHandlerModule.js +2 -0
- package/lib/typescript/specs/RNGestureHandlerButtonNativeComponent.d.ts +16 -0
- package/lib/typescript/specs/RNGestureHandlerButtonNativeComponent.d.ts.map +1 -0
- package/lib/typescript/specs/RNGestureHandlerButtonNativeComponent.js +2 -0
- package/lib/typescript/specs/RNGestureHandlerRootViewNativeComponent.d.ts +5 -0
- package/lib/typescript/specs/RNGestureHandlerRootViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/specs/RNGestureHandlerRootViewNativeComponent.js +2 -0
- package/lib/typescript/typeUtils.d.ts +1 -0
- package/lib/typescript/typeUtils.d.ts.map +1 -0
- package/lib/typescript/typeUtils.js +1 -0
- package/lib/typescript/utils.d.ts +20 -0
- package/lib/typescript/utils.d.ts.map +1 -0
- package/lib/typescript/utils.js +80 -0
- package/lib/typescript/web/Gestures.d.ts +36 -0
- package/lib/typescript/web/Gestures.d.ts.map +1 -0
- package/lib/typescript/web/Gestures.js +38 -0
- package/lib/typescript/web/constants.d.ts +2 -0
- package/lib/typescript/web/constants.d.ts.map +1 -0
- package/lib/typescript/web/constants.js +2 -0
- package/lib/typescript/web/detectors/RotationGestureDetector.d.ts +30 -0
- package/lib/typescript/web/detectors/RotationGestureDetector.d.ts.map +1 -0
- package/lib/typescript/web/detectors/RotationGestureDetector.js +122 -0
- package/lib/typescript/web/detectors/ScaleGestureDetector.d.ts +29 -0
- package/lib/typescript/web/detectors/ScaleGestureDetector.d.ts.map +1 -0
- package/lib/typescript/web/detectors/ScaleGestureDetector.js +117 -0
- package/lib/typescript/web/handlers/FlingGestureHandler.d.ts +26 -0
- package/lib/typescript/web/handlers/FlingGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/FlingGestureHandler.js +133 -0
- package/lib/typescript/web/handlers/GestureHandler.d.ts +102 -0
- package/lib/typescript/web/handlers/GestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/GestureHandler.js +656 -0
- package/lib/typescript/web/handlers/HoverGestureHandler.d.ts +10 -0
- package/lib/typescript/web/handlers/HoverGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/HoverGestureHandler.js +37 -0
- package/lib/typescript/web/handlers/IGestureHandler.d.ts +37 -0
- package/lib/typescript/web/handlers/IGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/IGestureHandler.js +1 -0
- package/lib/typescript/web/handlers/LongPressGestureHandler.d.ts +30 -0
- package/lib/typescript/web/handlers/LongPressGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/LongPressGestureHandler.js +136 -0
- package/lib/typescript/web/handlers/ManualGestureHandler.d.ts +10 -0
- package/lib/typescript/web/handlers/ManualGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/ManualGestureHandler.js +29 -0
- package/lib/typescript/web/handlers/NativeViewGestureHandler.d.ts +25 -0
- package/lib/typescript/web/handlers/NativeViewGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/NativeViewGestureHandler.js +133 -0
- package/lib/typescript/web/handlers/PanGestureHandler.d.ts +63 -0
- package/lib/typescript/web/handlers/PanGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/PanGestureHandler.js +420 -0
- package/lib/typescript/web/handlers/PinchGestureHandler.d.ts +27 -0
- package/lib/typescript/web/handlers/PinchGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/PinchGestureHandler.js +117 -0
- package/lib/typescript/web/handlers/RotationGestureHandler.d.ts +27 -0
- package/lib/typescript/web/handlers/RotationGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/RotationGestureHandler.js +122 -0
- package/lib/typescript/web/handlers/TapGestureHandler.d.ts +39 -0
- package/lib/typescript/web/handlers/TapGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web/handlers/TapGestureHandler.js +202 -0
- package/lib/typescript/web/interfaces.d.ts +157 -0
- package/lib/typescript/web/interfaces.d.ts.map +1 -0
- package/lib/typescript/web/interfaces.js +25 -0
- package/lib/typescript/web/tools/CircularBuffer.d.ts +11 -0
- package/lib/typescript/web/tools/CircularBuffer.d.ts.map +1 -0
- package/lib/typescript/web/tools/CircularBuffer.js +37 -0
- package/lib/typescript/web/tools/EventManager.d.ts +39 -0
- package/lib/typescript/web/tools/EventManager.d.ts.map +1 -0
- package/lib/typescript/web/tools/EventManager.js +85 -0
- package/lib/typescript/web/tools/GestureHandlerDelegate.d.ts +24 -0
- package/lib/typescript/web/tools/GestureHandlerDelegate.d.ts.map +1 -0
- package/lib/typescript/web/tools/GestureHandlerDelegate.js +1 -0
- package/lib/typescript/web/tools/GestureHandlerOrchestrator.d.ts +31 -0
- package/lib/typescript/web/tools/GestureHandlerOrchestrator.d.ts.map +1 -0
- package/lib/typescript/web/tools/GestureHandlerOrchestrator.js +273 -0
- package/lib/typescript/web/tools/GestureHandlerWebDelegate.d.ts +35 -0
- package/lib/typescript/web/tools/GestureHandlerWebDelegate.d.ts.map +1 -0
- package/lib/typescript/web/tools/GestureHandlerWebDelegate.js +169 -0
- package/lib/typescript/web/tools/InteractionManager.d.ts +17 -0
- package/lib/typescript/web/tools/InteractionManager.d.ts.map +1 -0
- package/lib/typescript/web/tools/InteractionManager.js +91 -0
- package/lib/typescript/web/tools/KeyboardEventManager.d.ts +13 -0
- package/lib/typescript/web/tools/KeyboardEventManager.d.ts.map +1 -0
- package/lib/typescript/web/tools/KeyboardEventManager.js +73 -0
- package/lib/typescript/web/tools/LeastSquareSolver.d.ts +12 -0
- package/lib/typescript/web/tools/LeastSquareSolver.d.ts.map +1 -0
- package/lib/typescript/web/tools/LeastSquareSolver.js +147 -0
- package/lib/typescript/web/tools/NodeManager.d.ts +12 -0
- package/lib/typescript/web/tools/NodeManager.d.ts.map +1 -0
- package/lib/typescript/web/tools/NodeManager.js +28 -0
- package/lib/typescript/web/tools/PointerEventManager.d.ts +19 -0
- package/lib/typescript/web/tools/PointerEventManager.d.ts.map +1 -0
- package/lib/typescript/web/tools/PointerEventManager.js +179 -0
- package/lib/typescript/web/tools/PointerTracker.d.ts +50 -0
- package/lib/typescript/web/tools/PointerTracker.d.ts.map +1 -0
- package/lib/typescript/web/tools/PointerTracker.js +161 -0
- package/lib/typescript/web/tools/Vector.d.ts +15 -0
- package/lib/typescript/web/tools/Vector.d.ts.map +1 -0
- package/lib/typescript/web/tools/Vector.js +43 -0
- package/lib/typescript/web/tools/VelocityTracker.d.ts +13 -0
- package/lib/typescript/web/tools/VelocityTracker.d.ts.map +1 -0
- package/lib/typescript/web/tools/VelocityTracker.js +76 -0
- package/lib/typescript/web/tools/WheelEventManager.d.ts +11 -0
- package/lib/typescript/web/tools/WheelEventManager.d.ts.map +1 -0
- package/lib/typescript/web/tools/WheelEventManager.js +40 -0
- package/lib/typescript/web/utils.d.ts +14 -0
- package/lib/typescript/web/utils.d.ts.map +1 -0
- package/lib/typescript/web/utils.js +233 -0
- package/lib/typescript/web_hammer/DiscreteGestureHandler.d.ts +20 -0
- package/lib/typescript/web_hammer/DiscreteGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/DiscreteGestureHandler.js +48 -0
- package/lib/typescript/web_hammer/DraggingGestureHandler.d.ts +15 -0
- package/lib/typescript/web_hammer/DraggingGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/DraggingGestureHandler.js +25 -0
- package/lib/typescript/web_hammer/Errors.d.ts +3 -0
- package/lib/typescript/web_hammer/Errors.d.ts.map +1 -0
- package/lib/typescript/web_hammer/Errors.js +5 -0
- package/lib/typescript/web_hammer/FlingGestureHandler.d.ts +43 -0
- package/lib/typescript/web_hammer/FlingGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/FlingGestureHandler.js +119 -0
- package/lib/typescript/web_hammer/GestureHandler.d.ts +145 -0
- package/lib/typescript/web_hammer/GestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/GestureHandler.js +469 -0
- package/lib/typescript/web_hammer/IndiscreteGestureHandler.d.ts +40 -0
- package/lib/typescript/web_hammer/IndiscreteGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/IndiscreteGestureHandler.js +26 -0
- package/lib/typescript/web_hammer/LongPressGestureHandler.d.ts +38 -0
- package/lib/typescript/web_hammer/LongPressGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/LongPressGestureHandler.js +46 -0
- package/lib/typescript/web_hammer/NativeViewGestureHandler.d.ts +7 -0
- package/lib/typescript/web_hammer/NativeViewGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/NativeViewGestureHandler.js +40 -0
- package/lib/typescript/web_hammer/NodeManager.d.ts +7 -0
- package/lib/typescript/web_hammer/NodeManager.d.ts.map +1 -0
- package/lib/typescript/web_hammer/NodeManager.js +28 -0
- package/lib/typescript/web_hammer/PanGestureHandler.d.ts +56 -0
- package/lib/typescript/web_hammer/PanGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/PanGestureHandler.js +151 -0
- package/lib/typescript/web_hammer/PinchGestureHandler.d.ts +13 -0
- package/lib/typescript/web_hammer/PinchGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/PinchGestureHandler.js +19 -0
- package/lib/typescript/web_hammer/PressGestureHandler.d.ts +83 -0
- package/lib/typescript/web_hammer/PressGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/PressGestureHandler.js +133 -0
- package/lib/typescript/web_hammer/RotationGestureHandler.d.ts +13 -0
- package/lib/typescript/web_hammer/RotationGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/RotationGestureHandler.js +20 -0
- package/lib/typescript/web_hammer/TapGestureHandler.d.ts +57 -0
- package/lib/typescript/web_hammer/TapGestureHandler.d.ts.map +1 -0
- package/lib/typescript/web_hammer/TapGestureHandler.js +142 -0
- package/lib/typescript/web_hammer/constants.d.ts +39 -0
- package/lib/typescript/web_hammer/constants.d.ts.map +1 -0
- package/lib/typescript/web_hammer/constants.js +42 -0
- package/lib/typescript/web_hammer/utils.d.ts +9 -0
- package/lib/typescript/web_hammer/utils.d.ts.map +1 -0
- package/lib/typescript/web_hammer/utils.js +15 -0
- package/package.json +1 -1
@@ -0,0 +1,287 @@
|
|
1
|
+
// Similarily to the DrawerLayout component this deserves to be put in a
|
2
|
+
// separate repo. Although, keeping it here for the time being will allow us to
|
3
|
+
// move faster and fix possible issues quicker
|
4
|
+
import * as React from 'react';
|
5
|
+
import { Component } from 'react';
|
6
|
+
import { Animated, StyleSheet, View, I18nManager, } from 'react-native';
|
7
|
+
import { PanGestureHandler, } from '../handlers/PanGestureHandler';
|
8
|
+
import { TapGestureHandler } from '../handlers/TapGestureHandler';
|
9
|
+
import { State } from '../State';
|
10
|
+
const DRAG_TOSS = 0.05;
|
11
|
+
/**
|
12
|
+
* @deprecated use Reanimated version of Swipeable instead
|
13
|
+
*
|
14
|
+
* This component allows for implementing swipeable rows or similar interaction.
|
15
|
+
*/
|
16
|
+
export default class Swipeable extends Component {
|
17
|
+
static defaultProps = {
|
18
|
+
friction: 1,
|
19
|
+
overshootFriction: 1,
|
20
|
+
useNativeAnimations: true,
|
21
|
+
};
|
22
|
+
constructor(props) {
|
23
|
+
super(props);
|
24
|
+
const dragX = new Animated.Value(0);
|
25
|
+
this.state = {
|
26
|
+
dragX,
|
27
|
+
rowTranslation: new Animated.Value(0),
|
28
|
+
rowState: 0,
|
29
|
+
leftWidth: undefined,
|
30
|
+
rightOffset: undefined,
|
31
|
+
rowWidth: undefined,
|
32
|
+
};
|
33
|
+
this.updateAnimatedEvent(props, this.state);
|
34
|
+
this.onGestureEvent = Animated.event([{ nativeEvent: { translationX: dragX } }], { useNativeDriver: props.useNativeAnimations });
|
35
|
+
}
|
36
|
+
shouldComponentUpdate(props, state) {
|
37
|
+
if (this.props.friction !== props.friction ||
|
38
|
+
this.props.overshootLeft !== props.overshootLeft ||
|
39
|
+
this.props.overshootRight !== props.overshootRight ||
|
40
|
+
this.props.overshootFriction !== props.overshootFriction ||
|
41
|
+
this.state.leftWidth !== state.leftWidth ||
|
42
|
+
this.state.rightOffset !== state.rightOffset ||
|
43
|
+
this.state.rowWidth !== state.rowWidth) {
|
44
|
+
this.updateAnimatedEvent(props, state);
|
45
|
+
}
|
46
|
+
return true;
|
47
|
+
}
|
48
|
+
onGestureEvent;
|
49
|
+
transX;
|
50
|
+
showLeftAction;
|
51
|
+
leftActionTranslate;
|
52
|
+
showRightAction;
|
53
|
+
rightActionTranslate;
|
54
|
+
updateAnimatedEvent = (props, state) => {
|
55
|
+
const { friction, overshootFriction } = props;
|
56
|
+
const { dragX, rowTranslation, leftWidth = 0, rowWidth = 0 } = state;
|
57
|
+
const { rightOffset = rowWidth } = state;
|
58
|
+
const rightWidth = Math.max(0, rowWidth - rightOffset);
|
59
|
+
const { overshootLeft = leftWidth > 0, overshootRight = rightWidth > 0 } = props;
|
60
|
+
const transX = Animated.add(rowTranslation, dragX.interpolate({
|
61
|
+
inputRange: [0, friction],
|
62
|
+
outputRange: [0, 1],
|
63
|
+
})).interpolate({
|
64
|
+
inputRange: [-rightWidth - 1, -rightWidth, leftWidth, leftWidth + 1],
|
65
|
+
outputRange: [
|
66
|
+
-rightWidth - (overshootRight ? 1 / overshootFriction : 0),
|
67
|
+
-rightWidth,
|
68
|
+
leftWidth,
|
69
|
+
leftWidth + (overshootLeft ? 1 / overshootFriction : 0),
|
70
|
+
],
|
71
|
+
});
|
72
|
+
this.transX = transX;
|
73
|
+
this.showLeftAction =
|
74
|
+
leftWidth > 0
|
75
|
+
? transX.interpolate({
|
76
|
+
inputRange: [-1, 0, leftWidth],
|
77
|
+
outputRange: [0, 0, 1],
|
78
|
+
})
|
79
|
+
: new Animated.Value(0);
|
80
|
+
this.leftActionTranslate = this.showLeftAction.interpolate({
|
81
|
+
inputRange: [0, Number.MIN_VALUE],
|
82
|
+
outputRange: [-10000, 0],
|
83
|
+
extrapolate: 'clamp',
|
84
|
+
});
|
85
|
+
this.showRightAction =
|
86
|
+
rightWidth > 0
|
87
|
+
? transX.interpolate({
|
88
|
+
inputRange: [-rightWidth, 0, 1],
|
89
|
+
outputRange: [1, 0, 0],
|
90
|
+
})
|
91
|
+
: new Animated.Value(0);
|
92
|
+
this.rightActionTranslate = this.showRightAction.interpolate({
|
93
|
+
inputRange: [0, Number.MIN_VALUE],
|
94
|
+
outputRange: [-10000, 0],
|
95
|
+
extrapolate: 'clamp',
|
96
|
+
});
|
97
|
+
};
|
98
|
+
onTapHandlerStateChange = ({ nativeEvent, }) => {
|
99
|
+
if (nativeEvent.oldState === State.ACTIVE) {
|
100
|
+
this.close();
|
101
|
+
}
|
102
|
+
};
|
103
|
+
onHandlerStateChange = (ev) => {
|
104
|
+
if (ev.nativeEvent.oldState === State.ACTIVE) {
|
105
|
+
this.handleRelease(ev);
|
106
|
+
}
|
107
|
+
if (ev.nativeEvent.state === State.ACTIVE) {
|
108
|
+
const { velocityX, translationX: dragX } = ev.nativeEvent;
|
109
|
+
const { rowState } = this.state;
|
110
|
+
const { friction } = this.props;
|
111
|
+
const translationX = (dragX + DRAG_TOSS * velocityX) / friction;
|
112
|
+
const direction = rowState === -1
|
113
|
+
? 'right'
|
114
|
+
: rowState === 1
|
115
|
+
? 'left'
|
116
|
+
: translationX > 0
|
117
|
+
? 'left'
|
118
|
+
: 'right';
|
119
|
+
if (rowState === 0) {
|
120
|
+
this.props.onSwipeableOpenStartDrag?.(direction);
|
121
|
+
}
|
122
|
+
else {
|
123
|
+
this.props.onSwipeableCloseStartDrag?.(direction);
|
124
|
+
}
|
125
|
+
}
|
126
|
+
};
|
127
|
+
handleRelease = (ev) => {
|
128
|
+
const { velocityX, translationX: dragX } = ev.nativeEvent;
|
129
|
+
const { leftWidth = 0, rowWidth = 0, rowState } = this.state;
|
130
|
+
const { rightOffset = rowWidth } = this.state;
|
131
|
+
const rightWidth = rowWidth - rightOffset;
|
132
|
+
const { friction, leftThreshold = leftWidth / 2, rightThreshold = rightWidth / 2, } = this.props;
|
133
|
+
const startOffsetX = this.currentOffset() + dragX / friction;
|
134
|
+
const translationX = (dragX + DRAG_TOSS * velocityX) / friction;
|
135
|
+
let toValue = 0;
|
136
|
+
if (rowState === 0) {
|
137
|
+
if (translationX > leftThreshold) {
|
138
|
+
toValue = leftWidth;
|
139
|
+
}
|
140
|
+
else if (translationX < -rightThreshold) {
|
141
|
+
toValue = -rightWidth;
|
142
|
+
}
|
143
|
+
}
|
144
|
+
else if (rowState === 1) {
|
145
|
+
// Swiped to left
|
146
|
+
if (translationX > -leftThreshold) {
|
147
|
+
toValue = leftWidth;
|
148
|
+
}
|
149
|
+
}
|
150
|
+
else {
|
151
|
+
// Swiped to right
|
152
|
+
if (translationX < rightThreshold) {
|
153
|
+
toValue = -rightWidth;
|
154
|
+
}
|
155
|
+
}
|
156
|
+
this.animateRow(startOffsetX, toValue, velocityX / friction);
|
157
|
+
};
|
158
|
+
animateRow = (fromValue, toValue, velocityX) => {
|
159
|
+
const { dragX, rowTranslation } = this.state;
|
160
|
+
dragX.setValue(0);
|
161
|
+
rowTranslation.setValue(fromValue);
|
162
|
+
this.setState({ rowState: Math.sign(toValue) });
|
163
|
+
Animated.spring(rowTranslation, {
|
164
|
+
restSpeedThreshold: 1.7,
|
165
|
+
restDisplacementThreshold: 0.4,
|
166
|
+
velocity: velocityX,
|
167
|
+
bounciness: 0,
|
168
|
+
toValue,
|
169
|
+
useNativeDriver: this.props.useNativeAnimations,
|
170
|
+
...this.props.animationOptions,
|
171
|
+
}).start(({ finished }) => {
|
172
|
+
if (finished) {
|
173
|
+
if (toValue > 0) {
|
174
|
+
this.props.onSwipeableLeftOpen?.();
|
175
|
+
this.props.onSwipeableOpen?.('left', this);
|
176
|
+
}
|
177
|
+
else if (toValue < 0) {
|
178
|
+
this.props.onSwipeableRightOpen?.();
|
179
|
+
this.props.onSwipeableOpen?.('right', this);
|
180
|
+
}
|
181
|
+
else {
|
182
|
+
const closingDirection = fromValue > 0 ? 'left' : 'right';
|
183
|
+
this.props.onSwipeableClose?.(closingDirection, this);
|
184
|
+
}
|
185
|
+
}
|
186
|
+
});
|
187
|
+
if (toValue > 0) {
|
188
|
+
this.props.onSwipeableLeftWillOpen?.();
|
189
|
+
this.props.onSwipeableWillOpen?.('left');
|
190
|
+
}
|
191
|
+
else if (toValue < 0) {
|
192
|
+
this.props.onSwipeableRightWillOpen?.();
|
193
|
+
this.props.onSwipeableWillOpen?.('right');
|
194
|
+
}
|
195
|
+
else {
|
196
|
+
const closingDirection = fromValue > 0 ? 'left' : 'right';
|
197
|
+
this.props.onSwipeableWillClose?.(closingDirection);
|
198
|
+
}
|
199
|
+
};
|
200
|
+
onRowLayout = ({ nativeEvent }) => {
|
201
|
+
this.setState({ rowWidth: nativeEvent.layout.width });
|
202
|
+
};
|
203
|
+
currentOffset = () => {
|
204
|
+
const { leftWidth = 0, rowWidth = 0, rowState } = this.state;
|
205
|
+
const { rightOffset = rowWidth } = this.state;
|
206
|
+
const rightWidth = rowWidth - rightOffset;
|
207
|
+
if (rowState === 1) {
|
208
|
+
return leftWidth;
|
209
|
+
}
|
210
|
+
else if (rowState === -1) {
|
211
|
+
return -rightWidth;
|
212
|
+
}
|
213
|
+
return 0;
|
214
|
+
};
|
215
|
+
close = () => {
|
216
|
+
this.animateRow(this.currentOffset(), 0);
|
217
|
+
};
|
218
|
+
// eslint-disable-next-line @eslint-react/no-unused-class-component-members
|
219
|
+
openLeft = () => {
|
220
|
+
const { leftWidth = 0 } = this.state;
|
221
|
+
this.animateRow(this.currentOffset(), leftWidth);
|
222
|
+
};
|
223
|
+
// eslint-disable-next-line @eslint-react/no-unused-class-component-members
|
224
|
+
openRight = () => {
|
225
|
+
const { rowWidth = 0 } = this.state;
|
226
|
+
const { rightOffset = rowWidth } = this.state;
|
227
|
+
const rightWidth = rowWidth - rightOffset;
|
228
|
+
this.animateRow(this.currentOffset(), -rightWidth);
|
229
|
+
};
|
230
|
+
// eslint-disable-next-line @eslint-react/no-unused-class-component-members
|
231
|
+
reset = () => {
|
232
|
+
const { dragX, rowTranslation } = this.state;
|
233
|
+
dragX.setValue(0);
|
234
|
+
rowTranslation.setValue(0);
|
235
|
+
this.setState({ rowState: 0 });
|
236
|
+
};
|
237
|
+
render() {
|
238
|
+
const { rowState } = this.state;
|
239
|
+
const { children, renderLeftActions, renderRightActions, dragOffsetFromLeftEdge = 10, dragOffsetFromRightEdge = 10, } = this.props;
|
240
|
+
const left = renderLeftActions && (<Animated.View style={[
|
241
|
+
styles.leftActions,
|
242
|
+
// All those and below parameters can have ! since they are all
|
243
|
+
// asigned in constructor in `updateAnimatedEvent` but TS cannot spot
|
244
|
+
// it for some reason
|
245
|
+
{ transform: [{ translateX: this.leftActionTranslate }] },
|
246
|
+
]}>
|
247
|
+
{renderLeftActions(this.showLeftAction, this.transX, this)}
|
248
|
+
<View onLayout={({ nativeEvent }) => this.setState({ leftWidth: nativeEvent.layout.x })}/>
|
249
|
+
</Animated.View>);
|
250
|
+
const right = renderRightActions && (<Animated.View style={[
|
251
|
+
styles.rightActions,
|
252
|
+
{ transform: [{ translateX: this.rightActionTranslate }] },
|
253
|
+
]}>
|
254
|
+
{renderRightActions(this.showRightAction, this.transX, this)}
|
255
|
+
<View onLayout={({ nativeEvent }) => this.setState({ rightOffset: nativeEvent.layout.x })}/>
|
256
|
+
</Animated.View>);
|
257
|
+
return (<PanGestureHandler activeOffsetX={[-dragOffsetFromRightEdge, dragOffsetFromLeftEdge]} touchAction="pan-y" {...this.props} onGestureEvent={this.onGestureEvent} onHandlerStateChange={this.onHandlerStateChange}>
|
258
|
+
<Animated.View onLayout={this.onRowLayout} style={[styles.container, this.props.containerStyle]}>
|
259
|
+
{left}
|
260
|
+
{right}
|
261
|
+
<TapGestureHandler enabled={rowState !== 0} touchAction="pan-y" onHandlerStateChange={this.onTapHandlerStateChange}>
|
262
|
+
<Animated.View pointerEvents={rowState === 0 ? 'auto' : 'box-only'} style={[
|
263
|
+
{
|
264
|
+
transform: [{ translateX: this.transX }],
|
265
|
+
},
|
266
|
+
this.props.childrenContainerStyle,
|
267
|
+
]}>
|
268
|
+
{children}
|
269
|
+
</Animated.View>
|
270
|
+
</TapGestureHandler>
|
271
|
+
</Animated.View>
|
272
|
+
</PanGestureHandler>);
|
273
|
+
}
|
274
|
+
}
|
275
|
+
const styles = StyleSheet.create({
|
276
|
+
container: {
|
277
|
+
overflow: 'hidden',
|
278
|
+
},
|
279
|
+
leftActions: {
|
280
|
+
...StyleSheet.absoluteFillObject,
|
281
|
+
flexDirection: I18nManager.isRTL ? 'row-reverse' : 'row',
|
282
|
+
},
|
283
|
+
rightActions: {
|
284
|
+
...StyleSheet.absoluteFillObject,
|
285
|
+
flexDirection: I18nManager.isRTL ? 'row' : 'row-reverse',
|
286
|
+
},
|
287
|
+
});
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../src/components/Text.tsx"],"names":[],"mappings":"AAAA,OAAO,KAMN,MAAM,OAAO,CAAC;AACf,OAAO,EAEL,IAAI,IAAI,MAAM,EACd,SAAS,IAAI,WAAW,EACzB,MAAM,cAAc,CAAC;AAKtB,eAAO,MAAM,IAAI,4EA0DhB,CAAC;AAEF,MAAM,MAAM,IAAI,GAAG,OAAO,IAAI,GAAG,MAAM,CAAC"}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
import React, { forwardRef, useEffect, useRef, } from 'react';
|
2
|
+
import { Platform, Text as RNText, } from 'react-native';
|
3
|
+
import { GestureObjects as Gesture } from '../handlers/gestures/gestureObjects';
|
4
|
+
import { GestureDetector } from '../handlers/gestures/GestureDetector';
|
5
|
+
export const Text = forwardRef((props, ref) => {
|
6
|
+
const { onPress, onLongPress, ...rest } = props;
|
7
|
+
const textRef = useRef(null);
|
8
|
+
const native = Gesture.Native().runOnJS(true);
|
9
|
+
const refHandler = (node) => {
|
10
|
+
textRef.current = node;
|
11
|
+
if (ref === null) {
|
12
|
+
return;
|
13
|
+
}
|
14
|
+
if (typeof ref === 'function') {
|
15
|
+
ref(node);
|
16
|
+
}
|
17
|
+
else {
|
18
|
+
ref.current = node;
|
19
|
+
}
|
20
|
+
};
|
21
|
+
// This is a special case for `Text` component. After https://github.com/software-mansion/react-native-gesture-handler/pull/3379 we check for
|
22
|
+
// `displayName` field. However, `Text` from RN has this field set to `Text`, but is also present in `RNSVGElements` set.
|
23
|
+
// We don't want to treat our `Text` as the one from `SVG`, therefore we add special field to ref.
|
24
|
+
refHandler.rngh = true;
|
25
|
+
useEffect(() => {
|
26
|
+
if (Platform.OS !== 'web') {
|
27
|
+
return;
|
28
|
+
}
|
29
|
+
const textElement = ref
|
30
|
+
? ref.current
|
31
|
+
: textRef.current;
|
32
|
+
// At this point we are sure that textElement is div in HTML tree
|
33
|
+
textElement?.setAttribute('rnghtext', 'true');
|
34
|
+
}, []);
|
35
|
+
return onPress || onLongPress ? (<GestureDetector gesture={native}>
|
36
|
+
<RNText onPress={onPress} onLongPress={onLongPress} ref={refHandler} {...rest}/>
|
37
|
+
</GestureDetector>) : (<RNText ref={ref} {...rest}/>);
|
38
|
+
});
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"gestureHandlerRootHOC.d.ts","sourceRoot":"","sources":["../../../src/components/gestureHandlerRootHOC.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAc,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAIhE,MAAM,CAAC,OAAO,UAAU,qBAAqB,CAAC,CAAC,SAAS,MAAM,EAC5D,SAAS,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,EACjC,eAAe,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,GACrC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAiBxB"}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { StyleSheet } from 'react-native';
|
3
|
+
import hoistNonReactStatics from 'hoist-non-react-statics';
|
4
|
+
import GestureHandlerRootView from './GestureHandlerRootView';
|
5
|
+
export default function gestureHandlerRootHOC(Component, containerStyles) {
|
6
|
+
function Wrapper(props) {
|
7
|
+
return (<GestureHandlerRootView style={[styles.container, containerStyles]}>
|
8
|
+
<Component {...props}/>
|
9
|
+
</GestureHandlerRootView>);
|
10
|
+
}
|
11
|
+
Wrapper.displayName = `gestureHandlerRootHOC(${Component.displayName || Component.name})`;
|
12
|
+
// @ts-ignore - hoistNonReactStatics uses old version of @types/react
|
13
|
+
hoistNonReactStatics(Wrapper, Component);
|
14
|
+
return Wrapper;
|
15
|
+
}
|
16
|
+
const styles = StyleSheet.create({
|
17
|
+
container: { flex: 1 },
|
18
|
+
});
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"ExtraButtonProps.d.ts","sourceRoot":"","sources":["../../../../src/components/touchables/ExtraButtonProps.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,gBAAgB,GAAG;IAC7B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IACrC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1,55 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { Component } from 'react';
|
3
|
+
import { GestureEvent, HandlerStateChangeEvent } from '../../handlers/gestureHandlerCommon';
|
4
|
+
import type { NativeViewGestureHandlerPayload } from '../../handlers/GestureHandlerEventPayload';
|
5
|
+
import type { GenericTouchableProps } from './GenericTouchableProps';
|
6
|
+
/**
|
7
|
+
* Each touchable is a states' machine which preforms transitions.
|
8
|
+
* On very beginning (and on the very end or recognition) touchable is
|
9
|
+
* UNDETERMINED. Then it moves to BEGAN. If touchable recognizes that finger
|
10
|
+
* travel outside it transits to special MOVED_OUTSIDE state. Gesture recognition
|
11
|
+
* finishes in UNDETERMINED state.
|
12
|
+
*/
|
13
|
+
export declare const TOUCHABLE_STATE: {
|
14
|
+
readonly UNDETERMINED: 0;
|
15
|
+
readonly BEGAN: 1;
|
16
|
+
readonly MOVED_OUTSIDE: 2;
|
17
|
+
};
|
18
|
+
type TouchableState = (typeof TOUCHABLE_STATE)[keyof typeof TOUCHABLE_STATE];
|
19
|
+
interface InternalProps {
|
20
|
+
onStateChange?: (oldState: TouchableState, newState: TouchableState) => void;
|
21
|
+
}
|
22
|
+
type Timeout = ReturnType<typeof setTimeout> | null | undefined;
|
23
|
+
/**
|
24
|
+
* GenericTouchable is not intented to be used as it is.
|
25
|
+
* Should be treated as a source for the rest of touchables
|
26
|
+
*/
|
27
|
+
export default class GenericTouchable extends Component<GenericTouchableProps & InternalProps> {
|
28
|
+
static defaultProps: {
|
29
|
+
delayLongPress: number;
|
30
|
+
extraButtonProps: {
|
31
|
+
rippleColor: string;
|
32
|
+
exclusive: boolean;
|
33
|
+
};
|
34
|
+
};
|
35
|
+
pressInTimeout: Timeout;
|
36
|
+
pressOutTimeout: Timeout;
|
37
|
+
longPressTimeout: Timeout;
|
38
|
+
longPressDetected: boolean;
|
39
|
+
pointerInside: boolean;
|
40
|
+
STATE: TouchableState;
|
41
|
+
handlePressIn(): void;
|
42
|
+
handleMoveOutside(): void;
|
43
|
+
handleGoToUndetermined(): void;
|
44
|
+
componentDidMount(): void;
|
45
|
+
reset(): void;
|
46
|
+
moveToState(newState: TouchableState): void;
|
47
|
+
onGestureEvent: ({ nativeEvent: { pointerInside }, }: GestureEvent<NativeViewGestureHandlerPayload>) => void;
|
48
|
+
onHandlerStateChange: ({ nativeEvent, }: HandlerStateChangeEvent<NativeViewGestureHandlerPayload>) => void;
|
49
|
+
onLongPressDetected: () => void;
|
50
|
+
componentWillUnmount(): void;
|
51
|
+
onMoveIn(): void;
|
52
|
+
onMoveOut(): void;
|
53
|
+
render(): React.JSX.Element;
|
54
|
+
}
|
55
|
+
export {};
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"GenericTouchable.d.ts","sourceRoot":"","sources":["../../../../src/components/touchables/GenericTouchable.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAMlC,OAAO,EACL,YAAY,EACZ,uBAAuB,EACxB,MAAM,qCAAqC,CAAC;AAC7C,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,2CAA2C,CAAC;AACjG,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAErE;;;;;;GAMG;AACH,eAAO,MAAM,eAAe;;;;CAIlB,CAAC;AAEX,KAAK,cAAc,GAAG,CAAC,OAAO,eAAe,CAAC,CAAC,MAAM,OAAO,eAAe,CAAC,CAAC;AAE7E,UAAU,aAAa;IACrB,aAAa,CAAC,EAAE,CAAC,QAAQ,EAAE,cAAc,EAAE,QAAQ,EAAE,cAAc,KAAK,IAAI,CAAC;CAC9E;AAID,KAAK,OAAO,GAAG,UAAU,CAAC,OAAO,UAAU,CAAC,GAAG,IAAI,GAAG,SAAS,CAAC;AAEhE;;;GAGG;AAEH,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,SAAS,CACrD,qBAAqB,GAAG,aAAa,CACtC;IACC,MAAM,CAAC,YAAY;;;;;;MAMjB;IAGF,cAAc,EAAE,OAAO,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,OAAO,CAAC;IAG1B,iBAAiB,UAAS;IAE1B,aAAa,UAAQ;IAGrB,KAAK,EAAE,cAAc,CAAgC;IAIrD,aAAa;IAiBb,iBAAiB;IAcjB,sBAAsB;IAkBtB,iBAAiB;IAIjB,KAAK;IAYL,WAAW,CAAC,QAAQ,EAAE,cAAc;IAyBpC,cAAc,GAAI,qCAEf,YAAY,CAAC,+BAA+B,CAAC,UAS9C;IAEF,oBAAoB,GAAI,kBAErB,uBAAuB,CAAC,+BAA+B,CAAC,UAyBzD;IAEF,mBAAmB,aAIjB;IAEF,oBAAoB;IAKpB,QAAQ;IAOR,SAAS;IAST,MAAM;CA+CP"}
|
@@ -0,0 +1,221 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { Component } from 'react';
|
3
|
+
import { Animated, Platform } from 'react-native';
|
4
|
+
import { State } from '../../State';
|
5
|
+
import { BaseButton } from '../GestureButtons';
|
6
|
+
/**
|
7
|
+
* Each touchable is a states' machine which preforms transitions.
|
8
|
+
* On very beginning (and on the very end or recognition) touchable is
|
9
|
+
* UNDETERMINED. Then it moves to BEGAN. If touchable recognizes that finger
|
10
|
+
* travel outside it transits to special MOVED_OUTSIDE state. Gesture recognition
|
11
|
+
* finishes in UNDETERMINED state.
|
12
|
+
*/
|
13
|
+
export const TOUCHABLE_STATE = {
|
14
|
+
UNDETERMINED: 0,
|
15
|
+
BEGAN: 1,
|
16
|
+
MOVED_OUTSIDE: 2,
|
17
|
+
};
|
18
|
+
/**
|
19
|
+
* GenericTouchable is not intented to be used as it is.
|
20
|
+
* Should be treated as a source for the rest of touchables
|
21
|
+
*/
|
22
|
+
export default class GenericTouchable extends Component {
|
23
|
+
static defaultProps = {
|
24
|
+
delayLongPress: 600,
|
25
|
+
extraButtonProps: {
|
26
|
+
rippleColor: 'transparent',
|
27
|
+
exclusive: true,
|
28
|
+
},
|
29
|
+
};
|
30
|
+
// Timeout handlers
|
31
|
+
pressInTimeout;
|
32
|
+
pressOutTimeout;
|
33
|
+
longPressTimeout;
|
34
|
+
// This flag is required since recognition of longPress implies not-invoking onPress
|
35
|
+
longPressDetected = false;
|
36
|
+
pointerInside = true;
|
37
|
+
// State of touchable
|
38
|
+
STATE = TOUCHABLE_STATE.UNDETERMINED;
|
39
|
+
// handlePressIn in called on first touch on traveling inside component.
|
40
|
+
// Handles state transition with delay.
|
41
|
+
handlePressIn() {
|
42
|
+
if (this.props.delayPressIn) {
|
43
|
+
this.pressInTimeout = setTimeout(() => {
|
44
|
+
this.moveToState(TOUCHABLE_STATE.BEGAN);
|
45
|
+
this.pressInTimeout = null;
|
46
|
+
}, this.props.delayPressIn);
|
47
|
+
}
|
48
|
+
else {
|
49
|
+
this.moveToState(TOUCHABLE_STATE.BEGAN);
|
50
|
+
}
|
51
|
+
if (this.props.onLongPress) {
|
52
|
+
const time = (this.props.delayPressIn || 0) + (this.props.delayLongPress || 0);
|
53
|
+
this.longPressTimeout = setTimeout(this.onLongPressDetected, time);
|
54
|
+
}
|
55
|
+
}
|
56
|
+
// handleMoveOutside in called on traveling outside component.
|
57
|
+
// Handles state transition with delay.
|
58
|
+
handleMoveOutside() {
|
59
|
+
if (this.props.delayPressOut) {
|
60
|
+
this.pressOutTimeout =
|
61
|
+
this.pressOutTimeout ||
|
62
|
+
setTimeout(() => {
|
63
|
+
this.moveToState(TOUCHABLE_STATE.MOVED_OUTSIDE);
|
64
|
+
this.pressOutTimeout = null;
|
65
|
+
}, this.props.delayPressOut);
|
66
|
+
}
|
67
|
+
else {
|
68
|
+
this.moveToState(TOUCHABLE_STATE.MOVED_OUTSIDE);
|
69
|
+
}
|
70
|
+
}
|
71
|
+
// handleGoToUndetermined transits to UNDETERMINED state with proper delay
|
72
|
+
handleGoToUndetermined() {
|
73
|
+
clearTimeout(this.pressOutTimeout); // TODO: maybe it can be undefined
|
74
|
+
if (this.props.delayPressOut) {
|
75
|
+
this.pressOutTimeout = setTimeout(() => {
|
76
|
+
if (this.STATE === TOUCHABLE_STATE.UNDETERMINED) {
|
77
|
+
this.moveToState(TOUCHABLE_STATE.BEGAN);
|
78
|
+
}
|
79
|
+
this.moveToState(TOUCHABLE_STATE.UNDETERMINED);
|
80
|
+
this.pressOutTimeout = null;
|
81
|
+
}, this.props.delayPressOut);
|
82
|
+
}
|
83
|
+
else {
|
84
|
+
if (this.STATE === TOUCHABLE_STATE.UNDETERMINED) {
|
85
|
+
this.moveToState(TOUCHABLE_STATE.BEGAN);
|
86
|
+
}
|
87
|
+
this.moveToState(TOUCHABLE_STATE.UNDETERMINED);
|
88
|
+
}
|
89
|
+
}
|
90
|
+
componentDidMount() {
|
91
|
+
this.reset();
|
92
|
+
}
|
93
|
+
// Reset timeout to prevent memory leaks.
|
94
|
+
reset() {
|
95
|
+
this.longPressDetected = false;
|
96
|
+
this.pointerInside = true;
|
97
|
+
clearTimeout(this.pressInTimeout);
|
98
|
+
clearTimeout(this.pressOutTimeout);
|
99
|
+
clearTimeout(this.longPressTimeout);
|
100
|
+
this.pressOutTimeout = null;
|
101
|
+
this.longPressTimeout = null;
|
102
|
+
this.pressInTimeout = null;
|
103
|
+
}
|
104
|
+
// All states' transitions are defined here.
|
105
|
+
moveToState(newState) {
|
106
|
+
if (newState === this.STATE) {
|
107
|
+
// Ignore dummy transitions
|
108
|
+
return;
|
109
|
+
}
|
110
|
+
if (newState === TOUCHABLE_STATE.BEGAN) {
|
111
|
+
// First touch and moving inside
|
112
|
+
this.props.onPressIn?.();
|
113
|
+
}
|
114
|
+
else if (newState === TOUCHABLE_STATE.MOVED_OUTSIDE) {
|
115
|
+
// Moving outside
|
116
|
+
this.props.onPressOut?.();
|
117
|
+
}
|
118
|
+
else if (newState === TOUCHABLE_STATE.UNDETERMINED) {
|
119
|
+
// Need to reset each time on transition to UNDETERMINED
|
120
|
+
this.reset();
|
121
|
+
if (this.STATE === TOUCHABLE_STATE.BEGAN) {
|
122
|
+
// ... and if it happens inside button.
|
123
|
+
this.props.onPressOut?.();
|
124
|
+
}
|
125
|
+
}
|
126
|
+
// Finally call lister (used by subclasses)
|
127
|
+
this.props.onStateChange?.(this.STATE, newState);
|
128
|
+
// ... and make transition.
|
129
|
+
this.STATE = newState;
|
130
|
+
}
|
131
|
+
onGestureEvent = ({ nativeEvent: { pointerInside }, }) => {
|
132
|
+
if (this.pointerInside !== pointerInside) {
|
133
|
+
if (pointerInside) {
|
134
|
+
this.onMoveIn();
|
135
|
+
}
|
136
|
+
else {
|
137
|
+
this.onMoveOut();
|
138
|
+
}
|
139
|
+
}
|
140
|
+
this.pointerInside = pointerInside;
|
141
|
+
};
|
142
|
+
onHandlerStateChange = ({ nativeEvent, }) => {
|
143
|
+
const { state } = nativeEvent;
|
144
|
+
if (state === State.CANCELLED || state === State.FAILED) {
|
145
|
+
// Need to handle case with external cancellation (e.g. by ScrollView)
|
146
|
+
this.moveToState(TOUCHABLE_STATE.UNDETERMINED);
|
147
|
+
}
|
148
|
+
else if (
|
149
|
+
// This platform check is an implication of slightly different behavior of handlers on different platform.
|
150
|
+
// And Android "Active" state is achieving on first move of a finger, not on press in.
|
151
|
+
// On iOS event on "Began" is not delivered.
|
152
|
+
state === (Platform.OS !== 'android' ? State.ACTIVE : State.BEGAN) &&
|
153
|
+
this.STATE === TOUCHABLE_STATE.UNDETERMINED) {
|
154
|
+
// Moving inside requires
|
155
|
+
this.handlePressIn();
|
156
|
+
}
|
157
|
+
else if (state === State.END) {
|
158
|
+
const shouldCallOnPress = !this.longPressDetected &&
|
159
|
+
this.STATE !== TOUCHABLE_STATE.MOVED_OUTSIDE &&
|
160
|
+
this.pressOutTimeout === null;
|
161
|
+
this.handleGoToUndetermined();
|
162
|
+
if (shouldCallOnPress) {
|
163
|
+
// Calls only inside component whether no long press was called previously
|
164
|
+
this.props.onPress?.();
|
165
|
+
}
|
166
|
+
}
|
167
|
+
};
|
168
|
+
onLongPressDetected = () => {
|
169
|
+
this.longPressDetected = true;
|
170
|
+
// Checked for in the caller of `onLongPressDetected`, but better to check twice
|
171
|
+
this.props.onLongPress?.();
|
172
|
+
};
|
173
|
+
componentWillUnmount() {
|
174
|
+
// To prevent memory leaks
|
175
|
+
this.reset();
|
176
|
+
}
|
177
|
+
onMoveIn() {
|
178
|
+
if (this.STATE === TOUCHABLE_STATE.MOVED_OUTSIDE) {
|
179
|
+
// This call is not throttled with delays (like in RN's implementation).
|
180
|
+
this.moveToState(TOUCHABLE_STATE.BEGAN);
|
181
|
+
}
|
182
|
+
}
|
183
|
+
onMoveOut() {
|
184
|
+
// Long press should no longer be detected
|
185
|
+
clearTimeout(this.longPressTimeout);
|
186
|
+
this.longPressTimeout = null;
|
187
|
+
if (this.STATE === TOUCHABLE_STATE.BEGAN) {
|
188
|
+
this.handleMoveOutside();
|
189
|
+
}
|
190
|
+
}
|
191
|
+
render() {
|
192
|
+
const hitSlop = (typeof this.props.hitSlop === 'number'
|
193
|
+
? {
|
194
|
+
top: this.props.hitSlop,
|
195
|
+
left: this.props.hitSlop,
|
196
|
+
bottom: this.props.hitSlop,
|
197
|
+
right: this.props.hitSlop,
|
198
|
+
}
|
199
|
+
: this.props.hitSlop) ?? undefined;
|
200
|
+
const coreProps = {
|
201
|
+
accessible: this.props.accessible !== false,
|
202
|
+
accessibilityLabel: this.props.accessibilityLabel,
|
203
|
+
accessibilityHint: this.props.accessibilityHint,
|
204
|
+
accessibilityRole: this.props.accessibilityRole,
|
205
|
+
// TODO: check if changed to no 's' correctly, also removed 2 props that are no longer available: `accessibilityComponentType` and `accessibilityTraits`,
|
206
|
+
// would be good to check if it is ok for sure, see: https://github.com/facebook/react-native/issues/24016
|
207
|
+
accessibilityState: this.props.accessibilityState,
|
208
|
+
accessibilityActions: this.props.accessibilityActions,
|
209
|
+
onAccessibilityAction: this.props.onAccessibilityAction,
|
210
|
+
nativeID: this.props.nativeID,
|
211
|
+
onLayout: this.props.onLayout,
|
212
|
+
};
|
213
|
+
return (<BaseButton style={this.props.containerStyle} onHandlerStateChange={
|
214
|
+
// TODO: not sure if it can be undefined instead of null
|
215
|
+
this.props.disabled ? undefined : this.onHandlerStateChange} onGestureEvent={this.onGestureEvent} hitSlop={hitSlop} userSelect={this.props.userSelect} shouldActivateOnStart={this.props.shouldActivateOnStart} disallowInterruption={this.props.disallowInterruption} testID={this.props.testID} touchSoundDisabled={this.props.touchSoundDisabled ?? false} enabled={!this.props.disabled} {...this.props.extraButtonProps}>
|
216
|
+
<Animated.View {...coreProps} style={this.props.style}>
|
217
|
+
{this.props.children}
|
218
|
+
</Animated.View>
|
219
|
+
</BaseButton>);
|
220
|
+
}
|
221
|
+
}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import type { StyleProp, ViewStyle, TouchableWithoutFeedbackProps, Insets } from 'react-native';
|
2
|
+
import type { UserSelect } from '../../handlers/gestureHandlerCommon';
|
3
|
+
import { ExtraButtonProps } from './ExtraButtonProps';
|
4
|
+
export interface GenericTouchableProps extends Omit<TouchableWithoutFeedbackProps, 'hitSlop'> {
|
5
|
+
onPress?: () => void;
|
6
|
+
onPressIn?: () => void;
|
7
|
+
onPressOut?: () => void;
|
8
|
+
onLongPress?: () => void;
|
9
|
+
nativeID?: string;
|
10
|
+
shouldActivateOnStart?: boolean;
|
11
|
+
disallowInterruption?: boolean;
|
12
|
+
containerStyle?: StyleProp<ViewStyle>;
|
13
|
+
hitSlop?: Insets | number;
|
14
|
+
userSelect?: UserSelect;
|
15
|
+
extraButtonProps?: ExtraButtonProps;
|
16
|
+
}
|