diff options
author | Paul Frazee <pfrazee@gmail.com> | 2023-04-24 16:36:05 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-24 16:36:05 -0500 |
commit | da8af38dcc23ea33c686714be2ce5f0bf0e65798 (patch) | |
tree | 78156a3b5803ccda6883e9e694ca79ccfdc40473 /src/Navigation.tsx | |
parent | 9d8600c21387999f8621274c553d5385be0c92c7 (diff) | |
download | voidsky-da8af38dcc23ea33c686714be2ce5f0bf0e65798.tar.zst |
Android & visual fixes: color themes, repost icon, navigation, back handler, etc (#519)
* Switch android to use slide left/right animations on navigation * Bump the repost icon down by a pixel * Tune theme colors for contrast and darker bg on darkmode * Move back handler to a point in the init flow that leads to more consistent capture of events * Fix image share flow on android * Fix lint * Add todo about sharing not available * Drop the android slide animation because it's too slow * Fix 'flashes of white' in dark mode android
Diffstat (limited to 'src/Navigation.tsx')
-rw-r--r-- | src/Navigation.tsx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Navigation.tsx b/src/Navigation.tsx index 186432c8c..d5ffb1539 100644 --- a/src/Navigation.tsx +++ b/src/Navigation.tsx @@ -6,6 +6,8 @@ import { createNavigationContainerRef, CommonActions, StackActions, + DefaultTheme, + DarkTheme, } from '@react-navigation/native' import {createNativeStackNavigator} from '@react-navigation/native-stack' import {createBottomTabNavigator} from '@react-navigation/bottom-tabs' @@ -256,8 +258,9 @@ const LINKING = { } function RoutesContainer({children}: React.PropsWithChildren<{}>) { + const theme = useColorSchemeStyle(DefaultTheme, DarkTheme) return ( - <NavigationContainer ref={navigationRef} linking={LINKING}> + <NavigationContainer ref={navigationRef} linking={LINKING} theme={theme}> {children} </NavigationContainer> ) @@ -334,7 +337,7 @@ const styles = StyleSheet.create({ backgroundColor: colors.black, }, bgLight: { - backgroundColor: colors.gray1, + backgroundColor: colors.white, }, }) |