@keboola/design 1.3.1 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (98) hide show
  1. package/dist/icons.cjs +32 -0
  2. package/dist/icons.js +1 -1
  3. package/dist/index.cjs +507 -103
  4. package/dist/index.cjs.map +1 -1
  5. package/dist/index.js +495 -106
  6. package/dist/index.js.map +1 -1
  7. package/dist/markdown-editor.cjs +78 -42
  8. package/dist/markdown-editor.cjs.map +1 -1
  9. package/dist/markdown-editor.js +78 -42
  10. package/dist/markdown-editor.js.map +1 -1
  11. package/dist/mermaid.cjs +32 -9
  12. package/dist/mermaid.cjs.map +1 -1
  13. package/dist/mermaid.js +32 -9
  14. package/dist/mermaid.js.map +1 -1
  15. package/dist/styles.css +1 -1
  16. package/package.json +8 -6
  17. package/src/blocks/AIKit/PlanApproval.tsx +29 -12
  18. package/src/blocks/AIKit/PromptInput.test.tsx +53 -0
  19. package/src/blocks/AIKit/PromptInput.tsx +1 -1
  20. package/src/blocks/AIKit/Question.tsx +39 -11
  21. package/src/blocks/AIKit/SuggestedPrompt.stories.tsx +2 -8
  22. package/src/blocks/EmptyState/EmptyState.stories.tsx +5 -5
  23. package/src/blocks/EmptyState/EmptyState.tsx +2 -2
  24. package/src/blocks/ErrorState/ErrorState.stories.tsx +6 -6
  25. package/src/blocks/ErrorState/ErrorState.tsx +18 -3
  26. package/src/blocks/InputOtp/InputOtp.stories.tsx +214 -0
  27. package/src/blocks/InputOtp/InputOtp.test.tsx +162 -0
  28. package/src/blocks/InputOtp/InputOtp.tsx +62 -0
  29. package/src/blocks/InputOtp/InputOtpGroup.tsx +13 -0
  30. package/src/blocks/InputOtp/InputOtpSeparator.tsx +23 -0
  31. package/src/blocks/InputOtp/InputOtpSlot.styles.ts +52 -0
  32. package/src/blocks/InputOtp/InputOtpSlot.tsx +44 -0
  33. package/src/blocks/InputOtp/context.ts +23 -0
  34. package/src/blocks/InputOtp/index.ts +23 -0
  35. package/src/blocks/PageHeader/AGENTS.md +1 -1
  36. package/src/blocks/PageHeader/PageHeader.stories.tsx +6 -3
  37. package/src/blocks/PageHeader/PageHeaderIndex.tsx +2 -2
  38. package/src/blocks/PageLayout/AGENTS.md +3 -3
  39. package/src/blocks/PageLayout/PageLayout.stories.tsx +7 -4
  40. package/src/blocks/PageLayout/PageLayout.tsx +1 -18
  41. package/src/blocks/PageToolbar/PageToolbar.stories.tsx +79 -74
  42. package/src/blocks/PageToolbar/PageToolbar.tsx +45 -4
  43. package/src/blocks/PageToolbar/PageToolbarToken.tsx +61 -0
  44. package/src/blocks/SearchInput/SearchInput.tsx +2 -2
  45. package/src/components/Alert/AlertDescription.tsx +5 -0
  46. package/src/components/Alert/AlertIcon.tsx +1 -1
  47. package/src/components/Badge/Badge.stories.tsx +3 -5
  48. package/src/components/Badge/BadgeAddon.tsx +1 -1
  49. package/src/components/Badge/BadgeButton.tsx +1 -1
  50. package/src/components/Breadcrumb/Breadcrumb.stories.tsx +4 -4
  51. package/src/components/Breadcrumb/BreadcrumbLink.tsx +1 -1
  52. package/src/components/Breadcrumb/BreadcrumbSeparator.tsx +1 -1
  53. package/src/components/Button/ButtonInline.stories.tsx +3 -3
  54. package/src/components/Button/ButtonInline.tsx +4 -0
  55. package/src/components/Button/styles.ts +33 -10
  56. package/src/components/Card/Card.stories.tsx +2 -2
  57. package/src/components/Combobox/ComboboxItemIndicator.tsx +1 -1
  58. package/src/components/Command/CommandItem/CommandItem.tsx +1 -1
  59. package/src/components/DropdownMenu/DropdownMenuItemIndicator.tsx +4 -4
  60. package/src/components/DropdownMenu/ItemIcon.tsx +1 -1
  61. package/src/components/FormGroup/FormGroup.stories.tsx +2 -2
  62. package/src/components/HoverCard/HoverCardContent.tsx +5 -0
  63. package/src/components/Input/Input.stories.tsx +2 -2
  64. package/src/components/InputGroup/InputGroup.stories.tsx +4 -5
  65. package/src/components/InputGroup/InputGroup.tsx +1 -1
  66. package/src/components/InputGroup/InputGroupAddon.tsx +35 -24
  67. package/src/components/Kbd/Kbd.stories.tsx +2 -2
  68. package/src/components/Label/Label.stories.tsx +2 -2
  69. package/src/components/Modal/ModalBody.tsx +5 -0
  70. package/src/components/Modal/ModalIcon.tsx +1 -1
  71. package/src/components/Navbar/Navbar.stories.tsx +4 -5
  72. package/src/components/Navbar/NavbarMenuItemAdornment.tsx +2 -2
  73. package/src/components/Pagination/Pagination.stories.tsx +0 -1
  74. package/src/components/Pagination/PaginationEllipsis.tsx +1 -1
  75. package/src/components/Popover/PopoverContent.tsx +4 -0
  76. package/src/components/Select/SelectContent.tsx +1 -1
  77. package/src/components/Select/SelectTrigger.tsx +1 -1
  78. package/src/components/Separator/Separator.stories.tsx +19 -0
  79. package/src/components/Separator/Separator.test.tsx +39 -0
  80. package/src/components/Separator/Separator.tsx +42 -11
  81. package/src/components/Sidebar/Sidebar.stories.tsx +6 -5
  82. package/src/components/Sidebar/SidebarGroup/SidebarGroupAction.tsx +1 -1
  83. package/src/components/Sidebar/SidebarMenu/SidebarMenuAction.tsx +1 -1
  84. package/src/components/Sidebar/SidebarMenu/SidebarMenuIcon.tsx +1 -1
  85. package/src/components/Table/Table.stories.tsx +16 -16
  86. package/src/components/Timeline/Timeline.stories.tsx +8 -8
  87. package/src/components/Timeline/TimelineConnector.tsx +5 -1
  88. package/src/components/Toast/ToastDismiss.tsx +1 -1
  89. package/src/components/Toast/ToastRoot.tsx +1 -1
  90. package/src/components/Toggle/Toggle.tsx +1 -1
  91. package/src/components/ToggleGroup/ToggleGroup.stories.tsx +60 -0
  92. package/src/components/ToggleGroup/ToggleGroup.tsx +99 -0
  93. package/src/components/ToggleGroup/index.ts +1 -0
  94. package/src/components/Tooltip/Tooltip.stories.tsx +2 -2
  95. package/src/hooks/useAutosizeInput.stories.tsx +2 -2
  96. package/src/icons/index.ts +8 -0
  97. package/src/index.ts +2 -0
  98. package/src/patterns/FilterToolbar.stories.tsx +248 -44
package/dist/index.cjs CHANGED
@@ -35,6 +35,7 @@ var RadixAvatar = require('@radix-ui/react-avatar');
35
35
  var BoringAvatar = require('boring-avatars');
36
36
  var fontawesomeSvgCore = require('@fortawesome/fontawesome-svg-core');
