@ai-matrx/design-system 0.86.339 → 0.86.341

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.
@@ -114,9 +114,64 @@ import {
114
114
  cn
115
115
  } from "./chunk-M6KA5EHN.js";
116
116
 
117
- // src/controls/decision-control.tsx
117
+ // src/controls/window-controls.tsx
118
118
  import * as React from "react";
119
- import { Fragment as Fragment2, jsx, jsxs } from "react/jsx-runtime";
119
+ import { jsx } from "react/jsx-runtime";
120
+ var WindowLights = React.forwardRef(
121
+ ({ className, inactive, touch, role = "group", "aria-label": ariaLabel = "Window controls", ...props }, ref) => /* @__PURE__ */ jsx(
122
+ "div",
123
+ {
124
+ ref,
125
+ role,
126
+ "aria-label": ariaLabel,
127
+ "data-matrx-window-lights": "",
128
+ "data-inactive": inactive ? "" : void 0,
129
+ "data-touch": touch ? "" : void 0,
130
+ className: cn("matrx-window-lights", className),
131
+ ...props
132
+ }
133
+ )
134
+ );
135
+ WindowLights.displayName = "WindowLights";
136
+ function lightGlyph(kind, restores) {
137
+ if (kind === "close") return /* @__PURE__ */ jsx(XIcon, { "aria-hidden": "true" });
138
+ if (kind === "minimize") return restores ? /* @__PURE__ */ jsx(Maximize2Icon, { "aria-hidden": "true" }) : /* @__PURE__ */ jsx(MinusIcon, { "aria-hidden": "true" });
139
+ return restores ? /* @__PURE__ */ jsx(Minimize2Icon, { "aria-hidden": "true" }) : /* @__PURE__ */ jsx(Maximize2Icon, { "aria-hidden": "true" });
140
+ }
141
+ var WindowLight = React.forwardRef(
142
+ ({ className, kind, restores = false, type, ...props }, ref) => /* @__PURE__ */ jsx(
143
+ "button",
144
+ {
145
+ ref,
146
+ type: type ?? "button",
147
+ "data-matrx-window-light": kind,
148
+ "data-restores": restores ? "" : void 0,
149
+ className: cn("matrx-window-light", className),
150
+ ...props,
151
+ children: lightGlyph(kind, restores)
152
+ }
153
+ )
154
+ );
155
+ WindowLight.displayName = "WindowLight";
156
+ var WindowChromeButton = React.forwardRef(
157
+ ({ className, icon, type, title, ...props }, ref) => /* @__PURE__ */ jsx(
158
+ "button",
159
+ {
160
+ ref,
161
+ type: type ?? "button",
162
+ "data-matrx-window-chrome-button": "",
163
+ className: cn("matrx-window-chrome-button", className),
164
+ title: title ?? props["aria-label"],
165
+ ...props,
166
+ children: icon
167
+ }
168
+ )
169
+ );
170
+ WindowChromeButton.displayName = "WindowChromeButton";
171
+
172
+ // src/controls/decision-control.tsx
173
+ import * as React2 from "react";
174
+ import { Fragment as Fragment2, jsx as jsx2, jsxs } from "react/jsx-runtime";
120
175
  function find(items, value) {
121
176
  if (!items || !value) return null;
122
177
  for (const i of items) {
@@ -127,21 +182,21 @@ function find(items, value) {
127
182
  return null;
128
183
  }
129
184
  function WayOutEntries({ items, chosen, onPick }) {
130
- return /* @__PURE__ */ jsx(Fragment2, { children: items.map((item, index) => /* @__PURE__ */ jsxs(React.Fragment, { children: [
185
+ return /* @__PURE__ */ jsx2(Fragment2, { children: items.map((item, index) => /* @__PURE__ */ jsxs(React2.Fragment, { children: [
131
186
  item.group ? /* @__PURE__ */ jsxs(Fragment2, { children: [
132
- index > 0 ? /* @__PURE__ */ jsx(DropdownMenuSeparator, {}) : null,
133
- /* @__PURE__ */ jsx(DropdownMenuLabel, { "data-way-out-group": "", children: item.group })
187
+ index > 0 ? /* @__PURE__ */ jsx2(DropdownMenuSeparator, {}) : null,
188
+ /* @__PURE__ */ jsx2(DropdownMenuLabel, { "data-way-out-group": "", children: item.group })
134
189
  ] }) : null,
135
190
  item.items?.length ? /* @__PURE__ */ jsxs(DropdownMenuSub, { children: [
136
191
  /* @__PURE__ */ jsxs(DropdownMenuSubTrigger, { "data-way-out": item.value, className: "text-foreground", children: [
137
- /* @__PURE__ */ jsx("span", { className: "flex-1", children: item.label }),
138
- find(item.items, chosen) ? /* @__PURE__ */ jsx(RadixCheckIcon, { className: "mr-1 size-3.5", "aria-hidden": "true" }) : null
192
+ /* @__PURE__ */ jsx2("span", { className: "flex-1", children: item.label }),
193
+ find(item.items, chosen) ? /* @__PURE__ */ jsx2(RadixCheckIcon, { className: "mr-1 size-3.5", "aria-hidden": "true" }) : null
139
194
  ] }),
140
- /* @__PURE__ */ jsx(DropdownMenuSubContent, { children: /* @__PURE__ */ jsx(WayOutEntries, { items: item.items, chosen, onPick }) })
195
+ /* @__PURE__ */ jsx2(DropdownMenuSubContent, { children: /* @__PURE__ */ jsx2(WayOutEntries, { items: item.items, chosen, onPick }) })
141
196
  ] }) : /* @__PURE__ */ jsxs(DropdownMenuItem, { "data-way-out": item.value, className: "text-foreground", onSelect: () => onPick(item.value), children: [
142
- /* @__PURE__ */ jsx("span", { className: "flex-1", children: item.label }),
143
- item.meta ? /* @__PURE__ */ jsx("span", { className: "text-[11px] text-muted-foreground", children: item.meta }) : null,
144
- chosen === item.value ? /* @__PURE__ */ jsx(RadixCheckIcon, { className: "size-3.5", "aria-hidden": "true" }) : null
197
+ /* @__PURE__ */ jsx2("span", { className: "flex-1", children: item.label }),
198
+ item.meta ? /* @__PURE__ */ jsx2("span", { className: "text-[11px] text-muted-foreground", children: item.meta }) : null,
199
+ chosen === item.value ? /* @__PURE__ */ jsx2(RadixCheckIcon, { className: "size-3.5", "aria-hidden": "true" }) : null
145
200
  ] })
146
201
  ] }, item.value)) });
147
202
  }
@@ -169,8 +224,8 @@ function DecisionControl({
169
224
  className,
170
225
  "aria-label": ariaLabel
171
226
  }) {
172
- const [otherOpen, setOtherOpen] = React.useState(false);
173
- const [chipOpen, setChipOpen] = React.useState(false);
227
+ const [otherOpen, setOtherOpen] = React2.useState(false);
228
+ const [chipOpen, setChipOpen] = React2.useState(false);
174
229
  const otherOn = value === "other" || otherOpen;
175
230
  const word = (a) => labels?.[a] ?? (a === "yes" ? "Yes" : a === "no" ? "No" : "Other");
176
231
  const yesMode = value === "yes" && Boolean(yesKinds?.length);
@@ -180,16 +235,16 @@ function DecisionControl({
180
235
  const primary = yesMode && yesKinds?.[0]?.value === yesKind;
181
236
  const wayOutMenu = /* @__PURE__ */ jsxs(Fragment2, { children: [
182
237
  wayOut?.length ? /* @__PURE__ */ jsxs(Fragment2, { children: [
183
- /* @__PURE__ */ jsx(WayOutEntries, { items: wayOut, chosen: wayOutValue, onPick: (v) => onWayOut?.(v) }),
184
- /* @__PURE__ */ jsx(DropdownMenuSeparator, {})
238
+ /* @__PURE__ */ jsx2(WayOutEntries, { items: wayOut, chosen: wayOutValue, onPick: (v) => onWayOut?.(v) }),
239
+ /* @__PURE__ */ jsx2(DropdownMenuSeparator, {})
185
240
  ] }) : null,
186
241
  /* @__PURE__ */ jsxs(DropdownMenuItem, { "data-way-out": "skip", className: "text-foreground", onSelect: onSkip, children: [
187
- /* @__PURE__ */ jsx("span", { className: "flex-1", children: skipLabel }),
188
- skipped ? /* @__PURE__ */ jsx(RadixCheckIcon, { className: "size-3.5", "aria-hidden": "true" }) : null
242
+ /* @__PURE__ */ jsx2("span", { className: "flex-1", children: skipLabel }),
243
+ skipped ? /* @__PURE__ */ jsx2(RadixCheckIcon, { className: "size-3.5", "aria-hidden": "true" }) : null
189
244
  ] })
190
245
  ] });
191
246
  const stage = size === "stage";
192
- const button = (a) => /* @__PURE__ */ jsx("span", { "data-decision-slot": a, "data-suggested": suggested === a ? "" : void 0, className: cn("inline-flex max-sm:flex-1", suggested === a && ring), children: /* @__PURE__ */ jsx(
247
+ const button = (a) => /* @__PURE__ */ jsx2("span", { "data-decision-slot": a, "data-suggested": suggested === a ? "" : void 0, className: cn("inline-flex max-sm:flex-1", suggested === a && ring), children: /* @__PURE__ */ jsx2(
193
248
  Button2,
194
249
  {
195
250
  variant: value === a ? a === "no" ? "danger" : "primary" : "outline",
@@ -227,7 +282,7 @@ function DecisionControl({
227
282
  setOtherOpen(next);
228
283
  },
229
284
  children: [
230
- /* @__PURE__ */ jsx("span", { "data-decision-slot": "other", "data-suggested": suggested === "other" ? "" : void 0, className: cn("inline-flex max-sm:flex-1", suggested === "other" && ring), children: /* @__PURE__ */ jsx(DropdownMenuTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx(
285
+ /* @__PURE__ */ jsx2("span", { "data-decision-slot": "other", "data-suggested": suggested === "other" ? "" : void 0, className: cn("inline-flex max-sm:flex-1", suggested === "other" && ring), children: /* @__PURE__ */ jsx2(DropdownMenuTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx2(
231
286
  Button2,
232
287
  {
233
288
  variant: otherOn ? "primary" : "outline",
@@ -240,12 +295,12 @@ function DecisionControl({
240
295
  children: word("other")
241
296
  }
242
297
  ) }) }),
243
- /* @__PURE__ */ jsx(DropdownMenuContent, { align: "start", className: "min-w-48", children: wayOutMenu })
298
+ /* @__PURE__ */ jsx2(DropdownMenuContent, { align: "start", className: "min-w-48", children: wayOutMenu })
244
299
  ]
245
300
  }
246
301
  ),
247
- /* @__PURE__ */ jsx("div", { className: cn("flex min-w-0 items-center sm:w-40", chipLabel === null && "max-sm:hidden", "max-sm:w-full"), "data-decision-picker-slot": "", children: chipLabel === null ? null : /* @__PURE__ */ jsxs(DropdownMenu, { open: chipOpen, onOpenChange: setChipOpen, children: [
248
- /* @__PURE__ */ jsx(DropdownMenuTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx(
302
+ /* @__PURE__ */ jsx2("div", { className: cn("flex min-w-0 items-center sm:w-40", chipLabel === null && "max-sm:hidden", "max-sm:w-full"), "data-decision-picker-slot": "", children: chipLabel === null ? null : /* @__PURE__ */ jsxs(DropdownMenu, { open: chipOpen, onOpenChange: setChipOpen, children: [
303
+ /* @__PURE__ */ jsx2(DropdownMenuTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx2(
249
304
  Chip,
250
305
  {
251
306
  asChild: true,
@@ -254,10 +309,10 @@ function DecisionControl({
254
309
  "data-decision-picker": "",
255
310
  "data-picker-primary": primary ? "" : void 0,
256
311
  "aria-label": `${yesMode ? word("yes") : word("other")}: ${chipLabel}`,
257
- children: /* @__PURE__ */ jsx("button", { type: "button", disabled })
312
+ children: /* @__PURE__ */ jsx2("button", { type: "button", disabled })
258
313
  }
259
314
  ) }),
260
- /* @__PURE__ */ jsx(DropdownMenuContent, { align: "start", className: "min-w-48", children: yesMode ? /* @__PURE__ */ jsx(WayOutEntries, { items: yesKinds ?? [], chosen: yesKind, onPick: (v) => onYesKind?.(v) }) : wayOutMenu })
315
+ /* @__PURE__ */ jsx2(DropdownMenuContent, { align: "start", className: "min-w-48", children: yesMode ? /* @__PURE__ */ jsx2(WayOutEntries, { items: yesKinds ?? [], chosen: yesKind, onPick: (v) => onYesKind?.(v) }) : wayOutMenu })
261
316
  ] }) })
262
317
  ]
263
318
  }
@@ -266,7 +321,7 @@ function DecisionControl({
266
321
 
267
322
  // src/controls/date-field.tsx
268
323
  import { parseDateOnly as parseDateOnly2, toDateOnly as toDateOnly2 } from "@ai-matrx/kit/dates";
269
- import * as React2 from "react";
324
+ import * as React3 from "react";
270
325
 
271
326
  // src/controls/date-parse.ts
272
327
  import { isValidDateOnly, parseDateOnly, toDateOnly } from "@ai-matrx/kit/dates";
@@ -421,9 +476,9 @@ function monthGrid(year, month, firstDay) {
421
476
  var TIME_SLOTS = Array.from({ length: 48 }, (_, i) => `${pad(Math.floor(i / 2))}:${i % 2 ? "30" : "00"}`);
422
477
 
423
478
  // src/controls/date-field.tsx
424
- import { Fragment as Fragment3, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
479
+ import { Fragment as Fragment3, jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
425
480
  var sameDay = (a, b) => a.getFullYear() === b.getFullYear() && a.getMonth() === b.getMonth() && a.getDate() === b.getDate();
426
- var DateField = React2.forwardRef(
481
+ var DateField = React3.forwardRef(
427
482
  ({
428
483
  value,
429
484
  onValueChange,
@@ -446,15 +501,15 @@ var DateField = React2.forwardRef(
446
501
  const word = emptyLabel ?? (mode === "time" ? "Pick a time" : "Pick a date");
447
502
  const dayText = day ? formatDay(day, locale) : "";
448
503
  const timeText = time ? formatTime(time, locale) : "";
449
- const [dayDraft, setDayDraft] = React2.useState(null);
450
- const [timeDraft, setTimeDraft] = React2.useState(null);
451
- const [dayInvalid, setDayInvalid] = React2.useState(false);
452
- const [timeInvalid, setTimeInvalid] = React2.useState(false);
453
- const [open, setOpen] = React2.useState(false);
454
- const dayRef = React2.useRef(null);
455
- const timeRef = React2.useRef(null);
504
+ const [dayDraft, setDayDraft] = React3.useState(null);
505
+ const [timeDraft, setTimeDraft] = React3.useState(null);
506
+ const [dayInvalid, setDayInvalid] = React3.useState(false);
507
+ const [timeInvalid, setTimeInvalid] = React3.useState(false);
508
+ const [open, setOpen] = React3.useState(false);
509
+ const dayRef = React3.useRef(null);
510
+ const timeRef = React3.useRef(null);
456
511
  const hasDraft = dayDraft !== null || timeDraft !== null;
457
- React2.useEffect(() => {
512
+ React3.useEffect(() => {
458
513
  if (!hasDraft) return;
459
514
  const onKey = (e) => {
460
515
  if (e.key !== "Escape") return;
@@ -550,7 +605,7 @@ var DateField = React2.forwardRef(
550
605
  }
551
606
  };
552
607
  const panelKind = hasDay ? "day" : "time";
553
- const panel = panelKind === "day" ? /* @__PURE__ */ jsx2(
608
+ const panel = panelKind === "day" ? /* @__PURE__ */ jsx3(
554
609
  CalendarGrid,
555
610
  {
556
611
  value: day,
@@ -558,12 +613,12 @@ var DateField = React2.forwardRef(
558
613
  onPick: pickDay,
559
614
  onClose: () => setOpen(false),
560
615
  footer: /* @__PURE__ */ jsxs2(Fragment3, { children: [
561
- /* @__PURE__ */ jsx2("button", { type: "button", className: "matrx-date-panel-action", onClick: () => pickDay(toDateOnly2(/* @__PURE__ */ new Date())), children: "Today" }),
562
- !empty && clearable ? /* @__PURE__ */ jsx2("button", { type: "button", className: "matrx-date-panel-action", onClick: clear, children: "Clear" }) : null
616
+ /* @__PURE__ */ jsx3("button", { type: "button", className: "matrx-date-panel-action", onClick: () => pickDay(toDateOnly2(/* @__PURE__ */ new Date())), children: "Today" }),
617
+ !empty && clearable ? /* @__PURE__ */ jsx3("button", { type: "button", className: "matrx-date-panel-action", onClick: clear, children: "Clear" }) : null
563
618
  ] })
564
619
  }
565
- ) : /* @__PURE__ */ jsx2(TimeList, { value: time, locale, onPick: pickTime, onClose: () => setOpen(false) });
566
- const glyph = /* @__PURE__ */ jsx2(
620
+ ) : /* @__PURE__ */ jsx3(TimeList, { value: time, locale, onPick: pickTime, onClose: () => setOpen(false) });
621
+ const glyph = /* @__PURE__ */ jsx3(
567
622
  "button",
568
623
  {
569
624
  type: "button",
@@ -574,7 +629,7 @@ var DateField = React2.forwardRef(
574
629
  "aria-expanded": open,
575
630
  "data-matrx-date-trigger": "",
576
631
  onClick: () => setOpen((o) => !o),
577
- children: hasDay ? /* @__PURE__ */ jsx2(CalendarIcon, {}) : /* @__PURE__ */ jsx2(ClockIcon, {})
632
+ children: hasDay ? /* @__PURE__ */ jsx3(CalendarIcon, {}) : /* @__PURE__ */ jsx3(ClockIcon, {})
578
633
  }
579
634
  );
580
635
  const capsule = /* @__PURE__ */ jsxs2(
@@ -599,7 +654,7 @@ var DateField = React2.forwardRef(
599
654
  },
600
655
  children: [
601
656
  glyph,
602
- hasDay ? /* @__PURE__ */ jsx2(
657
+ hasDay ? /* @__PURE__ */ jsx3(
603
658
  "input",
604
659
  {
605
660
  ref: dayRef,
@@ -624,7 +679,7 @@ var DateField = React2.forwardRef(
624
679
  onKeyDown: inputKeys("day")
625
680
  }
626
681
  ) : null,
627
- hasTime ? /* @__PURE__ */ jsx2(
682
+ hasTime ? /* @__PURE__ */ jsx3(
628
683
  "input",
629
684
  {
630
685
  ref: timeRef,
@@ -650,19 +705,19 @@ var DateField = React2.forwardRef(
650
705
  onKeyDown: inputKeys("time")
651
706
  }
652
707
  ) : null,
653
- clearable && !empty && !disabled ? /* @__PURE__ */ jsx2("button", { type: "button", "aria-label": "Clear", "data-matrx-date-clear": "", onClick: clear, children: /* @__PURE__ */ jsx2(XIcon, {}) }) : null
708
+ clearable && !empty && !disabled ? /* @__PURE__ */ jsx3("button", { type: "button", "aria-label": "Clear", "data-matrx-date-clear": "", onClick: clear, children: /* @__PURE__ */ jsx3(XIcon, {}) }) : null
654
709
  ]
655
710
  }
656
711
  );
657
712
  if (isMobile) {
658
713
  return /* @__PURE__ */ jsxs2(Fragment3, { children: [
659
714
  capsule,
660
- /* @__PURE__ */ jsx2(BottomSheet, { open, onOpenChange: setOpen, title: hasDay ? "Pick a date" : "Pick a time", surface: "solid", children: /* @__PURE__ */ jsx2("div", { className: "matrx-date-sheet", children: panel }) })
715
+ /* @__PURE__ */ jsx3(BottomSheet, { open, onOpenChange: setOpen, title: hasDay ? "Pick a date" : "Pick a time", surface: "solid", children: /* @__PURE__ */ jsx3("div", { className: "matrx-date-sheet", children: panel }) })
661
716
  ] });
662
717
  }
663
718
  return /* @__PURE__ */ jsxs2(Popover, { open, onOpenChange: setOpen, children: [
664
- /* @__PURE__ */ jsx2(PopoverAnchor, { asChild: true, children: capsule }),
665
- /* @__PURE__ */ jsx2(
719
+ /* @__PURE__ */ jsx3(PopoverAnchor, { asChild: true, children: capsule }),
720
+ /* @__PURE__ */ jsx3(
666
721
  PopoverContent,
667
722
  {
668
723
  sizing: "content",
@@ -681,9 +736,9 @@ var DateField = React2.forwardRef(
681
736
  }
682
737
  );
683
738
  DateField.displayName = "DateField";
684
- var DateTimeField = React2.forwardRef((props, ref) => /* @__PURE__ */ jsx2(DateField, { ref, ...props, mode: "datetime" }));
739
+ var DateTimeField = React3.forwardRef((props, ref) => /* @__PURE__ */ jsx3(DateField, { ref, ...props, mode: "datetime" }));
685
740
  DateTimeField.displayName = "DateTimeField";
686
- var TimeField = React2.forwardRef((props, ref) => /* @__PURE__ */ jsx2(DateField, { ref, ...props, mode: "time" }));
741
+ var TimeField = React3.forwardRef((props, ref) => /* @__PURE__ */ jsx3(DateField, { ref, ...props, mode: "time" }));
687
742
  TimeField.displayName = "TimeField";
688
743
  function CalendarGrid({
689
744
  value,
@@ -694,15 +749,15 @@ function CalendarGrid({
694
749
  }) {
695
750
  const selected = parseDateOnly2(value);
696
751
  const today = /* @__PURE__ */ new Date();
697
- const [focus, setFocus] = React2.useState(() => selected ?? today);
698
- const gridRef = React2.useRef(null);
752
+ const [focus, setFocus] = React3.useState(() => selected ?? today);
753
+ const gridRef = React3.useRef(null);
699
754
  const firstDay = weekStart(locale);
700
755
  const days = monthGrid(focus.getFullYear(), focus.getMonth(), firstDay);
701
756
  const weekdayFmt = new Intl.DateTimeFormat(locale, { weekday: "short" });
702
757
  const weekdayLong = new Intl.DateTimeFormat(locale, { weekday: "long" });
703
758
  const monthFmt = new Intl.DateTimeFormat(locale, { month: "long", year: "numeric" });
704
759
  const dayLabel = new Intl.DateTimeFormat(locale, { weekday: "long", month: "long", day: "numeric", year: "numeric" });
705
- React2.useEffect(() => {
760
+ React3.useEffect(() => {
706
761
  gridRef.current?.querySelector('[tabindex="0"]')?.focus();
707
762
  }, [focus]);
708
763
  const move = (days2, months = 0) => setFocus((f) => {
@@ -738,16 +793,16 @@ function CalendarGrid({
738
793
  const headers = days.slice(0, 7);
739
794
  return /* @__PURE__ */ jsxs2("div", { className: "matrx-date-panel", "data-matrx-date-panel": "calendar", children: [
740
795
  /* @__PURE__ */ jsxs2("div", { className: "matrx-date-panel-head", children: [
741
- /* @__PURE__ */ jsx2("button", { type: "button", className: "matrx-date-panel-nav", "aria-label": "Previous month", onClick: () => move(0, -1), children: /* @__PURE__ */ jsx2(ChevronLeftIcon, {}) }),
742
- /* @__PURE__ */ jsx2("span", { className: "matrx-date-panel-title", "aria-live": "polite", children: monthFmt.format(focus) }),
743
- /* @__PURE__ */ jsx2("button", { type: "button", className: "matrx-date-panel-nav", "aria-label": "Next month", onClick: () => move(0, 1), children: /* @__PURE__ */ jsx2(ChevronRightIcon, {}) })
796
+ /* @__PURE__ */ jsx3("button", { type: "button", className: "matrx-date-panel-nav", "aria-label": "Previous month", onClick: () => move(0, -1), children: /* @__PURE__ */ jsx3(ChevronLeftIcon, {}) }),
797
+ /* @__PURE__ */ jsx3("span", { className: "matrx-date-panel-title", "aria-live": "polite", children: monthFmt.format(focus) }),
798
+ /* @__PURE__ */ jsx3("button", { type: "button", className: "matrx-date-panel-nav", "aria-label": "Next month", onClick: () => move(0, 1), children: /* @__PURE__ */ jsx3(ChevronRightIcon, {}) })
744
799
  ] }),
745
800
  /* @__PURE__ */ jsxs2("div", { ref: gridRef, role: "grid", "aria-label": monthFmt.format(focus), className: "matrx-date-grid", onKeyDown, children: [
746
- /* @__PURE__ */ jsx2("div", { role: "row", className: "matrx-date-row", children: headers.map((d) => /* @__PURE__ */ jsx2("span", { role: "columnheader", "aria-label": weekdayLong.format(d), className: "matrx-date-weekday", children: weekdayFmt.format(d).slice(0, 2) }, d.getDay())) }),
747
- [0, 1, 2, 3, 4, 5].map((w) => /* @__PURE__ */ jsx2("div", { role: "row", className: "matrx-date-row", children: days.slice(w * 7, w * 7 + 7).map((d) => {
801
+ /* @__PURE__ */ jsx3("div", { role: "row", className: "matrx-date-row", children: headers.map((d) => /* @__PURE__ */ jsx3("span", { role: "columnheader", "aria-label": weekdayLong.format(d), className: "matrx-date-weekday", children: weekdayFmt.format(d).slice(0, 2) }, d.getDay())) }),
802
+ [0, 1, 2, 3, 4, 5].map((w) => /* @__PURE__ */ jsx3("div", { role: "row", className: "matrx-date-row", children: days.slice(w * 7, w * 7 + 7).map((d) => {
748
803
  const isSelected = selected ? sameDay(d, selected) : false;
749
804
  const isFocus = sameDay(d, focus);
750
- return /* @__PURE__ */ jsx2("span", { role: "gridcell", "aria-selected": isSelected, children: /* @__PURE__ */ jsx2(
805
+ return /* @__PURE__ */ jsx3("span", { role: "gridcell", "aria-selected": isSelected, children: /* @__PURE__ */ jsx3(
751
806
  "button",
752
807
  {
753
808
  type: "button",
@@ -767,7 +822,7 @@ function CalendarGrid({
767
822
  ) }, d.toISOString());
768
823
  }) }, w))
769
824
  ] }),
770
- footer ? /* @__PURE__ */ jsx2("div", { className: "matrx-date-panel-foot", children: footer }) : null
825
+ footer ? /* @__PURE__ */ jsx3("div", { className: "matrx-date-panel-foot", children: footer }) : null
771
826
  ] });
772
827
  }
773
828
  function TimeList({
@@ -776,10 +831,10 @@ function TimeList({
776
831
  onPick,
777
832
  onClose
778
833
  }) {
779
- const listRef = React2.useRef(null);
834
+ const listRef = React3.useRef(null);
780
835
  const start = value ? TIME_SLOTS.findIndex((s) => s >= value) : TIME_SLOTS.indexOf("09:00");
781
- const [active, setActive] = React2.useState(start < 0 ? TIME_SLOTS.length - 1 : start);
782
- React2.useEffect(() => {
836
+ const [active, setActive] = React3.useState(start < 0 ? TIME_SLOTS.length - 1 : start);
837
+ React3.useEffect(() => {
783
838
  const el = listRef.current?.querySelector(`[data-index="${active}"]`);
784
839
  el?.focus();
785
840
  el?.scrollIntoView?.({ block: "nearest" });
@@ -799,7 +854,7 @@ function TimeList({
799
854
  run();
800
855
  }
801
856
  };
802
- return /* @__PURE__ */ jsx2("div", { ref: listRef, role: "listbox", "aria-label": "Times", className: "matrx-date-panel matrx-time-list", onKeyDown, children: TIME_SLOTS.map((slot, i) => /* @__PURE__ */ jsx2(
857
+ return /* @__PURE__ */ jsx3("div", { ref: listRef, role: "listbox", "aria-label": "Times", className: "matrx-date-panel matrx-time-list", onKeyDown, children: TIME_SLOTS.map((slot, i) => /* @__PURE__ */ jsx3(
803
858
  "button",
804
859
  {
805
860
  type: "button",
@@ -818,7 +873,7 @@ function TimeList({
818
873
 
819
874
  // src/controls/number-stepper.tsx
820
875
  import { useState as useState3, useEffect as useEffect2 } from "react";
821
- import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
876
+ import { jsx as jsx4, jsxs as jsxs3 } from "react/jsx-runtime";
822
877
  function NumberStepper({
823
878
  value,
824
879
  onChange,
@@ -855,7 +910,7 @@ function NumberStepper({
855
910
  className
856
911
  ),
857
912
  children: [
858
- /* @__PURE__ */ jsx3(
913
+ /* @__PURE__ */ jsx4(
859
914
  "button",
860
915
  {
861
916
  type: "button",
@@ -866,10 +921,10 @@ function NumberStepper({
866
921
  className: cn(btnCls, "rounded-l-md border-r-0"),
867
922
  tabIndex: -1,
868
923
  "aria-label": "Decrease",
869
- children: /* @__PURE__ */ jsx3(MinusIcon, { width: 12, height: 12, strokeWidth: 2.25 })
924
+ children: /* @__PURE__ */ jsx4(MinusIcon, { width: 12, height: 12, strokeWidth: 2.25 })
870
925
  }
871
926
  ),
872
- /* @__PURE__ */ jsx3(
927
+ /* @__PURE__ */ jsx4(
873
928
  "input",
874
929
  {
875
930
  type: "text",
@@ -900,7 +955,7 @@ function NumberStepper({
900
955
  )
901
956
  }
902
957
  ),
903
- /* @__PURE__ */ jsx3(
958
+ /* @__PURE__ */ jsx4(
904
959
  "button",
905
960
  {
906
961
  type: "button",
@@ -911,7 +966,7 @@ function NumberStepper({
911
966
  className: cn(btnCls, "rounded-r-md border-l-0"),
912
967
  tabIndex: -1,
913
968
  "aria-label": "Increase",
914
- children: /* @__PURE__ */ jsx3(PlusIcon, { width: 12, height: 12, strokeWidth: 2.25 })
969
+ children: /* @__PURE__ */ jsx4(PlusIcon, { width: 12, height: 12, strokeWidth: 2.25 })
915
970
  }
916
971
  )
917
972
  ]
@@ -920,7 +975,7 @@ function NumberStepper({
920
975
  }
921
976
 
922
977
  // src/controls/stage-steps.tsx
923
- import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
978
+ import { jsx as jsx5, jsxs as jsxs4 } from "react/jsx-runtime";
924
979
  function stageSlots(count, current, maxVisible) {
925
980
  const all = Array.from({ length: count }, (_, index) => ({ kind: "step", index }));
926
981
  if (!maxVisible || count <= Math.max(5, maxVisible)) return all;
@@ -943,7 +998,7 @@ function stageStates(count, current) {
943
998
  function StageSteps({ steps, current, labels = "all", maxVisible, className, ...props }) {
944
999
  const states = stageStates(steps.length, current);
945
1000
  const slots = stageSlots(steps.length, current, maxVisible);
946
- return /* @__PURE__ */ jsx4("ol", { "data-matrx-control": "stage-steps", "data-labels": labels, className: cn("matrx-stage-steps", className), ...props, children: slots.map((slot, n) => {
1001
+ return /* @__PURE__ */ jsx5("ol", { "data-matrx-control": "stage-steps", "data-labels": labels, className: cn("matrx-stage-steps", className), ...props, children: slots.map((slot, n) => {
947
1002
  if (slot.kind === "more") {
948
1003
  const hidden = steps.slice(slot.from, slot.to + 1);
949
1004
  const state2 = states[slot.from];
@@ -957,7 +1012,7 @@ function StageSteps({ steps, current, labels = "all", maxVisible, className, ...
957
1012
  "aria-label": `${hidden.length} more steps: ${names}`,
958
1013
  className: "matrx-stage-steps-item",
959
1014
  children: [
960
- n > 0 ? /* @__PURE__ */ jsx4("span", { className: "matrx-stage-steps-sep", "aria-hidden": "true" }) : null,
1015
+ n > 0 ? /* @__PURE__ */ jsx5("span", { className: "matrx-stage-steps-sep", "aria-hidden": "true" }) : null,
961
1016
  /* @__PURE__ */ jsxs4("span", { className: "matrx-stage-steps-more", "aria-hidden": "true", children: [
962
1017
  "+",
963
1018
  hidden.length
@@ -979,11 +1034,11 @@ function StageSteps({ steps, current, labels = "all", maxVisible, className, ...
979
1034
  title: step.label,
980
1035
  className: "matrx-stage-steps-item",
981
1036
  children: [
982
- n > 0 ? /* @__PURE__ */ jsx4("span", { className: "matrx-stage-steps-sep", "aria-hidden": "true" }) : null,
983
- /* @__PURE__ */ jsx4("span", { className: "matrx-stage-steps-mark", "aria-hidden": "true", children: state === "done" ? /* @__PURE__ */ jsx4(RadixCheckIcon, {}) : i + 1 }),
1037
+ n > 0 ? /* @__PURE__ */ jsx5("span", { className: "matrx-stage-steps-sep", "aria-hidden": "true" }) : null,
1038
+ /* @__PURE__ */ jsx5("span", { className: "matrx-stage-steps-mark", "aria-hidden": "true", children: state === "done" ? /* @__PURE__ */ jsx5(RadixCheckIcon, {}) : i + 1 }),
984
1039
  /* @__PURE__ */ jsxs4("span", { className: "matrx-stage-steps-label", children: [
985
1040
  step.label,
986
- state === "done" ? /* @__PURE__ */ jsx4("span", { className: "matrx-sr-only", children: " (done)" }) : null
1041
+ state === "done" ? /* @__PURE__ */ jsx5("span", { className: "matrx-sr-only", children: " (done)" }) : null
987
1042
  ] })
988
1043
  ]
989
1044
  },
@@ -994,7 +1049,7 @@ function StageSteps({ steps, current, labels = "all", maxVisible, className, ...
994
1049
 
995
1050
  // src/controls/clamped-number-input.tsx
996
1051
  import { useEffect as useEffect3, useState as useState4 } from "react";
997
- import { jsx as jsx5 } from "react/jsx-runtime";
1052
+ import { jsx as jsx6 } from "react/jsx-runtime";
998
1053
  function shownDraft(raw, min, max, decimal = false) {
999
1054
  const next = clampDraft(raw, min, max, decimal);
1000
1055
  if (next === null) return null;
@@ -1039,7 +1094,7 @@ function ClampedNumberInput({
1039
1094
  setDraft(String(next));
1040
1095
  if (next !== value) onChange(next);
1041
1096
  };
1042
- return /* @__PURE__ */ jsx5(
1097
+ return /* @__PURE__ */ jsx6(
1043
1098
  Input,
1044
1099
  {
1045
1100
  id,
@@ -1071,13 +1126,13 @@ function ClampedNumberInput({
1071
1126
  }
1072
1127
 
1073
1128
  // src/controls/light-switch-toggle.tsx
1074
- import { useState as useState5, forwardRef as forwardRef2 } from "react";
1075
- import { jsx as jsx6, jsxs as jsxs5 } from "react/jsx-runtime";
1129
+ import { useState as useState5, forwardRef as forwardRef3 } from "react";
1130
+ import { jsx as jsx7, jsxs as jsxs5 } from "react/jsx-runtime";
1076
1131
  var defaultSizes = {
1077
1132
  width: "w-48",
1078
1133
  height: "h-16"
1079
1134
  };
1080
- var LightSwitchToggle = forwardRef2(
1135
+ var LightSwitchToggle = forwardRef3(
1081
1136
  ({
1082
1137
  variant,
1083
1138
  defaultValue = false,
@@ -1122,7 +1177,7 @@ var LightSwitchToggle = forwardRef2(
1122
1177
  isActive ? activeButtonClasses : inactiveButtonClasses
1123
1178
  ),
1124
1179
  children: [
1125
- /* @__PURE__ */ jsx6(
1180
+ /* @__PURE__ */ jsx7(
1126
1181
  "div",
1127
1182
  {
1128
1183
  className: cn(
@@ -1133,7 +1188,7 @@ var LightSwitchToggle = forwardRef2(
1133
1188
  )
1134
1189
  }
1135
1190
  ),
1136
- /* @__PURE__ */ jsx6(
1191
+ /* @__PURE__ */ jsx7(
1137
1192
  "span",
1138
1193
  {
1139
1194
  className: cn(
@@ -1146,8 +1201,8 @@ var LightSwitchToggle = forwardRef2(
1146
1201
  ]
1147
1202
  }
1148
1203
  );
1149
- return /* @__PURE__ */ jsx6("div", { className: "flex items-center justify-center", children: /* @__PURE__ */ jsxs5("div", { ref, className: containerClasses, children: [
1150
- /* @__PURE__ */ jsx6("div", { className: "absolute left-1/2 top-0 bottom-0 w-[2px] bg-border transform -translate-x-1/2 z-10" }),
1204
+ return /* @__PURE__ */ jsx7("div", { className: "flex items-center justify-center", children: /* @__PURE__ */ jsxs5("div", { ref, className: containerClasses, children: [
1205
+ /* @__PURE__ */ jsx7("div", { className: "absolute left-1/2 top-0 bottom-0 w-[2px] bg-border transform -translate-x-1/2 z-10" }),
1151
1206
  renderOption(!isOn, labels.off, "left", () => handleToggle(false)),
1152
1207
  renderOption(isOn, labels.on, "right", () => handleToggle(true))
1153
1208
  ] }) });
@@ -1157,7 +1212,7 @@ LightSwitchToggle.displayName = "LightSwitchToggle";
1157
1212
 
1158
1213
  // src/controls/option-combobox.tsx
1159
1214
  import { useState as useState6 } from "react";
1160
- import { jsx as jsx7, jsxs as jsxs6 } from "react/jsx-runtime";
1215
+ import { jsx as jsx8, jsxs as jsxs6 } from "react/jsx-runtime";
1161
1216
  function OptionCombobox({
1162
1217
  value,
1163
1218
  onChange,
@@ -1203,7 +1258,7 @@ function OptionCombobox({
1203
1258
  }
1204
1259
  },
1205
1260
  children: [
1206
- /* @__PURE__ */ jsx7(PopoverTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsxs6(
1261
+ /* @__PURE__ */ jsx8(PopoverTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsxs6(
1207
1262
  "button",
1208
1263
  {
1209
1264
  id,
@@ -1233,22 +1288,22 @@ function OptionCombobox({
1233
1288
  ),
1234
1289
  children: [
1235
1290
  hasValue ? getLabel(value) : placeholder,
1236
- hint && /* @__PURE__ */ jsx7("span", { className: "ml-1.5 text-muted-foreground", children: hint })
1291
+ hint && /* @__PURE__ */ jsx8("span", { className: "ml-1.5 text-muted-foreground", children: hint })
1237
1292
  ]
1238
1293
  }
1239
1294
  ),
1240
- /* @__PURE__ */ jsx7(SelectChevron, { size: "sm", className: variant === "inline" ? "h-3 w-3" : void 0 })
1295
+ /* @__PURE__ */ jsx8(SelectChevron, { size: "sm", className: variant === "inline" ? "h-3 w-3" : void 0 })
1241
1296
  ]
1242
1297
  }
1243
1298
  ) }),
1244
- /* @__PURE__ */ jsx7(
1299
+ /* @__PURE__ */ jsx8(
1245
1300
  PopoverContent,
1246
1301
  {
1247
1302
  sizing: "content",
1248
1303
  align: "start",
1249
1304
  className: "p-0",
1250
1305
  children: /* @__PURE__ */ jsxs6(Command, { shouldFilter: false, children: [
1251
- searchable && /* @__PURE__ */ jsx7(
1306
+ searchable && /* @__PURE__ */ jsx8(
1252
1307
  CommandInput,
1253
1308
  {
1254
1309
  placeholder: searchPlaceholder,
@@ -1267,21 +1322,21 @@ function OptionCombobox({
1267
1322
  if (visible.length === 0) return null;
1268
1323
  const folded = group.collapsed && !showMore && !q && !group.options.includes(value);
1269
1324
  if (folded) {
1270
- return /* @__PURE__ */ jsx7(CommandGroup, { children: /* @__PURE__ */ jsxs6(
1325
+ return /* @__PURE__ */ jsx8(CommandGroup, { children: /* @__PURE__ */ jsxs6(
1271
1326
  CommandItem,
1272
1327
  {
1273
1328
  value: `__more_${gi}`,
1274
1329
  onSelect: () => setShowMore(true),
1275
1330
  className: "text-muted-foreground",
1276
1331
  children: [
1277
- /* @__PURE__ */ jsx7(ChevronRightIcon, { className: "h-3.5 w-3.5" }),
1332
+ /* @__PURE__ */ jsx8(ChevronRightIcon, { className: "h-3.5 w-3.5" }),
1278
1333
  group.heading ?? "More",
1279
- /* @__PURE__ */ jsx7("span", { className: "ml-auto type-secondary tabular-nums", children: group.options.length })
1334
+ /* @__PURE__ */ jsx8("span", { className: "ml-auto type-secondary tabular-nums", children: group.options.length })
1280
1335
  ]
1281
1336
  }
1282
1337
  ) }, `g-${gi}`);
1283
1338
  }
1284
- return /* @__PURE__ */ jsx7(CommandGroup, { heading: group.heading, children: visible.map((o) => {
1339
+ return /* @__PURE__ */ jsx8(CommandGroup, { heading: group.heading, children: visible.map((o) => {
1285
1340
  const selected = o === value;
1286
1341
  const h = getHint?.(o);
1287
1342
  return /* @__PURE__ */ jsxs6(
@@ -1294,9 +1349,9 @@ function OptionCombobox({
1294
1349
  renderIcon?.(o),
1295
1350
  /* @__PURE__ */ jsxs6("span", { className: "min-w-0 flex-1 truncate", children: [
1296
1351
  getLabel(o),
1297
- h && /* @__PURE__ */ jsx7("span", { className: "ml-1.5 text-muted-foreground", children: h })
1352
+ h && /* @__PURE__ */ jsx8("span", { className: "ml-1.5 text-muted-foreground", children: h })
1298
1353
  ] }),
1299
- /* @__PURE__ */ jsx7(
1354
+ /* @__PURE__ */ jsx8(
1300
1355
  CheckIcon,
1301
1356
  {
1302
1357
  className: cn(
@@ -1398,7 +1453,7 @@ function groupRatioOptions(options) {
1398
1453
  }
1399
1454
 
1400
1455
  // src/controls/aspect-ratio-select.tsx
1401
- import { jsx as jsx8 } from "react/jsx-runtime";
1456
+ import { jsx as jsx9 } from "react/jsx-runtime";
1402
1457
  function AspectRatioGlyph({
1403
1458
  value,
1404
1459
  className
@@ -1406,7 +1461,7 @@ function AspectRatioGlyph({
1406
1461
  const r = parseRatio(value);
1407
1462
  const box = 14;
1408
1463
  if (!r) {
1409
- return /* @__PURE__ */ jsx8(
1464
+ return /* @__PURE__ */ jsx9(
1410
1465
  "span",
1411
1466
  {
1412
1467
  "aria-hidden": true,
@@ -1414,14 +1469,14 @@ function AspectRatioGlyph({
1414
1469
  "inline-flex h-3.5 w-3.5 shrink-0 items-center justify-center",
1415
1470
  className
1416
1471
  ),
1417
- children: /* @__PURE__ */ jsx8("span", { className: "h-2.5 w-2.5 rounded-[2px] border border-dashed border-current opacity-60" })
1472
+ children: /* @__PURE__ */ jsx9("span", { className: "h-2.5 w-2.5 rounded-[2px] border border-dashed border-current opacity-60" })
1418
1473
  }
1419
1474
  );
1420
1475
  }
1421
1476
  const k = r.w / r.h;
1422
1477
  const w = k >= 1 ? box : Math.max(3, box * k);
1423
1478
  const h = k >= 1 ? Math.max(3, box / k) : box;
1424
- return /* @__PURE__ */ jsx8(
1479
+ return /* @__PURE__ */ jsx9(
1425
1480
  "span",
1426
1481
  {
1427
1482
  "aria-hidden": true,
@@ -1429,7 +1484,7 @@ function AspectRatioGlyph({
1429
1484
  "inline-flex h-3.5 w-3.5 shrink-0 items-center justify-center",
1430
1485
  className
1431
1486
  ),
1432
- children: /* @__PURE__ */ jsx8(
1487
+ children: /* @__PURE__ */ jsx9(
1433
1488
  "span",
1434
1489
  {
1435
1490
  className: "rounded-[2px] border-[1.5px] border-current opacity-80",
@@ -1456,7 +1511,7 @@ function AspectRatioSelect({
1456
1511
  { options: common },
1457
1512
  ...more.length ? [{ heading: "More ratios", options: more, collapsed: true }] : []
1458
1513
  ];
1459
- return /* @__PURE__ */ jsx8(
1514
+ return /* @__PURE__ */ jsx9(
1460
1515
  OptionCombobox,
1461
1516
  {
1462
1517
  value,
@@ -1464,7 +1519,7 @@ function AspectRatioSelect({
1464
1519
  groups,
1465
1520
  getLabel: (o) => parseRatio(o) ? o : humanizeRatioWord(o),
1466
1521
  getHint: (o) => ratioShapeName(o),
1467
- renderIcon: (o) => /* @__PURE__ */ jsx8(AspectRatioGlyph, { value: o, className: "text-muted-foreground" }),
1522
+ renderIcon: (o) => /* @__PURE__ */ jsx9(AspectRatioGlyph, { value: o, className: "text-muted-foreground" }),
1468
1523
  searchable: options.length > 12,
1469
1524
  searchPlaceholder: "Search ratios\u2026",
1470
1525
  placeholder,
@@ -1478,7 +1533,7 @@ function AspectRatioSelect({
1478
1533
  }
1479
1534
 
1480
1535
  // src/indicator-strip.tsx
1481
- import { jsx as jsx9 } from "react/jsx-runtime";
1536
+ import { jsx as jsx10 } from "react/jsx-runtime";
1482
1537
  var TONE = {
1483
1538
  danger: "text-destructive",
1484
1539
  warning: "text-warning",
@@ -1491,7 +1546,7 @@ function indicatorText(item) {
1491
1546
  return item.detail ? `${item.label}: yes \u2014 ${item.detail}` : `${item.label}: yes`;
1492
1547
  }
1493
1548
  function IndicatorStrip({ items, className, ...props }) {
1494
- return /* @__PURE__ */ jsx9(
1549
+ return /* @__PURE__ */ jsx10(
1495
1550
  "span",
1496
1551
  {
1497
1552
  "data-slot": "indicator-strip",
@@ -1501,7 +1556,7 @@ function IndicatorStrip({ items, className, ...props }) {
1501
1556
  children: items.map((item) => {
1502
1557
  const Icon = item.icon;
1503
1558
  const text = indicatorText(item);
1504
- return /* @__PURE__ */ jsx9(
1559
+ return /* @__PURE__ */ jsx10(
1505
1560
  "span",
1506
1561
  {
1507
1562
  role: "listitem",
@@ -1514,7 +1569,7 @@ function IndicatorStrip({ items, className, ...props }) {
1514
1569
  item.on ? TONE[item.tone ?? "warning"] : "text-muted-foreground opacity-30",
1515
1570
  item.on && item.soft && "opacity-55"
1516
1571
  ),
1517
- children: /* @__PURE__ */ jsx9(Icon, { className: "size-3.5", "aria-hidden": true })
1572
+ children: /* @__PURE__ */ jsx10(Icon, { className: "size-3.5", "aria-hidden": true })
1518
1573
  },
1519
1574
  item.id
1520
1575
  );
@@ -1524,7 +1579,7 @@ function IndicatorStrip({ items, className, ...props }) {
1524
1579
  }
1525
1580
 
1526
1581
  // src/controls/middle-truncate.tsx
1527
- import { jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
1582
+ import { jsx as jsx11, jsxs as jsxs7 } from "react/jsx-runtime";
1528
1583
  var DEFAULT_TAIL = 10;
1529
1584
  function splitForMiddleTruncate(text, tail = DEFAULT_TAIL) {
1530
1585
  const keep = Math.min(tail, Math.floor(text.length / 2));
@@ -1538,14 +1593,14 @@ function MiddleTruncate({
1538
1593
  }) {
1539
1594
  const { head, end } = splitForMiddleTruncate(text, tail);
1540
1595
  return /* @__PURE__ */ jsxs7("span", { className: cn("flex min-w-0 items-baseline", className), title: text, children: [
1541
- /* @__PURE__ */ jsx10("span", { className: "sr-only", children: text }),
1542
- /* @__PURE__ */ jsx10("span", { "aria-hidden": true, className: "min-w-0 truncate whitespace-pre", children: head }),
1543
- end ? /* @__PURE__ */ jsx10("span", { "aria-hidden": true, className: "shrink-0 whitespace-pre", children: end }) : null
1596
+ /* @__PURE__ */ jsx11("span", { className: "sr-only", children: text }),
1597
+ /* @__PURE__ */ jsx11("span", { "aria-hidden": true, className: "min-w-0 truncate whitespace-pre", children: head }),
1598
+ end ? /* @__PURE__ */ jsx11("span", { "aria-hidden": true, className: "shrink-0 whitespace-pre", children: end }) : null
1544
1599
  ] });
1545
1600
  }
1546
1601
 
1547
1602
  // src/controls/callout-banner.tsx
1548
- import { jsx as jsx11, jsxs as jsxs8 } from "react/jsx-runtime";
1603
+ import { jsx as jsx12, jsxs as jsxs8 } from "react/jsx-runtime";
1549
1604
  var TONE2 = {
1550
1605
  destructive: { container: "border-destructive/30 bg-destructive/10", icon: "text-destructive" },
1551
1606
  warning: { container: "border-warning/30 bg-warning/10", icon: "text-warning" },
@@ -1574,15 +1629,15 @@ function CalloutBanner({
1574
1629
  role: "status",
1575
1630
  children: [
1576
1631
  /* @__PURE__ */ jsxs8("div", { className: "flex min-w-0 flex-1 items-start gap-2", children: [
1577
- Icon && /* @__PURE__ */ jsx11(Icon, { className: cn("mt-0.5 h-4 w-4 shrink-0", t.icon), "aria-hidden": true }),
1632
+ Icon && /* @__PURE__ */ jsx12(Icon, { className: cn("mt-0.5 h-4 w-4 shrink-0", t.icon), "aria-hidden": true }),
1578
1633
  /* @__PURE__ */ jsxs8("div", { className: "min-w-0", children: [
1579
- /* @__PURE__ */ jsx11("p", { className: "type-title text-foreground", children: title }),
1580
- description && /* @__PURE__ */ jsx11("p", { className: "mt-0.5 type-secondary text-muted-foreground", children: description })
1634
+ /* @__PURE__ */ jsx12("p", { className: "type-title text-foreground", children: title }),
1635
+ description && /* @__PURE__ */ jsx12("p", { className: "mt-0.5 type-secondary text-muted-foreground", children: description })
1581
1636
  ] })
1582
1637
  ] }),
1583
1638
  /* @__PURE__ */ jsxs8("div", { className: "flex shrink-0 items-center gap-1.5 sm:ml-2", children: [
1584
1639
  actions,
1585
- onDismiss && /* @__PURE__ */ jsx11(Button2, { variant: "quiet", icon: /* @__PURE__ */ jsx11(XIcon, {}), "aria-label": "Dismiss", onClick: onDismiss, disabled: dismissing })
1640
+ onDismiss && /* @__PURE__ */ jsx12(Button2, { variant: "quiet", icon: /* @__PURE__ */ jsx12(XIcon, {}), "aria-label": "Dismiss", onClick: onDismiss, disabled: dismissing })
1586
1641
  ] })
1587
1642
  ]
1588
1643
  }
@@ -1590,8 +1645,8 @@ function CalloutBanner({
1590
1645
  }
1591
1646
 
1592
1647
  // src/controls/gated-action-button.tsx
1593
- import * as React3 from "react";
1594
- import { jsx as jsx12, jsxs as jsxs9 } from "react/jsx-runtime";
1648
+ import * as React4 from "react";
1649
+ import { jsx as jsx13, jsxs as jsxs9 } from "react/jsx-runtime";
1595
1650
  function firstBlockingReason(checks) {
1596
1651
  for (const check of checks) {
1597
1652
  if (check && check.when) return check.reason;
@@ -1607,7 +1662,7 @@ function GatedActionButton({
1607
1662
  children,
1608
1663
  ...buttonProps
1609
1664
  }) {
1610
- const reactId = React3.useId();
1665
+ const reactId = React4.useId();
1611
1666
  const blocked = Boolean(reason && reason.trim());
1612
1667
  const reasonId = `gated-action-reason-${reactId}`;
1613
1668
  return /* @__PURE__ */ jsxs9(
@@ -1618,7 +1673,7 @@ function GatedActionButton({
1618
1673
  wrapperClassName
1619
1674
  ),
1620
1675
  children: [
1621
- blocked ? /* @__PURE__ */ jsx12(
1676
+ blocked ? /* @__PURE__ */ jsx13(
1622
1677
  "span",
1623
1678
  {
1624
1679
  id: reasonId,
@@ -1631,7 +1686,7 @@ function GatedActionButton({
1631
1686
  children: reason
1632
1687
  }
1633
1688
  ) : null,
1634
- /* @__PURE__ */ jsx12(
1689
+ /* @__PURE__ */ jsx13(
1635
1690
  Button,
1636
1691
  {
1637
1692
  ...buttonProps,
@@ -1649,7 +1704,7 @@ GatedActionButton.displayName = "GatedActionButton";
1649
1704
 
1650
1705
  // src/controls/search-input.tsx
1651
1706
  import { useEffect as useEffect4, useRef as useRef2, useState as useState7 } from "react";
1652
- import { jsx as jsx13, jsxs as jsxs10 } from "react/jsx-runtime";
1707
+ import { jsx as jsx14, jsxs as jsxs10 } from "react/jsx-runtime";
1653
1708
  function SearchInput({
1654
1709
  value,
1655
1710
  defaultValue = "",
@@ -1712,14 +1767,14 @@ function SearchInput({
1712
1767
  className: cn("flex min-w-0 items-center gap-2", className),
1713
1768
  children: [
1714
1769
  /* @__PURE__ */ jsxs10("div", { className: "relative min-w-0 flex-1", children: [
1715
- /* @__PURE__ */ jsx13(
1770
+ /* @__PURE__ */ jsx14(
1716
1771
  SearchIcon,
1717
1772
  {
1718
1773
  className: "pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground",
1719
1774
  "aria-hidden": true
1720
1775
  }
1721
1776
  ),
1722
- /* @__PURE__ */ jsx13(
1777
+ /* @__PURE__ */ jsx14(
1723
1778
  Input,
1724
1779
  {
1725
1780
  ref: inputRef,
@@ -1733,7 +1788,7 @@ function SearchInput({
1733
1788
  adornment: showClearButton && searchValue ? "both" : "start"
1734
1789
  }
1735
1790
  ),
1736
- showClearButton && searchValue ? /* @__PURE__ */ jsx13(
1791
+ showClearButton && searchValue ? /* @__PURE__ */ jsx14(
1737
1792
  "button",
1738
1793
  {
1739
1794
  type: "button",
@@ -1741,14 +1796,14 @@ function SearchInput({
1741
1796
  disabled,
1742
1797
  "aria-label": "Clear search",
1743
1798
  className: "absolute right-2 top-1/2 flex h-6 w-6 -translate-y-1/2 items-center justify-center rounded text-muted-foreground transition-colors hover:bg-accent hover:text-foreground disabled:pointer-events-none disabled:text-disabled-foreground",
1744
- children: /* @__PURE__ */ jsx13(XIcon, { className: "h-3.5 w-3.5" })
1799
+ children: /* @__PURE__ */ jsx14(XIcon, { className: "h-3.5 w-3.5" })
1745
1800
  }
1746
1801
  ) : null
1747
1802
  ] }),
1748
- showSubmitButton ? /* @__PURE__ */ jsx13(
1803
+ showSubmitButton ? /* @__PURE__ */ jsx14(
1749
1804
  Button2,
1750
1805
  {
1751
- icon: loading ? /* @__PURE__ */ jsx13(Loader2Icon, { className: "animate-spin" }) : /* @__PURE__ */ jsx13(SearchIcon, {}),
1806
+ icon: loading ? /* @__PURE__ */ jsx14(Loader2Icon, { className: "animate-spin" }) : /* @__PURE__ */ jsx14(SearchIcon, {}),
1752
1807
  variant: "primary",
1753
1808
  type: "submit",
1754
1809
  disabled: disabled || loading,
@@ -1763,7 +1818,7 @@ function SearchInput({
1763
1818
 
1764
1819
  // src/controls/collapsible-text.tsx
1765
1820
  import { useLayoutEffect, useRef as useRef3, useState as useState8 } from "react";
1766
- import { jsx as jsx14, jsxs as jsxs11 } from "react/jsx-runtime";
1821
+ import { jsx as jsx15, jsxs as jsxs11 } from "react/jsx-runtime";
1767
1822
  function CollapsibleText({
1768
1823
  children,
1769
1824
  expanded,
@@ -1798,7 +1853,7 @@ function CollapsibleText({
1798
1853
  const isCollapsed = isOverflowing && !expanded;
1799
1854
  if (showLabel) {
1800
1855
  return /* @__PURE__ */ jsxs11("div", { className: "relative min-w-0", children: [
1801
- /* @__PURE__ */ jsx14(
1856
+ /* @__PURE__ */ jsx15(
1802
1857
  "div",
1803
1858
  {
1804
1859
  ref: contentRef,
@@ -1822,7 +1877,7 @@ function CollapsibleText({
1822
1877
  },
1823
1878
  className: "mt-0.5 inline-flex min-h-6 items-center gap-0.5 rounded text-xs font-medium text-primary hover:underline focus-visible:outline focus-visible:outline-2 focus-visible:outline-ring",
1824
1879
  children: [
1825
- isCollapsed ? /* @__PURE__ */ jsx14(ChevronDownIcon, { className: "h-3.5 w-3.5", "aria-hidden": true }) : /* @__PURE__ */ jsx14(ChevronUpIcon, { className: "h-3.5 w-3.5", "aria-hidden": true }),
1880
+ isCollapsed ? /* @__PURE__ */ jsx15(ChevronDownIcon, { className: "h-3.5 w-3.5", "aria-hidden": true }) : /* @__PURE__ */ jsx15(ChevronUpIcon, { className: "h-3.5 w-3.5", "aria-hidden": true }),
1826
1881
  isCollapsed ? expandLabel : collapseLabel
1827
1882
  ]
1828
1883
  }
@@ -1830,7 +1885,7 @@ function CollapsibleText({
1830
1885
  ] });
1831
1886
  }
1832
1887
  return /* @__PURE__ */ jsxs11("div", { className: "relative min-w-0", children: [
1833
- /* @__PURE__ */ jsx14(
1888
+ /* @__PURE__ */ jsx15(
1834
1889
  "div",
1835
1890
  {
1836
1891
  ref: contentRef,
@@ -1843,10 +1898,10 @@ function CollapsibleText({
1843
1898
  children
1844
1899
  }
1845
1900
  ),
1846
- isCollapsed ? /* @__PURE__ */ jsx14("div", { className: "pointer-events-none absolute inset-x-0 bottom-0 flex justify-center", children: /* @__PURE__ */ jsx14(
1901
+ isCollapsed ? /* @__PURE__ */ jsx15("div", { className: "pointer-events-none absolute inset-x-0 bottom-0 flex justify-center", children: /* @__PURE__ */ jsx15(
1847
1902
  Button2,
1848
1903
  {
1849
- icon: /* @__PURE__ */ jsx14(ChevronDownIcon, {}),
1904
+ icon: /* @__PURE__ */ jsx15(ChevronDownIcon, {}),
1850
1905
  type: "button",
1851
1906
  variant: "outline",
1852
1907
  "aria-label": expandLabel,
@@ -1857,10 +1912,10 @@ function CollapsibleText({
1857
1912
  },
1858
1913
  className: "pointer-events-auto"
1859
1914
  }
1860
- ) }) : isOverflowing ? /* @__PURE__ */ jsx14("div", { className: "flex justify-center pt-0.5", children: /* @__PURE__ */ jsx14(
1915
+ ) }) : isOverflowing ? /* @__PURE__ */ jsx15("div", { className: "flex justify-center pt-0.5", children: /* @__PURE__ */ jsx15(
1861
1916
  Button2,
1862
1917
  {
1863
- icon: /* @__PURE__ */ jsx14(ChevronUpIcon, {}),
1918
+ icon: /* @__PURE__ */ jsx15(ChevronUpIcon, {}),
1864
1919
  type: "button",
1865
1920
  variant: "quiet",
1866
1921
  "aria-label": collapseLabel,
@@ -1882,10 +1937,10 @@ function CollapsibleTextGroupControls({
1882
1937
  }) {
1883
1938
  return /* @__PURE__ */ jsxs11("div", { className: "flex items-center gap-0.5", children: [
1884
1939
  /* @__PURE__ */ jsxs11(Tooltip, { children: [
1885
- /* @__PURE__ */ jsx14(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx14(
1940
+ /* @__PURE__ */ jsx15(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx15(
1886
1941
  Button2,
1887
1942
  {
1888
- icon: /* @__PURE__ */ jsx14(ChevronsDownIcon, { className: "!size-[18px] lg:!size-3.5" }),
1943
+ icon: /* @__PURE__ */ jsx15(ChevronsDownIcon, { className: "!size-[18px] lg:!size-3.5" }),
1889
1944
  type: "button",
1890
1945
  variant: "quiet",
1891
1946
  "aria-label": "Expand all",
@@ -1893,13 +1948,13 @@ function CollapsibleTextGroupControls({
1893
1948
  disabled: disabled || allExpanded
1894
1949
  }
1895
1950
  ) }),
1896
- /* @__PURE__ */ jsx14(TooltipContent, { side: "top", children: "Expand all" })
1951
+ /* @__PURE__ */ jsx15(TooltipContent, { side: "top", children: "Expand all" })
1897
1952
  ] }),
1898
1953
  /* @__PURE__ */ jsxs11(Tooltip, { children: [
1899
- /* @__PURE__ */ jsx14(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx14(
1954
+ /* @__PURE__ */ jsx15(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx15(
1900
1955
  Button2,
1901
1956
  {
1902
- icon: /* @__PURE__ */ jsx14(ChevronsUpIcon, { className: "!size-[18px] lg:!size-3.5" }),
1957
+ icon: /* @__PURE__ */ jsx15(ChevronsUpIcon, { className: "!size-[18px] lg:!size-3.5" }),
1903
1958
  type: "button",
1904
1959
  variant: "quiet",
1905
1960
  "aria-label": "Collapse all",
@@ -1907,14 +1962,14 @@ function CollapsibleTextGroupControls({
1907
1962
  disabled: disabled || !anyExpanded
1908
1963
  }
1909
1964
  ) }),
1910
- /* @__PURE__ */ jsx14(TooltipContent, { side: "top", children: "Collapse all" })
1965
+ /* @__PURE__ */ jsx15(TooltipContent, { side: "top", children: "Collapse all" })
1911
1966
  ] })
1912
1967
  ] });
1913
1968
  }
1914
1969
 
1915
1970
  // src/controls/info-hint.tsx
1916
1971
  import { useState as useState9, useSyncExternalStore } from "react";
1917
- import { jsx as jsx15, jsxs as jsxs12 } from "react/jsx-runtime";
1972
+ import { jsx as jsx16, jsxs as jsxs12 } from "react/jsx-runtime";
1918
1973
  var COARSE_POINTER_QUERY = "(pointer: coarse)";
1919
1974
  function subscribeCoarse(onChange) {
1920
1975
  const mq = window.matchMedia(COARSE_POINTER_QUERY);
@@ -1938,10 +1993,10 @@ function InfoHint({ text, label = "More info", className, side = "top" }) {
1938
1993
  const coarse = useCoarsePointer();
1939
1994
  const isMobile = useIsMobile();
1940
1995
  const [open, setOpen] = useState9(false);
1941
- const glyph = /* @__PURE__ */ jsx15(InfoIcon, { "aria-hidden": true, className: "h-3.5 w-3.5", strokeWidth: 2 });
1996
+ const glyph = /* @__PURE__ */ jsx16(InfoIcon, { "aria-hidden": true, className: "h-3.5 w-3.5", strokeWidth: 2 });
1942
1997
  if (coarse || isMobile) {
1943
1998
  return /* @__PURE__ */ jsxs12(Popover, { open, onOpenChange: setOpen, children: [
1944
- /* @__PURE__ */ jsx15(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx15(
1999
+ /* @__PURE__ */ jsx16(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx16(
1945
2000
  "button",
1946
2001
  {
1947
2002
  type: "button",
@@ -1955,7 +2010,7 @@ function InfoHint({ text, label = "More info", className, side = "top" }) {
1955
2010
  children: glyph
1956
2011
  }
1957
2012
  ) }),
1958
- /* @__PURE__ */ jsx15(
2013
+ /* @__PURE__ */ jsx16(
1959
2014
  PopoverContent,
1960
2015
  {
1961
2016
  side,
@@ -1972,8 +2027,8 @@ function InfoHint({ text, label = "More info", className, side = "top" }) {
1972
2027
  return (
1973
2028
  // Brings its own provider: an official component works wherever it is imported (a
1974
2029
  // test, a portal, a page without the app shell) — 2026-09-30, final-switch tests.
1975
- /* @__PURE__ */ jsx15(TooltipProvider, { delayDuration: 200, children: /* @__PURE__ */ jsxs12(Tooltip, { open, onOpenChange: setOpen, children: [
1976
- /* @__PURE__ */ jsx15(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx15(
2030
+ /* @__PURE__ */ jsx16(TooltipProvider, { delayDuration: 200, children: /* @__PURE__ */ jsxs12(Tooltip, { open, onOpenChange: setOpen, children: [
2031
+ /* @__PURE__ */ jsx16(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx16(
1977
2032
  "button",
1978
2033
  {
1979
2034
  type: "button",
@@ -1989,13 +2044,13 @@ function InfoHint({ text, label = "More info", className, side = "top" }) {
1989
2044
  children: glyph
1990
2045
  }
1991
2046
  ) }),
1992
- /* @__PURE__ */ jsx15(TooltipContent, { side, className: CONTENT_CLASS, onClick: isolate, children: text })
2047
+ /* @__PURE__ */ jsx16(TooltipContent, { side, className: CONTENT_CLASS, onClick: isolate, children: text })
1993
2048
  ] }) })
1994
2049
  );
1995
2050
  }
1996
2051
 
1997
2052
  // src/controls/status-badge.tsx
1998
- import { jsx as jsx16, jsxs as jsxs13 } from "react/jsx-runtime";
2053
+ import { jsx as jsx17, jsxs as jsxs13 } from "react/jsx-runtime";
1999
2054
  var STATUS_TONES = ["success", "warning", "danger", "neutral", "info"];
2000
2055
  var TONE_CLASS = {
2001
2056
  success: "border-success/40 bg-success/15 text-success-ink",
@@ -2027,7 +2082,7 @@ function StatusBadge({ label, tone: tone2, icon: Icon, size = "md", title, trail
2027
2082
  className
2028
2083
  ),
2029
2084
  children: [
2030
- Icon ? /* @__PURE__ */ jsx16(Icon, { "aria-hidden": true, className: cn("shrink-0", s.icon) }) : null,
2085
+ Icon ? /* @__PURE__ */ jsx17(Icon, { "aria-hidden": true, className: cn("shrink-0", s.icon) }) : null,
2031
2086
  label,
2032
2087
  trailing
2033
2088
  ]
@@ -2036,8 +2091,8 @@ function StatusBadge({ label, tone: tone2, icon: Icon, size = "md", title, trail
2036
2091
  }
2037
2092
 
2038
2093
  // src/controls/structured-section-card.tsx
2039
- import * as React5 from "react";
2040
- import { jsx as jsx17, jsxs as jsxs14 } from "react/jsx-runtime";
2094
+ import * as React6 from "react";
2095
+ import { jsx as jsx18, jsxs as jsxs14 } from "react/jsx-runtime";
2041
2096
  var TITLE_TONE = {
2042
2097
  primary: "text-primary-ink",
2043
2098
  foreground: "text-foreground"
@@ -2062,16 +2117,16 @@ function StructuredSectionCard({
2062
2117
  children: [
2063
2118
  /* @__PURE__ */ jsxs14("div", { className: "flex items-center justify-between border-b border-border bg-muted px-4 py-3", children: [
2064
2119
  /* @__PURE__ */ jsxs14("div", { className: "min-w-0", children: [
2065
- /* @__PURE__ */ jsx17("h3", { className: cn("font-medium", TITLE_TONE[titleTone]), children: title }),
2066
- description && /* @__PURE__ */ jsx17("p", { className: "type-body text-muted-foreground", children: description })
2120
+ /* @__PURE__ */ jsx18("h3", { className: cn("font-medium", TITLE_TONE[titleTone]), children: title }),
2121
+ description && /* @__PURE__ */ jsx18("p", { className: "type-body text-muted-foreground", children: description })
2067
2122
  ] }),
2068
- headerActions.length > 0 && /* @__PURE__ */ jsx17("div", { className: "ml-4 flex shrink-0 items-center space-x-2", children: headerActions.map((action, index) => /* @__PURE__ */ jsx17(React5.Fragment, { children: action }, index)) })
2123
+ headerActions.length > 0 && /* @__PURE__ */ jsx18("div", { className: "ml-4 flex shrink-0 items-center space-x-2", children: headerActions.map((action, index) => /* @__PURE__ */ jsx18(React6.Fragment, { children: action }, index)) })
2069
2124
  ] }),
2070
- /* @__PURE__ */ jsx17("div", { className: "p-4", children }),
2125
+ /* @__PURE__ */ jsx18("div", { className: "p-4", children }),
2071
2126
  hasFooter && /* @__PURE__ */ jsxs14("div", { className: "flex flex-wrap items-center border-t border-border px-4 py-3", children: [
2072
- /* @__PURE__ */ jsx17("div", { className: "flex min-w-[33%] flex-1 justify-start space-x-2 sm:min-w-0", children: footerLeft }),
2073
- /* @__PURE__ */ jsx17("div", { className: "mt-2 flex min-w-[33%] flex-1 justify-center space-x-2 sm:mt-0 sm:min-w-0", children: footerCenter }),
2074
- /* @__PURE__ */ jsx17("div", { className: "mt-2 flex min-w-[33%] flex-1 justify-end space-x-2 sm:mt-0 sm:min-w-0", children: footerRight })
2127
+ /* @__PURE__ */ jsx18("div", { className: "flex min-w-[33%] flex-1 justify-start space-x-2 sm:min-w-0", children: footerLeft }),
2128
+ /* @__PURE__ */ jsx18("div", { className: "mt-2 flex min-w-[33%] flex-1 justify-center space-x-2 sm:mt-0 sm:min-w-0", children: footerCenter }),
2129
+ /* @__PURE__ */ jsx18("div", { className: "mt-2 flex min-w-[33%] flex-1 justify-end space-x-2 sm:mt-0 sm:min-w-0", children: footerRight })
2075
2130
  ] })
2076
2131
  ]
2077
2132
  }
@@ -2079,7 +2134,7 @@ function StructuredSectionCard({
2079
2134
  }
2080
2135
 
2081
2136
  // src/controls/icon-dropdown-menu.tsx
2082
- import { jsx as jsx18, jsxs as jsxs15 } from "react/jsx-runtime";
2137
+ import { jsx as jsx19, jsxs as jsxs15 } from "react/jsx-runtime";
2083
2138
  function IconDropdownMenu({
2084
2139
  options,
2085
2140
  value,
@@ -2095,17 +2150,17 @@ function IconDropdownMenu({
2095
2150
  return null;
2096
2151
  }
2097
2152
  return /* @__PURE__ */ jsxs15(DropdownMenu, { children: [
2098
- /* @__PURE__ */ jsx18(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsx18(
2153
+ /* @__PURE__ */ jsx19(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsx19(
2099
2154
  Button2,
2100
2155
  {
2101
- icon: /* @__PURE__ */ jsx18(SelectedIcon, {}),
2102
- iconEnd: /* @__PURE__ */ jsx18(ChevronDownIcon, {}),
2156
+ icon: /* @__PURE__ */ jsx19(SelectedIcon, {}),
2157
+ iconEnd: /* @__PURE__ */ jsx19(ChevronDownIcon, {}),
2103
2158
  variant: "outline",
2104
2159
  "aria-label": selected.label,
2105
2160
  ...className ? { className } : {}
2106
2161
  }
2107
2162
  ) }),
2108
- /* @__PURE__ */ jsx18(DropdownMenuContent, { align, className: cn("rounded-2xl p-1", menuWidth), children: options.map((option) => {
2163
+ /* @__PURE__ */ jsx19(DropdownMenuContent, { align, className: cn("rounded-2xl p-1", menuWidth), children: options.map((option) => {
2109
2164
  const isSelected = option.value === value;
2110
2165
  const OptionIcon = option.icon;
2111
2166
  return /* @__PURE__ */ jsxs15(
@@ -2118,9 +2173,9 @@ function IconDropdownMenu({
2118
2173
  isSelected && "bg-primary/10"
2119
2174
  ),
2120
2175
  children: [
2121
- /* @__PURE__ */ jsx18(OptionIcon, { className: cn("h-4 w-4 shrink-0", isSelected ? "text-primary-ink" : "text-muted-foreground") }),
2122
- /* @__PURE__ */ jsx18("span", { className: cn("type-body flex-1 leading-tight", isSelected ? "font-medium text-primary-ink" : "text-foreground"), children: option.label }),
2123
- isSelected && /* @__PURE__ */ jsx18(CheckIcon, { className: "h-4 w-4 shrink-0 text-primary-ink" })
2176
+ /* @__PURE__ */ jsx19(OptionIcon, { className: cn("h-4 w-4 shrink-0", isSelected ? "text-primary-ink" : "text-muted-foreground") }),
2177
+ /* @__PURE__ */ jsx19("span", { className: cn("type-body flex-1 leading-tight", isSelected ? "font-medium text-primary-ink" : "text-foreground"), children: option.label }),
2178
+ isSelected && /* @__PURE__ */ jsx19(CheckIcon, { className: "h-4 w-4 shrink-0 text-primary-ink" })
2124
2179
  ]
2125
2180
  },
2126
2181
  String(option.value)
@@ -2130,7 +2185,7 @@ function IconDropdownMenu({
2130
2185
  }
2131
2186
 
2132
2187
  // src/controls/field.tsx
2133
- import { jsx as jsx19, jsxs as jsxs16 } from "react/jsx-runtime";
2188
+ import { jsx as jsx20, jsxs as jsxs16 } from "react/jsx-runtime";
2134
2189
  function LabeledField({
2135
2190
  label,
2136
2191
  htmlFor,
@@ -2161,27 +2216,27 @@ function LabeledField({
2161
2216
  ),
2162
2217
  children: [
2163
2218
  label,
2164
- required && /* @__PURE__ */ jsx19("span", { className: "text-destructive ml-1", "aria-hidden": true, children: "*" }),
2165
- !required && optional && /* @__PURE__ */ jsx19("span", { className: "text-muted-foreground ml-1.5 type-secondary font-normal", children: "(optional)" })
2219
+ required && /* @__PURE__ */ jsx20("span", { className: "text-destructive ml-1", "aria-hidden": true, children: "*" }),
2220
+ !required && optional && /* @__PURE__ */ jsx20("span", { className: "text-muted-foreground ml-1.5 type-secondary font-normal", children: "(optional)" })
2166
2221
  ]
2167
2222
  }
2168
2223
  ),
2169
- typeof help === "string" && help && /* @__PURE__ */ jsx19(InfoHint, { text: help, label: typeof label === "string" ? `About ${label}` : "Help" }),
2170
- help && typeof help !== "string" && /* @__PURE__ */ jsx19(TooltipProvider, { delayDuration: 150, children: /* @__PURE__ */ jsxs16(Tooltip, { children: [
2171
- /* @__PURE__ */ jsx19(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx19(
2224
+ typeof help === "string" && help && /* @__PURE__ */ jsx20(InfoHint, { text: help, label: typeof label === "string" ? `About ${label}` : "Help" }),
2225
+ help && typeof help !== "string" && /* @__PURE__ */ jsx20(TooltipProvider, { delayDuration: 150, children: /* @__PURE__ */ jsxs16(Tooltip, { children: [
2226
+ /* @__PURE__ */ jsx20(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx20(
2172
2227
  "button",
2173
2228
  {
2174
2229
  type: "button",
2175
2230
  "aria-label": "Help",
2176
2231
  className: "inline-flex items-center justify-center h-4 w-4 rounded-full text-muted-foreground hover:text-foreground transition-colors",
2177
- children: /* @__PURE__ */ jsx19(CircleHelpIcon, { className: "h-3.5 w-3.5" })
2232
+ children: /* @__PURE__ */ jsx20(CircleHelpIcon, { className: "h-3.5 w-3.5" })
2178
2233
  }
2179
2234
  ) }),
2180
- /* @__PURE__ */ jsx19(TooltipContent, { side: "top", className: "max-w-xs type-secondary", children: help })
2235
+ /* @__PURE__ */ jsx20(TooltipContent, { side: "top", className: "max-w-xs type-secondary", children: help })
2181
2236
  ] }) })
2182
2237
  ] }),
2183
- description && !error && /* @__PURE__ */ jsx19("p", { className: "type-secondary text-muted-foreground", children: description }),
2184
- /* @__PURE__ */ jsx19(
2238
+ description && !error && /* @__PURE__ */ jsx20("p", { className: "type-secondary text-muted-foreground", children: description }),
2239
+ /* @__PURE__ */ jsx20(
2185
2240
  "div",
2186
2241
  {
2187
2242
  "data-slot": "field-control",
@@ -2205,9 +2260,9 @@ function LabeledField({
2205
2260
  ),
2206
2261
  children: [
2207
2262
  error ? /* @__PURE__ */ jsxs16("p", { className: "type-secondary text-destructive flex items-center gap-1", children: [
2208
- /* @__PURE__ */ jsx19(CircleAlertIcon, { className: "h-3 w-3 flex-shrink-0" }),
2209
- /* @__PURE__ */ jsx19("span", { children: error }),
2210
- /* @__PURE__ */ jsx19(
2263
+ /* @__PURE__ */ jsx20(CircleAlertIcon, { className: "h-3 w-3 flex-shrink-0" }),
2264
+ /* @__PURE__ */ jsx20("span", { children: error }),
2265
+ /* @__PURE__ */ jsx20(
2211
2266
  ErrorActions,
2212
2267
  {
2213
2268
  ...typeof error === "string" ? { message: error } : {},
@@ -2221,12 +2276,12 @@ function LabeledField({
2221
2276
  "data-slot": "field-empty-notice",
2222
2277
  className: "hidden type-secondary text-muted-foreground items-center gap-1 [[data-field-root]:has(:placeholder-shown)_&]:flex",
2223
2278
  children: [
2224
- /* @__PURE__ */ jsx19(CircleAlertIcon, { className: "h-3 w-3 flex-shrink-0" }),
2225
- /* @__PURE__ */ jsx19("span", { children: "Empty \u2014 the gray text is an example, not your answer." })
2279
+ /* @__PURE__ */ jsx20(CircleAlertIcon, { className: "h-3 w-3 flex-shrink-0" }),
2280
+ /* @__PURE__ */ jsx20("span", { children: "Empty \u2014 the gray text is an example, not your answer." })
2226
2281
  ]
2227
2282
  }
2228
- ) : /* @__PURE__ */ jsx19("span", {}),
2229
- hasCounter && /* @__PURE__ */ jsx19(
2283
+ ) : /* @__PURE__ */ jsx20("span", {}),
2284
+ hasCounter && /* @__PURE__ */ jsx20(
2230
2285
  "span",
2231
2286
  {
2232
2287
  className: cn(
@@ -2247,10 +2302,10 @@ function LabeledField({
2247
2302
  import { copyText } from "@ai-matrx/kit/clipboard";
2248
2303
  import { openClipboardFallback } from "@ai-matrx/kit/clipboard-fallback-opener";
2249
2304
  import { toast } from "@ai-matrx/kit/notify";
2250
- import * as React6 from "react";
2305
+ import * as React7 from "react";
2251
2306
  import { createPortal } from "react-dom";
2252
- import { jsx as jsx20, jsxs as jsxs17 } from "react/jsx-runtime";
2253
- var { useState: useState10, useLayoutEffect: useLayoutEffect2, useRef: useRef4 } = React6;
2307
+ import { jsx as jsx21, jsxs as jsxs17 } from "react/jsx-runtime";
2308
+ var { useState: useState10, useLayoutEffect: useLayoutEffect2, useRef: useRef4 } = React7;
2254
2309
  function HelpIcon({
2255
2310
  text,
2256
2311
  content,
@@ -2348,8 +2403,8 @@ function HelpIcon({
2348
2403
  }, [isVisible]);
2349
2404
  const formatTextWithLineBreaks = (text2) => {
2350
2405
  const processedText = text2.replace(/\\n/g, "\n");
2351
- return processedText.split("\n").map((line, index) => /* @__PURE__ */ jsxs17(React6.Fragment, { children: [
2352
- index > 0 && /* @__PURE__ */ jsx20("br", {}),
2406
+ return processedText.split("\n").map((line, index) => /* @__PURE__ */ jsxs17(React7.Fragment, { children: [
2407
+ index > 0 && /* @__PURE__ */ jsx21("br", {}),
2353
2408
  line
2354
2409
  ] }, index));
2355
2410
  };
@@ -2362,7 +2417,7 @@ function HelpIcon({
2362
2417
  onMouseEnter: showTooltip,
2363
2418
  onMouseLeave: hideTooltip,
2364
2419
  children: [
2365
- /* @__PURE__ */ jsx20(InfoIcon, { className: "h-4 w-4 text-muted-foreground transition-colors duration-200" }),
2420
+ /* @__PURE__ */ jsx21(InfoIcon, { className: "h-4 w-4 text-muted-foreground transition-colors duration-200" }),
2366
2421
  isVisible && typeof document !== "undefined" && createPortal(
2367
2422
  /* @__PURE__ */ jsxs17(
2368
2423
  "div",
@@ -2379,27 +2434,27 @@ function HelpIcon({
2379
2434
  children: [
2380
2435
  /* @__PURE__ */ jsxs17("div", { className: "p-3", children: [
2381
2436
  /* @__PURE__ */ jsxs17("div", { className: "flex items-center gap-2 mb-2", children: [
2382
- /* @__PURE__ */ jsx20(CircleHelpIcon, { className: "h-4 w-4 flex-shrink-0 text-info-ink" }),
2383
- title && /* @__PURE__ */ jsx20("h3", { className: "text-foreground type-title", children: title }),
2384
- text && /* @__PURE__ */ jsx20(
2437
+ /* @__PURE__ */ jsx21(CircleHelpIcon, { className: "h-4 w-4 flex-shrink-0 text-info-ink" }),
2438
+ title && /* @__PURE__ */ jsx21("h3", { className: "text-foreground type-title", children: title }),
2439
+ text && /* @__PURE__ */ jsx21(
2385
2440
  Button2,
2386
2441
  {
2387
2442
  variant: "quiet",
2388
2443
  className: "ml-auto",
2389
- icon: copied ? /* @__PURE__ */ jsx20(CheckIcon, {}) : /* @__PURE__ */ jsx20(CopyIcon, {}),
2444
+ icon: copied ? /* @__PURE__ */ jsx21(CheckIcon, {}) : /* @__PURE__ */ jsx21(CopyIcon, {}),
2390
2445
  "aria-label": "Copy to clipboard",
2391
2446
  onClick: handleCopy
2392
2447
  }
2393
2448
  )
2394
2449
  ] }),
2395
- /* @__PURE__ */ jsx20("div", { className: "type-body text-foreground leading-relaxed", children: content ? content : text && formatTextWithLineBreaks(text) }),
2450
+ /* @__PURE__ */ jsx21("div", { className: "type-body text-foreground leading-relaxed", children: content ? content : text && formatTextWithLineBreaks(text) }),
2396
2451
  required && /* @__PURE__ */ jsxs17("div", { className: "mt-3 inline-flex items-center gap-1.5 px-2.5 py-1 bg-warning/15 text-warning-ink type-secondary font-medium rounded-full", children: [
2397
- /* @__PURE__ */ jsx20("div", { className: "w-1.5 h-1.5 bg-warning-ink rounded-full" }),
2452
+ /* @__PURE__ */ jsx21("div", { className: "w-1.5 h-1.5 bg-warning-ink rounded-full" }),
2398
2453
  "Required Field"
2399
2454
  ] }),
2400
- onAiAssistance && /* @__PURE__ */ jsx20(Button2, { variant: "primary", icon: /* @__PURE__ */ jsx20(CircleDotIcon, {}), className: "mt-3 w-full", onClick: handleAiClick, children: "Get Help From Matrx AI" })
2455
+ onAiAssistance && /* @__PURE__ */ jsx21(Button2, { variant: "primary", icon: /* @__PURE__ */ jsx21(CircleDotIcon, {}), className: "mt-3 w-full", onClick: handleAiClick, children: "Get Help From Matrx AI" })
2401
2456
  ] }),
2402
- /* @__PURE__ */ jsx20("div", { className: "absolute -bottom-1.5 left-1/2 -translate-x-1/2 w-3 h-3 bg-textured border-r border-b border-border rotate-45" })
2457
+ /* @__PURE__ */ jsx21("div", { className: "absolute -bottom-1.5 left-1/2 -translate-x-1/2 w-3 h-3 bg-textured border-r border-b border-border rotate-45" })
2403
2458
  ]
2404
2459
  }
2405
2460
  ),
@@ -2414,8 +2469,8 @@ function HelpIcon({
2414
2469
  import { copyText as copyText2 } from "@ai-matrx/kit/clipboard";
2415
2470
  import { toast as toast2 } from "@ai-matrx/kit/notify";
2416
2471
  import { openClipboardFallback as openClipboardFallback2 } from "@ai-matrx/kit/clipboard-fallback-opener";
2417
- import * as React7 from "react";
2418
- import { jsx as jsx21, jsxs as jsxs18 } from "react/jsx-runtime";
2472
+ import * as React8 from "react";
2473
+ import { jsx as jsx22, jsxs as jsxs18 } from "react/jsx-runtime";
2419
2474
  function cleanUrl(url) {
2420
2475
  try {
2421
2476
  const parsed = new URL(url);
@@ -2440,9 +2495,9 @@ function TextArrayInput({
2440
2495
  shouldCleanUrl = false,
2441
2496
  auxiliaryControlsTabIndex
2442
2497
  }) {
2443
- const [internalValue, setInternalValue] = React7.useState([]);
2444
- const [inputValue, setInputValue] = React7.useState("");
2445
- const [copied, setCopied] = React7.useState(false);
2498
+ const [internalValue, setInternalValue] = React8.useState([]);
2499
+ const [inputValue, setInputValue] = React8.useState("");
2500
+ const [copied, setCopied] = React8.useState(false);
2446
2501
  const value = externalValue || internalValue;
2447
2502
  const tabIndexProp = auxiliaryControlsTabIndex === void 0 ? {} : { tabIndex: auxiliaryControlsTabIndex };
2448
2503
  const handleCopy = async () => {
@@ -2473,7 +2528,7 @@ function TextArrayInput({
2473
2528
  };
2474
2529
  return /* @__PURE__ */ jsxs18("div", { className: `space-y-3 ${className}`, children: [
2475
2530
  /* @__PURE__ */ jsxs18("form", { onSubmit: handleSubmit, className: "relative w-full", children: [
2476
- /* @__PURE__ */ jsx21(
2531
+ /* @__PURE__ */ jsx22(
2477
2532
  Input,
2478
2533
  {
2479
2534
  adornment: "end",
@@ -2487,12 +2542,12 @@ function TextArrayInput({
2487
2542
  className: "w-full"
2488
2543
  }
2489
2544
  ),
2490
- showCopyIcon && value.length > 0 && /* @__PURE__ */ jsx21(
2545
+ showCopyIcon && value.length > 0 && /* @__PURE__ */ jsx22(
2491
2546
  Button2,
2492
2547
  {
2493
2548
  ...tabIndexProp,
2494
2549
  variant: "quiet",
2495
- icon: copied ? /* @__PURE__ */ jsx21(CheckIcon, {}) : /* @__PURE__ */ jsx21(CopyIcon, {}),
2550
+ icon: copied ? /* @__PURE__ */ jsx22(CheckIcon, {}) : /* @__PURE__ */ jsx22(CopyIcon, {}),
2496
2551
  ...copied ? { glyphTone: "success" } : {},
2497
2552
  "aria-label": "Copy values",
2498
2553
  onClick: handleCopy,
@@ -2500,13 +2555,13 @@ function TextArrayInput({
2500
2555
  }
2501
2556
  )
2502
2557
  ] }),
2503
- /* @__PURE__ */ jsx21("div", { className: "flex flex-wrap gap-2", children: value.length === 0 ? /* @__PURE__ */ jsx21("span", { className: "type-body inline-flex items-center rounded-full bg-muted px-3 py-1 text-muted-foreground", children: "None Added" }) : value.map((item, index) => /* @__PURE__ */ jsxs18(
2558
+ /* @__PURE__ */ jsx22("div", { className: "flex flex-wrap gap-2", children: value.length === 0 ? /* @__PURE__ */ jsx22("span", { className: "type-body inline-flex items-center rounded-full bg-muted px-3 py-1 text-muted-foreground", children: "None Added" }) : value.map((item, index) => /* @__PURE__ */ jsxs18(
2504
2559
  "span",
2505
2560
  {
2506
2561
  className: `inline-flex cursor-default items-center gap-1 rounded-full px-3 py-1 text-sm transition-all duration-200 ${chipClassName}`,
2507
2562
  children: [
2508
2563
  item,
2509
- /* @__PURE__ */ jsx21(
2564
+ /* @__PURE__ */ jsx22(
2510
2565
  "button",
2511
2566
  {
2512
2567
  ...tabIndexProp,
@@ -2517,7 +2572,7 @@ function TextArrayInput({
2517
2572
  },
2518
2573
  className: "cursor-pointer rounded-full p-0.5 transition-colors duration-200 hover:bg-primary-foreground/20",
2519
2574
  "aria-label": `Remove ${item}`,
2520
- children: /* @__PURE__ */ jsx21(XIcon, { className: "h-3.5 w-3.5" })
2575
+ children: /* @__PURE__ */ jsx22(XIcon, { className: "h-3.5 w-3.5" })
2521
2576
  }
2522
2577
  )
2523
2578
  ]
@@ -2528,7 +2583,7 @@ function TextArrayInput({
2528
2583
  }
2529
2584
 
2530
2585
  // src/read-state/untrusted-count.tsx
2531
- import { jsx as jsx22 } from "react/jsx-runtime";
2586
+ import { jsx as jsx23 } from "react/jsx-runtime";
2532
2587
  function countReadState(input) {
2533
2588
  const { read, trustworthy } = input;
2534
2589
  if (trustworthy === false) return "failed";
@@ -2557,7 +2612,7 @@ function UntrustedCount({
2557
2612
  const state = countReadState({ read, trustworthy });
2558
2613
  if (state === "ready") {
2559
2614
  if (countIsStale(read)) {
2560
- return /* @__PURE__ */ jsx22(
2615
+ return /* @__PURE__ */ jsx23(
2561
2616
  "span",
2562
2617
  {
2563
2618
  className,
@@ -2567,12 +2622,12 @@ function UntrustedCount({
2567
2622
  }
2568
2623
  );
2569
2624
  }
2570
- return /* @__PURE__ */ jsx22("span", { className, children: value });
2625
+ return /* @__PURE__ */ jsx23("span", { className, children: value });
2571
2626
  }
2572
2627
  if (state === "loading") {
2573
- return /* @__PURE__ */ jsx22("span", { className, "aria-busy": "true", "aria-label": `${label} loading`, children: "\u2026" });
2628
+ return /* @__PURE__ */ jsx23("span", { className, "aria-busy": "true", "aria-label": `${label} loading`, children: "\u2026" });
2574
2629
  }
2575
- return /* @__PURE__ */ jsx22(
2630
+ return /* @__PURE__ */ jsx23(
2576
2631
  "span",
2577
2632
  {
2578
2633
  className,
@@ -2584,7 +2639,7 @@ function UntrustedCount({
2584
2639
  }
2585
2640
 
2586
2641
  // src/controls/kpi-tile.tsx
2587
- import { Fragment as Fragment6, jsx as jsx23, jsxs as jsxs19 } from "react/jsx-runtime";
2642
+ import { Fragment as Fragment6, jsx as jsx24, jsxs as jsxs19 } from "react/jsx-runtime";
2588
2643
  var TONE_VALUE = {
2589
2644
  neutral: "text-foreground",
2590
2645
  good: "text-success-ink",
@@ -2616,9 +2671,9 @@ function KpiSparkline({ trend, label }) {
2616
2671
  "aria-label": `${trend.label ?? label}, last ${trend.period}`,
2617
2672
  className: "h-5 w-16 shrink-0 text-primary",
2618
2673
  children: [
2619
- /* @__PURE__ */ jsx23("title", { children: `${trend.label ?? label}, last ${trend.period}` }),
2620
- max === min ? null : /* @__PURE__ */ jsx23("polygon", { points: `0,${SPARK_H} ${pts} ${SPARK_W},${SPARK_H}`, fill: "currentColor", fillOpacity: 0.15 }),
2621
- /* @__PURE__ */ jsx23("polyline", { points: pts, fill: "none", stroke: "currentColor", strokeWidth: 1.5, strokeLinejoin: "round", vectorEffect: "non-scaling-stroke" })
2674
+ /* @__PURE__ */ jsx24("title", { children: `${trend.label ?? label}, last ${trend.period}` }),
2675
+ max === min ? null : /* @__PURE__ */ jsx24("polygon", { points: `0,${SPARK_H} ${pts} ${SPARK_W},${SPARK_H}`, fill: "currentColor", fillOpacity: 0.15 }),
2676
+ /* @__PURE__ */ jsx24("polyline", { points: pts, fill: "none", stroke: "currentColor", strokeWidth: 1.5, strokeLinejoin: "round", vectorEffect: "non-scaling-stroke" })
2622
2677
  ]
2623
2678
  }
2624
2679
  );
@@ -2642,17 +2697,17 @@ function KpiTile({
2642
2697
  const dot = TONE_DOT[tone2];
2643
2698
  const body = /* @__PURE__ */ jsxs19(Fragment6, { children: [
2644
2699
  /* @__PURE__ */ jsxs19("div", { className: "flex min-w-0 items-start gap-1.5 type-meta font-medium uppercase tracking-wide text-muted-foreground", children: [
2645
- dot ? /* @__PURE__ */ jsx23("span", { "aria-hidden": true, className: cn("mt-1 inline-block h-2 w-2 shrink-0 rounded-sm", dot) }) : null,
2700
+ dot ? /* @__PURE__ */ jsx24("span", { "aria-hidden": true, className: cn("mt-1 inline-block h-2 w-2 shrink-0 rounded-sm", dot) }) : null,
2646
2701
  /* @__PURE__ */ jsxs19("span", { className: "line-clamp-2 break-words", children: [
2647
2702
  label,
2648
2703
  title ? /* @__PURE__ */ jsxs19(Fragment6, { children: [
2649
2704
  " ",
2650
- /* @__PURE__ */ jsx23(InfoHint, { text: title, label: `What ${label} means` })
2705
+ /* @__PURE__ */ jsx24(InfoHint, { text: title, label: `What ${label} means` })
2651
2706
  ] }) : null
2652
2707
  ] })
2653
2708
  ] }),
2654
- loading ? /* @__PURE__ */ jsx23("div", { className: "my-0.5 h-6 w-12 animate-pulse rounded bg-muted", "aria-hidden": true }) : /* @__PURE__ */ jsxs19("div", { className: "flex min-w-0 items-end justify-between gap-2", children: [
2655
- /* @__PURE__ */ jsx23(
2709
+ loading ? /* @__PURE__ */ jsx24("div", { className: "my-0.5 h-6 w-12 animate-pulse rounded bg-muted", "aria-hidden": true }) : /* @__PURE__ */ jsxs19("div", { className: "flex min-w-0 items-end justify-between gap-2", children: [
2710
+ /* @__PURE__ */ jsx24(
2656
2711
  "div",
2657
2712
  {
2658
2713
  className: cn(
@@ -2664,16 +2719,16 @@ function KpiTile({
2664
2719
  children: shown === null ? "\u2014" : shown
2665
2720
  }
2666
2721
  ),
2667
- trend && shown !== null ? /* @__PURE__ */ jsx23(KpiSparkline, { trend, label }) : null
2722
+ trend && shown !== null ? /* @__PURE__ */ jsx24(KpiSparkline, { trend, label }) : null
2668
2723
  ] }),
2669
- hint ? /* @__PURE__ */ jsx23("div", { className: "truncate type-meta text-muted-foreground", children: hint }) : null
2724
+ hint ? /* @__PURE__ */ jsx24("div", { className: "truncate type-meta text-muted-foreground", children: hint }) : null
2670
2725
  ] });
2671
2726
  const shell = cn(
2672
2727
  "flex min-w-0 flex-col gap-0.5 rounded-md border border-border bg-card px-3 py-2",
2673
2728
  className
2674
2729
  );
2675
2730
  if (href && !loading && shown !== null) {
2676
- return /* @__PURE__ */ jsx23(
2731
+ return /* @__PURE__ */ jsx24(
2677
2732
  HostLink,
2678
2733
  {
2679
2734
  href,
@@ -2686,13 +2741,13 @@ function KpiTile({
2686
2741
  }
2687
2742
  );
2688
2743
  }
2689
- return /* @__PURE__ */ jsx23("div", { className: shell, "data-look-surface": "card", "aria-busy": loading || void 0, children: body });
2744
+ return /* @__PURE__ */ jsx24("div", { className: shell, "data-look-surface": "card", "aria-busy": loading || void 0, children: body });
2690
2745
  }
2691
2746
  function KpiGrid({
2692
2747
  children,
2693
2748
  className
2694
2749
  }) {
2695
- return /* @__PURE__ */ jsx23(
2750
+ return /* @__PURE__ */ jsx24(
2696
2751
  "div",
2697
2752
  {
2698
2753
  className: cn(
@@ -2705,8 +2760,8 @@ function KpiGrid({
2705
2760
  }
2706
2761
 
2707
2762
  // src/controls/action-feedback-button.tsx
2708
- import * as React8 from "react";
2709
- import { jsx as jsx24, jsxs as jsxs20 } from "react/jsx-runtime";
2763
+ import * as React9 from "react";
2764
+ import { jsx as jsx25, jsxs as jsxs20 } from "react/jsx-runtime";
2710
2765
  function ActionFeedbackButton({
2711
2766
  icon,
2712
2767
  tooltip,
@@ -2720,9 +2775,9 @@ function ActionFeedbackButton({
2720
2775
  disabled = false,
2721
2776
  ...props
2722
2777
  }) {
2723
- const [showSuccess, setShowSuccess] = React8.useState(false);
2724
- const timer = React8.useRef(null);
2725
- React8.useEffect(() => () => {
2778
+ const [showSuccess, setShowSuccess] = React9.useState(false);
2779
+ const timer = React9.useRef(null);
2780
+ React9.useEffect(() => () => {
2726
2781
  if (timer.current) clearTimeout(timer.current);
2727
2782
  }, []);
2728
2783
  const handleClick = () => {
@@ -2732,11 +2787,11 @@ function ActionFeedbackButton({
2732
2787
  timer.current = setTimeout(() => setShowSuccess(false), feedbackDuration);
2733
2788
  };
2734
2789
  const text = showSuccess ? successTooltip : disabled && disabledTooltip ? disabledTooltip : tooltip;
2735
- const button = /* @__PURE__ */ jsx24(
2790
+ const button = /* @__PURE__ */ jsx25(
2736
2791
  Button2,
2737
2792
  {
2738
2793
  variant,
2739
- icon: showSuccess ? successIcon ?? /* @__PURE__ */ jsx24(CheckCircle2Icon, {}) : icon,
2794
+ icon: showSuccess ? successIcon ?? /* @__PURE__ */ jsx25(CheckCircle2Icon, {}) : icon,
2740
2795
  ...showSuccess ? { glyphTone: "success" } : glyphTone ? { glyphTone } : {},
2741
2796
  ...props,
2742
2797
  "aria-label": text,
@@ -2745,14 +2800,14 @@ function ActionFeedbackButton({
2745
2800
  }
2746
2801
  );
2747
2802
  return /* @__PURE__ */ jsxs20(Tooltip, { children: [
2748
- /* @__PURE__ */ jsx24(TooltipTrigger, { asChild: true, children: disabled ? /* @__PURE__ */ jsx24("span", { className: "inline-flex", children: button }) : button }),
2749
- /* @__PURE__ */ jsx24(TooltipContent, { side: "bottom", sideOffset: 5, className: "z-[9999]", children: text })
2803
+ /* @__PURE__ */ jsx25(TooltipTrigger, { asChild: true, children: disabled ? /* @__PURE__ */ jsx25("span", { className: "inline-flex", children: button }) : button }),
2804
+ /* @__PURE__ */ jsx25(TooltipContent, { side: "bottom", sideOffset: 5, className: "z-[9999]", children: text })
2750
2805
  ] });
2751
2806
  }
2752
2807
 
2753
2808
  // src/controls/citation-chip.tsx
2754
2809
  import { useState as useState13 } from "react";
2755
- import { jsx as jsx25, jsxs as jsxs21 } from "react/jsx-runtime";
2810
+ import { jsx as jsx26, jsxs as jsxs21 } from "react/jsx-runtime";
2756
2811
  function CitationPopoverBody({
2757
2812
  icon: Icon,
2758
2813
  label,
@@ -2764,7 +2819,7 @@ function CitationPopoverBody({
2764
2819
  }) {
2765
2820
  return /* @__PURE__ */ jsxs21("div", { className: "flex flex-col gap-2", children: [
2766
2821
  /* @__PURE__ */ jsxs21("div", { className: "flex items-start gap-2", children: [
2767
- /* @__PURE__ */ jsx25(
2822
+ /* @__PURE__ */ jsx26(
2768
2823
  Icon,
2769
2824
  {
2770
2825
  className: "mt-0.5 h-4 w-4 shrink-0 text-muted-foreground",
@@ -2772,13 +2827,13 @@ function CitationPopoverBody({
2772
2827
  }
2773
2828
  ),
2774
2829
  /* @__PURE__ */ jsxs21("div", { className: "min-w-0", children: [
2775
- /* @__PURE__ */ jsx25("p", { className: "truncate type-title text-foreground", children: label }),
2776
- locator && /* @__PURE__ */ jsx25("p", { className: "type-secondary text-muted-foreground", children: locator })
2830
+ /* @__PURE__ */ jsx26("p", { className: "truncate type-title text-foreground", children: label }),
2831
+ locator && /* @__PURE__ */ jsx26("p", { className: "type-secondary text-muted-foreground", children: locator })
2777
2832
  ] })
2778
2833
  ] }),
2779
2834
  excerpt && /* @__PURE__ */ jsxs21("blockquote", { className: "flex gap-2 rounded-md bg-muted/60 p-2 type-secondary italic text-muted-foreground", children: [
2780
- /* @__PURE__ */ jsx25(QuoteIcon, { className: "h-3 w-3 shrink-0", "aria-hidden": true }),
2781
- /* @__PURE__ */ jsx25("span", { className: cn("not-italic", clampExcerpt && "line-clamp-6"), children: excerpt })
2835
+ /* @__PURE__ */ jsx26(QuoteIcon, { className: "h-3 w-3 shrink-0", "aria-hidden": true }),
2836
+ /* @__PURE__ */ jsx26("span", { className: cn("not-italic", clampExcerpt && "line-clamp-6"), children: excerpt })
2782
2837
  ] }),
2783
2838
  onOpen && /* @__PURE__ */ jsxs21(
2784
2839
  "button",
@@ -2787,7 +2842,7 @@ function CitationPopoverBody({
2787
2842
  onClick: onOpen,
2788
2843
  className: "inline-flex items-center gap-1 self-start text-xs font-medium text-primary hover:underline",
2789
2844
  children: [
2790
- /* @__PURE__ */ jsx25(ArrowUpRightIcon, { className: "h-3 w-3", "aria-hidden": true }),
2845
+ /* @__PURE__ */ jsx26(ArrowUpRightIcon, { className: "h-3 w-3", "aria-hidden": true }),
2791
2846
  openLabel
2792
2847
  ]
2793
2848
  }
@@ -2808,7 +2863,7 @@ function CitationChip({
2808
2863
  body.onOpen?.();
2809
2864
  } : void 0;
2810
2865
  return /* @__PURE__ */ jsxs21(Popover, { open, onOpenChange: setOpen, children: [
2811
- /* @__PURE__ */ jsx25(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxs21(
2866
+ /* @__PURE__ */ jsx26(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxs21(
2812
2867
  "button",
2813
2868
  {
2814
2869
  type: "button",
@@ -2818,20 +2873,20 @@ function CitationChip({
2818
2873
  chipClassName
2819
2874
  ),
2820
2875
  children: [
2821
- number != null && /* @__PURE__ */ jsx25("span", { className: "inline-flex h-4 min-w-4 shrink-0 items-center justify-center rounded-full bg-muted px-1 text-[0.65rem] font-medium leading-none text-muted-foreground", children: number }),
2822
- /* @__PURE__ */ jsx25(Icon, { className: "h-3 w-3 shrink-0 text-muted-foreground", "aria-hidden": true }),
2823
- /* @__PURE__ */ jsx25("span", { className: "truncate", children: label }),
2824
- chipSuffix && /* @__PURE__ */ jsx25("span", { className: "shrink-0 text-muted-foreground", children: chipSuffix })
2876
+ number != null && /* @__PURE__ */ jsx26("span", { className: "inline-flex h-4 min-w-4 shrink-0 items-center justify-center rounded-full bg-muted px-1 text-[0.65rem] font-medium leading-none text-muted-foreground", children: number }),
2877
+ /* @__PURE__ */ jsx26(Icon, { className: "h-3 w-3 shrink-0 text-muted-foreground", "aria-hidden": true }),
2878
+ /* @__PURE__ */ jsx26("span", { className: "truncate", children: label }),
2879
+ chipSuffix && /* @__PURE__ */ jsx26("span", { className: "shrink-0 text-muted-foreground", children: chipSuffix })
2825
2880
  ]
2826
2881
  }
2827
2882
  ) }),
2828
- /* @__PURE__ */ jsx25(PopoverContent, { sizing: "content", align: "start", className: "p-3", children: /* @__PURE__ */ jsx25(CitationPopoverBody, { ...body, onOpen }) })
2883
+ /* @__PURE__ */ jsx26(PopoverContent, { sizing: "content", align: "start", className: "p-3", children: /* @__PURE__ */ jsx26(CitationPopoverBody, { ...body, onOpen }) })
2829
2884
  ] });
2830
2885
  }
2831
2886
 
2832
2887
  // src/controls/tool-rail.tsx
2833
- import * as React9 from "react";
2834
- import { jsx as jsx26, jsxs as jsxs22 } from "react/jsx-runtime";
2888
+ import * as React10 from "react";
2889
+ import { jsx as jsx27, jsxs as jsxs22 } from "react/jsx-runtime";
2835
2890
  function ToolRail({
2836
2891
  groups,
2837
2892
  value,
@@ -2841,11 +2896,11 @@ function ToolRail({
2841
2896
  className,
2842
2897
  "aria-label": ariaLabel
2843
2898
  }) {
2844
- const flat = React9.useMemo(() => groups.flat(), [groups]);
2845
- const refs = React9.useRef(/* @__PURE__ */ new Map());
2899
+ const flat = React10.useMemo(() => groups.flat(), [groups]);
2900
+ const refs = React10.useRef(/* @__PURE__ */ new Map());
2846
2901
  const enabled = flat.filter((t) => !t.disabled);
2847
2902
  const activeEnabled = enabled.find((t) => t.id === value);
2848
- const [focusId, setFocusId] = React9.useState(null);
2903
+ const [focusId, setFocusId] = React10.useState(null);
2849
2904
  const stopId = (focusId && enabled.some((t) => t.id === focusId) ? focusId : null) ?? activeEnabled?.id ?? enabled[0]?.id;
2850
2905
  const vertical = orientation === "vertical";
2851
2906
  const focusAt = (id) => {
@@ -2871,7 +2926,7 @@ function ToolRail({
2871
2926
  focusAt(enabled[enabled.length - 1]?.id);
2872
2927
  }
2873
2928
  };
2874
- return /* @__PURE__ */ jsx26(
2929
+ return /* @__PURE__ */ jsx27(
2875
2930
  "div",
2876
2931
  {
2877
2932
  role: "toolbar",
@@ -2880,8 +2935,8 @@ function ToolRail({
2880
2935
  "data-matrx-tool-rail": "",
2881
2936
  "data-orientation": orientation,
2882
2937
  className: cn("flex w-fit shrink-0 items-center gap-1", vertical ? "flex-col" : "flex-row", className),
2883
- children: groups.map((group, gi) => /* @__PURE__ */ jsxs22(React9.Fragment, { children: [
2884
- gi > 0 ? /* @__PURE__ */ jsx26(
2938
+ children: groups.map((group, gi) => /* @__PURE__ */ jsxs22(React10.Fragment, { children: [
2939
+ gi > 0 ? /* @__PURE__ */ jsx27(
2885
2940
  "div",
2886
2941
  {
2887
2942
  role: "separator",
@@ -2894,7 +2949,7 @@ function ToolRail({
2894
2949
  const Icon = tool.icon;
2895
2950
  const name = tool.shortcut ? `${tool.label} (${tool.shortcut})` : tool.label;
2896
2951
  return /* @__PURE__ */ jsxs22(Tooltip, { children: [
2897
- /* @__PURE__ */ jsx26(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx26(
2952
+ /* @__PURE__ */ jsx27(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx27(
2898
2953
  Button2,
2899
2954
  {
2900
2955
  ref: (el) => {
@@ -2902,7 +2957,7 @@ function ToolRail({
2902
2957
  else refs.current.delete(tool.id);
2903
2958
  },
2904
2959
  variant: on ? "primary" : "quiet",
2905
- icon: /* @__PURE__ */ jsx26(Icon, {}),
2960
+ icon: /* @__PURE__ */ jsx27(Icon, {}),
2906
2961
  "aria-label": name,
2907
2962
  pressed: on,
2908
2963
  disabled: tool.disabled,
@@ -2913,7 +2968,7 @@ function ToolRail({
2913
2968
  onClick: () => onValueChange(on && allowDeselect ? null : tool.id, tool)
2914
2969
  }
2915
2970
  ) }),
2916
- /* @__PURE__ */ jsx26(TooltipContent, { side: vertical ? "right" : "bottom", sideOffset: 6, children: name })
2971
+ /* @__PURE__ */ jsx27(TooltipContent, { side: vertical ? "right" : "bottom", sideOffset: 6, children: name })
2917
2972
  ] }, tool.id);
2918
2973
  })
2919
2974
  ] }, gi))
@@ -2922,7 +2977,7 @@ function ToolRail({
2922
2977
  }
2923
2978
 
2924
2979
  // src/controls/page-range-input.tsx
2925
- import * as React10 from "react";
2980
+ import * as React11 from "react";
2926
2981
 
2927
2982
  // src/controls/page-ranges.ts
2928
2983
  var WORD_END = /^(end|last)$/i;
@@ -2993,7 +3048,7 @@ function formatPageRanges(pages) {
2993
3048
  }
2994
3049
 
2995
3050
  // src/controls/page-range-input.tsx
2996
- import { jsx as jsx27, jsxs as jsxs23 } from "react/jsx-runtime";
3051
+ import { jsx as jsx28, jsxs as jsxs23 } from "react/jsx-runtime";
2997
3052
  function PageRangeInput({
2998
3053
  value,
2999
3054
  onChange,
@@ -3005,13 +3060,13 @@ function PageRangeInput({
3005
3060
  id,
3006
3061
  "aria-label": ariaLabel = "Page range"
3007
3062
  }) {
3008
- const autoId = React10.useId();
3063
+ const autoId = React11.useId();
3009
3064
  const hintId = `${id ?? autoId}-hint`;
3010
- const parsed = React10.useMemo(() => parsePageRanges(value, pageCount), [value, pageCount]);
3065
+ const parsed = React11.useMemo(() => parsePageRanges(value, pageCount), [value, pageCount]);
3011
3066
  const first = parsed.issues[0];
3012
3067
  const hint = parsed.empty ? `${pageCount} page${pageCount === 1 ? "" : "s"}` : first ? first.hint : `${parsed.pages.length} page${parsed.pages.length === 1 ? "" : "s"}: ${formatPageRanges(parsed.pages)}`;
3013
3068
  return /* @__PURE__ */ jsxs23("div", { className: cn("flex min-w-0 flex-col gap-1", className), "data-matrx-page-range-input": "", children: [
3014
- /* @__PURE__ */ jsx27(
3069
+ /* @__PURE__ */ jsx28(
3015
3070
  Input,
3016
3071
  {
3017
3072
  id,
@@ -3030,7 +3085,7 @@ function PageRangeInput({
3030
3085
  }
3031
3086
  }
3032
3087
  ),
3033
- /* @__PURE__ */ jsx27(
3088
+ /* @__PURE__ */ jsx28(
3034
3089
  "p",
3035
3090
  {
3036
3091
  id: hintId,
@@ -3044,8 +3099,8 @@ function PageRangeInput({
3044
3099
  }
3045
3100
 
3046
3101
  // src/controls/opacity-slider.tsx
3047
- import * as React11 from "react";
3048
- import { jsx as jsx28, jsxs as jsxs24 } from "react/jsx-runtime";
3102
+ import * as React12 from "react";
3103
+ import { jsx as jsx29, jsxs as jsxs24 } from "react/jsx-runtime";
3049
3104
  var clamp = (n, lo, hi) => Math.min(hi, Math.max(lo, n));
3050
3105
  var toPercent = (v) => Math.round(v * 100);
3051
3106
  function OpacitySlider({
@@ -3057,7 +3112,7 @@ function OpacitySlider({
3057
3112
  className,
3058
3113
  "aria-label": ariaLabel = "Opacity"
3059
3114
  }) {
3060
- const [draft, setDraft] = React11.useState(null);
3115
+ const [draft, setDraft] = React12.useState(null);
3061
3116
  const percent = toPercent(clamp(value, min, max));
3062
3117
  const commit = () => {
3063
3118
  if (draft !== null && draft.trim() !== "" && Number.isFinite(Number(draft))) {
@@ -3066,7 +3121,7 @@ function OpacitySlider({
3066
3121
  setDraft(null);
3067
3122
  };
3068
3123
  return /* @__PURE__ */ jsxs24("div", { className: cn("flex min-w-0 items-center gap-2", className), "data-matrx-opacity-slider": "", children: [
3069
- /* @__PURE__ */ jsx28(
3124
+ /* @__PURE__ */ jsx29(
3070
3125
  Slider,
3071
3126
  {
3072
3127
  className: "min-w-0 flex-1",
@@ -3080,7 +3135,7 @@ function OpacitySlider({
3080
3135
  }
3081
3136
  ),
3082
3137
  /* @__PURE__ */ jsxs24("div", { className: "flex w-16 shrink-0 items-center gap-1", style: { ["--matrx-control-field-min"]: "0px" }, children: [
3083
- /* @__PURE__ */ jsx28(
3138
+ /* @__PURE__ */ jsx29(
3084
3139
  Input,
3085
3140
  {
3086
3141
  numeric: true,
@@ -3099,14 +3154,14 @@ function OpacitySlider({
3099
3154
  }
3100
3155
  }
3101
3156
  ),
3102
- /* @__PURE__ */ jsx28("span", { "aria-hidden": true, className: "text-xs text-muted-foreground", children: "%" })
3157
+ /* @__PURE__ */ jsx29("span", { "aria-hidden": true, className: "text-xs text-muted-foreground", children: "%" })
3103
3158
  ] })
3104
3159
  ] });
3105
3160
  }
3106
3161
 
3107
3162
  // src/controls/color-swatch-row.tsx
3108
- import * as React12 from "react";
3109
- import { jsx as jsx29 } from "react/jsx-runtime";
3163
+ import * as React13 from "react";
3164
+ import { jsx as jsx30 } from "react/jsx-runtime";
3110
3165
  function ColorSwatchRow({
3111
3166
  colors,
3112
3167
  value,
@@ -3115,7 +3170,7 @@ function ColorSwatchRow({
3115
3170
  className,
3116
3171
  "aria-label": ariaLabel = "Color"
3117
3172
  }) {
3118
- const refs = React12.useRef([]);
3173
+ const refs = React13.useRef([]);
3119
3174
  const chosen = colors.findIndex((c) => c.value.toLowerCase() === (value ?? "").toLowerCase());
3120
3175
  const stop = chosen >= 0 ? chosen : 0;
3121
3176
  const move = (to) => {
@@ -3125,7 +3180,7 @@ function ColorSwatchRow({
3125
3180
  refs.current[i]?.focus();
3126
3181
  onChange(c.value, c);
3127
3182
  };
3128
- return /* @__PURE__ */ jsx29(
3183
+ return /* @__PURE__ */ jsx30(
3129
3184
  "div",
3130
3185
  {
3131
3186
  role: "radiogroup",
@@ -3135,7 +3190,7 @@ function ColorSwatchRow({
3135
3190
  "data-matrx-color-swatch-row": "",
3136
3191
  children: colors.map((c, i) => {
3137
3192
  const on = i === chosen;
3138
- return /* @__PURE__ */ jsx29(
3193
+ return /* @__PURE__ */ jsx30(
3139
3194
  "button",
3140
3195
  {
3141
3196
  ref: (el) => {
@@ -3173,7 +3228,7 @@ function ColorSwatchRow({
3173
3228
  on && "ring-2 ring-foreground ring-offset-1 ring-offset-background"
3174
3229
  ),
3175
3230
  style: { backgroundColor: c.value },
3176
- children: on ? /* @__PURE__ */ jsx29(RadixCheckIcon, { className: "size-3 mix-blend-difference text-white" }) : null
3231
+ children: on ? /* @__PURE__ */ jsx30(RadixCheckIcon, { className: "size-3 mix-blend-difference text-white" }) : null
3177
3232
  },
3178
3233
  `${c.value}-${i}`
3179
3234
  );
@@ -3183,8 +3238,8 @@ function ColorSwatchRow({
3183
3238
  }
3184
3239
 
3185
3240
  // src/controls/anchored-toolbar.tsx
3186
- import * as React13 from "react";
3187
- import { jsx as jsx30, jsxs as jsxs25 } from "react/jsx-runtime";
3241
+ import * as React14 from "react";
3242
+ import { jsx as jsx31, jsxs as jsxs25 } from "react/jsx-runtime";
3188
3243
  function virtualFor(rect) {
3189
3244
  return {
3190
3245
  getBoundingClientRect: () => ({
@@ -3212,14 +3267,14 @@ function AnchoredToolbar({
3212
3267
  children
3213
3268
  }) {
3214
3269
  const x = rect?.x ?? 0, y = rect?.y ?? 0, w = rect?.width ?? 0, h = rect?.height ?? 0;
3215
- const virtualRef = React13.useMemo(
3270
+ const virtualRef = React14.useMemo(
3216
3271
  () => ({ current: virtualFor({ x, y, width: w, height: h }) }),
3217
3272
  [x, y, w, h]
3218
3273
  );
3219
3274
  const visible = open && rect !== null;
3220
3275
  return /* @__PURE__ */ jsxs25(Popover, { open: visible, ...onOpenChange ? { onOpenChange } : {}, children: [
3221
- /* @__PURE__ */ jsx30(PopoverAnchor, { virtualRef }),
3222
- /* @__PURE__ */ jsx30(
3276
+ /* @__PURE__ */ jsx31(PopoverAnchor, { virtualRef }),
3277
+ /* @__PURE__ */ jsx31(
3223
3278
  PopoverContent,
3224
3279
  {
3225
3280
  role: "toolbar",
@@ -3242,9 +3297,9 @@ function AnchoredToolbar({
3242
3297
  }
3243
3298
 
3244
3299
  // src/controls/icon-select.tsx
3245
- import * as React14 from "react";
3300
+ import * as React15 from "react";
3246
3301
  import { openOutbound } from "@ai-matrx/kit/outbound";
3247
- import { jsx as jsx31, jsxs as jsxs26 } from "react/jsx-runtime";
3302
+ import { jsx as jsx32, jsxs as jsxs26 } from "react/jsx-runtime";
3248
3303
  function wantsNewTab(e) {
3249
3304
  return Boolean(e.metaKey || e.ctrlKey || e.shiftKey || e.altKey || e.button === 1);
3250
3305
  }
@@ -3253,8 +3308,8 @@ var TRIGGER_SIZE = {
3253
3308
  touch: "!h-10 !w-10 sm:!h-8 sm:!w-8"
3254
3309
  };
3255
3310
  var TRIGGER_FACE = "h-7 w-7 justify-center border-none bg-muted px-0 focus:outline-none focus:ring-0";
3256
- var IconSelectTrigger = React14.forwardRef(function IconSelectTrigger2({ icon, disabled, ariaLabel, size = "default", className, ...rest }, ref) {
3257
- return /* @__PURE__ */ jsx31(
3311
+ var IconSelectTrigger = React15.forwardRef(function IconSelectTrigger2({ icon, disabled, ariaLabel, size = "default", className, ...rest }, ref) {
3312
+ return /* @__PURE__ */ jsx32(
3258
3313
  Button2,
3259
3314
  {
3260
3315
  ref,
@@ -3279,16 +3334,16 @@ function IconSelect({
3279
3334
  size = "default",
3280
3335
  className
3281
3336
  }) {
3282
- const [open, setOpen] = React14.useState(false);
3283
- const skipSelectRef = React14.useRef(false);
3337
+ const [open, setOpen] = React15.useState(false);
3338
+ const skipSelectRef = React15.useRef(false);
3284
3339
  if (searchable) {
3285
3340
  return /* @__PURE__ */ jsxs26(Popover, { open, onOpenChange: setOpen, children: [
3286
- /* @__PURE__ */ jsx31(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx31(IconSelectTrigger, { icon, disabled, ariaLabel, size, className }) }),
3287
- /* @__PURE__ */ jsx31(PopoverContent, { sizing: "content", className: "p-0", align: "start", children: /* @__PURE__ */ jsxs26(Command, { children: [
3288
- /* @__PURE__ */ jsx31(CommandInput, { placeholder: searchPlaceholder, className: "h-9 text-sm" }),
3341
+ /* @__PURE__ */ jsx32(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx32(IconSelectTrigger, { icon, disabled, ariaLabel, size, className }) }),
3342
+ /* @__PURE__ */ jsx32(PopoverContent, { sizing: "content", className: "p-0", align: "start", children: /* @__PURE__ */ jsxs26(Command, { children: [
3343
+ /* @__PURE__ */ jsx32(CommandInput, { placeholder: searchPlaceholder, className: "h-9 text-sm" }),
3289
3344
  /* @__PURE__ */ jsxs26(CommandList, { children: [
3290
- /* @__PURE__ */ jsx31(CommandEmpty, { children: "No results found." }),
3291
- /* @__PURE__ */ jsx31(CommandGroup, { className: "max-h-72 overflow-auto", children: items.map((item) => /* @__PURE__ */ jsx31(
3345
+ /* @__PURE__ */ jsx32(CommandEmpty, { children: "No results found." }),
3346
+ /* @__PURE__ */ jsx32(CommandGroup, { className: "max-h-72 overflow-auto", children: items.map((item) => /* @__PURE__ */ jsx32(
3292
3347
  CommandItem,
3293
3348
  {
3294
3349
  value: item.label,
@@ -3309,7 +3364,7 @@ function IconSelect({
3309
3364
  setOpen(false);
3310
3365
  },
3311
3366
  children: /* @__PURE__ */ jsxs26("div", { className: "flex items-center", children: [
3312
- item.icon && /* @__PURE__ */ jsx31("span", { className: "mr-2", children: item.icon }),
3367
+ item.icon && /* @__PURE__ */ jsx32("span", { className: "mr-2", children: item.icon }),
3313
3368
  item.label
3314
3369
  ] })
3315
3370
  },
@@ -3320,7 +3375,7 @@ function IconSelect({
3320
3375
  ] });
3321
3376
  }
3322
3377
  return /* @__PURE__ */ jsxs26(Select, { ...value === void 0 ? {} : { value }, ...onValueChange ? { onValueChange } : {}, disabled, children: [
3323
- /* @__PURE__ */ jsx31(
3378
+ /* @__PURE__ */ jsx32(
3324
3379
  SelectTrigger,
3325
3380
  {
3326
3381
  "aria-label": ariaLabel,
@@ -3329,7 +3384,7 @@ function IconSelect({
3329
3384
  children: icon
3330
3385
  }
3331
3386
  ),
3332
- /* @__PURE__ */ jsx31(SelectContent, { children: /* @__PURE__ */ jsx31(SelectGroup, { children: items.map((item) => /* @__PURE__ */ jsx31(
3387
+ /* @__PURE__ */ jsx32(SelectContent, { children: /* @__PURE__ */ jsx32(SelectGroup, { children: items.map((item) => /* @__PURE__ */ jsx32(
3333
3388
  SelectItem,
3334
3389
  {
3335
3390
  value: item.value,
@@ -3340,7 +3395,7 @@ function IconSelect({
3340
3395
  }
3341
3396
  },
3342
3397
  children: /* @__PURE__ */ jsxs26("div", { className: "flex items-center", children: [
3343
- item.icon && /* @__PURE__ */ jsx31("span", { className: "mr-2", children: item.icon }),
3398
+ item.icon && /* @__PURE__ */ jsx32("span", { className: "mr-2", children: item.icon }),
3344
3399
  item.label
3345
3400
  ] })
3346
3401
  },
@@ -3350,13 +3405,13 @@ function IconSelect({
3350
3405
  }
3351
3406
 
3352
3407
  // src/controls/advanced-collapsible.tsx
3353
- import * as React15 from "react";
3408
+ import * as React16 from "react";
3354
3409
  import { copyText as copyText3 } from "@ai-matrx/kit/clipboard";
3355
3410
  import { openClipboardFallback as openClipboardFallback3 } from "@ai-matrx/kit/clipboard-fallback-opener";
3356
3411
  import { toast as toast3 } from "@ai-matrx/kit/notify";
3357
3412
 
3358
3413
  // src/icon-button.tsx
3359
- import { jsx as jsx32, jsxs as jsxs27 } from "react/jsx-runtime";
3414
+ import { jsx as jsx33, jsxs as jsxs27 } from "react/jsx-runtime";
3360
3415
  var VARIANT = {
3361
3416
  ghost: "quiet",
3362
3417
  outline: "outline",
@@ -3377,11 +3432,11 @@ function IconButton({
3377
3432
  "aria-label": ariaLabel,
3378
3433
  ...props
3379
3434
  }) {
3380
- const control = /* @__PURE__ */ jsx32(
3435
+ const control = /* @__PURE__ */ jsx33(
3381
3436
  Button2,
3382
3437
  {
3383
3438
  variant: VARIANT[variant],
3384
- icon: spinning ? /* @__PURE__ */ jsx32(Icon, { className: MOTION_SPIN }) : /* @__PURE__ */ jsx32(Icon, {}),
3439
+ icon: spinning ? /* @__PURE__ */ jsx33(Icon, { className: MOTION_SPIN }) : /* @__PURE__ */ jsx33(Icon, {}),
3385
3440
  ...glyphTone ? { glyphTone } : {},
3386
3441
  "aria-label": ariaLabel ?? tooltip ?? "Action",
3387
3442
  ...props
@@ -3389,13 +3444,13 @@ function IconButton({
3389
3444
  );
3390
3445
  if (!tooltip) return control;
3391
3446
  return /* @__PURE__ */ jsxs27(Tooltip, { children: [
3392
- /* @__PURE__ */ jsx32(TooltipTrigger, { asChild: true, children: control }),
3393
- /* @__PURE__ */ jsx32(TooltipContent, { side: tooltipSide, align: tooltipAlign, className: "z-[9999]", sideOffset: tooltipOffset, children: tooltip })
3447
+ /* @__PURE__ */ jsx33(TooltipTrigger, { asChild: true, children: control }),
3448
+ /* @__PURE__ */ jsx33(TooltipContent, { side: tooltipSide, align: tooltipAlign, className: "z-[9999]", sideOffset: tooltipOffset, children: tooltip })
3394
3449
  ] });
3395
3450
  }
3396
3451
 
3397
3452
  // src/controls/advanced-collapsible.tsx
3398
- import { Fragment as Fragment8, jsx as jsx33, jsxs as jsxs28 } from "react/jsx-runtime";
3453
+ import { Fragment as Fragment8, jsx as jsx34, jsxs as jsxs28 } from "react/jsx-runtime";
3399
3454
  function AdvancedCollapsible({
3400
3455
  icon,
3401
3456
  title,
@@ -3414,10 +3469,10 @@ function AdvancedCollapsible({
3414
3469
  fullScreenTitle,
3415
3470
  fullScreenDescription
3416
3471
  }) {
3417
- const [isOpen, setIsOpen] = React15.useState(initialOpen);
3418
- const [isFullScreen, setIsFullScreen] = React15.useState(false);
3419
- const contentRef = React15.useRef(null);
3420
- const fullRef = React15.useRef(null);
3472
+ const [isOpen, setIsOpen] = React16.useState(initialOpen);
3473
+ const [isFullScreen, setIsFullScreen] = React16.useState(false);
3474
+ const contentRef = React16.useRef(null);
3475
+ const fullRef = React16.useRef(null);
3421
3476
  const handleOpenChange = (open) => {
3422
3477
  setIsOpen(open);
3423
3478
  onStateChange?.(open);
@@ -3436,28 +3491,28 @@ function AdvancedCollapsible({
3436
3491
  else onCopy?.();
3437
3492
  };
3438
3493
  const actions = /* @__PURE__ */ jsxs28("div", { className: "flex items-center justify-end gap-2", children: [
3439
- onSave && /* @__PURE__ */ jsx33(
3494
+ onSave && /* @__PURE__ */ jsx34(
3440
3495
  ActionFeedbackButton,
3441
3496
  {
3442
- icon: /* @__PURE__ */ jsx33(SaveIcon, {}),
3497
+ icon: /* @__PURE__ */ jsx34(SaveIcon, {}),
3443
3498
  glyphTone: "info",
3444
3499
  tooltip: saveTooltip,
3445
3500
  successTooltip: "Saved!",
3446
3501
  onClick: onSave
3447
3502
  }
3448
3503
  ),
3449
- onReset && /* @__PURE__ */ jsx33(
3504
+ onReset && /* @__PURE__ */ jsx34(
3450
3505
  ActionFeedbackButton,
3451
3506
  {
3452
- icon: /* @__PURE__ */ jsx33(RefreshCwIcon, {}),
3507
+ icon: /* @__PURE__ */ jsx34(RefreshCwIcon, {}),
3453
3508
  glyphTone: "warning",
3454
3509
  tooltip: resetTooltip,
3455
3510
  successTooltip: "Reset!",
3456
3511
  onClick: onReset
3457
3512
  }
3458
3513
  ),
3459
- /* @__PURE__ */ jsx33(IconButton, { icon: CopyIcon, tooltip: copyTooltip, onClick: () => void handleCopy() }),
3460
- /* @__PURE__ */ jsx33(
3514
+ /* @__PURE__ */ jsx34(IconButton, { icon: CopyIcon, tooltip: copyTooltip, onClick: () => void handleCopy() }),
3515
+ /* @__PURE__ */ jsx34(
3461
3516
  IconButton,
3462
3517
  {
3463
3518
  icon: isFullScreen ? Minimize2Icon : Maximize2Icon,
@@ -3479,9 +3534,9 @@ function AdvancedCollapsible({
3479
3534
  /* @__PURE__ */ jsxs28(CollapsibleTrigger, { className: "relative flex w-full items-center justify-between rounded-t-xl px-4 py-3 font-medium hover:bg-muted", children: [
3480
3535
  /* @__PURE__ */ jsxs28("div", { className: "flex items-center gap-2", children: [
3481
3536
  icon,
3482
- typeof title === "string" ? /* @__PURE__ */ jsx33("span", { children: title }) : title
3537
+ typeof title === "string" ? /* @__PURE__ */ jsx34("span", { children: title }) : title
3483
3538
  ] }),
3484
- /* @__PURE__ */ jsx33(
3539
+ /* @__PURE__ */ jsx34(
3485
3540
  ChevronDownIcon,
3486
3541
  {
3487
3542
  className: cn(
@@ -3491,27 +3546,27 @@ function AdvancedCollapsible({
3491
3546
  }
3492
3547
  )
3493
3548
  ] }),
3494
- /* @__PURE__ */ jsx33(CollapsibleContent, { children: /* @__PURE__ */ jsxs28("div", { className: "relative", children: [
3495
- /* @__PURE__ */ jsx33("div", { className: "absolute left-8 right-8 top-0 h-px bg-border" }),
3496
- /* @__PURE__ */ jsx33("div", { ref: contentRef, className: "p-4", children }),
3497
- /* @__PURE__ */ jsx33("div", { className: "mb-1 mr-1 mt-2", children: actions })
3549
+ /* @__PURE__ */ jsx34(CollapsibleContent, { children: /* @__PURE__ */ jsxs28("div", { className: "relative", children: [
3550
+ /* @__PURE__ */ jsx34("div", { className: "absolute left-8 right-8 top-0 h-px bg-border" }),
3551
+ /* @__PURE__ */ jsx34("div", { ref: contentRef, className: "p-4", children }),
3552
+ /* @__PURE__ */ jsx34("div", { className: "mb-1 mr-1 mt-2", children: actions })
3498
3553
  ] }) })
3499
3554
  ]
3500
3555
  }
3501
3556
  ),
3502
- /* @__PURE__ */ jsx33(Dialog, { open: isFullScreen, onOpenChange: setIsFullScreen, children: /* @__PURE__ */ jsxs28(DialogContent, { size: "full", height: "tall", children: [
3557
+ /* @__PURE__ */ jsx34(Dialog, { open: isFullScreen, onOpenChange: setIsFullScreen, children: /* @__PURE__ */ jsxs28(DialogContent, { size: "full", height: "tall", children: [
3503
3558
  /* @__PURE__ */ jsxs28(DialogHeader, { children: [
3504
- /* @__PURE__ */ jsx33(DialogTitle, { children: fullScreenTitle || heading }),
3505
- fullScreenDescription ? /* @__PURE__ */ jsx33(DialogDescription, { children: fullScreenDescription }) : null
3559
+ /* @__PURE__ */ jsx34(DialogTitle, { children: fullScreenTitle || heading }),
3560
+ fullScreenDescription ? /* @__PURE__ */ jsx34(DialogDescription, { children: fullScreenDescription }) : null
3506
3561
  ] }),
3507
3562
  actions,
3508
- /* @__PURE__ */ jsx33("div", { ref: fullRef, className: "min-h-0 flex-1 overflow-auto p-4", children })
3563
+ /* @__PURE__ */ jsx34("div", { ref: fullRef, className: "min-h-0 flex-1 overflow-auto p-4", children })
3509
3564
  ] }) })
3510
3565
  ] });
3511
3566
  }
3512
3567
 
3513
3568
  // src/controls/empty-state-card.tsx
3514
- import { jsx as jsx34, jsxs as jsxs29 } from "react/jsx-runtime";
3569
+ import { jsx as jsx35, jsxs as jsxs29 } from "react/jsx-runtime";
3515
3570
  var TONE3 = {
3516
3571
  primary: { data: "primary", button: "primary" },
3517
3572
  success: { data: "success", button: "outline" }
@@ -3527,19 +3582,19 @@ function EmptyStateCard({
3527
3582
  }) {
3528
3583
  const t = TONE3[tone2];
3529
3584
  return /* @__PURE__ */ jsxs29("div", { "data-tone": t.data, className: "matrx-hue-card flex flex-col items-center justify-center px-6 py-12 text-center", children: [
3530
- /* @__PURE__ */ jsx34("div", { className: "matrx-hue-icon mb-6 rounded-full p-6", children: /* @__PURE__ */ jsx34(Icon, { className: "h-12 w-12", strokeWidth: 1.5 }) }),
3531
- /* @__PURE__ */ jsx34("h3", { className: cn("mb-3 text-xl font-semibold", tone2 === "success" ? "text-success-ink" : "text-foreground"), children: title }),
3532
- /* @__PURE__ */ jsx34("p", { className: "mb-8 max-w-md text-muted-foreground", children: description }),
3585
+ /* @__PURE__ */ jsx35("div", { className: "matrx-hue-icon mb-6 rounded-full p-6", children: /* @__PURE__ */ jsx35(Icon, { className: "h-12 w-12", strokeWidth: 1.5 }) }),
3586
+ /* @__PURE__ */ jsx35("h3", { className: cn("mb-3 text-xl font-semibold", tone2 === "success" ? "text-success-ink" : "text-foreground"), children: title }),
3587
+ /* @__PURE__ */ jsx35("p", { className: "mb-8 max-w-md text-muted-foreground", children: description }),
3533
3588
  buttonText && /* @__PURE__ */ jsxs29("div", { className: "flex flex-col gap-4 sm:flex-row", children: [
3534
- /* @__PURE__ */ jsx34(Button2, { variant: t.button, ...tone2 === "success" ? { tone: "success" } : {}, ...onButtonClick ? { onClick: onButtonClick } : {}, children: buttonText }),
3589
+ /* @__PURE__ */ jsx35(Button2, { variant: t.button, ...tone2 === "success" ? { tone: "success" } : {}, ...onButtonClick ? { onClick: onButtonClick } : {}, children: buttonText }),
3535
3590
  secondaryButton
3536
3591
  ] })
3537
3592
  ] });
3538
3593
  }
3539
3594
 
3540
3595
  // src/controls/hue-cards.tsx
3541
- import * as React16 from "react";
3542
- import { Fragment as Fragment9, jsx as jsx35, jsxs as jsxs30 } from "react/jsx-runtime";
3596
+ import * as React17 from "react";
3597
+ import { Fragment as Fragment9, jsx as jsx36, jsxs as jsxs30 } from "react/jsx-runtime";
3543
3598
  var HUE_TONE = {
3544
3599
  indigo: "indigo",
3545
3600
  emerald: "emerald",
@@ -3560,7 +3615,7 @@ var HUE_TONE = {
3560
3615
  slate: "slate"
3561
3616
  };
3562
3617
  function sizedIcon(icon, fallback) {
3563
- return React16.isValidElement(icon) ? React16.cloneElement(icon, { size: icon.props.size || fallback }) : icon;
3618
+ return React17.isValidElement(icon) ? React17.cloneElement(icon, { size: icon.props.size || fallback }) : icon;
3564
3619
  }
3565
3620
  function tone(color) {
3566
3621
  return HUE_TONE[color] ?? HUE_TONE.slate;
@@ -3573,7 +3628,7 @@ function Destination({
3573
3628
  children
3574
3629
  }) {
3575
3630
  if (path) {
3576
- return /* @__PURE__ */ jsx35(
3631
+ return /* @__PURE__ */ jsx36(
3577
3632
  HostLink,
3578
3633
  {
3579
3634
  href: path,
@@ -3584,7 +3639,7 @@ function Destination({
3584
3639
  }
3585
3640
  );
3586
3641
  }
3587
- return /* @__PURE__ */ jsx35("div", { ...className ? { className } : {}, ...onClick ? { onClick } : {}, children });
3642
+ return /* @__PURE__ */ jsx36("div", { ...className ? { className } : {}, ...onClick ? { onClick } : {}, children });
3588
3643
  }
3589
3644
  var SIZE_PADDING = {
3590
3645
  xs: "p-3",
@@ -3607,19 +3662,19 @@ function HueCard({
3607
3662
  external = false
3608
3663
  }) {
3609
3664
  if (compact) {
3610
- return /* @__PURE__ */ jsx35(Destination, { path, onClick, external, children: /* @__PURE__ */ jsxs30(
3665
+ return /* @__PURE__ */ jsx36(Destination, { path, onClick, external, children: /* @__PURE__ */ jsxs30(
3611
3666
  "div",
3612
3667
  {
3613
3668
  "data-tone": tone(color),
3614
3669
  className: cn("matrx-hue-card flex cursor-pointer select-none flex-col items-center gap-1.5", className),
3615
3670
  children: [
3616
- /* @__PURE__ */ jsx35("div", { className: "matrx-hue-squircle flex aspect-square w-full max-w-[62px] items-center justify-center rounded-[22%] shadow-sm transition-colors", children: sizedIcon(icon, 36) }),
3617
- /* @__PURE__ */ jsx35("span", { className: "type-meta w-full truncate px-0.5 text-center font-medium leading-tight text-foreground", children: title })
3671
+ /* @__PURE__ */ jsx36("div", { className: "matrx-hue-squircle flex aspect-square w-full max-w-[62px] items-center justify-center rounded-[22%] shadow-sm transition-colors", children: sizedIcon(icon, 36) }),
3672
+ /* @__PURE__ */ jsx36("span", { className: "type-meta w-full truncate px-0.5 text-center font-medium leading-tight text-foreground", children: title })
3618
3673
  ]
3619
3674
  }
3620
3675
  ) });
3621
3676
  }
3622
- return /* @__PURE__ */ jsx35(Destination, { path, onClick, external, children: /* @__PURE__ */ jsx35(
3677
+ return /* @__PURE__ */ jsx36(Destination, { path, onClick, external, children: /* @__PURE__ */ jsx36(
3623
3678
  "div",
3624
3679
  {
3625
3680
  "data-tone": tone(color),
@@ -3629,9 +3684,9 @@ function HueCard({
3629
3684
  className
3630
3685
  ),
3631
3686
  children: /* @__PURE__ */ jsxs30("div", { className: "flex flex-col items-center space-y-3 text-center", children: [
3632
- /* @__PURE__ */ jsx35("div", { className: "matrx-hue-icon rounded-full p-3", children: sizedIcon(icon, 28) }),
3633
- /* @__PURE__ */ jsx35("h3", { className: "text-lg font-semibold", children: title }),
3634
- description && /* @__PURE__ */ jsx35("p", { className: "type-body text-muted-foreground", children: description }),
3687
+ /* @__PURE__ */ jsx36("div", { className: "matrx-hue-icon rounded-full p-3", children: sizedIcon(icon, 28) }),
3688
+ /* @__PURE__ */ jsx36("h3", { className: "text-lg font-semibold", children: title }),
3689
+ description && /* @__PURE__ */ jsx36("p", { className: "type-body text-muted-foreground", children: description }),
3635
3690
  descriptionNode && !description && descriptionNode
3636
3691
  ] })
3637
3692
  }
@@ -3659,10 +3714,10 @@ function HueGrid({
3659
3714
  }) {
3660
3715
  const colsClass = compact ? "grid-cols-4" : GRID_COLUMNS[Math.min(6, Math.max(1, columns))];
3661
3716
  return /* @__PURE__ */ jsxs30("div", { className, children: [
3662
- title && /* @__PURE__ */ jsx35("h2", { className: "mb-4 text-base font-semibold", children: title }),
3663
- description && /* @__PURE__ */ jsx35("p", { className: "type-body mb-4 text-muted-foreground", children: description }),
3717
+ title && /* @__PURE__ */ jsx36("h2", { className: "mb-4 text-base font-semibold", children: title }),
3718
+ description && /* @__PURE__ */ jsx36("p", { className: "type-body mb-4 text-muted-foreground", children: description }),
3664
3719
  /* @__PURE__ */ jsxs30("div", { className: cn("grid", compact ? "gap-2" : "gap-4", colsClass), children: [
3665
- items.map((item, index) => /* @__PURE__ */ jsx35(HueCard, { ...item, compact, className: cn(cardClassName, item.className) }, `card-${index}`)),
3720
+ items.map((item, index) => /* @__PURE__ */ jsx36(HueCard, { ...item, compact, className: cn(cardClassName, item.className) }, `card-${index}`)),
3666
3721
  showAddButton && /* @__PURE__ */ jsxs30(
3667
3722
  "button",
3668
3723
  {
@@ -3673,8 +3728,8 @@ function HueGrid({
3673
3728
  cardClassName
3674
3729
  ),
3675
3730
  children: [
3676
- /* @__PURE__ */ jsx35("span", { className: "rounded-full bg-muted p-3 text-muted-foreground", children: /* @__PURE__ */ jsx35(PlusIcon, { className: "h-7 w-7" }) }),
3677
- /* @__PURE__ */ jsx35("span", { className: "text-lg font-semibold", children: addButtonText })
3731
+ /* @__PURE__ */ jsx36("span", { className: "rounded-full bg-muted p-3 text-muted-foreground", children: /* @__PURE__ */ jsx36(PlusIcon, { className: "h-7 w-7" }) }),
3732
+ /* @__PURE__ */ jsx36("span", { className: "text-lg font-semibold", children: addButtonText })
3678
3733
  ]
3679
3734
  }
3680
3735
  )
@@ -3689,12 +3744,12 @@ function HueRow({
3689
3744
  color,
3690
3745
  path,
3691
3746
  className,
3692
- rightIcon = /* @__PURE__ */ jsx35(ChevronRightIcon, { className: "h-5 w-5 text-muted-foreground" }),
3747
+ rightIcon = /* @__PURE__ */ jsx36(ChevronRightIcon, { className: "h-5 w-5 text-muted-foreground" }),
3693
3748
  onClick,
3694
3749
  showBorder = true,
3695
3750
  isLast = false
3696
3751
  }) {
3697
- return /* @__PURE__ */ jsx35(Destination, { path, onClick, children: /* @__PURE__ */ jsxs30(
3752
+ return /* @__PURE__ */ jsx36(Destination, { path, onClick, children: /* @__PURE__ */ jsxs30(
3698
3753
  "div",
3699
3754
  {
3700
3755
  "data-tone": tone(color),
@@ -3705,10 +3760,10 @@ function HueRow({
3705
3760
  ),
3706
3761
  children: [
3707
3762
  /* @__PURE__ */ jsxs30("div", { className: "flex items-center", children: [
3708
- /* @__PURE__ */ jsx35("div", { className: "matrx-hue-icon mr-4 rounded-lg p-2", children: sizedIcon(icon, 20) }),
3763
+ /* @__PURE__ */ jsx36("div", { className: "matrx-hue-icon mr-4 rounded-lg p-2", children: sizedIcon(icon, 20) }),
3709
3764
  /* @__PURE__ */ jsxs30("div", { children: [
3710
- /* @__PURE__ */ jsx35("h3", { className: "font-medium", children: title }),
3711
- description && /* @__PURE__ */ jsx35("p", { className: "type-body text-muted-foreground", children: description }),
3765
+ /* @__PURE__ */ jsx36("h3", { className: "font-medium", children: title }),
3766
+ description && /* @__PURE__ */ jsx36("p", { className: "type-body text-muted-foreground", children: description }),
3712
3767
  descriptionNode && !description && descriptionNode
3713
3768
  ] })
3714
3769
  ] }),
@@ -3726,7 +3781,7 @@ function HueList({
3726
3781
  showBorders = true,
3727
3782
  showContainer = true
3728
3783
  }) {
3729
- const rows = items.map((item, index) => /* @__PURE__ */ jsx35(
3784
+ const rows = items.map((item, index) => /* @__PURE__ */ jsx36(
3730
3785
  HueRow,
3731
3786
  {
3732
3787
  ...item,
@@ -3737,13 +3792,13 @@ function HueList({
3737
3792
  `row-${index}`
3738
3793
  ));
3739
3794
  return /* @__PURE__ */ jsxs30("div", { className, children: [
3740
- title && /* @__PURE__ */ jsx35("h2", { className: "mb-4 text-base font-semibold", children: title }),
3741
- description && /* @__PURE__ */ jsx35("p", { className: "type-body mb-4 text-muted-foreground", children: description }),
3742
- showContainer ? /* @__PURE__ */ jsx35("div", { className: "rounded-xl bg-card shadow-md", children: rows }) : rows
3795
+ title && /* @__PURE__ */ jsx36("h2", { className: "mb-4 text-base font-semibold", children: title }),
3796
+ description && /* @__PURE__ */ jsx36("p", { className: "type-body mb-4 text-muted-foreground", children: description }),
3797
+ showContainer ? /* @__PURE__ */ jsx36("div", { className: "rounded-xl bg-card shadow-md", children: rows }) : rows
3743
3798
  ] });
3744
3799
  }
3745
3800
  function IosWidget({ title, description, icon, color, path, badge, className, onClick }) {
3746
- return /* @__PURE__ */ jsx35(Destination, { path, onClick, className: "contents", children: /* @__PURE__ */ jsxs30(
3801
+ return /* @__PURE__ */ jsx36(Destination, { path, onClick, className: "contents", children: /* @__PURE__ */ jsxs30(
3747
3802
  "div",
3748
3803
  {
3749
3804
  "data-tone": tone(color),
@@ -3753,12 +3808,12 @@ function IosWidget({ title, description, icon, color, path, badge, className, on
3753
3808
  ),
3754
3809
  children: [
3755
3810
  /* @__PURE__ */ jsxs30("div", { className: "flex items-start justify-between", children: [
3756
- /* @__PURE__ */ jsx35("div", { children: sizedIcon(icon, 32) }),
3757
- badge && /* @__PURE__ */ jsx35("span", { className: "type-meta rounded-full bg-black/25 px-2 py-0.5 font-semibold leading-tight", children: badge })
3811
+ /* @__PURE__ */ jsx36("div", { children: sizedIcon(icon, 32) }),
3812
+ badge && /* @__PURE__ */ jsx36("span", { className: "type-meta rounded-full bg-black/25 px-2 py-0.5 font-semibold leading-tight", children: badge })
3758
3813
  ] }),
3759
3814
  /* @__PURE__ */ jsxs30("div", { children: [
3760
- /* @__PURE__ */ jsx35("p", { className: "type-title line-clamp-2 leading-tight", children: title }),
3761
- description && /* @__PURE__ */ jsx35("p", { className: "type-meta mt-0.5 line-clamp-2 leading-tight", children: description })
3815
+ /* @__PURE__ */ jsx36("p", { className: "type-title line-clamp-2 leading-tight", children: title }),
3816
+ description && /* @__PURE__ */ jsx36("p", { className: "type-meta mt-0.5 line-clamp-2 leading-tight", children: description })
3762
3817
  ] })
3763
3818
  ]
3764
3819
  }
@@ -3770,20 +3825,20 @@ function TileCard({ icon, title, description, onClick, href, className }) {
3770
3825
  className
3771
3826
  );
3772
3827
  const content = /* @__PURE__ */ jsxs30(Fragment9, { children: [
3773
- icon && /* @__PURE__ */ jsx35("div", { className: "h-12 w-12 text-primary-ink", children: icon }),
3774
- title && /* @__PURE__ */ jsx35("span", { className: "font-medium text-primary-ink", children: title }),
3775
- description && /* @__PURE__ */ jsx35("p", { className: "type-secondary mt-1 text-center text-muted-foreground", children: description })
3828
+ icon && /* @__PURE__ */ jsx36("div", { className: "h-12 w-12 text-primary-ink", children: icon }),
3829
+ title && /* @__PURE__ */ jsx36("span", { className: "font-medium text-primary-ink", children: title }),
3830
+ description && /* @__PURE__ */ jsx36("p", { className: "type-secondary mt-1 text-center text-muted-foreground", children: description })
3776
3831
  ] });
3777
- return href ? /* @__PURE__ */ jsx35(HostLink, { href, className: face, children: content }) : /* @__PURE__ */ jsx35("div", { onClick, className: face, children: content });
3832
+ return href ? /* @__PURE__ */ jsx36(HostLink, { href, className: face, children: content }) : /* @__PURE__ */ jsx36("div", { onClick, className: face, children: content });
3778
3833
  }
3779
3834
  var TILE_COLUMNS = { 1: "md:grid-cols-1", 2: "md:grid-cols-2", 3: "md:grid-cols-3", 4: "md:grid-cols-4" };
3780
3835
  function TileCardGrid({ title, description, cards, columns = 2, className }) {
3781
3836
  return /* @__PURE__ */ jsxs30("div", { className: cn("w-full", className), children: [
3782
3837
  (title || description) && /* @__PURE__ */ jsxs30("div", { className: "pb-8 text-center", children: [
3783
- title && /* @__PURE__ */ jsx35("h2", { className: "text-2xl font-bold text-foreground md:text-3xl", children: title }),
3784
- description && /* @__PURE__ */ jsx35("p", { className: "mt-2 text-muted-foreground", children: description })
3838
+ title && /* @__PURE__ */ jsx36("h2", { className: "text-2xl font-bold text-foreground md:text-3xl", children: title }),
3839
+ description && /* @__PURE__ */ jsx36("p", { className: "mt-2 text-muted-foreground", children: description })
3785
3840
  ] }),
3786
- /* @__PURE__ */ jsx35("div", { className: cn("grid grid-cols-1 gap-6", TILE_COLUMNS[columns] ?? TILE_COLUMNS[2]), children: cards.map((card, index) => /* @__PURE__ */ jsx35(TileCard, { ...card }, index)) })
3841
+ /* @__PURE__ */ jsx36("div", { className: cn("grid grid-cols-1 gap-6", TILE_COLUMNS[columns] ?? TILE_COLUMNS[2]), children: cards.map((card, index) => /* @__PURE__ */ jsx36(TileCard, { ...card }, index)) })
3787
3842
  ] });
3788
3843
  }
3789
3844
 
@@ -3792,6 +3847,9 @@ export {
3792
3847
  countIsStale,
3793
3848
  unavailableCountLabel,
3794
3849
  UntrustedCount,
3850
+ WindowLights,
3851
+ WindowLight,
3852
+ WindowChromeButton,
3795
3853
  DecisionControl,
3796
3854
  parseTypedDate,
3797
3855
  parseTypedTime,
@@ -3860,4 +3918,4 @@ export {
3860
3918
  TileCard,
3861
3919
  TileCardGrid
3862
3920
  };
3863
- //# sourceMappingURL=chunk-T4IJELSS.js.map
3921
+ //# sourceMappingURL=chunk-KYH42WEX.js.map