@ai-matrx/agents 0.59.213 → 0.59.215

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.
@@ -427,116 +427,59 @@ var import_design_system2 = require("@ai-matrx/design-system");
427
427
  var import_controls = require("@ai-matrx/design-system/controls");
428
428
 
429
429
  // settings/react/settings-icons.tsx
430
- var import_jsx_runtime = require("react/jsx-runtime");
431
- function Svg({ className, children }) {
432
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
433
- "svg",
434
- {
435
- xmlns: "http://www.w3.org/2000/svg",
436
- viewBox: "0 0 24 24",
437
- fill: "none",
438
- stroke: "currentColor",
439
- strokeWidth: 2,
440
- strokeLinecap: "round",
441
- strokeLinejoin: "round",
442
- "aria-hidden": "true",
443
- className,
444
- children
445
- }
446
- );
447
- }
448
- var CircleCheckGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
449
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
450
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "m16 9-5.5 5.5L8 12" })
451
- ] });
452
- var TriangleAlertGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
453
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }),
454
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M12 9v4" }),
455
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M12 17h.01" })
456
- ] });
457
- var VariableGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
458
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M8 21s-4-3-4-9 4-9 4-9" }),
459
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M16 3s4 3 4 9-4 9-4 9" }),
460
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", { x1: "15", x2: "9", y1: "9", y2: "15" }),
461
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", { x1: "9", x2: "15", y1: "9", y2: "15" })
462
- ] });
463
- var UnlinkGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
464
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71" }),
465
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71" }),
466
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", { x1: "8", x2: "8", y1: "2", y2: "5" }),
467
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", { x1: "2", x2: "5", y1: "8", y2: "8" }),
468
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", { x1: "16", x2: "16", y1: "19", y2: "22" }),
469
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("line", { x1: "19", x2: "22", y1: "16", y2: "16" })
470
- ] });
471
- var WrenchGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Svg, { className, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z" }) });
472
- var Trash2Glyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
473
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M10 11v6" }),
474
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M14 11v6" }),
475
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6" }),
476
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M3 6h18" }),
477
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" })
478
- ] });
479
- var RotateCcwGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
480
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8" }),
481
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M3 3v5h5" })
482
- ] });
483
- var ImageGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
484
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", ry: "2" }),
485
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("circle", { cx: "9", cy: "9", r: "2" }),
486
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21" })
487
- ] });
488
- var FileTextGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
489
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z" }),
490
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M14 2v4a2 2 0 0 0 2 2h4" }),
491
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M10 9H8" }),
492
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M16 13H8" }),
493
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M16 17H8" })
494
- ] });
495
- var YoutubeGlyph = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Svg, { className, children: [
496
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17" }),
497
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "m10 15 5-3-5-3z" })
498
- ] });
430
+ var import_icons = require("@ai-matrx/design-system/icons");
431
+ var sized = (Glyph) => Glyph;
432
+ var CircleCheckGlyph = sized(import_icons.CircleCheckIcon);
433
+ var TriangleAlertGlyph = sized(import_icons.AlertTriangleIcon);
434
+ var VariableGlyph = sized(import_icons.VariableIcon);
435
+ var UnlinkGlyph = sized(import_icons.UnlinkIcon);
436
+ var WrenchGlyph = sized(import_icons.WrenchIcon);
437
+ var Trash2Glyph = sized(import_icons.Trash2Icon);
438
+ var RotateCcwGlyph = sized(import_icons.RotateCcwIcon);
439
+ var ImageGlyph = sized(import_icons.ImageIcon);
440
+ var FileTextGlyph = sized(import_icons.FileTextIcon);
441
+ var YoutubeGlyph = sized(import_icons.YoutubeIcon);
499
442
 
500
443
  // settings/react/SettingRowFrame.tsx
501
444
  var import_design_system = require("@ai-matrx/design-system");
502
- var import_jsx_runtime2 = require("react/jsx-runtime");
503
- var cn = (...parts) => parts.filter(Boolean).join(" ");
445
+ var import_cn = require("@ai-matrx/design-system/cn");
446
+ var import_jsx_runtime = require("react/jsx-runtime");
504
447
  function formatSettingValue(value) {
505
448
  if (typeof value === "boolean") return value ? "On" : "Off";
506
449
  if (value !== null && typeof value === "object") return JSON.stringify(value);
507
450
  return String(value);
508
451
  }
