diff --git a/pkgs/ui/src/app/layout.tsx b/pkgs/ui/src/app/layout.tsx index 4fffb2b2a..4cef02cb6 100644 --- a/pkgs/ui/src/app/layout.tsx +++ b/pkgs/ui/src/app/layout.tsx @@ -17,8 +17,7 @@ import { Toaster } from "react-hot-toast"; import "./globals.css"; import { darkTheme, lightTheme } from "./theme/themes"; -import Background from "@/components/background"; -import { AppContext, WithAppState } from "@/components/hooks/useAppContext"; +import { WithAppState } from "@/components/hooks/useAppContext"; const roboto = localFont({ src: [ @@ -58,61 +57,47 @@ export default function RootLayout({ - - {(appState) => { - const showSidebarDerived = Boolean( - showSidebar && !appState.isLoading && appState.data.isJoined - ); - return ( - <> - - - - setShowSidebar(false)} - /> - - + + setShowSidebar(false)} + /> + + + + + + setShowSidebar((c) => !c)} > - - - - setShowSidebar((c) => !c)} - > - {!showSidebar && appState.data.isJoined && ( - - )} - - - - - - - - - - - {children} - - - + {!showSidebar && } + - > - ); - }} - + + + + + + + + + {children} + + + +