From a2163a4c9d4ff45356230dc578e28bb15fb17e3f Mon Sep 17 00:00:00 2001 From: Jack Hansen <47556286+jackavh@users.noreply.github.com> Date: Wed, 15 May 2024 13:58:42 -0700 Subject: [PATCH] move all firebase providers to /admin/layout.tsx --- frontend/src/app/admin/layout.tsx | 6 +++--- frontend/src/app/layout.tsx | 6 +----- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/frontend/src/app/admin/layout.tsx b/frontend/src/app/admin/layout.tsx index 5dbf05bb..03640c02 100644 --- a/frontend/src/app/admin/layout.tsx +++ b/frontend/src/app/admin/layout.tsx @@ -2,7 +2,7 @@ import { usePathname } from "next/navigation"; -import { MyFirebaseProvider } from "./firebase/reactfireProvider"; +import { FirebaseProvider } from "./firebase/firebaseProvider"; import HeaderBarSpace from "@/components/HeaderBarSpace"; import NavigationBar from "@/components/NavigationBar"; @@ -14,12 +14,12 @@ export default function AdminLayout({ children }: { children: React.ReactNode }) const isLoginPage = pathname === "/admin"; return ( - +
{!isLoginPage && } {!isLoginPage && } {children}
-
+ ); } diff --git a/frontend/src/app/layout.tsx b/frontend/src/app/layout.tsx index f53a0b37..6d3e80ff 100644 --- a/frontend/src/app/layout.tsx +++ b/frontend/src/app/layout.tsx @@ -1,7 +1,5 @@ import { Inter, Open_Sans, Roboto_Slab } from "next/font/google"; -import { FirebaseProvider } from "./admin/firebase/firebaseProvider"; - import type { Metadata } from "next"; export const metadata: Metadata = { @@ -28,9 +26,7 @@ const robotoSlab = Roboto_Slab({ export default function RootLayout({ children }: { children: React.ReactNode }) { return ( - - {children} - + {children} ); }