@ottili/foundation-shell
v1.0.13
Published
Topbar, sidebar, mobile nav, inspector and switchers (SoT §8.4, §15).
Downloads
773
Readme
@ottili/foundation-shell
Topbar, sidebar, mobile nav, inspector and switchers (SoT §8.4, §15).
Install
npm install @ottili/foundation-shellThis package is part of the Ottili Foundation Framework. See docs/OTTILI_FOUNDATION_FRAMEWORK_SOURCE_OF_TRUTH.md for the canonical spec.
Public API
AppShelllays out topbar, sidebar, main, inspector, and workbench regions.Topbar,Sidebar,CompanySwitcher,ProductSwitcher,QuickCreate,FavoritesList, andRecentsList.useSidebarCollapsefor collapsible sidebar state.- Switcher and badge helpers for company/product context.
Usage
import { AppShell, Topbar, Sidebar, Brand, useSidebarCollapse } from "@ottili/foundation-shell";
const { collapsed } = useSidebarCollapse();
<AppShell
topbar={<Topbar brand={<Brand productName="HQ" />} />}
sidebar={<Sidebar items={navItems} translate={t} collapsed={collapsed} />}
>
<ProductPage />
</AppShell>