Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3345594
D5935.id19874.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
5 KB
Referenced Files
None
Subscribers
None
D5935.id19874.diff
View Options
diff --git a/native/android/app/src/main/java/app/comm/android/MainActivity.java b/native/android/app/src/main/java/app/comm/android/MainActivity.java
--- a/native/android/app/src/main/java/app/comm/android/MainActivity.java
+++ b/native/android/app/src/main/java/app/comm/android/MainActivity.java
@@ -5,7 +5,6 @@
import com.facebook.react.ReactActivity;
import com.facebook.react.ReactActivityDelegate;
import com.facebook.react.ReactRootView;
-import com.swmansion.gesturehandler.react.RNGestureHandlerEnabledRootView;
import expo.modules.ReactActivityDelegateWrapper;
public class MainActivity extends ReactActivity {
@@ -38,12 +37,9 @@
@Override
protected ReactActivityDelegate createReactActivityDelegate() {
return new ReactActivityDelegateWrapper(
- this, new MainActivityDelegate(this, getMainComponentName()) {
- @Override
- protected ReactRootView createRootView() {
- return new RNGestureHandlerEnabledRootView(MainActivity.this);
- }
- });
+ this,
+ new MainActivityDelegate(this, getMainComponentName())
+ );
}
public static class MainActivityDelegate extends ReactActivityDelegate {
public MainActivityDelegate(
diff --git a/native/chat/swipeable-message.react.js b/native/chat/swipeable-message.react.js
--- a/native/chat/swipeable-message.react.js
+++ b/native/chat/swipeable-message.react.js
@@ -312,7 +312,7 @@
snakes.push(
<PanGestureHandler
maxPointers={1}
- minDist={4}
+ activeOffsetX={[-4, 4]}
onGestureEvent={swipeEvent}
failOffsetX={isViewer ? 5 : -5}
failOffsetY={[-5, 5]}
diff --git a/native/flow-typed/npm/react-native-gesture-handler_v1.x.x.js b/native/flow-typed/npm/react-native-gesture-handler_v2.x.x.js
rename from native/flow-typed/npm/react-native-gesture-handler_v1.x.x.js
rename to native/flow-typed/npm/react-native-gesture-handler_v2.x.x.js
--- a/native/flow-typed/npm/react-native-gesture-handler_v1.x.x.js
+++ b/native/flow-typed/npm/react-native-gesture-handler_v2.x.x.js
@@ -408,8 +408,6 @@
maxDurationMs?: number,
maxDelayMs?: number,
numberOfTaps?: number,
- maxDeltaX?: number,
- maxDeltaY?: number,
maxDist?: number,
minPointers?: number,
...
@@ -622,6 +620,8 @@
...$Exact<Config>,
...
}>;
+
+ declare export var GestureHandlerRootView: React$ComponentType<{...}>;
}
declare module 'react-native-gesture-handler' {
diff --git a/native/ios/Podfile.lock b/native/ios/Podfile.lock
--- a/native/ios/Podfile.lock
+++ b/native/ios/Podfile.lock
@@ -490,7 +490,7 @@
- SDWebImageWebPCoder (~> 0.6.1)
- RNFS (2.15.2):
- React
- - RNGestureHandler (1.10.3):
+ - RNGestureHandler (2.8.0):
- React-Core
- RNKeychain (8.0.0):
- React-Core
@@ -895,7 +895,7 @@
RNExitApp: c4e052df2568b43bec8a37c7cd61194d4cfee2c3
RNFastImage: 2ed80661d5ef384fb1b539f1f3c81a1733f92bc9
RNFS: 54da03c2b7d862c42ea3ca8c7f86f892760a535a
- RNGestureHandler: a479ebd5ed4221a810967000735517df0d2db211
+ RNGestureHandler: 62232ba8f562f7dea5ba1b3383494eb5bf97a4d3
RNKeychain: 4f63aada75ebafd26f4bc2c670199461eab85d94
RNReanimated: f586bc5fd8ce1b6efadffb875319705939843c3b
RNScreens: 34cc502acf1b916c582c60003dc3089fa01dc66d
diff --git a/native/package.json b/native/package.json
--- a/native/package.json
+++ b/native/package.json
@@ -92,7 +92,7 @@
"react-native-firebase": "^5.6.0",
"react-native-floating-action": "^1.21.0",
"react-native-fs": "2.15.2",
- "react-native-gesture-handler": "^1.10.3",
+ "react-native-gesture-handler": "^2.8.0",
"react-native-in-app-message": "^1.0.2",
"react-native-keyboard-input": "6.0.1",
"react-native-keychain": "^8.0.0",
diff --git a/native/root.react.js b/native/root.react.js
--- a/native/root.react.js
+++ b/native/root.react.js
@@ -8,7 +8,7 @@
import * as SplashScreen from 'expo-splash-screen';
import invariant from 'invariant';
import * as React from 'react';
-import { Platform, UIManager, View, StyleSheet, LogBox } from 'react-native';
+import { Platform, UIManager, StyleSheet, LogBox } from 'react-native';
import Orientation from 'react-native-orientation-locker';
import {
SafeAreaProvider,
@@ -16,6 +16,7 @@
} from 'react-native-safe-area-context';
import { Provider } from 'react-redux';
import { PersistGate as ReduxPersistGate } from 'redux-persist/integration/react';
+import { GestureHandlerRootView } from 'react-native-gesture-handler';
import { actionLogger } from 'lib/utils/action-logger';
@@ -245,7 +246,7 @@
);
}
return (
- <View style={styles.app}>
+ <GestureHandlerRootView style={styles.app}>
<StaffContextProvider>
<NavContext.Provider value={navContext}>
<RootContext.Provider value={rootContext}>
@@ -275,7 +276,7 @@
</RootContext.Provider>
</NavContext.Provider>
</StaffContextProvider>
- </View>
+ </GestureHandlerRootView>
);
}
diff --git a/yarn.lock b/yarn.lock
--- a/yarn.lock
+++ b/yarn.lock
@@ -18653,15 +18653,15 @@
base-64 "^0.1.0"
utf8 "^3.0.0"
-react-native-gesture-handler@^1.10.3:
- version "1.10.3"
- resolved "https://registry.yarnpkg.com/react-native-gesture-handler/-/react-native-gesture-handler-1.10.3.tgz#942bbf2963bbf49fa79593600ee9d7b5dab3cfc0"
- integrity sha512-cBGMi1IEsIVMgoox4RvMx7V2r6bNKw0uR1Mu1o7NbuHS6BRSVLq0dP34l2ecnPlC+jpWd3le6Yg1nrdCjby2Mw==
+react-native-gesture-handler@^2.8.0:
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/react-native-gesture-handler/-/react-native-gesture-handler-2.8.0.tgz#ef9857871c10663c95a51546225b6e00cd4740cf"
+ integrity sha512-poOSfz/w0IyD6Qwq7aaIRRfEaVTl1ecQFoyiIbpOpfNTjm2B1niY2FLrdVQIOtIOe+K9nH55Qal04nr4jGkHdQ==
dependencies:
"@egjs/hammerjs" "^2.0.17"
- fbjs "^3.0.0"
hoist-non-react-statics "^3.3.0"
invariant "^2.2.4"
+ lodash "^4.17.21"
prop-types "^15.7.2"
react-native-gradle-plugin@^0.70.3:
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 23, 6:30 AM (14 h, 33 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2566852
Default Alt Text
D5935.id19874.diff (5 KB)
Attached To
Mode
D5935: [native] [34/40] RN 0.70: Update to react-native-gesture-handler@2.8.0
Attached
Detach File
Event Timeline
Log In to Comment