entasis 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/FloatingWindow/FloatingWindow.svelte +26 -2
- package/dist/components/FloatingWindow/floatingWindow.dock.svelte.js +11 -2
- package/dist/components/FloatingWindow/floatingWindow.mcp.d.ts +1 -1
- package/dist/components/FloatingWindow/floatingWindow.mcp.js +7 -4
- package/dist/components/FloatingWindow/floatingWindow.props.d.ts +6 -0
- package/dist/components/FloatingWindow/floatingWindow.state.svelte.d.ts +3 -0
- package/dist/components/FloatingWindow/floatingWindow.state.svelte.js +18 -4
- package/dist/components/FloatingWindow/floatingWindow.theme.d.ts +3 -0
- package/dist/components/FloatingWindow/floatingWindow.theme.js +20 -7
- package/dist/components/Form/File/FileInput.svelte +6 -42
- package/dist/components/Sidebar/Sidebar.svelte +72 -12
- package/dist/components/Sidebar/Sidebar.svelte.d.ts +1 -1
- package/dist/components/Sidebar/SidebarActivityBar.svelte +9 -2
- package/dist/components/Sidebar/SidebarActivityBar.svelte.d.ts +5 -1
- package/dist/components/Sidebar/SidebarDesktopShell.svelte +12 -4
- package/dist/components/Sidebar/SidebarMenuItem.svelte +19 -2
- package/dist/components/Sidebar/SidebarMenuItem.svelte.d.ts +4 -0
- package/dist/components/Sidebar/SidebarPanel.svelte +199 -88
- package/dist/components/Sidebar/SidebarPanel.svelte.d.ts +3 -0
- package/dist/components/Sidebar/SidebarViewStage.svelte +103 -0
- package/dist/components/Sidebar/SidebarViewStage.svelte.d.ts +18 -0
- package/dist/components/Sidebar/index.d.ts +1 -1
- package/dist/components/Sidebar/sidebar-layout.d.ts +7 -2
- package/dist/components/Sidebar/sidebar-layout.js +17 -6
- package/dist/components/Sidebar/sidebar.mcp.d.ts +1 -1
- package/dist/components/Sidebar/sidebar.mcp.js +19 -2
- package/dist/components/Sidebar/sidebar.props.d.ts +56 -1
- package/dist/components/Sidebar/sidebar.state.svelte.d.ts +4 -0
- package/dist/components/Sidebar/sidebar.state.svelte.js +9 -1
- package/dist/components/Sidebar/sidebar.theme.d.ts +149 -5
- package/dist/components/Sidebar/sidebar.theme.js +96 -3
- package/dist/components/Sidebar/sidebar.views.svelte.d.ts +138 -0
- package/dist/components/Sidebar/sidebar.views.svelte.js +303 -0
- package/dist/components/Theme/theme.floatingWindows.d.ts +6 -1
- package/dist/components/Theme/theme.floatingWindows.js +7 -2
- package/dist/components/Theme/theme.mcp.d.ts +1 -1
- package/dist/components/Theme/theme.mcp.js +1 -0
- package/dist/generated/componentContract.d.ts +1 -1
- package/dist/generated/componentContract.js +1 -0
- package/dist/generated/componentMcpRegistry.d.ts +4 -4
- package/dist/tailwind/index.mcp.d.ts +1 -1
- package/dist/tailwind/index.mcp.js +4 -0
- package/dist/tailwind/scales.js +11 -3
- package/dist/tailwind/spacing.js +17 -0
- package/dist/utils/cva/merge.d.ts +7 -0
- package/dist/utils/cva/merge.js +6 -1
- package/dist/utils/pointerDrag.js +7 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const sidebarDescription = "\n# Sidebar Component\n\nSidebar navigation with data-driven groups, icon collapse, mobile drawer behavior,\nrecursive tree groups, header/footer rows, search, actions, and snippet escape hatches.\n\n## Import\n\n```svelte\n<script lang=\"ts\">\n\timport { Sidebar, type SidebarGroup } from 'entasis/sidebar';\n</script>\n```\n\n## Basic Usage\n\n```svelte\n<script lang=\"ts\">\n\timport { Sidebar, type SidebarGroup } from 'entasis/sidebar';\n\timport { houseIcon } from 'entasis/icons/house';\n\timport { gearIcon } from 'entasis/icons/gear';\n\n\tconst items: SidebarGroup[] = [\n\t\t{\n\t\t\tlabel: 'Workspace',\n\t\t\titems: [\n\t\t\t\t{ label: 'Dashboard', href: '/', icon: houseIcon, isActive: true },\n\t\t\t\t{ label: 'Settings', href: '/settings', icon: gearIcon }\n\t\t\t]\n\t\t}\n\t];\n</script>\n\n<Sidebar items={items}>\n\t{#snippet children({ toggle })}\n\t\t<header>\n\t\t\t<button type=\"button\" onclick={toggle}>Toggle</button>\n\t\t</header>\n\t\t<main>Page content</main>\n\t{/snippet}\n</Sidebar>\n```\n\n## AI-Safe Usage Contract\n\n1. Use `items` for normal navigation. Use `content` only when data-driven rows cannot express the layout.\n2. Use local Entasis icon snippets such as `houseIcon`, not Lucide component constructors.\n3. Use `MenuItem[]` from `entasis/menu` for `menu` and action dropdowns.\n4. Do not combine `menu` with `href` or `onclick` on the same row; use `action` for a trailing row menu.\n5. Keep `children`, `header`, `content`, `footer`, `banner`, and action snippets pure; they receive `SidebarApi`.\n6. Use `collapsible=\"icon\"` for icon rail behavior, `collapsible=\"offcanvas\"` for hidden desktop panels, and `collapsible=\"none\"` for fixed sidebars. Icon collapse automatically falls back to offcanvas when any data-driven row lacks an icon.\n7. Offcanvas sidebars reveal over the content from the screen edge by default when hidden; set `edgeReveal={false}` to disable that. A revealed hidden sidebar keeps its resize handle and dismisses through a small rectangular pointer tolerance.\n8. Set `keyboardShortcut={false}` when embedding Sidebar inside another shortcut-heavy surface.\n9. Sidebar owns navigation, resize mechanics, the lower application wall, and variant surface geometry. AppShell forwards its variant and composes PageShell inside that surface.\n10. Use `size` for typography, icon scale, and item height. Use `density` independently for section padding, gaps, and submenu spacing.\n11. Use `activityBar` for a persistent icon rail outside the panel (section switching, workspaces). Every item needs an `icon` and a `label`; the label is the accessible name and the tooltip. It is layout mode only: `mode=\"panel\"` renders the navigation panel alone.\n12. Use `expandOnHover` only with `collapsible=\"icon\"`. It is a temporary peek, not a toggle: the persisted collapsed state never changes, while the peeked panel renders with expanded semantics.\n\n## Data Model\n\n### SidebarGroup\n- **label**: string - Group label, hidden in icon-collapsed mode.\n- **items**: SidebarMenuEntry[] - Menu rows.\n- **tree**: SidebarTreeNode[] - Recursive tree rows instead of menu items.\n- **action**: SidebarMenuActionDescriptor | SidebarMenuActionDescriptor[] | Snippet<[SidebarApi]> - Top-right group actions. Pass an array to pin several affordances (a `+` and a drag handle) to one group header; each renders as its own icon-only ghost button.\n- **collapsible**: boolean - Makes the group label a toggle.\n- **defaultOpen**: boolean - Initial collapsible group state.\n- **separator**: boolean - Divider before the group.\n\n### SidebarMenuEntry\n- **label**: string - Visible row label.\n- **icon**: SidebarIcon - Entasis icon snippet or string.\n- **iconColor**: Colors - Role tint for the leading icon, applied through `data-color`.\n- **iconVariant**: 'bare' | 'tile' - Leading icon treatment. `tile` paints a rounded square (`bg-color-muted text-color-muted-readable`) around the glyph, so per-project colour chips come from the role scale instead of hand-built markup.\n- **href**: string - Render as an anchor. Mutually exclusive with menu.\n- **onclick**: (event: MouseEvent) => void - Native click handler for button or anchor rows. Mutually exclusive with menu.\n- **isActive**: boolean - Adds active styling and `aria-current=\"page\"`.\n- **disabled**: boolean - Disables button rows and marks anchor rows disabled.\n- **badge**: string | number - Trailing count/status, hidden in icon mode.\n- **tooltip**: string - Entasis Tooltip content in icon mode. Defaults to label.\n- **items**: SidebarMenuSubEntry[] - Inline nested menu.\n- **collapsible**: boolean - Set false for an always-open submenu.\n- **defaultOpen**: boolean - Initial nested menu state.\n- **menu**: MenuItem[] - Popup menu opened from the full row. Mutually exclusive with href/onclick.\n- **action**: SidebarMenuActionDescriptor | Snippet<[SidebarApi]> - Hover/focus trailing action.\n\n### SidebarActivityBar\nIcon rail pinned to the outer edge of the sidebar, visible in every display state.\n- **items**: SidebarActivityBarItem[] - Items rendered from the top.\n- **footerItems**: SidebarActivityBarItem[] - Items pinned to the end of the column.\n- **header** / **footer**: Snippet - Custom content before the first item and after the pinned ones.\n- **width**: string (default '3rem') - Column thickness, published as `--sidebar-width-activity`.\n- **label**: string - Accessible name for the column landmark. Set it whenever the panel also renders navigation.\n- **onSelect**: ({ item, index }) => void - Fires after an item is activated. `index` counts `items` then `footerItems`.\n\n### SidebarActivityBarItem\n- **icon**: SidebarIcon (required) - Icon rendered in the square.\n- **label**: string (required) - Accessible name and default tooltip; the square shows no text.\n- **id**: string - Stable render key.\n- **href** / **target** / **rel** - Render an anchor instead of a button.\n- **onclick**: (event: MouseEvent) => void - Native click handler.\n- **isActive**: boolean - Adds active styling and `aria-current=\"page\"`.\n- **badge**: string | number | Snippet - Corner badge pinned to the outer top corner. An empty string renders a bare dot. A string or number badge joins the accessible name (`\"Alerts, 3\"`); a dot and a Snippet badge are decorative, so put their meaning in `label`.\n- **disabled**: boolean - Blocks activation and skips the item during keyboard navigation.\n- **tooltip**: string | false - Tooltip override; `false` suppresses it.\n\n### SidebarMenuButtonItem\nUse for `headerButton`, `footerButton`, or direct `<SidebarMenuButton />` rows.\n- **icon**: SidebarIcon - Leading logo/icon.\n- **avatar**: { src?: string; alt?: string; fallback?: string } - Leading avatar.\n- **variant**: 'default' | 'brand' | 'compact'.\n- **title**: string - Primary text.\n- **subtitle**: string - Secondary text.\n- **trailing**: SidebarIcon | false | SidebarMenuActionDescriptor - Trailing content. An icon is decorative; an action descriptor (`{ icon, label, onclick }`, the same shape as a group action) renders its own icon-only ghost button beside the row, so a workspace card can carry its own collapse control without a custom `header` snippet. Descriptor handlers are `onclick(event, api)`, so `api.toggle()` is reachable.\n- **href** / **onclick** / **menu** - Choose link, button, or popup behavior. `onclick(event, api)` receives the SidebarApi beside the event, so `api.toggle()` is reachable from the row itself.\n- **menuIconClass**: string - Class override for option icons inside the popup menu.\n\n## Props\n\n### State\n- **open**: boolean (bindable, default true) - Desktop expanded state.\n- **defaultOpen**: boolean (default true) - Initial desktop state when `open` is omitted.\n- **onOpenChange**: (open: boolean) => void - Called once for a library-originated desktop state change. Repeated requests and parent prop updates stay silent.\n- **onDisplayStateChange**: (state: SidebarDisplayState) => void - Called once for a library-originated semantic display-state change.\n- **api.displayState**: 'expanded' | 'collapsed' | 'hidden' - Semantic desktop state; hidden means closed offcanvas. A hover peek does not change it.\n- **api.isPeeking**: boolean - True while a hover peek renders the collapsed panel at full width. Read it alongside `displayState` when a snippet hides content in icon mode.\n- **keyboardShortcut**: string | false (default 'b') - Ctrl/Cmd shortcut key.\n\n### Layout\n- **side**: 'left' | 'right' - Desktop and mobile side.\n- **variant**: 'admin' | 'floating' | 'inset' | 'split' | 'framed' - Sidebar geometry. `framed` is the admin geometry for a sidebar hosted inside a raised card (AppShell variant framed), with a `surface-recessed` well. `admin` renders the conventional full-height navigation column; `inset` integrates navigation into the lower wall with an inset content surface; `split` renders detached sidebar and content surfaces.\n- **size**: 'small' | 'normal' | 'large' (default 'normal') - Typography, icon, avatar, badge, leading-media, item-height, and search-height scale.\n- **iconSize**: 'small' | 'normal' | 'large' - Icon and leading-media scale inside the panel on its own; defaults to `size`. Menu rows, sub rows, group labels and the header button follow it; the activity bar keeps `size`.\n- **activeVariant**: 'soft' | 'outline' | 'solid' (default 'soft') - How active rows are painted. `soft` is the shared selected recipe (`selectedSoft`: `bg-selected-muted text-selected-muted-readable`), `solid` its loud counterpart (`selectedSolid`: `bg-selected text-selected-contrast`), `outline` a bordered surface card (`bg-surface border border-neutral-muted text-neutral`) that reads as a raised card on a tinted well. Each row carries the choice as `data-active-variant`, so no descendant selector is needed to restyle selection.\n- **density**: 'compact' | 'normal' | 'comfortable' (default 'normal') - Section padding, group padding, gaps, horizontal inset, and submenu spacing.\n- **collapsible**: 'offcanvas' | 'icon' | 'none' - Collapse behavior. Icon mode requires icons on every data-driven row and otherwise resolves to offcanvas.\n- **collapseIcon**: DisclosureIndicator \u2014 'chevron' | 'plus-minus' | 'none' (default 'chevron') - Disclosure indicator drawn on collapsible menu rows. 'none' renders no indicator.\n- **mode**: 'layout' | 'panel' - Full resizing layout or only the visible navigation panel.\n- **frame**: 'viewport' | 'contained' - Standalone Sidebar positioning. Viewport mode uses Theme's dynamic window-height token; contained mode fills a positioned parent.\n- **width**: string - Expanded width.\n- **widthIcon**: string - Icon-collapsed width.\n- **widthMobile**: string - Mobile drawer width.\n- **rail**: boolean | 'line' | 'thumb' - Edge toggle rail. `true` keeps the thin line style; `thumb` renders a short visible handle with the same full-height hitbox. The appearance is preserved when the rail shares the resize control.\n- **activityBar**: SidebarActivityBar - Icon rail pinned outside the panel, in layout mode only (`mode=\"panel\"` renders the panel alone and ignores it). It never slides off screen: only the panel takes the offcanvas offset, and the reserved layout column is the panel width plus the rail width. On mobile it renders as a horizontal row at the top of the drawer.\n- **expandOnHover**: boolean (default false) - With `collapsible=\"icon\"`, hovering or focusing into the collapsed panel expands it to `width` over the page (`data-peek=\"true\"`) while the reserved column stays at `widthIcon`, so page content does not reflow. The persisted collapsed state is untouched, and the peeked panel renders exactly like an expanded one: group headers, badges, search, inline submenus, and inline tree branches all come back, and the rail or resize handle travels to its inner edge.\n- **edgeReveal**: boolean (default true) - Pointer/focus edge preview for hidden offcanvas sidebars. Hover reveal overlays content, remains resizable when configured, and re-hides after the pointer leaves its small rectangular tolerance. Dragging the sidebar closed suppresses immediate hover reopening until the pointer leaves the edge trigger; toggle/click opens persistently.\n- **resizable**: boolean | SidebarResizableOptions - Enables pointer and keyboard resizing while expanded, icon-collapsed, or temporarily edge-revealed. By default, collapse requires dragging 75% of `minWidth` beyond the minimum; override `collapseThreshold` for a custom boundary. Use `storageKey` to restore and persist the expanded width across sessions.\n - `onWidthChange({ width, isUserInteraction })` reports every expanded-width change with one named payload: continuously while the user resizes (`isUserInteraction: true`) and once when a stored width is restored (`isUserInteraction: false`).\n\n### Content\n- **items**: SidebarGroup[] - Data-driven body navigation.\n- **headerButton** / **footerButton**: SidebarMenuButtonItem - Sticky large rows.\n- **search**: SidebarSearch - Header search input; use its native `oninput` handler.\n- **headerMenu** / **footerMenu**: SidebarMenuEntry[] - Sticky quick menus.\n- Menu entries and nested entries accept `size: 'small' | 'normal' | 'large'` for row geometry.\n- **header**, **content**, **footer**, **children**, **banner**: Snippet<[SidebarApi]> - Escape hatches. The `header` snippet renders **first** in the header region, above `headerButton`, `search` and `headerMenu`.\n\n### Styling\n- **class**: string - Classes applied to the Sidebar root.\n- **theme**: SidebarThemeProps - Semantic part overrides such as `panel`, `header`, `nav`, `footer`, menu, search, rail, and mobile drawer parts. Every part, with the element it lands on, its variants and their default classes, is listed in the entasis skill's `theme-parts/sidebar.md`; the registry key is `sidebar`.\n\n## Motion\n\n- **motion** theme slot: the y-axis slide shared by collapsible groups, inline submenus, and\n tree branches. Takes `in` / `out` slide params plus a `duration` / `easing` motion token.\n- Ladder: `<Theme components={{ sidebar: { motion } }}>` \u2192 `setSidebarTheme({ motion })` \u2192\n `theme.motion`. Reduced motion collapses it to 0.\n\n## Restyle recipes\n\nThe five asks that come up first, as the override to copy. Each one is rendered and asserted by\n`sidebar-recipes.svelte.test.ts`, so it cannot drift from the component. One rule behind them: a\ndefault written under a variant prefix (`data-[active-variant=solid]:data-active:bg-selected`,\n`data-[side=left]:border-r`) is only replaced by an override carrying the same prefixes; an\nunprefixed class coexists with it and loses on specificity. `theme-parts/sidebar.md` shows every\ndefault verbatim, prefixes included.\n\n- **Dark panel.** `dark` scopes the dark theme's variables to the panel, so every neutral ink inside\n flips with it (every theme also emits its variables on `.<name>`, so the class scopes the dark theme to one subtree); needs a theme named `dark`, which the documented setup declares.\n `theme={{ panel: { base: 'dark bg-slate-900' }, mobilePanel: { base: 'dark bg-slate-900' } }}`\n- **Active row in your colour.** `activeVariant=\"solid\"` plus the same prefix chain as the default:\n `theme={{ menuButton: { base: 'rounded-full', activeVariant: { solid: 'data-[active-variant=solid]:data-active:bg-indigo-600 data-[active-variant=solid]:data-active:text-white' } } }}`\n- **No hover change.** The overlay is a `::before` and the default also brightens the ink on hover:\n `theme={{ menuButton: { base: 'state-layer-none hover:text-inherit' }, subButton: { base: 'state-layer-none hover:text-neutral/70' } }}`\n- **Flat panel.** The edge is a prefixed `border-r` / `border-l` on the admin variant, the shadow a\n `raised-*` on the floating ones:\n `theme={{ panel: { base: 'raised-none', variant: { admin: 'data-[side=left]:border-r-0 data-[side=right]:border-l-0' } } }}`\n- **Row height.** A plain height beats the compound `h-control-*`: `theme={{ menuButton: { base: 'h-11' } }}`\n- **Bigger icons.** A prop, not a theme: `iconSize=\"large\"`.\n\n## Accessibility\n\n- The body navigation renders inside a named `<nav>` landmark (`data-sidebar=\"nav\"`), so assistive tech can jump straight to it and tell it apart from the activity bar's own landmark.\n- Active links set `aria-current=\"page\"`.\n- Collapsible rows and groups set `aria-expanded`.\n- Disabled buttons use `disabled`; disabled links omit `href`, use `aria-disabled` and `tabindex=-1`, and block activation.\n- Mobile drawer includes a backdrop button labelled \"Close Sidebar\".\n- Icon-collapsed rows keep their labels mounted and visually fade them, preserving accessible names and stable icon geometry.\n- Search, group controls, actions, and nested rows become inert before collapse can remove or hide them; focus returns to the owning visible row.\n- Nested groups, tree branches, and inline submenus use reversible height transitions for open, close, and sidebar-collapse changes.\n- Tree roots use menu-row styling and nested tree nodes use submenu-row styling. In desktop icon mode, root folders open a PopupMenu and descendants remain navigable through recursive Menu submenu popovers; root leaves retain direct navigation and tooltips.\n- When `rail` and `resizable` are both enabled, one edge control owns click-to-toggle, drag resize, and keyboard resize without overlapping hitboxes.\n- Hidden offcanvas sidebars keep that combined edge control while temporarily revealed. Resizing does not pin the sidebar open; leaving the panel, trigger, and handle tolerance re-hides it without discarding the configured width.\n- Both peeks (edge reveal and `expandOnHover`) stay open while focus is inside the panel or while an overlay opened from inside it is open, including nested submenus. They release about 120ms after the pointer, focus, and every such overlay are gone.\n- The activity bar is its own `<nav>` landmark with a `<ul>` of items, a roving tabindex, and ArrowUp/ArrowDown/Home/End navigation that loops and skips disabled items. Tab lands on the `isActive` item. Each square takes its accessible name from `label`, with a string or number `badge` appended to it, and shows `label` as a tooltip on hover and focus.\n- A hidden offcanvas panel is `inert`, so Tab never lands in a panel parked off screen; a peek makes it interactive again.\n\n## Notes\n\n- Dropdown menus use Entasis `PopupMenu` and `MenuItem[]`.\n- The component uses semantic Entasis tokens. Do not add shadcn `sidebar-*` color tokens.\n- Snippet icons from `entasis/icons/*` are the preferred icon format.\n";
|
|
1
|
+
export declare const sidebarDescription = "\n# Sidebar Component\n\nSidebar navigation with data-driven groups, icon collapse, mobile drawer behavior,\nrecursive tree groups, header/footer rows, search, actions, and snippet escape hatches.\n\n## Import\n\n```svelte\n<script lang=\"ts\">\n\timport { Sidebar, type SidebarGroup } from 'entasis/sidebar';\n</script>\n```\n\n## Basic Usage\n\n```svelte\n<script lang=\"ts\">\n\timport { Sidebar, type SidebarGroup } from 'entasis/sidebar';\n\timport { houseIcon } from 'entasis/icons/house';\n\timport { gearIcon } from 'entasis/icons/gear';\n\n\tconst items: SidebarGroup[] = [\n\t\t{\n\t\t\tlabel: 'Workspace',\n\t\t\titems: [\n\t\t\t\t{ label: 'Dashboard', href: '/', icon: houseIcon, isActive: true },\n\t\t\t\t{ label: 'Settings', href: '/settings', icon: gearIcon }\n\t\t\t]\n\t\t}\n\t];\n</script>\n\n<Sidebar items={items}>\n\t{#snippet children({ toggle })}\n\t\t<header>\n\t\t\t<button type=\"button\" onclick={toggle}>Toggle</button>\n\t\t</header>\n\t\t<main>Page content</main>\n\t{/snippet}\n</Sidebar>\n```\n\n## AI-Safe Usage Contract\n\n1. Use `items` for normal navigation. Use `content` only when data-driven rows cannot express the layout.\n2. Use local Entasis icon snippets such as `houseIcon`, not Lucide component constructors.\n3. Use `MenuItem[]` from `entasis/menu` for `menu` and action dropdowns.\n4. Do not combine `menu` with `href` or `onclick` on the same row; use `action` for a trailing row menu.\n5. Keep `children`, `header`, `content`, `footer`, `banner`, and action snippets pure; they receive `SidebarApi`.\n6. Use `collapsible=\"icon\"` for icon rail behavior, `collapsible=\"offcanvas\"` for hidden desktop panels, and `collapsible=\"none\"` for fixed sidebars. Icon collapse automatically falls back to offcanvas when any data-driven row lacks an icon.\n7. Offcanvas sidebars reveal over the content from the screen edge by default when hidden; set `edgeReveal={false}` to disable that. A revealed hidden sidebar keeps its resize handle and dismisses through a small rectangular pointer tolerance.\n8. Set `keyboardShortcut={false}` when embedding Sidebar inside another shortcut-heavy surface.\n9. Sidebar owns navigation, resize mechanics, the lower application wall, and variant surface geometry. AppShell forwards its variant and composes PageShell inside that surface.\n10. Use `size` for typography, icon scale, and item height. Use `density` independently for section padding, gaps, and submenu spacing.\n11. Use `activityBar` for a persistent icon rail outside the panel (section switching, workspaces). Every item needs an `icon` and a `label`; the label is the accessible name and the tooltip. It is layout mode only: `mode=\"panel\"` renders the navigation panel alone. The rail does not change the panel by itself: keep the selected rail item in state from `onSelect`, mark it `isActive`, and either derive the Sidebar's `items` from it or, for an animated switch, give each rail item a view in `views` and set `view` from it.\n12. Use `expandOnHover` only with `collapsible=\"icon\"`. It is a temporary peek, not a toggle: the persisted collapsed state never changes, while the peeked panel renders with expanded semantics.\n13. Use `views` when the panel's contents change as the user moves through the app: sections switched from the activity bar or the route, and nested menus that open inside the panel. Key each view, set `parent` on nested ones, open them with a row's `view`, and drive `view` from state or the URL. Do not hand-animate `items` swaps.\n\n## Data Model\n\n### SidebarGroup\n- **label**: string - Group label, hidden in icon-collapsed mode.\n- **items**: SidebarMenuEntry[] - Menu rows.\n- **tree**: SidebarTreeNode[] - Recursive tree rows instead of menu items.\n- **action**: SidebarMenuActionDescriptor | SidebarMenuActionDescriptor[] | Snippet<[SidebarApi]> - Top-right group actions. Pass an array to pin several affordances (a `+` and a drag handle) to one group header; each renders as its own icon-only ghost button.\n- **collapsible**: boolean - Makes the group label a toggle.\n- **defaultOpen**: boolean - Initial collapsible group state.\n- **separator**: boolean - Divider before the group.\n\n### SidebarMenuEntry\n- **label**: string - Visible row label.\n- **icon**: SidebarIcon - Entasis icon snippet or string.\n- **iconColor**: Colors - Role tint for the leading icon, applied through `data-color`.\n- **iconVariant**: 'bare' | 'tile' - Leading icon treatment. `tile` paints a rounded square (`bg-color-muted text-color-muted-readable`) around the glyph, so per-project colour chips come from the role scale instead of hand-built markup.\n- **href**: string - Render as an anchor. Mutually exclusive with menu.\n- **onclick**: (event: MouseEvent) => void - Native click handler for button or anchor rows. Mutually exclusive with menu.\n- **isActive**: boolean - Adds active styling and `aria-current=\"page\"`.\n- **disabled**: boolean - Disables button rows and marks anchor rows disabled.\n- **badge**: string | number - Trailing count/status, hidden in icon mode.\n- **tooltip**: string - Entasis Tooltip content in icon mode. Defaults to label.\n- **items**: SidebarMenuSubEntry[] - Inline nested menu.\n- **collapsible**: boolean - Set false for an always-open submenu.\n- **defaultOpen**: boolean - Initial nested menu state.\n- **menu**: MenuItem[] - Popup menu opened from the full row. Mutually exclusive with href/onclick.\n- **view**: string - Key of the `views` entry the row opens, sliding it in; the row shows a trailing chevron. Mutually exclusive with href, menu and items.\n- **action**: SidebarMenuActionDescriptor | Snippet<[SidebarApi]> - Hover/focus trailing action.\n\n### SidebarView\nOne named panel content in `views`.\n- **label**: string - The view's name, shown on the back row of the views nested under it.\n- **parent**: string - Key of the view this one is nested under. A nested view opens with a back row to its parent (named \"Back, <parent label>\"), and on mobile a swipe toward the inline end goes back. A view without `parent` is a top-level section.\n- **items**: SidebarGroup[] / **content**: Snippet<[SidebarApi]> - The view's body.\n- **headerButton**, **search**, **headerMenu**, **header**, **footerButton**, **footerMenu**, **footer** - Header and footer props for this view. Each one left undefined comes from the parent view, then from the Sidebar's own prop; `null` removes an inherited one.\n\nChanging the view slides the two views side by side, like pages: a deeper view comes in from the inline end while the old one leaves to the start, a shallower one slides back the other way, and between views at the same depth (sections) the later one in `views` counts as forward. When both views get every header and footer prop from the same place, the header and footer stay still and only the menu slides; when a view changes any of them, the whole panel slides as one page. `api.view` reads the current view and `api.setView(key)` changes it from a snippet.\n\n### SidebarActivityBar\nIcon rail pinned to the outer edge of the sidebar, visible in every display state.\n- **items**: SidebarActivityBarItem[] - Items rendered from the top.\n- **footerItems**: SidebarActivityBarItem[] - Items pinned to the end of the column.\n- **header** / **footer**: Snippet - Custom content before the first item and after the pinned ones.\n- **width**: string (default '3rem') - Column thickness, published as `--sidebar-width-activity`.\n- **label**: string - Accessible name for the column landmark. Set it whenever the panel also renders navigation.\n- **onSelect**: ({ item, index }) => void - Fires after an item is activated. `index` counts `items` then `footerItems`.\n\n### SidebarActivityBarItem\n- **icon**: SidebarIcon (required) - Icon rendered in the square.\n- **label**: string (required) - Accessible name and default tooltip; the square shows no text.\n- **id**: string - Stable render key.\n- **href** / **target** / **rel** - Render an anchor instead of a button.\n- **onclick**: (event: MouseEvent) => void - Native click handler.\n- **isActive**: boolean - Adds active styling and `aria-current=\"page\"`.\n- **badge**: string | number | Snippet - Corner badge pinned to the outer top corner. An empty string renders a bare dot. A string or number badge joins the accessible name (`\"Alerts, 3\"`); a dot and a Snippet badge are decorative, so put their meaning in `label`.\n- **disabled**: boolean - Blocks activation and skips the item during keyboard navigation.\n- **tooltip**: string | false - Tooltip override; `false` suppresses it.\n\n### SidebarMenuButtonItem\nUse for `headerButton`, `footerButton`, or direct `<SidebarMenuButton />` rows.\n- **icon**: SidebarIcon - Leading logo/icon.\n- **avatar**: { src?: string; alt?: string; fallback?: string } - Leading avatar.\n- **variant**: 'default' | 'brand' | 'compact'.\n- **title**: string - Primary text.\n- **subtitle**: string - Secondary text.\n- **trailing**: SidebarIcon | false | SidebarMenuActionDescriptor - Trailing content. An icon is decorative; an action descriptor (`{ icon, label, onclick }`, the same shape as a group action) renders its own icon-only ghost button beside the row, so a workspace card can carry its own collapse control without a custom `header` snippet. Descriptor handlers are `onclick(event, api)`, so `api.toggle()` is reachable.\n- **href** / **onclick** / **menu** - Choose link, button, or popup behavior. `onclick(event, api)` receives the SidebarApi beside the event, so `api.toggle()` is reachable from the row itself.\n- **menuIconClass**: string - Class override for option icons inside the popup menu.\n\n## Props\n\n### State\n- **open**: boolean (bindable, default true) - Desktop expanded state.\n- **defaultOpen**: boolean (default true) - Initial desktop state when `open` is omitted.\n- **onOpenChange**: (open: boolean) => void - Called once for a library-originated desktop state change. Repeated requests and parent prop updates stay silent.\n- **onDisplayStateChange**: (state: SidebarDisplayState) => void - Called once for a library-originated semantic display-state change.\n- **view**: string (bindable) - Key of the view on screen when `views` is set. Defaults to `defaultView`, then the first view.\n- **defaultView**: string - Initial view when `view` is omitted.\n- **onViewChange**: (view: string) => void - Called once for a library-originated view change: a view row, a back row, a swipe. Parent prop updates stay silent; with a route-driven `view`, navigate here.\n- **api.displayState**: 'expanded' | 'collapsed' | 'hidden' - Semantic desktop state; hidden means closed offcanvas. A hover peek does not change it.\n- **api.isPeeking**: boolean - True while a hover peek renders the collapsed panel at full width. Read it alongside `displayState` when a snippet hides content in icon mode.\n- **keyboardShortcut**: string | false (default 'b') - Ctrl/Cmd shortcut key.\n\n### Layout\n- **side**: 'left' | 'right' - Desktop and mobile side.\n- **variant**: 'admin' | 'floating' | 'inset' | 'split' | 'framed' - Sidebar geometry. `framed` is the admin geometry for a sidebar hosted inside a raised card (AppShell variant framed), with a `surface-recessed` well. `admin` renders the conventional full-height navigation column; `inset` integrates navigation into the lower wall with an inset content surface; `split` renders detached sidebar and content surfaces.\n- **size**: 'small' | 'normal' | 'large' (default 'normal') - Typography, icon, avatar, badge, leading-media, item-height, and search-height scale.\n- **iconSize**: 'small' | 'normal' | 'large' - Icon and leading-media scale inside the panel on its own; defaults to `size`. Menu rows, sub rows, group labels and the header button follow it; the activity bar keeps `size`.\n- **activeVariant**: 'soft' | 'outline' | 'solid' (default 'soft') - How active rows are painted. `soft` is the shared selected recipe (`selectedSoft`: `bg-selected-muted text-selected-muted-readable`), `solid` its loud counterpart (`selectedSolid`: `bg-selected text-selected-contrast`), `outline` a bordered surface card (`bg-surface border border-neutral-muted text-neutral`) that reads as a raised card on a tinted well. Each row carries the choice as `data-active-variant`, so no descendant selector is needed to restyle selection.\n- **density**: 'compact' | 'normal' | 'comfortable' (default 'normal') - Section padding, group padding, gaps, horizontal inset, and submenu spacing.\n- **collapsible**: 'offcanvas' | 'icon' | 'none' - Collapse behavior. Icon mode requires icons on every data-driven row and otherwise resolves to offcanvas.\n- **collapseIcon**: DisclosureIndicator \u2014 'chevron' | 'plus-minus' | 'none' (default 'chevron') - Disclosure indicator drawn on collapsible menu rows. 'none' renders no indicator.\n- **mode**: 'layout' | 'panel' - Full resizing layout or only the visible navigation panel.\n- **frame**: 'viewport' | 'contained' - Standalone Sidebar positioning. Viewport mode uses Theme's dynamic window-height token; contained mode fills a positioned parent.\n- **width**: string - Expanded width.\n- **widthIcon**: string - Icon-collapsed width.\n- **widthMobile**: string - Mobile drawer width.\n- **rail**: boolean | 'line' | 'thumb' - Edge toggle rail. `true` keeps the thin line style; `thumb` renders a short visible handle with the same full-height hitbox. The appearance is preserved when the rail shares the resize control.\n- **activityBar**: SidebarActivityBar - Icon rail pinned outside the panel, in layout mode only (`mode=\"panel\"` renders the panel alone and ignores it). It never slides off screen: only the panel takes the offcanvas offset, and the reserved layout column is the panel width plus the rail width. It wears the surface of the variant's panel: a hairline column on the canvas for `admin`, the recessed well for `framed`, borderless on the canvas for `inset`, and a card of its own (the panel's radius, edge and gutter) for `floating` and `split`. On mobile it renders as a horizontal row at the top of the drawer.\n- **expandOnHover**: boolean (default false) - With `collapsible=\"icon\"`, hovering or focusing into the collapsed panel expands it to `width` over the page (`data-peek=\"true\"`) while the reserved column stays at `widthIcon`, so page content does not reflow. The persisted collapsed state is untouched, and the peeked panel renders exactly like an expanded one: group headers, badges, search, inline submenus, and inline tree branches all come back, and the rail or resize handle travels to its inner edge.\n- **edgeReveal**: boolean (default true) - Pointer/focus edge preview for hidden offcanvas sidebars. Hover reveal overlays content, remains resizable when configured, and re-hides after the pointer leaves its small rectangular tolerance. Dragging the sidebar closed suppresses immediate hover reopening until the pointer leaves the edge trigger; toggle/click opens persistently.\n- **resizable**: boolean | SidebarResizableOptions - Enables pointer and keyboard resizing while expanded, icon-collapsed, or temporarily edge-revealed. By default, collapse requires dragging 75% of `minWidth` beyond the minimum; override `collapseThreshold` for a custom boundary. Use `storageKey` to restore and persist the expanded width across sessions.\n - `onWidthChange({ width, isUserInteraction })` reports every expanded-width change with one named payload: continuously while the user resizes (`isUserInteraction: true`) and once when a stored width is restored (`isUserInteraction: false`).\n\n### Content\n- **items**: SidebarGroup[] - Data-driven body navigation.\n- **views**: Record<string, SidebarView> - Named panel contents, one on screen at a time, replacing `items` and `content`. See SidebarView.\n- **headerButton** / **footerButton**: SidebarMenuButtonItem - Sticky large rows.\n- **search**: SidebarSearch - Header search input; use its native `oninput` handler.\n- **headerMenu** / **footerMenu**: SidebarMenuEntry[] - Sticky quick menus.\n- Menu entries and nested entries accept `size: 'small' | 'normal' | 'large'` for row geometry.\n- **header**, **content**, **footer**, **children**, **banner**: Snippet<[SidebarApi]> - Escape hatches. The `header` snippet renders **first** in the header region, above `headerButton`, `search` and `headerMenu`.\n\n### Styling\n- **class**: string - Classes applied to the Sidebar root.\n- **theme**: SidebarThemeProps - Semantic part overrides such as `panel`, `header`, `nav`, `footer`, menu, search, rail, and mobile drawer parts. Every part, with the element it lands on, its variants and their default classes, is listed in the entasis skill's `theme-parts/sidebar.md`; the registry key is `sidebar`.\n\n## Motion\n\n- **motion** theme slot: the y-axis slide shared by collapsible groups, inline submenus, and\n tree branches. Takes `in` / `out` slide params plus a `duration` / `easing` motion token.\n- Ladder: `<Theme components={{ sidebar: { motion } }}>` \u2192 `setSidebarTheme({ motion })` \u2192\n `theme.motion`. Reduced motion collapses it to 0.\n- The `view` variant (`part: 'view'`) is the pager between views: `in.x` / `out.x` is how far a view travels (default `'100%'`: the two views slide side by side like pages) while it fades between `opacity` (default 0) and 1, at the `slow` duration on the `enter` easing. The back swipe moves the same layers the view change would, with the same travel and opacity. Reduced motion makes the switch instant while a swipe still follows the finger.\n\n## Restyle recipes\n\nThe five asks that come up first, as the override to copy. Each one is rendered and asserted by\n`sidebar-recipes.svelte.test.ts`, so it cannot drift from the component. One rule behind them: a\ndefault written under a variant prefix (`data-[active-variant=solid]:data-active:bg-selected`,\n`data-[side=left]:border-r`) is only replaced by an override carrying the same prefixes; an\nunprefixed class coexists with it and loses on specificity. `theme-parts/sidebar.md` shows every\ndefault verbatim, prefixes included.\n\n- **Dark panel.** `dark` scopes the dark theme's variables to the panel, so every neutral ink inside\n flips with it (every theme also emits its variables on `.<name>`, so the class scopes the dark theme to one subtree); needs a theme named `dark`, which the documented setup declares.\n `theme={{ panel: { base: 'dark bg-slate-900' }, mobilePanel: { base: 'dark bg-slate-900' } }}`\n- **Active row in your colour.** `activeVariant=\"solid\"` plus the same prefix chain as the default:\n `theme={{ menuButton: { base: 'rounded-full', activeVariant: { solid: 'data-[active-variant=solid]:data-active:bg-indigo-600 data-[active-variant=solid]:data-active:text-white' } } }}`\n- **No hover change.** The overlay is a `::before` and the default also brightens the ink on hover:\n `theme={{ menuButton: { base: 'state-layer-none hover:text-inherit' }, subButton: { base: 'state-layer-none hover:text-neutral/70' } }}`\n- **Flat panel.** The edge is a prefixed `border-r` / `border-l` on the admin variant, the shadow a\n `raised-*` on the floating ones:\n `theme={{ panel: { base: 'raised-none', variant: { admin: 'data-[side=left]:border-r-0 data-[side=right]:border-l-0' } } }}`\n- **Row height.** A plain height beats the compound `h-control-*`: `theme={{ menuButton: { base: 'h-11' } }}`\n- **Bigger icons.** A prop, not a theme: `iconSize=\"large\"`.\n\n## Accessibility\n\n- The body navigation renders inside a named `<nav>` landmark (`data-sidebar=\"nav\"`), so assistive tech can jump straight to it and tell it apart from the activity bar's own landmark.\n- Active links set `aria-current=\"page\"`.\n- Collapsible rows and groups set `aria-expanded`.\n- Disabled buttons use `disabled`; disabled links omit `href`, use `aria-disabled` and `tabindex=-1`, and block activation.\n- Mobile drawer includes a backdrop button labelled \"Close Sidebar\".\n- Icon-collapsed rows keep their labels mounted and visually fade them, preserving accessible names and stable icon geometry.\n- Search, group controls, actions, and nested rows become inert before collapse can remove or hide them; focus returns to the owning visible row.\n- Nested groups, tree branches, and inline submenus use reversible height transitions for open, close, and sidebar-collapse changes.\n- Tree roots use menu-row styling and nested tree nodes use submenu-row styling. In desktop icon mode, root folders open a PopupMenu and descendants remain navigable through recursive Menu submenu popovers; root leaves retain direct navigation and tooltips.\n- When `rail` and `resizable` are both enabled, one edge control owns click-to-toggle, drag resize, and keyboard resize without overlapping hitboxes.\n- Hidden offcanvas sidebars keep that combined edge control while temporarily revealed. Resizing does not pin the sidebar open; leaving the panel, trigger, and handle tolerance re-hides it without discarding the configured width.\n- Both peeks (edge reveal and `expandOnHover`) stay open while focus is inside the panel or while an overlay opened from inside it is open, including nested submenus. They release about 120ms after the pointer, focus, and every such overlay are gone.\n- The activity bar is its own `<nav>` landmark with a `<ul>` of items, a roving tabindex, and ArrowUp/ArrowDown/Home/End navigation that loops and skips disabled items. Tab lands on the `isActive` item. Each square takes its accessible name from `label`, with a string or number `badge` appended to it, and shows `label` as a tooltip on hover and focus.\n- A hidden offcanvas panel is `inert`, so Tab never lands in a panel parked off screen; a peek makes it interactive again.\n- Views: when focus sat in the view being replaced, it lands on the back row after going deeper and on the row that opened the view after coming back. A view change from outside the panel (a route) leaves focus where it is. The back swipe is a shortcut; the back row stays the accessible path.\n\n## Notes\n\n- Dropdown menus use Entasis `PopupMenu` and `MenuItem[]`.\n- The component uses semantic Entasis tokens. Do not add shadcn `sidebar-*` color tokens.\n- Snippet icons from `entasis/icons/*` are the preferred icon format.\n";
|
|
@@ -53,8 +53,9 @@ recursive tree groups, header/footer rows, search, actions, and snippet escape h
|
|
|
53
53
|
8. Set \`keyboardShortcut={false}\` when embedding Sidebar inside another shortcut-heavy surface.
|
|
54
54
|
9. Sidebar owns navigation, resize mechanics, the lower application wall, and variant surface geometry. AppShell forwards its variant and composes PageShell inside that surface.
|
|
55
55
|
10. Use \`size\` for typography, icon scale, and item height. Use \`density\` independently for section padding, gaps, and submenu spacing.
|
|
56
|
-
11. Use \`activityBar\` for a persistent icon rail outside the panel (section switching, workspaces). Every item needs an \`icon\` and a \`label\`; the label is the accessible name and the tooltip. It is layout mode only: \`mode="panel"\` renders the navigation panel alone.
|
|
56
|
+
11. Use \`activityBar\` for a persistent icon rail outside the panel (section switching, workspaces). Every item needs an \`icon\` and a \`label\`; the label is the accessible name and the tooltip. It is layout mode only: \`mode="panel"\` renders the navigation panel alone. The rail does not change the panel by itself: keep the selected rail item in state from \`onSelect\`, mark it \`isActive\`, and either derive the Sidebar's \`items\` from it or, for an animated switch, give each rail item a view in \`views\` and set \`view\` from it.
|
|
57
57
|
12. Use \`expandOnHover\` only with \`collapsible="icon"\`. It is a temporary peek, not a toggle: the persisted collapsed state never changes, while the peeked panel renders with expanded semantics.
|
|
58
|
+
13. Use \`views\` when the panel's contents change as the user moves through the app: sections switched from the activity bar or the route, and nested menus that open inside the panel. Key each view, set \`parent\` on nested ones, open them with a row's \`view\`, and drive \`view\` from state or the URL. Do not hand-animate \`items\` swaps.
|
|
58
59
|
|
|
59
60
|
## Data Model
|
|
60
61
|
|
|
@@ -82,8 +83,18 @@ recursive tree groups, header/footer rows, search, actions, and snippet escape h
|
|
|
82
83
|
- **collapsible**: boolean - Set false for an always-open submenu.
|
|
83
84
|
- **defaultOpen**: boolean - Initial nested menu state.
|
|
84
85
|
- **menu**: MenuItem[] - Popup menu opened from the full row. Mutually exclusive with href/onclick.
|
|
86
|
+
- **view**: string - Key of the \`views\` entry the row opens, sliding it in; the row shows a trailing chevron. Mutually exclusive with href, menu and items.
|
|
85
87
|
- **action**: SidebarMenuActionDescriptor | Snippet<[SidebarApi]> - Hover/focus trailing action.
|
|
86
88
|
|
|
89
|
+
### SidebarView
|
|
90
|
+
One named panel content in \`views\`.
|
|
91
|
+
- **label**: string - The view's name, shown on the back row of the views nested under it.
|
|
92
|
+
- **parent**: string - Key of the view this one is nested under. A nested view opens with a back row to its parent (named "Back, <parent label>"), and on mobile a swipe toward the inline end goes back. A view without \`parent\` is a top-level section.
|
|
93
|
+
- **items**: SidebarGroup[] / **content**: Snippet<[SidebarApi]> - The view's body.
|
|
94
|
+
- **headerButton**, **search**, **headerMenu**, **header**, **footerButton**, **footerMenu**, **footer** - Header and footer props for this view. Each one left undefined comes from the parent view, then from the Sidebar's own prop; \`null\` removes an inherited one.
|
|
95
|
+
|
|
96
|
+
Changing the view slides the two views side by side, like pages: a deeper view comes in from the inline end while the old one leaves to the start, a shallower one slides back the other way, and between views at the same depth (sections) the later one in \`views\` counts as forward. When both views get every header and footer prop from the same place, the header and footer stay still and only the menu slides; when a view changes any of them, the whole panel slides as one page. \`api.view\` reads the current view and \`api.setView(key)\` changes it from a snippet.
|
|
97
|
+
|
|
87
98
|
### SidebarActivityBar
|
|
88
99
|
Icon rail pinned to the outer edge of the sidebar, visible in every display state.
|
|
89
100
|
- **items**: SidebarActivityBarItem[] - Items rendered from the top.
|
|
@@ -122,6 +133,9 @@ Use for \`headerButton\`, \`footerButton\`, or direct \`<SidebarMenuButton />\`
|
|
|
122
133
|
- **defaultOpen**: boolean (default true) - Initial desktop state when \`open\` is omitted.
|
|
123
134
|
- **onOpenChange**: (open: boolean) => void - Called once for a library-originated desktop state change. Repeated requests and parent prop updates stay silent.
|
|
124
135
|
- **onDisplayStateChange**: (state: SidebarDisplayState) => void - Called once for a library-originated semantic display-state change.
|
|
136
|
+
- **view**: string (bindable) - Key of the view on screen when \`views\` is set. Defaults to \`defaultView\`, then the first view.
|
|
137
|
+
- **defaultView**: string - Initial view when \`view\` is omitted.
|
|
138
|
+
- **onViewChange**: (view: string) => void - Called once for a library-originated view change: a view row, a back row, a swipe. Parent prop updates stay silent; with a route-driven \`view\`, navigate here.
|
|
125
139
|
- **api.displayState**: 'expanded' | 'collapsed' | 'hidden' - Semantic desktop state; hidden means closed offcanvas. A hover peek does not change it.
|
|
126
140
|
- **api.isPeeking**: boolean - True while a hover peek renders the collapsed panel at full width. Read it alongside \`displayState\` when a snippet hides content in icon mode.
|
|
127
141
|
- **keyboardShortcut**: string | false (default 'b') - Ctrl/Cmd shortcut key.
|
|
@@ -141,7 +155,7 @@ Use for \`headerButton\`, \`footerButton\`, or direct \`<SidebarMenuButton />\`
|
|
|
141
155
|
- **widthIcon**: string - Icon-collapsed width.
|
|
142
156
|
- **widthMobile**: string - Mobile drawer width.
|
|
143
157
|
- **rail**: boolean | 'line' | 'thumb' - Edge toggle rail. \`true\` keeps the thin line style; \`thumb\` renders a short visible handle with the same full-height hitbox. The appearance is preserved when the rail shares the resize control.
|
|
144
|
-
- **activityBar**: SidebarActivityBar - Icon rail pinned outside the panel, in layout mode only (\`mode="panel"\` renders the panel alone and ignores it). It never slides off screen: only the panel takes the offcanvas offset, and the reserved layout column is the panel width plus the rail width. On mobile it renders as a horizontal row at the top of the drawer.
|
|
158
|
+
- **activityBar**: SidebarActivityBar - Icon rail pinned outside the panel, in layout mode only (\`mode="panel"\` renders the panel alone and ignores it). It never slides off screen: only the panel takes the offcanvas offset, and the reserved layout column is the panel width plus the rail width. It wears the surface of the variant's panel: a hairline column on the canvas for \`admin\`, the recessed well for \`framed\`, borderless on the canvas for \`inset\`, and a card of its own (the panel's radius, edge and gutter) for \`floating\` and \`split\`. On mobile it renders as a horizontal row at the top of the drawer.
|
|
145
159
|
- **expandOnHover**: boolean (default false) - With \`collapsible="icon"\`, hovering or focusing into the collapsed panel expands it to \`width\` over the page (\`data-peek="true"\`) while the reserved column stays at \`widthIcon\`, so page content does not reflow. The persisted collapsed state is untouched, and the peeked panel renders exactly like an expanded one: group headers, badges, search, inline submenus, and inline tree branches all come back, and the rail or resize handle travels to its inner edge.
|
|
146
160
|
- **edgeReveal**: boolean (default true) - Pointer/focus edge preview for hidden offcanvas sidebars. Hover reveal overlays content, remains resizable when configured, and re-hides after the pointer leaves its small rectangular tolerance. Dragging the sidebar closed suppresses immediate hover reopening until the pointer leaves the edge trigger; toggle/click opens persistently.
|
|
147
161
|
- **resizable**: boolean | SidebarResizableOptions - Enables pointer and keyboard resizing while expanded, icon-collapsed, or temporarily edge-revealed. By default, collapse requires dragging 75% of \`minWidth\` beyond the minimum; override \`collapseThreshold\` for a custom boundary. Use \`storageKey\` to restore and persist the expanded width across sessions.
|
|
@@ -149,6 +163,7 @@ Use for \`headerButton\`, \`footerButton\`, or direct \`<SidebarMenuButton />\`
|
|
|
149
163
|
|
|
150
164
|
### Content
|
|
151
165
|
- **items**: SidebarGroup[] - Data-driven body navigation.
|
|
166
|
+
- **views**: Record<string, SidebarView> - Named panel contents, one on screen at a time, replacing \`items\` and \`content\`. See SidebarView.
|
|
152
167
|
- **headerButton** / **footerButton**: SidebarMenuButtonItem - Sticky large rows.
|
|
153
168
|
- **search**: SidebarSearch - Header search input; use its native \`oninput\` handler.
|
|
154
169
|
- **headerMenu** / **footerMenu**: SidebarMenuEntry[] - Sticky quick menus.
|
|
@@ -165,6 +180,7 @@ Use for \`headerButton\`, \`footerButton\`, or direct \`<SidebarMenuButton />\`
|
|
|
165
180
|
tree branches. Takes \`in\` / \`out\` slide params plus a \`duration\` / \`easing\` motion token.
|
|
166
181
|
- Ladder: \`<Theme components={{ sidebar: { motion } }}>\` → \`setSidebarTheme({ motion })\` →
|
|
167
182
|
\`theme.motion\`. Reduced motion collapses it to 0.
|
|
183
|
+
- The \`view\` variant (\`part: 'view'\`) is the pager between views: \`in.x\` / \`out.x\` is how far a view travels (default \`'100%'\`: the two views slide side by side like pages) while it fades between \`opacity\` (default 0) and 1, at the \`slow\` duration on the \`enter\` easing. The back swipe moves the same layers the view change would, with the same travel and opacity. Reduced motion makes the switch instant while a swipe still follows the finger.
|
|
168
184
|
|
|
169
185
|
## Restyle recipes
|
|
170
186
|
|
|
@@ -204,6 +220,7 @@ default verbatim, prefixes included.
|
|
|
204
220
|
- Both peeks (edge reveal and \`expandOnHover\`) stay open while focus is inside the panel or while an overlay opened from inside it is open, including nested submenus. They release about 120ms after the pointer, focus, and every such overlay are gone.
|
|
205
221
|
- The activity bar is its own \`<nav>\` landmark with a \`<ul>\` of items, a roving tabindex, and ArrowUp/ArrowDown/Home/End navigation that loops and skips disabled items. Tab lands on the \`isActive\` item. Each square takes its accessible name from \`label\`, with a string or number \`badge\` appended to it, and shows \`label\` as a tooltip on hover and focus.
|
|
206
222
|
- A hidden offcanvas panel is \`inert\`, so Tab never lands in a panel parked off screen; a peek makes it interactive again.
|
|
223
|
+
- Views: when focus sat in the view being replaced, it lands on the back row after going deeper and on the row that opened the view after coming back. A view change from outside the panel (a route) leaves focus where it is. The back swipe is a shortcut; the back row stays the accessible path.
|
|
207
224
|
|
|
208
225
|
## Notes
|
|
209
226
|
|
|
@@ -80,6 +80,10 @@ export type SidebarApi = {
|
|
|
80
80
|
setDisplayState: (state: SidebarDisplayState) => void;
|
|
81
81
|
/** Set the mobile drawer open state. */
|
|
82
82
|
setOpenMobile: (open: boolean) => void;
|
|
83
|
+
/** The view on screen when `views` is set, undefined otherwise. */
|
|
84
|
+
readonly view: string | undefined;
|
|
85
|
+
/** Show another view. Its depth against the current one picks the slide direction. */
|
|
86
|
+
setView: (view: string) => void;
|
|
83
87
|
};
|
|
84
88
|
export type SidebarActivityBarItem = {
|
|
85
89
|
/** Stable identity used as the render key. Defaults to the label and index. */
|
|
@@ -206,10 +210,15 @@ type SidebarMenuEntryBase = {
|
|
|
206
210
|
action?: Snippet<[SidebarApi]> | SidebarMenuActionDescriptor;
|
|
207
211
|
};
|
|
208
212
|
type SidebarMenuEntryNavigation = SidebarMenuEntryBase & {
|
|
209
|
-
/** Link href. Mutually exclusive with menu. */
|
|
213
|
+
/** Link href. Mutually exclusive with menu and view. */
|
|
210
214
|
href?: string;
|
|
211
215
|
/** Native click handler. Mutually exclusive with menu. */
|
|
212
216
|
onclick?: (event: MouseEvent) => void;
|
|
217
|
+
/**
|
|
218
|
+
* Key of the `views` entry this row opens, sliding it in. Mutually exclusive with href, menu,
|
|
219
|
+
* and items.
|
|
220
|
+
*/
|
|
221
|
+
view?: string;
|
|
213
222
|
/** Popup menu rows own the whole trigger, so they cannot also navigate. */
|
|
214
223
|
menu?: never;
|
|
215
224
|
};
|
|
@@ -218,6 +227,7 @@ type SidebarMenuEntryMenu = SidebarMenuEntryBase & {
|
|
|
218
227
|
menu: MenuItem[];
|
|
219
228
|
href?: never;
|
|
220
229
|
onclick?: never;
|
|
230
|
+
view?: never;
|
|
221
231
|
};
|
|
222
232
|
export type SidebarMenuEntry = SidebarMenuEntryNavigation | SidebarMenuEntryMenu;
|
|
223
233
|
export type SidebarSearch = {
|
|
@@ -250,6 +260,38 @@ export type SidebarTreeNode = {
|
|
|
250
260
|
/** Child nodes. */
|
|
251
261
|
children?: SidebarTreeNode[];
|
|
252
262
|
};
|
|
263
|
+
/**
|
|
264
|
+
* One panel content in `views`. Header and footer props left undefined come from the parent view,
|
|
265
|
+
* then from the Sidebar's props; `null` removes an inherited one.
|
|
266
|
+
*/
|
|
267
|
+
export type SidebarView = {
|
|
268
|
+
/** The view's name, shown on the back row of the views nested under it. */
|
|
269
|
+
label?: string;
|
|
270
|
+
/**
|
|
271
|
+
* Key of the view this one is nested under. A nested view opens with a back row to it, and
|
|
272
|
+
* on mobile a swipe toward the inline end goes back. A view without a parent is a top-level
|
|
273
|
+
* section.
|
|
274
|
+
*/
|
|
275
|
+
parent?: string;
|
|
276
|
+
/** Groups rendered in the scrollable body. */
|
|
277
|
+
items?: SidebarGroup[];
|
|
278
|
+
/** Custom scrollable body. Overrides items. */
|
|
279
|
+
content?: Snippet<[SidebarApi]>;
|
|
280
|
+
/** Sticky top large menu row. */
|
|
281
|
+
headerButton?: SidebarMenuButtonItem | null;
|
|
282
|
+
/** Search box rendered in the header. */
|
|
283
|
+
search?: SidebarSearch | null;
|
|
284
|
+
/** Pinned menu rendered in the header. */
|
|
285
|
+
headerMenu?: SidebarMenuEntry[] | null;
|
|
286
|
+
/** Sticky top custom content. */
|
|
287
|
+
header?: Snippet<[SidebarApi]> | null;
|
|
288
|
+
/** Sticky bottom large menu row. */
|
|
289
|
+
footerButton?: SidebarMenuButtonItem | null;
|
|
290
|
+
/** Pinned menu rendered in the footer. */
|
|
291
|
+
footerMenu?: SidebarMenuEntry[] | null;
|
|
292
|
+
/** Sticky bottom custom content. */
|
|
293
|
+
footer?: Snippet<[SidebarApi]> | null;
|
|
294
|
+
};
|
|
253
295
|
export type SidebarGroup = {
|
|
254
296
|
/** Group label. Hidden in icon-collapsed mode. */
|
|
255
297
|
label?: string;
|
|
@@ -378,6 +420,19 @@ type SidebarOwnProps = {
|
|
|
378
420
|
activityBar?: SidebarActivityBar;
|
|
379
421
|
/** Items rendered in the scrollable body. Each item is a labelled sidebar group. */
|
|
380
422
|
items?: SidebarGroup[];
|
|
423
|
+
/**
|
|
424
|
+
* Named panel contents, one on screen at a time, replacing `items` and `content`. Changing
|
|
425
|
+
* the view slides between them: deeper views push in, shallower ones slide back, sections at
|
|
426
|
+
* the same depth crossfade. Header and footer props a view leaves out come from its parent,
|
|
427
|
+
* then from the Sidebar's own props.
|
|
428
|
+
*/
|
|
429
|
+
views?: Record<string, SidebarView>;
|
|
430
|
+
/** Bindable key of the view on screen. Defaults to `defaultView`, then the first view. */
|
|
431
|
+
view?: string;
|
|
432
|
+
/** Initial view when `view` is omitted. */
|
|
433
|
+
defaultView?: string;
|
|
434
|
+
/** Fires once for each library-originated view change: a view row, a back row, a swipe. */
|
|
435
|
+
onViewChange?: (view: string) => void;
|
|
381
436
|
/** Classes applied to the outer wrapper. */
|
|
382
437
|
class?: string;
|
|
383
438
|
/** Indicator style for collapsible menu items. */
|
|
@@ -6,7 +6,9 @@ type SidebarStateOptions = {
|
|
|
6
6
|
readonly side: SidebarSide;
|
|
7
7
|
readonly collapsible: SidebarCollapsible;
|
|
8
8
|
readonly peeking: boolean;
|
|
9
|
+
readonly view: string | undefined;
|
|
9
10
|
setDisplayState: (state: SidebarDisplayState) => void;
|
|
11
|
+
setView: (view: string) => void;
|
|
10
12
|
};
|
|
11
13
|
export declare class SidebarStateController {
|
|
12
14
|
private options;
|
|
@@ -19,6 +21,8 @@ export declare class SidebarStateController {
|
|
|
19
21
|
get displayState(): SidebarDisplayState;
|
|
20
22
|
get collapsibleState(): SidebarCollapsible | '';
|
|
21
23
|
get isMobile(): boolean;
|
|
24
|
+
get view(): string | undefined;
|
|
25
|
+
setView: (view: string) => void;
|
|
22
26
|
get side(): SidebarSide;
|
|
23
27
|
get collapsible(): SidebarCollapsible;
|
|
24
28
|
/**
|
|
@@ -39,7 +39,11 @@ function createSidebarApi(controller) {
|
|
|
39
39
|
toggle: () => controller.toggle(),
|
|
40
40
|
setOpen: (open) => controller.setOpen(open),
|
|
41
41
|
setDisplayState: (state) => controller.setDisplayState(state),
|
|
42
|
-
setOpenMobile: (open) => controller.setOpenMobile(open)
|
|
42
|
+
setOpenMobile: (open) => controller.setOpenMobile(open),
|
|
43
|
+
get view() {
|
|
44
|
+
return controller.view;
|
|
45
|
+
},
|
|
46
|
+
setView: (view) => controller.setView(view)
|
|
43
47
|
};
|
|
44
48
|
}
|
|
45
49
|
export class SidebarStateController {
|
|
@@ -89,6 +93,10 @@ export class SidebarStateController {
|
|
|
89
93
|
get isMobile() {
|
|
90
94
|
return this.mobileQuery.current;
|
|
91
95
|
}
|
|
96
|
+
get view() {
|
|
97
|
+
return this.options.view;
|
|
98
|
+
}
|
|
99
|
+
setView = (view) => this.options.setView(view);
|
|
92
100
|
get side() {
|
|
93
101
|
return this.options.side;
|
|
94
102
|
}
|
|
@@ -1,7 +1,43 @@
|
|
|
1
1
|
import { type InferComponentTheme } from '../../utils/cva/index.js';
|
|
2
|
-
export declare const defaultSidebarMotion: import("../../utils/motion/index.js").MotionResolver<
|
|
2
|
+
export declare const defaultSidebarMotion: import("../../utils/motion/index.js").MotionResolver<{
|
|
3
|
+
readonly part: {
|
|
4
|
+
readonly collapse: {};
|
|
5
|
+
readonly view: {
|
|
6
|
+
readonly in: {
|
|
7
|
+
readonly axis: "x";
|
|
8
|
+
readonly x: "100%";
|
|
9
|
+
readonly opacity: 0;
|
|
10
|
+
};
|
|
11
|
+
readonly out: {
|
|
12
|
+
readonly axis: "x";
|
|
13
|
+
readonly x: "100%";
|
|
14
|
+
readonly opacity: 0;
|
|
15
|
+
};
|
|
16
|
+
readonly duration: "slow";
|
|
17
|
+
readonly easing: "enter";
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
}>;
|
|
3
21
|
export declare const sidebarTheme: {
|
|
4
|
-
motion: import("../../utils/motion/index.js").MotionResolver<
|
|
22
|
+
motion: import("../../utils/motion/index.js").MotionResolver<{
|
|
23
|
+
readonly part: {
|
|
24
|
+
readonly collapse: {};
|
|
25
|
+
readonly view: {
|
|
26
|
+
readonly in: {
|
|
27
|
+
readonly axis: "x";
|
|
28
|
+
readonly x: "100%";
|
|
29
|
+
readonly opacity: 0;
|
|
30
|
+
};
|
|
31
|
+
readonly out: {
|
|
32
|
+
readonly axis: "x";
|
|
33
|
+
readonly x: "100%";
|
|
34
|
+
readonly opacity: 0;
|
|
35
|
+
};
|
|
36
|
+
readonly duration: "slow";
|
|
37
|
+
readonly easing: "enter";
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
}>;
|
|
5
41
|
root: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
6
42
|
variant: {
|
|
7
43
|
admin: string;
|
|
@@ -54,6 +90,13 @@ export declare const sidebarTheme: {
|
|
|
54
90
|
comfortable: string;
|
|
55
91
|
};
|
|
56
92
|
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
93
|
+
viewStage: (props?: import("../../utils/cva/types.js").CVAClassProp | undefined) => string;
|
|
94
|
+
viewLayer: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
95
|
+
swipe: {
|
|
96
|
+
true: string;
|
|
97
|
+
false: null;
|
|
98
|
+
};
|
|
99
|
+
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
57
100
|
footer: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
58
101
|
density: {
|
|
59
102
|
compact: string;
|
|
@@ -306,6 +349,17 @@ export declare const sidebarTheme: {
|
|
|
306
349
|
vertical: string;
|
|
307
350
|
horizontal: string;
|
|
308
351
|
};
|
|
352
|
+
variant: {
|
|
353
|
+
admin: string;
|
|
354
|
+
floating: string;
|
|
355
|
+
inset: string;
|
|
356
|
+
split: string;
|
|
357
|
+
framed: string;
|
|
358
|
+
};
|
|
359
|
+
placement: {
|
|
360
|
+
positioned: string;
|
|
361
|
+
static: string;
|
|
362
|
+
};
|
|
309
363
|
density: {
|
|
310
364
|
compact: string;
|
|
311
365
|
normal: string;
|
|
@@ -472,7 +526,25 @@ export declare const sidebarTheme: {
|
|
|
472
526
|
export type SidebarTheme = typeof sidebarTheme;
|
|
473
527
|
export type SidebarThemeProps = InferComponentTheme<SidebarTheme>;
|
|
474
528
|
export declare const setSidebarTheme: (theme: InferComponentTheme<{
|
|
475
|
-
motion: import("../../utils/motion/index.js").MotionResolver<
|
|
529
|
+
motion: import("../../utils/motion/index.js").MotionResolver<{
|
|
530
|
+
readonly part: {
|
|
531
|
+
readonly collapse: {};
|
|
532
|
+
readonly view: {
|
|
533
|
+
readonly in: {
|
|
534
|
+
readonly axis: "x";
|
|
535
|
+
readonly x: "100%";
|
|
536
|
+
readonly opacity: 0;
|
|
537
|
+
};
|
|
538
|
+
readonly out: {
|
|
539
|
+
readonly axis: "x";
|
|
540
|
+
readonly x: "100%";
|
|
541
|
+
readonly opacity: 0;
|
|
542
|
+
};
|
|
543
|
+
readonly duration: "slow";
|
|
544
|
+
readonly easing: "enter";
|
|
545
|
+
};
|
|
546
|
+
};
|
|
547
|
+
}>;
|
|
476
548
|
root: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
477
549
|
variant: {
|
|
478
550
|
admin: string;
|
|
@@ -525,6 +597,13 @@ export declare const setSidebarTheme: (theme: InferComponentTheme<{
|
|
|
525
597
|
comfortable: string;
|
|
526
598
|
};
|
|
527
599
|
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
600
|
+
viewStage: (props?: import("../../utils/cva/types.js").CVAClassProp | undefined) => string;
|
|
601
|
+
viewLayer: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
602
|
+
swipe: {
|
|
603
|
+
true: string;
|
|
604
|
+
false: null;
|
|
605
|
+
};
|
|
606
|
+
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
528
607
|
footer: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
529
608
|
density: {
|
|
530
609
|
compact: string;
|
|
@@ -777,6 +856,17 @@ export declare const setSidebarTheme: (theme: InferComponentTheme<{
|
|
|
777
856
|
vertical: string;
|
|
778
857
|
horizontal: string;
|
|
779
858
|
};
|
|
859
|
+
variant: {
|
|
860
|
+
admin: string;
|
|
861
|
+
floating: string;
|
|
862
|
+
inset: string;
|
|
863
|
+
split: string;
|
|
864
|
+
framed: string;
|
|
865
|
+
};
|
|
866
|
+
placement: {
|
|
867
|
+
positioned: string;
|
|
868
|
+
static: string;
|
|
869
|
+
};
|
|
780
870
|
density: {
|
|
781
871
|
compact: string;
|
|
782
872
|
normal: string;
|
|
@@ -941,7 +1031,25 @@ export declare const setSidebarTheme: (theme: InferComponentTheme<{
|
|
|
941
1031
|
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
942
1032
|
}>) => void;
|
|
943
1033
|
export declare const useSidebarTheme: import("../../utils/cva/theme.js").UseComponentTheme<{
|
|
944
|
-
motion: import("../../utils/motion/index.js").MotionResolver<
|
|
1034
|
+
motion: import("../../utils/motion/index.js").MotionResolver<{
|
|
1035
|
+
readonly part: {
|
|
1036
|
+
readonly collapse: {};
|
|
1037
|
+
readonly view: {
|
|
1038
|
+
readonly in: {
|
|
1039
|
+
readonly axis: "x";
|
|
1040
|
+
readonly x: "100%";
|
|
1041
|
+
readonly opacity: 0;
|
|
1042
|
+
};
|
|
1043
|
+
readonly out: {
|
|
1044
|
+
readonly axis: "x";
|
|
1045
|
+
readonly x: "100%";
|
|
1046
|
+
readonly opacity: 0;
|
|
1047
|
+
};
|
|
1048
|
+
readonly duration: "slow";
|
|
1049
|
+
readonly easing: "enter";
|
|
1050
|
+
};
|
|
1051
|
+
};
|
|
1052
|
+
}>;
|
|
945
1053
|
root: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
946
1054
|
variant: {
|
|
947
1055
|
admin: string;
|
|
@@ -994,6 +1102,13 @@ export declare const useSidebarTheme: import("../../utils/cva/theme.js").UseComp
|
|
|
994
1102
|
comfortable: string;
|
|
995
1103
|
};
|
|
996
1104
|
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
1105
|
+
viewStage: (props?: import("../../utils/cva/types.js").CVAClassProp | undefined) => string;
|
|
1106
|
+
viewLayer: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
1107
|
+
swipe: {
|
|
1108
|
+
true: string;
|
|
1109
|
+
false: null;
|
|
1110
|
+
};
|
|
1111
|
+
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
997
1112
|
footer: (props?: (import("../../utils/cva/types.js").CVAVariantSchema<{
|
|
998
1113
|
density: {
|
|
999
1114
|
compact: string;
|
|
@@ -1246,6 +1361,17 @@ export declare const useSidebarTheme: import("../../utils/cva/theme.js").UseComp
|
|
|
1246
1361
|
vertical: string;
|
|
1247
1362
|
horizontal: string;
|
|
1248
1363
|
};
|
|
1364
|
+
variant: {
|
|
1365
|
+
admin: string;
|
|
1366
|
+
floating: string;
|
|
1367
|
+
inset: string;
|
|
1368
|
+
split: string;
|
|
1369
|
+
framed: string;
|
|
1370
|
+
};
|
|
1371
|
+
placement: {
|
|
1372
|
+
positioned: string;
|
|
1373
|
+
static: string;
|
|
1374
|
+
};
|
|
1249
1375
|
density: {
|
|
1250
1376
|
compact: string;
|
|
1251
1377
|
normal: string;
|
|
@@ -1409,4 +1535,22 @@ export declare const useSidebarTheme: import("../../utils/cva/theme.js").UseComp
|
|
|
1409
1535
|
};
|
|
1410
1536
|
}> & import("../../utils/cva/types.js").CVAClassProp) | undefined) => string;
|
|
1411
1537
|
}>;
|
|
1412
|
-
export declare const useSidebarMotion: () => import("../../utils/motion/index.js").ComponentMotion<
|
|
1538
|
+
export declare const useSidebarMotion: () => import("../../utils/motion/index.js").ComponentMotion<{
|
|
1539
|
+
readonly part: {
|
|
1540
|
+
readonly collapse: {};
|
|
1541
|
+
readonly view: {
|
|
1542
|
+
readonly in: {
|
|
1543
|
+
readonly axis: "x";
|
|
1544
|
+
readonly x: "100%";
|
|
1545
|
+
readonly opacity: 0;
|
|
1546
|
+
};
|
|
1547
|
+
readonly out: {
|
|
1548
|
+
readonly axis: "x";
|
|
1549
|
+
readonly x: "100%";
|
|
1550
|
+
readonly opacity: 0;
|
|
1551
|
+
};
|
|
1552
|
+
readonly duration: "slow";
|
|
1553
|
+
readonly easing: "enter";
|
|
1554
|
+
};
|
|
1555
|
+
};
|
|
1556
|
+
}>;
|