@adea-ai/ui 0.82.2 → 0.83.1

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.
Files changed (41) hide show
  1. package/dist/components/composites/action-button/action-button.d.ts.map +1 -1
  2. package/dist/components/composites/action-button/action-button.js +55 -24
  3. package/dist/components/composites/action-button/action-button.js.map +1 -1
  4. package/dist/components/layout/orbit-layout/index.d.ts +3 -0
  5. package/dist/components/layout/orbit-layout/index.d.ts.map +1 -0
  6. package/dist/components/layout/orbit-layout/index.js +2 -0
  7. package/dist/components/layout/orbit-layout/orbit-layout.d.ts +38 -0
  8. package/dist/components/layout/orbit-layout/orbit-layout.d.ts.map +1 -0
  9. package/dist/components/layout/orbit-layout/orbit-layout.js +83 -0
  10. package/dist/components/layout/orbit-layout/orbit-layout.js.map +1 -0
  11. package/dist/components/layout/virtual-window/index.d.ts +3 -0
  12. package/dist/components/layout/virtual-window/index.d.ts.map +1 -0
  13. package/dist/components/layout/virtual-window/index.js +2 -0
  14. package/dist/components/layout/virtual-window/virtual-window.d.ts +22 -0
  15. package/dist/components/layout/virtual-window/virtual-window.d.ts.map +1 -0
  16. package/dist/components/layout/virtual-window/virtual-window.js +45 -0
  17. package/dist/components/layout/virtual-window/virtual-window.js.map +1 -0
  18. package/dist/components/ui/command/command.d.ts.map +1 -1
  19. package/dist/components/ui/command/command.js +1 -0
  20. package/dist/components/ui/command/command.js.map +1 -1
  21. package/dist/index.d.ts +2 -0
  22. package/dist/index.d.ts.map +1 -1
  23. package/dist/index.js +3 -1
  24. package/dist/r/orbit-layout.json +22 -0
  25. package/dist/r/registry.json +44 -0
  26. package/dist/r/src/components/composites/action-button/action-button.tsx +52 -11
  27. package/dist/r/src/components/layout/orbit-layout/index.ts +8 -0
  28. package/dist/r/src/components/layout/orbit-layout/orbit-layout.tsx +112 -0
  29. package/dist/r/src/components/layout/virtual-window/index.ts +2 -0
  30. package/dist/r/src/components/layout/virtual-window/virtual-window.tsx +55 -0
  31. package/dist/r/src/components/ui/command/command.tsx +1 -0
  32. package/dist/r/virtual-window.json +22 -0
  33. package/package.json +1 -1
  34. package/registry.json +44 -0
  35. package/src/components/composites/action-button/action-button.tsx +52 -11
  36. package/src/components/layout/orbit-layout/index.ts +8 -0
  37. package/src/components/layout/orbit-layout/orbit-layout.tsx +112 -0
  38. package/src/components/layout/virtual-window/index.ts +2 -0
  39. package/src/components/layout/virtual-window/virtual-window.tsx +55 -0
  40. package/src/components/ui/command/command.tsx +1 -0
  41. package/src/index.ts +2 -0
