@exsto/ds 0.0.1-rc.4 → 0.0.1-rc.6

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 (104) hide show
  1. package/README.md +8 -27
  2. package/dist/ds/src/index.d.ts +2 -3
  3. package/dist/index.js +5107 -2
  4. package/dist/index.js.map +1 -0
  5. package/dist/styles.css +525 -296
  6. package/dist/theme.css +58 -1
  7. package/dist/ui/src/components/edyn/animated-number/animated-number.d.ts +30 -0
  8. package/dist/ui/src/components/edyn/animated-number/animated-number.test.d.ts +9 -0
  9. package/dist/ui/src/components/edyn/animated-number/index.d.ts +1 -0
  10. package/dist/ui/src/components/edyn/date-range-picker/date-range-picker.d.ts +26 -0
  11. package/dist/ui/src/components/edyn/date-range-picker/date-range-picker.test.d.ts +9 -0
  12. package/dist/ui/src/components/edyn/date-range-picker/index.d.ts +1 -0
  13. package/dist/ui/src/components/edyn/initials-avatar/index.d.ts +1 -0
  14. package/dist/ui/src/components/edyn/initials-avatar/initials-avatar.d.ts +53 -0
  15. package/dist/ui/src/components/edyn/initials-avatar/initials-avatar.test.d.ts +10 -0
  16. package/dist/ui/src/components/edyn/multi-select/index.d.ts +1 -0
  17. package/dist/ui/src/components/edyn/multi-select/multi-select.d.ts +96 -0
  18. package/dist/ui/src/components/edyn/multi-select/multi-select.test.d.ts +9 -0
  19. package/dist/ui/src/components/edyn/progress-line/index.d.ts +1 -0
  20. package/dist/ui/src/components/edyn/progress-line/progress-line.d.ts +23 -0
  21. package/dist/ui/src/components/edyn/progress-line/progress-line.test.d.ts +9 -0
  22. package/dist/ui/src/components/ui/attachment/attachment.d.ts +1 -1
  23. package/dist/ui/src/components/ui/button/button.behavior.test.d.ts +8 -0
  24. package/dist/ui/src/components/ui/dropdown-menu/dropdown-menu.d.ts +9 -10
  25. package/dist/ui/src/components/ui/input-group/input-group.d.ts +1 -1
  26. package/dist/ui/src/components/ui/item/item.d.ts +1 -1
  27. package/dist/ui/src/components/ui/progress/progress.behavior.test.d.ts +8 -0
  28. package/dist/ui/src/components/ui/progress/progress.d.ts +43 -1
  29. package/dist/ui/src/components/ui/scroll-area/scroll-area.behavior.test.d.ts +7 -6
  30. package/dist/ui/src/components/ui/scroll-area/scroll-area.d.ts +27 -8
  31. package/dist/ui/src/components/ui/table/table.behavior.test.d.ts +4 -5
  32. package/dist/ui/src/index.d.ts +5 -0
  33. package/dist/ui/src/lib/focus-ring.test.d.ts +8 -0
  34. package/dist/ui/src/lib/popup-list.d.ts +47 -0
  35. package/dist/ui/src/lib/popup-list.test.d.ts +10 -0
  36. package/package.json +4 -9
  37. package/dist/chunks/toggle-group-CTTjTe-K.js +0 -4371
  38. package/dist/chunks/toggle-group-CTTjTe-K.js.map +0 -1
  39. package/dist/dom/src/context.d.ts +0 -34
  40. package/dist/dom/src/define-element.d.ts +0 -11
  41. package/dist/dom/src/define-element.test.d.ts +0 -1
  42. package/dist/dom/src/field-control.d.ts +0 -5
  43. package/dist/dom/src/index.d.ts +0 -6
  44. package/dist/dom/src/mode.d.ts +0 -8
  45. package/dist/dom/src/native-slot.test.d.ts +0 -1
  46. package/dist/dom/src/styles.d.ts +0 -6
  47. package/dist/dom/src/theme-state.d.ts +0 -1
  48. package/dist/dom/src/types.d.ts +0 -65
  49. package/dist/ds/src/elements.d.ts +0 -12
  50. package/dist/elements/src/edx-accordion.d.ts +0 -14
  51. package/dist/elements/src/edx-accordion.test.d.ts +0 -1
  52. package/dist/elements/src/edx-alert.d.ts +0 -14
  53. package/dist/elements/src/edx-audio-player.d.ts +0 -11
  54. package/dist/elements/src/edx-avatar.d.ts +0 -10
  55. package/dist/elements/src/edx-badge.d.ts +0 -12
  56. package/dist/elements/src/edx-breadcrumb.d.ts +0 -11
  57. package/dist/elements/src/edx-button-group.d.ts +0 -7
  58. package/dist/elements/src/edx-button.d.ts +0 -20
  59. package/dist/elements/src/edx-calendar.d.ts +0 -21
  60. package/dist/elements/src/edx-card.d.ts +0 -8
  61. package/dist/elements/src/edx-checkbox.d.ts +0 -18
  62. package/dist/elements/src/edx-combobox.d.ts +0 -28
  63. package/dist/elements/src/edx-content-components.d.ts +0 -2
  64. package/dist/elements/src/edx-dialog.d.ts +0 -20
  65. package/dist/elements/src/edx-drawer.d.ts +0 -21
  66. package/dist/elements/src/edx-dropdown-menu.d.ts +0 -29
  67. package/dist/elements/src/edx-field.d.ts +0 -9
  68. package/dist/elements/src/edx-field.test.d.ts +0 -1
  69. package/dist/elements/src/edx-indicator.d.ts +0 -14
  70. package/dist/elements/src/edx-input-group.d.ts +0 -32
  71. package/dist/elements/src/edx-input-otp.d.ts +0 -19
  72. package/dist/elements/src/edx-input.d.ts +0 -31
  73. package/dist/elements/src/edx-interactive-components.d.ts +0 -2
  74. package/dist/elements/src/edx-label.d.ts +0 -6
  75. package/dist/elements/src/edx-pagination.d.ts +0 -8
  76. package/dist/elements/src/edx-popover.d.ts +0 -24
  77. package/dist/elements/src/edx-progress.d.ts +0 -10
  78. package/dist/elements/src/edx-radio-group.d.ts +0 -22
  79. package/dist/elements/src/edx-radio-group.test.d.ts +0 -1
  80. package/dist/elements/src/edx-scroll-area.d.ts +0 -20
  81. package/dist/elements/src/edx-scroll-area.test.d.ts +0 -1
  82. package/dist/elements/src/edx-select.d.ts +0 -34
  83. package/dist/elements/src/edx-separator.d.ts +0 -10
  84. package/dist/elements/src/edx-skeleton.d.ts +0 -8
  85. package/dist/elements/src/edx-slider.d.ts +0 -17
  86. package/dist/elements/src/edx-slider.test.d.ts +0 -1
  87. package/dist/elements/src/edx-switch.d.ts +0 -18
  88. package/dist/elements/src/edx-table.d.ts +0 -13
  89. package/dist/elements/src/edx-table.test.d.ts +0 -1
  90. package/dist/elements/src/edx-tabs.d.ts +0 -15
  91. package/dist/elements/src/edx-tabs.test.d.ts +0 -1
  92. package/dist/elements/src/edx-textarea.d.ts +0 -25
  93. package/dist/elements/src/edx-toggle-group.d.ts +0 -27
  94. package/dist/elements/src/edx-toggle-group.test.d.ts +0 -1
  95. package/dist/elements/src/edx-toggle.d.ts +0 -18
  96. package/dist/elements/src/edx-tooltip.d.ts +0 -28
  97. package/dist/elements/src/edx-video-player.d.ts +0 -16
  98. package/dist/elements/src/field-control-bridge.d.ts +0 -7
  99. package/dist/elements/src/index.d.ts +0 -14
  100. package/dist/elements/src/projected-content.test.d.ts +0 -1
  101. package/dist/elements/src/registry.d.ts +0 -39
  102. package/dist/elements/src/registry.test.d.ts +0 -1
  103. package/dist/elements.js +0 -4026
  104. package/dist/elements.js.map +0 -1
