@godxjp/ui 9.1.0 → 10.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. package/README.md +58 -29
  2. package/dist/app/index.d.ts +1 -1
  3. package/dist/app/index.js +4 -4
  4. package/dist/{app.prop-DnIXFzLi.d.ts → app.prop-Cy6dJnU8.d.ts} +18 -35
  5. package/dist/aspect-ratio-CZZJd9Km.d.ts +9 -0
  6. package/dist/{checkbox-ChRsR7Nk.d.ts → checkbox-em-oFM5D.d.ts} +1 -1
  7. package/dist/{chunk-LJLGABFV.js → chunk-2HXZT2WJ.js} +17 -9
  8. package/dist/{chunk-QLMXEJSY.js → chunk-3Q4A4U2P.js} +24 -1
  9. package/dist/{chunk-26CPAKUP.js → chunk-44YRPSZ7.js} +1 -2
  10. package/dist/{chunk-HB2OHB5X.js → chunk-5NCFLCM7.js} +27 -16
  11. package/dist/{chunk-FXFJF4YA.js → chunk-6CSBMMZS.js} +262 -31
  12. package/dist/{chunk-ZRRLOOBX.js → chunk-6HHSU6RG.js} +8 -6
  13. package/dist/{chunk-INSF6K3Y.js → chunk-7Q45MBFW.js} +7 -5
  14. package/dist/{chunk-O24Z3ULJ.js → chunk-BE6GJGKJ.js} +1 -1
  15. package/dist/{chunk-5D42MFB4.js → chunk-BG5RNXTH.js} +71 -2
  16. package/dist/{chunk-AINW5WYN.js → chunk-COD66MFF.js} +1 -2
  17. package/dist/{chunk-IOGU3ZWF.js → chunk-DNGJHWJZ.js} +3 -3
  18. package/dist/{chunk-3TS3G4U3.js → chunk-EE5DKOHX.js} +3 -1
  19. package/dist/{chunk-KXOAZGPA.js → chunk-EQZP53KI.js} +33 -8
  20. package/dist/{chunk-BHV2FUOA.js → chunk-EZHHJQWQ.js} +1 -1
  21. package/dist/{chunk-N3JPLJ3B.js → chunk-GDDCSKCB.js} +12 -5
  22. package/dist/{chunk-RLGHEV4A.js → chunk-HTG5VHU7.js} +10 -1
  23. package/dist/{chunk-R2W2FX5Q.js → chunk-I7NQ2LIL.js} +1 -9
  24. package/dist/{chunk-XQMPK4GM.js → chunk-IHRMOJXD.js} +86 -39
  25. package/dist/{chunk-TILFZBTE.js → chunk-INIIF7F7.js} +1 -4
  26. package/dist/{chunk-UIYEAUWA.js → chunk-IY347EQA.js} +2 -2
  27. package/dist/{chunk-HCM4JAC2.js → chunk-JWGLJXQU.js} +39 -11
  28. package/dist/{chunk-TO33OY4L.js → chunk-LMKUKCTN.js} +1 -1
  29. package/dist/chunk-NXVCI6YB.js +453 -0
  30. package/dist/{chunk-JBHXILI4.js → chunk-O6DQZYNI.js} +63 -44
  31. package/dist/{chunk-O2OUNXV4.js → chunk-P5KPCT6R.js} +3 -3
  32. package/dist/{chunk-56NYZNVY.js → chunk-PDXFQS7M.js} +112 -49
  33. package/dist/{chunk-F7PG4OEV.js → chunk-QSGW3ZWK.js} +12 -4
  34. package/dist/{chunk-25RYBC5T.js → chunk-S2IJKT3D.js} +1 -1
  35. package/dist/{chunk-OJZ6C2HM.js → chunk-SARQRCKO.js} +54 -48
  36. package/dist/chunk-T2QO2S65.js +126 -0
  37. package/dist/{chunk-442ULAA6.js → chunk-TGNBXS7H.js} +142 -62
  38. package/dist/{chunk-6J7GRCDA.js → chunk-UNVRNJCB.js} +71 -11
  39. package/dist/{chunk-6YBYAEXD.js → chunk-VSM44AYE.js} +94 -24
  40. package/dist/chunk-VSUYVT2Q.js +163 -0
  41. package/dist/{chunk-4R7QL3MW.js → chunk-X2VY4MOW.js} +14 -29
  42. package/dist/{chunk-FRU44GA2.js → chunk-XK3M3VRR.js} +16 -2
  43. package/dist/{chunk-6YK3IJXW.js → chunk-Z46J47FY.js} +73 -77
  44. package/dist/components/admin/index.d.ts +23 -13
  45. package/dist/components/admin/index.js +29 -30
  46. package/dist/components/data-display/badge.js +3 -3
  47. package/dist/components/data-display/card.d.ts +3 -3
  48. package/dist/components/data-display/card.js +1 -1
  49. package/dist/components/data-display/carousel.js +3 -1
  50. package/dist/components/data-display/index.js +55 -33
  51. package/dist/components/data-entry/calendar.d.ts +1 -1
  52. package/dist/components/data-entry/calendar.js +1 -1
  53. package/dist/components/data-entry/cascader.d.ts +1 -1
  54. package/dist/components/data-entry/cascader.js +5 -5
  55. package/dist/components/data-entry/checkbox.d.ts +2 -2
  56. package/dist/components/data-entry/checkbox.js +2 -2
  57. package/dist/components/data-entry/color-picker.d.ts +1 -1
  58. package/dist/components/data-entry/color-picker.js +3 -3
  59. package/dist/components/data-entry/date-picker.d.ts +2 -2
  60. package/dist/components/data-entry/date-picker.js +4 -4
  61. package/dist/components/data-entry/date-range-picker.d.ts +2 -2
  62. package/dist/components/data-entry/date-range-picker.js +4 -4
  63. package/dist/components/data-entry/index.d.ts +9 -25
  64. package/dist/components/data-entry/index.js +22 -26
  65. package/dist/components/data-entry/radio.d.ts +1 -1
  66. package/dist/components/data-entry/radio.js +2 -2
  67. package/dist/components/data-entry/select.d.ts +2 -2
  68. package/dist/components/data-entry/select.js +3 -4
  69. package/dist/components/data-entry/slider.d.ts +1 -1
  70. package/dist/components/data-entry/switch.d.ts +2 -2
  71. package/dist/components/data-entry/switch.js +1 -1
  72. package/dist/components/data-entry/time-input.js +2 -2
  73. package/dist/components/data-entry/time-picker.d.ts +3 -1
  74. package/dist/components/data-entry/time-picker.js +3 -3
  75. package/dist/components/data-entry/transfer.d.ts +2 -2
  76. package/dist/components/data-entry/transfer.js +5 -5
  77. package/dist/components/data-entry/tree-select.d.ts +1 -1
  78. package/dist/components/data-entry/tree-select.js +5 -5
  79. package/dist/components/data-entry/upload.d.ts +2 -2
  80. package/dist/components/data-entry/upload.js +5 -5
  81. package/dist/components/feedback/alert.js +5 -5
  82. package/dist/components/feedback/dialog.d.ts +20 -1
  83. package/dist/components/feedback/dialog.js +3 -3
  84. package/dist/components/feedback/index.d.ts +10 -18
  85. package/dist/components/feedback/index.js +9 -9
  86. package/dist/components/feedback/sheet.js +1 -1
  87. package/dist/components/layout/index.d.ts +27 -15
  88. package/dist/components/layout/index.js +7 -5
  89. package/dist/components/navigation/dropdown-menu.js +1 -1
  90. package/dist/components/navigation/index.d.ts +15 -17
  91. package/dist/components/navigation/index.js +7 -8
  92. package/dist/components/navigation/pagination.d.ts +25 -4
  93. package/dist/components/navigation/pagination.js +4 -5
  94. package/dist/components/navigation/steps.d.ts +3 -3
  95. package/dist/components/navigation/steps.js +3 -1
  96. package/dist/components/query/index.d.ts +1 -5
  97. package/dist/components/query/index.js +6 -8
  98. package/dist/components/ui/index.d.ts +13 -12
  99. package/dist/components/ui/index.js +30 -32
  100. package/dist/{data-entry.prop-CDkOajPj.d.ts → data-entry.prop-BR4vNA1j.d.ts} +7 -35
  101. package/dist/filter-bar-BxjSJJnQ.d.ts +7 -0
  102. package/dist/{inline-DCqn4O29.d.ts → flex-D_EXRFSW.d.ts} +2 -8
  103. package/dist/form/index.js +1 -1
  104. package/dist/i18n/index.d.ts +82 -10
  105. package/dist/i18n/index.js +2 -2
  106. package/dist/index.d.ts +7 -7
  107. package/dist/index.js +41 -44
  108. package/dist/{layout.prop-DwJKI6ka.d.ts → layout.prop-JE2TcRyL.d.ts} +8 -2
  109. package/dist/lib/datetime/index.js +1 -1
  110. package/dist/{navigation.prop-8DgElO0c.d.ts → navigation.prop-DMcXkR-J.d.ts} +9 -11
  111. package/dist/{toggle-group-BulJgKh3.d.ts → password-strength-DVRvXEOK.d.ts} +24 -3
  112. package/dist/props/components/index.d.ts +4 -4
  113. package/dist/props/index.d.ts +4 -4
  114. package/dist/props/index.js +1 -1
  115. package/dist/props/registry.d.ts +84 -39
  116. package/dist/props/registry.js +1 -1
  117. package/dist/{search-input-cezAxpgb.d.ts → search-input-DpqDMXcn.d.ts} +2 -4
  118. package/dist/{skeleton-uWAjSacg.d.ts → skeleton-cj9kh5wo.d.ts} +1 -3
  119. package/dist/styles/control.css +176 -41
  120. package/dist/styles/data-display-layout.css +41 -15
  121. package/dist/styles/data-entry-layout.css +71 -0
  122. package/dist/styles/feedback-layout.css +44 -12
  123. package/dist/styles/index.css +45 -1
  124. package/dist/styles/layout.css +66 -17
  125. package/dist/styles/navigation-layout.css +3 -1
  126. package/dist/styles/shell-layout.css +3 -3
  127. package/dist/styles/table-layout.css +13 -0
  128. package/dist/tokens/foundation.css +12 -1
  129. package/dist/tokens/semantic/layout.css +2 -2
  130. package/dist/tooltip-Bf2KjRy8.d.ts +14 -0
  131. package/package.json +7 -7
  132. package/scripts/ui-audit.mjs +31 -2
  133. package/dist/aspect-ratio-DGoYrOry.d.ts +0 -6
  134. package/dist/chunk-CAEL2ZD2.js +0 -222
  135. package/dist/chunk-FYM3MJSK.js +0 -59
  136. package/dist/chunk-GKXPALFT.js +0 -32
  137. package/dist/chunk-JKHWLPM5.js +0 -101
  138. package/dist/chunk-KDBGFJJI.js +0 -220
  139. package/dist/chunk-VN72SWHX.js +0 -189
  140. package/dist/components/data-entry/autocomplete.d.ts +0 -24
  141. package/dist/components/data-entry/autocomplete.js +0 -10
  142. package/dist/components/data-entry/combobox.d.ts +0 -22
  143. package/dist/components/data-entry/combobox.js +0 -6
  144. package/dist/filter-bar-BycYH10i.d.ts +0 -14
  145. /package/dist/{chunk-LDSLS6HE.js → chunk-7CFO5FFE.js} +0 -0