37
37
  var reactToggle = require('@radix-ui/react-toggle');
38
+ var ToggleGroupPrimitive = require('@radix-ui/react-toggle-group');
38
39
  var reactProgress = require('@radix-ui/react-progress');
39
40
  var diff = require('diff');
40
41
  var RadixTabs = require('@radix-ui/react-tabs');
@@ -59,6 +60,7 @@ var state = require('@codemirror/state');
59
60
  var nodeDiff3 = require('node-diff3');
60
61
  var ResizablePrimitive = require('react-resizable-panels');
61
62
  var sonner = require('sonner');
63
+ var inputOtp = require('input-otp');
62
64
  var reactForm = require('@tanstack/react-form');
63
65
 
64
66
  function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
@@ -91,6 +93,7 @@ var DropdownMenuPrimitive3__namespace = /*#__PURE__*/_interopNamespace(DropdownM
91
93
  var DialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(DialogPrimitive);
92
94
  var RadixAvatar__namespace = /*#__PURE__*/_interopNamespace(RadixAvatar);
93
95
  var BoringAvatar__default = /*#__PURE__*/_interopDefault(BoringAvatar);
96
+ var ToggleGroupPrimitive__namespace = /*#__PURE__*/_interopNamespace(ToggleGroupPrimitive);
94
97
  var RadixTabs__namespace = /*#__PURE__*/_interopNamespace(RadixTabs);
95
98
  var CodeMirror__default = /*#__PURE__*/_interopDefault(CodeMirror);
96
99
  var colors__default = /*#__PURE__*/_interopDefault(colors);
@@ -509,15 +512,38 @@ var variants = classVarianceAuthority.cva(
509
512
  ]
510
513
  },
511
514
  size: {
512
- medium: ["tw-max-h-10", "tw-min-h-10", "tw-px-4", "tw-py-2.5", "[&_svg]:tw-size-4"],
513
- small: ["tw-max-h-8", "tw-min-h-8", "tw-px-4", "tw-py-1.5", "[&_svg]:tw-size-4"],
514
- large: ["tw-max-h-12", "tw-min-h-12", "tw-px-4", "tw-py-3.5", "[&_svg]:tw-size-4"],
515
- "icon-lg": ["tw-size-12", "tw-p-0", "[&_svg]:tw-size-6"],
516
- icon: ["tw-size-10", "tw-p-0", "[&_svg]:tw-size-4"],
517
- "icon-sm": ["tw-size-8", "tw-p-0", "[&_svg]:tw-size-4"],
518
- "icon-xs": ["tw-size-6", "tw-p-0", "[&_svg]:tw-size-4"],
519
- "icon-2xs": ["!tw-inline-flex", "tw-size-5", "tw-max-h-5", "[&_svg]:tw-size-3"],
520
- "icon-3xs": ["tw-h-fit", "tw-w-fit", "[&_svg]:tw-size-4"]
515
+ medium: [
516
+ "tw-max-h-10",
517
+ "tw-min-h-10",
518
+ "tw-px-4",
519
+ "tw-py-2.5",
520
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4'
521
+ ],
522
+ small: [
523
+ "tw-max-h-8",
524
+ "tw-min-h-8",
525
+ "tw-px-4",
526
+ "tw-py-1.5",
527
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4'
528
+ ],
529
+ large: [
530
+ "tw-max-h-12",
531
+ "tw-min-h-12",
532
+ "tw-px-4",
533
+ "tw-py-3.5",
534
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4'
535
+ ],
536
+ "icon-lg": ["tw-size-12", "tw-p-0", '[&_svg:not([class*="tw-size-"])]:tw-size-6'],
537
+ icon: ["tw-size-10", "tw-p-0", '[&_svg:not([class*="tw-size-"])]:tw-size-4'],
538
+ "icon-sm": ["tw-size-8", "tw-p-0", '[&_svg:not([class*="tw-size-"])]:tw-size-4'],
539
+ "icon-xs": ["tw-size-6", "tw-p-0", '[&_svg:not([class*="tw-size-"])]:tw-size-4'],
540
+ "icon-2xs": [
541
+ "!tw-inline-flex",
542
+ "tw-size-5",
543
+ "tw-max-h-5",
544
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3'
545
+ ],
546
+ "icon-3xs": ["tw-h-fit", "tw-w-fit", '[&_svg:not([class*="tw-size-"])]:tw-size-4']
521
547
  }
522
548
  }
523
549
  }
@@ -699,7 +725,10 @@ var buttonInlineVariants = classVarianceAuthority.cva(
699
725
  "disabled:tw-cursor-not-allowed",
700
726
  "disabled:tw-text-neutral-500",
701
727
  "disabled:tw-no-underline",
702
- "[&_svg]:disabled:tw-text-neutral-400"
728
+ "[&_svg]:disabled:tw-text-neutral-400",
729
+ // Default size for nested Lucide icons; callers can override on the icon.
730
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4",
731
+ "[&_svg]:tw-shrink-0"
703
732
  ],
