Skip to content

Commit

Permalink
chore: minor simplifications (#467)
Browse files Browse the repository at this point in the history
  • Loading branch information
vonovak committed May 31, 2021
1 parent 8932fe5 commit 7cfe70d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 11 deletions.
3 changes: 1 addition & 2 deletions src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ import { Dimensions, Platform } from 'react-native';
const { height: WINDOW_HEIGHT, width: WINDOW_WIDTH } = Dimensions.get('window');

enum GESTURE {
UNDETERMINED = 0,
CONTENT,
CONTENT = 0,
HANDLE,
}

Expand Down
11 changes: 2 additions & 9 deletions src/hooks/useBottomSheetTimingConfigs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,10 @@ export const useBottomSheetTimingConfigs = (
) => {
return useMemo(() => {
const _configs: Animated.WithTimingConfig = {
easing: DEFAULT_ANIMATION_EASING,
duration: DEFAULT_ANIMATION_DURATION,
easing: configs.easing || DEFAULT_ANIMATION_EASING,
duration: configs.duration || DEFAULT_ANIMATION_DURATION,
};

if (configs.easing) {
_configs.easing = configs.easing;
}

if (configs.duration) {
_configs.duration = configs.duration;
}
return _configs;
}, [configs.duration, configs.easing]);
};

0 comments on commit 7cfe70d

Please sign in to comment.