509
452
  function SettingRowFrame({ rowKey, state, leading, label, children, actions }) {
510
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
453
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
511
454
  "div",
512
455
  {
513
456
  "data-setting-row": rowKey,
514
457
  "data-setting-state": state,
515
458
  className: "grid grid-cols-[1rem_minmax(0,1fr)_auto] items-start gap-x-2 gap-y-1 py-1 @md:grid-cols-[1rem_9rem_minmax(0,1fr)_auto]",
516
459
  children: [
517
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "flex h-7 items-center", children: leading }),
518
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "flex min-h-7 min-w-0 items-center", children: label }),
519
- children !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "col-span-2 col-start-2 row-start-2 min-w-0 @md:col-span-1 @md:col-start-3 @md:row-start-1", children }) : null,
520
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "col-start-3 row-start-1 flex min-h-7 items-center justify-end @md:col-start-4", children: actions })
460
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "flex h-7 items-center", children: leading }),
461
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "flex min-h-7 min-w-0 items-center", children: label }),
462
+ children !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "col-span-2 col-start-2 row-start-2 min-w-0 @md:col-span-1 @md:col-start-3 @md:row-start-1", children }) : null,
463
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "col-start-3 row-start-1 flex min-h-7 items-center justify-end @md:col-start-4", children: actions })
521
464
  ]
522
465
  }
523
466
  );
524
467
  }
525
468
  function RowLabel({ htmlFor, muted, children }) {
526
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_design_system.Label, { htmlFor, className: cn("min-w-0 truncate type-body", muted ? "text-muted-foreground" : "text-foreground"), children });
469
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_design_system.Label, { htmlFor, className: (0, import_cn.cn)("min-w-0 truncate type-body", muted ? "text-muted-foreground" : "text-foreground"), children });
527
470
  }
528
471
  function RowText({ children, mono }) {
529
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: cn("flex min-h-7 items-center truncate type-secondary text-muted-foreground", mono && "font-mono"), children });
472
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: (0, import_cn.cn)("flex min-h-7 items-center truncate type-secondary text-muted-foreground", mono && "font-mono"), children });
530
473
  }
531
474
  function SettingsGroupSection({ id, title, children }) {
532
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("section", { "data-settings-group": id, className: title ? "mt-2 border-t border-border pt-2" : void 0, children: [
533
- title ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("h3", { className: "pb-1 type-title text-foreground", children: title }) : null,
475
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", { "data-settings-group": id, className: title ? "mt-2 border-t border-border pt-2" : void 0, children: [
476
+ title ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h3", { className: "pb-1 type-title text-foreground", children: title }) : null,
534
477
  children
535
478
  ] });
536
479
  }
537
480
 
538
481
  // settings/react/InputCapabilitiesEditor.tsx
