updated lang change and FormDisplay Components
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
"use client";
|
||||
import React, { ReactNode } from "react";
|
||||
import Header from "@/components/header/Header";
|
||||
import ClientMenu from "@/components/menu/menu";
|
||||
|
||||
interface DashboardLayoutProps {
|
||||
children: ReactNode;
|
||||
lang: "en" | "tr";
|
||||
activePage: string;
|
||||
siteUrls: string[];
|
||||
}
|
||||
|
||||
/**
|
||||
* A reusable dashboard layout component that provides consistent structure
|
||||
* for all dashboard pages with sidebar, header, and content area.
|
||||
*/
|
||||
export const DashboardLayout: React.FC<DashboardLayoutProps> = ({
|
||||
children,
|
||||
lang,
|
||||
activePage,
|
||||
siteUrls,
|
||||
}) => {
|
||||
return (
|
||||
<div className="min-h-screen min-w-screen flex h-screen w-screen">
|
||||
{/* Sidebar */}
|
||||
<aside className="w-1/4 border-r p-4 overflow-y-auto">
|
||||
<ClientMenu siteUrls={siteUrls} lang={lang} activePage={activePage} />
|
||||
</aside>
|
||||
|
||||
{/* Main Content Area */}
|
||||
<div className="flex flex-col w-3/4 overflow-y-auto">
|
||||
{/* Header Component */}
|
||||
<Header lang={lang} />
|
||||
|
||||
{/* Page Content */}
|
||||
<div className="container mx-auto p-4">
|
||||
{children}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default DashboardLayout;
|
||||
Reference in New Issue
Block a user