@ai-matrx/design-system 0.86.337 → 0.86.339
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/CHANGELOG.md +37 -2
- package/dist/carousel.js +6 -6
- package/dist/{chunk-GHPUO3O7.js → chunk-5IR3BZOS.js} +2 -2
- package/dist/{chunk-DQUCOMAC.js → chunk-6QKT52FR.js} +2 -2
- package/dist/{chunk-B24DLFWR.js → chunk-B4WMMAAJ.js} +2 -2
- package/dist/{chunk-M34WPTPX.js → chunk-CEA6X445.js} +2 -2
- package/dist/{chunk-PBDQZPKV.js → chunk-CJBSBKG5.js} +2 -2
- package/dist/{chunk-Q2HWDJED.js → chunk-GLLPO66A.js} +2 -2
- package/dist/{chunk-WZC3K7SO.js → chunk-LGC6EVFE.js} +4 -4
- package/dist/chunk-LGC6EVFE.js.map +1 -0
- package/dist/{chunk-BYOFPPPI.js → chunk-M45FEAVG.js} +4 -4
- package/dist/{chunk-RGJPHRU3.js → chunk-T4IJELSS.js} +4 -4
- package/dist/{chunk-L5OACQXS.js → chunk-TO4ZLGDW.js} +5 -2
- package/dist/chunk-TO4ZLGDW.js.map +1 -0
- package/dist/{chunk-VQ3G6AFN.js → chunk-TWRC7NP4.js} +4 -4
- package/dist/{chunk-BM2YYBUO.js → chunk-UM45E3LO.js} +2 -2
- package/dist/{chunk-SMJGESH7.js → chunk-WFITMVDB.js} +5 -2
- package/dist/{chunk-SMJGESH7.js.map → chunk-WFITMVDB.js.map} +1 -1
- package/dist/{chunk-QOEKPR37.js → chunk-XTP6HOB6.js} +2 -2
- package/dist/clipboard-fallback-dialog.cjs +4 -1
- package/dist/clipboard-fallback-dialog.cjs.map +1 -1
- package/dist/clipboard-fallback-dialog.js +3 -3
- package/dist/content-transfer.css +16 -6
- package/dist/controls.cjs +4 -1
- package/dist/controls.cjs.map +1 -1
- package/dist/controls.js +6 -6
- package/dist/data-table/data-row-inspector.js +5 -5
- package/dist/data-table/data-row-window.js +6 -6
- package/dist/data-table/index.cjs +4 -1
- package/dist/data-table/index.cjs.map +1 -1
- package/dist/data-table/index.js +9 -9
- package/dist/data-table/layered-filter-builder.cjs +4 -1
- package/dist/data-table/layered-filter-builder.cjs.map +1 -1
- package/dist/data-table/layered-filter-builder.js +2 -2
- package/dist/data-table/pagination.cjs +4 -1
- package/dist/data-table/pagination.cjs.map +1 -1
- package/dist/data-table/pagination.js +3 -3
- package/dist/data-table/uuid-cell.js +3 -3
- package/dist/desktop.cjs +4 -1
- package/dist/desktop.cjs.map +1 -1
- package/dist/desktop.js +5 -5
- package/dist/email-input-dialog.cjs +4 -1
- package/dist/email-input-dialog.cjs.map +1 -1
- package/dist/email-input-dialog.js +2 -2
- package/dist/index.cjs +10 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -3
- package/dist/index.d.ts +4 -3
- package/dist/index.js +11 -11
- package/dist/index.js.map +1 -1
- package/dist/item.cjs +5 -2
- package/dist/item.cjs.map +1 -1
- package/dist/item.d.cts +5 -3
- package/dist/item.d.ts +5 -3
- package/dist/item.js +4 -4
- package/dist/lite-table.js +2 -2
- package/dist/menu-look.cjs +4 -1
- package/dist/menu-look.cjs.map +1 -1
- package/dist/menu-look.css +8 -0
- package/dist/menu-look.d.cts +4 -1
- package/dist/menu-look.d.ts +4 -1
- package/dist/menu-look.js +1 -1
- package/dist/record-list.cjs +5 -2
- package/dist/record-list.cjs.map +1 -1
- package/dist/record-list.d.cts +5 -3
- package/dist/record-list.d.ts +5 -3
- package/dist/record-list.js +4 -4
- package/dist/settings.cjs +4 -1
- package/dist/settings.cjs.map +1 -1
- package/dist/settings.js +3 -3
- package/dist/text-input-dialog.cjs +4 -1
- package/dist/text-input-dialog.cjs.map +1 -1
- package/dist/text-input-dialog.js +2 -2
- package/dist/writing-field.js +3 -3
- package/package.json +2 -2
- package/dist/chunk-L5OACQXS.js.map +0 -1
- package/dist/chunk-WZC3K7SO.js.map +0 -1
- /package/dist/{chunk-GHPUO3O7.js.map → chunk-5IR3BZOS.js.map} +0 -0
- /package/dist/{chunk-DQUCOMAC.js.map → chunk-6QKT52FR.js.map} +0 -0
- /package/dist/{chunk-B24DLFWR.js.map → chunk-B4WMMAAJ.js.map} +0 -0
- /package/dist/{chunk-M34WPTPX.js.map → chunk-CEA6X445.js.map} +0 -0
- /package/dist/{chunk-PBDQZPKV.js.map → chunk-CJBSBKG5.js.map} +0 -0
- /package/dist/{chunk-Q2HWDJED.js.map → chunk-GLLPO66A.js.map} +0 -0
- /package/dist/{chunk-BYOFPPPI.js.map → chunk-M45FEAVG.js.map} +0 -0
- /package/dist/{chunk-RGJPHRU3.js.map → chunk-T4IJELSS.js.map} +0 -0
- /package/dist/{chunk-VQ3G6AFN.js.map → chunk-TWRC7NP4.js.map} +0 -0
- /package/dist/{chunk-BM2YYBUO.js.map → chunk-UM45E3LO.js.map} +0 -0
- /package/dist/{chunk-QOEKPR37.js.map → chunk-XTP6HOB6.js.map} +0 -0
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./chunk-AJ6BAYEN.js";
|
|
5
5
|
import {
|
|
6
6
|
Input
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-5IR3BZOS.js";
|
|
8
8
|
import {
|
|
9
9
|
Drawer,
|
|
10
10
|
DrawerContent,
|
|
@@ -34,7 +34,7 @@ import "./chunk-LEPD6TV7.js";
|
|
|
34
34
|
import "./chunk-BD77DHUO.js";
|
|
35
35
|
import "./chunk-BKCJUFD3.js";
|
|
36
36
|
import "./chunk-MOZRIHJF.js";
|
|
37
|
-
import "./chunk-
|
|
37
|
+
import "./chunk-WFITMVDB.js";
|
|
38
38
|
import "./chunk-WAT2XW7L.js";
|
|
39
39
|
import {
|
|
40
40
|
Button
|
package/dist/writing-field.js
CHANGED
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
AlertDialogHeader,
|
|
21
21
|
AlertDialogTitle,
|
|
22
22
|
Tile
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-B4WMMAAJ.js";
|
|
24
24
|
import "./chunk-DRSBLHOF.js";
|
|
25
25
|
import {
|
|
26
26
|
Dialog,
|
|
@@ -48,14 +48,14 @@ import {
|
|
|
48
48
|
import {
|
|
49
49
|
Field,
|
|
50
50
|
Textarea
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-XTP6HOB6.js";
|
|
52
52
|
import "./chunk-BD77DHUO.js";
|
|
53
53
|
import "./chunk-BKCJUFD3.js";
|
|
54
54
|
import "./chunk-PIQJULQB.js";
|
|
55
55
|
import "./chunk-MOZRIHJF.js";
|
|
56
56
|
import "./chunk-X6ZRHJQP.js";
|
|
57
57
|
import "./chunk-BNXNIN2S.js";
|
|
58
|
-
import "./chunk-
|
|
58
|
+
import "./chunk-WFITMVDB.js";
|
|
59
59
|
import "./chunk-WAT2XW7L.js";
|
|
60
60
|
import "./chunk-7IOSA55D.js";
|
|
61
61
|
import "./chunk-FXXSZNER.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ai-matrx/design-system",
|
|
3
|
-
"version": "0.86.
|
|
3
|
+
"version": "0.86.339",
|
|
4
4
|
"description": "AI Matrx semantic React primitives shared across Vite, Next.js, desktop, and customer-built applications.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -776,5 +776,5 @@
|
|
|
776
776
|
],
|
|
777
777
|
"layer": 2
|
|
778
778
|
},
|
|
779
|
-
"gitHead": "
|
|
779
|
+
"gitHead": "a07e6eb5779a4512b3a7ee14b4a63af5fcec6a2e"
|
|
780
780
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/menu-look.tsx"],"sourcesContent":["\"use client\";\n/**\n * `@ai-matrx/design-system/menu-look` — THE ONE MENU LOOK (Arman, 2026-10-23: the header \"…\", every\n * crumb dropdown and every Alchemy dropdown are \"the IDENTICAL dropdown that I use for Alchemy for size\n * and style\" — the right-click menu).\n *\n * Four families, one look:\n * - `MENU_LOOK_CLASS` / `MenuLookRowBody` / `MenuLookIconSlot`: the class names and the inside of a row,\n * used by @ai-matrx/context-menu's MenuPanel (its own non-Radix renderer, the right-click menu);\n * - THE DROPDOWN — `MenuLookContent` / `MenuLookSubContent` / `MenuLookItem` / `MenuLookSubTrigger` /\n * `MenuLookCheckboxItem` / `MenuLookRadioGroup` / `MenuLookRadioItem` / `MenuLookLabel` /\n * `MenuLookSeparator` / `MenuLookSearch` (+ `MenuLookSub`): the panel and rows on the Radix dropdown\n * (keyboard, typeahead, focus return, collision padding) — Alchemy's dropdowns, the frame's \"…\" and\n * crumb menus, a row's \"…\" (ItemMenu);\n * - THE RIGHT-CLICK — `MenuLookContext*`: the SAME rows on the Radix context menu (a row's right-click,\n * ItemContextMenu without a host menu);\n * - THE PANEL — `MenuLookPanel` / `MenuLookPopoverContent` / `MenuLookPanelItem` /\n * `MenuLookPanelControlRow` / `MenuLookPanelHeader` / `MenuLookPanelDisclosure` /\n * `MenuLookPanelLabel` / `MenuLookPanelSeparator`: the same panel and rows WITHOUT a Radix menu, for a\n * popover or sheet that also holds controls (a theme switch, a Switch, a search list) — the account\n * rail's Settings, Organization and account menus and the frame's admin menu.\n * Every measurement lives once, in `menu-look.css` (shipped inside `styles.css`): 280px panel, 30px rows,\n * 13px text on a 1.25 line, 16px icons, 4px/8px row padding, 10px corners. No part takes a `className`.\n *\n * ONE LEFT EDGE (Arman, 2026-10-23: \"get rid of the HORRIBLE and ugly indentation\"): a row without a\n * glyph draws no icon column, the current row is marked with a check at its END (`current`), and the\n * search is the menu's own header row whose text starts where every row's text starts.\n */\nimport * as React from \"react\";\nimport * as DropdownMenuPrimitive from \"@radix-ui/react-dropdown-menu\";\nimport * as ContextMenuPrimitive from \"@radix-ui/react-context-menu\";\nimport { DropdownMenuContent, DropdownMenuSubContent } from \"./dropdown-menu\";\nimport { ContextMenuContent, ContextMenuSubContent } from \"./context-menu\";\nimport { PopoverContent } from \"./popover\";\nimport { RadixCheckIcon, RadixChevronDownIcon, RadixChevronRightIcon } from \"./icons\";\nimport { useScrollFade } from \"./use-scroll-fade\";\n\n/** The look's measurements (what `menu-look.css` draws), for tests and hosts that size around a menu. */\nexport const MENU_LOOK = {\n width: 280,\n largeWidth: 360,\n rowHeight: 30,\n sheetRowHeight: 44,\n fontSize: 13,\n lineHeight: 1.25,\n icon: 16,\n headerMark: 28,\n rowPaddingY: 4,\n rowPaddingX: 8,\n radius: 10,\n} as const;\n\n/** The look's class names — the ONLY classes a menu part wears. */\nexport const MENU_LOOK_CLASS = {\n panel: \"cm-menu\",\n item: \"cm-item\",\n iconSlot: \"cm-icon-slot\",\n icon: \"cm-icon\",\n text: \"cm-text\",\n label: \"cm-label\",\n hint: \"cm-hint\",\n current: \"cm-current\",\n chevron: \"cm-chevron\",\n search: \"cm-search\",\n trail: \"cm-trail\",\n badge: \"cm-badge\",\n shortcut: \"cm-shortcut\",\n control: \"cm-control\",\n divider: \"cm-divider\",\n sectionLabel: \"cm-section-label\",\n header: \"cm-header\",\n headerMark: \"cm-header-mark\",\n headerText: \"cm-header-text\",\n headerTitle: \"cm-header-title\",\n headerSubtitle: \"cm-header-subtitle\",\n danger: \"cm-danger\",\n dimmed: \"cm-dimmed\",\n} as const;\n\nexport type MenuLookSize = \"standard\" | \"large\";\nexport type MenuLookDensity = \"comfortable\" | \"compact\";\n\n/** The 16px icon column of a row that has a glyph (an empty slot draws nothing: no reserved gutter). */\nexport function MenuLookIconSlot({ children }: { children?: React.ReactNode }): React.ReactElement {\n return <span className={MENU_LOOK_CLASS.iconSlot}>{children}</span>;\n}\n\nexport interface MenuLookRowBodyProps {\n /** The glyph (any 16px svg; the slot sizes it). Omitted → no icon column; the text starts the row. */\n icon?: React.ReactNode | undefined;\n label: React.ReactNode;\n /** Hover text for the label (a long description stays out of the row: no \"novels\" in menus). */\n labelTitle?: string | undefined;\n /** A muted second line under the label. */\n description?: React.ReactNode | undefined;\n /** A muted end-of-row hint (a trail, a shortcut word). */\n trail?: React.ReactNode | undefined;\n /** A small outlined tag at the row's end (\"New\", \"Beta\", a count). */\n badge?: React.ReactNode | undefined;\n /** The row's key, at its end (\"⌘C\", \"R\"). */\n shortcut?: React.ReactNode | undefined;\n /** The row the person is on now: medium weight and a check at the row's end (never a left gutter). */\n current?: boolean | undefined;\n}\n\n/** The inside of a row: icon (when given), label (+ second line), end hint, badge, key, current check. */\nexport function MenuLookRowBody({ icon, label, labelTitle, description, trail, badge, shortcut, current }: MenuLookRowBodyProps): React.ReactElement {\n return (\n <>\n {icon ? <MenuLookIconSlot>{icon}</MenuLookIconSlot> : null}\n <span className={MENU_LOOK_CLASS.text}>\n <span className={MENU_LOOK_CLASS.label} title={labelTitle}>{label}</span>\n {description ? <span className={MENU_LOOK_CLASS.hint}>{description}</span> : null}\n </span>\n {trail ? <span className={MENU_LOOK_CLASS.trail}>{trail}</span> : null}\n {badge ? <span className={MENU_LOOK_CLASS.badge}>{badge}</span> : null}\n {shortcut ? <kbd className={MENU_LOOK_CLASS.shortcut}>{shortcut}</kbd> : null}\n {current ? <RadixCheckIcon className={MENU_LOOK_CLASS.current} aria-hidden=\"true\" data-menu-current-mark=\"\" /> : null}\n </>\n );\n}\n\n/** A row's classes: the look's row, plus its danger / dimmed marks. */\nexport function menuLookItemClass({ destructive, dimmed }: { destructive?: boolean | undefined; dimmed?: boolean | undefined } = {}): string {\n return `${MENU_LOOK_CLASS.item}${destructive ? ` ${MENU_LOOK_CLASS.danger}` : \"\"}${dimmed ? ` ${MENU_LOOK_CLASS.dimmed}` : \"\"}`;\n}\n\ntype DataAttributes = { [dataAttribute: `data-${string}`]: string | undefined };\n\ninterface PanelLookProps {\n /** \"standard\" (280px, the right-click menu) or \"large\" (360px, 36px rows). */\n size?: MenuLookSize | undefined;\n density?: MenuLookDensity | undefined;\n}\n\n/**\n * A submenu panel's fit: `\"menu\"` (the look's width and padding) or `\"content\"` — the panel holds a\n * host's own surface (the Alchemy palette): its width, no padding, and the popover height the surface\n * reads mapped to the room this menu measured.\n */\nexport type MenuLookSubFit = \"menu\" | \"content\";\n\n// ── THE DROPDOWN and THE RIGHT-CLICK: one set of rows over either Radix menu ──────────────────────\n\ntype ContentProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuContent>, \"className\" | \"surface\">;\n\nexport interface MenuLookContentProps extends ContentProps, PanelLookProps, DataAttributes {\n /**\n * A LONG MENU SAYS SO, IN WORDS (FIX-Q13, production `/agents/all` at 1024x768: a record's \"…\" hid\n * its Delete below the fold and read as dead). Given, the panel is a frame that does not scroll, the\n * rows scroll inside it, and a bar with these words (\"More actions below\") sits at its bottom edge\n * whenever there is more below — a press scrolls to the end. Measured: a menu that fits shows nothing.\n */\n moreBelowLabel?: string | undefined;\n}\n\n/** The rows' scroller and its \"more below\" bar, for a panel that declares its overflow. */\nfunction DeclaredOverflow({ label, children }: { label: string; children: React.ReactNode }): React.ReactElement {\n const fade = useScrollFade();\n const viewport = React.useRef<HTMLDivElement | null>(null);\n const setViewport = React.useCallback(\n (node: HTMLDivElement | null) => {\n viewport.current = node;\n fade.ref(node);\n },\n [fade.ref],\n );\n return (\n <>\n <div ref={setViewport} className=\"cm-viewport\" data-slot=\"menu-look-viewport\">\n {children}\n </div>\n {fade.state.bottom ? (\n <button\n type=\"button\"\n className=\"cm-more-below\"\n data-slot=\"menu-look-more-below\"\n // Not a menu item: never roving focus or type-ahead; Escape and arrows stay the list's.\n tabIndex={-1}\n aria-hidden=\"true\"\n // Radix would otherwise close the menu on the press that starts this click.\n onPointerDown={(event) => event.preventDefault()}\n onClick={() => viewport.current?.scrollTo({ top: viewport.current.scrollHeight, behavior: \"smooth\" })}\n >\n <RadixChevronDownIcon aria-hidden=\"true\" />\n {label}\n </button>\n ) : null}\n </>\n );\n}\n\n/** The menu's panel on the Radix dropdown (portalled, capped at the room Radix measured, scrolls past it). */\nexport const MenuLookContent = React.forwardRef<HTMLDivElement, MenuLookContentProps>(function MenuLookContent(\n { size = \"standard\", density = \"comfortable\", moreBelowLabel, children, ...props },\n ref,\n) {\n return (\n <DropdownMenuContent\n ref={ref}\n surface=\"solid\"\n data-menu-look=\"\"\n data-menu-family=\"dropdown\"\n data-size={size}\n data-density={density}\n {...(moreBelowLabel ? { \"data-overflow\": \"declared\" } : {})}\n {...props}\n className={MENU_LOOK_CLASS.panel}\n >\n {moreBelowLabel ? <DeclaredOverflow label={moreBelowLabel}>{children}</DeclaredOverflow> : children}\n </DropdownMenuContent>\n );\n});\n\ntype SubContentProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuSubContent>, \"className\" | \"surface\">;\n\nexport interface MenuLookSubContentProps extends SubContentProps, PanelLookProps, DataAttributes {\n fit?: MenuLookSubFit | undefined;\n}\n\n/** A submenu's panel: the same panel, as wide as the menu it opens from. */\nexport const MenuLookSubContent = React.forwardRef<HTMLDivElement, MenuLookSubContentProps>(function MenuLookSubContent(\n { size = \"standard\", density = \"comfortable\", fit = \"menu\", ...props },\n ref,\n) {\n return (\n <DropdownMenuSubContent\n ref={ref}\n surface=\"solid\"\n data-menu-look=\"\"\n data-menu-family=\"dropdown\"\n data-size={size}\n data-density={density}\n data-fit={fit}\n {...props}\n className={MENU_LOOK_CLASS.panel}\n />\n );\n});\n\ntype ContextContentProps = Omit<React.ComponentPropsWithoutRef<typeof ContextMenuContent>, \"className\">;\n\nexport interface MenuLookContextContentProps extends ContextContentProps, PanelLookProps, DataAttributes {}\n\n/** The right-click menu's panel on the Radix context menu: the dropdown's panel, opened at the pointer. */\nexport const MenuLookContextContent = React.forwardRef<HTMLDivElement, MenuLookContextContentProps>(function MenuLookContextContent(\n { size = \"standard\", density = \"comfortable\", ...props },\n ref,\n) {\n return (\n <ContextMenuContent\n ref={ref}\n data-menu-look=\"\"\n data-menu-family=\"context\"\n data-size={size}\n data-density={density}\n {...props}\n className={MENU_LOOK_CLASS.panel}\n />\n );\n});\n\ntype ContextSubContentProps = Omit<React.ComponentPropsWithoutRef<typeof ContextMenuSubContent>, \"className\">;\n\nexport interface MenuLookContextSubContentProps extends ContextSubContentProps, PanelLookProps, DataAttributes {\n fit?: MenuLookSubFit | undefined;\n}\n\n/** A right-click submenu's panel. */\nexport const MenuLookContextSubContent = React.forwardRef<HTMLDivElement, MenuLookContextSubContentProps>(function MenuLookContextSubContent(\n { size = \"standard\", density = \"comfortable\", fit = \"menu\", ...props },\n ref,\n) {\n return (\n <ContextMenuSubContent\n ref={ref}\n data-menu-look=\"\"\n data-menu-family=\"context\"\n data-size={size}\n data-density={density}\n data-fit={fit}\n {...props}\n className={MENU_LOOK_CLASS.panel}\n />\n );\n});\n\ntype ItemProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Item>, \"className\" | \"children\" | \"asChild\">;\n\nexport interface MenuLookItemProps extends ItemProps, MenuLookRowBodyProps, DataAttributes {\n destructive?: boolean | undefined;\n /** Drawn dimmed (a greyed verb whose reason is the row's tooltip); still focusable. */\n dimmed?: boolean | undefined;\n /** A real link: the row is an `<a>` (a modified click keeps the browser's link behaviour). */\n href?: string | undefined;\n target?: string | undefined;\n /** Props for the `<a>` (aria-current, title, onClick). */\n linkProps?: undefined | Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, \"href\" | \"target\" | \"className\" | \"children\">;\n}\n\ntype SubTriggerProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.SubTrigger>, \"className\" | \"children\" | \"asChild\">;\n\nexport interface MenuLookSubTriggerProps extends SubTriggerProps, MenuLookRowBodyProps, DataAttributes {}\n\ntype CheckboxProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.CheckboxItem>, \"className\" | \"children\" | \"asChild\">;\n\nexport interface MenuLookCheckboxItemProps extends CheckboxProps, MenuLookRowBodyProps, DataAttributes {}\n\ntype RadioProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.RadioItem>, \"className\" | \"children\" | \"asChild\">;\n\nexport interface MenuLookRadioItemProps extends RadioProps, Omit<MenuLookRowBodyProps, \"current\">, DataAttributes {}\n\ntype LabelPrimitiveProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Label>, \"className\">;\n\nexport interface MenuLookLabelProps extends LabelPrimitiveProps {\n /** A muted line under the heading (a menu's header: the record it acts on). */\n description?: React.ReactNode | undefined;\n}\n\ntype SeparatorProps = Omit<React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Separator>, \"className\">;\n\n/** The parts both Radix menus share (the context menu's are the same components under other names). */\ninterface MenuPrimitives {\n Item: typeof DropdownMenuPrimitive.Item;\n SubTrigger: typeof DropdownMenuPrimitive.SubTrigger;\n CheckboxItem: typeof DropdownMenuPrimitive.CheckboxItem;\n RadioItem: typeof DropdownMenuPrimitive.RadioItem;\n ItemIndicator: typeof DropdownMenuPrimitive.ItemIndicator;\n Label: typeof DropdownMenuPrimitive.Label;\n Separator: typeof DropdownMenuPrimitive.Separator;\n}\n\n/** The rows, drawn once, over either Radix menu — so a row's \"…\" and its right-click are one look. */\nfunction menuLookRows(P: MenuPrimitives, family: \"dropdown-menu\" | \"context-menu\") {\n /** One row: icon, label (+ optional second line), optional end hint; a link when given `href`. */\n const Item = React.forwardRef<HTMLDivElement, MenuLookItemProps>(function MenuLookItem(\n { icon, label, labelTitle, description, trail, badge, shortcut, current, destructive, dimmed, href, target, linkProps, ...props },\n ref,\n ) {\n const className = menuLookItemClass({ destructive, dimmed });\n const body = <MenuLookRowBody icon={icon} label={label} labelTitle={labelTitle} description={description} trail={trail} badge={badge} shortcut={shortcut} current={current} />;\n const mark = current ? { \"data-current\": \"\" } : {};\n if (href) {\n return (\n <P.Item ref={ref} asChild data-slot={`${family}-item`} {...props} {...mark} className={className}>\n <a href={href} target={target} rel={target === \"_blank\" ? \"noopener noreferrer\" : undefined} {...linkProps}>\n {body}\n </a>\n </P.Item>\n );\n }\n return (\n <P.Item ref={ref} data-slot={`${family}-item`} {...props} {...mark} className={className}>\n {body}\n </P.Item>\n );\n });\n\n /**\n * A row that opens a submenu: the same row (icon slot, the standard gap, one left edge) with the\n * look's chevron at its END (`cm-chevron`, 16px, muted) — never a bare SubTrigger whose icon touches\n * its label.\n */\n const SubTrigger = React.forwardRef<HTMLDivElement, MenuLookSubTriggerProps>(function MenuLookSubTrigger(\n { icon, label, labelTitle, description, trail, badge, shortcut, current, ...props },\n ref,\n ) {\n return (\n <P.SubTrigger ref={ref} data-slot={`${family}-sub-trigger`} {...props} {...(current ? { \"data-current\": \"\" } : {})} className={MENU_LOOK_CLASS.item}>\n <MenuLookRowBody icon={icon} label={label} labelTitle={labelTitle} description={description} trail={trail} badge={badge} shortcut={shortcut} />\n <RadixChevronRightIcon className={MENU_LOOK_CLASS.chevron} aria-hidden=\"true\" />\n </P.SubTrigger>\n );\n });\n\n /** A toggle row: a check in the icon slot while on (the right-click menu's toggle), else its icon — a\n * toggle keeps its column either way, so switching it never moves its label. */\n const CheckboxItem = React.forwardRef<HTMLDivElement, MenuLookCheckboxItemProps>(function MenuLookCheckboxItem(\n { icon, label, labelTitle, description, trail, badge, shortcut, checked, ...props },\n ref,\n ) {\n const on = checked === true;\n return (\n <P.CheckboxItem ref={ref} {...(checked === undefined ? {} : { checked })} {...props} className={MENU_LOOK_CLASS.item}>\n <MenuLookRowBody icon={on ? <RadixCheckIcon className={MENU_LOOK_CLASS.icon} /> : (icon ?? <span className={MENU_LOOK_CLASS.icon} aria-hidden=\"true\" />)} label={label} labelTitle={labelTitle} description={description} trail={trail} badge={badge} shortcut={shortcut} />\n </P.CheckboxItem>\n );\n });\n\n /** A one-of row: the chosen one is marked like the current row — medium weight and a check at the\n * row's END — so no row reserves a left gutter for a dot. */\n const RadioItem = React.forwardRef<HTMLDivElement, MenuLookRadioItemProps>(function MenuLookRadioItem(\n { icon, label, labelTitle, description, trail, badge, shortcut, ...props },\n ref,\n ) {\n return (\n <P.RadioItem ref={ref} {...props} className={MENU_LOOK_CLASS.item}>\n <MenuLookRowBody icon={icon} label={label} labelTitle={labelTitle} description={description} trail={trail} badge={badge} shortcut={shortcut} />\n <P.ItemIndicator className={MENU_LOOK_CLASS.current} data-menu-current-mark=\"\">\n <RadixCheckIcon aria-hidden=\"true\" />\n </P.ItemIndicator>\n </P.RadioItem>\n );\n });\n\n /** A section heading (\"Copy\", \"Brands\", \"Pages\"), with an optional muted line under it. */\n const Label = React.forwardRef<HTMLDivElement, MenuLookLabelProps>(function MenuLookLabel(\n { description, children, ...props },\n ref,\n ) {\n if (!description) return <P.Label ref={ref} {...props} className={MENU_LOOK_CLASS.sectionLabel}>{children}</P.Label>;\n return (\n <P.Label ref={ref} {...props} data-has-hint=\"\" className={MENU_LOOK_CLASS.sectionLabel}>\n <span>{children}</span>\n <span className={MENU_LOOK_CLASS.hint}>{description}</span>\n </P.Label>\n );\n });\n\n /** The line between sections. */\n const Separator = React.forwardRef<HTMLDivElement, SeparatorProps>(function MenuLookSeparator(props, ref) {\n return <P.Separator ref={ref} {...props} className={MENU_LOOK_CLASS.divider} />;\n });\n\n return { Item, SubTrigger, CheckboxItem, RadioItem, Label, Separator };\n}\n\nconst dropdownRows = menuLookRows(DropdownMenuPrimitive, \"dropdown-menu\");\nconst contextRows = menuLookRows(ContextMenuPrimitive as unknown as MenuPrimitives, \"context-menu\");\n\nexport const MenuLookItem = dropdownRows.Item;\n/** Holds a submenu: `MenuLookSub` > `MenuLookSubTrigger` + `MenuLookSubContent`. */\nexport const MenuLookSub = DropdownMenuPrimitive.Sub;\nexport const MenuLookSubTrigger = dropdownRows.SubTrigger;\nexport const MenuLookCheckboxItem = dropdownRows.CheckboxItem;\n/** A group of one-of rows (`MenuLookRadioItem`); the host owns `value` / `onValueChange`. */\nexport const MenuLookRadioGroup = DropdownMenuPrimitive.RadioGroup;\nexport const MenuLookRadioItem = dropdownRows.RadioItem;\nexport const MenuLookLabel = dropdownRows.Label;\nexport const MenuLookSeparator = dropdownRows.Separator;\n\n/** The right-click twins of the dropdown rows — identical rows, the Radix context menu underneath. */\nexport const MenuLookContextItem = contextRows.Item;\nexport const MenuLookContextSub = ContextMenuPrimitive.Sub;\nexport const MenuLookContextSubTrigger = contextRows.SubTrigger;\nexport const MenuLookContextCheckboxItem = contextRows.CheckboxItem;\nexport const MenuLookContextRadioGroup = ContextMenuPrimitive.RadioGroup;\nexport const MenuLookContextRadioItem = contextRows.RadioItem;\nexport const MenuLookContextLabel = contextRows.Label;\nexport const MenuLookContextSeparator = contextRows.Separator;\n\n// ── THE PANEL: the same panel and rows with no Radix menu (a popover or sheet that holds controls) ──\n\n/**\n * Where a panel sits: `\"floating\"` draws the menu's own box (border, popover fill, shadow, 280px) — a\n * CSS-toggled menu, or a host whose popover draws nothing; `\"sheet\"` draws no box (a phone's bottom\n * sheet, or a host popover that is already the box) and gives its rows 44px touch height.\n */\nexport type MenuLookPanelSurface = \"floating\" | \"sheet\";\n\nexport interface MenuLookPanelProps\n extends Omit<React.HTMLAttributes<HTMLDivElement>, \"className\" | \"style\">,\n PanelLookProps,\n DataAttributes {\n surface?: MenuLookPanelSurface | undefined;\n /**\n * `\"lg\"`: below the large breakpoint (1024px) the floating panel fills the width its host gives it —\n * a CSS-toggled menu that becomes a bottom-anchored sheet on a phone (AppShell's account menu).\n */\n fillBelow?: \"lg\" | undefined;\n}\n\n/** The menu's panel as a plain element: its rows are `MenuLookPanel*` parts. Role `menu` by default. */\nexport const MenuLookPanel = React.forwardRef<HTMLDivElement, MenuLookPanelProps>(function MenuLookPanel(\n { size = \"standard\", density = \"comfortable\", surface = \"floating\", fillBelow, role = \"menu\", ...props },\n ref,\n) {\n return (\n <div\n ref={ref}\n role={role}\n data-menu-look=\"\"\n data-menu-family=\"panel\"\n data-surface={surface}\n {...(fillBelow ? { \"data-fill-below\": fillBelow } : {})}\n data-size={size}\n data-density={density}\n {...props}\n className={MENU_LOOK_CLASS.panel}\n />\n );\n});\n\ntype PopoverProps = Omit<React.ComponentPropsWithoutRef<typeof PopoverContent>, \"className\" | \"surface\" | \"width\" | \"padding\" | \"sizing\">;\n\nexport interface MenuLookPopoverContentProps extends PopoverProps, PanelLookProps, DataAttributes {}\n\n/**\n * The panel IS the popover: a Radix popover (outside click, Esc, focus return, collision padding)\n * wearing the menu's box — one element, never a popover box around a menu box. Role `menu`.\n */\nexport const MenuLookPopoverContent = React.forwardRef<HTMLDivElement, MenuLookPopoverContentProps>(function MenuLookPopoverContent(\n { size = \"standard\", density = \"comfortable\", role = \"menu\", ...props },\n ref,\n) {\n return (\n <PopoverContent\n ref={ref}\n role={role}\n surface=\"solid\"\n padding=\"none\"\n animated\n data-menu-look=\"\"\n data-menu-family=\"panel\"\n data-in-popover=\"\"\n data-surface=\"floating\"\n data-size={size}\n data-density={density}\n {...props}\n className={MENU_LOOK_CLASS.panel}\n />\n );\n});\n\ntype LinkComponent = React.ElementType;\n\ninterface PanelRowMarks {\n destructive?: boolean | undefined;\n /** Drawn dimmed (a greyed verb whose reason is the row's tooltip); still pressable. */\n dimmed?: boolean | undefined;\n}\n\nexport interface MenuLookPanelItemProps\n extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, \"className\" | \"style\" | \"children\" | \"type\">,\n MenuLookRowBodyProps,\n PanelRowMarks,\n DataAttributes {\n /**\n * A toggle row's state (a tool that is showing): `aria-pressed`, and while on it reads like the\n * current row (medium weight, the check at its end).\n */\n pressed?: boolean | undefined;\n /** A link: the row is an anchor (or `as`, the host's link component — Next's Link, an app link). */\n href?: string | undefined;\n target?: string | undefined;\n rel?: string | undefined;\n /** The link component for `href` (it receives `href`, `className`, `role`, `onClick`, children). */\n as?: LinkComponent | undefined;\n /** Extra props for the link component (`prefetch={false}`, `aria-current`). */\n linkProps?: Record<string, unknown> | undefined;\n}\n\n/** A panel row: a button, or a link with `href`. Same row as the dropdown's (`cm-item`). */\nexport const MenuLookPanelItem = React.forwardRef<HTMLElement, MenuLookPanelItemProps>(function MenuLookPanelItem(\n { icon, label, labelTitle, description, trail, badge, shortcut, current, pressed, destructive, dimmed, href, target, rel, as, linkProps, onClick, role = \"menuitem\", ...props },\n ref,\n) {\n const marked = Boolean(current || pressed);\n const body = <MenuLookRowBody icon={icon} label={label} labelTitle={labelTitle} description={description} trail={trail} badge={badge} shortcut={shortcut} current={marked} />;\n const className = menuLookItemClass({ destructive, dimmed });\n const mark = marked ? { \"data-current\": \"\" } : {};\n if (href) {\n const Link = as ?? \"a\";\n return (\n <Link\n ref={ref}\n href={href}\n target={target}\n rel={rel ?? (target === \"_blank\" ? \"noopener noreferrer\" : undefined)}\n role={role}\n onClick={onClick}\n {...props}\n {...linkProps}\n {...mark}\n className={className}\n >\n {body}\n </Link>\n );\n }\n return (\n <button\n ref={ref as React.Ref<HTMLButtonElement>}\n type=\"button\"\n role={role}\n onClick={onClick}\n {...(pressed === undefined ? {} : { \"aria-pressed\": pressed })}\n {...props}\n {...mark}\n className={className}\n >\n {body}\n </button>\n );\n});\n\nexport interface MenuLookPanelControlRowProps\n extends Omit<React.HTMLAttributes<HTMLElement>, \"className\" | \"style\" | \"children\">,\n Pick<MenuLookRowBodyProps, \"icon\" | \"label\" | \"description\">,\n DataAttributes {\n /** The row's own control at its end: a `Switch`, a `SegmentedControl`, a count. */\n control: React.ReactNode;\n /** `\"label\"` when the whole row should press its control (a Switch); default `\"div\"`. */\n as?: \"div\" | \"label\" | undefined;\n}\n\n/**\n * A row that holds a control instead of being one (Theme: Light | Dark | Device; Standard view with its\n * Switch): the same icon slot, label and left edge as every row, the control at its END, and no hover\n * fill (the control answers the pointer, not the row).\n */\nexport const MenuLookPanelControlRow = React.forwardRef<HTMLElement, MenuLookPanelControlRowProps>(function MenuLookPanelControlRow(\n { icon, label, description, control, as = \"div\", ...props },\n ref,\n) {\n const Row = as;\n return (\n <Row ref={ref as React.Ref<never>} data-control-row=\"\" {...props} className={MENU_LOOK_CLASS.item}>\n <MenuLookRowBody icon={icon} label={label} description={description} />\n <span className={MENU_LOOK_CLASS.control}>{control}</span>\n </Row>\n );\n});\n\nexport interface MenuLookPanelHeaderProps extends DataAttributes {\n /** The 28px mark (an avatar, an organization mark, a colored glyph). */\n mark: React.ReactNode;\n title: React.ReactNode;\n /** One muted line under the title. */\n subtitle?: React.ReactNode | undefined;\n /** The header is a door to its own page. */\n href?: string | undefined;\n as?: LinkComponent | undefined;\n linkProps?: Record<string, unknown> | undefined;\n onClick?: React.MouseEventHandler<HTMLElement> | undefined;\n}\n\n/**\n * The row a panel opens with (Settings, the organization, the person): a 28px mark on the rows' left\n * edge, a title, an optional muted subtitle. With `href` it is a link to its page.\n */\nexport function MenuLookPanelHeader({ mark, title, subtitle, href, as, linkProps, onClick, ...data }: MenuLookPanelHeaderProps): React.ReactElement {\n const body = (\n <>\n <span className={MENU_LOOK_CLASS.headerMark}>{mark}</span>\n <span className={MENU_LOOK_CLASS.headerText}>\n <span className={MENU_LOOK_CLASS.headerTitle}>{title}</span>\n {subtitle ? <span className={MENU_LOOK_CLASS.headerSubtitle}>{subtitle}</span> : null}\n </span>\n </>\n );\n if (href) {\n const Link = as ?? \"a\";\n return (\n <Link href={href} onClick={onClick} data-menu-look-header=\"\" {...data} {...linkProps} className={MENU_LOOK_CLASS.header}>\n {body}\n </Link>\n );\n }\n return (\n <div data-menu-look-header=\"\" {...data} className={MENU_LOOK_CLASS.header}>\n {body}\n </div>\n );\n}\n\nexport interface MenuLookPanelDisclosureProps extends Pick<MenuLookRowBodyProps, \"icon\" | \"label\">, DataAttributes {\n /** Omitted with `pending`: the group's rows are still on their way. */\n children?: React.ReactNode;\n /**\n * The group's row while its rows load (a lazy chunk): the same row and chevron, inert and hidden\n * from assistive tech, so nothing below it moves when the group arrives (no layout shift).\n */\n pending?: boolean | undefined;\n defaultOpen?: boolean | undefined;\n open?: boolean | undefined;\n onOpenChange?: ((open: boolean) => void) | undefined;\n}\n\n/**\n * A folded group of rows (\"Quick Access\", \"Admin\"): a row with a down-chevron at its END that opens\n * the group in place. Closed, its rows are ABSENT (hidden: out of the hit-test tree and the tab order),\n * never clipped-but-live. Open, they sit on the same left edge as every row — no indent.\n */\nexport function MenuLookPanelDisclosure({ icon, label, children, pending, defaultOpen = false, open: openProp, onOpenChange, ...data }: MenuLookPanelDisclosureProps): React.ReactElement {\n const [ownOpen, setOwnOpen] = React.useState(defaultOpen);\n const open = openProp ?? ownOpen;\n const id = React.useId();\n const toggle = () => {\n const next = !open;\n if (openProp === undefined) setOwnOpen(next);\n onOpenChange?.(next);\n };\n if (pending) {\n return (\n <div data-menu-look-disclosure=\"\" data-pending=\"\" aria-hidden=\"true\" {...data}>\n <div className={MENU_LOOK_CLASS.item}>\n <MenuLookRowBody icon={icon} label={label} />\n <RadixChevronDownIcon className={MENU_LOOK_CLASS.chevron} aria-hidden=\"true\" data-disclosure-chevron=\"\" />\n </div>\n </div>\n );\n }\n return (\n <div data-menu-look-disclosure=\"\" {...data}>\n <button type=\"button\" className={MENU_LOOK_CLASS.item} aria-expanded={open} aria-controls={id} onClick={toggle}>\n <MenuLookRowBody icon={icon} label={label} />\n <RadixChevronDownIcon className={MENU_LOOK_CLASS.chevron} aria-hidden=\"true\" data-disclosure-chevron=\"\" />\n </button>\n <div id={id} role=\"group\" hidden={!open}>\n {children}\n </div>\n </div>\n );\n}\n\n/** A panel's section heading. */\nexport function MenuLookPanelLabel({ children, ...data }: { children: React.ReactNode } & DataAttributes): React.ReactElement {\n return (\n <div {...data} className={MENU_LOOK_CLASS.sectionLabel}>\n {children}\n </div>\n );\n}\n\n/** The line between a panel's sections. */\nexport function MenuLookPanelSeparator(): React.ReactElement {\n return <div role=\"separator\" className={MENU_LOOK_CLASS.divider} />;\n}\n\n// ── The menu's search ─────────────────────────────────────────────────────────────────────────\n\nexport interface MenuLookSearchProps\n extends Omit<React.InputHTMLAttributes<HTMLInputElement>, \"className\" | \"style\" | \"size\" | \"type\">,\n DataAttributes {}\n\n/**\n * The menu's search: its own header row (full-bleed, a hairline under it, held at the top while the\n * list scrolls) whose text starts on the rows' left edge. The host owns the value and its keys (stop\n * propagation on letters so the menu's type-ahead never takes them).\n */\nexport const MenuLookSearch = React.forwardRef<HTMLInputElement, MenuLookSearchProps>(function MenuLookSearch(\n { placeholder = \"Search\", ...props },\n ref,\n) {\n return (\n <div className={MENU_LOOK_CLASS.search} data-menu-look-search=\"\">\n <input\n ref={ref}\n type=\"search\"\n autoComplete=\"off\"\n spellCheck={false}\n placeholder={placeholder}\n aria-label={props[\"aria-label\"] ?? placeholder}\n {...props}\n />\n </div>\n );\n});\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AA4BA,YAAY,WAAW;AACvB,YAAY,2BAA2B;AACvC,YAAY,0BAA0B;AAsD7B,SAwBL,UAxBK,KA0BH,YA1BG;AA9CF,IAAM,YAAY;AAAA,EACvB,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,WAAW;AAAA,EACX,gBAAgB;AAAA,EAChB,UAAU;AAAA,EACV,YAAY;AAAA,EACZ,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,aAAa;AAAA,EACb,QAAQ;AACV;AAGO,IAAM,kBAAkB;AAAA,EAC7B,OAAO;AAAA,EACP,MAAM;AAAA,EACN,UAAU;AAAA,EACV,MAAM;AAAA,EACN,MAAM;AAAA,EACN,OAAO;AAAA,EACP,MAAM;AAAA,EACN,SAAS;AAAA,EACT,SAAS;AAAA,EACT,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,OAAO;AAAA,EACP,UAAU;AAAA,EACV,SAAS;AAAA,EACT,SAAS;AAAA,EACT,cAAc;AAAA,EACd,QAAQ;AAAA,EACR,YAAY;AAAA,EACZ,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,gBAAgB;AAAA,EAChB,QAAQ;AAAA,EACR,QAAQ;AACV;AAMO,SAAS,iBAAiB,EAAE,SAAS,GAAuD;AACjG,SAAO,oBAAC,UAAK,WAAW,gBAAgB,UAAW,UAAS;AAC9D;AAqBO,SAAS,gBAAgB,EAAE,MAAM,OAAO,YAAY,aAAa,OAAO,OAAO,UAAU,QAAQ,GAA6C;AACnJ,SACE,iCACG;AAAA,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A,MACZ;AAAA,MACA,cAAY,MAAM,YAAY,KAAK;AAAA,MAClC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ,CAAC;","names":["MenuLookContent","MenuLookSubContent","MenuLookContextContent","MenuLookContextSubContent","MenuLookItem","MenuLookSubTrigger","MenuLookCheckboxItem","MenuLookRadioItem","MenuLookLabel","MenuLookSeparator","MenuLookPanel","MenuLookPopoverContent","MenuLookPanelItem","MenuLookPanelControlRow","MenuLookSearch"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/item/types.ts","../src/item/host.tsx","../src/item/run-entry.ts","../src/item/ItemMenu.tsx","../src/item/ItemMenuDrawer.tsx","../src/item/ItemRow.tsx"],"sourcesContent":["/**\n * Item system — shared schema + prop types for ItemRow and ItemMenu.\n * Moved whole from @ai-matrx/chat/ui/item-types (2026-10-08); chat re-exports\n * these and narrows the surface fields to its closed registries.\n *\n * Pure types (no JSX). The menu config is a structured `sections` array with a\n * discriminated union of entries (`kind`), so ordering is explicit, section\n * labels are first-class, separators fall out of section boundaries, and\n * submenus nest naturally.\n *\n * Consumed by ItemMenu.tsx, ItemMenuDrawer.tsx, ItemRow.tsx.\n */\n\nimport type { ComponentType, ReactNode } from \"react\";\n\n/** Any icon component taking a className (lucide-react icons fit as-is). */\nexport type ItemMenuIcon = ComponentType<{ className?: string | undefined }>;\n\n/**\n * The record a row stands for, as the host's right-click menu reads it.\n * Structural on purpose: design-system knows no entity registry. A host\n * (chat) narrows it to its own `ContextMenuEntityRef`.\n */\nexport interface ItemEntityRef {\n type?: string | undefined;\n id?: string | undefined;\n title?: string | undefined;\n}\n\n// ── Menu entries ────────────────────────────────────────────────────────────\n\ninterface ItemMenuEntryBase {\n /** Stable identity within the menu. React key + shortcut/debug target. */\n id: string;\n label: string;\n icon?: ItemMenuIcon | undefined;\n /**\n * Semantic color class for the icon ONLY (e.g. \"text-amber-500\" for a pin).\n * Destructive entries use `tone: \"destructive\"`, never an iconClassName.\n */\n iconClassName?: string | undefined;\n /**\n * Hover text for the entry — never a second line (Arman, 2026-10-14: no\n * \"novels\" in menus). A menu is a list of verbs; the only second line an\n * entry draws is its `disabledReason`.\n */\n description?: string | undefined;\n /**\n * Short trailing chip, right-aligned on the same line (\"Coming soon\", \"Beta\",\n * \"Pro\"). This is the RIGHT way to qualify an entry — it costs no height,\n * unlike `description`. One or two words; it is a tag, not a sentence.\n */\n badge?: string | undefined;\n /** Omit the entry entirely. Builders compute this at config-build time. */\n hidden?: boolean | undefined;\n disabled?: boolean | undefined;\n /** Why it's disabled — rendered inline (muted) and as a `title` tooltip. */\n disabledReason?: string | undefined;\n}\n\n/** Visual + semantic severity. Destructive renders text/icon in text-destructive. */\nexport type ItemMenuTone = \"default\" | \"destructive\";\n\nexport interface ItemMenuToast {\n loading: string;\n success: string;\n /** Static message, or derive one from the thrown error. */\n error?: (string | ((error: unknown) => string)) | undefined;\n}\n\n/** A plain action. The default entry kind. */\nexport interface ItemMenuCommand extends ItemMenuEntryBase {\n kind?: \"command\" | undefined;\n tone?: ItemMenuTone | undefined;\n /**\n * Runs synchronously in the select handler (preserves the user-gesture\n * context required by clipboard writes), then the menu closes. If it\n * returns a Promise AND `toast` is set, the promise is handed to\n * sonner's `toast.promise`. If it returns a Promise WITHOUT `toast`, it's\n * fire-and-forget (the action owns its own optimistic update + feedback —\n * the conversation-thunk pattern). Void → nothing.\n */\n onSelect: () => void | Promise<void>;\n toast?: ItemMenuToast | undefined;\n /** Display-only shortcut hint, right-aligned (\"⌘D\", \"R\"). Desktop only. */\n shortcut?: string | undefined;\n /**\n * Single character that activates this entry while the menu is open\n * (Claude Code style: P/R/A/D). Case-insensitive, no modifiers.\n */\n shortcutKey?: string | undefined;\n /**\n * Declarative hook for host components. ItemRow intercepts `\"rename\"` and\n * starts its inline rename INSTEAD of running `onSelect`. Standalone\n * ItemMenu ignores intent and runs `onSelect` (keep a dialog fallback\n * there for non-row surfaces).\n */\n intent?: \"rename\" | undefined;\n}\n\n/**\n * A persistent on/off toggle (Radix CheckboxItem desktop, check glyph in the\n * drawer). Selecting it does NOT close the menu — it's a view option.\n *\n * RESERVED for genuine view options (\"Show timestamps\", \"Compact rows\").\n * State-FLIP actions (Pin/Unpin, Archive/Unarchive) stay plain `command`s\n * whose label+icon the builder swaps from current state.\n */\nexport interface ItemMenuCheckbox extends ItemMenuEntryBase {\n kind: \"checkbox\";\n checked: boolean;\n /** Should be optimistic. Failures are the caller's to toast + revert. */\n onCheckedChange: (next: boolean) => void | Promise<void>;\n shortcut?: string | undefined;\n shortcutKey?: string | undefined;\n}\n\n/** A real <a>. Gives middle-click / cmd-click semantics inside the menu. */\nexport interface ItemMenuLink extends ItemMenuEntryBase {\n kind: \"link\";\n href: string;\n /** \"_blank\" adds rel=\"noopener noreferrer\" automatically. */\n target?: \"_blank\" | undefined;\n}\n\n/** Nested submenu — Radix Sub on desktop, drill-in view on the drawer. */\nexport interface ItemMenuSubmenu extends ItemMenuEntryBase {\n kind: \"submenu\";\n /** Submenu body. Sections render with separators between them. */\n sections: ItemMenuSection[];\n /** Embed an existing canonical menu without duplicating its commands. */\n renderContent?: ((onClose: () => void) => ReactNode) | undefined;\n}\n\nexport type ItemMenuEntry =\n ItemMenuCommand | ItemMenuCheckbox | ItemMenuLink | ItemMenuSubmenu;\n\n// ── Sections + config ───────────────────────────────────────────────────────\n\nexport interface ItemMenuSection {\n /** React key. Defaults to `label` ?? index. Provide when label is absent. */\n id?: string | undefined;\n /** Optional muted heading (\"Manage\", \"Danger\"). */\n label?: string | undefined;\n items: ItemMenuEntry[];\n}\n\nexport interface ItemMenuHeader {\n /** e.g. the row title. The drawer renders it as DrawerTitle. */\n title: string;\n description?: string | undefined;\n}\n\nexport interface ItemMenuConfig {\n /** Optional header. Desktop renders a muted label row; drawer a real header. */\n header?: ItemMenuHeader | undefined;\n /** Separators are derived from section boundaries — never declared. */\n sections: ItemMenuSection[];\n}\n\n/**\n * Lazy form: invoked when the menu opens, so big lists don't build N configs\n * per render. Either form is accepted anywhere a config is.\n */\nexport type ItemMenuConfigInput = ItemMenuConfig | (() => ItemMenuConfig);\n\n// ── ItemMenu component props ────────────────────────────────────────────────\n\nexport interface ItemMenuProps {\n config: ItemMenuConfigInput;\n /** The trigger element — rendered via Radix `asChild` (must accept a ref). */\n children: ReactNode;\n /** Dropdown alignment relative to trigger. Default \"end\". */\n align?: \"start\" | \"center\" | \"end\" | undefined;\n side?: \"top\" | \"right\" | \"bottom\" | \"left\" | undefined;\n /**\n * Controlled open state. Pass when a surface opens the menu from outside the\n * trigger (e.g. whole-row click opens the same kebab menu). Omit for the\n * default uncontrolled trigger-driven behavior.\n */\n open?: boolean | undefined;\n /** Observe / drive open state (e.g. ItemRow pins the kebab visible while open). */\n onOpenChange?: ((open: boolean) => void) | undefined;\n /**\n * Radix `onCloseAutoFocus` passthrough. ItemRow uses it to move focus into\n * the rename input instead of back to the kebab. Desktop only.\n */\n onCloseAutoFocus?: ((event: Event) => void) | undefined;\n /** Force presentation. Default: useIsMobile(). For demos/tests. */\n presentation?: \"auto\" | \"dropdown\" | \"drawer\" | undefined;\n}\n\n/**\n * What the row IS, forwarded to the v3 context menu.\n *\n * This is the slot that was dark. `entity` gates **Attach To** and **Share**\n * inside `MenuContent`; `ItemContextMenu` never passed one, so every consumer\n * of the item system was denied both — not because the capability was missing,\n * but because the wrapper dropped it on the floor. `sourceFeature` was worse\n * than absent: it was hardcoded `\"files\"` for every caller, so a note row's\n * agent launches were attributed to the files feature.\n */\nexport interface ItemMenuSurface {\n /**\n * REQUIRED. v3 attributes every shortcut and agent launched from this menu\n * to it, and the type is a closed registry — there is deliberately no\n * generic member to hide behind.\n */\n sourceFeature: string;\n /** Registry surface name, when the row's surface has one (AI actions, bound agents). */\n surfaceName?: string | undefined;\n /**\n * The record itself. Present → Attach To. With `resourceType` → Share too.\n * Omit only when the row does not correspond to a registered entity.\n */\n entity?: ItemEntityRef | undefined;\n}\n\nexport interface ItemContextMenuProps extends ItemMenuSurface {\n config: ItemMenuConfigInput;\n /** The right-clickable surface (usually the whole row). */\n children: ReactNode;\n onOpenChange?: ((open: boolean) => void) | undefined;\n onCloseAutoFocus?: ((event: Event) => void) | undefined;\n /**\n * When false, children render bare (no Radix root). ItemRow passes `false`\n * on touch so long-press doesn't fight scroll + the always-visible kebab.\n */\n enabled?: boolean | undefined;\n /**\n * Live surface values for the universal menu. A delegated pane menu uses\n * the same scope builder as its SurfaceRuntimeProvider, so AI actions never\n * lose the values the surface declares.\n */\n getApplicationScope?: (() => unknown) | undefined;\n /**\n * ONE-MENU-PER-PANE delegation. Resolve the clicked row's existing kebab\n * config and per-row context from the event target at open time.\n */\n resolveItemOnOpen?: (target: HTMLElement | null) => {\n config: ItemMenuConfigInput;\n context?: unknown | undefined;\n } | null;\n}\n\n// ── ItemRow props ───────────────────────────────────────────────────────────\n\nexport interface ItemRowRename {\n /** Text being renamed. Defaults to `label`. */\n value?: string | undefined;\n onCommit: (next: string) => void | Promise<void>;\n validate?: ((next: string) => string | null) | undefined;\n emptyFallback?: string | undefined;\n maxLength?: number | undefined;\n /** Allow double-click on the row to start renaming. Default true. */\n doubleClick?: boolean | undefined;\n}\n\nexport interface ItemRowDisclosure {\n /** Whether the sub-list is showing (sets `aria-expanded`). */\n open: boolean;\n onToggle: () => void;\n /** Screen-reader name; absent = \"Expand <label>\" / \"Collapse <label>\". */\n ariaLabel?: string | undefined;\n}\n\nexport type ItemRowSize = \"xs\" | \"sm\" | \"md\" | \"lg\"; // h-6 nested sub-row (muted) / h-7 / h-8 (default) / h-10\n\nexport interface ItemRowProps extends ItemMenuSurface {\n label: string;\n /** Muted, never masked; sits between label and trailing indicators. */\n secondaryLabel?: string | undefined;\n /**\n * The most room the secondary label may take before it truncates (the label keeps the rest).\n * \"half\" (default) or \"third\" — for a secondary that only explains the row (a search reason).\n */\n secondaryShare?: \"half\" | \"third\" | undefined;\n /**\n * A second line under the label (a record's owner, path or snippet). The row\n * grows to two lines; the label keeps its fade, the subtitle is cut with an ellipsis.\n */\n subtitle?: ReactNode;\n /**\n * Controls at the row's trailing edge, OUTSIDE the row's link/button (so a\n * button here is never nested in the row's own control). With `actions`, the\n * kebab sits in the same group instead of floating over the label.\n */\n actions?: ReactNode;\n /** A control before the row's link/button (a selection checkbox), outside it. */\n leadingControl?: ReactNode;\n /**\n * The row folds a sub-list (a conversation's helpers, a folder's children). THE DISCLOSURE IS ON\n * THE RIGHT (Arman, 2026-10-23: \"CHEVRONS DO NOT GO ON THE LEFT SIDE of things\"): a chevron button\n * at the row's trailing edge, outside the row's link, after the trailing indicators; the label\n * keeps the column's one left edge. Never draw a chevron in `leading`.\n */\n disclosure?: ItemRowDisclosure | undefined;\n /**\n * Keep the disclosure's trailing room even with no `disclosure` — pass it on the plain rows that\n * sit among disclosure rows so every row's trailing meta (time) ends on one right edge.\n */\n reserveDisclosure?: boolean | undefined;\n /** Icon / status-dot slot. Fixed-width content recommended (size-4). */\n leading?: ReactNode;\n /**\n * Indicator slot (star, streaming dot). Sits at the right edge at rest and\n * glides LEFT (translate) when the kebab is revealed. Never masked.\n */\n trailing?: ReactNode;\n /**\n * Meta shown only while the row is hovered, keyboard-focused or its menu is open (a chat's\n * relative time). At rest it takes no room, so `trailing` keeps the right edge. Always shown on\n * touch, where the kebab is always shown too.\n */\n trailingOnHover?: ReactNode;\n active?: boolean | undefined;\n disabled?: boolean | undefined;\n /** Navigation mode — renders next/link as the row's primary element. */\n href?: string | undefined;\n /** Click mode — renders a <button> primary. Ignored while renaming. */\n onOpen?: (() => void) | undefined;\n /**\n * Only meaningful alongside `href`. By default a plain click navigates to\n * `href` and `onOpen` runs as a side effect (close a popover, etc.). When\n * `true`, a plain left-click instead calls `onOpen` and PREVENTS navigation —\n * for self-contained surfaces (drawers, embedded panels) that open the target\n * in place rather than routing the page away. The `href` is kept so\n * modifier/middle-click still opens it in a new tab and \"Copy link\" still\n * works. Default false.\n */\n openInPlace?: boolean | undefined;\n /** Kebab + right-click menu. Omit for menu-less rows. */\n menu?: ItemMenuConfigInput | undefined;\n /**\n * `sourceFeature` / `surfaceName` / `entity` (inherited from\n * `ItemMenuSurface`) are forwarded to the right-click menu. **Pass `entity`**\n * — it is what turns Attach To and Share on, and every row that omits it\n * ships a menu missing two doors the platform already has.\n */\n /** Inline rename. Enables double-click + the `intent: \"rename\"` contract. */\n rename?: ItemRowRename | undefined;\n size?: ItemRowSize | undefined; // default \"md\"\n /** Tree depth. padding-inline-start = 8px + indent * 16px. */\n indent?: number | undefined;\n /** Accessible label for the kebab. Default `Options for ${label}`. */\n kebabAriaLabel?: string | undefined;\n /**\n * Suppress ItemRow's own right-click menu (the kebab keeps the config).\n * Set when the host wraps the row in the universal v3 context menu\n * (`features/context-menu-v3`) so right-click belongs to ONE system.\n */\n disableContextMenu?: boolean | undefined;\n className?: string | undefined;\n}\n\n// ── Type guards ─────────────────────────────────────────────────────────────\n\nexport function isCommand(entry: ItemMenuEntry): entry is ItemMenuCommand {\n return entry.kind === undefined || entry.kind === \"command\";\n}\nexport function isCheckbox(entry: ItemMenuEntry): entry is ItemMenuCheckbox {\n return entry.kind === \"checkbox\";\n}\nexport function isLink(entry: ItemMenuEntry): entry is ItemMenuLink {\n return entry.kind === \"link\";\n}\nexport function isSubmenu(entry: ItemMenuEntry): entry is ItemMenuSubmenu {\n return entry.kind === \"submenu\";\n}\n\nexport function resolveItemMenuConfig(\n input: ItemMenuConfigInput,\n): ItemMenuConfig {\n return typeof input === \"function\" ? input() : input;\n}\n","\"use client\";\n\n/**\n * The host seam for the item system (ItemRow / ItemMenu). A host may override\n * it, never NEED to: without a provider the row's right-click opens the same\n * menu config in design-system's own context menu, and a promised command's\n * failure is reported to the console instead of a toast.\n *\n * - `ContextMenu` — the host's universal right-click menu around a row (the\n * website / chat mount the v3 menu here, which adds Copy, agents, Attach To,\n * Share). It receives the full `ItemContextMenuProps`.\n * - `toastPromise` — the host's promise toast (sonner's `toast.promise` shape).\n */\n\nimport * as React from \"react\";\nimport type { ItemContextMenuProps, ItemMenuToast } from \"./types\";\n\nexport interface ItemToastPromise {\n (\n promise: Promise<unknown>,\n messages: { loading: string; success: string; error: (error: unknown) => string },\n ): void;\n}\n\nexport interface ItemMenuHost {\n ContextMenu?: React.ComponentType<ItemContextMenuProps>;\n toastPromise?: ItemToastPromise;\n}\n\nconst HOST_KEY = Symbol.for(\"@ai-matrx/design-system/item-menu-host\");\ntype HostRegistry = Record<symbol, React.Context<ItemMenuHost | null> | undefined>;\nconst hostRegistry = globalThis as unknown as HostRegistry;\nconst ItemMenuHostContext: React.Context<ItemMenuHost | null> =\n hostRegistry[HOST_KEY] ??\n (hostRegistry[HOST_KEY] = React.createContext<ItemMenuHost | null>(null));\n\n/** Mount once at the host's app root. */\nexport function ItemMenuHostProvider({\n host,\n children,\n}: {\n host: ItemMenuHost;\n children: React.ReactNode;\n}) {\n return <ItemMenuHostContext.Provider value={host}>{children}</ItemMenuHostContext.Provider>;\n}\n\nexport function useItemMenuHost(): ItemMenuHost | null {\n return React.useContext(ItemMenuHostContext);\n}\n\nexport type { ItemMenuToast };\n","/**\n * Action dispatch for ItemMenu entries — shared by the kebab/dropdown\n * renderer (ItemMenu.tsx), the drawer, the default right-click menu and any\n * host's right-click converter, so command/toggle semantics (sync-in-gesture\n * execution, promise toast, fire-and-forget promise swallow) can never drift\n * between presentations.\n */\n\nimport type { ItemToastPromise } from \"./host\";\nimport type { ItemMenuCheckbox, ItemMenuCommand } from \"./types\";\n\nexport function runCommand(entry: ItemMenuCommand, toastPromise?: ItemToastPromise) {\n const result = entry.onSelect();\n if (result instanceof Promise) {\n if (entry.toast && toastPromise) {\n const { loading, success, error } = entry.toast;\n toastPromise(result, {\n loading,\n success,\n error: (e) =>\n typeof error === \"function\"\n ? error(e)\n : (error ?? \"Something went wrong\"),\n });\n } else if (entry.toast) {\n // No host toaster: the failure still announces itself.\n result.catch((e) => console.error(`[ItemMenu] \"${entry.label}\" failed`, e));\n } else {\n result.catch(() => {});\n }\n }\n}\n\nexport function runToggle(entry: ItemMenuCheckbox, next: boolean) {\n const result = entry.onCheckedChange(next);\n if (result instanceof Promise) result.catch(() => {});\n}\n","\"use client\";\n\n/**\n * ItemMenu / ItemContextMenu — schema-driven menus rendered three ways from one\n * ItemMenuConfig:\n * - desktop dropdown (kebab trigger) → the one menu look on the Radix\n * dropdown (`MenuLook*`), modal={false}\n * - right-click (wraps a surface) → the host's right-click menu\n * (`ItemMenuHostProvider`; the\n * website/chat mount v3), else the\n * same look on the context menu\n * (`MenuLookContext*`)\n * - mobile (kebab trigger) → Vaul bottom drawer w/ drill-in\n *\n * No dimming backdrop on the dropdown (modal={false}). Command/toggle\n * execution is shared across ALL presentations via run-entry.ts (sync-in-\n * gesture for clipboard, sonner toast.promise), so semantics cannot drift.\n */\n\nimport { Fragment, useEffect, useRef, useState, type PointerEvent as ReactPointerEvent, type ReactNode } from \"react\";\nimport { ALCHEMY_GLYPH_PATHS } from \"../content-transfer/icon\";\nimport { declareLazyDataProps, useMatrxTableRowAlchemy, useMatrxTableRowControls } from \"../table-host/host\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport { useIsMobile } from \"@ai-matrx/kit/media-query\";\nimport { DropdownMenu, DropdownMenuTrigger } from \"../dropdown-menu\";\nimport { ContextMenu, ContextMenuTrigger } from \"../context-menu\";\nimport {\n MenuLookCheckboxItem,\n MenuLookContent,\n MenuLookContextCheckboxItem,\n MenuLookContextContent,\n MenuLookContextItem,\n MenuLookContextLabel,\n MenuLookContextSeparator,\n MenuLookContextSub,\n MenuLookContextSubContent,\n MenuLookContextSubTrigger,\n MenuLookItem,\n MenuLookLabel,\n MenuLookSeparator,\n MenuLookSub,\n MenuLookSubContent,\n MenuLookSubTrigger,\n type MenuLookCheckboxItemProps,\n type MenuLookItemProps,\n type MenuLookLabelProps,\n type MenuLookSubContentProps,\n type MenuLookSubTriggerProps,\n} from \"../menu-look\";\nimport { ItemMenuDrawer } from \"./ItemMenuDrawer\";\nimport { useItemMenuHost } from \"./host\";\nimport { runCommand, runToggle } from \"./run-entry\";\nimport {\n isCheckbox,\n isCommand,\n isLink,\n isSubmenu,\n resolveItemMenuConfig,\n type ItemContextMenuProps,\n type ItemMenuConfig,\n type ItemMenuEntry,\n type ItemMenuProps,\n type ItemMenuSection,\n} from \"./types\";\nimport type { ItemToastPromise } from \"./host\";\n\n// ── The two menus, one look ─────────────────────────────────────────────────\n// The \"…\" (dropdown) and the right-click (context menu) draw the SAME rows: the one menu look\n// (`../menu-look`, Arman 2026-10-23: \"the IDENTICAL dropdown ... for size and style\"). One renderer,\n// two Radix families underneath.\n\ninterface MenuFamily {\n Item: React.ComponentType<MenuLookItemProps>;\n CheckboxItem: React.ComponentType<MenuLookCheckboxItemProps>;\n Sub: React.ComponentType<{ children?: ReactNode }>;\n SubTrigger: React.ComponentType<MenuLookSubTriggerProps>;\n SubContent: React.ComponentType<MenuLookSubContentProps>;\n Separator: React.ComponentType;\n Label: React.ComponentType<MenuLookLabelProps>;\n}\n\nconst dropdownFamily: MenuFamily = {\n Item: MenuLookItem,\n CheckboxItem: MenuLookCheckboxItem,\n Sub: MenuLookSub,\n SubTrigger: MenuLookSubTrigger,\n SubContent: MenuLookSubContent,\n Separator: MenuLookSeparator,\n Label: MenuLookLabel,\n};\n\nconst contextFamily = {\n Item: MenuLookContextItem,\n CheckboxItem: MenuLookContextCheckboxItem,\n Sub: MenuLookContextSub,\n SubTrigger: MenuLookContextSubTrigger,\n SubContent: MenuLookContextSubContent,\n Separator: MenuLookContextSeparator,\n Label: MenuLookContextLabel,\n} as unknown as MenuFamily;\n\n// ── Action dispatch — shared with any host right-click converter ────────────\n// Lives in run-entry.ts so toast.promise / fire-and-forget semantics cannot\n// drift between the kebab dropdown and the universal right-click menu.\n\n// ── Shared leaf content ─────────────────────────────────────────────────────\n\n/** An entry's row, in the menu look's words: icon, label (hover text), why-disabled line, badge, key. */\nfunction entryRow(entry: ItemMenuEntry, { showShortcut = true }: { showShortcut?: boolean } = {}) {\n const Icon = entry.icon;\n const shortcut =\n showShortcut && (isCommand(entry) || isCheckbox(entry))\n ? (entry.shortcut ?? entry.shortcutKey?.toUpperCase())\n : undefined;\n return {\n // A destructive row's glyph takes the row's danger tone (menu-look.css); others keep their own color.\n icon: Icon ? <Icon className={isCommand(entry) && entry.tone === \"destructive\" ? undefined : entry.iconClassName} /> : undefined,\n label: entry.label,\n labelTitle: entry.description,\n // The only second line an entry draws is why it is disabled; `description` is hover text\n // (Arman, 2026-10-14: no \"novels\" in menus).\n description: entry.disabled && entry.disabledReason ? entry.disabledReason : undefined,\n badge: entry.badge,\n shortcut,\n };\n}\n\n// ── Recursive section renderer (desktop dropdown + context) ─────────────────\n\nfunction MenuSections({\n family,\n sections,\n onCloseRequest,\n}: {\n family: MenuFamily;\n sections: ItemMenuSection[];\n /** Closes the menu (used by link clicks; commands close via Radix default). */\n onCloseRequest: () => void;\n}) {\n const visibleSections = sections\n .map((s) => ({ ...s, items: s.items.filter((e) => !e.hidden) }))\n .filter((s) => s.items.length > 0);\n\n return (\n <>\n {visibleSections.map((section, sIdx) => (\n <Fragment key={section.id ?? section.label ?? sIdx}>\n {sIdx > 0 && <family.Separator />}\n {section.label && <family.Label>{section.label}</family.Label>}\n {section.items.map((entry) => (\n <MenuLeaf\n key={entry.id}\n family={family}\n entry={entry}\n onCloseRequest={onCloseRequest}\n />\n ))}\n </Fragment>\n ))}\n </>\n );\n}\n\nfunction keepCanonicalPaletteInteraction(event: CustomEvent<{ originalEvent: Event }>) {\n const target = event.detail.originalEvent.target;\n if (target instanceof Element && target.closest(\"[data-canonical-alchemy-submenu]\")) event.preventDefault();\n}\n\nfunction MenuLeaf({\n family,\n entry,\n onCloseRequest,\n}: {\n family: MenuFamily;\n entry: ItemMenuEntry;\n onCloseRequest: () => void;\n}) {\n const toastPromise = useItemMenuHost()?.toastPromise;\n if (isSubmenu(entry)) {\n return (\n <family.Sub>\n <family.SubTrigger {...entryRow(entry, { showShortcut: false })} disabled={entry.disabled} onPointerLeave={(event) => {\n if (entry.renderContent && event.relatedTarget instanceof Element && event.relatedTarget.closest(\"[data-canonical-alchemy-submenu]\")) event.preventDefault();\n }} />\n <family.SubContent onFocusOutside={keepCanonicalPaletteInteraction} onPointerDownOutside={keepCanonicalPaletteInteraction} fit={entry.renderContent ? \"content\" : \"menu\"}>\n {entry.renderContent ? entry.renderContent(onCloseRequest) : <MenuSections\n family={family}\n sections={entry.sections}\n onCloseRequest={onCloseRequest}\n />}\n </family.SubContent>\n </family.Sub>\n );\n }\n\n if (isCheckbox(entry)) {\n return (\n <family.CheckboxItem\n {...entryRow(entry)}\n checked={entry.checked}\n disabled={entry.disabled}\n onSelect={(e) => e.preventDefault()} // stay open\n onCheckedChange={(next) => runToggle(entry, next)}\n />\n );\n }\n\n if (isLink(entry)) {\n return (\n <family.Item\n {...entryRow(entry)}\n disabled={entry.disabled}\n href={entry.href}\n target={entry.target}\n linkProps={{ onClick: onCloseRequest }}\n />\n );\n }\n\n // command\n return (\n <family.Item\n {...entryRow(entry)}\n disabled={entry.disabled}\n destructive={entry.tone === \"destructive\"}\n onSelect={() => runCommand(entry, toastPromise)}\n />\n );\n}\n\n// ── Single-key shortcut handling ────────────────────────────────────────────\n\nfunction makeShortcutHandler(\n config: ItemMenuConfig,\n close: () => void,\n toastPromise?: ItemToastPromise,\n): (event: React.KeyboardEvent) => void {\n return (event) => {\n if (event.metaKey || event.ctrlKey || event.altKey) return;\n if (event.key.length !== 1) return;\n const key = event.key.toLowerCase();\n // Top-level entries only — submenus handle their own keys when open.\n const entries = config.sections\n .flatMap((s) => s.items)\n .filter((e) => !e.hidden && !e.disabled);\n const match = entries.find(\n (e) =>\n (isCommand(e) || isCheckbox(e)) && e.shortcutKey?.toLowerCase() === key,\n );\n if (!match) return;\n event.preventDefault();\n event.stopPropagation();\n if (isCheckbox(match)) {\n runToggle(match, !match.checked); // stays open\n } else if (isCommand(match)) {\n runCommand(match, toastPromise); // sets pendingRename etc. before close\n close();\n }\n };\n}\n\nfunction RowAlchemyIcon(props: { className?: string | undefined }) {\n return (\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth={2} strokeLinecap=\"round\" strokeLinejoin=\"round\" aria-hidden {...props}>\n {ALCHEMY_GLYPH_PATHS.portal.map((d, index) => <path key={index} d={d} />)}\n </svg>\n );\n}\nfunction hasVisibleEntry(config: ItemMenuConfig | null, id: string): boolean {\n const entries = config?.sections.flatMap((section) => section.items) ?? [];\n return entries.some((entry) =>\n entry.id === id\n ? !entry.hidden\n : isSubmenu(entry) && entry.sections.some((section) =>\n section.items.some((child) => child.id === id && !child.hidden),\n ),\n );\n}\nconst containsDestructiveAction = (items: ItemMenuEntry[]): boolean => items.some((item) =>\n (isCommand(item) && item.tone === \"destructive\") || (isSubmenu(item) && item.sections.some((section) => containsDestructiveAction(section.items))),\n);\n\n/** The transfer session stays mounted in the row; only its canonical palette portals here. */\nfunction RowAlchemySubmenuContent({ onClose, restoreFocus }: { onClose: () => void; restoreFocus: () => void }) {\n const alchemy = useMatrxTableRowAlchemy();\n const target = useRef<HTMLDivElement>(null);\n const closeRef = useRef(onClose);\n const focusRef = useRef(restoreFocus);\n useEffect(() => { focusRef.current = restoreFocus; }, [restoreFocus]);\n useEffect(() => { closeRef.current = onClose; }, [onClose]);\n const mountMenu = alchemy?.mountMenu;\n useEffect(() => {\n mountMenu?.(target.current, () => closeRef.current(), () => focusRef.current());\n return () => mountMenu?.(null);\n }, [mountMenu]);\n return <div ref={target} data-canonical-alchemy-submenu aria-label=\"Alchemy output options\" onKeyDown={(event) => {\n // The embedded canonical palette uses native controls, not MenuItems.\n // Let Tab reach those controls instead of Radix's menu-only suppression.\n if (event.key === \"Tab\") event.stopPropagation();\n }} />;\n}\n\n// ── ItemMenu (trigger-anchored dropdown / drawer) ───────────────────────────\n\n/** How long the pointer rests on the trigger before the real menu mounts under it. */\nconst ARM_ON_HOVER_MS = 150;\n\nexport function ItemMenu({\n config,\n children,\n align = \"end\",\n side,\n open: openProp,\n onOpenChange,\n onCloseAutoFocus,\n presentation = \"auto\",\n}: ItemMenuProps) {\n const toastPromise = useItemMenuHost()?.toastPromise;\n const rowAlchemy = useMatrxTableRowAlchemy();\n const rowControls = useMatrxTableRowControls();\n const restoreTargetRef = useRef<HTMLElement | null>(null);\n const dropdownTriggerRef = useRef<HTMLButtonElement | null>(null);\n useEffect(() => { rowAlchemy?.activate(); }, [rowAlchemy]);\n const isMobile = useIsMobile();\n const [uncontrolledOpen, setUncontrolledOpen] = useState(false);\n const isControlled = openProp !== undefined;\n const open = isControlled ? openProp : uncontrolledOpen;\n // Resolve while open so controlled open (whole-row click) and trigger open\n // share one path — no setState-during-render, no empty first frame.\n const baseConfig = open ? resolveItemMenuConfig(config) : null;\n const includeAlchemy = Boolean(rowAlchemy?.ready)\n && !hasVisibleEntry(baseConfig, \"alchemy\");\n const alchemyItem: ItemMenuEntry | null = rowAlchemy ? {\n kind: \"submenu\",\n id: \"alchemy\",\n label: \"Alchemy\",\n icon: RowAlchemyIcon,\n disabled: rowAlchemy.copy.disabled,\n sections: [],\n renderContent: (onClose) => <RowAlchemySubmenuContent onClose={onClose} restoreFocus={() => (dropdownTriggerRef.current ?? restoreTargetRef.current)?.focus()} />,\n } : null;\n const normalSections = baseConfig?.sections.map((section, index) => ({ section, index }))\n .filter(({ section }) => section.id !== \"danger\" && !containsDestructiveAction(section.items)) ?? [];\n const targetSection = (normalSections.find(({ section }) => !section.label) ?? normalSections[0])?.index;\n const injectedRowItems: ItemMenuEntry[] = [\n ...(rowControls?.beginEdit && !hasVisibleEntry(baseConfig, \"table-edit-row\") ? [{ id: \"table-edit-row\", label: \"Edit row\", onSelect: rowControls.beginEdit }] : []),\n ...(rowControls?.saveEdits && !hasVisibleEntry(baseConfig, \"table-save-row\") ? [{ id: \"table-save-row\", label: \"Save changes\", onSelect: rowControls.saveEdits }] : []),\n ...(rowControls?.cancelEdits && !hasVisibleEntry(baseConfig, \"table-discard-row\") ? [{ id: \"table-discard-row\", label: \"Discard changes\", onSelect: rowControls.cancelEdits }] : []),\n ...(alchemyItem && includeAlchemy ? [alchemyItem] : []),\n ];\n const resolved: ItemMenuConfig | null = baseConfig && injectedRowItems.length > 0 ? {\n ...baseConfig,\n sections: targetSection !== undefined\n ? baseConfig.sections.map((section, index) => index === targetSection ? { ...section, items: [...section.items, ...injectedRowItems] } : section)\n : [{ id: \"actions\", items: injectedRowItems }, ...baseConfig.sections],\n } : baseConfig;\n // A LONG MENU SAYS SO, IN WORDS (FIX-Q13): the panel declares its overflow — the menu look's\n // \"More actions below\" bar (`MenuLookContent moreBelowLabel`), never a fade that smears Delete.\n\n const handleOpenChange = (next: boolean) => {\n if (!isControlled) setUncontrolledOpen(next);\n onOpenChange?.(next);\n };\n\n const mode =\n presentation === \"auto\" ? (isMobile ? \"drawer\" : \"dropdown\") : presentation;\n\n // ── THE DROPDOWN MOUNTS ON FIRST INTENT ──────────────────────────────────\n //\n // A mounted Radix DropdownMenu listens to EVERY keydown on the document\n // (its keyboard-vs-pointer tracking), open or not. A list of 800 rows held\n // 800 of them: typing in a note beside the Notes sidebar paid 647ms of\n // listener work over 240 keystrokes (2026-10-10). Until the trigger is\n // hovered, focused or pressed it is the bare trigger; the first intent mounts\n // the real menu (a press opens it in the same gesture), and it stays mounted.\n const [armed, setArmed] = useState(false);\n const refocusOnArmRef = useRef(false);\n const armTimerRef = useRef<number | undefined>(undefined);\n useEffect(() => () => window.clearTimeout(armTimerRef.current), []);\n const live = armed || open;\n useEffect(() => {\n if (!armed || !refocusOnArmRef.current) return;\n // Mounting the menu replaced the trigger element; keep keyboard focus on it.\n refocusOnArmRef.current = false;\n dropdownTriggerRef.current?.focus();\n }, [armed]);\n\n if (mode === \"drawer\") {\n return (\n <>\n <Slot\n onClick={(e: React.MouseEvent) => {\n e.stopPropagation();\n if (e.currentTarget instanceof HTMLElement) restoreTargetRef.current = e.currentTarget;\n handleOpenChange(true);\n }}\n >\n {children}\n </Slot>\n {resolved && (\n <ItemMenuDrawer\n open={open}\n onOpenChange={handleOpenChange}\n config={resolved}\n onCommand={(entry) => isCommand(entry) && runCommand(entry, toastPromise)}\n onToggle={(entry, next) =>\n isCheckbox(entry) && runToggle(entry, next)\n }\n />\n )}\n </>\n );\n }\n\n if (!live) {\n return (\n <Slot\n data-item-menu-trigger=\"idle\"\n onPointerEnter={() => {\n // Hover INTENT, not hover: mounting the real trigger swaps the button's\n // DOM node, and a press that arrives in the same few milliseconds as the\n // pointer (automation, a fast tap) is dispatched at the node that was just\n // removed — React never sees it and the click does nothing. A press inside\n // the delay takes the pointerdown path below, on the live node.\n window.clearTimeout(armTimerRef.current);\n armTimerRef.current = window.setTimeout(() => setArmed(true), ARM_ON_HOVER_MS);\n }}\n onPointerLeave={() => window.clearTimeout(armTimerRef.current)}\n onFocus={() => {\n refocusOnArmRef.current = true;\n setArmed(true);\n }}\n onPointerDown={(e: ReactPointerEvent) => {\n // A press with no hover first (touch-like input, automation): mount\n // and open in the same gesture, as Radix's own trigger would.\n if (e.button !== 0 || e.ctrlKey) return;\n e.preventDefault();\n setArmed(true);\n handleOpenChange(true);\n }}\n >\n {children}\n </Slot>\n );\n }\n\n return (\n <DropdownMenu open={open} onOpenChange={handleOpenChange} modal={false}>\n <DropdownMenuTrigger ref={dropdownTriggerRef} asChild>{children}</DropdownMenuTrigger>\n {resolved && (\n <MenuLookContent\n onFocusOutside={keepCanonicalPaletteInteraction}\n onPointerDownOutside={keepCanonicalPaletteInteraction}\n align={align}\n {...(side ? { side } : {})}\n // A rich menu (a full record-action registry is 20+ entries) is taller than a short\n // viewport: the look caps it at the room Radix measured and the rows scroll inside it.\n collisionPadding={12}\n moreBelowLabel=\"More actions below\"\n {...(onCloseAutoFocus ? { onCloseAutoFocus } : {})}\n onKeyDown={makeShortcutHandler(resolved, () =>\n handleOpenChange(false),\n toastPromise)}\n >\n {resolved.header?.title && (\n <MenuLookLabel description={resolved.header.description}>{resolved.header.title}</MenuLookLabel>\n )}\n <MenuSections\n family={dropdownFamily}\n sections={resolved.sections}\n onCloseRequest={() => handleOpenChange(false)}\n />\n </MenuLookContent>\n )}\n </DropdownMenu>\n );\n}\n// A record's menu is never a route header's phone primary: RouteHeader sends it\n// to the shell's ⋮ sheet instead of drawing a second overflow beside it\n// (`isMenuAction` in features/shell/components/header/route-header-layout.tsx).\nItemMenu.routeHeaderMenu = true as const;\n\n// ── ItemContextMenu (right-click anchored) ──────────────────────────────────\n// The host's universal right-click menu when one is provided\n// (`ItemMenuHostProvider` — the website and chat mount the v3 menu, which adds\n// Copy, agents, Attach To and Share around the row's own config). Without a\n// host, the same config opens in design-system's ContextMenu: right-click is\n// never missing, only less rich.\n\nexport function ItemContextMenu(props: ItemContextMenuProps) {\n const host = useItemMenuHost();\n if (props.enabled === false) return <>{props.children}</>;\n const HostMenu = host?.ContextMenu;\n if (HostMenu) return <HostMenu {...props} />;\n return <DefaultItemContextMenu {...props} />;\n}\n\nfunction DefaultItemContextMenu({\n config,\n children,\n resolveItemOnOpen,\n onOpenChange,\n onCloseAutoFocus,\n}: ItemContextMenuProps) {\n const [resolved, setResolved] = useState<ItemMenuConfig | null>(null);\n const targetRef = useRef<HTMLElement | null>(null);\n return (\n <ContextMenu\n modal={false}\n onOpenChange={(open) => {\n if (open) {\n const item = resolveItemOnOpen?.(targetRef.current);\n setResolved(resolveItemMenuConfig(item?.config ?? config));\n }\n onOpenChange?.(open);\n }}\n >\n <ContextMenuTrigger\n asChild\n onContextMenu={(event) => {\n targetRef.current = event.target instanceof HTMLElement ? event.target : null;\n }}\n >\n {children}\n </ContextMenuTrigger>\n {resolved && (\n <MenuLookContextContent onCloseAutoFocus={onCloseAutoFocus}>\n {resolved.header?.title && (\n <MenuLookContextLabel description={resolved.header.description}>{resolved.header.title}</MenuLookContextLabel>\n )}\n <MenuSections family={contextFamily} sections={resolved.sections} onCloseRequest={() => onOpenChange?.(false)} />\n </MenuLookContextContent>\n )}\n </ContextMenu>\n );\n}\n\n// `config` may be a GETTER resolved only when the menu opens. Every list writes it inline\n// (`config={() => menuFor(row)}`), so the table compares it by what it returns, never by identity —\n// otherwise each host render redrew every row (/crm: 25 of 25 per checkbox tick).\ndeclareLazyDataProps(ItemMenu, [\"config\"]);\ndeclareLazyDataProps(ItemContextMenu, [\"config\"]);\n","\"use client\";\n\n/**\n * ItemMenuDrawer — mobile presentation for ItemMenu.\n *\n * A Vaul bottom sheet with iOS-style submenu drill-in: tapping a submenu pushes\n * a new view (slide-in-from-right), the back button pops it (slide-in-from-left).\n * Renders the same ItemMenuConfig the desktop dropdown/context menu use.\n *\n * Used internally by ItemMenu — not exported as a standalone primitive.\n */\n\nimport { useState } from \"react\";\nimport { ChevronLeftIcon as ChevronLeft, ChevronRightIcon as ChevronRight, CheckIcon } from \"../icons\";\nimport {\n Drawer,\n DrawerContent,\n DrawerTitle,\n} from \"../drawer\";\nimport { cn } from \"../cn\";\nimport {\n isCheckbox,\n isCommand,\n isLink,\n isSubmenu,\n type ItemMenuConfig,\n type ItemMenuEntry,\n type ItemMenuSection,\n type ItemMenuSubmenu,\n} from \"./types\";\n\ninterface ItemMenuDrawerProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n config: ItemMenuConfig;\n /** Runs a command entry (close-then-execute is handled by the caller). */\n onCommand: (entry: ItemMenuEntry) => void;\n /** Toggles a checkbox entry without closing the drawer. */\n onToggle: (entry: ItemMenuEntry, next: boolean) => void;\n}\n\n/** Walk a submenu `path` (entry ids) to the sections it points at. */\nfunction resolveSections(\n config: ItemMenuConfig,\n path: string[],\n): { sections: ItemMenuSection[]; title: string | null; renderContent?: ItemMenuSubmenu[\"renderContent\"] } {\n let sections = config.sections;\n let title: string | null = null;\n let renderContent: ItemMenuSubmenu[\"renderContent\"];\n for (const id of path) {\n const found = sections\n .flatMap((s) => s.items)\n .find((e) => e.id === id && isSubmenu(e));\n if (found && isSubmenu(found)) {\n sections = found.sections;\n title = found.label;\n renderContent = found.renderContent;\n } else {\n // Unknown id — defensively reset to root.\n return { sections: config.sections, title: null };\n }\n }\n return { sections, title, renderContent };\n}\n\nexport function ItemMenuDrawer({\n open,\n onOpenChange,\n config,\n onCommand,\n onToggle,\n}: ItemMenuDrawerProps) {\n const [path, setPath] = useState<string[]>([]);\n const [direction, setDirection] = useState<\"push\" | \"pop\">(\"push\");\n\n const { sections, title, renderContent } = resolveSections(config, path);\n const atRoot = path.length === 0;\n const headerTitle = atRoot ? config.header?.title : title;\n\n const push = (id: string) => {\n setDirection(\"push\");\n setPath((p) => [...p, id]);\n };\n const pop = () => {\n setDirection(\"pop\");\n setPath((p) => p.slice(0, -1));\n };\n\n const handleOpenChange = (next: boolean) => {\n if (!next) setPath([]);\n onOpenChange(next);\n };\n\n return (\n <Drawer open={open} onOpenChange={handleOpenChange}>\n <DrawerContent className=\"max-h-[80dvh] flex flex-col\">\n {/* Header — Back button when drilled in. DrawerTitle always present. */}\n {atRoot ? (\n headerTitle ? (\n <div className=\"flex-shrink-0 border-b border-border px-4 pb-3 pt-1\">\n <DrawerTitle className=\"text-center text-[15px] font-semibold\">\n {headerTitle}\n </DrawerTitle>\n {config.header?.description && (\n <p className=\"mt-1 text-center type-body text-muted-foreground\">\n {config.header.description}\n </p>\n )}\n </div>\n ) : (\n <DrawerTitle className=\"sr-only\">Options</DrawerTitle>\n )\n ) : (\n <div className=\"flex h-11 flex-shrink-0 items-center border-b border-border px-1\">\n <button\n type=\"button\"\n onClick={pop}\n aria-label=\"Back\"\n className=\"flex h-9 items-center gap-1 rounded-md px-2 text-sm text-muted-foreground hover:bg-accent hover:text-foreground\"\n >\n <ChevronLeft className=\"h-5 w-5\" />\n </button>\n <DrawerTitle className=\"flex-1 truncate pr-10 text-center text-[15px] font-semibold\">\n {headerTitle ?? \"Options\"}\n </DrawerTitle>\n </div>\n )}\n\n {/* Body — keyed by path so each view animates in. */}\n <div\n key={path.join(\"/\")}\n className={cn(\n \"flex-1 overflow-y-auto overscroll-contain py-2 pb-safe\",\n direction === \"push\"\n ? \"animate-in fade-in slide-in-from-right-8 duration-200\"\n : \"animate-in fade-in slide-in-from-left-8 duration-200\",\n )}\n >\n {renderContent?.(() => handleOpenChange(false))}\n {sections.map((section, sIdx) => {\n const visible = section.items.filter((e) => !e.hidden);\n if (visible.length === 0) return null;\n return (\n <div key={section.id ?? section.label ?? sIdx}>\n {sIdx > 0 && <div className=\"my-1 h-px bg-border\" />}\n {section.label && (\n <div className=\"px-4 pb-1 pt-2 type-secondary font-medium uppercase tracking-wide text-muted-foreground\">\n {section.label}\n </div>\n )}\n {visible.map((entry) => (\n <DrawerEntry\n key={entry.id}\n entry={entry}\n onCommand={onCommand}\n onToggle={onToggle}\n onDrill={() => push(entry.id)}\n onClose={() => handleOpenChange(false)}\n />\n ))}\n </div>\n );\n })}\n </div>\n </DrawerContent>\n </Drawer>\n );\n}\n\ninterface DrawerEntryProps {\n entry: ItemMenuEntry;\n onCommand: (entry: ItemMenuEntry) => void;\n onToggle: (entry: ItemMenuEntry, next: boolean) => void;\n onDrill: () => void;\n onClose: () => void;\n}\n\nfunction DrawerEntry({\n entry,\n onCommand,\n onToggle,\n onDrill,\n onClose,\n}: DrawerEntryProps) {\n const Icon = entry.icon;\n const destructive = isCommand(entry) && entry.tone === \"destructive\";\n const disabled = entry.disabled;\n\n const rowClass = cn(\n \"flex min-h-12 w-full items-center gap-3 px-4 text-left\",\n disabled\n ? \"opacity-50\"\n : \"active:bg-accent\",\n destructive && \"text-destructive\",\n );\n\n const content = (\n <>\n {Icon && (\n <Icon\n className={cn(\n \"h-[18px] w-[18px] shrink-0\",\n destructive\n ? \"text-destructive\"\n : entry.iconClassName ?? \"text-muted-foreground\",\n )}\n />\n )}\n <span className=\"flex min-w-0 flex-1 flex-col\">\n <span className=\"truncate text-[15px]\" title={entry.description}>{entry.label}</span>\n {disabled && entry.disabledReason ? (\n <span className=\"truncate type-body text-muted-foreground\">{entry.disabledReason}</span>\n ) : null}\n </span>\n </>\n );\n\n if (isSubmenu(entry)) {\n return (\n <button type=\"button\" disabled={disabled} onClick={onDrill} className={rowClass}>\n {content}\n <ChevronRight className=\"h-5 w-5 shrink-0 text-muted-foreground\" />\n </button>\n );\n }\n\n if (isCheckbox(entry)) {\n return (\n <button\n type=\"button\"\n disabled={disabled}\n onClick={() => onToggle(entry, !entry.checked)}\n className={rowClass}\n >\n {content}\n {entry.checked && <CheckIcon className=\"h-5 w-5 shrink-0 text-primary\" />}\n </button>\n );\n }\n\n if (isLink(entry)) {\n return (\n <a\n href={entry.href}\n target={entry.target}\n rel={entry.target === \"_blank\" ? \"noopener noreferrer\" : undefined}\n onClick={onClose}\n className={rowClass}\n >\n {content}\n </a>\n );\n }\n\n // command\n return (\n <button\n type=\"button\"\n disabled={disabled}\n onClick={() => {\n onClose();\n onCommand(entry);\n }}\n className={rowClass}\n >\n {content}\n </button>\n );\n}\n","\"use client\";\n\n/**\n * ItemRow — the reusable list row.\n *\n * - Full-width label with a right-edge mask fade (NO ellipsis) that deepens on\n * hover/focus/menu-open to clear the kebab (see `.item-row`/`.item-fade` in\n * design-system styles.css). Trailing indicators glide left in sync.\n * - Kebab is an absolute sibling (reserves no layout space) revealed on\n * hover/focus/menu-open, and always visible on touch.\n * - Right-click opens the SAME menu config (ItemContextMenu), disabled on touch.\n * - Inline rename: double-click the row, or a menu entry with `intent: \"rename\"`\n * (ItemRow swaps that entry's action for its own edit state and wins the\n * focus race via onCloseAutoFocus).\n *\n * The menu/rename schema lives in ./types; menus render via ./ItemMenu.\n */\n\nimport { useRef, useState } from \"react\";\nimport {\n ChevronDownIcon as ChevronDown,\n ChevronRightIcon as ChevronRight,\n MoreHorizontalIcon as MoreHorizontal,\n} from \"../icons\";\nimport { cn } from \"../cn\";\nimport { Button } from \"../controls/controls\";\nimport { useIsMobile } from \"@ai-matrx/kit/media-query\";\nimport { EditableLabel } from \"../editable-label\";\nimport { getTapTargetLinkComponent } from \"../tap-target/link\";\nimport { ItemMenu, ItemContextMenu } from \"./ItemMenu\";\nimport {\n isCommand,\n isSubmenu,\n resolveItemMenuConfig,\n type ItemMenuConfig,\n type ItemMenuConfigInput,\n type ItemMenuEntry,\n type ItemMenuSection,\n type ItemRowProps,\n type ItemRowSize,\n} from \"./types\";\n\nconst SIZE: Record<\n ItemRowSize,\n { row: string; text: string; kebab: string; icon: string; tone?: string }\n> = {\n // A nested sub-row (a conversation's helpers under it in the chat sidebar):\n // finer and quieter than its parent, so a tree reads at a glance.\n xs: {\n row: \"h-6\",\n text: \"text-xs\",\n kebab: \"h-5 w-5\",\n icon: \"h-3.5 w-3.5\",\n tone: \"text-muted-foreground\",\n },\n sm: {\n row: \"h-7\",\n text: \"text-[13px]\",\n kebab: \"h-5 w-5\",\n icon: \"h-3.5 w-3.5\",\n },\n md: { row: \"h-8\", text: \"text-sm\", kebab: \"h-6 w-6\", icon: \"h-4 w-4\" },\n lg: { row: \"h-10\", text: \"text-sm\", kebab: \"h-7 w-7\", icon: \"h-4 w-4\" },\n};\n\n/**\n * The trailing room a row keeps for its disclosure: the button (kebab size) + the 4px end inset +\n * a 4px gap, so the trailing meta (time) never touches the chevron. A disclosure row and a plain\n * sibling that passes `reserveDisclosure` keep the SAME room, so every row's meta ends on one edge.\n */\nconst DISCLOSURE_RESERVE: Record<ItemRowSize, number> = { xs: 32, sm: 32, md: 36, lg: 40 };\n\n/**\n * What reveals the kebab and the hover-only meta: pointer over the row, keyboard focus inside it,\n * its menu open, or a touch screen. Keyboard focus only — a clicked row keeps focus on its link, and\n * that must not pin its kebab and time on after the pointer leaves.\n */\nconst REVEAL_OPACITY =\n \"group-hover/item:opacity-100 group-has-[:focus-visible]/item:opacity-100 group-has-[[data-state=open]]/item:opacity-100 [@media(pointer:coarse)]:opacity-100\";\nconst REVEAL_DISPLAY =\n \"group-hover/item:inline group-has-[:focus-visible]/item:inline group-has-[[data-state=open]]/item:inline [@media(pointer:coarse)]:inline\";\n\n/**\n * Replace `intent: \"rename\"` command actions with the host's rename trigger —\n * or REMOVE them when this row has no `rename` prop at all.\n *\n * 🚨 The removal half is not tidiness. Without it, a row that renders a menu\n * carrying `intent: \"rename\"` but passes no `rename` handed the user a live\n * \"Rename\" row whose click set `pendingRenameRef`, flipped `editing`, and then\n * rendered the plain label again because `editing && rename` is false —\n * a control that looks clickable and does nothing (found by the LIVE-ITEM LAW,\n * 2026-09-11). `ctx.showRename === false` asks every consumer to remember;\n * this is the one place that KNOWS. Absent beats dead.\n */\nfunction mapRenameIntent(\n config: ItemMenuConfig,\n requestRename: (() => void) | null,\n): ItemMenuConfig {\n const mapEntry = (entry: ItemMenuEntry): ItemMenuEntry | null => {\n if (isSubmenu(entry)) {\n return { ...entry, sections: entry.sections.map(mapSection) };\n }\n if (isCommand(entry) && entry.intent === \"rename\") {\n return requestRename ? { ...entry, onSelect: requestRename } : null;\n }\n return entry;\n };\n const mapSection = (section: ItemMenuSection): ItemMenuSection => ({\n ...section,\n items: section.items\n .map(mapEntry)\n .filter((e): e is ItemMenuEntry => e !== null),\n });\n return { ...config, sections: config.sections.map(mapSection) };\n}\n\nexport function ItemRow({\n label,\n secondaryLabel,\n secondaryShare = \"half\",\n subtitle,\n actions,\n leadingControl,\n disclosure,\n reserveDisclosure = false,\n leading,\n trailing,\n trailingOnHover,\n active = false,\n disabled = false,\n href,\n onOpen,\n openInPlace = false,\n menu,\n rename,\n size = \"md\",\n indent,\n kebabAriaLabel,\n disableContextMenu = false,\n sourceFeature,\n surfaceName,\n entity,\n className,\n}: ItemRowProps) {\n const isMobile = useIsMobile();\n const [editing, setEditing] = useState(false);\n const pendingRenameRef = useRef(false);\n const sz = SIZE[size];\n\n const canRename = !!rename;\n const allowDoubleClick = canRename && rename.doubleClick !== false;\n\n // Wrap the menu so rename-intent entries drive ItemRow's edit state, and so\n // a static config is still resolved lazily (on open).\n const mappedMenu: ItemMenuConfigInput | undefined = menu\n ? () =>\n mapRenameIntent(\n resolveItemMenuConfig(menu),\n canRename\n ? () => {\n pendingRenameRef.current = true;\n }\n : null,\n )\n : undefined;\n\n // Radix returns focus to the trigger on close; when a rename was requested,\n // intercept it and move focus into the input instead (no focus tug-of-war).\n const handleCloseAutoFocus = (event: Event) => {\n if (pendingRenameRef.current) {\n pendingRenameRef.current = false;\n event.preventDefault();\n setEditing(true);\n }\n };\n\n const startInlineRename = () => {\n if (canRename) setEditing(true);\n };\n\n const labelNode =\n editing && rename ? (\n <EditableLabel\n activation=\"controlled\"\n editing\n onEditingChange={(next) => setEditing(next)}\n value={rename.value ?? label}\n onCommit={rename.onCommit}\n {...(rename.validate ? { validate: rename.validate } : {})}\n {...(rename.emptyFallback !== undefined ? { emptyFallback: rename.emptyFallback } : {})}\n {...(rename.maxLength !== undefined ? { maxLength: rename.maxLength } : {})}\n ariaLabel=\"Name\"\n className=\"flex-1\"\n inputClassName={cn(\"font-normal\", sz.text)}\n />\n ) : subtitle != null ? (\n <span className=\"flex min-w-0 flex-1 flex-col\">\n <span className={cn(\"item-fade min-w-0\", sz.text)} title={label}>\n {label}\n </span>\n <span className=\"min-w-0 truncate type-secondary text-muted-foreground\" data-item-subtitle=\"\">\n {subtitle}\n </span>\n </span>\n ) : (\n <span className={cn(\"item-fade min-w-0 flex-1\", sz.text)} title={label}>\n {label}\n </span>\n );\n\n const primaryInner = (\n <>\n {leading != null && (\n <span className=\"flex shrink-0 items-center\">{leading}</span>\n )}\n {labelNode}\n {secondaryLabel && (\n // Clamped: a secondary value can be a sentence (a lineage edge's\n // \"140 cards - 1 section could not be covered …\"). Unclamped it pushed\n // the label out of the row (owner, 2026-10-04).\n <span\n className={cn(\n \"item-shift min-w-0 truncate type-secondary text-muted-foreground\",\n secondaryShare === \"third\" ? \"max-w-[33%]\" : \"max-w-[50%]\",\n )}\n title={secondaryLabel}\n >\n {secondaryLabel}\n </span>\n )}\n {(trailing != null || trailingOnHover != null) && (\n <span className=\"item-shift flex shrink-0 items-center gap-1 pr-0.5\">\n {trailing}\n {trailingOnHover != null && (\n <span className={cn(\"hidden\", REVEAL_DISPLAY)} data-item-trailing-hover=\"\">\n {trailingOnHover}\n </span>\n )}\n </span>\n )}\n </>\n );\n\n const twoLine = subtitle != null && !editing;\n const sideBySide = actions != null || leadingControl != null;\n\n // THE DISCLOSURE IS ON THE RIGHT (Arman, 2026-10-23): a real button outside the row's link, after\n // the label and the trailing indicators — never before the label. It glides with the trailing\n // indicators when the kebab shows, so the two never overlap.\n const disclosureButton = disclosure ? (\n <Button\n type=\"button\"\n variant=\"quiet\"\n data-item-disclosure=\"\"\n aria-expanded={disclosure.open}\n aria-label={disclosure.ariaLabel ?? `${disclosure.open ? \"Collapse\" : \"Expand\"} ${label}`}\n onClick={(e) => {\n e.stopPropagation();\n disclosure.onToggle();\n }}\n icon={disclosure.open ? <ChevronDown className={sz.icon} /> : <ChevronRight className={sz.icon} />}\n className=\"shrink-0\"\n >\n </Button>\n ) : null;\n const primaryClass = cn(\n \"flex min-w-0 items-center gap-1.5 rounded-lg px-2\",\n sideBySide ? \"flex-1\" : \"w-full\",\n twoLine ? \"min-h-11 py-1.5\" : sz.row,\n sz.text,\n \"outline-none focus-visible:ring-1 focus-visible:ring-inset focus-visible:ring-ring\",\n active ? \"font-medium text-primary\" : (sz.tone ?? \"text-foreground\"),\n );\n\n const indentStyle: React.CSSProperties | undefined =\n (indent && indent > 0) || ((disclosure || reserveDisclosure) && !sideBySide)\n ? {\n ...(indent && indent > 0 ? { paddingInlineStart: 8 + indent * 16 } : {}),\n // Room for the disclosure at the trailing edge (its box + the row's 4px end inset).\n ...((disclosure || reserveDisclosure) && !sideBySide ? { paddingInlineEnd: DISCLOSURE_RESERVE[size] } : {}),\n }\n : undefined;\n\n // Primary element: link (navigation), button (click), or div (editing/disabled).\n let primary: React.ReactNode;\n if (editing || disabled) {\n primary = (\n <div className={primaryClass} style={indentStyle} data-item-primary=\"\">\n {primaryInner}\n </div>\n );\n } else if (href) {\n // The host's registered link (`setTapTargetLinkComponent`, e.g. next/link), else a plain anchor.\n const RegisteredLink = getTapTargetLinkComponent();\n const Link = (RegisteredLink ?? \"a\") as unknown as React.ComponentType<React.AnchorHTMLAttributes<HTMLAnchorElement> & { href: string; prefetch?: boolean }>;\n primary = (\n <Link\n href={href}\n data-item-primary=\"\"\n // 🚨 A ROW NEVER PREFETCHES. next/link prefetches every link in view, so\n // a 20-row list (chat history) fired 20 background route renders on\n // page load (2026-10-09). A row is opened by a click; the click loads it.\n {...(RegisteredLink ? { prefetch: false } : {})}\n className={primaryClass}\n style={indentStyle}\n onClick={(e: React.MouseEvent<HTMLAnchorElement>) => {\n // Modifier / middle-click: native <a> opens a new tab/window.\n if (e.metaKey || e.ctrlKey || e.shiftKey || e.button === 1) return;\n // `openInPlace`: handle the click in-app and keep the page put. The\n // href stays for new-tab / copy-link affordances above.\n if (openInPlace) e.preventDefault();\n onOpen?.();\n // Without `openInPlace`, `onOpen` is a side effect only (close a\n // popover, etc.) — navigation stays on the Link href.\n }}\n onDoubleClick={\n allowDoubleClick\n ? (e: React.MouseEvent<HTMLAnchorElement>) => {\n e.preventDefault();\n e.stopPropagation();\n startInlineRename();\n }\n : undefined\n }\n >\n {primaryInner}\n </Link>\n );\n } else {\n primary = (\n <button\n type=\"button\"\n data-item-primary=\"\"\n className={cn(primaryClass, \"cursor-pointer text-left\")}\n style={indentStyle}\n onClick={onOpen}\n onDoubleClick={\n allowDoubleClick\n ? (e) => {\n e.preventDefault();\n e.stopPropagation();\n startInlineRename();\n }\n : undefined\n }\n >\n {primaryInner}\n </button>\n );\n }\n\n const kebab =\n mappedMenu && !editing ? (\n <ItemMenu\n config={mappedMenu}\n align=\"end\"\n onCloseAutoFocus={handleCloseAutoFocus}\n >\n <Button\n type=\"button\"\n variant=\"quiet\"\n aria-label={kebabAriaLabel ?? `Options for ${label}`}\n icon={<MoreHorizontal className={sz.icon} />}\n aria-haspopup=\"menu\"\n onClick={(e) => e.stopPropagation()}\n data-item-kebab=\"\"\n className={cn(\n \"shrink-0\",\n !sideBySide && \"absolute right-1 top-1/2 -translate-y-1/2\",\n // Hidden at rest (it would sit on the trailing meta); shown on hover, keyboard focus,\n // while its menu is open, and always on touch.\n \"opacity-0 transition-opacity data-[state=open]:opacity-100 focus-visible:opacity-100\",\n REVEAL_OPACITY,\n )}\n >\n </Button>\n </ItemMenu>\n ) : null;\n\n const row = (\n <div\n data-active={active || undefined}\n // The deep fade exists to clear the kebab; a menu-less row has none, so\n // its label keeps every pixel (touch used to fade it permanently).\n data-no-menu={mappedMenu && !sideBySide ? undefined : true}\n className={cn(\n \"item-row group/item relative rounded-lg transition-colors\",\n sideBySide && \"flex items-center\",\n !active && \"hover:bg-accent/60\",\n active && \"bg-primary/10 text-primary-ink\",\n className,\n )}\n >\n {leadingControl != null ? (\n <span className=\"flex shrink-0 items-center pl-2\" data-item-leading-control=\"\">\n {leadingControl}\n </span>\n ) : null}\n {primary}\n\n {!sideBySide && disclosureButton ? (\n <span\n className=\"item-shift absolute inset-y-0 right-1 flex items-center\"\n data-item-disclosure-slot=\"\"\n >\n {disclosureButton}\n </span>\n ) : null}\n {!sideBySide && kebab}\n {/* The actions wrapper adds NO gap or padding: tap buttons space themselves (tap-target guard\n rules 3 and 4 flag a wrapper that adds space around one); a plain (non-tap) child gets its own\n horizontal margin from the wrapper's child selector below. */}\n {sideBySide && (actions != null || kebab || disclosureButton) ? (\n <span\n className=\"flex shrink-0 items-center [&>:not(.matrx-tap-target,.matrx-alchemy)]:mx-0.5\"\n data-item-actions=\"\"\n >\n {actions}\n {disclosureButton}\n {kebab}\n </span>\n ) : null}\n </div>\n );\n\n if (!mappedMenu || disableContextMenu) return row;\n\n return (\n <ItemContextMenu\n config={mappedMenu}\n // Forwarded, not invented. `entity` is what turns Attach To and Share on\n // in the v3 menu; a row that omits it ships a menu missing two doors the\n // platform already owns. `sourceFeature` is REQUIRED rather than\n // defaulted: it used to be hardcoded `\"files\"` inside ItemContextMenu, a\n // confident lie on every non-file row, and `SourceFeature` is a closed\n // registry with no generic member to hide behind — so the compiler makes\n // each row name itself instead.\n sourceFeature={sourceFeature}\n surfaceName={surfaceName}\n entity={entity}\n enabled={!isMobile && !editing}\n onCloseAutoFocus={handleCloseAutoFocus}\n // The v3 context menu is not a Radix content, so `onCloseAutoFocus` never fires\n // there: a Rename picked from the right-click menu set the pending flag and\n // nothing ever opened the editor. Its close is the signal instead.\n onOpenChange={(open) => {\n if (!open && pendingRenameRef.current) {\n pendingRenameRef.current = false;\n setTimeout(() => setEditing(true), 0);\n }\n }}\n >\n {row}\n </ItemContextMenu>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqWO,SAAS,UAAU,OAAgD;AACxE,SAAO,MAAM,SAAS,UAAa,MAAM,SAAS;AACpD;AACO,SAAS,WAAW,OAAiD;AAC1E,SAAO,MAAM,SAAS;AACxB;AACO,SAAS,OAAO,OAA6C;AAClE,SAAO,MAAM,SAAS;AACxB;AACO,SAAS,UAAU,OAAgD;AACxE,SAAO,MAAM,SAAS;AACxB;AAEO,SAAS,sBACd,OACgB;AAChB,SAAO,OAAO,UAAU,aAAa,MAAM,IAAI;AACjD;;;ACxWA,YAAY,WAAW;AA8Bd;AAfT,IAAM,WAAW,uBAAO,IAAI,wCAAwC;AAEpE,IAAM,eAAe;AACrB,IAAM,sBACJ,aAAa,QAAQ,MACpB,aAAa,QAAQ,IAAU,oBAAmC,IAAI;AAGlE,SAAS,qBAAqB;AAAA,EACnC;AAAA,EACA;AACF,GAGG;AACD,SAAO,oBAAC,oBAAoB,UAApB,EAA6B,OAAO,MAAO,UAAS;AAC9D;AAEO,SAAS,kBAAuC;AACrD,SAAa,iBAAW,mBAAmB;AAC7C;;;ACtCO,SAAS,WAAW,OAAwB,cAAiC;AAClF,QAAM,SAAS,MAAM,SAAS;AAC9B,MAAI,kBAAkB,SAAS;AAC7B,QAAI,MAAM,SAAS,cAAc;AAC/B,YAAM,EAAE,SAAS,SAAS,MAAM,IAAI,MAAM;AAC1C,mBAAa,QAAQ;AAAA,QACnB;AAAA,QACA;AAAA,QACA,OAAO,CAAC,MACN,OAAO,UAAU,aACb,MA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useIsMobile","Fragment","jsx","jsxs","useIsMobile","useState","useRef"]}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|