704
733
  {
705
734
  defaultVariants: {
@@ -880,7 +909,10 @@ var variants2 = classVarianceAuthority.cva(
880
909
  "data-[side=bottom]:tw-slide-in-from-top-2",
881
910
  "data-[side=left]:tw-slide-in-from-right-2",
882
911
  "data-[side=right]:tw-slide-in-from-left-2",
883
- "data-[side=top]:tw-slide-in-from-bottom-2"
912
+ "data-[side=top]:tw-slide-in-from-bottom-2",
913
+ // Default size for nested Lucide icons; callers can override on the icon.
914
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4",
915
+ "[&_svg]:tw-shrink-0"
884
916
  ],
885
917
  {
886
918
  defaultVariants: {
@@ -1134,32 +1166,42 @@ var TimePicker = ({
1134
1166
  )
1135
1167
  ] });
1136
1168
  };
1137
- var addonVariants = classVarianceAuthority.cva(["tw-flex", "tw-items-center", "tw-gap-1"], {
1138
- defaultVariants: {
1139
- align: "inline-start"
1140
- },
1141
- variants: {
1142
- align: {
1143
- "inline-start": ["tw-order-first", "[&:not(:empty)]:tw-pl-4"],
1144
- "inline-end": ["tw-order-last", "[&:not(:empty)]:tw-pr-4"],
1145
- "block-start": [
1146
- "tw-order-first",
1147
- // `tw-w-full` needs to be empty-conditional too — when the addon
1148
- // has no content the root stays in flex-row, and a 100%-wide
1149
- // empty addon would claim half of the input row beside the input.
1150
- "[&:not(:empty)]:tw-w-full",
1151
- "[&:not(:empty)]:tw-px-4",
1152
- "[&:not(:empty)]:tw-py-1.5"
1153
- ],
1154
- "block-end": [
1155
- "tw-order-last",
1156
- "[&:not(:empty)]:tw-w-full",
1157
- "[&:not(:empty)]:tw-px-4",
1158
- "[&:not(:empty)]:tw-py-1.5"
1159
- ]
1169
+ var addonVariants = classVarianceAuthority.cva(
1170
+ [
1171
+ "tw-flex",
1172
+ "tw-items-center",
1173
+ "tw-gap-1",
1174
+ // Default size for nested Lucide icons in prefix/suffix slots; callers can override on the icon.
1175
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4",
1176
+ "[&_svg]:tw-shrink-0"
1177
+ ],
1178
+ {
1179
+ defaultVariants: {
1180
+ align: "inline-start"
1181
+ },
1182
+ variants: {
1183
+ align: {
1184
+ "inline-start": ["tw-order-first", "[&:not(:empty)]:tw-pl-4"],
1185
+ "inline-end": ["tw-order-last", "[&:not(:empty)]:tw-pr-4"],
1186
+ "block-start": [
1187
+ "tw-order-first",
1188
+ // `tw-w-full` needs to be empty-conditional too — when the addon
1189
+ // has no content the root stays in flex-row, and a 100%-wide
1190
+ // empty addon would claim half of the input row beside the input.
1191
+ "[&:not(:empty)]:tw-w-full",
1192
+ "[&:not(:empty)]:tw-px-4",
1193
+ "[&:not(:empty)]:tw-py-1.5"
1194
+ ],
1195
+ "block-end": [
1196
+ "tw-order-last",
1197
+ "[&:not(:empty)]:tw-w-full",
1198
+ "[&:not(:empty)]:tw-px-4",
1199
+ "[&:not(:empty)]:tw-py-1.5"
1200
+ ]
1201
+ }
1160
1202
  }
1161
1203
  }
1162
- });
1204
+ );
1163
1205
  var InputGroupAddon = ({
1164
1206
  children,
1165
1207
  align = "inline-start",
@@ -1318,7 +1360,7 @@ var inputGroupVariants = classVarianceAuthority.cva(
1318
1360
  defaultVariants: {
1319
1361
  variant: "primary",
1320
1362
  state: "default",
1321
- sizing: "default",
1363
+ sizing: "medium",
1322
1364
  focusVariant: "default"
1323
1365
  },
1324
1366
  compoundVariants: [
@@ -2429,6 +2471,9 @@ var HoverCardContent = ({
2429
2471
  "data-[state=closed]:tw-animate-out",
2430
2472
  "data-[state=closed]:tw-fade-out-0",
2431
2473
  "data-[state=closed]:tw-zoom-out-95",
2474
+ // Default size for nested Lucide icons; callers can override on the icon.
2475
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4",
2476
+ "[&_svg]:tw-shrink-0",
2432
2477
  className
2433
2478
  ),
2434
2479
  ...props,
@@ -2447,7 +2492,7 @@ var separatorVariants = classVarianceAuthority.cva(
2447
2492
  "tw-self-stretch",
2448
2493
  // before
2449
2494
  "before:tw-content-['']",
2450
- "before:tw-bg-neutral-150"
2495
+ "before:tw-bg-border"
2451
2496
  ],
2452
2497
  {
2453
2498
  defaultVariants: {
@@ -2503,16 +2548,37 @@ var Separator = ({
2503
2548
  className,
2504
2549
  orientation = "vertical",
2505
2550
  size = "full",
2551
+ label,
2506
2552
  ...props
2507
- }) => /* @__PURE__ */ jsxRuntime.jsx(
2508
- RSeparator__namespace.Root,
2509
- {
2510
- ...props,
2511
- decorative: true,
2512
- orientation,
2513
- className: separatorVariants({ size, orientation, className })
2553
+ }) => {
2554
+ if (label != null && label !== false) {
2555
+ return /* @__PURE__ */ jsxRuntime.jsx(
2556
+ RSeparator__namespace.Root,
2557
+ {
2558
+ ...props,
2559
+ decorative: true,
2560
+ orientation: "horizontal",
2561
+ className: cn(
2562
+ "tw-flex tw-w-full tw-items-center tw-gap-3 tw-self-stretch",
2563
+ "tw-text-xs tw-font-medium tw-text-muted-foreground",
2564
+ "before:tw-content-[''] before:tw-h-px before:tw-flex-1 before:tw-bg-border",
2565
+ "after:tw-content-[''] after:tw-h-px after:tw-flex-1 after:tw-bg-border",
2566
+ className
2567
+ ),
2568
+ children: label
2569
+ }
2570
+ );
2514
2571
  }
2515
- );
2572
+ return /* @__PURE__ */ jsxRuntime.jsx(
2573
+ RSeparator__namespace.Root,
2574
+ {
2575
+ ...props,
2576
+ decorative: true,
2577
+ orientation,
2578
+ className: separatorVariants({ size, orientation, className })
2579
+ }
2580
+ );
2581
+ };
2516
2582
  var RadioGroupContext = react.createContext({
2517
2583
  variant: "radio",
2518
2584
  orientation: "horizontal"
@@ -3120,7 +3186,7 @@ var scrollButtonStyles = cn(
3120
3186
  "tw-justify-center",
3121
3187
  "tw-rounded-sm",
3122
3188
  "tw-p-1",
3123
- "[&_svg]:tw-size-5"
3189
+ '[&_svg:not([class*="tw-size-"])]:tw-size-5'
3124
3190
  );
3125
3191
  var SelectContent = ({
3126
3192
  ref,
@@ -3316,7 +3382,7 @@ var variants3 = classVarianceAuthority.cva(
3316
3382
  defaultVariants: {
3317
3383
  variant: "primary",
3318
3384
  state: "default",
3319
- sizing: "default"
3385
+ sizing: "medium"
3320
3386
  },
3321
3387
  compoundVariants: [
3322
3388
  {
@@ -3616,7 +3682,7 @@ var variants4 = classVarianceAuthority.cva(
3616
3682
  "tw-border-border",
3617
3683
  "tw-rounded-full",
3618
3684
  "tw-bg-white",
3619
- "[&_svg]:tw-size-2",
3685
+ '[&_svg:not([class*="tw-size-"])]:tw-size-2',
3620
3686
  "[&_svg]:data-[state=unchecked]:tw-hidden",
3621
3687
  // Lucide Circle is stroke-only — force fill to match the stroke
3622
3688
  // (currentColor) so the indicator reads as a solid dot.
@@ -3624,14 +3690,14 @@ var variants4 = classVarianceAuthority.cva(
3624
3690
  "group-data-[variant=argo]/dropdown-menu-content:[&_svg]:tw-text-primary",
3625
3691
  "group-data-[variant=default]/dropdown-menu-content:[&_svg]:tw-text-secondary-500"
3626
3692
  ],
3627
- check: ["[&_svg]:tw-size-3.5", "[&_svg]:tw-text-primary"],
3693
+ check: ['[&_svg:not([class*="tw-size-"])]:tw-size-3.5', "[&_svg]:tw-text-primary"],
3628
3694
  checkbox: [
3629
3695
  "[&_svg]:tw-text-white",
3630
3696
  "tw-border",
3631
3697
  "tw-border-solid",
3632
3698
  "tw-border-neutral-200",
3633
3699
  "tw-rounded",
3634
- "[&_svg]:tw-size-3",
3700
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3',
3635
3701
  "[&_svg]:data-[state=unchecked]:tw-hidden",
3636
3702
  "group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:tw-border-primary",
3637
3703
  "group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:tw-bg-primary",
@@ -3642,7 +3708,7 @@ var variants4 = classVarianceAuthority.cva(
3642
3708
  "tw-size-5",
3643
3709
  // Lucide SVGs default to 24×24 — constrain the rendered ToggleRight
3644
3710
  // to the indicator slot so it doesn't overflow.
3645
- "[&_svg]:tw-size-5",
3711
+ '[&_svg:not([class*="tw-size-"])]:tw-size-5',
3646
3712
  "tw-text-neutral-400",
3647
3713
  "data-[state=unchecked]:tw-rotate-180",
3648
3714
  "group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:tw-text-secondary-500",
@@ -3690,7 +3756,7 @@ var ItemIcon = ({ className, children, ...props }) => /* @__PURE__ */ jsxRuntime
3690
3756
  // 20px container fits the 16px Lucide glyph plus 2px breathing room
3691
3757
  // each side — the previous tw-size-4 + tw-p-0.5 clipped the 16px child.
3692
3758
  "tw-size-5",
3693
- "[&_svg]:tw-size-4",
3759
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
3694
3760
  "group-data-[variant=default]/dropdown-menu-content:tw-text-neutral-400",
3695
3761
  "group-data-[variant=argo]/dropdown-menu-content:tw-text-primary",
3696
3762
  "group-data-[variant=argo]/dropdown-menu-content:group-aria-disabled:tw-text-muted-foreground",
@@ -4071,6 +4137,9 @@ var ModalBody = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(
4071
4137
  "tw-px-1",
4072
4138
  // 4 px to complement ModalContent and still keep input focus outline visible
4073
4139
  "tw-py-1",
4140
+ // Default size for nested Lucide icons; callers can override on the icon.
4141
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4",
4142
+ "[&_svg]:tw-shrink-0",
4074
4143
  className
4075
4144
  ),
4076
4145
  ...props
@@ -4308,7 +4377,7 @@ var ModalIcon = (props) => {
4308
4377
  "tw-text-white": props.color !== "violet",
4309
4378
  "tw-text-purple-500": props.color === "violet"
4310
4379
  },
4311
- "[&_svg]:tw-size-6",
4380
+ '[&_svg:not([class*="tw-size-"])]:tw-size-6',
4312
4381
  "[&_svg]:tw-aspect-square"
4313
4382
  ),
4314
4383
  children: isFAIconValue(props.icon) ? /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: props.icon, spin: props.spin }) : props.icon
@@ -5315,7 +5384,7 @@ var SidebarGroupAction = ({
5315
5384
  "tw-text-neutral-800",
5316
5385
  "tw-rounded-full",
5317
5386
  // svg defaults: size + colour
5318
- "[&_svg]:tw-size-3",
5387
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3',
5319
5388
  "[&_svg]:tw-text-neutral-400",
5320
5389
  "hover:[&_svg]:tw-text-secondary-600",
5321
5390
  "hover:tw-bg-neutral-100",
@@ -5459,7 +5528,7 @@ var SidebarMenuIcon = ({
5459
5528
  "tw-shrink-0",
5460
5529
  "tw-p-0.5",
5461
5530
  "tw-text-sidebar-primary",
5462
- "[&_svg]:tw-size-4",
5531
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
5463
5532
  className
5464
5533
  ),
5465
5534
  children
@@ -5588,7 +5657,7 @@ var SidebarMenuAction = ({
5588
5657
  "tw-rounded",
5589
5658
  // icon styling
5590
5659
  "[&_svg]:tw-shrink-0",
5591
- "[&_svg]:tw-size-3.5",
5660
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3.5',
5592
5661
  "[&_svg]:tw-text-sidebar-accent-foreground",
5593
5662
  // focus visible
5594
5663
  "focus-visible:tw-outline-none",
@@ -6474,7 +6543,7 @@ var CommandItem = ({
6474
6543
  ),
6475
6544
  children: [
6476
6545
  /* @__PURE__ */ jsxRuntime.jsx(CheckIndicator, { variant }),
6477
- icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-inline-flex tw-size-4 tw-shrink-0 tw-items-center tw-justify-center tw-text-neutral-400 [&_svg]:tw-size-4", children: icon }),
6546
+ icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-inline-flex tw-size-4 tw-shrink-0 tw-items-center tw-justify-center tw-text-neutral-400 [&_svg:not([class*='tw-size-'])]:tw-size-4", children: icon }),
6478
6547
  children
6479
6548
  ]
6480
6549
  }
@@ -6548,7 +6617,7 @@ var addonVariants2 = classVarianceAuthority.cva(
6548
6617
  "tw-self-stretch",
6549
6618
  "tw-px-1",
6550
6619
  "has-[button]:tw-px-0",
6551
- "[&_svg]:tw-size-3"
6620
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3'
6552
6621
  ],
6553
6622
  {
6554
6623
  defaultVariants: {
@@ -6619,7 +6688,7 @@ var BadgeButton = ({
6619
6688
  // Default sizing for Lucide-icon children (which ship at 24×24); keeps
6620
6689
  // the visual baseline aligned with the previous FA-icon API and other
6621
6690
  // icon-wrapper components (ItemIcon, SidebarMenuIcon).
6622
- "[&_svg]:tw-size-3",
6691
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3',
6623
6692
  className
6624
6693
  ),
6625
6694
  children
@@ -7022,7 +7091,7 @@ var ComboboxItemIndicator = ({
7022
7091
  "group-data-[variant=default]/combobox-content:tw-right-4",
7023
7092
  // Lucide SVGs default to 24×24 — constrain the rendered child so the
7024
7093
  // 16px indicator slot owns the actual size.
7025
- "[&_svg]:tw-size-4",
7094
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
7026
7095
  "group-data-[highlighted]/combobox-item:tw-text-accent-foreground",
7027
7096
  "group-data-[variant=default]/combobox-content:group-data-[highlighted]/combobox-item:tw-text-foreground",
7028
7097
  className
@@ -7420,7 +7489,7 @@ var BreadcrumbLink = ({
7420
7489
  "focus-visible:tw-ring-secondary-500/50",
7421
7490
  "focus-visible:tw-rounded-sm",
7422
7491
  // Icon
7423
- "[&_svg]:tw-size-2.5",
7492
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3.5',
7424
7493
  // transition
7425
7494
  "tw-transition-colors",
7426
7495
  className
@@ -7476,7 +7545,7 @@ var BreadcrumbSeparator = ({ children, className, ...props }) => /* @__PURE__ */
7476
7545
  "tw-justify-center",
7477
7546
  "tw-aspect-square",
7478
7547
  "tw-size-[15px]",
7479
- "[&_svg]:tw-size-2.5",
7548
+ '[&_svg:not([class*="tw-size-"])]:tw-size-2.5',
7480
7549
  "tw-text-muted-foreground",
7481
7550
  className
7482
7551
  ),
@@ -7580,7 +7649,7 @@ var variants6 = classVarianceAuthority.cva(
7580
7649
  "tw-flex",
7581
7650
  "tw-justify-center",
7582
7651
  "tw-items-center",
7583
- "[&_svg]:tw-size-3",
7652
+ '[&_svg:not([class*="tw-size-"])]:tw-size-3',
7584
7653
  "[&:not(svg)]:tw-h-5",
7585
7654
  "[&:not(svg)]:tw-min-w-5",
7586
7655
  "tw-p-1",
@@ -7612,7 +7681,7 @@ var variants6 = classVarianceAuthority.cva(
7612
7681
  "group-data-[accent=orange]/navbar:tw-bg-warning-500",
7613
7682
  "group-data-[accent=green]/navbar:tw-bg-primary-500"
7614
7683
  ],
7615
- "icon-button": ["tw-size-4", "tw-max-h-9", "tw-leading-9", "tw-p-0"],
7684
+ "icon-button": ["tw-size-4", "!tw-p-0", '[&_svg:not([class*="tw-size-"])]:tw-size-4'],
7616
7685
  shortcut: ["tw-bg-muted", "tw-text-sidebar-foreground", "tw-ml-auto"]
7617
7686
  }
7618
7687
  }
@@ -7830,7 +7899,7 @@ var PaginationEllipsis = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime
7830
7899
  "tw-items-center",
7831
7900
  "tw-justify-center",
7832
7901
  "tw-text-foreground",
7833
- "[&_svg]:tw-size-4",
7902
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
7834
7903
  className
7835
7904
  ),
7836
7905
  ...props,
@@ -8156,12 +8225,83 @@ var Toggle = ({
8156
8225
  disabled,
8157
8226
  children: [
8158
8227
  badge && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-absolute tw-right-0 tw-top-0 -tw-translate-y-1/2 tw-translate-x-1/4", children: badge }),
8159
- icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-inline-flex tw-size-4 tw-shrink-0 tw-items-center tw-justify-center tw-align-middle [&_svg]:tw-size-4", children: renderLegacyIcon(icon) }),
8228
+ icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-inline-flex tw-size-4 tw-shrink-0 tw-items-center tw-justify-center tw-align-middle [&_svg:not([class*='tw-size-'])]:tw-size-4", children: renderLegacyIcon(icon) }),
8160
8229
  isAiVariant ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "tw-bg-gradient-to-br tw-from-secondary-700 tw-to-purple-700 tw-bg-clip-text tw-text-transparent", children }) : children
8161
8230
  ]
8162
8231
  }
8163
8232
  );
8164
8233
  };
8234
+ var rootVariants2 = classVarianceAuthority.cva(
8235
+ [
8236
+ "tailwindcss-preflight",
8237
+ "tw-inline-flex",
8238
+ "tw-items-center",
8239
+ "tw-shrink-0",
8240
+ "tw-bg-muted",
8241
+ "tw-rounded-lg",
8242
+ "tw-p-[3px]",
8243
+ "tw-gap-0"
8244
+ ],
8245
+ {
8246
+ defaultVariants: { size: "medium" },
8247
+ variants: {
8248
+ size: {
8249
+ small: ["tw-h-8"],
8250
+ medium: ["tw-h-9"],
8251
+ large: ["tw-h-10"]
8252
+ }
8253
+ }
8254
+ }
8255
+ );
8256
+ var itemClasses = cn(
8257
+ "tailwindcss-preflight",
8258
+ "tw-inline-flex",
8259
+ "tw-items-center",
8260
+ "tw-justify-center",
8261
+ "tw-gap-2",
8262
+ "tw-shrink-0",
8263
+ "tw-whitespace-nowrap",
8264
+ "tw-h-full",
8265
+ "tw-rounded-md",
8266
+ "tw-px-2",
8267
+ "tw-py-1",
8268
+ "tw-bg-transparent",
8269
+ "tw-text-foreground",
8270
+ "tw-text-sm",
8271
+ "tw-font-medium",
8272
+ "tw-transition-colors",
8273
+ "disabled:tw-cursor-not-allowed",
8274
+ "disabled:tw-opacity-50",
8275
+ "!tw-outline-none",
8276
+ "focus-visible:tw-ring-2",
8277
+ "focus-visible:tw-ring-primary/50",
8278
+ // hover on non-pressed
8279
+ "not-disabled:[&[data-state=off]]:hover:tw-bg-background/60",
8280
+ // pressed
8281
+ "data-[state=on]:tw-bg-background",
8282
+ "data-[state=on]:tw-shadow-[0_1px_2px_rgba(0,0,0,0.05),0_1px_1px_rgba(0,0,0,0.1)]",
8283
+ "[&_svg]:tw-shrink-0",
8284
+ "[&_svg]:tw-pointer-events-none",
8285
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4"
8286
+ );
8287
+ var Root25 = ({
8288
+ ref,
8289
+ className,
8290
+ size = "medium",
8291
+ ...props
8292
+ }) => /* @__PURE__ */ jsxRuntime.jsx(
8293
+ ToggleGroupPrimitive__namespace.Root,
8294
+ {
8295
+ ref,
8296
+ ...props,
8297
+ className: cn(rootVariants2({ size, className }))
8298
+ }
8299
+ );
8300
+ var Item6 = ({ ref, className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(ToggleGroupPrimitive__namespace.Item, { ref, ...props, className: cn(itemClasses, className) });
8301
+ var ToggleGroup = Object.assign(Root25, {
8302
+ /** Individual segment inside a `ToggleGroup`. `value` is required and must be unique within the group. */
8303
+ Item: Item6
8304
+ });
8165
8305
  var CONNECTOR_MARGIN_TOP = 8;
8166
8306
  var useLastLineHeight = () => {
8167
8307
  const [wrapper, setWrapper] = useElement();
@@ -8250,7 +8390,11 @@ var connector = classVarianceAuthority.cva(
8250
8390
  "tw-text-nowrap",
8251
8391
  "tw-text-xs"
8252
8392
  ],
8253
- icon: ["tw-bg-white", "[&_svg]:tw-text-neutral-300"],
8393
+ icon: [
8394
+ "tw-bg-white",
8395
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
8396
+ "[&_svg]:tw-text-neutral-300"
8397
+ ],
8254
8398
  line: [
8255
8399
  "tw-min-w-8",
8256
8400
  "tw-overflow-hidden",
@@ -9486,6 +9630,9 @@ var AlertDescription = ({
9486
9630
  "group-has-[[data-slot=alert-title]]/alert:before:tw-h-4",
9487
9631
  "group-has-[[data-slot=alert-title]]/alert:before:tw-content-['']",
9488
9632
  "tw-break-anywhere",
9633
+ // Default size for nested Lucide icons; callers can override on the icon.
9634
+ "[&_svg:not([class*='tw-size-'])]:tw-size-4",
9635
+ "[&_svg]:tw-shrink-0",
9489
9636
  className
9490
9637
  ),
9491
9638
  children
@@ -9508,7 +9655,7 @@ var AlertIcon = ({ variant, icon, className, ...rest }) => /* @__PURE__ */ jsxRu
9508
9655
  "tw-justify-center",
9509
9656
  "tw-self-start",
9510
9657
  "tw-p-0.5",
9511
- "[&_svg]:tw-size-4",
9658
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
9512
9659
  "group-data-[variant=info]/alert:tw-text-secondary-500",
9513
9660
  "group-data-[variant=warning]/alert:tw-text-warning-500",
9514
9661
  "group-data-[variant=error]/alert:tw-text-error-500",
@@ -11572,7 +11719,7 @@ var Skeleton = ({ height = "md", className, count = 1 }) => {
11572
11719
  var duplicateArray = (arr, times) => {
11573
11720
  return Array(times).fill(arr).flat();
11574
11721
  };
11575
- var Item5 = ({
11722
+ var Item7 = ({
11576
11723
  className,
11577
11724
  iconHeight = "md",
11578
11725
  rowHeight = "sm",
@@ -11599,7 +11746,7 @@ var SkeletonList = ({
11599
11746
  ),
11600
11747
  children: duplicateArray(["tw-w-5/6", "tw-w-3/4", "tw-w-4/5", "tw-w-2/3"], groups).map(
11601
11748
  (className2, index) => /* @__PURE__ */ jsxRuntime.jsx(
11602
- Item5,
11749
+ Item7,
11603
11750
  {
11604
11751
  iconHeight,
11605
11752
  rowHeight,
@@ -11867,7 +12014,7 @@ var ToastDismiss = ({
11867
12014
  "tw-row-start-1",
11868
12015
  "tailwindcss-preflight",
11869
12016
  "[&_svg]:tw-aspect-square",
11870
- "[&_svg]:tw-size-4",
12017
+ '[&_svg:not([class*="tw-size-"])]:tw-size-4',
11871
12018
  "[&_svg]:tw-m-1",
11872
12019
  "tw-text-white",
11873
12020
  "group-data-[variant=default]/toast:[&_svg]:tw-text-popover-foreground",
@@ -12018,7 +12165,7 @@ var ToastRoot = ({
12018
12165
  "tw-aspect-square",
12019
12166
  "tw-size-5",
12020
12167
  "tw-shrink-0",
12021
- "[&_svg]:tw-size-5",
12168
+ '[&_svg:not([class*="tw-size-"])]:tw-size-5',
12022
12169
  "tw-text-white",
12023
12170
  "group-data-[variant=default]/toast:tw-text-popover-foreground"
12024
12171
  ),
@@ -12148,8 +12295,8 @@ var emptyStateIconClassnames = classVarianceAuthority.cva(
12148
12295
  {
12149
12296
  variants: {
12150
12297
  variant: {
12151
- default: ["tw-size-16", "tw-text-4xl"],
12152
- compact: ["tw-size-10", "tw-text-2xl"]
12298
+ default: ["tw-size-16", "tw-text-4xl", '[&_svg:not([class*="tw-size-"])]:tw-size-10'],
12299
+ compact: ["tw-size-10", "tw-text-2xl", '[&_svg:not([class*="tw-size-"])]:tw-size-6']
12153
12300
  }
12154
12301
  },
12155
12302
  defaultVariants: {
@@ -12220,9 +12367,24 @@ var errorStateClassnames = classVarianceAuthority.cva(["tw-flex", "tw-flex-col",
12220
12367
  var errorStateIconClassnames = classVarianceAuthority.cva(["tw-flex", "tw-items-center", "tw-justify-center"], {
12221
12368
  variants: {
12222
12369
  variant: {
12223
- default: ["tw-size-16", "tw-text-4xl", "tw-text-warning-500"],
12224
- compact: ["tw-size-10", "tw-text-2xl", "tw-text-warning-500"],
12225
- destructive: ["tw-size-16", "tw-text-4xl", "tw-text-error-500"]
12370
+ default: [
12371
+ "tw-size-16",
12372
+ "tw-text-4xl",
12373
+ '[&_svg:not([class*="tw-size-"])]:tw-size-10',
12374
+ "tw-text-warning-500"
12375
+ ],
12376
+ compact: [
12377
+ "tw-size-10",
12378
+ "tw-text-2xl",
12379
+ '[&_svg:not([class*="tw-size-"])]:tw-size-6',
12380
+ "tw-text-warning-500"
12381
+ ],
12382
+ destructive: [
12383
+ "tw-size-16",
12384
+ "tw-text-4xl",
12385
+ '[&_svg:not([class*="tw-size-"])]:tw-size-10',
12386
+ "tw-text-error-500"
12387
+ ]
12226
12388
  }
12227
12389
  },
12228
12390
  defaultVariants: {
@@ -12286,7 +12448,7 @@ var maxWidthClass = {
12286
12448
  wide: "tw-max-w-[1600px]",
12287
12449
  full: "tw-max-w-full"
12288
12450
  };
12289
- var Root27 = ({
12451
+ var Root29 = ({
12290
12452
  ref,
12291
12453
  className,
12292
12454
  maxWidth = "full",
@@ -12331,20 +12493,6 @@ var Tabs2 = ({
12331
12493
  children
12332
12494
  }
12333
12495
  );
12334
- var Toolbar = ({
12335
- ref,
12336
- className,
12337
- children,
12338
- ...props
12339
- }) => /* @__PURE__ */ jsxRuntime.jsx(
12340
- "div",
12341
- {
12342
- ref,
12343
- className: cn("tw-flex tw-w-full tw-flex-wrap tw-items-center tw-gap-3", className),
12344
- ...props,
12345
- children
12346
- }
12347
- );
12348
12496
  var Content11 = ({
12349
12497
  ref,
12350
12498
  className,
@@ -12370,15 +12518,13 @@ var Footer = ({
12370
12518
  children
12371
12519
  }
12372
12520
  );
12373
- var PageLayout = Object.assign(Root27, {
12521
+ var PageLayout = Object.assign(Root29, {
12374
12522
  /** Detail-pattern breadcrumb row. Usually composed automatically by `PageHeader.Detail` — slot exists for layouts that don't fit either `PageHeader` variant. */
12375
12523
  Breadcrumbs,
12376
12524
  /** Host slot for `PageHeader.Index` / `PageHeader.Detail`, or custom header JSX when neither variant fits. */
12377
12525
  Header,
12378
12526
  /** Escape hatch for routing-based tab rows. Use `Tabs` / `TabsContent` core components inside, never a raw `<button>`. */
12379
12527
  Tabs: Tabs2,
12380
- /** Search / filter pill row. Belongs here, NOT in the header per the page-header patterns. */
12381
- Toolbar,
12382
12528
  /** Main content slot. Lists, cards, tables. */
12383
12529
  Content: Content11,
12384
12530
  /** Bottom action bar — form submit + cancel. Pass `sticky` for a footer that pins to the viewport. */
@@ -12464,7 +12610,47 @@ var PageHeader = {
12464
12610
  /** Detail variant — single-entity pages with required breadcrumbs and an overflow-actions slot. Max 2 visible actions. */
12465
12611
  Detail: PageHeaderDetail
12466
12612
  };
12467
- var Root28 = ({ ref, className, children, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(
12613
+ var PageToolbarToken = ({
12614
+ children,
12615
+ popover,
12616
+ onRemove,
12617
+ removeAriaLabel,
12618
+ ...props
12619
+ }) => /* @__PURE__ */ jsxRuntime.jsxs(Popover, { children: [
12620
+ /* @__PURE__ */ jsxRuntime.jsx(
12621
+ Badge,
12622
+ {
12623
+ ...props,
12624
+ asChild: true,
12625
+ variant: "pill",
12626
+ color: "blue-inverse",
12627
+ suffix: /* @__PURE__ */ jsxRuntime.jsx(
12628
+ Button,
12629
+ {
12630
+ type: "button",
12631
+ variant: "inline",
12632
+ size: "icon-2xs",
12633
+ "aria-label": removeAriaLabel,
12634
+ onClick: onRemove,
12635
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "tw-size-3" })
12636
+ }
12637
+ ),
12638
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
12639
+ Popover.Trigger,
12640
+ {
12641
+ type: "button",
12642
+ className: "tailwindcss-preflight tw-inline-flex tw-cursor-pointer tw-items-center tw-gap-1 tw-bg-inherit tw-text-inherit",
12643
+ children: [
12644
+ children,
12645
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDown, { className: "tw-size-3" })
12646
+ ]
12647
+ }
12648
+ )
12649
+ }
12650
+ ),
12651
+ /* @__PURE__ */ jsxRuntime.jsx(Popover.Content, { variant: "argo", align: "start", children: popover })
12652
+ ] });
12653
+ var Root30 = ({ ref, className, children, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(
12468
12654
  "div",
12469
12655
  {
12470
12656
  ref,
@@ -12504,12 +12690,32 @@ var ActiveFilters = ({ ref, className, children, ...props }) => /* @__PURE__ */
12504
12690
  children
12505
12691
  }
12506
12692
  );
12693
+ var Chip = ({ children, onRemove, removeAriaLabel, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(
12694
+ Badge,
12695
+ {
12696
+ ...props,
12697
+ variant: "pill",
12698
+ color: "blue-inverse",
12699
+ suffix: /* @__PURE__ */ jsxRuntime.jsx(
12700
+ Button,
12701
+ {
12702
+ type: "button",
12703
+ variant: "inline",
12704
+ size: "icon-2xs",
12705
+ "aria-label": removeAriaLabel,
12706
+ onClick: onRemove,
12707
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "tw-size-3" })
12708
+ }
12709
+ ),
12710
+ children
12711
+ }
12712
+ );
12507
12713
  var AddFilter = ({ className, children, ...props }) => /* @__PURE__ */ jsxRuntime.jsxs(Button, { argo: true, variant: "invisible", size: "small", className: cn("tw-gap-1.5", className), ...props, children: [
12508
- /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: "plus" }),
12714
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "tw-size-4" }),
12509
12715
  children ?? "Add filter"
12510
12716
  ] });
12511
12717
  var Clear = ({ className, children, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(Button, { argo: true, variant: "invisible", size: "small", className: cn("tw-ml-auto", className), ...props, children: children ?? "Clear all" });
12512
- var PageToolbar = Object.assign(Root28, {
12718
+ var PageToolbar = Object.assign(Root30, {
12513
12719
  /** Left slot — typically a `SearchInput`. */
12514
12720
  Search: Search4,
12515
12721
  /** Right cluster — host the four control groups below in the recommended order. */
@@ -12528,6 +12734,14 @@ var PageToolbar = Object.assign(Root28, {
12528
12734
  * by `AddFilter` / `Clear`.
12529
12735
  */
12530
12736
  ActiveFilters,
12737
+ /** Non-editable filter chip (Standard variant) — `Badge` pill with a dismiss button. */
12738
+ Chip,
12739
+ /**
12740
+ * Editable filter token (Query Builder variant) — `Badge` pill with a `chevron-down`
12741
+ * popover trigger for editing values and an `×` dismiss button. The popover content
12742
+ * is supplied by the caller via the `popover` slot (typically a `Combobox` or option list).
12743
+ */
12744
+ Token: PageToolbarToken,
12531
12745
  /** "+ Add filter" action — typically rendered after the chips/tokens in `ActiveFilters`. */
12532
12746
  AddFilter,
12533
12747
  /** "Clear all" action — self-aligns to the far right of `ActiveFilters`. */
@@ -13135,6 +13349,7 @@ var PlanApproval = ({
13135
13349
  onRequestChanges,
13136
13350
  onClose,
13137
13351
  isSubmitting = false,
13352
+ approveTooltip,
13138
13353
  pendingPillLabel = "Ready for approval",
13139
13354
  approvedPillLabel = "Approved",
13140
13355
  dismissedPillLabel = "Dismissed",
@@ -13321,7 +13536,7 @@ var PlanApproval = ({
13321
13536
  children: requestChangesLabel
13322
13537
  }
13323
13538
  ),
13324
- onApprove && /* @__PURE__ */ jsxRuntime.jsx(
13539
+ onApprove && (approveTooltip ? /* @__PURE__ */ jsxRuntime.jsx(Tooltip, { tooltip: approveTooltip, placement: "top", triggerAsChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
13325
13540
  Button,
13326
13541
  {
13327
13542
  argo: true,
@@ -13332,7 +13547,18 @@ var PlanApproval = ({
13332
13547
  "data-testid": "plan-approve-button",
13333
13548
  children: approveLabel
13334
13549
  }
13335
- )
13550
+ ) }) : /* @__PURE__ */ jsxRuntime.jsx(
13551
+ Button,
13552
+ {
13553
+ argo: true,
13554
+ variant: "primary",
13555
+ size: "small",
13556
+ onClick: onApprove,
13557
+ disabled: isSubmitting || isRequestingChanges,
13558
+ "data-testid": "plan-approve-button",
13559
+ children: approveLabel
13560
+ }
13561
+ ))
13336
13562
  ] })
13337
13563
  ]
13338
13564
  }
@@ -13483,7 +13709,7 @@ var PromptInput = ({
13483
13709
  const handleOnKeyDown = (event) => {
13484
13710
  if (event.key === "Enter" && !event.shiftKey && !event.ctrlKey && !event.metaKey) {
13485
13711
  event.preventDefault();
13486
- handleSubmit();
13712
+ if (status !== "streaming") handleSubmit();
13487
13713
  }
13488
13714
  };
13489
13715
  const handleOnMouseDown = (event) => {
@@ -13567,12 +13793,14 @@ var Question = ({
13567
13793
  onSelectionChange,
13568
13794
  customAnswer = "",
13569
13795
  onCustomAnswerChange,
13796
+ onCustomAnswerConfirm,
13570
13797
  showCustomAnswer = true,
13571
13798
  customAnswerPlaceholder = "Type your answer\u2026",
13572
13799
  showSkip = true,
13573
13800
  onSkip,
13574
13801
  onClose,
13575
13802
  onNext,
13803
+ submitTooltip,
13576
13804
  onPrevious,
13577
13805
  currentStep,
13578
13806
  totalSteps,
@@ -13727,6 +13955,12 @@ var Question = ({
13727
13955
  value: customAnswer,
13728
13956
  onValueChange: (value) => onCustomAnswerChange?.(value),
13729
13957
  onFocus: handleCustomFocus,
13958
+ onKeyDown: onCustomAnswerConfirm ? (e) => {
13959
+ if (e.key === "Enter" && !e.shiftKey && !(e.metaKey || e.ctrlKey)) {
13960
+ e.preventDefault();
13961
+ onCustomAnswerConfirm();
13962
+ }
13963
+ } : void 0,
13730
13964
  placeholder: customAnswerPlaceholder,
13731
13965
  sizing: "small",
13732
13966
  testId: "question-custom"
@@ -13800,7 +14034,7 @@ var Question = ({
13800
14034
  children: "Skip"
13801
14035
  }
13802
14036
  ),
13803
- (multiSelect || isCustomSelected) && /* @__PURE__ */ jsxRuntime.jsx(
14037
+ (multiSelect || isCustomSelected) && (submitTooltip ? /* @__PURE__ */ jsxRuntime.jsx(Tooltip, { tooltip: submitTooltip, placement: "top", triggerAsChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
13804
14038
  Button,
13805
14039
  {
13806
14040
  argo: true,
@@ -13810,7 +14044,17 @@ var Question = ({
13810
14044
  "data-testid": "question-next-button",
13811
14045
  children: isLastStep ? "Submit" : "Next"
13812
14046
  }
13813
- )
14047
+ ) }) : /* @__PURE__ */ jsxRuntime.jsx(
14048
+ Button,
14049
+ {
14050
+ argo: true,
14051
+ variant: "primary",
14052
+ size: "small",
14053
+ onClick: onNext,
14054
+ "data-testid": "question-next-button",
14055
+ children: isLastStep ? "Submit" : "Next"
14056
+ }
14057
+ ))
13814
14058
  ]
13815
14059
  }
13816
14060
  )
@@ -14113,6 +14357,151 @@ var PasswordInput = ({
14113
14357
  }
14114
14358
  );
14115
14359
  };
14360
+ var InputOtpVariantContext = react.createContext({
14361
+ sizing: "md",
14362
+ state: "default"
14363
+ });
14364
+ var useInputOtpVariant = () => react.use(InputOtpVariantContext);
14365
+ var useInputOtpRenderContext = () => react.use(inputOtp.OTPInputContext);
14366
+ var InputOtpGroup = ({
14367
+ ref,
14368
+ className,
14369
+ ...props
14370
+ }) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("tw-flex tw-items-center tw-gap-2", className), ...props });
14371
+ var InputOtpSeparator = ({
14372
+ ref,
14373
+ children,
14374
+ className,
14375
+ ...props
14376
+ }) => /* @__PURE__ */ jsxRuntime.jsx(
14377
+ "div",
14378
+ {
14379
+ ref,
14380
+ role: "separator",
14381
+ "aria-orientation": "vertical",
14382
+ className: cn("tw-flex tw-items-center tw-text-muted-foreground", className),
14383
+ ...props,
14384
+ children: children ?? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Minus, { className: "tw-size-4" })
14385
+ }
14386
+ );
14387
+ var slotVariants = classVarianceAuthority.cva(
14388
+ [
14389
+ "tw-relative",
14390
+ "tw-flex",
14391
+ "tw-items-center",
14392
+ "tw-justify-center",
14393
+ "tw-border",
14394
+ "tw-border-input",
14395
+ "tw-bg-background",
14396
+ "tw-text-foreground",
14397
+ "tw-font-medium",
14398
+ "tw-tabular-nums",
14399
+ "tw-rounded-lg",
14400
+ "tw-transition",
14401
+ "tw-outline-none",
14402
+ // active slot sits above its neighbours so its ring isn't clipped
14403
+ "data-[active=true]:tw-z-10",
14404
+ "data-[active=true]:tw-border-primary",
14405
+ "data-[active=true]:tw-ring-2",
14406
+ "data-[active=true]:tw-ring-primary/50"
14407
+ ],
14408
+ {
14409
+ defaultVariants: {
14410
+ sizing: "md",
14411
+ state: "default"
14412
+ },
14413
+ variants: {
14414
+ sizing: {
14415
+ sm: ["tw-h-8", "tw-w-8", "tw-text-sm"],
14416
+ md: ["tw-h-9", "tw-w-9", "tw-text-base"],
14417
+ lg: ["tw-h-10", "tw-w-10", "tw-text-lg"]
14418
+ },
14419
+ // `!` forces the border colour over the base `tw-border-input` once tailwind-merge dedupes.
14420
+ // Matches the pattern InputGroup uses for its argo error state.
14421
+ state: {
14422
+ default: [],
14423
+ error: [
14424
+ "!tw-border-destructive",
14425
+ "tw-bg-destructive/5",
14426
+ "data-[active=true]:!tw-border-destructive",
14427
+ "data-[active=true]:tw-ring-destructive/40"
14428
+ ]
14429
+ }
14430
+ }
14431
+ }
14432
+ );
14433
+ var InputOtpSlot = ({
14434
+ ref,
14435
+ index,
14436
+ className,
14437
+ ...props
14438
+ }) => {
14439
+ const { slots } = useInputOtpRenderContext();
14440
+ const { sizing, state } = useInputOtpVariant();
14441
+ const slot = slots[index];
14442
+ const char = slot?.char ?? null;
14443
+ const isActive = slot?.isActive ?? false;
14444
+ const hasFakeCaret = slot?.hasFakeCaret ?? false;
14445
+ return /* @__PURE__ */ jsxRuntime.jsxs(
14446
+ "div",
14447
+ {
14448
+ ref,
14449
+ "data-active": isActive || void 0,
14450
+ "data-slot-index": index,
14451
+ className: cn(slotVariants({ sizing, state }), className),
14452
+ ...props,
14453
+ children: [
14454
+ char,
14455
+ hasFakeCaret && /* @__PURE__ */ jsxRuntime.jsx(
14456
+ "div",
14457
+ {
14458
+ "aria-hidden": "true",
14459
+ className: "tw-pointer-events-none tw-absolute tw-inset-0 tw-flex tw-items-center tw-justify-center",
14460
+ children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "tw-h-1/2 tw-w-px tw-animate-caret-blink tw-bg-foreground" })
14461
+ }
14462
+ )
14463
+ ]
14464
+ }
14465
+ );
14466
+ };
14467
+ var Root31 = ({
14468
+ ref,
14469
+ sizing = "md",
14470
+ state = "default",
14471
+ pattern = inputOtp.REGEXP_ONLY_DIGITS,
14472
+ containerClassName,
14473
+ className,
14474
+ children,
14475
+ ...rest
14476
+ }) => /* @__PURE__ */ jsxRuntime.jsx(InputOtpVariantContext, { value: { sizing, state }, children: /* @__PURE__ */ jsxRuntime.jsx(
14477
+ inputOtp.OTPInput,
14478
+ {
14479
+ ...rest,
14480
+ ref,
14481
+ pattern,
14482
+ "aria-invalid": state === "error" || void 0,
14483
+ containerClassName: cn(
14484
+ "tw-flex tw-items-center tw-gap-2 has-[:disabled]:tw-opacity-50",
14485
+ containerClassName
14486
+ ),
14487
+ className: cn("disabled:tw-cursor-not-allowed", className),
14488
+ children
14489
+ }
14490
+ ) });
14491
+ var InputOtp = Object.assign(Root31, {
14492
+ Group: InputOtpGroup,
14493
+ Slot: InputOtpSlot,
14494
+ Separator: InputOtpSeparator
14495
+ });
14496
+
14497
+ // src/blocks/InputOtp/index.ts
14498
+ var useInputOtpContext = () => {
14499
+ const ctx = react.use(inputOtp.OTPInputContext);
14500
+ if (!ctx.slots) {
14501
+ throw new Error("useInputOtpContext must be used inside <InputOtp>.");
14502
+ }
14503
+ return ctx;
14504
+ };
14116
14505
  var { fieldContext, useFieldContext, formContext, useFormContext } = reactForm.createFormHookContexts();
14117
14506
  var FormBody = ({ children, className, ...formProps }) => {
14118
14507
  const form = useFormContext();
@@ -14591,6 +14980,18 @@ Object.defineProperty(exports, "useCommandState", {
14591
14980
  enumerable: true,
14592
14981
  get: function () { return cmdk.useCommandState; }
14593
14982
  });
14983
+ Object.defineProperty(exports, "REGEXP_ONLY_CHARS", {
14984
+ enumerable: true,
14985
+ get: function () { return inputOtp.REGEXP_ONLY_CHARS; }
14986
+ });
14987
+ Object.defineProperty(exports, "REGEXP_ONLY_DIGITS", {
14988
+ enumerable: true,
14989
+ get: function () { return inputOtp.REGEXP_ONLY_DIGITS; }
14990
+ });
14991
+ Object.defineProperty(exports, "REGEXP_ONLY_DIGITS_AND_CHARS", {
14992
+ enumerable: true,
14993
+ get: function () { return inputOtp.REGEXP_ONLY_DIGITS_AND_CHARS; }
14994
+ });
14594
14995
  exports.Alert = Alert;
14595
14996
  exports.AnswerSummary = AnswerSummary;
14596
14997
  exports.AutoSaveTextarea = AutoSaveTextarea;
@@ -14640,6 +15041,7 @@ exports.Icon = Icon;
14640
15041
  exports.InlineStepDetail = InlineStepDetail;
14641
15042
  exports.InlineStepLabel = InlineStepLabel;
14642
15043
  exports.InputGroup = InputGroup;
15044
+ exports.InputOtp = InputOtp;
14643
15045
  exports.Kbd = Kbd;
14644
15046
  exports.Label = Label;
14645
15047
  exports.Link = Link2;
@@ -14701,6 +15103,7 @@ exports.TimePicker = TimePicker;
14701
15103
  exports.Timeline = Timeline;
14702
15104
  exports.Toaster = Toaster;
14703
15105
  exports.Toggle = Toggle;
15106
+ exports.ToggleGroup = ToggleGroup;
14704
15107
  exports.Tooltip = Tooltip;
14705
15108
  exports.TooltipProvider = TooltipProvider;
14706
15109
  exports.Truncated = Truncated;
@@ -14719,6 +15122,7 @@ exports.setServerFieldErrors = setServerFieldErrors;
14719
15122
  exports.toast = toast;
14720
15123
  exports.useAppForm = useAppForm;
14721
15124
  exports.useAutosizeInput = useAutosizeInput;
15125
+ exports.useInputOtpContext = useInputOtpContext;
14722
15126
  exports.useMergeDiff = useMergeDiff;
14723
15127
  exports.useNotification = useNotification;
14724
15128
  exports.useScrollbarPosition = useScrollbarPosition;