carbon-components-svelte/docs/src/pages/components/UIShell.svx
2022-08-17 07:15:29 -07:00

72 lines
No EOL
1.7 KiB
Text

---
components: ["Header",
"HeaderAction",
"HeaderActionLink",
"HeaderSearch",
"HeaderNav",
"HeaderNavItem",
"HeaderNavMenu",
"HeaderPanelDivider",
"HeaderPanelLink",
"HeaderPanelLinks",
"HeaderUtilities",
"SideNav",
"SideNavItems",
"SideNavLink",
"SideNavMenu",
"SideNavMenuItem",
"Content",
"SkipToContent",
"HeaderGlobalAction"]
---
<script>
import { InlineNotification } from "carbon-components-svelte";
import Preview from "../../components/Preview.svelte";
</script>
<InlineNotification svx-ignore lowContrast title="Note:" kind="info" hideCloseButton>
<div class="body-short-01">
Currently, the UI Shell is not themable and only supports dark mode.
</div>
</InlineNotification>
Open the following examples in a new tab to experience them in full.
## Header
<FileSource src="/framed/UIShell/Header" />
## Header with side navigation
The hamburger menu will automatically be rendered if the `SideNav` component is used.
<FileSource src="/framed/UIShell/HeaderNav" />
## Header with side navigation (rail)
Set `rail` to `true` on `SideNav` to use the rail variant.
<FileSource src="/framed/UIShell/HeaderNavRail" />
## Header with app switcher
The `HeaderAction` component uses the [transition:slide API](https://svelte.dev/docs#slide); you can customize the transition duration, delay, and easing with the `transition` prop.
You can disable the `transition` by setting it to `false`.
<FileSource src="/framed/UIShell/HeaderSwitcher" />
## Header with global search
<FileSource src="/framed/UIShell/HeaderSearch" />
## Header with utilities
<FileSource src="/framed/UIShell/HeaderUtilities" />
## Header with persisted hamburger menu
<FileSource src="/framed/UIShell/PersistedHamburgerMenu" />