Provides collapsed/expanded state for the PortalLayout sidebar.
Wrap the part of your app that renders PortalLayout (plus any other component that needs to read the sidebar width) with SidebarProvider.
PortalLayout
SidebarProvider
import { SidebarProvider, PortalLayout } from '@hiyve/react-ui';function App() { return ( <SidebarProvider> <PortalLayout title="My Portal" navItems={items} currentPath={path} onNavigate={nav} /> </SidebarProvider> );} Copy
import { SidebarProvider, PortalLayout } from '@hiyve/react-ui';function App() { return ( <SidebarProvider> <PortalLayout title="My Portal" navItems={items} currentPath={path} onNavigate={nav} /> </SidebarProvider> );}
Provides collapsed/expanded state for the PortalLayout sidebar.
Wrap the part of your app that renders
PortalLayout(plus any other component that needs to read the sidebar width) withSidebarProvider.