@nurix/ui-component-library 1.1.4-stage.113 → 1.1.4-stage.115

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -8006,8 +8006,12 @@ var NAVIGATION_TOKENS = {
8006
8006
  unselected: "bg-transparent",
8007
8007
  iconWrap: "shrink-0 [&>svg]:h-4 [&>svg]:w-4",
8008
8008
  groupTop: "flex items-center gap-0",
8009
- groupSide: "flex w-full flex-col items-start gap-1",
8010
- groupSection: "flex w-full flex-col items-start gap-1",
8009
+ // `items-stretch` so every tab fills the full cross-axis width of the
8010
+ // list. With `items-start` each tab shrank to its own text width, so
8011
+ // hover / selected surfaces looked ragged (the shorter labels got a
8012
+ // narrow pill, the longer labels clipped past their neighbours).
8013
+ groupSide: "flex w-full flex-col items-stretch gap-1",
8014
+ groupSection: "flex w-full flex-col items-stretch gap-1",
8011
8015
  labelBase: "shrink-0"
8012
8016
  },
8013
8017
  // --- ListNavigation ---
@@ -9211,9 +9215,12 @@ var SELECT_TOKENS = {
9211
9215
  text: "text-fg-black shrink-0",
9212
9216
  asterisk: "text-fg-destructive shrink-0"
9213
9217
  },
9214
- // Select group (label + select)
9218
+ // Select group (label + select). No `p-1` here — the outer `dropdown.base`
9219
+ // already paints 4px padding around the viewport, so adding it again on the
9220
+ // group produced 8px of whitespace on every edge (visible as extra space
9221
+ // below the last item).
9215
9222
  group: {
9216
- container: "flex flex-col gap-1 p-1 items-start"
9223
+ container: "flex flex-col gap-1 items-start"
9217
9224
  },
9218
9225
  // Spec card (for storybook)
9219
9226
  specCard: "border border-token-light flex flex-col gap-10 items-start p-14 rounded-3xl size-full",
@@ -10101,27 +10108,37 @@ import * as React25 from "react";
10101
10108
 
10102
10109
  // src/list-card/variables.ts
10103
10110
  var LIST_TOKENS = {
10104
- base: "cursor-pointer transition-colors hover:bg-interaction-hov-solid-primary",
10111
+ base: "transition-all duration-150 cursor-pointer",
10105
10112
  type: {
10106
- card: "flex flex-col gap-4 items-start p-6",
10113
+ // Card: vertical stack, 20px padding, 16px gap
10114
+ card: "flex flex-col gap-4 items-start p-5",
10115
+ // List: horizontal row, 16px gap, 16px / 24px padding
10107
10116
  list: "flex gap-4 items-center py-4 px-6"
10108
10117
  },
10109
10118
  variant: {
10110
10119
  card: {
10111
- default: "bg-token-white",
10112
- outline: "bg-token-white border border-token-light px-6",
10113
- muted: "bg-token-grey"
10120
+ // Figma 6249:35274 — default rest state: white bg, 1px xlight border,
10121
+ // shadow-sm. On hover we darken the border to `light` and deepen the
10122
+ // shadow to `shadow-lg`; on press we scale down to 0.955 to mimic a
10123
+ // button press without shifting surrounding layout.
10124
+ default: "bg-token-white border border-token-xlight shadow-sm hover:border-token-light hover:shadow-lg active:scale-[0.955] active:shadow-sm",
10125
+ // Outline drops the shadow, keeps the border emphasis.
10126
+ outline: "bg-token-white border border-token-light hover:bg-interaction-hov-solid-primary active:scale-[0.955]",
10127
+ // Muted fill variant — unchanged interactive behaviour.
10128
+ muted: "bg-token-grey hover:bg-interaction-hov-solid-primary active:scale-[0.955]"
10114
10129
  },
10115
10130
  list: {
10116
- default: "",
10117
- outline: "border border-token-light px-4",
10118
- muted: "bg-token-grey"
10131
+ default: "hover:bg-interaction-hov-solid-primary",
10132
+ outline: "border border-token-light px-4 hover:bg-interaction-hov-solid-primary",
10133
+ muted: "bg-token-grey hover:bg-interaction-hov-solid-primary"
10119
10134
  }
10120
10135
  },
10121
10136
  radius: {
10122
10137
  none: `${DEFAULT_THEME.radius.mode1.roundedNone}px`,
10123
10138
  soft: `${DEFAULT_THEME.radius.mode1.roundedMd}px`,
10124
- rounded: `${DEFAULT_THEME.radius.mode1.rounded2xl}px`
10139
+ // Figma 6249:35274 specifies 20px corner radius on cards. The mode-1
10140
+ // `rounded2xl` token is 16px, so we pin the card-default to 20px here.
10141
+ rounded: "20px"
10125
10142
  }
10126
10143
  };
10127
10144
 
@@ -10176,8 +10193,8 @@ var SURFACE_TOKENS = {
10176
10193
  * the system (Dialog uses 24px as well).
10177
10194
  */
10178
10195
  padded: "p-6 gap-4",
10179
- header: "flex items-center gap-[10px] text-lg font-semibold leading-7 text-fg-black",
10180
- body: "flex flex-col gap-2 text-sm font-normal leading-5 text-fg-black",
10196
+ header: "flex items-center gap-[10px] text-lg font-semibold leading-7 text-fg-black min-w-0 break-words",
10197
+ body: "flex flex-col gap-2 text-sm font-normal leading-5 text-fg-black min-w-0 break-words",
10181
10198
  footer: "flex items-center justify-end gap-2"
10182
10199
  };
10183
10200
 
@@ -10229,8 +10246,55 @@ var SurfaceFooter = React26.forwardRef(
10229
10246
  );
10230
10247
  SurfaceFooter.displayName = "SurfaceFooter";
10231
10248
 
10232
- // src/tooltip/tooltip.tsx
10249
+ // src/side-panel/side-panel.tsx
10233
10250
  import * as React27 from "react";
10251
+
10252
+ // src/side-panel/variables.ts
10253
+ var SIDE_PANEL_TOKENS = {
10254
+ base: "bg-token-white h-full overflow-hidden flex flex-col",
10255
+ size: {
10256
+ sm: "w-[420px]",
10257
+ md: "w-[620px]"
10258
+ },
10259
+ side: {
10260
+ // Panel anchored to the RIGHT edge of the viewport — its LEFT edge is
10261
+ // the inward-facing one, so only left corners are rounded.
10262
+ right: "rounded-l-2xl",
10263
+ // Panel anchored to the LEFT edge of the viewport — mirror.
10264
+ left: "rounded-r-2xl"
10265
+ }
10266
+ };
10267
+
10268
+ // src/side-panel/side-panel.tsx
10269
+ import { jsx as jsx23 } from "react/jsx-runtime";
10270
+ var SidePanel = React27.forwardRef(
10271
+ ({
10272
+ size = "sm",
10273
+ side = "right",
10274
+ className,
10275
+ children,
10276
+ ...props
10277
+ }, ref) => {
10278
+ return /* @__PURE__ */ jsx23(
10279
+ "div",
10280
+ {
10281
+ ref,
10282
+ className: cn(
10283
+ SIDE_PANEL_TOKENS.base,
10284
+ SIDE_PANEL_TOKENS.size[size],
10285
+ SIDE_PANEL_TOKENS.side[side],
10286
+ className
10287
+ ),
10288
+ ...props,
10289
+ children
10290
+ }
10291
+ );
10292
+ }
10293
+ );
10294
+ SidePanel.displayName = "SidePanel";
10295
+
10296
+ // src/tooltip/tooltip.tsx
10297
+ import * as React28 from "react";
10234
10298
  import * as TooltipPrimitive from "@radix-ui/react-tooltip";
10235
10299
 
10236
10300
  // src/tooltip/variables.ts
@@ -10248,10 +10312,10 @@ var TOOLTIP_TOKENS = {
10248
10312
  };
10249
10313
 
10250
10314
  // src/tooltip/tooltip.tsx
