Skip to content

Commit

Permalink
fixed names
Browse files Browse the repository at this point in the history
  • Loading branch information
carolynzhuang committed Nov 6, 2024
1 parent a0d14eb commit 22ecaa9
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 9 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,5 @@ yarn-error.*

# typescript
*.tsbuildinfo

ios/
4 changes: 2 additions & 2 deletions App.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { NavigationContainer } from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';
import { LoginStackParamList } from '@/navigation/types';
import AdminLoginScreen from '@/screens/AdminLoginScreen';
import LoginScreen from '@/screens/LoginScreen';
import MemberLoginScreen from '@/screens/MemberLoginScreen';

const Stack = createNativeStackNavigator<LoginStackParamList>();

Expand All @@ -11,7 +11,7 @@ export default function App() {
<NavigationContainer>
<Stack.Navigator initialRouteName="Login">
<Stack.Screen name="Login" component={LoginScreen} />
<Stack.Screen name="MemberLogin" component={MemberLoginScreen} />
<Stack.Screen name="AdminLogin" component={AdminLoginScreen} />
</Stack.Navigator>
</NavigationContainer>
);
Expand Down
4 changes: 2 additions & 2 deletions src/components/Login.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ export default function Login({ navigation, route }: LoginProps) {

<TouchableOpacity
style={styles.button}
onPress={() => navigation.navigate('MemberLogin')}
onPress={() => navigation.navigate('AdminLogin')}
>
<Text style={styles.buttonText}>Staff or Member</Text>
<Text style={styles.buttonText}>Admin</Text>
</TouchableOpacity>
</View>
</View>
Expand Down
2 changes: 1 addition & 1 deletion src/navigation/types.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export type LoginStackParamList = {
Login: undefined;
GuestLogin: undefined;
MemberLogin: undefined;
AdminLogin: undefined;
};
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import { Text, TouchableOpacity, View } from 'react-native';
import Svg, { Circle } from 'react-native-svg';
import { styles } from '@/screens/styles';

export default function MemberLoginScreen() {
export default function AdminLoginScreen() {
return (
<View style={styles.memberLoginContainer}>
<Text style={styles.loginHeadingText}>Staff and Member Login</Text>
<View style={styles.adminLoginContainer}>
<Text style={styles.loginHeadingText}>Admin Login</Text>
<View style={styles.googleLoginProfileContainer}>
<Svg height="220" width="220">
<Circle cx="110" cy="110" r="110" fill="#D9D9D9" />
Expand Down
2 changes: 1 addition & 1 deletion src/screens/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export const styles = StyleSheet.create({
fontSize: 16,
},

memberLoginContainer: {
adminLoginContainer: {
flex: 1,
flexDirection: 'column',
justifyContent: 'flex-start',
Expand Down

0 comments on commit 22ecaa9

Please sign in to comment.