aboutsummaryrefslogtreecommitdiffstats
path: root/apps/mobile/app/_layout.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'apps/mobile/app/_layout.tsx')
-rw-r--r--apps/mobile/app/_layout.tsx79
1 files changed, 42 insertions, 37 deletions
diff --git a/apps/mobile/app/_layout.tsx b/apps/mobile/app/_layout.tsx
index e1751f1e..ca3da0cb 100644
--- a/apps/mobile/app/_layout.tsx
+++ b/apps/mobile/app/_layout.tsx
@@ -32,42 +32,47 @@ export default function RootLayout() {
}, [settings.theme]);
return (
- <GestureHandlerRootView style={{ flex: 1 }}>
- <ShareIntentProvider>
- <Providers>
- <StyledStack
- contentClassName={cn(
- "w-full flex-1 bg-gray-100 text-foreground dark:bg-background",
- colorScheme == "dark" ? "dark" : "light",
- )}
- screenOptions={{
- headerTitle: "",
- headerTransparent: true,
- }}
- >
- <Stack.Screen name="index" />
- <Stack.Screen
- name="signin"
- options={{
- headerShown: true,
- headerBackVisible: true,
- headerBackTitle: "Back",
- title: "",
- }}
- />
- <Stack.Screen name="sharing" />
- <Stack.Screen
- name="test-connection"
- options={{
- title: "Test Connection",
- headerShown: true,
- presentation: "modal",
- }}
- />
- </StyledStack>
- <StatusBar style="auto" />
- </Providers>
- </ShareIntentProvider>
- </GestureHandlerRootView>
+ <>
+ <StyledStack
+ layout={(props) => {
+ return (
+ <GestureHandlerRootView style={{ flex: 1 }}>
+ <ShareIntentProvider>
+ <Providers>{props.children}</Providers>
+ </ShareIntentProvider>
+ </GestureHandlerRootView>
+ );
+ }}
+ contentClassName={cn(
+ "w-full flex-1 bg-gray-100 text-foreground dark:bg-background",
+ colorScheme == "dark" ? "dark" : "light",
+ )}
+ screenOptions={{
+ headerTitle: "",
+ headerTransparent: true,
+ }}
+ >
+ <Stack.Screen name="index" />
+ <Stack.Screen
+ name="signin"
+ options={{
+ headerShown: true,
+ headerBackVisible: true,
+ headerBackTitle: "Back",
+ title: "",
+ }}
+ />
+ <Stack.Screen name="sharing" />
+ <Stack.Screen
+ name="test-connection"
+ options={{
+ title: "Test Connection",
+ headerShown: true,
+ presentation: "modal",
+ }}
+ />
+ </StyledStack>
+ <StatusBar style="auto" />
+ </>
);
}