forked from pasta-express/safe-haven
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Welcome.js
92 lines (78 loc) · 2.21 KB
/
Welcome.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
import { NavigationContainer } from "@react-navigation/native";
import React, { Component } from "react";
import { TouchableWithoutFeedback, Keyboard } from "react-native";
import { View, Text, TextInput, StyleSheet, Image, TouchableOpacity } from "react-native";
const Welcome = ({navigation, route}) => {
return(
<View style={styles.container}>
<Text style={styles.welcomeText}>Welcome to Safe Haven</Text>
<Image style={styles.logo} source={require('./assets/crafts.png')}/>
<TouchableOpacity
onPress={() => {
console.log("pressed")
navigation.navigate("Signup")
}}
style={styles.signUpButton}
>
<Text style={styles.signUpText}>Sign Up</Text>
</TouchableOpacity>
<Text style={styles.loginText}>Already have an account?</Text>
<TouchableOpacity
style={styles.loginButton}
onPress={
() => navigation.navigate("Login")
}>
<Text style={styles.underlinedText}>Login here</Text>
</TouchableOpacity>
</View>
);
}
const styles = StyleSheet.create({
container: {
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
flexDirection: 'column',
backgroundColor: '#D1EBB1',
width: '100%',
height: '100%'
},
welcomeText: {
fontSize: 25,
margin: 20,
marginBottom: 70
},
logo: {
height: 230,
width: 230,
marginBottom: 50
},
signUpButton: {
width: '50%',
height: 40,
borderRadius: 20,
backgroundColor: '#C4C4E8',
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
padding: 10,
margin: 20,
textAlign: 'center'
},
signUpText: {
fontSize: 16,
fontWeight: 'bold',
color: '#59599D'
},
loginText: {
marginTop: 20,
fontSize: 15
},
loginButton: {
},
underlinedText: {
fontSize: 15,
textDecorationLine: 'underline'
}
});
export default Welcome;