PageLayout
A full-page layout shell with Navbar, optional sidebar, content area, and Footer.
Import
import { PageLayout } from "@gumtree/ui/layout/PageLayout" ; Props
| Prop | Type | Default | Description |
|---|---|---|---|
sidebar | ComponentChildren | - | Sidebar content rendered to the left of main |
navbarEnd | ComponentChildren | - | Content for the Navbar end slot |
children | ComponentChildren | - | Main content area |
Examples
With Sidebar
A page layout with a sidebar and main content.
Main Content
Page body goes here.
< PageLayout
sidebar = { < Sidebar items = { [
{ label : "Home" , href : "#" , active : true } ,
{ label : "Settings" , href : "#" } ,
] } /> }
>
< h2 > Main Content </ h2 >
< p > Page body goes here. </ p >
</ PageLayout > Without Sidebar
PageLayout works without a sidebar too.
Full Width Content
No sidebar in this layout.
< PageLayout >
< h2 > Full Width Content </ h2 >
< p > No sidebar in this layout. </ p >
</ PageLayout >