539
- var import_jsx_runtime3 = require("react/jsx-runtime");
482
+ var import_jsx_runtime2 = require("react/jsx-runtime");
540
483
  var GATE_META = {
541
484
  image_urls: {
542
485
  label: "Image URLs",
@@ -565,24 +508,24 @@ function InputCapabilitiesEditor({
565
508
  title = "Input Capabilities",
566
509
  disabled = false
567
510
  }) {
568
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(SettingsGroupSection, { id: "input-capabilities", title, children: [
511
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(SettingsGroupSection, { id: "input-capabilities", title, children: [
569
512
  UI_GATE_EDITABLE_KEYS.map((key) => {
570
513
  const { label, description, Icon } = GATE_META[key];
571
514
  const switchId = `${idPrefix}-${key}`;
572
515
  const changed = changedKeys?.has(key) === true;
573
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
516
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
574
517
  SettingRowFrame,
575
518
  {
576
519
  rowKey: key,
577
520
  state: values[key] === true ? "on" : "off",
578
- leading: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Icon, { className: "h-4 w-4 text-muted-foreground" }),
579
- label: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(RowLabel, { htmlFor: switchId, children: label }),
580
- actions: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
581
- changed && onReset ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
521
+ leading: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(Icon, { className: "h-4 w-4 text-muted-foreground" }),
522
+ label: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(RowLabel, { htmlFor: switchId, children: label }),
523
+ actions: /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
524
+ changed && onReset ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
582
525
  import_controls.Button,
583
526
  {
584
527
  variant: "quiet",
585
- icon: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(RotateCcwGlyph, {}),
528
+ icon: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(RotateCcwGlyph, {}),
586
529
  onClick: () => onReset(key),
587
530
  disabled,
588
531
  "aria-label": `${resetLabel}: ${label}`,
@@ -590,7 +533,7 @@ function InputCapabilitiesEditor({
590
533
  "data-setting-reset": key
591
534
  }
592
535
  ) : null,
593
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
536
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
594
537
  import_controls.Switch,
595
538
  {
596
539
  id: switchId,
@@ -600,12 +543,12 @@ function InputCapabilitiesEditor({
600
543
  }
601
544
  )
602
545
  ] }),
603
- children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(RowText, { children: description })
546
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(RowText, { children: description })
604
547
  },
605
548
  key
606
549
  );
607
550
  }),
608
- error ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_design_system2.ErrorBox, { as: "p", className: "py-1 type-meta text-destructive", message: error }) : null
551
+ error ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_design_system2.ErrorBox, { as: "p", className: "py-1 type-meta text-destructive", message: error }) : null
609
552
  ] });
610
553
  }
611
554
 
@@ -613,7 +556,7 @@ function InputCapabilitiesEditor({
613
556
  var import_react = require("react");
614
557
  var import_design_system3 = require("@ai-matrx/design-system");
615
558
  var import_controls2 = require("@ai-matrx/design-system/controls");
616
- var import_jsx_runtime4 = require("react/jsx-runtime");
559
+ var import_jsx_runtime3 = require("react/jsx-runtime");
617
560
  var SELECT_MAX_OPTIONS = 12;
618
561
  function choiceFor(options) {
619
562
  if ((0, import_controls2.isAspectRatioOptionSet)(options)) return "aspect-ratio";
@@ -621,10 +564,10 @@ function choiceFor(options) {
621
564
  return "select";
622
565
  }
623
566
  function WarningIcon({ className }) {
624
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", className, children: [
625
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }),
626
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 9v4" }),
627
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 17h.01" })
567
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", className, children: [
568
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }),
569
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M12 9v4" }),
570
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M12 17h.01" })
628
571
  ] });
629
572
  }