@@ -52,6 +52,5 @@ function SkeletonStat() {
52
52
  /* @__PURE__ */ jsx(Skeleton, { className: "h-3 w-20" })
53
53
  ] });
54
54
  }
55
- var SkeletonCard = SkeletonStat;
56
55
 
57
- export { Skeleton, SkeletonCard, SkeletonDetail, SkeletonRows, SkeletonStat, SkeletonTable };
56
+ export { Skeleton, SkeletonDetail, SkeletonRows, SkeletonStat, SkeletonTable };
@@ -47,7 +47,7 @@ function Calendar({
47
47
  day: cn(
48
48
  "relative p-0 text-center text-sm focus-within:relative focus-within:z-20",
49
49
  "[&:has([aria-selected])]:bg-accent [&:has([aria-selected].day-outside)]:bg-accent/50",
50
- "[&:has([aria-selected].day-range-end)]:rounded-r-md",
50
+ "[&:has([aria-selected].day-range-end)]:rounded-e-md",
51
51
  classNames?.day
52
52
  ),
53
53
  day_button: cn(
@@ -55,8 +55,8 @@ function Calendar({
55
55
  "size-[length:var(--control-height)] p-0 font-normal aria-selected:opacity-100",
56
56
  classNames?.day_button
57
57
  ),
58
- range_start: cn("day-range-start rounded-l-md", classNames?.range_start),
59
- range_end: cn("day-range-end rounded-r-md", classNames?.range_end),
58
+ range_start: cn("day-range-start rounded-s-md", classNames?.range_start),
59
+ range_end: cn("day-range-end rounded-e-md", classNames?.range_end),
60
60
  range_middle: cn(
61
61
  "aria-selected:bg-accent aria-selected:text-accent-foreground",
62
62
  classNames?.range_middle
@@ -1,6 +1,6 @@
1
1
  import { Input } from './chunk-VOHTRR5X.js';
2
2
  import { controlIconClass } from './chunk-IBK5D2Q6.js';
3
- import { useTranslation } from './chunk-RLGHEV4A.js';
3
+ import { useTranslation } from './chunk-HTG5VHU7.js';
4
4
  import { cn } from './chunk-U7N2A7A3.js';
5
5
  import * as React from 'react';
6
6
  import { jsxs, jsx } from 'react/jsx-runtime';
@@ -56,8 +56,10 @@ function ColorPicker({
56
56
  showHexInput && /* @__PURE__ */ jsx(
57
57
  Input,
58
58
  {
59
+ id: id ? `${id}-hex` : void 0,
59
60
  value: display,
60
61
  disabled,
62
+ "aria-label": t("dataEntry.colorPicker.hexLabel"),
61
63
  onChange: (event) => setDraft(event.target.value),
62
64
  onBlur: () => commit(display),
63
65
  onKeyDown: (event) => {
@@ -1,13 +1,13 @@
1
- import { formatBytes } from './chunk-4R7QL3MW.js';
2
- import { Dialog, DialogContent, DialogHeader, DialogTitle, DialogFooter } from './chunk-5D42MFB4.js';
3
1
  import { Slider } from './chunk-CRERCLIZ.js';
2
+ import { formatBytes } from './chunk-X2VY4MOW.js';
3
+ import { Dialog, DialogContent, DialogHeader, DialogTitle, DialogDescription, DialogFooter } from './chunk-BG5RNXTH.js';
4
4
  import { Button } from './chunk-M4PZNAMV.js';
5
5
  import { controlIconClass } from './chunk-IBK5D2Q6.js';
6
- import { useTranslation } from './chunk-RLGHEV4A.js';
6
+ import { useTranslation } from './chunk-HTG5VHU7.js';
7
7
  import { cn } from './chunk-U7N2A7A3.js';
8
8
  import * as React2 from 'react';
9
9
  import { Upload as Upload$1, ImagePlus, Camera, Trash2, RotateCcw, X } from 'lucide-react';
10
- import { jsxs, jsx } from 'react/jsx-runtime';
10
+ import { jsx, jsxs } from 'react/jsx-runtime';
11
11
 
12
12
  function UploadCropDialog({ open, onOpenChange, file, onConfirm }) {
13
13
  const { t } = useTranslation();
@@ -49,7 +49,10 @@ function UploadCropDialog({ open, onOpenChange, file, onConfirm }) {
49
49
  onOpenChange(false);
50
50
  };
51
51
  return /* @__PURE__ */ jsx(Dialog, { open, onOpenChange, children: /* @__PURE__ */ jsxs(DialogContent, { className: "max-w-sm", children: [
52
- /* @__PURE__ */ jsx(DialogHeader, { children: /* @__PURE__ */ jsx(DialogTitle, { children: t("dataEntry.upload.cropTitle") }) }),
52
+ /* @__PURE__ */ jsxs(DialogHeader, { children: [
53
+ /* @__PURE__ */ jsx(DialogTitle, { children: t("dataEntry.upload.cropTitle") }),
54
+ /* @__PURE__ */ jsx(DialogDescription, { children: t("dataEntry.upload.cropDescription") })
55
+ ] }),
53
56
  /* @__PURE__ */ jsxs("div", { className: "ui-stack-sm", children: [
54
57
  /* @__PURE__ */ jsx(
55
58
  "div",
@@ -316,18 +319,24 @@ function Upload({
316
319
  accept,
317
320
  multiple: multiple && !isSingleAvatar,
318
321
  disabled,
322
+ "aria-label": t("dataEntry.upload.inputLabel"),
319
323
  onChange: (e) => {
320
324
  pickFiles(e.target.files);
321
325
  e.target.value = "";
322
326
  }
323
327
  }
324
328
  );
329
+ const uploadingCount = items.filter((it) => it.status === "uploading").length;
330
+ const doneCount = items.filter((it) => it.status === "done").length;
331
+ const errorCount = items.filter((it) => it.status === "error").length;
332
+ const liveRegion = /* @__PURE__ */ jsx("span", { "aria-live": "polite", className: "sr-only", "data-slot": "upload-status", children: errorCount > 0 ? t("dataEntry.upload.statusFailed", { count: errorCount }) : uploadingCount > 0 ? t("dataEntry.upload.statusUploading", { count: uploadingCount }) : items.length > 0 ? t("dataEntry.upload.statusReady", { count: items.length, done: doneCount }) : "" });
325
333
  const openPicker = () => {
326
334
  if (!disabled) inputRef.current?.click();
327
335
  };
328
336
  if (variant === "dropzone") {
329
337
  return /* @__PURE__ */ jsxs("div", { className: cn("ui-stack-sm", className), children: [
330
338
  hiddenInput,
339
+ liveRegion,
331
340
  /* @__PURE__ */ jsxs(
332
341
  "div",
333
342
  {
@@ -370,6 +379,7 @@ function Upload({
370
379
  if (variant === "button") {
371
380
  return /* @__PURE__ */ jsxs("div", { className: cn("ui-stack-sm", className), children: [
372
381
  hiddenInput,
382
+ liveRegion,
373
383
  /* @__PURE__ */ jsxs(Button, { type: "button", variant: "outline", disabled, onClick: openPicker, children: [
374
384
  /* @__PURE__ */ jsx(Upload$1, { className: "mr-2 size-4", "aria-hidden": "true" }),
375
385
  children ?? t("dataEntry.upload.buttonLabel")
@@ -381,6 +391,7 @@ function Upload({
381
391
  const canAdd = maxCount == null || items.length < maxCount;
382
392
  return /* @__PURE__ */ jsxs("div", { className: cn("flex flex-wrap gap-3", className), children: [
383
393
  hiddenInput,
394
+ liveRegion,
384
395
  items.map((item2) => /* @__PURE__ */ jsx(
385
396
  UploadPictureCard,
386
397
  {
@@ -413,6 +424,7 @@ function Upload({
413
424
  const item2 = draft.state.display;
414
425
  return /* @__PURE__ */ jsxs("div", { className: cn("ui-stack-sm max-w-xs", className), children: [
415
426
  hiddenInput,
427
+ liveRegion,
416
428
  item2?.previewUrl && !item2.pendingDelete ? /* @__PURE__ */ jsxs("div", { className: "relative overflow-hidden rounded-md border", children: [
417
429
  /* @__PURE__ */ jsx("img", { src: item2.previewUrl, alt: "", className: "max-h-48 w-full object-cover" }),
418
430
  item2.status === "uploading" && /* @__PURE__ */ jsx("div", { className: "bg-background/70 absolute inset-0 flex items-center justify-center text-sm", children: t("dataEntry.upload.uploading") }),
@@ -437,6 +449,7 @@ function Upload({
437
449
  const showPlaceholder = !item?.previewUrl || item.pendingDelete;
438
450
  return /* @__PURE__ */ jsxs("div", { className: cn("ui-stack-sm items-start", className), children: [
439
451
  hiddenInput,
452
+ liveRegion,
440
453
  /* @__PURE__ */ jsx(
441
454
  UploadCropDialog,
442
455
  {
@@ -516,6 +529,7 @@ function UploadDraftActions({
516
529
  return null;
517
530
  }
518
531
  function UploadPictureCard({ item, onRemove }) {
532
+ const { t } = useTranslation();
519
533
  return /* @__PURE__ */ jsxs("div", { className: "bg-muted relative size-24 overflow-hidden rounded-md border", children: [
520
534
  item.previewUrl ? /* @__PURE__ */ jsx("img", { src: item.previewUrl, alt: "", className: "size-full object-cover" }) : /* @__PURE__ */ jsx("div", { className: "text-muted-foreground flex size-full items-center justify-center text-xs", children: "\u2026" }),
521
535
  item.status === "uploading" && /* @__PURE__ */ jsx("div", { className: "bg-background/70 absolute inset-0 flex items-center justify-center text-xs", children: "\u2026" }),
@@ -524,8 +538,8 @@ function UploadPictureCard({ item, onRemove }) {
524
538
  {
525
539
  type: "button",
526
540
  onClick: onRemove,
527
- className: "bg-background/90 hover:bg-destructive hover:text-destructive-foreground absolute top-1 right-1 rounded-full p-0.5 shadow",
528
- "aria-label": "Remove",
541
+ className: "bg-background/90 hover:bg-destructive hover:text-destructive-foreground absolute end-1 top-1 rounded-full p-0.5 shadow",
542
+ "aria-label": t("dataEntry.upload.removeImage"),
529
543
  children: /* @__PURE__ */ jsx(X, { className: "size-3.5", "aria-hidden": "true" })
530
544
  }
531
545
  )
@@ -535,6 +549,7 @@ function UploadFileList({
535
549
  items,
536
550
  onRemove
537
551
  }) {
552
+ const { t } = useTranslation();
538
553
  return /* @__PURE__ */ jsx("ul", { className: "ui-stack-xs", children: items.map((item) => /* @__PURE__ */ jsxs("li", { className: "flex items-center gap-3 rounded-md border px-3 py-2 text-sm", children: [
539
554
  /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
540
555
  /* @__PURE__ */ jsx("div", { className: "truncate font-medium", children: item.name }),
@@ -552,7 +567,17 @@ function UploadFileList({
552
567
  ] })
553
568
  ] })
554
569
  ] }),
555
- onRemove && /* @__PURE__ */ jsx(Button, { type: "button", size: "sm", variant: "ghost", onClick: () => onRemove(item.uid), children: /* @__PURE__ */ jsx(X, { className: "size-4", "aria-hidden": "true" }) })
570
+ onRemove && /* @__PURE__ */ jsx(
571
+ Button,
572
+ {
573
+ type: "button",
574
+ size: "sm",
575
+ variant: "ghost",
576
+ "aria-label": t("dataEntry.upload.removeFile", { name: item.name }),
577
+ onClick: () => onRemove(item.uid),
578
+ children: /* @__PURE__ */ jsx(X, { className: "size-4", "aria-hidden": "true" })
579
+ }
580
+ )
556
581
  ] }, item.uid)) });
557
582
  }
558
583
 
@@ -92,7 +92,7 @@ var SheetTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__
92
92
  {
93
93
  ref,
94
94
  "data-slot": "sheet-title",
95
- className: cn("text-foreground text-lg font-semibold", className),
95
+ className: cn("text-foreground text-lg font-medium", className),
96
96
  ...props
97
97
  }
98
98
  ));
@@ -1,9 +1,9 @@
1
- import { Calendar } from './chunk-IOGU3ZWF.js';
1
+ import { Calendar } from './chunk-DNGJHWJZ.js';
2
2
  import { Input } from './chunk-VOHTRR5X.js';
3
3
  import { Button } from './chunk-M4PZNAMV.js';
4
4
  import { Popover, PopoverTrigger, PopoverContent } from './chunk-DY5C44UP.js';
5
- import { useTranslation, usePickerLocales } from './chunk-RLGHEV4A.js';
6
- import { toIsoDate, parseDateInput } from './chunk-FXFJF4YA.js';
5
+ import { useTranslation, usePickerLocales } from './chunk-HTG5VHU7.js';
6
+ import { toIsoDate, parseDateInput } from './chunk-6CSBMMZS.js';
7
7
  import { cn } from './chunk-U7N2A7A3.js';
8
8
  import * as React from 'react';
9
9
  import { CalendarIcon } from 'lucide-react';
@@ -11,7 +11,8 @@ import { jsxs, jsx } from 'react/jsx-runtime';
11
11
 
12
12
  var ISO_HINT = "yyyy-mm-dd";
13
13
  function DateRangePicker({
14
- value,
14
+ value: valueProp,
15
+ defaultValue,
15
16
  onValueChange,
16
17
  placeholder,
17
18
  disabled,
@@ -25,6 +26,9 @@ function DateRangePicker({
25
26
  const { t } = useTranslation();
26
27
  const { dayPickerLocale } = usePickerLocales(localeProp);
27
28
  const [open, setOpen] = React.useState(false);
29
+ const isControlled = React.useRef(valueProp !== void 0).current;
30
+ const [internalValue, setInternalValue] = React.useState(defaultValue);
31
+ const value = isControlled ? valueProp : internalValue;
28
32
  const [fromText, setFromText] = React.useState(() => toIsoDate(value?.from));
29
33
  const [toText, setToText] = React.useState(() => toIsoDate(value?.to));
30
34
  React.useEffect(() => {
@@ -32,7 +36,10 @@ function DateRangePicker({
32
36
  setToText(toIsoDate(value?.to));
33
37
  }, [value?.from, value?.to]);
34
38
  const resolvedPlaceholder = placeholder ?? t("dataEntry.dateRangePicker.placeholder") ?? ISO_HINT;
35
- const emit = (next) => onValueChange?.(next);
39
+ const emit = (next) => {
40
+ if (!isControlled) setInternalValue(next);
41
+ onValueChange?.(next);
42
+ };
36
43
  const commitEdge = (edge, raw) => {
37
44
  const parsed = raw.trim() === "" ? void 0 : parseDateInput(raw.trim()) ?? void 0;
38
45
  const next = { from: value?.from, to: value?.to, [edge]: parsed };
@@ -1,4 +1,4 @@
1
- import { APP_TIME_FORMATS, isAppDateFormat, isAppTimeFormat, isAppLocale, translate, getDateFnsLocale, syncI18nLocale, syncDatetimeContext, disableLiveRelativeFormatting, enableLiveRelativeFormatting, getDayPickerLocale, APP_REQUEST_HEADER_DATE_FORMAT, APP_REQUEST_HEADER_TIME_FORMAT, resolveDefaultDateFormat } from './chunk-FXFJF4YA.js';
1
+ import { APP_TIME_FORMATS, isAppDateFormat, isAppTimeFormat, isAppLocale, translate, getDateFnsLocale, syncI18nLocale, syncDatetimeContext, disableLiveRelativeFormatting, enableLiveRelativeFormatting, getDayPickerLocale, APP_REQUEST_HEADER_DATE_FORMAT, APP_REQUEST_HEADER_TIME_FORMAT, resolveDefaultDateFormat } from './chunk-6CSBMMZS.js';
2
2
  import * as React from 'react';
3
3
  import { useMemo } from 'react';
4
4
  import { jsx } from 'react/jsx-runtime';
@@ -211,6 +211,10 @@ function resetIanaTimezoneCacheForTests() {
211
211
  cachedAllTimezones = null;
212
212
  cachedTimezoneSet = null;
213
213
  }
214
+ var RTL_LANGUAGE_SUBTAGS = /* @__PURE__ */ new Set(["ar", "he", "fa", "ur", "ps", "sd", "yi", "dv", "ckb"]);
215
+ function localeDirection(locale) {
216
+ return RTL_LANGUAGE_SUBTAGS.has(locale.split("-")[0]?.toLowerCase() ?? "") ? "rtl" : "ltr";
217
+ }
214
218
  var AppContext = React.createContext(null);
215
219
  function resolveInitialTimeFormat(stored, defaultTimeFormat, locale) {
216
220
  if (stored) return stored;
@@ -354,6 +358,11 @@ function AppProvider({
354
358
  React.useEffect(() => {
355
359
  syncAppRequestHeaders(requestHeaders);
356
360
  }, [requestHeaders]);
361
+ React.useEffect(() => {
362
+ if (typeof document !== "undefined") {
363
+ document.documentElement.dir = localeDirection(locale);
364
+ }
365
+ }, [locale]);
357
366
  React.useEffect(() => {
358
367
  hasMountedRef.current = true;
359
368
  enableLiveRelativeFormatting();
@@ -4,15 +4,7 @@ import * as SwitchPrimitive from '@radix-ui/react-switch';
4
4
  import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
5
5
 
6
6
  var Switch = React.forwardRef(
7
- ({
8
- className,
9
- size = "default",
10
- name,
11
- checked,
12
- defaultChecked = false,
13
- onCheckedChange,
14
- ...props
15
- }, ref) => {
7
+ ({ className, size = "md", name, checked, defaultChecked = false, onCheckedChange, ...props }, ref) => {
16
8
  const [internalChecked, setInternalChecked] = React.useState(defaultChecked);
17
9
  const isControlled = checked !== void 0;
18
10
  const isChecked = isControlled ? checked : internalChecked;
@@ -319,22 +319,7 @@ var VOCABULARY_REGISTRY = {
319
319
  };
320
320
  var COMPONENT_PROP_REGISTRY = {
321
321
  AppProviderProp: { group: "app", file: "components/app.prop.ts", vocabulary: ["ChildrenProp"] },
322
- LocalePickerProp: {
323
- group: "app",
324
- file: "components/app.prop.ts",
325
- vocabulary: ["ValueProp", "OnValueChangeProp", "DisabledProp", "IdProp", "ClassNameProp"]
326
- },
327
- TimezonePickerProp: {
328
- group: "app",
329
- file: "components/app.prop.ts",
330
- vocabulary: ["ValueProp", "OnValueChangeProp", "DisabledProp", "IdProp", "ClassNameProp"]
331
- },
332
- TimeFormatPickerProp: {
333
- group: "app",
334
- file: "components/app.prop.ts",
335
- vocabulary: ["ValueProp", "OnValueChangeProp", "DisabledProp", "IdProp", "ClassNameProp"]
336
- },
337
- DateFormatPickerProp: {
322
+ AppSettingPickerProp: {
338
323
  group: "app",
339
324
  file: "components/app.prop.ts",
340
325
  vocabulary: ["ValueProp", "OnValueChangeProp", "DisabledProp", "IdProp", "ClassNameProp"]
@@ -480,26 +465,6 @@ var COMPONENT_PROP_REGISTRY = {
480
465
  file: "components/data-entry.prop.ts",
481
466
  vocabulary: ["IdProp", "LabelProp", "DescriptionProp", "ClassNameProp", "ChildrenProp"]
482
467
  },
483
- ChoiceFieldProp: {
484
- group: "data-entry",
485
- file: "components/data-entry.prop.ts",
486
- vocabulary: ["IdProp", "LabelProp", "ClassNameProp"]
487
- },
488
- CountryOptionProp: {
489
- group: "data-entry",
490
- file: "components/data-entry.prop.ts",
491
- vocabulary: ["LabelProp", "ValueProp"]
492
- },
493
- CountryOptionLabelProp: {
494
- group: "data-entry",
495
- file: "components/data-entry.prop.ts",
496
- vocabulary: ["ClassNameProp"]
497
- },
498
- CountrySelectProp: {
499
- group: "data-entry",
500
- file: "components/data-entry.prop.ts",
501
- vocabulary: ["IdProp", "NameProp", "DefaultValueProp", "RequiredProp", "PlaceholderProp"]
502
- },
503
468
  SliderProp: {
504
469
  group: "data-entry",
505
470
  file: "components/data-entry.prop.ts",
@@ -817,17 +782,17 @@ var COMPONENT_PROP_REGISTRY = {
817
782
  PaginationProp: {
818
783
  group: "navigation",
819
784
  file: "components/navigation.prop.ts",
820
- vocabulary: ["DisabledProp", "ClassNameProp"]
785
+ vocabulary: ["ValueProp", "OnValueChangeProp", "DisabledProp", "ClassNameProp"]
821
786
  },
822
787
  StepsProp: {
823
788
  group: "navigation",
824
789
  file: "components/navigation.prop.ts",
825
- vocabulary: ["SizeProp", "OnValueChangeProp", "ClassNameProp"]
790
+ vocabulary: ["ValueProp", "DefaultValueProp", "SizeProp", "OnValueChangeProp", "ClassNameProp"]
826
791
  },
827
792
  StepItemProp: {
828
793
  group: "navigation",
829
794
  file: "components/navigation.prop.ts",
830
- vocabulary: ["TitleProp", "DescriptionProp", "IconProp", "DisabledProp"]
795
+ vocabulary: ["TitleProp", "SubtitleProp", "DescriptionProp", "IconProp", "DisabledProp"]
831
796
  },
832
797
  StepStatusProp: { group: "navigation", file: "components/navigation.prop.ts", vocabulary: [] },
833
798
  TabsProp: {
@@ -869,6 +834,88 @@ var COMPONENT_PROP_REGISTRY = {
869
834
  group: "form",
870
835
  file: "components/form.prop.ts",
871
836
  vocabulary: ["ZodSchemaProp"]
837
+ },
838
+ // Component-declared prop types (XProps in src/components/**) — registered here so the
839
+ // prop-vocabulary guard governs them too (their fields are mostly Radix/native passthroughs).
840
+ ToggleProp: {
841
+ group: "data-entry",
842
+ file: "components/ui/toggle.tsx",
843
+ vocabulary: ["SizeProp", "ClassNameProp"]
844
+ },
845
+ RatingProp: {
846
+ group: "data-entry",
847
+ file: "components/ui/rating.tsx",
848
+ vocabulary: ["ValueProp", "OnValueChangeProp", "DisabledProp", "ClassNameProp"]
849
+ },
850
+ TagInputProp: {
851
+ group: "data-entry",
852
+ file: "components/ui/tag-input.tsx",
853
+ vocabulary: ["ValueProp", "OnValueChangeProp", "PlaceholderProp", "IdProp", "ClassNameProp"]
854
+ },
855
+ PasswordInputProp: {
856
+ group: "data-entry",
857
+ file: "components/ui/password-input.tsx",
858
+ vocabulary: ["ClassNameProp"]
859
+ },
860
+ PasswordStrengthProp: {
861
+ group: "data-entry",
862
+ file: "components/data-entry/password-strength.tsx",
863
+ vocabulary: ["ValueProp", "ClassNameProp"]
864
+ },
865
+ ProgressProp: {
866
+ group: "data-display",
867
+ file: "components/data-display/progress.tsx",
868
+ vocabulary: ["ValueProp", "LabelProp", "ClassNameProp"]
869
+ },
870
+ TimelineProp: {
871
+ group: "data-display",
872
+ file: "components/data-display/timeline.tsx",
873
+ vocabulary: ["ClassNameProp"]
874
+ },
875
+ TreeListProp: {
876
+ group: "data-display",
877
+ file: "components/data-display/tree-list.tsx",
878
+ vocabulary: ["ClassNameProp"]
879
+ },
880
+ CardProp: {
881
+ group: "data-display",
882
+ file: "components/data-display/card.tsx",
883
+ vocabulary: ["ToneProp", "ClassNameProp", "ChildrenProp"]
884
+ },
885
+ CardCoverProp: {
886
+ group: "data-display",
887
+ file: "components/data-display/card.tsx",
888
+ vocabulary: ["ClassNameProp", "ChildrenProp"]
889
+ },
890
+ CardHeaderProp: {
891
+ group: "data-display",
892
+ file: "components/data-display/card.tsx",
893
+ vocabulary: ["TitleProp", "DescriptionProp", "ClassNameProp", "ChildrenProp"]
894
+ },
895
+ CardContentProp: {
896
+ group: "data-display",
897
+ file: "components/data-display/card.tsx",
898
+ vocabulary: ["ClassNameProp", "ChildrenProp"]
899
+ },
900
+ CardFooterProp: {
901
+ group: "data-display",
902
+ file: "components/data-display/card.tsx",
903
+ vocabulary: ["ClassNameProp", "ChildrenProp"]
904
+ },
905
+ StatCardProp: {
906
+ group: "data-display",
907
+ file: "components/data-display/card.tsx",
908
+ vocabulary: ["TitleProp", "ToneProp", "ClassNameProp"]
909
+ },
910
+ ResponsiveGridProp: {
911
+ group: "layout",
912
+ file: "components/layout/responsive-grid.tsx",
913
+ vocabulary: ["GapProp", "ClassNameProp", "ChildrenProp"]
914
+ },
915
+ SplitPaneProp: {
916
+ group: "layout",
917
+ file: "components/layout/split-pane.tsx",
918
+ vocabulary: ["ClassNameProp", "ChildrenProp"]
872
919
  }
873
920
  };
874
921
  var PROP_ALIASES_FORBIDDEN = {
@@ -43,8 +43,5 @@ function Flex({
43
43
  }
44
44
  );
45
45
  }
46
- function Inline({ gap = "sm", ...props }) {
47
- return /* @__PURE__ */ jsx(Flex, { direction: "row", wrap: true, gap, align: "center", ...props });
48
- }
49
46
 
50
- export { Flex, Inline, densityClass, pageContainerVariantClass };
47
+ export { Flex, densityClass, pageContainerVariantClass };
@@ -1,5 +1,5 @@
1
1
  import { toneNeutralClass, toneMutedClass, toneInfoClass, toneDestructiveClass, toneWarningClass, toneSuccessClass } from './chunk-IBK5D2Q6.js';
2
- import { useTranslation } from './chunk-RLGHEV4A.js';
2
+ import { useTranslation } from './chunk-HTG5VHU7.js';
3
3
  import { cn } from './chunk-U7N2A7A3.js';
4
4
  import { cva } from 'class-variance-authority';
5
5
  import { XCircle, Pause, CheckCircle2, Circle, Trash2, AlertCircle, Clock, Play } from 'lucide-react';
@@ -29,7 +29,7 @@ var STATUS_MAP = {
29
29
  ASSIGNMENT_STATUS_TERMINATED: { tone: "destructive", icon: XCircle }
30
30
  };
31
31
  var badgeVariants = cva(
32
- "inline-flex items-center border text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring",
32
+ "inline-flex items-center border text-xs font-medium transition-colors focus:outline-none focus:ring-2 focus:ring-ring",
33
33
  {
34
34
  variants: {
35
35
  variant: {
@@ -1,3 +1,4 @@
1
+ import { useTranslation } from './chunk-HTG5VHU7.js';
1
2
  import { cn } from './chunk-U7N2A7A3.js';
2
3
  import * as React from 'react';
3
4
  import useEmblaCarousel from 'embla-carousel-react';
@@ -13,6 +14,7 @@ var useCarousel = () => {
13
14
  return context;
14
15
  };
15
16
  var Carousel = React.forwardRef(({ className, opts, plugins, setApi, children, ...props }, ref) => {
17
+ const { t } = useTranslation();
16
18
  const [emblaRef, api] = useEmblaCarousel(opts, plugins);
17
19
  const [canScrollPrev, setCanScrollPrev] = React.useState(false);
18
20
  const [canScrollNext, setCanScrollNext] = React.useState(false);
@@ -62,21 +64,43 @@ var Carousel = React.forwardRef(({ className, opts, plugins, setApi, children, .
62
64
  "data-slot": "carousel",
63
65
  className: cn("ui-carousel", className),
64
66
  "data-orientation": opts?.axis === "y" ? "vertical" : "horizontal",
67
+ role: "region",
68
+ "aria-roledescription": t("dataDisplay.carousel.roleDescription"),
69
+ "aria-label": t("dataDisplay.carousel.ariaLabel"),
65
70
  ...props,
66
71
  children: /* @__PURE__ */ jsx("div", { className: "ui-carousel-viewport", ref: emblaRef, children })
67
72
  }
68
73
  ) });
69
74
  });
70
75
  Carousel.displayName = "Carousel";
71
- var CarouselContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
72
- "div",
73
- {
74
- ref,
75
- "data-slot": "carousel-content",
76
- className: cn("ui-carousel-content", className),
77
- ...props
78
- }
79
- ));
76
+ var CarouselContent = React.forwardRef(({ className, children, ...props }, ref) => {
77
+ const { t } = useTranslation();
78
+ const items = React.Children.toArray(children).filter(React.isValidElement);
79
+ const total = items.length;
80
+ const decorated = React.Children.map(children, (child) => {
81
+ if (!React.isValidElement(child)) return child;
82
+ const index = items.indexOf(child);
83
+ if (index === -1) return child;
84
+ const childProps = child.props;
85
+ if (childProps["aria-label"] != null) return child;
86
+ return React.cloneElement(child, {
87
+ "aria-label": t("dataDisplay.carousel.slideLabel", {
88
+ index: index + 1,
89
+ total
90
+ })
91
+ });
92
+ });
93
+ return /* @__PURE__ */ jsx(
94
+ "div",
95
+ {
96
+ ref,
97
+ "data-slot": "carousel-content",
98
+ className: cn("ui-carousel-content", className),
99
+ ...props,
100
+ children: decorated
101
+ }
102
+ );
103
+ });
80
104
  CarouselContent.displayName = "CarouselContent";
81
105
  var CarouselItem = React.forwardRef(
82
106
  ({ className, ...props }, ref) => /* @__PURE__ */ jsx(
@@ -84,6 +108,8 @@ var CarouselItem = React.forwardRef(
84
108
  {
85
109
  ref,
86
110
  "data-slot": "carousel-item",
111
+ role: "group",
112
+ "aria-roledescription": "slide",
87
113
  className: cn("ui-carousel-item", className),
88
114
  ...props
89
115
  }
@@ -91,6 +117,7 @@ var CarouselItem = React.forwardRef(
91
117
  );
92
118
  CarouselItem.displayName = "CarouselItem";
93
119
  var CarouselPrevious = React.forwardRef(({ className, ...props }, ref) => {
120
+ const { t } = useTranslation();
94
121
  const { canScrollPrev, scrollPrev } = useCarousel();
95
122
  return /* @__PURE__ */ jsxs(
96
123
  "button",
@@ -104,13 +131,14 @@ var CarouselPrevious = React.forwardRef(({ className, ...props }, ref) => {
104
131
  ...props,
105
132
  children: [
106
133
  /* @__PURE__ */ jsx(ChevronLeft, { className: "ui-carousel-arrow", "aria-hidden": "true" }),
107
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Previous" })
134
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: t("dataDisplay.carousel.previous") })
108
135
  ]
109
136
  }
110
137
  );
111
138
  });
112
139
  CarouselPrevious.displayName = "CarouselPrevious";
113
140
  var CarouselNext = React.forwardRef(({ className, ...props }, ref) => {
141
+ const { t } = useTranslation();
114
142
  const { canScrollNext, scrollNext } = useCarousel();
115
143
  return /* @__PURE__ */ jsxs(
116
144
  "button",
@@ -124,7 +152,7 @@ var CarouselNext = React.forwardRef(({ className, ...props }, ref) => {
124
152
  ...props,
125
153
  children: [
126
154
  /* @__PURE__ */ jsx(ChevronRight, { className: "ui-carousel-arrow", "aria-hidden": "true" }),
127
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Next" })
155
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: t("dataDisplay.carousel.next") })
128
156
  ]
129
157
  }
130
158
  );
@@ -57,7 +57,7 @@ var DropdownMenuLabel = React.forwardRef(({ className, inset, ...props }, ref) =
57
57
  ref,
58
58
  "data-slot": "dropdown-menu-label",
59
59
  "data-inset": inset,
60
- className: cn("px-2 py-1.5 text-sm font-semibold data-[inset=true]:ps-8", className),
60
+ className: cn("px-2 py-1.5 text-sm font-medium data-[inset=true]:ps-8", className),
61
61
  ...props
62
62
  }
63
63
  ));