@wildo-ai/presets-components 1.1.1 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/components/actions/action-button.d.ts +1 -4
- package/dist/esm/components/actions/action-button.d.ts.map +1 -1
- package/dist/esm/components/actions/action-button.js +21 -5
- package/dist/esm/components/actions/action-button.js.map +1 -1
- package/dist/esm/components/ai-elements/artifacts/artifact-browser.d.ts.map +1 -1
- package/dist/esm/components/ai-elements/artifacts/artifact-browser.js +7 -3
- package/dist/esm/components/ai-elements/artifacts/artifact-browser.js.map +1 -1
- package/dist/esm/components/ai-elements/execution/task.d.ts.map +1 -1
- package/dist/esm/components/ai-elements/execution/task.js +10 -2
- package/dist/esm/components/ai-elements/execution/task.js.map +1 -1
- package/dist/esm/components/app/app-layout-main-container.labels.d.ts.map +1 -1
- package/dist/esm/components/app/app-layout-main-container.labels.js +10 -2
- package/dist/esm/components/app/app-layout-main-container.labels.js.map +1 -1
- package/dist/esm/components/app/public-layout-main-container.d.ts.map +1 -1
- package/dist/esm/components/app/public-layout-main-container.js +52 -5
- package/dist/esm/components/app/public-layout-main-container.js.map +1 -1
- package/dist/esm/components/data-display/description-list.d.ts.map +1 -1
- package/dist/esm/components/data-display/description-list.js +10 -7
- package/dist/esm/components/data-display/description-list.js.map +1 -1
- package/dist/esm/components/data-display/formatters/display-field-string.d.ts.map +1 -1
- package/dist/esm/components/data-display/formatters/display-field-string.js +3 -0
- package/dist/esm/components/data-display/formatters/display-field-string.js.map +1 -1
- package/dist/esm/components/form/chromes/form-primitive.labels.js +2 -2
- package/dist/esm/components/form/chromes/form-primitive.labels.js.map +1 -1
- package/dist/esm/components/navigation/app-level/menu-user-org.d.ts.map +1 -1
- package/dist/esm/components/navigation/app-level/menu-user-org.js +8 -2
- package/dist/esm/components/navigation/app-level/menu-user-org.js.map +1 -1
- package/dist/esm/components/navigation/app-level/sidebar.d.ts.map +1 -1
- package/dist/esm/components/navigation/app-level/sidebar.js +32 -15
- package/dist/esm/components/navigation/app-level/sidebar.js.map +1 -1
- package/dist/esm/components/overlays/containers/sheet.d.ts.map +1 -1
- package/dist/esm/components/overlays/containers/sheet.js +2 -2
- package/dist/esm/components/overlays/containers/sheet.js.map +1 -1
- package/dist/esm/components/sections/accordion.d.ts.map +1 -1
- package/dist/esm/components/sections/accordion.js +43 -13
- package/dist/esm/components/sections/accordion.js.map +1 -1
- package/dist/esm/components/sections/collapsible.d.ts.map +1 -1
- package/dist/esm/components/sections/collapsible.js +17 -3
- package/dist/esm/components/sections/collapsible.js.map +1 -1
- package/dist/esm/components/sections/content-section.d.ts.map +1 -1
- package/dist/esm/components/sections/content-section.js +11 -7
- package/dist/esm/components/sections/content-section.js.map +1 -1
- package/dist/esm/components/sections/disclosure-nesting.d.ts +20 -0
- package/dist/esm/components/sections/disclosure-nesting.d.ts.map +1 -0
- package/dist/esm/components/sections/disclosure-nesting.js +20 -0
- package/dist/esm/components/sections/disclosure-nesting.js.map +1 -0
- package/dist/esm/components/sections/tabs.d.ts.map +1 -1
- package/dist/esm/components/sections/tabs.js +141 -10
- package/dist/esm/components/sections/tabs.js.map +1 -1
- package/dist/esm/config/preset-kits.d.ts.map +1 -1
- package/dist/esm/config/preset-kits.js +0 -4
- package/dist/esm/config/preset-kits.js.map +1 -1
- package/dist/esm/config/preset-shell.d.ts.map +1 -1
- package/dist/esm/config/preset-shell.js +0 -4
- package/dist/esm/config/preset-shell.js.map +1 -1
- package/dist/esm/config/presets.d.ts.map +1 -1
- package/dist/esm/config/presets.js +0 -1
- package/dist/esm/config/presets.js.map +1 -1
- package/dist/esm/config/resources/application.resource-presets.d.ts.map +1 -1
- package/dist/esm/config/resources/application.resource-presets.js +6 -6
- package/dist/esm/config/resources/application.resource-presets.js.map +1 -1
- package/dist/esm/config/resources/billing.resource-presets.d.ts.map +1 -1
- package/dist/esm/config/resources/billing.resource-presets.js +8 -8
- package/dist/esm/config/resources/billing.resource-presets.js.map +1 -1
- package/dist/esm/config/resources/guidance.resource-presets.d.ts.map +1 -1
- package/dist/esm/config/resources/guidance.resource-presets.js +7 -7
- package/dist/esm/config/resources/guidance.resource-presets.js.map +1 -1
- package/dist/esm/config/resources/identity.resource-presets.d.ts.map +1 -1
- package/dist/esm/config/resources/identity.resource-presets.js +7 -7
- package/dist/esm/config/resources/identity.resource-presets.js.map +1 -1
- package/dist/esm/config/resources/organizations.resource-presets.d.ts.map +1 -1
- package/dist/esm/config/resources/organizations.resource-presets.js +8 -8
- package/dist/esm/config/resources/organizations.resource-presets.js.map +1 -1
- package/dist/esm/config/resources/security.resource-presets.d.ts.map +1 -1
- package/dist/esm/config/resources/security.resource-presets.js +9 -9
- package/dist/esm/config/resources/security.resource-presets.js.map +1 -1
- package/dist/esm/themes/cozy.theme.d.ts.map +1 -1
- package/dist/esm/themes/cozy.theme.js +8 -3
- package/dist/esm/themes/cozy.theme.js.map +1 -1
- package/dist/esm/themes/dense.theme.d.ts.map +1 -1
- package/dist/esm/themes/dense.theme.js +8 -5
- package/dist/esm/themes/dense.theme.js.map +1 -1
- package/dist/esm/themes/editorial.theme.d.ts.map +1 -1
- package/dist/esm/themes/editorial.theme.js +8 -3
- package/dist/esm/themes/editorial.theme.js.map +1 -1
- package/dist/esm/themes/glass.theme.d.ts.map +1 -1
- package/dist/esm/themes/glass.theme.js +10 -4
- package/dist/esm/themes/glass.theme.js.map +1 -1
- package/dist/esm/themes/neo-brutalist.theme.d.ts.map +1 -1
- package/dist/esm/themes/neo-brutalist.theme.js +8 -3
- package/dist/esm/themes/neo-brutalist.theme.js.map +1 -1
- package/dist/esm/themes/terminal.theme.d.ts.map +1 -1
- package/dist/esm/themes/terminal.theme.js +8 -3
- package/dist/esm/themes/terminal.theme.js.map +1 -1
- package/dist/esm/themes/trading.theme.d.ts.map +1 -1
- package/dist/esm/themes/trading.theme.js +8 -3
- package/dist/esm/themes/trading.theme.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +7 -7
- package/dist/esm/.builder.pid +0 -9
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sidebar.js","sourceRoot":"","sources":["../../../../../../src/components/navigation/app-level/sidebar.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,aAAa,EAAE,iBAAiB,EAAE,eAAe,EAAE,uBAAuB,EAAE,cAAc,EAAE,UAAU,EAAE,iBAAiB,EAAE,2BAA2B,EAAE,MAAM,qCAAqC,CAAC;AACtR,OAAO,EAEL,0BAA0B,EAC1B,yBAAyB,EAKzB,6BAA6B,EAC7B,MAAM,EACN,sBAAsB,EACtB,SAAS,EACT,UAAU,EACV,cAAc,EACd,WAAW,EACX,kBAAkB,EAClB,kBAAkB,EAClB,OAAO,EACP,QAAQ,EACR,qBAAqB,EACrB,mBAAmB,EACnB,eAAe,EACf,KAAK,EACL,8BAA8B,EAC9B,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,KAAK,EACL,YAAY,EACZ,UAAU,EACV,sBAAsB,EACtB,wBAAwB,EACxB,SAAS,EACT,EAAE,EACF,2CAA2C,EAC3C,OAAO,GACR,MAAM,6BAA6B,CAAC;AAErC;;;;;;GAMG;AACH,MAAM,uBAAuB,GAA+E;IAC1G,CAAC,sBAAsB,CAAC,YAAY,CAAC,EAAE,cAAc;IACrD,CAAC,sBAAsB,CAAC,eAAe,CAAC,EAAE,gBAAgB;IAC1D,CAAC,sBAAsB,CAAC,MAAM,CAAC,EAAE,MAAM;CACxC,CAAC;AAEF,MAAM,CAAC,MAAM,sCAAsC,GAA4C,CAAC,EAC9F,SAAS,GAAG,mBAAmB,CAAC,KAAK,EACrC,WAAW,EAAE,mBAAmB,EAChC,gBAAgB,EACjB,EAAE,EAAE;IAEH,MAAM,EAAE,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,CAAC,aAAa,oBAChC,EAAE,CAAC,WAAW,4BACN,EAAE,CAAC,aAAa,CAAC,gBAAgB,qBACxC,iBAAiB,EAClC,SAAS,EAAE,EAAE;YACX,oEAAoE;YACpE,4CAA4C;YAC5C,mBAAmB;YACnB,oEAAoE;YACpE,sEAAsE;YACtE,4CAA4C;YAC5C,gBAAgB,EAChB,iBAAiB;gBACf,iEAAiE;gBACjE,+CAA+C;gBAC/C,CAAC,CAAC,gCAAgC;gBAClC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,aAAa,CAAC,cAAc,EAAE,+EAA+E,CAAC,EACxH,uFAAuF,CACxF,EACD,KAAK,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,aAAa,CAAC,YAAY,IAAI,EAAE,YAEtD,+BAAmB,UAAU,CAAC,qBAAqB,CAAC,yBAAyB,EAAE,cAAc,CAAC,EAAE,SAAS,EAAC,8BAA8B,aACrI,iBAAiB,EAAE,EACnB,oBAAoB,EAAE,EACtB,sBAAsB,CAAC,iBAAiB,CAAC,MAAM,CAAC,EAChD,oBAAoB,EAAE,IACjB,GACJ,GACE,CACX,CAAC;AACJ,CAAC,CAAC","sourcesContent":["import React from 'react';\n\nimport { BrandAssetComposition } from '@wildo-ai/saas-models';\n\nimport { ButtonSize, CorePresetNames, FrontendComponentType, HorizontalPlacement, PlacementSide, SelectableVariant, ShellAppearance, SidebarCompactLabelMode, SurfaceVariant, UIBehavior, VerticalPlacement, resolvePlacementSideToRadix } from '@wildo-ai/presets-components-models';\nimport {\n type SectionRenderProps,\n SidebarSectionInlineCreate,\n SidebarSectionContentKind,\n AnyNavigationItem,\n HierarchicalNavigationItem,\n SectionGroup,\n ApplicationLevelProps_Sidebar,\n ApplicationLevelComponentType,\n Button,\n ButtonVariants_Variant,\n InputRoot,\n ScrollArea,\n ScrollAreaType,\n Collapsible,\n CollapsibleContent,\n CollapsibleTrigger,\n useI18n,\n IconSize,\n StandardIconReference,\n NavigationItemBadge,\n useIconRegistry,\n useUI,\n useHostedComponentInteractions,\n TruncatedText,\n useSidebarBehavior,\n SidebarHomeDisplayMode,\n Sheet,\n SheetContent,\n SheetTitle,\n SidebarResourceBrowser,\n ComponentRegistryService,\n envLoader,\n cn,\n NON_CANONICAL_SHELL_SURFACE_POLICY_OVERRIDE,\n Surface,\n} from '@wildo-ai/saas-frontend-lib';\n\n/**\n * Which single home affordance each mode renders — the mutual exclusion as\n * DATA, so a future `SidebarHomeDisplayMode` member cannot compile without\n * declaring its answer. Two independent predicates could drift into rendering\n * both affordances (or neither); this map is the one source both renderers gate\n * on.\n */\nconst HOME_AFFORDANCE_BY_MODE: Record<SidebarHomeDisplayMode, 'brand-header' | 'navigation-row' | 'none'> = {\n [SidebarHomeDisplayMode.BRAND_HEADER]: 'brand-header',\n [SidebarHomeDisplayMode.NAVIGATION_ITEM]: 'navigation-row',\n [SidebarHomeDisplayMode.HIDDEN]: 'none',\n};\n\nexport const ApplicationLevelPreset_Sidebar_Default: React.FC<ApplicationLevelProps_Sidebar> = ({\n placement = HorizontalPlacement.START,\n isCollapsed: externalIsCollapsed,\n onToggleCollapse\n}) => {\n\n const sb = useSidebarBehavior({ placement, isCollapsed: externalIsCollapsed, onToggleCollapse });\n const { renderIcon } = useIconRegistry();\n const { tComponent, tSidebarSection, isReady } = useI18n({ component: FrontendComponentType.APPLICATION_LEVEL_SIDEBAR });\n const { UIConfig, getRecipe, shellAppearance, sidebarCompactLabelMode } = useUI();\n const { getHostedComponentProps } = useHostedComponentInteractions();\n const currentBreakpoint = UIConfig?.currentBreakpoint;\n\n // CONTINUOUS shell chrome: the sidebar is a transparent region of the shared\n // canvas (theme backgroundLayer) — no sunken slab, no separating edge border.\n const isContinuousShell = shellAppearance === ShellAppearance.CONTINUOUS;\n // Compact rail with labels under icons (theme design policy). Only relevant\n // while collapsed; expanded rendering is unchanged.\n const showCompactLabels = sb.isCollapsed && sidebarCompactLabelMode === SidebarCompactLabelMode.ICON_AND_LABEL;\n\n // Nav items consume the theme's SELECTABLE/FILLED recipe (the vocabulary for\n // \"sidebar active items\") instead of hardcoding state classes: the active\n // look is a subtle `surface-sunken-accent` overlay + `font-medium` — weight,\n // not a primary tint — and stays themable. Items opt in via `data-active`.\n // These classes are appended AFTER the Button GHOST recipe (cn/tailwind-merge\n // puts `className` last), so the sidebar hover wash wins over GHOST's.\n const selectableRecipe = getRecipe(UIBehavior.SELECTABLE, SelectableVariant.FILLED);\n const navItemStateClasses = cn(\n selectableRecipe.states.hover,\n selectableRecipe.states.selected,\n selectableRecipe.motion.transition,\n );\n\n // The brand header takes the SAME themed hover wash as navigation rows but\n // deliberately NOT the selected state — identity is not a selectable\n // destination, and a permanently-filled header on the home route reads as a\n // stuck menu item.\n const brandHoverClasses = cn(\n selectableRecipe.states.hover,\n selectableRecipe.motion.transition,\n );\n\n // Compact rail: section titles are hidden, so group boundaries are drawn as\n // thin separator lines instead (theme DIVIDER recipe — stays themable).\n const dividerRecipe = getRecipe(UIBehavior.DIVIDER);\n\n // A brand asset URL comes from application CONFIG, but SERVING the file is the\n // application's own responsibility — a declared asset can 404 (or fall through\n // to an SPA html response). Track a failed load so the header degrades to its\n // no-logo presentation rather than rendering a broken image, and reset the\n // flag whenever the resolved URL changes (e.g. a light/dark theme switch).\n const brandLogoUrl = sb.brandHeader?.logoUrl;\n const [brandLogoFailed, setBrandLogoFailed] = React.useState(false);\n React.useEffect(() => setBrandLogoFailed(false), [brandLogoUrl]);\n\n const renderNavigationItem = (item: AnyNavigationItem, indent: number = 0) => {\n // Identity-keyed active check (resolved item id, not raw path) — two distinct\n // items sharing an identical urlPath must not both highlight; the behavior hook\n // elects one id. (Ids are deterministic per target, so the SAME target declared\n // in two sections shares one id and would still co-highlight — a config smell.)\n const isActive = sb.isNavigationItemActive(item);\n\n // Star affordance (favorites): only when a FAVORITES section is configured\n // and the rail is expanded (the collapsed rail has no hover surface for a\n // secondary action). Rendered as a SIBLING absolutely-positioned button —\n // a button must not contain interactive descendants — hover/focus-revealed,\n // and pinned visible while the item IS favorited (the \"star when favorite\n // is active\" cue). Favorites-section copies carry `favoriteId`, so the same\n // toggle unfavorites from there.\n const showStarAffordance = sb.hasFavoritesSection && !sb.isCollapsed;\n const isFavorite = showStarAffordance && sb.isItemFavorite(item);\n\n const itemButton = (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => sb.handleNavigationClick(item)}\n aria-current={isActive ? 'page' : undefined}\n data-active={isActive || undefined}\n // Resolved-item id (deterministic per target, e.g. `resolved-todos-list-default`)\n // as the i18n-independent automation hook — labels are runtime-translated.\n data-nav-item-id={item.id}\n className={cn(\n 'w-full justify-start gap-field-sm relative',\n navItemStateClasses,\n // Reserve the trailing star slot so hover-reveal does not reflow the\n // label/badge (the badge sits before the star, like Linear's row\n // action cluster).\n showStarAffordance && 'pe-8',\n sb.isCollapsed && !showCompactLabels && 'justify-center px-card-sm',\n // Icon-above-label rail item: intrinsic height (labels may wrap),\n // roomier vertical padding (`py-element` = spacing token) so each\n // entry breathes like a proper rail tile, not a squeezed row.\n showCompactLabels && 'h-auto min-h-8 flex-col items-center justify-center gap-1.5 px-1 py-element',\n )}\n style={{ paddingInlineStart: sb.isCollapsed ? undefined : `${12 + indent * 16}px` }}\n title={sb.isCollapsed && !showCompactLabels ? item.label : undefined}\n >\n {item.icon && (\n // Rail mode upsizes icons to MD (20px): with labels reduced to 11px,\n // the icon is the primary glyph and SM (16px) reads under-weighted.\n // CSS `size-*` on the wrapper wins over the svg's width/height attrs.\n <span className={cn('flex-shrink-0 relative', sb.isCollapsed && '[&_svg]:size-5')}>\n {item.icon}\n {sb.isCollapsed && item.notificationBadgeRef && (\n // Collapsed rail: the badge overlays the icon's top-end corner\n // (the expanded row shows it inline after the label instead).\n <span className=\"absolute -top-1.5 -end-1.5 z-10\">\n <NavigationItemBadge notificationBadgeRef={item.notificationBadgeRef} label={item.label} />\n </span>\n )}\n </span>\n )}\n {!sb.isCollapsed && (\n <>\n <TruncatedText className=\"flex-1 text-start\" tooltipSide={PlacementSide.END}>\n {item.label}\n </TruncatedText>\n {item.notificationBadgeRef && (\n <span className=\"ms-auto flex-shrink-0\">\n <NavigationItemBadge notificationBadgeRef={item.notificationBadgeRef} label={item.label} />\n </span>\n )}\n </>\n )}\n {showCompactLabels && (\n // The label is the primary affordance in this mode: it wraps onto\n // several lines rather than truncating (theme policy contract).\n <span className=\"w-full text-center text-[11px] leading-tight whitespace-normal break-words\">\n {item.label}\n </span>\n )}\n </Button>\n );\n\n if (!showStarAffordance) {\n return <React.Fragment key={item.id}>{itemButton}</React.Fragment>;\n }\n\n const favoriteLabel = tComponent(\n FrontendComponentType.APPLICATION_LEVEL_SIDEBAR,\n isFavorite ? 'favoriteRemove' : 'favoriteAdd',\n );\n\n return (\n <div key={item.id} className=\"relative group/navitem\">\n {itemButton}\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={(e) => {\n e.stopPropagation();\n sb.handleToggleItemFavorite(item);\n }}\n aria-pressed={isFavorite}\n aria-label={favoriteLabel}\n title={favoriteLabel}\n className={cn(\n 'absolute end-1 top-1/2 -translate-y-1/2 z-10 h-6 w-6 p-0 justify-center',\n 'text-muted-foreground hover:text-foreground',\n isFavorite\n ? 'opacity-100'\n : cn(\n 'opacity-0 transition-opacity duration-[var(--motion-duration-fast)] motion-reduce:transition-none',\n 'group-hover/navitem:opacity-100 group-focus-within/navitem:opacity-100 pointer-coarse:opacity-100',\n ),\n )}\n >\n <span className={cn('flex-shrink-0', isFavorite && '[&_svg]:fill-current')}>\n {renderIcon(StandardIconReference.STAR, { size: IconSize.XS })}\n </span>\n </Button>\n </div>\n );\n };\n\n const renderHierarchicalItem = (item: HierarchicalNavigationItem, indent: number = 0) => {\n const hasChildren = item.children && item.children.length > 0;\n const itemCollapsed = sb.isItemCollapsed(item.id);\n const isActive = sb.isNavigationItemActive(item);\n\n if (sb.isCollapsed || !hasChildren) {\n return renderNavigationItem(item, indent);\n }\n\n return (\n <Collapsible\n key={item.id}\n open={!itemCollapsed}\n onOpenChange={() => sb.handleToggleItemCollapse(item.id)}\n >\n <CollapsibleTrigger asChild>\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n aria-current={isActive ? 'page' : undefined}\n data-active={isActive || undefined}\n className={cn(\n 'w-full justify-start gap-field-sm relative',\n navItemStateClasses,\n )}\n style={{ paddingInlineStart: `${12 + indent * 16}px` }}\n >\n {item.icon && (\n <span className=\"flex-shrink-0\">\n {item.icon}\n </span>\n )}\n <TruncatedText className=\"flex-1 text-start\" tooltipSide={PlacementSide.END}>\n {item.label}\n </TruncatedText>\n <span className=\"ms-auto flex-shrink-0\">\n {renderIcon(\n itemCollapsed ? StandardIconReference.CHEVRON_RIGHT : StandardIconReference.CHEVRON_DOWN,\n { size: IconSize.XS }\n )}\n </span>\n </Button>\n </CollapsibleTrigger>\n <CollapsibleContent>\n <div className=\"space-y-item-xs\">\n {item.children?.map(child => renderNavigationItem(child, indent + 1))}\n </div>\n </CollapsibleContent>\n </Collapsible>\n );\n };\n\n /**\n * Pinned brand header (`SidebarHomeDisplayMode.BRAND_HEADER`): the app's\n * symbol + display name at the very top of the sidebar, OUTSIDE the scroll\n * region so it stays put while navigation scrolls — and therefore above any\n * TOP-hosted component such as the command-menu search trigger. It IS the\n * home button (Slack / Linear / Notion), so no Home row renders in this mode.\n */\n const renderBrandHeader = () => {\n if (HOME_AFFORDANCE_BY_MODE[sb.homeDisplayMode] !== 'brand-header' || !sb.brandHeader) return null;\n\n const homeLabel = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'home');\n const { name, logoUrl, logoComposition } = sb.brandHeader;\n\n // A WORDMARK/LOCKUP asset already CONTAINS the application name (the brand\n // resolver may return one when the app generated no symbol), so it replaces\n // the name label instead of sitting beside it — and it needs intrinsic width\n // rather than a square icon slot. Only a SYMBOL pairs with the text.\n const hasLogo = !!logoUrl && !brandLogoFailed;\n // Nothing identifiable to show (no name AND no usable mark) — render no\n // header rather than a nameless, unlabelled click target.\n if (!hasLogo && !name) return null;\n const logoCarriesName = hasLogo && logoComposition !== undefined && logoComposition !== BrandAssetComposition.SYMBOL;\n // The collapsed rail is an icon column: a wide mark cannot render there, so\n // it degrades to the framework home glyph exactly like a missing brand.\n const showSquareMark = hasLogo && !logoCarriesName;\n const showWideMark = hasLogo && logoCarriesName && !sb.isCollapsed;\n const showHomeGlyph = !showSquareMark && !showWideMark && sb.isCollapsed;\n // The name renders as text unless the mark already spells it.\n const showNameText = !sb.isCollapsed && !showWideMark;\n // Labelled rail falls back to the name ONLY when no mark resolved: a logo\n // already says which product this is, and repeating the name beneath it in\n // 11px spends rail height that navigation needs.\n const showCompactNameLabel = showCompactLabels && !showSquareMark;\n // Is the application name conveyed by something VISIBLE? A wide mark carries\n // it as `alt`; the two text branches carry it directly. When none render —\n // the logo-only rail — the button needs an explicit accessible name.\n const nameIsAnnounced = showNameText || showCompactNameLabel || showWideMark;\n\n const markImage = (className: string, alt: string) => (\n <img\n src={logoUrl}\n alt={alt}\n aria-hidden={alt === '' ? 'true' : undefined}\n onError={() => setBrandLogoFailed(true)}\n className={className}\n />\n );\n\n return (\n <div\n className={cn(\n 'px-card-sm pt-card-sm pb-item-xs flex items-center gap-element',\n // Rail: the mark alone, centred — the toggle lives at the bottom there.\n sb.isCollapsed && 'justify-center',\n )}\n >\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={sb.handleHomeClick}\n // `aria-current` stays truthful (the header DOES lead to the current\n // page when home is open) but NO `data-active` is set: the selected\n // fill belongs to navigation rows. The application's identity is not\n // a menu item that lights up — painting it selected made the product\n // name read as \"the highlighted row\", which is precisely the shell\n // language Linear/Notion/Slack reserve for navigation.\n aria-current={sb.isHomeActive ? 'page' : undefined}\n data-slot=\"sidebar-brand-header\"\n className={cn(\n // Its own register: taller than a nav row, hover-only affordance.\n // `min-w-0` lets the name truncate instead of pushing the collapse\n // toggle out of the row.\n 'flex-1 min-w-0 justify-start gap-field-sm h-11',\n brandHoverClasses,\n sb.isCollapsed && !showCompactLabels && 'justify-center px-card-sm',\n // Labelled rail (theme `SidebarCompactLabelMode.ICON_AND_LABEL`):\n // the brand tile follows the same icon-above-wrapped-label shape as\n // every other rail entry instead of staying an icon-only outlier.\n showCompactLabels && 'h-auto min-h-8 flex-col items-center justify-center gap-1.5 px-1 py-element',\n )}\n // Collapsed there is no visible text: the accessible name composes the\n // app name with the existing home label so the control still announces\n // WHAT it is and WHERE it leads — this covers the logo-only rail, whose\n // `alt=\"\"` mark would otherwise leave the button unnamed. When a name IS\n // visible it is the accessible name, and no `title` is set\n // (`TruncatedText` already supplies an overflow tooltip; a second one\n // would stack).\n aria-label={nameIsAnnounced ? undefined : `${name} — ${homeLabel}`}\n title={nameIsAnnounced ? undefined : `${name} — ${homeLabel}`}\n >\n {showSquareMark && markImage(cn('size-7 flex-shrink-0 rounded-md object-contain', sb.isCollapsed && 'size-5'), '')}\n {showWideMark && markImage('h-7 max-w-full flex-shrink-0 object-contain object-left', name)}\n {showHomeGlyph && (\n <span className=\"flex-shrink-0 [&_svg]:size-5\">\n {renderIcon(StandardIconReference.HOME, { size: IconSize.SM })}\n </span>\n )}\n {showNameText && (\n // Product identity type register — a step up from the 14px/500 nav\n // rows in size and weight, tightened so a longer name still reads as\n // one wordmark rather than a wrapped menu label.\n <TruncatedText className=\"flex-1 text-start text-base font-semibold tracking-tight leading-none\" tooltipSide={PlacementSide.END}>\n {name}\n </TruncatedText>\n )}\n {showCompactNameLabel && (\n // Labelled rail, but NO mark resolved: the name is the only thing\n // identifying the application, so it stands in for the logo. When a\n // mark IS present the rail shows the mark ALONE — a logo already\n // says which product this is, and repeating the name under it in\n // 11px steals rail height from navigation for no information.\n <span className=\"w-full text-center text-[11px] leading-tight whitespace-normal break-words\">\n {name}\n </span>\n )}\n </Button>\n {collapseToggleHostedInBrandHeader && (\n // Quiet by default (same fade contract as the former bottom control):\n // revealed on sidebar hover / focus-within, always visible to coarse\n // pointers, which have no hover to reveal it with.\n <span\n className={cn(\n 'flex-shrink-0',\n 'opacity-0 transition-opacity duration-[var(--motion-duration-normal)] ease-[var(--motion-easing-default)] motion-reduce:transition-none',\n 'group-hover/app-sidebar:opacity-100 group-focus-within/app-sidebar:opacity-100 pointer-coarse:opacity-100',\n )}\n >\n {renderCollapseToggle('h-8 w-8 p-0 justify-center')}\n </span>\n )}\n </div>\n );\n };\n\n const renderHomeLink = () => {\n if (HOME_AFFORDANCE_BY_MODE[sb.homeDisplayMode] !== 'navigation-row') return null;\n\n const homeLabel = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'home');\n const homeIcon = renderIcon(\n StandardIconReference.HOME,\n { size: IconSize.SM }\n );\n\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={sb.handleHomeClick}\n aria-current={sb.isHomeActive ? 'page' : undefined}\n data-active={sb.isHomeActive || undefined}\n className={cn(\n 'w-full justify-start gap-field-sm',\n navItemStateClasses,\n sb.isCollapsed && !showCompactLabels && 'justify-center px-card-sm',\n showCompactLabels && 'h-auto min-h-8 flex-col items-center justify-center gap-1.5 px-1 py-element',\n )}\n title={sb.isCollapsed && !showCompactLabels ? homeLabel : undefined}\n >\n <span className={cn('flex-shrink-0', sb.isCollapsed && '[&_svg]:size-5')}>{homeIcon}</span>\n {!sb.isCollapsed && <span>{homeLabel}</span>}\n {showCompactLabels && (\n <span className=\"w-full text-center text-[11px] leading-tight whitespace-normal break-words\">\n {homeLabel}\n </span>\n )}\n </Button>\n );\n };\n\n const renderInlineCreate = (section: SectionRenderProps) => {\n if (section.inlineCreate === SidebarSectionInlineCreate.NONE || sb.isCollapsed) {\n return null;\n }\n\n const isActive = sb.inlineCreate.activeSection === section.ref;\n const placeholder = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'inlineCreatePlaceholder');\n\n if (section.inlineCreate === SidebarSectionInlineCreate.INPUT) {\n if (!isActive) {\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => sb.inlineCreate.start(section.ref)}\n className=\"w-full justify-start gap-element text-muted-foreground hover:text-foreground\"\n >\n {renderIcon(\n StandardIconReference.PLUS,\n { size: IconSize.SM }\n )}\n <span className=\"text-sm\">{placeholder}</span>\n </Button>\n );\n }\n\n return (\n <div className=\"px-card-sm py-item-xs\">\n <InputRoot\n autoFocus\n type=\"text\"\n value={sb.inlineCreate.value}\n onChange={(e) => sb.inlineCreate.setValue(e.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n sb.inlineCreate.submit(section.ref, section.inlineCreateResourceType);\n } else if (e.key === 'Escape') {\n sb.inlineCreate.cancel();\n }\n }}\n onBlur={() => {\n setTimeout(sb.inlineCreate.cancel, 150);\n }}\n placeholder={placeholder}\n aria-label={placeholder}\n className=\"h-8 text-sm\"\n />\n </div>\n );\n }\n\n if (section.inlineCreate === SidebarSectionInlineCreate.DIALOG) {\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => {\n if (section.inlineCreateResourceType) {\n sb.inlineCreate.submit(section.ref, section.inlineCreateResourceType);\n }\n }}\n className=\"w-full justify-start gap-element text-muted-foreground hover:text-foreground\"\n >\n {renderIcon(\n StandardIconReference.PLUS,\n { size: IconSize.SM }\n )}\n <span className=\"text-sm\">{placeholder}</span>\n </Button>\n );\n }\n\n return null;\n };\n\n const renderMoreMenu = (moreMenuItems: HierarchicalNavigationItem[]) => {\n if (moreMenuItems.length === 0 || sb.isCollapsed) return null;\n\n const displayLabel = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'moreItems');\n\n return (\n <Collapsible>\n <CollapsibleTrigger asChild>\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n className=\"w-full justify-start gap-element text-muted-foreground hover:text-foreground\"\n >\n {renderIcon(\n StandardIconReference.MORE_HORIZONTAL,\n { size: IconSize.SM }\n )}\n <span>{displayLabel}</span>\n </Button>\n </CollapsibleTrigger>\n <CollapsibleContent className=\"space-y-item-xs ps-card\">\n {moreMenuItems.map(item => renderNavigationItem(item, 0))}\n </CollapsibleContent>\n </Collapsible>\n );\n };\n\n const renderSectionContent = (group: SectionGroup) => {\n const { contentKind } = group;\n\n if (contentKind === SidebarSectionContentKind.RESOURCE_BROWSER && group.resourceType) {\n return (\n <SidebarResourceBrowser\n resourceType={group.resourceType}\n operation={group.operation}\n operationVariant={group.operationVariant}\n navigateOperation={group.navigateOperation}\n navigateOperationVariant={group.navigateOperationVariant}\n instanceFilter={group.instanceFilter}\n onInstanceClick={group.onInstanceClick}\n isCollapsed={sb.isCollapsed}\n />\n );\n }\n\n if (contentKind === SidebarSectionContentKind.GUIDANCE_WIDGET) {\n const ref = group.guidanceRef;\n if (!ref) return null;\n const GuidanceComponent = ComponentRegistryService.resolve(ref as unknown as FrontendComponentType, CorePresetNames.DEFAULT);\n if (!GuidanceComponent) {\n if (envLoader.isDevelopment()) console.warn(`[Sidebar] No registered component for guidance widget \"${ref}\"`);\n return null;\n }\n return (\n <React.Suspense fallback={<div className=\"h-8 animate-pulse motion-reduce:animate-none bg-muted rounded\" aria-hidden=\"true\" />}>\n <GuidanceComponent />\n </React.Suspense>\n );\n }\n\n if (contentKind === SidebarSectionContentKind.CUSTOM_COMPONENT) {\n const ref = group.componentRef;\n if (!ref) return null;\n const CustomComponent = ComponentRegistryService.resolve(ref as unknown as FrontendComponentType, CorePresetNames.DEFAULT);\n if (!CustomComponent) {\n if (envLoader.isDevelopment()) console.warn(`[Sidebar] No registered component for custom component \"${ref}\"`);\n return null;\n }\n return (\n <React.Suspense fallback={<div className=\"h-8 animate-pulse motion-reduce:animate-none bg-muted rounded\" aria-hidden=\"true\" />}>\n <CustomComponent />\n </React.Suspense>\n );\n }\n\n return (\n <>\n {group.items.map(item => renderHierarchicalItem(item))}\n {renderMoreMenu(group.moreMenuItems)}\n {renderInlineCreate(group.section)}\n </>\n );\n };\n\n const renderSection = (group: SectionGroup) => {\n const { section } = group;\n const sectionCollapsed = sb.isSectionCollapsed(section);\n const showLabel = section.showLabel;\n const getSectionLabel = () => tSidebarSection(section.ref);\n\n if (!section.collapsible || sb.isCollapsed) {\n return (\n <div key={section.ref} className=\"space-y-item-xs\">\n {showLabel && !sb.isCollapsed && (\n <div className=\"px-card-sm py-card-sm text-xs font-medium text-muted-foreground uppercase tracking-wider\">\n {getSectionLabel()}\n </div>\n )}\n {renderSectionContent(group)}\n </div>\n );\n }\n\n return (\n <Collapsible\n key={section.ref}\n open={!sectionCollapsed}\n onOpenChange={() => sb.handleToggleSectionCollapse(section.ref)}\n >\n {showLabel && (\n <CollapsibleTrigger asChild>\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n className=\"w-full justify-between px-card-sm py-card-sm text-xs font-medium text-muted-foreground uppercase tracking-wider hover:text-foreground\"\n >\n <span>{getSectionLabel()}</span>\n <span className=\"flex-shrink-0\">\n {renderIcon(\n sectionCollapsed ? StandardIconReference.CHEVRON_RIGHT : StandardIconReference.CHEVRON_DOWN,\n { size: IconSize.XS }\n )}\n </span>\n </Button>\n </CollapsibleTrigger>\n )}\n <CollapsibleContent className=\"space-y-item-xs\">\n {renderSectionContent(group)}\n </CollapsibleContent>\n </Collapsible>\n );\n };\n\n /**\n * The rail-collapse toggle itself. A PANEL glyph, never a chevron: a chevron is\n * the framework's NAVIGATION vocabulary (back / forward / expand-a-tree), so\n * pointing one at the edge of the shell reads as \"go back\" rather than \"fold\n * this panel\". The glyph mirrors with `placement` so it always depicts the\n * panel it toggles, and stays the SAME in both states — what changes is the\n * accessible name (`expand` / `collapse`), not the picture.\n */\n const renderCollapseToggle = (className?: string) => {\n const collapseIconRef = sb.placement === HorizontalPlacement.START\n ? StandardIconReference.PANEL_LEFT\n : StandardIconReference.PANEL_RIGHT;\n\n const collapseLabel = tComponent(\n FrontendComponentType.APPLICATION_LEVEL_SIDEBAR,\n sb.isCollapsed ? 'expand' : 'collapse'\n );\n\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={sb.handleToggleCollapse}\n aria-expanded={!sb.isCollapsed}\n aria-label={collapseLabel}\n title={collapseLabel}\n data-slot=\"sidebar-collapse-toggle\"\n className={cn('text-muted-foreground hover:text-foreground', className)}\n >\n <span className=\"flex-shrink-0\">\n {renderIcon(collapseIconRef, { size: IconSize.SM })}\n </span>\n </Button>\n );\n };\n\n /**\n * BRAND_HEADER hosts the toggle at the trailing edge of its own row — which\n * costs NO extra height, because it shares the line the brand already\n * occupies. That only works while expanded: a collapsed rail is a single\n * ~64px icon column with no room beside the mark, and stacking the toggle\n * under it spends a whole extra row of the rail's scarcest axis. So the rail\n * hands the control back to the quiet bottom host. The two are mutually\n * exclusive by construction — one toggle, never two, never zero.\n */\n const collapseToggleHostedInBrandHeader =\n HOME_AFFORDANCE_BY_MODE[sb.homeDisplayMode] === 'brand-header'\n && sb.sidebarConfig.isCollapsible\n && !sb.isCollapsed;\n\n const renderCollapseButton = () => {\n if (!sb.sidebarConfig.isCollapsible || collapseToggleHostedInBrandHeader) return null;\n\n return (\n // Quiet control at the BOTTOM of the sidebar: invisible until the pointer\n // enters the sidebar (eased fade via motion tokens). Keyboard users get it\n // on focus (focus-within) and coarse pointers — which have no hover —\n // always see it. `group/app-sidebar` is set on the sidebar wrapper.\n <div\n className={cn(\n 'p-card-sm',\n 'opacity-0 transition-opacity duration-[var(--motion-duration-normal)] ease-[var(--motion-easing-default)] motion-reduce:transition-none',\n 'group-hover/app-sidebar:opacity-100 group-focus-within/app-sidebar:opacity-100 pointer-coarse:opacity-100',\n )}\n >\n {renderCollapseToggle(cn('w-full', sb.isCollapsed ? 'justify-center' : 'justify-start'))}\n </div>\n );\n };\n\n // Container-inversion: components hosted inside the sidebar (e.g. the\n // command-menu trigger), resolved via the registry and mounted with the\n // shell-level interaction-owner props — the SAME bridge the menubar uses.\n // While the rail is COLLAPSED the full input-like trigger can't fit the narrow\n // icon column, so the hosted component is told to render COMPACT (icon-only)\n // via `compact` — this keeps the palette reachable on a collapsed desktop rail\n // AND on the mobile burger (where the rail is always collapsed), instead of\n // vanishing entirely.\n const renderHostedComponents = (placement: VerticalPlacement) => {\n const hosted = sb.hostedComponents.filter(\n comp => (comp.placement ?? VerticalPlacement.TOP) === placement,\n );\n if (hosted.length === 0) return null;\n\n return (\n <div\n className={cn(\n 'px-card-sm space-y-item-xs',\n // Edge-aligned insets: the sidebar's outer rhythm is 8px (`card-sm`,\n // matching the nav's `p-card-sm`), so the edge-facing side gets the\n // full inset while the content-facing side stays light — the adjacent\n // nav/list padding supplies the rest of the separation. The previous\n // uniform `py-item-xs` left the TOP-hosted search trigger 1px from\n // the sidebar's top edge.\n placement === VerticalPlacement.TOP ? 'pt-card-sm pb-item-xs' : 'pt-item-xs pb-card-sm',\n sb.isCollapsed && 'flex flex-col items-center',\n )}\n >\n {hosted.map(comp => {\n const Component = ComponentRegistryService.resolve(\n comp.frontendComponentType,\n comp.presetName ?? CorePresetNames.DEFAULT,\n );\n if (!Component) {\n if (envLoader.isDevelopment()) console.warn(`[Sidebar] No registered component for hosted component \"${comp.frontendComponentType}\"`);\n return null;\n }\n return (\n <React.Suspense\n key={comp.instanceId}\n fallback={<div className=\"h-9 animate-pulse motion-reduce:animate-none bg-muted rounded\" aria-hidden=\"true\" />}\n >\n <Component\n {...getHostedComponentProps(comp.component, comp.instanceId)}\n containerType={ApplicationLevelComponentType.SIDEBAR}\n containerPlacement={comp.placement}\n triggerWidth={comp.triggerWidth}\n compact={sb.isCollapsed}\n />\n </React.Suspense>\n );\n })}\n </div>\n );\n };\n\n const renderSidebarContent = () => {\n // Primary sections form ONE unlabeled group at the top (the hook already\n // forces them headerless/non-collapsible and orders them first), headed by\n // the framework Home row when `homeDisplayMode` is NAVIGATION_ITEM —\n // `renderHomeLink` returns null in the other modes, leaving the group to\n // the app's own destinations. Everything else renders as titled sections.\n const primaryGroups = sb.groupedSections.filter(group => group.section.isPrimary);\n const secondaryGroups = sb.groupedSections.filter(group => !group.section.isPrimary);\n\n return (\n <>\n {/* `min-h-0` lets the ScrollArea actually shrink inside the flex column —\n without it the nav content dictates the column height and overflow\n escapes to the shell instead of scrolling internally (E4).\n\n `type=AUTO` is load-bearing, not cosmetic. Radix drives the viewport's\n overflow from whether a scrollbar is MOUNTED\n (`overflowY: scrollbarYEnabled ? 'scroll' : 'hidden'`), and its default\n `type=\"hover\"` only mounts one on `pointerenter`. Without this the rail\n was `overflow: hidden` until hovered — content below the fold was\n unreachable, and on touch (the mobile drawer) the first gesture scrolled\n the PAGE instead. AUTO mounts the scrollbar from content overflow\n (ResizeObserver), so wheel/touch/keyboard work immediately in BOTH the\n expanded column and the collapsed rail. Radix positions the scrollbar\n `absolute`, so it overlays rather than stealing rail width.\n `overscroll-contain` keeps a scroll that reaches the end from chaining\n out to the page behind the sidebar. */}\n <ScrollArea\n className=\"flex-1 min-h-0\"\n type={ScrollAreaType.AUTO}\n viewportClassName=\"overscroll-contain\"\n >\n {/* TOP-hosted components (the command-menu search trigger) SCROLL with\n the navigation — only the brand header stays pinned. A sidebar's\n vertical placement names where a component sits in the content\n column, and the palette remains reachable at any scroll position via\n its hotkey and the menubar trigger, so pinning it here would spend\n permanent rail height for no reachability gain. */}\n {renderHostedComponents(VerticalPlacement.TOP)}\n <nav aria-label={tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'navigationLabel')} className=\"p-card-sm space-y-item\">\n {/* Home + primary navigation: one visual group, same item rhythm as\n a section body (`space-y-item-xs`), no header between them. */}\n <div className=\"space-y-item-xs\">\n {renderHomeLink()}\n {primaryGroups.map(group => (\n <React.Fragment key={group.section.ref}>\n {renderSectionContent(group)}\n </React.Fragment>\n ))}\n </div>\n\n {sb.isNavigationLoading && !sb.hasItems && (\n <div role=\"status\" aria-live=\"polite\" className=\"px-card-sm py-card-sm text-sm text-muted-foreground\">\n {tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'loading')}\n </div>\n )}\n\n {secondaryGroups\n // Collapsed rail: a navigation section with nothing to render\n // must disappear entirely — otherwise its group separator stacks\n // against the next section's into a double line. Expanded mode\n // keeps empty sections (their titled header is the \"drop things\n // here\" cue). FAVORITES never reaches this filter while empty —\n // the behavior hook omits it entirely in both modes.\n .filter((group) =>\n !sb.isCollapsed\n || group.contentKind !== SidebarSectionContentKind.NAVIGATION_LIST\n || group.items.length > 0\n || group.moreMenuItems.length > 0)\n .map((group) => (\n <React.Fragment key={group.section.ref}>\n {/* Collapsed rail: draw the group boundary the hidden section\n title would otherwise provide (before EACH section — the\n first line also separates the primary group from the rest). */}\n {sb.isCollapsed && (\n <div role=\"presentation\" className={cn(dividerRecipe.base, 'h-px mx-element')} />\n )}\n {renderSection(group)}\n </React.Fragment>\n ))}\n\n {!sb.isNavigationLoading && !sb.hasItems && (\n <div className=\"px-card-sm py-card-sm text-sm text-muted-foreground\">\n {tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'noItems')}\n </div>\n )}\n </nav>\n </ScrollArea>\n </>\n );\n };\n\n // ── Mobile overlay drawer (responsivePolicy BURGER at/below the configured\n // responsiveBreakpoint) ─────────────────────────────────────────────────────\n // The schema documents BURGER as \"burger menu / drawer overlay on mobile\":\n // nothing renders inline (width 0 — no 45%-wide rail eating the viewport);\n // the sidebar opens as a Sheet overlay instead. Radix supplies the backdrop\n // (click-closes), Escape handling, focus trap and a close button. The trigger\n // lives in the menubar (mobile-only burger) and speaks HOTKEY_SIDEBAR_TOGGLE.\n if (sb.isMobileDrawerMode) {\n const dir = (typeof document !== 'undefined' ? document.documentElement?.dir : undefined) || 'ltr';\n const drawerSide = resolvePlacementSideToRadix(\n sb.placement === HorizontalPlacement.START ? PlacementSide.START : PlacementSide.END,\n dir as 'ltr' | 'rtl',\n );\n\n return (\n <Sheet open={sb.isMobileDrawerOpen} onOpenChange={(open) => { if (!open) sb.closeMobileDrawer(); }}>\n <SheetContent\n side={drawerSide}\n data-component-area={`sidebar-${sb.placement}`}\n data-placement={sb.placement}\n data-responsive-policy={sb.sidebarConfig.responsivePolicy}\n data-mobile-drawer=\"true\"\n data-breakpoint={currentBreakpoint}\n className=\"gap-0\"\n style={{ width: `${sb.sidebarConfig.currentWidth}px` }}\n >\n {/* Radix Dialog a11y: the drawer needs an accessible name; visually the\n nav content is self-describing, so the title is screen-reader-only. */}\n <SheetTitle className=\"sr-only\">{tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'sidebarLabel')}</SheetTitle>\n <aside\n aria-label={tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'sidebarLabel')}\n className=\"flex-1 min-h-0 flex flex-col\"\n >\n {renderBrandHeader()}\n {renderSidebarContent()}\n {renderHostedComponents(VerticalPlacement.BOTTOM)}\n {/* No collapse chevron in the drawer: rail collapse is a desktop\n concept, and the SheetContent already renders a close button. */}\n </aside>\n </SheetContent>\n </Sheet>\n );\n }\n\n return (\n <Surface asChild emitPolicyVars={false} variant={SurfaceVariant.SHELL} policyOverride={NON_CANONICAL_SHELL_SURFACE_POLICY_OVERRIDE}>\n <div\n data-component-area={`sidebar-${sb.placement}`}\n data-placement={sb.placement}\n data-collapsible={sb.sidebarConfig.isCollapsible}\n data-collapsed={sb.isCollapsed}\n data-responsive-policy={sb.sidebarConfig.responsivePolicy}\n data-breakpoint={currentBreakpoint}\n className={cn(\n // Named group so the bottom collapse control can fade in on hover /\n // focus-within of the whole sidebar region.\n 'group/app-sidebar',\n // Height chain (E4): fill the shell row and allow the internal flex\n // column to shrink, so overflow scrolls INSIDE the ScrollArea instead\n // of stretching the whole shell vertically.\n 'h-full min-h-0',\n isContinuousShell\n // CONTINUOUS: transparent region of the shared canvas — no slab,\n // no edge border; page foreground for content.\n ? 'bg-transparent text-foreground'\n : cn(sb.sidebarConfig.placementClass, 'border-surface-sunken-border bg-surface-sunken text-surface-sunken-foreground'),\n 'transition-all duration-[var(--motion-duration-normal)] motion-reduce:transition-none',\n )}\n style={{ width: `${sb.sidebarConfig.currentWidth}px` }}\n >\n <aside aria-label={tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'sidebarLabel')} className=\"h-full min-h-0 flex flex-col\">\n {renderBrandHeader()}\n {renderSidebarContent()}\n {renderHostedComponents(VerticalPlacement.BOTTOM)}\n {renderCollapseButton()}\n </aside>\n </div>\n </Surface>\n );\n};\n"]}
|
|
1
|
+
{"version":3,"file":"sidebar.js","sourceRoot":"","sources":["../../../../../../src/components/navigation/app-level/sidebar.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,aAAa,EAAE,iBAAiB,EAAE,eAAe,EAAE,uBAAuB,EAAE,cAAc,EAAE,UAAU,EAAE,iBAAiB,EAAE,2BAA2B,EAAE,MAAM,qCAAqC,CAAC;AACtR,OAAO,EAEL,0BAA0B,EAC1B,yBAAyB,EAKzB,6BAA6B,EAC7B,MAAM,EACN,sBAAsB,EACtB,SAAS,EACT,UAAU,EACV,cAAc,EACd,WAAW,EACX,kBAAkB,EAClB,kBAAkB,EAClB,OAAO,EACP,QAAQ,EACR,qBAAqB,EACrB,mBAAmB,EACnB,eAAe,EACf,KAAK,EACL,8BAA8B,EAC9B,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,KAAK,EACL,YAAY,EACZ,UAAU,EACV,sBAAsB,EACtB,wBAAwB,EACxB,SAAS,EACT,EAAE,EACF,2CAA2C,EAC3C,OAAO,GACR,MAAM,6BAA6B,CAAC;AAErC;;;;;;GAMG;AACH,MAAM,uBAAuB,GAA+E;IAC1G,CAAC,sBAAsB,CAAC,YAAY,CAAC,EAAE,cAAc;IACrD,CAAC,sBAAsB,CAAC,eAAe,CAAC,EAAE,gBAAgB;IAC1D,CAAC,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,EACnB,oBAAoB,EAAE,EACtB,sBAAsB,CAAC,iBAAiB,CAAC,MAAM,CAAC,IAG3C,IACK,GACT,CACT,CAAC;IACJ,CAAC;IAED,OAAO,CACL,KAAC,OAAO,IAAC,OAAO,QAAC,cAAc,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,KAAK,EAAE,cAAc,EAAE,2CAA2C,YAChI,qCACuB,WAAW,EAAE,CAAC,SAAS,EAAE,oBAC9B,EAAE,CAAC,SAAS,sBACV,EAAE,CAAC,aAAa,CAAC,aAAa,oBAChC,EAAE,CAAC,WAAW,4BACN,EAAE,CAAC,aAAa,CAAC,gBAAgB,qBACxC,iBAAiB,EAClC,SAAS,EAAE,EAAE;YACX,oEAAoE;YACpE,4CAA4C;YAC5C,mBAAmB;YACnB,oEAAoE;YACpE,sEAAsE;YACtE,4CAA4C;YAC5C,gBAAgB,EAChB,iBAAiB;gBACf,iEAAiE;gBACjE,+CAA+C;gBAC/C,CAAC,CAAC,gCAAgC;gBAClC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,aAAa,CAAC,cAAc,EAAE,+EAA+E,CAAC,EACxH,uFAAuF,CACxF,EACD,KAAK,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,aAAa,CAAC,YAAY,IAAI,EAAE,YAEtD,+BAAmB,UAAU,CAAC,qBAAqB,CAAC,yBAAyB,EAAE,cAAc,CAAC,EAAE,SAAS,EAAC,8BAA8B,aACrI,iBAAiB,EAAE,EACnB,oBAAoB,EAAE,EACtB,sBAAsB,CAAC,iBAAiB,CAAC,MAAM,CAAC,EAChD,oBAAoB,EAAE,IACjB,GACJ,GACE,CACX,CAAC;AACJ,CAAC,CAAC","sourcesContent":["import React from 'react';\n\nimport { BrandAssetComposition } from '@wildo-ai/saas-models';\n\nimport { ButtonSize, CorePresetNames, FrontendComponentType, HorizontalPlacement, PlacementSide, SelectableVariant, ShellAppearance, SidebarCompactLabelMode, SurfaceVariant, UIBehavior, VerticalPlacement, resolvePlacementSideToRadix } from '@wildo-ai/presets-components-models';\nimport {\n type SectionRenderProps,\n SidebarSectionInlineCreate,\n SidebarSectionContentKind,\n AnyNavigationItem,\n HierarchicalNavigationItem,\n SectionGroup,\n ApplicationLevelProps_Sidebar,\n ApplicationLevelComponentType,\n Button,\n ButtonVariants_Variant,\n InputRoot,\n ScrollArea,\n ScrollAreaType,\n Collapsible,\n CollapsibleContent,\n CollapsibleTrigger,\n useI18n,\n IconSize,\n StandardIconReference,\n NavigationItemBadge,\n useIconRegistry,\n useUI,\n useHostedComponentInteractions,\n TruncatedText,\n useSidebarBehavior,\n SidebarHomeDisplayMode,\n Sheet,\n SheetContent,\n SheetTitle,\n SidebarResourceBrowser,\n ComponentRegistryService,\n envLoader,\n cn,\n NON_CANONICAL_SHELL_SURFACE_POLICY_OVERRIDE,\n Surface,\n} from '@wildo-ai/saas-frontend-lib';\n\n/**\n * Which single home affordance each mode renders — the mutual exclusion as\n * DATA, so a future `SidebarHomeDisplayMode` member cannot compile without\n * declaring its answer. Two independent predicates could drift into rendering\n * both affordances (or neither); this map is the one source both renderers gate\n * on.\n */\nconst HOME_AFFORDANCE_BY_MODE: Record<SidebarHomeDisplayMode, 'brand-header' | 'navigation-row' | 'none'> = {\n [SidebarHomeDisplayMode.BRAND_HEADER]: 'brand-header',\n [SidebarHomeDisplayMode.NAVIGATION_ITEM]: 'navigation-row',\n [SidebarHomeDisplayMode.HIDDEN]: 'none',\n};\n\nexport const ApplicationLevelPreset_Sidebar_Default: React.FC<ApplicationLevelProps_Sidebar> = ({\n placement = HorizontalPlacement.START,\n isCollapsed: externalIsCollapsed,\n onToggleCollapse\n}) => {\n\n const sb = useSidebarBehavior({ placement, isCollapsed: externalIsCollapsed, onToggleCollapse });\n const { renderIcon } = useIconRegistry();\n const { tComponent, tSidebarSection, isReady } = useI18n({ component: FrontendComponentType.APPLICATION_LEVEL_SIDEBAR });\n const { UIConfig, getRecipe, shellAppearance, sidebarCompactLabelMode } = useUI();\n const { getHostedComponentProps } = useHostedComponentInteractions();\n const currentBreakpoint = UIConfig?.currentBreakpoint;\n\n // CONTINUOUS shell chrome: the sidebar is a transparent region of the shared\n // canvas (theme backgroundLayer) — no sunken slab, no separating edge border.\n const isContinuousShell = shellAppearance === ShellAppearance.CONTINUOUS;\n // Compact rail with labels under icons (theme design policy). Only relevant\n // while collapsed; expanded rendering is unchanged.\n const showCompactLabels = sb.isCollapsed && sidebarCompactLabelMode === SidebarCompactLabelMode.ICON_AND_LABEL;\n\n // Nav items consume the theme's SELECTABLE/FILLED recipe (the vocabulary for\n // \"sidebar active items\") instead of hardcoding state classes: the active\n // look is a subtle `surface-sunken-accent` overlay + `font-medium` — weight,\n // not a primary tint — and stays themable. Items opt in via `data-active`.\n // These classes are appended AFTER the Button GHOST recipe (cn/tailwind-merge\n // puts `className` last), so the sidebar hover wash wins over GHOST's.\n const selectableRecipe = getRecipe(UIBehavior.SELECTABLE, SelectableVariant.FILLED);\n const navItemStateClasses = cn(\n selectableRecipe.states.hover,\n selectableRecipe.states.selected,\n selectableRecipe.motion.transition,\n );\n\n // The brand header takes the SAME themed hover wash as navigation rows but\n // deliberately NOT the selected state — identity is not a selectable\n // destination, and a permanently-filled header on the home route reads as a\n // stuck menu item.\n const brandHoverClasses = cn(\n selectableRecipe.states.hover,\n selectableRecipe.motion.transition,\n );\n\n // Compact rail: section titles are hidden, so group boundaries are drawn as\n // thin separator lines instead (theme DIVIDER recipe — stays themable).\n const dividerRecipe = getRecipe(UIBehavior.DIVIDER);\n\n // A brand asset URL comes from application CONFIG, but SERVING the file is the\n // application's own responsibility — a declared asset can 404 (or fall through\n // to an SPA html response). Track a failed load so the header degrades to its\n // no-logo presentation rather than rendering a broken image, and reset the\n // flag whenever the resolved URL changes (e.g. a light/dark theme switch).\n const brandLogoUrl = sb.brandHeader?.logoUrl;\n const [brandLogoFailed, setBrandLogoFailed] = React.useState(false);\n React.useEffect(() => setBrandLogoFailed(false), [brandLogoUrl]);\n\n const renderNavigationItem = (item: AnyNavigationItem, indent: number = 0) => {\n // Identity-keyed active check (resolved item id, not raw path) — two distinct\n // items sharing an identical urlPath must not both highlight; the behavior hook\n // elects one id. (Ids are deterministic per target, so the SAME target declared\n // in two sections shares one id and would still co-highlight — a config smell.)\n const isActive = sb.isNavigationItemActive(item);\n\n // Star affordance (favorites): only when a FAVORITES section is configured\n // and the rail is expanded (the collapsed rail has no hover surface for a\n // secondary action). Rendered as a SIBLING absolutely-positioned button —\n // a button must not contain interactive descendants — hover/focus-revealed,\n // and pinned visible while the item IS favorited (the \"star when favorite\n // is active\" cue). Favorites-section copies carry `favoriteId`, so the same\n // toggle unfavorites from there.\n const showStarAffordance = sb.hasFavoritesSection && !sb.isCollapsed;\n const isFavorite = showStarAffordance && sb.isItemFavorite(item);\n\n const itemButton = (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => sb.handleNavigationClick(item)}\n aria-current={isActive ? 'page' : undefined}\n data-active={isActive || undefined}\n // Resolved-item id (deterministic per target, e.g. `resolved-todos-list-default`)\n // as the i18n-independent automation hook — labels are runtime-translated.\n data-nav-item-id={item.id}\n className={cn(\n 'w-full justify-start gap-field-sm relative',\n navItemStateClasses,\n // Reserve the trailing star slot so hover-reveal does not reflow the\n // label/badge (the badge sits before the star, like Linear's row\n // action cluster).\n showStarAffordance && 'pe-8',\n sb.isCollapsed && !showCompactLabels && 'justify-center px-card-sm',\n // Icon-above-label rail item: intrinsic height (labels may wrap),\n // roomier vertical padding (`py-element` = spacing token) so each\n // entry breathes like a proper rail tile, not a squeezed row.\n showCompactLabels && 'h-auto min-h-8 flex-col items-center justify-center gap-1.5 px-1 py-element',\n )}\n style={{ paddingInlineStart: sb.isCollapsed ? undefined : `${12 + indent * 16}px` }}\n title={sb.isCollapsed && !showCompactLabels ? item.label : undefined}\n >\n {item.icon && (\n // Rail mode upsizes icons to MD (20px): with labels reduced to 11px,\n // the icon is the primary glyph and SM (16px) reads under-weighted.\n // CSS `size-*` on the wrapper wins over the svg's width/height attrs.\n <span className={cn('flex-shrink-0 relative', sb.isCollapsed && '[&_svg]:size-5')}>\n {item.icon}\n {sb.isCollapsed && item.notificationBadgeRef && (\n // Collapsed rail: the badge overlays the icon's top-end corner\n // (the expanded row shows it inline after the label instead).\n <span className=\"absolute -top-1.5 -end-1.5 z-10\">\n <NavigationItemBadge notificationBadgeRef={item.notificationBadgeRef} label={item.label} />\n </span>\n )}\n </span>\n )}\n {!sb.isCollapsed && (\n <>\n <TruncatedText className=\"flex-1 text-start\" tooltipSide={PlacementSide.END}>\n {item.label}\n </TruncatedText>\n {item.notificationBadgeRef && (\n <span className=\"ms-auto flex-shrink-0\">\n <NavigationItemBadge notificationBadgeRef={item.notificationBadgeRef} label={item.label} />\n </span>\n )}\n </>\n )}\n {showCompactLabels && (\n // The label is the primary affordance in this mode: it wraps onto\n // several lines rather than truncating (theme policy contract).\n <span className=\"w-full text-center text-[11px] leading-tight whitespace-normal break-words\">\n {item.label}\n </span>\n )}\n </Button>\n );\n\n if (!showStarAffordance) {\n return <React.Fragment key={item.id}>{itemButton}</React.Fragment>;\n }\n\n const favoriteLabel = tComponent(\n FrontendComponentType.APPLICATION_LEVEL_SIDEBAR,\n isFavorite ? 'favoriteRemove' : 'favoriteAdd',\n );\n\n return (\n <div key={item.id} className=\"relative group/navitem\">\n {itemButton}\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={(e) => {\n e.stopPropagation();\n sb.handleToggleItemFavorite(item);\n }}\n aria-pressed={isFavorite}\n aria-label={favoriteLabel}\n title={favoriteLabel}\n className={cn(\n 'absolute end-1 top-1/2 -translate-y-1/2 z-10 h-6 w-6 p-0 justify-center',\n 'text-muted-foreground hover:text-foreground',\n isFavorite\n ? 'opacity-100'\n : cn(\n 'opacity-0 transition-opacity duration-[var(--motion-duration-fast)] motion-reduce:transition-none',\n 'group-hover/navitem:opacity-100 group-focus-within/navitem:opacity-100 pointer-coarse:opacity-100',\n ),\n )}\n >\n <span className={cn('flex-shrink-0', isFavorite && '[&_svg]:fill-current')}>\n {renderIcon(StandardIconReference.STAR, { size: IconSize.XS })}\n </span>\n </Button>\n </div>\n );\n };\n\n const renderHierarchicalItem = (item: HierarchicalNavigationItem, indent: number = 0) => {\n const hasChildren = item.children && item.children.length > 0;\n const itemCollapsed = sb.isItemCollapsed(item.id);\n const isActive = sb.isNavigationItemActive(item);\n\n if (sb.isCollapsed || !hasChildren) {\n return renderNavigationItem(item, indent);\n }\n\n return (\n <Collapsible\n key={item.id}\n open={!itemCollapsed}\n onOpenChange={() => sb.handleToggleItemCollapse(item.id)}\n >\n <CollapsibleTrigger asChild>\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n aria-current={isActive ? 'page' : undefined}\n data-active={isActive || undefined}\n className={cn(\n 'w-full justify-start gap-field-sm relative',\n navItemStateClasses,\n )}\n style={{ paddingInlineStart: `${12 + indent * 16}px` }}\n >\n {item.icon && (\n <span className=\"flex-shrink-0\">\n {item.icon}\n </span>\n )}\n <TruncatedText className=\"flex-1 text-start\" tooltipSide={PlacementSide.END}>\n {item.label}\n </TruncatedText>\n <span className=\"ms-auto flex-shrink-0\">\n {renderIcon(\n itemCollapsed ? StandardIconReference.CHEVRON_RIGHT : StandardIconReference.CHEVRON_DOWN,\n { size: IconSize.XS }\n )}\n </span>\n </Button>\n </CollapsibleTrigger>\n <CollapsibleContent>\n <div className=\"space-y-item-xs\">\n {item.children?.map(child => renderNavigationItem(child, indent + 1))}\n </div>\n </CollapsibleContent>\n </Collapsible>\n );\n };\n\n /**\n * Pinned brand header (`SidebarHomeDisplayMode.BRAND_HEADER`): the app's\n * symbol + display name at the very top of the sidebar, OUTSIDE the scroll\n * region so it stays put while navigation scrolls — and therefore above any\n * TOP-hosted component such as the command-menu search trigger. It IS the\n * home button (Slack / Linear / Notion), so no Home row renders in this mode.\n */\n const renderBrandHeader = () => {\n if (HOME_AFFORDANCE_BY_MODE[sb.homeDisplayMode] !== 'brand-header' || !sb.brandHeader) return null;\n\n const homeLabel = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'home');\n const { name, logoUrl, logoComposition } = sb.brandHeader;\n\n // A WORDMARK/LOCKUP asset already CONTAINS the application name (the brand\n // resolver may return one when the app generated no symbol), so it replaces\n // the name label instead of sitting beside it — and it needs intrinsic width\n // rather than a square icon slot. Only a SYMBOL pairs with the text.\n const hasLogo = !!logoUrl && !brandLogoFailed;\n // Nothing identifiable to show (no name AND no usable mark) — render no\n // header rather than a nameless, unlabelled click target.\n if (!hasLogo && !name) return null;\n const logoCarriesName = hasLogo && logoComposition !== undefined && logoComposition !== BrandAssetComposition.SYMBOL;\n // The collapsed rail is an icon column: a wide mark cannot render there, so\n // it degrades to the framework home glyph exactly like a missing brand.\n const showSquareMark = hasLogo && !logoCarriesName;\n const showWideMark = hasLogo && logoCarriesName && !sb.isCollapsed;\n const showHomeGlyph = !showSquareMark && !showWideMark && sb.isCollapsed;\n // The name renders as text unless the mark already spells it.\n const showNameText = !sb.isCollapsed && !showWideMark;\n // Labelled rail falls back to the name ONLY when no mark resolved: a logo\n // already says which product this is, and repeating the name beneath it in\n // 11px spends rail height that navigation needs.\n const showCompactNameLabel = showCompactLabels && !showSquareMark;\n // Is the application name conveyed by something VISIBLE? A wide mark carries\n // it as `alt`; the two text branches carry it directly. When none render —\n // the logo-only rail — the button needs an explicit accessible name.\n const nameIsAnnounced = showNameText || showCompactNameLabel || showWideMark;\n\n const markImage = (className: string, alt: string) => (\n <img\n src={logoUrl}\n alt={alt}\n aria-hidden={alt === '' ? 'true' : undefined}\n onError={() => setBrandLogoFailed(true)}\n className={className}\n />\n );\n\n return (\n <div\n className={cn(\n 'px-card-sm pt-card-sm pb-item-xs flex items-center gap-element',\n // Rail: the mark alone, centred — the toggle lives at the bottom there.\n sb.isCollapsed && 'justify-center',\n )}\n >\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={sb.handleHomeClick}\n // `aria-current` stays truthful (the header DOES lead to the current\n // page when home is open) but NO `data-active` is set: the selected\n // fill belongs to navigation rows. The application's identity is not\n // a menu item that lights up — painting it selected made the product\n // name read as \"the highlighted row\", which is precisely the shell\n // language Linear/Notion/Slack reserve for navigation.\n aria-current={sb.isHomeActive ? 'page' : undefined}\n data-slot=\"sidebar-brand-header\"\n className={cn(\n // Its own register: taller than a nav row, hover-only affordance.\n // `min-w-0` lets the name truncate instead of pushing the collapse\n // toggle out of the row.\n 'flex-1 min-w-0 justify-start gap-field-sm h-11',\n brandHoverClasses,\n sb.isCollapsed && !showCompactLabels && 'justify-center px-card-sm',\n // Labelled rail (theme `SidebarCompactLabelMode.ICON_AND_LABEL`):\n // the brand tile follows the same icon-above-wrapped-label shape as\n // every other rail entry instead of staying an icon-only outlier.\n showCompactLabels && 'h-auto min-h-8 flex-col items-center justify-center gap-1.5 px-1 py-element',\n )}\n // Collapsed there is no visible text: the accessible name composes the\n // app name with the existing home label so the control still announces\n // WHAT it is and WHERE it leads — this covers the logo-only rail, whose\n // `alt=\"\"` mark would otherwise leave the button unnamed. When a name IS\n // visible it is the accessible name, and no `title` is set\n // (`TruncatedText` already supplies an overflow tooltip; a second one\n // would stack).\n aria-label={nameIsAnnounced ? undefined : `${name} — ${homeLabel}`}\n title={nameIsAnnounced ? undefined : `${name} — ${homeLabel}`}\n >\n {showSquareMark && markImage(cn('size-7 flex-shrink-0 rounded-md object-contain', sb.isCollapsed && 'size-5'), '')}\n {showWideMark && markImage('h-7 max-w-full flex-shrink-0 object-contain object-left', name)}\n {showHomeGlyph && (\n <span className=\"flex-shrink-0 [&_svg]:size-5\">\n {renderIcon(StandardIconReference.HOME, { size: IconSize.SM })}\n </span>\n )}\n {showNameText && (\n // Product identity type register — a step up from the 14px/500 nav\n // rows in size and weight, tightened so a longer name still reads as\n // one wordmark rather than a wrapped menu label.\n <TruncatedText className=\"flex-1 text-start text-base font-semibold tracking-tight leading-none\" tooltipSide={PlacementSide.END}>\n {name}\n </TruncatedText>\n )}\n {showCompactNameLabel && (\n // Labelled rail, but NO mark resolved: the name is the only thing\n // identifying the application, so it stands in for the logo. When a\n // mark IS present the rail shows the mark ALONE — a logo already\n // says which product this is, and repeating the name under it in\n // 11px steals rail height from navigation for no information.\n <span className=\"w-full text-center text-[11px] leading-tight whitespace-normal break-words\">\n {name}\n </span>\n )}\n </Button>\n {collapseToggleHostedInBrandHeader && (\n // Quiet by default (same fade contract as the former bottom control):\n // revealed on sidebar hover / focus-within, always visible to coarse\n // pointers, which have no hover to reveal it with.\n <span\n className={cn(\n 'flex-shrink-0',\n 'opacity-0 transition-opacity duration-[var(--motion-duration-normal)] ease-[var(--motion-easing-default)] motion-reduce:transition-none',\n 'group-hover/app-sidebar:opacity-100 group-focus-within/app-sidebar:opacity-100 pointer-coarse:opacity-100',\n )}\n >\n {renderCollapseToggle('h-8 w-8 p-0 justify-center')}\n </span>\n )}\n </div>\n );\n };\n\n const renderHomeLink = () => {\n if (HOME_AFFORDANCE_BY_MODE[sb.homeDisplayMode] !== 'navigation-row') return null;\n\n const homeLabel = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'home');\n const homeIcon = renderIcon(\n StandardIconReference.HOME,\n { size: IconSize.SM }\n );\n\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={sb.handleHomeClick}\n aria-current={sb.isHomeActive ? 'page' : undefined}\n data-active={sb.isHomeActive || undefined}\n className={cn(\n 'w-full justify-start gap-field-sm',\n navItemStateClasses,\n sb.isCollapsed && !showCompactLabels && 'justify-center px-card-sm',\n showCompactLabels && 'h-auto min-h-8 flex-col items-center justify-center gap-1.5 px-1 py-element',\n )}\n title={sb.isCollapsed && !showCompactLabels ? homeLabel : undefined}\n >\n <span className={cn('flex-shrink-0', sb.isCollapsed && '[&_svg]:size-5')}>{homeIcon}</span>\n {!sb.isCollapsed && <span>{homeLabel}</span>}\n {showCompactLabels && (\n <span className=\"w-full text-center text-[11px] leading-tight whitespace-normal break-words\">\n {homeLabel}\n </span>\n )}\n </Button>\n );\n };\n\n const renderInlineCreate = (section: SectionRenderProps) => {\n if (section.inlineCreate === SidebarSectionInlineCreate.NONE || sb.isCollapsed) {\n return null;\n }\n\n const isActive = sb.inlineCreate.activeSection === section.ref;\n const placeholder = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'inlineCreatePlaceholder');\n\n if (section.inlineCreate === SidebarSectionInlineCreate.INPUT) {\n if (!isActive) {\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => sb.inlineCreate.start(section.ref)}\n className=\"w-full justify-start gap-element text-muted-foreground hover:text-foreground\"\n >\n {renderIcon(\n StandardIconReference.PLUS,\n { size: IconSize.SM }\n )}\n <span className=\"text-sm\">{placeholder}</span>\n </Button>\n );\n }\n\n return (\n <div className=\"px-card-sm py-item-xs\">\n <InputRoot\n autoFocus\n type=\"text\"\n value={sb.inlineCreate.value}\n onChange={(e) => sb.inlineCreate.setValue(e.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n sb.inlineCreate.submit(section.ref, section.inlineCreateResourceType);\n } else if (e.key === 'Escape') {\n sb.inlineCreate.cancel();\n }\n }}\n onBlur={() => {\n setTimeout(sb.inlineCreate.cancel, 150);\n }}\n placeholder={placeholder}\n aria-label={placeholder}\n className=\"h-8 text-sm\"\n />\n </div>\n );\n }\n\n if (section.inlineCreate === SidebarSectionInlineCreate.DIALOG) {\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={() => {\n if (section.inlineCreateResourceType) {\n sb.inlineCreate.submit(section.ref, section.inlineCreateResourceType);\n }\n }}\n className=\"w-full justify-start gap-element text-muted-foreground hover:text-foreground\"\n >\n {renderIcon(\n StandardIconReference.PLUS,\n { size: IconSize.SM }\n )}\n <span className=\"text-sm\">{placeholder}</span>\n </Button>\n );\n }\n\n return null;\n };\n\n const renderMoreMenu = (moreMenuItems: HierarchicalNavigationItem[]) => {\n if (moreMenuItems.length === 0 || sb.isCollapsed) return null;\n\n const displayLabel = tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'moreItems');\n\n return (\n <Collapsible>\n <CollapsibleTrigger asChild>\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n className=\"w-full justify-start gap-element text-muted-foreground hover:text-foreground\"\n >\n {renderIcon(\n StandardIconReference.MORE_HORIZONTAL,\n { size: IconSize.SM }\n )}\n <span>{displayLabel}</span>\n </Button>\n </CollapsibleTrigger>\n <CollapsibleContent className=\"space-y-item-xs ps-card\">\n {moreMenuItems.map(item => renderNavigationItem(item, 0))}\n </CollapsibleContent>\n </Collapsible>\n );\n };\n\n const renderSectionContent = (group: SectionGroup) => {\n const { contentKind } = group;\n\n if (contentKind === SidebarSectionContentKind.RESOURCE_BROWSER && group.resourceType) {\n return (\n <SidebarResourceBrowser\n resourceType={group.resourceType}\n operation={group.operation}\n operationVariant={group.operationVariant}\n navigateOperation={group.navigateOperation}\n navigateOperationVariant={group.navigateOperationVariant}\n instanceFilter={group.instanceFilter}\n onInstanceClick={group.onInstanceClick}\n isCollapsed={sb.isCollapsed}\n />\n );\n }\n\n if (contentKind === SidebarSectionContentKind.GUIDANCE_WIDGET) {\n const ref = group.guidanceRef;\n if (!ref) return null;\n const GuidanceComponent = ComponentRegistryService.resolve(ref as unknown as FrontendComponentType, CorePresetNames.DEFAULT);\n if (!GuidanceComponent) {\n if (envLoader.isDevelopment()) console.warn(`[Sidebar] No registered component for guidance widget \"${ref}\"`);\n return null;\n }\n return (\n <React.Suspense fallback={<div className=\"h-8 animate-pulse motion-reduce:animate-none bg-muted rounded\" aria-hidden=\"true\" />}>\n <GuidanceComponent />\n </React.Suspense>\n );\n }\n\n if (contentKind === SidebarSectionContentKind.CUSTOM_COMPONENT) {\n const ref = group.componentRef;\n if (!ref) return null;\n const CustomComponent = ComponentRegistryService.resolve(ref as unknown as FrontendComponentType, CorePresetNames.DEFAULT);\n if (!CustomComponent) {\n if (envLoader.isDevelopment()) console.warn(`[Sidebar] No registered component for custom component \"${ref}\"`);\n return null;\n }\n return (\n <React.Suspense fallback={<div className=\"h-8 animate-pulse motion-reduce:animate-none bg-muted rounded\" aria-hidden=\"true\" />}>\n <CustomComponent />\n </React.Suspense>\n );\n }\n\n return (\n <>\n {group.items.map(item => renderHierarchicalItem(item))}\n {renderMoreMenu(group.moreMenuItems)}\n {renderInlineCreate(group.section)}\n </>\n );\n };\n\n const renderSection = (group: SectionGroup) => {\n const { section } = group;\n const sectionCollapsed = sb.isSectionCollapsed(section);\n const showLabel = section.showLabel;\n const getSectionLabel = () => tSidebarSection(section.ref);\n\n if (!section.collapsible || sb.isCollapsed) {\n return (\n <div key={section.ref} className=\"space-y-item-xs\">\n {showLabel && !sb.isCollapsed && (\n <div className=\"px-card-sm py-card-sm text-xs font-medium text-muted-foreground uppercase tracking-wider\">\n {getSectionLabel()}\n </div>\n )}\n {renderSectionContent(group)}\n </div>\n );\n }\n\n return (\n <Collapsible\n key={section.ref}\n open={!sectionCollapsed}\n onOpenChange={() => sb.handleToggleSectionCollapse(section.ref)}\n >\n {showLabel && (\n <CollapsibleTrigger asChild>\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n className=\"w-full justify-between px-card-sm py-card-sm text-xs font-medium text-muted-foreground uppercase tracking-wider hover:text-foreground\"\n >\n <span>{getSectionLabel()}</span>\n <span className=\"flex-shrink-0\">\n {renderIcon(\n sectionCollapsed ? StandardIconReference.CHEVRON_RIGHT : StandardIconReference.CHEVRON_DOWN,\n { size: IconSize.XS }\n )}\n </span>\n </Button>\n </CollapsibleTrigger>\n )}\n <CollapsibleContent className=\"space-y-item-xs\">\n {renderSectionContent(group)}\n </CollapsibleContent>\n </Collapsible>\n );\n };\n\n /**\n * The rail-collapse toggle itself. A PANEL glyph, never a chevron: a chevron is\n * the framework's NAVIGATION vocabulary (back / forward / expand-a-tree), so\n * pointing one at the edge of the shell reads as \"go back\" rather than \"fold\n * this panel\". The glyph mirrors with `placement` so it always depicts the\n * panel it toggles, and stays the SAME in both states — what changes is the\n * accessible name (`expand` / `collapse`), not the picture.\n */\n const renderCollapseToggle = (className?: string) => {\n const collapseIconRef = sb.placement === HorizontalPlacement.START\n ? StandardIconReference.PANEL_LEFT\n : StandardIconReference.PANEL_RIGHT;\n\n const collapseLabel = tComponent(\n FrontendComponentType.APPLICATION_LEVEL_SIDEBAR,\n sb.isCollapsed ? 'expand' : 'collapse'\n );\n\n return (\n <Button\n variant={ButtonVariants_Variant.GHOST}\n size={ButtonSize.SM}\n onClick={sb.handleToggleCollapse}\n aria-expanded={!sb.isCollapsed}\n aria-label={collapseLabel}\n title={collapseLabel}\n data-slot=\"sidebar-collapse-toggle\"\n className={cn('text-muted-foreground hover:text-foreground', className)}\n >\n <span className=\"flex-shrink-0\">\n {renderIcon(collapseIconRef, { size: IconSize.SM })}\n </span>\n </Button>\n );\n };\n\n /**\n * BRAND_HEADER hosts the toggle at the trailing edge of its own row — which\n * costs NO extra height, because it shares the line the brand already\n * occupies. That only works while expanded: a collapsed rail is a single\n * ~64px icon column with no room beside the mark, and stacking the toggle\n * under it spends a whole extra row of the rail's scarcest axis. So the rail\n * hands the control back to the quiet bottom host. The two are mutually\n * exclusive by construction — one toggle, never two, never zero.\n */\n const collapseToggleHostedInBrandHeader =\n HOME_AFFORDANCE_BY_MODE[sb.homeDisplayMode] === 'brand-header'\n && sb.sidebarConfig.isCollapsible\n && !sb.isCollapsed;\n\n const renderCollapseButton = () => {\n if (!sb.sidebarConfig.isCollapsible || collapseToggleHostedInBrandHeader) return null;\n\n return (\n // Bottom-hosted collapse control.\n //\n // PERSISTENT while the rail is COLLAPSED, quiet-on-hover while it is expanded.\n //\n // The quiet contract — invisible until the pointer enters the sidebar, revealed\n // on focus-within for keyboard users, always shown to coarse pointers that have\n // no hover — is a deliberate reduction of chrome noise, and it holds while the\n // sidebar is EXPANDED: the surface is full of labelled rows, so it says what it\n // is and the toggle is a secondary affordance.\n //\n // It does NOT hold while the rail is COLLAPSED, and shipping it that way is what\n // made this a defect rather than a preference. In the collapsed state the toggle\n // is the ONLY chrome on the surface, nothing else on screen says the rail opens,\n // and a fine-pointer user who never happens to hover the rail has no way to\n // discover that it does. That went unnoticed for as long as every application\n // started expanded (the brand header hosts a toggle there, on the line it\n // already occupies); the moment `SIDEBAR.defaultCollapsed` let an application\n // OPEN collapsed, a first-run operator met an icon rail with no visible way out\n // of it — measured on the application-creation workbench.\n //\n // Hiding a control is only quiet when something else answers the question it\n // would have answered.\n <div\n className={cn(\n 'p-card-sm',\n sb.isCollapsed\n ? 'opacity-100'\n : cn(\n 'opacity-0 transition-opacity duration-[var(--motion-duration-normal)] ease-[var(--motion-easing-default)] motion-reduce:transition-none',\n 'group-hover/app-sidebar:opacity-100 group-focus-within/app-sidebar:opacity-100 pointer-coarse:opacity-100',\n ),\n )}\n >\n {renderCollapseToggle(cn('w-full', sb.isCollapsed ? 'justify-center' : 'justify-start'))}\n </div>\n );\n };\n\n // Container-inversion: components hosted inside the sidebar (e.g. the\n // command-menu trigger), resolved via the registry and mounted with the\n // shell-level interaction-owner props — the SAME bridge the menubar uses.\n // While the rail is COLLAPSED the full input-like trigger can't fit the narrow\n // icon column, so the hosted component is told to render COMPACT (icon-only)\n // via `compact` — this keeps the palette reachable on a collapsed desktop rail\n // AND on the mobile burger (where the rail is always collapsed), instead of\n // vanishing entirely.\n const renderHostedComponents = (placement: VerticalPlacement) => {\n const hosted = sb.hostedComponents.filter(\n comp => (comp.placement ?? VerticalPlacement.TOP) === placement,\n );\n if (hosted.length === 0) return null;\n\n return (\n <div\n className={cn(\n 'px-card-sm space-y-item-xs',\n // Edge-aligned insets: the sidebar's outer rhythm is 8px (`card-sm`,\n // matching the nav's `p-card-sm`), so the edge-facing side gets the\n // full inset while the content-facing side stays light — the adjacent\n // nav/list padding supplies the rest of the separation. The previous\n // uniform `py-item-xs` left the TOP-hosted search trigger 1px from\n // the sidebar's top edge.\n placement === VerticalPlacement.TOP ? 'pt-card-sm pb-item-xs' : 'pt-item-xs pb-card-sm',\n sb.isCollapsed && 'flex flex-col items-center',\n )}\n >\n {hosted.map(comp => {\n const Component = ComponentRegistryService.resolve(\n comp.frontendComponentType,\n comp.presetName ?? CorePresetNames.DEFAULT,\n );\n if (!Component) {\n if (envLoader.isDevelopment()) console.warn(`[Sidebar] No registered component for hosted component \"${comp.frontendComponentType}\"`);\n return null;\n }\n return (\n <React.Suspense\n key={comp.instanceId}\n fallback={<div className=\"h-9 animate-pulse motion-reduce:animate-none bg-muted rounded\" aria-hidden=\"true\" />}\n >\n <Component\n {...getHostedComponentProps(comp.component, comp.instanceId)}\n containerType={ApplicationLevelComponentType.SIDEBAR}\n containerPlacement={comp.placement}\n triggerWidth={comp.triggerWidth}\n compact={sb.isCollapsed}\n />\n </React.Suspense>\n );\n })}\n </div>\n );\n };\n\n const renderSidebarContent = () => {\n // Primary sections form ONE unlabeled group at the top (the hook already\n // forces them headerless/non-collapsible and orders them first), headed by\n // the framework Home row when `homeDisplayMode` is NAVIGATION_ITEM —\n // `renderHomeLink` returns null in the other modes, leaving the group to\n // the app's own destinations. Everything else renders as titled sections.\n const primaryGroups = sb.groupedSections.filter(group => group.section.isPrimary);\n const secondaryGroups = sb.groupedSections.filter(group => !group.section.isPrimary);\n\n return (\n <>\n {/* `min-h-0` lets the ScrollArea actually shrink inside the flex column —\n without it the nav content dictates the column height and overflow\n escapes to the shell instead of scrolling internally (E4).\n\n `type=AUTO` is load-bearing, not cosmetic. Radix drives the viewport's\n overflow from whether a scrollbar is MOUNTED\n (`overflowY: scrollbarYEnabled ? 'scroll' : 'hidden'`), and its default\n `type=\"hover\"` only mounts one on `pointerenter`. Without this the rail\n was `overflow: hidden` until hovered — content below the fold was\n unreachable, and on touch (the mobile drawer) the first gesture scrolled\n the PAGE instead. AUTO mounts the scrollbar from content overflow\n (ResizeObserver), so wheel/touch/keyboard work immediately in BOTH the\n expanded column and the collapsed rail. Radix positions the scrollbar\n `absolute`, so it overlays rather than stealing rail width.\n `overscroll-contain` keeps a scroll that reaches the end from chaining\n out to the page behind the sidebar. */}\n <ScrollArea\n className=\"flex-1 min-h-0\"\n type={ScrollAreaType.AUTO}\n viewportClassName=\"overscroll-contain\"\n >\n {/* TOP-hosted components (the command-menu search trigger) SCROLL with\n the navigation — only the brand header stays pinned. A sidebar's\n vertical placement names where a component sits in the content\n column, and the palette remains reachable at any scroll position via\n its hotkey and the menubar trigger, so pinning it here would spend\n permanent rail height for no reachability gain. */}\n {renderHostedComponents(VerticalPlacement.TOP)}\n <nav aria-label={tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'navigationLabel')} className=\"p-card-sm space-y-item\">\n {/* Home + primary navigation: one visual group, same item rhythm as\n a section body (`space-y-item-xs`), no header between them. */}\n <div className=\"space-y-item-xs\">\n {renderHomeLink()}\n {primaryGroups.map(group => (\n <React.Fragment key={group.section.ref}>\n {renderSectionContent(group)}\n </React.Fragment>\n ))}\n </div>\n\n {sb.isNavigationLoading && !sb.hasItems && (\n <div role=\"status\" aria-live=\"polite\" className=\"px-card-sm py-card-sm text-sm text-muted-foreground\">\n {tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'loading')}\n </div>\n )}\n\n {secondaryGroups\n // No emptiness filter here on purpose — `useSidebarBehavior` omits\n // an empty navigation section from `groupedSections` in BOTH modes,\n // so every preset inherits the policy and cannot disagree with it.\n // This preset used to filter for the collapsed rail alone (an empty\n // section's separator otherwise stacked against the next one into a\n // double line) while expanded mode kept the empty header; that split\n // is what shipped permanently-empty TOOLS / SETTINGS headings.\n .map((group) => (\n <React.Fragment key={group.section.ref}>\n {/* Collapsed rail: draw the group boundary the hidden section\n title would otherwise provide (before EACH section — the\n first line also separates the primary group from the rest). */}\n {sb.isCollapsed && (\n <div role=\"presentation\" className={cn(dividerRecipe.base, 'h-px mx-element')} />\n )}\n {renderSection(group)}\n </React.Fragment>\n ))}\n\n {!sb.isNavigationLoading && !sb.hasItems && (\n <div className=\"px-card-sm py-card-sm text-sm text-muted-foreground\">\n {tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'noItems')}\n </div>\n )}\n </nav>\n </ScrollArea>\n </>\n );\n };\n\n // ── Mobile overlay drawer (responsivePolicy BURGER at/below the configured\n // responsiveBreakpoint) ─────────────────────────────────────────────────────\n // The schema documents BURGER as \"burger menu / drawer overlay on mobile\":\n // nothing renders inline (width 0 — no 45%-wide rail eating the viewport);\n // the sidebar opens as a Sheet overlay instead. Radix supplies the backdrop\n // (click-closes), Escape handling, focus trap and a close button. The trigger\n // lives in the menubar (mobile-only burger) and speaks HOTKEY_SIDEBAR_TOGGLE.\n if (sb.isMobileDrawerMode) {\n const dir = (typeof document !== 'undefined' ? document.documentElement?.dir : undefined) || 'ltr';\n const drawerSide = resolvePlacementSideToRadix(\n sb.placement === HorizontalPlacement.START ? PlacementSide.START : PlacementSide.END,\n dir as 'ltr' | 'rtl',\n );\n\n return (\n <Sheet open={sb.isMobileDrawerOpen} onOpenChange={(open) => { if (!open) sb.closeMobileDrawer(); }}>\n <SheetContent\n side={drawerSide}\n data-component-area={`sidebar-${sb.placement}`}\n data-placement={sb.placement}\n data-responsive-policy={sb.sidebarConfig.responsivePolicy}\n data-mobile-drawer=\"true\"\n data-breakpoint={currentBreakpoint}\n className=\"gap-0\"\n style={{ width: `${sb.sidebarConfig.currentWidth}px` }}\n >\n {/* Radix Dialog a11y: the drawer needs an accessible name; visually the\n nav content is self-describing, so the title is screen-reader-only. */}\n <SheetTitle className=\"sr-only\">{tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'sidebarLabel')}</SheetTitle>\n <aside\n aria-label={tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'sidebarLabel')}\n className=\"flex-1 min-h-0 flex flex-col\"\n >\n {renderBrandHeader()}\n {renderSidebarContent()}\n {renderHostedComponents(VerticalPlacement.BOTTOM)}\n {/* No collapse chevron in the drawer: rail collapse is a desktop\n concept, and the SheetContent already renders a close button. */}\n </aside>\n </SheetContent>\n </Sheet>\n );\n }\n\n return (\n <Surface asChild emitPolicyVars={false} variant={SurfaceVariant.SHELL} policyOverride={NON_CANONICAL_SHELL_SURFACE_POLICY_OVERRIDE}>\n <div\n data-component-area={`sidebar-${sb.placement}`}\n data-placement={sb.placement}\n data-collapsible={sb.sidebarConfig.isCollapsible}\n data-collapsed={sb.isCollapsed}\n data-responsive-policy={sb.sidebarConfig.responsivePolicy}\n data-breakpoint={currentBreakpoint}\n className={cn(\n // Named group so the bottom collapse control can fade in on hover /\n // focus-within of the whole sidebar region.\n 'group/app-sidebar',\n // Height chain (E4): fill the shell row and allow the internal flex\n // column to shrink, so overflow scrolls INSIDE the ScrollArea instead\n // of stretching the whole shell vertically.\n 'h-full min-h-0',\n isContinuousShell\n // CONTINUOUS: transparent region of the shared canvas — no slab,\n // no edge border; page foreground for content.\n ? 'bg-transparent text-foreground'\n : cn(sb.sidebarConfig.placementClass, 'border-surface-sunken-border bg-surface-sunken text-surface-sunken-foreground'),\n 'transition-all duration-[var(--motion-duration-normal)] motion-reduce:transition-none',\n )}\n style={{ width: `${sb.sidebarConfig.currentWidth}px` }}\n >\n <aside aria-label={tComponent(FrontendComponentType.APPLICATION_LEVEL_SIDEBAR, 'sidebarLabel')} className=\"h-full min-h-0 flex flex-col\">\n {renderBrandHeader()}\n {renderSidebarContent()}\n {renderHostedComponents(VerticalPlacement.BOTTOM)}\n {renderCollapseButton()}\n </aside>\n </div>\n </Surface>\n );\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sheet.d.ts","sourceRoot":"","sources":["../../../../../../src/components/overlays/containers/sheet.tsx"],"names":[],"mappings":"AAMA,OAAO,EAkBL,aAAa,EACd,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"sheet.d.ts","sourceRoot":"","sources":["../../../../../../src/components/overlays/containers/sheet.tsx"],"names":[],"mappings":"AAMA,OAAO,EAkBL,aAAa,EACd,MAAM,6BAA6B,CAAC;AAwLrC,QAAA,MAAM,KAAK,eAQT,CAAA;AAEF,OAAO,EAAE,KAAK,EAAE,CAAA"}
|
|
@@ -12,7 +12,7 @@ SheetTrigger.displayName = 'SheetTrigger';
|
|
|
12
12
|
function SheetClose({ ...props }) {
|
|
13
13
|
return _jsx(SheetPrimitive.Close, { "data-slot": "sheet-close", ...props });
|
|
14
14
|
}
|
|
15
|
-
const SheetContent = React.forwardRef(({ className, children, side = "right", surfacePolicyOverride, ...props }, ref) => {
|
|
15
|
+
const SheetContent = React.forwardRef(({ className, children, side = "right", surfacePolicyOverride, showBackdrop = true, ...props }, ref) => {
|
|
16
16
|
const { renderIcon } = useIconRegistry();
|
|
17
17
|
const { tComponent, isReady } = useI18n({
|
|
18
18
|
component: FrontendComponentType.LOW_LEVEL_SHEET,
|
|
@@ -24,7 +24,7 @@ const SheetContent = React.forwardRef(({ className, children, side = "right", su
|
|
|
24
24
|
const overlayRecipe = getRecipe(UIBehavior.OVERLAY_BACKDROP);
|
|
25
25
|
const { container, shouldPortal } = useSurfacePolicyPortalTarget(SurfaceVariant.OVERLAY, surfacePolicyOverride);
|
|
26
26
|
const stackingClass = useSurfacePolicyStackingClass(SurfaceVariant.OVERLAY, surfacePolicyOverride);
|
|
27
|
-
const content = (_jsxs(_Fragment, { children: [_jsx(SheetPrimitive.Overlay, { "data-slot": "sheet-overlay", className: cn("fixed inset-0", stackingClass, overlayRecipe.base, overlayRecipe.motion.enter, overlayRecipe.motion.exit) }), _jsx(Surface, { asChild: true, variant: SurfaceVariant.OVERLAY, modal: true, a11yManagedByHost: true, policyOverride: {
|
|
27
|
+
const content = (_jsxs(_Fragment, { children: [showBackdrop && (_jsx(SheetPrimitive.Overlay, { "data-slot": "sheet-overlay", className: cn("fixed inset-0", stackingClass, overlayRecipe.base, overlayRecipe.motion.enter, overlayRecipe.motion.exit) })), _jsx(Surface, { asChild: true, variant: SurfaceVariant.OVERLAY, modal: true, a11yManagedByHost: true, policyOverride: {
|
|
28
28
|
...surfacePolicyOverride,
|
|
29
29
|
containment: {
|
|
30
30
|
...surfacePolicyOverride?.containment,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sheet.js","sourceRoot":"","sources":["../../../../../../src/components/overlays/containers/sheet.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,cAAc,MAAM,wBAAwB,CAAA;AACxD,OAAO,EAAE,qBAAqB,EAAE,kBAAkB,EAAiC,cAAc,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAA;AAE7K,OAAO,EACL,EAAE,EACF,eAAe,EACf,qBAAqB,EACrB,QAAQ,EACR,OAAO,EACP,KAAK,EACL,4BAA4B,EAC5B,6BAA6B,EAC7B,oBAAoB,EACpB,OAAO,GASR,MAAM,6BAA6B,CAAC;AAOrC,SAAS,SAAS,CAAC,EAAE,GAAG,KAAK,EAAc;IACzC,OAAO,KAAC,cAAc,CAAC,IAAI,iBAAW,OAAO,KAAK,KAAK,GAAI,CAAA;AAC7D,CAAC;AAED,MAAM,YAAY,GAAG,KAAK,CAAC,UAAU,CACnC,CAAC,KAAK,EAAE,GAAG,EAAE,EAAE,CAAC,KAAC,cAAc,CAAC,OAAO,IAAC,GAAG,EAAE,GAAG,eAAY,eAAe,KAAK,KAAK,GAAI,CAC1F,CAAA;AACD,YAAY,CAAC,WAAW,GAAG,cAAc,CAAA;AAEzC,SAAS,UAAU,CAAC,EAAE,GAAG,KAAK,EAAmB;IAC/C,OAAO,KAAC,cAAc,CAAC,KAAK,iBAAW,aAAa,KAAK,KAAK,GAAI,CAAA;AACpE,CAAC;AAED,MAAM,YAAY,GAAG,KAAK,CAAC,UAAU,CACnC,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,GAAG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AAW,IACzB,GAAG,EAAE,GAAG,eACE,mBAAmB,EAC7B,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,SAAS,CAAC,KACjC,KAAK,GACT,CACH,CAAA;AACH,CAAC,CACF,CAAA;AACD,gBAAgB,CAAC,WAAW,GAAG,kBAAkB,CAAA;AAEjD,MAAM,KAAK,GAAG,oBAAoB,CAAgB,SAAS,EAAE;IAC3D,OAAO,EAAE,YAAY;IACrB,OAAO,EAAE,YAAY;IACrB,KAAK,EAAE,UAAU;IACjB,MAAM,EAAE,WAAW;IACnB,MAAM,EAAE,WAAW;IACnB,KAAK,EAAE,UAAU;IACjB,WAAW,EAAE,gBAAgB;CAC9B,CAAC,CAAA;AAEF,OAAO,EAAE,KAAK,EAAE,CAAA","sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport * as SheetPrimitive from \"@radix-ui/react-dialog\"\nimport { FrontendComponentType, InteractiveVariant, type DeepPartialSurfacePolicy, SurfaceVariant, TypographyVariant, UIBehavior } from \"@wildo-ai/presets-components-models\"\n\nimport {\n cn,\n useIconRegistry,\n StandardIconReference,\n IconSize,\n useI18n,\n useUI,\n useSurfacePolicyPortalTarget,\n useSurfacePolicyStackingClass,\n createCompoundPreset,\n Surface,\n SheetProps,\n SheetTriggerProps,\n SheetCloseProps,\n SheetHeaderProps,\n SheetFooterProps,\n SheetTitleProps,\n SheetDescriptionProps,\n SheetCompound,\n} from '@wildo-ai/saas-frontend-lib';\n\ntype SheetContentImplProps = React.ComponentPropsWithoutRef<typeof SheetPrimitive.Content> & {\n side?: 'top' | 'right' | 'bottom' | 'left'\n surfacePolicyOverride?: DeepPartialSurfacePolicy\n}\n\nfunction SheetRoot({ ...props }: SheetProps): React.JSX.Element {\n return <SheetPrimitive.Root data-slot=\"sheet\" {...props} />\n}\n\nconst SheetTrigger = React.forwardRef<HTMLButtonElement, SheetTriggerProps>(\n (props, ref) => <SheetPrimitive.Trigger ref={ref} data-slot=\"sheet-trigger\" {...props} />\n)\nSheetTrigger.displayName = 'SheetTrigger'\n\nfunction SheetClose({ ...props }: SheetCloseProps): React.JSX.Element {\n return <SheetPrimitive.Close data-slot=\"sheet-close\" {...props} />\n}\n\nconst SheetContent = React.forwardRef<HTMLDivElement, SheetContentImplProps>(\n ({ className, children, side = \"right\", surfacePolicyOverride, ...props }, ref) => {\n const { renderIcon } = useIconRegistry()\n const { tComponent, isReady } = useI18n({\n component: FrontendComponentType.LOW_LEVEL_SHEET,\n })\n const { getRecipe } = useUI()\n const closeLabel = tComponent(FrontendComponentType.LOW_LEVEL_SHEET, 'close')\n const surfaceRecipe = getRecipe(UIBehavior.SURFACE, SurfaceVariant.OVERLAY)\n const closeRecipe = getRecipe(UIBehavior.INTERACTIVE, InteractiveVariant.GHOST)\n const overlayRecipe = getRecipe(UIBehavior.OVERLAY_BACKDROP)\n const { container, shouldPortal } = useSurfacePolicyPortalTarget(SurfaceVariant.OVERLAY, surfacePolicyOverride)\n const stackingClass = useSurfacePolicyStackingClass(SurfaceVariant.OVERLAY, surfacePolicyOverride)\n\n const content = (\n <>\n <SheetPrimitive.Overlay\n data-slot=\"sheet-overlay\"\n className={cn(\n \"fixed inset-0\",\n stackingClass,\n overlayRecipe.base,\n overlayRecipe.motion.enter,\n overlayRecipe.motion.exit,\n )}\n />\n <Surface\n asChild\n variant={SurfaceVariant.OVERLAY}\n modal\n a11yManagedByHost\n policyOverride={{\n ...surfacePolicyOverride,\n containment: {\n ...surfacePolicyOverride?.containment,\n paddingBlock: 'none',\n paddingInline: 'none',\n maxHeight: 'none',\n overflow: 'visible',\n },\n geometry: {\n ...surfacePolicyOverride?.geometry,\n actionAlignment: 'stack',\n },\n }}\n >\n <SheetPrimitive.Content\n ref={ref}\n data-slot=\"sheet-content\"\n className={cn(\n \"fixed flex flex-col gap-field\",\n surfaceRecipe.base,\n \"data-[state=open]:animate-in data-[state=closed]:animate-out transition ease-[var(--motion-easing-default)] data-[state=closed]:duration-[var(--motion-duration-normal)] data-[state=open]:duration-[var(--motion-duration-slow)] motion-reduce:data-[state=open]:animate-none motion-reduce:data-[state=closed]:animate-none\",\n side === \"right\" &&\n \"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 end-0 h-full w-3/4 border-s sm:max-w-sm\",\n side === \"left\" &&\n \"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 start-0 h-full w-3/4 border-e sm:max-w-sm\",\n side === \"top\" &&\n \"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b\",\n side === \"bottom\" &&\n \"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t\",\n className\n )}\n {...props}\n >\n {children}\n <SheetPrimitive.Close className={cn(\n \"absolute top-4 end-4 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n closeRecipe.base,\n \"opacity-[0.7]\",\n closeRecipe.states.hover,\n closeRecipe.states.focus,\n closeRecipe.states.disabled,\n closeRecipe.states.open,\n closeRecipe.motion.transition,\n )}>\n {renderIcon(StandardIconReference.CLOSE, { size: IconSize.SM })}\n <span className=\"sr-only\">{closeLabel}</span>\n </SheetPrimitive.Close>\n </SheetPrimitive.Content>\n </Surface>\n </>\n )\n\n if (!shouldPortal) {\n return content\n }\n\n return (\n <SheetPrimitive.Portal container={container}>\n {content}\n </SheetPrimitive.Portal>\n )\n }\n)\nSheetContent.displayName = 'SheetContent'\n\nfunction SheetHeader({ className, ...props }: SheetHeaderProps): React.JSX.Element {\n return (\n <div\n data-slot=\"sheet-header\"\n className={cn(\"flex flex-col gap-element-sm p-card\", className)}\n {...props}\n />\n )\n}\n\nfunction SheetFooter({ className, ...props }: SheetFooterProps): React.JSX.Element {\n return (\n <Surface.Footer\n data-component-slot=\"sheet-footer\"\n className={cn(\"mt-auto gap-element p-card\", className)}\n {...props}\n />\n )\n}\n\nconst SheetTitle = React.forwardRef<HTMLHeadingElement, SheetTitleProps>(\n ({ className, ...props }, ref) => {\n const { getRecipe } = useUI()\n const recipe = getRecipe(UIBehavior.TYPOGRAPHY, TypographyVariant.HEADING)\n\n return (\n <SheetPrimitive.Title\n ref={ref}\n data-slot=\"sheet-title\"\n className={cn(recipe.base, recipe.sizes?.h4, className)}\n {...props}\n />\n )\n }\n)\nSheetTitle.displayName = 'SheetTitle'\n\nconst SheetDescription = React.forwardRef<HTMLParagraphElement, SheetDescriptionProps>(\n ({ className, ...props }, ref) => {\n const { getRecipe } = useUI()\n const recipe = getRecipe(UIBehavior.TYPOGRAPHY, TypographyVariant.DESCRIPTION)\n\n return (\n <SheetPrimitive.Description\n ref={ref}\n data-slot=\"sheet-description\"\n className={cn(recipe.base, className)}\n {...props}\n />\n )\n }\n)\nSheetDescription.displayName = 'SheetDescription'\n\nconst Sheet = createCompoundPreset<SheetCompound>(SheetRoot, {\n Trigger: SheetTrigger,\n Content: SheetContent,\n Close: SheetClose,\n Header: SheetHeader,\n Footer: SheetFooter,\n Title: SheetTitle,\n Description: SheetDescription,\n})\n\nexport { Sheet }\n"]}
|
|
1
|
+
{"version":3,"file":"sheet.js","sourceRoot":"","sources":["../../../../../../src/components/overlays/containers/sheet.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,cAAc,MAAM,wBAAwB,CAAA;AACxD,OAAO,EAAE,qBAAqB,EAAE,kBAAkB,EAAiC,cAAc,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAA;AAE7K,OAAO,EACL,EAAE,EACF,eAAe,EACf,qBAAqB,EACrB,QAAQ,EACR,OAAO,EACP,KAAK,EACL,4BAA4B,EAC5B,6BAA6B,EAC7B,oBAAoB,EACpB,OAAO,GASR,MAAM,6BAA6B,CAAC;AASrC,SAAS,SAAS,CAAC,EAAE,GAAG,KAAK,EAAc;IACzC,OAAO,KAAC,cAA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,OAAO,CACL,KAAC,cAAc,CAAC,KAAK,IACnB,GAAG,EAAE,GAAG,eACE,aAAa,EACvB,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,CAAC,KAAK,EAAE,EAAE,EAAE,SAAS,CAAC,KACnD,KAAK,GACT,CACH,CAAA;AACH,CAAC,CACF,CAAA;AACD,UAAU,CAAC,WAAW,GAAG,YAAY,CAAA;AAErC,MAAM,gBAAgB,GAAG,KAAK,CAAC,UAAU,CACvC,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,GAAG,EAAE,EAAE;IAC/B,MAAM,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,CAAA;IAC7B,MAAM,MAAM,GAAG,SAAS,CAAC,UAAU,CAAC,UAAU,EAAE,iBAAiB,CAAC,WAAW,CAAC,CAAA;IAE9E,OAAO,CACL,KAAC,cAAc,CAAC,WAAW,IACzB,GAAG,EAAE,GAAG,eACE,mBAAmB,EAC7B,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,SAAS,CAAC,KACjC,KAAK,GACT,CACH,CAAA;AACH,CAAC,CACF,CAAA;AACD,gBAAgB,CAAC,WAAW,GAAG,kBAAkB,CAAA;AAEjD,MAAM,KAAK,GAAG,oBAAoB,CAAgB,SAAS,EAAE;IAC3D,OAAO,EAAE,YAAY;IACrB,OAAO,EAAE,YAAY;IACrB,KAAK,EAAE,UAAU;IACjB,MAAM,EAAE,WAAW;IACnB,MAAM,EAAE,WAAW;IACnB,KAAK,EAAE,UAAU;IACjB,WAAW,EAAE,gBAAgB;CAC9B,CAAC,CAAA;AAEF,OAAO,EAAE,KAAK,EAAE,CAAA","sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport * as SheetPrimitive from \"@radix-ui/react-dialog\"\nimport { FrontendComponentType, InteractiveVariant, type DeepPartialSurfacePolicy, SurfaceVariant, TypographyVariant, UIBehavior } from \"@wildo-ai/presets-components-models\"\n\nimport {\n cn,\n useIconRegistry,\n StandardIconReference,\n IconSize,\n useI18n,\n useUI,\n useSurfacePolicyPortalTarget,\n useSurfacePolicyStackingClass,\n createCompoundPreset,\n Surface,\n SheetProps,\n SheetTriggerProps,\n SheetCloseProps,\n SheetHeaderProps,\n SheetFooterProps,\n SheetTitleProps,\n SheetDescriptionProps,\n SheetCompound,\n} from '@wildo-ai/saas-frontend-lib';\n\ntype SheetContentImplProps = React.ComponentPropsWithoutRef<typeof SheetPrimitive.Content> & {\n /** Render the backdrop scrim. Default true — see `DialogFamilyContentBaseProps.showBackdrop`. */\n showBackdrop?: boolean\n side?: 'top' | 'right' | 'bottom' | 'left'\n surfacePolicyOverride?: DeepPartialSurfacePolicy\n}\n\nfunction SheetRoot({ ...props }: SheetProps): React.JSX.Element {\n return <SheetPrimitive.Root data-slot=\"sheet\" {...props} />\n}\n\nconst SheetTrigger = React.forwardRef<HTMLButtonElement, SheetTriggerProps>(\n (props, ref) => <SheetPrimitive.Trigger ref={ref} data-slot=\"sheet-trigger\" {...props} />\n)\nSheetTrigger.displayName = 'SheetTrigger'\n\nfunction SheetClose({ ...props }: SheetCloseProps): React.JSX.Element {\n return <SheetPrimitive.Close data-slot=\"sheet-close\" {...props} />\n}\n\nconst SheetContent = React.forwardRef<HTMLDivElement, SheetContentImplProps>(\n ({ className, children, side = \"right\", surfacePolicyOverride, showBackdrop = true, ...props }, ref) => {\n const { renderIcon } = useIconRegistry()\n const { tComponent, isReady } = useI18n({\n component: FrontendComponentType.LOW_LEVEL_SHEET,\n })\n const { getRecipe } = useUI()\n const closeLabel = tComponent(FrontendComponentType.LOW_LEVEL_SHEET, 'close')\n const surfaceRecipe = getRecipe(UIBehavior.SURFACE, SurfaceVariant.OVERLAY)\n const closeRecipe = getRecipe(UIBehavior.INTERACTIVE, InteractiveVariant.GHOST)\n const overlayRecipe = getRecipe(UIBehavior.OVERLAY_BACKDROP)\n const { container, shouldPortal } = useSurfacePolicyPortalTarget(SurfaceVariant.OVERLAY, surfacePolicyOverride)\n const stackingClass = useSurfacePolicyStackingClass(SurfaceVariant.OVERLAY, surfacePolicyOverride)\n\n const content = (\n <>\n {/*\n * The scrim is OPTIONAL. Radix does not require an Overlay, and an overlay that must not\n * darken what it sits over has no use for one — a detail sheet beside a live canvas, where a\n * dimmed page reads as \"disabled\" and the reader is still meant to be working in it.\n *\n * Separate from `modal`: that decides whether the page behind can be INTERACTED with. The two\n * are independent and both are needed — a non-modal sheet over a scrim still looks disabled,\n * and a modal one without a scrim still is.\n */}\n {showBackdrop && (\n <SheetPrimitive.Overlay\n data-slot=\"sheet-overlay\"\n className={cn(\n \"fixed inset-0\",\n stackingClass,\n overlayRecipe.base,\n overlayRecipe.motion.enter,\n overlayRecipe.motion.exit,\n )}\n />\n )}\n <Surface\n asChild\n variant={SurfaceVariant.OVERLAY}\n modal\n a11yManagedByHost\n policyOverride={{\n ...surfacePolicyOverride,\n containment: {\n ...surfacePolicyOverride?.containment,\n paddingBlock: 'none',\n paddingInline: 'none',\n maxHeight: 'none',\n overflow: 'visible',\n },\n geometry: {\n ...surfacePolicyOverride?.geometry,\n actionAlignment: 'stack',\n },\n }}\n >\n <SheetPrimitive.Content\n ref={ref}\n data-slot=\"sheet-content\"\n className={cn(\n \"fixed flex flex-col gap-field\",\n surfaceRecipe.base,\n \"data-[state=open]:animate-in data-[state=closed]:animate-out transition ease-[var(--motion-easing-default)] data-[state=closed]:duration-[var(--motion-duration-normal)] data-[state=open]:duration-[var(--motion-duration-slow)] motion-reduce:data-[state=open]:animate-none motion-reduce:data-[state=closed]:animate-none\",\n side === \"right\" &&\n \"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 end-0 h-full w-3/4 border-s sm:max-w-sm\",\n side === \"left\" &&\n \"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 start-0 h-full w-3/4 border-e sm:max-w-sm\",\n side === \"top\" &&\n \"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b\",\n side === \"bottom\" &&\n \"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t\",\n className\n )}\n {...props}\n >\n {children}\n <SheetPrimitive.Close className={cn(\n \"absolute top-4 end-4 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n closeRecipe.base,\n \"opacity-[0.7]\",\n closeRecipe.states.hover,\n closeRecipe.states.focus,\n closeRecipe.states.disabled,\n closeRecipe.states.open,\n closeRecipe.motion.transition,\n )}>\n {renderIcon(StandardIconReference.CLOSE, { size: IconSize.SM })}\n <span className=\"sr-only\">{closeLabel}</span>\n </SheetPrimitive.Close>\n </SheetPrimitive.Content>\n </Surface>\n </>\n )\n\n if (!shouldPortal) {\n return content\n }\n\n return (\n <SheetPrimitive.Portal container={container}>\n {content}\n </SheetPrimitive.Portal>\n )\n }\n)\nSheetContent.displayName = 'SheetContent'\n\nfunction SheetHeader({ className, ...props }: SheetHeaderProps): React.JSX.Element {\n return (\n <div\n data-slot=\"sheet-header\"\n className={cn(\"flex flex-col gap-element-sm p-card\", className)}\n {...props}\n />\n )\n}\n\nfunction SheetFooter({ className, ...props }: SheetFooterProps): React.JSX.Element {\n return (\n <Surface.Footer\n data-component-slot=\"sheet-footer\"\n className={cn(\"mt-auto gap-element p-card\", className)}\n {...props}\n />\n )\n}\n\nconst SheetTitle = React.forwardRef<HTMLHeadingElement, SheetTitleProps>(\n ({ className, ...props }, ref) => {\n const { getRecipe } = useUI()\n const recipe = getRecipe(UIBehavior.TYPOGRAPHY, TypographyVariant.HEADING)\n\n return (\n <SheetPrimitive.Title\n ref={ref}\n data-slot=\"sheet-title\"\n className={cn(recipe.base, recipe.sizes?.h4, className)}\n {...props}\n />\n )\n }\n)\nSheetTitle.displayName = 'SheetTitle'\n\nconst SheetDescription = React.forwardRef<HTMLParagraphElement, SheetDescriptionProps>(\n ({ className, ...props }, ref) => {\n const { getRecipe } = useUI()\n const recipe = getRecipe(UIBehavior.TYPOGRAPHY, TypographyVariant.DESCRIPTION)\n\n return (\n <SheetPrimitive.Description\n ref={ref}\n data-slot=\"sheet-description\"\n className={cn(recipe.base, className)}\n {...props}\n />\n )\n }\n)\nSheetDescription.displayName = 'SheetDescription'\n\nconst Sheet = createCompoundPreset<SheetCompound>(SheetRoot, {\n Trigger: SheetTrigger,\n Content: SheetContent,\n Close: SheetClose,\n Header: SheetHeader,\n Footer: SheetFooter,\n Title: SheetTitle,\n Description: SheetDescription,\n})\n\nexport { Sheet }\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accordion.d.ts","sourceRoot":"","sources":["../../../../../src/components/sections/accordion.tsx"],"names":[],"mappings":"AAGA,OAAO,EACL,iBAAiB,EAQlB,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"accordion.d.ts","sourceRoot":"","sources":["../../../../../src/components/sections/accordion.tsx"],"names":[],"mappings":"AAGA,OAAO,EACL,iBAAiB,EAQlB,MAAM,6BAA6B,CAAC;AAoIrC,eAAO,MAAM,SAAS,mBAAwI,CAAA"}
|
|
@@ -1,27 +1,57 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import * as React from "react";
|
|
2
3
|
import * as AccordionPrimitive from "@radix-ui/react-accordion";
|
|
3
4
|
import { createCompoundPreset, cn, useIconRegistry, StandardIconReference, IconSize, useUI, Surface, } from '@wildo-ai/saas-frontend-lib';
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
import { DividerVariant, SelectableVariant, SurfaceVariant, UIBehavior } from "@wildo-ai/presets-components-models";
|
|
6
|
+
import { DisclosureNestingContext } from "./disclosure-nesting.js";
|
|
7
|
+
function AccordionRoot({ className, ...props }) {
|
|
8
|
+
const isNested = React.useContext(DisclosureNestingContext);
|
|
9
|
+
const { getRecipe } = useUI();
|
|
10
|
+
/*
|
|
11
|
+
* NESTED accordions announce their depth, from the PRESET, so every application's
|
|
12
|
+
* collapsible-in-collapsible reads as hierarchy without each call site re-inventing it.
|
|
13
|
+
*
|
|
14
|
+
* The guide's LOOK comes from the theme (`DIVIDER` / `NESTING_GUIDE` — edge, color, weight); the
|
|
15
|
+
* INDENT is structure and stays here. Top-level accordions are untouched.
|
|
16
|
+
*/
|
|
17
|
+
const nestingGuideClasses = isNested
|
|
18
|
+
? cn(getRecipe(UIBehavior.DIVIDER, DividerVariant.NESTING_GUIDE).base, "ps-field")
|
|
19
|
+
: undefined;
|
|
20
|
+
return (_jsx(AccordionPrimitive.Root, { "data-slot": "accordion", className: cn(nestingGuideClasses, className), ...props }));
|
|
7
21
|
}
|
|
8
22
|
function AccordionItem({ className, ...props }) {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
23
|
+
return (_jsx(AccordionPrimitive.Item, { "data-slot": "accordion-item",
|
|
24
|
+
/*
|
|
25
|
+
* A plain `border-b` — deliberately NOT the DIVIDER recipe, whose base is a background FILL
|
|
26
|
+
* for elements that ARE the line. An earlier author consulted the recipe here and then
|
|
27
|
+
* applied `dividerRecipe.base ? "" : ""` — always the empty string — which dodged the fill
|
|
28
|
+
* without saying so; description-list made the same pairing without the dodge and painted
|
|
29
|
+
* every cell gray. The hairline color comes from the design system's base border-color rule.
|
|
30
|
+
*/
|
|
31
|
+
className: cn("border-b last:border-b-0", className), ...props }));
|
|
12
32
|
}
|
|
13
33
|
function AccordionTrigger({ className, children, ...props }) {
|
|
14
34
|
const { renderIcon } = useIconRegistry();
|
|
15
35
|
const { getRecipe } = useUI();
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
36
|
+
/*
|
|
37
|
+
* SELECTABLE / FILLED, not INTERACTIVE / GHOST — the register is the point, and the taxonomy
|
|
38
|
+
* already says so: `UIBehavior.SELECTABLE`'s own doc lists "Accordion trigger" as a member.
|
|
39
|
+
*
|
|
40
|
+
* This trigger has now wandered through three affordances, each wrong at a different altitude:
|
|
41
|
+
* a hardcoded `hover:underline` (a text-link affordance the cited recipe never declared), then
|
|
42
|
+
* GHOST's own hover — which is a MENU-ITEM affordance (`hover:bg-accent`), and on a full-width
|
|
43
|
+
* section header painted the entire bar in the theme's accent on every mouse-over. FILLED's
|
|
44
|
+
* hover is the sidebar-row treatment (`bg-surface-sunken-accent`): the theme's own answer for
|
|
45
|
+
* "a wide row you can activate", which is what this is.
|
|
46
|
+
*/
|
|
47
|
+
const recipe = getRecipe(UIBehavior.SELECTABLE, SelectableVariant.FILLED);
|
|
48
|
+
return (_jsx(AccordionPrimitive.Header, { className: "flex", children: _jsxs(AccordionPrimitive.Trigger, { "data-slot": "accordion-trigger", className: cn(recipe.base,
|
|
49
|
+
// Structure. `cursor-pointer` is here rather than in the recipe: an element that opens
|
|
50
|
+
// something wants a pointer in every theme — that is interaction structure, not a look.
|
|
51
|
+
"flex flex-1 cursor-pointer items-start justify-between gap-field rounded-md py-card text-start text-sm font-medium outline-none [&[data-state=open]>svg]:rotate-180", recipe.states.hover, recipe.states.focus, recipe.states.disabled, recipe.motion.transition, className), ...props, children: [children, renderIcon(StandardIconReference.CHEVRON_DOWN, { size: IconSize.SM, className: "text-muted-foreground pointer-events-none shrink-0 translate-y-0.5 transition-transform duration-[var(--motion-duration-fast)]" })] }) }));
|
|
22
52
|
}
|
|
23
53
|
function AccordionContent({ className, children, ...props }) {
|
|
24
|
-
return (_jsx(AccordionPrimitive.Content, { "data-slot": "accordion-content", className: "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm", ...props, children: _jsx(Surface, { asChild: true, emitPolicyVars: false, variant: SurfaceVariant.
|
|
54
|
+
return (_jsx(AccordionPrimitive.Content, { "data-slot": "accordion-content", className: "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm", ...props, children: _jsx(Surface, { asChild: true, emitPolicyVars: false, variant: SurfaceVariant.TAB_PANEL, children: _jsx("div", { className: cn("pt-0 pb-card", className), children: _jsx(DisclosureNestingContext.Provider, { value: true, children: children }) }) }) }));
|
|
25
55
|
}
|
|
26
56
|
export const Accordion = createCompoundPreset(AccordionRoot, { Item: AccordionItem, Trigger: AccordionTrigger, Content: AccordionContent });
|
|
27
57
|
//# sourceMappingURL=accordion.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accordion.js","sourceRoot":"","sources":["../../../../../src/components/sections/accordion.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"accordion.js","sourceRoot":"","sources":["../../../../../src/components/sections/accordion.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAA;AAE/D,OAAO,EAEL,oBAAoB,EACpB,EAAE,EACF,eAAe,EACf,qBAAqB,EACrB,QAAQ,EACR,KAAK,EACL,OAAO,GACR,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,cAAc,EAAyB,iBAAiB,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAA;AAC1I,OAAO,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAA;AAE/D,SAAS,aAAa,CAAC,EACrB,SAAS,EACT,GAAG,KAAK,EAC6C;IACrD,MAAM,QAAQ,GAAG,KAAK,CAAC,UAAU,CAAC,wBAAwB,CAAC,CAAA;IAC3D,MAAM,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,CAAA;IAE7B;;;;;;OAMG;IACH,MAAM,mBAAmB,GAAG,QAAQ;QAClC,CAAC,CAAC,EAAE,CAAC,SAAS,CAAC,UAAU,CAAC,OAAO,EAAE,cAAc,CAAC,aAAa,CAAC,CAAC,IAAI,EAAE,UAAU,CAAC;QAClF,CAAC,CAAC,SAAS,CAAA;IAEb,OAAO,CACL,KAAC,kBAAkB,CAAC,IAAI,iBACZ,WAAW,EACrB,SAAS,E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OAAO,CACL,KAAC,kBAAkB,CAAC,OAAO,iBACf,mBAAmB,EAC7B,SAAS,EAAC,2GAA2G,KACjH,KAAK,YAkBT,KAAC,OAAO,IAAC,OAAO,QAAC,cAAc,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,SAAS,YACvE,cAAK,SAAS,EAAE,EAAE,CAAC,cAAc,EAAE,SAAS,CAAC,YAC3C,KAAC,wBAAwB,CAAC,QAAQ,IAAC,KAAK,EAAE,IAAI,YAAG,QAAQ,GAAqC,GAC1F,GACE,GACiB,CAC9B,CAAA;AACH,CAAC;AAED,MAAM,CAAC,MAAM,SAAS,GAAG,oBAAoB,CAAoB,aAAa,EAAE,EAAE,IAAI,EAAE,aAAa,EAAE,OAAO,EAAE,gBAAgB,EAAE,OAAO,EAAE,gBAAgB,EAAE,CAAC,CAAA","sourcesContent":["import * as React from \"react\"\nimport * as AccordionPrimitive from \"@radix-ui/react-accordion\"\n\nimport {\n AccordionCompound,\n createCompoundPreset,\n cn,\n useIconRegistry,\n StandardIconReference,\n IconSize,\n useUI,\n Surface,\n} from '@wildo-ai/saas-frontend-lib';\n\nimport { DividerVariant, FrontendComponentType, SelectableVariant, SurfaceVariant, UIBehavior } from \"@wildo-ai/presets-components-models\"\nimport { DisclosureNestingContext } from \"./disclosure-nesting\"\n\nfunction AccordionRoot({\n className,\n ...props\n}: React.ComponentProps<typeof AccordionPrimitive.Root>): React.JSX.Element {\n const isNested = React.useContext(DisclosureNestingContext)\n const { getRecipe } = useUI()\n\n /*\n * NESTED accordions announce their depth, from the PRESET, so every application's\n * collapsible-in-collapsible reads as hierarchy without each call site re-inventing it.\n *\n * The guide's LOOK comes from the theme (`DIVIDER` / `NESTING_GUIDE` — edge, color, weight); the\n * INDENT is structure and stays here. Top-level accordions are untouched.\n */\n const nestingGuideClasses = isNested\n ? cn(getRecipe(UIBehavior.DIVIDER, DividerVariant.NESTING_GUIDE).base, \"ps-field\")\n : undefined\n\n return (\n <AccordionPrimitive.Root\n data-slot=\"accordion\"\n className={cn(nestingGuideClasses, className)}\n {...props}\n />\n )\n}\n\nfunction AccordionItem({\n className,\n ...props\n}: React.ComponentProps<typeof AccordionPrimitive.Item>): React.JSX.Element {\n return (\n <AccordionPrimitive.Item\n data-slot=\"accordion-item\"\n /*\n * A plain `border-b` — deliberately NOT the DIVIDER recipe, whose base is a background FILL\n * for elements that ARE the line. An earlier author consulted the recipe here and then\n * applied `dividerRecipe.base ? \"\" : \"\"` — always the empty string — which dodged the fill\n * without saying so; description-list made the same pairing without the dodge and painted\n * every cell gray. The hairline color comes from the design system's base border-color rule.\n */\n className={cn(\"border-b last:border-b-0\", className)}\n {...props}\n />\n )\n}\n\nfunction AccordionTrigger({\n className,\n children,\n ...props\n}: React.ComponentProps<typeof AccordionPrimitive.Trigger>): React.JSX.Element {\n const { renderIcon } = useIconRegistry()\n const { getRecipe } = useUI()\n /*\n * SELECTABLE / FILLED, not INTERACTIVE / GHOST — the register is the point, and the taxonomy\n * already says so: `UIBehavior.SELECTABLE`'s own doc lists \"Accordion trigger\" as a member.\n *\n * This trigger has now wandered through three affordances, each wrong at a different altitude:\n * a hardcoded `hover:underline` (a text-link affordance the cited recipe never declared), then\n * GHOST's own hover — which is a MENU-ITEM affordance (`hover:bg-accent`), and on a full-width\n * section header painted the entire bar in the theme's accent on every mouse-over. FILLED's\n * hover is the sidebar-row treatment (`bg-surface-sunken-accent`): the theme's own answer for\n * \"a wide row you can activate\", which is what this is.\n */\n const recipe = getRecipe(UIBehavior.SELECTABLE, SelectableVariant.FILLED)\n\n return (\n <AccordionPrimitive.Header className=\"flex\">\n <AccordionPrimitive.Trigger\n data-slot=\"accordion-trigger\"\n className={cn(\n recipe.base,\n // Structure. `cursor-pointer` is here rather than in the recipe: an element that opens\n // something wants a pointer in every theme — that is interaction structure, not a look.\n \"flex flex-1 cursor-pointer items-start justify-between gap-field rounded-md py-card text-start text-sm font-medium outline-none [&[data-state=open]>svg]:rotate-180\",\n recipe.states.hover,\n recipe.states.focus,\n recipe.states.disabled,\n recipe.motion.transition,\n className\n )}\n {...props}\n >\n {children}\n {renderIcon(StandardIconReference.CHEVRON_DOWN, { size: IconSize.SM, className: \"text-muted-foreground pointer-events-none shrink-0 translate-y-0.5 transition-transform duration-[var(--motion-duration-fast)]\" })}\n </AccordionPrimitive.Trigger>\n </AccordionPrimitive.Header>\n )\n}\n\nfunction AccordionContent({\n className,\n children,\n ...props\n}: React.ComponentProps<typeof AccordionPrimitive.Content>): React.JSX.Element {\n return (\n <AccordionPrimitive.Content\n data-slot=\"accordion-content\"\n className=\"data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm\"\n {...props}\n >\n {/*\n * TAB_PANEL, not BASE — and the difference is the frame.\n *\n * BASE paints the themed card chrome (`rounded-xl border shadow-sm` + raised fill), which put a\n * CARD around every accordion's open content, everywhere: inside a sheet, inside a CARD\n * section, inside another accordion — the exact \"always-on Surface BASE chrome that could not\n * de-dup its frame when nested\" that ContentSectionContainer's migration notes retired for\n * sections. A disclosure panel's frame belongs to the ITEM (which callers style); the content\n * joins seamlessly to the trigger above it.\n *\n * TAB_PANEL is that role, not a lookalike: its policy says \"joins seamlessly to the strip\n * above; never renders its own frame\" (`framingMode: 'never'`, truthfully published to\n * descendants), and its recipe carries the raised text/fill with no border and no shadow. A\n * tab panel and an accordion panel are the same container role — the content region of an\n * activating control — so this is the taxonomy's own answer, not a convenience borrow.\n */}\n <Surface asChild emitPolicyVars={false} variant={SurfaceVariant.TAB_PANEL}>\n <div className={cn(\"pt-0 pb-card\", className)}>\n <DisclosureNestingContext.Provider value={true}>{children}</DisclosureNestingContext.Provider>\n </div>\n </Surface>\n </AccordionPrimitive.Content>\n )\n}\n\nexport const Accordion = createCompoundPreset<AccordionCompound>(AccordionRoot, { Item: AccordionItem, Trigger: AccordionTrigger, Content: AccordionContent })\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapsible.d.ts","sourceRoot":"","sources":["../../../../../src/components/sections/collapsible.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAA;
|
|
1
|
+
{"version":3,"file":"collapsible.d.ts","sourceRoot":"","sources":["../../../../../src/components/sections/collapsible.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAA;AAoEtE,eAAO,MAAM,WAAW,qBAA2H,CAAA"}
|
|
@@ -1,14 +1,28 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
|
|
3
|
-
import { createCompoundPreset } from "@wildo-ai/saas-frontend-lib";
|
|
3
|
+
import { createCompoundPreset, cn } from "@wildo-ai/saas-frontend-lib";
|
|
4
|
+
import { DisclosureNestingContext } from "./disclosure-nesting.js";
|
|
4
5
|
function CollapsibleRoot({ ...props }) {
|
|
5
6
|
return _jsx(CollapsiblePrimitive.Root, { "data-slot": "collapsible", ...props });
|
|
6
7
|
}
|
|
7
8
|
function CollapsibleTrigger({ ...props }) {
|
|
8
9
|
return (_jsx(CollapsiblePrimitive.CollapsibleTrigger, { "data-slot": "collapsible-trigger", ...props }));
|
|
9
10
|
}
|
|
10
|
-
function CollapsibleContent({ ...props }) {
|
|
11
|
-
return (
|
|
11
|
+
function CollapsibleContent({ className, ...props }) {
|
|
12
|
+
return (
|
|
13
|
+
/*
|
|
14
|
+
* A collapsible panel is a disclosure panel: anything nesting-aware below it (today, an
|
|
15
|
+
* Accordion) reads this fact and applies the themed nesting guide. Providing the fact is not
|
|
16
|
+
* styling — this component stays headless.
|
|
17
|
+
*
|
|
18
|
+
* The provider wraps OUTSIDE the primitive, deliberately. Wrapping `children` INSIDE it shipped
|
|
19
|
+
* a crash: with `asChild` (AI_PlanContent does exactly this) Radix's Slot merges its props and
|
|
20
|
+
* measuring ref onto the single child element — which had become the Provider, not a DOM
|
|
21
|
+
* element — so the ref resolved to nothing and `ResizeObserver.observe()` threw "parameter 1 is
|
|
22
|
+
* not of type 'Element'". Context reaches descendants identically from out here, and the
|
|
23
|
+
* children slot stays exactly what the caller authored.
|
|
24
|
+
*/
|
|
25
|
+
_jsx(DisclosureNestingContext.Provider, { value: true, children: _jsx(CollapsiblePrimitive.CollapsibleContent, { "data-slot": "collapsible-content", className: cn('overflow-hidden data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down', className), ...props }) }));
|
|
12
26
|
}
|
|
13
27
|
export const Collapsible = createCompoundPreset(CollapsibleRoot, { Trigger: CollapsibleTrigger, Content: CollapsibleContent });
|
|
14
28
|
//# sourceMappingURL=collapsible.js.map
|