@@ -1 +1 @@
1
- {"version":3,"file":"action-button.d.ts","sourceRoot":"","sources":["../../../../src/components/composites/action-button/action-button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAyC,KAAK,GAAG,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAA;AAC/F,OAAO,EAAU,KAAK,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAI1D;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,iBAAiB,CAAC,CAAC,SAAS,cAAc,GAAG,QAAQ,IAAI,WAAW,CAAC,CAAC,CAAC,GAAG;IACpF,8FAA8F;IAC9F,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,WAAW,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAA;IACjD,uFAAuF;IACvF,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,uFAAuF;IACvF,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AA+BD,wBAAgB,YAAY,CAAC,CAAC,SAAS,cAAc,GAAG,QAAQ,EAAE,KAAK,EAAE,iBAAiB,CAAC,CAAC,CAAC,eAgF5F"}
1
+ {"version":3,"file":"action-button.d.ts","sourceRoot":"","sources":["../../../../src/components/composites/action-button/action-button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,GAAG,EACR,KAAK,cAAc,EACpB,MAAM,UAAU,CAAA;AACjB,OAAO,EAAU,KAAK,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAI1D;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,iBAAiB,CAAC,CAAC,SAAS,cAAc,GAAG,QAAQ,IAAI,WAAW,CAAC,CAAC,CAAC,GAAG;IACpF,8FAA8F;IAC9F,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,WAAW,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAA;IACjD,uFAAuF;IACvF,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,uFAAuF;IACvF,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AA+CD,wBAAgB,YAAY,CAAC,CAAC,SAAS,cAAc,GAAG,QAAQ,EAAE,KAAK,EAAE,iBAAiB,CAAC,CAAC,CAAC,eAkG5F"}
@@ -2,20 +2,30 @@ import { Button } from "../../ui/button/button.js";
2
2
  import { Tooltip, TooltipContent, TooltipTrigger } from "../../ui/tooltip/tooltip.js";
3
3
  import { Spinner } from "../../ui/spinner/spinner.js";
4
4
  import { createComponent, insert, memo, mergeProps, template } from "solid-js/web";
5
- import { Show, splitProps } from "solid-js";
5
+ import { Show, createSignal, splitProps } from "solid-js";
6
6
  //#region src/components/composites/action-button/action-button.tsx
7
7
  var _tmpl$ = /*#__PURE__*/ template(`<span role=status aria-live=polite class=visually-hidden>`);
8
- function guardedClick(handler, disabled) {
8
+ function invokeHandler(handler, event) {
9
+ if (Array.isArray(handler)) {
10
+ const [callback, data] = handler;
11
+ callback(data, event);
12
+ } else if (typeof handler === "function") handler(event);
13
+ }
14
+ function chainedHandler(handler, before) {
15
+ return (event) => {
16
+ before(event);
17
+ invokeHandler(handler, event);
18
+ };
19
+ }
20
+ function guardedClick(handler, disabled, onActivate = () => {}) {
9
21
  return (event) => {
10
22
  if (disabled()) {
11
23
  event.preventDefault();
12
24
  event.stopImmediatePropagation();
13
25
  return;
14
26
  }
15
- if (Array.isArray(handler)) {
16
- const [callback, data] = handler;
17
- callback(data, event);
18
- } else if (typeof handler === "function") handler(event);
27
+ onActivate(event);
28
+ invokeHandler(handler, event);
19
29
  };
20
30
  }
21
31
  /** Adapter keeps TooltipTrigger's `as` separate from Button's polymorphic `as`. */
@@ -42,6 +52,8 @@ function ActionButton(props) {
42
52
  const busy = () => local.busy ?? false;
43
53
  const disabled = () => busy() || !!local.disabled;
44
54
  const busyStatus = () => local.busyLabel ?? "Working";
55
+ const [tooltipOpen, setTooltipOpen] = createSignal(false);
56
+ const [tooltipSuppression, setTooltipSuppression] = createSignal(null);
45
57
  const onClickCapture = rest.onClickCapture;
46
58
  const PolymorphicButton = Button;
47
59
  const PolymorphicButtonTarget = ButtonTarget;
@@ -56,7 +68,17 @@ function ActionButton(props) {
56
68
  role: local.as === "a" && disabled() ? "link" : rest.role,
57
69
  href: local.as === "a" && disabled() ? void 0 : rest.href,
58
70
  "aria-busy": busy() || local["aria-busy"],
59
- onClick: guardedClick(rest.onClick, disabled),
71
+ onClick: guardedClick(rest.onClick, disabled, (event) => {
72
+ if (!local.tooltip) return;
73
+ setTooltipSuppression(event.detail > 0 ? "pointer" : "focus");
74
+ setTooltipOpen(false);
75
+ }),
76
+ onPointerLeave: chainedHandler(rest.onPointerLeave, () => {
77
+ if (tooltipSuppression() === "pointer") setTooltipSuppression(null);
78
+ }),
79
+ onBlur: chainedHandler(rest.onBlur, () => {
80
+ if (tooltipSuppression() === "focus") setTooltipSuppression(null);
81
+ }),
60
82
  onClickCapture: onClickCapture ? guardedClick(onClickCapture, disabled) : void 0,
61
83
  "on:click": guardedClick(rest["on:click"], disabled),
62
84
  "oncapture:click": guardedClick(rest["oncapture:click"], disabled)
@@ -86,23 +108,32 @@ function ActionButton(props) {
86
108
  } }));
87
109
  },
88
110
  get children() {
89
- return createComponent(Tooltip, { get children() {
90
- return [createComponent(TooltipTrigger, mergeProps({ as: PolymorphicButtonTarget }, () => buttonProps(), {
91
- get actionAs() {
92
- return local.as ?? "button";
93
- },
94
- get children() {
95
- return contents();
96
- }
97
- })), createComponent(TooltipContent, {
98
- get side() {
99
- return local.tooltipSide;
100
- },
101
- get children() {
102
- return local.tooltip;
103
- }
104
- })];
105
- } });
111
+ return createComponent(Tooltip, {
112
+ get open() {
113
+ return tooltipOpen();
114
+ },
115
+ onOpenChange: (open) => {
116
+ if (open && tooltipSuppression()) return;
117
+ setTooltipOpen(open);
118
+ },
119
+ get children() {
120
+ return [createComponent(TooltipTrigger, mergeProps({ as: PolymorphicButtonTarget }, () => buttonProps(), {
121
+ get actionAs() {
122
+ return local.as ?? "button";
123
+ },
124
+ get children() {
125
+ return contents();
126
+ }
127
+ })), createComponent(TooltipContent, {
128
+ get side() {
129
+ return local.tooltipSide;
130
+ },
131
+ get children() {
132
+ return local.tooltip;
133
+ }
134
+ })];
135
+ }
136
+ });
106
137
  }
107
138
  }), createComponent(Show, {
108
139
  get when() {
@@ -1 +1 @@
1
- {"version":3,"file":"action-button.js","names":["Show","splitProps","ComponentProps","JSX","ValidComponent","Button","ButtonProps","Spinner","Tooltip","TooltipContent","TooltipTrigger","ActionButtonProps","T","tooltip","tooltipSide","busy","busyLabel","guardedClick","handler","disabled","event","MouseEvent","preventDefault","stopImmediatePropagation","Array","isArray","callback","data","ButtonTargetProps","Omit","actionAs","ButtonTarget","props","local","rest","PolymorphicButton","targetProps","Element","_$createComponent","_$mergeProps","as","ActionButton","busyStatus","onClickCapture","buttonProps","PolymorphicButtonTarget","variant","size","class","filter","Boolean","join","tabIndex","role","href","undefined","onClick","Record","contents","when","children","label","_$memo","fallback","side","_el$","_tmpl$","_$insert","_$createComponent","PolymorphicButton","_$mergeProps","_$memo"],"sources":["../../../../src/components/composites/action-button/action-button.tsx"],"sourcesContent":["import { Show, splitProps, type ComponentProps, type JSX, type ValidComponent } from 'solid-js'\nimport { Button, type ButtonProps } from '../../ui/button'\nimport { Spinner } from '../../ui/spinner'\nimport { Tooltip, TooltipContent, TooltipTrigger } from '../../ui/tooltip'\n\n/**\n * ActionButton.\n *\n * A Button with optional explanatory tooltip and busy feedback. Use it for a\n * simple action that needs these states; actions with product-specific rules\n * should compose Button directly.\n *\n * The tooltip trigger renders the polymorphic Button itself. A disabled native\n * control cannot receive pointer or keyboard events. When a tooltip is set,\n * disabled actions therefore use focusable `aria-disabled` semantics and guard\n * activation; without a tooltip, native buttons retain native disabling.\n * Custom polymorphic components must forward aria, event, and href props for\n * these guarantees to apply.\n */\nexport type ActionButtonProps<T extends ValidComponent = 'button'> = ButtonProps<T> & {\n /** A short explanation, also shown on keyboard focus. The Button still needs its own name. */\n tooltip?: string\n tooltipSide?: 'top' | 'right' | 'bottom' | 'left'\n /** Disables the action and announces the busy label through a polite status region. */\n busy?: boolean\n /** The activity announced while busy. The Button's accessible name stays unchanged. */\n busyLabel?: string\n}\n\nfunction guardedClick(handler: unknown, disabled: () => boolean) {\n return (event: MouseEvent) => {\n if (disabled()) {\n event.preventDefault()\n event.stopImmediatePropagation()\n return\n }\n\n if (Array.isArray(handler)) {\n const [callback, data] = handler as [(data: unknown, event: MouseEvent) => void, unknown]\n callback(data, event)\n } else if (typeof handler === 'function') {\n const callback = handler as (event: MouseEvent) => void\n callback(event)\n }\n }\n}\n\ntype ButtonTargetProps<T extends ValidComponent = 'button'> = Omit<ButtonProps<T>, 'as'> & {\n actionAs?: T\n}\n\n/** Adapter keeps TooltipTrigger's `as` separate from Button's polymorphic `as`. */\nfunction ButtonTarget<T extends ValidComponent = 'button'>(props: ButtonTargetProps<T>) {\n const [local, rest] = splitProps(props as ButtonTargetProps, ['actionAs'])\n const PolymorphicButton = Button as (targetProps: ButtonProps<T>) => JSX.Element\n return <PolymorphicButton as={(local.actionAs ?? 'button') as T} {...(rest as ButtonProps<T>)} />\n}\n\nexport function ActionButton<T extends ValidComponent = 'button'>(props: ActionButtonProps<T>) {\n const [local, rest] = splitProps(props as ActionButtonProps, [\n 'as',\n 'variant',\n 'size',\n 'class',\n 'children',\n 'disabled',\n 'aria-busy',\n 'tooltip',\n 'tooltipSide',\n 'busy',\n 'busyLabel',\n ])\n const busy = () => local.busy ?? false\n const disabled = () => busy() || !!local.disabled\n const busyStatus = () => local.busyLabel ?? 'Working'\n const onClickCapture = (rest as { onClickCapture?: unknown }).onClickCapture\n const PolymorphicButton = Button as (buttonProps: ButtonProps<T>) => JSX.Element\n const PolymorphicButtonTarget = ButtonTarget as (targetProps: ButtonTargetProps<T>) => JSX.Element\n\n const buttonProps = () => ({\n ...rest,\n variant: local.variant,\n size: local.size,\n class: [local.class, local.tooltip && disabled() && 'aria-disabled:pointer-events-auto']\n .filter(Boolean)\n .join(' '),\n disabled: disabled() && !local.tooltip,\n 'aria-disabled': disabled() ? true : rest['aria-disabled'],\n tabIndex: local.as === 'a' && disabled() ? (local.tooltip ? 0 : -1) : rest.tabIndex,\n role: local.as === 'a' && disabled() ? 'link' : rest.role,\n href: local.as === 'a' && disabled() ? undefined : (rest as { href?: string }).href,\n 'aria-busy': busy() || local['aria-busy'],\n onClick: guardedClick(rest.onClick, disabled),\n onClickCapture: onClickCapture ? guardedClick(onClickCapture, disabled) : undefined,\n 'on:click': guardedClick((rest as Record<string, unknown>)['on:click'], disabled),\n 'oncapture:click': guardedClick((rest as Record<string, unknown>)['oncapture:click'], disabled),\n })\n\n const contents = () => (\n <>\n <Show when={busy()}>\n <Spinner size=\"sm\" label={false} aria-hidden=\"true\" data-icon=\"inline-start\" />\n </Show>\n {local.children}\n </>\n )\n\n return (\n <>\n <Show\n when={local.tooltip}\n fallback={\n <PolymorphicButton\n as={(local.as ?? 'button') as T}\n {...(buttonProps() as unknown as ButtonProps<T>)}\n >\n {contents()}\n </PolymorphicButton>\n }\n >\n <Tooltip>\n <TooltipTrigger\n as={PolymorphicButtonTarget}\n {...(buttonProps() as unknown as ComponentProps<typeof PolymorphicButtonTarget>)}\n actionAs={(local.as ?? 'button') as T}\n >\n {contents()}\n </TooltipTrigger>\n <TooltipContent side={local.tooltipSide}>{local.tooltip}</TooltipContent>\n </Tooltip>\n </Show>\n <Show when={busy()}>\n <span role=\"status\"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MAAA,OAAGG,MAAMO,MAAM;KAAc;KAAA,IAAAoB,WAAA;MAAA,OAEpCF,SAAS;KAAC;IAAA,CAAA,CAAA,GAAApB,gBAEZ7B,gBAAc;KAAA,IAACuD,OAAI;MAAA,OAAE/B,MAAMnB;KAAW;KAAA,IAAA8C,WAAA;MAAA,OAAG3B,MAAMpB;KAAO;IAAA,CAAA,CAAA;GAAA,EAAA,CAAA;EAAA;CAAA,CAAA,GAAAyB,gBAG1DtC,MAAI;EAAA,IAAC2D,OAAI;GAAA,OAAE5C,KAAK;EAAC;EAAA,IAAA6C,WAAA;GAAA,IAAAK,OAAAC,OAAA;GAAAC,OAAAF,MAEbvB,UAAU;GAAA,OAAAuB;EAAA;CAAA,CAAA,CAAA;AAKrB"}
1
+ {"version":3,"file":"action-button.js","names":["Show","createSignal","splitProps","ComponentProps","JSX","ValidComponent","Button","ButtonProps","Spinner","Tooltip","TooltipContent","TooltipTrigger","ActionButtonProps","T","tooltip","tooltipSide","busy","busyLabel","invokeHandler","handler","event","Event","Array","isArray","callback","data","chainedHandler","before","guardedClick","disabled","onActivate","MouseEvent","preventDefault","stopImmediatePropagation","ButtonTargetProps","Omit","actionAs","ButtonTarget","props","local","rest","PolymorphicButton","targetProps","Element","_$createComponent","_$mergeProps","as","ActionButton","busyStatus","tooltipOpen","setTooltipOpen","tooltipSuppression","setTooltipSuppression","onClickCapture","buttonProps","PolymorphicButtonTarget","variant","size","class","filter","Boolean","join","tabIndex","role","href","undefined","onClick","detail","onPointerLeave","onBlur","Record","contents","when","children","label","_$memo","fallback","open","onOpenChange","side","_el$","_tmpl$","_$insert","_$createComponent","PolymorphicButton","_$mergeProps","_$memo"],"sources":["../../../../src/components/composites/action-button/action-button.tsx"],"sourcesContent":["import {\n Show,\n createSignal,\n splitProps,\n type ComponentProps,\n type JSX,\n type ValidComponent,\n} from 'solid-js'\nimport { Button, type ButtonProps } from '../../ui/button'\nimport { Spinner } from '../../ui/spinner'\nimport { Tooltip, TooltipContent, TooltipTrigger } from '../../ui/tooltip'\n\n/**\n * ActionButton.\n *\n * A Button with optional explanatory tooltip and busy feedback. Use it for a\n * simple action that needs these states; actions with product-specific rules\n * should compose Button directly.\n *\n * The tooltip trigger renders the polymorphic Button itself. A disabled native\n * control cannot receive pointer or keyboard events. When a tooltip is set,\n * disabled actions therefore use focusable `aria-disabled` semantics and guard\n * activation; without a tooltip, native buttons retain native disabling.\n * Custom polymorphic components must forward aria, event, and href props for\n * these guarantees to apply.\n */\nexport type ActionButtonProps<T extends ValidComponent = 'button'> = ButtonProps<T> & {\n /** A short explanation, also shown on keyboard focus. The Button still needs its own name. */\n tooltip?: string\n tooltipSide?: 'top' | 'right' | 'bottom' | 'left'\n /** Disables the action and announces the busy label through a polite status region. */\n busy?: boolean\n /** The activity announced while busy. The Button's accessible name stays unchanged. */\n busyLabel?: string\n}\n\nfunction invokeHandler(handler: unknown, event: Event) {\n if (Array.isArray(handler)) {\n const [callback, data] = handler as [(data: unknown, event: Event) => void, unknown]\n callback(data, event)\n } else if (typeof handler === 'function') {\n const callback = handler as (event: Event) => void\n callback(event)\n }\n}\n\nfunction chainedHandler(handler: unknown, before: (event: Event) => void) {\n return (event: Event) => {\n before(event)\n invokeHandler(handler, event)\n }\n}\n\nfunction guardedClick(\n handler: unknown,\n disabled: () => boolean,\n onActivate: (event: MouseEvent) => void = () => {}\n) {\n return (event: MouseEvent) => {\n if (disabled()) {\n event.preventDefault()\n event.stopImmediatePropagation()\n return\n }\n\n onActivate(event)\n invokeHandler(handler, event)\n }\n}\n\ntype ButtonTargetProps<T extends ValidComponent = 'button'> = Omit<ButtonProps<T>, 'as'> & {\n actionAs?: T\n}\n\n/** Adapter keeps TooltipTrigger's `as` separate from Button's polymorphic `as`. */\nfunction ButtonTarget<T extends ValidComponent = 'button'>(props: ButtonTargetProps<T>) {\n const [local, rest] = splitProps(props as ButtonTargetProps, ['actionAs'])\n const PolymorphicButton = Button as (targetProps: ButtonProps<T>) => JSX.Element\n return <PolymorphicButton as={(local.actionAs ?? 'button') as T} {...(rest as ButtonProps<T>)} />\n}\n\nexport function ActionButton<T extends ValidComponent = 'button'>(props: ActionButtonProps<T>) {\n const [local, rest] = splitProps(props as ActionButtonProps, [\n 'as',\n 'variant',\n 'size',\n 'class',\n 'children',\n 'disabled',\n 'aria-busy',\n 'tooltip',\n 'tooltipSide',\n 'busy',\n 'busyLabel',\n ])\n const busy = () => local.busy ?? false\n const disabled = () => busy() || !!local.disabled\n const busyStatus = () => local.busyLabel ?? 'Working'\n const [tooltipOpen, setTooltipOpen] = createSignal(false)\n const [tooltipSuppression, setTooltipSuppression] = createSignal<'pointer' | 'focus' | null>(null)\n const onClickCapture = (rest as { onClickCapture?: unknown }).onClickCapture\n const PolymorphicButton = Button as (buttonProps: ButtonProps<T>) => JSX.Element\n const PolymorphicButtonTarget = ButtonTarget as (targetProps: ButtonTargetProps<T>) => JSX.Element\n\n const buttonProps = () => ({\n ...rest,\n variant: local.variant,\n size: local.size,\n class: [local.class, local.tooltip && disabled() && 'aria-disabled:pointer-events-auto']\n .filter(Boolean)\n .join(' '),\n disabled: disabled() && !local.tooltip,\n 'aria-disabled': disabled() ? true : rest['aria-disabled'],\n tabIndex: local.as === 'a' && disabled() ? (local.tooltip ? 0 : -1) : rest.tabIndex,\n role: local.as === 'a' && disabled() ? 'link' : rest.role,\n href: local.as === 'a' && disabled() ? undefined : (rest as { href?: string }).href,\n 'aria-busy': busy() || local['aria-busy'],\n onClick: guardedClick(rest.onClick, disabled, (event) => {\n if (!local.tooltip) return\n setTooltipSuppression(event.detail > 0 ? 'pointer' : 'focus')\n setTooltipOpen(false)\n }),\n onPointerLeave: chainedHandler(rest.onPointerLeave, () => {\n if (tooltipSuppression() === 'pointer') setTooltipSuppression(null)\n }),\n onBlur: chainedHandler(rest.onBlur, () => {\n if (tooltipSuppression() === 'focus') setTooltipSuppression(null)\n }),\n onClickCapture: onClickCapture ? guardedClick(onClickCapture, disabled) : undefined,\n 'on:click': guardedClick((rest as Record<string, unknown>)['on:click'], disabled),\n 'oncapture:click': guardedClick((rest as Record<string, unknown>)['oncapture:click'], disabled),\n })\n\n const contents = () => (\n <>\n <Show when={busy()}>\n <Spinner size=\"sm\" label={false} aria-hidden=\"true\" data-icon=\"inline-start\" />\n </Show>\n {local.children}\n </>\n )\n\n return (\n <>\n <Show\n when={local.tooltip}\n fallback={\n <PolymorphicButton\n as={(local.as ?? 'button') as T}\n {...(buttonProps() as unknown as ButtonProps<T>)}\n >\n {contents()}\n </PolymorphicButton>\n }\n >\n <Tooltip\n open={tooltipOpen()}\n onOpenChange={(open) => {\n if (open && tooltipSuppression()) return\n setTooltipOpen(open)\n }}\n >\n <TooltipTrigger\n as={PolymorphicButtonTarget}\n {...(buttonProps() as unknown as ComponentProps<typeof PolymorphicButtonTarget>)}\n actionAs={(local.as ?? 'button') as T}\n >\n {contents()}\n </TooltipTrigger>\n <TooltipContent side={local.tooltipSide}>{local.tooltip}</TooltipContent>\n </Tooltip>\n </Show>\n <Show when={busy()}>\n <span role=\"status\" aria-live=\"polite\" class=\"visually-hidden\">\n {busyStatus()}\n </span>\n </Show>\n </>\n )\n}\n"],"mappings":";;;;;;;AAoCA,SAASkB,cAAcC,SAAkBC,OAAc;CACrD,IAAIE,MAAMC,QAAQJ,OAAO,GAAG;EAC1B,MAAM,CAACK,UAAUC,QAAQN;EACzBK,SAASC,MAAML,KAAK;CACtB,OAAO,IAAI,OAAOD,YAAY,YAE5BK,QAASJ,KAAK;AAElB;AAEA,SAASM,eAAeP,SAAkBQ,QAAgC;CACxE,QAAQP,UAAiB;EACvBO,OAAOP,KAAK;EACZF,cAAcC,SAASC,KAAK;CAC9B;AACF;AAEA,SAASQ,aACPT,SACAU,UACAC,mBAAgD,CAAC,GACjD;CACA,QAAQV,UAAsB;EAC5B,IAAIS,SAAS,GAAG;GACdT,MAAMY,eAAe;GACrBZ,MAAMa,yBAAyB;GAC/B;EACF;EAEAH,WAAWV,KAAK;EAChBF,cAAcC,SAASC,KAAK;CA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ACtB,IAAIA,QAAQ1B,mBAAmB,GAAG;KAClCD,eAAe2B,IAAI;IACrB;IAAC,IAAAJ,WAAA;KAAA,OAAA,CAAA7B,gBAEAjC,gBAAckC,WAAA,EACbC,IAAIS,wBAAuB,SACtBD,YAAY,GAA8D;MAAA,IAC/ElB,WAAQ;OAAA,OAAGG,MAAMO,MAAM;MAAc;MAAA,IAAA2B,WAAA;OAAA,OAEpCF,SAAS;MAAC;KAAA,CAAA,CAAA,GAAA3B,gBAEZlC,gBAAc;MAAA,IAACqE,OAAI;OAAA,OAAExC,MAAMxB;MAAW;MAAA,IAAA0D,WAAA;OAAA,OAAGlC,MAAMzB;MAAO;KAAA,CAAA,CAAA;IAAA;GAAA,CAAA;EAAA;CAAA,CAAA,GAAA8B,gBAG1D5C,MAAI;EAAA,IAACwE,OAAI;GAAA,OAAExD,KAAK;EAAC;EAAA,IAAAyD,WAAA;GAAA,IAAAO,OAAAC,OAAA;GAAAC,OAAAF,MAEbhC,UAAU;GAAA,OAAAgC;EAAA;CAAA,CAAA,CAAA;AAKrB"}
@@ -0,0 +1,3 @@
1
+ /** Geometry-only wrappers for arranging content around a circle. */
2
+ export { OrbitItem, OrbitLayout, type OrbitItemProps, type OrbitLayoutProps, type OrbitRadius, } from './orbit-layout';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/orbit-layout/index.ts"],"names":[],"mappings":"AAAA,oEAAoE;AACpE,OAAO,EACL,SAAS,EACT,WAAW,EACX,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,WAAW,GACjB,MAAM,gBAAgB,CAAA"}
@@ -0,0 +1,2 @@
1
+ import { OrbitItem, OrbitLayout } from "./orbit-layout.js";
2
+ export { OrbitItem, OrbitLayout };
@@ -0,0 +1,38 @@
1
+ import type { ComponentProps } from 'solid-js';
2
+ /** A CSS length or expression used to place an item away from the orbit center. */
3
+ export type OrbitRadius = number | string;
4
+ export type OrbitLayoutMode = 'radial' | 'flow';
5
+ /**
6
+ * OrbitLayout.
7
+ *
8
+ * Provides a positioned canvas and a shared radius for its OrbitItems. It does
9
+ * not assign list semantics or alter DOM order: callers choose semantics, and
10
+ * keyboard and screen-reader order remain the source order of the children.
11
+ */
12
+ export type OrbitLayoutProps = Omit<ComponentProps<'div'>, 'style'> & {
13
+ /** JSX style props are owned by this geometry primitive. */
14
+ style?: never;
15
+ /** Responsive radius used by every OrbitItem unless that item overrides it. */
16
+ radius?: OrbitRadius;
17
+ /** `flow` places items in source order; `radial` positions them around the host. */
18
+ mode?: OrbitLayoutMode;
19
+ };
20
+ export declare function OrbitLayout(props: OrbitLayoutProps): import("solid-js").JSX.Element;
21
+ /**
22
+ * OrbitItem.
23
+ *
24
+ * Positions one ordinary child around its OrbitLayout. This is geometry only:
25
+ * the wrapper has no role, tabindex, or interaction of its own.
26
+ */
27
+ export type OrbitItemProps = Omit<ComponentProps<'div'>, 'style'> & {
28
+ /** JSX style props are owned by this geometry primitive. */
29
+ style?: never;
30
+ /** Zero-based position in the rendered sequence. */
31
+ index: number;
32
+ /** Number of items sharing this orbit. */
33
+ count: number;
34
+ /** Per-item override for OrbitLayout's responsive radius. */
35
+ radius?: OrbitRadius;
36
+ };
37
+ export declare function OrbitItem(props: OrbitItemProps): import("solid-js").JSX.Element;
38
+ //# sourceMappingURL=orbit-layout.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"orbit-layout.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/orbit-layout/orbit-layout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAI9C,mFAAmF;AACnF,MAAM,MAAM,WAAW,GAAG,MAAM,GAAG,MAAM,CAAA;AACzC,MAAM,MAAM,eAAe,GAAG,QAAQ,GAAG,MAAM,CAAA;AAW/C;;;;;;GAMG;AACH,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC,GAAG;IACpE,4DAA4D;IAC5D,KAAK,CAAC,EAAE,KAAK,CAAA;IACb,+EAA+E;IAC/E,MAAM,CAAC,EAAE,WAAW,CAAA;IACpB,oFAAoF;IACpF,IAAI,CAAC,EAAE,eAAe,CAAA;CACvB,CAAA;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,gBAAgB,kCAkBlD;AAED;;;;;GAKG;AACH,MAAM,MAAM,cAAc,GAAG,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC,GAAG;IAClE,4DAA4D;IAC5D,KAAK,CAAC,EAAE,KAAK,CAAA;IACb,oDAAoD;IACpD,KAAK,EAAE,MAAM,CAAA;IACb,0CAA0C;IAC1C,KAAK,EAAE,MAAM,CAAA;IACb,6DAA6D;IAC7D,MAAM,CAAC,EAAE,WAAW,CAAA;CACrB,CAAA;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,kCAyC9C"}
@@ -0,0 +1,83 @@
1
+ import { cn } from "../../../lib/utils.js";
2
+ import { createComponent, insert, mergeProps, spread, template } from "solid-js/web";
3
+ import { createContext, createMemo, splitProps, useContext } from "solid-js";
4
+ //#region src/components/layout/orbit-layout/orbit-layout.tsx
5
+ var _tmpl$ = /*#__PURE__*/ template(`<div>`);
6
+ var DEFAULT_ORBIT_RADIUS = "calc(50% - 2rem)";
7
+ var OrbitRadiusContext = createContext();
8
+ var OrbitModeContext = createContext();
9
+ function resolveRadius(radius) {
10
+ if (typeof radius === "number") return `${Number.isFinite(radius) ? Math.max(0, radius) : 0}px`;
11
+ return radius?.trim() || DEFAULT_ORBIT_RADIUS;
12
+ }
13
+ function OrbitLayout(props) {
14
+ const [local, rest] = splitProps(props, [
15
+ "class",
16
+ "radius",
17
+ "mode",
18
+ "style",
19
+ "children"
20
+ ]);
21
+ const radius = createMemo(() => resolveRadius(local.radius));
22
+ const mode = createMemo(() => local.mode ?? "radial");
23
+ return createComponent(OrbitRadiusContext.Provider, {
24
+ value: radius,
25
+ get children() {
26
+ return createComponent(OrbitModeContext.Provider, {
27
+ value: mode,
28
+ get children() {
29
+ var _el$ = _tmpl$();
30
+ spread(_el$, mergeProps(rest, {
31
+ "data-slot": "orbit-layout",
32
+ get ["class"]() {
33
+ return cn(mode() === "flow" ? "grid gap-3" : "relative size-full", local.class);
34
+ }
35
+ }), false, true);
36
+ insert(_el$, () => local.children);
37
+ return _el$;
38
+ }
39
+ });
40
+ }
41
+ });
42
+ }
43
+ function OrbitItem(props) {
44
+ const [local, rest] = splitProps(props, [
45
+ "class",
46
+ "index",
47
+ "count",
48
+ "radius",
49
+ "style",
50
+ "children"
51
+ ]);
52
+ const inheritedRadius = useContext(OrbitRadiusContext);
53
+ const inheritedMode = useContext(OrbitModeContext);
54
+ const mode = () => inheritedMode?.() ?? "radial";
55
+ const radius = () => local.radius !== void 0 ? resolveRadius(local.radius) : inheritedRadius?.() ?? DEFAULT_ORBIT_RADIUS;
56
+ const angle = createMemo(() => {
57
+ const count = Number.isFinite(local.count) ? Math.max(1, Math.trunc(local.count)) : 1;
58
+ return `${((Number.isFinite(local.index) ? Math.trunc(local.index) : 0) % count + count) % count / count * Math.PI * 2}rad`;
59
+ });
60
+ const positionStyle = () => mode() === "flow" ? void 0 : {
61
+ top: `calc(50% + sin(${angle()}) * ${radius()})`,
62
+ left: `calc(50% + cos(${angle()}) * ${radius()})`,
63
+ translate: "-50% -50%"
64
+ };
65
+ return (() => {
66
+ var _el$2 = _tmpl$();
67
+ spread(_el$2, mergeProps(rest, {
68
+ "data-slot": "orbit-item",
69
+ get ["class"]() {
70
+ return cn(mode() === "flow" ? void 0 : "absolute", local.class);
71
+ },
72
+ get style() {
73
+ return positionStyle();
74
+ }
75
+ }), false, true);
76
+ insert(_el$2, () => local.children);
77
+ return _el$2;
78
+ })();
79
+ }
80
+ //#endregion
81
+ export { OrbitItem, OrbitLayout };
82
+
83
+ //# sourceMappingURL=orbit-layout.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"orbit-layout.js","names":["ComponentProps","createContext","createMemo","splitProps","useContext","Accessor","cn","OrbitRadius","OrbitLayoutMode","DEFAULT_ORBIT_RADIUS","OrbitRadiusContext","OrbitModeContext","resolveRadius","radius","Number","isFinite","Math","max","trim","OrbitLayoutProps","Omit","style","mode","OrbitLayout","props","local","rest","_$createComponent","Provider","value","children","_el$","_tmpl$","_$spread","_$mergeProps","class","_$insert","OrbitItemProps","index","count","OrbitItem","inheritedRadius","inheritedMode","undefined","angle","trunc","rawIndex","PI","positionStyle","top","left","translate","_el$2","_$createComponent","_$mergeProps"],"sources":["../../../../src/components/layout/orbit-layout/orbit-layout.tsx"],"sourcesContent":["import type { ComponentProps } from 'solid-js'\nimport { createContext, createMemo, splitProps, useContext, type Accessor } from 'solid-js'\nimport { cn } from '#lib/utils'\n\n/** A CSS length or expression used to place an item away from the orbit center. */\nexport type OrbitRadius = number | string\nexport type OrbitLayoutMode = 'radial' | 'flow'\n\nconst DEFAULT_ORBIT_RADIUS = 'calc(50% - 2rem)'\nconst OrbitRadiusContext = createContext<Accessor<string>>()\nconst OrbitModeContext = createContext<Accessor<OrbitLayoutMode>>()\n\nfunction resolveRadius(radius: OrbitRadius | undefined): string {\n if (typeof radius === 'number') return `${Number.isFinite(radius) ? Math.max(0, radius) : 0}px`\n return radius?.trim() || DEFAULT_ORBIT_RADIUS\n}\n\n/**\n * OrbitLayout.\n *\n * Provides a positioned canvas and a shared radius for its OrbitItems. It does\n * not assign list semantics or alter DOM order: callers choose semantics, and\n * keyboard and screen-reader order remain the source order of the children.\n */\nexport type OrbitLayoutProps = Omit<ComponentProps<'div'>, 'style'> & {\n /** JSX style props are owned by this geometry primitive. */\n style?: never\n /** Responsive radius used by every OrbitItem unless that item overrides it. */\n radius?: OrbitRadius\n /** `flow` places items in source order; `radial` positions them around the host. */\n mode?: OrbitLayoutMode\n}\n\nexport function OrbitLayout(props: OrbitLayoutProps) {\n const [local, rest] = splitProps(props, ['class', 'radius', 'mode', 'style', 'children'])\n const radius = createMemo(() => resolveRadius(local.radius))\n const mode = createMemo(() => local.mode ?? 'radial')\n\n return (\n <OrbitRadiusContext.Provider value={radius}>\n <OrbitModeContext.Provider value={mode}>\n <div\n {...rest}\n data-slot=\"orbit-layout\"\n class={cn(mode() === 'flow' ? 'grid gap-3' : 'relative size-full', local.class)}\n >\n {local.children}\n </div>\n </OrbitModeContext.Provider>\n </OrbitRadiusContext.Provider>\n )\n}\n\n/**\n * OrbitItem.\n *\n * Positions one ordinary child around its OrbitLayout. This is geometry only:\n * the wrapper has no role, tabindex, or interaction of its own.\n */\nexport type OrbitItemProps = Omit<ComponentProps<'div'>, 'style'> & {\n /** JSX style props are owned by this geometry primitive. */\n style?: never\n /** Zero-based position in the rendered sequence. */\n index: number\n /** Number of items sharing this orbit. */\n count: number\n /** Per-item override for OrbitLayout's responsive radius. */\n radius?: OrbitRadius\n}\n\nexport function OrbitItem(props: OrbitItemProps) {\n const [local, rest] = splitProps(props, [\n 'class',\n 'index',\n 'count',\n 'radius',\n 'style',\n 'children',\n ])\n const inheritedRadius = useContext(OrbitRadiusContext)\n const inheritedMode = useContext(OrbitModeContext)\n const mode = () => inheritedMode?.() ?? 'radial'\n const radius = () =>\n local.radius !== undefined\n ? resolveRadius(local.radius)\n : (inheritedRadius?.() ?? DEFAULT_ORBIT_RADIUS)\n const angle = createMemo(() => {\n const count = Number.isFinite(local.count) ? Math.max(1, Math.trunc(local.count)) : 1\n const rawIndex = Number.isFinite(local.index) ? Math.trunc(local.index) : 0\n const index = ((rawIndex % count) + count) % count\n return `${(index / count) * Math.PI * 2}rad`\n })\n const positionStyle = () =>\n mode() === 'flow'\n ? undefined\n : {\n top: `calc(50% + sin(${angle()}) * ${radius()})`,\n left: `calc(50% + cos(${angle()}) * ${radius()})`,\n translate: '-50% -50%',\n }\n\n return (\n <div\n {...rest}\n data-slot=\"orbit-item\"\n class={cn(mode() === 'flow' ? undefined : 'absolute', local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AK;CACxC,MAAM7B,eACJY,MAAMZ,WAAW8B,KAAAA,IACb/B,cAAca,MAAMZ,MAAM,IACzB4B,kBAAkB,KAAKhC;CAC9B,MAAMmC,QAAQ1C,iBAAiB;EAC7B,MAAMqC,QAAQzB,OAAOC,SAASU,MAAMc,KAAK,IAAIvB,KAAKC,IAAI,GAAGD,KAAK6B,MAAMpB,MAAMc,KAAK,CAAC,IAAI;EAGpF,OAAO,KAFUzB,OAAOC,SAASU,MAAMa,KAAK,IAAItB,KAAK6B,MAAMpB,MAAMa,KAAK,IAAI,KAC/CC,QAASA,SAASA,QAC1BA,QAASvB,KAAK+B,KAAK,EAAC;CACzC,CAAC;CACD,MAAMC,sBACJ1B,KAAK,MAAM,SACPqB,KAAAA,IACA;EACEM,KAAK,kBAAkBL,MAAM,EAAC,MAAO/B,OAAO,EAAC;EAC7CqC,MAAM,kBAAkBN,MAAM,EAAC,MAAO/B,OAAO,EAAC;EAC9CsC,WAAW;CACb;CAEN,cAAA;EAAA,IAAAC,QAAApB,OAAA;EAAAC,OAAAmB,OAAAlB,WAEQR,MAAI;GAAA,aACE;GAAY,KAAA,WAAA;IAAA,OACfpB,GAAGgB,KAAK,MAAM,SAASqB,KAAAA,IAAY,YAAYlB,MAAMU,KAAK;GAAC;GAAA,IAClEd,QAAK;IAAA,OAAE2B,cAAc;GAAC;EAAA,CAAA,GAAA,OAAA,IAAA;EAAAZ,OAAAgB,aAErB3B,MAAMK,QAAQ;EAAA,OAAAsB;CAAA,EAAA,CAAA;AAGrB"}
@@ -0,0 +1,3 @@
1
+ /** Geometry wrappers for a virtual list; scrolling and range ownership stay with the caller. */
2
+ export { VirtualWindow, type VirtualWindowProps } from './virtual-window';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/virtual-window/index.ts"],"names":[],"mappings":"AAAA,gGAAgG;AAChG,OAAO,EAAE,aAAa,EAAE,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAA"}
@@ -0,0 +1,2 @@
1
+ import { VirtualWindow } from "./virtual-window.js";
2
+ export { VirtualWindow };
@@ -0,0 +1,22 @@
1
+ import type { ComponentProps, JSX } from 'solid-js';
2
+ /**
3
+ * VirtualWindow.
4
+ *
5
+ * Supplies the two geometry wrappers a virtualized viewport needs: a full-height
6
+ * scroll space and a translated window containing the mounted rows. The caller
7
+ * owns the scroll region, its semantics, keyboard model, and range calculation;
8
+ * this component only keeps those rows at their measured position.
9
+ */
10
+ export type VirtualWindowProps = Omit<ComponentProps<'div'>, 'children' | 'style'> & {
11
+ /** JSX style props are owned by this geometry primitive. */
12
+ style?: never;
13
+ /** The full scrollable height, in pixels. */
14
+ totalSize: number;
15
+ /** The mounted window's top offset from the start of the full list, in pixels. */
16
+ offset?: number;
17
+ /** Optional layout classes for the translated row container. */
18
+ contentClass?: string;
19
+ children?: JSX.Element;
20
+ };
21
+ export declare function VirtualWindow(props: VirtualWindowProps): JSX.Element;
22
+ //# sourceMappingURL=virtual-window.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"virtual-window.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/virtual-window/virtual-window.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,UAAU,CAAA;AAInD;;;;;;;GAOG;AACH,MAAM,MAAM,kBAAkB,GAAG,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE,UAAU,GAAG,OAAO,CAAC,GAAG;IACnF,4DAA4D;IAC5D,KAAK,CAAC,EAAE,KAAK,CAAA;IACb,6CAA6C;IAC7C,SAAS,EAAE,MAAM,CAAA;IACjB,kFAAkF;IAClF,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,gEAAgE;IAChE,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;CACvB,CAAA;AAMD,wBAAgB,aAAa,CAAC,KAAK,EAAE,kBAAkB,eA0BtD"}
@@ -0,0 +1,45 @@
1
+ import { cn } from "../../../lib/utils.js";
2
+ import { className, effect, insert, mergeProps, setStyleProperty, spread, template } from "solid-js/web";
3
+ import { splitProps } from "solid-js";
4
+ //#region src/components/layout/virtual-window/virtual-window.tsx
5
+ var _tmpl$ = /*#__PURE__*/ template(`<div><div data-slot=virtual-window-content>`);
6
+ function finitePixels(value) {
7
+ return `${Number.isFinite(value) ? value : 0}px`;
8
+ }
9
+ function VirtualWindow(props) {
10
+ const [local, rest] = splitProps(props, [
11
+ "class",
12
+ "children",
13
+ "totalSize",
14
+ "offset",
15
+ "contentClass",
16
+ "style"
17
+ ]);
18
+ return (() => {
19
+ var _el$ = _tmpl$(), _el$2 = _el$.firstChild;
20
+ spread(_el$, mergeProps(rest, {
21
+ "data-slot": "virtual-window-space",
22
+ get ["class"]() {
23
+ return cn("relative", local.class);
24
+ },
25
+ get style() {
26
+ return { height: finitePixels(Math.max(0, local.totalSize)) };
27
+ }
28
+ }), false, true);
29
+ insert(_el$2, () => local.children);
30
+ effect((_p$) => {
31
+ var _v$ = local.contentClass, _v$2 = `translateY(${finitePixels(local.offset ?? 0)})`;
32
+ _v$ !== _p$.e && className(_el$2, _p$.e = _v$);
33
+ _v$2 !== _p$.t && setStyleProperty(_el$2, "transform", _p$.t = _v$2);
34
+ return _p$;
35
+ }, {
36
+ e: void 0,
37
+ t: void 0
38
+ });
39
+ return _el$;
40
+ })();
41
+ }
42
+ //#endregion
43
+ export { VirtualWindow };
44
+
45
+ //# sourceMappingURL=virtual-window.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"virtual-window.js","names":["ComponentProps","JSX","splitProps","cn","VirtualWindowProps","Omit","style","totalSize","offset","contentClass","children","Element","finitePixels","value","Number","isFinite","VirtualWindow","props","local","rest","_el$","_tmpl$","_el$2","firstChild","_$spread","_$mergeProps","class","height","Math","max","_$insert","_$effect","_p$","_v$","_v$2","e","_$className","t","_$setStyleProperty","undefined","_$mergeProps","_$className","_$setStyleProperty"],"sources":["../../../../src/components/layout/virtual-window/virtual-window.tsx"],"sourcesContent":["import type { ComponentProps, JSX } from 'solid-js'\nimport { splitProps } from 'solid-js'\nimport { cn } from '#lib/utils'\n\n/**\n * VirtualWindow.\n *\n * Supplies the two geometry wrappers a virtualized viewport needs: a full-height\n * scroll space and a translated window containing the mounted rows. The caller\n * owns the scroll region, its semantics, keyboard model, and range calculation;\n * this component only keeps those rows at their measured position.\n */\nexport type VirtualWindowProps = Omit<ComponentProps<'div'>, 'children' | 'style'> & {\n /** JSX style props are owned by this geometry primitive. */\n style?: never\n /** The full scrollable height, in pixels. */\n totalSize: number\n /** The mounted window's top offset from the start of the full list, in pixels. */\n offset?: number\n /** Optional layout classes for the translated row container. */\n contentClass?: string\n children?: JSX.Element\n}\n\nfunction finitePixels(value: number): string {\n return `${Number.isFinite(value) ? value : 0}px`\n}\n\nexport function VirtualWindow(props: VirtualWindowProps) {\n const [local, rest] = splitProps(props, [\n 'class',\n 'children',\n 'totalSize',\n 'offset',\n 'contentClass',\n 'style',\n ])\n\n return (\n <div\n {...rest}\n data-slot=\"virtual-window-space\"\n class={cn('relative', local.class)}\n style={{ height: finitePixels(Math.max(0, local.totalSize)) }}\n >\n <div\n data-slot=\"virtual-window-content\"\n class={local.contentClass}\n style={{ transform: `translateY(${finitePixels(local.offset ?? 0)})` }}\n >\n {local.children}\n </div>\n </div>\n )\n}\n"],"mappings":";;;;;AAwBA,SAASY,aAAaC,OAAuB;CAC3C,OAAO,GAAGC,OAAOC,SAASF,KAAK,IAAIA,QAAQ,EAAC;AAC9C;AAEA,SAAgBG,cAAcC,OAA2B;CACvD,MAAM,CAACC,OAAOC,QAAQjB,WAAWe,OAAO;EACtC;EACA;EACA;EACA;EACA;EACA;CAAO,CACR;CAED,cAAA;EAAA,IAAAG,OAAAC,OAAA,GAAAC,QAAAF,KAAAG;EAAAC,OAAAJ,MAAAK,WAEQN,MAAI;GAAA,a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ialog(props) {
81
81
  return commandProps.label;
82
82
  },
83
83
  "cmdk-dialog": "",
84
+ role: "dialog",
84
85
  get ["class"]() {
85
86
  return cn("bg-popover text-popover-foreground fixed top-1/3 left-1/2 z-(--z-dialog) w-full max-w-lg -translate-x-1/2 -translate-y-1/2", "overflow-hidden rounded-xl border border-border shadow-xl", "data-expanded:animate-in data-expanded:fade-in-0 data-expanded:zoom-in-95", "data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", local.class, local.contentClassName);
86
87
  },
@@ -1 +1 @@
1
- {"version":3,"file":"command.js","names":["CommandDialog","CmdkDialog","CommandEmpty","CmdkEmpty","CommandGroup","CmdkGroup","CommandInput","CmdkInput","CommandItem","CmdkItem","CommandList","CmdkList","CommandLoading","CmdkLoading","CommandRoot","CmdkRoot","CommandSeparator","CmdkSeparator","useCommandState","Dialog","KobalteDialog","Search","ComponentProps","createEffect","createSignal","splitProps","createDialogFocusRestoration","menuItem","cn","commandItem","replace","Command","props","local","rest","_$createComponent","_$mergeProps","class","CommandDialogProps","Pick","Content","dialogProps","commandProps","isOpen","setIsOpen","open","defaultOpen","undefined","focus","onCloseAutoFocus","onOpenAutoFocus","onOpenChange","children","Portal","mount","container","Overlay","overlayClassName","aria-label","label","contentClassName","_el$","_tmpl$","_$insert","wrapper","setWrapper","HTMLDivElement","resultCount","state","filtered","count","root","selector","querySelector","setAttribute","_el$2","_tmpl$2","_$use","role","CommandShortcut","_el$3","_tmpl$3","_$effect","_$className","_$createComponent","CmdkRoot","_$mergeProps","KobalteDialog","CommandInput","CmdkInput","CommandList","CmdkList","CommandEmpty","CmdkEmpty","CommandGroup","CmdkGroup","CommandItem","CmdkItem","CommandSeparator","CmdkSeparator","CommandLoading","CmdkLoading","_$className"],"sources":["../../../../src/components/ui/command/command.tsx"],"sourcesContent":["import {\n CommandDialog as CmdkDialog,\n CommandEmpty as CmdkEmpty,\n CommandGroup as CmdkGroup,\n CommandInput as CmdkInput,\n CommandItem as CmdkItem,\n CommandList as CmdkList,\n CommandLoading as CmdkLoading,\n CommandRoot as CmdkRoot,\n CommandSeparator as CmdkSeparator,\n useCommandState,\n} from 'cmdk-solid'\nimport { Dialog as KobalteDialog } from '@kobalte/core/dialog'\nimport { Search } from 'lucide-solid'\nimport type { ComponentProps } from 'solid-js'\nimport { createEffect, createSignal, splitProps } from 'solid-js'\nimport { createDialogFocusRestoration } from '../dialog/dialog'\nimport { menuItem } from '#lib/overlay'\nimport { cn } from '#lib/utils'\n\n// cmdk emits data-disabled=\"false\" on enabled items, unlike the presence-only\n// attributes Kobalte menu rows use. Apply those shared disabled styles only when\n// cmdk's value is true.\nconst commandItem = menuItem\n .replace('data-[disabled]:pointer-events-none', '')\n .replace('data-[disabled]:text-muted-foreground', '')\n\n/**\n * Command.\n *\n * The command palette: a filtered list of everything the user can do, ranked\n * by fuzzy match. It is the one place in an app where a keyboard-first surface\n * is the *primary* one, so it carries rules the rest of the system does not:\n *\n * - Every item must be reachable by typing its name. If a user has to\n * remember which group it lives in, the palette has failed at its job.\n * - Groups exist for reading, not for navigation. The ranking crosses them.\n * - The empty state is not an apology — it should offer the closest thing\n * the app could guess, or say plainly that nothing matched.\n *\n * cmdk-solid supplies the filter, the scoring, the `aria-activedescendant`\n * wiring and the arrow-key navigation.\n */\nexport function Command(props: ComponentProps<typeof CmdkRoot>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkRoot\n class={cn(\n 'bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-xl',\n local.class\n )}\n {...rest}\n />\n )\n}\n\ntype CommandDialogProps = ComponentProps<typeof CmdkDialog> &\n Pick<ComponentProps<typeof KobalteDialog.Content>, 'onCloseAutoFocus' | 'onOpenAutoFocus'>\n\nexport function CommandDialog(props: CommandDialogProps) {\n // cmdk-solid's Dialog does not forward Content autofocus props: unknown\n // props fall through to its Command root. Compose Kobalte's dialog surface\n // here so Escape and other close paths can restore focus to the real opener.\n // Preserve the shared wrapper's `class` contract on the dialog surface;\n // `contentClassName` adds to it, while the nested Command keeps its own API.\n const [local, dialogProps, commandProps] = splitProps(\n props,\n [\n 'class',\n 'contentClassName',\n 'overlayClassName',\n 'container',\n 'onCloseAutoFocus',\n 'onOpenAutoFocus',\n ],\n [\n 'open',\n 'defaultOpen',\n 'onOpenChange',\n 'id',\n 'modal',\n 'preventScroll',\n 'forceMount',\n 'translations',\n ]\n )\n const [isOpen, setIsOpen] = createSignal(dialogProps.open ?? dialogProps.defaultOpen ?? false)\n\n createEffect(() => {\n if (dialogProps.open !== undefined) setIsOpen(dialogProps.open)\n })\n\n const focus = createDialogFocusRestoration({\n open: isOpen,\n onCloseAutoFocus: local.onCloseAutoFocus,\n onOpenAutoFocus: local.onOpenAutoFocus,\n })\n\n return (\n <KobalteDialog\n {...dialogProps}\n onOpenChange={(open) => {\n setIsOpen(open)\n dialogProps.onOpenChange?.(open)\n }}\n >\n <KobalteDialog.Portal mount={local.container}>\n <KobalteDialog.Overlay cmdk-overlay=\"\" class={local.overlayClassName} />\n <KobalteDialog.Content\n aria-label={commandProps.label}\n cmdk-dialog=\"\"\n class={cn(\n 'bg-popover text-popover-foreground fixed top-1/3 left-1/2 z-(--z-dialog) w-full max-w-lg -translate-x-1/2 -translate-y-1/2',\n 'overflow-hidden rounded-xl border border-border shadow-xl',\n 'data-expanded:animate-in data-expanded:fade-in-0 data-expanded:zoom-in-95',\n 'data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',\n local.class,\n local.contentClassName\n )}\n onOpenAutoFocus={focus.onOpenAutoFocus}\n onCloseAutoFocus={focus.onCloseAutoFocus}\n >\n <Command {...commandProps} />\n </KobalteDialog.Content>\n </KobalteDialog.Portal>\n </KobalteDialog>\n )\n}\n\nexport function CommandInput(props: ComponentProps<typeof CmdkInput>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <div\n data-slot=\"command-input-wrapper\"\n class=\"flex h-11 items-center gap-2 border-b border-border px-3\"\n >\n <Search class=\"size-4 shrink-0 text-muted-foreground\" aria-hidden=\"true\" />\n <CmdkInput\n class={cn(\n 'h-full w-full bg-transparent text-sm outline-none placeholder:text-muted-foreground',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n local.class\n )}\n {...rest}\n />\n </div>\n )\n}\n\n/**\n * The scrolling list.\n *\n * Two DOM corrections, and both are deliberate. cmdk builds a `role=\"listbox\"`\n * whose children include two elements ARIA does not allow there:\n *\n * - a bare `<div cmdk-list-sizer>` with no role, wrapped around every group;\n * - a `<div cmdk-separator role=\"separator\">`, and `separator` is a menu and\n * toolbar role — inside a listbox the only owned elements may be `option`\n * and `group`.\n *\n * Both are pure presentation: the sizer is layout, and the separator is a\n * hairline between groups that the groups already structure. `role=\"presentation\"`\n * is their accurate role rather than a workaround — each is flattened out of the\n * accessibility tree, and the options inside are reached exactly as before.\n *\n * Written onto the mounted nodes rather than through props, because cmdk owns\n * this markup and does not forward a `ref`; in an effect rather than `onMount`,\n * because cmdk renders the sizer with the first item, after the list itself.\n */\nexport function CommandList(props: ComponentProps<typeof CmdkList>) {\n const [local, rest] = splitProps(props, ['class'])\n const [wrapper, setWrapper] = createSignal<HTMLDivElement>()\n const resultCount = useCommandState((state) => state.filtered.count)\n\n createEffect(() => {\n const root = wrapper()\n if (!root) return\n for (const selector of ['[cmdk-list-sizer]', '[cmdk-separator]']) {\n root.querySelector(selector)?.setAttribute('role', 'presentation')\n }\n\n /*\n * A `listbox` must own at least one `option`, so a listbox with nothing in it\n * is invalid ARIA — which is what a search with no matches produces. When\n * there are no results the list is inert, so it becomes presentational and\n * the empty message carries the information instead. It keeps its `id`, so\n * the input's `aria-controls` still resolves.\n */\n root\n .querySelector('[cmdk-list]')\n ?.setAttribute('role', resultCount() > 0 ? 'listbox' : 'presentation')\n })\n\n return (\n <div ref={setWrapper} class=\"contents\">\n <CmdkList\n class={cn('max-h-80 scroll-py-1 overflow-y-auto overflow-x-hidden p-1', local.class)}\n {...rest}\n />\n </div>\n )\n}\n\nexport function CommandEmpty(props: ComponentProps<typeof CmdkEmpty>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkEmpty\n /*\n * A status rather than plain text: when the list is presentational, this is\n * the only thing that tells a screen reader the search matched nothing.\n */\n role=\"status\"\n class={cn('text-muted-foreground py-8 text-center text-sm', local.class)}\n {...rest}\n />\n )\n}\n\nexport function CommandGroup(props: ComponentProps<typeof CmdkGroup>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkGroup\n class={cn(\n 'text-foreground overflow-hidden p-1',\n '[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-2xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:tracking-wide [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group-heading]]:uppercase',\n local.class\n )}\n {...rest}\n />\n )\n}\n\nexport function CommandItem(props: ComponentProps<typeof CmdkItem>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkItem\n class={cn(\n commandItem,\n 'data-[disabled=true]:pointer-events-none data-[disabled=true]:text-muted-foreground',\n 'group/command-item text-popover-foreground data-[selected=true]:bg-card data-[selected=true]:text-popover-foreground',\n local.class\n )}\n {...rest}\n />\n )\n}\n\nexport function CommandSeparator(props: ComponentProps<typeof CmdkSeparator>) {\n const [local, rest] = splitProps(props, ['class'])\n return <CmdkSeparator class={cn('bg-border -mx-1 my-1 h-px', local.class)} {...rest} />\n}\n\nexport function CommandLoading(props: ComponentProps<typeof CmdkLoading>) {\n const [local, rest] = splitProps(props, ['class'])\n return (\n <CmdkLoading\n class={cn('text-muted-foreground py-6 text-center text-sm', local.class)}\n {...rest}\n />\n )\n}\n\n/** The keyboard hint a palette item usually carries. */\nexport function CommandShortcut(props: {\n class?: string\n children?: ComponentProps<'span'>['children']\n}) {\n return (\n <span\n class={cn(\n 'text-muted-foreground ms-auto font-mono text-2xs tracking-widest group-data-[selected=true]/command-item:text-foreground',\n props.class\n )}\n >\n {props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,SAAgBtB,iBAAeoB,OAA2C;CACxE,MAAM,CAACC,OAAOC,QAAQT,WAAWO,OAAO,CAAC,OAAO,CAAC;CACjD,OAAAG,gBACGtB,gBAAWuB,WAAA,EAAA,KAAA,WAAA;EAAA,OACHR,GAAG,kDAAkDK,MAAMI,KAAK;CAAC,EAAA,GACpEH,IAAI,CAAA;AAGd;;AAGA,SAAgB6C,gBAAgB/C,OAG7B;CACD,cAAA;EAAA,IAAAgD,QAAAC,QAAA;EAAAlB,OAAAiB,aAOKhD,MAAMoB,QAAQ;EAAA8B,aAAAC,UAAAH,OALRpD,GACL,4HACAI,MAAMK,KACR,CAAC,CAAA;EAAA,OAAA2C;CAAA,EAAA,CAAA;AAKP"}
1
+ {"version":3,"file":"command.js","names":["CommandDialog","CmdkDialog","CommandEmpty","CmdkEmpty","CommandGroup","CmdkGroup","CommandInput","CmdkInput","CommandItem","CmdkItem","CommandList","CmdkList","CommandLoading","CmdkLoading","CommandRoot","CmdkRoot","CommandSeparator","CmdkSeparator","useCommandState","Dialog","KobalteDialog","Search","ComponentProps","createEffect","createSignal","splitProps","createDialogFocusRestoration","menuItem","cn","commandItem","replace","Command","props","local","rest","_$createComponent","_$mergeProps","class","CommandDialogProps","Pick","Content","dialogProps","commandProps","isOpen","setIsOpen","open","defaultOpen","undefined","focus","onCloseAutoFocus","onOpenAutoFocus","onOpenChange","children","Portal","mount","container","Overlay","overlayClassName","aria-label","label","role","contentClassName","_el$","_tmpl$","_$insert","wrapper","setWrapper","HTMLDivElement","resultCount","state","filtered","count","root","selector","querySelector","setAttribute","_el$2","_tmpl$2","_$use","CommandShortcut","_el$3","_tmpl$3","_$effect","_$className","_$createComponent","CmdkRoot","_$mergeProps","KobalteDialog","CommandInput","CmdkInput","CommandList","CmdkList","CommandEmpty","CmdkEmpty","CommandGroup","CmdkGroup","CommandItem","CmdkItem","CommandSeparator","CmdkSeparator","CommandLoading","CmdkLoading","_$className"],"sources":["../../../../src/components/ui/command/command.tsx"],"sourcesContent":["import {\n CommandDialog as CmdkDialog,\n CommandEmpty as CmdkEmpty,\n CommandGroup as CmdkGroup,\n CommandInput as CmdkInput,\n CommandItem as CmdkItem,\n CommandList as CmdkList,\n CommandLoading as CmdkLoading,\n CommandRoot as CmdkRoot,\n CommandSeparator as CmdkSeparator,\n useCommandState,\n} from 'cmdk-solid'\nimport { Dialog as KobalteDialog } from '@kobalte/core/dialog'\nimport { Search } from 'lucide-solid'\nimport type { ComponentProps } from 'solid-js'\nimport { createEffect, createSignal, splitProps } from 'solid-js'\nimport { createDialogFocusRestoration } from '../dialog/dialog'\nimport { menuItem } from '#lib/overlay'\nimport { cn } from '#lib/utils'\n\n// cmdk emits data-disabled=\"false\" on enabled items, unlike the presence-only\n// attributes Kobalte menu rows use. Apply those shared disabled styles only when\n// cmdk's value is true.\nconst commandItem = menuItem\n .replace('data-[disabled]:pointer-events-none', '')\n .replace('data-[disabled]:text-muted-foreground', '')\n\n/**\n * Command.\n *\n * The command palette: a filtered list of everything the user can do, ranked\n * by fuzzy match. It is the one place in an app where a keyboard-first surface\n * is the *primary* one, so it carries rules the rest of the system does not:\n *\n * - Every item must be reachable by typing its name. If a user has to\n * remember which group it lives in, the palette has failed at its job.\n * - Groups exist for reading, not for navigation. The ranking crosses them.\n * - The empty state is not an apology — it should offer the closest thing\n * the app could guess, or say plainly that nothing matched.\n *\n * cmdk-solid supplies the filter, the scoring, the `aria-activedescendant`\n * wiring and the arrow-key navigation.\n */\nexport function Command(props: ComponentProps<typeof CmdkRoot>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkRoot\n class={cn(\n 'bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-xl',\n local.class\n )}\n {...rest}\n />\n )\n}\n\ntype CommandDialogProps = ComponentProps<typeof CmdkDialog> &\n Pick<ComponentProps<typeof KobalteDialog.Content>, 'onCloseAutoFocus' | 'onOpenAutoFocus'>\n\nexport function CommandDialog(props: CommandDialogProps) {\n // cmdk-solid's Dialog does not forward Content autofocus props: unknown\n // props fall through to its Command root. Compose Kobalte's dialog surface\n // here so Escape and other close paths can restore focus to the real opener.\n // Preserve the shared wrapper's `class` contract on the dialog surface;\n // `contentClassName` adds to it, while the nested Command keeps its own API.\n const [local, dialogProps, commandProps] = splitProps(\n props,\n [\n 'class',\n 'contentClassName',\n 'overlayClassName',\n 'container',\n 'onCloseAutoFocus',\n 'onOpenAutoFocus',\n ],\n [\n 'open',\n 'defaultOpen',\n 'onOpenChange',\n 'id',\n 'modal',\n 'preventScroll',\n 'forceMount',\n 'translations',\n ]\n )\n const [isOpen, setIsOpen] = createSignal(dialogProps.open ?? dialogProps.defaultOpen ?? false)\n\n createEffect(() => {\n if (dialogProps.open !== undefined) setIsOpen(dialogProps.open)\n })\n\n const focus = createDialogFocusRestoration({\n open: isOpen,\n onCloseAutoFocus: local.onCloseAutoFocus,\n onOpenAutoFocus: local.onOpenAutoFocus,\n })\n\n return (\n <KobalteDialog\n {...dialogProps}\n onOpenChange={(open) => {\n setIsOpen(open)\n dialogProps.onOpenChange?.(open)\n }}\n >\n <KobalteDialog.Portal mount={local.container}>\n <KobalteDialog.Overlay cmdk-overlay=\"\" class={local.overlayClassName} />\n <KobalteDialog.Content\n aria-label={commandProps.label}\n cmdk-dialog=\"\"\n role=\"dialog\"\n class={cn(\n 'bg-popover text-popover-foreground fixed top-1/3 left-1/2 z-(--z-dialog) w-full max-w-lg -translate-x-1/2 -translate-y-1/2',\n 'overflow-hidden rounded-xl border border-border shadow-xl',\n 'data-expanded:animate-in data-expanded:fade-in-0 data-expanded:zoom-in-95',\n 'data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',\n local.class,\n local.contentClassName\n )}\n onOpenAutoFocus={focus.onOpenAutoFocus}\n onCloseAutoFocus={focus.onCloseAutoFocus}\n >\n <Command {...commandProps} />\n </KobalteDialog.Content>\n </KobalteDialog.Portal>\n </KobalteDialog>\n )\n}\n\nexport function CommandInput(props: ComponentProps<typeof CmdkInput>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <div\n data-slot=\"command-input-wrapper\"\n class=\"flex h-11 items-center gap-2 border-b border-border px-3\"\n >\n <Search class=\"size-4 shrink-0 text-muted-foreground\" aria-hidden=\"true\" />\n <CmdkInput\n class={cn(\n 'h-full w-full bg-transparent text-sm outline-none placeholder:text-muted-foreground',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n local.class\n )}\n {...rest}\n />\n </div>\n )\n}\n\n/**\n * The scrolling list.\n *\n * Two DOM corrections, and both are deliberate. cmdk builds a `role=\"listbox\"`\n * whose children include two elements ARIA does not allow there:\n *\n * - a bare `<div cmdk-list-sizer>` with no role, wrapped around every group;\n * - a `<div cmdk-separator role=\"separator\">`, and `separator` is a menu and\n * toolbar role — inside a listbox the only owned elements may be `option`\n * and `group`.\n *\n * Both are pure presentation: the sizer is layout, and the separator is a\n * hairline between groups that the groups already structure. `role=\"presentation\"`\n * is their accurate role rather than a workaround — each is flattened out of the\n * accessibility tree, and the options inside are reached exactly as before.\n *\n * Written onto the mounted nodes rather than through props, because cmdk owns\n * this markup and does not forward a `ref`; in an effect rather than `onMount`,\n * because cmdk renders the sizer with the first item, after the list itself.\n */\nexport function CommandList(props: ComponentProps<typeof CmdkList>) {\n const [local, rest] = splitProps(props, ['class'])\n const [wrapper, setWrapper] = createSignal<HTMLDivElement>()\n const resultCount = useCommandState((state) => state.filtered.count)\n\n createEffect(() => {\n const root = wrapper()\n if (!root) return\n for (const selector of ['[cmdk-list-sizer]', '[cmdk-separator]']) {\n root.querySelector(selector)?.setAttribute('role', 'presentation')\n }\n\n /*\n * A `listbox` must own at least one `option`, so a listbox with nothing in it\n * is invalid ARIA — which is what a search with no matches produces. When\n * there are no results the list is inert, so it becomes presentational and\n * the empty message carries the information instead. It keeps its `id`, so\n * the input's `aria-controls` still resolves.\n */\n root\n .querySelector('[cmdk-list]')\n ?.setAttribute('role', resultCount() > 0 ? 'listbox' : 'presentation')\n })\n\n return (\n <div ref={setWrapper} class=\"contents\">\n <CmdkList\n class={cn('max-h-80 scroll-py-1 overflow-y-auto overflow-x-hidden p-1', local.class)}\n {...rest}\n />\n </div>\n )\n}\n\nexport function CommandEmpty(props: ComponentProps<typeof CmdkEmpty>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkEmpty\n /*\n * A status rather than plain text: when the list is presentational, this is\n * the only thing that tells a screen reader the search matched nothing.\n */\n role=\"status\"\n class={cn('text-muted-foreground py-8 text-center text-sm', local.class)}\n {...rest}\n />\n )\n}\n\nexport function CommandGroup(props: ComponentProps<typeof CmdkGroup>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkGroup\n class={cn(\n 'text-foreground overflow-hidden p-1',\n '[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-2xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:tracking-wide [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group-heading]]:uppercase',\n local.class\n )}\n {...rest}\n />\n )\n}\n\nexport function CommandItem(props: ComponentProps<typeof CmdkItem>) {\n const [local, rest] = splitProps(props, ['class'])\n\n return (\n <CmdkItem\n class={cn(\n commandItem,\n 'data-[disabled=true]:pointer-events-none data-[disabled=true]:text-muted-foreground',\n 'group/command-item text-popover-foreground data-[selected=true]:bg-card data-[selected=true]:text-popover-foreground',\n local.class\n )}\n {...rest}\n />\n )\n}\n\nexport function CommandSeparator(props: ComponentProps<typeof CmdkSeparator>) {\n const [local, rest] = splitProps(props, ['class'])\n return <CmdkSeparator class={cn('bg-border -mx-1 my-1 h-px', local.class)} {...rest} />\n}\n\nexport function CommandLoading(props: ComponentProps<typeof CmdkLoading>) {\n const [local, rest] = splitProps(props, ['class'])\n return (\n <CmdkLoading\n class={cn('text-muted-foreground py-6 text-center text-sm', local.class)}\n {...rest}\n />\n )\n}\n\n/** The keyboard hint a palette item usually carries. */\nexport function CommandShortcut(props: {\n class?: string\n children?: ComponentProps<'span'>['children']\n}) {\n return (\n <span\n class={cn(\n 'text-muted-foreground ms-auto font-mono text-2xs tracking-widest group-data-[selected=true]/command-item:text-foreground',\n props.class\n )}\n >\n {props.children}\n </span>\n )\n}\n"],"mappings":";;;;;;;;;;;;AAuBA,IAAM6B,cAAcF,SACjBG,QAAQ,uCAAuC,EAAE,CAAC,CAClDA,QAAQ,yCAAyC,EAAE;;;;;;;;;;;;;;;;;AAkBtD,SAAgBC,QAAQC,OAAwC;CAC9D,MAAM,CAACC,OAAOC,QAAQT,WAAWO,OAAO,CAAC,OAAO,CAAC;CAEjD,OAAAG,gBACGpB,aAAQqB,WAAA,EAAA,KAAA,WAAA;EAAA,OACAR,GACL,6FACAK,MAAMI,KACR;CAAC,EAAA,GACGH,IAAI,CAAA;AAGd;AAKA,SAAgBlC,cAAcgC,OAA2B;CAMvD,MAAM,CAACC,OAAOQ,aAAaC,gBAAgBjB,WACzCO,OACA;EACE;EACA;EACA;EACA;EACA;EACA;CAAiB,GAEnB;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;CAAc,CAElB;CACA,MAAM,CAACW,QAAQC,aAAapB,aAAaiB,YAAYI,QAAQJ,YAAYK,eAAe,KAAK;CAE7FvB,mBAAmB;EACjB,IAAIkB,YAAYI,SAASE,KAAAA,GAAWH,UAAUH,YAAYI,IAAI;CAChE,CAAC;CAED,MAAMG,QAAQtB,6BAA6B;EACzCmB,MAAMF;EACNM,kBAAkBhB,MAAMgB;EACxBC,iBAAiBjB,MAAMiB;CACzB,CAAC;CAED,OAAAf,gBACGf,QAAagB,WACRK,aAAW;EACfU,eAAeN,SAAS;GACtBD,UAAUC,IAAI;GACdJ,YAAYU,eAAeN,IAAI;EACjC;EAAC,IAAAO,WAAA;GAAA,OAAAjB,gBAEAf,OAAciC,QAAM;IAAA,IAACC,QAAK;KAAA,OAAErB,MAAMsB;IAAS;IAAA,IAAAH,WAAA;KAAA,OAAA,CAAAjB,gBACzCf,OAAcoC,SAAO;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ACjD,OAAAG,gBAAQlB,kBAAamB,WAAA,EAAA,KAAA,WAAA;EAAA,OAAQR,GAAG,6BAA6BK,MAAMI,KAAK;CAAC,EAAA,GAAMH,IAAI,CAAA;AACrF;AAEA,SAAgBtB,iBAAeoB,OAA2C;CACxE,MAAM,CAACC,OAAOC,QAAQT,WAAWO,OAAO,CAAC,OAAO,CAAC;CACjD,OAAAG,gBACGtB,gBAAWuB,WAAA,EAAA,KAAA,WAAA;EAAA,OACHR,GAAG,kDAAkDK,MAAMI,KAAK;CAAC,EAAA,GACpEH,IAAI,CAAA;AAGd;;AAGA,SAAgB6C,gBAAgB/C,OAG7B;CACD,cAAA;EAAA,IAAAgD,QAAAC,QAAA;EAAAjB,OAAAgB,aAOKhD,MAAMoB,QAAQ;EAAA8B,aAAAC,UAAAH,OALRpD,GACL,4HACAI,MAAMK,KACR,CAAC,CAAA;EAAA,OAAA2C;CAAA,EAAA,CAAA;AAKP"}
package/dist/index.d.ts CHANGED
@@ -73,6 +73,8 @@ export * from './components/ui/toggle-group';
73
73
  export * from './components/ui/tooltip';
74
74
  export * from './components/motion';
75
75
  export * from './components/layout/split-layout';
76
+ export * from './components/layout/orbit-layout';
77
+ export * from './components/layout/virtual-window';
76
78
  export * from './components/layout/app-shell';
77
79
  export * from './components/layout/page';
78
80
  export * from './components/layout/panel';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAGH,cAAc,2BAA2B,CAAA;AACzC,cAAc,uBAAuB,CAAA;AACrC,cAAc,8BAA8B,CAAA;AAC5C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,wBAAwB,CAAA;AACtC,cAAc,uBAAuB,CAAA;AACrC,cAAc,uBAAuB,CAAA;AACrC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,wBAAwB,CAAA;AACtC,cAAc,8BAA8B,CAAA;AAC5C,cAAc,0BAA0B,CAAA;AACxC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CAAA;AAChC,OAAO,EACL,kBAAkB,EAClB,WAAW,EACX,eAAe,EACf,YAAY,EACZ,GAAG,EACH,kBAAkB,EAClB,KAAK,WAAW,EAChB,KAAK,YAAY,GAClB,MAAM,gBAAgB,CAAA;AACvB,OAAO,EACL,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,mBAAmB,EACnB,SAAS,EACT,iBAAiB,EACjB,aAAa,EACb,mBAAmB,EACnB,aAAa,EACb,qBAAqB,EACrB,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,kBAAkB,EACvB,KAAK,YAAY,EACjB,KAAK,eAAe,EACpB,KAAK,oBAAoB,EACzB,KAAK,YAAY,GAClB,MAAM,cAAc,CAAA;AACrB,OAAO,EAAE,SAAS,EAAE,KAAK,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AAC3D,OAAO,EAAE,WAAW,EAAE,iBAAiB,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAA;AAC3F,OAAO,EACL,aAAa,EACb,SAAS,EACT,WAAW,EACX,aAAa,EACb,YAAY,EACZ,eAAe,EACf,WAAW,EACX,YAAY,EACZ,YAAY,EACZ,gBAAgB,EAChB,wBAAwB,EACxB,YAAY,EACZ,KAAK,YAAY,EACjB,KAAK,UAAU,EACf,KAAK,eAAe,EACpB,KAAK,SAAS,GACf,MAAM,cAAc,CAAA"}
package/dist/index.js CHANGED
@@ -63,6 +63,8 @@ import { Motion } from "./components/motion/index.js";
63
63
  import { MAX_LAYOUT_DEPTH, MAX_LAYOUT_LEAVES, MAX_SPLIT_RATIO, MIN_SPLIT_RATIO, closePane, countLeaves, createLayoutState, focusPane, layoutDepth, listLeaves, movePane, neighborLeaf, normalizeLayout, resizeSplit, splitPane, swapPanes, undoClosePane } from "./components/layout/split-layout/model.js";
64
64
  import { computeLayoutFrames } from "./components/layout/split-layout/geometry.js";
65
65
  import { SplitLayout } from "./components/layout/split-layout/split-layout.js";
66
+ import { OrbitItem, OrbitLayout } from "./components/layout/orbit-layout/orbit-layout.js";
67
+ import { VirtualWindow } from "./components/layout/virtual-window/virtual-window.js";
66
68
  import { AppShell, AppShellBody, AppShellContent, AppShellMain } from "./components/layout/app-shell/app-shell.js";
67
69
  import { Page, PageHeader, PageHeaderActions, PageHeaderContent, PageHeaderDescription, PageHeaderTitle, PageSection } from "./components/layout/page/page.js";
68
70
  import { Panel, PanelActions, PanelBody, PanelCard, PanelDescription, PanelFooter, PanelHeader, PanelPlaceholder, PanelTitle, PanelToolbar } from "./components/layout/panel/panel.js";
@@ -97,4 +99,4 @@ import { formatBytes, formatReleaseDate, plainTextFromMarkdown } from "./lib/ver
97
99
  import { UpdateDialog } from "./components/composites/update-dialog/update-dialog.js";
98
100
  import { WorkspaceMark } from "./components/composites/workspace-mark/workspace-mark.js";
99
101
  import { keyedRows } from "./lib/keyed-rows.js";
100
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, AccountMenu, ActionButton, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AppShell, AppShellBody, AppShellContent, AppShellMain, AppearanceEditor, AppearancePanel, AppearancePopover, AspectRatio, AttachmentCard, Avatar, AvatarFallback, AvatarImage, Badge, Board, BoardCardBody, BoardCardTitle, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbSeparator, BusySendButton, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, CalendarSurface, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChatComposer, Checkbox, CheckboxDescription, CheckboxLabel, CodeBlock, Collapsible, CollapsibleContent, CollapsibleTrigger, Combobox, ComboboxClear, ComboboxContent, ComboboxControl, ComboboxInput, ComboboxItem, ComboboxSection, ComboboxTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut, ComposerAttachmentButton, ComposerHint, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, ConversationAvatar, ConversationSurface, DatePicker, DetailPanel, DetailPanelBody, DetailPanelField, DetailPanelHeader, DetailPanelSection, Dialog, DialogClose, DialogCloseButton, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DiffBlock, DiffSummary, Drawer, DrawerBody, DrawerCloseButton, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, EntityIcon, Field, FieldDescription, FieldError, FieldInput, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTextArea, HoverCard, HoverCardContent, HoverCardTrigger, InlineCode, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputOtp, InputOtpCaret, Item, ItemDescription, ItemEmpty, ItemGroup, ItemGroupEntry, ItemTitle, Kbd, KbdGroup, Label, ListGroup, ListRow, MAX_LAYOUT_DEPTH, MAX_LAYOUT_LEAVES, MAX_SPLIT_RATIO, MIN_SPLIT_RATIO, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MessageBody, MessageComposer, MessageDayDivider, MessageGroup, MessageRow, ModalDialog, Motion, NativeSelect, NavigationMenu, NavigationMenuContent, NavigationMenuGroup, NavigationMenuGroupLabel, NavigationMenuItem, NavigationMenuMenu, NavigationMenuSeparator, NavigationMenuTrigger, NavigationMenuViewport, PASTE_THRESHOLD_CHARS, PASTE_THRESHOLD_LINES, PASTE_TOKEN_REGEX, Page, PageHeader, PageHeaderActions, PageHeaderContent, PageHeaderDescription, PageHeaderTitle, PageSection, Pagination, PaginationEllipsis, PaginationItem, PaginationNext, PaginationPrevious, PalettePreview, Panel, PanelActions, PanelBody, PanelCard, PanelDescription, PanelFooter, PanelHeader, PanelPlaceholder, PanelTitle, PanelToolbar, Popover, PopoverAnchor, PopoverCloseButton, PopoverContent, PopoverDescription, PopoverTitle, PopoverTrigger, Presence, Progress, PropertyList, PropertyRow, PropertyTerm, PropertyValue, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ScrollArea, Select, SelectChevronsUpDown, SelectContent, SelectItem, SelectLabel, SelectSection, SelectTrigger, SelectValue, Separator, SettingsField, SettingsPage, SettingsRow, SettingsSection, Sheet, SheetBody, SheetCloseButton, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, SideRail, SideRailButton, SideRailContent, SideRailFooter, SideRailHeader, SideRailItem, SideRailSection, SidebarNav, SidebarNavButton, SidebarNavContent, SidebarNavFooter, SidebarNavHeader, SidebarNavItem, SidebarNavSection, SidebarNavTitle, Skeleton, Slider, Spinner, SplitLayout, Stat, StatGroup, StatusBar, StatusBarItem, StatusBarSpacer, StatusChip, StatusList, Switch, SwitchDescription, SwitchLabel, TALL_CODE_BLOCK_PX, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableNumericCell, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeMiniature, ThemeMiniatureSplit, ThemePicker, ThemePreview, ThemeProvider, ThemeSwatch, ThemeToggle, ThreadPanel, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TopBar, TopBarBreadcrumb, TopBarPill, TopBarSearch, TopBarSection, TopBarTitle, TranscriptComposition, UpdateDialog, WorkspaceMark, accentPresets, alertVariants, allTokens, badgeVariants, boardCardTitleVariants, builtinThemes, buttonVariants, closePane, cn, colorTokens, computeLayoutFrames, contrastRatio, controlInteractive, controlSize, controlSizeIcon, controlSizes, countLeaves, countLines, createLayoutState, cva, defaultDarkThemeId, defaultLightThemeId, defaultThemeSelection, densityTokens, designTokens, diffLineVariants, diffStats, diffTargetPath, elevationTokens, entityIconVariants, expandAll, findTokenRanges, focusPane, fontOptions, formatBytes, formatReleaseDate, formatToken, initialsFrom, inlineScriptLiteral, isPasteBlock, itemVariants, keyedRows, layoutDepth, listLeaves, monogram, motionTokens, movePane, neighborLeaf, nextSeq, normalizeLayout, parseDiff, plainTextFromMarkdown, pruneBlocks, radiusTokens, recollapsePastes, remapCarriedBlocks, resizeSplit, resolvedDensity, sheetVariants, shouldCollapse, sidebarNavItemClass, sidebarNavItemStateClass, splitPane, statusDotVariants, stripTrailingBlankLines, surfaceInteractive, swapPanes, themeById, themeCssVariables, themeFamilies, themeScript, themesForAppearance, toast, toaster, toggleVariants, tokenRangeAt, transcriptDisclosureKey, typographyTokens, undoClosePane, undocumentedTokenAliases, useSideRail, useTheme, validateTheme, validateThemeRegistry, zIndexTokens };
102
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, AccountMenu, ActionButton, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AppShell, AppShellBody, AppShellContent, AppShellMain, AppearanceEditor, AppearancePanel, AppearancePopover, AspectRatio, AttachmentCard, Avatar, AvatarFallback, AvatarImage, Badge, Board, BoardCardBody, BoardCardTitle, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbSeparator, BusySendButton, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, CalendarSurface, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChatComposer, Checkbox, CheckboxDescription, CheckboxLabel, CodeBlock, Collapsible, CollapsibleContent, CollapsibleTrigger, Combobox, ComboboxClear, ComboboxContent, ComboboxControl, ComboboxInput, ComboboxItem, ComboboxSection, ComboboxTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut, ComposerAttachmentButton, ComposerHint, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, ConversationAvatar, ConversationSurface, DatePicker, DetailPanel, DetailPanelBody, DetailPanelField, DetailPanelHeader, DetailPanelSection, Dialog, DialogClose, DialogCloseButton, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DiffBlock, DiffSummary, Drawer, DrawerBody, DrawerCloseButton, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, EntityIcon, Field, FieldDescription, FieldError, FieldInput, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTextArea, HoverCard, HoverCardContent, HoverCardTrigger, InlineCode, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputOtp, InputOtpCaret, Item, ItemDescription, ItemEmpty, ItemGroup, ItemGroupEntry, ItemTitle, Kbd, KbdGroup, Label, ListGroup, ListRow, MAX_LAYOUT_DEPTH, MAX_LAYOUT_LEAVES, MAX_SPLIT_RATIO, MIN_SPLIT_RATIO, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MessageBody, MessageComposer, MessageDayDivider, MessageGroup, MessageRow, ModalDialog, Motion, NativeSelect, NavigationMenu, NavigationMenuContent, NavigationMenuGroup, NavigationMenuGroupLabel, NavigationMenuItem, NavigationMenuMenu, NavigationMenuSeparator, NavigationMenuTrigger, NavigationMenuViewport, OrbitItem, OrbitLayout, PASTE_THRESHOLD_CHARS, PASTE_THRESHOLD_LINES, PASTE_TOKEN_REGEX, Page, PageHeader, PageHeaderActions, PageHeaderContent, PageHeaderDescription, PageHeaderTitle, PageSection, Pagination, PaginationEllipsis, PaginationItem, PaginationNext, PaginationPrevious, PalettePreview, Panel, PanelActions, PanelBody, PanelCard, PanelDescription, PanelFooter, PanelHeader, PanelPlaceholder, PanelTitle, PanelToolbar, Popover, PopoverAnchor, PopoverCloseButton, PopoverContent, PopoverDescription, PopoverTitle, PopoverTrigger, Presence, Progress, PropertyList, PropertyRow, PropertyTerm, PropertyValue, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ScrollArea, Select, SelectChevronsUpDown, SelectContent, SelectItem, SelectLabel, SelectSection, SelectTrigger, SelectValue, Separator, SettingsField, SettingsPage, SettingsRow, SettingsSection, Sheet, SheetBody, SheetCloseButton, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, SideRail, SideRailButton, SideRailContent, SideRailFooter, SideRailHeader, SideRailItem, SideRailSection, SidebarNav, SidebarNavButton, SidebarNavContent, SidebarNavFooter, SidebarNavHeader, SidebarNavItem, SidebarNavSection, SidebarNavTitle, Skeleton, Slider, Spinner, SplitLayout, Stat, StatGroup, StatusBar, StatusBarItem, StatusBarSpacer, StatusChip, StatusList, Switch, SwitchDescription, SwitchLabel, TALL_CODE_BLOCK_PX, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableNumericCell, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeMiniature, ThemeMiniatureSplit, ThemePicker, ThemePreview, ThemeProvider, ThemeSwatch, ThemeToggle, ThreadPanel, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TopBar, TopBarBreadcrumb, TopBarPill, TopBarSearch, TopBarSection, TopBarTitle, TranscriptComposition, UpdateDialog, VirtualWindow, WorkspaceMark, accentPresets, alertVariants, allTokens, badgeVariants, boardCardTitleVariants, builtinThemes, buttonVariants, closePane, cn, colorTokens, computeLayoutFrames, contrastRatio, controlInteractive, controlSize, controlSizeIcon, controlSizes, countLeaves, countLines, createLayoutState, cva, defaultDarkThemeId, defaultLightThemeId, defaultThemeSelection, densityTokens, designTokens, diffLineVariants, diffStats, diffTargetPath, elevationTokens, entityIconVariants, expandAll, findTokenRanges, focusPane, fontOptions, formatBytes, formatReleaseDate, formatToken, initialsFrom, inlineScriptLiteral, isPasteBlock, itemVariants, keyedRows, layoutDepth, listLeaves, monogram, motionTokens, movePane, neighborLeaf, nextSeq, normalizeLayout, parseDiff, plainTextFromMarkdown, pruneBlocks, radiusTokens, recollapsePastes, remapCarriedBlocks, resizeSplit, resolvedDensity, sheetVariants, shouldCollapse, sidebarNavItemClass, sidebarNavItemStateClass, splitPane, statusDotVariants, stripTrailingBlankLines, surfaceInteractive, swapPanes, themeById, themeCssVariables, themeFamilies, themeScript, themesForAppearance, toast, toaster, toggleVariants, tokenRangeAt, transcriptDisclosureKey, typographyTokens, undoClosePane, undocumentedTokenAliases, useSideRail, useTheme, validateTheme, validateThemeRegistry, zIndexTokens };