@@ -1,4371 +0,0 @@
1
- import { Button } from "@base-ui/react/button";
2
- import { clsx } from "clsx";
3
- import { twMerge } from "tailwind-merge";
4
- import { cva } from "class-variance-authority";
5
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
6
- import { Slider } from "@base-ui/react/slider";
7
- import * as React from "react";
8
- import { createContext, useCallback, useContext, useEffect, useRef } from "react";
9
- import { IconAlertOctagon, IconAlertTriangle, IconArrowDown, IconCheck, IconChevronDown, IconChevronLeft, IconChevronRight, IconCircleCheck, IconDots, IconInfoCircle, IconLayoutSidebar, IconLoader, IconMaximize, IconMinus, IconPlayerPauseFilled, IconPlayerPlayFilled, IconSearch, IconSelector, IconVolume, IconVolumeOff, IconX } from "@tabler/icons-react";
10
- import { Accordion } from "@base-ui/react/accordion";
11
- import { AlertDialog } from "@base-ui/react/alert-dialog";
12
- import { mergeProps } from "@base-ui/react/merge-props";
13
- import { useRender } from "@base-ui/react/use-render";
14
- import { Avatar } from "@base-ui/react/avatar";
15
- import { DayPicker, getDefaultClassNames } from "react-day-picker";
16
- import useEmblaCarousel from "embla-carousel-react";
17
- import * as RechartsPrimitive from "recharts";
18
- import { Checkbox } from "@base-ui/react/checkbox";
19
- import { Collapsible } from "@base-ui/react/collapsible";
20
- import { Combobox } from "@base-ui/react/combobox";
21
- import { ScrollArea } from "@base-ui/react/scroll-area";
22
- import { Command } from "cmdk";
23
- import { Dialog } from "@base-ui/react/dialog";
24
- import { Input } from "@base-ui/react/input";
25
- import { ContextMenu } from "@base-ui/react/context-menu";
26
- import { DirectionProvider, useDirection } from "@base-ui/react/direction-provider";
27
- import { Menu } from "@base-ui/react/menu";
28
- import { Field } from "@base-ui/react/field";
29
- import { PreviewCard } from "@base-ui/react/preview-card";
30
- import { OTPInput, OTPInputContext } from "input-otp";
31
- import { Separator } from "@base-ui/react/separator";
32
- import { Menubar } from "@base-ui/react/menubar";
33
- import { MessageScroller, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility } from "@shadcn/react/message-scroller";
34
- import { NavigationMenu } from "@base-ui/react/navigation-menu";
35
- import { Popover } from "@base-ui/react/popover";
36
- import { Progress } from "@base-ui/react/progress";
37
- import { Questionnaire } from "@shadcn/react/questionnaire";
38
- import { Radio } from "@base-ui/react/radio";
39
- import { RadioGroup } from "@base-ui/react/radio-group";
40
- import * as ResizablePrimitive from "react-resizable-panels";
41
- import { Select } from "@base-ui/react/select";
42
- import { Tooltip } from "@base-ui/react/tooltip";
43
- import { Switch } from "@base-ui/react/switch";
44
- import { Tabs } from "@base-ui/react/tabs";
45
- import { Toast } from "@base-ui/react/toast";
46
- import { Toggle } from "@base-ui/react/toggle";
47
- import { ToggleGroup } from "@base-ui/react/toggle-group";
48
- //#region ../ui/src/lib/utils.ts
49
- var cn = (...inputs) => twMerge(clsx(inputs));
50
- /**
51
- * Normalise a size prop to a CSS length.
52
- *
53
- * Bare numbers become px, which is also what a bare numeric *string* means: an
54
- * element attribute arrives as a string, so `width="480"` and `width={480}` have
55
- * to land on the same value. Anything with a unit, a percentage or a keyword
56
- * passes through untouched.
57
- */
58
- var cssLength = (value) => {
59
- if (value == null || value === "") return;
60
- if (typeof value === "number") return Number.isFinite(value) ? `${value}px` : void 0;
61
- return /^-?\d*\.?\d+$/.test(value.trim()) ? `${value.trim()}px` : value;
62
- };
63
- //#endregion
64
- //#region ../ui/src/components/ui/button/button.tsx
65
- var buttonVariants = cva("group/button inline-flex shrink-0 cursor-pointer items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all motion-reduce:transition-none motion-reduce:transform-none outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
66
- variants: {
67
- variant: {
68
- default: "bg-primary text-primary-foreground hover:bg-primary/80",
69
- outline: "border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
70
- secondary: "bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",
71
- ghost: "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",
72
- destructive: "bg-destructive/10 text-destructive hover:bg-destructive/15 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/15 dark:hover:bg-destructive/20 dark:focus-visible:ring-destructive/40",
73
- link: "text-primary underline-offset-4 hover:underline"
74
- },
75
- size: {
76
- default: "h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
77
- xs: "h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
78
- sm: "h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
79
- lg: "h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
80
- icon: "size-8",
81
- "icon-xs": "size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3",
82
- "icon-sm": "size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg",
83
- "icon-lg": "size-9"
84
- }
85
- },
86
- defaultVariants: {
87
- variant: "default",
88
- size: "default"
89
- }
90
- });
91
- var Button$1 = ({ className, variant = "default", size = "default", ...props }) => {
92
- return /* @__PURE__ */ jsx(Button, {
93
- "data-slot": "button",
94
- className: cn(buttonVariants({
95
- variant,
96
- size,
97
- className
98
- }), "in-data-[edx-button-group-position=horizontal-first]:rounded-r-none", "in-data-[edx-button-group-position=horizontal-middle]:rounded-none", "in-data-[edx-button-group-position=horizontal-last]:rounded-l-none", "in-data-[edx-button-group-position=vertical-first]:rounded-b-none", "in-data-[edx-button-group-position=vertical-middle]:rounded-none", "in-data-[edx-button-group-position=vertical-last]:rounded-t-none"),
99
- ...props
100
- });
101
- };
102
- //#endregion
103
- //#region ../ui/src/components/ui/slider/slider.tsx
104
- var Slider$1 = ({ className, value, defaultValue, min, max, step, disabled, onValueChange, onValueCommitted, name, minStepsBetweenValues, "aria-label": ariaLabel, ...props }) => {
105
- const thumbValues = Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [value ?? defaultValue ?? min ?? 0];
106
- const thumbs = Array.from({ length: thumbValues.length }, (_, index) => ({
107
- id: `thumb-${index}`,
108
- index
109
- }));
110
- return /* @__PURE__ */ jsx(Slider.Root, {
111
- "data-slot": "slider",
112
- className: cn("relative flex w-full touch-none items-center", className),
113
- value,
114
- defaultValue,
115
- min,
116
- max,
117
- step,
118
- disabled,
119
- onValueChange,
120
- onValueCommitted,
121
- name,
122
- minStepsBetweenValues,
123
- thumbAlignment: "edge",
124
- "aria-label": ariaLabel,
125
- ...props,
126
- children: /* @__PURE__ */ jsxs(Slider.Control, {
127
- "data-slot": "slider-control",
128
- className: "relative flex w-full cursor-pointer touch-none items-center py-3 data-disabled:cursor-not-allowed data-disabled:opacity-50",
129
- children: [/* @__PURE__ */ jsx(Slider.Track, {
130
- "data-slot": "slider-track",
131
- className: "relative h-1.5 w-full grow overflow-hidden rounded-full bg-muted",
132
- children: /* @__PURE__ */ jsx(Slider.Indicator, {
133
- "data-slot": "slider-indicator",
134
- className: "absolute h-full bg-primary"
135
- })
136
- }), thumbs.map((thumb) => /* @__PURE__ */ jsx(Slider.Thumb, {
137
- index: thumb.index,
138
- getAriaLabel: ariaLabel ? () => thumbValues.length > 1 ? `${ariaLabel} ${thumb.index + 1}` : ariaLabel : void 0,
139
- "data-slot": "slider-thumb",
140
- className: "relative block size-4 shrink-0 rounded-full border border-primary/50 bg-background shadow-sm outline-none transition-colors after:absolute after:-inset-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 data-disabled:pointer-events-none data-disabled:opacity-50"
141
- }, thumb.id))]
142
- })
143
- });
144
- };
145
- //#endregion
146
- //#region ../ui/src/hooks/use-media-player.ts
147
- /** `0:00` for anything that is not a finite, non-negative number, so a loading or errored source still renders. */
148
- var formatMediaTime = (seconds) => {
149
- if (!Number.isFinite(seconds) || seconds < 0) return "0:00";
150
- const whole = Math.floor(seconds);
151
- const hours = Math.floor(whole / 3600);
152
- const minutes = Math.floor(whole % 3600 / 60);
153
- const rest = whole % 60;
154
- const padded = `${String(rest).padStart(2, "0")}`;
155
- if (hours > 0) return `${hours}:${String(minutes).padStart(2, "0")}:${padded}`;
156
- return `${minutes}:${padded}`;
157
- };
158
- /**
159
- * Shared playback engine for the Audio and Video players. Both wrap the same
160
- * HTMLMediaElement API, so the state machine lives here once and each component
161
- * owns only its own layout and controls.
162
- */
163
- var useMediaPlayer = (options = {}) => {
164
- const { onPlay, onPause, onEnded, onTimeUpdate } = options;
165
- const refMedia = React.useRef(null);
166
- const [state, setState] = React.useState({
167
- playing: false,
168
- currentTime: 0,
169
- duration: 0,
170
- volume: 1,
171
- muted: false
172
- });
173
- React.useEffect(() => {
174
- const media = refMedia.current;
175
- if (!media) return;
176
- const syncMeta = () => {
177
- setState((previous) => ({
178
- ...previous,
179
- duration: Number.isFinite(media.duration) ? media.duration : 0,
180
- volume: media.volume,
181
- muted: media.muted
182
- }));
183
- };
184
- const handlePlay = () => {
185
- setState((previous) => ({
186
- ...previous,
187
- playing: true
188
- }));
189
- onPlay?.();
190
- };
191
- const handlePause = () => {
192
- setState((previous) => ({
193
- ...previous,
194
- playing: false
195
- }));
196
- onPause?.();
197
- };
198
- const handleEnded = () => {
199
- setState((previous) => ({
200
- ...previous,
201
- playing: false
202
- }));
203
- onEnded?.();
204
- };
205
- const handleTimeUpdate = () => {
206
- setState((previous) => ({
207
- ...previous,
208
- currentTime: media.currentTime
209
- }));
210
- onTimeUpdate?.(media.currentTime, Number.isFinite(media.duration) ? media.duration : 0);
211
- };
212
- const handleVolumeChange = () => {
213
- setState((previous) => ({
214
- ...previous,
215
- volume: media.volume,
216
- muted: media.muted
217
- }));
218
- };
219
- syncMeta();
220
- media.addEventListener("loadedmetadata", syncMeta);
221
- media.addEventListener("durationchange", syncMeta);
222
- media.addEventListener("play", handlePlay);
223
- media.addEventListener("pause", handlePause);
224
- media.addEventListener("ended", handleEnded);
225
- media.addEventListener("timeupdate", handleTimeUpdate);
226
- media.addEventListener("volumechange", handleVolumeChange);
227
- return () => {
228
- media.removeEventListener("loadedmetadata", syncMeta);
229
- media.removeEventListener("durationchange", syncMeta);
230
- media.removeEventListener("play", handlePlay);
231
- media.removeEventListener("pause", handlePause);
232
- media.removeEventListener("ended", handleEnded);
233
- media.removeEventListener("timeupdate", handleTimeUpdate);
234
- media.removeEventListener("volumechange", handleVolumeChange);
235
- };
236
- }, [
237
- onPlay,
238
- onPause,
239
- onEnded,
240
- onTimeUpdate
241
- ]);
242
- const toggle = React.useCallback(() => {
243
- const media = refMedia.current;
244
- if (!media) return;
245
- if (media.paused) {
246
- media.play().catch(() => void 0);
247
- return;
248
- }
249
- media.pause();
250
- }, []);
251
- const seek = React.useCallback((seconds) => {
252
- const media = refMedia.current;
253
- if (!media || !Number.isFinite(seconds)) return;
254
- media.currentTime = seconds;
255
- setState((previous) => ({
256
- ...previous,
257
- currentTime: seconds
258
- }));
259
- }, []);
260
- const changeVolume = React.useCallback((volume) => {
261
- const media = refMedia.current;
262
- if (!media || !Number.isFinite(volume)) return;
263
- const next = Math.min(1, Math.max(0, volume));
264
- media.volume = next;
265
- media.muted = next === 0;
266
- }, []);
267
- const toggleMute = React.useCallback(() => {
268
- const media = refMedia.current;
269
- if (!media) return;
270
- media.muted = !media.muted;
271
- }, []);
272
- return {
273
- ...state,
274
- refMedia,
275
- toggle,
276
- seek,
277
- changeVolume,
278
- toggleMute
279
- };
280
- };
281
- //#endregion
282
- //#region ../ui/src/components/edyn/audio-player/audio-player.tsx
283
- /**
284
- * Compact inline media control for audio content: play/pause, elapsed and total
285
- * time, a seekable timeline, and volume. Four elements in one rounded row, per
286
- * the design-system anatomy.
287
- */
288
- var AudioPlayer = ({ src, muted = false, loop = false, disabled = false, width, className, "aria-label": ariaLabel = "Audio player", onPlay, onPause, onEnded, onTimeUpdate }) => {
289
- const { refMedia, playing, currentTime, duration, muted: isMuted, toggle, seek, toggleMute } = useMediaPlayer({
290
- onPlay,
291
- onPause,
292
- onEnded,
293
- onTimeUpdate
294
- });
295
- const PlaybackIcon = playing ? IconPlayerPauseFilled : IconPlayerPlayFilled;
296
- const VolumeIcon = isMuted ? IconVolumeOff : IconVolume;
297
- return /* @__PURE__ */ jsxs("div", {
298
- "data-slot": "audio-player",
299
- "data-playing": playing || void 0,
300
- role: "group",
301
- "aria-label": ariaLabel,
302
- style: { width: cssLength(width) },
303
- className: cn("flex h-12 w-full items-center gap-2 rounded-lg bg-muted px-3 py-1.5", className),
304
- children: [
305
- /* @__PURE__ */ jsx(Button$1, {
306
- type: "button",
307
- variant: "ghost",
308
- size: "icon",
309
- disabled,
310
- "aria-label": playing ? "Pause" : "Play",
311
- onClick: toggle,
312
- children: /* @__PURE__ */ jsx(PlaybackIcon, {})
313
- }),
314
- /* @__PURE__ */ jsxs("span", {
315
- "data-slot": "audio-player-time",
316
- className: "shrink-0 text-xs tabular-nums text-foreground/70",
317
- children: [
318
- formatMediaTime(currentTime),
319
- " / ",
320
- formatMediaTime(duration)
321
- ]
322
- }),
323
- /* @__PURE__ */ jsx(Slider$1, {
324
- className: "flex-1 [&_[data-slot=slider-control]]:py-1.5 [&_[data-slot=slider-thumb]]:size-3 [&_[data-slot=slider-track]]:h-1 [&_[data-slot=slider-track]]:bg-foreground/15",
325
- value: Math.min(currentTime, duration || 0),
326
- min: 0,
327
- max: duration || 0,
328
- step: 1,
329
- disabled: disabled || duration === 0,
330
- "aria-label": "Seek",
331
- onValueChange: (next) => {
332
- seek(next);
333
- }
334
- }),
335
- /* @__PURE__ */ jsx(Button$1, {
336
- type: "button",
337
- variant: "ghost",
338
- size: "icon",
339
- disabled,
340
- "aria-label": isMuted ? "Unmute" : "Mute",
341
- onClick: toggleMute,
342
- children: /* @__PURE__ */ jsx(VolumeIcon, {})
343
- }),
344
- /* @__PURE__ */ jsx("audio", {
345
- ref: refMedia,
346
- src,
347
- muted,
348
- loop,
349
- preload: "metadata"
350
- })
351
- ]
352
- });
353
- };
354
- //#endregion
355
- //#region ../ui/src/components/edyn/video-player/video-player.tsx
356
- /**
357
- * Media surface with an overlaid control bar: title and description, elapsed and
358
- * total time, a seekable scrubber, play/pause, volume, and fullscreen.
359
- *
360
- * The root carries the `dark` class so its tokens resolve to the dark palette in
361
- * both themes. Video is dark, so the letterbox and controls must stay dark and
362
- * light-on-dark; this re-scopes existing tokens rather than hardcoding a colour.
363
- */
364
- var VideoPlayer = ({ src, poster, title, description, muted = false, loop = false, disabled = false, width, height, ratio = "auto", className, "aria-label": ariaLabel = "Video player", onPlay, onPause, onEnded, onTimeUpdate }) => {
365
- const { refMedia, playing, currentTime, duration, muted: isMuted, toggle, seek, toggleMute } = useMediaPlayer({
366
- onPlay,
367
- onPause,
368
- onEnded,
369
- onTimeUpdate
370
- });
371
- const refContainer = React.useRef(null);
372
- const PlaybackIcon = playing ? IconPlayerPauseFilled : IconPlayerPlayFilled;
373
- const VolumeIcon = isMuted ? IconVolumeOff : IconVolume;
374
- const isSizedBox = height != null || ratio !== "auto";
375
- const requestFullscreen = () => {
376
- const container = refContainer.current;
377
- if (!container) return;
378
- if (document.fullscreenElement) {
379
- document.exitFullscreen().catch(() => void 0);
380
- return;
381
- }
382
- container.requestFullscreen?.().catch(() => void 0);
383
- };
384
- return /* @__PURE__ */ jsxs("div", {
385
- ref: refContainer,
386
- "data-slot": "video-player",
387
- "data-playing": playing || void 0,
388
- style: {
389
- width: cssLength(width),
390
- height: cssLength(height),
391
- aspectRatio: height == null && ratio !== "auto" ? ratio : void 0
392
- },
393
- className: cn("dark relative isolate w-full overflow-hidden rounded-lg bg-background", className),
394
- children: [/* @__PURE__ */ jsx("video", {
395
- ref: refMedia,
396
- src,
397
- poster,
398
- muted,
399
- loop,
400
- playsInline: true,
401
- preload: "metadata",
402
- "aria-label": ariaLabel,
403
- className: cn("w-full bg-background", isSizedBox ? "h-full object-contain" : "h-auto")
404
- }), /* @__PURE__ */ jsxs("div", {
405
- className: "pointer-events-none absolute inset-x-0 bottom-0 flex flex-col gap-0.5 bg-gradient-to-t from-background via-background/75 to-transparent px-3 pt-12 pb-2 text-foreground",
406
- children: [
407
- /* @__PURE__ */ jsxs("div", {
408
- className: "pointer-events-auto flex items-end justify-between gap-4",
409
- children: [/* @__PURE__ */ jsxs("div", {
410
- className: "min-w-0",
411
- children: [title ? /* @__PURE__ */ jsx("p", {
412
- className: "truncate text-sm font-medium text-foreground",
413
- children: title
414
- }) : null, description ? /* @__PURE__ */ jsx("p", {
415
- className: "truncate text-xs text-foreground/70",
416
- children: description
417
- }) : null]
418
- }), /* @__PURE__ */ jsxs("span", {
419
- className: "shrink-0 text-xs tabular-nums text-foreground/70",
420
- children: [
421
- formatMediaTime(currentTime),
422
- " / ",
423
- formatMediaTime(duration)
424
- ]
425
- })]
426
- }),
427
- /* @__PURE__ */ jsx(Slider$1, {
428
- className: "pointer-events-auto [&_[data-slot=slider-control]]:py-1.5 [&_[data-slot=slider-thumb]]:size-3 [&_[data-slot=slider-track]]:h-1",
429
- value: Math.min(currentTime, duration || 0),
430
- min: 0,
431
- max: duration || 0,
432
- step: 1,
433
- disabled: disabled || duration === 0,
434
- "aria-label": "Seek",
435
- onValueChange: (next) => {
436
- seek(next);
437
- }
438
- }),
439
- /* @__PURE__ */ jsxs("div", {
440
- className: "pointer-events-auto flex items-center justify-between",
441
- children: [/* @__PURE__ */ jsxs("div", {
442
- className: "flex items-center gap-1",
443
- children: [/* @__PURE__ */ jsx(Button$1, {
444
- type: "button",
445
- variant: "ghost",
446
- size: "icon",
447
- disabled,
448
- "aria-label": playing ? "Pause" : "Play",
449
- onClick: toggle,
450
- children: /* @__PURE__ */ jsx(PlaybackIcon, {})
451
- }), /* @__PURE__ */ jsx(Button$1, {
452
- type: "button",
453
- variant: "ghost",
454
- size: "icon",
455
- disabled,
456
- "aria-label": isMuted ? "Unmute" : "Mute",
457
- onClick: toggleMute,
458
- children: /* @__PURE__ */ jsx(VolumeIcon, {})
459
- })]
460
- }), /* @__PURE__ */ jsx(Button$1, {
461
- type: "button",
462
- variant: "ghost",
463
- size: "icon",
464
- disabled,
465
- "aria-label": "Fullscreen",
466
- onClick: requestFullscreen,
467
- children: /* @__PURE__ */ jsx(IconMaximize, {})
468
- })]
469
- })
470
- ]
471
- })]
472
- });
473
- };
474
- //#endregion
475
- //#region ../ui/src/components/ui/accordion/accordion.tsx
476
- var Accordion$1 = ({ value, defaultValue, onValueChange, multiple = false, className, children }) => /* @__PURE__ */ jsx(Accordion.Root, {
477
- "data-slot": "accordion",
478
- value,
479
- defaultValue,
480
- onValueChange: (next) => {
481
- onValueChange?.(next);
482
- },
483
- multiple,
484
- className: cn("w-full", className),
485
- children
486
- });
487
- var AccordionItem = ({ value, disabled, className, children }) => /* @__PURE__ */ jsx(Accordion.Item, {
488
- "data-slot": "accordion-item",
489
- value,
490
- disabled,
491
- className: cn("border-b border-border", className),
492
- children
493
- });
494
- var focusSiblingTrigger = (event) => {
495
- if (![
496
- "ArrowDown",
497
- "ArrowUp",
498
- "Home",
499
- "End"
500
- ].includes(event.key)) return;
501
- const root = event.currentTarget.closest("[data-slot=\"accordion\"]");
502
- const triggers = Array.from(root?.querySelectorAll("[data-slot=\"accordion-trigger\"]:not(:disabled)") ?? []);
503
- const currentIndex = triggers.indexOf(event.currentTarget);
504
- if (currentIndex < 0 || triggers.length === 0) return;
505
- event.preventDefault();
506
- let nextIndex = currentIndex;
507
- if (event.key === "Home") nextIndex = 0;
508
- else if (event.key === "End") nextIndex = triggers.length - 1;
509
- else if (event.key === "ArrowDown") nextIndex = (currentIndex + 1) % triggers.length;
510
- else if (event.key === "ArrowUp") nextIndex = (currentIndex - 1 + triggers.length) % triggers.length;
511
- triggers[nextIndex]?.focus();
512
- };
513
- var AccordionTrigger = ({ className, children }) => /* @__PURE__ */ jsx(Accordion.Header, {
514
- "data-slot": "accordion-header",
515
- className: "flex",
516
- children: /* @__PURE__ */ jsxs(Accordion.Trigger, {
517
- "data-slot": "accordion-trigger",
518
- onKeyDown: focusSiblingTrigger,
519
- className: cn("flex flex-1 items-center justify-between py-4 text-sm font-medium transition-all hover:underline", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2", "[&[data-panel-open]>svg]:rotate-180", className),
520
- children: [children, /* @__PURE__ */ jsx("svg", {
521
- xmlns: "http://www.w3.org/2000/svg",
522
- width: "24",
523
- height: "24",
524
- viewBox: "0 0 24 24",
525
- fill: "none",
526
- stroke: "currentColor",
527
- strokeWidth: "2",
528
- strokeLinecap: "round",
529
- strokeLinejoin: "round",
530
- className: "size-4 shrink-0 text-muted-foreground transition-transform duration-200",
531
- "aria-hidden": "true",
532
- children: /* @__PURE__ */ jsx("path", { d: "m6 9 6 6 6-6" })
533
- })]
534
- })
535
- });
536
- var AccordionContent = ({ className, children }) => /* @__PURE__ */ jsx(Accordion.Panel, {
537
- keepMounted: true,
538
- className: cn("h-[var(--accordion-panel-height)] overflow-hidden text-sm transition-[height] duration-200 ease-out motion-reduce:transition-none", "data-starting-style:h-0 data-ending-style:h-0", className),
539
- children: /* @__PURE__ */ jsx("div", {
540
- className: "pb-4 pt-0",
541
- children
542
- })
543
- });
544
- //#endregion
545
- //#region ../ui/src/components/ui/alert/alert.tsx
546
- var alertVariants = cva("group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4", {
547
- variants: { variant: {
548
- default: "bg-card text-card-foreground",
549
- destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive *:[svg]:text-current",
550
- success: "bg-card text-success *:data-[slot=alert-description]:text-success *:[svg]:text-current",
551
- warning: "bg-card text-warning *:data-[slot=alert-description]:text-warning *:[svg]:text-current",
552
- info: "bg-card text-info *:data-[slot=alert-description]:text-info *:[svg]:text-current"
553
- } },
554
- defaultVariants: { variant: "default" }
555
- });
556
- var Alert = ({ className, variant, ...props }) => {
557
- return /* @__PURE__ */ jsx("div", {
558
- "data-slot": "alert",
559
- role: "alert",
560
- className: cn(alertVariants({ variant }), className),
561
- ...props
562
- });
563
- };
564
- var AlertTitle = ({ className, ...props }) => {
565
- return /* @__PURE__ */ jsx("div", {
566
- "data-slot": "alert-title",
567
- className: cn("font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground", className),
568
- ...props
569
- });
570
- };
571
- var AlertDescription = ({ className, ...props }) => {
572
- return /* @__PURE__ */ jsx("div", {
573
- "data-slot": "alert-description",
574
- className: cn("text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4", className),
575
- ...props
576
- });
577
- };
578
- var AlertAction = ({ className, ...props }) => {
579
- return /* @__PURE__ */ jsx("div", {
580
- "data-slot": "alert-action",
581
- className: cn("absolute top-2.5 right-2", className),
582
- ...props
583
- });
584
- };
585
- //#endregion
586
- //#region ../ui/src/components/ui/alert-dialog/alert-dialog.tsx
587
- var AlertDialog$1 = ({ ...props }) => {
588
- return /* @__PURE__ */ jsx(AlertDialog.Root, {
589
- "data-slot": "alert-dialog",
590
- ...props
591
- });
592
- };
593
- var AlertDialogTrigger = ({ ...props }) => {
594
- return /* @__PURE__ */ jsx(AlertDialog.Trigger, {
595
- "data-slot": "alert-dialog-trigger",
596
- ...props
597
- });
598
- };
599
- var AlertDialogPortal = ({ ...props }) => {
600
- return /* @__PURE__ */ jsx(AlertDialog.Portal, {
601
- "data-slot": "alert-dialog-portal",
602
- ...props
603
- });
604
- };
605
- var AlertDialogOverlay = ({ className, ...props }) => {
606
- return /* @__PURE__ */ jsx(AlertDialog.Backdrop, {
607
- "data-slot": "alert-dialog-overlay",
608
- className: cn("fixed inset-0 isolate z-50 bg-overlay duration-100 motion-reduce:animate-none supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", className),
609
- ...props
610
- });
611
- };
612
- var AlertDialogContent = ({ className, size = "default", ...props }) => {
613
- return /* @__PURE__ */ jsxs(AlertDialogPortal, { children: [/* @__PURE__ */ jsx(AlertDialogOverlay, {}), /* @__PURE__ */ jsx(AlertDialog.Popup, {
614
- "data-slot": "alert-dialog-content",
615
- "data-size": size,
616
- className: cn("group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 motion-reduce:animate-none outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
617
- ...props
618
- })] });
619
- };
620
- var AlertDialogHeader = ({ className, ...props }) => {
621
- return /* @__PURE__ */ jsx("div", {
622
- "data-slot": "alert-dialog-header",
623
- className: cn("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", className),
624
- ...props
625
- });
626
- };
627
- var AlertDialogFooter = ({ className, ...props }) => {
628
- return /* @__PURE__ */ jsx("div", {
629
- "data-slot": "alert-dialog-footer",
630
- className: cn("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", className),
631
- ...props
632
- });
633
- };
634
- var AlertDialogMedia = ({ className, ...props }) => {
635
- return /* @__PURE__ */ jsx("div", {
636
- "data-slot": "alert-dialog-media",
637
- className: cn("mb-2 inline-flex size-10 items-center justify-center rounded-md bg-muted sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6", className),
638
- ...props
639
- });
640
- };
641
- var AlertDialogTitle = ({ className, ...props }) => {
642
- return /* @__PURE__ */ jsx(AlertDialog.Title, {
643
- "data-slot": "alert-dialog-title",
644
- className: cn("font-heading text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", className),
645
- ...props
646
- });
647
- };
648
- var AlertDialogDescription = ({ className, ...props }) => {
649
- return /* @__PURE__ */ jsx(AlertDialog.Description, {
650
- "data-slot": "alert-dialog-description",
651
- className: cn("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", className),
652
- ...props
653
- });
654
- };
655
- var AlertDialogAction = ({ className, ...props }) => {
656
- return /* @__PURE__ */ jsx(Button$1, {
657
- "data-slot": "alert-dialog-action",
658
- className: cn(className),
659
- ...props
660
- });
661
- };
662
- var AlertDialogCancel = ({ className, variant = "outline", size = "default", ...props }) => {
663
- return /* @__PURE__ */ jsx(AlertDialog.Close, {
664
- "data-slot": "alert-dialog-cancel",
665
- className: cn(className),
666
- render: /* @__PURE__ */ jsx(Button$1, {
667
- variant,
668
- size
669
- }),
670
- ...props
671
- });
672
- };
673
- //#endregion
674
- //#region ../ui/src/components/ui/aspect-ratio/aspect-ratio.tsx
675
- var AspectRatio = ({ ratio, className, ...props }) => {
676
- return /* @__PURE__ */ jsx("div", {
677
- "data-slot": "aspect-ratio",
678
- style: { "--ratio": ratio },
679
- className: cn("relative aspect-(--ratio)", className),
680
- ...props
681
- });
682
- };
683
- //#endregion
684
- //#region ../ui/src/components/ui/attachment/attachment.tsx
685
- var attachmentVariants = cva("group/attachment relative flex w-fit max-w-full min-w-0 shrink-0 flex-wrap rounded-xl border bg-card text-card-foreground transition-colors focus-within:ring-1 focus-within:ring-ring/50 has-[>a,>button]:hover:bg-muted/50 data-[state=error]:border-destructive/30 data-[state=idle]:border-dashed", { variants: {
686
- size: {
687
- default: "gap-2 text-sm has-data-[slot=attachment-content]:px-2.5 has-data-[slot=attachment-content]:py-2 has-data-[slot=attachment-media]:p-2",
688
- sm: "gap-2.5 text-xs has-data-[slot=attachment-content]:px-2 has-data-[slot=attachment-content]:py-1.5 has-data-[slot=attachment-media]:p-1.5",
689
- xs: "gap-1.5 rounded-lg text-xs has-data-[slot=attachment-content]:px-1.5 has-data-[slot=attachment-content]:py-1 has-data-[slot=attachment-media]:p-1"
690
- },
691
- orientation: {
692
- horizontal: "min-w-40 items-center",
693
- vertical: "w-24 flex-col has-data-[slot=attachment-content]:w-30"
694
- }
695
- } });
696
- var Attachment = ({ className, state = "done", size = "default", orientation = "horizontal", ...props }) => {
697
- return /* @__PURE__ */ jsx("div", {
698
- "data-slot": "attachment",
699
- "data-state": state,
700
- "data-size": size,
701
- "data-orientation": orientation,
702
- className: cn(attachmentVariants({
703
- size,
704
- orientation
705
- }), className),
706
- ...props
707
- });
708
- };
709
- var attachmentMediaVariants = cva("relative flex aspect-square w-10 shrink-0 items-center justify-center overflow-hidden rounded-lg bg-muted text-foreground group-data-[orientation=vertical]/attachment:w-full group-data-[size=sm]/attachment:w-8 group-data-[size=xs]/attachment:w-7 group-data-[size=xs]/attachment:rounded-md group-data-[state=error]/attachment:bg-destructive/10 group-data-[state=error]/attachment:text-destructive group-data-[orientation=vertical]/attachment:*:data-[slot=spinner]:size-6! [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 group-data-[orientation=vertical]/attachment:[&_svg:not([class*='size-'])]:size-6 group-data-[size=xs]/attachment:[&_svg:not([class*='size-'])]:size-3.5", {
710
- variants: { variant: {
711
- icon: "",
712
- image: "opacity-60 group-data-[state=done]/attachment:opacity-100 group-data-[state=idle]/attachment:opacity-100 *:[img]:aspect-square *:[img]:w-full *:[img]:object-cover"
713
- } },
714
- defaultVariants: { variant: "icon" }
715
- });
716
- var AttachmentMedia = ({ className, variant = "icon", ...props }) => {
717
- return /* @__PURE__ */ jsx("div", {
718
- "data-slot": "attachment-media",
719
- "data-variant": variant,
720
- className: cn(attachmentMediaVariants({ variant }), className),
721
- ...props
722
- });
723
- };
724
- var AttachmentContent = ({ className, ...props }) => {
725
- return /* @__PURE__ */ jsx("div", {
726
- "data-slot": "attachment-content",
727
- className: cn("max-w-full min-w-0 flex-1 leading-tight group-data-[orientation=vertical]/attachment:px-1", className),
728
- ...props
729
- });
730
- };
731
- var AttachmentTitle = ({ className, ...props }) => {
732
- return /* @__PURE__ */ jsx("span", {
733
- "data-slot": "attachment-title",
734
- className: cn("block max-w-full min-w-0 truncate font-medium group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer", className),
735
- ...props
736
- });
737
- };
738
- var AttachmentDescription = ({ className, ...props }) => {
739
- return /* @__PURE__ */ jsx("span", {
740
- "data-slot": "attachment-description",
741
- className: cn("mt-0.5 block min-w-0 truncate text-xs text-muted-foreground group-data-[state=error]/attachment:text-destructive", "max-w-full", className),
742
- ...props
743
- });
744
- };
745
- var AttachmentActions = ({ className, ...props }) => {
746
- return /* @__PURE__ */ jsx("div", {
747
- "data-slot": "attachment-actions",
748
- className: cn("relative z-20 flex shrink-0 items-center group-data-[orientation=vertical]/attachment:absolute group-data-[orientation=vertical]/attachment:top-3 group-data-[orientation=vertical]/attachment:right-3 group-data-[orientation=vertical]/attachment:gap-1", className),
749
- ...props
750
- });
751
- };
752
- var AttachmentAction = ({ className, variant, size = "icon-xs", ...props }) => {
753
- return /* @__PURE__ */ jsx(Button$1, {
754
- "data-slot": "attachment-action",
755
- variant: variant ?? "ghost",
756
- size,
757
- className: cn(className),
758
- ...props
759
- });
760
- };
761
- var AttachmentTrigger = ({ className, render, type, ...props }) => {
762
- return useRender({
763
- defaultTagName: "button",
764
- props: mergeProps({
765
- type: render ? type : type ?? "button",
766
- className: cn("absolute inset-0 z-10 outline-none", className)
767
- }, props),
768
- render,
769
- state: { slot: "attachment-trigger" }
770
- });
771
- };
772
- var AttachmentGroup = ({ className, ...props }) => {
773
- return /* @__PURE__ */ jsx("div", {
774
- "data-slot": "attachment-group",
775
- className: cn("flex min-w-0 scroll-fade-x snap-x snap-mandatory scroll-px-1 scrollbar-none gap-3 overflow-x-auto overscroll-x-contain py-1 *:data-[slot=attachment]:flex-none *:data-[slot=attachment]:snap-start", className),
776
- ...props
777
- });
778
- };
779
- //#endregion
780
- //#region ../ui/src/components/ui/avatar/avatar.tsx
781
- var Avatar$1 = ({ className, size = "default", ...props }) => {
782
- return /* @__PURE__ */ jsx(Avatar.Root, {
783
- "data-slot": "avatar",
784
- "data-size": size,
785
- className: cn("group/avatar relative flex size-8 shrink-0 rounded-full select-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken data-[size=lg]:size-10 data-[size=sm]:size-6 dark:after:mix-blend-lighten", className),
786
- ...props
787
- });
788
- };
789
- var AvatarImage = ({ className, ...props }) => {
790
- return /* @__PURE__ */ jsx(Avatar.Image, {
791
- "data-slot": "avatar-image",
792
- className: cn("aspect-square size-full rounded-full object-cover", className),
793
- ...props
794
- });
795
- };
796
- var AvatarFallback = ({ className, ...props }) => {
797
- return /* @__PURE__ */ jsx(Avatar.Fallback, {
798
- "data-slot": "avatar-fallback",
799
- className: cn("flex size-full items-center justify-center rounded-full bg-muted text-sm text-foreground/70 group-data-[size=sm]/avatar:text-xs", className),
800
- ...props
801
- });
802
- };
803
- var AvatarBadge = ({ className, ...props }) => {
804
- return /* @__PURE__ */ jsx("span", {
805
- "data-slot": "avatar-badge",
806
- className: cn("absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground bg-blend-color ring-2 ring-background select-none", "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden", "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2", "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2", className),
807
- ...props
808
- });
809
- };
810
- var AvatarGroup = ({ className, ...props }) => {
811
- return /* @__PURE__ */ jsx("div", {
812
- "data-slot": "avatar-group",
813
- className: cn("group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background", className),
814
- ...props
815
- });
816
- };
817
- var AvatarGroupCount = ({ className, ...props }) => {
818
- return /* @__PURE__ */ jsx("div", {
819
- "data-slot": "avatar-group-count",
820
- className: cn("relative flex size-8 shrink-0 items-center justify-center rounded-full bg-muted text-sm text-foreground/70 ring-2 ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3", className),
821
- ...props
822
- });
823
- };
824
- //#endregion
825
- //#region ../ui/src/components/ui/badge/badge.tsx
826
- var badgeVariants = cva("group/badge inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden border border-transparent text-xs font-medium whitespace-nowrap transition-all motion-reduce:transition-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!", {
827
- variants: {
828
- variant: {
829
- default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
830
- secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
831
- destructive: "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",
832
- success: "bg-success-ring/40 text-success focus-visible:ring-success/20 [a]:hover:bg-success-ring/60 dark:bg-success-ring/30",
833
- warning: "bg-warning-ring/40 text-warning focus-visible:ring-warning/20 [a]:hover:bg-warning-ring/60 dark:bg-warning-ring/30",
834
- info: "bg-info-ring/40 text-info focus-visible:ring-info/20 [a]:hover:bg-info-ring/60 dark:bg-info-ring/30",
835
- outline: "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",
836
- ghost: "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",
837
- link: "text-primary underline-offset-4 hover:underline"
838
- },
839
- size: {
840
- default: "h-5 rounded-4xl px-2 py-0.5",
841
- lg: "h-7 rounded-md px-2 py-1"
842
- }
843
- },
844
- defaultVariants: {
845
- variant: "default",
846
- size: "default"
847
- }
848
- });
849
- var Badge = ({ className, variant = "default", size = "default", render, ...props }) => {
850
- return useRender({
851
- defaultTagName: "span",
852
- props: mergeProps({ className: cn(badgeVariants({
853
- variant,
854
- size
855
- }), className) }, props),
856
- render,
857
- state: {
858
- slot: "badge",
859
- variant,
860
- size
861
- }
862
- });
863
- };
864
- //#endregion
865
- //#region ../ui/src/components/ui/breadcrumb/breadcrumb.tsx
866
- var Breadcrumb = ({ className, ...props }) => {
867
- return /* @__PURE__ */ jsx("nav", {
868
- "aria-label": "breadcrumb",
869
- "data-slot": "breadcrumb",
870
- className: cn(className),
871
- ...props
872
- });
873
- };
874
- var BreadcrumbList = ({ className, ...props }) => {
875
- return /* @__PURE__ */ jsx("ol", {
876
- "data-slot": "breadcrumb-list",
877
- className: cn("flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground", className),
878
- ...props
879
- });
880
- };
881
- var BreadcrumbItem = ({ className, ...props }) => {
882
- return /* @__PURE__ */ jsx("li", {
883
- "data-slot": "breadcrumb-item",
884
- className: cn("inline-flex items-center gap-1", className),
885
- ...props
886
- });
887
- };
888
- var BreadcrumbLink = ({ className, render, ...props }) => {
889
- return useRender({
890
- defaultTagName: "a",
891
- props: mergeProps({ className: cn("transition-colors hover:text-foreground", className) }, props),
892
- render,
893
- state: { slot: "breadcrumb-link" }
894
- });
895
- };
896
- var BreadcrumbPage = ({ className, ...props }) => {
897
- return /* @__PURE__ */ jsx("span", {
898
- "data-slot": "breadcrumb-page",
899
- role: "link",
900
- "aria-disabled": "true",
901
- "aria-current": "page",
902
- className: cn("font-normal text-foreground", className),
903
- ...props
904
- });
905
- };
906
- var BreadcrumbSeparator = ({ children, className, ...props }) => {
907
- return /* @__PURE__ */ jsx("li", {
908
- "data-slot": "breadcrumb-separator",
909
- role: "presentation",
910
- "aria-hidden": "true",
911
- className: cn("[&>svg]:size-3.5", className),
912
- ...props,
913
- children: children ?? /* @__PURE__ */ jsx(IconChevronRight, {})
914
- });
915
- };
916
- var BreadcrumbEllipsis = ({ className, ...props }) => {
917
- return /* @__PURE__ */ jsxs("span", {
918
- "data-slot": "breadcrumb-ellipsis",
919
- role: "presentation",
920
- "aria-hidden": "true",
921
- className: cn("flex size-5 items-center justify-center [&>svg]:size-4", className),
922
- ...props,
923
- children: [/* @__PURE__ */ jsx(IconDots, {}), /* @__PURE__ */ jsx("span", {
924
- className: "sr-only",
925
- children: "More"
926
- })]
927
- });
928
- };
929
- //#endregion
930
- //#region ../ui/src/components/ui/bubble/bubble.tsx
931
- var BubbleGroup = ({ className, ...props }) => {
932
- return /* @__PURE__ */ jsx("div", {
933
- "data-slot": "bubble-group",
934
- className: cn("flex min-w-0 flex-col gap-2", className),
935
- ...props
936
- });
937
- };
938
- var bubbleVariants = cva("group/bubble relative flex w-fit max-w-[80%] min-w-0 flex-col gap-1 group-data-[align=end]/message:self-end data-[align=end]:self-end data-[variant=ghost]:max-w-full", {
939
- variants: { variant: {
940
- default: "*:data-[slot=bubble-content]:bg-primary *:data-[slot=bubble-content]:text-primary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-primary/80",
941
- secondary: "*:data-[slot=bubble-content]:bg-secondary *:data-[slot=bubble-content]:text-secondary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)]",
942
- muted: "*:data-[slot=bubble-content]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--muted),var(--foreground)_5%)]",
943
- tinted: "*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.93_calc(c*0.4)_h)] *:data-[slot=bubble-content]:text-foreground dark:*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.3_calc(c*0.4)_h)] [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.88_calc(c*0.5)_h)] dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.35_calc(c*0.5)_h)]",
944
- outline: "*:data-[slot=bubble-content]:border-border *:data-[slot=bubble-content]:bg-background [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-input/30",
945
- ghost: "border-none *:data-[slot=bubble-content]:rounded-none *:data-[slot=bubble-content]:bg-transparent *:data-[slot=bubble-content]:p-0 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted/50",
946
- destructive: "*:data-[slot=bubble-content]:bg-destructive/10 *:data-[slot=bubble-content]:text-destructive dark:*:data-[slot=bubble-content]:bg-destructive/20 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/20 dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/30"
947
- } },
948
- defaultVariants: { variant: "default" }
949
- });
950
- var Bubble = ({ variant = "default", align = "start", className, ...props }) => {
951
- return /* @__PURE__ */ jsx("div", {
952
- "data-slot": "bubble",
953
- "data-variant": variant,
954
- "data-align": align,
955
- className: cn(bubbleVariants({ variant }), className),
956
- ...props
957
- });
958
- };
959
- var BubbleContent = ({ className, render, ...props }) => {
960
- return useRender({
961
- defaultTagName: "div",
962
- props: mergeProps({ className: cn("w-fit max-w-full min-w-0 overflow-hidden rounded-xl border border-transparent px-3 py-2 text-sm leading-relaxed wrap-break-word group-data-[align=end]/bubble:self-end [button]:text-left [button,a]:transition-colors [button,a]:outline-none [button,a]:focus-visible:border-ring [button,a]:focus-visible:ring-3 [button,a]:focus-visible:ring-ring/50", className) }, props),
963
- render,
964
- state: { slot: "bubble-content" }
965
- });
966
- };
967
- var bubbleReactionsVariants = cva("absolute z-10 flex w-fit shrink-0 items-center justify-center gap-1 rounded-full bg-muted px-1.5 py-0.5 text-sm ring-3 ring-card has-[button]:p-0", {
968
- variants: {
969
- side: {
970
- top: "top-0 -translate-y-3/4",
971
- bottom: "bottom-0 translate-y-3/4"
972
- },
973
- align: {
974
- start: "left-3",
975
- end: "right-3"
976
- }
977
- },
978
- defaultVariants: {
979
- side: "bottom",
980
- align: "end"
981
- }
982
- });
983
- var BubbleReactions = ({ side = "bottom", align = "end", className, ...props }) => {
984
- return /* @__PURE__ */ jsx("div", {
985
- "data-slot": "bubble-reactions",
986
- "data-align": align,
987
- "data-side": side,
988
- className: cn(bubbleReactionsVariants({
989
- side,
990
- align
991
- }), className),
992
- ...props
993
- });
994
- };
995
- //#endregion
996
- //#region ../ui/src/components/ui/button-group/button-group.tsx
997
- var ButtonGroupContext = React.createContext("horizontal");
998
- var ButtonGroup = ({ className, orientation = "horizontal", ...props }) => {
999
- return /* @__PURE__ */ jsx(ButtonGroupContext.Provider, {
1000
- value: orientation,
1001
- children: /* @__PURE__ */ jsx("div", {
1002
- "data-slot": "button-group",
1003
- "data-orientation": orientation,
1004
- className: cn("inline-flex items-center", "[&>*:not(:first-child):not(:last-child)]:rounded-none", "data-[orientation=horizontal]:[&>*:first-child]:rounded-r-none", "data-[orientation=horizontal]:[&>*:last-child]:rounded-l-none", "data-[orientation=horizontal]:[&>*:not(:first-child)]:-ml-px", "data-[orientation=vertical]:flex-col", "data-[orientation=vertical]:[&>*:first-child]:rounded-b-none", "data-[orientation=vertical]:[&>*:last-child]:rounded-t-none", "data-[orientation=vertical]:[&>*:not(:first-child)]:-mt-px", "[&>*]:relative [&>*]:z-0 [&>*:focus-visible]:z-10 [&>*:hover]:z-10", className),
1005
- ...props
1006
- })
1007
- });
1008
- };
1009
- var ButtonGroupSeparator = ({ className, ...props }) => {
1010
- const orientation = React.useContext(ButtonGroupContext);
1011
- return /* @__PURE__ */ jsx("span", {
1012
- "data-slot": "button-group-separator",
1013
- role: "separator",
1014
- "aria-orientation": orientation === "horizontal" ? "vertical" : "horizontal",
1015
- className: cn("inline-flex shrink-0 self-stretch bg-border", "in-data-[orientation=horizontal]:w-px", "in-data-[orientation=vertical]:h-px in-data-[orientation=vertical]:self-auto in-data-[orientation=vertical]:w-full", className),
1016
- ...props
1017
- });
1018
- };
1019
- var ButtonGroupText = ({ className, ...props }) => {
1020
- return /* @__PURE__ */ jsx("span", {
1021
- "data-slot": "button-group-text",
1022
- className: cn("inline-flex shrink-0 items-center justify-center rounded-none border border-border bg-muted px-2.5 text-sm text-muted-foreground select-none", className),
1023
- ...props
1024
- });
1025
- };
1026
- //#endregion
1027
- //#region ../ui/src/components/ui/calendar/calendar.tsx
1028
- var Calendar = ({ className, classNames, showOutsideDays = true, captionLayout = "label", buttonVariant = "ghost", locale, formatters, components, ...props }) => {
1029
- const defaultClassNames = getDefaultClassNames();
1030
- return /* @__PURE__ */ jsx(DayPicker, {
1031
- showOutsideDays,
1032
- className: cn("group/calendar bg-background p-2 [--cell-radius:var(--radius-md)] [--cell-size:--spacing(7)] in-data-[slot=card-content]:bg-transparent in-data-[slot=popover-content]:bg-transparent", String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`, String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`, className),
1033
- captionLayout,
1034
- locale,
1035
- formatters: {
1036
- formatMonthDropdown: (date) => date.toLocaleString(locale?.code, { month: "short" }),
1037
- ...formatters
1038
- },
1039
- classNames: {
1040
- root: cn("w-fit", defaultClassNames.root),
1041
- months: cn("relative flex flex-col gap-4 md:flex-row", defaultClassNames.months),
1042
- month: cn("flex w-full flex-col gap-4", defaultClassNames.month),
1043
- nav: cn("absolute inset-x-0 top-0 flex w-full items-center justify-between gap-1", defaultClassNames.nav),
1044
- button_previous: cn(buttonVariants({ variant: buttonVariant }), "size-(--cell-size) p-0 select-none aria-disabled:opacity-50", defaultClassNames.button_previous),
1045
- button_next: cn(buttonVariants({ variant: buttonVariant }), "size-(--cell-size) p-0 select-none aria-disabled:opacity-50", defaultClassNames.button_next),
1046
- month_caption: cn("flex h-(--cell-size) w-full items-center justify-center px-(--cell-size)", defaultClassNames.month_caption),
1047
- dropdowns: cn("flex h-(--cell-size) w-full items-center justify-center gap-1.5 text-sm font-medium", defaultClassNames.dropdowns),
1048
- dropdown_root: cn("relative rounded-(--cell-radius)", defaultClassNames.dropdown_root),
1049
- dropdown: cn("absolute inset-0 bg-popover opacity-0", defaultClassNames.dropdown),
1050
- caption_label: cn("font-medium select-none", captionLayout === "label" ? "text-sm" : "flex items-center gap-1 rounded-(--cell-radius) text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground", defaultClassNames.caption_label),
1051
- month_grid: cn("w-full border-collapse", defaultClassNames.month_grid),
1052
- weekdays: cn("flex", defaultClassNames.weekdays),
1053
- weekday: cn("flex-1 rounded-(--cell-radius) text-[0.8rem] font-normal text-muted-foreground select-none", defaultClassNames.weekday),
1054
- week: cn("mt-2 flex w-full", defaultClassNames.week),
1055
- week_number_header: cn("w-(--cell-size) select-none", defaultClassNames.week_number_header),
1056
- week_number: cn("text-[0.8rem] text-muted-foreground select-none", defaultClassNames.week_number),
1057
- day: cn("group/day relative aspect-square h-full w-full rounded-(--cell-radius) p-0 text-center select-none [&:last-child[data-selected=true]_button]:rounded-r-(--cell-radius)", props.showWeekNumber ? "[&:nth-child(2)[data-selected=true]_button]:rounded-l-(--cell-radius)" : "[&:first-child[data-selected=true]_button]:rounded-l-(--cell-radius)", defaultClassNames.day),
1058
- range_start: cn("relative isolate z-0 rounded-l-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:right-0 after:w-4 after:bg-muted", defaultClassNames.range_start),
1059
- range_middle: cn("rounded-none", defaultClassNames.range_middle),
1060
- range_end: cn("relative isolate z-0 rounded-r-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:left-0 after:w-4 after:bg-muted", defaultClassNames.range_end),
1061
- today: cn("rounded-(--cell-radius) bg-muted text-foreground data-[selected=true]:rounded-none", defaultClassNames.today),
1062
- outside: cn("text-muted-foreground aria-selected:text-muted-foreground", defaultClassNames.outside),
1063
- disabled: cn("text-muted-foreground opacity-50", defaultClassNames.disabled),
1064
- hidden: cn("invisible", defaultClassNames.hidden),
1065
- ...classNames
1066
- },
1067
- components: {
1068
- Root: ({ className, rootRef, ...props }) => {
1069
- return /* @__PURE__ */ jsx("div", {
1070
- "data-slot": "calendar",
1071
- ref: rootRef,
1072
- className: cn(className),
1073
- ...props
1074
- });
1075
- },
1076
- Chevron: ({ className, orientation, ...props }) => {
1077
- if (orientation === "left") return /* @__PURE__ */ jsx(IconChevronLeft, {
1078
- className: cn("size-4", className),
1079
- ...props
1080
- });
1081
- if (orientation === "right") return /* @__PURE__ */ jsx(IconChevronRight, {
1082
- className: cn("size-4", className),
1083
- ...props
1084
- });
1085
- return /* @__PURE__ */ jsx(IconChevronDown, {
1086
- className: cn("size-4", className),
1087
- ...props
1088
- });
1089
- },
1090
- DayButton: ({ ...props }) => /* @__PURE__ */ jsx(CalendarDayButton, {
1091
- locale,
1092
- ...props
1093
- }),
1094
- WeekNumber: ({ children, ...props }) => {
1095
- return /* @__PURE__ */ jsx("td", {
1096
- ...props,
1097
- children: /* @__PURE__ */ jsx("div", {
1098
- className: "flex size-(--cell-size) items-center justify-center text-center",
1099
- children
1100
- })
1101
- });
1102
- },
1103
- ...components
1104
- },
1105
- ...props
1106
- });
1107
- };
1108
- var CalendarDayButton = ({ className, day, modifiers, locale, ...props }) => {
1109
- const defaultClassNames = getDefaultClassNames();
1110
- const refButton = React.useRef(null);
1111
- React.useEffect(() => {
1112
- if (modifiers.focused) refButton.current?.focus();
1113
- }, [modifiers.focused]);
1114
- return /* @__PURE__ */ jsx(Button$1, {
1115
- ref: refButton,
1116
- variant: "ghost",
1117
- size: "icon",
1118
- "data-day": day.date.toLocaleDateString(locale?.code),
1119
- "data-selected-single": modifiers.selected && !modifiers.range_start && !modifiers.range_end && !modifiers.range_middle,
1120
- "data-range-start": modifiers.range_start,
1121
- "data-range-end": modifiers.range_end,
1122
- "data-range-middle": modifiers.range_middle,
1123
- className: cn("relative isolate z-10 flex aspect-square size-auto w-full min-w-(--cell-size) flex-col gap-1 border-0 leading-none font-normal group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:border-ring group-data-[focused=true]/day:ring-[3px] group-data-[focused=true]/day:ring-ring/50 data-[range-end=true]:rounded-(--cell-radius) data-[range-end=true]:rounded-r-(--cell-radius) data-[range-end=true]:bg-primary data-[range-end=true]:text-primary-foreground data-[range-middle=true]:rounded-none data-[range-middle=true]:bg-muted data-[range-middle=true]:text-foreground data-[range-start=true]:rounded-(--cell-radius) data-[range-start=true]:rounded-l-(--cell-radius) data-[range-start=true]:bg-primary data-[range-start=true]:text-primary-foreground data-[selected-single=true]:bg-primary data-[selected-single=true]:text-primary-foreground dark:hover:text-foreground [&>span]:text-xs [&>span]:opacity-70", defaultClassNames.day, className),
1124
- ...props
1125
- });
1126
- };
1127
- //#endregion
1128
- //#region ../ui/src/components/ui/card/card.tsx
1129
- var Card = ({ className, size = "default", ...props }) => {
1130
- return /* @__PURE__ */ jsx("div", {
1131
- "data-slot": "card",
1132
- "data-size": size,
1133
- className: cn("group/card flex flex-col gap-4 overflow-hidden rounded-xl bg-card py-4 text-sm text-card-foreground ring-1 ring-foreground/10 has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:gap-3 data-[size=sm]:py-3 data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl", className),
1134
- ...props
1135
- });
1136
- };
1137
- var CardHeader = ({ className, ...props }) => {
1138
- return /* @__PURE__ */ jsx("div", {
1139
- "data-slot": "card-header",
1140
- className: cn("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4 group-data-[size=sm]/card:px-3 has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3", className),
1141
- ...props
1142
- });
1143
- };
1144
- var CardTitle = ({ className, ...props }) => {
1145
- return /* @__PURE__ */ jsx("div", {
1146
- "data-slot": "card-title",
1147
- className: cn("text-base leading-snug font-medium group-data-[size=sm]/card:text-sm", className),
1148
- ...props
1149
- });
1150
- };
1151
- var CardDescription = ({ className, ...props }) => {
1152
- return /* @__PURE__ */ jsx("div", {
1153
- "data-slot": "card-description",
1154
- className: cn("text-sm text-muted-foreground", className),
1155
- ...props
1156
- });
1157
- };
1158
- var CardAction = ({ className, ...props }) => {
1159
- return /* @__PURE__ */ jsx("div", {
1160
- "data-slot": "card-action",
1161
- className: cn("col-start-2 row-span-2 row-start-1 self-start justify-self-end", className),
1162
- ...props
1163
- });
1164
- };
1165
- var CardContent = ({ className, ...props }) => {
1166
- return /* @__PURE__ */ jsx("div", {
1167
- "data-slot": "card-content",
1168
- className: cn("px-4 group-data-[size=sm]/card:px-3", className),
1169
- ...props
1170
- });
1171
- };
1172
- var CardFooter = ({ className, ...props }) => {
1173
- return /* @__PURE__ */ jsx("div", {
1174
- "data-slot": "card-footer",
1175
- className: cn("flex items-center rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/card:p-3", className),
1176
- ...props
1177
- });
1178
- };
1179
- //#endregion
1180
- //#region ../ui/src/components/ui/carousel/carousel.tsx
1181
- var CarouselContext = React.createContext(null);
1182
- var useCarousel = () => {
1183
- const context = React.useContext(CarouselContext);
1184
- if (!context) throw new Error("useCarousel must be used within a <Carousel />");
1185
- return context;
1186
- };
1187
- var Carousel = ({ orientation = "horizontal", opts, setApi, plugins, className, children, ...props }) => {
1188
- const [carouselRef, api] = useEmblaCarousel({
1189
- ...opts,
1190
- axis: orientation === "horizontal" ? "x" : "y"
1191
- }, plugins);
1192
- const [canScrollPrev, setCanScrollPrev] = React.useState(false);
1193
- const [canScrollNext, setCanScrollNext] = React.useState(false);
1194
- const onSelect = React.useCallback((api) => {
1195
- if (!api) return;
1196
- setCanScrollPrev(api.canScrollPrev());
1197
- setCanScrollNext(api.canScrollNext());
1198
- }, []);
1199
- const scrollPrev = React.useCallback(() => {
1200
- api?.scrollPrev();
1201
- }, [api]);
1202
- const scrollNext = React.useCallback(() => {
1203
- api?.scrollNext();
1204
- }, [api]);
1205
- const handleKeyDown = React.useCallback((event) => {
1206
- if (event.key === "ArrowLeft") {
1207
- event.preventDefault();
1208
- scrollPrev();
1209
- } else if (event.key === "ArrowRight") {
1210
- event.preventDefault();
1211
- scrollNext();
1212
- }
1213
- }, [scrollPrev, scrollNext]);
1214
- React.useEffect(() => {
1215
- if (!api || !setApi) return;
1216
- setApi(api);
1217
- }, [api, setApi]);
1218
- React.useEffect(() => {
1219
- if (!api) return;
1220
- onSelect(api);
1221
- api.on("reInit", onSelect);
1222
- api.on("select", onSelect);
1223
- return () => {
1224
- api.off("reInit", onSelect);
1225
- api.off("select", onSelect);
1226
- };
1227
- }, [api, onSelect]);
1228
- return /* @__PURE__ */ jsx(CarouselContext.Provider, {
1229
- value: {
1230
- carouselRef,
1231
- api,
1232
- opts,
1233
- orientation: orientation || (opts?.axis === "y" ? "vertical" : "horizontal"),
1234
- scrollPrev,
1235
- scrollNext,
1236
- canScrollPrev,
1237
- canScrollNext
1238
- },
1239
- children: /* @__PURE__ */ jsx("div", {
1240
- onKeyDownCapture: handleKeyDown,
1241
- className: cn("relative", className),
1242
- role: "region",
1243
- "aria-roledescription": "carousel",
1244
- "data-slot": "carousel",
1245
- ...props,
1246
- children
1247
- })
1248
- });
1249
- };
1250
- var CarouselContent = ({ className, ...props }) => {
1251
- const { carouselRef, orientation } = useCarousel();
1252
- return /* @__PURE__ */ jsx("div", {
1253
- ref: carouselRef,
1254
- className: "overflow-hidden",
1255
- "data-slot": "carousel-content",
1256
- children: /* @__PURE__ */ jsx("div", {
1257
- className: cn("flex", orientation === "horizontal" ? "-ml-4" : "-mt-4 flex-col", className),
1258
- ...props
1259
- })
1260
- });
1261
- };
1262
- var CarouselItem = ({ className, ...props }) => {
1263
- const { orientation } = useCarousel();
1264
- return /* @__PURE__ */ jsx("div", {
1265
- role: "group",
1266
- "aria-roledescription": "slide",
1267
- "data-slot": "carousel-item",
1268
- className: cn("min-w-0 shrink-0 grow-0 basis-full", orientation === "horizontal" ? "pl-4" : "pt-4", className),
1269
- ...props
1270
- });
1271
- };
1272
- var CarouselPrevious = ({ className, variant = "outline", size = "icon-sm", ...props }) => {
1273
- const { orientation, scrollPrev, canScrollPrev } = useCarousel();
1274
- return /* @__PURE__ */ jsxs(Button$1, {
1275
- "data-slot": "carousel-previous",
1276
- variant,
1277
- size,
1278
- className: cn("absolute touch-manipulation rounded-full", orientation === "horizontal" ? "inset-y-0 -left-12 my-auto" : "-top-12 left-1/2 -translate-x-1/2 rotate-90", className),
1279
- disabled: !canScrollPrev,
1280
- onClick: scrollPrev,
1281
- ...props,
1282
- children: [/* @__PURE__ */ jsx(IconChevronLeft, {}), /* @__PURE__ */ jsx("span", {
1283
- className: "sr-only",
1284
- children: "Previous slide"
1285
- })]
1286
- });
1287
- };
1288
- var CarouselNext = ({ className, variant = "outline", size = "icon-sm", ...props }) => {
1289
- const { orientation, scrollNext, canScrollNext } = useCarousel();
1290
- return /* @__PURE__ */ jsxs(Button$1, {
1291
- "data-slot": "carousel-next",
1292
- variant,
1293
- size,
1294
- className: cn("absolute touch-manipulation rounded-full", orientation === "horizontal" ? "inset-y-0 -right-12 my-auto" : "-bottom-12 left-1/2 -translate-x-1/2 rotate-90", className),
1295
- disabled: !canScrollNext,
1296
- onClick: scrollNext,
1297
- ...props,
1298
- children: [/* @__PURE__ */ jsx(IconChevronRight, {}), /* @__PURE__ */ jsx("span", {
1299
- className: "sr-only",
1300
- children: "Next slide"
1301
- })]
1302
- });
1303
- };
1304
- //#endregion
1305
- //#region ../ui/src/components/ui/chart/chart.tsx
1306
- var THEMES = {
1307
- light: "",
1308
- dark: ".dark"
1309
- };
1310
- var INITIAL_DIMENSION = {
1311
- width: 320,
1312
- height: 200
1313
- };
1314
- var ChartContext = React.createContext(null);
1315
- var useChart = () => {
1316
- const context = React.useContext(ChartContext);
1317
- if (!context) throw new Error("useChart must be used within a <ChartContainer />");
1318
- return context;
1319
- };
1320
- var ChartContainer = ({ id, className, children, config, initialDimension = INITIAL_DIMENSION, ...props }) => {
1321
- const uniqueId = React.useId();
1322
- const chartId = `chart-${id ?? uniqueId.replace(/:/g, "")}`;
1323
- const refContainer = React.useRef(null);
1324
- const [hasSize, setHasSize] = React.useState(false);
1325
- React.useLayoutEffect(() => {
1326
- const element = refContainer.current;
1327
- if (!element) return;
1328
- const update = () => {
1329
- const { width, height } = element.getBoundingClientRect();
1330
- setHasSize(width > 0 && height > 0);
1331
- };
1332
- update();
1333
- const observer = new ResizeObserver(update);
1334
- observer.observe(element);
1335
- return () => observer.disconnect();
1336
- }, []);
1337
- return /* @__PURE__ */ jsx(ChartContext.Provider, {
1338
- value: { config },
1339
- children: /* @__PURE__ */ jsxs("div", {
1340
- ref: refContainer,
1341
- "data-slot": "chart",
1342
- "data-chart": chartId,
1343
- className: cn("flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden", className),
1344
- ...props,
1345
- children: [/* @__PURE__ */ jsx(ChartStyle, {
1346
- id: chartId,
1347
- config
1348
- }), hasSize && /* @__PURE__ */ jsx(RechartsPrimitive.ResponsiveContainer, {
1349
- initialDimension,
1350
- children
1351
- })]
1352
- })
1353
- });
1354
- };
1355
- var ChartStyle = ({ id, config }) => {
1356
- const colorConfig = Object.entries(config).filter(([, config]) => config.theme ?? config.color);
1357
- if (!colorConfig.length) return null;
1358
- const css = Object.entries(THEMES).map(([theme, prefix]) => `
1359
- ${prefix} [data-chart=${id}] {
1360
- ${colorConfig.map(([key, itemConfig]) => {
1361
- const color = itemConfig.theme?.[theme] ?? itemConfig.color;
1362
- return color ? ` --color-${key}: ${color};` : null;
1363
- }).join("\n")}
1364
- }
1365
- `).join("\n");
1366
- return /* @__PURE__ */ jsx("style", { children: css });
1367
- };
1368
- var ChartTooltip = RechartsPrimitive.Tooltip;
1369
- var ChartTooltipContent = ({ active, payload, className, indicator = "dot", hideLabel = false, hideIndicator = false, label, labelFormatter, labelClassName, formatter, color, nameKey, labelKey }) => {
1370
- const { config } = useChart();
1371
- const tooltipLabel = React.useMemo(() => {
1372
- if (hideLabel || !payload?.length) return null;
1373
- const [item] = payload;
1374
- const key = `${labelKey ?? item?.dataKey ?? item?.name ?? "value"}`;
1375
- const itemConfig = getPayloadConfigFromPayload(config, item, key);
1376
- const value = !labelKey && typeof label === "string" ? config[label]?.label ?? label : itemConfig?.label;
1377
- if (labelFormatter) return /* @__PURE__ */ jsx("div", {
1378
- className: cn("font-medium", labelClassName),
1379
- children: labelFormatter(value, payload)
1380
- });
1381
- if (!value) return null;
1382
- return /* @__PURE__ */ jsx("div", {
1383
- className: cn("font-medium", labelClassName),
1384
- children: value
1385
- });
1386
- }, [
1387
- label,
1388
- labelFormatter,
1389
- payload,
1390
- hideLabel,
1391
- labelClassName,
1392
- config,
1393
- labelKey
1394
- ]);
1395
- if (!active || !payload?.length) return null;
1396
- const nestLabel = payload.length === 1 && indicator !== "dot";
1397
- return /* @__PURE__ */ jsxs("div", {
1398
- className: cn("grid min-w-32 items-start gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl", className),
1399
- children: [!nestLabel ? tooltipLabel : null, /* @__PURE__ */ jsx("div", {
1400
- className: "grid gap-1.5",
1401
- children: payload.filter((item) => item.type !== "none").map((item, index) => {
1402
- const key = `${nameKey ?? item.name ?? item.dataKey ?? "value"}`;
1403
- const itemConfig = getPayloadConfigFromPayload(config, item, key);
1404
- const indicatorColor = color ?? item.payload?.fill ?? item.color;
1405
- return /* @__PURE__ */ jsx("div", {
1406
- className: cn("flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground", indicator === "dot" && "items-center"),
1407
- children: formatter && item?.value !== void 0 && item.name ? formatter(item.value, item.name, item, index, item.payload) : /* @__PURE__ */ jsxs(Fragment, { children: [itemConfig?.icon ? /* @__PURE__ */ jsx(itemConfig.icon, {}) : !hideIndicator && /* @__PURE__ */ jsx("div", {
1408
- className: cn("shrink-0 rounded-[2px] border-(--color-border) bg-(--color-bg)", {
1409
- "h-2.5 w-2.5": indicator === "dot",
1410
- "w-1": indicator === "line",
1411
- "w-0 border-[1.5px] border-dashed bg-transparent": indicator === "dashed",
1412
- "my-0.5": nestLabel && indicator === "dashed"
1413
- }),
1414
- style: {
1415
- "--color-bg": indicatorColor,
1416
- "--color-border": indicatorColor
1417
- }
1418
- }), /* @__PURE__ */ jsxs("div", {
1419
- className: cn("flex flex-1 justify-between leading-none", nestLabel ? "items-end" : "items-center"),
1420
- children: [/* @__PURE__ */ jsxs("div", {
1421
- className: "grid gap-1.5",
1422
- children: [nestLabel ? tooltipLabel : null, /* @__PURE__ */ jsx("span", {
1423
- className: "text-muted-foreground",
1424
- children: itemConfig?.label ?? item.name
1425
- })]
1426
- }), item.value != null && /* @__PURE__ */ jsx("span", {
1427
- className: "font-mono font-medium text-foreground tabular-nums",
1428
- children: typeof item.value === "number" ? item.value.toLocaleString() : String(item.value)
1429
- })]
1430
- })] })
1431
- }, `${key}-${String(item.value ?? "")}`);
1432
- })
1433
- })]
1434
- });
1435
- };
1436
- var ChartLegend = RechartsPrimitive.Legend;
1437
- var ChartLegendContent = ({ className, hideIcon = false, payload, verticalAlign = "bottom", nameKey }) => {
1438
- const { config } = useChart();
1439
- if (!payload?.length) return null;
1440
- return /* @__PURE__ */ jsx("div", {
1441
- className: cn("flex items-center justify-center gap-4", verticalAlign === "top" ? "pb-3" : "pt-3", className),
1442
- children: payload.filter((item) => item.type !== "none").map((item) => {
1443
- const key = `${nameKey ?? item.dataKey ?? "value"}`;
1444
- const itemConfig = getPayloadConfigFromPayload(config, item, key);
1445
- return /* @__PURE__ */ jsxs("div", {
1446
- className: cn("flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground"),
1447
- children: [itemConfig?.icon && !hideIcon ? /* @__PURE__ */ jsx(itemConfig.icon, {}) : /* @__PURE__ */ jsx("div", {
1448
- className: "h-2 w-2 shrink-0 rounded-[2px]",
1449
- style: { backgroundColor: item.color }
1450
- }), itemConfig?.label]
1451
- }, `${key}-${String(item.value ?? "")}`);
1452
- })
1453
- });
1454
- };
1455
- var getPayloadConfigFromPayload = (config, payload, key) => {
1456
- if (typeof payload !== "object" || payload === null) return;
1457
- const payloadPayload = "payload" in payload && typeof payload.payload === "object" && payload.payload !== null ? payload.payload : void 0;
1458
- let configLabelKey = key;
1459
- if (key in payload && typeof payload[key] === "string") configLabelKey = payload[key];
1460
- else if (payloadPayload && key in payloadPayload && typeof payloadPayload[key] === "string") configLabelKey = payloadPayload[key];
1461
- return configLabelKey in config ? config[configLabelKey] : config[key];
1462
- };
1463
- //#endregion
1464
- //#region ../ui/src/components/ui/checkbox/checkbox.tsx
1465
- var Checkbox$1 = ({ className, ...props }) => {
1466
- return /* @__PURE__ */ jsx(Checkbox.Root, {
1467
- "data-slot": "checkbox",
1468
- className: cn("peer relative flex size-4 shrink-0 items-center justify-center rounded-sm border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary", className),
1469
- ...props,
1470
- children: /* @__PURE__ */ jsxs(Checkbox.Indicator, {
1471
- "data-slot": "checkbox-indicator",
1472
- className: "group/checkbox-indicator grid place-content-center text-current transition-none [&>svg]:size-3.5",
1473
- children: [/* @__PURE__ */ jsx(IconCheck, { className: "group-data-indeterminate/checkbox-indicator:hidden" }), /* @__PURE__ */ jsx(IconMinus, { className: "hidden group-data-indeterminate/checkbox-indicator:block" })]
1474
- })
1475
- });
1476
- };
1477
- //#endregion
1478
- //#region ../ui/src/components/ui/collapsible/collapsible.tsx
1479
- var Collapsible$1 = ({ ...props }) => {
1480
- return /* @__PURE__ */ jsx(Collapsible.Root, {
1481
- "data-slot": "collapsible",
1482
- ...props
1483
- });
1484
- };
1485
- var CollapsibleTrigger = ({ ...props }) => {
1486
- return /* @__PURE__ */ jsx(Collapsible.Trigger, {
1487
- "data-slot": "collapsible-trigger",
1488
- ...props
1489
- });
1490
- };
1491
- var CollapsibleContent = ({ ...props }) => {
1492
- return /* @__PURE__ */ jsx(Collapsible.Panel, {
1493
- "data-slot": "collapsible-content",
1494
- ...props
1495
- });
1496
- };
1497
- //#endregion
1498
- //#region ../ui/src/hooks/use-merged-refs.ts
1499
- var assignRef = (ref, value) => {
1500
- if (typeof ref === "function") ref(value);
1501
- else if (ref !== null) ref.current = value;
1502
- };
1503
- var mergeRefs = (...refs) => {
1504
- return (node) => {
1505
- for (const ref of refs) if (ref) assignRef(ref, node);
1506
- };
1507
- };
1508
- var useMergedRefs = (...refs) => {
1509
- return useCallback(mergeRefs(...refs), [...refs]);
1510
- };
1511
- //#endregion
1512
- //#region ../ui/src/components/ui/scroll-area/scroll-area.tsx
1513
- var ScrollBar = ({ className, orientation = "vertical", visibility = "hover", ...props }) => {
1514
- return /* @__PURE__ */ jsx(ScrollArea.Scrollbar, {
1515
- "data-slot": "scroll-area-scrollbar",
1516
- orientation,
1517
- className: cn("peer/scrollbar z-100 flex touch-none select-none motion-safe:transition-opacity motion-safe:duration-150", orientation === "vertical" && "h-full w-2 border-l border-l-transparent p-px", orientation === "horizontal" && "h-2 flex-col border-t border-t-transparent p-px", visibility !== "always" && "opacity-0 data-scrolling:opacity-100", visibility === "hover" && "data-hovering:opacity-100 group-hover/scroll-area:opacity-100", className),
1518
- ...props,
1519
- children: /* @__PURE__ */ jsx(ScrollArea.Thumb, { className: "relative flex-1 rounded-full bg-muted-foreground/50 transition-colors hover:bg-muted-foreground/70 data-scrolling:bg-muted-foreground/70" })
1520
- });
1521
- };
1522
- var FADE_FROM = {
1523
- card: "from-card",
1524
- background: "from-background",
1525
- sidebar: "from-sidebar",
1526
- popover: "from-popover"
1527
- };
1528
- /**
1529
- * Each fade follows one of the overflow flags Base UI keeps on the root, so the
1530
- * reveal is pure CSS: no scroll listener, no measurement, nothing to re-render.
1531
- * The flags are logical (x-start / x-end rather than left / right), which is
1532
- * also what makes the horizontal pair correct under RTL.
1533
- *
1534
- * Below the scrollbar's z-100, so the bar never dissolves into the edge it sits on.
1535
- */
1536
- var FADE_BASE = "pointer-events-none absolute z-10 opacity-0 to-transparent transition-opacity duration-200 motion-reduce:transition-none";
1537
- var FADE_EDGES = {
1538
- "y-start": "inset-x-0 top-0 h-8 bg-linear-to-b group-data-overflow-y-start/scroll-area:opacity-100",
1539
- "y-end": "inset-x-0 bottom-0 h-8 bg-linear-to-t group-data-overflow-y-end/scroll-area:opacity-100",
1540
- "x-start": "inset-y-0 start-0 w-12 ltr:bg-linear-to-r rtl:bg-linear-to-l group-data-overflow-x-start/scroll-area:opacity-100",
1541
- "x-end": "inset-y-0 end-0 w-12 ltr:bg-linear-to-l rtl:bg-linear-to-r group-data-overflow-x-end/scroll-area:opacity-100"
1542
- };
1543
- /**
1544
- * Themed scroll container (Base UI): overflowing content scrolls INSIDE the component
1545
- * with a slim overlay scrollbar instead of exposing a native browser scrollbar. House
1546
- * rule: wide/tall content (tables, lists, code) always goes through this, never a bare
1547
- * overflow-* utility.
1548
- *
1549
- * Cap the height with a plain class on the component itself, e.g.
1550
- * `<ScrollArea className="max-h-88">`. The viewport picks the cap up through
1551
- * `max-h-inherit`, which matters because the viewport is the element that actually
1552
- * scrolls: a cap that lands only on the root leaves tall content spilling out
1553
- * underneath with no scrollbar, and that reads as a working height right up until the
1554
- * content outgrows it.
1555
- *
1556
- * `fade` draws an edge fade on each side that is currently hiding content, rather than
1557
- * always painting one: a permanent fade is a lie half the time, dimming the last row
1558
- * that fits and promising more below when the reader is already at the end. The static
1559
- * faded-* utilities in @edyn/theme/utilities.css are the other tool, for DECORATIVE
1560
- * edges that do not track scroll position.
1561
- *
1562
- * The viewport publishes its size as --scroll-area-width/--scroll-area-height CSS vars
1563
- * so children can size against the visible area.
1564
- */
1565
- var ScrollArea$1 = ({ className, children, orientation = "vertical", type = "hover", fade = false, fadeFrom = "card", scrollbarClassName, viewportId, viewportRef, viewportClassName, scrollRestorationId, viewPortId, viewPortRef, viewPortClassName, scrollVerticalClassName, scrollHorizontalClassName, ...props }) => {
1566
- const refInner = useRef(null);
1567
- const refsViewport = useMergedRefs(refInner, viewportRef ?? viewPortRef);
1568
- useEffect(() => {
1569
- const el = refInner.current;
1570
- if (!el) return;
1571
- const observer = new ResizeObserver(() => {
1572
- el.style.setProperty("--scroll-area-width", `${el.clientWidth}px`);
1573
- el.style.setProperty("--scroll-area-height", `${el.clientHeight}px`);
1574
- });
1575
- observer.observe(el);
1576
- return () => {
1577
- observer.disconnect();
1578
- };
1579
- }, []);
1580
- const fadeEdges = fade ? [...orientation === "horizontal" ? [] : ["y-start", "y-end"], ...orientation === "vertical" ? [] : ["x-start", "x-end"]] : [];
1581
- return /* @__PURE__ */ jsxs(ScrollArea.Root, {
1582
- "data-slot": "scroll-area",
1583
- className: cn("group/scroll-area relative grid min-w-0 grid-rows-1 overflow-hidden", className),
1584
- ...props,
1585
- children: [
1586
- (orientation === "vertical" || orientation === "both") && /* @__PURE__ */ jsx(ScrollBar, {
1587
- orientation: "vertical",
1588
- visibility: type,
1589
- className: cn(scrollbarClassName, scrollVerticalClassName)
1590
- }),
1591
- (orientation === "horizontal" || orientation === "both") && /* @__PURE__ */ jsx(ScrollBar, {
1592
- orientation: "horizontal",
1593
- visibility: type,
1594
- className: cn(scrollbarClassName, scrollHorizontalClassName)
1595
- }),
1596
- /* @__PURE__ */ jsx(ScrollArea.Corner, {}),
1597
- /* @__PURE__ */ jsx(ScrollArea.Viewport, {
1598
- "data-slot": "scroll-area-viewport",
1599
- id: viewportId ?? viewPortId,
1600
- ref: refsViewport,
1601
- "data-scroll-restoration-id": scrollRestorationId,
1602
- className: cn("max-h-inherit w-full rounded-[inherit]", orientation === "vertical" && "overflow-x-hidden!", orientation === "horizontal" && "overflow-y-hidden!", viewportClassName ?? viewPortClassName),
1603
- children: /* @__PURE__ */ jsx(ScrollArea.Content, {
1604
- style: orientation === "vertical" ? { minWidth: 0 } : void 0,
1605
- children
1606
- })
1607
- }),
1608
- fadeEdges.map((edge) => /* @__PURE__ */ jsx("div", {
1609
- "aria-hidden": true,
1610
- "data-slot": "scroll-area-fade",
1611
- "data-edge": edge,
1612
- className: cn(FADE_BASE, FADE_EDGES[edge], FADE_FROM[fadeFrom])
1613
- }, edge))
1614
- ]
1615
- });
1616
- };
1617
- //#endregion
1618
- //#region ../ui/src/components/ui/combobox/combobox.tsx
1619
- var Combobox$1 = ({ ...props }) => {
1620
- return /* @__PURE__ */ jsx(Combobox.Root, {
1621
- "data-slot": "combobox",
1622
- ...props
1623
- });
1624
- };
1625
- var ComboboxInput = ({ className, ...props }) => {
1626
- return /* @__PURE__ */ jsxs(Combobox.InputGroup, {
1627
- "data-slot": "combobox-input-group",
1628
- className: "relative flex w-full items-center",
1629
- children: [/* @__PURE__ */ jsx(Combobox.Input, {
1630
- "data-slot": "combobox-input",
1631
- className: cn("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 pr-8 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", className),
1632
- ...props
1633
- }), /* @__PURE__ */ jsx(Combobox.Trigger, {
1634
- "data-slot": "combobox-trigger",
1635
- className: "absolute right-2 flex items-center text-muted-foreground disabled:pointer-events-none disabled:opacity-50",
1636
- tabIndex: -1,
1637
- "aria-hidden": true,
1638
- children: /* @__PURE__ */ jsx(IconChevronDown, { className: "size-4" })
1639
- })]
1640
- });
1641
- };
1642
- var ComboboxContent = ({ className, children, empty, portalContainer, ...props }) => {
1643
- return /* @__PURE__ */ jsx(Combobox.Portal, {
1644
- "data-slot": "combobox-portal",
1645
- container: portalContainer,
1646
- children: /* @__PURE__ */ jsx(Combobox.Positioner, {
1647
- "data-slot": "combobox-positioner",
1648
- sideOffset: 4,
1649
- className: "z-50",
1650
- children: /* @__PURE__ */ jsxs(Combobox.Popup, {
1651
- "data-slot": "combobox-content",
1652
- className: cn("min-w-[var(--anchor-width)] overflow-hidden rounded-lg border border-border bg-popover text-popover-foreground shadow-md outline-none motion-reduce:animate-none data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
1653
- ...props,
1654
- children: [/* @__PURE__ */ jsx(ComboboxEmpty, { children: empty }), /* @__PURE__ */ jsx(ScrollArea$1, {
1655
- type: "always",
1656
- fade: true,
1657
- fadeFrom: "popover",
1658
- className: "max-h-60",
1659
- children: /* @__PURE__ */ jsx(Combobox.List, {
1660
- "data-slot": "combobox-list",
1661
- className: "p-1",
1662
- children
1663
- })
1664
- })]
1665
- })
1666
- })
1667
- });
1668
- };
1669
- var ComboboxItem = ({ className, children, ...props }) => {
1670
- return /* @__PURE__ */ jsxs(Combobox.Item, {
1671
- "data-slot": "combobox-item",
1672
- className: cn("relative flex cursor-default select-none items-center gap-2 rounded-md px-2 py-1.5 text-sm outline-none data-highlighted:bg-accent data-highlighted:text-accent-foreground data-[selected]:font-medium data-disabled:pointer-events-none data-disabled:opacity-50", className),
1673
- ...props,
1674
- children: [/* @__PURE__ */ jsx(Combobox.ItemIndicator, {
1675
- "data-slot": "combobox-item-indicator",
1676
- className: "flex size-4 items-center justify-center",
1677
- children: /* @__PURE__ */ jsx(IconCheck, { className: "size-3.5" })
1678
- }), /* @__PURE__ */ jsx("span", {
1679
- className: "flex-1",
1680
- children
1681
- })]
1682
- });
1683
- };
1684
- var ComboboxEmpty = ({ className, children, ...props }) => {
1685
- return /* @__PURE__ */ jsx(Combobox.Empty, {
1686
- "data-slot": "combobox-empty",
1687
- className: cn("py-4 text-center text-sm text-muted-foreground empty:py-0", className),
1688
- ...props,
1689
- children: children ?? "No results found."
1690
- });
1691
- };
1692
- //#endregion
1693
- //#region ../ui/src/components/ui/dialog/dialog.tsx
1694
- var Dialog$1 = ({ ...props }) => {
1695
- return /* @__PURE__ */ jsx(Dialog.Root, {
1696
- "data-slot": "dialog",
1697
- ...props
1698
- });
1699
- };
1700
- var DialogTrigger = ({ ...props }) => {
1701
- return /* @__PURE__ */ jsx(Dialog.Trigger, {
1702
- "data-slot": "dialog-trigger",
1703
- ...props
1704
- });
1705
- };
1706
- var DialogPortal = ({ ...props }) => {
1707
- return /* @__PURE__ */ jsx(Dialog.Portal, {
1708
- "data-slot": "dialog-portal",
1709
- ...props
1710
- });
1711
- };
1712
- var DialogClose = ({ ...props }) => {
1713
- return /* @__PURE__ */ jsx(Dialog.Close, {
1714
- "data-slot": "dialog-close",
1715
- ...props
1716
- });
1717
- };
1718
- var DialogOverlay = ({ className, ...props }) => {
1719
- return /* @__PURE__ */ jsx(Dialog.Backdrop, {
1720
- "data-slot": "dialog-overlay",
1721
- className: cn("fixed inset-0 isolate z-50 bg-overlay duration-100 motion-reduce:animate-none supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", className),
1722
- ...props
1723
- });
1724
- };
1725
- var DialogContent = ({ className, children, showCloseButton = true, ...props }) => {
1726
- return /* @__PURE__ */ jsxs(DialogPortal, { children: [/* @__PURE__ */ jsx(DialogOverlay, {}), /* @__PURE__ */ jsxs(Dialog.Popup, {
1727
- "data-slot": "dialog-content",
1728
- className: cn("fixed top-1/2 left-1/2 z-50 grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 motion-reduce:animate-none outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
1729
- ...props,
1730
- children: [children, showCloseButton && /* @__PURE__ */ jsxs(Dialog.Close, {
1731
- "data-slot": "dialog-close",
1732
- render: /* @__PURE__ */ jsx(Button$1, {
1733
- variant: "ghost",
1734
- className: "absolute top-2 right-2",
1735
- size: "icon-sm"
1736
- }),
1737
- children: [/* @__PURE__ */ jsx(IconX, {}), /* @__PURE__ */ jsx("span", {
1738
- className: "sr-only",
1739
- children: "Close"
1740
- })]
1741
- })]
1742
- })] });
1743
- };
1744
- var DialogHeader = ({ className, ...props }) => {
1745
- return /* @__PURE__ */ jsx("div", {
1746
- "data-slot": "dialog-header",
1747
- className: cn("flex flex-col gap-2", className),
1748
- ...props
1749
- });
1750
- };
1751
- var DialogFooter = ({ className, showCloseButton = false, children, ...props }) => {
1752
- return /* @__PURE__ */ jsxs("div", {
1753
- "data-slot": "dialog-footer",
1754
- className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className),
1755
- ...props,
1756
- children: [children, showCloseButton && /* @__PURE__ */ jsx(Dialog.Close, {
1757
- render: /* @__PURE__ */ jsx(Button$1, { variant: "outline" }),
1758
- children: "Close"
1759
- })]
1760
- });
1761
- };
1762
- var DialogTitle = ({ className, ...props }) => {
1763
- return /* @__PURE__ */ jsx(Dialog.Title, {
1764
- "data-slot": "dialog-title",
1765
- className: cn("text-base leading-none font-medium", className),
1766
- ...props
1767
- });
1768
- };
1769
- var DialogDescription = ({ className, ...props }) => {
1770
- return /* @__PURE__ */ jsx(Dialog.Description, {
1771
- "data-slot": "dialog-description",
1772
- className: cn("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", className),
1773
- ...props
1774
- });
1775
- };
1776
- //#endregion
1777
- //#region ../ui/src/components/ui/input/input.tsx
1778
- var Input$1 = ({ className, type, ...props }) => {
1779
- return /* @__PURE__ */ jsx(Input, {
1780
- type,
1781
- "data-slot": "input",
1782
- className: cn("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", className),
1783
- ...props
1784
- });
1785
- };
1786
- //#endregion
1787
- //#region ../ui/src/components/ui/textarea/textarea.tsx
1788
- var Textarea = ({ className, ...props }) => {
1789
- return /* @__PURE__ */ jsx("textarea", {
1790
- "data-slot": "textarea",
1791
- className: cn("block min-h-16 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1.5 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 field-sizing-content resize-y md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", className),
1792
- ...props
1793
- });
1794
- };
1795
- //#endregion
1796
- //#region ../ui/src/components/ui/input-group/input-group.tsx
1797
- var InputGroup = ({ className, ...props }) => {
1798
- return /* @__PURE__ */ jsx("div", {
1799
- "data-slot": "input-group",
1800
- className: cn("group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input transition-colors outline-none", "has-disabled:bg-input/50 has-disabled:opacity-50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50", "has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-destructive/20 dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40", "has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto", "has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5", className),
1801
- ...props
1802
- });
1803
- };
1804
- var inputGroupAddonVariants = cva("flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium text-foreground/70 select-none [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4", {
1805
- variants: { align: {
1806
- "inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
1807
- "inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
1808
- "block-start": "order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2",
1809
- "block-end": "order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2"
1810
- } },
1811
- defaultVariants: { align: "inline-start" }
1812
- });
1813
- var InputGroupAddon = ({ className, align = "inline-start", ...props }) => {
1814
- return /* @__PURE__ */ jsx("div", {
1815
- "data-slot": "input-group-addon",
1816
- "data-align": align,
1817
- className: cn(inputGroupAddonVariants({ align }), className),
1818
- onPointerDown: (event) => {
1819
- if (event.target.closest("button")) return;
1820
- event.currentTarget.parentElement?.querySelector("input")?.focus();
1821
- },
1822
- ...props
1823
- });
1824
- };
1825
- var inputGroupButtonVariants = cva("flex items-center gap-2 text-sm shadow-none", {
1826
- variants: { size: {
1827
- xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
1828
- sm: "",
1829
- "icon-xs": "size-6 rounded-[calc(var(--radius)-3px)] p-0 has-[>svg]:p-0",
1830
- "icon-sm": "size-8 p-0 has-[>svg]:p-0"
1831
- } },
1832
- defaultVariants: { size: "xs" }
1833
- });
1834
- var InputGroupButton = ({ className, type = "button", variant = "ghost", size = "xs", ...props }) => {
1835
- return /* @__PURE__ */ jsx(Button$1, {
1836
- type,
1837
- "data-size": size,
1838
- variant,
1839
- className: cn(inputGroupButtonVariants({ size }), className),
1840
- ...props
1841
- });
1842
- };
1843
- var InputGroupText = ({ className, ...props }) => {
1844
- return /* @__PURE__ */ jsx("span", {
1845
- className: cn("flex items-center gap-2 text-sm text-foreground/70 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4", className),
1846
- ...props
1847
- });
1848
- };
1849
- var InputGroupInput = ({ className, ...props }) => {
1850
- return /* @__PURE__ */ jsx(Input$1, {
1851
- "data-slot": "input-group-control",
1852
- className: cn("flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent", className),
1853
- ...props
1854
- });
1855
- };
1856
- var InputGroupTextarea = ({ className, ...props }) => {
1857
- return /* @__PURE__ */ jsx(Textarea, {
1858
- "data-slot": "input-group-control",
1859
- className: cn("flex-1 resize-none rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent", className),
1860
- ...props
1861
- });
1862
- };
1863
- //#endregion
1864
- //#region ../ui/src/components/ui/command/command.tsx
1865
- var Command$1 = ({ className, ...props }) => {
1866
- return /* @__PURE__ */ jsx(Command, {
1867
- "data-slot": "command",
1868
- className: cn("flex size-full flex-col overflow-hidden rounded-xl! bg-popover p-1 text-popover-foreground", className),
1869
- ...props
1870
- });
1871
- };
1872
- var CommandDialog = ({ title = "Command Palette", description = "Search for a command to run...", children, className, showCloseButton = false, ...props }) => {
1873
- return /* @__PURE__ */ jsxs(Dialog$1, {
1874
- ...props,
1875
- children: [/* @__PURE__ */ jsxs(DialogHeader, {
1876
- className: "sr-only",
1877
- children: [/* @__PURE__ */ jsx(DialogTitle, { children: title }), /* @__PURE__ */ jsx(DialogDescription, { children: description })]
1878
- }), /* @__PURE__ */ jsx(DialogContent, {
1879
- className: cn("top-1/3 translate-y-0 overflow-hidden rounded-xl! p-0", className),
1880
- showCloseButton,
1881
- children
1882
- })]
1883
- });
1884
- };
1885
- var CommandInput = ({ className, ...props }) => {
1886
- return /* @__PURE__ */ jsx("div", {
1887
- "data-slot": "command-input-wrapper",
1888
- className: "p-1 pb-0",
1889
- children: /* @__PURE__ */ jsxs(InputGroup, {
1890
- className: "h-8! rounded-lg! border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!",
1891
- children: [/* @__PURE__ */ jsx(Command.Input, {
1892
- "data-slot": "command-input",
1893
- className: cn("w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50", className),
1894
- ...props
1895
- }), /* @__PURE__ */ jsx(InputGroupAddon, { children: /* @__PURE__ */ jsx(IconSearch, { className: "size-4 shrink-0 opacity-50" }) })]
1896
- })
1897
- });
1898
- };
1899
- /**
1900
- * The palette's results list. The scroll container is the DS ScrollArea rather
1901
- * than the primitive's own `overflow-y-auto`, because a list of results that
1902
- * continues past the fold with no bar and no fade reads as a complete list. The
1903
- * cap stays overridable: `cn` lets a caller's own `max-h-*` replace the default.
1904
- *
1905
- * The ScrollArea wraps the list from OUTSIDE rather than lining it: cmdk's list
1906
- * carries `role="listbox"`, and a listbox may not contain presentation wrappers
1907
- * (axe flags that as a critical aria-required-children violation). The options
1908
- * have to stay direct children of the element that holds the role.
1909
- *
1910
- * cmdk keeps the active item in view with `scrollIntoView({ block: 'nearest' })`
1911
- * on the item, which acts on the nearest scrollable ancestor, so that keeps
1912
- * working now that the viewport is the one that scrolls. `scroll-py-1` goes on
1913
- * the viewport for the same reason: it is what pads that scroll.
1914
- */
1915
- var CommandList = ({ className, children, ...props }) => {
1916
- return /* @__PURE__ */ jsx(ScrollArea$1, {
1917
- type: "always",
1918
- fade: true,
1919
- fadeFrom: "popover",
1920
- className: cn("max-h-72", className),
1921
- viewPortClassName: "scroll-py-1",
1922
- children: /* @__PURE__ */ jsx(Command.List, {
1923
- "data-slot": "command-list",
1924
- className: "outline-none",
1925
- ...props,
1926
- children
1927
- })
1928
- });
1929
- };
1930
- var CommandEmpty = ({ className, ...props }) => {
1931
- return /* @__PURE__ */ jsx(Command.Empty, {
1932
- "data-slot": "command-empty",
1933
- className: cn("py-6 text-center text-sm", className),
1934
- ...props
1935
- });
1936
- };
1937
- var CommandGroup = ({ className, ...props }) => {
1938
- return /* @__PURE__ */ jsx(Command.Group, {
1939
- "data-slot": "command-group",
1940
- className: cn("overflow-hidden p-1 text-foreground **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium **:[[cmdk-group-heading]]:text-muted-foreground", className),
1941
- ...props
1942
- });
1943
- };
1944
- var CommandSeparator = ({ className, ...props }) => {
1945
- return /* @__PURE__ */ jsx(Command.Separator, {
1946
- "data-slot": "command-separator",
1947
- className: cn("-mx-1 h-px bg-border", className),
1948
- ...props
1949
- });
1950
- };
1951
- var CommandItem = ({ className, children, ...props }) => {
1952
- return /* @__PURE__ */ jsxs(Command.Item, {
1953
- "data-slot": "command-item",
1954
- className: cn("group/command-item relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none in-data-[slot=dialog-content]:rounded-lg! data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 data-selected:bg-muted data-selected:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-selected:*:[svg]:text-foreground", className),
1955
- ...props,
1956
- children: [children, /* @__PURE__ */ jsx(IconCheck, { className: "ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" })]
1957
- });
1958
- };
1959
- var CommandShortcut = ({ className, ...props }) => {
1960
- return /* @__PURE__ */ jsx("span", {
1961
- "data-slot": "command-shortcut",
1962
- className: cn("ml-auto text-xs tracking-widest text-muted-foreground group-data-selected/command-item:text-foreground", className),
1963
- ...props
1964
- });
1965
- };
1966
- //#endregion
1967
- //#region ../ui/src/components/ui/context-menu/context-menu.tsx
1968
- var ContextMenu$1 = ({ ...props }) => {
1969
- return /* @__PURE__ */ jsx(ContextMenu.Root, {
1970
- "data-slot": "context-menu",
1971
- ...props
1972
- });
1973
- };
1974
- var ContextMenuPortal = ({ ...props }) => {
1975
- return /* @__PURE__ */ jsx(ContextMenu.Portal, {
1976
- "data-slot": "context-menu-portal",
1977
- ...props
1978
- });
1979
- };
1980
- var ContextMenuTrigger = ({ className, ...props }) => {
1981
- return /* @__PURE__ */ jsx(ContextMenu.Trigger, {
1982
- "data-slot": "context-menu-trigger",
1983
- className: cn("select-none", className),
1984
- ...props
1985
- });
1986
- };
1987
- var ContextMenuContent = ({ className, align = "start", alignOffset = 4, side = "right", sideOffset = 0, ...props }) => {
1988
- return /* @__PURE__ */ jsx(ContextMenu.Portal, { children: /* @__PURE__ */ jsx(ContextMenu.Positioner, {
1989
- className: "isolate z-50 outline-none",
1990
- align,
1991
- alignOffset,
1992
- side,
1993
- sideOffset,
1994
- children: /* @__PURE__ */ jsx(ContextMenu.Popup, {
1995
- "data-slot": "context-menu-content",
1996
- className: cn("z-50 max-h-(--available-height) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", "motion-reduce:animate-none", className),
1997
- ...props
1998
- })
1999
- }) });
2000
- };
2001
- var ContextMenuGroup = ({ ...props }) => {
2002
- return /* @__PURE__ */ jsx(ContextMenu.Group, {
2003
- "data-slot": "context-menu-group",
2004
- ...props
2005
- });
2006
- };
2007
- var ContextMenuLabel = ({ className, inset, ...props }) => {
2008
- return /* @__PURE__ */ jsx(ContextMenu.GroupLabel, {
2009
- "data-slot": "context-menu-label",
2010
- "data-inset": inset,
2011
- className: cn("px-1.5 py-1 text-xs font-medium text-muted-foreground data-[inset=true]:pl-7", className),
2012
- ...props
2013
- });
2014
- };
2015
- var ContextMenuItem = ({ className, inset, variant = "default", ...props }) => {
2016
- return /* @__PURE__ */ jsx(ContextMenu.Item, {
2017
- "data-slot": "context-menu-item",
2018
- "data-inset": inset,
2019
- "data-variant": variant,
2020
- className: cn("group/context-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[inset=true]:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 focus:*:[svg]:text-accent-foreground data-[variant=destructive]:*:[svg]:text-destructive", className),
2021
- ...props
2022
- });
2023
- };
2024
- var ContextMenuSub = ({ ...props }) => {
2025
- return /* @__PURE__ */ jsx(ContextMenu.SubmenuRoot, {
2026
- "data-slot": "context-menu-sub",
2027
- ...props
2028
- });
2029
- };
2030
- var ContextMenuSubTrigger = ({ className, inset, children, ...props }) => {
2031
- return /* @__PURE__ */ jsxs(ContextMenu.SubmenuTrigger, {
2032
- "data-slot": "context-menu-sub-trigger",
2033
- "data-inset": inset,
2034
- className: cn("flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[inset=true]:pl-7 data-popup-open:bg-accent data-popup-open:text-accent-foreground data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2035
- ...props,
2036
- children: [children, /* @__PURE__ */ jsx(IconChevronRight, { className: "ml-auto" })]
2037
- });
2038
- };
2039
- var ContextMenuSubContent = ({ ...props }) => {
2040
- return /* @__PURE__ */ jsx(ContextMenuContent, {
2041
- "data-slot": "context-menu-sub-content",
2042
- className: "shadow-lg",
2043
- side: "right",
2044
- ...props
2045
- });
2046
- };
2047
- var ContextMenuCheckboxItem = ({ className, children, checked, inset, ...props }) => {
2048
- return /* @__PURE__ */ jsxs(ContextMenu.CheckboxItem, {
2049
- "data-slot": "context-menu-checkbox-item",
2050
- "data-inset": inset,
2051
- className: cn("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[inset=true]:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2052
- checked,
2053
- ...props,
2054
- children: [/* @__PURE__ */ jsx("span", {
2055
- className: "pointer-events-none absolute right-2",
2056
- children: /* @__PURE__ */ jsx(ContextMenu.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx(IconCheck, {}) })
2057
- }), children]
2058
- });
2059
- };
2060
- var ContextMenuRadioGroup = ({ ...props }) => {
2061
- return /* @__PURE__ */ jsx(ContextMenu.RadioGroup, {
2062
- "data-slot": "context-menu-radio-group",
2063
- ...props
2064
- });
2065
- };
2066
- var ContextMenuRadioItem = ({ className, children, inset, ...props }) => {
2067
- return /* @__PURE__ */ jsxs(ContextMenu.RadioItem, {
2068
- "data-slot": "context-menu-radio-item",
2069
- "data-inset": inset,
2070
- className: cn("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[inset=true]:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2071
- ...props,
2072
- children: [/* @__PURE__ */ jsx("span", {
2073
- className: "pointer-events-none absolute right-2",
2074
- children: /* @__PURE__ */ jsx(ContextMenu.RadioItemIndicator, { children: /* @__PURE__ */ jsx(IconCheck, {}) })
2075
- }), children]
2076
- });
2077
- };
2078
- var ContextMenuSeparator = ({ className, ...props }) => {
2079
- return /* @__PURE__ */ jsx(ContextMenu.Separator, {
2080
- "data-slot": "context-menu-separator",
2081
- className: cn("-mx-1 my-1 h-px bg-border", className),
2082
- ...props
2083
- });
2084
- };
2085
- var ContextMenuShortcut = ({ className, ...props }) => {
2086
- return /* @__PURE__ */ jsx("span", {
2087
- "data-slot": "context-menu-shortcut",
2088
- className: cn("ml-auto text-xs tracking-widest text-muted-foreground group-focus/context-menu-item:text-accent-foreground", className),
2089
- ...props
2090
- });
2091
- };
2092
- //#endregion
2093
- //#region ../ui/src/components/ui/drawer/drawer.tsx
2094
- var Drawer = ({ ...props }) => {
2095
- return /* @__PURE__ */ jsx(Dialog.Root, {
2096
- "data-slot": "drawer",
2097
- ...props
2098
- });
2099
- };
2100
- var DrawerTrigger = ({ ...props }) => {
2101
- return /* @__PURE__ */ jsx(Dialog.Trigger, {
2102
- "data-slot": "drawer-trigger",
2103
- ...props
2104
- });
2105
- };
2106
- var DrawerClose = ({ ...props }) => {
2107
- return /* @__PURE__ */ jsx(Dialog.Close, {
2108
- "data-slot": "drawer-close",
2109
- ...props
2110
- });
2111
- };
2112
- var DrawerOverlay = ({ className, ...props }) => {
2113
- return /* @__PURE__ */ jsx(Dialog.Backdrop, {
2114
- "data-slot": "drawer-overlay",
2115
- className: cn("fixed inset-0 isolate z-50 bg-overlay duration-100 motion-reduce:animate-none supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", className),
2116
- ...props
2117
- });
2118
- };
2119
- var DrawerContent = ({ className, children, side = "right", showCloseButton = true, ...props }) => {
2120
- return /* @__PURE__ */ jsxs(Dialog.Portal, {
2121
- "data-slot": "drawer-portal",
2122
- children: [/* @__PURE__ */ jsx(DrawerOverlay, {}), /* @__PURE__ */ jsxs(Dialog.Popup, {
2123
- "data-slot": "drawer-content",
2124
- "data-side": side,
2125
- className: cn("fixed z-50 flex flex-col gap-4 border-border bg-popover p-4 text-sm text-popover-foreground shadow-lg outline-none duration-100 motion-reduce:animate-none data-open:animate-in data-closed:animate-out", side === "right" && "inset-y-0 right-0 h-full w-3/4 max-w-sm border-l data-open:slide-in-from-right data-closed:slide-out-to-right", side === "left" && "inset-y-0 left-0 h-full w-3/4 max-w-sm border-r data-open:slide-in-from-left data-closed:slide-out-to-left", side === "top" && "inset-x-0 top-0 h-auto border-b data-open:slide-in-from-top data-closed:slide-out-to-top", side === "bottom" && "inset-x-0 bottom-0 h-auto border-t data-open:slide-in-from-bottom data-closed:slide-out-to-bottom", className),
2126
- ...props,
2127
- children: [children, showCloseButton && /* @__PURE__ */ jsxs(Dialog.Close, {
2128
- "data-slot": "drawer-close",
2129
- render: /* @__PURE__ */ jsx(Button$1, {
2130
- variant: "ghost",
2131
- className: "absolute top-2 right-2",
2132
- size: "icon-sm"
2133
- }),
2134
- children: [/* @__PURE__ */ jsx(IconX, {}), /* @__PURE__ */ jsx("span", {
2135
- className: "sr-only",
2136
- children: "Close"
2137
- })]
2138
- })]
2139
- })]
2140
- });
2141
- };
2142
- var DrawerHeader = ({ className, ...props }) => {
2143
- return /* @__PURE__ */ jsx("div", {
2144
- "data-slot": "drawer-header",
2145
- className: cn("flex flex-col gap-2", className),
2146
- ...props
2147
- });
2148
- };
2149
- var DrawerFooter = ({ className, ...props }) => {
2150
- return /* @__PURE__ */ jsx("div", {
2151
- "data-slot": "drawer-footer",
2152
- className: cn("mt-auto flex flex-col gap-2", className),
2153
- ...props
2154
- });
2155
- };
2156
- var DrawerTitle = ({ className, ...props }) => {
2157
- return /* @__PURE__ */ jsx(Dialog.Title, {
2158
- "data-slot": "drawer-title",
2159
- className: cn("text-base leading-none font-medium", className),
2160
- ...props
2161
- });
2162
- };
2163
- var DrawerDescription = ({ className, ...props }) => {
2164
- return /* @__PURE__ */ jsx(Dialog.Description, {
2165
- "data-slot": "drawer-description",
2166
- className: cn("text-sm text-muted-foreground", className),
2167
- ...props
2168
- });
2169
- };
2170
- //#endregion
2171
- //#region ../ui/src/components/ui/dropdown-menu/dropdown-menu.tsx
2172
- var DropdownMenu = ({ ...props }) => {
2173
- return /* @__PURE__ */ jsx(Menu.Root, {
2174
- "data-slot": "dropdown-menu",
2175
- ...props
2176
- });
2177
- };
2178
- var DropdownMenuPortal = ({ ...props }) => {
2179
- return /* @__PURE__ */ jsx(Menu.Portal, {
2180
- "data-slot": "dropdown-menu-portal",
2181
- ...props
2182
- });
2183
- };
2184
- var DropdownMenuTrigger = ({ ...props }) => {
2185
- return /* @__PURE__ */ jsx(Menu.Trigger, {
2186
- "data-slot": "dropdown-menu-trigger",
2187
- ...props
2188
- });
2189
- };
2190
- /**
2191
- * The menu scrolls itself, with the browser's own scrollbar, where the popup
2192
- * lists in Command, Select and Combobox scroll inside a DS ScrollArea.
2193
- *
2194
- * That is not an oversight. Base UI puts `role="menu"` on this popup and offers
2195
- * no inner list part to move it onto, and a menu may not contain the
2196
- * presentation wrappers a ScrollArea brings: axe reports it as a critical
2197
- * aria-required-children violation, which is exactly what the palette and the
2198
- * select hit before their scroll container was moved outside the role. Select
2199
- * and Combobox were fixable because their primitives hand the role to a list
2200
- * part (Select.List) and leave the popup as presentation.
2201
- */
2202
- var DropdownMenuContent = ({ align = "start", alignOffset = 0, side = "bottom", sideOffset = 4, className, ...props }) => {
2203
- return /* @__PURE__ */ jsx(Menu.Portal, { children: /* @__PURE__ */ jsx(Menu.Positioner, {
2204
- className: "isolate z-50 outline-none",
2205
- align,
2206
- alignOffset,
2207
- side,
2208
- sideOffset,
2209
- children: /* @__PURE__ */ jsx(Menu.Popup, {
2210
- "data-slot": "dropdown-menu-content",
2211
- className: cn("z-50 max-h-(--available-height) w-(--anchor-width) min-w-32 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:overflow-hidden data-closed:fade-out-0 data-closed:zoom-out-95", "motion-reduce:animate-none", className),
2212
- ...props
2213
- })
2214
- }) });
2215
- };
2216
- var DropdownMenuGroup = ({ ...props }) => {
2217
- return /* @__PURE__ */ jsx(Menu.Group, {
2218
- "data-slot": "dropdown-menu-group",
2219
- ...props
2220
- });
2221
- };
2222
- var DropdownMenuLabel = ({ className, inset, ...props }) => {
2223
- return /* @__PURE__ */ jsx(Menu.GroupLabel, {
2224
- "data-slot": "dropdown-menu-label",
2225
- "data-inset": inset,
2226
- className: cn("px-1.5 py-1 text-xs font-medium text-muted-foreground data-[inset=true]:pl-7", className),
2227
- ...props
2228
- });
2229
- };
2230
- var DropdownMenuItem = ({ className, inset, variant = "default", ...props }) => {
2231
- return /* @__PURE__ */ jsx(Menu.Item, {
2232
- "data-slot": "dropdown-menu-item",
2233
- "data-inset": inset,
2234
- "data-variant": variant,
2235
- className: cn("group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-[inset=true]:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive", className),
2236
- ...props
2237
- });
2238
- };
2239
- var DropdownMenuSub = ({ ...props }) => {
2240
- return /* @__PURE__ */ jsx(Menu.SubmenuRoot, {
2241
- "data-slot": "dropdown-menu-sub",
2242
- ...props
2243
- });
2244
- };
2245
- var DropdownMenuSubTrigger = ({ className, inset, children, ...props }) => {
2246
- return /* @__PURE__ */ jsxs(Menu.SubmenuTrigger, {
2247
- "data-slot": "dropdown-menu-sub-trigger",
2248
- "data-inset": inset,
2249
- className: cn("flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-[inset=true]:pl-7 data-popup-open:bg-accent data-popup-open:text-accent-foreground data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2250
- ...props,
2251
- children: [children, /* @__PURE__ */ jsx(IconChevronRight, { className: "ml-auto" })]
2252
- });
2253
- };
2254
- var DropdownMenuSubContent = ({ align = "start", alignOffset = -3, side = "right", sideOffset = 0, className, ...props }) => {
2255
- return /* @__PURE__ */ jsx(DropdownMenuContent, {
2256
- "data-slot": "dropdown-menu-sub-content",
2257
- className: cn("w-auto min-w-[96px] rounded-lg bg-popover p-1 text-popover-foreground shadow-lg ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", "motion-reduce:animate-none", className),
2258
- align,
2259
- alignOffset,
2260
- side,
2261
- sideOffset,
2262
- ...props
2263
- });
2264
- };
2265
- var DropdownMenuCheckboxItem = ({ className, children, checked, inset, ...props }) => {
2266
- return /* @__PURE__ */ jsxs(Menu.CheckboxItem, {
2267
- "data-slot": "dropdown-menu-checkbox-item",
2268
- "data-inset": inset,
2269
- className: cn("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-[inset=true]:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2270
- checked,
2271
- ...props,
2272
- children: [/* @__PURE__ */ jsx("span", {
2273
- className: "pointer-events-none absolute right-2 flex items-center justify-center",
2274
- "data-slot": "dropdown-menu-checkbox-item-indicator",
2275
- children: /* @__PURE__ */ jsx(Menu.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx(IconCheck, {}) })
2276
- }), children]
2277
- });
2278
- };
2279
- var DropdownMenuRadioGroup = ({ ...props }) => {
2280
- return /* @__PURE__ */ jsx(Menu.RadioGroup, {
2281
- "data-slot": "dropdown-menu-radio-group",
2282
- ...props
2283
- });
2284
- };
2285
- var DropdownMenuRadioItem = ({ className, children, inset, ...props }) => {
2286
- return /* @__PURE__ */ jsxs(Menu.RadioItem, {
2287
- "data-slot": "dropdown-menu-radio-item",
2288
- "data-inset": inset,
2289
- className: cn("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-[inset=true]:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2290
- ...props,
2291
- children: [/* @__PURE__ */ jsx("span", {
2292
- className: "pointer-events-none absolute right-2 flex items-center justify-center",
2293
- "data-slot": "dropdown-menu-radio-item-indicator",
2294
- children: /* @__PURE__ */ jsx(Menu.RadioItemIndicator, { children: /* @__PURE__ */ jsx(IconCheck, {}) })
2295
- }), children]
2296
- });
2297
- };
2298
- var DropdownMenuSeparator = ({ className, ...props }) => {
2299
- return /* @__PURE__ */ jsx(Menu.Separator, {
2300
- "data-slot": "dropdown-menu-separator",
2301
- className: cn("-mx-1 my-1 h-px bg-border", className),
2302
- ...props
2303
- });
2304
- };
2305
- var DropdownMenuShortcut = ({ className, ...props }) => {
2306
- return /* @__PURE__ */ jsx("span", {
2307
- "data-slot": "dropdown-menu-shortcut",
2308
- className: cn("ml-auto text-xs tracking-widest text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground", className),
2309
- ...props
2310
- });
2311
- };
2312
- //#endregion
2313
- //#region ../ui/src/components/ui/empty/empty.tsx
2314
- var Empty = ({ className, ...props }) => {
2315
- return /* @__PURE__ */ jsx("div", {
2316
- "data-slot": "empty",
2317
- className: cn("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance", className),
2318
- ...props
2319
- });
2320
- };
2321
- var EmptyHeader = ({ className, ...props }) => {
2322
- return /* @__PURE__ */ jsx("div", {
2323
- "data-slot": "empty-header",
2324
- className: cn("flex max-w-sm flex-col items-center gap-2", className),
2325
- ...props
2326
- });
2327
- };
2328
- var emptyMediaVariants = cva("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0", {
2329
- variants: { variant: {
2330
- default: "bg-transparent",
2331
- icon: "flex size-8 shrink-0 items-center justify-center rounded-lg bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"
2332
- } },
2333
- defaultVariants: { variant: "default" }
2334
- });
2335
- var EmptyMedia = ({ className, variant = "default", ...props }) => {
2336
- return /* @__PURE__ */ jsx("div", {
2337
- "data-slot": "empty-icon",
2338
- "data-variant": variant,
2339
- className: cn(emptyMediaVariants({
2340
- variant,
2341
- className
2342
- })),
2343
- ...props
2344
- });
2345
- };
2346
- var EmptyTitle = ({ className, ...props }) => {
2347
- return /* @__PURE__ */ jsx("div", {
2348
- "data-slot": "empty-title",
2349
- className: cn("font-heading text-sm font-medium tracking-tight", className),
2350
- ...props
2351
- });
2352
- };
2353
- var EmptyDescription = ({ className, ...props }) => {
2354
- return /* @__PURE__ */ jsx("div", {
2355
- "data-slot": "empty-description",
2356
- className: cn("text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary", className),
2357
- ...props
2358
- });
2359
- };
2360
- var EmptyContent = ({ className, ...props }) => {
2361
- return /* @__PURE__ */ jsx("div", {
2362
- "data-slot": "empty-content",
2363
- className: cn("flex w-full max-w-sm min-w-0 flex-col items-center gap-2.5 text-sm text-balance", className),
2364
- ...props
2365
- });
2366
- };
2367
- //#endregion
2368
- //#region ../ui/src/components/ui/field/field.tsx
2369
- var Field$1 = ({ className, ...props }) => {
2370
- return /* @__PURE__ */ jsx(Field.Root, {
2371
- "data-slot": "field",
2372
- className: cn("group/field flex flex-col gap-1.5", className),
2373
- ...props
2374
- });
2375
- };
2376
- var FieldLabel = ({ className, ...props }) => {
2377
- return /* @__PURE__ */ jsx(Field.Label, {
2378
- "data-slot": "field-label",
2379
- className: cn("flex items-center gap-2 text-sm leading-none font-medium select-none group-has-disabled/field:pointer-events-none group-has-disabled/field:opacity-50", className),
2380
- ...props
2381
- });
2382
- };
2383
- var FieldDescription = ({ className, ...props }) => {
2384
- return /* @__PURE__ */ jsx(Field.Description, {
2385
- "data-slot": "field-description",
2386
- className: cn("text-sm text-muted-foreground", className),
2387
- ...props
2388
- });
2389
- };
2390
- var FieldError = ({ className, ...props }) => {
2391
- return /* @__PURE__ */ jsx(Field.Error, {
2392
- "data-slot": "field-error",
2393
- className: cn("text-sm text-destructive", className),
2394
- ...props
2395
- });
2396
- };
2397
- //#endregion
2398
- //#region ../ui/src/components/ui/hover-card/hover-card.tsx
2399
- var HoverCard = ({ ...props }) => {
2400
- return /* @__PURE__ */ jsx(PreviewCard.Root, {
2401
- "data-slot": "hover-card",
2402
- ...props
2403
- });
2404
- };
2405
- var HoverCardTrigger = ({ ...props }) => {
2406
- return /* @__PURE__ */ jsx(PreviewCard.Trigger, {
2407
- "data-slot": "hover-card-trigger",
2408
- ...props
2409
- });
2410
- };
2411
- var HoverCardContent = ({ className, side = "bottom", sideOffset = 4, align = "center", alignOffset = 4, ...props }) => {
2412
- return /* @__PURE__ */ jsx(PreviewCard.Portal, {
2413
- "data-slot": "hover-card-portal",
2414
- children: /* @__PURE__ */ jsx(PreviewCard.Positioner, {
2415
- align,
2416
- alignOffset,
2417
- side,
2418
- sideOffset,
2419
- className: "isolate z-50",
2420
- children: /* @__PURE__ */ jsx(PreviewCard.Popup, {
2421
- "data-slot": "hover-card-content",
2422
- className: cn("z-50 w-64 origin-(--transform-origin) rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 motion-reduce:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
2423
- ...props
2424
- })
2425
- })
2426
- });
2427
- };
2428
- //#endregion
2429
- //#region ../ui/src/components/ui/indicator/indicator.tsx
2430
- /**
2431
- * Indicator: notification count-bubble or status-dot that attaches to a corner
2432
- * of another element (the Material/Angular "badge" concept; our Badge is the
2433
- * label chip). The parent element must be position-relative (e.g. `relative`).
2434
- *
2435
- * Legacy mapping: `edynBadge` directive -> `Indicator` default/destructive;
2436
- * `edyn-dot` -> `Indicator` dot variant.
2437
- * Positioning uses Radix vocabulary: side (top|bottom) + align (start|end).
2438
- */
2439
- var indicatorVariants = cva("absolute z-10 inline-flex shrink-0 items-center justify-center font-medium leading-none ring-2 ring-background", {
2440
- variants: {
2441
- variant: {
2442
- /** Count bubble: primary colors, shows children as the count/text. */
2443
- default: "h-4 min-w-4 rounded-full bg-primary px-1 text-xs tabular-nums text-primary-foreground",
2444
- /** Status dot: solid circle, no children rendered. */
2445
- dot: "size-2 rounded-full bg-primary",
2446
- /** Count bubble in destructive (error/alert) colors. */
2447
- destructive: "h-4 min-w-4 rounded-full bg-destructive px-1 text-xs text-destructive-foreground tabular-nums dark:text-background"
2448
- },
2449
- side: {
2450
- top: "top-0",
2451
- bottom: "bottom-0"
2452
- },
2453
- align: {
2454
- start: "left-0",
2455
- end: "right-0"
2456
- }
2457
- },
2458
- compoundVariants: [
2459
- {
2460
- side: "top",
2461
- align: "start",
2462
- class: "-translate-x-1/2 -translate-y-1/2"
2463
- },
2464
- {
2465
- side: "top",
2466
- align: "end",
2467
- class: "translate-x-1/2 -translate-y-1/2"
2468
- },
2469
- {
2470
- side: "bottom",
2471
- align: "start",
2472
- class: "-translate-x-1/2 translate-y-1/2"
2473
- },
2474
- {
2475
- side: "bottom",
2476
- align: "end",
2477
- class: "translate-x-1/2 translate-y-1/2"
2478
- }
2479
- ],
2480
- defaultVariants: {
2481
- variant: "default",
2482
- side: "top",
2483
- align: "end"
2484
- }
2485
- });
2486
- var Indicator = ({ className, variant = "default", side = "top", align = "end", children, ...props }) => {
2487
- return /* @__PURE__ */ jsx("span", {
2488
- "data-slot": "indicator",
2489
- "data-variant": variant,
2490
- "data-side": side,
2491
- "data-align": align,
2492
- className: cn(indicatorVariants({
2493
- variant,
2494
- side,
2495
- align
2496
- }), className),
2497
- ...props,
2498
- children: variant !== "dot" ? children : null
2499
- });
2500
- };
2501
- //#endregion
2502
- //#region ../ui/src/components/ui/input-otp/input-otp.tsx
2503
- var InputOTP = ({ className, containerClassName, ...props }) => {
2504
- return /* @__PURE__ */ jsx(OTPInput, {
2505
- "data-slot": "input-otp",
2506
- containerClassName: cn("cn-input-otp flex items-center has-disabled:opacity-50", containerClassName),
2507
- spellCheck: false,
2508
- className: cn("disabled:cursor-not-allowed", className),
2509
- ...props
2510
- });
2511
- };
2512
- var InputOTPGroup = ({ className, ...props }) => {
2513
- return /* @__PURE__ */ jsx("div", {
2514
- "data-slot": "input-otp-group",
2515
- className: cn("flex items-center rounded-lg has-aria-invalid:border-destructive has-aria-invalid:ring-3 has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40", className),
2516
- ...props
2517
- });
2518
- };
2519
- var InputOTPSlot = ({ index, className, ...props }) => {
2520
- const { char, hasFakeCaret, isActive } = React.useContext(OTPInputContext)?.slots[index] ?? {};
2521
- return /* @__PURE__ */ jsxs("div", {
2522
- "data-slot": "input-otp-slot",
2523
- "data-active": isActive,
2524
- className: cn("relative flex size-8 items-center justify-center border-y border-r border-input text-sm transition-all outline-none first:rounded-l-lg first:border-l last:rounded-r-lg aria-invalid:border-destructive data-[active=true]:z-10 data-[active=true]:border-ring data-[active=true]:ring-3 data-[active=true]:ring-ring/50 data-[active=true]:aria-invalid:border-destructive data-[active=true]:aria-invalid:ring-destructive/20 dark:bg-input/30 dark:data-[active=true]:aria-invalid:ring-destructive/40", className),
2525
- ...props,
2526
- children: [char, hasFakeCaret && /* @__PURE__ */ jsx("div", {
2527
- className: "pointer-events-none absolute inset-0 flex items-center justify-center",
2528
- children: /* @__PURE__ */ jsx("div", { className: "h-4 w-px animate-caret-blink bg-foreground duration-1000 motion-reduce:animate-none" })
2529
- })]
2530
- });
2531
- };
2532
- var InputOTPSeparator = ({ ...props }) => {
2533
- return /* @__PURE__ */ jsx("div", {
2534
- "data-slot": "input-otp-separator",
2535
- className: "flex items-center [&_svg:not([class*='size-'])]:size-4",
2536
- "aria-hidden": "true",
2537
- ...props,
2538
- children: /* @__PURE__ */ jsx(IconMinus, {})
2539
- });
2540
- };
2541
- //#endregion
2542
- //#region ../ui/src/components/ui/separator/separator.tsx
2543
- /**
2544
- * Hairline rule between content, announced as `role="separator"`.
2545
- *
2546
- * The orientation styles are branched in TS rather than written as
2547
- * `data-[orientation=*]:` variants on purpose. A variant carries two
2548
- * selectors' worth of specificity, so it would outrank a plain class passed in
2549
- * by the caller: the sidebar's own `w-auto` lost to `w-full` that way. Branching
2550
- * emits one plain class per axis, which `cn` can dedupe and a caller can
2551
- * override.
2552
- *
2553
- * Vertical uses `self-stretch` instead of `h-full`: a percentage height needs a
2554
- * definite parent, and the usual host is an `items-center` row whose height
2555
- * comes from its content.
2556
- */
2557
- var Separator$1 = ({ className, orientation = "horizontal", ...props }) => {
2558
- return /* @__PURE__ */ jsx(Separator, {
2559
- "data-slot": "separator",
2560
- orientation,
2561
- className: cn("shrink-0 bg-border", orientation === "horizontal" ? "h-px w-full" : "w-px self-stretch", className),
2562
- ...props
2563
- });
2564
- };
2565
- //#endregion
2566
- //#region ../ui/src/components/ui/item/item.tsx
2567
- var ItemGroup = ({ className, ...props }) => {
2568
- return /* @__PURE__ */ jsx("div", {
2569
- role: "list",
2570
- "data-slot": "item-group",
2571
- className: cn("group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2", className),
2572
- ...props
2573
- });
2574
- };
2575
- var ItemSeparator = ({ className, ...props }) => {
2576
- return /* @__PURE__ */ jsx(Separator$1, {
2577
- "data-slot": "item-separator",
2578
- orientation: "horizontal",
2579
- className: cn("my-2", className),
2580
- ...props
2581
- });
2582
- };
2583
- var itemVariants = cva("group/item flex w-full flex-wrap items-center rounded-lg border text-sm transition-colors duration-100 outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 [a]:transition-colors [a]:hover:bg-muted", {
2584
- variants: {
2585
- variant: {
2586
- default: "border-transparent",
2587
- outline: "border-border",
2588
- muted: "border-transparent bg-muted/50"
2589
- },
2590
- size: {
2591
- default: "gap-2.5 px-3 py-2.5",
2592
- sm: "gap-2.5 px-3 py-2.5",
2593
- xs: "gap-2 px-2.5 py-2 in-data-[slot=dropdown-menu-content]:p-0"
2594
- }
2595
- },
2596
- defaultVariants: {
2597
- variant: "default",
2598
- size: "default"
2599
- }
2600
- });
2601
- var Item = ({ className, variant = "default", size = "default", render, ...props }) => {
2602
- return useRender({
2603
- defaultTagName: "div",
2604
- props: mergeProps({ className: cn(itemVariants({
2605
- variant,
2606
- size,
2607
- className
2608
- })) }, props),
2609
- render,
2610
- state: {
2611
- slot: "item",
2612
- variant,
2613
- size
2614
- }
2615
- });
2616
- };
2617
- var itemMediaVariants = cva("flex shrink-0 items-center justify-center gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start [&_svg]:pointer-events-none", {
2618
- variants: { variant: {
2619
- default: "bg-transparent",
2620
- icon: "[&_svg:not([class*='size-'])]:size-4",
2621
- image: "size-10 overflow-hidden rounded-sm group-data-[size=sm]/item:size-8 group-data-[size=xs]/item:size-6 [&_img]:size-full [&_img]:object-cover"
2622
- } },
2623
- defaultVariants: { variant: "default" }
2624
- });
2625
- var ItemMedia = ({ className, variant = "default", ...props }) => {
2626
- return /* @__PURE__ */ jsx("div", {
2627
- "data-slot": "item-media",
2628
- "data-variant": variant,
2629
- className: cn(itemMediaVariants({
2630
- variant,
2631
- className
2632
- })),
2633
- ...props
2634
- });
2635
- };
2636
- var ItemContent = ({ className, ...props }) => {
2637
- return /* @__PURE__ */ jsx("div", {
2638
- "data-slot": "item-content",
2639
- className: cn("flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none", className),
2640
- ...props
2641
- });
2642
- };
2643
- var ItemTitle = ({ className, ...props }) => {
2644
- return /* @__PURE__ */ jsx("div", {
2645
- "data-slot": "item-title",
2646
- className: cn("line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4", className),
2647
- ...props
2648
- });
2649
- };
2650
- var ItemDescription = ({ className, ...props }) => {
2651
- return /* @__PURE__ */ jsx("p", {
2652
- "data-slot": "item-description",
2653
- className: cn("line-clamp-2 text-left text-sm leading-normal font-normal text-muted-foreground group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary", className),
2654
- ...props
2655
- });
2656
- };
2657
- var ItemActions = ({ className, ...props }) => {
2658
- return /* @__PURE__ */ jsx("div", {
2659
- "data-slot": "item-actions",
2660
- className: cn("flex items-center gap-2", className),
2661
- ...props
2662
- });
2663
- };
2664
- var ItemHeader = ({ className, ...props }) => {
2665
- return /* @__PURE__ */ jsx("div", {
2666
- "data-slot": "item-header",
2667
- className: cn("flex basis-full items-center justify-between gap-2", className),
2668
- ...props
2669
- });
2670
- };
2671
- var ItemFooter = ({ className, ...props }) => {
2672
- return /* @__PURE__ */ jsx("div", {
2673
- "data-slot": "item-footer",
2674
- className: cn("flex basis-full items-center justify-between gap-2", className),
2675
- ...props
2676
- });
2677
- };
2678
- //#endregion
2679
- //#region ../ui/src/components/ui/kbd/kbd.tsx
2680
- var Kbd = ({ className, ...props }) => {
2681
- return /* @__PURE__ */ jsx("kbd", {
2682
- "data-slot": "kbd",
2683
- className: cn("pointer-events-none inline-flex h-5 w-fit min-w-5 items-center justify-center gap-1 rounded-sm bg-muted px-1 font-sans text-xs font-medium text-muted-foreground select-none in-data-[slot=tooltip-content]:bg-background/20 in-data-[slot=tooltip-content]:text-background dark:in-data-[slot=tooltip-content]:bg-background/10 [&_svg:not([class*='size-'])]:size-3", className),
2684
- ...props
2685
- });
2686
- };
2687
- var KbdGroup = ({ className, ...props }) => {
2688
- return /* @__PURE__ */ jsx("kbd", {
2689
- "data-slot": "kbd-group",
2690
- className: cn("inline-flex items-center gap-1", className),
2691
- ...props
2692
- });
2693
- };
2694
- //#endregion
2695
- //#region ../ui/src/components/ui/label/label.tsx
2696
- var Label = ({ className, ...props }) => {
2697
- return /* @__PURE__ */ jsx("label", {
2698
- "data-slot": "label",
2699
- className: cn("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50", className),
2700
- ...props
2701
- });
2702
- };
2703
- //#endregion
2704
- //#region ../ui/src/components/ui/marker/marker.tsx
2705
- var markerVariants = cva("group/marker relative flex min-h-4 w-full items-center gap-2 text-left text-sm text-muted-foreground [&_svg:not([class*='size-'])]:size-4 [a]:underline [a]:underline-offset-3 [a]:hover:text-foreground", { variants: { variant: {
2706
- default: "",
2707
- separator: "before:mr-1 before:h-px before:min-w-0 before:flex-1 before:bg-border after:ml-1 after:h-px after:min-w-0 after:flex-1 after:bg-border",
2708
- border: "border-b border-border pb-2"
2709
- } } });
2710
- var Marker = ({ className, variant = "default", render, ...props }) => {
2711
- return useRender({
2712
- defaultTagName: "div",
2713
- props: mergeProps({ className: cn(markerVariants({
2714
- variant,
2715
- className
2716
- })) }, props),
2717
- render,
2718
- state: {
2719
- slot: "marker",
2720
- variant
2721
- }
2722
- });
2723
- };
2724
- var MarkerIcon = ({ className, ...props }) => {
2725
- return /* @__PURE__ */ jsx("span", {
2726
- "data-slot": "marker-icon",
2727
- "aria-hidden": "true",
2728
- className: cn("size-4 shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2729
- ...props
2730
- });
2731
- };
2732
- var MarkerContent = ({ className, ...props }) => {
2733
- return /* @__PURE__ */ jsx("span", {
2734
- "data-slot": "marker-content",
2735
- className: cn("min-w-0 wrap-break-word group-data-[variant=separator]/marker:flex-none group-data-[variant=separator]/marker:text-center *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", className),
2736
- ...props
2737
- });
2738
- };
2739
- //#endregion
2740
- //#region ../ui/src/components/ui/menubar/menubar.tsx
2741
- var Menubar$1 = ({ className, ...props }) => {
2742
- return /* @__PURE__ */ jsx(Menubar, {
2743
- "data-slot": "menubar",
2744
- className: cn("flex h-8 items-center gap-0.5 rounded-lg border p-[3px]", className),
2745
- ...props
2746
- });
2747
- };
2748
- var MenubarMenu = ({ ...props }) => {
2749
- return /* @__PURE__ */ jsx(DropdownMenu, {
2750
- "data-slot": "menubar-menu",
2751
- ...props
2752
- });
2753
- };
2754
- var MenubarGroup = ({ ...props }) => {
2755
- return /* @__PURE__ */ jsx(DropdownMenuGroup, {
2756
- "data-slot": "menubar-group",
2757
- ...props
2758
- });
2759
- };
2760
- var MenubarPortal = ({ ...props }) => {
2761
- return /* @__PURE__ */ jsx(DropdownMenuPortal, {
2762
- "data-slot": "menubar-portal",
2763
- ...props
2764
- });
2765
- };
2766
- var MenubarTrigger = ({ className, ...props }) => {
2767
- return /* @__PURE__ */ jsx(DropdownMenuTrigger, {
2768
- "data-slot": "menubar-trigger",
2769
- className: cn("flex items-center rounded-sm px-1.5 py-[2px] text-sm font-medium outline-hidden select-none hover:bg-muted aria-expanded:bg-muted", className),
2770
- ...props
2771
- });
2772
- };
2773
- var MenubarContent = ({ className, align = "start", alignOffset = -4, sideOffset = 8, ...props }) => {
2774
- return /* @__PURE__ */ jsx(DropdownMenuContent, {
2775
- "data-slot": "menubar-content",
2776
- align,
2777
- alignOffset,
2778
- sideOffset,
2779
- className: cn("min-w-36 rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95", "motion-reduce:animate-none", className),
2780
- ...props
2781
- });
2782
- };
2783
- var MenubarItem = ({ className, inset, variant = "default", ...props }) => {
2784
- return /* @__PURE__ */ jsx(DropdownMenuItem, {
2785
- "data-slot": "menubar-item",
2786
- "data-inset": inset,
2787
- "data-variant": variant,
2788
- className: cn("group/menubar-item gap-1.5 rounded-md px-1.5 py-1 text-sm focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-[inset=true]:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:opacity-50 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive!", className),
2789
- ...props
2790
- });
2791
- };
2792
- var MenubarCheckboxItem = ({ className, children, checked, inset, ...props }) => {
2793
- return /* @__PURE__ */ jsxs(Menu.CheckboxItem, {
2794
- "data-slot": "menubar-checkbox-item",
2795
- "data-inset": inset,
2796
- className: cn("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-1.5 pl-7 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-[inset=true]:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0", className),
2797
- checked,
2798
- ...props,
2799
- children: [/* @__PURE__ */ jsx("span", {
2800
- className: "pointer-events-none absolute left-1.5 flex size-4 items-center justify-center [&_svg:not([class*='size-'])]:size-4",
2801
- children: /* @__PURE__ */ jsx(Menu.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx(IconCheck, {}) })
2802
- }), children]
2803
- });
2804
- };
2805
- var MenubarRadioGroup = ({ ...props }) => {
2806
- return /* @__PURE__ */ jsx(DropdownMenuRadioGroup, {
2807
- "data-slot": "menubar-radio-group",
2808
- ...props
2809
- });
2810
- };
2811
- var MenubarRadioItem = ({ className, children, inset, ...props }) => {
2812
- return /* @__PURE__ */ jsxs(Menu.RadioItem, {
2813
- "data-slot": "menubar-radio-item",
2814
- "data-inset": inset,
2815
- className: cn("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-1.5 pl-7 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-[inset=true]:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
2816
- ...props,
2817
- children: [/* @__PURE__ */ jsx("span", {
2818
- className: "pointer-events-none absolute left-1.5 flex size-4 items-center justify-center [&_svg:not([class*='size-'])]:size-4",
2819
- children: /* @__PURE__ */ jsx(Menu.RadioItemIndicator, { children: /* @__PURE__ */ jsx(IconCheck, {}) })
2820
- }), children]
2821
- });
2822
- };
2823
- var MenubarLabel = ({ className, inset, ...props }) => {
2824
- return /* @__PURE__ */ jsx(DropdownMenuLabel, {
2825
- "data-slot": "menubar-label",
2826
- "data-inset": inset,
2827
- className: cn("px-1.5 py-1 text-sm font-medium data-[inset=true]:pl-7", className),
2828
- ...props
2829
- });
2830
- };
2831
- var MenubarSeparator = ({ className, ...props }) => {
2832
- return /* @__PURE__ */ jsx(DropdownMenuSeparator, {
2833
- "data-slot": "menubar-separator",
2834
- className: cn("-mx-1 my-1 h-px bg-border", className),
2835
- ...props
2836
- });
2837
- };
2838
- var MenubarShortcut = ({ className, ...props }) => {
2839
- return /* @__PURE__ */ jsx(DropdownMenuShortcut, {
2840
- "data-slot": "menubar-shortcut",
2841
- className: cn("ml-auto text-xs tracking-widest text-muted-foreground group-focus/menubar-item:text-accent-foreground", className),
2842
- ...props
2843
- });
2844
- };
2845
- var MenubarSub = ({ ...props }) => {
2846
- return /* @__PURE__ */ jsx(DropdownMenuSub, {
2847
- "data-slot": "menubar-sub",
2848
- ...props
2849
- });
2850
- };
2851
- var MenubarSubTrigger = ({ className, inset, ...props }) => {
2852
- return /* @__PURE__ */ jsx(DropdownMenuSubTrigger, {
2853
- "data-slot": "menubar-sub-trigger",
2854
- "data-inset": inset,
2855
- className: cn("gap-1.5 rounded-md px-1.5 py-1 text-sm focus:bg-accent focus:text-accent-foreground data-[inset=true]:pl-7 data-open:bg-accent data-open:text-accent-foreground [&_svg:not([class*='size-'])]:size-4", className),
2856
- ...props
2857
- });
2858
- };
2859
- var MenubarSubContent = ({ className, ...props }) => {
2860
- return /* @__PURE__ */ jsx(DropdownMenuSubContent, {
2861
- "data-slot": "menubar-sub-content",
2862
- className: cn("min-w-32 rounded-lg bg-popover p-1 text-popover-foreground shadow-lg ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", "motion-reduce:animate-none", className),
2863
- ...props
2864
- });
2865
- };
2866
- //#endregion
2867
- //#region ../ui/src/components/ui/message/message.tsx
2868
- var MessageGroup = ({ className, ...props }) => {
2869
- return /* @__PURE__ */ jsx("div", {
2870
- "data-slot": "message-group",
2871
- className: cn("flex min-w-0 flex-col gap-2", className),
2872
- ...props
2873
- });
2874
- };
2875
- var Message = ({ className, align = "start", ...props }) => {
2876
- return /* @__PURE__ */ jsx("div", {
2877
- "data-slot": "message",
2878
- "data-align": align,
2879
- className: cn("group/message relative flex w-full min-w-0 gap-2 text-sm data-[align=end]:flex-row-reverse", className),
2880
- ...props
2881
- });
2882
- };
2883
- var MessageAvatar = ({ className, ...props }) => {
2884
- return /* @__PURE__ */ jsx("div", {
2885
- "data-slot": "message-avatar",
2886
- className: cn("flex w-fit min-w-8 shrink-0 items-center justify-center self-end overflow-hidden rounded-full bg-muted group-has-data-[slot=message-footer]/message:-translate-y-8", className),
2887
- ...props
2888
- });
2889
- };
2890
- var MessageContent = ({ className, ...props }) => {
2891
- return /* @__PURE__ */ jsx("div", {
2892
- "data-slot": "message-content",
2893
- className: cn("flex w-full min-w-0 flex-col gap-2.5 wrap-break-word group-data-[align=end]/message:*:data-slot:self-end", className),
2894
- ...props
2895
- });
2896
- };
2897
- var MessageHeader = ({ className, ...props }) => {
2898
- return /* @__PURE__ */ jsx("div", {
2899
- "data-slot": "message-header",
2900
- className: cn("flex max-w-full min-w-0 items-center px-3 text-xs font-medium text-muted-foreground group-has-data-[variant=ghost]/message:px-0", className),
2901
- ...props
2902
- });
2903
- };
2904
- var MessageFooter = ({ className, ...props }) => {
2905
- return /* @__PURE__ */ jsx("div", {
2906
- "data-slot": "message-footer",
2907
- className: cn("flex max-w-full min-w-0 items-center px-3 text-xs font-medium text-muted-foreground group-has-data-[variant=ghost]/message:px-0 group-data-[align=end]/message:justify-end", className),
2908
- ...props
2909
- });
2910
- };
2911
- //#endregion
2912
- //#region ../ui/src/components/ui/message-scroller/message-scroller.tsx
2913
- var MessageScrollerProvider = (props) => {
2914
- return /* @__PURE__ */ jsx(MessageScroller.Provider, { ...props });
2915
- };
2916
- var MessageScroller$1 = ({ className, ...props }) => {
2917
- return /* @__PURE__ */ jsx(MessageScroller.Root, {
2918
- "data-slot": "message-scroller",
2919
- className: cn("group/message-scroller relative flex size-full min-h-0 flex-col overflow-hidden", className),
2920
- ...props
2921
- });
2922
- };
2923
- var MessageScrollerViewport = ({ className, ...props }) => {
2924
- return /* @__PURE__ */ jsx(MessageScroller.Viewport, {
2925
- "data-slot": "message-scroller-viewport",
2926
- className: cn("size-full min-h-0 min-w-0 scroll-fade-b scrollbar-thin scrollbar-gutter-stable overflow-y-auto overscroll-contain contain-content data-autoscrolling:scrollbar-thumb-transparent data-autoscrolling:scrollbar-track-transparent data-pending-scroll:invisible", className),
2927
- ...props
2928
- });
2929
- };
2930
- var MessageScrollerContent = ({ className, ...props }) => {
2931
- return /* @__PURE__ */ jsx(MessageScroller.Content, {
2932
- "data-slot": "message-scroller-content",
2933
- className: cn("flex h-max min-h-full flex-col gap-6", className),
2934
- ...props
2935
- });
2936
- };
2937
- var MessageScrollerItem = ({ className, scrollAnchor = false, ...props }) => {
2938
- return /* @__PURE__ */ jsx(MessageScroller.Item, {
2939
- "data-slot": "message-scroller-item",
2940
- scrollAnchor,
2941
- className: cn("min-w-0 shrink-0 [contain-intrinsic-size:auto_10rem] [content-visibility:auto]", className),
2942
- ...props
2943
- });
2944
- };
2945
- var MessageScrollerButton = ({ direction = "end", className, children, render, variant = "secondary", size = "icon-sm", ...props }) => {
2946
- return /* @__PURE__ */ jsx(MessageScroller.Button, {
2947
- "data-slot": "message-scroller-button",
2948
- "data-direction": direction,
2949
- "data-variant": variant,
2950
- "data-size": size,
2951
- direction,
2952
- className: cn("absolute inset-s-1/2 -translate-x-1/2 border-border bg-background text-foreground transition-[translate,scale,opacity] duration-200 motion-reduce:transition-none hover:bg-muted hover:text-foreground data-[active=false]:pointer-events-none data-[active=false]:scale-95 data-[active=false]:opacity-0 data-[active=false]:duration-400 data-[active=false]:ease-[cubic-bezier(0.7,0,0.84,0)] data-[active=true]:translate-y-0 data-[active=true]:scale-100 data-[active=true]:opacity-100 data-[active=true]:ease-[cubic-bezier(0.23,1,0.32,1)] data-[direction=end]:bottom-4 data-[direction=end]:data-[active=false]:translate-y-full data-[direction=start]:top-4 data-[direction=start]:data-[active=false]:-translate-y-full rtl:translate-x-1/2 data-[direction=start]:[&_svg]:rotate-180", className),
2953
- render: render ?? /* @__PURE__ */ jsx(Button$1, {
2954
- variant,
2955
- size
2956
- }),
2957
- ...props,
2958
- children: children ?? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(IconArrowDown, {}), /* @__PURE__ */ jsx("span", {
2959
- className: "sr-only",
2960
- children: direction === "end" ? "Scroll to end" : "Scroll to start"
2961
- })] })
2962
- });
2963
- };
2964
- //#endregion
2965
- //#region ../ui/src/components/ui/native-select/native-select.tsx
2966
- var NativeSelect = ({ className, size = "default", ...props }) => {
2967
- return /* @__PURE__ */ jsxs("div", {
2968
- className: cn("group/native-select relative w-fit has-[select:disabled]:opacity-50", className),
2969
- "data-slot": "native-select-wrapper",
2970
- "data-size": size,
2971
- children: [/* @__PURE__ */ jsx("select", {
2972
- "data-slot": "native-select",
2973
- "data-size": size,
2974
- className: "h-8 w-full min-w-0 appearance-none rounded-lg border border-input bg-transparent py-1 pr-8 pl-2.5 text-sm transition-colors outline-none select-none selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-[size=sm]:py-0.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
2975
- ...props
2976
- }), /* @__PURE__ */ jsx(IconSelector, {
2977
- className: "pointer-events-none absolute top-1/2 right-2.5 size-4 -translate-y-1/2 text-muted-foreground select-none",
2978
- "aria-hidden": "true",
2979
- "data-slot": "native-select-icon"
2980
- })]
2981
- });
2982
- };
2983
- var NativeSelectOption = ({ className, ...props }) => {
2984
- return /* @__PURE__ */ jsx("option", {
2985
- "data-slot": "native-select-option",
2986
- className: cn("bg-[Canvas] text-[CanvasText]", className),
2987
- ...props
2988
- });
2989
- };
2990
- var NativeSelectOptGroup = ({ className, ...props }) => {
2991
- return /* @__PURE__ */ jsx("optgroup", {
2992
- "data-slot": "native-select-optgroup",
2993
- className: cn("bg-[Canvas] text-[CanvasText]", className),
2994
- ...props
2995
- });
2996
- };
2997
- //#endregion
2998
- //#region ../ui/src/components/ui/navigation-menu/navigation-menu.tsx
2999
- var NavigationMenu$1 = ({ align = "start", className, children, ...props }) => {
3000
- return /* @__PURE__ */ jsxs(NavigationMenu.Root, {
3001
- "data-slot": "navigation-menu",
3002
- className: cn("group/navigation-menu relative flex max-w-max flex-1 items-center justify-center", className),
3003
- ...props,
3004
- children: [children, /* @__PURE__ */ jsx(NavigationMenuPositioner, { align })]
3005
- });
3006
- };
3007
- var NavigationMenuList = ({ className, ...props }) => {
3008
- return /* @__PURE__ */ jsx(NavigationMenu.List, {
3009
- "data-slot": "navigation-menu-list",
3010
- className: cn("group flex flex-1 list-none items-center justify-center gap-0", className),
3011
- ...props
3012
- });
3013
- };
3014
- var NavigationMenuItem = ({ className, ...props }) => {
3015
- return /* @__PURE__ */ jsx(NavigationMenu.Item, {
3016
- "data-slot": "navigation-menu-item",
3017
- className: cn("relative", className),
3018
- ...props
3019
- });
3020
- };
3021
- var navigationMenuTriggerStyle = cva("group/navigation-menu-trigger inline-flex h-9 w-max items-center justify-center rounded-lg px-2.5 py-1.5 text-sm font-medium transition-all outline-none motion-reduce:transition-none hover:bg-muted focus:bg-muted focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-popup-open:bg-muted/50 data-popup-open:hover:bg-muted data-open:bg-muted/50 data-open:hover:bg-muted data-open:focus:bg-muted");
3022
- var NavigationMenuTrigger = ({ className, children, ...props }) => {
3023
- return /* @__PURE__ */ jsxs(NavigationMenu.Trigger, {
3024
- "data-slot": "navigation-menu-trigger",
3025
- className: cn(navigationMenuTriggerStyle(), "group", className),
3026
- ...props,
3027
- children: [
3028
- children,
3029
- " ",
3030
- /* @__PURE__ */ jsx(IconChevronDown, {
3031
- className: "relative top-px ml-1 size-3 transition duration-300 motion-reduce:transition-none group-data-popup-open/navigation-menu-trigger:rotate-180 group-data-open/navigation-menu-trigger:rotate-180",
3032
- "aria-hidden": "true"
3033
- })
3034
- ]
3035
- });
3036
- };
3037
- var NavigationMenuContent = ({ className, ...props }) => {
3038
- return /* @__PURE__ */ jsx(NavigationMenu.Content, {
3039
- "data-slot": "navigation-menu-content",
3040
- className: cn("motion-reduce:animate-none motion-reduce:transition-none", "data-ending-style:data-[activation-direction=left]:translate-x-[50%] data-ending-style:data-[activation-direction=right]:translate-x-[-50%] data-starting-style:data-[activation-direction=left]:translate-x-[-50%] data-starting-style:data-[activation-direction=right]:translate-x-[50%] h-full w-auto p-1 transition-[opacity,transform,translate] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] group-data-[viewport=false]/navigation-menu:rounded-lg group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:shadow group-data-[viewport=false]/navigation-menu:ring-1 group-data-[viewport=false]/navigation-menu:ring-foreground/10 group-data-[viewport=false]/navigation-menu:duration-300 data-ending-style:opacity-0 data-starting-style:opacity-0 data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out **:data-[slot=navigation-menu-link]:focus:ring-0 **:data-[slot=navigation-menu-link]:focus:outline-none group-data-[viewport=false]/navigation-menu:data-open:animate-in group-data-[viewport=false]/navigation-menu:data-open:fade-in-0 group-data-[viewport=false]/navigation-menu:data-open:zoom-in-95 group-data-[viewport=false]/navigation-menu:data-closed:animate-out group-data-[viewport=false]/navigation-menu:data-closed:fade-out-0 group-data-[viewport=false]/navigation-menu:data-closed:zoom-out-95", className),
3041
- ...props
3042
- });
3043
- };
3044
- var NavigationMenuPositioner = ({ className, side = "bottom", sideOffset = 8, align = "start", alignOffset = 0, ...props }) => {
3045
- return /* @__PURE__ */ jsx(NavigationMenu.Portal, { children: /* @__PURE__ */ jsx(NavigationMenu.Positioner, {
3046
- side,
3047
- sideOffset,
3048
- align,
3049
- alignOffset,
3050
- className: cn("isolate z-50 h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-[top,left,right,bottom] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] motion-reduce:transition-none data-instant:transition-none data-[side=bottom]:before:top-[-10px] data-[side=bottom]:before:right-0 data-[side=bottom]:before:left-0", className),
3051
- ...props,
3052
- children: /* @__PURE__ */ jsx(NavigationMenu.Popup, {
3053
- className: "data-[ending-style]:easing-[ease] xs:w-(--popup-width) relative h-(--popup-height) w-(--popup-width) origin-(--transform-origin) rounded-lg bg-popover text-popover-foreground shadow ring-1 ring-foreground/10 transition-[opacity,transform,width,height,scale,translate] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] outline-none motion-reduce:transition-none data-ending-style:scale-90 data-ending-style:opacity-0 data-ending-style:duration-150 data-starting-style:scale-90 data-starting-style:opacity-0",
3054
- children: /* @__PURE__ */ jsx(NavigationMenu.Viewport, { className: "relative size-full overflow-hidden" })
3055
- })
3056
- }) });
3057
- };
3058
- var NavigationMenuLink = ({ className, ...props }) => {
3059
- return /* @__PURE__ */ jsx(NavigationMenu.Link, {
3060
- "data-slot": "navigation-menu-link",
3061
- className: cn("flex items-center gap-2 rounded-lg p-2 text-sm transition-all outline-none motion-reduce:transition-none hover:bg-muted focus:bg-muted focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:outline-1 in-data-[slot=navigation-menu-content]:rounded-md data-active:bg-muted/50 data-active:hover:bg-muted data-active:focus:bg-muted [&_svg:not([class*='size-'])]:size-4", className),
3062
- ...props
3063
- });
3064
- };
3065
- var NavigationMenuIndicator = ({ className, ...props }) => {
3066
- return /* @__PURE__ */ jsx(NavigationMenu.Icon, {
3067
- "data-slot": "navigation-menu-indicator",
3068
- className: cn("motion-reduce:animate-none", "top-full z-1 flex h-1.5 items-end justify-center overflow-hidden data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:animate-in data-[state=visible]:fade-in", className),
3069
- ...props,
3070
- children: /* @__PURE__ */ jsx("div", { className: "relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md" })
3071
- });
3072
- };
3073
- //#endregion
3074
- //#region ../ui/src/components/ui/pagination/pagination.tsx
3075
- /**
3076
- * Compute the ordered list of page numbers and ellipsis markers to render.
3077
- * First and last pages are always included. `siblingCount` controls how many
3078
- * page numbers appear on each side of the current page.
3079
- */
3080
- var getPaginationRange = (page, count, siblingCount = 1) => {
3081
- if (count <= 0) return [];
3082
- const currentPage = Math.min(Math.max(page, 1), count);
3083
- if (count <= 2 * siblingCount + 5) return Array.from({ length: count }, (_, i) => i + 1);
3084
- const leftSiblingStart = Math.max(currentPage - siblingCount, 2);
3085
- const rightSiblingEnd = Math.min(currentPage + siblingCount, count - 1);
3086
- const showLeftEllipsis = leftSiblingStart > 2;
3087
- const showRightEllipsis = rightSiblingEnd < count - 1;
3088
- const range = [1];
3089
- if (showLeftEllipsis) range.push("ellipsis");
3090
- else for (let i = 2; i < leftSiblingStart; i++) range.push(i);
3091
- for (let i = leftSiblingStart; i <= rightSiblingEnd; i++) range.push(i);
3092
- if (showRightEllipsis) range.push("ellipsis");
3093
- else for (let i = rightSiblingEnd + 1; i < count; i++) range.push(i);
3094
- range.push(count);
3095
- return range;
3096
- };
3097
- /** Clamp a page number to the valid [1, count] range (count <= 0 yields 1). */
3098
- var clampPage = (page, count) => Math.min(Math.max(page, 1), Math.max(count, 1));
3099
- var Pagination = ({ page, count, onPageChange, siblingCount = 1, className }) => {
3100
- const currentPage = clampPage(page, count);
3101
- const range = getPaginationRange(currentPage, count, siblingCount);
3102
- let ellipsisCount = 0;
3103
- const handlePrev = () => {
3104
- if (currentPage > 1) onPageChange(currentPage - 1);
3105
- };
3106
- const handleNext = () => {
3107
- if (currentPage < count) onPageChange(currentPage + 1);
3108
- };
3109
- return /* @__PURE__ */ jsx("nav", {
3110
- "aria-label": "pagination",
3111
- className: cn("mx-auto flex w-full justify-center", className),
3112
- children: /* @__PURE__ */ jsxs("ul", {
3113
- className: "flex flex-row items-center gap-1",
3114
- children: [
3115
- /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx("button", {
3116
- type: "button",
3117
- "aria-label": "Go to previous page",
3118
- disabled: currentPage <= 1,
3119
- onClick: handlePrev,
3120
- className: cn(buttonVariants({
3121
- variant: "ghost",
3122
- size: "icon"
3123
- }), "size-8"),
3124
- children: /* @__PURE__ */ jsx(IconChevronLeft, { size: 16 })
3125
- }) }),
3126
- range.map((item) => {
3127
- if (item === "ellipsis") {
3128
- ellipsisCount += 1;
3129
- const ellipsisKey = `ellipsis-${ellipsisCount}`;
3130
- return /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx("span", {
3131
- "aria-hidden": "true",
3132
- className: cn(buttonVariants({
3133
- variant: "ghost",
3134
- size: "icon"
3135
- }), "size-8 cursor-default pointer-events-none"),
3136
- children: /* @__PURE__ */ jsx(IconDots, { size: 16 })
3137
- }) }, ellipsisKey);
3138
- }
3139
- const isActive = item === currentPage;
3140
- return /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx("button", {
3141
- type: "button",
3142
- "aria-label": `Go to page ${item}`,
3143
- "aria-current": isActive ? "page" : void 0,
3144
- onClick: () => {
3145
- if (!isActive) onPageChange(item);
3146
- },
3147
- className: cn(buttonVariants({
3148
- variant: isActive ? "outline" : "ghost",
3149
- size: "icon"
3150
- }), "size-8", isActive && "pointer-events-none font-semibold"),
3151
- children: item
3152
- }) }, item);
3153
- }),
3154
- /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx("button", {
3155
- type: "button",
3156
- "aria-label": "Go to next page",
3157
- disabled: currentPage >= count,
3158
- onClick: handleNext,
3159
- className: cn(buttonVariants({
3160
- variant: "ghost",
3161
- size: "icon"
3162
- }), "size-8"),
3163
- children: /* @__PURE__ */ jsx(IconChevronRight, { size: 16 })
3164
- }) })
3165
- ]
3166
- })
3167
- });
3168
- };
3169
- //#endregion
3170
- //#region ../ui/src/components/ui/popover/popover.tsx
3171
- var Popover$1 = ({ ...props }) => {
3172
- return /* @__PURE__ */ jsx(Popover.Root, {
3173
- "data-slot": "popover",
3174
- ...props
3175
- });
3176
- };
3177
- var PopoverTrigger = ({ ...props }) => {
3178
- return /* @__PURE__ */ jsx(Popover.Trigger, {
3179
- "data-slot": "popover-trigger",
3180
- ...props
3181
- });
3182
- };
3183
- var PopoverContent = ({ className, align = "center", alignOffset = 0, side = "bottom", sideOffset = 4, ...props }) => {
3184
- return /* @__PURE__ */ jsx(Popover.Portal, { children: /* @__PURE__ */ jsx(Popover.Positioner, {
3185
- align,
3186
- alignOffset,
3187
- side,
3188
- sideOffset,
3189
- className: "isolate z-50",
3190
- children: /* @__PURE__ */ jsx(Popover.Popup, {
3191
- "data-slot": "popover-content",
3192
- className: cn("z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 motion-reduce:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
3193
- ...props
3194
- })
3195
- }) });
3196
- };
3197
- var PopoverHeader = ({ className, ...props }) => {
3198
- return /* @__PURE__ */ jsx("div", {
3199
- "data-slot": "popover-header",
3200
- className: cn("flex flex-col gap-0.5 text-sm", className),
3201
- ...props
3202
- });
3203
- };
3204
- var PopoverTitle = ({ className, ...props }) => {
3205
- return /* @__PURE__ */ jsx(Popover.Title, {
3206
- "data-slot": "popover-title",
3207
- className: cn("font-medium", className),
3208
- ...props
3209
- });
3210
- };
3211
- var PopoverDescription = ({ className, ...props }) => {
3212
- return /* @__PURE__ */ jsx(Popover.Description, {
3213
- "data-slot": "popover-description",
3214
- className: cn("text-muted-foreground", className),
3215
- ...props
3216
- });
3217
- };
3218
- //#endregion
3219
- //#region ../ui/src/components/ui/progress/progress.tsx
3220
- var Progress$1 = ({ value = null, className, ...props }) => {
3221
- return /* @__PURE__ */ jsx(Progress.Root, {
3222
- "data-slot": "progress",
3223
- value: value ?? null,
3224
- className: cn("w-full", className),
3225
- ...props,
3226
- children: /* @__PURE__ */ jsx(Progress.Track, {
3227
- "data-slot": "progress-track",
3228
- className: "relative h-2 w-full overflow-hidden rounded-full bg-primary/20",
3229
- children: /* @__PURE__ */ jsx(Progress.Indicator, {
3230
- "data-slot": "progress-indicator",
3231
- className: "h-full rounded-full bg-primary transition-[width] duration-300 ease-in-out motion-reduce:transition-none motion-reduce:animate-none data-indeterminate:w-1/3 data-indeterminate:animate-[progress-indeterminate_1.5s_ease-in-out_infinite]",
3232
- style: value != null ? { width: `${value}%` } : void 0
3233
- })
3234
- })
3235
- });
3236
- };
3237
- //#endregion
3238
- //#region ../ui/src/components/ui/questionnaire/questionnaire.tsx
3239
- var Questionnaire$1 = ({ className, ...props }) => {
3240
- return /* @__PURE__ */ jsx(Questionnaire.Root, {
3241
- "data-slot": "questionnaire",
3242
- className: cn("flex w-full min-w-0 flex-col gap-4", className),
3243
- ...props
3244
- });
3245
- };
3246
- var QuestionnaireProgress = ({ className, ...props }) => {
3247
- return /* @__PURE__ */ jsx(Questionnaire.Progress, {
3248
- "data-slot": "questionnaire-progress",
3249
- className: cn("min-h-[1lh] w-fit min-w-[14ch] text-xs font-medium text-muted-foreground tabular-nums", className),
3250
- ...props
3251
- });
3252
- };
3253
- var QuestionnaireItem = ({ className, ...props }) => {
3254
- return /* @__PURE__ */ jsx(Questionnaire.Item, {
3255
- "data-slot": "questionnaire-item",
3256
- className: cn("flex min-w-0 flex-col gap-4 border-0 p-0 outline-none", className),
3257
- ...props
3258
- });
3259
- };
3260
- var QuestionnaireTitle = ({ className, ...props }) => {
3261
- return /* @__PURE__ */ jsx(Questionnaire.Title, {
3262
- "data-slot": "questionnaire-title",
3263
- className: cn("font-heading text-base leading-snug font-medium text-pretty [&:not(:has(~[data-slot=questionnaire-description]))]:mb-4", className),
3264
- ...props
3265
- });
3266
- };
3267
- var QuestionnaireDescription = ({ className, ...props }) => {
3268
- return /* @__PURE__ */ jsx(Questionnaire.Description, {
3269
- "data-slot": "questionnaire-description",
3270
- className: cn("text-sm text-pretty text-muted-foreground", className),
3271
- ...props
3272
- });
3273
- };
3274
- var QuestionnaireChoices = ({ className, ...props }) => {
3275
- return /* @__PURE__ */ jsx(Questionnaire.Choices, {
3276
- "data-slot": "questionnaire-choices",
3277
- className: cn("group/questionnaire-choices grid min-w-0 gap-2", className),
3278
- ...props
3279
- });
3280
- };
3281
- var QuestionnaireChoice = ({ children, className, ...props }) => {
3282
- return /* @__PURE__ */ jsxs(Questionnaire.Choice, {
3283
- "data-slot": "questionnaire-choice",
3284
- className: cn("group/questionnaire-choice relative flex min-h-11 cursor-pointer items-start gap-2.5 rounded-lg border border-input bg-transparent px-3 py-2.5 text-start text-sm transition-colors outline-none select-none hover:bg-muted/50 has-[>input:focus-visible]:border-ring has-[>input:focus-visible]:ring-3 has-[>input:focus-visible]:ring-ring/50 data-invalid:border-destructive dark:bg-input/20 data-checked:border-primary/40 data-checked:bg-muted dark:data-checked:bg-muted", "data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:opacity-50", className),
3285
- ...props,
3286
- children: [
3287
- /* @__PURE__ */ jsx(Questionnaire.ChoiceInput, {
3288
- "data-slot": "questionnaire-choice-input",
3289
- className: "absolute inset-0 z-10 size-full cursor-pointer opacity-0"
3290
- }),
3291
- /* @__PURE__ */ jsxs("span", {
3292
- "aria-hidden": "true",
3293
- "data-slot": "questionnaire-choice-indicator",
3294
- className: "pointer-events-none relative flex size-4 shrink-0 translate-y-[--spacing(0.45)] items-center justify-center rounded-[4px] border border-input group-has-data-[slot=questionnaire-choice-description]/questionnaire-choice:translate-y-0.5 group-data-[type=radio]/questionnaire-choice:rounded-full group-data-checked/questionnaire-choice:border-primary group-data-checked/questionnaire-choice:bg-primary group-data-checked/questionnaire-choice:text-primary-foreground dark:bg-input/30 dark:group-data-checked/questionnaire-choice:bg-primary",
3295
- children: [/* @__PURE__ */ jsx("span", {
3296
- "data-slot": "questionnaire-choice-indicator-dot",
3297
- className: "hidden size-2 rounded-full bg-primary-foreground group-data-[type=checkbox]/questionnaire-choice:hidden group-data-checked/questionnaire-choice:block"
3298
- }), /* @__PURE__ */ jsx(IconCheck, {
3299
- "data-slot": "questionnaire-choice-indicator-check",
3300
- className: "hidden size-3.5 group-data-[type=radio]/questionnaire-choice:hidden group-data-checked/questionnaire-choice:block"
3301
- })]
3302
- }),
3303
- /* @__PURE__ */ jsx(Questionnaire.ChoiceLabel, {
3304
- "data-slot": "questionnaire-choice-label",
3305
- className: "flex min-w-0 flex-1 flex-col gap-0.5 leading-snug",
3306
- children
3307
- }),
3308
- /* @__PURE__ */ jsx(Questionnaire.ChoiceShortcut, {
3309
- "data-slot": "questionnaire-choice-shortcut",
3310
- className: "pointer-events-none ms-auto hidden size-5 shrink-0 translate-y-[--spacing(0.45)] items-center justify-center rounded-md border border-input bg-background font-mono text-[0.625rem] leading-none font-medium text-muted-foreground group-has-data-[slot=questionnaire-choice-description]/questionnaire-choice:translate-y-0.5 group-data-[shortcut]/questionnaire-choice:inline-flex"
3311
- })
3312
- ]
3313
- });
3314
- };
3315
- var QuestionnaireChoiceDescription = ({ className, ...props }) => {
3316
- return /* @__PURE__ */ jsx("span", {
3317
- "data-slot": "questionnaire-choice-description",
3318
- className: cn("text-muted-foreground", className),
3319
- ...props
3320
- });
3321
- };
3322
- var QuestionnaireInput = ({ className, ...props }) => {
3323
- return /* @__PURE__ */ jsx("div", {
3324
- "data-slot": "questionnaire-input-wrapper",
3325
- className: "group/questionnaire-input relative w-full min-w-0",
3326
- children: /* @__PURE__ */ jsx(Questionnaire.Input, {
3327
- "data-slot": "questionnaire-input",
3328
- className: cn("h-8 min-h-11 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-[color,box-shadow,background-color] outline-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 sm:min-h-0 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", "selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground", className),
3329
- ...props
3330
- })
3331
- });
3332
- };
3333
- var QuestionnaireError = ({ className, ...props }) => {
3334
- return /* @__PURE__ */ jsx(Questionnaire.Error, {
3335
- "data-slot": "questionnaire-error",
3336
- className: cn("mt-2 text-sm text-destructive", className),
3337
- ...props
3338
- });
3339
- };
3340
- var QuestionnaireActions = ({ className, ...props }) => {
3341
- return /* @__PURE__ */ jsx("div", {
3342
- "data-slot": "questionnaire-actions",
3343
- className: cn("grid min-h-11 w-full grid-cols-[minmax(0,1fr)_auto_auto] items-center gap-2 sm:min-h-8", className),
3344
- ...props
3345
- });
3346
- };
3347
- var QuestionnairePrevious = ({ children, className, size = "default", variant = "outline", ...props }) => {
3348
- return /* @__PURE__ */ jsx(Questionnaire.Previous, {
3349
- "data-slot": "questionnaire-previous",
3350
- "data-size": size,
3351
- "data-variant": variant,
3352
- className: cn(buttonVariants({
3353
- size,
3354
- variant
3355
- }), "col-start-1 row-start-1 min-h-11 justify-self-start sm:min-h-0", className),
3356
- ...props,
3357
- children: children ?? "Previous"
3358
- });
3359
- };
3360
- var QuestionnaireSkip = ({ children, className, size = "default", variant = "outline", ...props }) => {
3361
- return /* @__PURE__ */ jsx(Questionnaire.Skip, {
3362
- "data-slot": "questionnaire-skip",
3363
- "data-size": size,
3364
- "data-variant": variant,
3365
- className: cn(buttonVariants({
3366
- size,
3367
- variant
3368
- }), "col-start-2 row-start-1 min-h-11 justify-self-end sm:min-h-0", className),
3369
- ...props,
3370
- children: children ?? "Skip"
3371
- });
3372
- };
3373
- var QuestionnaireNext = ({ children, className, size = "default", variant = "default", ...props }) => {
3374
- return /* @__PURE__ */ jsx(Questionnaire.Next, {
3375
- "data-slot": "questionnaire-next",
3376
- "data-size": size,
3377
- "data-variant": variant,
3378
- className: cn(buttonVariants({
3379
- size,
3380
- variant
3381
- }), "col-start-3 row-start-1 min-h-11 justify-self-end sm:min-h-0", className),
3382
- ...props,
3383
- children: children ?? "Next"
3384
- });
3385
- };
3386
- var QuestionnaireSubmit = ({ children, className, size = "default", variant = "default", ...props }) => {
3387
- return /* @__PURE__ */ jsx(Questionnaire.Submit, {
3388
- "data-slot": "questionnaire-submit",
3389
- "data-size": size,
3390
- "data-variant": variant,
3391
- className: cn(buttonVariants({
3392
- size,
3393
- variant
3394
- }), "col-start-3 row-start-1 min-h-11 justify-self-end sm:min-h-0", className),
3395
- ...props,
3396
- children: children ?? "Submit"
3397
- });
3398
- };
3399
- //#endregion
3400
- //#region ../ui/src/components/ui/radio-group/radio-group.tsx
3401
- var RadioGroup$1 = ({ className, orientation = "vertical", ...props }) => {
3402
- return /* @__PURE__ */ jsx(RadioGroup, {
3403
- "data-slot": "radio-group",
3404
- "data-orientation": orientation,
3405
- "aria-orientation": orientation,
3406
- className: cn("grid w-full gap-2 data-[orientation=horizontal]:flex data-[orientation=horizontal]:items-center", className),
3407
- ...props
3408
- });
3409
- };
3410
- var RadioGroupItem = ({ className, ...props }) => {
3411
- return /* @__PURE__ */ jsx(Radio.Root, {
3412
- "data-slot": "radio-group-item",
3413
- className: cn("peer relative flex size-4 shrink-0 items-center justify-center rounded-full border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:bg-input/30 dark:aria-invalid:ring-destructive/40", className),
3414
- ...props,
3415
- children: /* @__PURE__ */ jsx(Radio.Indicator, {
3416
- "data-slot": "radio-group-item-indicator",
3417
- className: "flex size-2 shrink-0 rounded-full bg-primary transition-none"
3418
- })
3419
- });
3420
- };
3421
- //#endregion
3422
- //#region ../ui/src/components/ui/resizable/resizable.tsx
3423
- var ResizablePanelGroup = ({ className, ...props }) => {
3424
- return /* @__PURE__ */ jsx(ResizablePrimitive.Group, {
3425
- "data-slot": "resizable-panel-group",
3426
- className: cn("flex h-full w-full aria-[orientation=vertical]:flex-col", className),
3427
- ...props
3428
- });
3429
- };
3430
- var ResizablePanel = ({ ...props }) => {
3431
- return /* @__PURE__ */ jsx(ResizablePrimitive.Panel, {
3432
- "data-slot": "resizable-panel",
3433
- ...props
3434
- });
3435
- };
3436
- var ResizableHandle = ({ withHandle, className, ...props }) => {
3437
- return /* @__PURE__ */ jsx(ResizablePrimitive.Separator, {
3438
- "data-slot": "resizable-handle",
3439
- className: cn("relative flex w-px items-center justify-center bg-border ring-offset-background after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-hidden aria-[orientation=horizontal]:h-px aria-[orientation=horizontal]:w-full aria-[orientation=horizontal]:after:left-0 aria-[orientation=horizontal]:after:h-1 aria-[orientation=horizontal]:after:w-full aria-[orientation=horizontal]:after:translate-x-0 aria-[orientation=horizontal]:after:-translate-y-1/2 [&[aria-orientation=horizontal]>div]:rotate-90", className),
3440
- ...props,
3441
- children: withHandle && /* @__PURE__ */ jsx("div", { className: "z-10 flex h-6 w-1 shrink-0 rounded-lg bg-border" })
3442
- });
3443
- };
3444
- //#endregion
3445
- //#region ../ui/src/components/ui/select/select.tsx
3446
- var Select$1 = ({ ...props }) => {
3447
- return /* @__PURE__ */ jsx(Select.Root, {
3448
- "data-slot": "select",
3449
- ...props
3450
- });
3451
- };
3452
- var SelectTrigger = ({ className, size = "default", children, ...props }) => {
3453
- return /* @__PURE__ */ jsxs(Select.Trigger, {
3454
- "data-slot": "select-trigger",
3455
- className: cn("flex w-full cursor-pointer items-center justify-between gap-2 rounded-lg border border-input bg-transparent text-sm text-foreground transition-colors outline-none", "focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50", "disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50", "aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20", "data-popup-open:border-ring data-popup-open:ring-3 data-popup-open:ring-ring/50", "dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", size === "sm" ? "h-7 px-2.5 text-[0.8rem]" : "h-8 px-2.5", className),
3456
- ...props,
3457
- children: [children, /* @__PURE__ */ jsx(Select.Icon, {
3458
- "data-slot": "select-icon",
3459
- className: "shrink-0 text-muted-foreground",
3460
- children: /* @__PURE__ */ jsx(IconChevronDown, { className: "size-4" })
3461
- })]
3462
- });
3463
- };
3464
- var SelectValue = ({ className, ...props }) => {
3465
- return /* @__PURE__ */ jsx(Select.Value, {
3466
- "data-slot": "select-value",
3467
- className: cn("truncate data-placeholder:text-muted-foreground", className),
3468
- ...props
3469
- });
3470
- };
3471
- var SelectContent = ({ className, children, portalContainer, ...props }) => {
3472
- return /* @__PURE__ */ jsx(Select.Portal, {
3473
- container: portalContainer,
3474
- children: /* @__PURE__ */ jsx(Select.Positioner, {
3475
- "data-slot": "select-positioner",
3476
- sideOffset: 4,
3477
- alignItemWithTrigger: false,
3478
- children: /* @__PURE__ */ jsx(Select.Popup, {
3479
- "data-slot": "select-content",
3480
- className: cn("z-50 min-w-[var(--anchor-width)] overflow-hidden rounded-xl border border-border bg-popover p-1 text-popover-foreground shadow-md outline-none", "origin-[var(--transform-origin)]", "transition-[transform,scale,opacity] motion-reduce:animate-none motion-reduce:transition-none data-open:scale-100 data-open:opacity-100 data-closed:scale-95 data-closed:opacity-0 data-open:animate-in data-closed:animate-out data-open:fade-in-0 data-closed:fade-out-0", className),
3481
- ...props,
3482
- children: /* @__PURE__ */ jsx(ScrollArea$1, {
3483
- type: "always",
3484
- fade: true,
3485
- fadeFrom: "popover",
3486
- className: "max-h-(--available-height)",
3487
- children: /* @__PURE__ */ jsx(Select.List, {
3488
- "data-slot": "select-list",
3489
- children
3490
- })
3491
- })
3492
- })
3493
- })
3494
- });
3495
- };
3496
- var SelectGroup = ({ className, ...props }) => {
3497
- return /* @__PURE__ */ jsx(Select.Group, {
3498
- "data-slot": "select-group",
3499
- className: cn("flex flex-col gap-0.5", className),
3500
- ...props
3501
- });
3502
- };
3503
- var SelectLabel = ({ className, ...props }) => {
3504
- return /* @__PURE__ */ jsx(Select.GroupLabel, {
3505
- "data-slot": "select-label",
3506
- className: cn("px-2 py-1 text-xs font-semibold text-muted-foreground", className),
3507
- ...props
3508
- });
3509
- };
3510
- var SelectItem = ({ className, children, ...props }) => {
3511
- return /* @__PURE__ */ jsxs(Select.Item, {
3512
- "data-slot": "select-item",
3513
- className: cn("relative flex cursor-default items-center gap-2 rounded-lg py-1.5 pr-2 pl-8 text-sm text-foreground outline-none select-none", "transition-colors", "data-highlighted:bg-accent data-highlighted:text-accent-foreground", "data-[selected]:font-medium", "data-disabled:pointer-events-none data-disabled:opacity-50", className),
3514
- ...props,
3515
- children: [/* @__PURE__ */ jsx(Select.ItemIndicator, {
3516
- "data-slot": "select-item-indicator",
3517
- className: "absolute left-2 flex size-4 items-center justify-center text-foreground",
3518
- children: /* @__PURE__ */ jsx(IconCheck, { className: "size-3.5" })
3519
- }), /* @__PURE__ */ jsx(Select.ItemText, {
3520
- "data-slot": "select-item-text",
3521
- children
3522
- })]
3523
- });
3524
- };
3525
- var SelectSeparator = ({ className, ...props }) => {
3526
- return /* @__PURE__ */ jsx("div", {
3527
- "data-slot": "select-separator",
3528
- className: cn("-mx-1 my-1 h-px bg-border", className),
3529
- "aria-hidden": "true",
3530
- ...props
3531
- });
3532
- };
3533
- //#endregion
3534
- //#region ../ui/src/components/ui/sheet/sheet.tsx
3535
- var Sheet = ({ ...props }) => {
3536
- return /* @__PURE__ */ jsx(Dialog.Root, {
3537
- "data-slot": "sheet",
3538
- ...props
3539
- });
3540
- };
3541
- var SheetTrigger = ({ ...props }) => {
3542
- return /* @__PURE__ */ jsx(Dialog.Trigger, {
3543
- "data-slot": "sheet-trigger",
3544
- ...props
3545
- });
3546
- };
3547
- var SheetClose = ({ ...props }) => {
3548
- return /* @__PURE__ */ jsx(Dialog.Close, {
3549
- "data-slot": "sheet-close",
3550
- ...props
3551
- });
3552
- };
3553
- var SheetPortal = ({ ...props }) => {
3554
- return /* @__PURE__ */ jsx(Dialog.Portal, {
3555
- "data-slot": "sheet-portal",
3556
- ...props
3557
- });
3558
- };
3559
- var SheetOverlay = ({ className, ...props }) => {
3560
- return /* @__PURE__ */ jsx(Dialog.Backdrop, {
3561
- "data-slot": "sheet-overlay",
3562
- className: cn("fixed inset-0 z-50 bg-overlay transition-opacity duration-150 motion-reduce:transition-none data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs", className),
3563
- ...props
3564
- });
3565
- };
3566
- var SheetContent = ({ className, children, side = "right", showCloseButton = true, ...props }) => {
3567
- return /* @__PURE__ */ jsxs(SheetPortal, { children: [/* @__PURE__ */ jsx(SheetOverlay, {}), /* @__PURE__ */ jsxs(Dialog.Popup, {
3568
- "data-slot": "sheet-content",
3569
- "data-side": side,
3570
- className: cn("fixed z-50 flex flex-col gap-4 bg-popover bg-clip-padding text-sm text-popover-foreground shadow-lg transition duration-200 motion-reduce:transition-none ease-in-out data-ending-style:opacity-0 data-starting-style:opacity-0 data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=bottom]:data-ending-style:translate-y-[2.5rem] data-[side=bottom]:data-starting-style:translate-y-[2.5rem] data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=left]:data-ending-style:translate-x-[-2.5rem] data-[side=left]:data-starting-style:translate-x-[-2.5rem] data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=right]:data-ending-style:translate-x-[2.5rem] data-[side=right]:data-starting-style:translate-x-[2.5rem] data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=top]:data-ending-style:translate-y-[-2.5rem] data-[side=top]:data-starting-style:translate-y-[-2.5rem] data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm", className),
3571
- ...props,
3572
- children: [children, showCloseButton && /* @__PURE__ */ jsxs(Dialog.Close, {
3573
- "data-slot": "sheet-close",
3574
- render: /* @__PURE__ */ jsx(Button$1, {
3575
- variant: "ghost",
3576
- className: "absolute top-3 right-3",
3577
- size: "icon-sm"
3578
- }),
3579
- children: [/* @__PURE__ */ jsx(IconX, {}), /* @__PURE__ */ jsx("span", {
3580
- className: "sr-only",
3581
- children: "Close"
3582
- })]
3583
- })]
3584
- })] });
3585
- };
3586
- var SheetHeader = ({ className, ...props }) => {
3587
- return /* @__PURE__ */ jsx("div", {
3588
- "data-slot": "sheet-header",
3589
- className: cn("flex flex-col gap-0.5 p-4", className),
3590
- ...props
3591
- });
3592
- };
3593
- var SheetFooter = ({ className, ...props }) => {
3594
- return /* @__PURE__ */ jsx("div", {
3595
- "data-slot": "sheet-footer",
3596
- className: cn("mt-auto flex flex-col gap-2 p-4", className),
3597
- ...props
3598
- });
3599
- };
3600
- var SheetTitle = ({ className, ...props }) => {
3601
- return /* @__PURE__ */ jsx(Dialog.Title, {
3602
- "data-slot": "sheet-title",
3603
- className: cn("font-heading text-base font-medium text-foreground", className),
3604
- ...props
3605
- });
3606
- };
3607
- var SheetDescription = ({ className, ...props }) => {
3608
- return /* @__PURE__ */ jsx(Dialog.Description, {
3609
- "data-slot": "sheet-description",
3610
- className: cn("text-sm text-muted-foreground", className),
3611
- ...props
3612
- });
3613
- };
3614
- //#endregion
3615
- //#region ../ui/src/hooks/use-mobile.ts
3616
- var MOBILE_BREAKPOINT = 768;
3617
- var useIsMobile = () => {
3618
- const [isMobile, setIsMobile] = React.useState(void 0);
3619
- React.useEffect(() => {
3620
- const mql = window.matchMedia(`(max-width: 767px)`);
3621
- const onChange = () => {
3622
- setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
3623
- };
3624
- mql.addEventListener("change", onChange);
3625
- setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
3626
- return () => mql.removeEventListener("change", onChange);
3627
- }, []);
3628
- return !!isMobile;
3629
- };
3630
- //#endregion
3631
- //#region ../ui/src/components/ui/skeleton/skeleton.tsx
3632
- var Skeleton = ({ className, ...props }) => {
3633
- return /* @__PURE__ */ jsx("div", {
3634
- "data-slot": "skeleton",
3635
- className: cn("animate-pulse rounded-md bg-muted motion-reduce:animate-none", className),
3636
- ...props
3637
- });
3638
- };
3639
- //#endregion
3640
- //#region ../ui/src/components/ui/tooltip/tooltip.tsx
3641
- var TooltipProvider = ({ delay = 0, ...props }) => {
3642
- return /* @__PURE__ */ jsx(Tooltip.Provider, {
3643
- "data-slot": "tooltip-provider",
3644
- delay,
3645
- ...props
3646
- });
3647
- };
3648
- var Tooltip$1 = ({ ...props }) => {
3649
- return /* @__PURE__ */ jsx(Tooltip.Root, {
3650
- "data-slot": "tooltip",
3651
- ...props
3652
- });
3653
- };
3654
- var TooltipTrigger = ({ ...props }) => {
3655
- return /* @__PURE__ */ jsx(Tooltip.Trigger, {
3656
- "data-slot": "tooltip-trigger",
3657
- ...props
3658
- });
3659
- };
3660
- var TooltipContent = ({ className, side = "top", sideOffset = 4, align = "center", alignOffset = 0, children, ...props }) => {
3661
- return /* @__PURE__ */ jsx(Tooltip.Portal, { children: /* @__PURE__ */ jsx(Tooltip.Positioner, {
3662
- align,
3663
- alignOffset,
3664
- side,
3665
- sideOffset,
3666
- className: "isolate z-50",
3667
- children: /* @__PURE__ */ jsxs(Tooltip.Popup, {
3668
- "data-slot": "tooltip-content",
3669
- className: cn("z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", "motion-reduce:animate-none", className),
3670
- ...props,
3671
- children: [children, /* @__PURE__ */ jsx(Tooltip.Arrow, { className: "z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground data-[side=bottom]:top-1 data-[side=inline-end]:top-1/2! data-[side=inline-end]:-left-1 data-[side=inline-end]:-translate-y-1/2 data-[side=inline-start]:top-1/2! data-[side=inline-start]:-right-1 data-[side=inline-start]:-translate-y-1/2 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5" })]
3672
- })
3673
- }) });
3674
- };
3675
- //#endregion
3676
- //#region ../ui/src/components/ui/sidebar/sidebar.tsx
3677
- var SIDEBAR_COOKIE_NAME = "sidebar_state";
3678
- var SIDEBAR_COOKIE_MAX_AGE = 604800;
3679
- var SIDEBAR_WIDTH = "16rem";
3680
- var SIDEBAR_WIDTH_MOBILE = "18rem";
3681
- var SIDEBAR_WIDTH_ICON = "3rem";
3682
- var SIDEBAR_KEYBOARD_SHORTCUT = "b";
3683
- var SidebarContext = React.createContext(null);
3684
- var useSidebar = () => {
3685
- const context = React.useContext(SidebarContext);
3686
- if (!context) throw new Error("useSidebar must be used within a SidebarProvider.");
3687
- return context;
3688
- };
3689
- var SidebarProvider = ({ defaultOpen = true, open: openProp, onOpenChange: setOpenProp, className, style, children, ...props }) => {
3690
- const isMobile = useIsMobile();
3691
- const [openMobile, setOpenMobile] = React.useState(false);
3692
- const [_open, _setOpen] = React.useState(defaultOpen);
3693
- const open = openProp ?? _open;
3694
- const setOpen = React.useCallback((value) => {
3695
- const openState = typeof value === "function" ? value(open) : value;
3696
- if (setOpenProp) setOpenProp(openState);
3697
- else _setOpen(openState);
3698
- document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;
3699
- }, [setOpenProp, open]);
3700
- const toggleSidebar = React.useCallback(() => {
3701
- return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);
3702
- }, [isMobile, setOpen]);
3703
- React.useEffect(() => {
3704
- const handleKeyDown = (event) => {
3705
- if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
3706
- event.preventDefault();
3707
- toggleSidebar();
3708
- }
3709
- };
3710
- window.addEventListener("keydown", handleKeyDown);
3711
- return () => window.removeEventListener("keydown", handleKeyDown);
3712
- }, [toggleSidebar]);
3713
- const state = open ? "expanded" : "collapsed";
3714
- const contextValue = React.useMemo(() => ({
3715
- state,
3716
- open,
3717
- setOpen,
3718
- isMobile,
3719
- openMobile,
3720
- setOpenMobile,
3721
- toggleSidebar
3722
- }), [
3723
- state,
3724
- open,
3725
- setOpen,
3726
- isMobile,
3727
- openMobile,
3728
- toggleSidebar
3729
- ]);
3730
- return /* @__PURE__ */ jsx(SidebarContext.Provider, {
3731
- value: contextValue,
3732
- children: /* @__PURE__ */ jsx("div", {
3733
- "data-slot": "sidebar-wrapper",
3734
- style: {
3735
- "--sidebar-width": SIDEBAR_WIDTH,
3736
- "--sidebar-width-icon": SIDEBAR_WIDTH_ICON,
3737
- ...style
3738
- },
3739
- className: cn("group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-sidebar", className),
3740
- ...props,
3741
- children
3742
- })
3743
- });
3744
- };
3745
- var Sidebar = ({ side = "left", variant = "sidebar", collapsible = "offcanvas", className, children, dir, ...props }) => {
3746
- const { isMobile, state, openMobile, setOpenMobile } = useSidebar();
3747
- if (collapsible === "none") return /* @__PURE__ */ jsx("div", {
3748
- "data-slot": "sidebar",
3749
- className: cn("flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground", className),
3750
- ...props,
3751
- children
3752
- });
3753
- if (isMobile) return /* @__PURE__ */ jsx(Sheet, {
3754
- open: openMobile,
3755
- onOpenChange: setOpenMobile,
3756
- ...props,
3757
- children: /* @__PURE__ */ jsxs(SheetContent, {
3758
- dir,
3759
- "data-sidebar": "sidebar",
3760
- "data-slot": "sidebar",
3761
- "data-mobile": "true",
3762
- className: "w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",
3763
- style: { "--sidebar-width": SIDEBAR_WIDTH_MOBILE },
3764
- side,
3765
- children: [/* @__PURE__ */ jsxs(SheetHeader, {
3766
- className: "sr-only",
3767
- children: [/* @__PURE__ */ jsx(SheetTitle, { children: "Sidebar" }), /* @__PURE__ */ jsx(SheetDescription, { children: "Displays the mobile sidebar." })]
3768
- }), /* @__PURE__ */ jsx("div", {
3769
- className: "flex h-full w-full flex-col",
3770
- children
3771
- })]
3772
- })
3773
- });
3774
- return /* @__PURE__ */ jsxs("div", {
3775
- className: "group peer hidden text-sidebar-foreground md:block",
3776
- "data-state": state,
3777
- "data-collapsible": state === "collapsed" ? collapsible : "",
3778
- "data-variant": variant,
3779
- "data-side": side,
3780
- "data-slot": "sidebar",
3781
- children: [/* @__PURE__ */ jsx("div", {
3782
- "data-slot": "sidebar-gap",
3783
- className: cn("relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 motion-reduce:transition-none ease-linear", "group-data-[collapsible=offcanvas]:w-0", "group-data-[side=right]:rotate-180", variant === "floating" || variant === "inset" ? "group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon)")
3784
- }), /* @__PURE__ */ jsx("div", {
3785
- "data-slot": "sidebar-container",
3786
- "data-side": side,
3787
- className: cn("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 motion-reduce:transition-none ease-linear data-[side=left]:left-0 data-[side=left]:group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)] data-[side=right]:right-0 data-[side=right]:group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)] md:flex", variant === "floating" || variant === "inset" ? "p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l", className),
3788
- ...props,
3789
- children: /* @__PURE__ */ jsx("div", {
3790
- "data-sidebar": "sidebar",
3791
- "data-slot": "sidebar-inner",
3792
- className: "flex size-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1 group-data-[variant=floating]:ring-sidebar-border",
3793
- children
3794
- })
3795
- })]
3796
- });
3797
- };
3798
- var SidebarTrigger = ({ className, onClick, ...props }) => {
3799
- const { toggleSidebar } = useSidebar();
3800
- return /* @__PURE__ */ jsxs(Button$1, {
3801
- "data-sidebar": "trigger",
3802
- "data-slot": "sidebar-trigger",
3803
- variant: "ghost",
3804
- size: "icon-sm",
3805
- className: cn(className),
3806
- onClick: (event) => {
3807
- onClick?.(event);
3808
- toggleSidebar();
3809
- },
3810
- ...props,
3811
- children: [/* @__PURE__ */ jsx(IconLayoutSidebar, {}), /* @__PURE__ */ jsx("span", {
3812
- className: "sr-only",
3813
- children: "Toggle Sidebar"
3814
- })]
3815
- });
3816
- };
3817
- var SidebarRail = ({ className, ...props }) => {
3818
- const { toggleSidebar } = useSidebar();
3819
- return /* @__PURE__ */ jsx("button", {
3820
- "data-sidebar": "rail",
3821
- "data-slot": "sidebar-rail",
3822
- "aria-label": "Toggle Sidebar",
3823
- tabIndex: -1,
3824
- onClick: toggleSidebar,
3825
- title: "Toggle Sidebar",
3826
- className: cn("absolute inset-y-0 z-20 hidden w-4 transition-all motion-reduce:transition-none ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:start-1/2 after:w-[2px] hover:after:bg-sidebar-border sm:flex ltr:-translate-x-1/2 rtl:-translate-x-1/2", "in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize", "[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize", "group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full hover:group-data-[collapsible=offcanvas]:bg-sidebar", "[[data-side=left][data-collapsible=offcanvas]_&]:-right-2", "[[data-side=right][data-collapsible=offcanvas]_&]:-left-2", className),
3827
- ...props
3828
- });
3829
- };
3830
- var SidebarInset = ({ className, ...props }) => {
3831
- return /* @__PURE__ */ jsx("main", {
3832
- "data-slot": "sidebar-inset",
3833
- className: cn("relative flex w-full flex-1 flex-col bg-background md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2", className),
3834
- ...props
3835
- });
3836
- };
3837
- var SidebarInput = ({ className, ...props }) => {
3838
- return /* @__PURE__ */ jsx(Input$1, {
3839
- "data-slot": "sidebar-input",
3840
- "data-sidebar": "input",
3841
- className: cn("h-8 w-full bg-background shadow-none", className),
3842
- ...props
3843
- });
3844
- };
3845
- var SidebarHeader = ({ className, ...props }) => {
3846
- return /* @__PURE__ */ jsx("div", {
3847
- "data-slot": "sidebar-header",
3848
- "data-sidebar": "header",
3849
- className: cn("flex flex-col gap-2 p-2", className),
3850
- ...props
3851
- });
3852
- };
3853
- var SidebarFooter = ({ className, ...props }) => {
3854
- return /* @__PURE__ */ jsx("div", {
3855
- "data-slot": "sidebar-footer",
3856
- "data-sidebar": "footer",
3857
- className: cn("flex flex-col gap-2 p-2", className),
3858
- ...props
3859
- });
3860
- };
3861
- var SidebarSeparator = ({ className, ...props }) => {
3862
- return /* @__PURE__ */ jsx(Separator$1, {
3863
- "data-slot": "sidebar-separator",
3864
- "data-sidebar": "separator",
3865
- className: cn("mx-2 w-auto bg-sidebar-border", className),
3866
- ...props
3867
- });
3868
- };
3869
- var SidebarContent = ({ className, ...props }) => {
3870
- return /* @__PURE__ */ jsx("div", {
3871
- "data-slot": "sidebar-content",
3872
- "data-sidebar": "content",
3873
- className: cn("no-scrollbar flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden", className),
3874
- ...props
3875
- });
3876
- };
3877
- var SidebarGroup = ({ className, ...props }) => {
3878
- return /* @__PURE__ */ jsx("div", {
3879
- "data-slot": "sidebar-group",
3880
- "data-sidebar": "group",
3881
- className: cn("relative flex w-full min-w-0 flex-col p-2", className),
3882
- ...props
3883
- });
3884
- };
3885
- var SidebarGroupLabel = ({ className, render, ...props }) => {
3886
- return useRender({
3887
- defaultTagName: "div",
3888
- props: mergeProps({ className: cn("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 ring-sidebar-ring outline-hidden transition-[margin,opacity] duration-200 motion-reduce:transition-none ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0", className) }, props),
3889
- render,
3890
- state: {
3891
- slot: "sidebar-group-label",
3892
- sidebar: "group-label"
3893
- }
3894
- });
3895
- };
3896
- var SidebarGroupAction = ({ className, render, ...props }) => {
3897
- return useRender({
3898
- defaultTagName: "button",
3899
- props: mergeProps({ className: cn("absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground ring-sidebar-ring outline-hidden transition-transform motion-reduce:transition-none group-data-[collapsible=icon]:hidden after:absolute after:-inset-2 hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 md:after:hidden [&>svg]:size-4 [&>svg]:shrink-0", className) }, props),
3900
- render,
3901
- state: {
3902
- slot: "sidebar-group-action",
3903
- sidebar: "group-action"
3904
- }
3905
- });
3906
- };
3907
- var SidebarGroupContent = ({ className, ...props }) => {
3908
- return /* @__PURE__ */ jsx("div", {
3909
- "data-slot": "sidebar-group-content",
3910
- "data-sidebar": "group-content",
3911
- className: cn("w-full text-sm", className),
3912
- ...props
3913
- });
3914
- };
3915
- var SidebarMenu = ({ className, ...props }) => {
3916
- return /* @__PURE__ */ jsx("ul", {
3917
- "data-slot": "sidebar-menu",
3918
- "data-sidebar": "menu",
3919
- className: cn("flex w-full min-w-0 flex-col gap-0", className),
3920
- ...props
3921
- });
3922
- };
3923
- var SidebarMenuItem = ({ className, ...props }) => {
3924
- return /* @__PURE__ */ jsx("li", {
3925
- "data-slot": "sidebar-menu-item",
3926
- "data-sidebar": "menu-item",
3927
- className: cn("group/menu-item relative", className),
3928
- ...props
3929
- });
3930
- };
3931
- var sidebarMenuButtonVariants = cva("peer/menu-button group/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm ring-sidebar-ring outline-hidden transition-[width,height,padding] motion-reduce:transition-none group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:font-medium data-active:text-sidebar-accent-foreground [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate", {
3932
- variants: {
3933
- variant: {
3934
- default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
3935
- outline: "bg-background shadow-[0_0_0_1px_var(--sidebar-border)] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_var(--sidebar-accent)]"
3936
- },
3937
- size: {
3938
- default: "h-8 text-sm",
3939
- sm: "h-7 text-xs",
3940
- lg: "h-12 text-sm group-data-[collapsible=icon]:p-0!"
3941
- }
3942
- },
3943
- defaultVariants: {
3944
- variant: "default",
3945
- size: "default"
3946
- }
3947
- });
3948
- var SidebarMenuButton = ({ render, isActive = false, variant = "default", size = "default", tooltip, className, ...props }) => {
3949
- const { isMobile, state } = useSidebar();
3950
- const comp = useRender({
3951
- defaultTagName: "button",
3952
- props: mergeProps({ className: cn(sidebarMenuButtonVariants({
3953
- variant,
3954
- size
3955
- }), className) }, props),
3956
- render: !tooltip ? render : /* @__PURE__ */ jsx(TooltipTrigger, { render }),
3957
- state: {
3958
- slot: "sidebar-menu-button",
3959
- sidebar: "menu-button",
3960
- size,
3961
- active: isActive
3962
- }
3963
- });
3964
- if (!tooltip) return comp;
3965
- if (typeof tooltip === "string") tooltip = { children: tooltip };
3966
- return /* @__PURE__ */ jsxs(Tooltip$1, { children: [comp, /* @__PURE__ */ jsx(TooltipContent, {
3967
- side: "right",
3968
- align: "center",
3969
- hidden: state !== "collapsed" || isMobile,
3970
- ...tooltip
3971
- })] });
3972
- };
3973
- var SidebarMenuAction = ({ className, render, showOnHover = false, ...props }) => {
3974
- return useRender({
3975
- defaultTagName: "button",
3976
- props: mergeProps({ className: cn("absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground ring-sidebar-ring outline-hidden transition-transform motion-reduce:transition-none group-data-[collapsible=icon]:hidden peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[size=default]/menu-button:top-1.5 peer-data-[size=lg]/menu-button:top-2.5 peer-data-[size=sm]/menu-button:top-1 after:absolute after:-inset-2 hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 md:after:hidden [&>svg]:size-4 [&>svg]:shrink-0", showOnHover && "group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 peer-data-active/menu-button:text-sidebar-accent-foreground aria-expanded:opacity-100 md:opacity-0", className) }, props),
3977
- render,
3978
- state: {
3979
- slot: "sidebar-menu-action",
3980
- sidebar: "menu-action"
3981
- }
3982
- });
3983
- };
3984
- var SidebarMenuBadge = ({ className, ...props }) => {
3985
- return /* @__PURE__ */ jsx("div", {
3986
- "data-slot": "sidebar-menu-badge",
3987
- "data-sidebar": "menu-badge",
3988
- className: cn("pointer-events-none absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium text-sidebar-foreground tabular-nums select-none group-data-[collapsible=icon]:hidden peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[size=default]/menu-button:top-1.5 peer-data-[size=lg]/menu-button:top-2.5 peer-data-[size=sm]/menu-button:top-1 peer-data-active/menu-button:text-sidebar-accent-foreground", className),
3989
- ...props
3990
- });
3991
- };
3992
- var SidebarMenuSkeleton = ({ className, showIcon = false, ...props }) => {
3993
- const [width] = React.useState(() => {
3994
- return `${Math.floor(Math.random() * 40) + 50}%`;
3995
- });
3996
- return /* @__PURE__ */ jsxs("div", {
3997
- "data-slot": "sidebar-menu-skeleton",
3998
- "data-sidebar": "menu-skeleton",
3999
- className: cn("flex h-8 items-center gap-2 rounded-md px-2", className),
4000
- ...props,
4001
- children: [showIcon && /* @__PURE__ */ jsx(Skeleton, {
4002
- className: "size-4 rounded-md",
4003
- "data-sidebar": "menu-skeleton-icon"
4004
- }), /* @__PURE__ */ jsx(Skeleton, {
4005
- className: "h-4 max-w-(--skeleton-width) flex-1",
4006
- "data-sidebar": "menu-skeleton-text",
4007
- style: { "--skeleton-width": width }
4008
- })]
4009
- });
4010
- };
4011
- var SidebarMenuSub = ({ className, ...props }) => {
4012
- return /* @__PURE__ */ jsx("ul", {
4013
- "data-slot": "sidebar-menu-sub",
4014
- "data-sidebar": "menu-sub",
4015
- className: cn("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5 group-data-[collapsible=icon]:hidden", className),
4016
- ...props
4017
- });
4018
- };
4019
- var SidebarMenuSubItem = ({ className, ...props }) => {
4020
- return /* @__PURE__ */ jsx("li", {
4021
- "data-slot": "sidebar-menu-sub-item",
4022
- "data-sidebar": "menu-sub-item",
4023
- className: cn("group/menu-sub-item relative", className),
4024
- ...props
4025
- });
4026
- };
4027
- var SidebarMenuSubButton = ({ render, size = "md", isActive = false, className, ...props }) => {
4028
- return useRender({
4029
- defaultTagName: "a",
4030
- props: mergeProps({ className: cn("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground ring-sidebar-ring outline-hidden group-data-[collapsible=icon]:hidden hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[size=md]:text-sm data-[size=sm]:text-xs data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground", className) }, props),
4031
- render,
4032
- state: {
4033
- slot: "sidebar-menu-sub-button",
4034
- sidebar: "menu-sub-button",
4035
- size,
4036
- active: isActive
4037
- }
4038
- });
4039
- };
4040
- //#endregion
4041
- //#region ../ui/src/components/ui/spinner/spinner.tsx
4042
- var spinnerVariants = cva("animate-spin motion-reduce:animate-none", {
4043
- variants: { size: {
4044
- xs: "size-3",
4045
- sm: "size-4",
4046
- default: "size-5",
4047
- lg: "size-6",
4048
- xl: "size-8"
4049
- } },
4050
- defaultVariants: { size: "default" }
4051
- });
4052
- var Spinner = ({ className, size = "default", ...props }) => {
4053
- return /* @__PURE__ */ jsx(IconLoader, {
4054
- "data-slot": "spinner",
4055
- role: "status",
4056
- "aria-label": "Loading",
4057
- className: cn(spinnerVariants({ size }), className),
4058
- ...props
4059
- });
4060
- };
4061
- //#endregion
4062
- //#region ../ui/src/components/ui/switch/switch.tsx
4063
- var Switch$1 = ({ className, size = "default", ...props }) => {
4064
- return /* @__PURE__ */ jsx(Switch.Root, {
4065
- "data-slot": "switch",
4066
- "data-size": size,
4067
- className: cn("peer group/switch relative inline-flex shrink-0 items-center rounded-full border border-transparent transition-all motion-reduce:transition-none outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-[size=default]:h-4.5 data-[size=default]:w-8 data-[size=sm]:h-3.5 data-[size=sm]:w-6 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:bg-primary data-unchecked:bg-input dark:data-unchecked:bg-input/80 data-disabled:cursor-not-allowed data-disabled:opacity-50", className),
4068
- ...props,
4069
- children: /* @__PURE__ */ jsx(Switch.Thumb, {
4070
- "data-slot": "switch-thumb",
4071
- className: "pointer-events-none block rounded-full bg-background ring-0 transition-transform motion-reduce:transition-none group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=sm]/switch:data-checked:translate-x-[calc(100%-2px)] dark:data-checked:bg-primary-foreground group-data-[size=default]/switch:data-unchecked:translate-x-0 group-data-[size=sm]/switch:data-unchecked:translate-x-0 dark:data-unchecked:bg-foreground"
4072
- })
4073
- });
4074
- };
4075
- //#endregion
4076
- //#region ../ui/src/components/ui/table/table.tsx
4077
- var Table = ({ className, ...props }) => {
4078
- return /* @__PURE__ */ jsx("div", {
4079
- "data-slot": "table-container",
4080
- className: "relative w-full overflow-x-auto",
4081
- children: /* @__PURE__ */ jsx("table", {
4082
- "data-slot": "table",
4083
- className: cn("w-full caption-bottom text-sm", className),
4084
- ...props
4085
- })
4086
- });
4087
- };
4088
- var TableHeader = ({ className, ...props }) => {
4089
- return /* @__PURE__ */ jsx("thead", {
4090
- "data-slot": "table-header",
4091
- className: cn("[&_tr]:border-b", className),
4092
- ...props
4093
- });
4094
- };
4095
- var TableBody = ({ className, ...props }) => {
4096
- return /* @__PURE__ */ jsx("tbody", {
4097
- "data-slot": "table-body",
4098
- className: cn("[&_tr:last-child]:border-0", className),
4099
- ...props
4100
- });
4101
- };
4102
- var TableFooter = ({ className, ...props }) => {
4103
- return /* @__PURE__ */ jsx("tfoot", {
4104
- "data-slot": "table-footer",
4105
- className: cn("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0", className),
4106
- ...props
4107
- });
4108
- };
4109
- var TableRow = ({ className, ...props }) => {
4110
- return /* @__PURE__ */ jsx("tr", {
4111
- "data-slot": "table-row",
4112
- className: cn("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted", className),
4113
- ...props
4114
- });
4115
- };
4116
- var TableHead = ({ className, ...props }) => {
4117
- return /* @__PURE__ */ jsx("th", {
4118
- "data-slot": "table-head",
4119
- className: cn("h-10 px-2 text-left align-middle font-medium whitespace-nowrap text-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]", className),
4120
- ...props
4121
- });
4122
- };
4123
- var TableCell = ({ className, ...props }) => {
4124
- return /* @__PURE__ */ jsx("td", {
4125
- "data-slot": "table-cell",
4126
- className: cn("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]", className),
4127
- ...props
4128
- });
4129
- };
4130
- var TableCaption = ({ className, ...props }) => {
4131
- return /* @__PURE__ */ jsx("caption", {
4132
- "data-slot": "table-caption",
4133
- className: cn("mt-4 text-sm text-muted-foreground", className),
4134
- ...props
4135
- });
4136
- };
4137
- //#endregion
4138
- //#region ../ui/src/components/ui/tabs/tabs.tsx
4139
- var Tabs$1 = ({ value, defaultValue, onValueChange, className, orientation = "horizontal", children }) => /* @__PURE__ */ jsx(Tabs.Root, {
4140
- "data-slot": "tabs",
4141
- "data-orientation": orientation,
4142
- value,
4143
- defaultValue,
4144
- orientation,
4145
- onValueChange: (next) => {
4146
- onValueChange?.(String(next));
4147
- },
4148
- className: cn("group/tabs flex w-full gap-2 data-[orientation=horizontal]:flex-col", className),
4149
- children
4150
- });
4151
- var tabsListVariants = cva("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-[orientation=horizontal]/tabs:h-8 group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col data-[variant=line]:rounded-none", {
4152
- variants: { variant: {
4153
- default: "bg-muted",
4154
- line: "gap-1 bg-transparent"
4155
- } },
4156
- defaultVariants: { variant: "default" }
4157
- });
4158
- var TabsList = ({ className, variant = "default", children }) => /* @__PURE__ */ jsx(Tabs.List, {
4159
- "data-slot": "tabs-list",
4160
- "data-variant": variant,
4161
- className: cn(tabsListVariants({ variant }), className),
4162
- children
4163
- });
4164
- var TabsTrigger = ({ value, disabled, className, children }) => /* @__PURE__ */ jsx(Tabs.Tab, {
4165
- value,
4166
- disabled,
4167
- className: cn("relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium whitespace-nowrap text-foreground/60 transition-all group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start hover:text-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 dark:text-muted-foreground dark:hover:text-foreground group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*=\"size-\"])]:size-4", "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent", "data-active:bg-background data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 dark:data-active:text-foreground", "after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-right-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100", className),
4168
- children
4169
- });
4170
- var TabsContent = ({ value, keepMounted = false, className, children }) => /* @__PURE__ */ jsx(Tabs.Panel, {
4171
- value,
4172
- keepMounted,
4173
- className: cn("flex-1 text-sm outline-none", className),
4174
- children
4175
- });
4176
- //#endregion
4177
- //#region ../ui/src/components/ui/toast/toast.tsx
4178
- var toast = Toast.createToastManager();
4179
- var ToastProvider = ({ ...props }) => {
4180
- return /* @__PURE__ */ jsx(Toast.Provider, { ...props });
4181
- };
4182
- var ToastPortal = ({ ...props }) => {
4183
- return /* @__PURE__ */ jsx(Toast.Portal, {
4184
- "data-slot": "toast-portal",
4185
- ...props
4186
- });
4187
- };
4188
- var ToastViewport = ({ className, ...props }) => {
4189
- return /* @__PURE__ */ jsx(Toast.Viewport, {
4190
- "data-slot": "toast-viewport",
4191
- className: cn("pointer-events-none fixed inset-x-4 bottom-4 z-50 mx-auto w-auto max-w-sm outline-none sm:right-4 sm:left-auto sm:mx-0 sm:w-full", className),
4192
- ...props
4193
- });
4194
- };
4195
- var Toast$1 = ({ className, ...props }) => {
4196
- return /* @__PURE__ */ jsx(Toast.Root, {
4197
- "data-slot": "toast",
4198
- className: cn("group/toast pointer-events-auto absolute right-0 bottom-0 z-[calc(1000-var(--toast-index))] w-full origin-bottom rounded-2xl border bg-popover text-popover-foreground shadow-lg will-change-transform outline-none select-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50", "[--gap:0.75rem] [--height:var(--toast-frontmost-height,var(--toast-height))] [--offset-y:calc(var(--toast-offset-y)*-1+calc(var(--toast-index)*var(--gap)*-1)+var(--toast-swipe-movement-y))] [--peek:0.75rem] [--scale:calc(max(0,1-(var(--toast-index)*0.1)))] [--shrink:calc(1-var(--scale))]", "h-(--height) [transform:translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)-(var(--toast-index)*var(--peek))-(var(--shrink)*var(--height))))_scale(var(--scale))] [transition:transform_500ms_cubic-bezier(0.22,1,0.36,1),opacity_500ms,height_150ms] motion-reduce:transition-none", "after:absolute after:top-full after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:content-['']", "data-expanded:h-(--toast-height) data-expanded:[transform:translateX(var(--toast-swipe-movement-x))_translateY(var(--offset-y))]", "data-limited:opacity-0 data-starting-style:[transform:translateY(150%)]", "[&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:[transform:translateY(150%)]", "data-ending-style:data-[swipe-direction=down]:[transform:translateY(calc(var(--toast-swipe-movement-y)+150%))]", "data-ending-style:data-[swipe-direction=left]:[transform:translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))]", "data-ending-style:data-[swipe-direction=right]:[transform:translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))]", "data-ending-style:data-[swipe-direction=up]:[transform:translateY(calc(var(--toast-swipe-movement-y)-150%))]", "data-expanded:data-ending-style:data-[swipe-direction=down]:[transform:translateY(calc(var(--toast-swipe-movement-y)+150%))]", "data-expanded:data-ending-style:data-[swipe-direction=left]:[transform:translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))]", "data-expanded:data-ending-style:data-[swipe-direction=right]:[transform:translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))]", "data-expanded:data-ending-style:data-[swipe-direction=up]:[transform:translateY(calc(var(--toast-swipe-movement-y)-150%))]", className),
4199
- ...props
4200
- });
4201
- };
4202
- var ToastContent = ({ className, ...props }) => {
4203
- return /* @__PURE__ */ jsx(Toast.Content, {
4204
- "data-slot": "toast-content",
4205
- className: cn("flex h-full items-center gap-3 overflow-hidden p-4 transition-opacity duration-250 ease-[cubic-bezier(0.22,1,0.36,1)] motion-reduce:transition-none data-behind:opacity-0 data-expanded:opacity-100", className),
4206
- ...props
4207
- });
4208
- };
4209
- var ToastTitle = ({ className, ...props }) => {
4210
- return /* @__PURE__ */ jsx(Toast.Title, {
4211
- "data-slot": "toast-title",
4212
- className: cn("text-sm font-medium", className),
4213
- ...props
4214
- });
4215
- };
4216
- var ToastDescription = ({ className, ...props }) => {
4217
- return /* @__PURE__ */ jsx(Toast.Description, {
4218
- "data-slot": "toast-description",
4219
- className: cn("text-sm text-muted-foreground", className),
4220
- ...props
4221
- });
4222
- };
4223
- var ToastAction = ({ className, render = /* @__PURE__ */ jsx(Button$1, {
4224
- variant: "outline",
4225
- size: "sm"
4226
- }), ...props }) => {
4227
- return /* @__PURE__ */ jsx(Toast.Action, {
4228
- "data-slot": "toast-action",
4229
- render,
4230
- className: cn("shrink-0", className),
4231
- ...props
4232
- });
4233
- };
4234
- var ToastClose = ({ className, children, render = /* @__PURE__ */ jsx(Button$1, {
4235
- variant: "ghost",
4236
- size: "icon-sm"
4237
- }), ...props }) => {
4238
- return /* @__PURE__ */ jsx(Toast.Close, {
4239
- "data-slot": "toast-close",
4240
- "aria-label": "Close toast",
4241
- render,
4242
- className: cn("relative shrink-0 text-muted-foreground after:absolute after:-inset-2 after:content-[''] hover:text-foreground", className),
4243
- ...props,
4244
- children: children ?? /* @__PURE__ */ jsx(IconX, { "aria-hidden": "true" })
4245
- });
4246
- };
4247
- var ToastIcon = ({ type }) => {
4248
- let icon = null;
4249
- if (type === "success") icon = /* @__PURE__ */ jsx(IconCircleCheck, { "aria-hidden": "true" });
4250
- if (type === "info") icon = /* @__PURE__ */ jsx(IconInfoCircle, { "aria-hidden": "true" });
4251
- if (type === "warning") icon = /* @__PURE__ */ jsx(IconAlertTriangle, { "aria-hidden": "true" });
4252
- if (type === "error") icon = /* @__PURE__ */ jsx(IconAlertOctagon, {
4253
- className: "text-destructive",
4254
- "aria-hidden": "true"
4255
- });
4256
- if (type === "loading") icon = /* @__PURE__ */ jsx(IconLoader, {
4257
- className: "animate-spin motion-reduce:animate-none",
4258
- "aria-hidden": "true"
4259
- });
4260
- if (!icon) return null;
4261
- return /* @__PURE__ */ jsx("span", {
4262
- "data-slot": "toast-icon",
4263
- className: "shrink-0 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
4264
- children: icon
4265
- });
4266
- };
4267
- var ToastList = () => {
4268
- const { toasts } = Toast.useToastManager();
4269
- return toasts.map((toastItem) => /* @__PURE__ */ jsx(Toast$1, {
4270
- toast: toastItem,
4271
- children: /* @__PURE__ */ jsxs(ToastContent, { children: [
4272
- /* @__PURE__ */ jsx(ToastIcon, { type: toastItem.type }),
4273
- /* @__PURE__ */ jsxs("div", {
4274
- className: "flex min-w-0 flex-1 flex-col gap-1",
4275
- children: [/* @__PURE__ */ jsx(ToastTitle, {}), /* @__PURE__ */ jsx(ToastDescription, {})]
4276
- }),
4277
- /* @__PURE__ */ jsx(ToastAction, {}),
4278
- /* @__PURE__ */ jsx(ToastClose, {})
4279
- ] })
4280
- }, toastItem.id));
4281
- };
4282
- var Toaster = ({ children, toastManager = toast, ...props }) => {
4283
- return /* @__PURE__ */ jsxs(ToastProvider, {
4284
- toastManager,
4285
- ...props,
4286
- children: [children, /* @__PURE__ */ jsx(ToastPortal, { children: /* @__PURE__ */ jsx(ToastViewport, { children: /* @__PURE__ */ jsx(ToastList, {}) }) })]
4287
- });
4288
- };
4289
- var createToastManager = Toast.createToastManager;
4290
- var useToastManager = Toast.useToastManager;
4291
- //#endregion
4292
- //#region ../ui/src/components/ui/toggle/toggle.tsx
4293
- var toggleVariants = cva("inline-flex shrink-0 cursor-pointer items-center justify-center gap-1.5 rounded-lg border border-transparent text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 data-pressed:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*=\"size-\"])]:size-4", {
4294
- variants: {
4295
- variant: {
4296
- default: "bg-transparent hover:bg-muted hover:text-foreground data-pressed:bg-muted",
4297
- outline: "border-border bg-background hover:bg-muted hover:text-foreground data-pressed:bg-muted dark:border-input dark:bg-input/30 dark:hover:bg-input/50"
4298
- },
4299
- size: {
4300
- sm: "h-7 px-2.5 text-[0.8rem]",
4301
- default: "h-8 px-2.5",
4302
- lg: "h-9 px-3"
4303
- }
4304
- },
4305
- defaultVariants: {
4306
- variant: "default",
4307
- size: "default"
4308
- }
4309
- });
4310
- var Toggle$1 = ({ className, variant = "default", size = "default", ...props }) => {
4311
- return /* @__PURE__ */ jsx(Toggle, {
4312
- "data-slot": "toggle",
4313
- className: cn(toggleVariants({
4314
- variant,
4315
- size,
4316
- className
4317
- })),
4318
- ...props
4319
- });
4320
- };
4321
- //#endregion
4322
- //#region ../ui/src/components/ui/toggle-group/toggle-group.tsx
4323
- var ToggleGroupContext = createContext({
4324
- variant: "default",
4325
- size: "default",
4326
- spacing: 2,
4327
- orientation: "horizontal"
4328
- });
4329
- var ToggleGroup$1 = ({ className, variant = "default", size = "default", spacing = 2, orientation = "horizontal", children, ...props }) => {
4330
- return /* @__PURE__ */ jsx(ToggleGroupContext.Provider, {
4331
- value: {
4332
- variant,
4333
- size,
4334
- spacing,
4335
- orientation
4336
- },
4337
- children: /* @__PURE__ */ jsx(ToggleGroup, {
4338
- "data-slot": "toggle-group",
4339
- "data-variant": variant,
4340
- "data-size": size,
4341
- "data-spacing": spacing,
4342
- "data-orientation": orientation,
4343
- orientation,
4344
- "aria-orientation": void 0,
4345
- style: { gap: `calc(var(--spacing) * ${spacing})` },
4346
- className: cn("group/toggle-group flex w-fit flex-row items-center rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-[orientation=vertical]:flex-col data-[orientation=vertical]:items-stretch", className),
4347
- ...props,
4348
- children
4349
- })
4350
- });
4351
- };
4352
- var ToggleGroupItem = ({ className, variant, size, ...props }) => {
4353
- const ctx = useContext(ToggleGroupContext);
4354
- const resolvedVariant = variant ?? ctx.variant ?? "default";
4355
- const resolvedSize = size ?? ctx.size ?? "default";
4356
- return /* @__PURE__ */ jsx(Toggle, {
4357
- "data-slot": "toggle-group-item",
4358
- "data-variant": resolvedVariant,
4359
- "data-size": resolvedSize,
4360
- "data-spacing": ctx.spacing,
4361
- className: cn("shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-[orientation=horizontal]/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-[orientation=vertical]/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-[orientation=horizontal]/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-[orientation=vertical]/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-[orientation=horizontal]/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-[orientation=vertical]/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-[orientation=horizontal]/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-[orientation=vertical]/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t", toggleVariants({
4362
- variant: resolvedVariant,
4363
- size: resolvedSize
4364
- }), className),
4365
- ...props
4366
- });
4367
- };
4368
- //#endregion
4369
- export { SidebarProvider as $, AlertDialogAction as $a, ChartContainer as $i, ItemActions as $n, ContextMenu$1 as $r, Pagination as $t, TableRow as A, BreadcrumbLink as Aa, Input$1 as Ai, MenubarCheckboxItem as An, DropdownMenuContent as Ar, RadioGroupItem as At, SidebarGroupLabel as B, AvatarGroupCount as Ba, DialogTrigger as Bi, MenubarShortcut as Bn, DropdownMenuSubContent as Br, QuestionnaireNext as Bt, Table as C, Bubble as Ca, InputGroup as Ci, Message as Cn, Button$1 as Co, EmptyContent as Cr, SelectSeparator as Ct, TableFooter as D, Breadcrumb as Da, InputGroupText as Di, MessageGroup as Dn, EmptyTitle as Dr, ResizablePanel as Dt, TableCell as E, BubbleReactions as Ea, InputGroupInput as Ei, MessageFooter as En, EmptyMedia as Er, ResizableHandle as Et, SidebarContent as F, badgeVariants as Fa, DialogFooter as Fi, MenubarMenu as Fn, DropdownMenuRadioGroup as Fr, QuestionnaireChoices as Ft, SidebarMenuAction as G, AttachmentContent as Ga, ComboboxItem as Gi, Marker as Gn, DrawerContent as Gr, QuestionnaireTitle as Gt, SidebarInput as H, Attachment as Ha, ComboboxContent as Hi, MenubarSubContent as Hn, DropdownMenuTrigger as Hr, QuestionnaireProgress as Ht, SidebarFooter as I, Avatar$1 as Ia, DialogHeader as Ii, MenubarPortal as In, DropdownMenuRadioItem as Ir, QuestionnaireDescription as It, SidebarMenuItem as J, AttachmentMedia as Ja, useMergedRefs as Ji, markerVariants as Jn, DrawerHeader as Jr, PopoverContent as Jt, SidebarMenuBadge as K, AttachmentDescription as Ka, ScrollArea$1 as Ki, MarkerContent as Kn, DrawerDescription as Kr, Progress$1 as Kt, SidebarGroup as L, AvatarBadge as La, DialogOverlay as Li, MenubarRadioGroup as Ln, DropdownMenuSeparator as Lr, QuestionnaireError as Lt, Spinner as M, BreadcrumbPage as Ma, DialogClose as Mi, MenubarGroup as Mn, DropdownMenuItem as Mr, QuestionnaireActions as Mt, spinnerVariants as N, BreadcrumbSeparator as Na, DialogContent as Ni, MenubarItem as Nn, DropdownMenuLabel as Nr, QuestionnaireChoice as Nt, TableHead as O, BreadcrumbEllipsis as Oa, InputGroupTextarea as Oi, MessageHeader as On, DropdownMenu as Or, ResizablePanelGroup as Ot, Sidebar as P, Badge as Pa, DialogDescription as Pi, MenubarLabel as Pn, DropdownMenuPortal as Pr, QuestionnaireChoiceDescription as Pt, SidebarMenuSubItem as Q, AlertDialog$1 as Qa, Checkbox$1 as Qi, Item as Qn, useDirection as Qr, PopoverTrigger as Qt, SidebarGroupAction as R, AvatarFallback as Ra, DialogPortal as Ri, MenubarRadioItem as Rn, DropdownMenuShortcut as Rr, QuestionnaireInput as Rt, tabsListVariants as S, ButtonGroupText as Sa, CommandShortcut as Si, useMessageScrollerVisibility as Sn, Slider$1 as So, Empty as Sr, SelectLabel as St, TableCaption as T, BubbleGroup as Ta, InputGroupButton as Ti, MessageContent as Tn, cn as To, EmptyHeader as Tr, SelectValue as Tt, SidebarInset as U, AttachmentAction as Ua, ComboboxEmpty as Ui, MenubarSubTrigger as Un, Drawer as Ur, QuestionnaireSkip as Ut, SidebarHeader as V, AvatarImage as Va, Combobox$1 as Vi, MenubarSub as Vn, DropdownMenuSubTrigger as Vr, QuestionnairePrevious as Vt, SidebarMenu as W, AttachmentActions as Wa, ComboboxInput as Wi, MenubarTrigger as Wn, DrawerClose as Wr, QuestionnaireSubmit as Wt, SidebarMenuSub as X, AttachmentTrigger as Xa, CollapsibleContent as Xi, Kbd as Xn, DrawerTrigger as Xr, PopoverHeader as Xt, SidebarMenuSkeleton as Y, AttachmentTitle as Ya, Collapsible$1 as Yi, Label as Yn, DrawerTitle as Yr, PopoverDescription as Yt, SidebarMenuSubButton as Z, AspectRatio as Za, CollapsibleTrigger as Zi, KbdGroup as Zn, DirectionProvider as Zr, PopoverTitle as Zt, useToastManager as _, CardTitle as _a, CommandGroup as _i, MessageScrollerItem as _n, AccordionTrigger as _o, HoverCardTrigger as _r, SheetTrigger as _t, Toast$1 as a, Carousel as aa, ContextMenuPortal as ai, NavigationMenuItem as an, AlertDialogMedia as ao, ItemMedia as ar, TooltipContent as at, TabsList as b, ButtonGroup as ba, CommandList as bi, useMessageScroller as bn, formatMediaTime as bo, FieldError as br, SelectGroup as bt, ToastContent as c, CarouselNext as ca, ContextMenuSeparator as ci, NavigationMenuPositioner as cn, AlertDialogTitle as co, Separator$1 as cr, Skeleton as ct, ToastProvider as d, Card as da, ContextMenuSubContent as di, NativeSelect as dn, AlertAction as do, InputOTPSeparator as dr, SheetClose as dt, ChartLegend as ea, ContextMenuCheckboxItem as ei, clampPage as en, AlertDialogCancel as eo, ItemContent as er, SidebarRail as et, ToastTitle as f, CardAction as fa, ContextMenuSubTrigger as fi, NativeSelectOptGroup as fn, AlertDescription as fo, InputOTPSlot as fr, SheetContent as ft, toast as g, CardHeader as ga, CommandEmpty as gi, MessageScrollerContent as gn, AccordionItem as go, HoverCardContent as gr, SheetTitle as gt, createToastManager as h, CardFooter as ha, CommandDialog as hi, MessageScrollerButton as hn, AccordionContent as ho, HoverCard as hr, SheetHeader as ht, toggleVariants as i, ChartTooltipContent as ia, ContextMenuLabel as ii, NavigationMenuIndicator as in, AlertDialogHeader as io, ItemHeader as ir, Tooltip$1 as it, Switch$1 as j, BreadcrumbList as ja, Dialog$1 as ji, MenubarContent as jn, DropdownMenuGroup as jr, Questionnaire$1 as jt, TableHeader as k, BreadcrumbItem as ka, Textarea as ki, Menubar$1 as kn, DropdownMenuCheckboxItem as kr, RadioGroup$1 as kt, ToastDescription as l, CarouselPrevious as la, ContextMenuShortcut as li, NavigationMenuTrigger as ln, AlertDialogTrigger as lo, InputOTP as lr, useIsMobile as lt, Toaster as m, CardDescription as ma, Command$1 as mi, MessageScroller$1 as mn, Accordion$1 as mo, indicatorVariants as mr, SheetFooter as mt, ToggleGroupItem as n, ChartStyle as na, ContextMenuGroup as ni, NavigationMenu$1 as nn, AlertDialogDescription as no, ItemFooter as nr, SidebarTrigger as nt, ToastAction as o, CarouselContent as oa, ContextMenuRadioGroup as oi, NavigationMenuLink as on, AlertDialogOverlay as oo, ItemSeparator as or, TooltipProvider as ot, ToastViewport as p, CardContent as pa, ContextMenuTrigger as pi, NativeSelectOption as pn, AlertTitle as po, Indicator as pr, SheetDescription as pt, SidebarMenuButton as q, AttachmentGroup as qa, ScrollBar as qi, MarkerIcon as qn, DrawerFooter as qr, Popover$1 as qt, Toggle$1 as r, ChartTooltip as ra, ContextMenuItem as ri, NavigationMenuContent as rn, AlertDialogFooter as ro, ItemGroup as rr, useSidebar as rt, ToastClose as s, CarouselItem as sa, ContextMenuRadioItem as si, NavigationMenuList as sn, AlertDialogPortal as so, ItemTitle as sr, TooltipTrigger as st, ToggleGroup$1 as t, ChartLegendContent as ta, ContextMenuContent as ti, getPaginationRange as tn, AlertDialogContent as to, ItemDescription as tr, SidebarSeparator as tt, ToastPortal as u, useCarousel as ua, ContextMenuSub as ui, navigationMenuTriggerStyle as un, Alert as uo, InputOTPGroup as ur, Sheet as ut, Tabs$1 as v, Calendar as va, CommandInput as vi, MessageScrollerProvider as vn, VideoPlayer as vo, Field$1 as vr, Select$1 as vt, TableBody as w, BubbleContent as wa, InputGroupAddon as wi, MessageAvatar as wn, buttonVariants as wo, EmptyDescription as wr, SelectTrigger as wt, TabsTrigger as x, ButtonGroupSeparator as xa, CommandSeparator as xi, useMessageScrollerScrollable as xn, useMediaPlayer as xo, FieldLabel as xr, SelectItem as xt, TabsContent as y, CalendarDayButton as ya, CommandItem as yi, MessageScrollerViewport as yn, AudioPlayer as yo, FieldDescription as yr, SelectContent as yt, SidebarGroupContent as z, AvatarGroup as za, DialogTitle as zi, MenubarSeparator as zn, DropdownMenuSub as zr, QuestionnaireItem as zt };
4370
-
4371
- //# sourceMappingURL=toggle-group-CTTjTe-K.js.map