630
573
  function flattenTypeObject(value) {
@@ -648,7 +591,7 @@ function SettingControlInput({
648
591
  const isValueMismatch = stringValue !== "" && !control.enum.includes(stringValue);
649
592
  const emit = (v) => onChange(settingKey === "response_format" ? { type: v } : v);
650
593
  const choice = choiceFor(control.enum);
651
- const picker = choice === "aspect-ratio" ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
594
+ const picker = choice === "aspect-ratio" ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
652
595
  import_controls2.AspectRatioSelect,
653
596
  {
654
597
  value: isValueMismatch ? "" : stringValue,
@@ -659,7 +602,7 @@ function SettingControlInput({
659
602
  id: inputId,
660
603
  placeholder: "Default"
661
604
  }
662
- ) : choice === "searchable" ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
605
+ ) : choice === "searchable" ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
663
606
  import_controls2.OptionCombobox,
664
607
  {
665
608
  value: isValueMismatch ? "" : stringValue,
@@ -671,23 +614,23 @@ function SettingControlInput({
671
614
  placeholder: "Default"
672
615
  }
673
616
  ) : null;
674
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "flex flex-1 items-center gap-1.5", children: [
675
- picker ?? /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
617
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "flex flex-1 items-center gap-1.5", children: [
618
+ picker ?? /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
676
619
  import_design_system3.Select,
677
620
  {
678
621
  value: isValueMismatch ? "" : stringValue,
679
622
  onValueChange: emit,
680
623
  disabled,
681
624
  children: [
682
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
625
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
683
626
  import_design_system3.SelectTrigger,
684
627
  {
685
628
  id: inputId,
686
629
  className: "h-7 flex-1 border-0 bg-transparent px-1 text-xs font-medium text-foreground shadow-none hover:bg-transparent focus:ring-0 pointer-coarse:h-11 [&_svg]:h-3 [&_svg]:w-3",
687
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_design_system3.SelectValue, { placeholder: isValueMismatch ? stringValue : "Default" })
630
+ children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_design_system3.SelectValue, { placeholder: isValueMismatch ? stringValue : "Default" })
688
631
  }
689
632
  ),
690
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_design_system3.SelectContent, { className: "text-xs", children: control.enum.map((option) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
633
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_design_system3.SelectContent, { className: "text-xs", children: control.enum.map((option) => /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
691
634
  import_design_system3.SelectItem,
692
635
  {
693
636
  value: option,
@@ -699,9 +642,9 @@ function SettingControlInput({
699
642
  ]
700
643
  }
701
644
  ),
702
- isValueMismatch && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_design_system3.TooltipProvider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_design_system3.Tooltip, { children: [
703
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_design_system3.TooltipTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "shrink-0 cursor-help text-amber-500", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(WarningIcon, { className: "h-3.5 w-3.5" }) }) }),
704
- /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_design_system3.TooltipContent, { side: "top", className: "max-w-[220px] type-secondary", children: [
645
+ isValueMismatch && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_design_system3.TooltipProvider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_design_system3.Tooltip, { children: [
646
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_design_system3.TooltipTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { className: "shrink-0 cursor-help text-amber-500", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(WarningIcon, { className: "h-3.5 w-3.5" }) }) }),
647
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_design_system3.TooltipContent, { side: "top", className: "max-w-[220px] type-secondary", children: [
705
648
  '"',
706
649
  stringValue,
707
650
  '" is not a recognized option for this model'
@@ -710,8 +653,8 @@ function SettingControlInput({
710
653
  ] });
711
654
  }
712
655
  if (control.type === "boolean") {
713
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "flex items-center gap-2", children: [
714
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
656
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "flex items-center gap-2", children: [
657
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
715
658
  import_design_system3.Checkbox,
716
659
  {
717
660
  id: inputId,
@@ -721,7 +664,7 @@ function SettingControlInput({
721
664
  className: "cursor-pointer"
722
665
  }
723
666
  ),
724
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
667
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
725
668
  import_design_system3.Label,
726
669
  {
727
670
  htmlFor: inputId,
@@ -734,7 +677,7 @@ function SettingControlInput({
734
677
  if (control.type === "number" || control.type === "integer") {
735
678
  const numeric = typeof value === "number" ? value : void 0;
736
679
  const hasRange = control.min !== void 0 && control.max !== void 0;
737
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
680
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
738
681
  NumberInput,
739
682
  {
740
683
  value: numeric,
@@ -752,7 +695,7 @@ function SettingControlInput({
752
695
  }
753
696
  if (control.type === "string_array") {
754
697
  const arrayValue = Array.isArray(value) ? value.join("\n") : "";
755
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
698
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
756
699
  import_design_system3.Textarea,
757
700
  {
758
701
  id: inputId,
@@ -765,7 +708,7 @@ function SettingControlInput({
765
708
  );
766
709
  }
767
710
  if (control.type === "array" || control.type === "object_array" || typeof value === "object" && value !== null) {
768
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
711
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
769
712
  JsonValueInput,
770
713
  {
771
714
  id: inputId,
@@ -775,7 +718,7 @@ function SettingControlInput({
775
718
  }
776
719
  );
777
720
  }
778
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
721
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
779
722
  import_design_system3.Input,
780
723
  {
781
724
  id: inputId,
@@ -800,8 +743,8 @@ function JsonValueInput({
800
743
  setDraft(toText(value));
801
744
  setJsonError(null);
802
745
  }, [JSON.stringify(value)]);
803
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "flex flex-col gap-1", children: [
804
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
746
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "flex flex-col gap-1", children: [
747
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
805
748
  import_design_system3.Textarea,
806
749
  {
807
750
  id,
@@ -828,7 +771,7 @@ function JsonValueInput({
828
771
  spellCheck: false
829
772
  }
830
773
  ),
831
- jsonError && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("p", { className: "type-meta text-amber-600 dark:text-amber-400", children: jsonError })
774
+ jsonError && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("p", { className: "type-meta text-amber-600 dark:text-amber-400", children: jsonError })
832
775
  ] });
833
776
  }
834
777
  function NumberInput({
@@ -862,12 +805,12 @@ function NumberInput({
862
805
  } else setDraft(shown);
863
806
  };
864
807
  if (withSlider) {
865
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
808
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
866
809
  "div",
867
810
  {
868
811
  className: "grid grid-cols-[1fr_4.5rem] items-center gap-2",
869
812
  children: [
870
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
813
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
871
814
  import_design_system3.Slider,
872
815
  {
873
816
  ...min !== void 0 ? { min } : {},
@@ -885,7 +828,7 @@ function NumberInput({
885
828
  disabled
886
829
  }
887
830
  ),
888
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
831
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
889
832
  import_design_system3.Input,
890
833
  {
891
834
  type: "text",
@@ -906,7 +849,7 @@ function NumberInput({
906
849
  }
907
850
  );
908
851
  }
909
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
852
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
910
853
  import_design_system3.Input,
911
854
  {
912
855
  type: "text",
@@ -926,28 +869,28 @@ function NumberInput({
926
869
  }
927
870
 
928
871
  // settings/react/ModelSettingsPanel.tsx
929
- var import_jsx_runtime5 = require("react/jsx-runtime");
872
+ var import_jsx_runtime4 = require("react/jsx-runtime");
930
873
  function StatusGlyph({ issue, source }) {
931
874
  const title = issue ? issue.message : source ? `Valid \xB7 ${source}` : "Valid";
932
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
875
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
933
876
  "span",
934
877
  {
935
- className: cn("inline-flex h-7 w-6 shrink-0 items-center justify-center", issue ? "text-warning" : "text-success"),
878
+ className: (0, import_cn.cn)("inline-flex h-7 w-6 shrink-0 items-center justify-center", issue ? "text-warning" : "text-success"),
936
879
  role: "img",
937
880
  "aria-label": title,
938
881
  title,
939
- children: issue ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(TriangleAlertGlyph, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(CircleCheckGlyph, { className: "h-3.5 w-3.5" })
882
+ children: issue ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(TriangleAlertGlyph, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(CircleCheckGlyph, { className: "h-3.5 w-3.5" })
940
883
  }
941
884
  );
942
885
  }
943
886
  function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
944
887
  const read = target.read(row.key, control);
945
888
  const resetLabel = target.resetLabel ?? "Reset to agent";
946
- const reset = read.changedHere && target.resetToInherited ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
889
+ const reset = read.changedHere && target.resetToInherited ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
947
890
  import_controls3.Button,
948
891
  {
949
892
  variant: "quiet",
950
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RotateCcwGlyph, {}),
893
+ icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RotateCcwGlyph, {}),
951
894
  onClick: () => target.resetToInherited?.(row.key),
952
895
  disabled,
953
896
  "aria-label": `${resetLabel}: ${row.label}`,
@@ -956,20 +899,20 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
956
899
  }
957
900
  ) : null;
958
901
  if (read.state === "bound") {
959
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
902
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
960
903
  SettingRowFrame,
961
904
  {
962
905
  rowKey: row.key,
963
906
  state: "bound",
964
- leading: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_design_system4.Checkbox, { checked: true, disabled: true, "aria-label": `${row.label} is a run input` }),
965
- label: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RowLabel, { children: row.label }),
966
- actions: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
907
+ leading: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_design_system4.Checkbox, { checked: true, disabled: true, "aria-label": `${row.label} is a run input` }),
908
+ label: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RowLabel, { children: row.label }),
909
+ actions: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
967
910
  reset,
968
- target.unbind ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
911
+ target.unbind ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
969
912
  import_controls3.Button,
970
913
  {
971
914
  variant: "quiet",
972
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(UnlinkGlyph, {}),
915
+ icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(UnlinkGlyph, {}),
973
916
  onClick: () => target.unbind?.(row.key, control),
974
917
  disabled,
975
918
  "aria-label": `Make ${row.label} a fixed setting`,
@@ -977,9 +920,9 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
977
920
  }
978
921
  ) : null
979
922
  ] }),
980
- children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "flex min-h-7 min-w-0 items-center gap-2", "data-bound-control": row.key, children: [
981
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_controls3.Chip, { tone: "primary", icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(VariableGlyph, {}), label: `{{${read.variableName}}}` }),
982
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "truncate type-meta text-muted-foreground", children: read.value === void 0 || read.value === null || read.value === "" ? "Model default" : formatSettingValue(read.value) })
923
+ children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("span", { className: "flex min-h-7 min-w-0 items-center gap-2", "data-bound-control": row.key, children: [
924
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_controls3.Chip, { tone: "primary", icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(VariableGlyph, {}), label: `{{${read.variableName}}}` }),
925
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "truncate type-meta text-muted-foreground", children: read.value === void 0 || read.value === null || read.value === "" ? "Model default" : formatSettingValue(read.value) })
983
926
  ] })
984
927
  }
985
928
  );
@@ -989,12 +932,12 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
989
932
  const isOff = isSet && isOffValue(value, control);
990
933
  const checkboxId = `${idPrefix}-setting-${row.key}`;
991
934
  const canBind = Boolean(target.bind) && (target.canBind?.(row.key) ?? true);
992
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
935
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
993
936
  SettingRowFrame,
994
937
  {
995
938
  rowKey: row.key,
996
939
  state: isOff ? "off" : read.state,
997
- leading: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
940
+ leading: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
998
941
  import_design_system4.Checkbox,
999
942
  {
1000
943
  id: checkboxId,
@@ -1003,14 +946,14 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
1003
946
  onCheckedChange: (next) => next === true ? target.turnOn(row.key, control) : target.clear(row.key)
1004
947
  }
1005
948
  ),
1006
- label: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RowLabel, { htmlFor: checkboxId, muted: !isSet, children: row.label }),
1007
- actions: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
1008
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(StatusGlyph, { issue: read.issue, source: read.source }),
1009
- canBind ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
949
+ label: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RowLabel, { htmlFor: checkboxId, muted: !isSet, children: row.label }),
950
+ actions: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
951
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(StatusGlyph, { issue: read.issue, source: read.source }),
952
+ canBind ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1010
953
  import_controls3.Button,
1011
954
  {
1012
955
  variant: "quiet",
1013
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(VariableGlyph, {}),
956
+ icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(VariableGlyph, {}),
1014
957
  onClick: () => target.bind?.(row.key, control),
1015
958
  disabled,
1016
959
  "aria-label": `Make ${row.label} a run input`,
@@ -1018,11 +961,11 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
1018
961
  "data-bind-control": row.key
1019
962
  }
1020
963
  ) : null,
1021
- isSet && read.issue?.fixable && target.fix ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
964
+ isSet && read.issue?.fixable && target.fix ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1022
965
  import_controls3.Button,
1023
966
  {
1024
967
  variant: "quiet",
1025
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(WrenchGlyph, {}),
968
+ icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(WrenchGlyph, {}),
1026
969
  onClick: () => target.fix?.(row.key),
1027
970
  disabled,
1028
971
  "aria-label": `Fix ${row.label} automatically`,
@@ -1030,12 +973,12 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
1030
973
  }
1031
974
  ) : null,
1032
975
  reset,
1033
- isSet ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
976
+ isSet ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1034
977
  import_controls3.Button,
1035
978
  {
1036
979
  variant: "quiet",
1037
980
  removes: true,
1038
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Trash2Glyph, {}),
981
+ icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Trash2Glyph, {}),
1039
982
  onClick: () => target.clear(row.key),
1040
983
  disabled,
1041
984
  "aria-label": `Clear ${row.label} to not set`,
@@ -1044,8 +987,8 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
1044
987
  }
1045
988
  ) : null
1046
989
  ] }),
1047
- children: isSet ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
1048
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
990
+ children: isSet ? /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
991
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1049
992
  SettingControlInput,
1050
993
  {
1051
994
  settingKey: row.key,
@@ -1056,40 +999,40 @@ function ModelSettingRow({ row, control, target, idPrefix, disabled }) {
1056
999
  id: `${idPrefix}-control-${row.key}`
1057
1000
  }
1058
1001
  ),
1059
- read.issue ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "pt-1 type-meta text-warning-ink", children: read.issue.message }) : null
1060
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RowText, { children: read.modelDefault !== void 0 && read.modelDefault !== null ? `Not set \xB7 Model default: ${formatSettingValue(read.modelDefault)}` : "Not set" })
1002
+ read.issue ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("p", { className: "pt-1 type-meta text-warning-ink", children: read.issue.message }) : null
1003
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RowText, { children: read.modelDefault !== void 0 && read.modelDefault !== null ? `Not set \xB7 Model default: ${formatSettingValue(read.modelDefault)}` : "Not set" })
1061
1004
  }
