Last active
July 25, 2022 13:52
-
-
Save jai-adapptor/56eba4756b4728f6cac640661675ebf5 to your computer and use it in GitHub Desktop.
6: Markup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| return ( | |
| <View style={styles.container}> | |
| <PanGestureHandler onGestureEvent={onGestureEvent}> | |
| <Animated.View style={[sheetHeightAnimatedStyle, styles.sheet]}> | |
| <View style={styles.handleContainer}> | |
| <View style={styles.handle} /> | |
| </View> | |
| <Animated.View style={sheetContentAnimatedStyle}> | |
| <Animated.View style={sheetNavigationAnimatedStyle}> | |
| <TouchableOpacity | |
| style={styles.closeButton} | |
| onPress={() => { | |
| navHeight.value = withSpring(0, springConfig); | |
| sheetHeight.value = withSpring(-expandedHeight, springConfig); | |
| position.value = 'expanded'; | |
| }} | |
| > | |
| <Text>{`❌`}</Text> | |
| </TouchableOpacity> | |
| </Animated.View> | |
| <SafeAreaView> | |
| <ScrollView>{props.children}</ScrollView> | |
| </SafeAreaView> | |
| </Animated.View> | |
| </Animated.View> | |
| </PanGestureHandler> | |
| </View> | |
| ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment