Files
dockship/src/components/dashboard/DashboardLayout.tsx
T
2025-12-26 21:22:17 +01:00

27 lines
679 B
TypeScript

import { ReactNode } from "react";
import { DashboardSidebar } from "./DashboardSidebar";
import { DashboardHeader } from "./DashboardHeader";
import { SidebarProvider } from "../ui/sidebar";
interface DashboardLayoutProps {
children: ReactNode;
title: string;
subtitle?: string;
}
export function DashboardLayout({
children,
title,
subtitle,
}: DashboardLayoutProps) {
return (
<SidebarProvider>
<DashboardSidebar />
<div className="flex-1 flex flex-col overflow-hidden">
<DashboardHeader title={title} subtitle={subtitle} />
<main className="flex-1 overflow-auto p-6">{children}</main>
</div>
</SidebarProvider>
);
}