1062
1005
  );
1063
1006
  }
1064
1007
  function ExtraSettingRow({ rowKey, label, value, kind, onClear, onReset, resetLabel = "Reset to agent", disabled = false }) {
1065
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1008
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1066
1009
  SettingRowFrame,
1067
1010
  {
1068
1011
  rowKey,
1069
1012
  state: kind,
1070
- label: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RowLabel, { children: label }),
1071
- actions: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
1072
- kind === "translated" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_controls3.Chip, { tone: "sky", label: "Translated", title: "Kept as set and sent as this model's closest equivalent" }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_controls3.Chip, { tone: "warning", label: "Not on this model", title: "This model has no such setting" }),
1073
- onReset ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_controls3.Button, { variant: "quiet", icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RotateCcwGlyph, {}), onClick: onReset, disabled, "aria-label": `${resetLabel}: ${label}`, title: resetLabel, "data-setting-reset": rowKey }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_controls3.Button, { variant: "quiet", removes: true, icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Trash2Glyph, {}), onClick: onClear, disabled, "aria-label": `Clear ${label}`, title: "Clear to not set", "data-setting-clear": rowKey })
1013
+ label: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RowLabel, { children: label }),
1014
+ actions: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
1015
+ kind === "translated" ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_controls3.Chip, { tone: "sky", label: "Translated", title: "Kept as set and sent as this model's closest equivalent" }) : /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_controls3.Chip, { tone: "warning", label: "Not on this model", title: "This model has no such setting" }),
1016
+ onReset ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_controls3.Button, { variant: "quiet", icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RotateCcwGlyph, {}), onClick: onReset, disabled, "aria-label": `${resetLabel}: ${label}`, title: resetLabel, "data-setting-reset": rowKey }) : /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_controls3.Button, { variant: "quiet", removes: true, icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Trash2Glyph, {}), onClick: onClear, disabled, "aria-label": `Clear ${label}`, title: "Clear to not set", "data-setting-clear": rowKey })
1074
1017
  ] }),
