Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bottom tab bar #224

Closed
wants to merge 25 commits into from
Closed
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
d0867bf
Add this to workflows to test new pull request
Phantom0110 Mar 6, 2024
a5793b1
Testing new workflows with firebase-secret.json file.
Phantom0110 Mar 7, 2024
911032b
Updated workflows to make the check detect firebase-secret.json
Phantom0110 Mar 7, 2024
d6baa25
Testing checks with .env files
Phantom0110 Mar 7, 2024
4061db6
Testing checks with .env files
Phantom0110 Mar 7, 2024
d7f2bb3
Testing checks with .env files
Phantom0110 Mar 7, 2024
a2764d6
Testing checks with .env files
Phantom0110 Mar 7, 2024
7e6adee
Merge branch 'main' into main
Phantom0110 Mar 7, 2024
0f8628c
Testing checks with .env files
Phantom0110 Mar 7, 2024
6d5ef5b
Merge branch 'main' of https://github.com/Phantom0110/OSC-Proximity-C…
Phantom0110 Mar 7, 2024
47a23ab
Testing check for .env files
Phantom0110 Mar 7, 2024
1e3fcf2
deleted firebase-secret.json
Phantom0110 Mar 7, 2024
3862017
testing alternative for checking firebase-secret.json
Phantom0110 Mar 7, 2024
201c5ce
testing .env files
Phantom0110 Mar 7, 2024
13fe97b
Testing for firebase-secret.json
Phantom0110 Mar 7, 2024
d7f3e8f
Merge branch 'main' of https://github.com/Phantom0110/OSC-Proximity-C…
Phantom0110 Apr 11, 2024
13437d4
Merge branch 'main' of https://github.com/Phantom0110/OSC-Proximity-C…
Phantom0110 Apr 15, 2024
1c25681
recovered
Phantom0110 Apr 18, 2024
c39c210
deleting some silly directory issues
Phantom0110 Apr 18, 2024
a4d62ad
Merge branch 'ufosc:main' into main
Phantom0110 Apr 18, 2024
fe71591
Delete server/firebase-secret.json
AlexanderWangY Jun 5, 2024
03a445d
Merge branch 'main' of https://github.com/Phantom0110/OSC-Proximity-C…
Phantom0110 Jun 13, 2024
ebf283f
merge with main
Phantom0110 Jun 13, 2024
cb9fdcb
merge with main
Phantom0110 Jun 13, 2024
760e6ff
Merge branch 'bottom-tab' of https://github.com/Phantom0110/OSC-Proxi…
Phantom0110 Jun 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
105 changes: 94 additions & 11 deletions client/src/navigation/AppNavigator.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,21 @@
import { createBottomTabNavigator } from "@react-navigation/bottom-tabs";
import * as React from "react";

import { LocationProvider } from "../contexts/LocationContext";
import { SocketProvider } from "../contexts/SocketContext";
import { UserProvider } from "../contexts/UserContext";
import * as React from 'react';

Check warning on line 2 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

Replace `'react'` with `"react"`
import {

Check warning on line 3 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

There should be at least one empty line between import groups

Check warning on line 3 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

Delete `·`
SafeAreaView,

Check warning on line 4 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

'SafeAreaView' is defined but never used
ScrollView,

Check warning on line 5 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

'ScrollView' is defined but never used
StatusBar,

Check warning on line 6 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

'StatusBar' is defined but never used
StyleSheet,

Check warning on line 7 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

'StyleSheet' is defined but never used
Text,
useColorScheme,

Check warning on line 9 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

'useColorScheme' is defined but never used
Image,

Check warning on line 10 in client/src/navigation/AppNavigator.tsx

View workflow job for this annotation

GitHub Actions / lint (21.x)

'Image' is defined but never used
View,
} from 'react-native';
import ChatScreen from "../screens/chat/ChatScreen";
import SettingsScreen from "../screens/settings/SettingsScreen";
import { SocketProvider } from "../contexts/SocketContext";
import { LocationProvider } from "../contexts/LocationContext";
import { UserProvider } from "../contexts/UserContext";
import { Map, Settings, MessageSquare } from "react-native-feather";

const Tab = createBottomTabNavigator();

Expand All @@ -14,12 +24,85 @@
<LocationProvider>
<SocketProvider>
<UserProvider>
<Tab.Navigator
screenOptions={{
headerShown: false,
}}>
<Tab.Screen name="Home" component={ChatScreen} />
<Tab.Screen name="Profile" component={SettingsScreen} />
<Tab.Navigator screenOptions={{
headerShown: false,
tabBarStyle: {
backgroundColor: '#EFEFEF',
borderTopLeftRadius: 30,
borderTopRightRadius: 30,
},

}}>
<Tab.Screen
name="Map"
component={ChatScreen}
options={{
tabBarShowLabel: false,
tabBarActiveTintColor: '#34D1BF',
tabBarIcon: ({focused}) => (
<View style={{alignItems: 'center', justifyContent: 'center', top: 3, left: 5}}>
<Map
color={'black'}
style={{
width: 22,
height: 22,
}}
/>
<Text
style={{color: focused ? '#34D1BF' : 'black', fontSize: 10, top: 2,}}>
Map
</Text>

</View>
)
}}
/>
<Tab.Screen
name="Chat"
component={ChatScreen}
options={{
tabBarShowLabel: false,
tabBarActiveTintColor: '#34D1BF',
tabBarIcon: ({focused}) => (
<View style={{alignItems: 'center', justifyContent: 'center', top: 3}}>
<MessageSquare
color={'black'}
style={{
width: 22,
height: 22,
}}
/>
<Text
style={{color: focused ? '#34D1BF' : 'black', fontSize: 10, top: 2}}>
Chat
</Text>

</View>
)
}} />
<Tab.Screen
name="Settings"
component={SettingsScreen}
options={{
tabBarShowLabel: false,
tabBarActiveTintColor: '#34D1BF',
tabBarIcon: ({focused}) => (
<View style={{alignItems: 'center', justifyContent: 'center', top: 3, right: 5}}>
<Settings
color={'black'}
style={{
width: 22,
height: 22,
}}
/>
<Text
style = {{color: focused ? '#34D1BF' : 'black', fontSize: 10, top: 2}}>
Settings
</Text>
</View>
)
}}
/>
</Tab.Navigator>
</UserProvider>
</SocketProvider>
Expand Down
Loading