-
Notifications
You must be signed in to change notification settings - Fork 0
/
App.js
122 lines (108 loc) · 3.01 KB
/
App.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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
import React, { useState } from 'react';
import { Text, View, Image, TouchableOpacity, StyleSheet } from 'react-native';
import FloatingLabel from 'aj-floating-label-input';
export default function LoginScreen(props) {
const [Username, setUsername] = useState('');
const [Password, setPassword] = useState('');
return (
<View style={LoginStyles.MainView} >
<Image
style={LoginStyles.LogoImage}
source={require('./logo1.png')} />
<View style={LoginStyles.TextInputMainView}>
<View style={LoginStyles.TextInputView}>
<FloatingLabel
onChangeText={value => setUsername(value)}
focusBorderColor={ThemeColors.ThemeColorPrimary}
focusLabelColor={ThemeColors.ThemeColorPrimary}
blurBorderColor="#AAA"
blurLabelColor="#AAA"
floatingLabel="Username"
inputStyle={{}}
labelStyle={{}}
floatedStyle={{ fontSize: 10, top: 3, }}
unfloatedStyle={{ fontSize: 11, top: 12, }}
containerStyle={{ borderRadius: 50, borderWidth: 0.5 }}
/>
</View>
<View style={{ ...LoginStyles.TextInputView, marginTop: 10 }}>
<FloatingLabel
onChangeText={value => setPassword(value)}
focusBorderColor={ThemeColors.ThemeColorPrimary}
focusLabelColor={ThemeColors.ThemeColorPrimary}
blurBorderColor="#AAA"
blurLabelColor="#AAA"
floatingLabel="Password"
secureTextEntry={true}
inputStyle={{}}
labelStyle={{}}
floatedStyle={{ fontSize: 10, top: 3, }}
unfloatedStyle={{ fontSize: 11, top: 12, }}
containerStyle={{ borderRadius: 50, borderWidth: 0.5 }}
/>
</View>
</View>
<TouchableOpacity>
<Text style={LoginStyles.FogetPassword}>Forgot Password?</Text>
</TouchableOpacity>
<TouchableOpacity
style={LoginStyles.LoginBtn}>
<Text style={LoginStyles.LoginBtnLabel}>Login</Text>
</TouchableOpacity>
</View >
);
}
const ThemeColors = {
ThemeColorPrimary: '#fc4503',
}
const LoginStyles = StyleSheet.create(
{
MainView:
{
flex: 1,
justifyContent: "center",
backgroundColor: "#ffffff"
},
LogoImage:
{
alignSelf: "center",
width: 160,
height: 160,
marginTop: -50,
},
TextInputMainView:
{
marginTop: 50,
},
TextInputView: {
marginLeft: 40,
marginRight: 40
},
FogetPassword:
{
fontSize: 12,
fontWeight: "100",
color: "grey",
alignSelf: "flex-end",
marginEnd: 50,
marginTop: 20,
},
LoginBtn:
{
borderRadius: 40,
marginLeft: 40,
marginRight: 40,
marginTop: 50,
backgroundColor: "#fc4503",
justifyContent: "center",
alignItems: "center",
paddingTop: 15,
paddingBottom: 15,
},
LoginBtnLabel:
{
color: "#ffffff",
fontSize: 12,
}
}
)