1075
- children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RowText, { mono: value !== void 0 && value !== null, children: value === void 0 || value === null ? "Not set" : isOffValue(value, null) ? "Off" : formatSettingValue(value) })
1018
+ children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RowText, { mono: value !== void 0 && value !== null, children: value === void 0 || value === null ? "Not set" : isOffValue(value, null) ? "Off" : formatSettingValue(value) })
1076
1019
  }
1077
1020
  );
1078
1021
  }
1079
1022
  function ModelRow({ model, resetLabel, idPrefix, disabled }) {
1080
1023
  const off = disabled || model.disabled === true;
1081
1024
  const oneMessageId = `${idPrefix}-model-one-message`;
1082
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1025
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1083
1026
  SettingRowFrame,
1084
1027
  {
1085
1028
  rowKey: "model",
1086
1029
  state: model.value ? "set" : "unset",
1087
- label: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RowLabel, { children: "Model" }),
1088
- actions: model.changedHere && model.resetToInherited ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1030
+ label: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RowLabel, { children: "Model" }),
1031
+ actions: model.changedHere && model.resetToInherited ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1089
1032
  import_controls3.Button,
1090
1033
  {
1091
1034
  variant: "quiet",
1092
- icon: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RotateCcwGlyph, {}),
1035
+ icon: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(RotateCcwGlyph, {}),
1093
1036
  onClick: () => model.resetToInherited?.(),
