@febkosq8/arc 0.8.9 → 0.8.10

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/arc.js CHANGED
@@ -251,17 +251,24 @@ var xe = ({ className: e, orientation: r = "horizontal", selectedVariant: o, chi
251
251
  role: "separator",
252
252
  className: t("arc-divider w-full border-b border-border", e),
253
253
  ...n
254
- }), ke = ({ items: e, value: n, onChange: r, className: i, placeholder: a = "Select an option", disabled: o, name: s, preventEmpty: c = !1, "data-name": l, "data-required": u }) => {
255
- let d = e.find((e) => String(e.key) === String(n)) ?? null;
254
+ }), U = (e) => e == null || typeof e == "boolean" ? "" : typeof e == "string" || typeof e == "number" || typeof e == "bigint" ? String(e) : Array.isArray(e) ? e.map(U).join("") : a(e) ? U(e.props.children) : "", W = (e) => {
255
+ let t = e.labelTextValue;
256
+ return t === void 0 ? typeof e.label == "string" || typeof e.label == "number" ? String(e.label) : U(e.label) || String(e.key) : t;
257
+ }, ke = ({ items: e, value: n, onChange: r, className: i, placeholder: a = "Select an option", disabled: o, name: s, preventEmpty: c = !1, id: u, inputValue: d, onInputValueChange: h, onKeyDown: g, open: _, onOpenChange: v, renderItem: y, renderValue: S, selectedValueFillsSpace: C = !1, loading: w = !1, loadingLabel: T = "Loading options…", "aria-label": E, "data-name": D, "data-required": O }) => {
258
+ let k = e.find((e) => String(e.key) === String(n)) ?? null, A = k !== null && typeof k.label != "string" && typeof k.label != "number" && k.label !== null && typeof k.label != "boolean", j = k ? S ? S(k) : A ? k.label : null : null, M = j != null && j !== !1, N = C || A && !S, P = l(null);
256
259
  return /* @__PURE__ */ f(m.Root, {
257
260
  items: e,
258
- value: d,
261
+ value: k,
259
262
  onValueChange: (e) => {
260
263
  if (c && e === null) return;
261
- let t = e !== null && d !== null && String(e.key) === String(d.key);
264
+ let t = e !== null && k !== null && String(e.key) === String(k.key);
262
265
  r?.(!c && t ? null : e);
263
266
  },
264
- itemToStringLabel: (e) => e?.label ?? "",
267
+ open: _,
268
+ onOpenChange: (e) => v?.(e),
269
+ inputValue: d,
270
+ onInputValueChange: (e) => h?.(e),
271
+ itemToStringLabel: (e) => e ? W(e) : "",
265
272
  itemToStringValue: (e) => String(e?.key ?? ""),
266
273
  isItemEqualToValue: (e, t) => String(e.key) === String(t.key),
267
274
  name: s,
@@ -269,50 +276,72 @@ var xe = ({ className: e, orientation: r = "horizontal", selectedVariant: o, chi
269
276
  children: /* @__PURE__ */ p("div", {
270
277
  className: t("arc-dropdown relative", i),
271
278
  children: [/* @__PURE__ */ p(m.InputGroup, {
272
- className: t("relative flex h-8 w-full items-center justify-between gap-5 rounded border border-border bg-background pr-2 text-foreground shadow-xs pointer-coarse:h-9", "focus-within:border-transparent focus-within:outline-hidden focus-within:ring-2 focus-within:ring-ring", "data-disabled:cursor-not-allowed data-disabled:bg-muted data-disabled:text-muted-foreground"),
273
- children: [/* @__PURE__ */ f(m.Input, {
274
- className: "h-full grow border-none bg-transparent py-2 pl-3 outline-hidden placeholder:text-muted-foreground focus:ring-0 focus:outline-hidden disabled:cursor-not-allowed",
275
- placeholder: a,
276
- "data-name": l,
277
- "data-required": u,
278
- "data-disabled": o
279
- }), /* @__PURE__ */ f(m.Trigger, {
280
- className: "shrink-0 self-center rounded-md focus:outline-none focus-visible:ring-2 focus-visible:ring-ring",
281
- "aria-label": "Toggle options",
282
- children: /* @__PURE__ */ f(x, {
283
- className: "h-5 w-5 text-foreground",
284
- "aria-hidden": "true"
279
+ className: t("relative flex h-8 w-full items-center justify-between gap-5 overflow-hidden rounded border border-border bg-background pr-2 text-foreground shadow-xs pointer-coarse:h-9", M && (N ? "gap-0" : "gap-2"), "focus-within:border-transparent focus-within:outline-hidden focus-within:ring-2 focus-within:ring-ring", "data-disabled:cursor-not-allowed data-disabled:bg-muted data-disabled:text-muted-foreground"),
280
+ children: [
281
+ M && /* @__PURE__ */ f("span", {
282
+ className: t("ml-3", N ? "mr-2 min-w-0 flex-1 truncate" : "flex shrink-0 items-center"),
283
+ onMouseDown: N ? (e) => {
284
+ e.preventDefault(), P.current?.focus();
285
+ } : void 0,
286
+ children: j
287
+ }),
288
+ /* @__PURE__ */ f(m.Input, {
289
+ ref: P,
290
+ id: u,
291
+ className: t("h-full min-w-0 border-none bg-transparent outline-hidden placeholder:text-muted-foreground focus:ring-0 focus:outline-hidden disabled:cursor-not-allowed", M ? N ? "w-0 flex-none p-0" : "grow py-2 pl-0" : "grow py-2 pl-3"),
292
+ placeholder: a,
293
+ onKeyDown: g,
294
+ "aria-label": E,
295
+ "data-name": D,
296
+ "data-required": O,
297
+ "data-disabled": o
298
+ }),
299
+ /* @__PURE__ */ f(m.Trigger, {
300
+ className: "shrink-0 self-center rounded-md focus:outline-none focus-visible:ring-2 focus-visible:ring-ring",
301
+ "aria-label": "Toggle options",
302
+ children: /* @__PURE__ */ f(x, {
303
+ className: "h-5 w-5 text-foreground",
304
+ "aria-hidden": "true"
305
+ })
285
306
  })
286
- })]
307
+ ]
287
308
  }), /* @__PURE__ */ f(m.Portal, { children: /* @__PURE__ */ f(m.Positioner, {
288
309
  className: "z-50",
289
310
  sideOffset: 8,
290
311
  children: /* @__PURE__ */ p(m.Popup, {
291
312
  className: "max-h-60 min-w-(--anchor-width) overflow-auto rounded-md border border-border bg-popover text-foreground shadow-lg outline-0",
292
- children: [/* @__PURE__ */ f(m.Empty, {
293
- className: "relative cursor-default select-none px-4 py-2 text-muted-foreground empty:hidden",
294
- children: "No values to show."
295
- }), /* @__PURE__ */ f(m.List, { children: (e) => /* @__PURE__ */ p(m.Item, {
296
- value: e,
297
- disabled: e.disabled,
298
- className: t("relative flex h-8 w-full cursor-default select-none items-center gap-2 border-b border-border px-4 py-1 last:border-b-0", "data-selected:font-medium data-selected:text-primary", "data-highlighted:bg-accent data-highlighted:text-primary", "data-disabled:cursor-not-allowed data-disabled:opacity-50"),
299
- children: [/* @__PURE__ */ f(m.ItemIndicator, {
300
- className: "flex items-center",
301
- children: /* @__PURE__ */ f(b, {
302
- className: "h-3 w-3",
303
- "aria-hidden": "true"
304
- })
305
- }), /* @__PURE__ */ f("span", {
306
- title: e.label,
307
- className: "block truncate",
308
- children: e.label
309
- })]
310
- }, e.key) })]
313
+ children: [
314
+ w && /* @__PURE__ */ f("div", {
315
+ role: "status",
316
+ className: "px-4 py-2 text-sm text-muted-foreground",
317
+ children: T
318
+ }),
319
+ /* @__PURE__ */ f(m.Empty, {
320
+ className: t("relative cursor-default select-none px-4 py-2 text-muted-foreground empty:hidden", w && "hidden"),
321
+ children: "No values to show."
322
+ }),
323
+ /* @__PURE__ */ f(m.List, { children: (e) => /* @__PURE__ */ p(m.Item, {
324
+ value: e,
325
+ disabled: e.disabled,
326
+ className: t("relative flex h-8 w-full cursor-default select-none items-center gap-2 border-b border-border px-4 py-1 last:border-b-0", "data-selected:font-medium data-selected:text-primary", "data-highlighted:bg-accent data-highlighted:text-primary", "data-disabled:cursor-not-allowed data-disabled:opacity-50"),
327
+ children: [/* @__PURE__ */ f(m.ItemIndicator, {
328
+ className: "flex items-center",
329
+ children: /* @__PURE__ */ f(b, {
330
+ className: "h-3 w-3",
331
+ "aria-hidden": "true"
332
+ })
333
+ }), y ? y(e) : /* @__PURE__ */ f("div", {
334
+ title: W(e),
335
+ className: "min-w-0 flex-1 truncate",
336
+ children: e.label
337
+ })]
338
+ }, e.key) })
339
+ ]
311
340
  })
312
341
  }) })]
313
342
  })
314
343
  });
315
- }, U = ({ data: e, className: n, ...r }) => {
344
+ }, G = ({ data: e, className: n, ...r }) => {
316
345
  let i = Array.isArray(e) ? e.join(", ") : typeof e == "string" ? e : null;
317
346
  return /* @__PURE__ */ f("em", {
318
347
  role: "alert",
@@ -322,7 +351,7 @@ var xe = ({ className: e, orientation: r = "horizontal", selectedVariant: o, chi
322
351
  children: i
323
352
  });
324
353
  }, Ae = /* @__PURE__ */ "*.+.×.÷.=.~.!.?.@.#.%.&.§.¶.※.◇.◆.○.●.△.▽.□.■.♠.♣.♦.♤.♧.♢.♪.♫.∴.∵".split(".");
325
- function W(e, t, n) {
354
+ function K(e, t, n) {
326
355
  let r = Math.sin((e + 1) * 12.9898 + t * 78.233 + n * 37.719) * 43758.5453;
327
356
  return r - Math.floor(r);
328
357
  }
@@ -387,10 +416,10 @@ var je = [
387
416
  gridTemplateRows: `repeat(${n}, minmax(0, 1fr))`
388
417
  },
389
418
  children: Array.from({ length: n * r }, (e, o) => /* @__PURE__ */ f("span", {
390
- className: t(Me({ shape: s === "mixed" ? y[o] ?? C[Math.floor(W(o, n, r) * C.length)] : s })),
419
+ className: t(Me({ shape: s === "mixed" ? y[o] ?? C[Math.floor(K(o, n, r) * C.length)] : s })),
391
420
  onAnimationIteration: () => {
392
421
  s === "mixed" && b((e) => {
393
- let t = [...e], i = t[o] ?? C[Math.floor(W(o, n, r) * C.length)], a = C.filter((e) => e !== i);
422
+ let t = [...e], i = t[o] ?? C[Math.floor(K(o, n, r) * C.length)], a = C.filter((e) => e !== i);
394
423
  return t[o] = a.length > 0 ? a[Math.floor(Math.random() * a.length)] : i, t;
395
424
  }), l.length > 1 && S((e) => {
396
425
  let t = [...e];
@@ -401,8 +430,8 @@ var je = [
401
430
  });
402
431
  },
403
432
  style: {
404
- animationDelay: l.length > 1 ? `${o / (n * r) * 1200}ms` : `${-W(o, n, r) * 1200}ms`,
405
- animationDuration: l.length > 1 ? "1200ms" : `${900 + W(o, n, r) * 600}ms`,
433
+ animationDelay: l.length > 1 ? `${o / (n * r) * 1200}ms` : `${-K(o, n, r) * 1200}ms`,
434
+ animationDuration: l.length > 1 ? "1200ms" : `${900 + K(o, n, r) * 600}ms`,
406
435
  backgroundColor: l.length > 0 ? l[(o + (x[o] ?? 0)) % l.length] : void 0,
407
436
  fontSize: `${Math.min(i / Math.max(n, r), a) * .4}px`,
408
437
  maxWidth: a,
@@ -415,7 +444,7 @@ var je = [
415
444
  }, o))
416
445
  })
417
446
  });
418
- }, G = ({ cardContent: e, children: n, trigger: r = "hover", triggerRender: i, side: a = "bottom", align: o = "center", className: s, open: c, onOpenChange: l }) => /* @__PURE__ */ p(A.Root, {
447
+ }, q = ({ cardContent: e, children: n, trigger: r = "hover", triggerRender: i, side: a = "bottom", align: o = "center", className: s, open: c, onOpenChange: l }) => /* @__PURE__ */ p(A.Root, {
419
448
  open: c,
420
449
  onOpenChange: l,
421
450
  children: [/* @__PURE__ */ f(A.Trigger, {
@@ -445,7 +474,7 @@ var je = [
445
474
  htmlFor: e,
446
475
  children: n
447
476
  }),
448
- r != null && r !== !1 && /* @__PURE__ */ f(G, {
477
+ r != null && r !== !1 && /* @__PURE__ */ f(q, {
449
478
  trigger: "hover",
450
479
  triggerRender: /* @__PURE__ */ f("button", {
451
480
  type: "button",
@@ -461,10 +490,10 @@ var je = [
461
490
  "aria-hidden": "true"
462
491
  })
463
492
  }),
464
- s && (Array.isArray(s) ? s.length > 0 && /* @__PURE__ */ f(U, { data: s }) : /* @__PURE__ */ f(U, { data: s }))
493
+ s && (Array.isArray(s) ? s.length > 0 && /* @__PURE__ */ f(G, { data: s }) : /* @__PURE__ */ f(G, { data: s }))
465
494
  ]
466
495
  });
467
- }, Fe = e("arc-input rounded border text-foreground placeholder:text-muted-foreground focus:border-transparent focus:outline-hidden focus:ring-2 focus:ring-ring disabled:cursor-not-allowed disabled:border-muted disabled:bg-muted", {
496
+ }, Fe = e("arc-input overflow-hidden rounded border text-foreground placeholder:text-muted-foreground focus:border-transparent focus:outline-hidden focus:ring-2 focus:ring-ring disabled:cursor-not-allowed disabled:border-muted disabled:bg-muted", {
468
497
  variants: {
469
498
  variant: {
470
499
  default: "border-border bg-background",
@@ -472,14 +501,14 @@ var je = [
472
501
  },
473
502
  as: {
474
503
  input: "h-8 pointer-coarse:h-9 p-1 pl-2",
475
- textarea: "min-h-50 max-h-250 resize-y overflow-auto! p-2 whitespace-pre-wrap"
504
+ textarea: "min-h-50 max-h-250 resize-y p-2 whitespace-pre-wrap"
476
505
  }
477
506
  },
478
507
  defaultVariants: {
479
508
  variant: "default",
480
509
  as: "input"
481
510
  }
482
- }), K = ({ as: e = "input", className: n, variant: r, ...i }) => {
511
+ }), J = ({ as: e = "input", className: n, variant: r, ...i }) => {
483
512
  let a = t(Fe({
484
513
  as: e,
485
514
  variant: r
@@ -501,7 +530,7 @@ var je = [
501
530
  "outline-warning": "border-warning bg-background text-warning"
502
531
  } },
503
532
  defaultVariants: { variant: "outline-secondary" }
504
- }), q = (e) => {
533
+ }), Y = (e) => {
505
534
  let { className: n, variant: r, hoverable: i = !0, hoverLift: a = !0, hoverBorder: o = !0, hoverGradient: s = !0, postHeaderBorder: c = !0, preFooterBorder: l = !0, onPointerMove: u, ...d } = e, p = i && a, m = i && o, h = i && s;
506
535
  return /* @__PURE__ */ f("div", {
507
536
  className: t(Ie({ variant: r }), h && "arc-card-cursor-border", c && "[&_.arc-card-header]:border-b", !c && "[&_.arc-card-header]:border-b-0", l && "[&_.arc-card-footer]:border-t", !l && "[&_.arc-card-footer]:border-t-0", (p || m) && "transition-[border-color,transform] duration-300 ease-out", p && "hover:-translate-y-1", m && "hover:border-primary", n),
@@ -513,19 +542,19 @@ var je = [
513
542
  ...d
514
543
  });
515
544
  };
516
- q.Header = (e) => {
545
+ Y.Header = (e) => {
517
546
  let { className: n, ...r } = e;
518
547
  return /* @__PURE__ */ f("h2", {
519
548
  className: t("arc-card-header flex w-full typography-heading-3 flex-col border-foreground/40 px-0 pb-1", n),
520
549
  ...r
521
550
  });
522
- }, q.Content = (e) => {
551
+ }, Y.Content = (e) => {
523
552
  let { className: n, ...r } = e;
524
553
  return /* @__PURE__ */ f("div", {
525
554
  className: t("arc-card-content typography-paragraph mt-0! w-full justify-between px-0 py-1 whitespace-pre-wrap", n),
526
555
  ...r
527
556
  });
528
- }, q.Footer = (e) => {
557
+ }, Y.Footer = (e) => {
529
558
  let { className: n, ...r } = e;
530
559
  return /* @__PURE__ */ f("div", {
531
560
  className: t("arc-card-footer typography-muted mt-auto mb-0 flex w-full items-end justify-start border-foreground/40 px-0 pt-1", n),
@@ -640,7 +669,7 @@ var Le = class e {
640
669
  }
641
670
  }, Re = ({ value: e, format: t = "$ISO$ ($RELATIVE$)", ...n }) => {
642
671
  let r = c(() => e ? Le.getFormattedTime(e, t) : "", [e, t]);
643
- return /* @__PURE__ */ f(K, {
672
+ return /* @__PURE__ */ f(J, {
644
673
  type: "text",
645
674
  disabled: !0,
646
675
  readOnly: !0,
@@ -749,7 +778,7 @@ var Le = class e {
749
778
  "outline-destructive": "bg-destructive text-destructive-foreground ring-2 ring-destructive ring-offset-2",
750
779
  "outline-ghost": "bg-accent text-accent-foreground ring-2 ring-ring ring-offset-2",
751
780
  "outline-warning": "bg-warning text-warning-foreground ring-2 ring-warning ring-offset-2"
752
- }, J = ({ active: e = !1, className: n, size: r = "md", variant: i = "pill", ...a }) => /* @__PURE__ */ f("button", {
781
+ }, X = ({ active: e = !1, className: n, size: r = "md", variant: i = "pill", ...a }) => /* @__PURE__ */ f("button", {
753
782
  type: "button",
754
783
  className: t(Ve({
755
784
  variant: i,
@@ -757,10 +786,10 @@ var Le = class e {
757
786
  }), e && He[i], n),
758
787
  "aria-pressed": e,
759
788
  ...a
760
- }), Ue = ({ children: e }) => n.toArray(e).map((e, t) => /* @__PURE__ */ p(r, { children: [t > 0 && /* @__PURE__ */ f(M.Separator, { className: "mx-2 h-px bg-border" }), e] }, t)), Y = Object.assign(({ className: e, contentClassName: n, active: r, activeClassName: i, buttonText: a, children: o }) => /* @__PURE__ */ p(M.Root, {
789
+ }), Ue = ({ children: e }) => n.toArray(e).map((e, t) => /* @__PURE__ */ p(r, { children: [t > 0 && /* @__PURE__ */ f(M.Separator, { className: "mx-2 h-px bg-border" }), e] }, t)), Z = Object.assign(({ className: e, contentClassName: n, active: r, activeClassName: i, buttonText: a, children: o }) => /* @__PURE__ */ p(M.Root, {
761
790
  loopFocus: !0,
762
791
  children: [/* @__PURE__ */ p(M.Trigger, {
763
- render: /* @__PURE__ */ f(J, {
792
+ render: /* @__PURE__ */ f(X, {
764
793
  active: r,
765
794
  className: t("w-fit", r && i, e)
766
795
  }),
@@ -868,7 +897,7 @@ var Le = class e {
868
897
  onValueChange: (e) => {
869
898
  l && e.length === 0 || i?.(e);
870
899
  },
871
- itemToStringLabel: (e) => e?.label ?? "",
900
+ itemToStringLabel: (e) => e ? W(e) : "",
872
901
  itemToStringValue: (e) => String(e?.key ?? ""),
873
902
  isItemEqualToValue: (e, t) => String(e.key) === String(t.key),
874
903
  name: c,
@@ -876,7 +905,7 @@ var Le = class e {
876
905
  children: /* @__PURE__ */ p("div", {
877
906
  className: t("arc-dropdown-multi relative", a),
878
907
  children: [/* @__PURE__ */ p(m.InputGroup, {
879
- className: t("relative flex min-h-8 w-full items-center justify-between gap-1.5 rounded border border-border bg-background py-1 pr-2 pl-2 text-foreground shadow-xs pointer-coarse:min-h-9", "focus-within:border-transparent focus-within:outline-hidden focus-within:ring-2 focus-within:ring-ring", "data-disabled:cursor-not-allowed data-disabled:bg-muted data-disabled:text-muted-foreground"),
908
+ className: t("relative flex min-h-8 w-full items-center justify-between gap-1.5 overflow-hidden rounded border border-border bg-background py-1 pr-2 pl-2 text-foreground shadow-xs pointer-coarse:min-h-9", "focus-within:border-transparent focus-within:outline-hidden focus-within:ring-2 focus-within:ring-ring", "data-disabled:cursor-not-allowed data-disabled:bg-muted data-disabled:text-muted-foreground"),
880
909
  children: [/* @__PURE__ */ f(m.Value, { children: (n) => /* @__PURE__ */ p("div", {
881
910
  className: "flex min-w-0 grow flex-wrap items-center gap-1.5",
882
911
  children: [/* @__PURE__ */ f(m.Chips, {
@@ -884,11 +913,12 @@ var Le = class e {
884
913
  children: n.map((e) => /* @__PURE__ */ p(m.Chip, {
885
914
  className: "inline-flex items-center gap-1 rounded-md border border-border bg-muted px-2 py-0.5 text-sm text-foreground",
886
915
  children: [/* @__PURE__ */ f("span", {
916
+ title: W(e),
887
917
  className: "max-w-32 truncate",
888
918
  children: e.label
889
919
  }), !s && (!l || n.length > 1) && /* @__PURE__ */ f(m.ChipRemove, {
890
920
  className: "ml-0.5 cursor-pointer rounded-md hover:text-destructive focus:outline-none focus-visible:ring-2 focus-visible:ring-ring",
891
- "aria-label": `Remove ${e.label}`,
921
+ "aria-label": `Remove ${W(e)}`,
892
922
  children: /* @__PURE__ */ f(z, {
893
923
  className: "h-3 w-3",
894
924
  "aria-hidden": "true"
@@ -929,9 +959,9 @@ var Le = class e {
929
959
  className: "h-3 w-3",
930
960
  "aria-hidden": "true"
931
961
  })
932
- }), /* @__PURE__ */ f("span", {
933
- title: e.label,
934
- className: "block truncate",
962
+ }), /* @__PURE__ */ f("div", {
963
+ title: W(e),
964
+ className: "min-w-0 flex-1 truncate",
935
965
  children: e.label
936
966
  })]
937
967
  }, e.key) })]
@@ -939,23 +969,27 @@ var Le = class e {
939
969
  }) })]
940
970
  })
941
971
  });
942
- }, X = ({ id: e, value: n, onChange: r, data: i, className: a, disabled: o, placeholder: s, ...c }) => /* @__PURE__ */ p(B.Root, {
972
+ }, Q = ({ id: e, value: n, onChange: r, data: i, className: a, disabled: o, placeholder: s, ...c }) => /* @__PURE__ */ p(B.Root, {
943
973
  value: n,
944
974
  onValueChange: (e) => {
945
975
  e !== null && r(e);
946
976
  },
947
977
  disabled: o,
948
- items: i.map((e) => ({
949
- value: e.key,
950
- label: typeof e.label == "string" ? e.label : e.key
951
- })),
978
+ items: i.map((e) => {
979
+ let t = e.labelTextValue ?? (typeof e.label == "string" || typeof e.label == "number" ? String(e.label) : U(e.label) || e.key);
980
+ return {
981
+ value: e.key,
982
+ label: t
983
+ };
984
+ }),
952
985
  ...c,
953
986
  children: [/* @__PURE__ */ p(B.Trigger, {
954
987
  id: e,
955
988
  className: t("arc-select flex h-8 w-full items-center gap-2 overflow-hidden rounded border border-border bg-background px-2 py-1 text-foreground shadow-xs focus:outline-none focus-visible:ring-2 focus-visible:ring-ring pointer-coarse:h-9", "disabled:cursor-not-allowed disabled:bg-muted disabled:text-muted-foreground", a),
956
989
  children: [/* @__PURE__ */ f(B.Value, {
957
990
  placeholder: s,
958
- className: "min-w-0 flex-1 truncate text-left"
991
+ className: "min-w-0 flex-1 truncate text-left",
992
+ children: (e) => i.find((t) => t.key === e)?.label ?? s
959
993
  }), /* @__PURE__ */ f(B.Icon, {
960
994
  className: "shrink-0",
961
995
  children: /* @__PURE__ */ f(x, {
@@ -1002,7 +1036,7 @@ var Le = class e {
1002
1036
  ...n
1003
1037
  }), Ye = ({ className: e, variant: n = "outline", size: r, ...i }) => /* @__PURE__ */ f(V.Tab, {
1004
1038
  className: e,
1005
- render: (e, i) => /* @__PURE__ */ f(J, {
1039
+ render: (e, i) => /* @__PURE__ */ f(X, {
1006
1040
  ...e,
1007
1041
  "aria-pressed": void 0,
1008
1042
  variant: n,
@@ -1045,14 +1079,14 @@ var Le = class e {
1045
1079
  }), Qe = (e, t, n, r) => {
1046
1080
  let i = e.getValue(t), a = ee(i, n);
1047
1081
  return r({ itemRank: a }), a.passed;
1048
- }, Z = {
1082
+ }, $e = {
1049
1083
  fuzzy: Qe,
1050
1084
  includesString: ce,
1051
1085
  select: (e, t, n) => {
1052
1086
  let r = e.getValue(t);
1053
1087
  return Array.isArray(r) ? r.some((e) => String(e) === String(n)) : typeof r == "string" && r.includes(",") ? r.split(",").map((e) => e.trim()).includes(String(n)) : String(r) === String(n);
1054
1088
  }
1055
- }, Q = ve({
1089
+ }, et = ve({
1056
1090
  columnMeta: {},
1057
1091
  columnFilteringFeature: te,
1058
1092
  columnResizingFeature: ne,
@@ -1072,23 +1106,23 @@ var Le = class e {
1072
1106
  text: ge,
1073
1107
  textCaseSensitive: _e
1074
1108
  },
1075
- filterFns: Z
1109
+ filterFns: $e
1076
1110
  });
1077
- function $e(e) {
1078
- return Object.prototype.hasOwnProperty.call(Z, e);
1111
+ function tt(e) {
1112
+ return Object.prototype.hasOwnProperty.call($e, e);
1079
1113
  }
1080
- function et(e, t) {
1114
+ function nt(e, t) {
1081
1115
  if (e !== !1) {
1082
1116
  if (e === void 0) return t ? "select" : void 0;
1083
- if (typeof e == "function" || e === "auto" || $e(e)) return e;
1084
- throw Error(`Unsupported table filterFn "${e}". Use "auto" or one of: ${Object.keys(Z).join(", ")}.`);
1117
+ if (typeof e == "function" || e === "auto" || tt(e)) return e;
1118
+ throw Error(`Unsupported table filterFn "${e}". Use "auto" or one of: ${Object.keys($e).join(", ")}.`);
1085
1119
  }
1086
1120
  }
1087
- function tt(e) {
1088
- if (e === void 0 || e === "auto" || typeof e == "function" || Object.prototype.hasOwnProperty.call(Q.sortFns, e)) return e;
1089
- throw Error(`Unsupported table sortingFn "${e}". Use "auto" or one of: ${Object.keys(Q.sortFns).join(", ")}.`);
1121
+ function rt(e) {
1122
+ if (e === void 0 || e === "auto" || typeof e == "function" || Object.prototype.hasOwnProperty.call(et.sortFns, e)) return e;
1123
+ throw Error(`Unsupported table sortingFn "${e}". Use "auto" or one of: ${Object.keys(et.sortFns).join(", ")}.`);
1090
1124
  }
1091
- var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a = !0, showFilters: o = !0, showSorting: l = !0 }) => {
1125
+ var it = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a = !0, showFilters: o = !0, showSorting: l = !0 }) => {
1092
1126
  let d = s(), [m, b] = u({
1093
1127
  pageIndex: 0,
1094
1128
  pageSize: r
@@ -1098,13 +1132,13 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1098
1132
  enableResizing: e.enableResizing,
1099
1133
  enableColumnFilter: e.filterFn !== !1 && e.enableColumnFilter,
1100
1134
  enableSorting: e.enableSorting,
1101
- sortFn: tt(e.sortingFn),
1135
+ sortFn: rt(e.sortingFn),
1102
1136
  ...e.sortUndefined === void 0 ? {} : { sortUndefined: e.sortUndefined },
1103
1137
  enableHiding: e.enableHiding ?? !0,
1104
1138
  size: e.size,
1105
1139
  minSize: e.minSize ?? 50,
1106
1140
  maxSize: e.maxSize ?? 1e3,
1107
- filterFn: et(e.filterFn, e.filterSelectOptions),
1141
+ filterFn: nt(e.filterFn, e.filterSelectOptions),
1108
1142
  meta: {
1109
1143
  headerLabel: e.header,
1110
1144
  filterSelectOptions: e.filterSelectOptions,
@@ -1159,7 +1193,7 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1159
1193
  onColumnFiltersChange: w,
1160
1194
  onGlobalFilterChange: D,
1161
1195
  globalFilterFn: Qe,
1162
- features: Q,
1196
+ features: et,
1163
1197
  defaultColumn: {
1164
1198
  size: 200,
1165
1199
  minSize: 50,
@@ -1184,7 +1218,7 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1184
1218
  title: "Clear filters and sorting",
1185
1219
  type: "button",
1186
1220
  children: [/* @__PURE__ */ f(E, { className: "mr-1.5 h-3 w-3" }), "Clear filters and sorting"]
1187
- }), /* @__PURE__ */ f(at, { table: P })]
1221
+ }), /* @__PURE__ */ f(st, { table: P })]
1188
1222
  }),
1189
1223
  /* @__PURE__ */ p("nav", {
1190
1224
  "aria-label": "Table pagination",
@@ -1293,7 +1327,7 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1293
1327
  /* @__PURE__ */ p("label", {
1294
1328
  htmlFor: `${d}-page-size`,
1295
1329
  className: "text-muted-foreground flex w-full items-center justify-between gap-2 text-xs md:w-auto",
1296
- children: ["Rows per page", /* @__PURE__ */ f(X, {
1330
+ children: ["Rows per page", /* @__PURE__ */ f(Q, {
1297
1331
  id: `${d}-page-size`,
1298
1332
  value: P.state.pagination.pageSize.toString(),
1299
1333
  onChange: (e) => {
@@ -1332,7 +1366,7 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1332
1366
  htmlFor: `${d}-sort`,
1333
1367
  className: "text-muted-foreground mb-1 block text-xs font-medium",
1334
1368
  children: "Sort by"
1335
- }), /* @__PURE__ */ f(X, {
1369
+ }), /* @__PURE__ */ f(Q, {
1336
1370
  id: `${d}-sort`,
1337
1371
  value: O[0]?.id ?? "__none__",
1338
1372
  onChange: (e) => {
@@ -1376,7 +1410,7 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1376
1410
  htmlFor: n,
1377
1411
  className: "text-muted-foreground mb-1 block text-xs font-medium",
1378
1412
  children: t
1379
- }), /* @__PURE__ */ f(it, {
1413
+ }), /* @__PURE__ */ f(ot, {
1380
1414
  column: e,
1381
1415
  idPrefix: `${d}-`
1382
1416
  })]
@@ -1446,7 +1480,7 @@ var nt = ({ data: e, columnDef: n, pageSize: r = 10, className: i, showHeader: a
1446
1480
  ]
1447
1481
  });
1448
1482
  };
1449
- function rt({ value: e, onChange: t, debounce: n = 500, ...r }) {
1483
+ function at({ value: e, onChange: t, debounce: n = 500, ...r }) {
1450
1484
  let [i, a] = u(e);
1451
1485
  return o(() => {
1452
1486
  a(e);
@@ -1459,14 +1493,14 @@ function rt({ value: e, onChange: t, debounce: n = 500, ...r }) {
1459
1493
  i,
1460
1494
  n,
1461
1495
  t
1462
- ]), /* @__PURE__ */ f(K, {
1496
+ ]), /* @__PURE__ */ f(J, {
1463
1497
  ...r,
1464
1498
  value: i,
1465
1499
  onChange: (e) => a(e.target.value),
1466
1500
  autoComplete: "off"
1467
1501
  });
1468
1502
  }
1469
- function it({ column: e, idPrefix: t = "" }) {
1503
+ function ot({ column: e, idPrefix: t = "" }) {
1470
1504
  let n = `${t}${e.id}-filter`, r = {
1471
1505
  includesString: "Includes string",
1472
1506
  equalsString: "Equals string",
@@ -1474,7 +1508,7 @@ function it({ column: e, idPrefix: t = "" }) {
1474
1508
  equals: "Equals",
1475
1509
  fuzzy: "Fuzzy"
1476
1510
  }, i = e.getFilterValue(), a = e.columnDef.meta?.filterSelectOptions;
1477
- return a ? /* @__PURE__ */ f(X, {
1511
+ return a ? /* @__PURE__ */ f(Q, {
1478
1512
  id: n,
1479
1513
  value: i ?? "__all__",
1480
1514
  onChange: (t) => e.setFilterValue(t === "__all__" ? void 0 : t),
@@ -1486,7 +1520,7 @@ function it({ column: e, idPrefix: t = "" }) {
1486
1520
  key: e.value,
1487
1521
  label: e.label
1488
1522
  }))]
1489
- }) : /* @__PURE__ */ f(rt, {
1523
+ }) : /* @__PURE__ */ f(at, {
1490
1524
  id: n,
1491
1525
  type: "text",
1492
1526
  name: e.id,
@@ -1497,8 +1531,8 @@ function it({ column: e, idPrefix: t = "" }) {
1497
1531
  className: "border-border text-foreground placeholder:text-muted-foreground focus:ring-ring w-full rounded border bg-transparent px-2 py-1 text-xs shadow-sm focus:border-transparent focus:ring-1 focus:outline-hidden"
1498
1532
  });
1499
1533
  }
1500
- function at({ table: e }) {
1501
- return /* @__PURE__ */ p(G, {
1534
+ function st({ table: e }) {
1535
+ return /* @__PURE__ */ p(q, {
1502
1536
  trigger: "click",
1503
1537
  triggerRender: /* @__PURE__ */ f(H, {
1504
1538
  variant: "outline-secondary",
@@ -1528,31 +1562,31 @@ function at({ table: e }) {
1528
1562
  });
1529
1563
  }
1530
1564
  // components/text-link.tsx
1531
- var ot = ({ className: e, href: n, text: r, target: i = "_blank", rel: a, ...o }) => /* @__PURE__ */ f("a", {
1565
+ var ct = ({ className: e, href: n, text: r, target: i = "_blank", rel: a, ...o }) => /* @__PURE__ */ f("a", {
1532
1566
  className: t("arc-text-link rounded-md text-primary underline transition hover:text-primary/80 focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-opacity-75", e),
1533
1567
  href: n,
1534
1568
  target: i,
1535
1569
  rel: a ?? (i === "_blank" ? "noopener noreferrer" : void 0),
1536
1570
  ...o,
1537
1571
  children: r
1538
- }), st = ({ checked: e = !1, onChange: n, disabled: r = !1, variant: i = "primary", children: a, ...o }) => /* @__PURE__ */ f(be.Root, {
1572
+ }), lt = ({ checked: e = !1, onChange: n, disabled: r = !1, variant: i = "primary", children: a, ...o }) => /* @__PURE__ */ f(be.Root, {
1539
1573
  checked: e,
1540
1574
  disabled: r,
1541
1575
  onCheckedChange: n,
1542
- className: t("arc-switch", ct({
1576
+ className: t("arc-switch", ut({
1543
1577
  variant: i,
1544
1578
  disabled: r
1545
1579
  })),
1546
1580
  ...o,
1547
1581
  children: a ? a(e) : /* @__PURE__ */ f(be.Thumb, {
1548
1582
  "aria-hidden": "true",
1549
- className: lt({
1583
+ className: dt({
1550
1584
  variant: i,
1551
1585
  checked: e,
1552
1586
  disabled: r
1553
1587
  })
1554
1588
  })
1555
- }), ct = e("relative inline-flex h-7 w-12 items-center rounded-full border border-border bg-muted transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 hover:not-data-disabled:ring-2 hover:not-data-disabled:ring-ring/60 data-disabled:cursor-not-allowed data-disabled:opacity-60", { variants: {
1589
+ }), ut = e("relative inline-flex h-7 w-12 items-center rounded-full border border-border bg-muted transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 hover:not-data-disabled:ring-2 hover:not-data-disabled:ring-ring/60 data-disabled:cursor-not-allowed data-disabled:opacity-60", { variants: {
1556
1590
  variant: {
1557
1591
  danger: "data-checked:bg-destructive",
1558
1592
  success: "data-checked:bg-success",
@@ -1563,7 +1597,7 @@ var ot = ({ className: e, href: n, text: r, target: i = "_blank", rel: a, ...o }
1563
1597
  true: "ring-2 ring-border",
1564
1598
  false: ""
1565
1599
  }
1566
- } }), lt = e("absolute top-1/2 inline-block h-5 w-5 -translate-y-1/2 transform rounded-full border shadow-sm transition-[left,translate,background-color,border-color] duration-300 ease-out", {
1600
+ } }), dt = e("absolute top-1/2 inline-block h-5 w-5 -translate-y-1/2 transform rounded-full border shadow-sm transition-[left,translate,background-color,border-color] duration-300 ease-out", {
1567
1601
  variants: {
1568
1602
  variant: {
1569
1603
  primary: "",
@@ -1656,7 +1690,7 @@ var ot = ({ className: e, href: n, text: r, target: i = "_blank", rel: a, ...o }
1656
1690
  className: "border-success bg-success/70"
1657
1691
  }
1658
1692
  ]
1659
- }), ut = {
1693
+ }), ft = {
1660
1694
  light: L,
1661
1695
  dark: I,
1662
1696
  system: F
@@ -1664,25 +1698,25 @@ var ot = ({ className: e, href: n, text: r, target: i = "_blank", rel: a, ...o }
1664
1698
  light: "Light",
1665
1699
  dark: "Dark",
1666
1700
  system: "System"
1667
- }, dt = "theme", ft = (e) => e === "dark" || e === "system" && typeof window < "u" && window.matchMedia("(prefers-color-scheme: dark)").matches, pt = () => {
1701
+ }, pt = "theme", mt = (e) => e === "dark" || e === "system" && typeof window < "u" && window.matchMedia("(prefers-color-scheme: dark)").matches, ht = () => {
1668
1702
  if (typeof window > "u") return "system";
1669
- let e = window.localStorage.getItem(dt);
1703
+ let e = window.localStorage.getItem(pt);
1670
1704
  return e === "light" || e === "dark" || e === "system" ? e : "system";
1671
- }, mt = (e) => e === "system" ? "light" : e === "light" ? "dark" : "system";
1672
- function ht({ variant: e = "dropdown", showLabel: n = !1 }) {
1673
- let [r, i] = u(pt);
1705
+ }, gt = (e) => e === "system" ? "light" : e === "light" ? "dark" : "system";
1706
+ function _t({ variant: e = "dropdown", showLabel: n = !1 }) {
1707
+ let [r, i] = u(ht);
1674
1708
  o(() => {
1675
- typeof window < "u" && (document.documentElement.classList.toggle("dark", ft(r)), window.localStorage.setItem(dt, r));
1709
+ typeof window < "u" && (document.documentElement.classList.toggle("dark", mt(r)), window.localStorage.setItem(pt, r));
1676
1710
  }, [r]);
1677
1711
  let a = () => {
1678
- i(mt(r));
1712
+ i(gt(r));
1679
1713
  };
1680
1714
  if (e === "toggle") {
1681
- let e = ut[r], t = mt(r);
1715
+ let e = ft[r], t = gt(r);
1682
1716
  return /* @__PURE__ */ f("div", {
1683
1717
  className: "arc-theme-switcher",
1684
- children: /* @__PURE__ */ p(J, {
1685
- active: ft(r),
1718
+ children: /* @__PURE__ */ p(X, {
1719
+ active: mt(r),
1686
1720
  "aria-label": `Switch to ${t} theme`,
1687
1721
  title: `Switch to ${t} theme`,
1688
1722
  onClick: a,
@@ -1691,18 +1725,18 @@ function ht({ variant: e = "dropdown", showLabel: n = !1 }) {
1691
1725
  })
1692
1726
  });
1693
1727
  }
1694
- let s = ut[r];
1728
+ let s = ft[r];
1695
1729
  return /* @__PURE__ */ f("div", {
1696
1730
  className: "arc-theme-switcher",
1697
- children: /* @__PURE__ */ p(Y, {
1731
+ children: /* @__PURE__ */ p(Z, {
1698
1732
  className: "gap-3",
1699
1733
  contentClassName: "min-w-(--anchor-width)",
1700
1734
  buttonText: /* @__PURE__ */ p(d, { children: [/* @__PURE__ */ f(s, { "aria-hidden": "true" }), n && $[r]] }),
1701
1735
  children: [
1702
- /* @__PURE__ */ f(Y.Item, {
1736
+ /* @__PURE__ */ f(Z.Item, {
1703
1737
  asChild: !0,
1704
1738
  className: t("border-0! focus-visible:outline-none", n ? "px-3!" : "justify-center! p-0!"),
1705
- children: /* @__PURE__ */ p(J, {
1739
+ children: /* @__PURE__ */ p(X, {
1706
1740
  active: r === "system",
1707
1741
  title: "System Theme",
1708
1742
  onClick: () => {
@@ -1715,10 +1749,10 @@ function ht({ variant: e = "dropdown", showLabel: n = !1 }) {
1715
1749
  }), n && $.system]
1716
1750
  })
1717
1751
  }),
1718
- /* @__PURE__ */ f(Y.Item, {
1752
+ /* @__PURE__ */ f(Z.Item, {
1719
1753
  asChild: !0,
1720
1754
  className: t("border-0! focus-visible:outline-none", n ? "px-3!" : "justify-center! p-0!"),
1721
- children: /* @__PURE__ */ p(J, {
1755
+ children: /* @__PURE__ */ p(X, {
1722
1756
  active: r === "light",
1723
1757
  title: "Light Theme",
1724
1758
  onClick: () => {
@@ -1731,10 +1765,10 @@ function ht({ variant: e = "dropdown", showLabel: n = !1 }) {
1731
1765
  }), n && $.light]
1732
1766
  })
1733
1767
  }),
1734
- /* @__PURE__ */ f(Y.Item, {
1768
+ /* @__PURE__ */ f(Z.Item, {
1735
1769
  asChild: !0,
1736
1770
  className: t("border-0! focus-visible:outline-none", n ? "px-3!" : "justify-center! p-0!"),
1737
- children: /* @__PURE__ */ p(J, {
1771
+ children: /* @__PURE__ */ p(X, {
1738
1772
  active: r === "dark",
1739
1773
  title: "Dark Theme",
1740
1774
  onClick: () => {
@@ -1752,16 +1786,16 @@ function ht({ variant: e = "dropdown", showLabel: n = !1 }) {
1752
1786
  });
1753
1787
  }
1754
1788
  // components/typing-animation.tsx
1755
- function gt(e) {
1789
+ function vt(e) {
1756
1790
  return e === "newline" ? "\n" : e === "comma" ? ", " : "";
1757
1791
  }
1758
- function _t(e, t, n, r, i) {
1792
+ function yt(e, t, n, r, i) {
1759
1793
  if (r === "character") return Math.max(0, Math.min(e.length, t + n * i));
1760
1794
  let a = [...e.matchAll(/\S+\s*/g)].map((e) => e.index + e[0].length), o = t;
1761
1795
  for (let t = 0; t < n; t += 1) o = i === 1 ? a.find((e) => e > o) ?? e.length : [...a].reverse().find((e) => e < o) ?? 0;
1762
1796
  return o;
1763
1797
  }
1764
- function vt({ strings: e, placeholder: t, perTick: n = {
1798
+ function bt({ strings: e, placeholder: t, perTick: n = {
1765
1799
  amount: 1,
1766
1800
  unit: "character"
1767
1801
  }, msDelay: r = {
@@ -1806,9 +1840,9 @@ function vt({ strings: e, placeholder: t, perTick: n = {
1806
1840
  T([]), C(""), N.current += 1, P.current = 0, t = setTimeout(r, _);
1807
1841
  return;
1808
1842
  }
1809
- if (L.current) P.current = _t(i, P.current, b, x, -1), C(i.slice(0, P.current)), P.current === 0 && (L.current = !1, N.current = (N.current + 1) % e.length);
1843
+ if (L.current) P.current = yt(i, P.current, b, x, -1), C(i.slice(0, P.current)), P.current === 0 && (L.current = !1, N.current = (N.current + 1) % e.length);
1810
1844
  else {
1811
- if (P.current = _t(i, P.current, b, x, 1), C(i.slice(0, P.current)), L.current = !n && P.current === i.length && (s || N.current < e.length - 1), !n && P.current === i.length && !L.current && !s) {
1845
+ if (P.current = yt(i, P.current, b, x, 1), C(i.slice(0, P.current)), L.current = !n && P.current === i.length && (s || N.current < e.length - 1), !n && P.current === i.length && !L.current && !s) {
1812
1846
  k(!0);
1813
1847
  return;
1814
1848
  }
@@ -1841,7 +1875,7 @@ function vt({ strings: e, placeholder: t, perTick: n = {
1841
1875
  O,
1842
1876
  v
1843
1877
  ]);
1844
- let R = A ? "." : "", z = d !== "clear", B = gt(d), V = w.reduce((e, t) => e + t.split("\n").length, 0);
1878
+ let R = A ? "." : "", z = d !== "clear", B = vt(d), V = w.reduce((e, t) => e + t.split("\n").length, 0);
1845
1879
  return z ? /* @__PURE__ */ f("div", {
1846
1880
  ref: (e) => {
1847
1881
  M.current = e;
@@ -1872,7 +1906,7 @@ function vt({ strings: e, placeholder: t, perTick: n = {
1872
1906
  });
1873
1907
  }
1874
1908
  // utilities/hash-navigation.ts
1875
- function yt({ intervalMs: e = 500, maxAttempts: t = 20, behavior: n = "smooth", block: r } = {}) {
1909
+ function xt({ intervalMs: e = 500, maxAttempts: t = 20, behavior: n = "smooth", block: r } = {}) {
1876
1910
  if (typeof window > "u") return () => {};
1877
1911
  let i = 0, a = setInterval(() => {
1878
1912
  i += 1;
@@ -1890,10 +1924,10 @@ function yt({ intervalMs: e = 500, maxAttempts: t = 20, behavior: n = "smooth",
1890
1924
  }, e);
1891
1925
  return () => clearInterval(a);
1892
1926
  }
1893
- function bt(e) {
1894
- o(() => yt(e), []);
1927
+ function St(e) {
1928
+ o(() => xt(e), []);
1895
1929
  }
1896
- function xt({ container: e, sectionIds: t, hashFirstSection: n = !0, onActiveChange: r }) {
1930
+ function Ct({ container: e, sectionIds: t, hashFirstSection: n = !0, onActiveChange: r }) {
1897
1931
  let i = t.map((e) => document.getElementById(e)).filter((e) => e !== null), a = window.location.hash.toLowerCase().slice(1) || null, o = () => {
1898
1932
  let t = e.getBoundingClientRect(), o = t.top + t.height / 2, s = i.find((e) => {
1899
1933
  let t = e.getBoundingClientRect();
@@ -1905,4 +1939,4 @@ function xt({ container: e, sectionIds: t, hashFirstSection: n = !0, onActiveCha
1905
1939
  };
1906
1940
  return o(), e.addEventListener("scroll", o, { passive: !0 }), () => e.removeEventListener("scroll", o);
1907
1941
  }
1908
- export { De as Avatar, H as Button, xe as ButtonGroup, q as Card, Le as DateHandler, Oe as Divider, Ce as DoubleClickButton, ke as Dropdown, U as ErrorText, Ne as GridLoader, K as Input, Re as InputTimestamp, Pe as LabelField, we as LongPressButton, Y as Menu, We as Modal, Ge as MultiDropdown, J as Pill, Be as PillLink, G as PreviewCard, X as Select, st as Switch, nt as Table, Ke as Tabs, qe as TabsList, Je as TabsPanel, Ye as TabsTab, Ze as Tag, ot as TextLink, ht as ThemeSwitcher, vt as TypingAnimation, yt as navigateToHashOnLoad, xt as updateHashOnScroll, bt as useHashNavigationOnLoad };
1942
+ export { De as Avatar, H as Button, xe as ButtonGroup, Y as Card, Le as DateHandler, Oe as Divider, Ce as DoubleClickButton, ke as Dropdown, G as ErrorText, Ne as GridLoader, J as Input, Re as InputTimestamp, Pe as LabelField, we as LongPressButton, Z as Menu, We as Modal, Ge as MultiDropdown, X as Pill, Be as PillLink, q as PreviewCard, Q as Select, lt as Switch, it as Table, Ke as Tabs, qe as TabsList, Je as TabsPanel, Ye as TabsTab, Ze as Tag, ct as TextLink, _t as ThemeSwitcher, bt as TypingAnimation, xt as navigateToHashOnLoad, Ct as updateHashOnScroll, St as useHashNavigationOnLoad };
@@ -1,8 +1,12 @@
1
+ import { KeyboardEventHandler, ReactNode } from 'react';
1
2
  export type DropdownItem = {
2
3
  key: string | number;
3
- label: string;
4
+ label: ReactNode;
5
+ labelTextValue?: string;
4
6
  disabled?: boolean;
5
7
  };
8
+ export declare const getReactNodeText: (node: ReactNode) => string;
9
+ export declare const getDropdownItemText: (item: DropdownItem) => string;
6
10
  export interface DropdownProps {
7
11
  items: DropdownItem[];
8
12
  value: number | string;
@@ -12,8 +16,20 @@ export interface DropdownProps {
12
16
  disabled?: boolean;
13
17
  name?: string;
14
18
  preventEmpty?: boolean;
19
+ id?: string;
20
+ inputValue?: string;
21
+ onInputValueChange?: (inputValue: string) => void;
22
+ onKeyDown?: KeyboardEventHandler<HTMLInputElement>;
23
+ open?: boolean;
24
+ onOpenChange?: (open: boolean) => void;
25
+ renderItem?: (item: DropdownItem) => ReactNode;
26
+ renderValue?: (item: DropdownItem) => ReactNode;
27
+ selectedValueFillsSpace?: boolean;
28
+ loading?: boolean;
29
+ loadingLabel?: string;
30
+ "aria-label"?: string;
15
31
  "data-name"?: string;
16
32
  "data-required"?: boolean;
17
33
  }
18
- declare const Dropdown: ({ items, value, onChange, className, placeholder, disabled, name, preventEmpty, "data-name": dataName, "data-required": dataRequired, }: DropdownProps) => import('react').JSX.Element;
34
+ declare const Dropdown: ({ items, value, onChange, className, placeholder, disabled, name, preventEmpty, id, inputValue, onInputValueChange, onKeyDown, open, onOpenChange, renderItem, renderValue, selectedValueFillsSpace, loading, loadingLabel, "aria-label": ariaLabel, "data-name": dataName, "data-required": dataRequired, }: DropdownProps) => import('react').JSX.Element;
19
35
  export default Dropdown;
@@ -2,6 +2,7 @@ import { ReactNode } from 'react';
2
2
  export type SelectItem = {
3
3
  key: string;
4
4
  label: ReactNode;
5
+ labelTextValue?: string;
5
6
  disabled?: boolean;
6
7
  };
7
8
  export interface SelectProps {
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@febkosq8/arc",
3
3
  "description": "A React components library for febkosq8",
4
4
  "private": false,
5
- "version": "0.8.9",
5
+ "version": "0.8.10",
6
6
  "type": "module",
7
7
  "main": "./dist/arc.js",
8
8
  "types": "./dist/index.d.ts",
@@ -63,7 +63,7 @@
63
63
  "@typescript/typescript6": "6.0.2",
64
64
  "@vitejs/plugin-react": "6.3.0",
65
65
  "eslint": "10.14.0",
66
- "prettier": "3.9.10",
66
+ "prettier": "3.10.1",
67
67
  "prettier-plugin-css-order": "2.2.0",
68
68
  "prettier-plugin-organize-attributes": "1.0.0",
69
69
  "prettier-plugin-organize-imports": "4.3.0",
@@ -74,6 +74,6 @@
74
74
  "tailwindcss": "4.3.5",
75
75
  "typescript": "7.0.2",
76
76
  "unplugin-dts": "1.1.2",
77
- "vite": "8.3.7"
77
+ "vite": "8.3.8"
78
78
  }
79
79
  }