···88import { Basic } from '../../../examples/sidebar-layout/basic'
99import { WithHeaderLayout } from '../../../examples/sidebar-layout/with-header-layout'
1010import { WithHeaderLayoutWrapper } from '../../../examples/sidebar-layout/with-header-layout-wrapper'
1111+import { InconsequentialSidebar } from '../../../examples/sidebar-layout/inconsequential-sidebar'
11121213<Example src={Basic} noPadding />
1314···23242425This is a custom component built for page layouts with sidebar and content slots.
25262626-<PropDocs components={["SidebarLayoutRoot", "SidebarLayoutSidebar", "SidebarLayoutPage"]} />
2727+<PropDocs components={["SidebarLayoutRoot", "SidebarLayoutNavigationSidebar", "SidebarLayoutPage", "SidebarLayoutInconsequentialSidebar"]} />
27282829## Features
3030+3131+### InconsequentialSidebar
3232+3333+The `InconsequentialSidebar` component is a secondary sidebar for supplementary content that is not critical for navigation or core functionality.
3434+3535+Unlike `NavigationSidebar`, this component:
3636+3737+- Does not include mobile drawer support
3838+- Simply hides on smaller screens when space is limited
3939+- Is designed for content that can be safely hidden without impacting usability
4040+4141+#### Use Cases
4242+4343+- **Table of Contents**: Display document structure and quick navigation
4444+- **Related Links**: Show related articles, resources, or supplementary content
4545+- **Filters & Controls**: Secondary filtering options that aren't critical
4646+- **Metadata**: Additional information like tags, categories, or timestamps
4747+- **Secondary Navigation**: Additional navigation that complements the main sidebar
4848+4949+<Example src={InconsequentialSidebar} noPadding />
29503051### With Header Layout
3152
···11+import { SidebarLayout } from "@/components/sidebar-layout";
22+import { TableOfContents, Toc } from "@/components/table-of-contents";
33+import { Content } from "@/components/content";
44+import { Heading1, Heading2, Heading3, Body } from "@/components/typography";
55+import * as stylex from "@stylexjs/stylex";
66+77+const styles = stylex.create({
88+ root: {
99+ maxHeight: "60vh",
1010+ overflowY: "auto",
1111+ },
1212+});
1313+1414+// Mock table of contents data
1515+const toc: Toc = [
1616+ {
1717+ id: "introduction",
1818+ value: "Introduction",
1919+ depth: 1,
2020+ children: [],
2121+ },
2222+ {
2323+ id: "getting-started",
2424+ value: "Getting Started",
2525+ depth: 1,
2626+ children: [
2727+ {
2828+ id: "installation",
2929+ value: "Installation",
3030+ depth: 2,
3131+ children: [],
3232+ },
3333+ {
3434+ id: "configuration",
3535+ value: "Configuration",
3636+ depth: 2,
3737+ children: [],
3838+ },
3939+ ],
4040+ },
4141+ {
4242+ id: "components",
4343+ value: "Components",
4444+ depth: 1,
4545+ children: [
4646+ {
4747+ id: "button",
4848+ value: "Button",
4949+ depth: 2,
5050+ children: [],
5151+ },
5252+ {
5353+ id: "card",
5454+ value: "Card",
5555+ depth: 2,
5656+ children: [],
5757+ },
5858+ ],
5959+ },
6060+];
6161+6262+export function InconsequentialSidebar() {
6363+ return (
6464+ <SidebarLayout.Root style={styles.root}>
6565+ <SidebarLayout.Page>
6666+ <Content>
6767+ <Heading1 id="introduction">Introduction</Heading1>
6868+ <Body>
6969+ This example demonstrates the InconsequentialSidebar component. The
7070+ main navigation is on the left, and the table of contents appears on
7171+ the right side on large screens.
7272+ </Body>
7373+7474+ <Heading2 id="getting-started">Getting Started</Heading2>
7575+ <Body>
7676+ The InconsequentialSidebar is perfect for supplementary content like
7777+ table of contents, related links, or metadata.
7878+ </Body>
7979+8080+ <Heading3 id="installation">Installation</Heading3>
8181+ <Body>
8282+ Resize your browser window to see how the sidebar hides on smaller
8383+ screens. It only appears on large screens (lg breakpoint).
8484+ </Body>
8585+8686+ <Heading3 id="configuration">Configuration</Heading3>
8787+ <Body>
8888+ You can control when the sidebar appears using the visible prop. Set
8989+ it to "md" for medium screens or "lg" for large screens only.
9090+ </Body>
9191+9292+ <Heading2 id="components">Components</Heading2>
9393+ <Body>
9494+ The InconsequentialSidebar is ideal for content that enhances the
9595+ user experience but isn't critical for core functionality.
9696+ </Body>
9797+9898+ <Heading3 id="button">Button</Heading3>
9999+ <Body>
100100+ Unlike NavigationSidebar, this component doesn't include mobile
101101+ drawer support. It simply hides when space is limited.
102102+ </Body>
103103+104104+ <Heading3 id="card">Card</Heading3>
105105+ <Body>
106106+ This makes it perfect for supplementary content that can be safely
107107+ hidden on smaller screens without impacting usability.
108108+ </Body>
109109+ </Content>
110110+ </SidebarLayout.Page>
111111+ <SidebarLayout.InconsequentialSidebar visible="md">
112112+ <TableOfContents toc={toc} />
113113+ </SidebarLayout.InconsequentialSidebar>
114114+ </SidebarLayout.Root>
115115+ );
116116+}