@vamos-ui/react 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (194) hide show
  1. package/README.md +4 -0
  2. package/dist/blocks/block-heading.js +1 -1
  3. package/dist/blocks/block-link.js +1 -1
  4. package/dist/blocks/index.d.ts +3 -3
  5. package/dist/blocks/index.js +3 -3
  6. package/dist/blocks/labels.d.ts +8 -0
  7. package/dist/blocks/labels.js +60 -0
  8. package/dist/blocks/section-header.js +1 -1
  9. package/dist/blocks/section.js +2 -2
  10. package/dist/blocks/site/feature-tabs.js +1 -1
  11. package/dist/blocks/site/footer.d.ts +10 -1
  12. package/dist/blocks/site/footer.js +28 -4
  13. package/dist/blocks/site/registry-2.js +3 -1
  14. package/dist/blocks/site/shared/labels-2.d.ts +8 -0
  15. package/dist/blocks/site/shared/labels-2.js +808 -0
  16. package/dist/blocks/site/site-shell.js +3 -3
  17. package/dist/business/approval-flow.js +2 -2
  18. package/dist/business/import-wizard.js +1 -1
  19. package/dist/business/line-items.js +1 -1
  20. package/dist/business/multi-step-form.js +2 -2
  21. package/dist/business/permission-matrix.js +1 -1
  22. package/dist/business/setup-checklist.js +2 -2
  23. package/dist/business/signer-status.js +1 -1
  24. package/dist/charts/bar-list.js +1 -1
  25. package/dist/charts/chart-shell.js +1 -1
  26. package/dist/charts/donut-chart.js +1 -1
  27. package/dist/charts/funnel.js +1 -1
  28. package/dist/charts/gauge.js +2 -2
  29. package/dist/components/accordion.d.ts +1 -1
  30. package/dist/components/accordion.js +8 -8
  31. package/dist/components/activity-timeline.js +6 -6
  32. package/dist/components/address-field.js +3 -3
  33. package/dist/components/alert-dialog.d.ts +1 -1
  34. package/dist/components/alert-dialog.js +8 -8
  35. package/dist/components/alert.js +2 -2
  36. package/dist/components/app-shell.js +3 -3
  37. package/dist/components/aspect-ratio.js +2 -2
  38. package/dist/components/attachment-list.js +2 -2
  39. package/dist/components/audit-log.js +1 -1
  40. package/dist/components/avatar.d.ts +1 -1
  41. package/dist/components/avatar.js +8 -8
  42. package/dist/components/backup-codes.js +1 -1
  43. package/dist/components/badge.js +3 -3
  44. package/dist/components/breadcrumb.js +10 -9
  45. package/dist/components/button-group.js +4 -4
  46. package/dist/components/button.js +4 -4
  47. package/dist/components/calendar.js +5 -5
  48. package/dist/components/card.js +8 -8
  49. package/dist/components/carousel.js +9 -9
  50. package/dist/components/checkbox.d.ts +1 -1
  51. package/dist/components/checkbox.js +6 -6
  52. package/dist/components/collapsible.d.ts +1 -1
  53. package/dist/components/collapsible.js +4 -4
  54. package/dist/components/color-picker.js +3 -3
  55. package/dist/components/combobox.js +1 -1
  56. package/dist/components/command.js +9 -9
  57. package/dist/components/comment-thread.js +3 -3
  58. package/dist/components/context-menu.d.ts +1 -1
  59. package/dist/components/context-menu.js +9 -9
  60. package/dist/components/currency-input.js +1 -1
  61. package/dist/components/date-picker.js +2 -2
  62. package/dist/components/date-range-picker.js +1 -1
  63. package/dist/components/description-list.js +2 -2
  64. package/dist/components/dialog.d.ts +1 -1
  65. package/dist/components/dialog.js +9 -9
  66. package/dist/components/dropdown-menu.d.ts +1 -1
  67. package/dist/components/dropdown-menu.js +9 -9
  68. package/dist/components/editor-layout.js +9 -9
  69. package/dist/components/empty-state.js +2 -2
  70. package/dist/components/entity-card.js +1 -1
  71. package/dist/components/file-upload.js +5 -5
  72. package/dist/components/formatted-input.js +3 -3
  73. package/dist/components/hierarchy-chart.js +1 -1
  74. package/dist/components/hover-card.d.ts +1 -1
  75. package/dist/components/hover-card.js +3 -3
  76. package/dist/components/iban-input.js +1 -1
  77. package/dist/components/id-input.js +3 -3
  78. package/dist/components/image.js +5 -5
  79. package/dist/components/input-otp.js +6 -6
  80. package/dist/components/input.d.ts +1 -1
  81. package/dist/components/input.js +6 -6
  82. package/dist/components/item.js +4 -4
  83. package/dist/components/kbd.js +3 -3
  84. package/dist/components/list-layout.js +9 -9
  85. package/dist/components/menubar.d.ts +1 -1
  86. package/dist/components/menubar.js +12 -12
  87. package/dist/components/native-select.js +1 -1
  88. package/dist/components/navigation-menu.d.ts +1 -1
  89. package/dist/components/navigation-menu.js +12 -11
  90. package/dist/components/notification-center.js +4 -4
  91. package/dist/components/page-header.js +3 -3
  92. package/dist/components/pagination.js +9 -9
  93. package/dist/components/phone-input.js +1 -1
  94. package/dist/components/pin-map.js +1 -1
  95. package/dist/components/placeholder-art.js +1 -1
  96. package/dist/components/popover.d.ts +1 -1
  97. package/dist/components/popover.js +7 -7
  98. package/dist/components/progress.js +3 -3
  99. package/dist/components/qr-code.js +1 -1
  100. package/dist/components/radio-group.d.ts +1 -1
  101. package/dist/components/radio-group.js +4 -4
  102. package/dist/components/record-detail-layout.js +10 -10
  103. package/dist/components/record-picker.js +2 -2
  104. package/dist/components/resizable.js +2 -2
  105. package/dist/components/scroll-area.d.ts +1 -1
  106. package/dist/components/scroll-area.js +4 -4
  107. package/dist/components/select.d.ts +1 -1
  108. package/dist/components/select.js +10 -10
  109. package/dist/components/separator.d.ts +1 -1
  110. package/dist/components/separator.js +3 -3
  111. package/dist/components/settings-layout.js +6 -6
  112. package/dist/components/sheet.js +3 -3
  113. package/dist/components/sidebar.js +12 -11
  114. package/dist/components/signature-pad.js +1 -1
  115. package/dist/components/skeleton.js +5 -5
  116. package/dist/components/sla-timer.js +2 -2
  117. package/dist/components/slider.d.ts +1 -1
  118. package/dist/components/slider.js +2 -2
  119. package/dist/components/slug-input.js +1 -1
  120. package/dist/components/sparkline.js +1 -1
  121. package/dist/components/spinner.js +2 -2
  122. package/dist/components/stat.js +5 -5
  123. package/dist/components/status-picker.js +2 -2
  124. package/dist/components/stepper.js +1 -1
  125. package/dist/components/switch.d.ts +1 -1
  126. package/dist/components/switch.js +3 -3
  127. package/dist/components/table.js +10 -10
  128. package/dist/components/tabs.d.ts +1 -1
  129. package/dist/components/tabs.js +11 -11
  130. package/dist/components/tag-input.js +1 -1
  131. package/dist/components/task-list.js +1 -1
  132. package/dist/components/time-picker.js +3 -3
  133. package/dist/components/toggle.d.ts +2 -1
  134. package/dist/components/toggle.js +7 -6
  135. package/dist/components/tooltip.d.ts +1 -1
  136. package/dist/components/tooltip.js +5 -4
  137. package/dist/components/top-bar.js +4 -4
  138. package/dist/components/tour.js +1 -1
  139. package/dist/components/tree-select.js +2 -2
  140. package/dist/components/tree-view.js +3 -3
  141. package/dist/components/typography.js +11 -11
  142. package/dist/components/user-picker.js +2 -2
  143. package/dist/components/version-history.js +3 -3
  144. package/dist/data-table/data-table.js +1 -1
  145. package/dist/data-table/filter-bar.js +2 -2
  146. package/dist/data-table/index.d.ts +15 -8
  147. package/dist/data-table/index.js +9 -8
  148. package/dist/data-table/saved-views.js +1 -1
  149. package/dist/editor/block-editor.js +1 -1
  150. package/dist/editor/context.js +1 -1
  151. package/dist/editor/menus.js +1 -1
  152. package/dist/fonts/font-picker.js +3 -3
  153. package/dist/fonts/pairing-picker.js +1 -1
  154. package/dist/fonts/provider.js +1 -1
  155. package/dist/index.d.ts +188 -94
  156. package/dist/index.js +94 -94
  157. package/dist/lib/data-islands.js +1 -1
  158. package/dist/lib/field-context.js +1 -1
  159. package/dist/lib/floating-arrow.js +1 -1
  160. package/dist/lib/islands.js +1 -1
  161. package/dist/lib/layer.js +3 -3
  162. package/dist/lib/locale.js +2 -2
  163. package/dist/lib/menu.js +2 -2
  164. package/dist/lib/provider.js +4 -4
  165. package/dist/lib/theme-scope.js +4 -3
  166. package/dist/lib/variants.js +2 -2
  167. package/dist/media/focal-point.js +1 -1
  168. package/dist/media/gallery.js +1 -1
  169. package/dist/media/image-cropper.js +1 -1
  170. package/dist/media/image-field.js +2 -2
  171. package/dist/media/lightbox.js +4 -3
  172. package/dist/media/link-preview.js +3 -3
  173. package/dist/media/media-library.js +3 -3
  174. package/dist/media/media-picker.js +1 -1
  175. package/dist/media/media-provider.js +1 -1
  176. package/dist/media/video-player.js +4 -4
  177. package/dist/motion/count-up.js +1 -1
  178. package/dist/motion/motion-scope.js +2 -2
  179. package/dist/motion/page-transition.js +1 -1
  180. package/dist/motion/parallax.js +2 -2
  181. package/dist/motion/pointer.js +3 -3
  182. package/dist/motion/reveal.js +3 -3
  183. package/dist/motion/skeleton-swap.js +1 -1
  184. package/dist/motion/text-reveal.js +1 -1
  185. package/dist/motion/ticker.js +1 -1
  186. package/dist/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -0
  187. package/dist/scheduler/gantt.js +2 -2
  188. package/dist/scheduler/resource-calendar.js +2 -2
  189. package/dist/scheduler/scheduler.js +3 -3
  190. package/dist/scheduler/time-tracker.js +4 -4
  191. package/dist/sortable/kanban.js +2 -2
  192. package/dist/sortable/sortable-list.js +2 -2
  193. package/dist/sortable/sortable.js +4 -4
  194. package/package.json +1 -1