10251
- import { Fragment as Fragment7, jsx as jsx23, jsxs as jsxs15 } from "react/jsx-runtime";
10315
+ import { Fragment as Fragment7, jsx as jsx24, jsxs as jsxs15 } from "react/jsx-runtime";
10252
10316
  var useTooltipContainer = (anchorRef) => {
10253
- const [container, setContainer] = React27.useState(void 0);
10254
- React27.useEffect(() => {
10317
+ const [container, setContainer] = React28.useState(void 0);
10318
+ React28.useEffect(() => {
10255
10319
  var _a5;
10256
10320
  if (typeof document === "undefined") return;
10257
10321
  const anchor = anchorRef.current;
@@ -10263,8 +10327,8 @@ var useTooltipContainer = (anchorRef) => {
10263
10327
  var TooltipProvider = TooltipPrimitive.Provider;
10264
10328
  var Tooltip = TooltipPrimitive.Root;
10265
10329
  var TooltipTrigger = TooltipPrimitive.Trigger;
10266
- var TooltipContent = React27.forwardRef(({ className, sideOffset = 6, shortcut, children, ...props }, ref) => {
10267
- const anchorRef = React27.useRef(null);
10330
+ var TooltipContent = React28.forwardRef(({ className, sideOffset = 6, shortcut, children, ...props }, ref) => {
10331
+ const anchorRef = React28.useRef(null);
10268
10332
  const container = useTooltipContainer(anchorRef);
10269
10333
  const content = /* @__PURE__ */ jsxs15(
10270
10334
  TooltipPrimitive.Content,
@@ -10281,7 +10345,7 @@ var TooltipContent = React27.forwardRef(({ className, sideOffset = 6, shortcut,
10281
10345
  children: [
10282
10346
  /* @__PURE__ */ jsxs15("div", { className: "flex items-center", children: [
10283
10347
  children,
10284
- shortcut && /* @__PURE__ */ jsx23(
10348
+ shortcut && /* @__PURE__ */ jsx24(
10285
10349
  "span",
10286
10350
  {
10287
10351
  className: cn(
@@ -10293,7 +10357,7 @@ var TooltipContent = React27.forwardRef(({ className, sideOffset = 6, shortcut,
10293
10357
  }
10294
10358
  )
10295
10359
  ] }),
10296
- /* @__PURE__ */ jsx23(
10360
+ /* @__PURE__ */ jsx24(
10297
10361
  TooltipPrimitive.Arrow,
10298
10362
  {
10299
10363
  className: TOOLTIP_TOKENS.arrow,
@@ -10304,14 +10368,14 @@ var TooltipContent = React27.forwardRef(({ className, sideOffset = 6, shortcut,
10304
10368
  }
10305
10369
  );
10306
10370
  return /* @__PURE__ */ jsxs15(Fragment7, { children: [
10307
- /* @__PURE__ */ jsx23("span", { ref: anchorRef, style: { display: "none" } }),
10308
- container ? /* @__PURE__ */ jsx23(TooltipPrimitive.Portal, { container, children: content }) : content
10371
+ /* @__PURE__ */ jsx24("span", { ref: anchorRef, style: { display: "none" } }),
10372
+ container ? /* @__PURE__ */ jsx24(TooltipPrimitive.Portal, { container, children: content }) : content
10309
10373
  ] });
10310
10374
  });
10311
10375
  TooltipContent.displayName = TooltipPrimitive.Content.displayName;
10312
10376
 
10313
10377
  // src/dialog/dialog.tsx
10314
- import * as React28 from "react";
10378
+ import * as React29 from "react";
10315
10379
  import { X } from "lucide-react";
10316
10380
 
10317
10381
  // src/dialog/variables.ts
@@ -10347,10 +10411,10 @@ var DIALOG_TOKENS = {
10347
10411
  };
10348
10412
 
10349
10413
  // src/dialog/dialog.tsx
10350
- import { jsx as jsx24, jsxs as jsxs16 } from "react/jsx-runtime";
10351
- var DialogContext = React28.createContext({ close: () => {
10414
+ import { jsx as jsx25, jsxs as jsxs16 } from "react/jsx-runtime";
10415
+ var DialogContext = React29.createContext({ close: () => {
10352
10416
  } });
10353
- var Dialog = React28.forwardRef(
10417
+ var Dialog = React29.forwardRef(
10354
10418
  ({
10355
10419
  open,
10356
10420
  onOpenChange,
@@ -10366,8 +10430,8 @@ var Dialog = React28.forwardRef(
10366
10430
  onConfirm,
10367
10431
  className
10368
10432
  }, ref) => {
10369
- const close = React28.useCallback(() => onOpenChange(false), [onOpenChange]);
10370
- React28.useEffect(() => {
10433
+ const close = React29.useCallback(() => onOpenChange(false), [onOpenChange]);
10434
+ React29.useEffect(() => {
10371
10435
  if (!open) return;
10372
10436
  const handler = (e) => {
10373
10437
  if (e.key === "Escape") close();
@@ -10380,7 +10444,7 @@ var Dialog = React28.forwardRef(
10380
10444
  const hasFixedDividers = type === "scrollable-fixed";
10381
10445
  const hasIcon = type === "icon";
10382
10446
  const showClose = !hasIcon;
10383
- return /* @__PURE__ */ jsx24(DialogContext.Provider, { value: { close }, children: /* @__PURE__ */ jsx24("div", { className: DIALOG_TOKENS.overlay, onClick: close, children: /* @__PURE__ */ jsxs16(
10447
+ return /* @__PURE__ */ jsx25(DialogContext.Provider, { value: { close }, children: /* @__PURE__ */ jsx25("div", { className: DIALOG_TOKENS.overlay, onClick: close, children: /* @__PURE__ */ jsxs16(
10384
10448
  "div",
10385
10449
  {
10386
10450
  ref,
@@ -10394,24 +10458,24 @@ var Dialog = React28.forwardRef(
10394
10458
  ),
10395
10459
  onClick: (e) => e.stopPropagation(),
10396
10460
  children: [
10397
- hasIcon && icon && /* @__PURE__ */ jsx24("div", { className: DIALOG_TOKENS.icon.wrapper, children: icon }),
10461
+ hasIcon && icon && /* @__PURE__ */ jsx25("div", { className: DIALOG_TOKENS.icon.wrapper, children: icon }),
10398
10462
  title && /* @__PURE__ */ jsxs16("div", { className: DIALOG_TOKENS.header.wrapper, children: [
10399
10463
  /* @__PURE__ */ jsxs16("div", { className: DIALOG_TOKENS.header.row, children: [
10400
- /* @__PURE__ */ jsx24("h2", { id: "dialog-title", className: DIALOG_TOKENS.header.title, children: title }),
10401
- showClose && /* @__PURE__ */ jsx24(
10464
+ /* @__PURE__ */ jsx25("h2", { id: "dialog-title", className: DIALOG_TOKENS.header.title, children: title }),
10465
+ showClose && /* @__PURE__ */ jsx25(
10402
10466
  "button",
10403
10467
  {
10404
10468
  type: "button",
10405
10469
  onClick: close,
10406
10470
  className: DIALOG_TOKENS.header.closeBtn,
10407
10471
  "aria-label": "Close dialog",
10408
- children: /* @__PURE__ */ jsx24(X, { className: "size-[18px]" })
10472
+ children: /* @__PURE__ */ jsx25(X, { className: "size-[18px]" })
10409
10473
  }
10410
10474
  )
10411
10475
  ] }),
10412
- hasFixedDividers && /* @__PURE__ */ jsx24("div", { className: DIALOG_TOKENS.header.divider })
10476
+ hasFixedDividers && /* @__PURE__ */ jsx25("div", { className: DIALOG_TOKENS.header.divider })
10413
10477
  ] }),
10414
- /* @__PURE__ */ jsx24(
10478
+ /* @__PURE__ */ jsx25(
10415
10479
  "div",
10416
10480
  {
10417
10481
  className: cn(
@@ -10422,9 +10486,9 @@ var Dialog = React28.forwardRef(
10422
10486
  }
10423
10487
  ),
10424
10488
  /* @__PURE__ */ jsxs16("div", { className: DIALOG_TOKENS.footer.wrapper, children: [
10425
- hasFixedDividers && /* @__PURE__ */ jsx24("div", { className: DIALOG_TOKENS.footer.divider }),
10489
+ hasFixedDividers && /* @__PURE__ */ jsx25("div", { className: DIALOG_TOKENS.footer.divider }),
10426
10490
  /* @__PURE__ */ jsxs16("div", { className: DIALOG_TOKENS.footer.row, children: [
10427
- showCancel && /* @__PURE__ */ jsx24(
10491
+ showCancel && /* @__PURE__ */ jsx25(
10428
10492
  Button,
10429
10493
  {
10430
10494
  variant: "outline",
@@ -10433,7 +10497,7 @@ var Dialog = React28.forwardRef(
10433
10497
  children: cancelLabel
10434
10498
  }
10435
10499
  ),
10436
- /* @__PURE__ */ jsx24(
10500
+ /* @__PURE__ */ jsx25(
10437
10501
  Button,
10438
10502
  {
10439
10503
  variant: "primary",
@@ -10450,34 +10514,34 @@ var Dialog = React28.forwardRef(
10450
10514
  }
10451
10515
  );
10452
10516
  Dialog.displayName = "Dialog";
10453
- var DialogIcon = React28.forwardRef(
10454
- ({ children, className }, ref) => /* @__PURE__ */ jsx24("div", { ref, className: cn(DIALOG_TOKENS.icon.wrapper, className), children })
10517
+ var DialogIcon = React29.forwardRef(
10518
+ ({ children, className }, ref) => /* @__PURE__ */ jsx25("div", { ref, className: cn(DIALOG_TOKENS.icon.wrapper, className), children })
10455
10519
  );
10456
10520
  DialogIcon.displayName = "DialogIcon";
10457
- var DialogHeader = React28.forwardRef(
10521
+ var DialogHeader = React29.forwardRef(
10458
10522
  ({ title, showClose = true, showDivider = false, className }, ref) => {
10459
- const { close } = React28.useContext(DialogContext);
10523
+ const { close } = React29.useContext(DialogContext);
10460
10524
  return /* @__PURE__ */ jsxs16("div", { ref, className: cn(DIALOG_TOKENS.header.wrapper, className), children: [
10461
10525
  /* @__PURE__ */ jsxs16("div", { className: DIALOG_TOKENS.header.row, children: [
10462
- /* @__PURE__ */ jsx24("h2", { className: DIALOG_TOKENS.header.title, children: title }),
10463
- showClose && /* @__PURE__ */ jsx24(
10526
+ /* @__PURE__ */ jsx25("h2", { className: DIALOG_TOKENS.header.title, children: title }),
10527
+ showClose && /* @__PURE__ */ jsx25(
10464
10528
  "button",
10465
10529
  {
10466
10530
  type: "button",
10467
10531
  onClick: close,
10468
10532
  className: DIALOG_TOKENS.header.closeBtn,
10469
10533
  "aria-label": "Close dialog",
10470
- children: /* @__PURE__ */ jsx24(X, { className: "size-[18px]" })
10534
+ children: /* @__PURE__ */ jsx25(X, { className: "size-[18px]" })
10471
10535
  }
10472
10536
  )
10473
10537
  ] }),
10474
- showDivider && /* @__PURE__ */ jsx24("div", { className: DIALOG_TOKENS.header.divider })
10538
+ showDivider && /* @__PURE__ */ jsx25("div", { className: DIALOG_TOKENS.header.divider })
10475
10539
  ] });
10476
10540
  }
10477
10541
  );
10478
10542
  DialogHeader.displayName = "DialogHeader";
10479
- var DialogBody = React28.forwardRef(
10480
- ({ children, scrollable = false, className }, ref) => /* @__PURE__ */ jsx24(
10543
+ var DialogBody = React29.forwardRef(
10544
+ ({ children, scrollable = false, className }, ref) => /* @__PURE__ */ jsx25(
10481
10545
  "div",
10482
10546
  {
10483
10547
  ref,
@@ -10491,7 +10555,7 @@ var DialogBody = React28.forwardRef(
10491
10555
  )
10492
10556
  );
10493
10557
  DialogBody.displayName = "DialogBody";
10494
- var DialogFooter = React28.forwardRef(
10558
+ var DialogFooter = React29.forwardRef(
10495
10559
  ({
10496
10560
  cancelLabel = "Cancel",
10497
10561
  confirmLabel = "Continue",
@@ -10501,11 +10565,11 @@ var DialogFooter = React28.forwardRef(
10501
10565
  showDivider = false,
10502
10566
  className
10503
10567
  }, ref) => {
10504
- const { close } = React28.useContext(DialogContext);
10568
+ const { close } = React29.useContext(DialogContext);
10505
10569
  return /* @__PURE__ */ jsxs16("div", { ref, className: cn(DIALOG_TOKENS.footer.wrapper, className), children: [
10506
- showDivider && /* @__PURE__ */ jsx24("div", { className: DIALOG_TOKENS.footer.divider }),
10570
+ showDivider && /* @__PURE__ */ jsx25("div", { className: DIALOG_TOKENS.footer.divider }),
10507
10571
  /* @__PURE__ */ jsxs16("div", { className: DIALOG_TOKENS.footer.row, children: [
10508
- showCancel && /* @__PURE__ */ jsx24(
10572
+ showCancel && /* @__PURE__ */ jsx25(
10509
10573
  Button,
10510
10574
  {
10511
10575
  variant: "outline",
@@ -10514,7 +10578,7 @@ var DialogFooter = React28.forwardRef(
10514
10578
  children: cancelLabel
10515
10579
  }
10516
10580
  ),
10517
- /* @__PURE__ */ jsx24(
10581
+ /* @__PURE__ */ jsx25(
10518
10582
  Button,
10519
10583
  {
10520
10584
  variant: "primary",
@@ -10530,7 +10594,7 @@ var DialogFooter = React28.forwardRef(
10530
10594
  DialogFooter.displayName = "DialogFooter";
10531
10595
 
10532
10596
  // src/toast/toast.tsx
10533
- import * as React29 from "react";
10597
+ import * as React30 from "react";
10534
10598
  import { Toaster as SonnerToaster, toast as sonnerToast } from "sonner";
10535
10599
  import { ChevronRight, CircleCheck, CircleAlert, ThumbsUp } from "lucide-react";
10536
10600
 
@@ -10573,11 +10637,11 @@ var TOAST_TOKENS = {
10573
10637
  };
10574
10638
 
10575
10639
  // src/toast/toast.tsx
10576
- import { jsx as jsx25, jsxs as jsxs17 } from "react/jsx-runtime";
10640
+ import { jsx as jsx26, jsxs as jsxs17 } from "react/jsx-runtime";
10577
10641
  var Toaster = ({
10578
10642
  position = "bottom-right",
10579
10643
  ...props
10580
- }) => /* @__PURE__ */ jsx25(
10644
+ }) => /* @__PURE__ */ jsx26(
10581
10645
  SonnerToaster,
10582
10646
  {
10583
10647
  position,
@@ -10591,7 +10655,7 @@ var TOAST_ICON = {
10591
10655
  error: CircleAlert,
10592
10656
  default: ThumbsUp
10593
10657
  };
10594
- var Toast = React29.forwardRef(
10658
+ var Toast = React30.forwardRef(
10595
10659
  ({
10596
10660
  variant = "default",
10597
10661
  title,
@@ -10616,26 +10680,26 @@ var Toast = React29.forwardRef(
10616
10680
  /* @__PURE__ */ jsxs17("div", { className: TOAST_TOKENS.innerRow, children: [
10617
10681
  /* @__PURE__ */ jsxs17("div", { className: TOAST_TOKENS.content, children: [
10618
10682
  /* @__PURE__ */ jsxs17("div", { className: TOAST_TOKENS.titleRow, children: [
10619
- /* @__PURE__ */ jsx25(Icon2, { className: TOAST_TOKENS.icon[variant] }),
10620
- /* @__PURE__ */ jsx25("span", { className: TOAST_TOKENS.title[variant], children: title })
10683
+ /* @__PURE__ */ jsx26(Icon2, { className: TOAST_TOKENS.icon[variant] }),
10684
+ /* @__PURE__ */ jsx26("span", { className: TOAST_TOKENS.title[variant], children: title })
10621
10685
  ] }),
10622
- subtext && /* @__PURE__ */ jsx25("div", { className: TOAST_TOKENS.subtextRow, children: /* @__PURE__ */ jsx25("span", { className: TOAST_TOKENS.subtext, children: subtext }) })
10686
+ subtext && /* @__PURE__ */ jsx26("div", { className: TOAST_TOKENS.subtextRow, children: /* @__PURE__ */ jsx26("span", { className: TOAST_TOKENS.subtext, children: subtext }) })
10623
10687
  ] }),
10624
- showCancel && /* @__PURE__ */ jsx25(
10688
+ showCancel && /* @__PURE__ */ jsx26(
10625
10689
  "button",
10626
10690
  {
10627
10691
  type: "button",
10628
10692
  onClick: onCancel,
10629
10693
  className: TOAST_TOKENS.cancelBtn,
10630
10694
  "aria-label": "Dismiss",
10631
- children: /* @__PURE__ */ jsx25(ChevronRight, {})
10695
+ children: /* @__PURE__ */ jsx26(ChevronRight, {})
10632
10696
  }
10633
10697
  )
10634
10698
  ] }),
10635
10699
  showProgress && /* @__PURE__ */ jsxs17("div", { className: TOAST_TOKENS.progress.wrapper, children: [
10636
- /* @__PURE__ */ jsx25("style", { children: `@keyframes toast-shrink { from { width: 100% } to { width: 0% } }` }),
10637
- /* @__PURE__ */ jsx25("div", { className: TOAST_TOKENS.progress.track }),
10638
- /* @__PURE__ */ jsx25(
10700
+ /* @__PURE__ */ jsx26("style", { children: `@keyframes toast-shrink { from { width: 100% } to { width: 0% } }` }),
10701
+ /* @__PURE__ */ jsx26("div", { className: TOAST_TOKENS.progress.track }),
10702
+ /* @__PURE__ */ jsx26(
10639
10703
  "div",
10640
10704
  {
10641
10705
  className: cn(
@@ -10657,7 +10721,7 @@ var showToast = ({
10657
10721
  ...props
10658
10722
  }) => {
10659
10723
  return sonnerToast.custom(
10660
- (id) => /* @__PURE__ */ jsx25(
10724
+ (id) => /* @__PURE__ */ jsx26(
10661
10725
  Toast,
10662
10726
  {
10663
10727
  ...props,
@@ -10669,7 +10733,7 @@ var showToast = ({
10669
10733
  };
10670
10734
 
10671
10735
  // src/stepper/stepper.tsx
10672
- import * as React30 from "react";
10736
+ import * as React31 from "react";
10673
10737
  import { Check as Check4 } from "lucide-react";
10674
10738
 
10675
10739
  // src/stepper/variables.ts
@@ -10718,16 +10782,16 @@ var STEPPER_TOKENS = {
10718
10782
  };
10719
10783
 
10720
10784
  // src/stepper/stepper.tsx
10721
- import { jsx as jsx26, jsxs as jsxs18 } from "react/jsx-runtime";
10722
- var StepperBar = React30.forwardRef(
10785
+ import { jsx as jsx27, jsxs as jsxs18 } from "react/jsx-runtime";
10786
+ var StepperBar = React31.forwardRef(
10723
10787
  ({ totalSteps = 4, currentStep, className, style }, ref) => {
10724
- return /* @__PURE__ */ jsx26(
10788
+ return /* @__PURE__ */ jsx27(
10725
10789
  "div",
10726
10790
  {
10727
10791
  ref,
10728
10792
  className: cn(STEPPER_TOKENS.bar.root, className),
10729
10793
  style,
10730
- children: Array.from({ length: totalSteps }).map((_2, index2) => /* @__PURE__ */ jsx26(
10794
+ children: Array.from({ length: totalSteps }).map((_2, index2) => /* @__PURE__ */ jsx27(
10731
10795
  "div",
10732
10796
  {
10733
10797
  className: cn(
@@ -10742,9 +10806,9 @@ var StepperBar = React30.forwardRef(
10742
10806
  }
10743
10807
  );
10744
10808
  StepperBar.displayName = "StepperBar";
10745
- var Stepper = React30.forwardRef(
10809
+ var Stepper = React31.forwardRef(
10746
10810
  ({ steps, className, style }, ref) => {
10747
- return /* @__PURE__ */ jsx26(
10811
+ return /* @__PURE__ */ jsx27(
10748
10812
  "div",
10749
10813
  {
10750
10814
  ref,
@@ -10753,16 +10817,16 @@ var Stepper = React30.forwardRef(
10753
10817
  children: steps.map((step, index2) => {
10754
10818
  var _a5;
10755
10819
  const state2 = (_a5 = step.state) != null ? _a5 : "incomplete";
10756
- return /* @__PURE__ */ jsxs18(React30.Fragment, { children: [
10820
+ return /* @__PURE__ */ jsxs18(React31.Fragment, { children: [
10757
10821
  /* @__PURE__ */ jsxs18("div", { className: STEPPER_TOKENS.stepper.step.wrapper, children: [
10758
- /* @__PURE__ */ jsx26(
10822
+ /* @__PURE__ */ jsx27(
10759
10823
  "div",
10760
10824
  {
10761
10825
  className: cn(
10762
10826
  STEPPER_TOKENS.stepper.step.indicator.base,
10763
10827
  STEPPER_TOKENS.stepper.step.indicator[state2]
10764
10828
  ),
10765
- children: state2 === "complete" ? /* @__PURE__ */ jsx26(Check4, { className: STEPPER_TOKENS.stepper.step.checkIcon }) : /* @__PURE__ */ jsx26(
10829
+ children: state2 === "complete" ? /* @__PURE__ */ jsx27(Check4, { className: STEPPER_TOKENS.stepper.step.checkIcon }) : /* @__PURE__ */ jsx27(
10766
10830
  "span",
10767
10831
  {
10768
10832
  className: state2 === "active" ? STEPPER_TOKENS.stepper.step.number.active : STEPPER_TOKENS.stepper.step.number.incomplete,
@@ -10771,7 +10835,7 @@ var Stepper = React30.forwardRef(
10771
10835
  )
10772
10836
  }
10773
10837
  ),
10774
- /* @__PURE__ */ jsx26(
10838
+ /* @__PURE__ */ jsx27(
10775
10839
  "span",
10776
10840
  {
10777
10841
  className: cn(
@@ -10782,7 +10846,7 @@ var Stepper = React30.forwardRef(
10782
10846
  }
10783
10847
  )
10784
10848
  ] }),
10785
- index2 < steps.length - 1 && /* @__PURE__ */ jsx26(
10849
+ index2 < steps.length - 1 && /* @__PURE__ */ jsx27(
10786
10850
  "div",
10787
10851
  {
10788
10852
  className: cn(
@@ -10798,10 +10862,10 @@ var Stepper = React30.forwardRef(
10798
10862
  }
10799
10863
  );
10800
10864
  Stepper.displayName = "Stepper";
10801
- var ProgressBar = React30.forwardRef(
10865
+ var ProgressBar = React31.forwardRef(
10802
10866
  ({ value, max = 100, className, style }, ref) => {
10803
10867
  const percentage = Math.min(100, Math.max(0, value / max * 100));
10804
- return /* @__PURE__ */ jsx26(
10868
+ return /* @__PURE__ */ jsx27(
10805
10869
  "div",
10806
10870
  {
10807
10871
  ref,
@@ -10811,7 +10875,7 @@ var ProgressBar = React30.forwardRef(
10811
10875
  "aria-valuenow": value,
10812
10876
  "aria-valuemin": 0,
10813
10877
  "aria-valuemax": max,
10814
- children: /* @__PURE__ */ jsx26("div", { className: STEPPER_TOKENS.progressBar.track, children: /* @__PURE__ */ jsx26(
10878
+ children: /* @__PURE__ */ jsx27("div", { className: STEPPER_TOKENS.progressBar.track, children: /* @__PURE__ */ jsx27(
10815
10879
  "div",
10816
10880
  {
10817
10881
  className: STEPPER_TOKENS.progressBar.fill,
@@ -10825,7 +10889,7 @@ var ProgressBar = React30.forwardRef(
10825
10889
  ProgressBar.displayName = "ProgressBar";
10826
10890
 
10827
10891
  // src/icon/icon.tsx
10828
- import * as React31 from "react";
10892
+ import * as React32 from "react";
10829
10893
  import * as DropdownMenuPrimitive2 from "@radix-ui/react-dropdown-menu";
10830
10894
  import { Search as Search2 } from "lucide-react";
10831
10895
  import * as LucideIcons from "lucide-react";
@@ -10874,10 +10938,10 @@ var ICON_TOKENS = {
10874
10938
  };
10875
10939
 
10876
10940
  // src/icon/icon.tsx
10877
- import { jsx as jsx27, jsxs as jsxs19 } from "react/jsx-runtime";
10878
- var IconWrapper = React31.forwardRef(
10941
+ import { jsx as jsx28, jsxs as jsxs19 } from "react/jsx-runtime";
10942
+ var IconWrapper = React32.forwardRef(
10879
10943
  ({ color = "default", size = "sm", children, className, style }, ref) => {
10880
- return /* @__PURE__ */ jsx27(
10944
+ return /* @__PURE__ */ jsx28(
10881
10945
  "span",
10882
10946
  {
10883
10947
  ref,
@@ -11014,7 +11078,7 @@ function getLucideIcon(name) {
11014
11078
  }
11015
11079
  return null;
11016
11080
  }
11017
- var IconPicker = React31.forwardRef(
11081
+ var IconPicker = React32.forwardRef(
11018
11082
  ({
11019
11083
  value,
11020
11084
  onValueChange,
@@ -11027,24 +11091,24 @@ var IconPicker = React31.forwardRef(
11027
11091
  }, ref) => {
11028
11092
  const { theme } = useTheme();
11029
11093
  const themeClass = theme === "dark" ? "dark" : "light";
11030
- const [open, setOpen] = React31.useState(false);
11031
- const [query, setQuery] = React31.useState("");
11094
+ const [open, setOpen] = React32.useState(false);
11095
+ const [query, setQuery] = React32.useState("");
11032
11096
  const iconNames = icons != null ? icons : COMMON_ICON_NAMES;
11033
- const filtered = React31.useMemo(() => {
11097
+ const filtered = React32.useMemo(() => {
11034
11098
  if (!query.trim()) return iconNames;
11035
11099
  const q = query.toLowerCase().trim();
11036
11100
  return iconNames.filter((name) => name.toLowerCase().includes(q));
11037
11101
  }, [iconNames, query]);
11038
11102
  const SelectedIcon = value ? getLucideIcon(value) : null;
11039
- const container = React31.useMemo(
11103
+ const container = React32.useMemo(
11040
11104
  () => {
11041
11105
  var _a5;
11042
11106
  return typeof document !== "undefined" ? (_a5 = document.querySelector(".lego-land")) != null ? _a5 : void 0 : void 0;
11043
11107
  },
11044
11108
  []
11045
11109
  );
11046
- return /* @__PURE__ */ jsx27("div", { ref, className: cn("inline-block", className), style, children: /* @__PURE__ */ jsxs19(DropdownMenuPrimitive2.Root, { open, onOpenChange: setOpen, children: [
11047
- /* @__PURE__ */ jsx27(DropdownMenuPrimitive2.Trigger, { asChild: true, children: /* @__PURE__ */ jsx27(
11110
+ return /* @__PURE__ */ jsx28("div", { ref, className: cn("inline-block", className), style, children: /* @__PURE__ */ jsxs19(DropdownMenuPrimitive2.Root, { open, onOpenChange: setOpen, children: [
11111
+ /* @__PURE__ */ jsx28(DropdownMenuPrimitive2.Trigger, { asChild: true, children: /* @__PURE__ */ jsx28(
11048
11112
  "button",
11049
11113
  {
11050
11114
  type: "button",
@@ -11052,10 +11116,10 @@ var IconPicker = React31.forwardRef(
11052
11116
  ICON_TOKENS.picker.trigger,
11053
11117
  ICON_TOKENS.color[color]
11054
11118
  ),
11055
- children: SelectedIcon ? /* @__PURE__ */ jsx27(SelectedIcon, { className: ICON_TOKENS.size[size] }) : /* @__PURE__ */ jsx27("span", { className: "text-xs text-fg-placeholder", children: placeholder })
11119
+ children: SelectedIcon ? /* @__PURE__ */ jsx28(SelectedIcon, { className: ICON_TOKENS.size[size] }) : /* @__PURE__ */ jsx28("span", { className: "text-xs text-fg-placeholder", children: placeholder })
11056
11120
  }
11057
11121
  ) }),
11058
- /* @__PURE__ */ jsx27(DropdownMenuPrimitive2.Portal, { container, children: /* @__PURE__ */ jsx27("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsxs19(
11122
+ /* @__PURE__ */ jsx28(DropdownMenuPrimitive2.Portal, { container, children: /* @__PURE__ */ jsx28("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsxs19(
11059
11123
  DropdownMenuPrimitive2.Content,
11060
11124
  {
11061
11125
  className: cn(
@@ -11072,8 +11136,8 @@ var IconPicker = React31.forwardRef(
11072
11136
  onCloseAutoFocus: (e) => e.preventDefault(),
11073
11137
  children: [
11074
11138
  /* @__PURE__ */ jsxs19("div", { className: "flex items-center gap-2", children: [
11075
- /* @__PURE__ */ jsx27(Search2, { className: "size-4 text-fg-grey-secondary shrink-0" }),
11076
- /* @__PURE__ */ jsx27(
11139
+ /* @__PURE__ */ jsx28(Search2, { className: "size-4 text-fg-grey-secondary shrink-0" }),
11140
+ /* @__PURE__ */ jsx28(
11077
11141
  "input",
11078
11142
  {
11079
11143
  type: "search",
@@ -11086,11 +11150,11 @@ var IconPicker = React31.forwardRef(
11086
11150
  }
11087
11151
  )
11088
11152
  ] }),
11089
- filtered.length === 0 ? /* @__PURE__ */ jsx27("p", { className: ICON_TOKENS.picker.emptyText, children: "No icons found" }) : /* @__PURE__ */ jsx27("div", { className: ICON_TOKENS.picker.grid, children: filtered.map((name) => {
11153
+ filtered.length === 0 ? /* @__PURE__ */ jsx28("p", { className: ICON_TOKENS.picker.emptyText, children: "No icons found" }) : /* @__PURE__ */ jsx28("div", { className: ICON_TOKENS.picker.grid, children: filtered.map((name) => {
11090
11154
  const Icon2 = getLucideIcon(name);
11091
11155
  if (!Icon2) return null;
11092
11156
  const isSelected = name === value;
11093
- return /* @__PURE__ */ jsx27(
11157
+ return /* @__PURE__ */ jsx28(
11094
11158
  DropdownMenuPrimitive2.Item,
11095
11159
  {
11096
11160
  className: cn(
@@ -11104,7 +11168,7 @@ var IconPicker = React31.forwardRef(
11104
11168
  setOpen(false);
11105
11169
  },
11106
11170
  title: name,
11107
- children: /* @__PURE__ */ jsx27(Icon2, { className: "size-4" })
11171
+ children: /* @__PURE__ */ jsx28(Icon2, { className: "size-4" })
11108
11172
  },
11109
11173
  name
11110
11174
  );
@@ -11118,9 +11182,9 @@ var IconPicker = React31.forwardRef(
11118
11182
  IconPicker.displayName = "IconPicker";
11119
11183
 
11120
11184
  // src/shadow-dom-wrapper.tsx
11121
- import * as React32 from "react";
11185
+ import * as React33 from "react";
11122
11186
  import { createPortal } from "react-dom";
11123
- import { Fragment as Fragment9, jsx as jsx28, jsxs as jsxs20 } from "react/jsx-runtime";
11187
+ import { Fragment as Fragment9, jsx as jsx29, jsxs as jsxs20 } from "react/jsx-runtime";
11124
11188
  var ShadowDOMWrapper = ({
11125
11189
  children,
11126
11190
  styles,
@@ -11128,10 +11192,10 @@ var ShadowDOMWrapper = ({
11128
11192
  additionalStyles = "",
11129
11193
  copyCSSVariables = true
11130
11194
  }) => {
11131
- const containerRef = React32.useRef(null);
11132
- const shadowRootRef = React32.useRef(null);
11133
- const [shadowRoot, setShadowRoot] = React32.useState(null);
11134
- React32.useEffect(() => {
11195
+ const containerRef = React33.useRef(null);
11196
+ const shadowRootRef = React33.useRef(null);
11197
+ const [shadowRoot, setShadowRoot] = React33.useState(null);
11198
+ React33.useEffect(() => {
11135
11199
  if (!containerRef.current) return;
11136
11200
  if (!shadowRootRef.current) {
11137
11201
  shadowRootRef.current = containerRef.current.attachShadow({ mode });
@@ -11221,14 +11285,14 @@ var ShadowDOMWrapper = ({
11221
11285
  };
11222
11286
  }, [styles, mode, additionalStyles, copyCSSVariables]);
11223
11287
  return /* @__PURE__ */ jsxs20(Fragment9, { children: [
11224
- /* @__PURE__ */ jsx28("div", { ref: containerRef }),
11288
+ /* @__PURE__ */ jsx29("div", { ref: containerRef }),
11225
11289
  shadowRoot && createPortal(children, shadowRoot)
11226
11290
  ] });
11227
11291
  };
11228
11292
  ShadowDOMWrapper.displayName = "ShadowDOMWrapper";
11229
11293
 
11230
11294
  // src/table/table.tsx
11231
- import * as React33 from "react";
11295
+ import * as React34 from "react";
11232
11296
  import {
11233
11297
  ChevronUp,
11234
11298
  ChevronDown as ChevronDown4,
@@ -11326,22 +11390,22 @@ function getColumnWidthPx(width) {
11326
11390
  }
11327
11391
 
11328
11392
  // src/table/table.tsx
11329
- import { Fragment as Fragment10, jsx as jsx29, jsxs as jsxs21 } from "react/jsx-runtime";
11393
+ import { Fragment as Fragment10, jsx as jsx30, jsxs as jsxs21 } from "react/jsx-runtime";
11330
11394
  function formatNumber(n) {
11331
11395
  if (n == null) return "0";
11332
11396
  return n.toLocaleString();
11333
11397
  }
11334
11398
  function isCellTextContent(value) {
11335
- return typeof value === "object" && value !== null && !React33.isValidElement(value) && "text" in value;
11399
+ return typeof value === "object" && value !== null && !React34.isValidElement(value) && "text" in value;
11336
11400
  }
11337
11401
  function renderCellContent(content) {
11338
11402
  if (content === null || content === void 0) return null;
11339
11403
  if (typeof content === "string" || typeof content === "number") {
11340
- return /* @__PURE__ */ jsx29("span", { children: content });
11404
+ return /* @__PURE__ */ jsx30("span", { children: content });
11341
11405
  }
11342
11406
  if (isCellTextContent(content)) {
11343
11407
  const { text, className, style } = content;
11344
- return /* @__PURE__ */ jsx29("span", { className, style, children: text });
11408
+ return /* @__PURE__ */ jsx30("span", { className, style, children: text });
11345
11409
  }
11346
11410
  return content;
11347
11411
  }
@@ -11378,15 +11442,15 @@ function Pagination({
11378
11442
  ] }),
11379
11443
  /* @__PURE__ */ jsxs21("div", { className: TABLE_TOKENS.paginationBar.rightSection, children: [
11380
11444
  /* @__PURE__ */ jsxs21("div", { className: TABLE_TOKENS.paginationBar.rowCountSection, children: [
11381
- /* @__PURE__ */ jsx29("span", { className: TABLE_TOKENS.paginationBar.text, children: "Rows per page" }),
11445
+ /* @__PURE__ */ jsx30("span", { className: TABLE_TOKENS.paginationBar.text, children: "Rows per page" }),
11382
11446
  /* @__PURE__ */ jsxs21(
11383
11447
  Select,
11384
11448
  {
11385
11449
  value: String(rowsPerPage),
11386
11450
  onValueChange: handleRowsPerPageSelect,
11387
11451
  children: [
11388
- /* @__PURE__ */ jsx29(SelectTrigger, { size: "small", children: /* @__PURE__ */ jsx29(SelectValue, {}) }),
11389
- /* @__PURE__ */ jsx29(
11452
+ /* @__PURE__ */ jsx30(SelectTrigger, { size: "small", children: /* @__PURE__ */ jsx30(SelectValue, {}) }),
11453
+ /* @__PURE__ */ jsx30(
11390
11454
  SelectContent,
11391
11455
  {
11392
11456
  items: ROWS_PER_PAGE_OPTIONS.map((n) => ({
@@ -11407,7 +11471,7 @@ function Pagination({
11407
11471
  formatNumber(totalPages || 1)
11408
11472
  ] }),
11409
11473
  /* @__PURE__ */ jsxs21("div", { className: TABLE_TOKENS.paginationBar.navButtons, children: [
11410
- /* @__PURE__ */ jsx29(
11474
+ /* @__PURE__ */ jsx30(
11411
11475
  "button",
11412
11476
  {
11413
11477
  type: "button",
@@ -11418,10 +11482,10 @@ function Pagination({
11418
11482
  onClick: () => currentPage > 1 && handlePageChange(1),
11419
11483
  disabled: isFirstPage,
11420
11484
  "aria-label": "Go to first page",
11421
- children: /* @__PURE__ */ jsx29(ChevronFirst, { className: isFirstPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11485
+ children: /* @__PURE__ */ jsx30(ChevronFirst, { className: isFirstPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11422
11486
  }
11423
11487
  ),
11424
- /* @__PURE__ */ jsx29(
11488
+ /* @__PURE__ */ jsx30(
11425
11489
  "button",
11426
11490
  {
11427
11491
  type: "button",
@@ -11432,10 +11496,10 @@ function Pagination({
11432
11496
  onClick: () => currentPage > 1 && handlePageChange(currentPage - 1),
11433
11497
  disabled: isFirstPage,
11434
11498
  "aria-label": "Go to previous page",
11435
- children: /* @__PURE__ */ jsx29(ChevronLeft, { className: isFirstPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11499
+ children: /* @__PURE__ */ jsx30(ChevronLeft, { className: isFirstPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11436
11500
  }
11437
11501
  ),
11438
- /* @__PURE__ */ jsx29(
11502
+ /* @__PURE__ */ jsx30(
11439
11503
  "button",
11440
11504
  {
11441
11505
  type: "button",
@@ -11446,10 +11510,10 @@ function Pagination({
11446
11510
  onClick: () => currentPage < totalPages && handlePageChange(currentPage + 1),
11447
11511
  disabled: isLastPage,
11448
11512
  "aria-label": "Go to next page",
11449
- children: /* @__PURE__ */ jsx29(ChevronRight2, { className: isLastPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11513
+ children: /* @__PURE__ */ jsx30(ChevronRight2, { className: isLastPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11450
11514
  }
11451
11515
  ),
11452
- /* @__PURE__ */ jsx29(
11516
+ /* @__PURE__ */ jsx30(
11453
11517
  "button",
11454
11518
  {
11455
11519
  type: "button",
@@ -11460,7 +11524,7 @@ function Pagination({
11460
11524
  onClick: () => currentPage < totalPages && handlePageChange(totalPages),
11461
11525
  disabled: isLastPage,
11462
11526
  "aria-label": "Go to last page",
11463
- children: /* @__PURE__ */ jsx29(ChevronLast, { className: isLastPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11527
+ children: /* @__PURE__ */ jsx30(ChevronLast, { className: isLastPage ? TABLE_TOKENS.paginationBar.navIconDisabled : TABLE_TOKENS.paginationBar.navIcon })
11464
11528
  }
11465
11529
  )
11466
11530
  ] })
@@ -11492,20 +11556,20 @@ function DataTable({
11492
11556
  loading = false,
11493
11557
  onRowClick
11494
11558
  }) {
11495
- const resolveId = React33.useCallback(
11559
+ const resolveId = React34.useCallback(
11496
11560
  (row, index2) => {
11497
11561
  if (getRowId) return getRowId(row);
11498
11562
  return String(index2);
11499
11563
  },
11500
11564
  [getRowId]
11501
11565
  );
11502
- const orderedColumns = React33.useMemo(() => {
11566
+ const orderedColumns = React34.useMemo(() => {
11503
11567
  const pinnedSet = new Set(pinnedColumns);
11504
11568
  const pinned = pinnedColumns.map((key) => columns.find((c) => c.key === key)).filter((c) => c !== void 0);
11505
11569
  const rest = columns.filter((c) => !pinnedSet.has(c.key));
11506
11570
  return [...pinned, ...rest];
11507
11571
  }, [columns, pinnedColumns]);
11508
- const stickyOffsets = React33.useMemo(() => {
11572
+ const stickyOffsets = React34.useMemo(() => {
11509
11573
  const offsets = {};
11510
11574
  let accumulated = showCheckbox ? CHECKBOX_COLUMN_WIDTH : 0;
11511
11575
  for (const col of orderedColumns) {
@@ -11516,7 +11580,7 @@ function DataTable({
11516
11580
  }
11517
11581
  return offsets;
11518
11582
  }, [orderedColumns, pinnedColumns, showCheckbox]);
11519
- const sortState = React33.useMemo(() => {
11583
+ const sortState = React34.useMemo(() => {
11520
11584
  const col = orderedColumns.find((c) => c.sort_direction);
11521
11585
  return col ? { key: col.key, direction: col.sort_direction } : null;
11522
11586
  }, [orderedColumns]);
@@ -11532,7 +11596,7 @@ function DataTable({
11532
11596
  onSortChange({ key, direction: null });
11533
11597
  }
11534
11598
  };
11535
- const selectedSet = React33.useMemo(
11599
+ const selectedSet = React34.useMemo(
11536
11600
  () => new Set(selectedRows),
11537
11601
  [selectedRows]
11538
11602
  );
@@ -11549,9 +11613,9 @@ function DataTable({
11549
11613
  const hasActions = actions.length > 0;
11550
11614
  const skeletonColumnCount = columns.length > 0 ? columns.length : 5;
11551
11615
  const skeletonRowCount = 10;
11552
- const scrollContainerRef = React33.useRef(null);
11553
- const [scrollContainerWidth, setScrollContainerWidth] = React33.useState(0);
11554
- React33.useEffect(() => {
11616
+ const scrollContainerRef = React34.useRef(null);
11617
+ const [scrollContainerWidth, setScrollContainerWidth] = React34.useState(0);
11618
+ React34.useEffect(() => {
11555
11619
  const el = scrollContainerRef.current;
11556
11620
  if (!el || typeof ResizeObserver === "undefined") return;
11557
11621
  const observer = new ResizeObserver((entries) => {
@@ -11562,10 +11626,10 @@ function DataTable({
11562
11626
  observer.observe(el);
11563
11627
  return () => observer.disconnect();
11564
11628
  }, []);
11565
- return /* @__PURE__ */ jsx29(TooltipProvider, { children: /* @__PURE__ */ jsxs21("div", { className: cn(TABLE_TOKENS.wrapper, !showBorder && "border-0", className), children: [
11566
- /* @__PURE__ */ jsx29("div", { ref: scrollContainerRef, className: TABLE_TOKENS.scrollContainer, children: /* @__PURE__ */ jsxs21("table", { className: TABLE_TOKENS.table, children: [
11567
- /* @__PURE__ */ jsx29("thead", { children: /* @__PURE__ */ jsxs21("tr", { className: TABLE_TOKENS.headerRow, children: [
11568
- showCheckbox && /* @__PURE__ */ jsx29(
11629
+ return /* @__PURE__ */ jsx30(TooltipProvider, { children: /* @__PURE__ */ jsxs21("div", { className: cn(TABLE_TOKENS.wrapper, !showBorder && "border-0", className), children: [
11630
+ /* @__PURE__ */ jsx30("div", { ref: scrollContainerRef, className: TABLE_TOKENS.scrollContainer, children: /* @__PURE__ */ jsxs21("table", { className: TABLE_TOKENS.table, children: [
11631
+ /* @__PURE__ */ jsx30("thead", { children: /* @__PURE__ */ jsxs21("tr", { className: TABLE_TOKENS.headerRow, children: [
11632
+ showCheckbox && /* @__PURE__ */ jsx30(
11569
11633
  "th",
11570
11634
  {
11571
11635
  className: cn(
@@ -11581,7 +11645,7 @@ function DataTable({
11581
11645
  const isPinned = pinnedColumns.includes(col.key);
11582
11646
  const isLastPinned = col.key === lastPinnedKey;
11583
11647
  const isSorted = (sortState == null ? void 0 : sortState.key) === col.key;
11584
- return /* @__PURE__ */ jsx29(
11648
+ return /* @__PURE__ */ jsx30(
11585
11649
  "th",
11586
11650
  {
11587
11651
  className: cn(
@@ -11599,14 +11663,14 @@ function DataTable({
11599
11663
  onClick: col.isSortable ? () => handleSortClick(col.key) : void 0,
11600
11664
  children: /* @__PURE__ */ jsxs21("span", { className: "inline-flex items-center", children: [
11601
11665
  col.header,
11602
- col.isSortable && /* @__PURE__ */ jsx29(
11666
+ col.isSortable && /* @__PURE__ */ jsx30(
11603
11667
  "span",
11604
11668
  {
11605
11669
  className: cn(
11606
11670
  TABLE_TOKENS.sortIconWrapper,
11607
11671
  isSorted && TABLE_TOKENS.sortIconActive
11608
11672
  ),
11609
- children: !isSorted ? /* @__PURE__ */ jsx29(ChevronsUpDown, { className: "h-3.5 w-3.5" }) : (sortState == null ? void 0 : sortState.direction) === "asc" ? /* @__PURE__ */ jsx29(ChevronUp, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ jsx29(ChevronDown4, { className: "h-3.5 w-3.5" })
11673
+ children: !isSorted ? /* @__PURE__ */ jsx30(ChevronsUpDown, { className: "h-3.5 w-3.5" }) : (sortState == null ? void 0 : sortState.direction) === "asc" ? /* @__PURE__ */ jsx30(ChevronUp, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ jsx30(ChevronDown4, { className: "h-3.5 w-3.5" })
11610
11674
  }
11611
11675
  )
11612
11676
  ] })
@@ -11616,20 +11680,20 @@ function DataTable({
11616
11680
  }) : (
11617
11681
  // Skeleton headers when columns is empty
11618
11682
  Array.from({ length: skeletonColumnCount }).map(
11619
- (_2, colIndex) => /* @__PURE__ */ jsx29(
11683
+ (_2, colIndex) => /* @__PURE__ */ jsx30(
11620
11684
  "th",
11621
11685
  {
11622
11686
  className: cn(
11623
11687
  TABLE_TOKENS.headerCell,
11624
11688
  stickyHeader && TABLE_TOKENS.headerCellStickyTop
11625
11689
  ),
11626
- children: /* @__PURE__ */ jsx29("div", { className: "h-4 w-20 rounded bg-token-grey animate-pulse" })
11690
+ children: /* @__PURE__ */ jsx30("div", { className: "h-4 w-20 rounded bg-token-grey animate-pulse" })
11627
11691
  },
11628
11692
  `skeleton-header-${colIndex}`
11629
11693
  )
11630
11694
  )
11631
11695
  ),
11632
- hasActions && /* @__PURE__ */ jsx29(
11696
+ hasActions && /* @__PURE__ */ jsx30(
11633
11697
  "th",
11634
11698
  {
11635
11699
  className: cn(
@@ -11639,7 +11703,7 @@ function DataTable({
11639
11703
  style: { width: ACTIONS_COLUMN_WIDTH }
11640
11704
  }
11641
11705
  ),
11642
- headerAction && /* @__PURE__ */ jsx29(
11706
+ headerAction && /* @__PURE__ */ jsx30(
11643
11707
  "th",
11644
11708
  {
11645
11709
  className: cn(
@@ -11652,18 +11716,18 @@ function DataTable({
11652
11716
  padding: "8px",
11653
11717
  right: 0
11654
11718
  },
11655
- children: /* @__PURE__ */ jsx29("div", { className: "flex items-center justify-center h-full w-full", children: headerAction })
11719
+ children: /* @__PURE__ */ jsx30("div", { className: "flex items-center justify-center h-full w-full", children: headerAction })
11656
11720
  }
11657
11721
  )
11658
11722
  ] }) }),
11659
- /* @__PURE__ */ jsx29("tbody", { children: loading ? (
11723
+ /* @__PURE__ */ jsx30("tbody", { children: loading ? (
11660
11724
  // Skeleton loading rows
11661
11725
  Array.from({ length: skeletonRowCount }).map((_2, rowIndex) => /* @__PURE__ */ jsxs21(
11662
11726
  "tr",
11663
11727
  {
11664
11728
  className: cn("group", TABLE_TOKENS.bodyRow),
11665
11729
  children: [
11666
- showCheckbox && /* @__PURE__ */ jsx29(
11730
+ showCheckbox && /* @__PURE__ */ jsx30(
11667
11731
  "td",
11668
11732
  {
11669
11733
  className: cn(
@@ -11672,13 +11736,13 @@ function DataTable({
11672
11736
  checkboxIsLastPinned && TABLE_TOKENS.pinnedLastBorder
11673
11737
  ),
11674
11738
  style: { left: 0, width: CHECKBOX_COLUMN_WIDTH },
11675
- children: /* @__PURE__ */ jsx29("div", { className: "h-4 w-4 rounded bg-token-grey animate-pulse" })
11739
+ children: /* @__PURE__ */ jsx30("div", { className: "h-4 w-4 rounded bg-token-grey animate-pulse" })
11676
11740
  }
11677
11741
  ),
11678
11742
  columns.length > 0 ? orderedColumns.map((col, colIndex) => {
11679
11743
  const isPinned = pinnedColumns.includes(col.key);
11680
11744
  const isLastPinned = col.key === lastPinnedKey;
11681
- return /* @__PURE__ */ jsx29(
11745
+ return /* @__PURE__ */ jsx30(
11682
11746
  "td",
11683
11747
  {
11684
11748
  className: cn(
@@ -11690,21 +11754,21 @@ function DataTable({
11690
11754
  left: stickyOffsets[col.key],
11691
11755
  width: getColumnWidthPx(col.width)
11692
11756
  } : col.width ? { width: getColumnWidthPx(col.width) } : void 0,
11693
- children: /* @__PURE__ */ jsx29("div", { className: "h-4 w-3/4 rounded bg-token-grey animate-pulse" })
11757
+ children: /* @__PURE__ */ jsx30("div", { className: "h-4 w-3/4 rounded bg-token-grey animate-pulse" })
11694
11758
  },
11695
11759
  `skeleton-col-${col.key}`
11696
11760
  );
11697
11761
  }) : Array.from({ length: skeletonColumnCount }).map(
11698
- (_3, colIndex) => /* @__PURE__ */ jsx29(
11762
+ (_3, colIndex) => /* @__PURE__ */ jsx30(
11699
11763
  "td",
11700
11764
  {
11701
11765
  className: TABLE_TOKENS.bodyCell,
11702
- children: /* @__PURE__ */ jsx29("div", { className: "h-4 w-3/4 rounded bg-token-grey animate-pulse" })
11766
+ children: /* @__PURE__ */ jsx30("div", { className: "h-4 w-3/4 rounded bg-token-grey animate-pulse" })
11703
11767
  },
11704
11768
  `skeleton-col-${colIndex}`
11705
11769
  )
11706
11770
  ),
11707
- hasActions && /* @__PURE__ */ jsx29(
11771
+ hasActions && /* @__PURE__ */ jsx30(
11708
11772
  "td",
11709
11773
  {
11710
11774
  className: cn(
@@ -11712,7 +11776,7 @@ function DataTable({
11712
11776
  TABLE_TOKENS.actionsCell
11713
11777
  ),
11714
11778
  style: { width: ACTIONS_COLUMN_WIDTH },
11715
- children: /* @__PURE__ */ jsx29("div", { className: "flex items-center gap-1 justify-end", children: /* @__PURE__ */ jsx29("div", { className: "h-6 w-6 rounded bg-token-grey animate-pulse" }) })
11779
+ children: /* @__PURE__ */ jsx30("div", { className: "flex items-center gap-1 justify-end", children: /* @__PURE__ */ jsx30("div", { className: "h-6 w-6 rounded bg-token-grey animate-pulse" }) })
11716
11780
  }
11717
11781
  )
11718
11782
  ]
@@ -11736,7 +11800,7 @@ function DataTable({
11736
11800
  "data-selected": isSelected ? "true" : void 0,
11737
11801
  onClick: onRowClick ? () => onRowClick(row) : void 0,
11738
11802
  children: [
11739
- showCheckbox && /* @__PURE__ */ jsx29(
11803
+ showCheckbox && /* @__PURE__ */ jsx30(
11740
11804
  "td",
11741
11805
  {
11742
11806
  className: cn(
@@ -11746,7 +11810,7 @@ function DataTable({
11746
11810
  checkboxIsLastPinned && TABLE_TOKENS.pinnedLastBorder
11747
11811
  ),
11748
11812
  style: { left: 0, width: CHECKBOX_COLUMN_WIDTH },
11749
- children: /* @__PURE__ */ jsx29("div", { onClick: (e) => e.stopPropagation(), children: /* @__PURE__ */ jsx29(
11813
+ children: /* @__PURE__ */ jsx30("div", { onClick: (e) => e.stopPropagation(), children: /* @__PURE__ */ jsx30(
11750
11814
  Checkbox,
11751
11815
  {
11752
11816
  checked: isSelected,
@@ -11760,7 +11824,7 @@ function DataTable({
11760
11824
  const isPinned = pinnedColumns.includes(col.key);
11761
11825
  const isLastPinned = col.key === lastPinnedKey;
11762
11826
  const content = col.accessor(row);
11763
- return /* @__PURE__ */ jsx29(
11827
+ return /* @__PURE__ */ jsx30(
11764
11828
  "td",
11765
11829
  {
11766
11830
  className: cn(
@@ -11772,12 +11836,12 @@ function DataTable({
11772
11836
  left: stickyOffsets[col.key],
11773
11837
  width: getColumnWidthPx(col.width)
11774
11838
  } : col.width ? { width: getColumnWidthPx(col.width) } : void 0,
11775
- children: /* @__PURE__ */ jsx29("div", { className: "flex items-center", children: renderCellContent(content) })
11839
+ children: /* @__PURE__ */ jsx30("div", { className: "flex items-center", children: renderCellContent(content) })
11776
11840
  },
11777
11841
  col.key
11778
11842
  );
11779
11843
  }),
11780
- hasActions && /* @__PURE__ */ jsx29(
11844
+ hasActions && /* @__PURE__ */ jsx30(
11781
11845
  "td",
11782
11846
  {
11783
11847
  className: cn(
@@ -11785,8 +11849,8 @@ function DataTable({
11785
11849
  TABLE_TOKENS.actionsCell
11786
11850
  ),
11787
11851
  style: { width: ACTIONS_COLUMN_WIDTH },
11788
- children: /* @__PURE__ */ jsx29("div", { className: "flex items-center gap-1 justify-end", children: actions.map((action, actionIndex) => /* @__PURE__ */ jsxs21(Tooltip, { delayDuration: 0, children: [
11789
- /* @__PURE__ */ jsx29(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx29("div", { onClick: (e) => e.stopPropagation(), children: /* @__PURE__ */ jsx29(
11852
+ children: /* @__PURE__ */ jsx30("div", { className: "flex items-center gap-1 justify-end", children: actions.map((action, actionIndex) => /* @__PURE__ */ jsxs21(Tooltip, { delayDuration: 0, children: [
11853
+ /* @__PURE__ */ jsx30(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx30("div", { onClick: (e) => e.stopPropagation(), children: /* @__PURE__ */ jsx30(
11790
11854
  Button,
11791
11855
  {
11792
11856
  variant: "link",
@@ -11796,7 +11860,7 @@ function DataTable({
11796
11860
  children: action.icon
11797
11861
  }
11798
11862
  ) }) }),
11799
- /* @__PURE__ */ jsx29(TooltipContent, { children: /* @__PURE__ */ jsx29("p", { children: action.label }) })
11863
+ /* @__PURE__ */ jsx30(TooltipContent, { children: /* @__PURE__ */ jsx30("p", { children: action.label }) })
11800
11864
  ] }, actionIndex)) })
11801
11865
  }
11802
11866
  )
@@ -11805,12 +11869,12 @@ function DataTable({
11805
11869
  id
11806
11870
  );
11807
11871
  }),
11808
- data.length === 0 && /* @__PURE__ */ jsx29("tr", { children: /* @__PURE__ */ jsx29(
11872
+ data.length === 0 && /* @__PURE__ */ jsx30("tr", { children: /* @__PURE__ */ jsx30(
11809
11873
  "td",
11810
11874
  {
11811
11875
  colSpan: orderedColumns.length + (hasActions ? 1 : 0) + (showCheckbox ? 1 : 0),
11812
11876
  className: "p-0",
11813
- children: /* @__PURE__ */ jsx29(
11877
+ children: /* @__PURE__ */ jsx30(
11814
11878
  "div",
11815
11879
  {
11816
11880
  className: "sticky left-0 px-4 py-8 text-center text-sm text-fg-grey-secondary",
@@ -11823,7 +11887,7 @@ function DataTable({
11823
11887
  ] })
11824
11888
  ) })
11825
11889
  ] }) }),
11826
- showPagination && !loading && data.length > 0 && onPageChange && onRowsPerPageChange && /* @__PURE__ */ jsx29("div", { className: cn(TABLE_TOKENS.pagination, !showBorder && "border-t-0"), children: /* @__PURE__ */ jsx29(
11890
+ showPagination && !loading && data.length > 0 && onPageChange && onRowsPerPageChange && /* @__PURE__ */ jsx30("div", { className: cn(TABLE_TOKENS.pagination, !showBorder && "border-t-0"), children: /* @__PURE__ */ jsx30(
11827
11891
  Pagination,
11828
11892
  {
11829
11893
  handlePageChange: onPageChange,
@@ -11850,7 +11914,7 @@ var ColumnWidth = /* @__PURE__ */ ((ColumnWidth2) => {
11850
11914
  })(ColumnWidth || {});
11851
11915
 
11852
11916
  // src/filter-select/filter-select.tsx
11853
- import * as React36 from "react";
11917
+ import * as React37 from "react";
11854
11918
  import * as DropdownMenuPrimitive3 from "@radix-ui/react-dropdown-menu";
11855
11919
  import {
11856
11920
  Check as Check6,
@@ -11912,12 +11976,15 @@ var FILTER_SELECT_TOKENS = {
11912
11976
  dropdown: {
11913
11977
  base: [
11914
11978
  "bg-token-white flex flex-col items-stretch",
11915
- "pt-1 pb-2 px-1 rounded-[16px] shadow-sm",
11979
+ // Symmetric 4px padding on all sides — prevents the extra whitespace
11980
+ // below the last list item / footer that used to come from `pb-2`.
11981
+ "p-1 rounded-[16px] shadow-sm",
11916
11982
  "min-w-[196px] font-sans",
11917
11983
  "outline-none"
11918
11984
  ].join(" "),
11919
- // Date dropdown: Figma p-12, gap-16, rounded-16
11920
- date: "p-3 gap-4 rounded-[16px]"
11985
+ // Date dropdown tight 4px padding on all sides so the calendar / presets
11986
+ // sit flush against the 16px corner radius with no extra whitespace gutter.
11987
+ date: "p-1 gap-2 rounded-[16px]"
11921
11988
  },
11922
11989
  // ---------- List item (.menu - secondary) ----------
11923
11990
  // Figma 4085:5931 exact spec:
@@ -12009,7 +12076,22 @@ var FILTER_SELECT_TOKENS = {
12009
12076
  // ---------- Empty state ----------
12010
12077
  emptyState: "px-3 py-4 font-sans text-xs leading-4 text-fg-grey-secondary text-center w-full",
12011
12078
  // ---------- Date presets (left sidebar) ----------
12012
- datePresetSidebar: "flex flex-col gap-1 shrink-0 w-[116px] min-h-full",
12079
+ // `gap-0` on the outer column so the preset list and the bottom Remove/Clear
12080
+ // button own their own spacing — avoids a double-gap between the last preset
12081
+ // and the bottom action.
12082
+ datePresetSidebar: "flex flex-col shrink-0 w-[116px] min-h-full",
12083
+ // Bottom action (Remove/Clear) for the date filter. Lives INSIDE the preset
12084
+ // column so it only occupies the sidebar width, not the whole dropdown. No
12085
+ // sticky / no border-t / no rounded-b — those were artefacts of the old
12086
+ // full-width footer. Pinned to the BOTTOM of the sidebar via `mt-auto` so
12087
+ // the action row aligns with the calendar's bottom edge — no extra
12088
+ // whitespace opens between Remove and the dropdown's rounded corner.
12089
+ datePresetSidebarAction: {
12090
+ wrapper: "group/remove mt-auto w-full rounded-[8px] transition-colors hover:bg-interaction-hov-solid-primary",
12091
+ button: "flex items-center gap-2 w-full p-2 rounded-[8px] cursor-pointer outline-none bg-transparent",
12092
+ icon: "shrink-0 size-4 text-fg-black transition-colors group-hover/remove:text-fg-destructive",
12093
+ text: "font-sans font-normal text-xs leading-4 tracking-normal whitespace-nowrap text-fg-black transition-colors group-hover/remove:text-fg-destructive"
12094
+ },
12013
12095
  datePreset: {
12014
12096
  base: "w-full text-left px-2.5 py-2 rounded-full font-sans text-xs font-medium leading-4 cursor-pointer transition-colors border border-transparent outline-none",
12015
12097
  default: "text-fg-grey-secondary hover:bg-interaction-hov-solid-primary",
@@ -12145,11 +12227,11 @@ var FILTER_SELECT_TOKENS = {
12145
12227
  };
12146
12228
 
12147
12229
  // src/filter-select/filter-list-item.tsx
12148
- import * as React35 from "react";
12230
+ import * as React36 from "react";
12149
12231
  import { Check as Check5, GripHorizontal } from "lucide-react";
12150
12232
 
12151
12233
  // src/spinner/spinner.tsx
12152
- import * as React34 from "react";
12234
+ import * as React35 from "react";
12153
12235
  import { Loader2 } from "lucide-react";
12154
12236
 
12155
12237
  // src/spinner/variables.ts
@@ -12170,10 +12252,10 @@ var SPINNER_TOKENS = {
12170
12252
  };
12171
12253
 
12172
12254
  // src/spinner/spinner.tsx
12173
- import { jsx as jsx30 } from "react/jsx-runtime";
12174
- var Spinner = React34.forwardRef(
12255
+ import { jsx as jsx31 } from "react/jsx-runtime";
12256
+ var Spinner = React35.forwardRef(
12175
12257
  ({ size = "md", className, ...props }, ref) => {
12176
- return /* @__PURE__ */ jsx30("div", { ref, className: cn(SPINNER_TOKENS.base, className), ...props, children: /* @__PURE__ */ jsx30(
12258
+ return /* @__PURE__ */ jsx31("div", { ref, className: cn(SPINNER_TOKENS.base, className), ...props, children: /* @__PURE__ */ jsx31(
12177
12259
  Loader2,
12178
12260
  {
12179
12261
  className: cn(SPINNER_TOKENS.size[size], SPINNER_TOKENS.icon),
@@ -12185,8 +12267,8 @@ var Spinner = React34.forwardRef(
12185
12267
  Spinner.displayName = "Spinner";
12186
12268
 
12187
12269
  // src/filter-select/filter-list-item.tsx
12188
- import { jsx as jsx31, jsxs as jsxs22 } from "react/jsx-runtime";
12189
- var FilterListItem = React35.forwardRef(
12270
+ import { jsx as jsx32, jsxs as jsxs22 } from "react/jsx-runtime";
12271
+ var FilterListItem = React36.forwardRef(
12190
12272
  ({
12191
12273
  value,
12192
12274
  label,
@@ -12207,18 +12289,18 @@ var FilterListItem = React35.forwardRef(
12207
12289
  className,
12208
12290
  ...props
12209
12291
  }, ref) => {
12210
- const handleClick = React35.useCallback(() => {
12292
+ const handleClick = React36.useCallback(() => {
12211
12293
  if (loading) return;
12212
12294
  onSelect == null ? void 0 : onSelect(value);
12213
12295
  }, [loading, onSelect, value]);
12214
- const handleDragStart = React35.useCallback(
12296
+ const handleDragStart = React36.useCallback(
12215
12297
  (e) => {
12216
12298
  e.dataTransfer.effectAllowed = "move";
12217
12299
  onDragStart == null ? void 0 : onDragStart(e);
12218
12300
  },
12219
12301
  [onDragStart]
12220
12302
  );
12221
- const handleDragOver = React35.useCallback(
12303
+ const handleDragOver = React36.useCallback(
12222
12304
  (e) => {
12223
12305
  e.preventDefault();
12224
12306
  e.dataTransfer.dropEffect = "move";
@@ -12226,33 +12308,33 @@ var FilterListItem = React35.forwardRef(
12226
12308
  },
12227
12309
  [onDragOver]
12228
12310
  );
12229
- const handleDragLeave = React35.useCallback(
12311
+ const handleDragLeave = React36.useCallback(
12230
12312
  (e) => {
12231
12313
  onDragLeave == null ? void 0 : onDragLeave(e);
12232
12314
  },
12233
12315
  [onDragLeave]
12234
12316
  );
12235
- const handleDrop = React35.useCallback(
12317
+ const handleDrop = React36.useCallback(
12236
12318
  (e) => {
12237
12319
  e.preventDefault();
12238
12320
  onDrop == null ? void 0 : onDrop(e);
12239
12321
  },
12240
12322
  [onDrop]
12241
12323
  );
12242
- const handleDragEnd = React35.useCallback(
12324
+ const handleDragEnd = React36.useCallback(
12243
12325
  (e) => {
12244
12326
  onDragEnd == null ? void 0 : onDragEnd(e);
12245
12327
  },
12246
12328
  [onDragEnd]
12247
12329
  );
12248
- const handleGripClick = React35.useCallback((e) => {
12330
+ const handleGripClick = React36.useCallback((e) => {
12249
12331
  e.stopPropagation();
12250
12332
  }, []);
12251
12333
  const renderIcon2 = () => {
12252
12334
  if (!icon) return null;
12253
- if (React35.isValidElement(icon)) return icon;
12335
+ if (React36.isValidElement(icon)) return icon;
12254
12336
  if (typeof icon === "function" || typeof icon === "object" && icon !== null && "$$typeof" in icon) {
12255
- return React35.createElement(
12337
+ return React36.createElement(
12256
12338
  icon,
12257
12339
  { className: "size-4" }
12258
12340
  );
@@ -12286,22 +12368,22 @@ var FilterListItem = React35.forwardRef(
12286
12368
  ...props,
12287
12369
  children: [
12288
12370
  /* @__PURE__ */ jsxs22("div", { className: "flex items-center gap-2 min-w-0 flex-1", children: [
12289
- draggable && /* @__PURE__ */ jsx31(
12371
+ draggable && /* @__PURE__ */ jsx32(
12290
12372
  "span",
12291
12373
  {
12292
12374
  className: FILTER_SELECT_TOKENS.dragHandle,
12293
12375
  onClick: handleGripClick,
12294
12376
  "aria-hidden": "true",
12295
- children: /* @__PURE__ */ jsx31(GripHorizontal, { className: "size-4" })
12377
+ children: /* @__PURE__ */ jsx32(GripHorizontal, { className: "size-4" })
12296
12378
  }
12297
12379
  ),
12298
- icon && /* @__PURE__ */ jsx31("span", { className: "shrink-0 flex items-center justify-center text-fg-grey-secondary", children: renderIcon2() }),
12380
+ icon && /* @__PURE__ */ jsx32("span", { className: "shrink-0 flex items-center justify-center text-fg-grey-secondary", children: renderIcon2() }),
12299
12381
  /* @__PURE__ */ jsxs22("div", { className: "flex flex-col min-w-0 flex-1 gap-[2px]", children: [
12300
- labelNode ? /* @__PURE__ */ jsx31("span", { className: "min-w-0", children: labelNode }) : /* @__PURE__ */ jsx31("p", { className: FILTER_SELECT_TOKENS.itemLabel, children: label }),
12301
- subtext && /* @__PURE__ */ jsx31("p", { className: FILTER_SELECT_TOKENS.itemSubtext, children: subtext })
12382
+ labelNode ? /* @__PURE__ */ jsx32("span", { className: "min-w-0", children: labelNode }) : /* @__PURE__ */ jsx32("p", { className: FILTER_SELECT_TOKENS.itemLabel, children: label }),
12383
+ subtext && /* @__PURE__ */ jsx32("p", { className: FILTER_SELECT_TOKENS.itemSubtext, children: subtext })
12302
12384
  ] })
12303
12385
  ] }),
12304
- /* @__PURE__ */ jsx31("span", { className: "shrink-0 flex items-center justify-end w-4", children: loading ? /* @__PURE__ */ jsx31(Spinner, { size: "sm" }) : selected ? /* @__PURE__ */ jsx31(Check5, { className: FILTER_SELECT_TOKENS.itemTick, "aria-hidden": "true" }) : null })
12386
+ /* @__PURE__ */ jsx32("span", { className: "shrink-0 flex items-center justify-end w-4", children: loading ? /* @__PURE__ */ jsx32(Spinner, { size: "sm" }) : selected ? /* @__PURE__ */ jsx32(Check5, { className: FILTER_SELECT_TOKENS.itemTick, "aria-hidden": "true" }) : null })
12305
12387
  ]
12306
12388
  }
12307
12389
  );
@@ -12310,7 +12392,7 @@ var FilterListItem = React35.forwardRef(
12310
12392
  FilterListItem.displayName = "FilterListItem";
12311
12393
 
12312
12394
  // src/filter-select/filter-select.tsx
12313
- import { Fragment as Fragment11, jsx as jsx32, jsxs as jsxs23 } from "react/jsx-runtime";
12395
+ import { Fragment as Fragment11, jsx as jsx33, jsxs as jsxs23 } from "react/jsx-runtime";
12314
12396
  function startOfDay(d) {
12315
12397
  const x = new Date(d);
12316
12398
  x.setHours(0, 0, 0, 0);
@@ -12430,11 +12512,11 @@ var OperandDropdown = ({
12430
12512
  disabled
12431
12513
  }) => {
12432
12514
  var _a5, _b5;
12433
- const [open, setOpen] = React36.useState(false);
12515
+ const [open, setOpen] = React37.useState(false);
12434
12516
  const selectedLabel = (_b5 = (_a5 = options.find((o) => o.value === value)) == null ? void 0 : _a5.label) != null ? _b5 : "";
12435
12517
  const hasValue = Boolean(value);
12436
12518
  return /* @__PURE__ */ jsxs23(DropdownMenuPrimitive3.Root, { open, onOpenChange: setOpen, children: [
12437
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12519
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12438
12520
  "button",
12439
12521
  {
12440
12522
  type: "button",
@@ -12451,7 +12533,7 @@ var OperandDropdown = ({
12451
12533
  ),
12452
12534
  "aria-label": placeholder || "Select operand",
12453
12535
  children: [
12454
- /* @__PURE__ */ jsx32(
12536
+ /* @__PURE__ */ jsx33(
12455
12537
  "span",
12456
12538
  {
12457
12539
  className: cn(
@@ -12461,7 +12543,7 @@ var OperandDropdown = ({
12461
12543
  children: hasValue ? selectedLabel : placeholder || ""
12462
12544
  }
12463
12545
  ),
12464
- /* @__PURE__ */ jsx32(
12546
+ /* @__PURE__ */ jsx33(
12465
12547
  ChevronDown5,
12466
12548
  {
12467
12549
  className: cn(
@@ -12473,7 +12555,7 @@ var OperandDropdown = ({
12473
12555
  ]
12474
12556
  }
12475
12557
  ) }),
12476
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx32("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx32(
12558
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx33("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx33(
12477
12559
  DropdownMenuPrimitive3.Content,
12478
12560
  {
12479
12561
  className: cn(FILTER_SELECT_TOKENS.operand.content, "z-[250]"),
@@ -12495,8 +12577,8 @@ var OperandDropdown = ({
12495
12577
  "data-state": isSelected ? "checked" : "unchecked",
12496
12578
  className: FILTER_SELECT_TOKENS.operand.item,
12497
12579
  children: [
12498
- /* @__PURE__ */ jsx32("span", { className: "truncate", children: opt.label }),
12499
- /* @__PURE__ */ jsx32("span", { className: "shrink-0 flex items-center justify-end w-4", children: isSelected && /* @__PURE__ */ jsx32(
12580
+ /* @__PURE__ */ jsx33("span", { className: "truncate", children: opt.label }),
12581
+ /* @__PURE__ */ jsx33("span", { className: "shrink-0 flex items-center justify-end w-4", children: isSelected && /* @__PURE__ */ jsx33(
12500
12582
  Check6,
12501
12583
  {
12502
12584
  className: FILTER_SELECT_TOKENS.operand.itemTick,
@@ -12534,12 +12616,12 @@ var TimeSelectPill = ({
12534
12616
  container,
12535
12617
  themeClass
12536
12618
  }) => {
12537
- const [open, setOpen] = React36.useState(false);
12538
- const selectedRef = React36.useRef(null);
12619
+ const [open, setOpen] = React37.useState(false);
12620
+ const selectedRef = React37.useRef(null);
12539
12621
  const currentHour = value.getHours();
12540
12622
  const currentMinute = value.getMinutes();
12541
12623
  const selectedSlotIndex = currentHour * 2 + (currentMinute >= 30 ? 1 : 0);
12542
- React36.useEffect(() => {
12624
+ React37.useEffect(() => {
12543
12625
  if (!open) return;
12544
12626
  const id = window.setTimeout(() => {
12545
12627
  var _a5;
@@ -12554,19 +12636,19 @@ var TimeSelectPill = ({
12554
12636
  setOpen(false);
12555
12637
  };
12556
12638
  return /* @__PURE__ */ jsxs23(DropdownMenuPrimitive3.Root, { open, onOpenChange: setOpen, children: [
12557
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12639
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12558
12640
  "button",
12559
12641
  {
12560
12642
  type: "button",
12561
12643
  className: FILTER_SELECT_TOKENS.timeSelectPill.trigger,
12562
12644
  "aria-label": ariaLabel,
12563
12645
  children: [
12564
- /* @__PURE__ */ jsx32("span", { className: "truncate", children: formatTime12h(value) }),
12565
- /* @__PURE__ */ jsx32(ChevronDown5, { className: FILTER_SELECT_TOKENS.timeSelectPill.chevron })
12646
+ /* @__PURE__ */ jsx33("span", { className: "truncate", children: formatTime12h(value) }),
12647
+ /* @__PURE__ */ jsx33(ChevronDown5, { className: FILTER_SELECT_TOKENS.timeSelectPill.chevron })
12566
12648
  ]
12567
12649
  }
12568
12650
  ) }),
12569
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx32("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx32(
12651
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx33("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx33(
12570
12652
  DropdownMenuPrimitive3.Content,
12571
12653
  {
12572
12654
  className: cn(FILTER_SELECT_TOKENS.timeSelectPill.content, "z-[250]"),
@@ -12577,7 +12659,7 @@ var TimeSelectPill = ({
12577
12659
  onCloseAutoFocus: (e) => e.preventDefault(),
12578
12660
  children: TIME_OPTIONS_30M.map((opt, idx) => {
12579
12661
  const isSelected = idx === selectedSlotIndex;
12580
- return /* @__PURE__ */ jsx32(
12662
+ return /* @__PURE__ */ jsx33(
12581
12663
  DropdownMenuPrimitive3.Item,
12582
12664
  {
12583
12665
  ref: isSelected ? selectedRef : void 0,
@@ -12587,7 +12669,7 @@ var TimeSelectPill = ({
12587
12669
  },
12588
12670
  "data-state": isSelected ? "checked" : "unchecked",
12589
12671
  className: FILTER_SELECT_TOKENS.timeSelectPill.item,
12590
- children: /* @__PURE__ */ jsx32("span", { className: "truncate", children: opt.label })
12672
+ children: /* @__PURE__ */ jsx33("span", { className: "truncate", children: opt.label })
12591
12673
  },
12592
12674
  opt.label
12593
12675
  );
@@ -12616,9 +12698,9 @@ var MonthSelectPill = ({
12616
12698
  container,
12617
12699
  themeClass
12618
12700
  }) => {
12619
- const [open, setOpen] = React36.useState(false);
12620
- const selectedRef = React36.useRef(null);
12621
- React36.useEffect(() => {
12701
+ const [open, setOpen] = React37.useState(false);
12702
+ const selectedRef = React37.useRef(null);
12703
+ React37.useEffect(() => {
12622
12704
  if (!open) return;
12623
12705
  const id = window.setTimeout(() => {
12624
12706
  var _a5;
@@ -12627,19 +12709,19 @@ var MonthSelectPill = ({
12627
12709
  return () => window.clearTimeout(id);
12628
12710
  }, [open]);
12629
12711
  return /* @__PURE__ */ jsxs23(DropdownMenuPrimitive3.Root, { open, onOpenChange: setOpen, children: [
12630
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12712
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12631
12713
  "button",
12632
12714
  {
12633
12715
  type: "button",
12634
12716
  className: FILTER_SELECT_TOKENS.timeSelectPill.trigger,
12635
12717
  "aria-label": "Select month",
12636
12718
  children: [
12637
- /* @__PURE__ */ jsx32("span", { className: "truncate", children: MONTH_LABELS[monthIndex] }),
12638
- /* @__PURE__ */ jsx32(ChevronDown5, { className: FILTER_SELECT_TOKENS.timeSelectPill.chevron })
12719
+ /* @__PURE__ */ jsx33("span", { className: "truncate", children: MONTH_LABELS[monthIndex] }),
12720
+ /* @__PURE__ */ jsx33(ChevronDown5, { className: FILTER_SELECT_TOKENS.timeSelectPill.chevron })
12639
12721
  ]
12640
12722
  }
12641
12723
  ) }),
12642
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx32("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx32(
12724
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx33("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx33(
12643
12725
  DropdownMenuPrimitive3.Content,
12644
12726
  {
12645
12727
  className: cn(FILTER_SELECT_TOKENS.timeSelectPill.content, "z-[250]"),
@@ -12650,7 +12732,7 @@ var MonthSelectPill = ({
12650
12732
  onCloseAutoFocus: (e) => e.preventDefault(),
12651
12733
  children: MONTH_LABELS.map((label, idx) => {
12652
12734
  const isSelected = idx === monthIndex;
12653
- return /* @__PURE__ */ jsx32(
12735
+ return /* @__PURE__ */ jsx33(
12654
12736
  DropdownMenuPrimitive3.Item,
12655
12737
  {
12656
12738
  ref: isSelected ? selectedRef : void 0,
@@ -12661,7 +12743,7 @@ var MonthSelectPill = ({
12661
12743
  },
12662
12744
  "data-state": isSelected ? "checked" : "unchecked",
12663
12745
  className: FILTER_SELECT_TOKENS.timeSelectPill.item,
12664
- children: /* @__PURE__ */ jsx32("span", { className: "truncate", children: label })
12746
+ children: /* @__PURE__ */ jsx33("span", { className: "truncate", children: label })
12665
12747
  },
12666
12748
  label
12667
12749
  );
@@ -12678,14 +12760,14 @@ var YearSelectPill = ({
12678
12760
  container,
12679
12761
  themeClass
12680
12762
  }) => {
12681
- const [open, setOpen] = React36.useState(false);
12682
- const selectedRef = React36.useRef(null);
12683
- const years = React36.useMemo(() => {
12763
+ const [open, setOpen] = React37.useState(false);
12764
+ const selectedRef = React37.useRef(null);
12765
+ const years = React37.useMemo(() => {
12684
12766
  const out = [];
12685
12767
  for (let y = minYear; y <= maxYear; y++) out.push(y);
12686
12768
  return out;
12687
12769
  }, [minYear, maxYear]);
12688
- React36.useEffect(() => {
12770
+ React37.useEffect(() => {
12689
12771
  if (!open) return;
12690
12772
  const id = window.setTimeout(() => {
12691
12773
  var _a5;
@@ -12694,19 +12776,19 @@ var YearSelectPill = ({
12694
12776
  return () => window.clearTimeout(id);
12695
12777
  }, [open]);
12696
12778
  return /* @__PURE__ */ jsxs23(DropdownMenuPrimitive3.Root, { open, onOpenChange: setOpen, children: [
12697
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12779
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
12698
12780
  "button",
12699
12781
  {
12700
12782
  type: "button",
12701
12783
  className: FILTER_SELECT_TOKENS.timeSelectPill.trigger,
12702
12784
  "aria-label": "Select year",
12703
12785
  children: [
12704
- /* @__PURE__ */ jsx32("span", { className: "truncate", children: year }),
12705
- /* @__PURE__ */ jsx32(ChevronDown5, { className: FILTER_SELECT_TOKENS.timeSelectPill.chevron })
12786
+ /* @__PURE__ */ jsx33("span", { className: "truncate", children: year }),
12787
+ /* @__PURE__ */ jsx33(ChevronDown5, { className: FILTER_SELECT_TOKENS.timeSelectPill.chevron })
12706
12788
  ]
12707
12789
  }
12708
12790
  ) }),
12709
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx32("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx32(
12791
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx33("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx33(
12710
12792
  DropdownMenuPrimitive3.Content,
12711
12793
  {
12712
12794
  className: cn(FILTER_SELECT_TOKENS.timeSelectPill.content, "z-[250]"),
@@ -12717,7 +12799,7 @@ var YearSelectPill = ({
12717
12799
  onCloseAutoFocus: (e) => e.preventDefault(),
12718
12800
  children: years.map((y) => {
12719
12801
  const isSelected = y === year;
12720
- return /* @__PURE__ */ jsx32(
12802
+ return /* @__PURE__ */ jsx33(
12721
12803
  DropdownMenuPrimitive3.Item,
12722
12804
  {
12723
12805
  ref: isSelected ? selectedRef : void 0,
@@ -12728,7 +12810,7 @@ var YearSelectPill = ({
12728
12810
  },
12729
12811
  "data-state": isSelected ? "checked" : "unchecked",
12730
12812
  className: FILTER_SELECT_TOKENS.timeSelectPill.item,
12731
- children: /* @__PURE__ */ jsx32("span", { className: "truncate", children: y })
12813
+ children: /* @__PURE__ */ jsx33("span", { className: "truncate", children: y })
12732
12814
  },
12733
12815
  y
12734
12816
  );
@@ -12737,15 +12819,15 @@ var YearSelectPill = ({
12737
12819
  ) }) })
12738
12820
  ] });
12739
12821
  };
12740
- var CalendarMonthCaptionContext = React36.createContext(null);
12822
+ var CalendarMonthCaptionContext = React37.createContext(null);
12741
12823
  var CalendarMonthCaption = ({
12742
12824
  calendarMonth,
12743
12825
  displayIndex
12744
12826
  }) => {
12745
12827
  var _a5, _b5;
12746
- const ctx = React36.useContext(CalendarMonthCaptionContext);
12828
+ const ctx = React37.useContext(CalendarMonthCaptionContext);
12747
12829
  const { goToMonth, previousMonth, nextMonth, months } = useDayPicker();
12748
- if (!ctx) return /* @__PURE__ */ jsx32(Fragment11, {});
12830
+ if (!ctx) return /* @__PURE__ */ jsx33(Fragment11, {});
12749
12831
  const { date, onDateChange, container, themeClass, showTime, minYear, maxYear } = ctx;
12750
12832
  const monthDate = calendarMonth.date;
12751
12833
  const monthIndex = monthDate.getMonth();
@@ -12778,7 +12860,7 @@ var CalendarMonthCaption = ({
12778
12860
  }
12779
12861
  };
12780
12862
  return /* @__PURE__ */ jsxs23("div", { className: "flex items-center justify-between gap-1 w-full px-0 py-1", children: [
12781
- isFirst && /* @__PURE__ */ jsx32(
12863
+ isFirst && /* @__PURE__ */ jsx33(
12782
12864
  "button",
12783
12865
  {
12784
12866
  type: "button",
@@ -12786,11 +12868,11 @@ var CalendarMonthCaption = ({
12786
12868
  "aria-label": "Previous month",
12787
12869
  onClick: () => previousMonth && goToMonth(previousMonth),
12788
12870
  disabled: !previousMonth,
12789
- children: /* @__PURE__ */ jsx32(ChevronLeft2, { className: "size-4" })
12871
+ children: /* @__PURE__ */ jsx33(ChevronLeft2, { className: "size-4" })
12790
12872
  }
12791
12873
  ),
12792
- /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-1 flex-1 justify-center", children: [
12793
- /* @__PURE__ */ jsx32(
12874
+ /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-1 flex-1 justify-start", children: [
12875
+ /* @__PURE__ */ jsx33(
12794
12876
  MonthSelectPill,
12795
12877
  {
12796
12878
  monthIndex,
@@ -12799,7 +12881,7 @@ var CalendarMonthCaption = ({
12799
12881
  themeClass
12800
12882
  }
12801
12883
  ),
12802
- /* @__PURE__ */ jsx32(
12884
+ /* @__PURE__ */ jsx33(
12803
12885
  YearSelectPill,
12804
12886
  {
12805
12887
  year,
@@ -12810,7 +12892,7 @@ var CalendarMonthCaption = ({
12810
12892
  themeClass
12811
12893
  }
12812
12894
  ),
12813
- showTime && timeValue && /* @__PURE__ */ jsx32(
12895
+ showTime && timeValue && /* @__PURE__ */ jsx33(
12814
12896
  TimeSelectPill,
12815
12897
  {
12816
12898
  value: timeValue,
@@ -12821,7 +12903,7 @@ var CalendarMonthCaption = ({
12821
12903
  }
12822
12904
  )
12823
12905
  ] }),
12824
- isLast && /* @__PURE__ */ jsx32(
12906
+ isLast && /* @__PURE__ */ jsx33(
12825
12907
  "button",
12826
12908
  {
12827
12909
  type: "button",
@@ -12829,7 +12911,7 @@ var CalendarMonthCaption = ({
12829
12911
  "aria-label": "Next month",
12830
12912
  onClick: () => nextMonth && goToMonth(nextMonth),
12831
12913
  disabled: !nextMonth,
12832
- children: /* @__PURE__ */ jsx32(ChevronRight3, { className: "size-4" })
12914
+ children: /* @__PURE__ */ jsx33(ChevronRight3, { className: "size-4" })
12833
12915
  }
12834
12916
  )
12835
12917
  ] });
@@ -12839,7 +12921,7 @@ var DEFAULT_DURATION_UNITS = [
12839
12921
  { value: "min", label: "min" },
12840
12922
  { value: "hours", label: "hours" }
12841
12923
  ];
12842
- var FilterSelect = React36.forwardRef(
12924
+ var FilterSelect = React37.forwardRef(
12843
12925
  ({
12844
12926
  label = "Language",
12845
12927
  icon: Icon2,
@@ -12884,24 +12966,26 @@ var FilterSelect = React36.forwardRef(
12884
12966
  showTime = true,
12885
12967
  emptyStateLabel,
12886
12968
  labelClassName,
12969
+ isPersistent = false,
12887
12970
  ...props
12888
12971
  }, ref) => {
12972
+ const footerActionLabel = isPersistent ? "Clear" : "Remove";
12889
12973
  const { theme } = useTheme();
12890
12974
  const themeClass = theme === "dark" ? "dark" : "light";
12891
- const [internalOpen, setInternalOpen] = React36.useState(
12975
+ const [internalOpen, setInternalOpen] = React37.useState(
12892
12976
  defaultOpen != null ? defaultOpen : false
12893
12977
  );
12894
12978
  const open = controlledOpen != null ? controlledOpen : internalOpen;
12895
- const [searchQuery, setSearchQuery] = React36.useState("");
12896
- const triggerRef = React36.useRef(null);
12897
- const [triggerWidth, setTriggerWidth] = React36.useState(null);
12898
- const [focusedMonth, setFocusedMonth] = React36.useState(
12979
+ const [searchQuery, setSearchQuery] = React37.useState("");
12980
+ const triggerRef = React37.useRef(null);
12981
+ const [triggerWidth, setTriggerWidth] = React37.useState(null);
12982
+ const [focusedMonth, setFocusedMonth] = React37.useState(
12899
12983
  () => {
12900
12984
  var _a5;
12901
12985
  return (_a5 = date == null ? void 0 : date.start) != null ? _a5 : /* @__PURE__ */ new Date();
12902
12986
  }
12903
12987
  );
12904
- const setOpen = React36.useCallback(
12988
+ const setOpen = React37.useCallback(
12905
12989
  (newOpen) => {
12906
12990
  if (controlledOpen === void 0) {
12907
12991
  setInternalOpen(newOpen);
@@ -12910,25 +12994,25 @@ var FilterSelect = React36.forwardRef(
12910
12994
  },
12911
12995
  [controlledOpen, onOpenChange]
12912
12996
  );
12913
- const container = React36.useMemo(
12997
+ const container = React37.useMemo(
12914
12998
  () => {
12915
12999
  var _a5;
12916
13000
  return typeof document !== "undefined" ? (_a5 = document.querySelector(".lego-land")) != null ? _a5 : void 0 : void 0;
12917
13001
  },
12918
13002
  []
12919
13003
  );
12920
- const selectedItemsOrdered = React36.useMemo(() => {
13004
+ const selectedItemsOrdered = React37.useMemo(() => {
12921
13005
  if (!selectedItems.length) return [];
12922
13006
  return selectedItems;
12923
13007
  }, [selectedItems]);
12924
- const filteredItems = React36.useMemo(() => {
13008
+ const filteredItems = React37.useMemo(() => {
12925
13009
  return filterItemsBySearch2(items, searchQuery);
12926
13010
  }, [items, searchQuery]);
12927
- const isSectioned = React36.useMemo(
13011
+ const isSectioned = React37.useMemo(
12928
13012
  () => filteredItems.length > 0 && "sectionLabel" in filteredItems[0],
12929
13013
  [filteredItems]
12930
13014
  );
12931
- const sortedItems = React36.useMemo(() => {
13015
+ const sortedItems = React37.useMemo(() => {
12932
13016
  if (!draggable || !isSectioned) {
12933
13017
  if (!draggable) return filteredItems;
12934
13018
  const flatItems = filteredItems;
@@ -12961,7 +13045,7 @@ var FilterSelect = React36.forwardRef(
12961
13045
  return { ...section, items: sorted };
12962
13046
  });
12963
13047
  }, [filteredItems, selectedItemsOrdered, draggable, isSectioned]);
12964
- const selectedLabels = React36.useMemo(() => {
13048
+ const selectedLabels = React37.useMemo(() => {
12965
13049
  const itemMap = /* @__PURE__ */ new Map();
12966
13050
  const isSectionedItems = items.length > 0 && "sectionLabel" in items[0];
12967
13051
  if (isSectionedItems) {
@@ -12982,7 +13066,7 @@ var FilterSelect = React36.forwardRef(
12982
13066
  }
12983
13067
  );
12984
13068
  }, [selectedItemsOrdered, items]);
12985
- const selectedItemsText = React36.useMemo(() => {
13069
+ const selectedItemsText = React37.useMemo(() => {
12986
13070
  var _a5, _b5, _c, _d, _e2, _f;
12987
13071
  let trimmedText = text == null ? void 0 : text.trim();
12988
13072
  if (type === "text_with_operands" && trimmedText && trimmedText.length > 0) {
@@ -13037,10 +13121,10 @@ var FilterSelect = React36.forwardRef(
13037
13121
  durationUnits
13038
13122
  ]);
13039
13123
  const hasValue = Boolean(selectedItemsText);
13040
- const [visibleItemsCount, setVisibleItemsCount] = React36.useState(null);
13041
- const selectedItemsRef = React36.useRef(null);
13042
- const measureRef = React36.useRef(null);
13043
- React36.useEffect(() => {
13124
+ const [visibleItemsCount, setVisibleItemsCount] = React37.useState(null);
13125
+ const selectedItemsRef = React37.useRef(null);
13126
+ const measureRef = React37.useRef(null);
13127
+ React37.useEffect(() => {
13044
13128
  if (type !== "list" || selectedLabels.length === 0) {
13045
13129
  setVisibleItemsCount(null);
13046
13130
  return;
@@ -13112,7 +13196,7 @@ var FilterSelect = React36.forwardRef(
13112
13196
  ro.observe(containerEl);
13113
13197
  return () => ro.disconnect();
13114
13198
  }, [type, selectedLabels, selectedItemsMaxWidth, selectedItemsText]);
13115
- React36.useEffect(() => {
13199
+ React37.useEffect(() => {
13116
13200
  const el = triggerRef.current;
13117
13201
  if (!el) return;
13118
13202
  const m = () => setTriggerWidth(el.offsetWidth);
@@ -13121,27 +13205,27 @@ var FilterSelect = React36.forwardRef(
13121
13205
  ro.observe(el);
13122
13206
  return () => ro.disconnect();
13123
13207
  }, [open, selectedItemsText]);
13124
- const handleItemSelect = React36.useCallback(
13208
+ const handleItemSelect = React37.useCallback(
13125
13209
  (value) => {
13126
13210
  const newSelection = selectedItems.includes(value) ? selectedItems.filter((v2) => v2 !== value) : [...selectedItems, value];
13127
13211
  onSelectionChange == null ? void 0 : onSelectionChange(newSelection);
13128
13212
  },
13129
13213
  [selectedItems, onSelectionChange]
13130
13214
  );
13131
- const handleClearAll = React36.useCallback(() => {
13215
+ const handleClearAll = React37.useCallback(() => {
13132
13216
  onSelectionChange == null ? void 0 : onSelectionChange([]);
13133
13217
  onRemoveAll == null ? void 0 : onRemoveAll();
13134
13218
  }, [onSelectionChange, onRemoveAll]);
13135
- const handleTextClear = React36.useCallback(() => {
13219
+ const handleTextClear = React37.useCallback(() => {
13136
13220
  onTextChange == null ? void 0 : onTextChange("");
13137
13221
  onOperandChange == null ? void 0 : onOperandChange("");
13138
13222
  onRemoveAll == null ? void 0 : onRemoveAll();
13139
13223
  }, [onTextChange, onOperandChange, onRemoveAll]);
13140
- const handleDateClear = React36.useCallback(() => {
13224
+ const handleDateClear = React37.useCallback(() => {
13141
13225
  onDateChange == null ? void 0 : onDateChange({ start: void 0, end: void 0 });
13142
13226
  onRemoveAll == null ? void 0 : onRemoveAll();
13143
13227
  }, [onDateChange, onRemoveAll]);
13144
- const hasContentToClear = React36.useMemo(() => {
13228
+ const hasContentToClear = React37.useMemo(() => {
13145
13229
  if (type === "text" || type === "numeric") {
13146
13230
  return text !== void 0 && text !== "";
13147
13231
  }
@@ -13162,18 +13246,18 @@ var FilterSelect = React36.forwardRef(
13162
13246
  }
13163
13247
  return selectedItems.length > 0;
13164
13248
  }, [type, text, operand, selectedItems.length, date, rangeMin, rangeMax]);
13165
- const [draggedValue, setDraggedValue] = React36.useState(null);
13166
- const [dragOverValue, setDragOverValue] = React36.useState(
13249
+ const [draggedValue, setDraggedValue] = React37.useState(null);
13250
+ const [dragOverValue, setDragOverValue] = React37.useState(
13167
13251
  null
13168
13252
  );
13169
- const handleDragStart = React36.useCallback(
13253
+ const handleDragStart = React37.useCallback(
13170
13254
  (e, value) => {
13171
13255
  setDraggedValue(value);
13172
13256
  e.dataTransfer.effectAllowed = "move";
13173
13257
  },
13174
13258
  []
13175
13259
  );
13176
- const handleDragOver = React36.useCallback(
13260
+ const handleDragOver = React37.useCallback(
13177
13261
  (e, value) => {
13178
13262
  e.preventDefault();
13179
13263
  if (draggedValue !== null && draggedValue !== value && selectedItems.includes(value)) {
@@ -13182,10 +13266,10 @@ var FilterSelect = React36.forwardRef(
13182
13266
  },
13183
13267
  [draggedValue, selectedItems]
13184
13268
  );
13185
- const handleDragLeave = React36.useCallback(() => {
13269
+ const handleDragLeave = React37.useCallback(() => {
13186
13270
  setDragOverValue(null);
13187
13271
  }, []);
13188
- const handleDrop = React36.useCallback(
13272
+ const handleDrop = React37.useCallback(
13189
13273
  (e, dropValue) => {
13190
13274
  e.preventDefault();
13191
13275
  if (draggedValue === null || draggedValue === dropValue || !selectedItems.includes(dropValue)) {
@@ -13217,13 +13301,13 @@ var FilterSelect = React36.forwardRef(
13217
13301
  onSelectionChange
13218
13302
  ]
13219
13303
  );
13220
- const handleDragEnd = React36.useCallback(() => {
13304
+ const handleDragEnd = React37.useCallback(() => {
13221
13305
  setDraggedValue(null);
13222
13306
  setDragOverValue(null);
13223
13307
  }, []);
13224
13308
  const isCompactBody = type === "duration" || type === "numeric_with_operands" && !isRangeMode;
13225
13309
  const bodyMinWidth = isCompactBody ? Math.max(160, triggerWidth != null ? triggerWidth : 0) : Math.max(196, triggerWidth != null ? triggerWidth : 0);
13226
- const renderFooterClear = (onClick, labelText, ariaLabel) => /* @__PURE__ */ jsx32("div", { className: FILTER_SELECT_TOKENS.footer.wrapper, children: /* @__PURE__ */ jsxs23(
13310
+ const renderFooterClear = (onClick, labelText, ariaLabel) => /* @__PURE__ */ jsx33("div", { className: FILTER_SELECT_TOKENS.footer.wrapper, children: /* @__PURE__ */ jsxs23(
13227
13311
  "button",
13228
13312
  {
13229
13313
  type: "button",
@@ -13231,13 +13315,13 @@ var FilterSelect = React36.forwardRef(
13231
13315
  className: FILTER_SELECT_TOKENS.removeButton.base,
13232
13316
  "aria-label": ariaLabel,
13233
13317
  children: [
13234
- /* @__PURE__ */ jsx32(Trash2, { className: FILTER_SELECT_TOKENS.removeButton.icon }),
13235
- /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.removeButton.text, children: labelText })
13318
+ /* @__PURE__ */ jsx33(Trash2, { className: FILTER_SELECT_TOKENS.removeButton.icon }),
13319
+ /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.removeButton.text, children: labelText })
13236
13320
  ]
13237
13321
  }
13238
13322
  ) });
13239
- return /* @__PURE__ */ jsx32("div", { ref, className: "inline-block font-sans", ...props, children: /* @__PURE__ */ jsxs23(DropdownMenuPrimitive3.Root, { open, onOpenChange: setOpen, children: [
13240
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
13323
+ return /* @__PURE__ */ jsx33("div", { ref, className: "inline-block font-sans", ...props, children: /* @__PURE__ */ jsxs23(DropdownMenuPrimitive3.Root, { open, onOpenChange: setOpen, children: [
13324
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs23(
13241
13325
  "button",
13242
13326
  {
13243
13327
  type: "button",
@@ -13254,8 +13338,8 @@ var FilterSelect = React36.forwardRef(
13254
13338
  ),
13255
13339
  children: [
13256
13340
  /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-2 min-w-0", children: [
13257
- Icon2 && /* @__PURE__ */ jsx32(Icon2, { className: FILTER_SELECT_TOKENS.icon }),
13258
- /* @__PURE__ */ jsx32(
13341
+ Icon2 && /* @__PURE__ */ jsx33(Icon2, { className: FILTER_SELECT_TOKENS.icon }),
13342
+ /* @__PURE__ */ jsx33(
13259
13343
  "span",
13260
13344
  {
13261
13345
  "data-filter-label": "",
@@ -13264,7 +13348,15 @@ var FilterSelect = React36.forwardRef(
13264
13348
  }
13265
13349
  ),
13266
13350
  selectedItemsText && /* @__PURE__ */ jsxs23(Fragment11, { children: [
13267
- /* @__PURE__ */ jsx32(
13351
+ /* @__PURE__ */ jsx33(
13352
+ "span",
13353
+ {
13354
+ "aria-hidden": "true",
13355
+ "data-filter-separator": "",
13356
+ className: FILTER_SELECT_TOKENS.separator
13357
+ }
13358
+ ),
13359
+ /* @__PURE__ */ jsx33(
13268
13360
  "span",
13269
13361
  {
13270
13362
  ref: selectedItemsRef,
@@ -13278,7 +13370,7 @@ var FilterSelect = React36.forwardRef(
13278
13370
  )}, +${selectedLabels.length - visibleItemsCount}` : selectedItemsText
13279
13371
  }
13280
13372
  ),
13281
- type === "list" && /* @__PURE__ */ jsx32(
13373
+ type === "list" && /* @__PURE__ */ jsx33(
13282
13374
  "span",
13283
13375
  {
13284
13376
  ref: measureRef,
@@ -13297,7 +13389,7 @@ var FilterSelect = React36.forwardRef(
13297
13389
  )
13298
13390
  ] })
13299
13391
  ] }),
13300
- /* @__PURE__ */ jsx32(
13392
+ /* @__PURE__ */ jsx33(
13301
13393
  ChevronDown5,
13302
13394
  {
13303
13395
  className: cn(
@@ -13310,14 +13402,14 @@ var FilterSelect = React36.forwardRef(
13310
13402
  ]
13311
13403
  }
13312
13404
  ) }),
13313
- /* @__PURE__ */ jsx32(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx32(
13405
+ /* @__PURE__ */ jsx33(DropdownMenuPrimitive3.Portal, { container, children: /* @__PURE__ */ jsx33(
13314
13406
  "div",
13315
13407
  {
13316
13408
  className: cn(
13317
13409
  !container && "lego-land",
13318
13410
  !container && themeClass
13319
13411
  ),
13320
- children: /* @__PURE__ */ jsx32(
13412
+ children: /* @__PURE__ */ jsx33(
13321
13413
  DropdownMenuPrimitive3.Content,
13322
13414
  {
13323
13415
  className: cn(
@@ -13360,8 +13452,8 @@ var FilterSelect = React36.forwardRef(
13360
13452
  e.preventDefault();
13361
13453
  }
13362
13454
  },
13363
- children: loading ? /* @__PURE__ */ jsx32(Spinner, { size: "md" }) : type === "text" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13364
- /* @__PURE__ */ jsx32("div", { className: "p-1", children: /* @__PURE__ */ jsx32(
13455
+ children: loading ? /* @__PURE__ */ jsx33(Spinner, { size: "md" }) : type === "text" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13456
+ /* @__PURE__ */ jsx33("div", { className: "p-1", children: /* @__PURE__ */ jsx33(
13365
13457
  "textarea",
13366
13458
  {
13367
13459
  value: text != null ? text : "",
@@ -13371,10 +13463,10 @@ var FilterSelect = React36.forwardRef(
13371
13463
  autoFocus: true
13372
13464
  }
13373
13465
  ) }),
13374
- (showClearBtn || hasContentToClear) && renderFooterClear(handleTextClear, "Remove", "Remove text")
13466
+ (showClearBtn || hasContentToClear) && renderFooterClear(handleTextClear, footerActionLabel, `${footerActionLabel} text`)
13375
13467
  ] }) : type === "text_with_operands" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13376
13468
  /* @__PURE__ */ jsxs23("div", { className: "p-1 flex flex-col gap-2", children: [
13377
- /* @__PURE__ */ jsx32("div", { className: "pb-2 -mx-1 px-1 border-b border-token-xlight", children: /* @__PURE__ */ jsx32(
13469
+ /* @__PURE__ */ jsx33(
13378
13470
  OperandDropdown,
13379
13471
  {
13380
13472
  value: operand != null ? operand : "",
@@ -13384,8 +13476,8 @@ var FilterSelect = React36.forwardRef(
13384
13476
  container,
13385
13477
  themeClass
13386
13478
  }
13387
- ) }),
13388
- /* @__PURE__ */ jsx32(
13479
+ ),
13480
+ /* @__PURE__ */ jsx33(
13389
13481
  "textarea",
13390
13482
  {
13391
13483
  value: text != null ? text : "",
@@ -13398,12 +13490,12 @@ var FilterSelect = React36.forwardRef(
13398
13490
  ] }),
13399
13491
  (showClearBtn || hasContentToClear) && renderFooterClear(
13400
13492
  handleTextClear,
13401
- "Remove",
13402
- "Remove filter"
13493
+ footerActionLabel,
13494
+ `${footerActionLabel} filter`
13403
13495
  )
13404
13496
  ] }) : type === "numeric" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13405
- /* @__PURE__ */ jsx32("div", { className: "p-1", children: /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapper, children: [
13406
- /* @__PURE__ */ jsx32(
13497
+ /* @__PURE__ */ jsx33("div", { className: "p-1", children: /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapper, children: [
13498
+ /* @__PURE__ */ jsx33(
13407
13499
  "input",
13408
13500
  {
13409
13501
  type: "number",
@@ -13414,12 +13506,12 @@ var FilterSelect = React36.forwardRef(
13414
13506
  autoFocus: true
13415
13507
  }
13416
13508
  ),
13417
- unitLabel && /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13509
+ unitLabel && /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13418
13510
  ] }) }),
13419
- (showClearBtn || hasContentToClear) && renderFooterClear(handleTextClear, "Remove", "Remove number")
13511
+ (showClearBtn || hasContentToClear) && renderFooterClear(handleTextClear, footerActionLabel, `${footerActionLabel} number`)
13420
13512
  ] }) : type === "numeric_with_operands" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13421
13513
  /* @__PURE__ */ jsxs23("div", { className: "p-1 flex flex-col gap-2", children: [
13422
- /* @__PURE__ */ jsx32("div", { className: "pb-2 -mx-1 px-1 border-b border-token-xlight", children: /* @__PURE__ */ jsx32(
13514
+ /* @__PURE__ */ jsx33(
13423
13515
  OperandDropdown,
13424
13516
  {
13425
13517
  value: operand != null ? operand : "",
@@ -13429,10 +13521,10 @@ var FilterSelect = React36.forwardRef(
13429
13521
  container,
13430
13522
  themeClass
13431
13523
  }
13432
- ) }),
13524
+ ),
13433
13525
  isRangeMode ? /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-2 w-full", children: [
13434
13526
  /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapper, children: [
13435
- /* @__PURE__ */ jsx32(
13527
+ /* @__PURE__ */ jsx33(
13436
13528
  "input",
13437
13529
  {
13438
13530
  type: "text",
@@ -13449,7 +13541,7 @@ var FilterSelect = React36.forwardRef(
13449
13541
  className: FILTER_SELECT_TOKENS.bodyInput.input
13450
13542
  }
13451
13543
  ),
13452
- unitLabel && /* @__PURE__ */ jsx32(
13544
+ unitLabel && /* @__PURE__ */ jsx33(
13453
13545
  "span",
13454
13546
  {
13455
13547
  className: FILTER_SELECT_TOKENS.bodyInput.unit,
@@ -13457,9 +13549,9 @@ var FilterSelect = React36.forwardRef(
13457
13549
  }
13458
13550
  )
13459
13551
  ] }),
13460
- /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.rangeDivider, children: "-" }),
13552
+ /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.rangeDivider, children: "-" }),
13461
13553
  /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapper, children: [
13462
- /* @__PURE__ */ jsx32(
13554
+ /* @__PURE__ */ jsx33(
13463
13555
  "input",
13464
13556
  {
13465
13557
  type: "text",
@@ -13476,7 +13568,7 @@ var FilterSelect = React36.forwardRef(
13476
13568
  className: FILTER_SELECT_TOKENS.bodyInput.input
13477
13569
  }
13478
13570
  ),
13479
- unitLabel && /* @__PURE__ */ jsx32(
13571
+ unitLabel && /* @__PURE__ */ jsx33(
13480
13572
  "span",
13481
13573
  {
13482
13574
  className: FILTER_SELECT_TOKENS.bodyInput.unit,
@@ -13485,7 +13577,7 @@ var FilterSelect = React36.forwardRef(
13485
13577
  )
13486
13578
  ] })
13487
13579
  ] }) : /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapperCompact, children: [
13488
- /* @__PURE__ */ jsx32(
13580
+ /* @__PURE__ */ jsx33(
13489
13581
  "input",
13490
13582
  {
13491
13583
  type: "number",
@@ -13496,7 +13588,7 @@ var FilterSelect = React36.forwardRef(
13496
13588
  autoFocus: true
13497
13589
  }
13498
13590
  ),
13499
- unitLabel && /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13591
+ unitLabel && /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13500
13592
  ] })
13501
13593
  ] }),
13502
13594
  (showClearBtn || hasContentToClear) && renderFooterClear(
@@ -13507,13 +13599,13 @@ var FilterSelect = React36.forwardRef(
13507
13599
  onRangeMaxChange == null ? void 0 : onRangeMaxChange("");
13508
13600
  onRemoveAll == null ? void 0 : onRemoveAll();
13509
13601
  },
13510
- "Remove",
13511
- "Remove filter"
13602
+ footerActionLabel,
13603
+ `${footerActionLabel} filter`
13512
13604
  )
13513
13605
  ] }) : type === "in_between" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13514
- /* @__PURE__ */ jsx32("div", { className: "p-1", children: /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-2 w-full", children: [
13606
+ /* @__PURE__ */ jsx33("div", { className: "p-1", children: /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-2 w-full", children: [
13515
13607
  /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapper, children: [
13516
- /* @__PURE__ */ jsx32(
13608
+ /* @__PURE__ */ jsx33(
13517
13609
  "input",
13518
13610
  {
13519
13611
  type: "text",
@@ -13531,11 +13623,11 @@ var FilterSelect = React36.forwardRef(
13531
13623
  autoFocus: true
13532
13624
  }
13533
13625
  ),
13534
- unitLabel && /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13626
+ unitLabel && /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13535
13627
  ] }),
13536
- /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.rangeDivider, children: "-" }),
13628
+ /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.rangeDivider, children: "-" }),
13537
13629
  /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapper, children: [
13538
- /* @__PURE__ */ jsx32(
13630
+ /* @__PURE__ */ jsx33(
13539
13631
  "input",
13540
13632
  {
13541
13633
  type: "text",
@@ -13552,7 +13644,7 @@ var FilterSelect = React36.forwardRef(
13552
13644
  className: FILTER_SELECT_TOKENS.bodyInput.input
13553
13645
  }
13554
13646
  ),
13555
- unitLabel && /* @__PURE__ */ jsx32("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13647
+ unitLabel && /* @__PURE__ */ jsx33("span", { className: FILTER_SELECT_TOKENS.bodyInput.unit, children: unitLabel })
13556
13648
  ] })
13557
13649
  ] }) }),
13558
13650
  (showClearBtn || hasContentToClear) && renderFooterClear(
@@ -13561,12 +13653,12 @@ var FilterSelect = React36.forwardRef(
13561
13653
  onRangeMaxChange == null ? void 0 : onRangeMaxChange("");
13562
13654
  onRemoveAll == null ? void 0 : onRemoveAll();
13563
13655
  },
13564
- "Remove",
13565
- "Remove range"
13656
+ footerActionLabel,
13657
+ `${footerActionLabel} range`
13566
13658
  )
13567
13659
  ] }) : type === "duration" ? /* @__PURE__ */ jsxs23(Fragment11, { children: [
13568
13660
  /* @__PURE__ */ jsxs23("div", { className: "p-1 flex items-center gap-2", children: [
13569
- /* @__PURE__ */ jsx32("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapperCompact, children: /* @__PURE__ */ jsx32(
13661
+ /* @__PURE__ */ jsx33("div", { className: FILTER_SELECT_TOKENS.bodyInput.wrapperCompact, children: /* @__PURE__ */ jsx33(
13570
13662
  "input",
13571
13663
  {
13572
13664
  type: "number",
@@ -13577,7 +13669,7 @@ var FilterSelect = React36.forwardRef(
13577
13669
  autoFocus: true
13578
13670
  }
13579
13671
  ) }),
13580
- /* @__PURE__ */ jsx32(
13672
+ /* @__PURE__ */ jsx33(
13581
13673
  OperandDropdown,
13582
13674
  {
13583
13675
  value: durationUnit != null ? durationUnit : "",
@@ -13595,41 +13687,75 @@ var FilterSelect = React36.forwardRef(
13595
13687
  onDurationUnitChange == null ? void 0 : onDurationUnitChange("");
13596
13688
  onRemoveAll == null ? void 0 : onRemoveAll();
13597
13689
  },
13598
- "Remove",
13599
- "Remove duration"
13690
+ footerActionLabel,
13691
+ `${footerActionLabel} duration`
13600
13692
  )
13601
13693
  ] }) : type === "date" ? /* @__PURE__ */ jsxs23("div", { className: "flex flex-col min-h-0 flex-1", children: [
13602
13694
  /* @__PURE__ */ jsxs23(
13603
13695
  "div",
13604
13696
  {
13605
13697
  className: cn(
13606
- "flex gap-4 flex-1 min-h-0",
13698
+ // Tight `gap-2` between presets and calendar so there
13699
+ // is no wide gutter between the two columns.
13700
+ "flex gap-2 flex-1 min-h-0",
13607
13701
  datePresets !== false && "flex-row"
13608
13702
  ),
13609
13703
  children: [
13610
- datePresets !== false && /* @__PURE__ */ jsx32("div", { className: FILTER_SELECT_TOKENS.datePresetSidebar, children: /* @__PURE__ */ jsx32("div", { className: "flex flex-col gap-1", children: (Array.isArray(datePresets) ? datePresets : DEFAULT_DATE_PRESETS).map((preset) => {
13611
- const selected = isPresetSelected(preset, date);
13612
- return /* @__PURE__ */ jsx32(
13613
- "button",
13614
- {
13615
- type: "button",
13616
- onClick: () => {
13617
- const range = preset.getRange();
13618
- onDateChange == null ? void 0 : onDateChange({
13619
- start: range.start,
13620
- end: range.end
13621
- });
13704
+ datePresets !== false && /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.datePresetSidebar, children: [
13705
+ /* @__PURE__ */ jsx33("div", { className: "flex flex-col gap-1", children: (Array.isArray(datePresets) ? datePresets : DEFAULT_DATE_PRESETS).map((preset) => {
13706
+ const selected = isPresetSelected(preset, date);
13707
+ return /* @__PURE__ */ jsx33(
13708
+ "button",
13709
+ {
13710
+ type: "button",
13711
+ onClick: () => {
13712
+ const range = preset.getRange();
13713
+ onDateChange == null ? void 0 : onDateChange({
13714
+ start: range.start,
13715
+ end: range.end
13716
+ });
13717
+ },
13718
+ className: cn(
13719
+ FILTER_SELECT_TOKENS.datePreset.base,
13720
+ selected ? FILTER_SELECT_TOKENS.datePreset.selected : FILTER_SELECT_TOKENS.datePreset.default
13721
+ ),
13722
+ children: preset.label
13622
13723
  },
13623
- className: cn(
13624
- FILTER_SELECT_TOKENS.datePreset.base,
13625
- selected ? FILTER_SELECT_TOKENS.datePreset.selected : FILTER_SELECT_TOKENS.datePreset.default
13626
- ),
13627
- children: preset.label
13628
- },
13629
- preset.value
13630
- );
13631
- }) }) }),
13632
- /* @__PURE__ */ jsx32("div", { className: "flex flex-col min-w-0 flex-1 gap-2", children: /* @__PURE__ */ jsx32(
13724
+ preset.value
13725
+ );
13726
+ }) }),
13727
+ (showClearBtn || hasContentToClear) && /* @__PURE__ */ jsx33(
13728
+ "div",
13729
+ {
13730
+ className: FILTER_SELECT_TOKENS.datePresetSidebarAction.wrapper,
13731
+ children: /* @__PURE__ */ jsxs23(
13732
+ "button",
13733
+ {
13734
+ type: "button",
13735
+ onClick: handleDateClear,
13736
+ className: FILTER_SELECT_TOKENS.datePresetSidebarAction.button,
13737
+ "aria-label": `${footerActionLabel} date range`,
13738
+ children: [
13739
+ /* @__PURE__ */ jsx33(
13740
+ Trash2,
13741
+ {
13742
+ className: FILTER_SELECT_TOKENS.datePresetSidebarAction.icon
13743
+ }
13744
+ ),
13745
+ /* @__PURE__ */ jsx33(
13746
+ "span",
13747
+ {
13748
+ className: FILTER_SELECT_TOKENS.datePresetSidebarAction.text,
13749
+ children: footerActionLabel
13750
+ }
13751
+ )
13752
+ ]
13753
+ }
13754
+ )
13755
+ }
13756
+ )
13757
+ ] }),
13758
+ /* @__PURE__ */ jsx33("div", { className: "flex flex-col min-w-0 flex-1 gap-2", children: /* @__PURE__ */ jsx33(
13633
13759
  CalendarMonthCaptionContext.Provider,
13634
13760
  {
13635
13761
  value: {
@@ -13641,7 +13767,7 @@ var FilterSelect = React36.forwardRef(
13641
13767
  minYear: 2020,
13642
13768
  maxYear: (/* @__PURE__ */ new Date()).getFullYear() + 5
13643
13769
  },
13644
- children: /* @__PURE__ */ jsx32(
13770
+ children: /* @__PURE__ */ jsx33(
13645
13771
  DayPicker,
13646
13772
  {
13647
13773
  mode: "range",
@@ -13679,7 +13805,7 @@ var FilterSelect = React36.forwardRef(
13679
13805
  MonthCaption: CalendarMonthCaption,
13680
13806
  // Hide the default nav toolbar — chevrons now live
13681
13807
  // inside our custom MonthCaption on the outer edges.
13682
- Nav: () => /* @__PURE__ */ jsx32(Fragment11, {})
13808
+ Nav: () => /* @__PURE__ */ jsx33(Fragment11, {})
13683
13809
  },
13684
13810
  className: "p-0 font-sans [&_.rdp-day_button]:rounded-[8px]"
13685
13811
  }
@@ -13689,10 +13815,10 @@ var FilterSelect = React36.forwardRef(
13689
13815
  ]
13690
13816
  }
13691
13817
  ),
13692
- (showClearBtn || hasContentToClear) && renderFooterClear(
13818
+ datePresets === false && (showClearBtn || hasContentToClear) && renderFooterClear(
13693
13819
  handleDateClear,
13694
- "Remove",
13695
- "Remove date range"
13820
+ footerActionLabel,
13821
+ `${footerActionLabel} date range`
13696
13822
  )
13697
13823
  ] }) : (
13698
13824
  // -----------------------------------------------------------------
@@ -13700,8 +13826,8 @@ var FilterSelect = React36.forwardRef(
13700
13826
  // -----------------------------------------------------------------
13701
13827
  /* @__PURE__ */ jsxs23(Fragment11, { children: [
13702
13828
  showSearch && /* @__PURE__ */ jsxs23("div", { className: FILTER_SELECT_TOKENS.searchBar.wrapper, children: [
13703
- /* @__PURE__ */ jsx32(Search3, { className: FILTER_SELECT_TOKENS.searchBar.icon }),
13704
- /* @__PURE__ */ jsx32(
13829
+ /* @__PURE__ */ jsx33(Search3, { className: FILTER_SELECT_TOKENS.searchBar.icon }),
13830
+ /* @__PURE__ */ jsx33(
13705
13831
  "input",
13706
13832
  {
13707
13833
  type: "text",
@@ -13712,20 +13838,20 @@ var FilterSelect = React36.forwardRef(
13712
13838
  className: FILTER_SELECT_TOKENS.searchBar.input
13713
13839
  }
13714
13840
  ),
13715
- searchQuery && /* @__PURE__ */ jsx32(
13841
+ searchQuery && /* @__PURE__ */ jsx33(
13716
13842
  "button",
13717
13843
  {
13718
13844
  type: "button",
13719
13845
  onClick: () => setSearchQuery(""),
13720
13846
  "aria-label": "Remove search",
13721
13847
  className: FILTER_SELECT_TOKENS.searchBar.clearBtn,
13722
- children: /* @__PURE__ */ jsx32(X2, { className: FILTER_SELECT_TOKENS.searchBar.icon })
13848
+ children: /* @__PURE__ */ jsx33(X2, { className: FILTER_SELECT_TOKENS.searchBar.icon })
13723
13849
  }
13724
13850
  )
13725
13851
  ] }),
13726
- /* @__PURE__ */ jsx32("div", { className: "flex flex-col gap-1 w-full min-w-0 overflow-y-auto flex-1 min-h-0", children: isSectioned ? sortedItems.length === 0 ? /* @__PURE__ */ jsx32("div", { className: FILTER_SELECT_TOKENS.emptyState, children: emptyStateLabel || "No items available" }) : sortedItems.map(
13852
+ /* @__PURE__ */ jsx33("div", { className: "flex flex-col gap-1 w-full min-w-0 overflow-y-auto flex-1 min-h-0", children: isSectioned ? sortedItems.length === 0 ? /* @__PURE__ */ jsx33("div", { className: FILTER_SELECT_TOKENS.emptyState, children: emptyStateLabel || "No items available" }) : sortedItems.map(
13727
13853
  (section, sectionIdx) => /* @__PURE__ */ jsxs23("div", { className: "flex flex-col gap-1", children: [
13728
- /* @__PURE__ */ jsx32(
13854
+ /* @__PURE__ */ jsx33(
13729
13855
  "div",
13730
13856
  {
13731
13857
  className: FILTER_SELECT_TOKENS.sectionHeader,
@@ -13736,7 +13862,7 @@ var FilterSelect = React36.forwardRef(
13736
13862
  const isSelected = selectedItems.includes(
13737
13863
  item.value
13738
13864
  );
13739
- return /* @__PURE__ */ jsx32(
13865
+ return /* @__PURE__ */ jsx33(
13740
13866
  FilterListItem,
13741
13867
  {
13742
13868
  value: item.value,
@@ -13760,9 +13886,9 @@ var FilterSelect = React36.forwardRef(
13760
13886
  );
13761
13887
  })
13762
13888
  ] }, sectionIdx)
13763
- ) : sortedItems.length === 0 ? /* @__PURE__ */ jsx32("div", { className: FILTER_SELECT_TOKENS.emptyState, children: emptyStateLabel || "No items available" }) : sortedItems.map((item) => {
13889
+ ) : sortedItems.length === 0 ? /* @__PURE__ */ jsx33("div", { className: FILTER_SELECT_TOKENS.emptyState, children: emptyStateLabel || "No items available" }) : sortedItems.map((item) => {
13764
13890
  const isSelected = selectedItems.includes(item.value);
13765
- return /* @__PURE__ */ jsx32(
13891
+ return /* @__PURE__ */ jsx33(
13766
13892
  FilterListItem,
13767
13893
  {
13768
13894
  value: item.value,
@@ -13787,8 +13913,8 @@ var FilterSelect = React36.forwardRef(
13787
13913
  }) }),
13788
13914
  showClearBtn && selectedItems.length > 0 && renderFooterClear(
13789
13915
  handleClearAll,
13790
- "Remove",
13791
- "Remove all selected items"
13916
+ footerActionLabel,
13917
+ `${footerActionLabel} all selected items`
13792
13918
  )
13793
13919
  ] })
13794
13920
  )
@@ -13802,17 +13928,17 @@ var FilterSelect = React36.forwardRef(
13802
13928
  FilterSelect.displayName = "FilterSelect";
13803
13929
 
13804
13930
  // src/filter-select/compound-filter-select.tsx
13805
- import * as React37 from "react";
13931
+ import * as React38 from "react";
13806
13932
  import * as DropdownMenuPrimitive4 from "@radix-ui/react-dropdown-menu";
13807
13933
  import { Check as Check7, ChevronDown as ChevronDown6 } from "lucide-react";
13808
- import { jsx as jsx33, jsxs as jsxs24 } from "react/jsx-runtime";
13934
+ import { jsx as jsx34, jsxs as jsxs24 } from "react/jsx-runtime";
13809
13935
  function renderIcon(icon, className) {
13810
13936
  if (!icon) return null;
13811
- if (React37.isValidElement(icon)) {
13812
- return /* @__PURE__ */ jsx33("span", { className: "inline-flex items-center", children: icon });
13937
+ if (React38.isValidElement(icon)) {
13938
+ return /* @__PURE__ */ jsx34("span", { className: "inline-flex items-center", children: icon });
13813
13939
  }
13814
13940
  if (typeof icon === "function" || typeof icon === "object" && icon !== null && "$$typeof" in icon) {
13815
- return React37.createElement(icon, {
13941
+ return React38.createElement(icon, {
13816
13942
  className: cn("size-4", className)
13817
13943
  });
13818
13944
  }
@@ -13831,8 +13957,8 @@ function CompoundFilterSelect({
13831
13957
  }) {
13832
13958
  const { theme } = useTheme();
13833
13959
  const themeClass = theme === "dark" ? "dark" : "light";
13834
- const [open, setOpen] = React37.useState(false);
13835
- const container = React37.useMemo(
13960
+ const [open, setOpen] = React38.useState(false);
13961
+ const container = React38.useMemo(
13836
13962
  () => {
13837
13963
  var _a5;
13838
13964
  return typeof document !== "undefined" ? (_a5 = document.querySelector(".lego-land")) != null ? _a5 : void 0 : void 0;
@@ -13852,7 +13978,7 @@ function CompoundFilterSelect({
13852
13978
  ...props,
13853
13979
  children: [
13854
13980
  /* @__PURE__ */ jsxs24(DropdownMenuPrimitive4.Root, { open, onOpenChange: setOpen, children: [
13855
- /* @__PURE__ */ jsx33(DropdownMenuPrimitive4.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs24(
13981
+ /* @__PURE__ */ jsx34(DropdownMenuPrimitive4.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs24(
13856
13982
  "button",
13857
13983
  {
13858
13984
  type: "button",
@@ -13871,8 +13997,8 @@ function CompoundFilterSelect({
13871
13997
  "aria-label": "Toggle filter type",
13872
13998
  children: [
13873
13999
  renderIcon(effectiveLeadingIcon, "text-fg-black"),
13874
- leftLabel && /* @__PURE__ */ jsx33("span", { className: "font-sans text-xs font-medium leading-4 text-fg-black tracking-normal whitespace-nowrap", children: leftLabel }),
13875
- /* @__PURE__ */ jsx33(
14000
+ leftLabel && /* @__PURE__ */ jsx34("span", { className: "font-sans text-xs font-medium leading-4 text-fg-black tracking-normal whitespace-nowrap", children: leftLabel }),
14001
+ /* @__PURE__ */ jsx34(
13876
14002
  ChevronDown6,
13877
14003
  {
13878
14004
  className: cn(
@@ -13884,7 +14010,7 @@ function CompoundFilterSelect({
13884
14010
  ]
13885
14011
  }
13886
14012
  ) }),
13887
- /* @__PURE__ */ jsx33(DropdownMenuPrimitive4.Portal, { container, children: /* @__PURE__ */ jsx33("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx33(
14013
+ /* @__PURE__ */ jsx34(DropdownMenuPrimitive4.Portal, { container, children: /* @__PURE__ */ jsx34("div", { className: cn(!container && "lego-land", !container && themeClass), children: /* @__PURE__ */ jsx34(
13888
14014
  DropdownMenuPrimitive4.Content,
13889
14015
  {
13890
14016
  className: cn(
@@ -13917,9 +14043,9 @@ function CompoundFilterSelect({
13917
14043
  children: [
13918
14044
  /* @__PURE__ */ jsxs24("span", { className: "flex items-center gap-2 min-w-0", children: [
13919
14045
  renderIcon(opt.icon, "text-fg-black"),
13920
- /* @__PURE__ */ jsx33("span", { className: "font-sans text-xs font-normal leading-4 text-fg-black truncate", children: opt.label })
14046
+ /* @__PURE__ */ jsx34("span", { className: "font-sans text-xs font-normal leading-4 text-fg-black truncate", children: opt.label })
13921
14047
  ] }),
13922
- /* @__PURE__ */ jsx33("span", { className: "shrink-0 flex items-center justify-end w-4", children: isSelected && /* @__PURE__ */ jsx33(
14048
+ /* @__PURE__ */ jsx34("span", { className: "shrink-0 flex items-center justify-end w-4", children: isSelected && /* @__PURE__ */ jsx34(
13923
14049
  Check7,
13924
14050
  {
13925
14051
  className: "size-4 text-fg-brand",
@@ -13934,7 +14060,7 @@ function CompoundFilterSelect({
13934
14060
  }
13935
14061
  ) }) })
13936
14062
  ] }),
13937
- /* @__PURE__ */ jsx33(
14063
+ /* @__PURE__ */ jsx34(
13938
14064
  "div",
13939
14065
  {
13940
14066
  className: cn(
@@ -13944,7 +14070,11 @@ function CompoundFilterSelect({
13944
14070
  "[&_button[data-state]]:!rounded-none [&_button[data-state]]:!rounded-r-[16px]",
13945
14071
  // Paint the FilterSelect label in brand blue, regular weight (Figma 5427:32334).
13946
14072
  "[&_[data-filter-label]]:!text-fg-brand",
13947
- "[&_[data-filter-label]]:!font-normal"
14073
+ "[&_[data-filter-label]]:!font-normal",
14074
+ // In a compound pill, the right-side label IS the value — there is no
14075
+ // separate label/value split to divide. Hide the internal separator
14076
+ // so the trigger reads `[icon] Agent [chevron]`, not `Agent | ▼`.
14077
+ "[&_[data-filter-separator]]:!hidden"
13948
14078
  ),
13949
14079
  children
13950
14080
  }
@@ -13956,7 +14086,7 @@ function CompoundFilterSelect({
13956
14086
  CompoundFilterSelect.displayName = "CompoundFilterSelect";
13957
14087
 
13958
14088
  // src/button-list/button-list.tsx
13959
- import * as React38 from "react";
14089
+ import * as React39 from "react";
13960
14090
  import * as DropdownMenuPrimitive5 from "@radix-ui/react-dropdown-menu";
13961
14091
  import { ChevronDown as ChevronDown7, Code } from "lucide-react";
13962
14092
 
@@ -13969,8 +14099,8 @@ var BUTTON_LIST_TOKENS = {
13969
14099
  };
13970
14100
 
13971
14101
  // src/button-list/button-list.tsx
13972
- import { jsx as jsx34, jsxs as jsxs25 } from "react/jsx-runtime";
13973
- var ButtonList = React38.forwardRef(
14102
+ import { jsx as jsx35, jsxs as jsxs25 } from "react/jsx-runtime";
14103
+ var ButtonList = React39.forwardRef(
13974
14104
  ({
13975
14105
  label = "Button List",
13976
14106
  leadingIcon: LeadingIcon = Code,
@@ -13985,53 +14115,53 @@ var ButtonList = React38.forwardRef(
13985
14115
  }, ref) => {
13986
14116
  const { theme } = useTheme();
13987
14117
  const themeClass = theme === "dark" ? "dark" : "light";
13988
- const container = React38.useMemo(
14118
+ const container = React39.useMemo(
13989
14119
  () => {
13990
14120
  var _a5;
13991
14121
  return typeof document !== "undefined" ? (_a5 = document.querySelector(".lego-land")) != null ? _a5 : void 0 : void 0;
13992
14122
  },
13993
14123
  []
13994
14124
  );
13995
- const [uncontrolledOpen, setUncontrolledOpen] = React38.useState(
14125
+ const [uncontrolledOpen, setUncontrolledOpen] = React39.useState(
13996
14126
  defaultOpen != null ? defaultOpen : false
13997
14127
  );
13998
14128
  const isControlled = controlledOpen !== void 0;
13999
14129
  const open = isControlled ? controlledOpen : uncontrolledOpen;
14000
- const setOpen = React38.useCallback(
14130
+ const setOpen = React39.useCallback(
14001
14131
  (next) => {
14002
14132
  if (!isControlled) setUncontrolledOpen(next);
14003
14133
  onOpenChange == null ? void 0 : onOpenChange(next);
14004
14134
  },
14005
14135
  [isControlled, onOpenChange]
14006
14136
  );
14007
- const handleSelect = React38.useCallback(
14137
+ const handleSelect = React39.useCallback(
14008
14138
  (value) => {
14009
14139
  onSelect == null ? void 0 : onSelect(value);
14010
14140
  setOpen(false);
14011
14141
  },
14012
14142
  [onSelect, setOpen]
14013
14143
  );
14014
- return /* @__PURE__ */ jsx34("div", { ref, ...props, children: /* @__PURE__ */ jsxs25(DropdownMenuPrimitive5.Root, { open, onOpenChange: setOpen, children: [
14015
- /* @__PURE__ */ jsx34(DropdownMenuPrimitive5.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs25(
14144
+ return /* @__PURE__ */ jsx35("div", { ref, ...props, children: /* @__PURE__ */ jsxs25(DropdownMenuPrimitive5.Root, { open, onOpenChange: setOpen, children: [
14145
+ /* @__PURE__ */ jsx35(DropdownMenuPrimitive5.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs25(
14016
14146
  "button",
14017
14147
  {
14018
14148
  type: "button",
14019
14149
  className: cn(BUTTON_LIST_TOKENS.trigger, "group", className),
14020
14150
  children: [
14021
- /* @__PURE__ */ jsx34(LeadingIcon, { className: BUTTON_LIST_TOKENS.icon }),
14022
- /* @__PURE__ */ jsx34("span", { children: label }),
14023
- /* @__PURE__ */ jsx34(ChevronDown7, { className: "size-4 shrink-0 transition-transform group-data-[state=open]:rotate-180" })
14151
+ /* @__PURE__ */ jsx35(LeadingIcon, { className: BUTTON_LIST_TOKENS.icon }),
14152
+ /* @__PURE__ */ jsx35("span", { children: label }),
14153
+ /* @__PURE__ */ jsx35(ChevronDown7, { className: "size-4 shrink-0 transition-transform group-data-[state=open]:rotate-180" })
14024
14154
  ]
14025
14155
  }
14026
14156
  ) }),
14027
- /* @__PURE__ */ jsx34(DropdownMenuPrimitive5.Portal, { container, children: /* @__PURE__ */ jsx34(
14157
+ /* @__PURE__ */ jsx35(DropdownMenuPrimitive5.Portal, { container, children: /* @__PURE__ */ jsx35(
14028
14158
  "div",
14029
14159
  {
14030
14160
  className: cn(
14031
14161
  !container && "lego-land",
14032
14162
  !container && themeClass
14033
14163
  ),
14034
- children: /* @__PURE__ */ jsx34(
14164
+ children: /* @__PURE__ */ jsx35(
14035
14165
  DropdownMenuPrimitive5.Content,
14036
14166
  {
14037
14167
  className: cn(
@@ -14051,8 +14181,8 @@ var ButtonList = React38.forwardRef(
14051
14181
  className: cn(BUTTON_LIST_TOKENS.listItem),
14052
14182
  onClick: () => handleSelect(item.value),
14053
14183
  children: [
14054
- Icon2 && /* @__PURE__ */ jsx34(Icon2, { className: BUTTON_LIST_TOKENS.icon }),
14055
- /* @__PURE__ */ jsx34("span", { children: item.label })
14184
+ Icon2 && /* @__PURE__ */ jsx35(Icon2, { className: BUTTON_LIST_TOKENS.icon }),
14185
+ /* @__PURE__ */ jsx35("span", { children: item.label })
14056
14186
  ]
14057
14187
  },
14058
14188
  item.value
@@ -15019,7 +15149,7 @@ function useJsonEditor({
15019
15149
  }
15020
15150
 
15021
15151
  // src/json-editor/JsonEditor.tsx
15022
- import { Fragment as Fragment12, jsx as jsx35, jsxs as jsxs26 } from "react/jsx-runtime";
15152
+ import { Fragment as Fragment12, jsx as jsx36, jsxs as jsxs26 } from "react/jsx-runtime";
15023
15153
  function JsonEditor({
15024
15154
  value,
15025
15155
  onChange,
@@ -15058,25 +15188,25 @@ function JsonEditor({
15058
15188
  className: `rounded-[16px] border border-token-xlight overflow-hidden bg-token-white ${hideHeader ? "rounded-t-none border-t-0" : ""}`,
15059
15189
  children: [
15060
15190
  !hideHeader && /* @__PURE__ */ jsxs26("div", { className: "flex items-center justify-between px-3 py-1.5 bg-token-light-grey rounded-t-xl", children: [
15061
- /* @__PURE__ */ jsx35("span", { className: "text-xs font-semibold leading-4 text-fg-grey-secondary uppercase select-none", children: label }),
15191
+ /* @__PURE__ */ jsx36("span", { className: "text-xs font-semibold leading-4 text-fg-grey-secondary uppercase select-none", children: label }),
15062
15192
  /* @__PURE__ */ jsxs26("div", { className: "flex items-center gap-0.5", children: [
15063
- /* @__PURE__ */ jsx35(ToolbarButton, { onClick: formatJson, title: "Format JSON", children: /* @__PURE__ */ jsx35(WandSparkles, { className: "size-3" }) }),
15064
- /* @__PURE__ */ jsx35(Divider, {}),
15065
- /* @__PURE__ */ jsx35(ToolbarButton, { onClick: copyToClipboard, title: "Copy JSON", children: copied ? /* @__PURE__ */ jsx35(Check8, { className: "size-3 text-fg-success" }) : /* @__PURE__ */ jsx35(Copy, { className: "size-3" }) }),
15193
+ /* @__PURE__ */ jsx36(ToolbarButton, { onClick: formatJson, title: "Format JSON", children: /* @__PURE__ */ jsx36(WandSparkles, { className: "size-3" }) }),
15194
+ /* @__PURE__ */ jsx36(Divider, {}),
15195
+ /* @__PURE__ */ jsx36(ToolbarButton, { onClick: copyToClipboard, title: "Copy JSON", children: copied ? /* @__PURE__ */ jsx36(Check8, { className: "size-3 text-fg-success" }) : /* @__PURE__ */ jsx36(Copy, { className: "size-3" }) }),
15066
15196
  showExpandButton && /* @__PURE__ */ jsxs26(Fragment12, { children: [
15067
- /* @__PURE__ */ jsx35(Divider, {}),
15068
- /* @__PURE__ */ jsx35(
15197
+ /* @__PURE__ */ jsx36(Divider, {}),
15198
+ /* @__PURE__ */ jsx36(
15069
15199
  ToolbarButton,
15070
15200
  {
15071
15201
  onClick: () => setIsOpen(true),
15072
15202
  title: "Expand editor",
15073
- children: /* @__PURE__ */ jsx35(Expand, { className: "size-3" })
15203
+ children: /* @__PURE__ */ jsx36(Expand, { className: "size-3" })
15074
15204
  }
15075
15205
  )
15076
15206
  ] })
15077
15207
  ] })
15078
15208
  ] }),
15079
- /* @__PURE__ */ jsx35(
15209
+ /* @__PURE__ */ jsx36(
15080
15210
  Ft,
15081
15211
  {
15082
15212
  height,
@@ -15088,11 +15218,11 @@ function JsonEditor({
15088
15218
  theme: "vs"
15089
15219
  }
15090
15220
  ),
15091
- hasErrors && /* @__PURE__ */ jsx35(ErrorBar, { errors })
15221
+ hasErrors && /* @__PURE__ */ jsx36(ErrorBar, { errors })
15092
15222
  ]
15093
15223
  }
15094
15224
  ),
15095
- showExpandButton && /* @__PURE__ */ jsx35(
15225
+ showExpandButton && /* @__PURE__ */ jsx36(
15096
15226
  Dialog,
15097
15227
  {
15098
15228
  open: isOpen,
@@ -15102,20 +15232,20 @@ function JsonEditor({
15102
15232
  confirmLabel: "Close",
15103
15233
  onConfirm: () => setIsOpen(false),
15104
15234
  className: "w-[85vw] max-w-[85vw] h-[85vh]",
15105
- children: /* @__PURE__ */ jsx35("div", { className: "flex flex-col overflow-hidden h-full", children: /* @__PURE__ */ jsxs26("div", { className: "flex-1 min-h-0 flex flex-col rounded-[16px] border border-token-xlight overflow-hidden bg-token-white", children: [
15235
+ children: /* @__PURE__ */ jsx36("div", { className: "flex flex-col overflow-hidden h-full", children: /* @__PURE__ */ jsxs26("div", { className: "flex-1 min-h-0 flex flex-col rounded-[16px] border border-token-xlight overflow-hidden bg-token-white", children: [
15106
15236
  /* @__PURE__ */ jsxs26("div", { className: "flex-none flex items-center justify-between px-3 py-1.5 bg-token-light-grey rounded-t-xl", children: [
15107
- /* @__PURE__ */ jsx35("span", { className: "text-xs font-semibold leading-4 text-fg-grey-secondary uppercase select-none" }),
15237
+ /* @__PURE__ */ jsx36("span", { className: "text-xs font-semibold leading-4 text-fg-grey-secondary uppercase select-none" }),
15108
15238
  /* @__PURE__ */ jsxs26("div", { className: "flex items-center gap-0.5", children: [
15109
- /* @__PURE__ */ jsx35(
15239
+ /* @__PURE__ */ jsx36(
15110
15240
  ToolbarButton,
15111
15241
  {
15112
15242
  onClick: formatExpandedJson,
15113
15243
  title: "Format JSON",
15114
- children: /* @__PURE__ */ jsx35(WandSparkles, { className: "size-3" })
15244
+ children: /* @__PURE__ */ jsx36(WandSparkles, { className: "size-3" })
15115
15245
  }
15116
15246
  ),
15117
- /* @__PURE__ */ jsx35(Divider, {}),
15118
- /* @__PURE__ */ jsx35(ToolbarButton, { onClick: copyToClipboard, title: "Copy JSON", children: copied ? /* @__PURE__ */ jsx35(Check8, { className: "size-3 text-fg-success" }) : /* @__PURE__ */ jsx35(Copy, { className: "size-3" }) })
15247
+ /* @__PURE__ */ jsx36(Divider, {}),
15248
+ /* @__PURE__ */ jsx36(ToolbarButton, { onClick: copyToClipboard, title: "Copy JSON", children: copied ? /* @__PURE__ */ jsx36(Check8, { className: "size-3 text-fg-success" }) : /* @__PURE__ */ jsx36(Copy, { className: "size-3" }) })
15119
15249
  ] })
15120
15250
  ] }),
15121
15251
  /* @__PURE__ */ jsxs26(
@@ -15124,7 +15254,7 @@ function JsonEditor({
15124
15254
  scrollable: true,
15125
15255
  className: "flex-1 min-h-0 p-0 overflow-hidden",
15126
15256
  children: [
15127
- /* @__PURE__ */ jsx35("div", { className: "h-full min-h-[50vh] overflow-hidden", children: /* @__PURE__ */ jsx35(
15257
+ /* @__PURE__ */ jsx36("div", { className: "h-full min-h-[50vh] overflow-hidden", children: /* @__PURE__ */ jsx36(
15128
15258
  Ft,
15129
15259
  {
15130
15260
  height: "100%",
@@ -15136,7 +15266,7 @@ function JsonEditor({
15136
15266
  theme: "vs"
15137
15267
  }
15138
15268
  ) }),
15139
- hasErrors && /* @__PURE__ */ jsx35(ErrorBar, { errors })
15269
+ hasErrors && /* @__PURE__ */ jsx36(ErrorBar, { errors })
15140
15270
  ]
15141
15271
  }
15142
15272
  )
@@ -15150,8 +15280,8 @@ function ToolbarButton({
15150
15280
  title,
15151
15281
  children
15152
15282
  }) {
15153
- return /* @__PURE__ */ jsx35(TooltipProvider, { children: /* @__PURE__ */ jsxs26(Tooltip, { children: [
15154
- /* @__PURE__ */ jsx35(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx35(
15283
+ return /* @__PURE__ */ jsx36(TooltipProvider, { children: /* @__PURE__ */ jsxs26(Tooltip, { children: [
15284
+ /* @__PURE__ */ jsx36(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx36(
15155
15285
  "button",
15156
15286
  {
15157
15287
  type: "button",
@@ -15160,16 +15290,16 @@ function ToolbarButton({
15160
15290
  children
15161
15291
  }
15162
15292
  ) }),
15163
- /* @__PURE__ */ jsx35(TooltipContent, { side: "top", sideOffset: 6, children: title })
15293
+ /* @__PURE__ */ jsx36(TooltipContent, { side: "top", sideOffset: 6, children: title })
15164
15294
  ] }) });
15165
15295
  }
15166
15296
  function Divider() {
15167
- return /* @__PURE__ */ jsx35("div", { className: "w-px h-3.5 bg-border-token-xlight mx-0.5" });
15297
+ return /* @__PURE__ */ jsx36("div", { className: "w-px h-3.5 bg-border-token-xlight mx-0.5" });
15168
15298
  }
15169
15299
  function ErrorBar({ errors }) {
15170
15300
  return /* @__PURE__ */ jsxs26("div", { className: "flex items-start gap-2 bg-token-destructive-secondary border-t border-token-xlight text-fg-destructive text-xs px-3 py-2", children: [
15171
- /* @__PURE__ */ jsx35("span", { className: "mt-px shrink-0", children: "\u26A0" }),
15172
- /* @__PURE__ */ jsx35("div", { className: "flex flex-col gap-0.5", children: errors.map((err, idx) => /* @__PURE__ */ jsx35("span", { children: err }, idx)) })
15301
+ /* @__PURE__ */ jsx36("span", { className: "mt-px shrink-0", children: "\u26A0" }),
15302
+ /* @__PURE__ */ jsx36("div", { className: "flex flex-col gap-0.5", children: errors.map((err, idx) => /* @__PURE__ */ jsx36("span", { children: err }, idx)) })
15173
15303
  ] });
15174
15304
  }
15175
15305
 
@@ -15188,7 +15318,7 @@ var JSON_EDITOR_LANGUAGE_OPTIONS = [
15188
15318
  ];
15189
15319
 
15190
15320
  // src/key-value-editor/key-value-editor.tsx
15191
- import * as React40 from "react";
15321
+ import * as React41 from "react";
15192
15322
  import { GitCompare, Trash2 as Trash22 } from "lucide-react";
15193
15323
 
15194
15324
  // src/key-value-editor/variables.ts
@@ -15213,8 +15343,8 @@ var KEY_VALUE_EDITOR_TOKENS = {
15213
15343
  };
15214
15344
 
15215
15345
  // src/key-value-editor/key-value-editor.tsx
15216
- import { jsx as jsx36, jsxs as jsxs27 } from "react/jsx-runtime";
15217
- var KeyValueEditor = React40.forwardRef(
15346
+ import { jsx as jsx37, jsxs as jsxs27 } from "react/jsx-runtime";
15347
+ var KeyValueEditor = React41.forwardRef(
15218
15348
  ({
15219
15349
  pairs,
15220
15350
  onPairsChange,
@@ -15227,7 +15357,7 @@ var KeyValueEditor = React40.forwardRef(
15227
15357
  className,
15228
15358
  style
15229
15359
  }, ref) => {
15230
- const updatePair = React40.useCallback(
15360
+ const updatePair = React41.useCallback(
15231
15361
  (index2, field, value) => {
15232
15362
  const next = [...pairs];
15233
15363
  next[index2] = { ...next[index2], [field]: value };
@@ -15235,14 +15365,14 @@ var KeyValueEditor = React40.forwardRef(
15235
15365
  },
15236
15366
  [pairs, onPairsChange]
15237
15367
  );
15238
- const deletePair = React40.useCallback(
15368
+ const deletePair = React41.useCallback(
15239
15369
  (index2) => {
15240
15370
  const next = pairs.filter((_2, i) => i !== index2);
15241
15371
  onPairsChange(next);
15242
15372
  },
15243
15373
  [pairs, onPairsChange]
15244
15374
  );
15245
- const handleRowFocus = React40.useCallback(
15375
+ const handleRowFocus = React41.useCallback(
15246
15376
  (index2) => {
15247
15377
  if (index2 === pairs.length - 1) {
15248
15378
  onPairsChange([...pairs, { key: "", value: "" }]);
@@ -15250,7 +15380,7 @@ var KeyValueEditor = React40.forwardRef(
15250
15380
  },
15251
15381
  [pairs, onPairsChange]
15252
15382
  );
15253
- const defaultValueIcon = /* @__PURE__ */ jsx36(GitCompare, {});
15383
+ const defaultValueIcon = /* @__PURE__ */ jsx37(GitCompare, {});
15254
15384
  return /* @__PURE__ */ jsxs27(
15255
15385
  "div",
15256
15386
  {
@@ -15259,11 +15389,11 @@ var KeyValueEditor = React40.forwardRef(
15259
15389
  style,
15260
15390
  children: [
15261
15391
  !hideHeader && /* @__PURE__ */ jsxs27("div", { className: KEY_VALUE_EDITOR_TOKENS.header, children: [
15262
- /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.headerCell, children: /* @__PURE__ */ jsx36("span", { className: KEY_VALUE_EDITOR_TOKENS.headerLabel, children: "Key" }) }),
15263
- /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.headerCell, children: /* @__PURE__ */ jsx36("span", { className: KEY_VALUE_EDITOR_TOKENS.headerLabel, children: "Value" }) }),
15264
- /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.headerCellActions, children: toolbar && /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.iconGroup, children: toolbar }) })
15392
+ /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.headerCell, children: /* @__PURE__ */ jsx37("span", { className: KEY_VALUE_EDITOR_TOKENS.headerLabel, children: "Key" }) }),
15393
+ /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.headerCell, children: /* @__PURE__ */ jsx37("span", { className: KEY_VALUE_EDITOR_TOKENS.headerLabel, children: "Value" }) }),
15394
+ /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.headerCellActions, children: toolbar && /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.iconGroup, children: toolbar }) })
15265
15395
  ] }),
15266
- pairs.map((pair, index2) => /* @__PURE__ */ jsx36(
15396
+ pairs.map((pair, index2) => /* @__PURE__ */ jsx37(
15267
15397
  KeyValueRow,
15268
15398
  {
15269
15399
  pair,
@@ -15294,7 +15424,7 @@ function KeyValueRow({
15294
15424
  showDelete
15295
15425
  }) {
15296
15426
  return /* @__PURE__ */ jsxs27("div", { className: KEY_VALUE_EDITOR_TOKENS.row, children: [
15297
- /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.rowCell, children: /* @__PURE__ */ jsx36(
15427
+ /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.rowCell, children: /* @__PURE__ */ jsx37(
15298
15428
  Input,
15299
15429
  {
15300
15430
  inputSize: "sm",
@@ -15309,7 +15439,7 @@ function KeyValueRow({
15309
15439
  hideSupportingText: !pair.keyError
15310
15440
  }
15311
15441
  ) }),
15312
- /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.rowCell, children: /* @__PURE__ */ jsx36(
15442
+ /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.rowCell, children: /* @__PURE__ */ jsx37(
15313
15443
  Input,
15314
15444
  {
15315
15445
  inputSize: "sm",
@@ -15325,21 +15455,21 @@ function KeyValueRow({
15325
15455
  hideSupportingText: !pair.valueError
15326
15456
  }
15327
15457
  ) }),
15328
- /* @__PURE__ */ jsx36("div", { className: KEY_VALUE_EDITOR_TOKENS.rowCellActions, children: showDelete && /* @__PURE__ */ jsx36(
15458
+ /* @__PURE__ */ jsx37("div", { className: KEY_VALUE_EDITOR_TOKENS.rowCellActions, children: showDelete && /* @__PURE__ */ jsx37(
15329
15459
  "button",
15330
15460
  {
15331
15461
  type: "button",
15332
15462
  className: KEY_VALUE_EDITOR_TOKENS.deleteButton,
15333
15463
  onClick: onDelete,
15334
15464
  "aria-label": "Delete row",
15335
- children: /* @__PURE__ */ jsx36(Trash22, {})
15465
+ children: /* @__PURE__ */ jsx37(Trash22, {})
15336
15466
  }
15337
15467
  ) })
15338
15468
  ] });
15339
15469
  }
15340
15470
 
15341
15471
  // src/audio-player/audio-player.tsx
15342
- import * as React41 from "react";
15472
+ import * as React42 from "react";
15343
15473
  import { Pause as Pause3, Play as Play3 } from "lucide-react";
15344
15474
 
15345
15475
  // src/audio-player/variables.ts
@@ -15365,14 +15495,14 @@ var AUDIO_PLAYER_TOKENS = {
15365
15495
  };
15366
15496
 
15367
15497
  // src/audio-player/audio-player.tsx
15368
- import { jsx as jsx37, jsxs as jsxs28 } from "react/jsx-runtime";
15498
+ import { jsx as jsx38, jsxs as jsxs28 } from "react/jsx-runtime";
15369
15499
  function defaultFormatTime(seconds) {
15370
15500
  if (!isFinite(seconds) || seconds < 0) return "0:00";
15371
15501
  const m = Math.floor(seconds / 60);
15372
15502
  const s = Math.floor(seconds % 60);
15373
15503
  return `${m}:${String(s).padStart(2, "0")}`;
15374
15504
  }
15375
- var AudioPlayer = React41.forwardRef(
15505
+ var AudioPlayer = React42.forwardRef(
15376
15506
  ({
15377
15507
  isPlaying,
15378
15508
  currentTime,
@@ -15388,7 +15518,7 @@ var AudioPlayer = React41.forwardRef(
15388
15518
  ...props
15389
15519
  }, ref) => {
15390
15520
  const progress = duration > 0 ? Math.min(1, Math.max(0, currentTime / duration)) : 0;
15391
- const handleWaveformClick = React41.useCallback(
15521
+ const handleWaveformClick = React42.useCallback(
15392
15522
  (e) => {
15393
15523
  if (!onSeek || duration <= 0) return;
15394
15524
  const rect = e.currentTarget.getBoundingClientRect();
@@ -15400,7 +15530,7 @@ var AudioPlayer = React41.forwardRef(
15400
15530
  },
15401
15531
  [onSeek, duration]
15402
15532
  );
15403
- const handleRateClick = React41.useCallback(() => {
15533
+ const handleRateClick = React42.useCallback(() => {
15404
15534
  var _a5;
15405
15535
  if (!onRateChange || !playbackRateOptions.length) return;
15406
15536
  const idx = playbackRateOptions.findIndex((r) => r === playbackRate);
@@ -15417,14 +15547,14 @@ var AudioPlayer = React41.forwardRef(
15417
15547
  ...props,
15418
15548
  children: [
15419
15549
  /* @__PURE__ */ jsxs28("div", { className: AUDIO_PLAYER_TOKENS.leftGroup, children: [
15420
- /* @__PURE__ */ jsx37(
15550
+ /* @__PURE__ */ jsx38(
15421
15551
  "button",
15422
15552
  {
15423
15553
  type: "button",
15424
15554
  onClick: onPlayPause,
15425
15555
  className: AUDIO_PLAYER_TOKENS.btnXs,
15426
15556
  "aria-label": isPlaying ? "Pause" : "Play",
15427
- children: /* @__PURE__ */ jsx37(
15557
+ children: /* @__PURE__ */ jsx38(
15428
15558
  Icon2,
15429
15559
  {
15430
15560
  className: AUDIO_PLAYER_TOKENS.playIcon,
@@ -15434,9 +15564,9 @@ var AudioPlayer = React41.forwardRef(
15434
15564
  )
15435
15565
  }
15436
15566
  ),
15437
- /* @__PURE__ */ jsx37("span", { className: AUDIO_PLAYER_TOKENS.time, children: formatTime(currentTime) })
15567
+ /* @__PURE__ */ jsx38("span", { className: AUDIO_PLAYER_TOKENS.time, children: formatTime(currentTime) })
15438
15568
  ] }),
15439
- /* @__PURE__ */ jsx37(
15569
+ /* @__PURE__ */ jsx38(
15440
15570
  "div",
15441
15571
  {
15442
15572
  className: AUDIO_PLAYER_TOKENS.waveform.wrapper,
@@ -15445,7 +15575,7 @@ var AudioPlayer = React41.forwardRef(
15445
15575
  "aria-valuemin": onSeek ? 0 : void 0,
15446
15576
  "aria-valuemax": onSeek ? duration : void 0,
15447
15577
  "aria-valuenow": onSeek ? currentTime : void 0,
15448
- children: waveform && waveform.length > 0 ? /* @__PURE__ */ jsx37("div", { className: AUDIO_PLAYER_TOKENS.waveform.bars, children: waveform.map((v2, i) => /* @__PURE__ */ jsx37(
15578
+ children: waveform && waveform.length > 0 ? /* @__PURE__ */ jsx38("div", { className: AUDIO_PLAYER_TOKENS.waveform.bars, children: waveform.map((v2, i) => /* @__PURE__ */ jsx38(
15449
15579
  "span",
15450
15580
  {
15451
15581
  className: cn(
@@ -15457,12 +15587,12 @@ var AudioPlayer = React41.forwardRef(
15457
15587
  }
15458
15588
  },
15459
15589
  i
15460
- )) }) : /* @__PURE__ */ jsx37("div", { className: AUDIO_PLAYER_TOKENS.waveform.baseline })
15590
+ )) }) : /* @__PURE__ */ jsx38("div", { className: AUDIO_PLAYER_TOKENS.waveform.baseline })
15461
15591
  }
15462
15592
  ),
15463
15593
  /* @__PURE__ */ jsxs28("div", { className: AUDIO_PLAYER_TOKENS.rightGroup, children: [
15464
- /* @__PURE__ */ jsx37("span", { className: AUDIO_PLAYER_TOKENS.time, children: formatTime(duration) }),
15465
- playbackRate != null && /* @__PURE__ */ jsx37(
15594
+ /* @__PURE__ */ jsx38("span", { className: AUDIO_PLAYER_TOKENS.time, children: formatTime(duration) }),
15595
+ playbackRate != null && /* @__PURE__ */ jsx38(
15466
15596
  "button",
15467
15597
  {
15468
15598
  type: "button",
@@ -15484,7 +15614,7 @@ var AudioPlayer = React41.forwardRef(
15484
15614
  AudioPlayer.displayName = "AudioPlayer";
15485
15615
 
15486
15616
  // src/chat-bubble/chat-bubble.tsx
15487
- import * as React42 from "react";
15617
+ import * as React43 from "react";
15488
15618
  import { User } from "lucide-react";
15489
15619
 
15490
15620
  // src/chat-bubble/variables.ts
@@ -15499,13 +15629,16 @@ var CHAT_BUBBLE_TOKENS = {
15499
15629
  // Row: bubble aligned to the right, avatar after it.
15500
15630
  row: "flex items-end justify-end gap-1 w-full",
15501
15631
  // Default bubble — background/grey #f5f5f5, rounded 12, p 12.
15502
- bubble: "max-w-[80%] p-3 rounded-xl bg-token-grey text-sm font-normal leading-5 text-fg-black",
15632
+ // `min-w-0 break-words` so long unbroken strings (URLs, tokens) wrap
15633
+ // inside the max-w-[80%] cap instead of overflowing horizontally.
15634
+ bubble: "max-w-[80%] min-w-0 p-3 rounded-xl bg-token-grey text-sm font-normal leading-5 text-fg-black break-words",
15503
15635
  // In-Focus: bubble becomes white (sits over the pale-blue row wash).
15504
15636
  bubbleFocused: "bg-token-white",
15505
15637
  // 16px avatar — by default a brand-primary circle.
15506
15638
  avatar: "shrink-0 size-4 rounded-full bg-token-brand-primary overflow-hidden",
15507
- // Timestamp row — right-aligned under the bubble, with a 20px gutter.
15508
- timestampRow: "flex items-center justify-end pr-5"
15639
+ // Timestamp row — timestamp first, then trailing (e.g. tool-call badge);
15640
+ // 8px gap between them, 20px right gutter. Figma: 3575:10751.
15641
+ timestampRow: "flex items-center justify-end gap-2 pr-5"
15509
15642
  },
15510
15643
  user: {
15511
15644
  // Row: avatar first, then text (no bubble).
@@ -15514,7 +15647,7 @@ var CHAT_BUBBLE_TOKENS = {
15514
15647
  avatar: "shrink-0 size-4 rounded-full bg-token-grey flex items-center justify-center text-fg-grey-secondary [&>svg]:size-3",
15515
15648
  // Message text — per Figma: 14px regular, grey-secondary.
15516
15649
  text: "flex-1 min-w-0 text-sm font-normal leading-5 text-fg-grey-secondary break-words",
15517
- timestampRow: "flex items-center pl-5"
15650
+ timestampRow: "flex items-center gap-2 pl-5"
15518
15651
  },
15519
15652
  timestamp: "text-xs font-normal leading-4 tracking-normal text-fg-grey-secondary whitespace-nowrap transition-opacity",
15520
15653
  timestampHidden: "opacity-0 group-hover:opacity-100"
@@ -15524,8 +15657,8 @@ var CHAT_BUBBLE_TOKENS = {
15524
15657
  var agent_avatar_default = "./agent-avatar-ZI4HOQHG.png";
15525
15658
 
15526
15659
  // src/chat-bubble/chat-bubble.tsx
15527
- import { jsx as jsx38, jsxs as jsxs29 } from "react/jsx-runtime";
15528
- var ChatBubbleAgent = React42.forwardRef(
15660
+ import { jsx as jsx39, jsxs as jsxs29 } from "react/jsx-runtime";
15661
+ var ChatBubbleAgent = React43.forwardRef(
15529
15662
  ({
15530
15663
  message,
15531
15664
  timestamp,
@@ -15548,7 +15681,7 @@ var ChatBubbleAgent = React42.forwardRef(
15548
15681
  ...props,
15549
15682
  children: [
15550
15683
  /* @__PURE__ */ jsxs29("div", { className: CHAT_BUBBLE_TOKENS.agent.row, children: [
15551
- /* @__PURE__ */ jsx38(
15684
+ /* @__PURE__ */ jsx39(
15552
15685
  "div",
15553
15686
  {
15554
15687
  className: cn(
@@ -15558,7 +15691,7 @@ var ChatBubbleAgent = React42.forwardRef(
15558
15691
  children: message
15559
15692
  }
15560
15693
  ),
15561
- /* @__PURE__ */ jsx38("div", { className: CHAT_BUBBLE_TOKENS.agent.avatar, children: avatar != null ? avatar : /* @__PURE__ */ jsx38(
15694
+ /* @__PURE__ */ jsx39("div", { className: CHAT_BUBBLE_TOKENS.agent.avatar, children: avatar != null ? avatar : /* @__PURE__ */ jsx39(
15562
15695
  "img",
15563
15696
  {
15564
15697
  src: agent_avatar_default,
@@ -15568,18 +15701,17 @@ var ChatBubbleAgent = React42.forwardRef(
15568
15701
  ) })
15569
15702
  ] }),
15570
15703
  (timestamp || trailing) && /* @__PURE__ */ jsxs29("div", { className: CHAT_BUBBLE_TOKENS.agent.timestampRow, children: [
15571
- trailing,
15572
- timestamp && /* @__PURE__ */ jsx38(
15704
+ timestamp && /* @__PURE__ */ jsx39(
15573
15705
  "span",
15574
15706
  {
15575
15707
  className: cn(
15576
15708
  CHAT_BUBBLE_TOKENS.timestamp,
15577
- trailing && "ml-2",
15578
15709
  !alwaysShowTimestamp && !focused && CHAT_BUBBLE_TOKENS.timestampHidden
15579
15710
  ),
15580
15711
  children: timestamp
15581
15712
  }
15582
- )
15713
+ ),
15714
+ trailing
15583
15715
  ] })
15584
15716
  ]
15585
15717
  }
@@ -15587,7 +15719,7 @@ var ChatBubbleAgent = React42.forwardRef(
15587
15719
  }
15588
15720
  );
15589
15721
  ChatBubbleAgent.displayName = "ChatBubbleAgent";
15590
- var ChatBubbleUser = React42.forwardRef(
15722
+ var ChatBubbleUser = React43.forwardRef(
15591
15723
  ({
15592
15724
  message,
15593
15725
  timestamp,
@@ -15611,22 +15743,21 @@ var ChatBubbleUser = React42.forwardRef(
15611
15743
  ...props,
15612
15744
  children: [
15613
15745
  /* @__PURE__ */ jsxs29("div", { className: CHAT_BUBBLE_TOKENS.user.row, children: [
15614
- /* @__PURE__ */ jsx38("div", { className: cn(CHAT_BUBBLE_TOKENS.user.avatar, "mb-0.5"), children: avatar != null ? avatar : /* @__PURE__ */ jsx38(User, {}) }),
15615
- /* @__PURE__ */ jsx38("div", { className: CHAT_BUBBLE_TOKENS.user.text, children: message })
15746
+ /* @__PURE__ */ jsx39("div", { className: cn(CHAT_BUBBLE_TOKENS.user.avatar, "mb-0.5"), children: avatar != null ? avatar : /* @__PURE__ */ jsx39(User, {}) }),
15747
+ /* @__PURE__ */ jsx39("div", { className: CHAT_BUBBLE_TOKENS.user.text, children: message })
15616
15748
  ] }),
15617
15749
  (timestamp || trailing) && /* @__PURE__ */ jsxs29("div", { className: CHAT_BUBBLE_TOKENS.user.timestampRow, children: [
15618
- trailing,
15619
- timestamp && /* @__PURE__ */ jsx38(
15750
+ timestamp && /* @__PURE__ */ jsx39(
15620
15751
  "span",
15621
15752
  {
15622
15753
  className: cn(
15623
15754
  CHAT_BUBBLE_TOKENS.timestamp,
15624
- trailing && "ml-2",
15625
15755
  !alwaysShowTimestamp && !focused && CHAT_BUBBLE_TOKENS.timestampHidden
15626
15756
  ),
15627
15757
  children: timestamp
15628
15758
  }
15629
- )
15759
+ ),
15760
+ trailing
15630
15761
  ] })
15631
15762
  ]
15632
15763
  }
@@ -15636,7 +15767,7 @@ var ChatBubbleUser = React42.forwardRef(
15636
15767
  ChatBubbleUser.displayName = "ChatBubbleUser";
15637
15768
 
15638
15769
  // src/popover/popover.tsx
15639
- import * as React43 from "react";
15770
+ import * as React44 from "react";
15640
15771
  import { createPortal as createPortal2 } from "react-dom";
15641
15772
  import { Search as Search4 } from "lucide-react";
15642
15773
 
@@ -15673,7 +15804,7 @@ var POPOVER_TOKENS = {
15673
15804
  };
15674
15805
 
15675
15806
  // src/popover/popover.tsx
15676
- import { jsx as jsx39, jsxs as jsxs30 } from "react/jsx-runtime";
15807
+ import { jsx as jsx40, jsxs as jsxs30 } from "react/jsx-runtime";
15677
15808
  function flipSide(side) {
15678
15809
  if (side === "right") return "left";
15679
15810
  if (side === "left") return "right";
@@ -15738,7 +15869,7 @@ function computePosition(triggerRect, popoverRect, side, align, sideOffset) {
15738
15869
  const clampedTop = Math.max(margin, Math.min(primary.top, vh - popoverRect.height - margin));
15739
15870
  return { top: clampedTop, left: clampedLeft };
15740
15871
  }
15741
- var Popover = React43.forwardRef(
15872
+ var Popover = React44.forwardRef(
15742
15873
  ({
15743
15874
  open: controlledOpen,
15744
15875
  onOpenChange,
@@ -15762,21 +15893,21 @@ var Popover = React43.forwardRef(
15762
15893
  var _a5, _b5, _c;
15763
15894
  const { theme } = useTheme();
15764
15895
  const themeClass = theme === "dark" ? "dark" : "light";
15765
- const [internalOpen, setInternalOpen] = React43.useState(defaultOpen);
15896
+ const [internalOpen, setInternalOpen] = React44.useState(defaultOpen);
15766
15897
  const isControlled = controlledOpen !== void 0;
15767
15898
  const open = isControlled ? controlledOpen : internalOpen;
15768
- const triggerRef = React43.useRef(null);
15769
- const popoverRef = React43.useRef(null);
15770
- const [position, setPosition] = React43.useState({ top: 0, left: 0 });
15771
- const [triggerWidth, setTriggerWidth] = React43.useState(0);
15772
- const setOpen = React43.useCallback(
15899
+ const triggerRef = React44.useRef(null);
15900
+ const popoverRef = React44.useRef(null);
15901
+ const [position, setPosition] = React44.useState({ top: 0, left: 0 });
15902
+ const [triggerWidth, setTriggerWidth] = React44.useState(0);
15903
+ const setOpen = React44.useCallback(
15773
15904
  (next) => {
15774
15905
  if (!isControlled) setInternalOpen(next);
15775
15906
  onOpenChange == null ? void 0 : onOpenChange(next);
15776
15907
  },
15777
15908
  [isControlled, onOpenChange]
15778
15909
  );
15779
- React43.useLayoutEffect(() => {
15910
+ React44.useLayoutEffect(() => {
15780
15911
  if (!open) return;
15781
15912
  const t = triggerRef.current;
15782
15913
  const p = popoverRef.current;
@@ -15800,7 +15931,7 @@ var Popover = React43.forwardRef(
15800
15931
  window.removeEventListener("scroll", onScroll, true);
15801
15932
  };
15802
15933
  }, [open, side, align, sideOffset]);
15803
- React43.useEffect(() => {
15934
+ React44.useEffect(() => {
15804
15935
  if (!open) return;
15805
15936
  const onKey = (e) => {
15806
15937
  if (closeOnEscape && e.key === "Escape") setOpen(false);
@@ -15853,9 +15984,9 @@ var Popover = React43.forwardRef(
15853
15984
  style: popoverStyle,
15854
15985
  onClick: (e) => e.stopPropagation(),
15855
15986
  children: [
15856
- search && /* @__PURE__ */ jsx39("div", { className: POPOVER_TOKENS.searchWrapper, children: /* @__PURE__ */ jsxs30("div", { className: POPOVER_TOKENS.search.container, children: [
15857
- /* @__PURE__ */ jsx39(Search4, { className: POPOVER_TOKENS.search.icon }),
15858
- /* @__PURE__ */ jsx39(
15987
+ search && /* @__PURE__ */ jsx40("div", { className: POPOVER_TOKENS.searchWrapper, children: /* @__PURE__ */ jsxs30("div", { className: POPOVER_TOKENS.search.container, children: [
15988
+ /* @__PURE__ */ jsx40(Search4, { className: POPOVER_TOKENS.search.icon }),
15989
+ /* @__PURE__ */ jsx40(
15859
15990
  "input",
15860
15991
  {
15861
15992
  type: "search",
@@ -15871,12 +16002,12 @@ var Popover = React43.forwardRef(
15871
16002
  }
15872
16003
  )
15873
16004
  ] }) }),
15874
- /* @__PURE__ */ jsx39("div", { className: POPOVER_TOKENS.content, children })
16005
+ /* @__PURE__ */ jsx40("div", { className: POPOVER_TOKENS.content, children })
15875
16006
  ]
15876
16007
  }
15877
16008
  );
15878
16009
  return /* @__PURE__ */ jsxs30("div", { className: cn("inline-block relative", wrapperClassName), children: [
15879
- /* @__PURE__ */ jsx39(
16010
+ /* @__PURE__ */ jsx40(
15880
16011
  "div",
15881
16012
  {
15882
16013
  ref: triggerRef,
@@ -15886,7 +16017,7 @@ var Popover = React43.forwardRef(
15886
16017
  }
15887
16018
  ),
15888
16019
  typeof document !== "undefined" && popoverContent && createPortal2(
15889
- /* @__PURE__ */ jsx39("div", { className: cn("lego-land", themeClass), children: popoverContent }),
16020
+ /* @__PURE__ */ jsx40("div", { className: cn("lego-land", themeClass), children: popoverContent }),
15890
16021
  document.body
15891
16022
  )
15892
16023
  ] });
@@ -15957,6 +16088,7 @@ export {
15957
16088
  SelectTrigger,
15958
16089
  SelectValue,
15959
16090
  ShadowDOMWrapper,
16091
+ SidePanel,
15960
16092
  Spinner,
15961
16093
  Stepper,
15962
16094
  StepperBar,