react-native-gesture-handler 2.22.1 → 2.23.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (677) hide show
  1. package/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerButtonViewManager.kt +14 -0
  2. package/android/src/main/jni/cpp-adapter.cpp +19 -12
  3. package/apple/RNGestureHandler.mm +15 -8
  4. package/apple/RNGestureHandlerModule.mm +17 -5
  5. package/lib/commonjs/ActionType.js +3 -3
  6. package/lib/commonjs/ActionType.js.map +1 -1
  7. package/lib/commonjs/Directions.js +11 -8
  8. package/lib/commonjs/Directions.js.map +1 -1
  9. package/lib/commonjs/EnableNewWebImplementation.js +2 -10
  10. package/lib/commonjs/EnableNewWebImplementation.js.map +1 -1
  11. package/lib/commonjs/GestureHandlerRootViewContext.js +2 -7
  12. package/lib/commonjs/GestureHandlerRootViewContext.js.map +1 -1
  13. package/lib/commonjs/PlatformConstants.js +1 -6
  14. package/lib/commonjs/PlatformConstants.js.map +1 -1
  15. package/lib/commonjs/PlatformConstants.web.js +1 -3
  16. package/lib/commonjs/PlatformConstants.web.js.map +1 -1
  17. package/lib/commonjs/PointerType.js +3 -5
  18. package/lib/commonjs/PointerType.js.map +1 -1
  19. package/lib/commonjs/RNGestureHandlerModule.js +2 -6
  20. package/lib/commonjs/RNGestureHandlerModule.js.map +1 -1
  21. package/lib/commonjs/RNGestureHandlerModule.web.js +13 -39
  22. package/lib/commonjs/RNGestureHandlerModule.web.js.map +1 -1
  23. package/lib/commonjs/RNGestureHandlerModule.windows.js +22 -32
  24. package/lib/commonjs/RNGestureHandlerModule.windows.js.map +1 -1
  25. package/lib/commonjs/RNRenderer.js +1 -3
  26. package/lib/commonjs/RNRenderer.js.map +1 -1
  27. package/lib/commonjs/RNRenderer.web.js +1 -2
  28. package/lib/commonjs/RNRenderer.web.js.map +1 -1
  29. package/lib/commonjs/State.js +4 -3
  30. package/lib/commonjs/State.js.map +1 -1
  31. package/lib/commonjs/TouchEventType.js +3 -3
  32. package/lib/commonjs/TouchEventType.js.map +1 -1
  33. package/lib/commonjs/components/DrawerLayout.js +96 -115
  34. package/lib/commonjs/components/DrawerLayout.js.map +1 -1
  35. package/lib/commonjs/components/GestureButtons.js +36 -80
  36. package/lib/commonjs/components/GestureButtons.js.map +1 -1
  37. package/lib/commonjs/components/GestureButtonsProps.js.map +1 -1
  38. package/lib/commonjs/components/GestureComponents.js +26 -37
  39. package/lib/commonjs/components/GestureComponents.js.map +1 -1
  40. package/lib/commonjs/components/GestureComponents.web.js +13 -27
  41. package/lib/commonjs/components/GestureComponents.web.js.map +1 -1
  42. package/lib/commonjs/components/GestureHandlerButton.js +2 -6
  43. package/lib/commonjs/components/GestureHandlerButton.js.map +1 -1
  44. package/lib/commonjs/components/GestureHandlerButton.web.js +4 -12
  45. package/lib/commonjs/components/GestureHandlerButton.web.js.map +1 -1
  46. package/lib/commonjs/components/GestureHandlerRootView.android.js +4 -15
  47. package/lib/commonjs/components/GestureHandlerRootView.android.js.map +1 -1
  48. package/lib/commonjs/components/GestureHandlerRootView.js +4 -14
  49. package/lib/commonjs/components/GestureHandlerRootView.js.map +1 -1
  50. package/lib/commonjs/components/GestureHandlerRootView.web.js +4 -13
  51. package/lib/commonjs/components/GestureHandlerRootView.web.js.map +1 -1
  52. package/lib/commonjs/components/Pressable/Pressable.js +46 -78
  53. package/lib/commonjs/components/Pressable/Pressable.js.map +1 -1
  54. package/lib/commonjs/components/Pressable/PressableProps.js.map +1 -1
  55. package/lib/commonjs/components/Pressable/index.js +1 -3
  56. package/lib/commonjs/components/Pressable/index.js.map +1 -1
  57. package/lib/commonjs/components/Pressable/utils.js +5 -20
  58. package/lib/commonjs/components/Pressable/utils.js.map +1 -1
  59. package/lib/commonjs/components/ReanimatedDrawerLayout.js +38 -76
  60. package/lib/commonjs/components/ReanimatedDrawerLayout.js.map +1 -1
  61. package/lib/commonjs/components/ReanimatedSwipeable.js +61 -59
  62. package/lib/commonjs/components/ReanimatedSwipeable.js.map +1 -1
  63. package/lib/commonjs/components/Swipeable.js +34 -75
  64. package/lib/commonjs/components/Swipeable.js.map +1 -1
  65. package/lib/commonjs/components/Text.js +18 -26
  66. package/lib/commonjs/components/Text.js.map +1 -1
  67. package/lib/commonjs/components/gestureHandlerRootHOC.js +5 -14
  68. package/lib/commonjs/components/gestureHandlerRootHOC.js.map +1 -1
  69. package/lib/commonjs/components/touchables/GenericTouchable.js +40 -76
  70. package/lib/commonjs/components/touchables/GenericTouchable.js.map +1 -1
  71. package/lib/commonjs/components/touchables/GenericTouchableProps.js.map +1 -1
  72. package/lib/commonjs/components/touchables/TouchableHighlight.js +20 -33
  73. package/lib/commonjs/components/touchables/TouchableHighlight.js.map +1 -1
  74. package/lib/commonjs/components/touchables/TouchableNativeFeedback.android.js +17 -31
  75. package/lib/commonjs/components/touchables/TouchableNativeFeedback.android.js.map +1 -1
  76. package/lib/commonjs/components/touchables/TouchableNativeFeedback.js +5 -4
  77. package/lib/commonjs/components/touchables/TouchableNativeFeedback.js.map +1 -1
  78. package/lib/commonjs/components/touchables/TouchableNativeFeedbackProps.js.map +1 -1
  79. package/lib/commonjs/components/touchables/TouchableOpacity.js +17 -24
  80. package/lib/commonjs/components/touchables/TouchableOpacity.js.map +1 -1
  81. package/lib/commonjs/components/touchables/TouchableWithoutFeedback.js +12 -13
  82. package/lib/commonjs/components/touchables/TouchableWithoutFeedback.js.map +1 -1
  83. package/lib/commonjs/components/touchables/index.js +7 -12
  84. package/lib/commonjs/components/touchables/index.js.map +1 -1
  85. package/lib/commonjs/findNodeHandle.js +1 -4
  86. package/lib/commonjs/findNodeHandle.js.map +1 -1
  87. package/lib/commonjs/findNodeHandle.web.js +9 -10
  88. package/lib/commonjs/findNodeHandle.web.js.map +1 -1
  89. package/lib/commonjs/getReactNativeVersion.js +1 -6
  90. package/lib/commonjs/getReactNativeVersion.js.map +1 -1
  91. package/lib/commonjs/getReactNativeVersion.web.js +0 -1
  92. package/lib/commonjs/getReactNativeVersion.web.js.map +1 -1
  93. package/lib/commonjs/getShadowNodeFromRef.js +13 -14
  94. package/lib/commonjs/getShadowNodeFromRef.js.map +1 -1
  95. package/lib/commonjs/getShadowNodeFromRef.web.js +0 -1
  96. package/lib/commonjs/getShadowNodeFromRef.web.js.map +1 -1
  97. package/lib/commonjs/ghQueueMicrotask.js +1 -2
  98. package/lib/commonjs/ghQueueMicrotask.js.map +1 -1
  99. package/lib/commonjs/handlers/FlingGestureHandler.js +16 -10
  100. package/lib/commonjs/handlers/FlingGestureHandler.js.map +1 -1
  101. package/lib/commonjs/handlers/ForceTouchGestureHandler.js +20 -23
  102. package/lib/commonjs/handlers/ForceTouchGestureHandler.js.map +1 -1
  103. package/lib/commonjs/handlers/GestureHandlerEventPayload.js.map +1 -1
  104. package/lib/commonjs/handlers/LongPressGestureHandler.js +16 -10
  105. package/lib/commonjs/handlers/LongPressGestureHandler.js.map +1 -1
  106. package/lib/commonjs/handlers/NativeViewGestureHandler.js +17 -12
  107. package/lib/commonjs/handlers/NativeViewGestureHandler.js.map +1 -1
  108. package/lib/commonjs/handlers/PanGestureHandler.js +20 -31
  109. package/lib/commonjs/handlers/PanGestureHandler.js.map +1 -1
  110. package/lib/commonjs/handlers/PinchGestureHandler.js +14 -8
  111. package/lib/commonjs/handlers/PinchGestureHandler.js.map +1 -1
  112. package/lib/commonjs/handlers/PressabilityDebugView.js +0 -1
  113. package/lib/commonjs/handlers/PressabilityDebugView.js.map +1 -1
  114. package/lib/commonjs/handlers/PressabilityDebugView.web.js +0 -1
  115. package/lib/commonjs/handlers/PressabilityDebugView.web.js.map +1 -1
  116. package/lib/commonjs/handlers/RotationGestureHandler.js +14 -8
  117. package/lib/commonjs/handlers/RotationGestureHandler.js.map +1 -1
  118. package/lib/commonjs/handlers/TapGestureHandler.js +16 -10
  119. package/lib/commonjs/handlers/TapGestureHandler.js.map +1 -1
  120. package/lib/commonjs/handlers/createHandler.js +55 -135
  121. package/lib/commonjs/handlers/createHandler.js.map +1 -1
  122. package/lib/commonjs/handlers/createNativeWrapper.js +17 -27
  123. package/lib/commonjs/handlers/createNativeWrapper.js.map +1 -1
  124. package/lib/commonjs/handlers/customDirectEventTypes.js +0 -1
  125. package/lib/commonjs/handlers/customDirectEventTypes.js.map +1 -1
  126. package/lib/commonjs/handlers/customDirectEventTypes.web.js +1 -2
  127. package/lib/commonjs/handlers/customDirectEventTypes.web.js.map +1 -1
  128. package/lib/commonjs/handlers/gestureHandlerCommon.js +9 -10
  129. package/lib/commonjs/handlers/gestureHandlerCommon.js.map +1 -1
  130. package/lib/commonjs/handlers/gestureHandlerTypesCompat.js.map +1 -1
  131. package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.js +5 -14
  132. package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.js.map +1 -1
  133. package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.web.js +10 -20
  134. package/lib/commonjs/handlers/gestures/GestureDetector/Wrap.web.js.map +1 -1
  135. package/lib/commonjs/handlers/gestures/GestureDetector/attachHandlers.js +9 -29
  136. package/lib/commonjs/handlers/gestures/GestureDetector/attachHandlers.js.map +1 -1
  137. package/lib/commonjs/handlers/gestures/GestureDetector/dropHandlers.js +1 -10
  138. package/lib/commonjs/handlers/gestures/GestureDetector/dropHandlers.js.map +1 -1
  139. package/lib/commonjs/handlers/gestures/GestureDetector/index.js +12 -37
  140. package/lib/commonjs/handlers/gestures/GestureDetector/index.js.map +1 -1
  141. package/lib/commonjs/handlers/gestures/GestureDetector/needsToReattach.js +0 -3
  142. package/lib/commonjs/handlers/gestures/GestureDetector/needsToReattach.js.map +1 -1
  143. package/lib/commonjs/handlers/gestures/GestureDetector/types.js.map +1 -1
  144. package/lib/commonjs/handlers/gestures/GestureDetector/updateHandlers.js +12 -24
  145. package/lib/commonjs/handlers/gestures/GestureDetector/updateHandlers.js.map +1 -1
  146. package/lib/commonjs/handlers/gestures/GestureDetector/useAnimatedGesture.js +12 -48
  147. package/lib/commonjs/handlers/gestures/GestureDetector/useAnimatedGesture.js.map +1 -1
  148. package/lib/commonjs/handlers/gestures/GestureDetector/useDetectorUpdater.js +3 -13
  149. package/lib/commonjs/handlers/gestures/GestureDetector/useDetectorUpdater.js.map +1 -1
  150. package/lib/commonjs/handlers/gestures/GestureDetector/useMountReactions.js +2 -9
  151. package/lib/commonjs/handlers/gestures/GestureDetector/useMountReactions.js.map +1 -1
  152. package/lib/commonjs/handlers/gestures/GestureDetector/useViewRefHandler.js +8 -16
  153. package/lib/commonjs/handlers/gestures/GestureDetector/useViewRefHandler.js.map +1 -1
  154. package/lib/commonjs/handlers/gestures/GestureDetector/utils.js +28 -56
  155. package/lib/commonjs/handlers/gestures/GestureDetector/utils.js.map +1 -1
  156. package/lib/commonjs/handlers/gestures/eventReceiver.js +14 -46
  157. package/lib/commonjs/handlers/gestures/eventReceiver.js.map +1 -1
  158. package/lib/commonjs/handlers/gestures/flingGesture.js +5 -12
  159. package/lib/commonjs/handlers/gestures/flingGesture.js.map +1 -1
  160. package/lib/commonjs/handlers/gestures/forceTouchGesture.js +8 -19
  161. package/lib/commonjs/handlers/gestures/forceTouchGesture.js.map +1 -1
  162. package/lib/commonjs/handlers/gestures/gesture.js +44 -84
  163. package/lib/commonjs/handlers/gestures/gesture.js.map +1 -1
  164. package/lib/commonjs/handlers/gestures/gestureComposition.js +17 -31
  165. package/lib/commonjs/handlers/gestures/gestureComposition.js.map +1 -1
  166. package/lib/commonjs/handlers/gestures/gestureObjects.js +1 -27
  167. package/lib/commonjs/handlers/gestures/gestureObjects.js.map +1 -1
  168. package/lib/commonjs/handlers/gestures/gestureStateManager.js +3 -9
  169. package/lib/commonjs/handlers/gestures/gestureStateManager.js.map +1 -1
  170. package/lib/commonjs/handlers/gestures/gestureStateManager.web.js +2 -7
  171. package/lib/commonjs/handlers/gestures/gestureStateManager.web.js.map +1 -1
  172. package/lib/commonjs/handlers/gestures/hoverGesture.js +11 -25
  173. package/lib/commonjs/handlers/gestures/hoverGesture.js.map +1 -1
  174. package/lib/commonjs/handlers/gestures/longPressGesture.js +6 -14
  175. package/lib/commonjs/handlers/gestures/longPressGesture.js.map +1 -1
  176. package/lib/commonjs/handlers/gestures/manualGesture.js +0 -6
  177. package/lib/commonjs/handlers/gestures/manualGesture.js.map +1 -1
  178. package/lib/commonjs/handlers/gestures/nativeGesture.js +5 -12
  179. package/lib/commonjs/handlers/gestures/nativeGesture.js.map +1 -1
  180. package/lib/commonjs/handlers/gestures/panGesture.js +18 -43
  181. package/lib/commonjs/handlers/gestures/panGesture.js.map +1 -1
  182. package/lib/commonjs/handlers/gestures/pinchGesture.js +2 -9
  183. package/lib/commonjs/handlers/gestures/pinchGesture.js.map +1 -1
  184. package/lib/commonjs/handlers/gestures/reanimatedWrapper.js +1 -8
  185. package/lib/commonjs/handlers/gestures/reanimatedWrapper.js.map +1 -1
  186. package/lib/commonjs/handlers/gestures/rotationGesture.js +2 -9
  187. package/lib/commonjs/handlers/gestures/rotationGesture.js.map +1 -1
  188. package/lib/commonjs/handlers/gestures/tapGesture.js +10 -22
  189. package/lib/commonjs/handlers/gestures/tapGesture.js.map +1 -1
  190. package/lib/commonjs/handlers/getNextHandlerTag.js +0 -1
  191. package/lib/commonjs/handlers/getNextHandlerTag.js.map +1 -1
  192. package/lib/commonjs/handlers/handlersRegistry.js +11 -21
  193. package/lib/commonjs/handlers/handlersRegistry.js.map +1 -1
  194. package/lib/commonjs/handlers/utils.js +6 -26
  195. package/lib/commonjs/handlers/utils.js.map +1 -1
  196. package/lib/commonjs/index.js +75 -104
  197. package/lib/commonjs/index.js.map +1 -1
  198. package/lib/commonjs/init.js +4 -11
  199. package/lib/commonjs/init.js.map +1 -1
  200. package/lib/commonjs/jestUtils/index.js +4 -5
  201. package/lib/commonjs/jestUtils/index.js.map +1 -1
  202. package/lib/commonjs/jestUtils/jestUtils.js +19 -83
  203. package/lib/commonjs/jestUtils/jestUtils.js.map +1 -1
  204. package/lib/commonjs/mocks.js +5 -15
  205. package/lib/commonjs/mocks.js.map +1 -1
  206. package/lib/commonjs/mountRegistry.js +3 -12
  207. package/lib/commonjs/mountRegistry.js.map +1 -1
  208. package/lib/commonjs/specs/NativeRNGestureHandlerModule.js +1 -5
  209. package/lib/commonjs/specs/NativeRNGestureHandlerModule.js.map +1 -1
  210. package/lib/commonjs/specs/RNGestureHandlerButtonNativeComponent.js +2 -7
  211. package/lib/commonjs/specs/RNGestureHandlerButtonNativeComponent.js.map +1 -1
  212. package/lib/commonjs/specs/RNGestureHandlerRootViewNativeComponent.js +2 -7
  213. package/lib/commonjs/specs/RNGestureHandlerRootViewNativeComponent.js.map +1 -1
  214. package/lib/commonjs/typeUtils.js.map +1 -1
  215. package/lib/commonjs/utils.js +15 -30
  216. package/lib/commonjs/utils.js.map +1 -1
  217. package/lib/commonjs/web/Gestures.js +5 -23
  218. package/lib/commonjs/web/Gestures.js.map +1 -1
  219. package/lib/commonjs/web/constants.js +2 -4
  220. package/lib/commonjs/web/constants.js.map +1 -1
  221. package/lib/commonjs/web/detectors/RotationGestureDetector.js +26 -62
  222. package/lib/commonjs/web/detectors/RotationGestureDetector.js.map +1 -1
  223. package/lib/commonjs/web/detectors/ScaleGestureDetector.js +36 -65
  224. package/lib/commonjs/web/detectors/ScaleGestureDetector.js.map +1 -1
  225. package/lib/commonjs/web/handlers/FlingGestureHandler.js +12 -55
  226. package/lib/commonjs/web/handlers/FlingGestureHandler.js.map +1 -1
  227. package/lib/commonjs/web/handlers/GestureHandler.js +160 -273
  228. package/lib/commonjs/web/handlers/GestureHandler.js.map +1 -1
  229. package/lib/commonjs/web/handlers/HoverGestureHandler.js +8 -21
  230. package/lib/commonjs/web/handlers/HoverGestureHandler.js.map +1 -1
  231. package/lib/commonjs/web/handlers/IGestureHandler.js.map +1 -1
  232. package/lib/commonjs/web/handlers/LongPressGestureHandler.js +12 -53
  233. package/lib/commonjs/web/handlers/LongPressGestureHandler.js.map +1 -1
  234. package/lib/commonjs/web/handlers/ManualGestureHandler.js +1 -11
  235. package/lib/commonjs/web/handlers/ManualGestureHandler.js.map +1 -1
  236. package/lib/commonjs/web/handlers/NativeViewGestureHandler.js +21 -62
  237. package/lib/commonjs/web/handlers/NativeViewGestureHandler.js.map +1 -1
  238. package/lib/commonjs/web/handlers/PanGestureHandler.js +23 -138
  239. package/lib/commonjs/web/handlers/PanGestureHandler.js.map +1 -1
  240. package/lib/commonjs/web/handlers/PinchGestureHandler.js +19 -56
  241. package/lib/commonjs/web/handlers/PinchGestureHandler.js.map +1 -1
  242. package/lib/commonjs/web/handlers/RotationGestureHandler.js +16 -54
  243. package/lib/commonjs/web/handlers/RotationGestureHandler.js.map +1 -1
  244. package/lib/commonjs/web/handlers/TapGestureHandler.js +10 -71
  245. package/lib/commonjs/web/handlers/TapGestureHandler.js.map +1 -1
  246. package/lib/commonjs/web/interfaces.js +9 -17
  247. package/lib/commonjs/web/interfaces.js.map +1 -1
  248. package/lib/commonjs/web/tools/CircularBuffer.js +17 -29
  249. package/lib/commonjs/web/tools/CircularBuffer.js.map +1 -1
  250. package/lib/commonjs/web/tools/EventManager.js +7 -41
  251. package/lib/commonjs/web/tools/EventManager.js.map +1 -1
  252. package/lib/commonjs/web/tools/GestureHandlerDelegate.js.map +1 -1
  253. package/lib/commonjs/web/tools/GestureHandlerOrchestrator.js +51 -118
  254. package/lib/commonjs/web/tools/GestureHandlerOrchestrator.js.map +1 -1
  255. package/lib/commonjs/web/tools/GestureHandlerWebDelegate.js +37 -58
  256. package/lib/commonjs/web/tools/GestureHandlerWebDelegate.js.map +1 -1
  257. package/lib/commonjs/web/tools/InteractionManager.js +21 -40
  258. package/lib/commonjs/web/tools/InteractionManager.js.map +1 -1
  259. package/lib/commonjs/web/tools/KeyboardEventManager.js +4 -26
  260. package/lib/commonjs/web/tools/KeyboardEventManager.js.map +1 -1
  261. package/lib/commonjs/web/tools/LeastSquareSolver.js +30 -67
  262. package/lib/commonjs/web/tools/LeastSquareSolver.js.map +1 -1
  263. package/lib/commonjs/web/tools/NodeManager.js +9 -16
  264. package/lib/commonjs/web/tools/NodeManager.js.map +1 -1
  265. package/lib/commonjs/web/tools/PointerEventManager.js +10 -45
  266. package/lib/commonjs/web/tools/PointerEventManager.js.map +1 -1
  267. package/lib/commonjs/web/tools/PointerTracker.js +24 -60
  268. package/lib/commonjs/web/tools/PointerTracker.js.map +1 -1
  269. package/lib/commonjs/web/tools/Vector.js +3 -18
  270. package/lib/commonjs/web/tools/Vector.js.map +1 -1
  271. package/lib/commonjs/web/tools/VelocityTracker.js +10 -32
  272. package/lib/commonjs/web/tools/VelocityTracker.js.map +1 -1
  273. package/lib/commonjs/web/tools/WheelEventManager.js +4 -17
  274. package/lib/commonjs/web/tools/WheelEventManager.js.map +1 -1
  275. package/lib/commonjs/web/utils.js +26 -55
  276. package/lib/commonjs/web/utils.js.map +1 -1
  277. package/lib/commonjs/web_hammer/DiscreteGestureHandler.js +7 -19
  278. package/lib/commonjs/web_hammer/DiscreteGestureHandler.js.map +1 -1
  279. package/lib/commonjs/web_hammer/DraggingGestureHandler.js +3 -13
  280. package/lib/commonjs/web_hammer/DraggingGestureHandler.js.map +1 -1
  281. package/lib/commonjs/web_hammer/Errors.js +0 -3
  282. package/lib/commonjs/web_hammer/Errors.js.map +1 -1
  283. package/lib/commonjs/web_hammer/FlingGestureHandler.js +13 -44
  284. package/lib/commonjs/web_hammer/FlingGestureHandler.js.map +1 -1
  285. package/lib/commonjs/web_hammer/GestureHandler.js +55 -142
  286. package/lib/commonjs/web_hammer/GestureHandler.js.map +1 -1
  287. package/lib/commonjs/web_hammer/IndiscreteGestureHandler.js +2 -11
  288. package/lib/commonjs/web_hammer/IndiscreteGestureHandler.js.map +1 -1
  289. package/lib/commonjs/web_hammer/LongPressGestureHandler.js +5 -19
  290. package/lib/commonjs/web_hammer/LongPressGestureHandler.js.map +1 -1
  291. package/lib/commonjs/web_hammer/NativeViewGestureHandler.js +16 -24
  292. package/lib/commonjs/web_hammer/NativeViewGestureHandler.js.map +1 -1
  293. package/lib/commonjs/web_hammer/NodeManager.js +9 -16
  294. package/lib/commonjs/web_hammer/NodeManager.js.map +1 -1
  295. package/lib/commonjs/web_hammer/PanGestureHandler.js +8 -49
  296. package/lib/commonjs/web_hammer/PanGestureHandler.js.map +1 -1
  297. package/lib/commonjs/web_hammer/PinchGestureHandler.js +2 -11
  298. package/lib/commonjs/web_hammer/PinchGestureHandler.js.map +1 -1
  299. package/lib/commonjs/web_hammer/PressGestureHandler.js +15 -43
  300. package/lib/commonjs/web_hammer/PressGestureHandler.js.map +1 -1
  301. package/lib/commonjs/web_hammer/RotationGestureHandler.js +2 -13
  302. package/lib/commonjs/web_hammer/RotationGestureHandler.js.map +1 -1
  303. package/lib/commonjs/web_hammer/TapGestureHandler.js +33 -52
  304. package/lib/commonjs/web_hammer/TapGestureHandler.js.map +1 -1
  305. package/lib/commonjs/web_hammer/constants.js +13 -26
  306. package/lib/commonjs/web_hammer/constants.js.map +1 -1
  307. package/lib/commonjs/web_hammer/utils.js +4 -14
  308. package/lib/commonjs/web_hammer/utils.js.map +1 -1
  309. package/lib/module/ActionType.js +3 -1
  310. package/lib/module/ActionType.js.map +1 -1
  311. package/lib/module/Directions.js +9 -3
  312. package/lib/module/Directions.js.map +1 -1
  313. package/lib/module/EnableNewWebImplementation.js +2 -5
  314. package/lib/module/EnableNewWebImplementation.js.map +1 -1
  315. package/lib/module/GestureHandlerRootViewContext.js.map +1 -1
  316. package/lib/module/PlatformConstants.js +0 -1
  317. package/lib/module/PlatformConstants.js.map +1 -1
  318. package/lib/module/PlatformConstants.web.js +0 -1
  319. package/lib/module/PlatformConstants.web.js.map +1 -1
  320. package/lib/module/PointerType.js +3 -4
  321. package/lib/module/PointerType.js.map +1 -1
  322. package/lib/module/RNGestureHandlerModule.js +1 -0
  323. package/lib/module/RNGestureHandlerModule.js.map +1 -1
  324. package/lib/module/RNGestureHandlerModule.web.js +12 -22
  325. package/lib/module/RNGestureHandlerModule.web.js.map +1 -1
  326. package/lib/module/RNGestureHandlerModule.windows.js +18 -17
  327. package/lib/module/RNGestureHandlerModule.windows.js.map +1 -1
  328. package/lib/module/RNRenderer.js.map +1 -1
  329. package/lib/module/RNRenderer.web.js.map +1 -1
  330. package/lib/module/State.js +4 -1
  331. package/lib/module/State.js.map +1 -1
  332. package/lib/module/TouchEventType.js +3 -1
  333. package/lib/module/TouchEventType.js.map +1 -1
  334. package/lib/module/components/DrawerLayout.js +87 -99
  335. package/lib/module/components/DrawerLayout.js.map +1 -1
  336. package/lib/module/components/GestureButtons.js +27 -55
  337. package/lib/module/components/GestureButtons.js.map +1 -1
  338. package/lib/module/components/GestureButtonsProps.js.map +1 -1
  339. package/lib/module/components/GestureComponents.js +17 -12
  340. package/lib/module/components/GestureComponents.js.map +1 -1
  341. package/lib/module/components/GestureComponents.web.js +4 -4
  342. package/lib/module/components/GestureComponents.web.js.map +1 -1
  343. package/lib/module/components/GestureHandlerButton.js.map +1 -1
  344. package/lib/module/components/GestureHandlerButton.web.js +1 -2
  345. package/lib/module/components/GestureHandlerButton.web.js.map +1 -1
  346. package/lib/module/components/GestureHandlerRootView.android.js +1 -2
  347. package/lib/module/components/GestureHandlerRootView.android.js.map +1 -1
  348. package/lib/module/components/GestureHandlerRootView.js +1 -2
  349. package/lib/module/components/GestureHandlerRootView.js.map +1 -1
  350. package/lib/module/components/GestureHandlerRootView.web.js +1 -2
  351. package/lib/module/components/GestureHandlerRootView.web.js.map +1 -1
  352. package/lib/module/components/Pressable/Pressable.js +44 -61
  353. package/lib/module/components/Pressable/Pressable.js.map +1 -1
  354. package/lib/module/components/Pressable/PressableProps.js.map +1 -1
  355. package/lib/module/components/Pressable/index.js.map +1 -1
  356. package/lib/module/components/Pressable/utils.js +4 -14
  357. package/lib/module/components/Pressable/utils.js.map +1 -1
  358. package/lib/module/components/ReanimatedDrawerLayout.js +34 -56
  359. package/lib/module/components/ReanimatedDrawerLayout.js.map +1 -1
  360. package/lib/module/components/ReanimatedSwipeable.js +57 -44
  361. package/lib/module/components/ReanimatedSwipeable.js.map +1 -1
  362. package/lib/module/components/Swipeable.js +28 -59
  363. package/lib/module/components/Swipeable.js.map +1 -1
  364. package/lib/module/components/Text.js +14 -13
  365. package/lib/module/components/Text.js.map +1 -1
  366. package/lib/module/components/gestureHandlerRootHOC.js +2 -2
  367. package/lib/module/components/gestureHandlerRootHOC.js.map +1 -1
  368. package/lib/module/components/touchables/GenericTouchable.js +34 -63
  369. package/lib/module/components/touchables/GenericTouchable.js.map +1 -1
  370. package/lib/module/components/touchables/GenericTouchableProps.js.map +1 -1
  371. package/lib/module/components/touchables/TouchableHighlight.js +16 -23
  372. package/lib/module/components/touchables/TouchableHighlight.js.map +1 -1
  373. package/lib/module/components/touchables/TouchableNativeFeedback.android.js +11 -19
  374. package/lib/module/components/touchables/TouchableNativeFeedback.android.js.map +1 -1
  375. package/lib/module/components/touchables/TouchableNativeFeedback.js +6 -1
  376. package/lib/module/components/touchables/TouchableNativeFeedback.js.map +1 -1
  377. package/lib/module/components/touchables/TouchableNativeFeedbackProps.js.map +1 -1
  378. package/lib/module/components/touchables/TouchableOpacity.js +13 -14
  379. package/lib/module/components/touchables/TouchableOpacity.js.map +1 -1
  380. package/lib/module/components/touchables/TouchableWithoutFeedback.js +9 -2
  381. package/lib/module/components/touchables/TouchableWithoutFeedback.js.map +1 -1
  382. package/lib/module/components/touchables/index.js.map +1 -1
  383. package/lib/module/findNodeHandle.js.map +1 -1
  384. package/lib/module/findNodeHandle.web.js +9 -8
  385. package/lib/module/findNodeHandle.web.js.map +1 -1
  386. package/lib/module/getReactNativeVersion.js.map +1 -1
  387. package/lib/module/getReactNativeVersion.web.js.map +1 -1
  388. package/lib/module/getShadowNodeFromRef.js +13 -13
  389. package/lib/module/getShadowNodeFromRef.js.map +1 -1
  390. package/lib/module/getShadowNodeFromRef.web.js.map +1 -1
  391. package/lib/module/ghQueueMicrotask.js.map +1 -1
  392. package/lib/module/handlers/FlingGestureHandler.js +13 -0
  393. package/lib/module/handlers/FlingGestureHandler.js.map +1 -1
  394. package/lib/module/handlers/ForceTouchGestureHandler.js +16 -8
  395. package/lib/module/handlers/ForceTouchGestureHandler.js.map +1 -1
  396. package/lib/module/handlers/GestureHandlerEventPayload.js.map +1 -1
  397. package/lib/module/handlers/LongPressGestureHandler.js +13 -0
  398. package/lib/module/handlers/LongPressGestureHandler.js.map +1 -1
  399. package/lib/module/handlers/NativeViewGestureHandler.js +13 -0
  400. package/lib/module/handlers/NativeViewGestureHandler.js.map +1 -1
  401. package/lib/module/handlers/PanGestureHandler.js +15 -19
  402. package/lib/module/handlers/PanGestureHandler.js.map +1 -1
  403. package/lib/module/handlers/PinchGestureHandler.js +13 -0
  404. package/lib/module/handlers/PinchGestureHandler.js.map +1 -1
  405. package/lib/module/handlers/PressabilityDebugView.js.map +1 -1
  406. package/lib/module/handlers/PressabilityDebugView.web.js.map +1 -1
  407. package/lib/module/handlers/RotationGestureHandler.js +13 -0
  408. package/lib/module/handlers/RotationGestureHandler.js.map +1 -1
  409. package/lib/module/handlers/TapGestureHandler.js +13 -0
  410. package/lib/module/handlers/TapGestureHandler.js.map +1 -1
  411. package/lib/module/handlers/createHandler.js +54 -108
  412. package/lib/module/handlers/createHandler.js.map +1 -1
  413. package/lib/module/handlers/createNativeWrapper.js +12 -17
  414. package/lib/module/handlers/createNativeWrapper.js.map +1 -1
  415. package/lib/module/handlers/customDirectEventTypes.js.map +1 -1
  416. package/lib/module/handlers/customDirectEventTypes.web.js.map +1 -1
  417. package/lib/module/handlers/gestureHandlerCommon.js +9 -4
  418. package/lib/module/handlers/gestureHandlerCommon.js.map +1 -1
  419. package/lib/module/handlers/gestureHandlerTypesCompat.js.map +1 -1
  420. package/lib/module/handlers/gestures/GestureDetector/Wrap.js +3 -4
  421. package/lib/module/handlers/gestures/GestureDetector/Wrap.js.map +1 -1
  422. package/lib/module/handlers/gestures/GestureDetector/Wrap.web.js +5 -6
  423. package/lib/module/handlers/gestures/GestureDetector/Wrap.web.js.map +1 -1
  424. package/lib/module/handlers/gestures/GestureDetector/attachHandlers.js +8 -16
  425. package/lib/module/handlers/gestures/GestureDetector/attachHandlers.js.map +1 -1
  426. package/lib/module/handlers/gestures/GestureDetector/dropHandlers.js +0 -1
  427. package/lib/module/handlers/gestures/GestureDetector/dropHandlers.js.map +1 -1
  428. package/lib/module/handlers/gestures/GestureDetector/index.js +9 -15
  429. package/lib/module/handlers/gestures/GestureDetector/index.js.map +1 -1
  430. package/lib/module/handlers/gestures/GestureDetector/needsToReattach.js +0 -2
  431. package/lib/module/handlers/gestures/GestureDetector/needsToReattach.js.map +1 -1
  432. package/lib/module/handlers/gestures/GestureDetector/types.js.map +1 -1
  433. package/lib/module/handlers/gestures/GestureDetector/updateHandlers.js +11 -14
  434. package/lib/module/handlers/gestures/GestureDetector/updateHandlers.js.map +1 -1
  435. package/lib/module/handlers/gestures/GestureDetector/useAnimatedGesture.js +12 -39
  436. package/lib/module/handlers/gestures/GestureDetector/useAnimatedGesture.js.map +1 -1
  437. package/lib/module/handlers/gestures/GestureDetector/useDetectorUpdater.js +5 -5
  438. package/lib/module/handlers/gestures/GestureDetector/useDetectorUpdater.js.map +1 -1
  439. package/lib/module/handlers/gestures/GestureDetector/useMountReactions.js +2 -6
  440. package/lib/module/handlers/gestures/GestureDetector/useMountReactions.js.map +1 -1
  441. package/lib/module/handlers/gestures/GestureDetector/useViewRefHandler.js +7 -9
  442. package/lib/module/handlers/gestures/GestureDetector/useViewRefHandler.js.map +1 -1
  443. package/lib/module/handlers/gestures/GestureDetector/utils.js +25 -30
  444. package/lib/module/handlers/gestures/GestureDetector/utils.js.map +1 -1
  445. package/lib/module/handlers/gestures/eventReceiver.js +14 -38
  446. package/lib/module/handlers/gestures/eventReceiver.js.map +1 -1
  447. package/lib/module/handlers/gestures/flingGesture.js +5 -9
  448. package/lib/module/handlers/gestures/flingGesture.js.map +1 -1
  449. package/lib/module/handlers/gestures/forceTouchGesture.js +8 -17
  450. package/lib/module/handlers/gestures/forceTouchGesture.js.map +1 -1
  451. package/lib/module/handlers/gestures/gesture.js +44 -73
  452. package/lib/module/handlers/gestures/gesture.js.map +1 -1
  453. package/lib/module/handlers/gestures/gestureComposition.js +16 -24
  454. package/lib/module/handlers/gestures/gestureComposition.js.map +1 -1
  455. package/lib/module/handlers/gestures/gestureObjects.js +1 -14
  456. package/lib/module/handlers/gestures/gestureObjects.js.map +1 -1
  457. package/lib/module/handlers/gestures/gestureStateManager.js +3 -4
  458. package/lib/module/handlers/gestures/gestureStateManager.js.map +1 -1
  459. package/lib/module/handlers/gestures/gestureStateManager.web.js +0 -1
  460. package/lib/module/handlers/gestures/gestureStateManager.web.js.map +1 -1
  461. package/lib/module/handlers/gestures/hoverGesture.js +9 -18
  462. package/lib/module/handlers/gestures/hoverGesture.js.map +1 -1
  463. package/lib/module/handlers/gestures/longPressGesture.js +6 -11
  464. package/lib/module/handlers/gestures/longPressGesture.js.map +1 -1
  465. package/lib/module/handlers/gestures/manualGesture.js +0 -4
  466. package/lib/module/handlers/gestures/manualGesture.js.map +1 -1
  467. package/lib/module/handlers/gestures/nativeGesture.js +5 -9
  468. package/lib/module/handlers/gestures/nativeGesture.js.map +1 -1
  469. package/lib/module/handlers/gestures/panGesture.js +18 -41
  470. package/lib/module/handlers/gestures/panGesture.js.map +1 -1
  471. package/lib/module/handlers/gestures/pinchGesture.js +2 -7
  472. package/lib/module/handlers/gestures/pinchGesture.js.map +1 -1
  473. package/lib/module/handlers/gestures/reanimatedWrapper.js +0 -5
  474. package/lib/module/handlers/gestures/reanimatedWrapper.js.map +1 -1
  475. package/lib/module/handlers/gestures/rotationGesture.js +2 -7
  476. package/lib/module/handlers/gestures/rotationGesture.js.map +1 -1
  477. package/lib/module/handlers/gestures/tapGesture.js +10 -19
  478. package/lib/module/handlers/gestures/tapGesture.js.map +1 -1
  479. package/lib/module/handlers/getNextHandlerTag.js.map +1 -1
  480. package/lib/module/handlers/handlersRegistry.js +6 -8
  481. package/lib/module/handlers/handlersRegistry.js.map +1 -1
  482. package/lib/module/handlers/utils.js +4 -13
  483. package/lib/module/handlers/utils.js.map +1 -1
  484. package/lib/module/index.js.map +1 -1
  485. package/lib/module/init.js +3 -2
  486. package/lib/module/init.js.map +1 -1
  487. package/lib/module/jestUtils/index.js.map +1 -1
  488. package/lib/module/jestUtils/jestUtils.js +20 -66
  489. package/lib/module/jestUtils/jestUtils.js.map +1 -1
  490. package/lib/module/mocks.js +3 -7
  491. package/lib/module/mocks.js.map +1 -1
  492. package/lib/module/mountRegistry.js +3 -10
  493. package/lib/module/mountRegistry.js.map +1 -1
  494. package/lib/module/specs/NativeRNGestureHandlerModule.js.map +1 -1
  495. package/lib/module/specs/RNGestureHandlerButtonNativeComponent.js.map +1 -1
  496. package/lib/module/specs/RNGestureHandlerRootViewNativeComponent.js.map +1 -1
  497. package/lib/module/typeUtils.js.map +1 -1
  498. package/lib/module/utils.js +8 -13
  499. package/lib/module/utils.js.map +1 -1
  500. package/lib/module/web/Gestures.js +2 -1
  501. package/lib/module/web/Gestures.js.map +1 -1
  502. package/lib/module/web/constants.js.map +1 -1
  503. package/lib/module/web/detectors/RotationGestureDetector.js +26 -59
  504. package/lib/module/web/detectors/RotationGestureDetector.js.map +1 -1
  505. package/lib/module/web/detectors/ScaleGestureDetector.js +36 -61
  506. package/lib/module/web/detectors/ScaleGestureDetector.js.map +1 -1
  507. package/lib/module/web/handlers/FlingGestureHandler.js +11 -45
  508. package/lib/module/web/handlers/FlingGestureHandler.js.map +1 -1
  509. package/lib/module/web/handlers/GestureHandler.js +159 -259
  510. package/lib/module/web/handlers/GestureHandler.js.map +1 -1
  511. package/lib/module/web/handlers/HoverGestureHandler.js +7 -13
  512. package/lib/module/web/handlers/HoverGestureHandler.js.map +1 -1
  513. package/lib/module/web/handlers/IGestureHandler.js.map +1 -1
  514. package/lib/module/web/handlers/LongPressGestureHandler.js +11 -46
  515. package/lib/module/web/handlers/LongPressGestureHandler.js.map +1 -1
  516. package/lib/module/web/handlers/ManualGestureHandler.js +0 -6
  517. package/lib/module/web/handlers/ManualGestureHandler.js.map +1 -1
  518. package/lib/module/web/handlers/NativeViewGestureHandler.js +20 -54
  519. package/lib/module/web/handlers/NativeViewGestureHandler.js.map +1 -1
  520. package/lib/module/web/handlers/PanGestureHandler.js +22 -129
  521. package/lib/module/web/handlers/PanGestureHandler.js.map +1 -1
  522. package/lib/module/web/handlers/PinchGestureHandler.js +18 -48
  523. package/lib/module/web/handlers/PinchGestureHandler.js.map +1 -1
  524. package/lib/module/web/handlers/RotationGestureHandler.js +15 -46
  525. package/lib/module/web/handlers/RotationGestureHandler.js.map +1 -1
  526. package/lib/module/web/handlers/TapGestureHandler.js +9 -63
  527. package/lib/module/web/handlers/TapGestureHandler.js.map +1 -1
  528. package/lib/module/web/interfaces.js +9 -14
  529. package/lib/module/web/interfaces.js.map +1 -1
  530. package/lib/module/web/tools/CircularBuffer.js +17 -27
  531. package/lib/module/web/tools/CircularBuffer.js.map +1 -1
  532. package/lib/module/web/tools/EventManager.js +7 -39
  533. package/lib/module/web/tools/EventManager.js.map +1 -1
  534. package/lib/module/web/tools/GestureHandlerDelegate.js.map +1 -1
  535. package/lib/module/web/tools/GestureHandlerOrchestrator.js +50 -111
  536. package/lib/module/web/tools/GestureHandlerOrchestrator.js.map +1 -1
  537. package/lib/module/web/tools/GestureHandlerWebDelegate.js +36 -47
  538. package/lib/module/web/tools/GestureHandlerWebDelegate.js.map +1 -1
  539. package/lib/module/web/tools/InteractionManager.js +21 -35
  540. package/lib/module/web/tools/InteractionManager.js.map +1 -1
  541. package/lib/module/web/tools/KeyboardEventManager.js +3 -19
  542. package/lib/module/web/tools/KeyboardEventManager.js.map +1 -1
  543. package/lib/module/web/tools/LeastSquareSolver.js +30 -65
  544. package/lib/module/web/tools/LeastSquareSolver.js.map +1 -1
  545. package/lib/module/web/tools/NodeManager.js +9 -14
  546. package/lib/module/web/tools/NodeManager.js.map +1 -1
  547. package/lib/module/web/tools/PointerEventManager.js +9 -35
  548. package/lib/module/web/tools/PointerEventManager.js.map +1 -1
  549. package/lib/module/web/tools/PointerTracker.js +23 -54
  550. package/lib/module/web/tools/PointerTracker.js.map +1 -1
  551. package/lib/module/web/tools/Vector.js +3 -14
  552. package/lib/module/web/tools/Vector.js.map +1 -1
  553. package/lib/module/web/tools/VelocityTracker.js +9 -26
  554. package/lib/module/web/tools/VelocityTracker.js.map +1 -1
  555. package/lib/module/web/tools/WheelEventManager.js +3 -10
  556. package/lib/module/web/tools/WheelEventManager.js.map +1 -1
  557. package/lib/module/web/utils.js +21 -40
  558. package/lib/module/web/utils.js.map +1 -1
  559. package/lib/module/web_hammer/DiscreteGestureHandler.js +4 -13
  560. package/lib/module/web_hammer/DiscreteGestureHandler.js.map +1 -1
  561. package/lib/module/web_hammer/DraggingGestureHandler.js +0 -5
  562. package/lib/module/web_hammer/DraggingGestureHandler.js.map +1 -1
  563. package/lib/module/web_hammer/Errors.js +0 -1
  564. package/lib/module/web_hammer/Errors.js.map +1 -1
  565. package/lib/module/web_hammer/FlingGestureHandler.js +10 -35
  566. package/lib/module/web_hammer/FlingGestureHandler.js.map +1 -1
  567. package/lib/module/web_hammer/GestureHandler.js +53 -130
  568. package/lib/module/web_hammer/GestureHandler.js.map +1 -1
  569. package/lib/module/web_hammer/IndiscreteGestureHandler.js +1 -6
  570. package/lib/module/web_hammer/IndiscreteGestureHandler.js.map +1 -1
  571. package/lib/module/web_hammer/LongPressGestureHandler.js +2 -11
  572. package/lib/module/web_hammer/LongPressGestureHandler.js.map +1 -1
  573. package/lib/module/web_hammer/NativeViewGestureHandler.js +12 -12
  574. package/lib/module/web_hammer/NativeViewGestureHandler.js.map +1 -1
  575. package/lib/module/web_hammer/NodeManager.js +6 -8
  576. package/lib/module/web_hammer/NodeManager.js.map +1 -1
  577. package/lib/module/web_hammer/PanGestureHandler.js +6 -40
  578. package/lib/module/web_hammer/PanGestureHandler.js.map +1 -1
  579. package/lib/module/web_hammer/PinchGestureHandler.js +0 -5
  580. package/lib/module/web_hammer/PinchGestureHandler.js.map +1 -1
  581. package/lib/module/web_hammer/PressGestureHandler.js +13 -34
  582. package/lib/module/web_hammer/PressGestureHandler.js.map +1 -1
  583. package/lib/module/web_hammer/RotationGestureHandler.js +0 -6
  584. package/lib/module/web_hammer/RotationGestureHandler.js.map +1 -1
  585. package/lib/module/web_hammer/TapGestureHandler.js +31 -45
  586. package/lib/module/web_hammer/TapGestureHandler.js.map +1 -1
  587. package/lib/module/web_hammer/constants.js +2 -1
  588. package/lib/module/web_hammer/constants.js.map +1 -1
  589. package/lib/module/web_hammer/utils.js +2 -2
  590. package/lib/module/web_hammer/utils.js.map +1 -1
  591. package/lib/typescript/components/DrawerLayout.d.ts +27 -0
  592. package/lib/typescript/components/GestureButtonsProps.d.ts +18 -2
  593. package/lib/typescript/components/Pressable/PressableProps.d.ts +3 -10
  594. package/lib/typescript/components/Pressable/index.d.ts +1 -1
  595. package/lib/typescript/components/ReanimatedSwipeable.d.ts +6 -0
  596. package/lib/typescript/components/touchables/TouchableHighlight.d.ts +5 -0
  597. package/lib/typescript/components/touchables/TouchableNativeFeedback.android.d.ts +2 -0
  598. package/lib/typescript/components/touchables/TouchableNativeFeedback.d.ts +5 -1
  599. package/lib/typescript/components/touchables/TouchableNativeFeedbackProps.d.ts +3 -0
  600. package/lib/typescript/components/touchables/TouchableOpacity.d.ts +5 -0
  601. package/lib/typescript/components/touchables/TouchableWithoutFeedback.d.ts +6 -0
  602. package/lib/typescript/handlers/FlingGestureHandler.d.ts +9 -0
  603. package/lib/typescript/handlers/ForceTouchGestureHandler.d.ts +9 -0
  604. package/lib/typescript/handlers/LongPressGestureHandler.d.ts +9 -0
  605. package/lib/typescript/handlers/NativeViewGestureHandler.d.ts +9 -0
  606. package/lib/typescript/handlers/PanGestureHandler.d.ts +9 -0
  607. package/lib/typescript/handlers/PinchGestureHandler.d.ts +9 -0
  608. package/lib/typescript/handlers/RotationGestureHandler.d.ts +9 -0
  609. package/lib/typescript/handlers/TapGestureHandler.d.ts +9 -0
  610. package/lib/typescript/handlers/handlersRegistry.d.ts +1 -0
  611. package/lib/typescript/index.d.ts +1 -1
  612. package/lib/typescript/utils.d.ts +1 -1
  613. package/lib/typescript/web/detectors/RotationGestureDetector.d.ts +7 -7
  614. package/lib/typescript/web/detectors/ScaleGestureDetector.d.ts +8 -8
  615. package/lib/typescript/web/handlers/GestureHandler.d.ts +33 -28
  616. package/lib/typescript/web/handlers/IGestureHandler.d.ts +12 -13
  617. package/lib/typescript/web/tools/CircularBuffer.d.ts +3 -3
  618. package/lib/typescript/web/tools/GestureHandlerDelegate.d.ts +1 -1
  619. package/lib/typescript/web/tools/GestureHandlerOrchestrator.d.ts +2 -2
  620. package/lib/typescript/web/tools/GestureHandlerWebDelegate.d.ts +3 -2
  621. package/lib/typescript/web/tools/InteractionManager.d.ts +2 -2
  622. package/lib/typescript/web/tools/NodeManager.d.ts +1 -1
  623. package/lib/typescript/web/tools/PointerTracker.d.ts +4 -4
  624. package/lib/typescript/web/tools/VelocityTracker.d.ts +1 -1
  625. package/package.json +2 -2
  626. package/src/RNGestureHandlerModule.web.ts +2 -2
  627. package/src/components/DrawerLayout.tsx +29 -0
  628. package/src/components/GestureButtons.tsx +13 -2
  629. package/src/components/GestureButtonsProps.ts +31 -2
  630. package/src/components/Pressable/Pressable.tsx +22 -5
  631. package/src/components/Pressable/PressableProps.tsx +4 -11
  632. package/src/components/Pressable/index.ts +4 -1
  633. package/src/components/ReanimatedSwipeable.tsx +97 -66
  634. package/src/components/Text.tsx +13 -4
  635. package/src/components/touchables/TouchableHighlight.tsx +5 -0
  636. package/src/components/touchables/TouchableNativeFeedback.android.tsx +2 -0
  637. package/src/components/touchables/TouchableNativeFeedback.tsx +6 -1
  638. package/src/components/touchables/TouchableNativeFeedbackProps.tsx +3 -0
  639. package/src/components/touchables/TouchableOpacity.tsx +5 -0
  640. package/src/components/touchables/TouchableWithoutFeedback.tsx +6 -0
  641. package/src/findNodeHandle.web.ts +6 -0
  642. package/src/handlers/FlingGestureHandler.ts +10 -0
  643. package/src/handlers/ForceTouchGestureHandler.ts +9 -0
  644. package/src/handlers/LongPressGestureHandler.ts +10 -0
  645. package/src/handlers/NativeViewGestureHandler.ts +10 -0
  646. package/src/handlers/PanGestureHandler.ts +10 -0
  647. package/src/handlers/PinchGestureHandler.ts +10 -0
  648. package/src/handlers/RotationGestureHandler.ts +10 -0
  649. package/src/handlers/TapGestureHandler.ts +10 -0
  650. package/src/handlers/createHandler.tsx +11 -4
  651. package/src/handlers/gestures/GestureDetector/index.tsx +2 -2
  652. package/src/handlers/gestures/GestureDetector/useViewRefHandler.ts +3 -3
  653. package/src/handlers/gestures/GestureDetector/utils.ts +2 -2
  654. package/src/handlers/handlersRegistry.ts +7 -3
  655. package/src/index.ts +4 -1
  656. package/src/utils.ts +2 -2
  657. package/src/web/detectors/RotationGestureDetector.ts +22 -22
  658. package/src/web/detectors/ScaleGestureDetector.ts +24 -24
  659. package/src/web/handlers/FlingGestureHandler.ts +6 -7
  660. package/src/web/handlers/GestureHandler.ts +115 -105
  661. package/src/web/handlers/HoverGestureHandler.ts +2 -2
  662. package/src/web/handlers/IGestureHandler.ts +12 -13
  663. package/src/web/handlers/LongPressGestureHandler.ts +7 -7
  664. package/src/web/handlers/NativeViewGestureHandler.ts +14 -19
  665. package/src/web/handlers/PanGestureHandler.ts +17 -17
  666. package/src/web/handlers/PinchGestureHandler.ts +17 -21
  667. package/src/web/handlers/RotationGestureHandler.ts +12 -12
  668. package/src/web/handlers/TapGestureHandler.ts +4 -6
  669. package/src/web/tools/CircularBuffer.ts +15 -15
  670. package/src/web/tools/GestureHandlerDelegate.ts +1 -1
  671. package/src/web/tools/GestureHandlerOrchestrator.ts +42 -42
  672. package/src/web/tools/GestureHandlerWebDelegate.ts +32 -13
  673. package/src/web/tools/InteractionManager.ts +16 -16
  674. package/src/web/tools/NodeManager.ts +2 -2
  675. package/src/web/tools/PointerTracker.ts +20 -20
  676. package/src/web/tools/Vector.ts +1 -1
  677. package/src/web/tools/VelocityTracker.ts +1 -1