@@ -16,13 +16,13 @@ const PATTERNS = {
16
16
  digits: "^\\d+$",
17
17
  alphanumeric: "^[a-zA-Z0-9]+$",
18
18
  };
19
- const OTPStyleContext = React.createContext({ size: "md", mask: false, invalid: false });
19
+ const OTPStyleContext = /*#__PURE__*/ React.createContext({ size: "md", mask: false, invalid: false });
20
20
  /**
21
21
  * One real `<input>` (screen readers, SMS autofill, password managers and paste all see one
22
22
  * field) with visual slots drawn over it. Compose `InputOTPGroup` / `InputOTPSlot` /
23
23
  * `InputOTPSeparator`, or use the `InputOTP` shorthand.
24
24
  */
25
- export const InputOTPRoot = React.forwardRef(function InputOTPRoot(rawProps, ref) {
25
+ export const InputOTPRoot = /*#__PURE__*/ React.forwardRef(function InputOTPRoot(rawProps, ref) {
26
26
  const { maxLength, value: valueProp, defaultValue, onValueChange, onComplete, pattern = "digits", size = "md", mask = false, invalid, loading, containerClassName, className, labels, children, ...rest } = rawProps;
27
27
  const t = useLabels("otp", otpLabels, labels);
28
28
  const field = useFieldContext();
@@ -37,11 +37,11 @@ export const InputOTPRoot = React.forwardRef(function InputOTPRoot(rawProps, ref
37
37
  dir: "ltr", children: _jsxs(_Fragment, { children: [children, loading ? (_jsx("span", { className: "ms-1 inline-flex items-center", children: _jsx(Spinner, { size: "sm", tone: "muted", label: t("verifying") }) })) : null] }) }) }));
38
38
  });
39
39
  /** A run of joined slots. */
