Files
frontend/components/templates/main-layout/MainLayout.tsx
T
2026-04-03 20:09:05 +07:00

28 lines
695 B
TypeScript

import { CartFab } from "@/components/organisms/cart";
import Footer from "@/layouts/footer";
import Header from "@/layouts/header";
import type { MainLayoutProps } from "./MainLayout.types";
/**
* Main layout template — wraps content with Header, Footer, and CartFab.
* Used by the (main) route group layout.
*/
export default function MainLayout({ children }: MainLayoutProps) {
return (
<>
{/* Sticky top header */}
<Header />
{/* Page content (grows to fill remaining height) */}
<div className="flex-1">{children}</div>
{/* Footer always at bottom */}
<Footer />
{/* Global floating cart button */}
<CartFab />
</>
);
}