chore: sync latest stack

This commit is contained in:
Satyajit Sahoo
2020-03-20 11:40:21 +01:00
parent 915861e601
commit 72bbebc80e
3 changed files with 12 additions and 13 deletions

View File

@@ -45,7 +45,7 @@
"devDependencies": {
"@react-native-community/bob": "^0.10.0",
"@react-native-community/masked-view": "^0.1.7",
"@react-navigation/stack": "^5.2.2",
"@react-navigation/stack": "^5.2.3",
"@types/color": "^3.0.1",
"@types/react": "^16.9.23",
"@types/react-native": "^0.61.22",

View File

@@ -271,16 +271,15 @@ export default class Card extends React.Component<Props> {
velocity = nativeEvent.velocityX;
}
if (
gestureDirection === 'horizontal-inverted' ||
gestureDirection === 'vertical-inverted'
) {
translation *= -1;
velocity *= -1;
}
const gestureDirectionFactor =
gestureDirection === 'horizontal' || gestureDirection === 'vertical'
? 1
: -1;
const closing =
translation + velocity * gestureVelocityImpact > distance / 2
gestureDirectionFactor *
(translation + velocity * gestureVelocityImpact) >
distance / 2
? velocity !== 0 || translation !== 0
: false;

View File

@@ -3268,10 +3268,10 @@
resolved "https://registry.yarnpkg.com/@react-native-community/masked-view/-/masked-view-0.1.7.tgz#a65ce0702f55cb67fd777995de6fc7b3e5781903"
integrity sha512-9KbP7LTLFz9dx1heURJbO6nuVMdSjDez8znlrUzaB1nUwKVsTTwlKRuHxGUYIIkReLWrJQeCv9tidy+84z2eCw==
"@react-navigation/stack@^5.2.2":
version "5.2.2"
resolved "https://registry.yarnpkg.com/@react-navigation/stack/-/stack-5.2.2.tgz#2ad170250c9e4eb9715d3fa05d780f47d9c2644d"
integrity sha512-9xBIIDuGFtPTKfESQ0xPxCRACngcLSMJYWql583v8HRZidT4fdOlIKbmhNZ+iPhwvRbjDm/mxMat7R9CBakoDg==
"@react-navigation/stack@^5.2.3":
version "5.2.3"
resolved "https://registry.yarnpkg.com/@react-navigation/stack/-/stack-5.2.3.tgz#2c92ee6f0a032720960acfa037e13061c378781e"
integrity sha512-mCji6N6r03sTMF09hbVmhdCZHcuIrZCr/MY8yuiG+kzzYcFfj+72wwJ885erKw32jBKAaJV8wZNq8W0K+ZiCQQ==
dependencies:
color "^3.1.2"
react-native-iphone-x-helper "^1.2.1"