removed navigation header border

main
alex 2023-08-13 17:32:53 +00:00
parent f33b7f7c97
commit a9869cd2eb
1 changed files with 8 additions and 9 deletions

17
App.js
View File

@ -114,17 +114,14 @@ export function MyApp() {
colors: { colors: {
...DefaultTheme.colors, ...DefaultTheme.colors,
background: appContext.appTheme.backgroundColor, background: appContext.appTheme.backgroundColor,
border: "transparent",
}, },
}; };
return ( return (
<SafeAreaView style={{ flex: 1 }}> <SafeAreaView style={{ flex: 1 }}>
<NavigationContainer theme={navigatonTheme}> <NavigationContainer theme={navigatonTheme}>
<Stack.Navigator <Stack.Navigator screenOptions={{ headerTitleAlign: "center" }}>
screenOptions={{
headerTitleAlign: "center",
}}
>
<Stack.Screen <Stack.Screen
name="drawer" name="drawer"
component={MyDrawer} component={MyDrawer}
@ -337,6 +334,7 @@ export function MyApp() {
); );
} }
// This is for the left sidebar navigation
function MyDrawer() { function MyDrawer() {
const appContext = useContext(AppContext); const appContext = useContext(AppContext);
@ -344,10 +342,10 @@ function MyDrawer() {
<Drawer.Navigator <Drawer.Navigator
screenOptions={{ screenOptions={{
headerShown: false, headerShown: false,
headerStyle: { //headerStyle: {
backgroundColor: appContext.appTheme.backgroundColor, // backgroundColor: appContext.appTheme.backgroundColor,
}, //},
headerTintColor: appContext.appTheme.text, //headerTintColor: appContext.appTheme.text,
drawerStyle: { drawerStyle: {
backgroundColor: appContext.appTheme.drawer.backgroundColor, backgroundColor: appContext.appTheme.drawer.backgroundColor,
}, },
@ -448,6 +446,7 @@ function getScreenStackOptions(
</TouchableOpacity> </TouchableOpacity>
), ),
headerTintColor: headerTintColor, headerTintColor: headerTintColor,
headerTitleAlign: "center",
headerStyle: { headerStyle: {
backgroundColor: headerBackgroundColor, backgroundColor: headerBackgroundColor,
height: IsPlatformIos() ? 76 : 56, height: IsPlatformIos() ? 76 : 56,