mirror of
https://github.com/vercel/commerce.git
synced 2025-07-22 20:26:49 +00:00
add preloading to account's pages
This commit is contained in:
@@ -36,15 +36,17 @@ export const metadata = {
|
||||
export default async function RootLayout({ children }: { children: ReactNode }) {
|
||||
return (
|
||||
<html lang="en" className={GeistSans.variable}>
|
||||
<body className="bg-white text-black selection:bg-teal-300 dark:bg-neutral-900 dark:text-white dark:selection:bg-pink-500 dark:selection:text-white">
|
||||
<body className="min-h-screen bg-white text-black selection:bg-primary-muted dark:bg-neutral-900 dark:text-white dark:selection:bg-primary-emphasis dark:selection:text-white">
|
||||
<AuthProvider>
|
||||
<div>
|
||||
{/* We need to have this wrapper div because the headless ui popover clickaway event is not working properly */}
|
||||
{/* https://github.com/tailwindlabs/headlessui/issues/2752#issuecomment-1724096430 */}
|
||||
<div className="flex h-screen flex-col">
|
||||
<header>
|
||||
<Banner />
|
||||
<Navbar />
|
||||
</header>
|
||||
<Suspense>
|
||||
<main>{children}</main>
|
||||
<main className="main group flex-1">{children}</main>
|
||||
</Suspense>
|
||||
</div>
|
||||
</AuthProvider>
|
||||
|
Reference in New Issue
Block a user