@@ -55,6 +55,11 @@ class RNGestureHandlerButtonViewManager : ViewGroupManager<ButtonViewGroup>(), R
55
55
  view.useDrawableOnForeground = useDrawableOnForeground
56
56
  }
57
57
 
58
+ @ReactProp(name = "backgroundColor")
59
+ override fun setBackgroundColor(view: ButtonViewGroup, backgroundColor: Int) {
60
+ view.setBackgroundColor(backgroundColor)
61
+ }
62
+
58
63
  @ReactProp(name = "borderless")
59
64
  override fun setBorderless(view: ButtonViewGroup, useBorderlessDrawable: Boolean) {
60
65
  view.useBorderlessDrawable = useBorderlessDrawable
@@ -291,6 +296,15 @@ class RNGestureHandlerButtonViewManager : ViewGroupManager<ButtonViewGroup>(), R
291
296
  val eventTime = event.eventTime
292
297
  val action = event.action
293
298
 
299
+ if (touchResponder != null && touchResponder !== this && touchResponder!!.exclusive) {
300
+ if (isPressed) {
301
+ setPressed(false)
302
+ }
303
+ lastEventTime = eventTime
304
+ lastAction = action
305
+ return false
306
+ }
307
+
294
308
  if (event.action == MotionEvent.ACTION_CANCEL) {
295
309
  tryFreeingResponder()
296
310
  }
@@ -7,9 +7,9 @@ using namespace facebook;
7
7
  using namespace react;
8
8
 
9
9
  void decorateRuntime(jsi::Runtime &runtime) {
10
- auto isFormsStackingContext = jsi::Function::createFromHostFunction(
10
+ auto isViewFlatteningDisabled = jsi::Function::createFromHostFunction(
11
11
  runtime,
12
- jsi::PropNameID::forAscii(runtime, "isFormsStackingContext"),
12
+ jsi::PropNameID::forAscii(runtime, "isViewFlatteningDisabled"),
13
13
  1,
14
14
  [](jsi::Runtime &runtime,
15
15
  const jsi::Value &thisValue,
@@ -20,21 +20,28 @@ void decorateRuntime(jsi::Runtime &runtime) {
20
20
  }
21
21
 
22
22
  auto shadowNode = shadowNodeFromValue(runtime, arguments[0]);
23
- bool isFormsStackingContext = shadowNode->getTraits().check(ShadowNodeTraits::FormsStackingContext);
23
+ bool isViewFlatteningDisabled = shadowNode->getTraits().check(
24
+ ShadowNodeTraits::FormsStackingContext);
24
25
 
25
- return jsi::Value(isFormsStackingContext);
26
+ // This is done using component names instead of type checking because
27
+ // of duplicate symbols for RN types, which prevent RTTI from working.
28
+ const char *componentName = shadowNode->getComponentName();
29
+ bool isTextComponent = strcmp(componentName, "Paragraph") == 0 ||
30
+ strcmp(componentName, "Text") == 0;
31
+
32
+ return jsi::Value(isViewFlatteningDisabled || isTextComponent);
26
33
  });
27
34
  runtime.global().setProperty(
28
- runtime, "isFormsStackingContext", std::move(isFormsStackingContext));
35
+ runtime, "isViewFlatteningDisabled", std::move(isViewFlatteningDisabled));
29
36
  }
30
37
 
31
38
  extern "C" JNIEXPORT void JNICALL
32
39
  Java_com_swmansion_gesturehandler_react_RNGestureHandlerModule_decorateRuntime(
33
- JNIEnv *env,
34
- jobject clazz,
35
- jlong jsiPtr) {
36
- jsi::Runtime *runtime = reinterpret_cast<jsi::Runtime *>(jsiPtr);
37
- if (runtime) {
38
- decorateRuntime(*runtime);
39
- }
40
+ JNIEnv *env,
41
+ jobject clazz,
42
+ jlong jsiPtr) {
43
+ jsi::Runtime *runtime = reinterpret_cast<jsi::Runtime *>(jsiPtr);
44
+ if (runtime) {
45
+ decorateRuntime(*runtime);
46
+ }
40
47
  }
@@ -461,16 +461,23 @@ static NSHashTable<RNGestureHandler *> *allGestureHandlers;
461
461
  - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer
462
462
  shouldRequireFailureOfGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer
463
463
  {
464
- if ([_handlersToWaitFor count]) {
465
- RNGestureHandler *handler = [RNGestureHandler findGestureHandlerByRecognizer:otherGestureRecognizer];
466
- if (handler != nil) {
467
- for (NSNumber *handlerTag in _handlersToWaitFor) {
468
- if ([handler.tag isEqual:handlerTag]) {
469
- return YES;
470
- }
471
- }
464
+ RNGestureHandler *handler = [RNGestureHandler findGestureHandlerByRecognizer:otherGestureRecognizer];
465
+ if (handler == nil) {
466
+ return NO;
467
+ }
468
+
469
+ for (NSNumber *handlerTag in _handlersToWaitFor) {
470
+ if ([handler.tag isEqual:handlerTag]) {
471
+ return YES;
472
472
  }
473
473
  }
474
+
475
+ for (NSNumber *handlerTag in handler->_handlersThatShouldWait) {
476
+ if ([_tag isEqual:handlerTag]) {
477
+ return YES;
478
+ }
479
+ }
480
+
474
481
  return NO;
475
482
  }
476
483
 
@@ -14,6 +14,8 @@
14
14
  #import <ReactCommon/CallInvoker.h>
15
15
  #import <ReactCommon/RCTTurboModule.h>
16
16
 
17
+ #import <react/renderer/components/text/ParagraphShadowNode.h>
18
+ #import <react/renderer/components/text/TextShadowNode.h>
17
19
  #import <react/renderer/uimanager/primitives.h>
18
20
  #endif // RCT_NEW_ARCH_ENABLED
19
21
 
@@ -91,19 +93,29 @@ RCT_EXPORT_MODULE()
91
93
  #ifdef RCT_NEW_ARCH_ENABLED
92
94
  void decorateRuntime(jsi::Runtime &runtime)
93
95
  {
94
- auto isFormsStackingContext = jsi::Function::createFromHostFunction(
96
+ auto isViewFlatteningDisabled = jsi::Function::createFromHostFunction(
95
97
  runtime,
96
- jsi::PropNameID::forAscii(runtime, "isFormsStackingContext"),
98
+ jsi::PropNameID::forAscii(runtime, "isViewFlatteningDisabled"),
97
99
  1,
98
100
  [](jsi::Runtime &runtime, const jsi::Value &thisValue, const jsi::Value *arguments, size_t count) -> jsi::Value {
99
101
  if (!arguments[0].isObject()) {
100
102
  return jsi::Value::null();
101
103
  }
102
104
  auto shadowNode = shadowNodeFromValue(runtime, arguments[0]);
103
- bool isFormsStackingContext = shadowNode->getTraits().check(ShadowNodeTraits::FormsStackingContext);
104
- return jsi::Value(isFormsStackingContext);
105
+
106
+ if (dynamic_pointer_cast<const ParagraphShadowNode>(shadowNode)) {
107
+ return jsi::Value(true);
108
+ }
109
+
110
+ if (dynamic_pointer_cast<const TextShadowNode>(shadowNode)) {
111
+ return jsi::Value(true);
112
+ }
113
+
114
+ bool isViewFlatteningDisabled = shadowNode->getTraits().check(ShadowNodeTraits::FormsStackingContext);
115
+
116
+ return jsi::Value(isViewFlatteningDisabled);
105
117
  });
106
- runtime.global().setProperty(runtime, "isFormsStackingContext", std::move(isFormsStackingContext));
118
+ runtime.global().setProperty(runtime, "isViewFlatteningDisabled", std::move(isViewFlatteningDisabled));
107
119
  }
108
120
  #endif // RCT_NEW_ARCH_ENABLED
109
121
 
@@ -4,12 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.ActionType = void 0;
7
- const ActionType = {
7
+ const ActionType = exports.ActionType = {
8
8
  REANIMATED_WORKLET: 1,
9
9
  NATIVE_ANIMATED_EVENT: 2,
10
10
  JS_FUNCTION_OLD_API: 3,
11
11
  JS_FUNCTION_NEW_API: 4
12
- }; // eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
12
+ };
13
13
 
14
- exports.ActionType = ActionType;
14
+ // eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
15
15
  //# sourceMappingURL=ActionType.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["ActionType.ts"],"names":["ActionType","REANIMATED_WORKLET","NATIVE_ANIMATED_EVENT","JS_FUNCTION_OLD_API","JS_FUNCTION_NEW_API"],"mappings":";;;;;;AAAO,MAAMA,UAAU,GAAG;AACxBC,EAAAA,kBAAkB,EAAE,CADI;AAExBC,EAAAA,qBAAqB,EAAE,CAFC;AAGxBC,EAAAA,mBAAmB,EAAE,CAHG;AAIxBC,EAAAA,mBAAmB,EAAE;AAJG,CAAnB,C,CAOP","sourcesContent":["export const ActionType = {\n REANIMATED_WORKLET: 1,\n NATIVE_ANIMATED_EVENT: 2,\n JS_FUNCTION_OLD_API: 3,\n JS_FUNCTION_NEW_API: 4,\n} as const;\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value\nexport type ActionType = (typeof ActionType)[keyof typeof ActionType];\n"]}
1
+ {"version":3,"names":["ActionType","exports","REANIMATED_WORKLET","NATIVE_ANIMATED_EVENT","JS_FUNCTION_OLD_API","JS_FUNCTION_NEW_API"],"sources":["ActionType.ts"],"sourcesContent":["export const ActionType = {\n REANIMATED_WORKLET: 1,\n NATIVE_ANIMATED_EVENT: 2,\n JS_FUNCTION_OLD_API: 3,\n JS_FUNCTION_NEW_API: 4,\n} as const;\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value\nexport type ActionType = (typeof ActionType)[keyof typeof ActionType];\n"],"mappings":";;;;;;AAAO,MAAMA,UAAU,GAAAC,OAAA,CAAAD,UAAA,GAAG;EACxBE,kBAAkB,EAAE,CAAC;EACrBC,qBAAqB,EAAE,CAAC;EACxBC,mBAAmB,EAAE,CAAC;EACtBC,mBAAmB,EAAE;AACvB,CAAU;;AAEV","ignoreList":[]}
@@ -3,26 +3,29 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.DiagonalDirections = exports.Directions = void 0;
6
+ exports.Directions = exports.DiagonalDirections = void 0;
7
7
  const RIGHT = 1;
8
8
  const LEFT = 2;
9
9
  const UP = 4;
10
- const DOWN = 8; // Public interface
10
+ const DOWN = 8;
11
11
 
12
- const Directions = {
12
+ // Public interface
13
+ const Directions = exports.Directions = {
13
14
  RIGHT: RIGHT,
14
15
  LEFT: LEFT,
15
16
  UP: UP,
16
17
  DOWN: DOWN
17
- }; // Internal interface
18
+ };
18
19
 
19
- exports.Directions = Directions;
20
- const DiagonalDirections = {
20
+ // Internal interface
21
+ const DiagonalDirections = exports.DiagonalDirections = {
21
22
  UP_RIGHT: UP | RIGHT,
22
23
  DOWN_RIGHT: DOWN | RIGHT,
23
24
  UP_LEFT: UP | LEFT,
24
25
  DOWN_LEFT: DOWN | LEFT
25
- }; // eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
26
+ };
26
27
 
27
- exports.DiagonalDirections = DiagonalDirections;
28
+ // eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value
29
+
30
+ // eslint-disable-next-line @typescript-eslint/no-redeclare
28
31
  //# sourceMappingURL=Directions.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["Directions.ts"],"names":["RIGHT","LEFT","UP","DOWN","Directions","DiagonalDirections","UP_RIGHT","DOWN_RIGHT","UP_LEFT","DOWN_LEFT"],"mappings":";;;;;;AAAA,MAAMA,KAAK,GAAG,CAAd;AACA,MAAMC,IAAI,GAAG,CAAb;AACA,MAAMC,EAAE,GAAG,CAAX;AACA,MAAMC,IAAI,GAAG,CAAb,C,CAEA;;AACO,MAAMC,UAAU,GAAG;AACxBJ,EAAAA,KAAK,EAAEA,KADiB;AAExBC,EAAAA,IAAI,EAAEA,IAFkB;AAGxBC,EAAAA,EAAE,EAAEA,EAHoB;AAIxBC,EAAAA,IAAI,EAAEA;AAJkB,CAAnB,C,CAOP;;;AACO,MAAME,kBAAkB,GAAG;AAChCC,EAAAA,QAAQ,EAAEJ,EAAE,GAAGF,KADiB;AAEhCO,EAAAA,UAAU,EAAEJ,IAAI,GAAGH,KAFa;AAGhCQ,EAAAA,OAAO,EAAEN,EAAE,GAAGD,IAHkB;AAIhCQ,EAAAA,SAAS,EAAEN,IAAI,GAAGF;AAJc,CAA3B,C,CAOP","sourcesContent":["const RIGHT = 1;\nconst LEFT = 2;\nconst UP = 4;\nconst DOWN = 8;\n\n// Public interface\nexport const Directions = {\n RIGHT: RIGHT,\n LEFT: LEFT,\n UP: UP,\n DOWN: DOWN,\n} as const;\n\n// Internal interface\nexport const DiagonalDirections = {\n UP_RIGHT: UP | RIGHT,\n DOWN_RIGHT: DOWN | RIGHT,\n UP_LEFT: UP | LEFT,\n DOWN_LEFT: DOWN | LEFT,\n} as const;\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value\nexport type Directions = (typeof Directions)[keyof typeof Directions];\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport type DiagonalDirections =\n (typeof DiagonalDirections)[keyof typeof DiagonalDirections];\n"]}
1
+ {"version":3,"names":["RIGHT","LEFT","UP","DOWN","Directions","exports","DiagonalDirections","UP_RIGHT","DOWN_RIGHT","UP_LEFT","DOWN_LEFT"],"sources":["Directions.ts"],"sourcesContent":["const RIGHT = 1;\nconst LEFT = 2;\nconst UP = 4;\nconst DOWN = 8;\n\n// Public interface\nexport const Directions = {\n RIGHT: RIGHT,\n LEFT: LEFT,\n UP: UP,\n DOWN: DOWN,\n} as const;\n\n// Internal interface\nexport const DiagonalDirections = {\n UP_RIGHT: UP | RIGHT,\n DOWN_RIGHT: DOWN | RIGHT,\n UP_LEFT: UP | LEFT,\n DOWN_LEFT: DOWN | LEFT,\n} as const;\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare -- backward compatibility; it can be used as a type and as a value\nexport type Directions = (typeof Directions)[keyof typeof Directions];\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport type DiagonalDirections =\n (typeof DiagonalDirections)[keyof typeof DiagonalDirections];\n"],"mappings":";;;;;;AAAA,MAAMA,KAAK,GAAG,CAAC;AACf,MAAMC,IAAI,GAAG,CAAC;AACd,MAAMC,EAAE,GAAG,CAAC;AACZ,MAAMC,IAAI,GAAG,CAAC;;AAEd;AACO,MAAMC,UAAU,GAAAC,OAAA,CAAAD,UAAA,GAAG;EACxBJ,KAAK,EAAEA,KAAK;EACZC,IAAI,EAAEA,IAAI;EACVC,EAAE,EAAEA,EAAE;EACNC,IAAI,EAAEA;AACR,CAAU;;AAEV;AACO,MAAMG,kBAAkB,GAAAD,OAAA,CAAAC,kBAAA,GAAG;EAChCC,QAAQ,EAAEL,EAAE,GAAGF,KAAK;EACpBQ,UAAU,EAAEL,IAAI,GAAGH,KAAK;EACxBS,OAAO,EAAEP,EAAE,GAAGD,IAAI;EAClBS,SAAS,EAAEP,IAAI,GAAGF;AACpB,CAAU;;AAEV;;AAEA","ignoreList":[]}
@@ -6,41 +6,33 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.enableExperimentalWebImplementation = enableExperimentalWebImplementation;
7
7
  exports.enableLegacyWebImplementation = enableLegacyWebImplementation;
8
8
  exports.isNewWebImplementationEnabled = isNewWebImplementationEnabled;
9
-
10
9
  var _reactNative = require("react-native");
11
-
12
10
  var _utils = require("./utils");
13
-
14
11
  let useNewWebImplementation = true;
15
12
  let getWasCalled = false;
13
+
16
14
  /**
17
15
  * @deprecated new web implementation is enabled by default. This function will be removed in Gesture Handler 3
18
16
  */
19
-
20
17
  function enableExperimentalWebImplementation(_shouldEnable = true) {
21
18
  // NO-OP since the new implementation is now the default
22
19
  console.warn((0, _utils.tagMessage)('New web implementation is enabled by default. This function will be removed in Gesture Handler 3.'));
23
20
  }
21
+
24
22
  /**
25
23
  * @deprecated legacy implementation is no longer supported. This function will be removed in Gesture Handler 3
26
24
  */
27
-
28
-
29
25
  function enableLegacyWebImplementation(shouldUseLegacyImplementation = true) {
30
26
  console.warn((0, _utils.tagMessage)('Legacy web implementation is deprecated. This function will be removed in Gesture Handler 3.'));
31
-
32
27
  if (_reactNative.Platform.OS !== 'web' || useNewWebImplementation === !shouldUseLegacyImplementation) {
33
28
  return;
34
29
  }
35
-
36
30
  if (getWasCalled) {
37
31
  console.error('Some parts of this application have already started using the new gesture handler implementation. No changes will be applied. You can try enabling legacy implementation earlier.');
38
32
  return;
39
33
  }
40
-
41
34
  useNewWebImplementation = !shouldUseLegacyImplementation;
42
35
  }
43
-
44
36
  function isNewWebImplementationEnabled() {
45
37
  getWasCalled = true;
46
38
  return useNewWebImplementation;
@@ -1 +1 @@
1
- {"version":3,"sources":["EnableNewWebImplementation.ts"],"names":["useNewWebImplementation","getWasCalled","enableExperimentalWebImplementation","_shouldEnable","console","warn","enableLegacyWebImplementation","shouldUseLegacyImplementation","Platform","OS","error","isNewWebImplementationEnabled"],"mappings":";;;;;;;;;AAAA;;AACA;;AAEA,IAAIA,uBAAuB,GAAG,IAA9B;AACA,IAAIC,YAAY,GAAG,KAAnB;AAEA;AACA;AACA;;AACO,SAASC,mCAAT,CACLC,aAAa,GAAG,IADX,EAEC;AACN;AACAC,EAAAA,OAAO,CAACC,IAAR,CACE,uBACE,mGADF,CADF;AAKD;AAED;AACA;AACA;;;AACO,SAASC,6BAAT,CACLC,6BAA6B,GAAG,IAD3B,EAEC;AACNH,EAAAA,OAAO,CAACC,IAAR,CACE,uBACE,8FADF,CADF;;AAMA,MACEG,sBAASC,EAAT,KAAgB,KAAhB,IACAT,uBAAuB,KAAK,CAACO,6BAF/B,EAGE;AACA;AACD;;AAED,MAAIN,YAAJ,EAAkB;AAChBG,IAAAA,OAAO,CAACM,KAAR,CACE,mLADF;AAGA;AACD;;AAEDV,EAAAA,uBAAuB,GAAG,CAACO,6BAA3B;AACD;;AAEM,SAASI,6BAAT,GAAkD;AACvDV,EAAAA,YAAY,GAAG,IAAf;AACA,SAAOD,uBAAP;AACD","sourcesContent":["import { Platform } from 'react-native';\nimport { tagMessage } from './utils';\n\nlet useNewWebImplementation = true;\nlet getWasCalled = false;\n\n/**\n * @deprecated new web implementation is enabled by default. This function will be removed in Gesture Handler 3\n */\nexport function enableExperimentalWebImplementation(\n _shouldEnable = true\n): void {\n // NO-OP since the new implementation is now the default\n console.warn(\n tagMessage(\n 'New web implementation is enabled by default. This function will be removed in Gesture Handler 3.'\n )\n );\n}\n\n/**\n * @deprecated legacy implementation is no longer supported. This function will be removed in Gesture Handler 3\n */\nexport function enableLegacyWebImplementation(\n shouldUseLegacyImplementation = true\n): void {\n console.warn(\n tagMessage(\n 'Legacy web implementation is deprecated. This function will be removed in Gesture Handler 3.'\n )\n );\n\n if (\n Platform.OS !== 'web' ||\n useNewWebImplementation === !shouldUseLegacyImplementation\n ) {\n return;\n }\n\n if (getWasCalled) {\n console.error(\n 'Some parts of this application have already started using the new gesture handler implementation. No changes will be applied. You can try enabling legacy implementation earlier.'\n );\n return;\n }\n\n useNewWebImplementation = !shouldUseLegacyImplementation;\n}\n\nexport function isNewWebImplementationEnabled(): boolean {\n getWasCalled = true;\n return useNewWebImplementation;\n}\n"]}
1
+ {"version":3,"names":["_reactNative","require","_utils","useNewWebImplementation","getWasCalled","enableExperimentalWebImplementation","_shouldEnable","console","warn","tagMessage","enableLegacyWebImplementation","shouldUseLegacyImplementation","Platform","OS","error","isNewWebImplementationEnabled"],"sources":["EnableNewWebImplementation.ts"],"sourcesContent":["import { Platform } from 'react-native';\nimport { tagMessage } from './utils';\n\nlet useNewWebImplementation = true;\nlet getWasCalled = false;\n\n/**\n * @deprecated new web implementation is enabled by default. This function will be removed in Gesture Handler 3\n */\nexport function enableExperimentalWebImplementation(\n _shouldEnable = true\n): void {\n // NO-OP since the new implementation is now the default\n console.warn(\n tagMessage(\n 'New web implementation is enabled by default. This function will be removed in Gesture Handler 3.'\n )\n );\n}\n\n/**\n * @deprecated legacy implementation is no longer supported. This function will be removed in Gesture Handler 3\n */\nexport function enableLegacyWebImplementation(\n shouldUseLegacyImplementation = true\n): void {\n console.warn(\n tagMessage(\n 'Legacy web implementation is deprecated. This function will be removed in Gesture Handler 3.'\n )\n );\n\n if (\n Platform.OS !== 'web' ||\n useNewWebImplementation === !shouldUseLegacyImplementation\n ) {\n return;\n }\n\n if (getWasCalled) {\n console.error(\n 'Some parts of this application have already started using the new gesture handler implementation. No changes will be applied. You can try enabling legacy implementation earlier.'\n );\n return;\n }\n\n useNewWebImplementation = !shouldUseLegacyImplementation;\n}\n\nexport function isNewWebImplementationEnabled(): boolean {\n getWasCalled = true;\n return useNewWebImplementation;\n}\n"],"mappings":";;;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AAEA,IAAIE,uBAAuB,GAAG,IAAI;AAClC,IAAIC,YAAY,GAAG,KAAK;;AAExB;AACA;AACA;AACO,SAASC,mCAAmCA,CACjDC,aAAa,GAAG,IAAI,EACd;EACN;EACAC,OAAO,CAACC,IAAI,CACV,IAAAC,iBAAU,EACR,mGACF,CACF,CAAC;AACH;;AAEA;AACA;AACA;AACO,SAASC,6BAA6BA,CAC3CC,6BAA6B,GAAG,IAAI,EAC9B;EACNJ,OAAO,CAACC,IAAI,CACV,IAAAC,iBAAU,EACR,8FACF,CACF,CAAC;EAED,IACEG,qBAAQ,CAACC,EAAE,KAAK,KAAK,IACrBV,uBAAuB,KAAK,CAACQ,6BAA6B,EAC1D;IACA;EACF;EAEA,IAAIP,YAAY,EAAE;IAChBG,OAAO,CAACO,KAAK,CACX,mLACF,CAAC;IACD;EACF;EAEAX,uBAAuB,GAAG,CAACQ,6BAA6B;AAC1D;AAEO,SAASI,6BAA6BA,CAAA,EAAY;EACvDX,YAAY,GAAG,IAAI;EACnB,OAAOD,uBAAuB;AAChC","ignoreList":[]}
@@ -4,12 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _react = _interopRequireDefault(require("react"));
9
-
10
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
-
12
- var _default = /*#__PURE__*/_react.default.createContext(false);
13
-
14
- exports.default = _default;
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
9
+ var _default = exports.default = /*#__PURE__*/_react.default.createContext(false);
15
10
  //# sourceMappingURL=GestureHandlerRootViewContext.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["GestureHandlerRootViewContext.ts"],"names":["React","createContext"],"mappings":";;;;;;;AAAA;;;;4BAEeA,eAAMC,aAAN,CAAoB,KAApB,C","sourcesContent":["import React from 'react';\n\nexport default React.createContext(false);\n"]}
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","e","__esModule","default","_default","exports","React","createContext"],"sources":["GestureHandlerRootViewContext.ts"],"sourcesContent":["import React from 'react';\n\nexport default React.createContext(false);\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA0B,SAAAD,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAAA,IAAAG,QAAA,GAAAC,OAAA,CAAAF,OAAA,gBAEXG,cAAK,CAACC,aAAa,CAAC,KAAK,CAAC","ignoreList":[]}
@@ -4,12 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _reactNative = require("react-native");
9
-
10
8
  var _NativeModules$Platfo;
11
-
12
- var _default = (_NativeModules$Platfo = _reactNative.NativeModules === null || _reactNative.NativeModules === void 0 ? void 0 : _reactNative.NativeModules.PlatformConstants) !== null && _NativeModules$Platfo !== void 0 ? _NativeModules$Platfo : _reactNative.Platform.constants;
13
-
14
- exports.default = _default;
9
+ var _default = exports.default = (_NativeModules$Platfo = _reactNative.NativeModules === null || _reactNative.NativeModules === void 0 ? void 0 : _reactNative.NativeModules.PlatformConstants) !== null && _NativeModules$Platfo !== void 0 ? _NativeModules$Platfo : _reactNative.Platform.constants;
15
10
  //# sourceMappingURL=PlatformConstants.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["PlatformConstants.ts"],"names":["NativeModules","PlatformConstants","Platform","constants"],"mappings":";;;;;;;AAAA;;;;wCAMgBA,0B,aAAAA,0B,uBAAAA,2BAAeC,iB,yEAC7BC,sBAASC,S","sourcesContent":["import { NativeModules, Platform } from 'react-native';\n\ntype PlatformConstants = {\n forceTouchAvailable: boolean;\n};\n\nexport default (NativeModules?.PlatformConstants ??\n Platform.constants) as PlatformConstants;\n"]}
1
+ {"version":3,"names":["_reactNative","require","_NativeModules$Platfo","_default","exports","default","NativeModules","PlatformConstants","Platform","constants"],"sources":["PlatformConstants.ts"],"sourcesContent":["import { NativeModules, Platform } from 'react-native';\n\ntype PlatformConstants = {\n forceTouchAvailable: boolean;\n};\n\nexport default (NativeModules?.PlatformConstants ??\n Platform.constants) as PlatformConstants;\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAuD,IAAAC,qBAAA;AAAA,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,IAAAH,qBAAA,GAMvCI,0BAAa,aAAbA,0BAAa,uBAAbA,0BAAa,CAAEC,iBAAiB,cAAAL,qBAAA,cAAAA,qBAAA,GAC9CM,qBAAQ,CAACC,SAAS","ignoreList":[]}
@@ -4,11 +4,9 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
- var _default = {
7
+ var _default = exports.default = {
8
8
  get forceTouchAvailable() {
9
9
  return false;
10
10
  }
11
-
12
11
  };
13
- exports.default = _default;
14
12
  //# sourceMappingURL=PlatformConstants.web.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["PlatformConstants.web.ts"],"names":["forceTouchAvailable"],"mappings":";;;;;;eAAe;AACb,MAAIA,mBAAJ,GAA0B;AACxB,WAAO,KAAP;AACD;;AAHY,C","sourcesContent":["export default {\n get forceTouchAvailable() {\n return false;\n },\n};\n"]}
1
+ {"version":3,"names":["forceTouchAvailable"],"sources":["PlatformConstants.web.ts"],"sourcesContent":["export default {\n get forceTouchAvailable() {\n return false;\n },\n};\n"],"mappings":";;;;;;iCAAe;EACb,IAAIA,mBAAmBA,CAAA,EAAG;IACxB,OAAO,KAAK;EACd;AACF,CAAC","ignoreList":[]}
@@ -4,14 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.PointerType = void 0;
7
- let PointerType;
8
- exports.PointerType = PointerType;
9
-
10
- (function (PointerType) {
7
+ let PointerType = exports.PointerType = /*#__PURE__*/function (PointerType) {
11
8
  PointerType[PointerType["TOUCH"] = 0] = "TOUCH";
12
9
  PointerType[PointerType["STYLUS"] = 1] = "STYLUS";
13
10
  PointerType[PointerType["MOUSE"] = 2] = "MOUSE";
14
11
  PointerType[PointerType["KEY"] = 3] = "KEY";
15
12
  PointerType[PointerType["OTHER"] = 4] = "OTHER";
16
- })(PointerType || (exports.PointerType = PointerType = {}));
13
+ return PointerType;
14
+ }({});
17
15
  //# sourceMappingURL=PointerType.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["PointerType.ts"],"names":["PointerType"],"mappings":";;;;;;IAAYA,W;;;WAAAA,W;AAAAA,EAAAA,W,CAAAA,W;AAAAA,EAAAA,W,CAAAA,W;AAAAA,EAAAA,W,CAAAA,W;AAAAA,EAAAA,W,CAAAA,W;AAAAA,EAAAA,W,CAAAA,W;GAAAA,W,2BAAAA,W","sourcesContent":["export enum PointerType {\n TOUCH,\n STYLUS,\n MOUSE,\n KEY,\n OTHER,\n}\n"]}
1
+ {"version":3,"names":["PointerType","exports"],"sources":["PointerType.ts"],"sourcesContent":["export enum PointerType {\n TOUCH,\n STYLUS,\n MOUSE,\n KEY,\n OTHER,\n}\n"],"mappings":";;;;;;IAAYA,WAAW,GAAAC,OAAA,CAAAD,WAAA,0BAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA","ignoreList":[]}
@@ -4,13 +4,9 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _NativeRNGestureHandlerModule = _interopRequireDefault(require("./specs/NativeRNGestureHandlerModule"));
9
-
10
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
-
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
12
9
  // Reexport the native module spec used by codegen. The relevant files are inluded on Android
13
10
  // to ensure the compatibility with the old arch, while iOS doesn't require those at all.
14
- var _default = _NativeRNGestureHandlerModule.default;
15
- exports.default = _default;
11
+ var _default = exports.default = _NativeRNGestureHandlerModule.default;
16
12
  //# sourceMappingURL=RNGestureHandlerModule.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["RNGestureHandlerModule.ts"],"names":["Module"],"mappings":";;;;;;;AAGA;;;;AAHA;AACA;eAGeA,qC","sourcesContent":["// Reexport the native module spec used by codegen. The relevant files are inluded on Android\n// to ensure the compatibility with the old arch, while iOS doesn't require those at all.\n\nimport Module from './specs/NativeRNGestureHandlerModule';\nexport default Module;\n"]}
1
+ {"version":3,"names":["_NativeRNGestureHandlerModule","_interopRequireDefault","require","e","__esModule","default","_default","exports","Module"],"sources":["RNGestureHandlerModule.ts"],"sourcesContent":["// Reexport the native module spec used by codegen. The relevant files are inluded on Android\n// to ensure the compatibility with the old arch, while iOS doesn't require those at all.\n\nimport Module from './specs/NativeRNGestureHandlerModule';\nexport default Module;\n"],"mappings":";;;;;;AAGA,IAAAA,6BAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA0D,SAAAD,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAH1D;AACA;AAAA,IAAAG,QAAA,GAAAC,OAAA,CAAAF,OAAA,GAGeG,qCAAM","ignoreList":[]}
@@ -4,69 +4,52 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _react = _interopRequireDefault(require("react"));
9
-
10
8
  var _EnableNewWebImplementation = require("./EnableNewWebImplementation");
11
-
12
9
  var _Gestures = require("./web/Gestures");
13
-
14
10
  var _InteractionManager = _interopRequireDefault(require("./web/tools/InteractionManager"));
15
-
16
11
  var _NodeManager = _interopRequireDefault(require("./web/tools/NodeManager"));
17
-
18
12
  var HammerNodeManager = _interopRequireWildcard(require("./web_hammer/NodeManager"));
19
-
20
13
  var _GestureHandlerWebDelegate = require("./web/tools/GestureHandlerWebDelegate");
21
-
22
- function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
23
-
24
- function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
25
-
26
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
27
-
14
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
15
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
16
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
28
17
  // init method is called inside attachGestureHandler function. However, this function may
29
18
  // fail when received view is not valid HTML element. On the other hand, dropGestureHandler
30
19
  // will be called even if attach failed, which will result in crash.
31
20
  //
32
21
  // We use this flag to check whether or not dropGestureHandler should be called.
33
22
  let shouldPreventDrop = false;
34
- var _default = {
23
+ var _default = exports.default = {
35
24
  handleSetJSResponder(tag, blockNativeResponder) {
36
25
  console.warn('handleSetJSResponder: ', tag, blockNativeResponder);
37
26
  },
38
-
39
27
  handleClearJSResponder() {
40
28
  console.warn('handleClearJSResponder: ');
41
29
  },
42
-
43
30
  createGestureHandler(handlerName, handlerTag, config) {
44
31
  if ((0, _EnableNewWebImplementation.isNewWebImplementationEnabled)()) {
45
32
  if (!(handlerName in _Gestures.Gestures)) {
46
33
  throw new Error(`react-native-gesture-handler: ${handlerName} is not supported on web.`);
47
34
  }
48
-
49
35
  const GestureClass = _Gestures.Gestures[handlerName];
50
-
51
36
  _NodeManager.default.createGestureHandler(handlerTag, new GestureClass(new _GestureHandlerWebDelegate.GestureHandlerWebDelegate()));
52
-
53
- _InteractionManager.default.getInstance().configureInteractions(_NodeManager.default.getHandler(handlerTag), config);
37
+ _InteractionManager.default.instance.configureInteractions(_NodeManager.default.getHandler(handlerTag), config);
54
38
  } else {
55
39
  if (!(handlerName in _Gestures.HammerGestures)) {
56
40
  throw new Error(`react-native-gesture-handler: ${handlerName} is not supported on web.`);
57
- } // @ts-ignore If it doesn't exist, the error is thrown
58
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
59
-
60
-
61
- const GestureClass = _Gestures.HammerGestures[handlerName]; // eslint-disable-next-line @typescript-eslint/no-unsafe-call
41
+ }
62
42
 
43
+ // @ts-ignore If it doesn't exist, the error is thrown
44
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
45
+ const GestureClass = _Gestures.HammerGestures[handlerName];
46
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-call
63
47
  HammerNodeManager.createGestureHandler(handlerTag, new GestureClass());
64
48
  }
65
-
66
49
  this.updateGestureHandler(handlerTag, config);
67
50
  },
68
-
69
- attachGestureHandler(handlerTag, // eslint-disable-next-line @typescript-eslint/no-explicit-any
51
+ attachGestureHandler(handlerTag,
52
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
70
53
  newView, _actionType, propsRef) {
71
54
  if (!(newView instanceof Element || newView instanceof _react.default.Component)) {
72
55
  shouldPreventDrop = true;
@@ -74,7 +57,6 @@ var _default = {
74
57
  const handlerName = handler.constructor.name;
75
58
  throw new Error(`${handlerName} with tag ${handlerTag} received child that is not valid HTML element.`);
76
59
  }
77
-
78
60
  if ((0, _EnableNewWebImplementation.isNewWebImplementationEnabled)()) {
79
61
  // @ts-ignore Types should be HTMLElement or React.Component
80
62
  _NodeManager.default.getHandler(handlerTag).init(newView, propsRef);
@@ -83,17 +65,14 @@ var _default = {
83
65
  HammerNodeManager.getHandler(handlerTag).setView(newView, propsRef);
84
66
  }
85
67
  },
86
-
87
68
  updateGestureHandler(handlerTag, newConfig) {
88
69
  if ((0, _EnableNewWebImplementation.isNewWebImplementationEnabled)()) {
89
70
  _NodeManager.default.getHandler(handlerTag).updateGestureConfig(newConfig);
90
-
91
- _InteractionManager.default.getInstance().configureInteractions(_NodeManager.default.getHandler(handlerTag), newConfig);
71
+ _InteractionManager.default.instance.configureInteractions(_NodeManager.default.getHandler(handlerTag), newConfig);
92
72
  } else {
93
73
  HammerNodeManager.getHandler(handlerTag).updateGestureConfig(newConfig);
94
74
  }
95
75
  },
96
-
97
76
  getGestureHandlerNode(handlerTag) {
98
77
  if ((0, _EnableNewWebImplementation.isNewWebImplementationEnabled)()) {
99
78
  return _NodeManager.default.getHandler(handlerTag);
@@ -101,22 +80,17 @@ var _default = {
101
80
  return HammerNodeManager.getHandler(handlerTag);
102
81
  }
103
82
  },
104
-
105
83
  dropGestureHandler(handlerTag) {
106
84
  if (shouldPreventDrop) {
107
85
  return;
108
86
  }
109
-
110
87
  if ((0, _EnableNewWebImplementation.isNewWebImplementationEnabled)()) {
111
88
  _NodeManager.default.dropGestureHandler(handlerTag);
112
89
  } else {
113
90
  HammerNodeManager.dropGestureHandler(handlerTag);
114
91
  }
115
92
  },
116
-
117
93
  // eslint-disable-next-line @typescript-eslint/no-empty-function
118
94
  flushOperations() {}
119
-
120
95
  };
121
- exports.default = _default;
122
96
  //# sourceMappingURL=RNGestureHandlerModule.web.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["RNGestureHandlerModule.web.ts"],"names":["shouldPreventDrop","handleSetJSResponder","tag","blockNativeResponder","console","warn","handleClearJSResponder","createGestureHandler","handlerName","handlerTag","config","Gestures","Error","GestureClass","NodeManager","GestureHandlerWebDelegate","InteractionManager","getInstance","configureInteractions","getHandler","HammerGestures","HammerNodeManager","updateGestureHandler","attachGestureHandler","newView","_actionType","propsRef","Element","React","Component","handler","constructor","name","init","setView","newConfig","updateGestureConfig","getGestureHandlerNode","dropGestureHandler","flushOperations"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;AAEA;;AACA;;AACA;;AACA;;;;;;;;AAEA;AACA;AACA;AACA;AACA;AACA,IAAIA,iBAAiB,GAAG,KAAxB;eAEe;AACbC,EAAAA,oBAAoB,CAACC,GAAD,EAAcC,oBAAd,EAA6C;AAC/DC,IAAAA,OAAO,CAACC,IAAR,CAAa,wBAAb,EAAuCH,GAAvC,EAA4CC,oBAA5C;AACD,GAHY;;AAIbG,EAAAA,sBAAsB,GAAG;AACvBF,IAAAA,OAAO,CAACC,IAAR,CAAa,0BAAb;AACD,GANY;;AAObE,EAAAA,oBAAoB,CAClBC,WADkB,EAElBC,UAFkB,EAGlBC,MAHkB,EAIlB;AACA,QAAI,gEAAJ,EAAqC;AACnC,UAAI,EAAEF,WAAW,IAAIG,kBAAjB,CAAJ,EAAgC;AAC9B,cAAM,IAAIC,KAAJ,CACH,iCAAgCJ,WAAY,2BADzC,CAAN;AAGD;;AAED,YAAMK,YAAY,GAAGF,mBAASH,WAAT,CAArB;;AACAM,2BAAYP,oBAAZ,CACEE,UADF,EAEE,IAAII,YAAJ,CAAiB,IAAIE,oDAAJ,EAAjB,CAFF;;AAIAC,kCAAmBC,WAAnB,GAAiCC,qBAAjC,CACEJ,qBAAYK,UAAZ,CAAuBV,UAAvB,CADF,EAEEC,MAFF;AAID,KAhBD,MAgBO;AACL,UAAI,EAAEF,WAAW,IAAIY,wBAAjB,CAAJ,EAAsC;AACpC,cAAM,IAAIR,KAAJ,CACH,iCAAgCJ,WAAY,2BADzC,CAAN;AAGD,OALI,CAOL;AACA;;;AACA,YAAMK,YAAY,GAAGO,yBAAeZ,WAAf,CAArB,CATK,CAUL;;AACAa,MAAAA,iBAAiB,CAACd,oBAAlB,CAAuCE,UAAvC,EAAmD,IAAII,YAAJ,EAAnD;AACD;;AAED,SAAKS,oBAAL,CAA0Bb,UAA1B,EAAsCC,MAAtC;AACD,GA3CY;;AA4Cba,EAAAA,oBAAoB,CAClBd,UADkB,EAElB;AACAe,EAAAA,OAHkB,EAIlBC,WAJkB,EAKlBC,QALkB,EAMlB;AACA,QAAI,EAAEF,OAAO,YAAYG,OAAnB,IAA8BH,OAAO,YAAYI,eAAMC,SAAzD,CAAJ,EAAyE;AACvE7B,MAAAA,iBAAiB,GAAG,IAApB;AAEA,YAAM8B,OAAO,GAAG,mEACZhB,qBAAYK,UAAZ,CAAuBV,UAAvB,CADY,GAEZY,iBAAiB,CAACF,UAAlB,CAA6BV,UAA7B,CAFJ;AAIA,YAAMD,WAAW,GAAGsB,OAAO,CAACC,WAAR,CAAoBC,IAAxC;AAEA,YAAM,IAAIpB,KAAJ,CACH,GAAEJ,WAAY,aAAYC,UAAW,iDADlC,CAAN;AAGD;;AAED,QAAI,gEAAJ,EAAqC;AACnC;AACAK,2BAAYK,UAAZ,CAAuBV,UAAvB,EAAmCwB,IAAnC,CAAwCT,OAAxC,EAAiDE,QAAjD;AACD,KAHD,MAGO;AACL;AACAL,MAAAA,iBAAiB,CAACF,UAAlB,CAA6BV,UAA7B,EAAyCyB,OAAzC,CAAiDV,OAAjD,EAA0DE,QAA1D;AACD;AACF,GAxEY;;AAyEbJ,EAAAA,oBAAoB,CAACb,UAAD,EAAqB0B,SAArB,EAAwC;AAC1D,QAAI,gEAAJ,EAAqC;AACnCrB,2BAAYK,UAAZ,CAAuBV,UAAvB,EAAmC2B,mBAAnC,CAAuDD,SAAvD;;AAEAnB,kCAAmBC,WAAnB,GAAiCC,qBAAjC,CACEJ,qBAAYK,UAAZ,CAAuBV,UAAvB,CADF,EAEE0B,SAFF;AAID,KAPD,MAOO;AACLd,MAAAA,iBAAiB,CAACF,UAAlB,CAA6BV,UAA7B,EAAyC2B,mBAAzC,CAA6DD,SAA7D;AACD;AACF,GApFY;;AAqFbE,EAAAA,qBAAqB,CAAC5B,UAAD,EAAqB;AACxC,QAAI,gEAAJ,EAAqC;AACnC,aAAOK,qBAAYK,UAAZ,CAAuBV,UAAvB,CAAP;AACD,KAFD,MAEO;AACL,aAAOY,iBAAiB,CAACF,UAAlB,CAA6BV,UAA7B,CAAP;AACD;AACF,GA3FY;;AA4Fb6B,EAAAA,kBAAkB,CAAC7B,UAAD,EAAqB;AACrC,QAAIT,iBAAJ,EAAuB;AACrB;AACD;;AAED,QAAI,gEAAJ,EAAqC;AACnCc,2BAAYwB,kBAAZ,CAA+B7B,UAA/B;AACD,KAFD,MAEO;AACLY,MAAAA,iBAAiB,CAACiB,kBAAlB,CAAqC7B,UAArC;AACD;AACF,GAtGY;;AAuGb;AACA8B,EAAAA,eAAe,GAAG,CAAE;;AAxGP,C","sourcesContent":["import React from 'react';\n\nimport type { ActionType } from './ActionType';\nimport { isNewWebImplementationEnabled } from './EnableNewWebImplementation';\nimport { Gestures, HammerGestures } from './web/Gestures';\nimport type { Config } from './web/interfaces';\nimport InteractionManager from './web/tools/InteractionManager';\nimport NodeManager from './web/tools/NodeManager';\nimport * as HammerNodeManager from './web_hammer/NodeManager';\nimport { GestureHandlerWebDelegate } from './web/tools/GestureHandlerWebDelegate';\n\n// init method is called inside attachGestureHandler function. However, this function may\n// fail when received view is not valid HTML element. On the other hand, dropGestureHandler\n// will be called even if attach failed, which will result in crash.\n//\n// We use this flag to check whether or not dropGestureHandler should be called.\nlet shouldPreventDrop = false;\n\nexport default {\n handleSetJSResponder(tag: number, blockNativeResponder: boolean) {\n console.warn('handleSetJSResponder: ', tag, blockNativeResponder);\n },\n handleClearJSResponder() {\n console.warn('handleClearJSResponder: ');\n },\n createGestureHandler<T>(\n handlerName: keyof typeof Gestures,\n handlerTag: number,\n config: T\n ) {\n if (isNewWebImplementationEnabled()) {\n if (!(handlerName in Gestures)) {\n throw new Error(\n `react-native-gesture-handler: ${handlerName} is not supported on web.`\n );\n }\n\n const GestureClass = Gestures[handlerName];\n NodeManager.createGestureHandler(\n handlerTag,\n new GestureClass(new GestureHandlerWebDelegate())\n );\n InteractionManager.getInstance().configureInteractions(\n NodeManager.getHandler(handlerTag),\n config as unknown as Config\n );\n } else {\n if (!(handlerName in HammerGestures)) {\n throw new Error(\n `react-native-gesture-handler: ${handlerName} is not supported on web.`\n );\n }\n\n // @ts-ignore If it doesn't exist, the error is thrown\n // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n const GestureClass = HammerGestures[handlerName];\n // eslint-disable-next-line @typescript-eslint/no-unsafe-call\n HammerNodeManager.createGestureHandler(handlerTag, new GestureClass());\n }\n\n this.updateGestureHandler(handlerTag, config as unknown as Config);\n },\n attachGestureHandler(\n handlerTag: number,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n newView: any,\n _actionType: ActionType,\n propsRef: React.RefObject<unknown>\n ) {\n if (!(newView instanceof Element || newView instanceof React.Component)) {\n shouldPreventDrop = true;\n\n const handler = isNewWebImplementationEnabled()\n ? NodeManager.getHandler(handlerTag)\n : HammerNodeManager.getHandler(handlerTag);\n\n const handlerName = handler.constructor.name;\n\n throw new Error(\n `${handlerName} with tag ${handlerTag} received child that is not valid HTML element.`\n );\n }\n\n if (isNewWebImplementationEnabled()) {\n // @ts-ignore Types should be HTMLElement or React.Component\n NodeManager.getHandler(handlerTag).init(newView, propsRef);\n } else {\n // @ts-ignore Types should be HTMLElement or React.Component\n HammerNodeManager.getHandler(handlerTag).setView(newView, propsRef);\n }\n },\n updateGestureHandler(handlerTag: number, newConfig: Config) {\n if (isNewWebImplementationEnabled()) {\n NodeManager.getHandler(handlerTag).updateGestureConfig(newConfig);\n\n InteractionManager.getInstance().configureInteractions(\n NodeManager.getHandler(handlerTag),\n newConfig\n );\n } else {\n HammerNodeManager.getHandler(handlerTag).updateGestureConfig(newConfig);\n }\n },\n getGestureHandlerNode(handlerTag: number) {\n if (isNewWebImplementationEnabled()) {\n return NodeManager.getHandler(handlerTag);\n } else {\n return HammerNodeManager.getHandler(handlerTag);\n }\n },\n dropGestureHandler(handlerTag: number) {\n if (shouldPreventDrop) {\n return;\n }\n\n if (isNewWebImplementationEnabled()) {\n NodeManager.dropGestureHandler(handlerTag);\n } else {\n HammerNodeManager.dropGestureHandler(handlerTag);\n }\n },\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n flushOperations() {},\n};\n"]}
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_EnableNewWebImplementation","_Gestures","_InteractionManager","_NodeManager","HammerNodeManager","_interopRequireWildcard","_GestureHandlerWebDelegate","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","shouldPreventDrop","_default","exports","handleSetJSResponder","tag","blockNativeResponder","console","warn","handleClearJSResponder","createGestureHandler","handlerName","handlerTag","config","isNewWebImplementationEnabled","Gestures","Error","GestureClass","NodeManager","GestureHandlerWebDelegate","InteractionManager","instance","configureInteractions","getHandler","HammerGestures","updateGestureHandler","attachGestureHandler","newView","_actionType","propsRef","Element","React","Component","handler","constructor","name","init","setView","newConfig","updateGestureConfig","getGestureHandlerNode","dropGestureHandler","flushOperations"],"sources":["RNGestureHandlerModule.web.ts"],"sourcesContent":["import React from 'react';\n\nimport type { ActionType } from './ActionType';\nimport { isNewWebImplementationEnabled } from './EnableNewWebImplementation';\nimport { Gestures, HammerGestures } from './web/Gestures';\nimport type { Config } from './web/interfaces';\nimport InteractionManager from './web/tools/InteractionManager';\nimport NodeManager from './web/tools/NodeManager';\nimport * as HammerNodeManager from './web_hammer/NodeManager';\nimport { GestureHandlerWebDelegate } from './web/tools/GestureHandlerWebDelegate';\n\n// init method is called inside attachGestureHandler function. However, this function may\n// fail when received view is not valid HTML element. On the other hand, dropGestureHandler\n// will be called even if attach failed, which will result in crash.\n//\n// We use this flag to check whether or not dropGestureHandler should be called.\nlet shouldPreventDrop = false;\n\nexport default {\n handleSetJSResponder(tag: number, blockNativeResponder: boolean) {\n console.warn('handleSetJSResponder: ', tag, blockNativeResponder);\n },\n handleClearJSResponder() {\n console.warn('handleClearJSResponder: ');\n },\n createGestureHandler<T>(\n handlerName: keyof typeof Gestures,\n handlerTag: number,\n config: T\n ) {\n if (isNewWebImplementationEnabled()) {\n if (!(handlerName in Gestures)) {\n throw new Error(\n `react-native-gesture-handler: ${handlerName} is not supported on web.`\n );\n }\n\n const GestureClass = Gestures[handlerName];\n NodeManager.createGestureHandler(\n handlerTag,\n new GestureClass(new GestureHandlerWebDelegate())\n );\n InteractionManager.instance.configureInteractions(\n NodeManager.getHandler(handlerTag),\n config as unknown as Config\n );\n } else {\n if (!(handlerName in HammerGestures)) {\n throw new Error(\n `react-native-gesture-handler: ${handlerName} is not supported on web.`\n );\n }\n\n // @ts-ignore If it doesn't exist, the error is thrown\n // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n const GestureClass = HammerGestures[handlerName];\n // eslint-disable-next-line @typescript-eslint/no-unsafe-call\n HammerNodeManager.createGestureHandler(handlerTag, new GestureClass());\n }\n\n this.updateGestureHandler(handlerTag, config as unknown as Config);\n },\n attachGestureHandler(\n handlerTag: number,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n newView: any,\n _actionType: ActionType,\n propsRef: React.RefObject<unknown>\n ) {\n if (!(newView instanceof Element || newView instanceof React.Component)) {\n shouldPreventDrop = true;\n\n const handler = isNewWebImplementationEnabled()\n ? NodeManager.getHandler(handlerTag)\n : HammerNodeManager.getHandler(handlerTag);\n\n const handlerName = handler.constructor.name;\n\n throw new Error(\n `${handlerName} with tag ${handlerTag} received child that is not valid HTML element.`\n );\n }\n\n if (isNewWebImplementationEnabled()) {\n // @ts-ignore Types should be HTMLElement or React.Component\n NodeManager.getHandler(handlerTag).init(newView, propsRef);\n } else {\n // @ts-ignore Types should be HTMLElement or React.Component\n HammerNodeManager.getHandler(handlerTag).setView(newView, propsRef);\n }\n },\n updateGestureHandler(handlerTag: number, newConfig: Config) {\n if (isNewWebImplementationEnabled()) {\n NodeManager.getHandler(handlerTag).updateGestureConfig(newConfig);\n\n InteractionManager.instance.configureInteractions(\n NodeManager.getHandler(handlerTag),\n newConfig\n );\n } else {\n HammerNodeManager.getHandler(handlerTag).updateGestureConfig(newConfig);\n }\n },\n getGestureHandlerNode(handlerTag: number) {\n if (isNewWebImplementationEnabled()) {\n return NodeManager.getHandler(handlerTag);\n } else {\n return HammerNodeManager.getHandler(handlerTag);\n }\n },\n dropGestureHandler(handlerTag: number) {\n if (shouldPreventDrop) {\n return;\n }\n\n if (isNewWebImplementationEnabled()) {\n NodeManager.dropGestureHandler(handlerTag);\n } else {\n HammerNodeManager.dropGestureHandler(handlerTag);\n }\n },\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n flushOperations() {},\n};\n"],"mappings":"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","ignoreList":[]}