{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "layout-header-clip",
  "type": "registry:item",
  "title": "Header Clip",
  "description": "Control whether the Header spans over the left/right EdgeSidebar.",
  "dependencies": [
    "@mui/material",
    "@emotion/react",
    "@emotion/styled"
  ],
  "registryDependencies": [
    "https://www.mui-treasury.com/r/layout-core.json"
  ],
  "files": [
    {
      "path": "layout/layout-docs-header/demos/layout-header-clip.demo.tsx",
      "target": "src/mui-treasury/layout/layout-docs-header/demos/layout-header-clip.demo.tsx",
      "content": "import React from 'react';\n\nimport Box from '@mui/material/Box';\nimport ToggleButton from '@mui/material/ToggleButton';\nimport ToggleButtonGroup from '@mui/material/ToggleButtonGroup';\nimport Typography from '@mui/material/Typography';\n\nimport Content from '@/registry/layout/layout-core/Content';\nimport EdgeSidebar from '@/registry/layout/layout-core/EdgeSidebar';\nimport EdgeSidebarContent from '@/registry/layout/layout-core/EdgeSidebarContent';\nimport EdgeSidebarRight from '@/registry/layout/layout-core/EdgeSidebarRight';\nimport Footer from '@/registry/layout/layout-core/Footer';\nimport Header from '@/registry/layout/layout-core/Header';\nimport Root from '@/registry/layout/layout-core/Root';\n\ntype ClipValue = 'left' | 'right' | 'both' | 'none';\n\nexport const meta = {\n  title: 'Header Clip',\n  description:\n    'Control whether the Header spans over the left/right EdgeSidebar.',\n  previewMode: 'iframe' as const,\n};\n\nexport function Demo() {\n  const [clip, setClip] = React.useState<ClipValue>('none');\n\n  const headerClip =\n    clip === 'both' ? true : clip === 'none' ? undefined : clip;\n\n  return (\n    <Box\n      sx={{ display: 'flex', flexDirection: 'column', gap: 2, width: '100%' }}\n    >\n      <ToggleButtonGroup\n        value={clip}\n        exclusive\n        onChange={(_, value) => {\n          if (value !== null) setClip(value);\n        }}\n        size=\"small\"\n      >\n        <ToggleButton value=\"none\">None</ToggleButton>\n        <ToggleButton value=\"left\">Left</ToggleButton>\n        <ToggleButton value=\"right\">Right</ToggleButton>\n        <ToggleButton value=\"both\">Both</ToggleButton>\n      </ToggleButtonGroup>\n      <Root height=\"300px\" sx={{ width: '100%' }}>\n        <Header clip={headerClip}>\n          <Box sx={{ px: 2 }}>\n            <Typography\n              variant=\"subtitle2\"\n              sx={{\n                fontWeight: 'bold',\n              }}\n            >\n              Header\n            </Typography>\n          </Box>\n        </Header>\n        <EdgeSidebar variant={['permanent', { width: '200px' }]}>\n          <EdgeSidebarContent>\n            <Box sx={{ p: 2 }}>\n              <Typography\n                variant=\"caption\"\n                sx={{\n                  color: 'text.secondary',\n                }}\n              >\n                Left Sidebar\n              </Typography>\n            </Box>\n          </EdgeSidebarContent>\n        </EdgeSidebar>\n        <Content>\n          <Box sx={{ p: 2 }}>\n            <Typography\n              variant=\"body2\"\n              sx={{\n                color: 'text.secondary',\n              }}\n            >\n              Content area\n            </Typography>\n          </Box>\n        </Content>\n        <EdgeSidebarRight variant={['permanent', { width: '200px' }]}>\n          <EdgeSidebarContent>\n            <Box sx={{ p: 2 }}>\n              <Typography\n                variant=\"caption\"\n                sx={{\n                  color: 'text.secondary',\n                }}\n              >\n                Right Sidebar\n              </Typography>\n            </Box>\n          </EdgeSidebarContent>\n        </EdgeSidebarRight>\n        <Footer>\n          <Box sx={{ p: 2 }}>\n            <Typography\n              variant=\"caption\"\n              sx={{\n                color: 'text.secondary',\n              }}\n            >\n              Footer\n            </Typography>\n          </Box>\n        </Footer>\n      </Root>\n    </Box>\n  );\n}\n",
      "type": "registry:item"
    }
  ],
  "meta": {
    "category": "layout",
    "previewMode": "iframe"
  }
}