From 5522e20104da6afe2e4667cf45dbbbbc0e838865 Mon Sep 17 00:00:00 2001
From: Mohamed Bassem <me@mbassem.com>
Date: Sat, 23 Nov 2024 20:59:34 +0000
Subject: ui(mobile): Replace bottom sheet with native screens (#690)

* Remove bottom sheet from bookmark info page

* Remove bottom sheet from manage lists page

* Remove bottom sheet from new list page

* Remove bottom sheet from new bookmark page

* Drop bottom-sheets

* Improve the look of the modals

* Make the search page fade from bottom
---
 apps/mobile/app/_layout.tsx | 74 ++++++++++++++++++++++-----------------------
 1 file changed, 37 insertions(+), 37 deletions(-)

(limited to 'apps/mobile/app/_layout.tsx')

diff --git a/apps/mobile/app/_layout.tsx b/apps/mobile/app/_layout.tsx
index 5eadad80..62c29c27 100644
--- a/apps/mobile/app/_layout.tsx
+++ b/apps/mobile/app/_layout.tsx
@@ -12,7 +12,6 @@ import { StyledStack } from "@/components/navigation/stack";
 import { Providers } from "@/lib/providers";
 import useAppSettings from "@/lib/settings";
 import { cn } from "@/lib/utils";
-import { BottomSheetModalProvider } from "@gorhom/bottom-sheet";
 import { useColorScheme } from "nativewind";
 
 export default function RootLayout() {
@@ -37,44 +36,45 @@ export default function RootLayout() {
     <ShareIntentProvider>
       <Providers>
         <GestureHandlerRootView style={{ flex: 1 }}>
-          <BottomSheetModalProvider>
-            <View
-              className={cn(
-                "w-full flex-1 bg-gray-100 text-foreground dark:bg-background",
-                colorScheme == "dark" ? "dark" : "light",
-              )}
+          <View
+            className={cn(
+              "w-full flex-1 bg-gray-100 text-foreground dark:bg-background",
+              colorScheme == "dark" ? "dark" : "light",
+            )}
+          >
+            <StyledStack
+              contentClassName="bg-gray-100 dark:bg-background"
+              screenOptions={{
+                headerShown: false,
+                headerTransparent: true,
+              }}
             >
-              <StyledStack
-                contentClassName="bg-gray-100 dark:bg-background"
-                screenOptions={{
-                  headerShown: false,
-                  headerTransparent: true,
+              <Stack.Screen name="index" />
+              <Stack.Screen
+                name="signin"
+                options={{
+                  headerShown: true,
+                  headerBackVisible: true,
+                  headerBackTitle: "Back",
+                  title: "",
                 }}
-              >
-                <Stack.Screen name="index" />
-                <Stack.Screen
-                  name="signin"
-                  options={{
-                    headerShown: true,
-                    headerBackVisible: true,
-                    headerBackTitle: "Back",
-                    title: "",
-                  }}
-                />
-                <Stack.Screen name="server-address" />
-                <Stack.Screen name="sharing" />
-                <Stack.Screen
-                  name="test-connection"
-                  options={{
-                    title: "Test Connection",
-                    headerShown: true,
-                    presentation: "modal",
-                  }}
-                />
-              </StyledStack>
-              <StatusBar style="auto" />
-            </View>
-          </BottomSheetModalProvider>
+              />
+              <Stack.Screen name="server-address" />
+              <Stack.Screen
+                name="sharing"
+                options={{ presentation: "modal" }}
+              />
+              <Stack.Screen
+                name="test-connection"
+                options={{
+                  title: "Test Connection",
+                  headerShown: true,
+                  presentation: "modal",
+                }}
+              />
+            </StyledStack>
+            <StatusBar style="auto" />
+          </View>
         </GestureHandlerRootView>
       </Providers>
     </ShareIntentProvider>
-- 
cgit v1.2.3-70-g09d2

