@danjelp/ngx-app-shell 1.0.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.
@@ -0,0 +1 @@
1
+ {"version":3,"file":"danjelp-ngx-app-shell.mjs","sources":["../../../projects/app-shell/src/lib/core/shell.types.ts","../../../projects/app-shell/src/lib/responsive/shell-size.ts","../../../projects/app-shell/src/lib/sidebar/sidebar-states.ts","../../../projects/app-shell/src/lib/sidebar/responsive-sidebar-behavior.ts","../../../projects/app-shell/src/lib/sidebar/sidebar-behavior.ts","../../../projects/app-shell/src/lib/core/shell.config.ts","../../../projects/app-shell/src/lib/core/shell-state-storage.ts","../../../projects/app-shell/src/lib/core/shell.ids.ts","../../../projects/app-shell/src/lib/core/shell.store.ts","../../../projects/app-shell/src/lib/sidebar/manual-sidebar-behavior.ts","../../../projects/app-shell/src/lib/sidebar/drawer-sidebar-behavior.ts","../../../projects/app-shell/src/lib/responsive/observe-width.ts","../../../projects/app-shell/src/lib/responsive/measure-region.ts","../../../projects/app-shell/src/lib/responsive/shell-region.ts","../../../projects/app-shell/src/lib/responsive/container-size.directive.ts","../../../projects/app-shell/src/lib/slots/shell-slot-registry.ts","../../../projects/app-shell/src/lib/slots/shell-slot.directive.ts","../../../projects/app-shell/src/lib/slots/shell-slot-outlet.component.ts","../../../projects/app-shell/src/lib/slots/has-slot.ts","../../../projects/app-shell/src/lib/breadcrumbs/breadcrumb.types.ts","../../../projects/app-shell/src/lib/breadcrumbs/shell-breadcrumb-store.ts","../../../projects/app-shell/src/lib/layout/shell-footer.component.ts","../../../projects/app-shell/src/lib/layout/shell-footer.component.html","../../../projects/app-shell/src/lib/a11y/focus-trap.ts","../../../projects/app-shell/src/lib/directives/sidebar-toggle.directive.ts","../../../projects/app-shell/src/lib/layout/shell-sidebar.component.ts","../../../projects/app-shell/src/lib/layout/shell-sidebar.component.html","../../../projects/app-shell/src/lib/layout/shell-overflow-menu.component.ts","../../../projects/app-shell/src/lib/layout/shell-overflow-menu.component.html","../../../projects/app-shell/src/lib/breadcrumbs/shell-breadcrumb.component.ts","../../../projects/app-shell/src/lib/breadcrumbs/shell-breadcrumb.component.html","../../../projects/app-shell/src/lib/layout/shell-subheader.component.ts","../../../projects/app-shell/src/lib/layout/shell-subheader.component.html","../../../projects/app-shell/src/lib/layout/shell-topbar.component.ts","../../../projects/app-shell/src/lib/layout/shell-topbar.component.html","../../../projects/app-shell/src/lib/layout/app-shell.component.ts","../../../projects/app-shell/src/lib/layout/app-shell.component.html","../../../projects/app-shell/src/lib/nav/shell-nav-item.component.ts","../../../projects/app-shell/src/lib/nav/shell-nav-item.component.html","../../../projects/app-shell/src/lib/nav/shell-nav-registry.ts","../../../projects/app-shell/src/lib/nav/shell-nav.component.ts","../../../projects/app-shell/src/lib/nav/shell-nav.component.html","../../../projects/app-shell/src/lib/app-shell.imports.ts","../../../projects/app-shell/src/public-api.ts","../../../projects/app-shell/src/danjelp-ngx-app-shell.ts"],"sourcesContent":["import { Signal } from '@angular/core';\n\n/** Ordered size buckets. Order matters: `sizeRank()` relies on the index. */\nexport const SHELL_SIZES = ['xs', 'sm', 'md', 'lg', 'xl'] as const;\nexport type ShellSize = (typeof SHELL_SIZES)[number];\n\n/** Minimum *container* width (px) at which each bucket starts. */\nexport type ShellBreakpoints = Readonly<Record<ShellSize, number>>;\n\n/**\n * `topbar-full` – topbar spans the full width, sidebar starts below it.\n * `sidebar-full` – sidebar spans the full height, topbar starts next to it.\n * `stacked` – topbar *and* footer span the full width, sidebar sits between.\n * `inset` – topbar, main and footer share one rounded card; the sidebar\n * sits directly on the shell background.\n */\nexport type ShellLayout = 'topbar-full' | 'sidebar-full' | 'stacked' | 'inset';\n\n/**\n * `main` = app-like, only the content area scrolls.\n * `page` = the document scrolls — or, in the `inset` layout, the card itself\n * scrolls with the topbar sticky at its top.\n */\nexport type ShellScrollMode = 'main' | 'page';\n\n/** What the sidebar currently *is*. Derived state, never set directly. */\nexport type SidebarMode = 'expanded' | 'collapsed' | 'overlay' | 'hidden';\n\n/**\n * What the user *asked for* on a screen wide enough for a persistent sidebar.\n * `auto` hands the decision back to the behaviour. The drawer's open/closed\n * state is deliberately not an intent: it is transient and never persisted.\n */\nexport type SidebarIntent = 'auto' | 'expanded' | 'collapsed' | 'hidden';\n\n/**\n * When the topbar renders its built-in sidebar toggle.\n * `auto` = only when the sidebar cannot be reached otherwise (drawer or hidden).\n */\nexport type SidebarToggleVisibility = 'always' | 'auto' | 'never';\n\n/** Fully resolved sidebar state — the single source of truth for template + CSS. */\nexport interface SidebarState {\n readonly mode: SidebarMode;\n /** Is the panel visible at all (open drawer, or an in-flow rail/panel)? */\n readonly open: boolean;\n /** Does it trap focus and need a scrim? True for the open overlay drawer. */\n readonly modal: boolean;\n /** Should item labels / group headings render? False on an icon rail. */\n readonly labels: boolean;\n /** Collapsed rail temporarily widened by hover/focus peek. */\n readonly peeked: boolean;\n /** Width reserved in the shell grid. `0px` when the panel floats over content. */\n readonly trackWidth: string;\n /** Width of the panel element itself. */\n readonly panelWidth: string;\n}\n\n/**\n * Slot names the built-in regions render. Extra names are allowed — the\n * `(string & {})` member keeps autocompletion for the known ones while letting\n * you invent your own and render them with `<shell-slot-outlet>`.\n */\nexport type ShellSlotName =\n // topbar, start to end\n | 'topbar-start'\n | 'brand'\n | 'primary-nav'\n | 'title'\n | 'search'\n | 'actions'\n | 'account'\n | 'topbar-end'\n // sidebar, top to bottom\n | 'sidebar-header'\n | 'sidebar-action'\n | 'sidebar-search'\n | 'sidebar-nav'\n | 'sidebar-secondary'\n | 'sidebar-footer'\n // breadcrumb row, start to end\n | 'breadcrumb'\n | 'subheader-start'\n | 'subheader-end'\n // footer\n | 'footer-start'\n | 'footer'\n | 'footer-end'\n | (string & {});\n\n/** Imperative surface handed to slot templates and to `[shellSidebarToggle]`. */\nexport interface ShellApi {\n readonly size: Signal<ShellSize>;\n readonly sidebar: Signal<SidebarState>;\n readonly sidebarIntent: Signal<SidebarIntent>;\n toggleSidebar(): void;\n openSidebar(): void;\n closeSidebar(): void;\n setSidebarIntent(intent: SidebarIntent): void;\n}\n\n/** `let-` context available inside every `<ng-template shellSlot=\"…\">`. */\nexport interface ShellSlotContext {\n /** `let-sidebar` / `let-x` — resolved sidebar state. */\n readonly $implicit: SidebarState;\n readonly sidebar: SidebarState;\n /** Size bucket of the whole shell. */\n readonly size: ShellSize;\n /** Size bucket of the region rendering this slot (topbar, sidebar, footer…). */\n readonly region: ShellSize;\n /** True when rendered inside a ⋯ overflow menu (topbar or breadcrumb row). */\n readonly overflow: boolean;\n readonly shell: ShellApi;\n}\n","import { ShellBreakpoints, ShellSize, SHELL_SIZES } from '../core/shell.types';\n\n/**\n * Container-first breakpoints. Deliberately *not* device widths: they describe\n * the space a region has, which is what layout decisions should react to.\n */\nexport const DEFAULT_BREAKPOINTS: ShellBreakpoints = {\n xs: 0,\n sm: 520,\n md: 768,\n lg: 1080,\n xl: 1440,\n};\n\nexport function sizeRank(size: ShellSize): number {\n return SHELL_SIZES.indexOf(size);\n}\n\n/** Largest bucket whose minimum width is still <= `width`. */\nexport function resolveSize(width: number, breakpoints: ShellBreakpoints): ShellSize {\n let match: ShellSize = SHELL_SIZES[0];\n for (const size of SHELL_SIZES) {\n if (width >= breakpoints[size]) {\n match = size;\n }\n }\n return match;\n}\n\n/** `atLeast('md', 'sm')` → true */\nexport function atLeast(size: ShellSize, min: ShellSize): boolean {\n return sizeRank(size) >= sizeRank(min);\n}\n\n/** `atMost('md', 'lg')` → true */\nexport function atMost(size: ShellSize, max: ShellSize): boolean {\n return sizeRank(size) <= sizeRank(max);\n}\n\n/** Strictly narrower than `bound` — used for \"collapse below md\" style rules. */\nexport function isBelow(size: ShellSize, bound: ShellSize): boolean {\n return sizeRank(size) < sizeRank(bound);\n}\n","import type { ShellSidebarConfig } from '../core/shell.config';\nimport type { SidebarState } from '../core/shell.types';\n\n/**\n * Building blocks for `SidebarBehavior.resolve`. Each returns a complete,\n * internally consistent state, so a custom behaviour only decides *which* mode\n * applies — never how wide the track is or whether a scrim is needed.\n */\n\n/** Off-canvas modal drawer. Reserves no grid track. */\nexport function drawerState(open: boolean, sidebar: ShellSidebarConfig): SidebarState {\n return {\n mode: 'overlay',\n open,\n modal: open,\n labels: true,\n peeked: false,\n trackWidth: '0px',\n panelWidth: sidebar.overlayWidth,\n };\n}\n\n/** Icon rail. While peeking the panel floats wider but the track stays put. */\nexport function railState(peeking: boolean, sidebar: ShellSidebarConfig): SidebarState {\n const peeked = peeking && sidebar.peek;\n return {\n mode: 'collapsed',\n open: true,\n modal: false,\n labels: peeked,\n peeked,\n trackWidth: sidebar.collapsedWidth,\n panelWidth: peeked ? sidebar.width : sidebar.collapsedWidth,\n };\n}\n\n/** Full in-flow panel with labels. */\nexport function panelState(sidebar: ShellSidebarConfig): SidebarState {\n return {\n mode: 'expanded',\n open: true,\n modal: false,\n labels: true,\n peeked: false,\n trackWidth: sidebar.width,\n panelWidth: sidebar.width,\n };\n}\n\nconst HIDDEN_STATE: SidebarState = {\n mode: 'hidden',\n open: false,\n modal: false,\n labels: false,\n peeked: false,\n trackWidth: '0px',\n panelWidth: '0px',\n};\n\n/** Not rendered, zero-width track. */\nexport function hiddenState(): SidebarState {\n return HIDDEN_STATE;\n}\n","import { isBelow } from '../responsive/shell-size';\nimport type { SidebarState } from '../core/shell.types';\nimport type { SidebarBehavior, SidebarContext } from './sidebar-behavior';\nimport { drawerState, hiddenState, panelState, railState } from './sidebar-states';\n\n/**\n * Default policy.\n *\n * size < overlayBelow → modal drawer, closed until opened\n * size < collapseBelow → icon rail, widened while peeking\n * otherwise → full panel\n *\n * An explicit intent (`expanded`, `collapsed`, `hidden`) wins over the\n * automatic choice, except in drawer territory where there is no room for a\n * persistent panel. Set the intent back to `auto` to follow breakpoints again.\n */\nexport const responsiveSidebarBehavior: SidebarBehavior = {\n resolve({ size, intent, drawerOpen, peeking, config }: SidebarContext): SidebarState {\n const sidebar = config.sidebar;\n\n if (isBelow(size, sidebar.overlayBelow)) {\n return drawerState(drawerOpen, sidebar);\n }\n if (intent === 'hidden') {\n return hiddenState();\n }\n\n const automatic = isBelow(size, sidebar.collapseBelow) ? 'collapsed' : 'expanded';\n const resolved = intent === 'auto' ? automatic : intent;\n return resolved === 'collapsed' ? railState(peeking, sidebar) : panelState(sidebar);\n },\n};\n","import { InjectionToken } from '@angular/core';\nimport type { ShellConfig } from '../core/shell.config';\nimport type { ShellSize, SidebarIntent, SidebarState } from '../core/shell.types';\nimport { responsiveSidebarBehavior } from './responsive-sidebar-behavior';\n\n/** Everything a behaviour is allowed to look at. Pure in, pure out. */\nexport interface SidebarContext {\n /** Measured width of the shell in px, or `null` before the first measurement. */\n readonly width: number | null;\n /** Resolved size bucket of the shell container. */\n readonly size: ShellSize;\n /** The user's persistent preference for wide screens. */\n readonly intent: SidebarIntent;\n /** Transient open state, meaningful only when the behaviour resolves a drawer. */\n readonly drawerOpen: boolean;\n /** Pointer/focus is dwelling on the collapsed rail. */\n readonly peeking: boolean;\n readonly config: ShellConfig;\n}\n\n/**\n * The collapse policy, isolated behind one interface so an app can change how\n * the sidebar behaves without forking the layout. Swap it with\n * `provideAppShell(config, { behavior })` or at runtime with\n * `ShellStore.setBehavior()`.\n *\n * `resolve` must be a pure function of the context: it runs inside a `computed`.\n * Build the returned state with `drawerState`, `railState`, `panelState` and\n * `hiddenState` so every behaviour produces consistent widths and flags.\n */\nexport interface SidebarBehavior {\n resolve(context: SidebarContext): SidebarState;\n /**\n * Intent produced by activating a toggle while the sidebar is *not* a drawer\n * (drawers simply open/close). Default: expanded ⇄ collapsed.\n */\n nextIntent?(context: SidebarContext): SidebarIntent;\n /** Should this intent survive a reload? Default: yes. */\n persistIntent?(intent: SidebarIntent, context: SidebarContext): boolean;\n}\n\nexport const SIDEBAR_BEHAVIOR = new InjectionToken<SidebarBehavior>('SIDEBAR_BEHAVIOR', {\n providedIn: 'root',\n factory: () => responsiveSidebarBehavior,\n});\n","import { EnvironmentProviders, InjectionToken, makeEnvironmentProviders } from '@angular/core';\nimport { DEFAULT_BREAKPOINTS } from '../responsive/shell-size';\nimport { SIDEBAR_BEHAVIOR, SidebarBehavior } from '../sidebar/sidebar-behavior';\nimport type {\n ShellBreakpoints,\n ShellLayout,\n ShellScrollMode,\n ShellSize,\n SidebarIntent,\n SidebarToggleVisibility,\n} from './shell.types';\n\n// ── Appearance & motion vocabularies ────────────────────────────────────────\n\n/**\n * Topbar look. `elevated` trades the border for a shadow; `blur` and\n * `transparent` only show through when content scrolls under the bar\n * (`scroll: 'page'`).\n */\nexport type TopbarAppearance = 'solid' | 'elevated' | 'blur' | 'transparent';\n\n/** `floating` insets the panel as a rounded, shadowed card inside its track. */\nexport type SidebarAppearance = 'solid' | 'floating' | 'borderless';\n\nexport type FooterAppearance = 'solid' | 'minimal';\n\n/** How the active nav item is marked. `none` = accent text only. */\nexport type NavIndicator = 'pill' | 'bar' | 'none';\n\nexport type DrawerMotion = 'slide' | 'fade' | 'scale' | 'none';\nexport type MenuMotion = 'fade' | 'scale' | 'slide' | 'none';\nexport type ScrimMotion = 'fade' | 'none';\n\n/** `auto` = follow the page (see `ShellSubheaderConfig.enabled`); booleans force it. */\nexport type SubheaderVisibility = 'auto' | boolean;\n\n/** Breadcrumb row look. `transparent` blends into the page; `elevated` trades the rule for a shadow. */\nexport type SubheaderAppearance = 'solid' | 'transparent' | 'elevated';\n\n/** Glyph between breadcrumb levels. Always decorative: screen readers skip it. */\nexport type BreadcrumbSeparator = 'chevron' | 'slash' | 'dot';\n\n// ── Config sections ─────────────────────────────────────────────────────────\n\nexport interface ShellSidebarConfig {\n /** Width of the expanded panel. Any CSS length. */\n readonly width: string;\n /** Width of the icon rail. */\n readonly collapsedWidth: string;\n /** Width of the off-canvas drawer. */\n readonly overlayWidth: string;\n /** Starting intent. `auto` = let the behaviour decide from available space. */\n readonly intent: SidebarIntent;\n /** Below this bucket the panel collapses to a rail. */\n readonly collapseBelow: ShellSize;\n /** Below this bucket the panel becomes a modal drawer. */\n readonly overlayBelow: ShellSize;\n /** Widen the rail on hover/focus instead of showing flyouts. */\n readonly peek: boolean;\n /** Dwell time (ms) before a hover peeks the rail open. */\n readonly peekDelay: number;\n /** Close the drawer after a router navigation. */\n readonly closeOnNavigate: boolean;\n /** Let the user drag the expanded panel's edge to resize it. */\n readonly resizable: boolean;\n /** Resize bounds in px. */\n readonly minWidth: number;\n readonly maxWidth: number;\n /**\n * Key that toggles the sidebar together with Ctrl (Windows/Linux) or ⌘ (macOS),\n * e.g. `'b'` for the VS Code style Ctrl+B. `null` disables the shortcut.\n */\n readonly toggleShortcut: string | null;\n /** Remember the user's intent and custom width across reloads. */\n readonly persist: boolean;\n /** Prefix for persisted keys: `<storageKey>.intent`, `<storageKey>.width`. */\n readonly storageKey: string;\n}\n\nexport interface ShellTopbarConfig {\n readonly enabled: boolean;\n readonly sidebarToggle: SidebarToggleVisibility;\n}\n\nexport interface ShellFooterConfig {\n /** Render the footer even when no footer slot is filled. */\n readonly enabled: boolean;\n}\n\n/**\n * Look presets per part. Each preset only changes the *defaults* of that\n * part's component tokens, so `--shell-topbar-bg` & co. always win.\n */\nexport interface ShellAppearanceConfig {\n readonly topbar: TopbarAppearance;\n readonly sidebar: SidebarAppearance;\n readonly footer: FooterAppearance;\n readonly navIndicator: NavIndicator;\n readonly subheader: SubheaderAppearance;\n}\n\n/**\n * Which animations run and how. Timing per part lives in CSS\n * (`--shell-drawer-duration`, `--shell-collapse-easing` …); this chooses the\n * *kind*. `prefers-reduced-motion` is always respected on top.\n */\nexport interface ShellMotionConfig {\n /** Master switch. `false` makes every shell transition instant. */\n readonly enabled: boolean;\n /** Speed multiplier for every duration: 2 = twice as fast, 0.5 = half speed. */\n readonly speed: number;\n readonly drawer: DrawerMotion;\n readonly overflowMenu: MenuMotion;\n readonly scrim: ScrimMotion;\n /** Animate rail ⇄ panel (grid track, panel width, peek). */\n readonly collapse: boolean;\n /** Animate nav sections opening and closing. */\n readonly navExpand: boolean;\n}\n\n/** The breadcrumb row between the topbar and `main`. */\nexport interface ShellSubheaderConfig {\n /**\n * `'auto'`: shown when the trail is at least two levels deep or a subheader\n * slot is filled; a route's `data: { subheader }` overrides. Booleans force it.\n */\n readonly enabled: SubheaderVisibility;\n /** With `scroll: 'page'`, stick under the topbar instead of scrolling away. */\n readonly sticky: boolean;\n /** Slot names the row may push into its own ⋯ menu, in that order. */\n readonly overflowSlots: readonly string[];\n}\n\n/** How `ShellBreadcrumbStore` builds the trail and `<shell-breadcrumb>` shows it. */\nexport interface ShellBreadcrumbsConfig {\n /** Prepend a home crumb (unless the trail already starts there). */\n readonly includeHome: boolean;\n readonly homeLabel: string;\n readonly homeUrl: string;\n /** Show the current page as the last item (NN/g); `false` ends at the parent (GOV.UK). */\n readonly includeCurrent: boolean;\n /** Beyond this many items the middle levels fold into \"…\". Minimum 2. */\n readonly maxItems: number;\n /** Label levels without `data.breadcrumb` by their route `title`. */\n readonly useRouteTitle: boolean;\n /** Below this width (px, of the trail itself): first › … › parent › current. */\n readonly compactBelow: number;\n /** Below this width (px): a single \"‹ Parent\" link. */\n readonly backBelow: number;\n /** A pending label only shows its skeleton after this many ms. */\n readonly skeletonDelay: number;\n readonly separator: BreadcrumbSeparator;\n}\n\nexport interface ShellLabels {\n readonly skipToContent: string;\n readonly openNavigation: string;\n readonly closeNavigation: string;\n readonly expandSidebar: string;\n readonly collapseSidebar: string;\n readonly resizeSidebar: string;\n readonly moreActions: string;\n readonly primaryNavigation: string;\n readonly breadcrumb: string;\n readonly showPath: string;\n readonly back: string;\n readonly loading: string;\n}\n\nexport interface ShellConfig {\n readonly layout: ShellLayout;\n readonly scroll: ShellScrollMode;\n /**\n * With `scroll: 'main'` the router cannot restore scroll (the window never\n * scrolls), so the shell scrolls `main` back to the top after navigation.\n */\n readonly scrollTopOnNavigate: boolean;\n /** Bucket assumed before the first measurement (and on the server). */\n readonly initialSize: ShellSize;\n readonly breakpoints: ShellBreakpoints;\n readonly sidebar: ShellSidebarConfig;\n readonly topbar: ShellTopbarConfig;\n readonly footer: ShellFooterConfig;\n readonly appearance: ShellAppearanceConfig;\n readonly motion: ShellMotionConfig;\n readonly subheader: ShellSubheaderConfig;\n readonly breadcrumbs: ShellBreadcrumbsConfig;\n /** Slot names the topbar may push into its overflow menu, in that order. */\n readonly overflowSlots: readonly string[];\n readonly labels: ShellLabels;\n}\n\nexport const DEFAULT_SHELL_CONFIG: ShellConfig = {\n layout: 'topbar-full',\n scroll: 'main',\n scrollTopOnNavigate: true,\n initialSize: 'lg',\n breakpoints: DEFAULT_BREAKPOINTS,\n sidebar: {\n width: 'var(--shell-sidebar-width, 264px)',\n collapsedWidth: 'var(--shell-sidebar-collapsed-width, 68px)',\n overlayWidth: 'var(--shell-sidebar-overlay-width, min(88vw, 320px))',\n intent: 'auto',\n collapseBelow: 'lg',\n overlayBelow: 'md',\n peek: true,\n peekDelay: 180,\n closeOnNavigate: true,\n resizable: false,\n minWidth: 200,\n maxWidth: 420,\n toggleShortcut: null,\n persist: true,\n storageKey: 'app-shell.sidebar',\n },\n topbar: { enabled: true, sidebarToggle: 'always' },\n footer: { enabled: false },\n appearance: {\n topbar: 'solid',\n sidebar: 'solid',\n footer: 'solid',\n navIndicator: 'pill',\n subheader: 'solid',\n },\n motion: {\n enabled: true,\n speed: 1,\n drawer: 'slide',\n overflowMenu: 'fade',\n scrim: 'fade',\n collapse: true,\n navExpand: true,\n },\n subheader: {\n enabled: 'auto',\n sticky: true,\n overflowSlots: ['subheader-end'],\n },\n breadcrumbs: {\n includeHome: false,\n homeLabel: 'Home',\n homeUrl: '/',\n includeCurrent: true,\n maxItems: 4,\n useRouteTitle: true,\n compactBelow: 480,\n backBelow: 280,\n skeletonDelay: 400,\n separator: 'chevron',\n },\n overflowSlots: ['primary-nav', 'search', 'actions'],\n labels: {\n skipToContent: 'Skip to main content',\n openNavigation: 'Open navigation',\n closeNavigation: 'Close navigation',\n expandSidebar: 'Expand sidebar',\n collapseSidebar: 'Collapse sidebar',\n resizeSidebar: 'Resize sidebar',\n moreActions: 'More',\n primaryNavigation: 'Primary',\n breadcrumb: 'Breadcrumb',\n showPath: 'Show full path',\n back: 'Back to',\n loading: 'Loading',\n },\n};\n\n/** Configuration as provided by the app (`provideAppShell`). */\nexport const SHELL_CONFIG = new InjectionToken<ShellConfig>('SHELL_CONFIG', {\n providedIn: 'root',\n factory: () => DEFAULT_SHELL_CONFIG,\n});\n\n/**\n * Two levels deep is all the config tree needs — which keeps the merge honest\n * and the type readable. Arrays and primitives are replaced wholesale; nested\n * option objects are merged key by key.\n */\nexport type ShellConfigInput = {\n readonly [K in keyof ShellConfig]?: ShellConfig[K] extends readonly unknown[]\n ? ShellConfig[K]\n : ShellConfig[K] extends object\n ? Partial<ShellConfig[K]>\n : ShellConfig[K];\n};\n\n/** Merge `input` over `base` (the defaults unless given). Never mutates. */\nexport function mergeShellConfig(\n input: ShellConfigInput = {},\n base: ShellConfig = DEFAULT_SHELL_CONFIG,\n): ShellConfig {\n return {\n ...base,\n ...input,\n breakpoints: { ...base.breakpoints, ...input.breakpoints },\n sidebar: { ...base.sidebar, ...input.sidebar },\n topbar: { ...base.topbar, ...input.topbar },\n footer: { ...base.footer, ...input.footer },\n appearance: { ...base.appearance, ...input.appearance },\n motion: { ...base.motion, ...input.motion },\n subheader: { ...base.subheader, ...input.subheader },\n breadcrumbs: { ...base.breadcrumbs, ...input.breadcrumbs },\n labels: { ...base.labels, ...input.labels },\n };\n}\n\n/**\n * Register the shell once, in `app.config.ts`:\n *\n * ```ts\n * provideAppShell({ layout: 'sidebar-full', sidebar: { collapseBelow: 'xl' } })\n * ```\n *\n * Pass `behavior` to replace the collapse policy wholesale. Both can also be\n * changed at runtime through `ShellStore.configure()` / `setBehavior()`.\n */\nexport function provideAppShell(\n config: ShellConfigInput = {},\n options: { readonly behavior?: SidebarBehavior } = {},\n): EnvironmentProviders {\n const providers: Parameters<typeof makeEnvironmentProviders>[0] = [\n { provide: SHELL_CONFIG, useValue: mergeShellConfig(config) },\n ];\n if (options.behavior) {\n providers.push({ provide: SIDEBAR_BEHAVIOR, useValue: options.behavior });\n }\n return makeEnvironmentProviders(providers);\n}\n","import { InjectionToken, PLATFORM_ID, inject } from '@angular/core';\nimport { isPlatformBrowser } from '@angular/common';\n\n/** Minimal persistence port so the shell never touches `localStorage` directly. */\nexport interface ShellStateStorage {\n read(key: string): string | null;\n write(key: string, value: string): void;\n}\n\nconst NOOP_STORAGE: ShellStateStorage = {\n read: () => null,\n write: () => undefined,\n};\n\nexport function localShellStateStorage(): ShellStateStorage {\n if (!isPlatformBrowser(inject(PLATFORM_ID))) {\n return NOOP_STORAGE;\n }\n return {\n read(key) {\n try {\n return localStorage.getItem(key);\n } catch {\n // Private mode / disabled storage: degrade to \"no preference\".\n return null;\n }\n },\n write(key, value) {\n try {\n localStorage.setItem(key, value);\n } catch {\n /* ignore */\n }\n },\n };\n}\n\nexport const SHELL_STATE_STORAGE = new InjectionToken<ShellStateStorage>('SHELL_STATE_STORAGE', {\n providedIn: 'root',\n factory: localShellStateStorage,\n});\n","/**\n * Stable element ids. The shell assumes one instance per application, which\n * lets `aria-controls` work from a toggle rendered anywhere in the tree.\n */\nexport const SHELL_SIDEBAR_ID = 'shell-sidebar';\nexport const SHELL_MAIN_ID = 'shell-main';\n","import { Injectable, Signal, computed, inject, linkedSignal, signal } from '@angular/core';\nimport { resolveSize } from '../responsive/shell-size';\nimport { SIDEBAR_BEHAVIOR, SidebarBehavior, SidebarContext } from '../sidebar/sidebar-behavior';\nimport { SHELL_CONFIG, ShellConfig, ShellConfigInput, mergeShellConfig } from './shell.config';\nimport { SHELL_STATE_STORAGE } from './shell-state-storage';\nimport type { ShellApi, ShellSize, SidebarIntent, SidebarState } from './shell.types';\n\nconst INTENTS: readonly SidebarIntent[] = ['auto', 'expanded', 'collapsed', 'hidden'];\n\n/**\n * Single source of truth for the shell.\n *\n * Root-provided on purpose: any component in the app — including lazily loaded\n * pages and content projected into `<app-shell>` — can inject it and drive the\n * sidebar without input/output plumbing. One shell per application.\n *\n * Everything is derived from four inputs: the measured shell width, the user's\n * intent, the transient drawer/peek flags, and the (runtime-changeable)\n * config + behaviour.\n */\n@Injectable({ providedIn: 'root' })\nexport class ShellStore implements ShellApi {\n private readonly storage = inject(SHELL_STATE_STORAGE);\n\n private readonly baseConfig = signal<ShellConfig>(inject(SHELL_CONFIG));\n private readonly behaviorState = signal<SidebarBehavior>(inject(SIDEBAR_BEHAVIOR));\n\n /** Measured shell width; `null` until the first ResizeObserver callback. */\n private readonly width = signal<number | null>(null);\n private readonly intent = signal<SidebarIntent>(this.restoreIntent());\n /** User-dragged panel width in px; `null` = use the configured width. */\n private readonly customWidth = signal<number | null>(this.restoreWidth());\n private readonly peekRequested = signal(false);\n private readonly resizingState = signal(false);\n private peekTimer: ReturnType<typeof setTimeout> | undefined;\n\n /** Size bucket of the shell container — not of the viewport. */\n readonly size: Signal<ShellSize> = computed(() => {\n const width = this.width();\n const config = this.baseConfig();\n return width === null ? config.initialSize : resolveSize(width, config.breakpoints);\n });\n\n /**\n * Drawer open state. Transient by design: it is never persisted, and any\n * change of size bucket closes it, so rotating a phone or resizing a window\n * never leaves a modal drawer stranded open.\n */\n private readonly drawerOpen = linkedSignal<ShellSize, boolean>({\n source: this.size,\n computation: () => false,\n });\n\n /** Effective configuration: app config, runtime patches and the user's width. */\n readonly config: Signal<ShellConfig> = computed(() => {\n const config = this.baseConfig();\n const width = this.customWidth();\n if (width === null || !config.sidebar.resizable) {\n return config;\n }\n return { ...config, sidebar: { ...config.sidebar, width: `${width}px` } };\n });\n\n readonly behavior: Signal<SidebarBehavior> = this.behaviorState.asReadonly();\n readonly shellWidth: Signal<number | null> = this.width.asReadonly();\n readonly sidebarIntent: Signal<SidebarIntent> = this.intent.asReadonly();\n readonly sidebarWidth: Signal<number | null> = this.customWidth.asReadonly();\n readonly resizing: Signal<boolean> = this.resizingState.asReadonly();\n\n readonly sidebar: Signal<SidebarState> = computed(() =>\n this.behaviorState().resolve(this.context()),\n );\n\n // ── Configuration ─────────────────────────────────────────────────────────\n\n /** Patch the configuration at runtime, e.g. from a settings screen. */\n configure(patch: ShellConfigInput): void {\n this.baseConfig.update((current) => mergeShellConfig(patch, current));\n }\n\n /** Swap the collapse policy at runtime. */\n setBehavior(behavior: SidebarBehavior): void {\n this.behaviorState.set(behavior);\n }\n\n /** Called by `<app-shell>` with its measured width. */\n setWidth(width: number | null): void {\n this.width.set(width);\n }\n\n // ── Sidebar commands ──────────────────────────────────────────────────────\n\n setSidebarIntent(intent: SidebarIntent): void {\n this.intent.set(intent);\n this.persistIntent(intent);\n }\n\n /**\n * Overlay drawers toggle open/closed; persistent panels ask the behaviour\n * for the next intent (by default: expanded ⇄ collapsed).\n */\n toggleSidebar(): void {\n const state = this.sidebar();\n if (state.mode === 'overlay') {\n this.drawerOpen.set(!state.open);\n return;\n }\n const context = this.context();\n const next =\n this.behaviorState().nextIntent?.(context) ??\n (state.mode === 'expanded' ? 'collapsed' : 'expanded');\n this.setSidebarIntent(next);\n }\n\n openSidebar(): void {\n if (this.sidebar().mode === 'overlay') {\n this.drawerOpen.set(true);\n } else {\n this.setSidebarIntent('expanded');\n }\n }\n\n closeSidebar(): void {\n if (this.sidebar().mode === 'overlay') {\n this.drawerOpen.set(false);\n } else {\n this.setSidebarIntent('collapsed');\n }\n }\n\n /**\n * Set the expanded panel width in px (clamped to `minWidth`/`maxWidth`), or\n * `null` to return to the configured width. Pass `{ persist: false }` for\n * intermediate values, e.g. while a drag is still in progress.\n */\n setSidebarWidth(width: number | null, options: { readonly persist?: boolean } = {}): void {\n const { minWidth, maxWidth } = this.baseConfig().sidebar;\n const next = width === null ? null : Math.round(Math.min(maxWidth, Math.max(minWidth, width)));\n this.customWidth.set(next);\n if (options.persist ?? true) {\n this.write('width', next === null ? '' : String(next));\n }\n }\n\n /** Suspends layout transitions while a resize drag is in progress. */\n setResizing(resizing: boolean): void {\n this.resizingState.set(resizing);\n }\n\n /** Hover/focus peek on the collapsed rail, debounced by `sidebar.peekDelay`. */\n requestPeek(peeking: boolean): void {\n clearTimeout(this.peekTimer);\n if (!peeking) {\n this.peekRequested.set(false);\n return;\n }\n const sidebar = this.baseConfig().sidebar;\n if (!sidebar.peek) {\n return;\n }\n this.peekTimer = setTimeout(() => this.peekRequested.set(true), sidebar.peekDelay);\n }\n\n // ── Internals ─────────────────────────────────────────────────────────────\n\n private context(): SidebarContext {\n return {\n width: this.width(),\n size: this.size(),\n intent: this.intent(),\n drawerOpen: this.drawerOpen(),\n peeking: this.peekRequested(),\n config: this.config(),\n };\n }\n\n private persistIntent(intent: SidebarIntent): void {\n const allowed = this.behaviorState().persistIntent?.(intent, this.context()) ?? true;\n if (allowed) {\n this.write('intent', intent);\n }\n }\n\n private write(key: 'intent' | 'width', value: string): void {\n const sidebar = this.baseConfig().sidebar;\n if (sidebar.persist) {\n this.storage.write(`${sidebar.storageKey}.${key}`, value);\n }\n }\n\n private read(key: 'intent' | 'width'): string | null {\n const sidebar = this.baseConfig().sidebar;\n return sidebar.persist ? this.storage.read(`${sidebar.storageKey}.${key}`) : null;\n }\n\n private restoreIntent(): SidebarIntent {\n const stored = this.read('intent');\n return INTENTS.includes(stored as SidebarIntent)\n ? (stored as SidebarIntent)\n : this.baseConfig().sidebar.intent;\n }\n\n private restoreWidth(): number | null {\n const stored = Number.parseInt(this.read('width') ?? '', 10);\n return Number.isFinite(stored) ? stored : null;\n }\n}\n","import { isBelow } from '../responsive/shell-size';\nimport type { SidebarState } from '../core/shell.types';\nimport type { SidebarBehavior, SidebarContext } from './sidebar-behavior';\nimport { drawerState, hiddenState, panelState, railState } from './sidebar-states';\n\n/**\n * The sidebar never collapses on its own. Whatever the user last chose is what\n * they get at every desktop size (`auto` means expanded); only drawer\n * territory overrides it.\n *\n * ```ts\n * provideAppShell({}, { behavior: manualSidebarBehavior });\n * ```\n */\nexport const manualSidebarBehavior: SidebarBehavior = {\n resolve({ size, intent, drawerOpen, peeking, config }: SidebarContext): SidebarState {\n const sidebar = config.sidebar;\n\n if (isBelow(size, sidebar.overlayBelow)) {\n return drawerState(drawerOpen, sidebar);\n }\n switch (intent) {\n case 'hidden':\n return hiddenState();\n case 'collapsed':\n return railState(peeking, sidebar);\n default:\n return panelState(sidebar);\n }\n },\n};\n","import type { SidebarState } from '../core/shell.types';\nimport type { SidebarBehavior, SidebarContext } from './sidebar-behavior';\nimport { drawerState } from './sidebar-states';\n\n/**\n * Content-first policy: the sidebar is always an off-canvas drawer, at every\n * size. Suits editors, media players and dashboards that want the full width.\n */\nexport const drawerSidebarBehavior: SidebarBehavior = {\n resolve({ drawerOpen, config }: SidebarContext): SidebarState {\n return drawerState(drawerOpen, config.sidebar);\n },\n};\n","import { ElementRef, NgZone, Signal, effect, inject, signal } from '@angular/core';\n\nexport type WidthTarget =\n | ElementRef<HTMLElement>\n | Signal<ElementRef<HTMLElement> | undefined>;\n\n/**\n * Tracks the inline size of an element as a signal.\n *\n * Accepts a plain `ElementRef` (host element) or a `viewChild` signal, in which\n * case the observer follows the element as it appears, changes or is removed.\n *\n * Must be called from an injection context. SSR safe: with no `ResizeObserver`\n * the signal simply stays `null`, which callers read as \"not measured yet\" and\n * fall back to `config.initialSize` — so the server renders the desktop layout\n * instead of flashing the mobile one.\n */\nexport function observeWidth(target: WidthTarget): Signal<number | null> {\n const width = signal<number | null>(null);\n const zone = inject(NgZone);\n const read: () => ElementRef<HTMLElement> | undefined =\n typeof target === 'function' ? target : () => target;\n\n effect((onCleanup) => {\n const element = read()?.nativeElement;\n if (!element || typeof ResizeObserver === 'undefined') {\n return;\n }\n\n const observer = new ResizeObserver((entries) => {\n const entry = entries[entries.length - 1];\n const box = entry.borderBoxSize?.[0];\n const next = Math.round(box ? box.inlineSize : entry.contentRect.width);\n // Signal equality dedupes; NgZone.run keeps zone-based apps ticking.\n zone.run(() => width.set(next));\n });\n\n observer.observe(element);\n onCleanup(() => observer.disconnect());\n });\n\n return width.asReadonly();\n}\n","import { Signal, computed, inject } from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSize } from '../core/shell.types';\nimport { WidthTarget, observeWidth } from './observe-width';\nimport { resolveSize } from './shell-size';\n\nexport interface MeasuredRegion {\n /** Measured inline size in px, `null` until measured. */\n readonly width: Signal<number | null>;\n /** Bucket for that width under the shell's current breakpoints. */\n readonly size: Signal<ShellSize>;\n}\n\n/**\n * Measure an element and bucket its width with the shell's breakpoints.\n * Before the first measurement (and on the server) the bucket is\n * `config.initialSize`. Call from an injection context.\n */\nexport function measureRegion(target: WidthTarget): MeasuredRegion {\n const store = inject(ShellStore);\n const width = observeWidth(target);\n const size = computed<ShellSize>(() => {\n const measured = width();\n const config = store.config();\n return measured === null ? config.initialSize : resolveSize(measured, config.breakpoints);\n });\n return { width, size };\n}\n","import { InjectionToken, Signal } from '@angular/core';\nimport type { ShellSize } from '../core/shell.types';\n\n/**\n * The size bucket of the nearest enclosing region (topbar, sidebar, drawer,\n * main). Regions provide this so slot outlets and consumer templates react to\n * *their own* available space rather than to the viewport.\n */\nexport interface ShellRegion {\n readonly regionName: string;\n readonly regionSize: Signal<ShellSize>;\n readonly regionWidth: Signal<number | null>;\n}\n\nexport const SHELL_REGION = new InjectionToken<ShellRegion>('SHELL_REGION');\n","import { Directive, ElementRef, Signal, computed, inject, input } from '@angular/core';\nimport type { ShellSize } from '../core/shell.types';\nimport { measureRegion } from './measure-region';\nimport { SHELL_REGION, ShellRegion } from './shell-region';\nimport { atLeast, atMost, isBelow } from './shell-size';\n\n/**\n * Turns any element into a measured container.\n *\n * ```html\n * <div shellContainerSize #box=\"shellContainerSize\">\n * @if (box.atLeast('md')) { <app-filters /> }\n * <span>{{ box.size() }}</span>\n * </div>\n * ```\n *\n * Also mirrors the bucket onto the host as `data-shell-size` and the raw width\n * as `--shell-container-width`, and makes the host a CSS query container, so\n * plain CSS can react without a media query:\n *\n * ```scss\n * [data-shell-size='xs'] .toolbar__label { display: none; }\n * ```\n *\n * Provides itself as the enclosing `SHELL_REGION`, so nested slot outlets pick\n * the nearest measured ancestor.\n */\n@Directive({\n selector: '[shellContainerSize]',\n exportAs: 'shellContainerSize',\n host: {\n '[attr.data-shell-size]': 'size()',\n '[style.container-type]': '\"inline-size\"',\n '[style.--shell-container-width]': 'cssWidth()',\n },\n providers: [{ provide: SHELL_REGION, useExisting: ContainerSizeDirective }],\n})\nexport class ContainerSizeDirective implements ShellRegion {\n /** Optional name, purely for debugging: `shellContainerSize=\"toolbar\"`. */\n readonly label = input('', { alias: 'shellContainerSize' });\n\n private readonly region = measureRegion(inject<ElementRef<HTMLElement>>(ElementRef));\n\n readonly regionWidth: Signal<number | null> = this.region.width;\n readonly size: Signal<ShellSize> = this.region.size;\n readonly regionSize: Signal<ShellSize> = this.size;\n\n protected readonly cssWidth = computed(() => {\n const width = this.regionWidth();\n return width === null ? null : `${width}px`;\n });\n\n get regionName(): string {\n return this.label() || 'container';\n }\n\n atLeast(min: ShellSize): boolean {\n return atLeast(this.size(), min);\n }\n\n atMost(max: ShellSize): boolean {\n return atMost(this.size(), max);\n }\n\n below(bound: ShellSize): boolean {\n return isBelow(this.size(), bound);\n }\n}\n","import { Injectable, Signal, computed, signal } from '@angular/core';\nimport type { ShellSize, ShellSlotName } from '../core/shell.types';\nimport { atLeast, atMost } from '../responsive/shell-size';\nimport type { ShellSlotDirective } from './shell-slot.directive';\n\n/** Reactive index of every registered slot template, keyed by name. */\n@Injectable({ providedIn: 'root' })\nexport class ShellSlotRegistry {\n private readonly slots = signal<readonly ShellSlotDirective[]>([]);\n private readonly byName = new Map<string, Signal<readonly ShellSlotDirective[]>>();\n\n register(slot: ShellSlotDirective): void {\n this.slots.update((current) => [...current, slot]);\n }\n\n unregister(slot: ShellSlotDirective): void {\n this.slots.update((current) => current.filter((candidate) => candidate !== slot));\n }\n\n /** All templates for a slot, ordered. Memoised per name. */\n all(name: ShellSlotName): Signal<readonly ShellSlotDirective[]> {\n let entry = this.byName.get(name);\n if (!entry) {\n entry = computed(() =>\n this.slots()\n .filter((slot) => slot.name() === name)\n .sort((a, b) => a.order() - b.order()),\n );\n this.byName.set(name, entry);\n }\n return entry;\n }\n\n /** Templates that fit the given region size. */\n visible(name: ShellSlotName, size: ShellSize): readonly ShellSlotDirective[] {\n return this.all(name)().filter((slot) => fits(slot, size));\n }\n\n /** Templates that do not fit but asked to be kept via the overflow menu. */\n overflowing(name: ShellSlotName, size: ShellSize): readonly ShellSlotDirective[] {\n return this.all(name)().filter((slot) => !fits(slot, size) && slot.overflow());\n }\n}\n\nfunction fits(slot: ShellSlotDirective, size: ShellSize): boolean {\n return atLeast(size, slot.minSize()) && atMost(size, slot.maxSize());\n}\n","import {\n DestroyRef,\n Directive,\n TemplateRef,\n effect,\n inject,\n input,\n isDevMode,\n numberAttribute,\n untracked,\n} from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSize, ShellSlotContext, ShellSlotName } from '../core/shell.types';\nimport { ShellSlotRegistry } from './shell-slot-registry';\n\n/**\n * Declares a piece of shell chrome.\n *\n * ```html\n * <ng-template shellSlot=\"search\" slotMinSize=\"md\" slotOverflow>\n * <app-global-search />\n * </ng-template>\n * ```\n *\n * Templates register themselves with a root registry, so a slot can be\n * contributed from anywhere — the app root, a routed page, a feature\n * component — and it does not need to be a DOM child of `<app-shell>`.\n * That is also what allows the same template to be rendered in the topbar on a\n * wide screen and inside the overflow menu on a narrow one.\n */\n@Directive({\n selector: 'ng-template[shellSlot]',\n})\nexport class ShellSlotDirective {\n /** Target slot. Unknown names are fine; render them with `<shell-slot-outlet>`. */\n readonly name = input.required<ShellSlotName>({ alias: 'shellSlot' });\n\n /** Ascending render order within the slot. Contribute several templates freely. */\n readonly order = input(0, { alias: 'slotOrder', transform: numberAttribute });\n\n /** Render only when the *region* has at least this much room. */\n readonly minSize = input<ShellSize>('xs', { alias: 'slotMinSize' });\n\n /** Render only up to this region size — for narrow-only affordances. */\n readonly maxSize = input<ShellSize>('xl', { alias: 'slotMaxSize' });\n\n /**\n * When the region is too narrow, move the content into the overflow menu\n * instead of dropping it. Off by default: dropping is the right answer for\n * decorative chrome, moving is the right answer for actions. Only slots in\n * `config.overflowSlots` have an overflow menu.\n */\n readonly overflow = input(false, {\n alias: 'slotOverflow',\n transform: (value: boolean | '') => value !== false,\n });\n\n readonly template: TemplateRef<ShellSlotContext> = inject(TemplateRef);\n\n private readonly registry = inject(ShellSlotRegistry);\n\n constructor() {\n this.registry.register(this);\n inject(DestroyRef).onDestroy(() => this.registry.unregister(this));\n\n if (isDevMode()) {\n this.warnOnUnsupportedOverflow();\n }\n }\n\n /** Type guard for `let-` context inference in the template. */\n static ngTemplateContextGuard(\n _directive: ShellSlotDirective,\n _context: unknown,\n ): _context is ShellSlotContext {\n return true;\n }\n\n /**\n * `slotOverflow` on a slot the topbar never scans is silently ignored at\n * runtime; say so during development. Inputs are only readable once bound,\n * hence the effect. Config is read untracked so runtime `configure()` calls\n * do not repeat the warning.\n */\n private warnOnUnsupportedOverflow(): void {\n const store = inject(ShellStore);\n effect(() => {\n const name = this.name();\n if (!this.overflow()) {\n return;\n }\n const overflowSlots = untracked(() => {\n const config = store.config();\n return [...config.overflowSlots, ...config.subheader.overflowSlots];\n });\n if (!overflowSlots.includes(name)) {\n console.warn(\n `[app-shell] slotOverflow on \"${name}\" has no effect: only slots listed in ` +\n `config.overflowSlots or config.subheader.overflowSlots (${overflowSlots.join(', ')}) ` +\n `have an overflow menu. Add \"${name}\" to one of them, or render it with your own ` +\n `<shell-slot-outlet select=\"overflow\">.`,\n );\n }\n });\n }\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, Signal, computed, inject, input } from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSlotContext, ShellSlotName, ShellSize } from '../core/shell.types';\nimport { SHELL_REGION } from '../responsive/shell-region';\nimport { ShellSlotDirective } from './shell-slot.directive';\nimport { ShellSlotRegistry } from './shell-slot-registry';\n\n/**\n * Renders the templates registered for a slot.\n *\n * Size filtering uses the nearest measured region, falling back to the shell\n * itself — which is why a topbar squeezed by a wide sidebar collapses its\n * contents even though the window never changed.\n */\n@Component({\n selector: 'shell-slot-outlet',\n imports: [NgTemplateOutlet],\n template: `\n @for (slot of slots(); track slot) {\n <ng-container *ngTemplateOutlet=\"slot.template; context: context()\" />\n }\n `,\n styles: `\n :host {\n display: flex;\n align-items: center;\n min-inline-size: 0;\n }\n :host([hidden]) {\n display: none;\n }\n `,\n host: {\n '[attr.data-slot]': 'name()',\n // Collapse to nothing when unfilled, so a region's gaps never show as\n // phantom spacing for a slot the app never provided.\n '[hidden]': '!slots().length',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellSlotOutletComponent {\n readonly name = input.required<ShellSlotName>();\n\n /** `visible` renders what fits; `overflow` renders what did not fit. */\n readonly select = input<'visible' | 'overflow'>('visible');\n\n /** Overrides the measured region size. Mostly for tests. */\n readonly size = input<ShellSize | null>(null);\n\n private readonly registry = inject(ShellSlotRegistry);\n private readonly store = inject(ShellStore);\n private readonly region = inject(SHELL_REGION, { optional: true });\n\n private readonly effectiveSize: Signal<ShellSize> = computed(\n () => this.size() ?? this.region?.regionSize() ?? this.store.size(),\n );\n\n readonly slots: Signal<readonly ShellSlotDirective[]> = computed(() =>\n this.select() === 'overflow'\n ? this.registry.overflowing(this.name(), this.effectiveSize())\n : this.registry.visible(this.name(), this.effectiveSize()),\n );\n\n readonly context: Signal<ShellSlotContext> = computed(() => {\n const sidebar = this.store.sidebar();\n return {\n $implicit: sidebar,\n sidebar,\n size: this.store.size(),\n region: this.effectiveSize(),\n overflow: this.select() === 'overflow',\n shell: this.store,\n };\n });\n}\n","import { Signal, computed, inject } from '@angular/core';\nimport type { ShellSlotName } from '../core/shell.types';\nimport { ShellSlotRegistry } from './shell-slot-registry';\n\n/**\n * `true` when at least one template is registered for a slot — lets a region\n * skip its wrapper markup (and its padding) instead of rendering an empty box.\n * Call from an injection context.\n */\nexport function hasSlot(...names: readonly ShellSlotName[]): Signal<boolean> {\n const registry = inject(ShellSlotRegistry);\n return computed(() => names.some((name) => registry.all(name)().length > 0));\n}\n","import type { TemplateRef } from '@angular/core';\n\n/**\n * Route `data` key for a level's label: a string (static, or produced by a\n * resolver under `resolve: { breadcrumb: … }`), or `false` to skip the level.\n */\nexport const BREADCRUMB_DATA_KEY = 'breadcrumb';\n\n/** Route `data` key that forces the breadcrumb row on (`true`) or off (`false`) for a page. */\nexport const SUBHEADER_DATA_KEY = 'subheader';\n\n/** One level of the trail. */\nexport interface ShellCrumb {\n /** `null` while the label is still loading: the crumb renders as a placeholder. */\n readonly label: string | null;\n readonly url: string;\n /** The page the user is on: rendered as text with `aria-current=\"page\"`, not as a link. */\n readonly current: boolean;\n}\n\n/**\n * How the trail is laid out:\n * `full` — every level (the middle folds into \"…\" beyond `maxItems`);\n * `compact` — first › … › parent › current;\n * `back` — a single \"‹ Parent\" link.\n */\nexport type ShellBreadcrumbDisplay = 'full' | 'compact' | 'back';\n\n/** Context of a custom `[itemTemplate]` on `<shell-breadcrumb>`. */\nexport interface ShellCrumbContext {\n readonly $implicit: ShellCrumb;\n readonly crumb: ShellCrumb;\n}\n\nexport type ShellCrumbTemplate = TemplateRef<ShellCrumbContext>;\n","import { DestroyRef, Injectable, Signal, computed, inject, isSignal, signal } from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { ActivatedRoute, ActivatedRouteSnapshot, NavigationEnd, Router } from '@angular/router';\nimport { filter } from 'rxjs';\nimport { ShellStore } from '../core/shell.store';\nimport { BREADCRUMB_DATA_KEY, SUBHEADER_DATA_KEY, type ShellCrumb } from './breadcrumb.types';\n\n/** A label, or a signal of one that is `undefined` while it loads. */\nexport type ShellBreadcrumbLabel = string | Signal<string | undefined>;\n\n/** One URL level of the active route tree. */\ninterface RouteLevel {\n readonly url: string;\n /** The route's own `data.breadcrumb` (static or resolved), if it declares one. */\n readonly label: string | undefined;\n /** The route's own resolved `title`, if it declares one. */\n readonly title: string | undefined;\n}\n\ninterface LabelOverride {\n /** The route whose level this labels; `null` = whichever level is current. */\n readonly route: ActivatedRoute | null;\n readonly label: ShellBreadcrumbLabel;\n}\n\nconst NO_OVERRIDE = Symbol('no-override');\n\nfunction urlOf(snapshot: ActivatedRouteSnapshot): string {\n const segments = snapshot.pathFromRoot.flatMap((route) => route.url.map((part) => part.path));\n return `/${segments.join('/')}`;\n}\n\nfunction readLabel(label: ShellBreadcrumbLabel): string | undefined {\n return isSignal(label) ? label() : label;\n}\n\n/**\n * The breadcrumb trail, derived from the router.\n *\n * On every `NavigationEnd` it walks the active (primary) route tree. Each\n * route that consumes URL segments is one level, labelled by — in order — a\n * page override, the route's own `data.breadcrumb` (static or resolved), or\n * its own `title`. Only what a route declares *itself* counts: Angular copies\n * `data` from componentless and empty-path parents into children, and a child\n * must not borrow its parent's label.\n */\n@Injectable({ providedIn: 'root' })\nexport class ShellBreadcrumbStore {\n private readonly router = inject(Router, { optional: true });\n private readonly shell = inject(ShellStore);\n\n private readonly levels = signal<readonly RouteLevel[]>([]);\n private readonly routeSubheader = signal<boolean | undefined>(undefined);\n private readonly overrides = signal<readonly LabelOverride[]>([]);\n\n /** Labelled levels of the current route, before the home/current options. */\n private readonly trail = computed<readonly ShellCrumb[]>(() => {\n const levels = this.levels();\n const overrides = this.overrides();\n const useTitle = this.shell.config().breadcrumbs.useRouteTitle;\n const crumbs: ShellCrumb[] = [];\n\n levels.forEach((level, index) => {\n const override = this.overrideFor(level.url, index === levels.length - 1, overrides);\n const label =\n override === NO_OVERRIDE\n ? (level.label ?? (useTitle ? level.title : undefined))\n : (override ?? null);\n if (label !== undefined) {\n crumbs.push({ label, url: level.url, current: false });\n }\n });\n\n const last = crumbs.length - 1;\n if (last >= 0) {\n crumbs[last] = { ...crumbs[last], current: true };\n }\n return crumbs;\n });\n\n /** The trail to render, with `breadcrumbs.includeHome` / `includeCurrent` applied. */\n readonly crumbs: Signal<readonly ShellCrumb[]> = computed(() => {\n const options = this.shell.config().breadcrumbs;\n let crumbs = [...this.trail()];\n if (options.includeHome && crumbs[0]?.url !== options.homeUrl) {\n crumbs.unshift({ label: options.homeLabel, url: options.homeUrl, current: crumbs.length === 0 });\n }\n if (!options.includeCurrent) {\n crumbs = crumbs.filter((crumb) => !crumb.current);\n }\n return crumbs;\n });\n\n /** Labelled levels in the current route; the home crumb is not counted. */\n readonly depth: Signal<number> = computed(() => this.trail().length);\n\n /** `data.subheader` of the deepest route that declares it, if any. */\n readonly subheaderOverride: Signal<boolean | undefined> = this.routeSubheader.asReadonly();\n\n constructor() {\n this.router?.events\n .pipe(\n filter((event) => event instanceof NavigationEnd),\n takeUntilDestroyed(),\n )\n .subscribe(() => this.refresh());\n this.refresh();\n }\n\n /**\n * Label one level from code — for names only the page knows, e.g. a record\n * loaded without a resolver. `route` picks the level ending at that route's\n * URL; `null` labels the current level. While a signal label is `undefined`\n * the crumb renders as a placeholder. Returns a function that removes the\n * label again; prefer `contributeBreadcrumbLabel()`, which does so for you.\n */\n setLabel(label: ShellBreadcrumbLabel, route: ActivatedRoute | null = null): () => void {\n const entry: LabelOverride = { route, label };\n this.overrides.update((current) => [...current, entry]);\n return () =>\n this.overrides.update((current) => current.filter((candidate) => candidate !== entry));\n }\n\n /** The latest override for a level, `undefined` while pending, or `NO_OVERRIDE`. */\n private overrideFor(\n url: string,\n isCurrent: boolean,\n overrides: readonly LabelOverride[],\n ): string | undefined | typeof NO_OVERRIDE {\n for (let index = overrides.length - 1; index >= 0; index--) {\n const { route, label } = overrides[index];\n const matches = route ? urlOf(route.snapshot) === url : isCurrent;\n if (matches) {\n return readLabel(label);\n }\n }\n return NO_OVERRIDE;\n }\n\n private refresh(): void {\n const router = this.router;\n if (!router) {\n return;\n }\n const levels: RouteLevel[] = [];\n const segments: string[] = [];\n let subheader: boolean | undefined;\n\n for (\n let route: ActivatedRouteSnapshot | null = router.routerState.snapshot.root;\n route;\n route = route.firstChild\n ) {\n const config = route.routeConfig;\n const declaresLabel =\n config?.data?.[BREADCRUMB_DATA_KEY] !== undefined ||\n config?.resolve?.[BREADCRUMB_DATA_KEY] !== undefined;\n const label: unknown = declaresLabel ? route.data[BREADCRUMB_DATA_KEY] : undefined;\n const flag: unknown = config?.data?.[SUBHEADER_DATA_KEY];\n if (typeof flag === 'boolean') {\n subheader = flag;\n }\n\n segments.push(...route.url.map((part) => part.path));\n // Empty-path routes add no level; `breadcrumb: false` removes one.\n if (route.url.length > 0 && label !== false) {\n levels.push({\n url: `/${segments.join('/')}`,\n label: typeof label === 'string' ? label : undefined,\n title: config?.title !== undefined ? route.title : undefined,\n });\n }\n }\n\n this.levels.set(levels);\n this.routeSubheader.set(subheader);\n }\n}\n\n/**\n * Label the calling page's own level of the trail, for as long as the page\n * lives. Call from a routed component's injection context:\n *\n * ```ts\n * export class ProjectPage {\n * readonly name = signal<string | undefined>(undefined); // set when loaded\n * constructor() { contributeBreadcrumbLabel(this.name); }\n * }\n * ```\n *\n * While the signal is `undefined` the crumb is a placeholder; the breadcrumb\n * row has reserved its height, so nothing shifts when the name arrives.\n */\nexport function contributeBreadcrumbLabel(label: ShellBreadcrumbLabel): void {\n const route = inject(ActivatedRoute, { optional: true });\n const remove = inject(ShellBreadcrumbStore).setLabel(label, route);\n inject(DestroyRef).onDestroy(remove);\n}\n","import { ChangeDetectionStrategy, Component, ElementRef, Signal, inject } from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSize } from '../core/shell.types';\nimport { measureRegion } from '../responsive/measure-region';\nimport { SHELL_REGION, ShellRegion } from '../responsive/shell-region';\nimport { ShellSlotOutletComponent } from '../slots/shell-slot-outlet.component';\n\n/**\n * Footer strip. Three slots so the common \"legal start, meta end\" pattern\n * needs no markup of its own, and so a status bar can occupy the middle.\n * Measures itself, because its width depends on the layout and the sidebar.\n */\n@Component({\n selector: 'shell-footer',\n templateUrl: './shell-footer.component.html',\n styleUrl: './shell-footer.component.scss',\n imports: [ShellSlotOutletComponent],\n host: {\n role: 'contentinfo',\n '[attr.data-shell-size]': 'regionSize()',\n '[attr.data-variant]': 'store.config().appearance.footer',\n },\n providers: [{ provide: SHELL_REGION, useExisting: ShellFooterComponent }],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellFooterComponent implements ShellRegion {\n private readonly region = measureRegion(inject<ElementRef<HTMLElement>>(ElementRef));\n\n protected readonly store = inject(ShellStore);\n\n readonly regionName = 'footer';\n readonly regionWidth: Signal<number | null> = this.region.width;\n readonly regionSize: Signal<ShellSize> = this.region.size;\n}\n","<shell-slot-outlet name=\"footer-start\" class=\"footer__slot\" />\n<shell-slot-outlet name=\"footer\" class=\"footer__slot footer__slot--main\" />\n<shell-slot-outlet name=\"footer-end\" class=\"footer__slot\" />\n","const FOCUSABLE = [\n 'a[href]',\n 'button:not([disabled])',\n 'input:not([disabled]):not([type=\"hidden\"])',\n 'select:not([disabled])',\n 'textarea:not([disabled])',\n '[tabindex]:not([tabindex=\"-1\"])',\n '[contenteditable=\"true\"]',\n].join(',');\n\nfunction focusable(root: HTMLElement): HTMLElement[] {\n return Array.from(root.querySelectorAll<HTMLElement>(FOCUSABLE)).filter(\n (element) =>\n !element.hasAttribute('inert') &&\n element.offsetWidth + element.offsetHeight > 0 &&\n getComputedStyle(element).visibility !== 'hidden',\n );\n}\n\nexport interface FocusTrapHandle {\n release(): void;\n}\n\n/**\n * Keeps Tab inside `root` while a modal drawer is open and restores focus to\n * whatever was focused before. Small on purpose: no dependency on the CDK, and\n * the only behaviours a navigation drawer needs.\n */\nexport function trapFocus(root: HTMLElement, options: { restoreTo?: HTMLElement | null } = {}): FocusTrapHandle {\n const previous = options.restoreTo ?? (document.activeElement as HTMLElement | null);\n\n const onKeydown = (event: KeyboardEvent) => {\n if (event.key !== 'Tab') {\n return;\n }\n const items = focusable(root);\n if (!items.length) {\n event.preventDefault();\n root.focus();\n return;\n }\n const first = items[0];\n const last = items[items.length - 1];\n const active = document.activeElement as HTMLElement | null;\n\n if (event.shiftKey && (active === first || !root.contains(active))) {\n event.preventDefault();\n last.focus();\n } else if (!event.shiftKey && active === last) {\n event.preventDefault();\n first.focus();\n }\n };\n\n root.addEventListener('keydown', onKeydown);\n // Focus the first control, or the panel itself when it has none yet.\n (focusable(root)[0] ?? root).focus({ preventScroll: true });\n\n return {\n release() {\n root.removeEventListener('keydown', onKeydown);\n previous?.focus?.({ preventScroll: true });\n },\n };\n}\n","import { Directive, computed, inject } from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\nimport { SHELL_SIDEBAR_ID } from '../core/shell.ids';\n\n/**\n * Drop-in toggle. Works anywhere in the app — header, page, command palette —\n * because it talks to the root store rather than to a parent component.\n *\n * ```html\n * <button shellSidebarToggle class=\"icon-button\">☰</button>\n * ```\n *\n * Sets `aria-expanded`, `aria-controls` and an accessible label that tracks the\n * current mode, so the same button reads correctly as a hamburger on mobile and\n * as a collapse control on desktop.\n */\n@Directive({\n selector: 'button[shellSidebarToggle]',\n exportAs: 'shellSidebarToggle',\n host: {\n type: 'button',\n '[attr.aria-controls]': 'sidebarId',\n '[attr.aria-expanded]': 'expanded()',\n '[attr.aria-label]': 'label()',\n '[attr.title]': 'label()',\n '[attr.data-sidebar-mode]': 'store.sidebar().mode',\n '(click)': 'store.toggleSidebar()',\n },\n})\nexport class SidebarToggleDirective {\n protected readonly store = inject(ShellStore);\n protected readonly sidebarId = SHELL_SIDEBAR_ID;\n\n /** True when the sidebar is showing its full, labelled panel. */\n readonly expanded = computed(() => {\n const state = this.store.sidebar();\n return state.mode === 'expanded' || (state.mode === 'overlay' && state.open);\n });\n\n readonly label = computed(() => {\n const labels = this.store.config().labels;\n const state = this.store.sidebar();\n if (state.mode === 'overlay') {\n return state.open ? labels.closeNavigation : labels.openNavigation;\n }\n return this.expanded() ? labels.collapseSidebar : labels.expandSidebar;\n });\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Signal,\n booleanAttribute,\n computed,\n effect,\n inject,\n input,\n viewChild,\n} from '@angular/core';\nimport { FocusTrapHandle, trapFocus } from '../a11y/focus-trap';\nimport { SidebarToggleDirective } from '../directives/sidebar-toggle.directive';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSize, SidebarState } from '../core/shell.types';\nimport { observeWidth } from '../responsive/observe-width';\nimport { SHELL_REGION, ShellRegion } from '../responsive/shell-region';\nimport { hasSlot } from '../slots/has-slot';\nimport { ShellSlotOutletComponent } from '../slots/shell-slot-outlet.component';\n\nconst RESIZE_STEP = 16;\nconst RESIZE_STEP_LARGE = 48;\n\n/**\n * Sidebar with four modes — `expanded`, `collapsed` (icon rail), `overlay`\n * (modal drawer) and `hidden` — chosen by the injected `SidebarBehavior`\n * rather than by this component. All this class does is render the resolved\n * state and handle the mechanics each mode needs: peek timing, focus trapping,\n * Escape, and drag-to-resize.\n *\n * Slot order, top to bottom:\n *\n * sidebar-header brand, workspace or account switcher\n * sidebar-action one primary action (\"New\", \"Compose\")\n * sidebar-search quick find / command palette launcher\n * sidebar-nav the scrolling navigation (grows)\n * sidebar-secondary settings, help, upgrade prompts\n * sidebar-footer user card, storage meter — shares a row with the collapse control\n */\n@Component({\n selector: 'shell-sidebar',\n templateUrl: './shell-sidebar.component.html',\n styleUrl: './shell-sidebar.component.scss',\n imports: [ShellSlotOutletComponent, SidebarToggleDirective],\n host: {\n '[attr.data-mode]': 'state().mode',\n '[attr.data-open]': 'state().open',\n '[attr.data-labels]': 'state().labels',\n '[attr.data-peeked]': 'state().peeked',\n '[attr.data-shell-size]': 'regionSize()',\n '[attr.data-resizing]': 'store.resizing() || null',\n '[attr.data-variant]': 'config().appearance.sidebar',\n '[attr.data-drawer-motion]': 'config().motion.drawer',\n '[attr.inert]': 'state().open ? null : \"\"',\n },\n providers: [{ provide: SHELL_REGION, useExisting: ShellSidebarComponent }],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellSidebarComponent implements ShellRegion {\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly panel = viewChild<ElementRef<HTMLElement>>('panel');\n\n protected readonly store = inject(ShellStore);\n protected readonly config = this.store.config;\n\n /** Render the built-in expand/collapse control in the footer row. */\n readonly collapseControl = input(true, { transform: booleanAttribute });\n\n readonly regionName = 'sidebar';\n\n /**\n * Measured on the *panel*, not the host: during a peek the panel is wider\n * than the grid track it lives in. Exposed as `--shell-container-width`.\n */\n readonly regionWidth: Signal<number | null> = observeWidth(this.panel);\n\n /**\n * The sidebar reports a *semantic* bucket rather than a measured one. Its\n * panel is a few hundred pixels wide in every mode, so raw widths would put\n * it permanently in `xs` and make `slotMinSize` useless. The contract is:\n *\n * rail (icons only) → `xs`\n * panel / drawer (labels on) → `md`\n *\n * so `slotMinSize=\"sm\"` on a sidebar slot reads as \"only when labels show\".\n */\n readonly regionSize: Signal<ShellSize> = computed(() => (this.state().labels ? 'md' : 'xs'));\n\n protected readonly state: Signal<SidebarState> = this.store.sidebar;\n protected readonly hasHeader = hasSlot('sidebar-header');\n protected readonly hasSecondary = hasSlot('sidebar-secondary');\n private readonly hasFooterSlot = hasSlot('sidebar-footer');\n\n /** The collapse control only makes sense for persistent panels. */\n protected readonly showCollapse = computed(() => {\n const mode = this.state().mode;\n return this.collapseControl() && (mode === 'expanded' || mode === 'collapsed');\n });\n\n protected readonly showFooter = computed(() => this.hasFooterSlot() || this.showCollapse());\n\n protected readonly containerWidth = computed(() => {\n const width = this.regionWidth();\n return width === null ? null : `${width}px`;\n });\n\n /** Peek only makes sense on a rail, and only when configured. */\n private readonly peekable = computed(\n () => this.config().sidebar.peek && this.state().mode === 'collapsed',\n );\n\n protected readonly resizable = computed(\n () => this.config().sidebar.resizable && this.state().mode === 'expanded',\n );\n\n /** Current panel width in px for `aria-valuenow` and keyboard steps. */\n protected readonly resizeValue = computed(\n () => this.store.sidebarWidth() ?? this.regionWidth() ?? this.config().sidebar.minWidth,\n );\n\n constructor() {\n // Trap focus for as long as the drawer is modal, and hand focus back on close.\n effect((onCleanup) => {\n const element = this.panel()?.nativeElement;\n if (!this.state().modal || !element) {\n return;\n }\n let handle: FocusTrapHandle | undefined;\n const frame = requestAnimationFrame(() => (handle = trapFocus(element)));\n onCleanup(() => {\n cancelAnimationFrame(frame);\n handle?.release();\n });\n });\n }\n\n // ── Peek ──────────────────────────────────────────────────────────────────\n\n protected onPointerEnter(): void {\n if (this.peekable()) {\n this.store.requestPeek(true);\n }\n }\n\n protected onPointerLeave(): void {\n if (!this.store.resizing()) {\n this.store.requestPeek(false);\n }\n }\n\n /** Keyboard users get the same peek: focus entering the rail widens it. */\n protected onFocusIn(): void {\n if (this.peekable()) {\n this.store.requestPeek(true);\n }\n }\n\n protected onFocusOut(event: FocusEvent): void {\n const next = event.relatedTarget as Node | null;\n if (!next || !this.panel()?.nativeElement.contains(next)) {\n this.store.requestPeek(false);\n }\n }\n\n protected onEscape(): void {\n if (this.state().modal) {\n this.store.closeSidebar();\n }\n }\n\n // ── Resize ────────────────────────────────────────────────────────────────\n\n protected onResizeStart(event: PointerEvent): void {\n if (event.button !== 0) {\n return;\n }\n event.preventDefault();\n (event.currentTarget as HTMLElement).setPointerCapture(event.pointerId);\n this.store.setResizing(true);\n }\n\n protected onResizeMove(event: PointerEvent): void {\n const panel = this.panel()?.nativeElement;\n if (!this.store.resizing() || !panel) {\n return;\n }\n // Measured from the grid track (the host), not the panel: a floating panel\n // is inset from its track, and the handle must stay under the pointer.\n const track = this.host.nativeElement.getBoundingClientRect();\n const inset = Number.parseFloat(getComputedStyle(panel).marginInlineEnd) || 0;\n const offset = this.isRtl(panel) ? track.right - event.clientX : event.clientX - track.left;\n this.store.setSidebarWidth(offset + inset, { persist: false });\n }\n\n protected onResizeEnd(event: PointerEvent): void {\n const handle = event.currentTarget as HTMLElement;\n if (handle.hasPointerCapture(event.pointerId)) {\n handle.releasePointerCapture(event.pointerId);\n }\n if (this.store.resizing()) {\n this.store.setResizing(false);\n this.store.setSidebarWidth(this.store.sidebarWidth());\n }\n }\n\n protected onResizeKey(event: KeyboardEvent): void {\n const panel = this.panel()?.nativeElement;\n if (!panel) {\n return;\n }\n const { minWidth, maxWidth } = this.config().sidebar;\n const step = event.shiftKey ? RESIZE_STEP_LARGE : RESIZE_STEP;\n // \"Right\" grows the panel in LTR and shrinks it in RTL.\n const grow = this.isRtl(panel) ? -step : step;\n const current = this.resizeValue();\n\n let next: number;\n switch (event.key) {\n case 'ArrowRight':\n next = current + grow;\n break;\n case 'ArrowLeft':\n next = current - grow;\n break;\n case 'Home':\n next = minWidth;\n break;\n case 'End':\n next = maxWidth;\n break;\n default:\n return;\n }\n event.preventDefault();\n this.store.setSidebarWidth(next);\n }\n\n /** Double-click the handle to return to the configured width. */\n protected onResizeReset(): void {\n this.store.setSidebarWidth(null);\n }\n\n private isRtl(element: HTMLElement): boolean {\n return getComputedStyle(element).direction === 'rtl';\n }\n}\n","<!--\n `aside` wraps the panel so the drawer can slide and the rail can peek without\n moving the grid track. Everything below reads from one resolved state object.\n-->\n<aside\n #panel\n class=\"sidebar__panel\"\n [style.--shell-sidebar-panel-width]=\"state().panelWidth\"\n [style.--shell-container-width]=\"containerWidth()\"\n [attr.role]=\"state().modal ? 'dialog' : null\"\n [attr.aria-modal]=\"state().modal ? 'true' : null\"\n [attr.aria-label]=\"state().modal ? config().labels.primaryNavigation : null\"\n [attr.tabindex]=\"state().modal ? -1 : null\"\n (keydown.escape)=\"onEscape()\"\n (pointerenter)=\"onPointerEnter()\"\n (pointerleave)=\"onPointerLeave()\"\n (focusin)=\"onFocusIn()\"\n (focusout)=\"onFocusOut($event)\"\n>\n @if (hasHeader()) {\n <div class=\"sidebar__header\">\n <shell-slot-outlet name=\"sidebar-header\" class=\"sidebar__header-slot\" />\n </div>\n }\n\n <shell-slot-outlet name=\"sidebar-action\" class=\"sidebar__block\" />\n <shell-slot-outlet name=\"sidebar-search\" class=\"sidebar__block\" />\n\n <nav class=\"sidebar__nav\" [attr.aria-label]=\"config().labels.primaryNavigation\">\n <shell-slot-outlet name=\"sidebar-nav\" class=\"sidebar__block\" />\n </nav>\n\n @if (hasSecondary()) {\n <shell-slot-outlet name=\"sidebar-secondary\" class=\"sidebar__block sidebar__secondary\" />\n }\n\n @if (showFooter()) {\n <div class=\"sidebar__footer\">\n <shell-slot-outlet name=\"sidebar-footer\" class=\"sidebar__footer-slot\" />\n\n @if (showCollapse()) {\n <button shellSidebarToggle class=\"sidebar__collapse\">\n <span class=\"sidebar__collapse-glyph\" aria-hidden=\"true\"></span>\n </button>\n }\n </div>\n }\n\n @if (resizable()) {\n <div\n class=\"sidebar__resizer\"\n role=\"separator\"\n aria-orientation=\"vertical\"\n tabindex=\"0\"\n [attr.aria-label]=\"config().labels.resizeSidebar\"\n [attr.aria-valuemin]=\"config().sidebar.minWidth\"\n [attr.aria-valuemax]=\"config().sidebar.maxWidth\"\n [attr.aria-valuenow]=\"resizeValue()\"\n (pointerdown)=\"onResizeStart($event)\"\n (pointermove)=\"onResizeMove($event)\"\n (pointerup)=\"onResizeEnd($event)\"\n (pointercancel)=\"onResizeEnd($event)\"\n (keydown)=\"onResizeKey($event)\"\n (dblclick)=\"onResizeReset()\"\n ></div>\n }\n</aside>\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n computed,\n inject,\n input,\n signal,\n viewChild,\n} from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\n\nlet nextId = 0;\n\n/**\n * The shell's ⋯ menu: a disclosure button plus a panel for projected content.\n * Shared by the topbar, the breadcrumb row and the breadcrumb's folded levels,\n * so behaviour, motion and accessibility live in one place.\n *\n * The panel stays mounted so it can animate out as well as in; while closed it\n * is invisible and `inert`. It closes on Escape (returning focus to the\n * trigger), on a press outside, and after a link or button inside is used.\n */\n@Component({\n selector: 'shell-overflow-menu',\n templateUrl: './shell-overflow-menu.component.html',\n styleUrl: './shell-overflow-menu.component.scss',\n host: {\n '[attr.data-align]': 'align()',\n '[attr.data-menu-motion]': 'motion()',\n '(keydown.escape)': 'close(true)',\n '(document:pointerdown)': 'onDocumentPointerDown($event)',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellOverflowMenuComponent {\n /** Accessible name and tooltip of the trigger. */\n readonly label = input.required<string>();\n /** Which edge of the trigger the panel lines up with. */\n readonly align = input<'start' | 'end'>('end');\n\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly trigger = viewChild.required<ElementRef<HTMLButtonElement>>('trigger');\n private readonly store = inject(ShellStore);\n\n protected readonly motion = computed(() => this.store.config().motion.overflowMenu);\n protected readonly panelId = `shell-overflow-menu-${nextId++}`;\n\n private readonly openState = signal(false);\n readonly open = this.openState.asReadonly();\n\n toggle(): void {\n this.openState.update((open) => !open);\n }\n\n close(restoreFocus = false): void {\n if (!this.openState()) {\n return;\n }\n this.openState.set(false);\n if (restoreFocus) {\n this.trigger().nativeElement.focus();\n }\n }\n\n protected onDocumentPointerDown(event: Event): void {\n if (!this.host.nativeElement.contains(event.target as Node)) {\n this.close();\n }\n }\n\n /** Activating anything inside the menu is a choice; close behind it. */\n protected onPanelClick(event: Event): void {\n if ((event.target as Element).closest('a[href], button:not([aria-haspopup])')) {\n this.close();\n }\n }\n}\n","<button\n #trigger\n type=\"button\"\n class=\"shell-menu__trigger\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"panelId\"\n [attr.aria-label]=\"label()\"\n [attr.title]=\"label()\"\n (click)=\"toggle()\"\n>\n <span class=\"shell-menu__glyph\" aria-hidden=\"true\"></span>\n</button>\n\n<div\n class=\"shell-menu__panel\"\n [id]=\"panelId\"\n [attr.data-open]=\"open()\"\n [attr.inert]=\"open() ? null : ''\"\n (click)=\"onPanelClick($event)\"\n>\n <ng-content />\n</div>\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n computed,\n effect,\n inject,\n input,\n signal,\n} from '@angular/core';\nimport { RouterLink } from '@angular/router';\nimport { ShellStore } from '../core/shell.store';\nimport { ShellOverflowMenuComponent } from '../layout/shell-overflow-menu.component';\nimport { observeWidth } from '../responsive/observe-width';\nimport type { ShellBreadcrumbDisplay, ShellCrumb, ShellCrumbTemplate } from './breadcrumb.types';\nimport { ShellBreadcrumbStore } from './shell-breadcrumb-store';\n\ninterface TrailView {\n readonly head: readonly ShellCrumb[];\n /** Levels folded into the \"…\" menu. */\n readonly hidden: readonly ShellCrumb[];\n readonly tail: readonly ShellCrumb[];\n}\n\n/**\n * Breadcrumb trail, following the WAI-ARIA breadcrumb pattern:\n * `<nav aria-label>` › `<ol>` › links, the current page as text with\n * `aria-current=\"page\"`, and CSS separators that screen readers skip.\n *\n * Renders the router-derived trail from `ShellBreadcrumbStore`, or `[items]`.\n * It measures its own width and shortens itself instead of wrapping:\n * full → middle levels folded into \"…\" → first › … › parent › current →\n * a single \"‹ Parent\" back link.\n */\n@Component({\n selector: 'shell-breadcrumb',\n templateUrl: './shell-breadcrumb.component.html',\n styleUrl: './shell-breadcrumb.component.scss',\n imports: [NgTemplateOutlet, RouterLink, ShellOverflowMenuComponent],\n host: {\n '[attr.data-display]': 'mode()',\n '[attr.data-separator]': 'separator()',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellBreadcrumbComponent {\n /** A manual trail. Leave unset to follow the router. */\n readonly items = input<readonly ShellCrumb[] | null>(null);\n /** Overrides `breadcrumbs.maxItems` for this instance. */\n readonly maxItems = input<number | null>(null);\n /** Force a layout instead of choosing one from the available width. */\n readonly display = input<'auto' | ShellBreadcrumbDisplay>('auto');\n /** Custom crumb content; the link and `aria-current` stay the library's. */\n readonly itemTemplate = input<ShellCrumbTemplate | null>(null);\n\n private readonly store = inject(ShellBreadcrumbStore);\n private readonly shell = inject(ShellStore);\n private readonly width = observeWidth(inject<ElementRef<HTMLElement>>(ElementRef));\n private readonly options = computed(() => this.shell.config().breadcrumbs);\n\n protected readonly separator = computed(() => this.options().separator);\n\n protected readonly labels = computed(() => this.shell.config().labels);\n protected readonly crumbs = computed(() => this.items() ?? this.store.crumbs());\n\n protected readonly mode = computed<ShellBreadcrumbDisplay>(() => {\n const forced = this.display();\n if (forced !== 'auto') {\n return forced;\n }\n const width = this.width();\n if (width === null) {\n return 'full';\n }\n const { backBelow, compactBelow } = this.options();\n return width < backBelow ? 'back' : width < compactBelow ? 'compact' : 'full';\n });\n\n protected readonly view = computed<TrailView>(() => {\n const crumbs = this.crumbs();\n // compact = first › … › parent › current\n const limit =\n this.mode() === 'compact' ? 3 : Math.max(2, this.maxItems() ?? this.options().maxItems);\n if (crumbs.length <= limit) {\n return { head: crumbs, hidden: [], tail: [] };\n }\n const tailCount = limit - 1;\n return {\n head: crumbs.slice(0, 1),\n hidden: crumbs.slice(1, crumbs.length - tailCount),\n tail: crumbs.slice(crumbs.length - tailCount),\n };\n });\n\n /** Target of the \"‹ Parent\" link: the level just above the current page. */\n protected readonly parent = computed<ShellCrumb | null>(() => {\n const crumbs = this.crumbs();\n const current = crumbs.findIndex((crumb) => crumb.current);\n if (current === -1) {\n return crumbs.at(-1) ?? null;\n }\n return current > 0 ? crumbs[current - 1] : null;\n });\n\n protected readonly pending = computed(() => this.crumbs().some((crumb) => crumb.label === null));\n\n /** Fast labels never flash a skeleton: it only shows after `skeletonDelay`. */\n private readonly delayElapsed = signal(false);\n protected readonly skeletonShown = computed(\n () => this.pending() && (this.options().skeletonDelay <= 0 || this.delayElapsed()),\n );\n\n constructor() {\n effect((onCleanup) => {\n if (!this.pending()) {\n this.delayElapsed.set(false);\n return;\n }\n const timer = setTimeout(() => this.delayElapsed.set(true), this.options().skeletonDelay);\n onCleanup(() => clearTimeout(timer));\n });\n }\n}\n","<nav class=\"crumbs\" [attr.aria-label]=\"labels().breadcrumb\">\n @if (mode() === 'back') {\n @if (parent(); as target) {\n <a\n class=\"crumbs__back\"\n [routerLink]=\"target.url\"\n [attr.aria-label]=\"labels().back + ' ' + (target.label ?? '')\"\n >\n <span class=\"crumbs__back-glyph\" aria-hidden=\"true\"></span>\n <ng-container *ngTemplateOutlet=\"labelTemplate; context: { $implicit: target }\" />\n </a>\n } @else if (crumbs()[0]; as only) {\n <span class=\"crumbs__current\" aria-current=\"page\">\n <ng-container *ngTemplateOutlet=\"labelTemplate; context: { $implicit: only }\" />\n </span>\n }\n } @else {\n @let trail = view();\n <ol class=\"crumbs__list\" [attr.aria-busy]=\"pending() ? 'true' : null\">\n @for (crumb of trail.head; track crumb.url) {\n <li class=\"crumbs__item\">\n <ng-container *ngTemplateOutlet=\"crumbTemplate; context: { $implicit: crumb }\" />\n </li>\n }\n\n @if (trail.hidden.length) {\n <li class=\"crumbs__item crumbs__item--more\">\n <shell-overflow-menu class=\"crumbs__more\" align=\"start\" [label]=\"labels().showPath\">\n @for (crumb of trail.hidden; track crumb.url) {\n <a class=\"crumbs__menu-link\" [routerLink]=\"crumb.url\">{{ crumb.label }}</a>\n }\n </shell-overflow-menu>\n </li>\n }\n\n @for (crumb of trail.tail; track crumb.url) {\n <li class=\"crumbs__item\">\n <ng-container *ngTemplateOutlet=\"crumbTemplate; context: { $implicit: crumb }\" />\n </li>\n }\n </ol>\n }\n\n @if (pending()) {\n <span class=\"crumbs__sr\">{{ labels().loading }}</span>\n }\n</nav>\n\n<ng-template #crumbTemplate let-crumb>\n @if (crumb.current) {\n <span class=\"crumbs__current\" aria-current=\"page\">\n <ng-container *ngTemplateOutlet=\"labelTemplate; context: { $implicit: crumb }\" />\n </span>\n } @else {\n <a class=\"crumbs__link\" [routerLink]=\"crumb.url\">\n <ng-container *ngTemplateOutlet=\"labelTemplate; context: { $implicit: crumb }\" />\n </a>\n }\n</ng-template>\n\n<!--\n A pending label is a placeholder: it reserves its width from the start, and\n only becomes a visible skeleton once `skeletonDelay` has passed.\n-->\n<ng-template #labelTemplate let-crumb>\n @if (crumb.label === null) {\n <span class=\"crumbs__skeleton\" [class.crumbs__skeleton--shown]=\"skeletonShown()\" aria-hidden=\"true\"></span>\n } @else if (itemTemplate(); as custom) {\n <ng-container *ngTemplateOutlet=\"custom; context: { $implicit: crumb, crumb: crumb }\" />\n } @else {\n <span class=\"crumbs__label\">{{ crumb.label }}</span>\n }\n</ng-template>\n","import { ChangeDetectionStrategy, Component, ElementRef, Signal, computed, inject } from '@angular/core';\nimport { ShellBreadcrumbComponent } from '../breadcrumbs/shell-breadcrumb.component';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSize, ShellSlotName } from '../core/shell.types';\nimport { measureRegion } from '../responsive/measure-region';\nimport { SHELL_REGION, ShellRegion } from '../responsive/shell-region';\nimport { hasSlot } from '../slots/has-slot';\nimport { ShellSlotOutletComponent } from '../slots/shell-slot-outlet.component';\nimport { ShellSlotRegistry } from '../slots/shell-slot-registry';\nimport { ShellOverflowMenuComponent } from './shell-overflow-menu.component';\n\n/**\n * The breadcrumb row, between the topbar and `main`.\n *\n * [breadcrumb | built-in trail] [subheader-start] ········ [subheader-end] [⋯]\n *\n * A measured region like the topbar: `subheader-end` templates use\n * `slotMinSize` / `slotOverflow` against the row's own width and move into\n * the row's ⋯ menu when they don't fit. Its minimum height is reserved, so\n * labels and actions that arrive late never shift the page.\n */\n@Component({\n selector: 'shell-subheader',\n templateUrl: './shell-subheader.component.html',\n styleUrl: './shell-subheader.component.scss',\n imports: [ShellSlotOutletComponent, ShellBreadcrumbComponent, ShellOverflowMenuComponent],\n host: {\n '[attr.data-shell-size]': 'regionSize()',\n '[attr.data-variant]': 'config().appearance.subheader',\n },\n providers: [{ provide: SHELL_REGION, useExisting: ShellSubheaderComponent }],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellSubheaderComponent implements ShellRegion {\n private readonly region = measureRegion(inject<ElementRef<HTMLElement>>(ElementRef));\n private readonly registry = inject(ShellSlotRegistry);\n\n protected readonly config = inject(ShellStore).config;\n\n readonly regionName = 'subheader';\n readonly regionWidth: Signal<number | null> = this.region.width;\n readonly regionSize: Signal<ShellSize> = this.region.size;\n\n /** An app-provided trail replaces the built-in one. */\n protected readonly customTrail = hasSlot('breadcrumb');\n\n protected readonly overflowSlots = computed(\n () => this.config().subheader.overflowSlots as readonly ShellSlotName[],\n );\n\n protected readonly hasOverflow = computed(() =>\n this.overflowSlots().some(\n (name) => this.registry.overflowing(name, this.regionSize()).length > 0,\n ),\n );\n}\n","<div class=\"subheader__start\">\n @if (customTrail()) {\n <shell-slot-outlet name=\"breadcrumb\" class=\"subheader__slot subheader__trail\" />\n } @else {\n <shell-breadcrumb class=\"subheader__trail\" />\n }\n <shell-slot-outlet name=\"subheader-start\" class=\"subheader__slot\" />\n</div>\n\n<div class=\"subheader__end\">\n <shell-slot-outlet name=\"subheader-end\" class=\"subheader__slot\" />\n\n @if (hasOverflow()) {\n <shell-overflow-menu [label]=\"config().labels.moreActions\">\n @for (name of overflowSlots(); track name) {\n <shell-slot-outlet [name]=\"name\" select=\"overflow\" class=\"subheader__overflow-item\" />\n }\n </shell-overflow-menu>\n }\n</div>\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Signal,\n computed,\n inject,\n} from '@angular/core';\nimport { SidebarToggleDirective } from '../directives/sidebar-toggle.directive';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellSize, ShellSlotName } from '../core/shell.types';\nimport { measureRegion } from '../responsive/measure-region';\nimport { SHELL_REGION, ShellRegion } from '../responsive/shell-region';\nimport { ShellSlotOutletComponent } from '../slots/shell-slot-outlet.component';\nimport { ShellSlotRegistry } from '../slots/shell-slot-registry';\nimport { ShellOverflowMenuComponent } from './shell-overflow-menu.component';\n\n/**\n * Topbar with priority-based slot collapsing.\n *\n * The bar measures **itself**, not the window. That matters: expanding the\n * sidebar from a rail to a full panel takes ~200px away from the topbar without\n * the window ever resizing, and the bar has to respond to that the same way it\n * responds to a phone.\n *\n * Slot order, start to end:\n *\n * [toggle] [topbar-start] [brand] [primary-nav] [title] ····· [search] [actions] [⋯] [account] [topbar-end]\n *\n * Each slot template declares the room it needs (`slotMinSize` / `slotMaxSize`)\n * and what happens when it does not get it (`slotOverflow` → move into the ⋯\n * menu, otherwise drop).\n */\n@Component({\n selector: 'shell-topbar',\n templateUrl: './shell-topbar.component.html',\n styleUrl: './shell-topbar.component.scss',\n imports: [ShellSlotOutletComponent, SidebarToggleDirective, ShellOverflowMenuComponent],\n host: {\n role: 'banner',\n '[attr.data-shell-size]': 'regionSize()',\n '[attr.data-overflow]': 'hasOverflow()',\n '[attr.data-variant]': 'config().appearance.topbar',\n '[attr.data-menu-motion]': 'config().motion.overflowMenu',\n },\n providers: [{ provide: SHELL_REGION, useExisting: ShellTopbarComponent }],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellTopbarComponent implements ShellRegion {\n private readonly registry = inject(ShellSlotRegistry);\n private readonly region = measureRegion(inject<ElementRef<HTMLElement>>(ElementRef));\n\n protected readonly store = inject(ShellStore);\n protected readonly config = this.store.config;\n\n readonly regionName = 'topbar';\n readonly regionWidth: Signal<number | null> = this.region.width;\n readonly regionSize: Signal<ShellSize> = this.region.size;\n\n protected readonly showToggle = computed(() => {\n switch (this.config().topbar.sidebarToggle) {\n case 'never':\n return false;\n case 'auto': {\n const mode = this.store.sidebar().mode;\n return mode === 'overlay' || mode === 'hidden';\n }\n default:\n return true;\n }\n });\n\n protected readonly overflowSlots = computed(\n () => this.config().overflowSlots as readonly ShellSlotName[],\n );\n\n /** The ⋯ menu exists only while something is in it. */\n protected readonly hasOverflow = computed(() =>\n this.overflowSlots().some(\n (name) => this.registry.overflowing(name, this.regionSize()).length > 0,\n ),\n );\n}\n","<div class=\"topbar__group topbar__group--start\">\n @if (showToggle()) {\n <button shellSidebarToggle class=\"topbar__icon-button topbar__toggle\">\n <span class=\"topbar__toggle-glyph\" aria-hidden=\"true\"></span>\n </button>\n }\n\n <shell-slot-outlet name=\"topbar-start\" class=\"topbar__slot\" />\n <shell-slot-outlet name=\"brand\" class=\"topbar__slot topbar__slot--brand\" />\n <shell-slot-outlet name=\"primary-nav\" class=\"topbar__slot topbar__slot--nav\" />\n <shell-slot-outlet name=\"title\" class=\"topbar__slot topbar__slot--title\" />\n</div>\n\n<div class=\"topbar__group topbar__group--end\">\n <shell-slot-outlet name=\"search\" class=\"topbar__slot topbar__slot--search\" />\n <shell-slot-outlet name=\"actions\" class=\"topbar__slot\" />\n\n @if (hasOverflow()) {\n <shell-overflow-menu class=\"topbar__overflow\" [label]=\"config().labels.moreActions\">\n @for (name of overflowSlots(); track name) {\n <shell-slot-outlet [name]=\"name\" select=\"overflow\" class=\"topbar__overflow-item\" />\n }\n </shell-overflow-menu>\n }\n\n <shell-slot-outlet name=\"account\" class=\"topbar__slot\" />\n <shell-slot-outlet name=\"topbar-end\" class=\"topbar__slot\" />\n</div>\n","import { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Signal,\n booleanAttribute,\n computed,\n effect,\n inject,\n input,\n viewChild,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { NavigationEnd, Router } from '@angular/router';\nimport { filter } from 'rxjs';\nimport { ShellBreadcrumbStore } from '../breadcrumbs/shell-breadcrumb-store';\nimport { SHELL_MAIN_ID, SHELL_SIDEBAR_ID } from '../core/shell.ids';\nimport { ShellStore } from '../core/shell.store';\nimport type { ShellLayout, ShellScrollMode, ShellSize, SidebarState } from '../core/shell.types';\nimport { observeWidth } from '../responsive/observe-width';\nimport { SHELL_REGION, ShellRegion } from '../responsive/shell-region';\nimport { hasSlot } from '../slots/has-slot';\nimport { ShellFooterComponent } from './shell-footer.component';\nimport { ShellSidebarComponent } from './shell-sidebar.component';\nimport { ShellSubheaderComponent } from './shell-subheader.component';\nimport { ShellTopbarComponent } from './shell-topbar.component';\n\n/** `undefined` (attribute absent) means \"use the config\"; otherwise a boolean attribute. */\nfunction optionalBoolean(value: unknown): boolean | undefined {\n return value === undefined || value === null ? undefined : booleanAttribute(value);\n}\n\nfunction isEditable(target: EventTarget | null): boolean {\n if (!(target instanceof HTMLElement)) {\n return false;\n }\n return target.isContentEditable || /^(INPUT|TEXTAREA|SELECT)$/.test(target.tagName);\n}\n\n/**\n * The navigational shell: sidebar + topbar + breadcrumb row + main + footer.\n *\n * Layout is a CSS grid whose tracks come from custom properties, so a host app\n * restyles it entirely from CSS. The only value TypeScript writes is the\n * current sidebar track width, which is derived state, not layout maths.\n */\n@Component({\n selector: 'app-shell',\n templateUrl: './app-shell.component.html',\n styleUrl: './app-shell.component.scss',\n imports: [ShellTopbarComponent, ShellSidebarComponent, ShellSubheaderComponent, ShellFooterComponent],\n host: {\n '[attr.data-layout]': 'resolvedLayout()',\n '[attr.data-scroll]': 'resolvedScroll()',\n '[attr.data-topbar]': 'showTopbar()',\n '[attr.data-subheader]': 'showSubheader()',\n '[attr.data-shell-size]': 'size()',\n '[attr.data-sidebar-mode]': 'sidebar().mode',\n '[attr.data-sidebar-open]': 'sidebar().open',\n '[attr.data-sidebar-modal]': 'sidebar().modal',\n '[attr.data-sidebar-peeked]': 'sidebar().peeked',\n '[attr.data-resizing]': 'store.resizing() || null',\n '[attr.data-motion-collapse]': 'config().motion.collapse ? null : \"off\"',\n '[style.--shell-sidebar-track]': 'sidebar().trackWidth',\n '[style.--shell-motion-scale]': 'motionScale()',\n '(document:keydown)': 'onDocumentKeydown($event)',\n },\n providers: [{ provide: SHELL_REGION, useExisting: AppShellComponent }],\n exportAs: 'appShell',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class AppShellComponent implements ShellRegion {\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly document = inject(DOCUMENT);\n private readonly router = inject(Router, { optional: true });\n private readonly breadcrumbs = inject(ShellBreadcrumbStore);\n private readonly main = viewChild.required<ElementRef<HTMLElement>>('main');\n private readonly frame = viewChild.required<ElementRef<HTMLElement>>('frame');\n\n protected readonly store = inject(ShellStore);\n protected readonly config = this.store.config;\n protected readonly mainId = SHELL_MAIN_ID;\n protected readonly sidebarId = SHELL_SIDEBAR_ID;\n\n /** Per-instance overrides. Leave unset to follow the (runtime) config. */\n readonly layout = input<ShellLayout | undefined>(undefined);\n readonly scroll = input<ShellScrollMode | undefined>(undefined);\n readonly topbar = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n readonly subheader = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n readonly footer = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly regionName = 'shell';\n readonly regionWidth: Signal<number | null> = observeWidth(this.host);\n readonly regionSize: Signal<ShellSize> = this.store.size;\n\n protected readonly size = this.store.size;\n protected readonly sidebar: Signal<SidebarState> = this.store.sidebar;\n private readonly hasSubheaderSlots = hasSlot('breadcrumb', 'subheader-start', 'subheader-end');\n private readonly hasFooterSlots = hasSlot('footer', 'footer-start', 'footer-end');\n\n protected readonly resolvedLayout = computed(() => this.layout() ?? this.config().layout);\n protected readonly resolvedScroll = computed(() => this.scroll() ?? this.config().scroll);\n /** Topbar, main and footer share one rounded card; the sidebar sits on the shell. */\n protected readonly inset = computed(() => this.resolvedLayout() === 'inset');\n protected readonly showTopbar = computed(() => this.topbar() ?? this.config().topbar.enabled);\n protected readonly showFooter = computed(\n () => this.footer() ?? (this.config().footer.enabled || this.hasFooterSlots()),\n );\n\n /**\n * The breadcrumb row. In `'auto'` it follows the page: a route's\n * `data.subheader` wins; otherwise it shows when the trail is at least two\n * levels deep (a flat trail is noise) or when a page fills a subheader slot.\n * Decided per navigation, so it never appears or vanishes within a page.\n */\n protected readonly showSubheader = computed(() => {\n const explicit = this.subheader();\n if (explicit !== undefined) {\n return explicit;\n }\n const mode = this.config().subheader.enabled;\n if (mode !== 'auto') {\n return mode;\n }\n return (\n this.breadcrumbs.subheaderOverride() ??\n (this.breadcrumbs.depth() >= 2 || this.hasSubheaderSlots())\n );\n });\n\n /**\n * Factor every shell duration is multiplied by (see `duration()` in the\n * token file): 0 turns motion off, 1 / speed scales it.\n */\n protected readonly motionScale = computed(() => {\n const { enabled, speed } = this.config().motion;\n return String(enabled && speed > 0 ? 1 / speed : 0);\n });\n\n constructor() {\n // Feed the measured width back into the store: everything downstream —\n // buckets, sidebar mode, slot visibility — is derived from this one value.\n effect(() => this.store.setWidth(this.regionWidth()));\n\n // A modal drawer must not leave the page scrolling underneath it. Done in\n // TS rather than a global class so the library needs no global stylesheet.\n effect((onCleanup) => {\n if (!this.sidebar().modal) {\n return;\n }\n const root = this.document.documentElement;\n const previous = root.style.overflow;\n root.style.overflow = 'hidden';\n onCleanup(() => {\n root.style.overflow = previous;\n });\n });\n\n this.router?.events\n .pipe(\n filter((event) => event instanceof NavigationEnd),\n takeUntilDestroyed(),\n )\n .subscribe(() => {\n const config = this.config();\n const state = this.store.sidebar();\n if (config.sidebar.closeOnNavigate && state.mode === 'overlay' && state.open) {\n this.store.closeSidebar();\n }\n if (config.scrollTopOnNavigate) {\n this.resetScroll();\n }\n });\n }\n\n /**\n * The window does not scroll in these modes, so the router cannot restore\n * scroll: `main` scrolls in `scroll: 'main'`, the card in `inset` + `page`.\n */\n private resetScroll(): void {\n if (this.resolvedScroll() === 'main') {\n this.main().nativeElement.scrollTo({ top: 0 });\n } else if (this.inset()) {\n this.frame().nativeElement.scrollTo({ top: 0 });\n }\n }\n\n /**\n * A plain `href=\"#id\"` would resolve against `<base href>` and trigger a\n * router navigation, so the jump is done by moving focus instead.\n */\n protected skipToMain(event: Event): void {\n event.preventDefault();\n this.document.getElementById(this.mainId)?.focus();\n }\n\n /** Optional Ctrl/⌘ + key toggle, ignored while typing. */\n protected onDocumentKeydown(event: KeyboardEvent): void {\n const key = this.config().sidebar.toggleShortcut;\n if (\n !key ||\n event.defaultPrevented ||\n event.altKey ||\n event.shiftKey ||\n !(event.ctrlKey || event.metaKey) ||\n event.key.toLowerCase() !== key.toLowerCase() ||\n isEditable(event.target)\n ) {\n return;\n }\n event.preventDefault();\n this.store.toggleSidebar();\n }\n}\n","<a class=\"shell__skip-link\" [href]=\"'#' + mainId\" (click)=\"skipToMain($event)\">\n {{ config().labels.skipToContent }}\n</a>\n\n<!--\n Outside `inset` the topbar comes first in the DOM, so keyboard order follows\n the visual order (topbar → sidebar → breadcrumbs → main). In `inset` it moves\n into the card. Only one of the two ever renders.\n-->\n@if (showTopbar() && !inset()) {\n <shell-topbar class=\"shell__topbar\" />\n}\n\n<shell-sidebar class=\"shell__sidebar\" [id]=\"sidebarId\" [attr.data-layout]=\"resolvedLayout()\" />\n\n<!--\n The frame wraps topbar, breadcrumb row, main and footer. In `inset` it is the\n rounded card (and, with `scroll: 'page'`, the scroll container); in every\n other layout it is `display: contents`, so its children stay shell grid items.\n-->\n<div #frame class=\"shell__frame\">\n @if (showTopbar() && inset()) {\n <shell-topbar class=\"shell__topbar\" />\n }\n\n <!-- Before <main>, so the skip link jumps past the breadcrumbs too. -->\n @if (showSubheader()) {\n <shell-subheader class=\"shell__subheader\" [attr.data-sticky]=\"config().subheader.sticky || null\" />\n }\n\n <main #main class=\"shell__main\" [id]=\"mainId\" tabindex=\"-1\">\n <div class=\"shell__content\">\n <ng-content />\n </div>\n </main>\n\n @if (showFooter()) {\n <shell-footer class=\"shell__footer\" />\n }\n</div>\n\n<!--\n Scrim for the modal drawer. Always rendered so it can fade out as well as\n in; while closed it is invisible and ignores the pointer. It stacks above\n main content but below the sidebar, which is raised by --shell-z-sidebar.\n-->\n<div\n class=\"shell__scrim\"\n aria-hidden=\"true\"\n [attr.data-open]=\"sidebar().modal\"\n [attr.data-motion]=\"config().motion.scrim\"\n (click)=\"store.closeSidebar()\"\n></div>\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n Signal,\n TemplateRef,\n computed,\n inject,\n input,\n linkedSignal,\n signal,\n} from '@angular/core';\nimport { toSignal } from '@angular/core/rxjs-interop';\nimport { IsActiveMatchOptions, NavigationEnd, Router, RouterLink, RouterLinkActive } from '@angular/router';\nimport { filter, map } from 'rxjs';\nimport type {\n ShellNavIconContext,\n ShellNavItem,\n ShellNavItemContext,\n ShellNavItemTemplate,\n} from './nav.types';\n\n/**\n * A single navigation entry: a link, or an expandable section when it has\n * children.\n *\n * Renders `<a>` for anything navigable and `<button>` for a pure section\n * header. Those are different semantics for assistive tech, and only one of\n * them belongs in the tab order as a link. A section whose subtree contains the\n * active route opens itself and is marked, so deep links never land in a\n * collapsed tree.\n */\n@Component({\n selector: 'shell-nav-item',\n templateUrl: './shell-nav-item.component.html',\n styleUrl: './shell-nav-item.component.scss',\n // Self-import: the template renders `<shell-nav-item>` for children.\n imports: [NgTemplateOutlet, RouterLink, RouterLinkActive, ShellNavItemComponent],\n host: {\n '[attr.data-depth]': 'depth()',\n '[attr.data-expanded]': 'expanded()',\n '[attr.data-labels]': 'labels()',\n '[attr.data-child-active]': 'childActive() || null',\n '[attr.data-disabled]': 'item().disabled || null',\n '[style.--shell-nav-depth]': 'depth()',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellNavItemComponent {\n readonly item = input.required<ShellNavItem>();\n readonly depth = input(0);\n /** False on an icon rail: labels and badges give way to icons and tooltips. */\n readonly labels = input(true);\n readonly iconTemplate = input<TemplateRef<ShellNavIconContext> | null>(null);\n /** Replaces the row content; see `ShellNavComponent.itemTemplate`. */\n readonly itemTemplate = input<ShellNavItemTemplate | null>(null);\n\n private readonly router = inject(Router, { optional: true });\n\n /** Current URL, so \"contains the active route\" re-evaluates on navigation. */\n private readonly url: Signal<string> = this.router\n ? toSignal(\n this.router.events.pipe(\n filter((event) => event instanceof NavigationEnd),\n map((event) => event.urlAfterRedirects),\n ),\n { initialValue: this.router.url },\n )\n : signal('');\n\n protected readonly children = computed(() => this.item().children ?? []);\n protected readonly hasChildren = computed(() => this.children().length > 0);\n\n protected readonly isLink = computed(() => {\n const item = this.item();\n return !!(item.route || item.href) && !item.disabled;\n });\n\n protected readonly childActive = computed(() => {\n this.url();\n return this.hasChildren() && this.containsActive(this.children());\n });\n\n /**\n * User-toggleable, but re-derives when the data or the active route changes —\n * so a server-driven `expanded` flag or a deep link still wins, without\n * clobbering a click the moment anything else re-renders.\n */\n private readonly expandedState = linkedSignal(\n () => (this.item().expanded ?? false) || this.childActive(),\n );\n\n protected readonly expanded = computed(() => this.hasChildren() && this.expandedState());\n\n /** Tooltip only when the label is not rendered — otherwise it is noise. */\n protected readonly title = computed(() => (this.labels() ? null : this.item().label));\n\n /** Stand-in for a missing icon on a rail, so the row is never blank. */\n protected readonly initial = computed(() => this.item().label.trim().charAt(0).toUpperCase());\n\n protected readonly itemContext = computed<ShellNavItemContext>(() => {\n const item = this.item();\n return {\n $implicit: item,\n item,\n depth: this.depth(),\n labels: this.labels(),\n expanded: this.expanded(),\n };\n });\n\n protected toggle(): void {\n this.expandedState.update((open) => !open);\n }\n\n /** `readonly unknown[]` is friendlier as an API than RouterLink's `any[]`. */\n protected routerTarget(item: ShellNavItem): string | unknown[] {\n const route = item.route;\n if (route === undefined) {\n return [];\n }\n return typeof route === 'string' ? route : [...route];\n }\n\n private containsActive(items: readonly ShellNavItem[]): boolean {\n const router = this.router;\n if (!router) {\n return false;\n }\n return items.some((item) => {\n if (item.route !== undefined) {\n const tree =\n typeof item.route === 'string'\n ? router.parseUrl(item.route)\n : router.createUrlTree([...item.route]);\n const options: IsActiveMatchOptions = {\n paths: item.exact ? 'exact' : 'subset',\n queryParams: 'ignored',\n fragment: 'ignored',\n matrixParams: 'ignored',\n };\n if (router.isActive(tree, options)) {\n return true;\n }\n }\n return this.containsActive(item.children ?? []);\n });\n }\n}\n","@let entry = item();\n@let icon = entry.icon;\n@let badge = entry.badge;\n\n@if (isLink()) {\n @if (entry.route) {\n <a\n class=\"nav-item__row\"\n [routerLink]=\"routerTarget(entry)\"\n routerLinkActive=\"nav-item__row--active\"\n [routerLinkActiveOptions]=\"{ exact: !!entry.exact }\"\n ariaCurrentWhenActive=\"page\"\n [attr.title]=\"title()\"\n [attr.target]=\"entry.target\"\n >\n <ng-container *ngTemplateOutlet=\"row\" />\n </a>\n } @else {\n <a\n class=\"nav-item__row\"\n [href]=\"entry.href\"\n [attr.title]=\"title()\"\n [attr.target]=\"entry.target\"\n [attr.rel]=\"entry.target === '_blank' ? 'noopener' : null\"\n >\n <ng-container *ngTemplateOutlet=\"row\" />\n </a>\n }\n} @else if (hasChildren()) {\n <button\n type=\"button\"\n class=\"nav-item__row nav-item__row--section\"\n [attr.aria-expanded]=\"expanded()\"\n [attr.title]=\"title()\"\n [disabled]=\"entry.disabled\"\n (click)=\"toggle()\"\n >\n <ng-container *ngTemplateOutlet=\"row\" />\n <span class=\"nav-item__chevron\" aria-hidden=\"true\"></span>\n </button>\n} @else {\n <span class=\"nav-item__row nav-item__row--static\" [attr.title]=\"title()\">\n <ng-container *ngTemplateOutlet=\"row\" />\n </span>\n}\n\n@if (hasChildren()) {\n <!--\n Height animation via grid-template-rows 0fr → 1fr: no JS measurement, and\n it degrades to an instant show/hide under prefers-reduced-motion.\n `inert` keeps collapsed children out of the tab order and the a11y tree.\n -->\n <div class=\"nav-item__children\">\n <ul class=\"nav-item__child-list\" [attr.inert]=\"expanded() ? null : true\">\n @for (child of children(); track child.id ?? child.label) {\n <li>\n <shell-nav-item\n [item]=\"child\"\n [depth]=\"depth() + 1\"\n [labels]=\"labels()\"\n [iconTemplate]=\"iconTemplate()\"\n [itemTemplate]=\"itemTemplate()\"\n />\n </li>\n }\n </ul>\n </div>\n}\n\n<ng-template #row>\n @if (itemTemplate(); as custom) {\n <!--\n Custom content inside the library's row element: link semantics, active\n state and sections still come from here; the template owns the rest.\n -->\n <ng-container *ngTemplateOutlet=\"custom; context: itemContext()\" />\n } @else {\n @if (icon) {\n <span class=\"nav-item__icon\" aria-hidden=\"true\">\n @if (iconTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n iconTemplate()!;\n context: { $implicit: icon, icon: icon, item: entry }\n \"\n />\n } @else {\n {{ icon }}\n }\n </span>\n } @else if (!labels()) {\n <!-- Without an icon a rail row would be empty: show the label's initial. -->\n <span class=\"nav-item__glyph\" aria-hidden=\"true\">{{ initial() }}</span>\n }\n\n @if (labels()) {\n <span class=\"nav-item__label\">{{ entry.label }}</span>\n\n @if (badge !== undefined && badge !== null) {\n <span class=\"nav-item__badge\">{{ badge }}</span>\n }\n } @else {\n <!-- The label still has to reach screen readers on an icon rail. -->\n <span class=\"nav-item__sr-label\">{{ entry.label }}</span>\n\n @if (badge !== undefined && badge !== null) {\n <span class=\"nav-item__dot\" aria-hidden=\"true\"></span>\n }\n }\n }\n</ng-template>\n","import {\n DestroyRef,\n EnvironmentProviders,\n Injectable,\n Signal,\n inject,\n isSignal,\n provideEnvironmentInitializer,\n signal,\n} from '@angular/core';\nimport type { ShellNavGroup, ShellNavItem } from './nav.types';\n\n/** Static items, or a signal of items (e.g. with live badge counts). */\nexport type ShellNavItemsSource = readonly ShellNavItem[] | Signal<readonly ShellNavItem[]>;\n\nexport interface ShellNavContributionOptions {\n /**\n * Ascending position among contributions to the same group. Contributions\n * always follow the group's own items; ties keep registration order.\n */\n readonly order?: number;\n}\n\ninterface Contribution {\n readonly groupId: string;\n readonly items: ShellNavItemsSource;\n readonly order: number;\n readonly sequence: number;\n}\n\n/**\n * Lets code other than the owner of the nav array add entries to it — a\n * feature library adding \"Roadmap\" to the app's \"Workspace\" group, or a\n * section adding context links while it is open.\n *\n * Contributions target a group by `ShellNavGroup.id` and are merged into every\n * `<shell-nav>` that renders a group with that id. The app keeps control of\n * structure and order: it declares the groups (an empty group is fine — empty\n * groups are not rendered), features only fill them.\n */\n@Injectable({ providedIn: 'root' })\nexport class ShellNavRegistry {\n private readonly contributions = signal<readonly Contribution[]>([]);\n private sequence = 0;\n\n /**\n * Add items to the group with this id. Returns a function that removes them\n * again. Prefer `contributeNavItems()` / `provideShellNavItems()`, which\n * remove them automatically.\n */\n contribute(\n groupId: string,\n items: ShellNavItemsSource,\n options: ShellNavContributionOptions = {},\n ): () => void {\n const entry: Contribution = {\n groupId,\n items,\n order: options.order ?? 0,\n sequence: this.sequence++,\n };\n this.contributions.update((current) => [...current, entry]);\n return () =>\n this.contributions.update((current) => current.filter((candidate) => candidate !== entry));\n }\n\n /** Items contributed to a group, in order. Reactive when read in a signal context. */\n itemsFor(groupId: string): readonly ShellNavItem[] {\n return this.contributions()\n .filter((contribution) => contribution.groupId === groupId)\n .sort((a, b) => a.order - b.order || a.sequence - b.sequence)\n .flatMap((contribution) =>\n isSignal(contribution.items) ? contribution.items() : contribution.items,\n );\n }\n\n /**\n * `groups` with contributed items appended to the groups whose `id` matches.\n * Returns the input untouched when there is nothing to add, so object\n * identity stays stable for the common case. Reactive.\n */\n merge(groups: readonly ShellNavGroup[]): readonly ShellNavGroup[] {\n if (!this.contributions().length) {\n return groups;\n }\n return groups.map((group) => {\n const extra = group.id === undefined ? [] : this.itemsFor(group.id);\n return extra.length ? { ...group, items: [...group.items, ...extra] } : group;\n });\n }\n}\n\n/**\n * Contribute nav items for the lifetime of the calling component, directive or\n * service. Call from an injection context.\n *\n * ```ts\n * export class ProjectPage {\n * constructor() {\n * contributeNavItems('workspace', [{ label: 'Project settings', route: '/settings' }]);\n * }\n * }\n * ```\n */\nexport function contributeNavItems(\n groupId: string,\n items: ShellNavItemsSource,\n options?: ShellNavContributionOptions,\n): void {\n const remove = inject(ShellNavRegistry).contribute(groupId, items, options);\n inject(DestroyRef).onDestroy(remove);\n}\n\n/**\n * Contribute nav items for the lifetime of an environment injector. In the app\n * config the entries exist from startup — the usual way for a feature to own\n * its link:\n *\n * ```ts\n * providers: [provideShellNavItems('workspace', [{ label: 'Roadmap', route: '/roadmap' }])]\n * ```\n *\n * In a lazy route's `providers` they only appear once that route has loaded,\n * so do not use that to add the link *to* the lazy route itself.\n */\nexport function provideShellNavItems(\n groupId: string,\n items: ShellNavItemsSource,\n options?: ShellNavContributionOptions,\n): EnvironmentProviders {\n return provideEnvironmentInitializer(() => contributeNavItems(groupId, items, options));\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n TemplateRef,\n booleanAttribute,\n computed,\n inject,\n input,\n signal,\n} from '@angular/core';\nimport { ShellStore } from '../core/shell.store';\nimport { ShellNavItemComponent } from './shell-nav-item.component';\nimport { ShellNavRegistry } from './shell-nav-registry';\nimport type {\n ShellNavGroup,\n ShellNavIconContext,\n ShellNavItem,\n ShellNavItemTemplate,\n} from './nav.types';\n\n/**\n * Renders grouped navigation. Data in, markup out — so the same array feeds\n * the sidebar, the mobile drawer and anything else that needs the nav tree.\n *\n * ```html\n * <ng-template shellSlot=\"sidebar-nav\">\n * <shell-nav [groups]=\"navigation\" [iconTemplate]=\"icon\" />\n * </ng-template>\n * ```\n *\n * `labels` follows the sidebar by default, so a rail needs no configuration.\n * Items contributed through `ShellNavRegistry` are merged into the groups with\n * a matching `id`; groups that end up empty are not rendered.\n */\n@Component({\n selector: 'shell-nav',\n templateUrl: './shell-nav.component.html',\n styleUrl: './shell-nav.component.scss',\n imports: [ShellNavItemComponent],\n host: {\n '[attr.data-labels]': 'showLabels()',\n '[attr.data-indicator]': 'store.config().appearance.navIndicator',\n '[attr.data-motion-expand]': 'store.config().motion.navExpand ? null : \"off\"',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ShellNavComponent {\n /** Groups, or a flat item list which is wrapped in one unlabelled group. */\n readonly groups = input<readonly ShellNavGroup[]>([]);\n readonly items = input<readonly ShellNavItem[]>([]);\n\n /** Override the sidebar's label state — useful when reusing `shell-nav`. */\n readonly labels = input<boolean | null>(null);\n\n /** Hide group headings even when labels show (a denser, Slack-like list). */\n readonly headings = input(true, { transform: booleanAttribute });\n\n /** Renders `ShellNavItem.icon` keys. Without it, the key is shown as text. */\n readonly iconTemplate = input<TemplateRef<ShellNavIconContext> | null>(null);\n\n /**\n * Replaces the *content* of every row (icon, label, badge). The row element\n * itself — link, section button, active state, children — stays the\n * library's, so routing and accessibility keep working.\n */\n readonly itemTemplate = input<ShellNavItemTemplate | null>(null);\n\n protected readonly store = inject(ShellStore);\n private readonly registry = inject(ShellNavRegistry);\n /** Per-group overrides on top of the data's own `collapsed` flag. */\n private readonly groupOverrides = signal<ReadonlyMap<string, boolean>>(new Map());\n\n protected readonly showLabels = computed(() => this.labels() ?? this.store.sidebar().labels);\n\n protected readonly resolvedGroups = computed<readonly ShellNavGroup[]>(() => {\n const groups = this.groups();\n const items = this.items();\n const base: readonly ShellNavGroup[] = groups.length ? groups : items.length ? [{ items }] : [];\n return this.registry.merge(base).filter((group) => group.items.length > 0);\n });\n\n protected groupKey(group: ShellNavGroup, index: number): string {\n return group.id ?? group.label ?? `group-${index}`;\n }\n\n protected isCollapsed(group: ShellNavGroup, index: number): boolean {\n return this.groupOverrides().get(this.groupKey(group, index)) ?? !!group.collapsed;\n }\n\n protected toggleGroup(group: ShellNavGroup, index: number): void {\n const key = this.groupKey(group, index);\n const collapsed = this.isCollapsed(group, index);\n this.groupOverrides.update((current) => new Map(current).set(key, !collapsed));\n }\n}\n","@for (group of resolvedGroups(); track groupKey(group, $index); let index = $index) {\n @let collapsed = isCollapsed(group, index);\n @let showHeading = showLabels() && headings() && !!group.label;\n\n <div class=\"nav__group\" [attr.data-collapsed]=\"collapsed\">\n @if (showHeading) {\n @if (group.collapsible) {\n <button\n type=\"button\"\n class=\"nav__heading nav__heading--button\"\n [attr.aria-expanded]=\"!collapsed\"\n (click)=\"toggleGroup(group, index)\"\n >\n <span class=\"nav__heading-text\">{{ group.label }}</span>\n <span class=\"nav__heading-chevron\" aria-hidden=\"true\"></span>\n </button>\n } @else {\n <h2 class=\"nav__heading\">{{ group.label }}</h2>\n }\n } @else if (index > 0) {\n <!-- Without a heading, a rule keeps the groups legible on a rail. -->\n <hr class=\"nav__divider\" />\n }\n\n @if (!collapsed) {\n <ul class=\"nav__list\">\n @for (item of group.items; track item.id ?? item.label) {\n <li>\n <shell-nav-item\n [item]=\"item\"\n [labels]=\"showLabels()\"\n [iconTemplate]=\"iconTemplate()\"\n [itemTemplate]=\"itemTemplate()\"\n />\n </li>\n }\n </ul>\n }\n </div>\n}\n","import { ShellBreadcrumbComponent } from './breadcrumbs/shell-breadcrumb.component';\nimport { ContainerSizeDirective } from './responsive/container-size.directive';\nimport { SidebarToggleDirective } from './directives/sidebar-toggle.directive';\nimport { AppShellComponent } from './layout/app-shell.component';\nimport { ShellNavComponent } from './nav/shell-nav.component';\nimport { ShellNavItemComponent } from './nav/shell-nav-item.component';\nimport { ShellSlotDirective } from './slots/shell-slot.directive';\nimport { ShellSlotOutletComponent } from './slots/shell-slot-outlet.component';\n\n/**\n * Add to a component's `imports` to get the whole shell vocabulary:\n *\n * ```ts\n * @Component({ imports: [APP_SHELL], … })\n * ```\n *\n * Tree-shaking still applies per component, so unused pieces are dropped.\n */\nexport const APP_SHELL = [\n AppShellComponent,\n ShellSlotDirective,\n ShellSlotOutletComponent,\n ShellNavComponent,\n ShellNavItemComponent,\n ShellBreadcrumbComponent,\n SidebarToggleDirective,\n ContainerSizeDirective,\n] as const;\n","/*\n * Public API of the app shell.\n *\n * Everything a host application needs, and nothing it should not reach for:\n * internals such as the focus trap live behind the barrel.\n */\n\n// Configuration & types\nexport * from './lib/core/shell.types';\nexport {\n SHELL_CONFIG,\n DEFAULT_SHELL_CONFIG,\n mergeShellConfig,\n provideAppShell,\n} from './lib/core/shell.config';\nexport type {\n DrawerMotion,\n FooterAppearance,\n MenuMotion,\n NavIndicator,\n ScrimMotion,\n ShellAppearanceConfig,\n ShellConfig,\n ShellConfigInput,\n ShellFooterConfig,\n ShellLabels,\n ShellMotionConfig,\n ShellSidebarConfig,\n ShellTopbarConfig,\n ShellSubheaderConfig,\n ShellBreadcrumbsConfig,\n SidebarAppearance,\n SubheaderVisibility,\n SubheaderAppearance,\n BreadcrumbSeparator,\n TopbarAppearance,\n} from './lib/core/shell.config';\nexport { SHELL_STATE_STORAGE, localShellStateStorage } from './lib/core/shell-state-storage';\nexport type { ShellStateStorage } from './lib/core/shell-state-storage';\nexport { SHELL_MAIN_ID, SHELL_SIDEBAR_ID } from './lib/core/shell.ids';\n\n// State\nexport { ShellStore } from './lib/core/shell.store';\n\n// Sidebar behaviour\nexport { SIDEBAR_BEHAVIOR } from './lib/sidebar/sidebar-behavior';\nexport type { SidebarBehavior, SidebarContext } from './lib/sidebar/sidebar-behavior';\nexport { drawerState, hiddenState, panelState, railState } from './lib/sidebar/sidebar-states';\nexport { responsiveSidebarBehavior } from './lib/sidebar/responsive-sidebar-behavior';\nexport { manualSidebarBehavior } from './lib/sidebar/manual-sidebar-behavior';\nexport { drawerSidebarBehavior } from './lib/sidebar/drawer-sidebar-behavior';\n\n// Responsiveness\nexport {\n DEFAULT_BREAKPOINTS,\n atLeast,\n atMost,\n isBelow,\n resolveSize,\n sizeRank,\n} from './lib/responsive/shell-size';\nexport { observeWidth } from './lib/responsive/observe-width';\nexport type { WidthTarget } from './lib/responsive/observe-width';\nexport { measureRegion } from './lib/responsive/measure-region';\nexport type { MeasuredRegion } from './lib/responsive/measure-region';\nexport { ContainerSizeDirective } from './lib/responsive/container-size.directive';\nexport { SHELL_REGION } from './lib/responsive/shell-region';\nexport type { ShellRegion } from './lib/responsive/shell-region';\n\n// Slots\nexport { ShellSlotDirective } from './lib/slots/shell-slot.directive';\nexport { ShellSlotRegistry } from './lib/slots/shell-slot-registry';\nexport { ShellSlotOutletComponent } from './lib/slots/shell-slot-outlet.component';\nexport { hasSlot } from './lib/slots/has-slot';\n\n// Layout\nexport { AppShellComponent } from './lib/layout/app-shell.component';\nexport { ShellTopbarComponent } from './lib/layout/shell-topbar.component';\nexport { ShellSidebarComponent } from './lib/layout/shell-sidebar.component';\nexport { ShellFooterComponent } from './lib/layout/shell-footer.component';\nexport { ShellSubheaderComponent } from './lib/layout/shell-subheader.component';\n\n// Breadcrumbs\nexport { ShellBreadcrumbComponent } from './lib/breadcrumbs/shell-breadcrumb.component';\nexport {\n ShellBreadcrumbStore,\n contributeBreadcrumbLabel,\n} from './lib/breadcrumbs/shell-breadcrumb-store';\nexport type { ShellBreadcrumbLabel } from './lib/breadcrumbs/shell-breadcrumb-store';\nexport { BREADCRUMB_DATA_KEY, SUBHEADER_DATA_KEY } from './lib/breadcrumbs/breadcrumb.types';\nexport type {\n ShellBreadcrumbDisplay,\n ShellCrumb,\n ShellCrumbContext,\n ShellCrumbTemplate,\n} from './lib/breadcrumbs/breadcrumb.types';\nexport { SidebarToggleDirective } from './lib/directives/sidebar-toggle.directive';\n\n// Navigation\nexport { ShellNavComponent } from './lib/nav/shell-nav.component';\nexport { ShellNavItemComponent } from './lib/nav/shell-nav-item.component';\nexport {\n ShellNavRegistry,\n contributeNavItems,\n provideShellNavItems,\n} from './lib/nav/shell-nav-registry';\nexport type {\n ShellNavContributionOptions,\n ShellNavItemsSource,\n} from './lib/nav/shell-nav-registry';\nexport type {\n ShellNavGroup,\n ShellNavIconContext,\n ShellNavItem,\n ShellNavItemContext,\n ShellNavItemTemplate,\n} from './lib/nav/nav.types';\n\n// Convenience: everything a consumer template usually needs at once.\nexport { APP_SHELL } from './lib/app-shell.imports';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAEA;AACO,MAAM,WAAW,GAAG,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI;;ACDxD;;;AAGG;AACI,MAAM,mBAAmB,GAAqB;AACnD,IAAA,EAAE,EAAE,CAAC;AACL,IAAA,EAAE,EAAE,GAAG;AACP,IAAA,EAAE,EAAE,GAAG;AACP,IAAA,EAAE,EAAE,IAAI;AACR,IAAA,EAAE,EAAE,IAAI;;AAGJ,SAAU,QAAQ,CAAC,IAAe,EAAA;AACtC,IAAA,OAAO,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC;AAClC;AAEA;AACM,SAAU,WAAW,CAAC,KAAa,EAAE,WAA6B,EAAA;AACtE,IAAA,IAAI,KAAK,GAAc,WAAW,CAAC,CAAC,CAAC;AACrC,IAAA,KAAK,MAAM,IAAI,IAAI,WAAW,EAAE;AAC9B,QAAA,IAAI,KAAK,IAAI,WAAW,CAAC,IAAI,CAAC,EAAE;YAC9B,KAAK,GAAG,IAAI;QACd;IACF;AACA,IAAA,OAAO,KAAK;AACd;AAEA;AACM,SAAU,OAAO,CAAC,IAAe,EAAE,GAAc,EAAA;IACrD,OAAO,QAAQ,CAAC,IAAI,CAAC,IAAI,QAAQ,CAAC,GAAG,CAAC;AACxC;AAEA;AACM,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AA,EAAA,EAAA,kBAAA,EAAA,cAAA,EAAA,qBAAA,EAAA,wCAAA,EAAA,yBAAA,EAAA,kDAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EC9C9B,20CAwCA,EAAA,MAAA,EAAA,CAAA,iiEAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EDFY,qBAAqB,EAAA,QAAA,EAAA,gBAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,OAAA,EAAA,QAAA,EAAA,cAAA,EAAA,cAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAQpB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAZ7B,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,WAAW,EAAA,OAAA,EAGZ,CAAC,qBAAqB,CAAC,EAAA,IAAA,EAC1B;AACJ,wBAAA,oBAAoB,EAAE,cAAc;AACpC,wBAAA,uBAAuB,EAAE,wCAAwC;AACjE,wBAAA,2BAA2B,EAAE,gDAAgD;qBAC9E,EAAA,eAAA,EACgB,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,20CAAA,EAAA,MAAA,EAAA,CAAA,iiEAAA,CAAA,EAAA;;;AEnCjD;;;;;;;;AAQG;AACI,MAAM,SAAS,GAAG;IACvB,iBAAiB;IACjB,kBAAkB;IAClB,wBAAwB;IACxB,iBAAiB;IACjB,qBAAqB;IACrB,wBAAwB;IACxB,sBAAsB;IACtB,sBAAsB;;;AC1BxB;;;;;AAKG;AAEH;;ACPA;;AAEG;;"}
package/package.json ADDED
@@ -0,0 +1,55 @@
1
+ {
2
+ "name": "@danjelp/ngx-app-shell",
3
+ "version": "1.0.0",
4
+ "description": "Reusable Angular navigational shell: sidebar, topbar, main and footer with container-aware slots and a pluggable sidebar behaviour.",
5
+ "keywords": [
6
+ "angular",
7
+ "app-shell",
8
+ "layout",
9
+ "sidebar",
10
+ "topbar",
11
+ "navigation",
12
+ "breadcrumbs",
13
+ "responsive",
14
+ "signals"
15
+ ],
16
+ "author": "Danjel Peqini",
17
+ "license": "MIT",
18
+ "homepage": "https://github.com/dpeqini/ngx-app-shell#readme",
19
+ "repository": {
20
+ "type": "git",
21
+ "url": "git+https://github.com/dpeqini/ngx-app-shell.git",
22
+ "directory": "projects/app-shell"
23
+ },
24
+ "bugs": {
25
+ "url": "https://github.com/dpeqini/ngx-app-shell/issues"
26
+ },
27
+ "publishConfig": {
28
+ "access": "public"
29
+ },
30
+ "sideEffects": false,
31
+ "exports": {
32
+ "./styles/tokens": {
33
+ "sass": "./styles/_tokens.scss"
34
+ },
35
+ "./package.json": {
36
+ "default": "./package.json"
37
+ },
38
+ ".": {
39
+ "types": "./types/danjelp-ngx-app-shell.d.ts",
40
+ "default": "./fesm2022/danjelp-ngx-app-shell.mjs"
41
+ }
42
+ },
43
+ "peerDependencies": {
44
+ "@angular/common": "^19.0.0 || ^20.0.0 || ^21.0.0 || ^22.0.0",
45
+ "@angular/core": "^19.0.0 || ^20.0.0 || ^21.0.0 || ^22.0.0",
46
+ "@angular/router": "^19.0.0 || ^20.0.0 || ^21.0.0 || ^22.0.0",
47
+ "rxjs": "^7.4.0"
48
+ },
49
+ "dependencies": {
50
+ "tslib": "^2.3.0"
51
+ },
52
+ "module": "fesm2022/danjelp-ngx-app-shell.mjs",
53
+ "typings": "types/danjelp-ngx-app-shell.d.ts",
54
+ "type": "module"
55
+ }