adding organization feature.

This commit is contained in:
killian-larcher
2024-12-12 13:31:11 +01:00
parent 5bd24574c3
commit afb936bc5b
29 changed files with 363 additions and 93 deletions
+16 -11
View File
@@ -6,6 +6,7 @@ import {AppSidebar} from "@/components/wrappers/Dashboard/SideBar/app-sidebar";
import {currentUser} from "@/auth/current-user";
import {Header} from "@/features/layout/Header";
import {prisma} from "@/prisma";
import {GlobalStoreProvider} from "@/state-management/provider";
export default async function Layout({children}: { children: React.ReactNode }) {
@@ -22,16 +23,20 @@ export default async function Layout({children}: { children: React.ReactNode })
if (!user) redirect('/login')
return (
<SidebarProvider>
<div className="flex flex-col lg:flex-row w-full">
<AppSidebar/>
<SidebarInset>
<Header/>
<main className="h-full">
{children}
</main>
</SidebarInset>
</div>
</SidebarProvider>
// <HydrationZustand>
<GlobalStoreProvider>
<SidebarProvider>
<div className="flex flex-col lg:flex-row w-full">
<AppSidebar/>
<SidebarInset>
<Header/>
<main className="h-full">
{children}
</main>
</SidebarInset>
</div>
</SidebarProvider>
</GlobalStoreProvider>
// </HydrationZustand>
)
}