1094
1037
  disabled: off,
1095
1038
  "aria-label": `${resetLabel}: Model`,
@@ -1097,8 +1040,8 @@ function ModelRow({ model, resetLabel, idPrefix, disabled }) {
1097
1040
  "data-setting-reset": "model"
1098
1041
  }
1099
1042
  ) : null,
1100
- children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex min-h-7 min-w-0 flex-wrap items-center gap-x-2", children: [
1101
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1043
+ children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "flex min-h-7 min-w-0 flex-wrap items-center gap-x-2", children: [
1044
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1102
1045
  import_react2.ModelListDropdown,
1103
1046
  {
1104
1047
  "aria-label": "Model",
@@ -1114,8 +1057,8 @@ function ModelRow({ model, resetLabel, idPrefix, disabled }) {
1114
1057
  ...model.disabledTitle ? { disabledTitle: model.disabledTitle } : {}
1115
1058
  }
1116
1059
  ),
1117
- model.oneMessage ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { htmlFor: oneMessageId, className: "flex min-h-7 items-center gap-1 type-secondary text-muted-foreground", title: "Use this model for the next message, then go back", children: [
1118
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1060
+ model.oneMessage ? /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("label", { htmlFor: oneMessageId, className: "flex min-h-7 items-center gap-1 type-secondary text-muted-foreground", title: "Use this model for the next message, then go back", children: [
1061
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1119
1062
  import_controls3.Switch,
1120
1063
  {
1121
1064
  id: oneMessageId,
@@ -1145,7 +1088,7 @@ function ModelSettingsPanel({
1145
1088
  const groups = controls ? buildSettingsRows(controls, values).filter((group) => group.rows.length > 0) : [];
1146
1089
  const extras = extraSettingKeys(controls, values, target.changedKeys);
1147
1090
  const resetLabel = target.resetLabel ?? "Reset to agent";
1148
- const extraRow = (key, kind) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1091
+ const extraRow = (key, kind) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1149
1092
  ExtraSettingRow,
1150
1093
  {
1151
1094
  rowKey: key,
@@ -1159,17 +1102,17 @@ function ModelSettingsPanel({
1159
1102
  },
1160
1103
  key
1161
1104
  );
1162
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { "data-model-settings-panel": "", className: "@container flex min-w-0 flex-col", children: [
1163
- model ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ModelRow, { model, resetLabel, idPrefix, disabled }) : null,
1105
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { "data-model-settings-panel": "", className: "@container flex min-w-0 flex-col", children: [
1106
+ model ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ModelRow, { model, resetLabel, idPrefix, disabled }) : null,
1164
1107
  notices,
1165
1108
  extras.unsupported.map((key) => extraRow(key, "unsupported")),
1166
- extras.translated.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SettingsGroupSection, { id: "translated", title: "Translated for this model", children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { "data-translated-settings": "", children: extras.translated.map((key) => extraRow(key, "translated")) }) }) : null,
1167
- groups.length === 0 && emptyNote ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "py-2 type-secondary text-muted-foreground", children: emptyNote }) : null,
1168
- groups.map((group) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SettingsGroupSection, { id: group.id, title: group.label || void 0, children: group.rows.map((row) => {
1109
+ extras.translated.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SettingsGroupSection, { id: "translated", title: "Translated for this model", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { "data-translated-settings": "", children: extras.translated.map((key) => extraRow(key, "translated")) }) }) : null,
1110
+ groups.length === 0 && emptyNote ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "py-2 type-secondary text-muted-foreground", children: emptyNote }) : null,
1111
+ groups.map((group) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SettingsGroupSection, { id: group.id, title: group.label || void 0, children: group.rows.map((row) => {
1169
1112
  const custom = renderRow?.(row);
1170
- if (custom !== void 0) return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { children: custom }, row.key);
1113
+ if (custom !== void 0) return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { children: custom }, row.key);
1171
1114
  if (!row.control) return null;
1172
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1115
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1173
1116
  ModelSettingRow,
1174
1117
  {
1175
1118
  row,
@@ -1181,7 +1124,7 @@ function ModelSettingsPanel({
1181
1124
  row.key
1182
1125
  );
1183
1126
  }) }, group.id)),
1184
- capabilities ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1127
+ capabilities ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1185
1128
  InputCapabilitiesEditor,
1186
1129
  {
1187
1130
  values: capabilities.values,