@react-native-oh-tpl/react-native-gesture-handler 2.14.1-2.14.8 → 2.14.1-2.14.9
Sign up to get free protection for your applications and to get access to all the features.
- package/DrawerLayout/index.ts +2 -2
- package/Swipeable/index.ts +2 -2
- package/harmony/gesture_handler/BuildProfile.ets +17 -0
- package/harmony/gesture_handler/build-profile.json5 +19 -0
- package/harmony/gesture_handler/hvigorfile.ts +2 -0
- package/harmony/gesture_handler/index.ets +3 -0
- package/harmony/gesture_handler/oh-package-lock.json5 +18 -0
- package/harmony/gesture_handler/oh-package.json5 +12 -0
- package/harmony/gesture_handler/src/main/cpp/CMakeLists.txt +8 -0
- package/harmony/gesture_handler/src/main/cpp/GestureHandlerPackage.cpp +149 -0
- package/harmony/gesture_handler/src/main/cpp/GestureHandlerPackage.h +21 -0
- package/harmony/gesture_handler/src/main/cpp/RNGestureHandlerButtonComponentDescriptor.h +36 -0
- package/harmony/gesture_handler/src/main/cpp/RNGestureHandlerButtonJSIBinder.h +32 -0
- package/harmony/gesture_handler/src/main/cpp/RNGestureHandlerModule.cpp +22 -0
- package/harmony/gesture_handler/src/main/cpp/RNGestureHandlerModule.h +15 -0
- package/harmony/gesture_handler/src/main/cpp/RNGestureHandlerRootViewComponentDescriptor.h +36 -0
- package/harmony/gesture_handler/src/main/cpp/RNGestureHandlerRootViewJSIBinder.h +25 -0
- package/harmony/gesture_handler/src/main/cpp/componentInstances/RNGestureHandlerButtonComponentInstance.h +27 -0
- package/harmony/gesture_handler/src/main/cpp/componentInstances/RNGestureHandlerRootViewComponentInstance.h +234 -0
- package/harmony/gesture_handler/src/main/ets/core/CircularBuffer.ts +42 -0
- package/harmony/gesture_handler/src/main/ets/core/GestureHandler.ts +684 -0
- package/harmony/gesture_handler/src/main/ets/core/GestureHandlerOrchestrator.ts +335 -0
- package/harmony/gesture_handler/src/main/ets/core/GestureHandlerRegistry.ts +35 -0
- package/harmony/gesture_handler/src/main/ets/core/IncomingEvent.ts +78 -0
- package/harmony/gesture_handler/src/main/ets/core/InteractionManager.ts +144 -0
- package/harmony/gesture_handler/src/main/ets/core/LeastSquareSolver.ts +182 -0
- package/harmony/gesture_handler/src/main/ets/core/OutgoingEvent.ts +34 -0
- package/harmony/gesture_handler/src/main/ets/core/OutgoingEventDispatcher.ts +12 -0
- package/harmony/gesture_handler/src/main/ets/core/PointerTracker.ts +239 -0
- package/harmony/gesture_handler/src/main/ets/core/RNGHError.ts +5 -0
- package/harmony/gesture_handler/src/main/ets/core/RNGHLogger.ts +12 -0
- package/harmony/gesture_handler/src/main/ets/core/State.ts +47 -0
- package/harmony/gesture_handler/src/main/ets/core/Vector2D.ts +80 -0
- package/harmony/gesture_handler/src/main/ets/core/VelocityTracker.ts +106 -0
- package/harmony/gesture_handler/src/main/ets/core/View.ts +19 -0
- package/harmony/gesture_handler/src/main/ets/core/index.ts +13 -0
- package/harmony/gesture_handler/src/main/ets/detectors/ScaleGestureDetector.ts +169 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/FlingGestureHandler.ts +211 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/GestureHandlerFactory.ts +64 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/LongPressGestureHandler.ts +127 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/ManualGestureHandler.ts +42 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/NativeViewGestureHandler.ts +113 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/PanGestureHandler.ts +342 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/PinchGestureHandler.ts +159 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/RotationGestureHandler.ts +164 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/TapGestureHandler.ts +206 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/detectors/RotationGestureDetector.ts +167 -0
- package/harmony/gesture_handler/src/main/ets/gesture-handlers/index.ts +1 -0
- package/harmony/gesture_handler/src/main/ets/namespace/RNGestureHandlerModule.ts +24 -0
- package/harmony/gesture_handler/src/main/ets/namespace/components/RNGestureHandlerButton.ts +139 -0
- package/harmony/gesture_handler/src/main/ets/namespace/components/RNGestureHandlerRootView.ts +101 -0
- package/harmony/gesture_handler/src/main/ets/namespace/components/ts.ts +2 -0
- package/harmony/gesture_handler/src/main/ets/namespace/ts.ts +2 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/GestureHandlerArkUIAdapter.ts +240 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/GestureHandlerPackage.ts +22 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/Logger.ts +49 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/OutgoingEventDispatchers.ts +71 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNGHRootTouchHandlerArkTS.ts +104 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNGHRootTouchHandlerCAPI.ts +110 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNGestureHandlerButton.ets +38 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNGestureHandlerModule.ts +230 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNGestureHandlerRootView.ets +53 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNOHGestureResponder.ts +24 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/RNOHScrollLocker.ts +32 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/View.ts +119 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/ViewRegistry.ts +95 -0
- package/harmony/gesture_handler/src/main/ets/rnoh/types.ts +25 -0
- package/harmony/gesture_handler/src/main/module.json5 +9 -0
- package/harmony/gesture_handler/src/main/resources/base/element/color.json +8 -0
- package/harmony/gesture_handler/src/main/resources/base/element/string.json +16 -0
- package/harmony/gesture_handler/src/main/resources/base/media/icon.png +0 -0
- package/harmony/gesture_handler/src/main/resources/base/profile/main_pages.json +5 -0
- package/harmony/gesture_handler/src/main/resources/en_US/element/string.json +16 -0
- package/harmony/gesture_handler/src/main/resources/zh_CN/element/string.json +16 -0
- package/harmony/gesture_handler/ts.ts +2 -0
- package/harmony/gesture_handler.har +0 -0
- package/lib/commonjs/RNGestureHandlerModule.js +3 -2
- package/lib/commonjs/RNGestureHandlerModule.js.map +1 -1
- package/lib/commonjs/components/GestureHandlerRootView.js +3 -3
- package/lib/commonjs/components/GestureHandlerRootView.js.map +1 -1
- package/lib/commonjs/handlers/createHandler.js +18 -15
- package/lib/commonjs/handlers/createHandler.js.map +1 -1
- package/lib/commonjs/index.js +8 -5
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/specs/NativeRNGestureHandlerModule.js +2 -1
- package/lib/commonjs/specs/NativeRNGestureHandlerModule.js.map +1 -1
- package/lib/commonjs/specs/RNGestureHandlerButtonNativeComponent.js +3 -2
- package/lib/commonjs/specs/RNGestureHandlerButtonNativeComponent.js.map +1 -1
- package/lib/commonjs/specs/RNGestureHandlerRootViewNativeComponent.js +3 -2
- package/lib/commonjs/specs/RNGestureHandlerRootViewNativeComponent.js.map +1 -1
- package/lib/module/RNGestureHandlerModule.js.map +1 -1
- package/lib/module/components/GestureHandlerRootView.js.map +1 -1
- package/lib/module/handlers/createHandler.js +15 -12
- package/lib/module/handlers/createHandler.js.map +1 -1
- package/lib/module/index.js +1 -3
- package/lib/module/index.js.map +1 -1
- package/lib/module/specs/NativeRNGestureHandlerModule.js.map +1 -1
- package/lib/module/specs/RNGestureHandlerButtonNativeComponent.js.map +1 -1
- package/lib/module/specs/RNGestureHandlerRootViewNativeComponent.js.map +1 -1
- package/lib/typescript/RNGestureHandlerModule.d.ts +2 -2
- package/lib/typescript/components/GestureHandlerRootView.d.ts +6 -6
- package/lib/typescript/handlers/createHandler.d.ts +11 -11
- package/lib/typescript/index.d.ts +43 -42
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/specs/NativeRNGestureHandlerModule.d.ts +14 -14
- package/lib/typescript/specs/RNGestureHandlerButtonNativeComponent.d.ts +14 -14
- package/lib/typescript/specs/RNGestureHandlerRootViewNativeComponent.d.ts +6 -6
- package/package.json +68 -69
- package/src/RNGestureHandlerModule.ts +4 -4
- package/src/components/GestureHandlerRootView.tsx +23 -23
- package/src/handlers/createHandler.tsx +534 -534
- package/src/index.ts +172 -172
- package/src/specs/NativeRNGestureHandlerModule.ts +26 -26
- package/src/specs/RNGestureHandlerButtonNativeComponent.ts +18 -18
- package/src/specs/RNGestureHandlerRootViewNativeComponent.ts +6 -6
@@ -1,12 +1,12 @@
|
|
1
|
-
import * as React from 'react';
|
2
|
-
import { BaseGestureHandlerProps } from "react-native-gesture-handler/src/handlers/gestureHandlerCommon";
|
3
|
-
declare type CreateHandlerArgs<HandlerPropsT extends Record<string, unknown>> = Readonly<{
|
4
|
-
name: string;
|
5
|
-
allowedProps: Readonly<Extract<keyof HandlerPropsT, string>[]>;
|
6
|
-
config: Readonly<Record<string, unknown>>;
|
7
|
-
transformProps?: (props: HandlerPropsT) => HandlerPropsT;
|
8
|
-
customNativeProps?: Readonly<string[]>;
|
9
|
-
}>;
|
10
|
-
export default function createHandler<T extends BaseGestureHandlerProps<U>, U extends Record<string, unknown>>({ name, allowedProps, config, transformProps, customNativeProps, }: CreateHandlerArgs<T>): React.ComponentType<T & React.RefAttributes<any>>;
|
11
|
-
export {};
|
1
|
+
import * as React from 'react';
|
2
|
+
import { BaseGestureHandlerProps } from "react-native-gesture-handler/src/handlers/gestureHandlerCommon";
|
3
|
+
declare type CreateHandlerArgs<HandlerPropsT extends Record<string, unknown>> = Readonly<{
|
4
|
+
name: string;
|
5
|
+
allowedProps: Readonly<Extract<keyof HandlerPropsT, string>[]>;
|
6
|
+
config: Readonly<Record<string, unknown>>;
|
7
|
+
transformProps?: (props: HandlerPropsT) => HandlerPropsT;
|
8
|
+
customNativeProps?: Readonly<string[]>;
|
9
|
+
}>;
|
10
|
+
export default function createHandler<T extends BaseGestureHandlerProps<U>, U extends Record<string, unknown>>({ name, allowedProps, config, transformProps, customNativeProps, }: CreateHandlerArgs<T>): React.ComponentType<T & React.RefAttributes<any>>;
|
11
|
+
export {};
|
12
12
|
//# sourceMappingURL=createHandler.d.ts.map
|
@@ -1,43 +1,44 @@
|
|
1
|
-
export { Directions } from 'react-native-gesture-handler/src/Directions';
|
2
|
-
export { State } from 'react-native-gesture-handler/src/State';
|
3
|
-
export { default as gestureHandlerRootHOC } from 'react-native-gesture-handler/src/components/gestureHandlerRootHOC';
|
4
|
-
export { default as GestureHandlerRootView } from './components/GestureHandlerRootView';
|
5
|
-
export type { GestureEvent, HandlerStateChangeEvent, GestureEventPayload, HandlerStateChangeEventPayload, GestureTouchEvent, TouchData, GestureUpdateEvent, GestureStateChangeEvent, } from 'react-native-gesture-handler/src/handlers/gestureHandlerCommon';
|
6
|
-
export type { GestureType } from 'react-native-gesture-handler/src/handlers/gestures/gesture';
|
7
|
-
export type { TapGestureHandlerEventPayload, TapGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/TapGestureHandler';
|
8
|
-
export type { ForceTouchGestureHandlerEventPayload, ForceTouchGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/ForceTouchGestureHandler';
|
9
|
-
export type { ForceTouchGestureChangeEventPayload } from 'react-native-gesture-handler/src/handlers/gestures/forceTouchGesture';
|
10
|
-
export type { LongPressGestureHandlerEventPayload, LongPressGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/LongPressGestureHandler';
|
11
|
-
export type { PanGestureHandlerEventPayload, PanGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/PanGestureHandler';
|
12
|
-
export type { PanGestureChangeEventPayload } from 'react-native-gesture-handler/src/handlers/gestures/panGesture';
|
13
|
-
export type { PinchGestureHandlerEventPayload, PinchGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/PinchGestureHandler';
|
14
|
-
export type { PinchGestureChangeEventPayload } from 'react-native-gesture-handler/src/handlers/gestures/pinchGesture';
|
15
|
-
export type { RotationGestureHandlerEventPayload, RotationGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/RotationGestureHandler';
|
16
|
-
export type { FlingGestureHandlerEventPayload, FlingGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/FlingGestureHandler';
|
17
|
-
export { TapGestureHandler } from 'react-native-gesture-handler/src/handlers/TapGestureHandler';
|
18
|
-
export { PanGestureHandler } from 'react-native-gesture-handler/src/handlers/PanGestureHandler';
|
19
|
-
export { default as createNativeWrapper } from 'react-native-gesture-handler/src/handlers/createNativeWrapper';
|
20
|
-
export type { NativeViewGestureHandlerPayload, NativeViewGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/NativeViewGestureHandler';
|
21
|
-
export { GestureDetector } from 'react-native-gesture-handler/src/handlers/gestures/GestureDetector';
|
22
|
-
export { GestureObjects as Gesture } from 'react-native-gesture-handler/src/handlers/gestures/gestureObjects';
|
23
|
-
export type { TapGestureType as TapGesture } from 'react-native-gesture-handler/src/handlers/gestures/tapGesture';
|
24
|
-
export type { PanGestureType as PanGesture } from 'react-native-gesture-handler/src/handlers/gestures/panGesture';
|
25
|
-
export type { FlingGestureType as FlingGesture } from 'react-native-gesture-handler/src/handlers/gestures/flingGesture';
|
26
|
-
export type { LongPressGestureType as LongPressGesture } from 'react-native-gesture-handler/src/handlers/gestures/longPressGesture';
|
27
|
-
export type { PinchGestureType as PinchGesture } from 'react-native-gesture-handler/src/handlers/gestures/pinchGesture';
|
28
|
-
export type { RotationGestureType as RotationGesture } from 'react-native-gesture-handler/src/handlers/gestures/rotationGesture';
|
29
|
-
export type { ForceTouchGestureType as ForceTouchGesture } from 'react-native-gesture-handler/src/handlers/gestures/forceTouchGesture';
|
30
|
-
export type { NativeGestureType as NativeGesture } from 'react-native-gesture-handler/src/handlers/gestures/nativeGesture';
|
31
|
-
export type { ManualGestureType as ManualGesture } from 'react-native-gesture-handler/src/handlers/gestures/manualGesture';
|
32
|
-
export type { ComposedGestureType as ComposedGesture, RaceGestureType as RaceGesture, SimultaneousGestureType as SimultaneousGesture, ExclusiveGestureType as ExclusiveGesture, } from 'react-native-gesture-handler/src/handlers/gestures/gestureComposition';
|
33
|
-
export type { GestureStateManagerType as GestureStateManager } from 'react-native-gesture-handler/src/handlers/gestures/gestureStateManager';
|
34
|
-
export
|
35
|
-
export {
|
36
|
-
export {
|
37
|
-
export {
|
38
|
-
export
|
39
|
-
export {
|
40
|
-
export
|
41
|
-
export {
|
42
|
-
export {
|
1
|
+
export { Directions } from 'react-native-gesture-handler/src/Directions';
|
2
|
+
export { State } from 'react-native-gesture-handler/src/State';
|
3
|
+
export { default as gestureHandlerRootHOC } from 'react-native-gesture-handler/src/components/gestureHandlerRootHOC';
|
4
|
+
export { default as GestureHandlerRootView } from './components/GestureHandlerRootView';
|
5
|
+
export type { GestureEvent, HandlerStateChangeEvent, GestureEventPayload, HandlerStateChangeEventPayload, GestureTouchEvent, TouchData, GestureUpdateEvent, GestureStateChangeEvent, } from 'react-native-gesture-handler/src/handlers/gestureHandlerCommon';
|
6
|
+
export type { GestureType } from 'react-native-gesture-handler/src/handlers/gestures/gesture';
|
7
|
+
export type { TapGestureHandlerEventPayload, TapGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/TapGestureHandler';
|
8
|
+
export type { ForceTouchGestureHandlerEventPayload, ForceTouchGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/ForceTouchGestureHandler';
|
9
|
+
export type { ForceTouchGestureChangeEventPayload } from 'react-native-gesture-handler/src/handlers/gestures/forceTouchGesture';
|
10
|
+
export type { LongPressGestureHandlerEventPayload, LongPressGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/LongPressGestureHandler';
|
11
|
+
export type { PanGestureHandlerEventPayload, PanGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/PanGestureHandler';
|
12
|
+
export type { PanGestureChangeEventPayload } from 'react-native-gesture-handler/src/handlers/gestures/panGesture';
|
13
|
+
export type { PinchGestureHandlerEventPayload, PinchGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/PinchGestureHandler';
|
14
|
+
export type { PinchGestureChangeEventPayload } from 'react-native-gesture-handler/src/handlers/gestures/pinchGesture';
|
15
|
+
export type { RotationGestureHandlerEventPayload, RotationGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/RotationGestureHandler';
|
16
|
+
export type { FlingGestureHandlerEventPayload, FlingGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/FlingGestureHandler';
|
17
|
+
export { TapGestureHandler } from 'react-native-gesture-handler/src/handlers/TapGestureHandler';
|
18
|
+
export { PanGestureHandler } from 'react-native-gesture-handler/src/handlers/PanGestureHandler';
|
19
|
+
export { default as createNativeWrapper } from 'react-native-gesture-handler/src/handlers/createNativeWrapper';
|
20
|
+
export type { NativeViewGestureHandlerPayload, NativeViewGestureHandlerProps, } from 'react-native-gesture-handler/src/handlers/NativeViewGestureHandler';
|
21
|
+
export { GestureDetector } from 'react-native-gesture-handler/src/handlers/gestures/GestureDetector';
|
22
|
+
export { GestureObjects as Gesture } from 'react-native-gesture-handler/src/handlers/gestures/gestureObjects';
|
23
|
+
export type { TapGestureType as TapGesture } from 'react-native-gesture-handler/src/handlers/gestures/tapGesture';
|
24
|
+
export type { PanGestureType as PanGesture } from 'react-native-gesture-handler/src/handlers/gestures/panGesture';
|
25
|
+
export type { FlingGestureType as FlingGesture } from 'react-native-gesture-handler/src/handlers/gestures/flingGesture';
|
26
|
+
export type { LongPressGestureType as LongPressGesture } from 'react-native-gesture-handler/src/handlers/gestures/longPressGesture';
|
27
|
+
export type { PinchGestureType as PinchGesture } from 'react-native-gesture-handler/src/handlers/gestures/pinchGesture';
|
28
|
+
export type { RotationGestureType as RotationGesture } from 'react-native-gesture-handler/src/handlers/gestures/rotationGesture';
|
29
|
+
export type { ForceTouchGestureType as ForceTouchGesture } from 'react-native-gesture-handler/src/handlers/gestures/forceTouchGesture';
|
30
|
+
export type { NativeGestureType as NativeGesture } from 'react-native-gesture-handler/src/handlers/gestures/nativeGesture';
|
31
|
+
export type { ManualGestureType as ManualGesture } from 'react-native-gesture-handler/src/handlers/gestures/manualGesture';
|
32
|
+
export type { ComposedGestureType as ComposedGesture, RaceGestureType as RaceGesture, SimultaneousGestureType as SimultaneousGesture, ExclusiveGestureType as ExclusiveGesture, } from 'react-native-gesture-handler/src/handlers/gestures/gestureComposition';
|
33
|
+
export type { GestureStateManagerType as GestureStateManager } from 'react-native-gesture-handler/src/handlers/gestures/gestureStateManager';
|
34
|
+
export { NativeViewGestureHandler } from 'react-native-gesture-handler/src/handlers/NativeViewGestureHandler';
|
35
|
+
export type { RawButtonProps, BaseButtonProps, RectButtonProps, BorderlessButtonProps, } from 'react-native-gesture-handler/src/components/GestureButtons';
|
36
|
+
export { RawButton, BaseButton, RectButton, BorderlessButton, PureNativeButton, } from 'react-native-gesture-handler/src/components/GestureButtons';
|
37
|
+
export { TouchableHighlight, TouchableNativeFeedback, TouchableOpacity, TouchableWithoutFeedback, } from 'react-native-gesture-handler/src/components/touchables';
|
38
|
+
export { ScrollView, Switch, TextInput, DrawerLayoutAndroid, FlatList, RefreshControl, } from 'react-native-gesture-handler/src/components/GestureComponents';
|
39
|
+
export type { GestureHandlerGestureEvent, GestureHandlerStateChangeEvent, GestureHandlerGestureEventNativeEvent, GestureHandlerStateChangeNativeEvent, NativeViewGestureHandlerGestureEvent, NativeViewGestureHandlerStateChangeEvent, TapGestureHandlerGestureEvent, TapGestureHandlerStateChangeEvent, ForceTouchGestureHandlerGestureEvent, ForceTouchGestureHandlerStateChangeEvent, LongPressGestureHandlerGestureEvent, LongPressGestureHandlerStateChangeEvent, PanGestureHandlerGestureEvent, PanGestureHandlerStateChangeEvent, PinchGestureHandlerGestureEvent, PinchGestureHandlerStateChangeEvent, RotationGestureHandlerGestureEvent, RotationGestureHandlerStateChangeEvent, FlingGestureHandlerGestureEvent, FlingGestureHandlerStateChangeEvent, NativeViewGestureHandlerProperties, TapGestureHandlerProperties, LongPressGestureHandlerProperties, PanGestureHandlerProperties, PinchGestureHandlerProperties, RotationGestureHandlerProperties, FlingGestureHandlerProperties, ForceTouchGestureHandlerProperties, RawButtonProperties, BaseButtonProperties, RectButtonProperties, BorderlessButtonProperties, } from 'react-native-gesture-handler/src/handlers/gestureHandlerTypesCompat';
|
40
|
+
export { default as Swipeable } from 'react-native-gesture-handler/src/components/Swipeable';
|
41
|
+
export type { DrawerLayoutProps, DrawerPosition, DrawerState, DrawerType, DrawerLockMode, DrawerKeyboardDismissMode, } from 'react-native-gesture-handler/src/components/DrawerLayout';
|
42
|
+
export { default as DrawerLayout } from 'react-native-gesture-handler/src/components/DrawerLayout';
|
43
|
+
export { enableExperimentalWebImplementation, enableLegacyWebImplementation, } from 'react-native-gesture-handler/src/EnableNewWebImplementation';
|
43
44
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,UAAU,EAAE,MAAM,6CAA6C,CAAC;AACzE,OAAO,EAAE,KAAK,EAAE,MAAM,wCAAwC,CAAC;AAC/D,OAAO,EAAE,OAAO,IAAI,qBAAqB,EAAE,MAAM,mEAAmE,CAAC;AACrH,OAAO,EAAE,OAAO,IAAI,sBAAsB,EAAE,MAAM,qCAAqC,CAAC;AACxF,YAAY,EAEV,YAAY,EACZ,uBAAuB,EAEvB,mBAAmB,EACnB,8BAA8B,EAE9B,iBAAiB,EACjB,SAAS,EAET,kBAAkB,EAClB,uBAAuB,GACxB,MAAM,gEAAgE,CAAC;AACxE,YAAY,EAAE,WAAW,EAAE,MAAM,4DAA4D,CAAC;AAC9F,YAAY,EACV,6BAA6B,EAC7B,sBAAsB,GACvB,MAAM,6DAA6D,CAAC;AACrE,YAAY,EACV,oCAAoC,EACpC,6BAA6B,GAC9B,MAAM,oEAAoE,CAAC;AAC5E,YAAY,EAAE,mCAAmC,EAAE,MAAM,sEAAsE,CAAC;AAChI,YAAY,EACV,mCAAmC,EACnC,4BAA4B,GAC7B,MAAM,mEAAmE,CAAC;AAC3E,YAAY,EACV,6B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C1B,MAAM,0DAA0D,CAAC;AAClE,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,0DAA0D,CAAC;AAEnG,OAAO,EACL,mCAAmC,EACnC,6BAA6B,GAC9B,MAAM,6DAA6D,CAAC"}
|
@@ -1,15 +1,15 @@
|
|
1
|
-
import { TurboModule } from 'react-native';
|
2
|
-
import { Int32 } from 'react-native/Libraries/Types/CodegenTypes';
|
3
|
-
export interface Spec extends TurboModule {
|
4
|
-
handleSetJSResponder: (tag: Int32, blockNativeResponder: boolean) => void;
|
5
|
-
handleClearJSResponder: () => void;
|
6
|
-
createGestureHandler: (handlerName: string, handlerTag: Int32, config: Object) => void;
|
7
|
-
attachGestureHandler: (handlerTag: Int32, newView: Int32, actionType: Int32) => void;
|
8
|
-
updateGestureHandler: (handlerTag: Int32, newConfig: Object) => void;
|
9
|
-
dropGestureHandler: (handlerTag: Int32) => void;
|
10
|
-
install: () => boolean;
|
11
|
-
flushOperations: () => void;
|
12
|
-
}
|
13
|
-
declare const _default: Spec;
|
14
|
-
export default _default;
|
1
|
+
import { TurboModule } from 'react-native';
|
2
|
+
import { Int32 } from 'react-native/Libraries/Types/CodegenTypes';
|
3
|
+
export interface Spec extends TurboModule {
|
4
|
+
handleSetJSResponder: (tag: Int32, blockNativeResponder: boolean) => void;
|
5
|
+
handleClearJSResponder: () => void;
|
6
|
+
createGestureHandler: (handlerName: string, handlerTag: Int32, config: Object) => void;
|
7
|
+
attachGestureHandler: (handlerTag: Int32, newView: Int32, actionType: Int32) => void;
|
8
|
+
updateGestureHandler: (handlerTag: Int32, newConfig: Object) => void;
|
9
|
+
dropGestureHandler: (handlerTag: Int32) => void;
|
10
|
+
install: () => boolean;
|
11
|
+
flushOperations: () => void;
|
12
|
+
}
|
13
|
+
declare const _default: Spec;
|
14
|
+
export default _default;
|
15
15
|
//# sourceMappingURL=NativeRNGestureHandlerModule.d.ts.map
|
@@ -1,15 +1,15 @@
|
|
1
|
-
/// <reference types="react-native/types/modules/codegen" />
|
2
|
-
import type { Int32, WithDefault } from 'react-native/Libraries/Types/CodegenTypes';
|
3
|
-
import type { ViewProps, ColorValue } from 'react-native';
|
4
|
-
interface NativeProps extends ViewProps {
|
5
|
-
exclusive?: WithDefault<boolean, true>;
|
6
|
-
foreground?: boolean;
|
7
|
-
borderless?: boolean;
|
8
|
-
enabled?: WithDefault<boolean, true>;
|
9
|
-
rippleColor?: ColorValue;
|
10
|
-
rippleRadius?: Int32;
|
11
|
-
touchSoundDisabled?: WithDefault<boolean, false>;
|
12
|
-
}
|
13
|
-
declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
|
14
|
-
export default _default;
|
1
|
+
/// <reference types="react-native/types/modules/codegen" />
|
2
|
+
import type { Int32, WithDefault } from 'react-native/Libraries/Types/CodegenTypes';
|
3
|
+
import type { ViewProps, ColorValue } from 'react-native';
|
4
|
+
interface NativeProps extends ViewProps {
|
5
|
+
exclusive?: WithDefault<boolean, true>;
|
6
|
+
foreground?: boolean;
|
7
|
+
borderless?: boolean;
|
8
|
+
enabled?: WithDefault<boolean, true>;
|
9
|
+
rippleColor?: ColorValue;
|
10
|
+
rippleRadius?: Int32;
|
11
|
+
touchSoundDisabled?: WithDefault<boolean, false>;
|
12
|
+
}
|
13
|
+
declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
|
14
|
+
export default _default;
|
15
15
|
//# sourceMappingURL=RNGestureHandlerButtonNativeComponent.d.ts.map
|
@@ -1,7 +1,7 @@
|
|
1
|
-
/// <reference types="react-native/types/modules/codegen" />
|
2
|
-
import type { ViewProps } from 'react-native';
|
3
|
-
interface NativeProps extends ViewProps {
|
4
|
-
}
|
5
|
-
declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
|
6
|
-
export default _default;
|
1
|
+
/// <reference types="react-native/types/modules/codegen" />
|
2
|
+
import type { ViewProps } from 'react-native';
|
3
|
+
interface NativeProps extends ViewProps {
|
4
|
+
}
|
5
|
+
declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
|
6
|
+
export default _default;
|
7
7
|
//# sourceMappingURL=RNGestureHandlerRootViewNativeComponent.d.ts.map
|
package/package.json
CHANGED
@@ -1,70 +1,69 @@
|
|
1
|
-
{
|
2
|
-
"name": "@react-native-oh-tpl/react-native-gesture-handler",
|
3
|
-
"harmony": {
|
4
|
-
"alias": "react-native-gesture-handler",
|
5
|
-
"redirectInternalImports": true
|
6
|
-
},
|
7
|
-
"repository": {
|
8
|
-
"type": "git",
|
9
|
-
"url": "https://github.com/react-native-oh-library/react-native-harmony-gesture-handler.git"
|
10
|
-
},
|
11
|
-
"version": "2.14.1-2.14.
|
12
|
-
"description": "",
|
13
|
-
"react-native": "src/index.ts",
|
14
|
-
"main": "lib/commonjs/index.js",
|
15
|
-
"module": "lib/module/index.js",
|
16
|
-
"types": "lib/typescript/index.d.ts",
|
17
|
-
"scripts": {
|
18
|
-
"prepack": "bob build",
|
19
|
-
"test": "jest",
|
20
|
-
"pack:prod": "npm pack",
|
21
|
-
"
|
22
|
-
"
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
"react": "*",
|
27
|
-
"react-native": "*",
|
28
|
-
"react-native-
|
29
|
-
|
30
|
-
|
31
|
-
"
|
32
|
-
"
|
33
|
-
"
|
34
|
-
|
35
|
-
"
|
36
|
-
"
|
37
|
-
"@babel/
|
38
|
-
"@babel/
|
39
|
-
"@babel/preset-
|
40
|
-
"@babel/
|
41
|
-
"@
|
42
|
-
"
|
43
|
-
"
|
44
|
-
"react": "^
|
45
|
-
"react-native": "^0.
|
46
|
-
"
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
"
|
51
|
-
"
|
52
|
-
"
|
53
|
-
"
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
"
|
58
|
-
"
|
59
|
-
|
60
|
-
"
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
}
|
1
|
+
{
|
2
|
+
"name": "@react-native-oh-tpl/react-native-gesture-handler",
|
3
|
+
"harmony": {
|
4
|
+
"alias": "react-native-gesture-handler",
|
5
|
+
"redirectInternalImports": true
|
6
|
+
},
|
7
|
+
"repository": {
|
8
|
+
"type": "git",
|
9
|
+
"url": "https://github.com/react-native-oh-library/react-native-harmony-gesture-handler.git"
|
10
|
+
},
|
11
|
+
"version": "2.14.1-2.14.9",
|
12
|
+
"description": "",
|
13
|
+
"react-native": "src/index.ts",
|
14
|
+
"main": "lib/commonjs/index.js",
|
15
|
+
"module": "lib/module/index.js",
|
16
|
+
"types": "lib/typescript/index.d.ts",
|
17
|
+
"scripts": {
|
18
|
+
"prepack": "bob build",
|
19
|
+
"test": "jest",
|
20
|
+
"pack:prod": "npm pack",
|
21
|
+
"update_version": "node ./scripts/update-version.js",
|
22
|
+
"deploy": "node ./scripts/deploy.js"
|
23
|
+
},
|
24
|
+
"peerDependencies": {
|
25
|
+
"react": "*",
|
26
|
+
"react-native": "*",
|
27
|
+
"react-native-harmony": "*",
|
28
|
+
"react-native-gesture-handler": "2.14.1"
|
29
|
+
},
|
30
|
+
"keywords": [],
|
31
|
+
"author": "",
|
32
|
+
"license": "ISC",
|
33
|
+
"devDependencies": {
|
34
|
+
"@types/hoist-non-react-statics": "^3.3.1",
|
35
|
+
"react-native-gesture-handler": "2.14.1",
|
36
|
+
"@babel/core": "^7.12.9",
|
37
|
+
"@babel/plugin-proposal-class-properties": "^7.12.1",
|
38
|
+
"@babel/preset-env": "^7.12.11",
|
39
|
+
"@babel/preset-typescript": "^7.12.7",
|
40
|
+
"@babel/runtime": "^7.12.5",
|
41
|
+
"@types/react": "^18.2.18",
|
42
|
+
"metro-react-native-babel-preset": "^0.64.0",
|
43
|
+
"react": "^18.2.0",
|
44
|
+
"react-native": "^0.72.0",
|
45
|
+
"react-native-builder-bob": "^0.21.3",
|
46
|
+
"typescript": "4.5.5"
|
47
|
+
},
|
48
|
+
"files": [
|
49
|
+
"./harmony/*",
|
50
|
+
"src",
|
51
|
+
"lib",
|
52
|
+
"DrawerLayout/",
|
53
|
+
"Swipeable/"
|
54
|
+
],
|
55
|
+
"react-native-builder-bob": {
|
56
|
+
"source": "src",
|
57
|
+
"output": "lib",
|
58
|
+
"targets": [
|
59
|
+
"commonjs",
|
60
|
+
"module",
|
61
|
+
[
|
62
|
+
"typescript",
|
63
|
+
{
|
64
|
+
"project": "tsconfig.build.json"
|
65
|
+
}
|
66
|
+
]
|
67
|
+
]
|
68
|
+
}
|
70
69
|
}
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import NativeRNGestureHandlerModule from '../src/specs/NativeRNGestureHandlerModule';
|
2
|
-
|
3
|
-
const RNGestureHandlerModule = NativeRNGestureHandlerModule;
|
4
|
-
|
1
|
+
import NativeRNGestureHandlerModule from '../src/specs/NativeRNGestureHandlerModule';
|
2
|
+
|
3
|
+
const RNGestureHandlerModule = NativeRNGestureHandlerModule;
|
4
|
+
|
5
5
|
export default RNGestureHandlerModule;
|
@@ -1,23 +1,23 @@
|
|
1
|
-
import * as React from 'react';
|
2
|
-
import { PropsWithChildren } from 'react';
|
3
|
-
import { ViewProps } from 'react-native';
|
4
|
-
import { maybeInitializeFabric } from "react-native-gesture-handler/src/init";
|
5
|
-
import GestureHandlerRootViewContext from 'react-native-gesture-handler/src/GestureHandlerRootViewContext';
|
6
|
-
import RNGestureHandlerRootViewNativeComponent from '../specs/RNGestureHandlerRootViewNativeComponent';
|
7
|
-
export interface GestureHandlerRootViewProps
|
8
|
-
extends PropsWithChildren<ViewProps> {}
|
9
|
-
|
10
|
-
export default function GestureHandlerRootView(
|
11
|
-
props: GestureHandlerRootViewProps
|
12
|
-
) {
|
13
|
-
// try initialize fabric on the first render, at this point we can
|
14
|
-
// reliably check if fabric is enabled (the function contains a flag
|
15
|
-
// to make sure it's called only once)
|
16
|
-
maybeInitializeFabric();
|
17
|
-
|
18
|
-
return (
|
19
|
-
<GestureHandlerRootViewContext.Provider value>
|
20
|
-
<RNGestureHandlerRootViewNativeComponent {...props} />
|
21
|
-
</GestureHandlerRootViewContext.Provider>
|
22
|
-
);
|
23
|
-
}
|
1
|
+
import * as React from 'react';
|
2
|
+
import { PropsWithChildren } from 'react';
|
3
|
+
import { ViewProps } from 'react-native';
|
4
|
+
import { maybeInitializeFabric } from "react-native-gesture-handler/src/init";
|
5
|
+
import GestureHandlerRootViewContext from 'react-native-gesture-handler/src/GestureHandlerRootViewContext';
|
6
|
+
import RNGestureHandlerRootViewNativeComponent from '../specs/RNGestureHandlerRootViewNativeComponent';
|
7
|
+
export interface GestureHandlerRootViewProps
|
8
|
+
extends PropsWithChildren<ViewProps> {}
|
9
|
+
|
10
|
+
export default function GestureHandlerRootView(
|
11
|
+
props: GestureHandlerRootViewProps
|
12
|
+
) {
|
13
|
+
// try initialize fabric on the first render, at this point we can
|
14
|
+
// reliably check if fabric is enabled (the function contains a flag
|
15
|
+
// to make sure it's called only once)
|
16
|
+
maybeInitializeFabric();
|
17
|
+
|
18
|
+
return (
|
19
|
+
<GestureHandlerRootViewContext.Provider value>
|
20
|
+
<RNGestureHandlerRootViewNativeComponent {...props} />
|
21
|
+
</GestureHandlerRootViewContext.Provider>
|
22
|
+
);
|
23
|
+
}
|