-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #39 from BOBpossible/feat/#37_Onboarding
Feat/#37 onboarding
- Loading branch information
Showing
39 changed files
with
633 additions
and
4 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains 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
This file contains 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
import React from 'react'; | ||
import type {FC} from 'react'; | ||
import {StyleSheet, Text, TouchableOpacity, View} from 'react-native'; | ||
import Icon from 'react-native-vector-icons/MaterialCommunityIcons'; | ||
import {DesignSystem} from '../assets/DesignSystem'; | ||
import {useNavigation} from '@react-navigation/native'; | ||
|
||
export type OnBoardingHeaderProps = { | ||
goBack?: () => void; | ||
}; | ||
|
||
export const OnBoardingHeader: FC<OnBoardingHeaderProps> = ({goBack}) => { | ||
const navigation = useNavigation(); | ||
return ( | ||
<View style={[styles.headerWrap]}> | ||
{goBack !== undefined ? ( | ||
<TouchableOpacity onPress={goBack}> | ||
<View style={[styles.backButton]}> | ||
<Icon name="arrow-left" size={24} color="black" /> | ||
</View> | ||
</TouchableOpacity> | ||
) : ( | ||
<View /> | ||
)} | ||
<TouchableOpacity onPress={() => navigation.reset({routes: [{name: 'MainNavigator'}]})}> | ||
<Text style={[DesignSystem.body2Lt, {color: '#949494'}]}>건너뛰기</Text> | ||
</TouchableOpacity> | ||
</View> | ||
); | ||
}; | ||
|
||
const styles = StyleSheet.create({ | ||
headerWrap: { | ||
flexDirection: 'row', | ||
justifyContent: 'space-between', | ||
alignItems: 'center', | ||
marginLeft: 16, | ||
marginRight: 16, | ||
height: 50, | ||
}, | ||
backButton: { | ||
zIndex: 1, | ||
// width: 16, | ||
// height: 15.56, | ||
justifyContent: 'center', | ||
alignItems: 'center', | ||
}, | ||
disable: {opacity: 0}, | ||
progressText: { | ||
color: '#949494', | ||
fontSize: 16, | ||
}, | ||
}); |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import React from 'react'; | ||
import type {FC} from 'react'; | ||
import {StyleSheet, Text, TouchableOpacity, View} from 'react-native'; | ||
|
||
export type OnBoardingNextButtonProps = { | ||
goNext: () => void; | ||
text: string; | ||
}; | ||
|
||
export const OnBoardingNextButton: FC<OnBoardingNextButtonProps> = ({goNext, text}) => { | ||
return ( | ||
<TouchableOpacity onPress={goNext} style={[styles.buttonWrap]}> | ||
<View | ||
style={[styles.buttonStyle, text === '다음' ? styles.blackButton : styles.purpleButton]} | ||
> | ||
<Text | ||
style={{fontFamily: 'Pretendard-Medium', color: 'white', fontSize: 18, lineHeight: 24}} | ||
> | ||
{text} | ||
</Text> | ||
</View> | ||
</TouchableOpacity> | ||
); | ||
}; | ||
|
||
const styles = StyleSheet.create({ | ||
buttonWrap: {justifyContent: 'center', alignItems: 'center', margin: 20}, | ||
buttonStyle: { | ||
width: '100%', | ||
height: 56, | ||
justifyContent: 'center', | ||
alignItems: 'center', | ||
borderRadius: 10, | ||
}, | ||
blackButton: { | ||
backgroundColor: '#2A2A2A', | ||
}, | ||
stateNextButton: {backgroundColor: '#2A2A2A'}, | ||
purpleButton: {backgroundColor: '#6C69FF'}, | ||
}); |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
import {NativeStackScreenProps} from '@react-navigation/native-stack'; | ||
import React, {useEffect, useState} from 'react'; | ||
import {View, StyleSheet, Text, Image} from 'react-native'; | ||
import {SafeAreaView} from 'react-native-safe-area-context'; | ||
import {RegisterHeader, RegisterNextButton} from '../../components'; | ||
import {OnBoardingHeader} from '../../components/OnBoardingHeader'; | ||
import {OnBoardingNextButton} from '../../components/OnBoardingNextButton'; | ||
import Icon from 'react-native-vector-icons/MaterialCommunityIcons'; | ||
import {DesignSystem} from '../../assets/DesignSystem'; | ||
|
||
const HowTo1 = ({navigation, route}: Props) => { | ||
const [loading, setLoading] = useState(false); | ||
const goNext = () => { | ||
navigation.navigate('HowTo2'); | ||
}; | ||
useEffect(() => { | ||
const id = setTimeout(() => { | ||
setLoading(true); | ||
}, 1000); | ||
return () => { | ||
clearTimeout(id); | ||
}; | ||
}, []); | ||
return ( | ||
<SafeAreaView style={[styles.flex]}> | ||
<OnBoardingHeader goBack={() => console.log('back')} /> | ||
<View style={[styles.flex, DesignSystem.centerArrange]}> | ||
<Image source={require('../../assets/images/onBoarding/obText1.png')} /> | ||
<Image source={require('../../assets/images/onBoarding/obBob1.png')} /> | ||
</View> | ||
{loading ? ( | ||
<OnBoardingNextButton goNext={goNext} text={'다음'} /> | ||
) : ( | ||
<View style={{height: 56, margin: 20}} /> | ||
)} | ||
</SafeAreaView> | ||
); | ||
}; | ||
|
||
const styles = StyleSheet.create({ | ||
flex: {flex: 1, backgroundColor: '#FFFFFF'}, | ||
|
||
}); | ||
|
||
export default HowTo1; |
Oops, something went wrong.