40
- export const InputOTPGroup = React.forwardRef(function InputOTPGroup({ className, ...props }, ref) {
40
+ export const InputOTPGroup = /*#__PURE__*/ React.forwardRef(function InputOTPGroup({ className, ...props }, ref) {
41
41
  return _jsx("div", { ref: ref, "data-slot": "input-otp-group", className: cn("ui-otp-group flex items-center", className), ...props });
42
42
  });
43
43
  /** One visual character box: active ring, fake caret, filled state. */
44
- export const InputOTPSlot = React.forwardRef(function InputOTPSlot({ index, className, ...props }, ref) {
44
+ export const InputOTPSlot = /*#__PURE__*/ React.forwardRef(function InputOTPSlot({ index, className, ...props }, ref) {
45
45
  const ctx = React.useContext(OTPInputContext);
46
46
  const { size, mask, invalid } = React.useContext(OTPStyleContext);
47
47
  const slot = ctx.slots[index];
@@ -49,7 +49,7 @@ export const InputOTPSlot = React.forwardRef(function InputOTPSlot({ index, clas
49
49
  return (_jsxs("div", { ref: ref, "data-slot": "input-otp-slot", "data-active": slot?.isActive ? "" : undefined, "data-filled": char ? "" : undefined, "aria-hidden": true, className: cn("relative flex items-center justify-center border-y border-e border-field-border bg-field font-medium text-fg tabular", "transition-[border-color,box-shadow,background-color] duration-150", "first:rounded-s-ui first:border-s last:rounded-e-ui", size === "lg" ? "h-[calc(var(--control-h)+1rem)] w-[calc(var(--control-h)+0.25rem)] text-xl" : "h-[calc(var(--control-h)+0.25rem)] w-[calc(var(--control-h)-0.25rem)] text-lg", "group-hover/otp:border-field-border-hover", slot?.isActive && "z-10 border-ring shadow-[0_0_0_3px_var(--accent-soft)]", slot?.isActive && "border-s", invalid && "border-danger", invalid && slot?.isActive && "shadow-[0_0_0_3px_color-mix(in_srgb,var(--danger)_18%,transparent)]", className), ...props, children: [char ? mask ? _jsx("span", { className: "size-2 rounded-full bg-current" }) : char : null, slot?.hasFakeCaret ? (_jsx("span", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: _jsx("span", { className: "ui-otp-caret h-[45%] w-px bg-fg" }) })) : null] }));
50
50
  });
51
51
  /** Visual divider between groups (123–456). */
52
- export const InputOTPSeparator = React.forwardRef(function InputOTPSeparator({ className, ...props }, ref) {
52
+ export const InputOTPSeparator = /*#__PURE__*/ React.forwardRef(function InputOTPSeparator({ className, ...props }, ref) {
53
53
  return (_jsx("div", { ref: ref, role: "separator", "data-slot": "input-otp-separator", className: cn("flex w-3 items-center justify-center text-fg-subtle", className), ...props, children: _jsx("span", { className: "h-px w-2.5 bg-current" }) }));
54
54
  });
55
55
  /**
@@ -62,7 +62,7 @@ export const InputOTPSeparator = React.forwardRef(function InputOTPSeparator({ c
62
62
  * </Field>
63
63
  * ```
64
64
  */
65
- export const InputOTP = React.forwardRef(function InputOTP({ length = 6, groups, ...props }, ref) {
65
+ export const InputOTP = /*#__PURE__*/ React.forwardRef(function InputOTP({ length = 6, groups, ...props }, ref) {
66
66
  const sizes = groups && groups.reduce((a, b) => a + b, 0) === length ? groups : [length];
67
67
  let start = 0;
68
68
  return (_jsx(InputOTPRoot, { ref: ref, maxLength: length, ...props, children: sizes.map((count, gi) => {
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- import { Label as LabelPrimitive } from "radix-ui";
2
+ import * as LabelPrimitive from "radix-ui/label";
3
3
  /**
4
4
  * The classic field look for a bare `<input>` / `<textarea>`. Kept for compatibility —
5
5
  * new controls should use `controlVariants` from `lib/variants`.
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import * as React from "react";
4
- import { Label as LabelPrimitive } from "radix-ui";
4
+ import * as LabelPrimitive from "radix-ui/label";
5
5
  import { CircleAlert, X } from "lucide-react";
6
6
  import { cn } from "../lib/cn.js";
7
7
  import { useComposedRefs, mergeIds } from "../lib/compose-refs.js";
@@ -39,7 +39,7 @@ const setNativeValue = (el, value) => {
39
39
  * <Input addonStart="https://" addonEnd=".vamos.ist" defaultValue="northpoint" />
40
40
  * ```
41
41
  */
42
- export const Input = React.forwardRef(function Input(rawProps, forwardedRef) {
42
+ export const Input = /*#__PURE__*/ React.forwardRef(function Input(rawProps, forwardedRef) {
43
43
  const { className, inputClassName, size = "md", variant = "default", leading, trailing, addonStart, addonEnd, clearable, onClear, showCount, invalid, labels, style, ...rest } = rawProps;
44
44
  const props = useFieldControl({ ...rest, "aria-invalid": invalid ? true : rest["aria-invalid"] });
45
45
  const t = useLabels("input", inputLabels, labels);
@@ -92,7 +92,7 @@ export const Input = React.forwardRef(function Input(rawProps, forwardedRef) {
92
92
  * <Field label="Anything we should know first?"><Textarea maxLength={400} showCount /></Field>
93
93
  * ```
94
94
  */
95
- export const Textarea = React.forwardRef(function Textarea({ className, rows = 4, invalid, showCount, labels, ...rest }, ref) {
95
+ export const Textarea = /*#__PURE__*/ React.forwardRef(function Textarea({ className, rows = 4, invalid, showCount, labels, ...rest }, ref) {
96
96
  const props = useFieldControl({ ...rest, "aria-invalid": invalid ? true : rest["aria-invalid"] });
97
97
  const t = useLabels("input", inputLabels, labels);
98
98
  const countId = React.useId();
@@ -114,7 +114,7 @@ export const Textarea = React.forwardRef(function Textarea({ className, rows = 4
114
114
  /* Label */
115
115
  /* ------------------------------------------------------------------ */
116
116
  /** Form label (Radix Label: no text selection on double-click). */
117
- export const Label = React.forwardRef(function Label({ className, ...props }, ref) {
117
+ export const Label = /*#__PURE__*/ React.forwardRef(function Label({ className, ...props }, ref) {
118
118
  return (_jsx(LabelPrimitive.Root, { ref: ref, "data-slot": "label", className: cn("text-[13px] font-medium text-fg", className), ...props }));
119
119
  });
120
120
  /* ------------------------------------------------------------------ */
@@ -175,13 +175,13 @@ export function Field({ label, hint, error, id, name, required = false, optional
175
175
  * </Fieldset>
176
176
  * ```
177
177
  */
178
- export const Fieldset = React.forwardRef(function Fieldset({ legend, hint, error, className, children, "aria-describedby": describedBy, ...props }, ref) {
178
+ export const Fieldset = /*#__PURE__*/ React.forwardRef(function Fieldset({ legend, hint, error, className, children, "aria-describedby": describedBy, ...props }, ref) {
179
179
  const id = React.useId();
180
180
  const hintId = hint && !error ? `${id}-hint` : undefined;
181
181
  const errorId = error ? `${id}-error` : undefined;
182
182
  return (_jsxs("fieldset", { ref: ref, "data-slot": "fieldset", "aria-describedby": mergeIds(hintId, errorId, describedBy), "data-invalid": error ? "" : undefined, className: cn("grid min-w-0 gap-3 border-0 p-0 disabled:opacity-60", className), ...props, children: [legend ? _jsx(Legend, { className: "float-left w-full", children: legend }) : null, hint && !error ? (_jsx("p", { id: hintId, className: "-mt-2 text-xs text-fg-subtle", children: hint })) : null, error ? (_jsxs("p", { id: errorId, className: "-mt-2 flex items-start gap-1.5 text-xs text-danger", children: [_jsx(CircleAlert, { "aria-hidden": true, className: "mt-px size-3.5 shrink-0" }), _jsx("span", { children: error })] })) : null, children] }));
183
183
  });
184
184
  /** Title of a Fieldset. */
185
- export const Legend = React.forwardRef(function Legend({ className, ...props }, ref) {
185
+ export const Legend = /*#__PURE__*/ React.forwardRef(function Legend({ className, ...props }, ref) {
186
186
  return _jsx("legend", { ref: ref, "data-slot": "legend", className: cn("mb-0 p-0 text-sm font-semibold tracking-[-0.005em] text-fg", className), ...props });
187
187
  });
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import * as React from "react";
3
- import { Slot } from "radix-ui";
3
+ import * as Slot from "radix-ui/slot";
4
4
  import { Check } from "lucide-react";
5
5
  import { cva } from "class-variance-authority";
6
6
  import { cn } from "../lib/cn.js";
@@ -16,7 +16,7 @@ import { Skeleton } from "./skeleton.js";
16
16
  * </ItemList>
17
17
  * ```
18
18
  */
19
- export const ItemList = React.forwardRef(function ItemList({ divided = true, inset, selectable, value, defaultValue, onValueChange, as = "ul", empty, className, children, ...props }, ref) {
19
+ export const ItemList = /*#__PURE__*/ React.forwardRef(function ItemList({ divided = true, inset, selectable, value, defaultValue, onValueChange, as = "ul", empty, className, children, ...props }, ref) {
20
20
  const count = React.Children.toArray(children).length;
21
21
  const classes = cn("group/list m-0 grid list-none p-0", inset && "-mx-2 gap-0.5",
22
22
  // hairline at the bottom of every row but the last (also through an asChild wrapper)
@@ -34,7 +34,7 @@ export const ItemList = React.forwardRef(function ItemList({ divided = true, ins
34
34
  /* ------------------------------------------------------------------ */
35
35
  /* Item */
36
36
  /* ------------------------------------------------------------------ */
37
- export const itemRowVariants = cva([
37
+ export const itemRowVariants = /*#__PURE__*/ cva([
38
38
  "group/item relative flex w-full min-w-0 gap-3 text-start text-[13px] text-fg outline-none",
39
39
  "px-(--card-p,1.25rem) group-data-inset/list:rounded-ui-sm group-data-inset/list:px-2",
40
40
  // states (also driven by the listbox island via aria-selected / aria-disabled)
@@ -67,7 +67,7 @@ export const itemRowVariants = cva([
67
67
  * </Item>
68
68
  * ```
69
69
  */
70
- export const Item = React.forwardRef(function Item({ value, asChild, interactive, disabled, size, align, as = "li", className, children, ...props }, ref) {
70
+ export const Item = /*#__PURE__*/ React.forwardRef(function Item({ value, asChild, interactive, disabled, size, align, as = "li", className, children, ...props }, ref) {
71
71
  const option = value !== undefined;
72
72
  const rowClass = cn(itemRowVariants({ size, align, interactive: interactive ?? (asChild || option) }), className);
73
73
  const state = {
@@ -5,7 +5,7 @@ import { cva } from "class-variance-authority";
5
5
  import { cn } from "../lib/cn.js";
6
6
  import { formatKey, parseShortcut, shortcutKeys, useIsMac } from "../lib/use-hotkeys.js";
7
7
  import { useLabels } from "../lib/labels.js";
8
- export const kbdVariants = cva("ui-keycap inline-flex shrink-0 select-none items-center justify-center whitespace-nowrap rounded-[calc(var(--radius)*0.42)] font-mono font-medium leading-none tabular", {
8
+ export const kbdVariants = /*#__PURE__*/ cva("ui-keycap inline-flex shrink-0 select-none items-center justify-center whitespace-nowrap rounded-[calc(var(--radius)*0.42)] font-mono font-medium leading-none tabular", {
9
9
  variants: {
10
10
  size: {
11
11
  sm: "h-[1.125rem] min-w-[1.125rem] px-1 text-[10.5px]",
@@ -85,7 +85,7 @@ function spokenKey(token, isMac) {
85
85
  * <Kbd keyName="mod" /> // ⌘ on macOS, Ctrl elsewhere
86
86
  * ```
87
87
  */
88
- export const Kbd = React.forwardRef(function Kbd({ keyName, size, variant, labels, className, children, ...props }, ref) {
88
+ export const Kbd = /*#__PURE__*/ React.forwardRef(function Kbd({ keyName, size, variant, labels, className, children, ...props }, ref) {
89
89
  const isMac = useIsMac();
90
90
  const t = useLabels("kbd", kbdLabels, labels);
91
91
  let content = children;
@@ -112,7 +112,7 @@ export const Kbd = React.forwardRef(function Kbd({ keyName, size, variant, label
112
112
  * <KbdGroup keys={["g", "p"]} separator="then" />
113
113
  * ```
114
114
  */
115
- export const KbdGroup = React.forwardRef(function KbdGroup({ keys, separator, size, variant, labels, className, ...props }, ref) {
115
+ export const KbdGroup = /*#__PURE__*/ React.forwardRef(function KbdGroup({ keys, separator, size, variant, labels, className, ...props }, ref) {
116
116
  const isMac = useIsMac();
117
117
  const tokens = typeof keys === "string" ? shortcutKeys(keys, isMac) : keys;
118
118
  return (_jsx("kbd", { ref: ref, dir: "ltr", "data-slot": "kbd-group", className: cn("inline-flex items-center gap-1 font-sans", className), ...props, children: tokens.map((k, i) => (_jsxs(React.Fragment, { children: [i > 0 && separator != null ? (_jsx("span", { "aria-hidden": typeof separator === "string" && /^[+\-–]$/.test(separator) ? true : undefined, className: "text-[11px] text-fg-subtle", children: separator })) : null, _jsx(Kbd, { keyName: k, size: size, variant: variant, labels: labels })] }, `${k}-${i}`))) }));
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import * as React from "react";
4
- import { ToggleGroup as ToggleGroupPrimitive } from "radix-ui";
4
+ import * as ToggleGroupPrimitive from "radix-ui/toggle-group";
5
5
  import { cva } from "class-variance-authority";
6
6
  import { SlidersHorizontal, X } from "lucide-react";
7
7
  import { cn } from "../lib/cn.js";
@@ -35,11 +35,11 @@ const listLabels = {
35
35
  error: "Couldn't load this list",
36
36
  retry: "Try again",
37
37
  };
38
- const ListLayoutContext = React.createContext(null);
38
+ const ListLayoutContext = /*#__PURE__*/ React.createContext(null);
39
39
  /* ------------------------------------------------------------------ */
40
40
  /* ListLayout */
41
41
  /* ------------------------------------------------------------------ */
42
- export const listLayoutVariants = cva("@container/list relative mx-auto flex w-full min-w-0 flex-col", {
42
+ export const listLayoutVariants = /*#__PURE__*/ cva("@container/list relative mx-auto flex w-full min-w-0 flex-col", {
43
43
  variants: {
44
44
  width: {
45
45
  /** Edge to edge of the page area. */
@@ -70,7 +70,7 @@ export const listLayoutVariants = cva("@container/list relative mx-auto flex w-f
70
70
  *
71
71
  * Responds to its own width (container queries), so it behaves the same in a split view.
72
72
  */
73
- export const ListLayout = React.forwardRef(function ListLayout({ width = "full", stickyToolbar = true, stickyTop, className, style, ...props }, ref) {
73
+ export const ListLayout = /*#__PURE__*/ React.forwardRef(function ListLayout({ width = "full", stickyToolbar = true, stickyTop, className, style, ...props }, ref) {
74
74
  const [bulkActive, setBulkActive] = React.useState(false);
75
75
  const toolbarRef = React.useRef(null);
76
76
  const ctx = React.useMemo(() => ({ stickyToolbar, bulkActive, setBulkActive, toolbarRef }), [stickyToolbar, bulkActive]);
@@ -82,7 +82,7 @@ const stickyBar = "sticky top-(--list-sticky-top,var(--topbar-h)) z-(--z-sticky)
82
82
  * The row above the content. Sticky under the top bar on the bar surface; while a selection is
83
83
  * active the `ListBulkBar` takes its place.
84
84
  */
85
- export const ListToolbar = React.forwardRef(function ListToolbar({ search, filters, filterCount, views, viewSwitch, actions, searchLabel, labels, className, children, ...props }, ref) {
85
+ export const ListToolbar = /*#__PURE__*/ React.forwardRef(function ListToolbar({ search, filters, filterCount, views, viewSwitch, actions, searchLabel, labels, className, children, ...props }, ref) {
86
86
  const t = useLabels("list", listLabels, labels);
87
87
  const ctx = React.useContext(ListLayoutContext);
88
88
  const setRefs = React.useCallback((node) => {
@@ -102,7 +102,7 @@ export const ListToolbar = React.forwardRef(function ListToolbar({ search, filte
102
102
  * Table / grid / board switch: a segmented radio group (one tab stop, arrow keys move, Space selects). Labels
103
103
  * collapse to icons below ~640px of list width; the accessible name stays.
104
104
  */
105
- export const ListViewSwitch = React.forwardRef(function ListViewSwitch({ options, value: valueProp, defaultValue, onValueChange, label, labels, className, ...props }, ref) {
105
+ export const ListViewSwitch = /*#__PURE__*/ React.forwardRef(function ListViewSwitch({ options, value: valueProp, defaultValue, onValueChange, label, labels, className, ...props }, ref) {
106
106
  const t = useLabels("list", listLabels, labels);
107
107
  const [inner, setInner] = React.useState(defaultValue ?? options[0]?.value ?? "");
108
108
  const value = valueProp ?? inner;
@@ -118,7 +118,7 @@ export const ListViewSwitch = React.forwardRef(function ListViewSwitch({ options
118
118
  * The selection bar. Presentational: the Data Table (or your list) owns the selection. Announces
119
119
  * "{n} selected" politely; Esc inside the bar clears the selection and focus returns to the toolbar.
120
120
  */
121
- export const ListBulkBar = React.forwardRef(function ListBulkBar({ count, total, onSelectAll, allSelected, onClear, labels, className, children, onKeyDown, ...props }, ref) {
121
+ export const ListBulkBar = /*#__PURE__*/ React.forwardRef(function ListBulkBar({ count, total, onSelectAll, allSelected, onClear, labels, className, children, onKeyDown, ...props }, ref) {
122
122
  const t = useLabels("list", listLabels, labels);
123
123
  const f = useFormat();
124
124
  const ctx = React.useContext(ListLayoutContext);
@@ -155,7 +155,7 @@ export const ListBulkBar = React.forwardRef(function ListBulkBar({ count, total,
155
155
  * The content slot (table, grid or board) with every state. `refreshing` keeps the content and
156
156
  * shows a thin indeterminate bar; all states set `aria-busy` while work is pending.
157
157
  */
158
- export const ListContent = React.forwardRef(function ListContent({ state = "ready", empty, noResults, error, onRetry, onClearFilters, skeleton, skeletonRows = 6, resultCount, labels, className, children, ...props }, ref) {
158
+ export const ListContent = /*#__PURE__*/ React.forwardRef(function ListContent({ state = "ready", empty, noResults, error, onRetry, onClearFilters, skeleton, skeletonRows = 6, resultCount, labels, className, children, ...props }, ref) {
159
159
  const t = useLabels("list", listLabels, labels);
160
160
  const busy = state === "loading" || state === "refreshing";
161
161
  // Announce state changes once (not on every render).
@@ -205,6 +205,6 @@ export const ListContent = React.forwardRef(function ListContent({ state = "read
205
205
  return (_jsxs("div", { ref: ref, "data-slot": "list-content", "data-state": state, "aria-busy": busy || undefined, className: cn("relative min-w-0 flex-1 py-4", className), ...props, children: [state === "refreshing" ? (_jsx(Progress, { "aria-label": t("refreshing"), value: null, size: "xs", className: "absolute inset-x-0 top-0 rounded-none bg-transparent" })) : null, _jsx("div", { className: cn(state === "refreshing" && "opacity-70 transition-opacity motion-reduce:transition-none"), children: body }), _jsx("div", { "aria-live": "polite", role: "status", className: "sr-only", children: announcement })] }));
206
206
  });
207
207
  /** The row under the content: `PaginationBar`, "Load more", a summary line. */
208
- export const ListFooter = React.forwardRef(function ListFooter({ className, ...props }, ref) {
208
+ export const ListFooter = /*#__PURE__*/ React.forwardRef(function ListFooter({ className, ...props }, ref) {
209
209
  return _jsx("div", { ref: ref, "data-slot": "list-footer", className: cn("flex flex-wrap items-center gap-3 border-t border-line pt-3 pb-1", className), ...props });
210
210
  });
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- import { Menubar as MenubarPrimitive } from "radix-ui";
2
+ import * as MenubarPrimitive from "radix-ui/menubar";
3
3
  import { type VariantProps } from "class-variance-authority";
4
4
  import type { MenuEntry } from "../lib/variants.js";
5
5
  export declare const menubarVariants: (props?: ({
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import * as React from "react";
4
- import { Menubar as MenubarPrimitive } from "radix-ui";
4
+ import * as MenubarPrimitive from "radix-ui/menubar";
5
5
  import { cva } from "class-variance-authority";
6
6
  import { cn } from "../lib/cn.js";
7
7
  import { usePortalContainer } from "../lib/theme-scope.js";
@@ -11,7 +11,7 @@ import { MenuCheckIcon, MenuEntries, MenuItemContent, MenuRadioDot, MenuSizeCont
11
11
  /* ------------------------------------------------------------------ */
12
12
  /* Bar */
13
13
  /* ------------------------------------------------------------------ */
14
- export const menubarVariants = cva("flex min-w-0 items-center gap-0.5 overflow-x-auto [scrollbar-width:none]", {
14
+ export const menubarVariants = /*#__PURE__*/ cva("flex min-w-0 items-center gap-0.5 overflow-x-auto [scrollbar-width:none]", {
15
15
  variants: {
16
16
  variant: {
17
17
  /** A hairline surface strip — the top of an editor or a desktop-style app window. */
@@ -32,7 +32,7 @@ export const menubarVariants = cva("flex min-w-0 items-center gap-0.5 overflow-x
32
32
  * ]} />
33
33
  * ```
34
34
  */
35
- export const Menubar = React.forwardRef(function Menubar({ className, variant, menus, size = "md", children, loop = true, ...props }, ref) {
35
+ export const Menubar = /*#__PURE__*/ React.forwardRef(function Menubar({ className, variant, menus, size = "md", children, loop = true, ...props }, ref) {
36
36
  return (_jsx(MenuSizeContext.Provider, { value: size, children: _jsxs(MenubarPrimitive.Root, { ref: ref, "data-slot": "menubar", "data-variant": variant ?? "bar", loop: loop, className: cn(menubarVariants({ variant }), className), ...props, children: [menus ? _jsx(MenubarMenus, { menus: menus }) : null, children] }) }));
37
37
  });
38
38
  /** One menu: a `MenubarTrigger` plus its `MenubarContent`. `value` is needed only for a controlled bar. */
@@ -41,35 +41,35 @@ export const MenubarGroup = MenubarPrimitive.Group;
41
41
  export const MenubarSub = MenubarPrimitive.Sub;
42
42
  export const MenubarRadioGroup = MenubarPrimitive.RadioGroup;
43
43
  /** The top-level button ("File"). */
44
- export const MenubarTrigger = React.forwardRef(function MenubarTrigger({ className, ...props }, ref) {
44
+ export const MenubarTrigger = /*#__PURE__*/ React.forwardRef(function MenubarTrigger({ className, ...props }, ref) {
45
45
  return (_jsx(MenubarPrimitive.Trigger, { ref: ref, "data-slot": "menubar-trigger", className: cn("inline-flex h-[calc(var(--control-h)-0.5rem)] shrink-0 cursor-default select-none items-center gap-1.5 rounded-ui-sm px-2.5 text-[13px] font-medium text-fg outline-none", "transition-colors duration-100 hover:bg-hover focus-visible:bg-hover focus-ring", "data-highlighted:bg-hover data-[state=open]:bg-selected", "disabled:pointer-events-none disabled:opacity-45 data-disabled:pointer-events-none data-disabled:opacity-45", "[&_svg]:size-3.5 [&_svg]:shrink-0 [&_svg]:text-fg-muted", className), ...props }));
46
46
  });
47
47
  /** A menu panel under its trigger. Portals into the nearest `ThemeScope`; only this first layer blurs in glass mode. */
48
- export const MenubarContent = React.forwardRef(function MenubarContent({ className, size: sizeProp, sideOffset = 6, alignOffset = -4, collisionPadding = 12, align = "start", ...props }, ref) {
48
+ export const MenubarContent = /*#__PURE__*/ React.forwardRef(function MenubarContent({ className, size: sizeProp, sideOffset = 6, alignOffset = -4, collisionPadding = 12, align = "start", ...props }, ref) {
49
49
  const container = usePortalContainer();
50
50
  const barSize = React.useContext(MenuSizeContext);
51
51
  const size = sizeProp ?? barSize;
52
52
  return (_jsx(MenubarPrimitive.Portal, { container: container, children: _jsx(MenuSizeContext.Provider, { value: size, children: _jsx(Layer, { asChild: true, children: _jsx(MenubarPrimitive.Content, { ref: ref, "data-slot": "menubar-content", sideOffset: sideOffset, alignOffset: alignOffset, collisionPadding: collisionPadding, align: align, className: cn(menuContentVariants({ size }), "max-h-(--radix-menubar-content-available-height) origin-(--radix-menubar-content-transform-origin)", className), ...props }) }) }) }));
53
53
  });
54
54
  /** One command. `onSelect` fires on click, Enter and Space, then the menu closes (`event.preventDefault()` keeps it open). */
55
- export const MenubarItem = React.forwardRef(function MenubarItem({ className, icon, description, shortcut, badge, tone = "default", inset, asChild, children, ...props }, ref) {
55
+ export const MenubarItem = /*#__PURE__*/ React.forwardRef(function MenubarItem({ className, icon, description, shortcut, badge, tone = "default", inset, asChild, children, ...props }, ref) {
56
56
  const size = React.useContext(MenuSizeContext);
57
57
  return (_jsx(MenubarPrimitive.Item, { ref: ref, "data-slot": "menubar-item", "data-tone": tone, asChild: asChild, className: menuItemClass({ size, tone, inset, className }), ...props, children: asChild ? (children) : (_jsx(MenuItemContent, { icon: icon, description: description, shortcut: shortcut, badge: badge, children: children })) }));
58
58
  });
59
59
  /** A toggle (`menuitemcheckbox`) — "Show ruler", "Word wrap". */
60
- export const MenubarCheckboxItem = React.forwardRef(function MenubarCheckboxItem({ className, shortcut, description, children, ...props }, ref) {
60
+ export const MenubarCheckboxItem = /*#__PURE__*/ React.forwardRef(function MenubarCheckboxItem({ className, shortcut, description, children, ...props }, ref) {
61
61
  const size = React.useContext(MenuSizeContext);
62
62
  return (_jsxs(MenubarPrimitive.CheckboxItem, { ref: ref, "data-slot": "menubar-checkbox-item", className: menuItemClass({ size, inset: true, className }), ...props, children: [_jsx("span", { className: menuIndicatorClass, children: _jsx(MenubarPrimitive.ItemIndicator, { children: _jsx(MenuCheckIcon, {}) }) }), _jsx(MenuItemContent, { shortcut: shortcut, description: description, children: children })] }));
63
63
  });
64
64
  /** One choice inside a `MenubarRadioGroup` (`menuitemradio`) — zoom level, sort order. */
65
- export const MenubarRadioItem = React.forwardRef(function MenubarRadioItem({ className, shortcut, description, children, ...props }, ref) {
65
+ export const MenubarRadioItem = /*#__PURE__*/ React.forwardRef(function MenubarRadioItem({ className, shortcut, description, children, ...props }, ref) {
66
66
  const size = React.useContext(MenuSizeContext);
67
67
  return (_jsxs(MenubarPrimitive.RadioItem, { ref: ref, "data-slot": "menubar-radio-item", className: menuItemClass({ size, inset: true, className }), ...props, children: [_jsx("span", { className: menuIndicatorClass, children: _jsx(MenubarPrimitive.ItemIndicator, { children: _jsx(MenuRadioDot, {}) }) }), _jsx(MenuItemContent, { shortcut: shortcut, description: description, children: children })] }));
68
68
  });
69
- export const MenubarLabel = React.forwardRef(function MenubarLabel({ className, inset, ...props }, ref) {
69
+ export const MenubarLabel = /*#__PURE__*/ React.forwardRef(function MenubarLabel({ className, inset, ...props }, ref) {
70
70
  return _jsx(MenubarPrimitive.Label, { ref: ref, "data-slot": "menubar-label", className: cn(menuLabelClass, inset && "ps-8", className), ...props });
71
71
  });
72
- export const MenubarSeparator = React.forwardRef(function MenubarSeparator({ className, ...props }, ref) {
72
+ export const MenubarSeparator = /*#__PURE__*/ React.forwardRef(function MenubarSeparator({ className, ...props }, ref) {
73
73
  return _jsx(MenubarPrimitive.Separator, { ref: ref, "data-slot": "menubar-separator", className: cn(menuSeparatorClass, className), ...props });
74
74
  });
75
75
  /** Trailing text hint (when you don't want keycaps). */
@@ -77,12 +77,12 @@ export function MenubarShortcut({ className, ...props }) {
77
77
  return _jsx("span", { "data-slot": "menubar-shortcut", className: cn("ms-auto ps-4 font-mono text-[11px] tracking-wide text-fg-subtle", className), ...props });
78
78
  }
79
79
  /** Opens a submenu on hover, Enter, Space or → (← in RTL). */
80
- export const MenubarSubTrigger = React.forwardRef(function MenubarSubTrigger({ className, icon, inset, children, ...props }, ref) {
80
+ export const MenubarSubTrigger = /*#__PURE__*/ React.forwardRef(function MenubarSubTrigger({ className, icon, inset, children, ...props }, ref) {
81
81
  const size = React.useContext(MenuSizeContext);
82
82
  return (_jsx(MenubarPrimitive.SubTrigger, { ref: ref, "data-slot": "menubar-sub-trigger", className: menuItemClass({ size, inset, className: cn("data-[state=open]:bg-hover", className) }), ...props, children: _jsx(MenuItemContent, { icon: icon, chevron: true, children: children }) }));
83
83
  });
84
84
  /** A submenu panel. One layer deeper, so it is opaque in glass mode. */
85
- export const MenubarSubContent = React.forwardRef(function MenubarSubContent({ className, size: sizeProp, sideOffset = 4, alignOffset = -5, collisionPadding = 12, ...props }, ref) {
85
+ export const MenubarSubContent = /*#__PURE__*/ React.forwardRef(function MenubarSubContent({ className, size: sizeProp, sideOffset = 4, alignOffset = -5, collisionPadding = 12, ...props }, ref) {
86
86
  const container = usePortalContainer();
87
87
  const parentSize = React.useContext(MenuSizeContext);
88
88
  const size = sizeProp ?? parentSize;
@@ -16,7 +16,7 @@ import { controlVariants } from "../lib/variants.js";
16
16
  * </Field>
17
17
  * ```
18
18
  */
19
- export const NativeSelect = React.forwardRef(function NativeSelect({ className, selectClassName, size = "md", variant = "default", invalid, placeholder, items, children, ...rest }, ref) {
19
+ export const NativeSelect = /*#__PURE__*/ React.forwardRef(function NativeSelect({ className, selectClassName, size = "md", variant = "default", invalid, placeholder, items, children, ...rest }, ref) {
20
20
  const props = useFieldControl({ ...rest, "aria-invalid": invalid ? true : rest["aria-invalid"] });
21
21
  const { readOnly, ...selectProps } = props;
22
22
  let options = children;
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- import { NavigationMenu as RadixNav } from "radix-ui";
2
+ import * as RadixNav from "radix-ui/navigation-menu";
3
3
  declare const navLabels: {
4
4
  label: string;
5
5
  open: string;
@@ -1,7 +1,8 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import * as React from "react";
4
- import { Dialog, NavigationMenu as RadixNav } from "radix-ui";
4
+ import * as Dialog from "radix-ui/dialog";
5
+ import * as RadixNav from "radix-ui/navigation-menu";
5
6
  import { ChevronDown, Menu, X } from "lucide-react";
6
7
  import { cva } from "class-variance-authority";
7
8
  import { cn } from "../lib/cn.js";
@@ -19,7 +20,7 @@ const navLabels = {
19
20
  /* ------------------------------------------------------------------ */
20
21
  /* Root */
21
22
  /* ------------------------------------------------------------------ */
22
- const rootVariants = cva("relative z-(--z-nav) flex max-w-max flex-1 items-center justify-center", {
23
+ const rootVariants = /*#__PURE__*/ cva("relative z-(--z-nav) flex max-w-max flex-1 items-center justify-center", {
23
24
  variants: {
24
25
  variant: {
25
26
  /** Sits in a site header. */
@@ -49,7 +50,7 @@ const rootVariants = cva("relative z-(--z-nav) flex max-w-max flex-1 items-cente
49
50
  * </NavigationMenu>
50
51
  * ```
51
52
  */
52
- export const NavigationMenu = React.forwardRef(function NavigationMenu({ variant = "bar", viewport = true, items, labels, className, children, "aria-label": ariaLabel, ...props }, ref) {
53
+ export const NavigationMenu = /*#__PURE__*/ React.forwardRef(function NavigationMenu({ variant = "bar", viewport = true, items, labels, className, children, "aria-label": ariaLabel, ...props }, ref) {
53
54
  const t = useLabels("navigationMenu", navLabels, labels);
54
55
  return (_jsxs(RadixNav.Root, { ref: ref, "data-slot": "navigation-menu", "data-variant": variant, "data-viewport": viewport || undefined, "aria-label": ariaLabel ?? t("label"), className: cn(rootVariants({ variant }), className), ...props, children: [items ? _jsx(NavigationMenuItems, { items: items, viewport: viewport }) : children, viewport ? _jsx(NavigationMenuViewport, {}) : null] }));
55
56
  });
@@ -57,16 +58,16 @@ function NavigationMenuItems({ items, viewport }) {
57
58
  return (_jsx(NavigationMenuList, { children: items.map((item, i) => (_jsx(NavigationMenuItem, { children: item.children?.length ? (_jsxs(_Fragment, { children: [_jsx(NavigationMenuTrigger, { children: item.label }), _jsxs(NavigationMenuContent, { layout: item.layout, inline: !viewport, children: [item.layout === "featured" && item.featured ? _jsx(NavigationMenuFeatured, { ...item.featured }) : null, _jsx(NavigationMenuGroup, { children: item.children.map((child, j) => (_jsx("li", { children: _jsx(NavigationMenuLink, { href: child.href ?? "#", title: child.label, description: child.description, icon: child.icon }) }, child.id ?? j))) })] })] })) : (_jsx(NavigationMenuLink, { href: item.href ?? "#", variant: "top", children: item.label })) }, item.id ?? i))) }));
58
59
  }
59
60
  /** The row of top-level items. */
60
- export const NavigationMenuList = React.forwardRef(function NavigationMenuList({ className, ...props }, ref) {
61
+ export const NavigationMenuList = /*#__PURE__*/ React.forwardRef(function NavigationMenuList({ className, ...props }, ref) {
61
62
  return _jsx(RadixNav.List, { ref: ref, "data-slot": "navigation-menu-list", className: cn("flex flex-1 list-none items-center justify-center gap-0.5", className), ...props });
62
63
  });
63
64
  /** One top-level item (a trigger + content, or a plain link). */
64
- export const NavigationMenuItem = React.forwardRef(function NavigationMenuItem({ className, ...props }, ref) {
65
+ export const NavigationMenuItem = /*#__PURE__*/ React.forwardRef(function NavigationMenuItem({ className, ...props }, ref) {
65
66
  return _jsx(RadixNav.Item, { ref: ref, "data-slot": "navigation-menu-item", className: cn("relative", className), ...props });
66
67
  });
67
68
  const topItemClass = cn("group/nav inline-flex h-9 select-none items-center justify-center gap-1 rounded-full px-3.5 text-sm font-medium text-fg-muted outline-none", "transition-colors duration-150 hover:bg-hover hover:text-fg focus-ring", "data-[state=open]:bg-hover data-[state=open]:text-fg data-active:text-fg aria-[current=page]:text-fg");
68
69
  /** Opens a panel. Hover (with intent delay), click, Enter/Space or ↓. */
69
- export const NavigationMenuTrigger = React.forwardRef(function NavigationMenuTrigger({ className, children, ...props }, ref) {
70
+ export const NavigationMenuTrigger = /*#__PURE__*/ React.forwardRef(function NavigationMenuTrigger({ className, children, ...props }, ref) {
70
71
  return (_jsxs(RadixNav.Trigger, { ref: ref, "data-slot": "navigation-menu-trigger", className: cn(topItemClass, className), ...props, children: [children, _jsx(ChevronDown, { "aria-hidden": true, className: "relative top-px size-3.5 text-fg-subtle transition-transform duration-200 motion-reduce:transition-none group-data-[state=open]/nav:rotate-180" })] }));
71
72
  });
72
73
  const contentLayouts = {
@@ -75,19 +76,19 @@ const contentLayouts = {
75
76
  featured: "grid w-[min(42rem,calc(100vw-2rem))] grid-cols-[minmax(0,15rem)_minmax(0,1fr)] gap-2",
76
77
  };
77
78
  /** The panel of an item. */
78
- export const NavigationMenuContent = React.forwardRef(function NavigationMenuContent({ layout = "list", inline, className, ...props }, ref) {
79
+ export const NavigationMenuContent = /*#__PURE__*/ React.forwardRef(function NavigationMenuContent({ layout = "list", inline, className, ...props }, ref) {
79
80
  return (_jsx(RadixNav.Content, { ref: ref, "data-slot": "navigation-menu-content", "data-layout": layout, className: cn("ui-nav-content p-2", inline ? "surface-popover ui-pop absolute start-0 top-full z-(--z-popover) mt-2 rounded-ui-lg" : "start-0 top-0 md:absolute", contentLayouts[layout], className), ...props }));
80
81
  });
81
82
  /** The shared, animated container all panels render into. Rendered by `NavigationMenu` unless `viewport={false}`. */
82
- export const NavigationMenuViewport = React.forwardRef(function NavigationMenuViewport({ className, ...props }, ref) {
83
+ export const NavigationMenuViewport = /*#__PURE__*/ React.forwardRef(function NavigationMenuViewport({ className, ...props }, ref) {
83
84
  return (_jsx("div", { className: "absolute start-0 top-full z-(--z-popover) flex w-full justify-center pt-2", children: _jsx(Layer, { asChild: true, children: _jsx(RadixNav.Viewport, { ref: ref, "data-slot": "navigation-menu-viewport", className: cn("ui-pop ui-nav-viewport surface-popover relative shrink-0 origin-top overflow-hidden rounded-ui-lg", "h-(--radix-navigation-menu-viewport-height) w-full md:w-(--radix-navigation-menu-viewport-width)", className), ...props }) }) }));
84
85
  });
85
86
  /** A list of links inside a panel (`ul`). */
86
- export const NavigationMenuGroup = React.forwardRef(function NavigationMenuGroup({ heading, className, children, ...props }, ref) {
87
+ export const NavigationMenuGroup = /*#__PURE__*/ React.forwardRef(function NavigationMenuGroup({ heading, className, children, ...props }, ref) {
87
88
  return (_jsxs("div", { className: "min-w-0", children: [heading ? _jsx("p", { className: "px-3 pt-2 pb-1 text-[11px] font-medium tracking-[0.06em] text-fg-subtle", children: heading }) : null, _jsx("ul", { ref: ref, "data-slot": "navigation-menu-group", className: cn("grid list-none gap-0.5", className), ...props, children: children })] }));
88
89
  });
89
90
  /** A link — in the bar (`variant="top"`) or in a panel with icon and description. Uses the app's router `Link`. */
90
- export const NavigationMenuLink = React.forwardRef(function NavigationMenuLink({ href, variant = "panel", title, description, icon, active, className, children, ...props }, ref) {
91
+ export const NavigationMenuLink = /*#__PURE__*/ React.forwardRef(function NavigationMenuLink({ href, variant = "panel", title, description, icon, active, className, children, ...props }, ref) {
91
92
  const { isActive } = useNavigation();
92
93
  const current = active ?? isActive(href);
93
94
  if (variant === "top") {
@@ -100,7 +101,7 @@ export function NavigationMenuFeatured({ title, description, href, eyebrow, clas
100
101
  return (_jsx(RadixNav.Link, { asChild: true, children: _jsxs(SmartLink, { href: href, "data-slot": "navigation-menu-featured", className: cn("group/feat relative flex min-h-full flex-col justify-end overflow-hidden rounded-ui bg-fg p-5 text-scene outline-none focus-ring", className), children: [_jsx("span", { "aria-hidden": true, className: "absolute -end-10 -top-10 size-40 rounded-full border-[18px] border-accent opacity-90 transition-transform duration-300 group-hover/feat:scale-105 motion-reduce:transition-none" }), eyebrow ? _jsx("span", { className: "relative mb-auto text-[11px] font-medium tracking-[0.08em] opacity-70", children: eyebrow }) : null, _jsx("span", { className: "relative mt-10 font-display text-[1.375rem] leading-tight", children: title }), description ? _jsx("span", { className: "relative mt-1.5 text-[13px] leading-snug opacity-75", children: description }) : null] }) }));
101
102
  }
102
103
  /** Optional arrow under the open trigger. */
103
- export const NavigationMenuIndicator = React.forwardRef(function NavigationMenuIndicator({ className, ...props }, ref) {
104
+ export const NavigationMenuIndicator = /*#__PURE__*/ React.forwardRef(function NavigationMenuIndicator({ className, ...props }, ref) {
104
105
  return (_jsx(RadixNav.Indicator, { ref: ref, "data-slot": "navigation-menu-indicator", className: cn("top-full z-[1] flex h-2 items-end justify-center overflow-hidden ui-fade", className), ...props, children: _jsx("span", { className: "relative top-[60%] size-2.5 rotate-45 rounded-tl-sm border-s border-t border-popover-border bg-popover" }) }));
105
106
  });
106
107
  /**
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import * as React from "react";
4
- import { Popover as PopoverPrimitive } from "radix-ui";
4
+ import * as PopoverPrimitive from "radix-ui/popover";
5
5
  import { Bell, Check, CheckCheck, Settings } from "lucide-react";
6
6
  import { cn } from "../lib/cn.js";
7
7
  import { useLabels } from "../lib/labels.js";
@@ -92,7 +92,7 @@ export function createMemoryNotificationAdapter(initial, options = {}) {
92
92
  };
93
93
  }
94
94
  const emptyList = { items: [], status: "idle", loadingMore: false };
95
- const NotificationContext = React.createContext(null);
95
+ const NotificationContext = /*#__PURE__*/ React.createContext(null);
96
96
  const useNC = () => {
97
97
  const ctx = React.useContext(NotificationContext);
98
98
  if (!ctx)
@@ -270,7 +270,7 @@ export function NotificationCenter({ adapter, tabs: tabsProp, toastOnNew, pollIn
270
270
  /* Trigger */
271
271
  /* ------------------------------------------------------------------ */
272
272
  /** The bell with the unread badge (99+). `aria-label` includes the count. */
273
- export const NotificationTrigger = React.forwardRef(function NotificationTrigger({ className, size = "sm", onClick, ...props }, ref) {
273
+ export const NotificationTrigger = /*#__PURE__*/ React.forwardRef(function NotificationTrigger({ className, size = "sm", onClick, ...props }, ref) {
274
274
  const { open, setOpen, unread, important, triggerRef, t } = useNC();
275
275
  const { format } = useLocale();
276
276
  const label = unread > 0 ? t("triggerUnread", { count: unread }) : t("trigger");
@@ -379,7 +379,7 @@ const toneWell = {
379
379
  danger: "tone-danger",
380
380
  };
381
381
  /** One notification. Usable on its own — e.g. a full "/notifications" page. */
382
- export const NotificationItem = React.forwardRef(function NotificationItem({ notification: n, onOpen, onMarkRead, onAction, pendingAction, posinset, setsize, labels, className, ...props }, ref) {
382
+ export const NotificationItem = /*#__PURE__*/ React.forwardRef(function NotificationItem({ notification: n, onOpen, onMarkRead, onAction, pendingAction, posinset, setsize, labels, className, ...props }, ref) {
383
383
  const t = useLabels("notifications", notificationLabels, labels);
384
384
  const { format } = useLocale();
385
385
  const titleId = React.useId();
@@ -9,7 +9,7 @@ import { ActionMenu } from "./dropdown-menu.js";
9
9
  import { AppShellBreadcrumb } from "./app-shell.js";
10
10
  // Server-safe nav helpers (this module has no "use client"), so server layouts can call them.
11
11
  export { filterNav, resolveActive, flattenNav, matchPath, navItems, findNavItem, navTrailItems, normaliseBadge, isNavGroup, isNavItem, isNavSeparator, SIDEBAR_COOKIE, parseSidebarCookie, } from "../lib/nav.js";
12
- export const pageHeaderTitleVariants = cva("font-display min-w-0 text-fg [text-wrap:balance]", {
12
+ export const pageHeaderTitleVariants = /*#__PURE__*/ cva("font-display min-w-0 text-fg [text-wrap:balance]", {
13
13
  variants: {
14
14
  size: {
15
15
  /** Record pages. */
@@ -36,12 +36,12 @@ export const pageHeaderTitleVariants = cva("font-display min-w-0 text-fg [text-w
36
36
  * />
37
37
  * ```
38
38
  */
39
- export const PageHeader = React.forwardRef(function PageHeader({ title, eyebrow, breadcrumb, back, description, meta, actions, menu, tabs, size = "md", sticky, align = "start", loading, className, children, ...props }, ref) {
39
+ export const PageHeader = /*#__PURE__*/ React.forwardRef(function PageHeader({ title, eyebrow, breadcrumb, back, description, meta, actions, menu, tabs, size = "md", sticky, align = "start", loading, className, children, ...props }, ref) {
40
40
  const centered = align === "center";
41
41
  return (_jsxs("header", { ref: ref, "data-slot": "page-header", "data-size": size, className: cn("grid gap-3", tabs ? "mb-6" : size === "lg" ? "mb-8" : "mb-6", sticky && "surface-bar sticky top-(--topbar-h) z-(--z-sticky) -mx-[var(--page-px,1.5rem)] px-[var(--page-px,1.5rem)] pt-3", sticky && !tabs && "pb-3", centered && "justify-items-center text-center", className), ...props, children: [breadcrumb === "auto" ? _jsx(AppShellBreadcrumb, {}) : breadcrumb ? breadcrumb : null, back ? (_jsxs(SmartLink, { href: back.href, className: "-ms-0.5 inline-flex w-fit items-center gap-1.5 rounded-ui-sm text-[13px] text-fg-muted transition-colors hover:text-fg focus-ring", children: [_jsx(ArrowLeft, { "aria-hidden": true, className: "size-3.5 rtl:-scale-x-100" }), back.label] })) : null, _jsxs("div", { className: cn("flex flex-wrap items-end gap-x-6 gap-y-4", centered ? "justify-center" : "justify-between"), children: [_jsxs("div", { className: cn("min-w-0", centered ? "max-w-2xl" : "max-w-3xl flex-[1_1_22rem]"), children: [eyebrow ? _jsx(PageHeaderEyebrow, { className: "mb-1.5", children: eyebrow }) : null, _jsxs("div", { className: cn("flex flex-wrap items-center gap-x-3 gap-y-1.5", centered && "justify-center"), children: [_jsx(PageHeaderTitle, { size: size, "aria-busy": loading || undefined, children: loading ? _jsx(Skeleton, { className: "inline-block h-[0.8em] w-[min(18rem,60vw)] rounded-ui-sm align-middle" }) : title }), meta ? _jsx("div", { className: "flex flex-wrap items-center gap-2 text-[13px] text-fg-subtle", children: meta }) : null] }), description ? _jsx(PageHeaderDescription, { className: cn(size === "lg" ? "mt-2.5" : "mt-1.5", centered && "mx-auto"), children: description }) : null] }), actions || menu?.length ? (_jsxs(PageHeaderActions, { children: [actions, menu?.length ? _jsx(ActionMenu, { items: menu, triggerSize: "md" }) : null] })) : null] }), children, tabs ? _jsx(PageHeaderTabs, { children: tabs }) : null] }));
42
42
  });
43
43
  /** The `<h1>`. */
44
- export const PageHeaderTitle = React.forwardRef(function PageHeaderTitle({ size, className, ...props }, ref) {
44
+ export const PageHeaderTitle = /*#__PURE__*/ React.forwardRef(function PageHeaderTitle({ size, className, ...props }, ref) {
45
45
  return _jsx("h1", { ref: ref, "data-slot": "page-header-title", className: cn(pageHeaderTitleVariants({ size }), className), ...props });
46
46
  });
47
47
  /** The small line above the title. Not uppercased with CSS: `text-transform` breaks Turkish i/İ without the right `lang`. */
@@ -59,21 +59,21 @@ export function usePaginationRange(options) {
59
59
  const { page, pageCount, siblingCount, boundaryCount } = options;
60
60
  return React.useMemo(() => paginationRange({ page, pageCount, siblingCount, boundaryCount }), [page, pageCount, siblingCount, boundaryCount]);
61
61
  }
62
- const SizeContext = React.createContext("md");
62
+ const SizeContext = /*#__PURE__*/ React.createContext("md");
63
63
  const itemSize = {
64
64
  sm: "h-8 min-w-8 px-2 text-[13px] rounded-ui-sm [&_svg]:size-3.5",
65
65
  md: "h-(--control-h) min-w-(--control-h) px-2.5 text-sm rounded-ui [&_svg]:size-4",
66
66
  };
67
67
  /** The `<ul>` of page items. */
68
- export const PaginationList = React.forwardRef(function PaginationList({ className, ...props }, ref) {
68
+ export const PaginationList = /*#__PURE__*/ React.forwardRef(function PaginationList({ className, ...props }, ref) {
69
69
  return _jsx("ul", { ref: ref, "data-slot": "pagination-list", className: cn("flex items-center gap-1", className), ...props });
70
70
  });
71
71
  /** One `<li>`. */
72
- export const PaginationItem = React.forwardRef(function PaginationItem({ className, ...props }, ref) {
72
+ export const PaginationItem = /*#__PURE__*/ React.forwardRef(function PaginationItem({ className, ...props }, ref) {
73
73
  return _jsx("li", { ref: ref, "data-slot": "pagination-item", className: cn("inline-flex", className), ...props });
74
74
  });
75
75
  /** A page number, or the shell for Previous / Next. Router `Link` when `href` is set, else a button. */
76
- export const PaginationLink = React.forwardRef(function PaginationLink({ href, isActive, disabled, loading, className, children, onClick, ...props }, ref) {
76
+ export const PaginationLink = /*#__PURE__*/ React.forwardRef(function PaginationLink({ href, isActive, disabled, loading, className, children, onClick, ...props }, ref) {
77
77
  const Link = useLink();
78
78
  const size = React.useContext(SizeContext);
79
79
  const classes = cn(buttonVariants({ variant: "ghost" }), itemSize[size], "tabular font-normal text-fg-muted hover:text-fg", isActive && "bg-selected font-semibold text-fg hover:bg-selected", className);
@@ -88,12 +88,12 @@ export const PaginationLink = React.forwardRef(function PaginationLink({ href, i
88
88
  return (_jsx("button", { ref: ref, type: "button", "aria-current": isActive ? "page" : undefined, "aria-busy": loading || undefined, disabled: disabled, className: classes, "data-slot": "pagination-link", onClick: onClick, ...props, children: content }));
89
89
  });
90
90
  /** Previous-page control. The arrow flips in RTL. */
91
- export const PaginationPrevious = React.forwardRef(function PaginationPrevious({ showLabel, labels, className, ...props }, ref) {
91
+ export const PaginationPrevious = /*#__PURE__*/ React.forwardRef(function PaginationPrevious({ showLabel, labels, className, ...props }, ref) {
92
92
  const t = useLabels("pagination", paginationLabels, labels);
93
93
  return (_jsxs(PaginationLink, { ref: ref, "aria-label": t("previousPage"), className: cn(showLabel && "gap-1 ps-2 pe-3", className), "data-slot": "pagination-previous", ...props, children: [_jsx(ChevronLeft, { "aria-hidden": true, className: "rtl:-scale-x-100" }), showLabel ? _jsx("span", { children: t("previous") }) : null] }));
94
94
  });
95
95
  /** Next-page control. The arrow flips in RTL. */
96
- export const PaginationNext = React.forwardRef(function PaginationNext({ showLabel, labels, className, ...props }, ref) {
96
+ export const PaginationNext = /*#__PURE__*/ React.forwardRef(function PaginationNext({ showLabel, labels, className, ...props }, ref) {
97
97
  const t = useLabels("pagination", paginationLabels, labels);
98
98
  return (_jsxs(PaginationLink, { ref: ref, "aria-label": t("nextPage"), className: cn(showLabel && "gap-1 ps-3 pe-2", className), "data-slot": "pagination-next", ...props, children: [showLabel ? _jsx("span", { children: t("next") }) : null, _jsx(ChevronRight, { "aria-hidden": true, className: "rtl:-scale-x-100" })] }));
99
99
  });
@@ -113,7 +113,7 @@ export function PaginationEllipsis({ className, labels, ...props }) {
113
113
  *
114
114
  * Moving focus to the top of the list after a page change is the consumer's job.
115
115
  */
116
- export const Pagination = React.forwardRef(function Pagination({ page, pageCount, onPageChange, getHref, siblingCount, boundaryCount, variant = "numbers", size = "md", hideOnSinglePage = true, loading, labels, className, ...props }, ref) {
116
+ export const Pagination = /*#__PURE__*/ React.forwardRef(function Pagination({ page, pageCount, onPageChange, getHref, siblingCount, boundaryCount, variant = "numbers", size = "md", hideOnSinglePage = true, loading, labels, className, ...props }, ref) {
117
117
  const t = useLabels("pagination", paginationLabels, labels);
118
118
  const range = usePaginationRange({ page, pageCount, siblingCount, boundaryCount });
119
119
  if (pageCount < 1 || (hideOnSinglePage && pageCount <= 1))
@@ -137,7 +137,7 @@ export const Pagination = React.forwardRef(function Pagination({ page, pageCount
137
137
  * The table footer: "1–20 of 312" + rows per page + page numbers. Changing the page size keeps the
138
138
  * first visible row on screen (the page is recomputed) — the consumer receives both callbacks.
139
139
  */
140
- export const PaginationBar = React.forwardRef(function PaginationBar({ total, pageSize, pageSizeOptions = [10, 20, 50, 100], onPageSizeChange, page, onPageChange, labels, size = "md", className, style, id, ...props }, ref) {
140
+ export const PaginationBar = /*#__PURE__*/ React.forwardRef(function PaginationBar({ total, pageSize, pageSizeOptions = [10, 20, 50, 100], onPageSizeChange, page, onPageChange, labels, size = "md", className, style, id, ...props }, ref) {
141
141
  const t = useLabels("pagination", paginationLabels, labels);
142
142
  const f = useFormat();
143
143
  const selectId = React.useId();
@@ -156,7 +156,7 @@ export const PaginationBar = React.forwardRef(function PaginationBar({ total, pa
156
156
  }, className: cn(controlVariants({ size: "sm" }), "tabular w-auto appearance-none pe-7 text-fg"), children: options.map((o) => (_jsx("option", { value: o, children: f.number(o) }, o))) }), _jsx(ChevronDown, { "aria-hidden": true, className: "pointer-events-none absolute end-2 top-1/2 size-3.5 -translate-y-1/2 text-fg-subtle" })] })] })) : null, _jsx(Pagination, { page: current, pageCount: pageCount, onPageChange: onPageChange, labels: labels, size: size, hideOnSinglePage: false, ...props })] }));
157
157
  });
158
158
  /** Previous / Next for cursor APIs where the total is unknown. */
159
- export const CursorPagination = React.forwardRef(function CursorPagination({ hasPrev, hasNext, onPrev, onNext, loading, status, size = "md", labels, className, ...props }, ref) {
159
+ export const CursorPagination = /*#__PURE__*/ React.forwardRef(function CursorPagination({ hasPrev, hasNext, onPrev, onNext, loading, status, size = "md", labels, className, ...props }, ref) {
160
160
  const t = useLabels("pagination", paginationLabels, labels);
161
161
  const [pressed, setPressed] = React.useState(null);
162
162
  React.useEffect(() => {
@@ -53,7 +53,7 @@ const accept = (ch) => (ch >= "0" && ch <= "9") || ch === "+";
53
53
  * <Field label="Mobile"><PhoneInput defaultCountry="TR" onValueChange={(e164) => save(e164)} /></Field>
54
54
  * ```
55
55
  */
56
- export const PhoneInput = React.forwardRef(function PhoneInput(props, forwardedRef) {
56
+ export const PhoneInput = /*#__PURE__*/ React.forwardRef(function PhoneInput(props, forwardedRef) {
57
57
  const { country: countryProp, defaultCountry, onCountryChange, countries, preferredCountries, display: displayMode = "national", hideCountry, value, defaultValue, onValueChange, validateOn = "blur", onValidate, mono, labels, name, invalid, inputClassName, onBlur, onKeyDown, disabled, readOnly, size, ...rest } = props;
58
58
  const { locale } = useLocale();
59
59
  const t = useLabels("phoneInput", phoneInputLabels, labels);