beez-ui 0.6.1 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +134 -82
- package/README.md +25 -11
- package/dist/components/alert.js +1 -1
- package/dist/components/avatar.d.ts +2 -1
- package/dist/components/avatar.js +4 -3
- package/dist/components/calendar.js +102 -0
- package/dist/components/carousel.js +61 -48
- package/dist/components/checkbox.js +1 -1
- package/dist/components/data-table.js +34 -4
- package/dist/components/dropdown-menu.js +5 -2
- package/dist/components/filter-query-bar.js +11 -6
- package/dist/components/form.d.ts +5 -0
- package/dist/components/form.js +11 -9
- package/dist/components/input-group.js +1 -1
- package/dist/components/input.js +1 -1
- package/dist/components/pagination.d.ts +1 -0
- package/dist/components/pagination.js +9 -4
- package/dist/components/radio-group.js +1 -1
- package/dist/components/select.js +1 -1
- package/dist/components/sheet.js +12 -9
- package/dist/components/sidebar.js +9 -5
- package/dist/components/skeleton.d.ts +6 -0
- package/dist/components/skeleton.js +7 -1
- package/dist/components/switch.js +1 -1
- package/dist/components/textarea.js +1 -1
- package/dist/components/typing-animation.js +42 -15
- package/dist/lib/column-filter-value.d.ts +12 -0
- package/dist/lib/column-filter-value.js +52 -0
- package/dist/motion/glide-indicator.d.ts +37 -3
- package/dist/motion/glide-indicator.js +37 -3
- package/dist/motion/motion-slot.js +47 -18
- package/dist/motion/surface-keyframes.js +18 -6
- package/dist/motion/tokens.d.ts +24 -1
- package/dist/motion/tokens.js +23 -0
- package/dist/providers/beez-ui-provider.js +49 -17
- package/dist/styles.css +1 -1
- package/package.json +2 -2
|
@@ -7,6 +7,17 @@ import { cn } from "../lib/utils.js";
|
|
|
7
7
|
import { Button } from "./button.js";
|
|
8
8
|
import { ChevronLeftIcon, ChevronRightIcon } from "lucide-react";
|
|
9
9
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
|
+
/** Arrow keys that move to the previous and next slide along each axis. */
|
|
11
|
+
const CAROUSEL_KEYS = {
|
|
12
|
+
horizontal: {
|
|
13
|
+
previous: "ArrowLeft",
|
|
14
|
+
next: "ArrowRight"
|
|
15
|
+
},
|
|
16
|
+
vertical: {
|
|
17
|
+
previous: "ArrowUp",
|
|
18
|
+
next: "ArrowDown"
|
|
19
|
+
}
|
|
20
|
+
};
|
|
10
21
|
const CarouselContext = React.createContext(null);
|
|
11
22
|
function useCarousel() {
|
|
12
23
|
const context = React.useContext(CarouselContext);
|
|
@@ -16,7 +27,7 @@ function useCarousel() {
|
|
|
16
27
|
return context;
|
|
17
28
|
}
|
|
18
29
|
function Carousel(t0) {
|
|
19
|
-
const $ = _c(
|
|
30
|
+
const $ = _c(48);
|
|
20
31
|
let children;
|
|
21
32
|
let className;
|
|
22
33
|
let opts;
|
|
@@ -100,28 +111,30 @@ function Carousel(t0) {
|
|
|
100
111
|
}
|
|
101
112
|
const scrollNext = t6;
|
|
102
113
|
let t7;
|
|
103
|
-
if ($[18] !==
|
|
114
|
+
if ($[18] !== orientation || $[19] !== scrollNext || $[20] !== scrollPrev) {
|
|
104
115
|
t7 = (event) => {
|
|
105
|
-
|
|
116
|
+
const keys = CAROUSEL_KEYS[orientation];
|
|
117
|
+
if (event.key === keys.previous) {
|
|
106
118
|
event.preventDefault();
|
|
107
119
|
scrollPrev();
|
|
108
120
|
} else {
|
|
109
|
-
if (event.key ===
|
|
121
|
+
if (event.key === keys.next) {
|
|
110
122
|
event.preventDefault();
|
|
111
123
|
scrollNext();
|
|
112
124
|
}
|
|
113
125
|
}
|
|
114
126
|
};
|
|
115
|
-
$[18] =
|
|
116
|
-
$[19] =
|
|
117
|
-
$[20] =
|
|
127
|
+
$[18] = orientation;
|
|
128
|
+
$[19] = scrollNext;
|
|
129
|
+
$[20] = scrollPrev;
|
|
130
|
+
$[21] = t7;
|
|
118
131
|
} else {
|
|
119
|
-
t7 = $[
|
|
132
|
+
t7 = $[21];
|
|
120
133
|
}
|
|
121
134
|
const handleKeyDown = t7;
|
|
122
135
|
let t8;
|
|
123
136
|
let t9;
|
|
124
|
-
if ($[
|
|
137
|
+
if ($[22] !== api || $[23] !== setApi) {
|
|
125
138
|
t8 = () => {
|
|
126
139
|
if (!api || !setApi) {
|
|
127
140
|
return;
|
|
@@ -129,18 +142,18 @@ function Carousel(t0) {
|
|
|
129
142
|
setApi(api);
|
|
130
143
|
};
|
|
131
144
|
t9 = [api, setApi];
|
|
132
|
-
$[
|
|
133
|
-
$[
|
|
134
|
-
$[
|
|
135
|
-
$[
|
|
145
|
+
$[22] = api;
|
|
146
|
+
$[23] = setApi;
|
|
147
|
+
$[24] = t8;
|
|
148
|
+
$[25] = t9;
|
|
136
149
|
} else {
|
|
137
|
-
t8 = $[
|
|
138
|
-
t9 = $[
|
|
150
|
+
t8 = $[24];
|
|
151
|
+
t9 = $[25];
|
|
139
152
|
}
|
|
140
153
|
React.useEffect(t8, t9);
|
|
141
154
|
let t10;
|
|
142
155
|
let t11;
|
|
143
|
-
if ($[
|
|
156
|
+
if ($[26] !== api) {
|
|
144
157
|
t10 = () => {
|
|
145
158
|
if (!api) {
|
|
146
159
|
return;
|
|
@@ -160,17 +173,17 @@ function Carousel(t0) {
|
|
|
160
173
|
};
|
|
161
174
|
};
|
|
162
175
|
t11 = [api, onSelect];
|
|
163
|
-
$[
|
|
164
|
-
$[
|
|
165
|
-
$[
|
|
176
|
+
$[26] = api;
|
|
177
|
+
$[27] = t10;
|
|
178
|
+
$[28] = t11;
|
|
166
179
|
} else {
|
|
167
|
-
t10 = $[
|
|
168
|
-
t11 = $[
|
|
180
|
+
t10 = $[27];
|
|
181
|
+
t11 = $[28];
|
|
169
182
|
}
|
|
170
183
|
React.useEffect(t10, t11);
|
|
171
184
|
const t12 = orientation || (opts?.axis === "y" ? "vertical" : "horizontal");
|
|
172
185
|
let t13;
|
|
173
|
-
if ($[
|
|
186
|
+
if ($[29] !== api || $[30] !== canScrollNext || $[31] !== canScrollPrev || $[32] !== carouselRef || $[33] !== opts || $[34] !== scrollNext || $[35] !== scrollPrev || $[36] !== t12) {
|
|
174
187
|
t13 = {
|
|
175
188
|
carouselRef,
|
|
176
189
|
api,
|
|
@@ -181,28 +194,28 @@ function Carousel(t0) {
|
|
|
181
194
|
canScrollPrev,
|
|
182
195
|
canScrollNext
|
|
183
196
|
};
|
|
184
|
-
$[
|
|
185
|
-
$[
|
|
186
|
-
$[
|
|
187
|
-
$[
|
|
188
|
-
$[
|
|
189
|
-
$[
|
|
190
|
-
$[
|
|
191
|
-
$[
|
|
192
|
-
$[
|
|
197
|
+
$[29] = api;
|
|
198
|
+
$[30] = canScrollNext;
|
|
199
|
+
$[31] = canScrollPrev;
|
|
200
|
+
$[32] = carouselRef;
|
|
201
|
+
$[33] = opts;
|
|
202
|
+
$[34] = scrollNext;
|
|
203
|
+
$[35] = scrollPrev;
|
|
204
|
+
$[36] = t12;
|
|
205
|
+
$[37] = t13;
|
|
193
206
|
} else {
|
|
194
|
-
t13 = $[
|
|
207
|
+
t13 = $[37];
|
|
195
208
|
}
|
|
196
209
|
let t14;
|
|
197
|
-
if ($[
|
|
210
|
+
if ($[38] !== className) {
|
|
198
211
|
t14 = cn("relative", className);
|
|
199
|
-
$[
|
|
200
|
-
$[
|
|
212
|
+
$[38] = className;
|
|
213
|
+
$[39] = t14;
|
|
201
214
|
} else {
|
|
202
|
-
t14 = $[
|
|
215
|
+
t14 = $[39];
|
|
203
216
|
}
|
|
204
217
|
let t15;
|
|
205
|
-
if ($[
|
|
218
|
+
if ($[40] !== children || $[41] !== handleKeyDown || $[42] !== props || $[43] !== t14) {
|
|
206
219
|
t15 = /* @__PURE__ */ _jsx("div", {
|
|
207
220
|
onKeyDownCapture: handleKeyDown,
|
|
208
221
|
className: t14,
|
|
@@ -212,25 +225,25 @@ function Carousel(t0) {
|
|
|
212
225
|
...props,
|
|
213
226
|
children
|
|
214
227
|
});
|
|
215
|
-
$[
|
|
216
|
-
$[
|
|
217
|
-
$[
|
|
218
|
-
$[
|
|
219
|
-
$[
|
|
228
|
+
$[40] = children;
|
|
229
|
+
$[41] = handleKeyDown;
|
|
230
|
+
$[42] = props;
|
|
231
|
+
$[43] = t14;
|
|
232
|
+
$[44] = t15;
|
|
220
233
|
} else {
|
|
221
|
-
t15 = $[
|
|
234
|
+
t15 = $[44];
|
|
222
235
|
}
|
|
223
236
|
let t16;
|
|
224
|
-
if ($[
|
|
237
|
+
if ($[45] !== t13 || $[46] !== t15) {
|
|
225
238
|
t16 = /* @__PURE__ */ _jsx(CarouselContext.Provider, {
|
|
226
239
|
value: t13,
|
|
227
240
|
children: t15
|
|
228
241
|
});
|
|
229
|
-
$[
|
|
230
|
-
$[
|
|
231
|
-
$[
|
|
242
|
+
$[45] = t13;
|
|
243
|
+
$[46] = t15;
|
|
244
|
+
$[47] = t16;
|
|
232
245
|
} else {
|
|
233
|
-
t16 = $[
|
|
246
|
+
t16 = $[47];
|
|
234
247
|
}
|
|
235
248
|
return t16;
|
|
236
249
|
}
|
|
@@ -21,7 +21,7 @@ function Checkbox(t0) {
|
|
|
21
21
|
}
|
|
22
22
|
let t1;
|
|
23
23
|
if ($[3] !== className) {
|
|
24
|
-
t1 = cn("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input shadow-xs transition-shadow 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);
|
|
24
|
+
t1 = cn("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input shadow-xs transition-[color,background-color,border-color,box-shadow] 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);
|
|
25
25
|
$[3] = className;
|
|
26
26
|
$[4] = t1;
|
|
27
27
|
} else {
|
|
@@ -3,6 +3,7 @@ import * as React from "react";
|
|
|
3
3
|
import { flexRender, getCoreRowModel, getFilteredRowModel, getSortedRowModel, useReactTable } from "@tanstack/react-table";
|
|
4
4
|
import { CircleAlert, ChevronDown, ChevronRight, Ellipsis, Eraser, X } from "lucide-react";
|
|
5
5
|
import { cn } from "../lib/utils.js";
|
|
6
|
+
import { matchesColumnFilterValue, normalizeFilterToken } from "../lib/column-filter-value.js";
|
|
6
7
|
import { MotionSlot } from "../motion/motion-slot.js";
|
|
7
8
|
import { Button } from "./button.js";
|
|
8
9
|
import { Badge } from "./badge.js";
|
|
@@ -12,7 +13,6 @@ import { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMe
|
|
|
12
13
|
import { Input } from "./input.js";
|
|
13
14
|
import { Table, TableBody, TableCell, TableFooter, TableHead, TableHeader, TableRow } from "./table.js";
|
|
14
15
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
15
|
-
const DIACRITICS_PATTERN = /[\u0300-\u036f]/g;
|
|
16
16
|
const CLEAR_FILTER_ARIA_LABEL = "Limpiar filtro";
|
|
17
17
|
const ACTIVE_EXCLUSIONS_SR_LABEL = "Filtros de exclusión activos";
|
|
18
18
|
const HIDE_EXCLUDE_FILTERS_ARIA_LABEL = "Ocultar filtros de exclusión";
|
|
@@ -22,8 +22,37 @@ const EXCLUDED_ROWS_SUMMARY_LABEL = "Total excluidas";
|
|
|
22
22
|
const CLEAR_ALL_EXCLUSIONS_ARIA_LABEL = "Quitar todas las exclusiones";
|
|
23
23
|
const CLEAR_ALL_EXCLUSIONS_FROM_INPUT_ARIA_LABEL = "Limpiar filtros excluidos";
|
|
24
24
|
const REVERSE_FILTER_PENDING_MESSAGE = "Estás escribiendo una exclusión. Presioná Enter para aplicarla.";
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
/** Filters a column with the structured values the query bar writes, or plain text. */
|
|
26
|
+
const columnFilterValueFn = (row, columnId, filterValue) => matchesColumnFilterValue(row.getValue(columnId), filterValue);
|
|
27
|
+
/** Mirrors TanStack's column id resolution: explicit id, else the accessor key with dots as `_`. */
|
|
28
|
+
function getColumnDefId(column) {
|
|
29
|
+
if (column.id) return column.id;
|
|
30
|
+
const accessorKey = column.accessorKey;
|
|
31
|
+
return typeof accessorKey === "string" ? accessorKey.replaceAll(".", "_") : undefined;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Gives the columns targeted by query qualifiers a filter that understands the query bar's
|
|
35
|
+
* structured values. TanStack would otherwise infer one from the data (`inNumberRange` for
|
|
36
|
+
* numbers, which crashes on an object). A consumer's own `filterFn` always wins.
|
|
37
|
+
*/
|
|
38
|
+
function withQueryFilterFns(columns, targetedColumnIds) {
|
|
39
|
+
if (targetedColumnIds.size === 0) return columns;
|
|
40
|
+
return columns.map((column) => {
|
|
41
|
+
if ("columns" in column && column.columns) {
|
|
42
|
+
return {
|
|
43
|
+
...column,
|
|
44
|
+
columns: withQueryFilterFns(column.columns, targetedColumnIds)
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
const columnId = getColumnDefId(column);
|
|
48
|
+
if (column.filterFn != null || columnId == null || !targetedColumnIds.has(columnId)) {
|
|
49
|
+
return column;
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
...column,
|
|
53
|
+
filterFn: columnFilterValueFn
|
|
54
|
+
};
|
|
55
|
+
});
|
|
27
56
|
}
|
|
28
57
|
function getTableFilterValue(filterValue, showExcludeFilterToggle) {
|
|
29
58
|
const normalizedFilterValue = filterValue.trimStart();
|
|
@@ -310,8 +339,9 @@ export function DataTable({ columns, data, emptyMessage, toolbarActions, onVisib
|
|
|
310
339
|
onColumnVisibilityChange?.(updater);
|
|
311
340
|
}, [controlledColumnVisibility, onColumnVisibilityChange]);
|
|
312
341
|
// TanStack Table manages internal reactive state through this hook.
|
|
342
|
+
const tableColumns = React.useMemo(() => withQueryFilterFns(columns, advancedFilterColumnIds), [columns, advancedFilterColumnIds]);
|
|
313
343
|
const table = useReactTable({
|
|
314
|
-
columns,
|
|
344
|
+
columns: tableColumns,
|
|
315
345
|
data,
|
|
316
346
|
// La tabla no pagina (no hay `getPaginationRowModel`). Con el auto-reset por
|
|
317
347
|
// defecto, cada cambio de filtro dispara `resetPageIndex` → `setPagination`,
|
|
@@ -586,7 +586,7 @@ function DropdownMenuSubTrigger(t0) {
|
|
|
586
586
|
}
|
|
587
587
|
let t1;
|
|
588
588
|
if ($[5] !== className) {
|
|
589
|
-
t1 = 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:pl-7 data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className);
|
|
589
|
+
t1 = 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:pl-7 data-open:bg-accent data-open:text-accent-foreground data-open:*:data-[slot=dropdown-menu-sub-trigger-icon]:translate-x-0.5 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className);
|
|
590
590
|
$[5] = className;
|
|
591
591
|
$[6] = t1;
|
|
592
592
|
} else {
|
|
@@ -594,7 +594,10 @@ function DropdownMenuSubTrigger(t0) {
|
|
|
594
594
|
}
|
|
595
595
|
let t2;
|
|
596
596
|
if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
|
|
597
|
-
t2 = /* @__PURE__ */ _jsx(ChevronRightIcon, {
|
|
597
|
+
t2 = /* @__PURE__ */ _jsx(ChevronRightIcon, {
|
|
598
|
+
"data-slot": "dropdown-menu-sub-trigger-icon",
|
|
599
|
+
className: "ml-auto transition-transform duration-200 ease-out"
|
|
600
|
+
});
|
|
598
601
|
$[7] = t2;
|
|
599
602
|
} else {
|
|
600
603
|
t2 = $[7];
|
|
@@ -5,6 +5,7 @@ import { Calendar, Check, CircleDot, CircleMinus, CircleSlash, Folder, Hash, Lis
|
|
|
5
5
|
import { Button } from "./button.js";
|
|
6
6
|
import { Input } from "./input.js";
|
|
7
7
|
import { Popover, PopoverAnchor, PopoverContent } from "./popover.js";
|
|
8
|
+
import { GlideSlot } from "../motion/glide-slot.js";
|
|
8
9
|
import { cn } from "../lib/utils.js";
|
|
9
10
|
import { getActiveFilterToken, getValueHighlightRanges, normalizeFilterSlug, parseFilterQuery, PRESENCE_HAS_META_KEY, PRESENCE_NO_META_KEY, UNASSIGNED_FOLDER_FILTER_VALUE } from "./filter-query-grammar.js";
|
|
10
11
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -810,12 +811,16 @@ export function FilterQueryBar(t0) {
|
|
|
810
811
|
onCloseAutoFocus: _temp,
|
|
811
812
|
onInteractOutside: t34,
|
|
812
813
|
onOpenAutoFocus: _temp2,
|
|
813
|
-
children: /* @__PURE__ */ _jsx(
|
|
814
|
-
"
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
814
|
+
children: /* @__PURE__ */ _jsx(GlideSlot, {
|
|
815
|
+
preset: "suggestions",
|
|
816
|
+
children: /* @__PURE__ */ _jsx("ul", {
|
|
817
|
+
"aria-label": t35,
|
|
818
|
+
className: "grid gap-0.5",
|
|
819
|
+
"data-slot": "filter-query-bar-suggestions",
|
|
820
|
+
id: listboxId,
|
|
821
|
+
role: "listbox",
|
|
822
|
+
children: t36
|
|
823
|
+
})
|
|
819
824
|
})
|
|
820
825
|
});
|
|
821
826
|
$[83] = listboxId;
|
|
@@ -4,6 +4,11 @@ import { Slot } from "radix-ui";
|
|
|
4
4
|
import { type ControllerProps, type FieldPath, type FieldValues } from "react-hook-form";
|
|
5
5
|
declare const Form: <TFieldValues extends FieldValues, TContext = any, TTransformedValues = TFieldValues>({ children, watch, getValues, getErrors, getFieldState, setError, clearErrors, setValue, setValues, trigger, formState, resetField, reset, resetDefaultValues, handleSubmit, unregister, control, register, setFocus, subscribe, }: import("react-hook-form").FormProviderProps<TFieldValues, TContext, TTransformedValues>) => React.JSX.Element;
|
|
6
6
|
declare const FormField: <TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({ ...props }: ControllerProps<TFieldValues, TName>) => React.JSX.Element;
|
|
7
|
+
/**
|
|
8
|
+
* Reads the field and item context shared by the form parts.
|
|
9
|
+
* @returns Accessible ids plus the react-hook-form state of the enclosing field.
|
|
10
|
+
* @throws When used outside `<FormField>`, where no field name is available.
|
|
11
|
+
*/
|
|
7
12
|
declare const useFormField: () => {
|
|
8
13
|
invalid: boolean;
|
|
9
14
|
isDirty: boolean;
|
package/dist/components/form.js
CHANGED
|
@@ -49,6 +49,11 @@ const FormField = (t0) => {
|
|
|
49
49
|
}
|
|
50
50
|
return t3;
|
|
51
51
|
};
|
|
52
|
+
/**
|
|
53
|
+
* Reads the field and item context shared by the form parts.
|
|
54
|
+
* @returns Accessible ids plus the react-hook-form state of the enclosing field.
|
|
55
|
+
* @throws When used outside `<FormField>`, where no field name is available.
|
|
56
|
+
*/
|
|
52
57
|
const useFormField = () => {
|
|
53
58
|
const $ = _c(13);
|
|
54
59
|
const fieldContext = React.useContext(FormFieldContext);
|
|
@@ -63,6 +68,9 @@ const useFormField = () => {
|
|
|
63
68
|
t0 = $[1];
|
|
64
69
|
}
|
|
65
70
|
const formState = useFormState(t0);
|
|
71
|
+
if (!fieldContext.name) {
|
|
72
|
+
throw new Error("useFormField: must be used within <FormField>, which provides the field name");
|
|
73
|
+
}
|
|
66
74
|
let t1;
|
|
67
75
|
if ($[2] !== fieldContext.name || $[3] !== formState || $[4] !== getFieldState) {
|
|
68
76
|
t1 = getFieldState(fieldContext.name, formState);
|
|
@@ -74,9 +82,6 @@ const useFormField = () => {
|
|
|
74
82
|
t1 = $[5];
|
|
75
83
|
}
|
|
76
84
|
const fieldState = t1;
|
|
77
|
-
if (!fieldContext) {
|
|
78
|
-
throw new Error("useFormField should be used within <FormField>");
|
|
79
|
-
}
|
|
80
85
|
const { id } = itemContext;
|
|
81
86
|
const t2 = `${id}-form-item`;
|
|
82
87
|
const t3 = `${id}-form-item-description`;
|
|
@@ -149,12 +154,9 @@ function FormItem(t0) {
|
|
|
149
154
|
}
|
|
150
155
|
let t4;
|
|
151
156
|
if ($[10] !== t1 || $[11] !== t3) {
|
|
152
|
-
t4 = /* @__PURE__ */ _jsx(
|
|
153
|
-
|
|
154
|
-
children:
|
|
155
|
-
value: t1,
|
|
156
|
-
children: t3
|
|
157
|
-
})
|
|
157
|
+
t4 = /* @__PURE__ */ _jsx(FormItemContext.Provider, {
|
|
158
|
+
value: t1,
|
|
159
|
+
children: t3
|
|
158
160
|
});
|
|
159
161
|
$[10] = t1;
|
|
160
162
|
$[11] = t3;
|
|
@@ -23,7 +23,7 @@ function InputGroup(t0) {
|
|
|
23
23
|
}
|
|
24
24
|
let t1;
|
|
25
25
|
if ($[3] !== className) {
|
|
26
|
-
t1 = cn("group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input transition-
|
|
26
|
+
t1 = cn("group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input transition-[color,background-color,border-color,box-shadow] outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 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 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 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]]:[&>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);
|
|
27
27
|
$[3] = className;
|
|
28
28
|
$[4] = t1;
|
|
29
29
|
} else {
|
package/dist/components/input.js
CHANGED
|
@@ -9,7 +9,7 @@ function Input({ className, type, ...props }) {
|
|
|
9
9
|
children: /* @__PURE__ */ _jsx(InputPrimitive, {
|
|
10
10
|
type,
|
|
11
11
|
"data-slot": "input",
|
|
12
|
-
className: cn("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-
|
|
12
|
+
className: cn("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-[color,background-color,border-color,box-shadow] 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),
|
|
13
13
|
...props
|
|
14
14
|
})
|
|
15
15
|
});
|
|
@@ -2,6 +2,7 @@ import * as React from "react";
|
|
|
2
2
|
import { type LinkProps } from "./link.js";
|
|
3
3
|
import { Button } from "./button.js";
|
|
4
4
|
declare function Pagination({ className, ...props }: React.ComponentProps<"nav">): React.JSX.Element;
|
|
5
|
+
/** Lists page links; the current page's highlight glides to the newly selected page. */
|
|
5
6
|
declare function PaginationContent({ className, ...props }: React.ComponentProps<"ul">): React.JSX.Element;
|
|
6
7
|
declare function PaginationItem({ ...props }: React.ComponentProps<"li">): React.JSX.Element;
|
|
7
8
|
export type PaginationLinkProps = {
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import { c as _c } from "react/compiler-runtime";
|
|
3
3
|
import * as React from "react";
|
|
4
4
|
import { Link } from "./link.js";
|
|
5
|
+
import { GlideSlot } from "../motion/glide-slot.js";
|
|
5
6
|
import { cn } from "../lib/utils.js";
|
|
6
7
|
import { Button } from "./button.js";
|
|
7
8
|
import { ChevronLeftIcon, ChevronRightIcon, MoreHorizontalIcon } from "lucide-react";
|
|
@@ -44,6 +45,7 @@ function Pagination(t0) {
|
|
|
44
45
|
}
|
|
45
46
|
return t2;
|
|
46
47
|
}
|
|
48
|
+
/** Lists page links; the current page's highlight glides to the newly selected page. */
|
|
47
49
|
function PaginationContent(t0) {
|
|
48
50
|
const $ = _c(8);
|
|
49
51
|
let className;
|
|
@@ -67,10 +69,13 @@ function PaginationContent(t0) {
|
|
|
67
69
|
}
|
|
68
70
|
let t2;
|
|
69
71
|
if ($[5] !== props || $[6] !== t1) {
|
|
70
|
-
t2 = /* @__PURE__ */ _jsx(
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
72
|
+
t2 = /* @__PURE__ */ _jsx(GlideSlot, {
|
|
73
|
+
preset: "pagination",
|
|
74
|
+
children: /* @__PURE__ */ _jsx("ul", {
|
|
75
|
+
"data-slot": "pagination-content",
|
|
76
|
+
className: t1,
|
|
77
|
+
...props
|
|
78
|
+
})
|
|
74
79
|
});
|
|
75
80
|
$[5] = props;
|
|
76
81
|
$[6] = t1;
|
|
@@ -56,7 +56,7 @@ function RadioGroupItem(t0) {
|
|
|
56
56
|
}
|
|
57
57
|
let t1;
|
|
58
58
|
if ($[3] !== className) {
|
|
59
|
-
t1 = cn("group/radio-group-item peer relative flex aspect-square size-4 shrink-0 rounded-full border border-input 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 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);
|
|
59
|
+
t1 = cn("group/radio-group-item peer relative flex aspect-square size-4 shrink-0 rounded-full border border-input transition-[color,background-color,border-color,box-shadow] 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 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);
|
|
60
60
|
$[3] = className;
|
|
61
61
|
$[4] = t1;
|
|
62
62
|
} else {
|
|
@@ -116,7 +116,7 @@ function SelectTrigger(t0) {
|
|
|
116
116
|
const size = t1 === undefined ? "default" : t1;
|
|
117
117
|
let t2;
|
|
118
118
|
if ($[5] !== className) {
|
|
119
|
-
t2 = cn("flex w-fit items-center justify-between gap-1.5 rounded-lg border data-[state=open]:*:data-[slot=select-icon]:rotate-180 border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-
|
|
119
|
+
t2 = cn("flex w-fit items-center justify-between gap-1.5 rounded-lg border data-[state=open]:*:data-[slot=select-icon]:rotate-180 border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-[color,background-color,border-color,box-shadow] outline-none select-none 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 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 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", className);
|
|
120
120
|
$[5] = className;
|
|
121
121
|
$[6] = t2;
|
|
122
122
|
} else {
|
package/dist/components/sheet.js
CHANGED
|
@@ -196,7 +196,7 @@ function SheetContent(t0) {
|
|
|
196
196
|
}
|
|
197
197
|
let t5;
|
|
198
198
|
if ($[7] !== className) {
|
|
199
|
-
t5 = cn("fixed z-50 flex flex-col gap-4 overflow-y-auto overscroll-contain data-[side=bottom]:max-h-dvh data-[side=top]:max-h-dvh bg-background bg-clip-padding text-sm shadow-lg
|
|
199
|
+
t5 = cn("fixed z-50 flex flex-col gap-4 overflow-y-auto overscroll-contain data-[side=bottom]:max-h-dvh data-[side=top]:max-h-dvh bg-background bg-clip-padding text-sm shadow-lg data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t 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=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=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm ", className);
|
|
200
200
|
$[7] = className;
|
|
201
201
|
$[8] = t5;
|
|
202
202
|
} else {
|
|
@@ -207,14 +207,17 @@ function SheetContent(t0) {
|
|
|
207
207
|
t6 = showCloseButton && /* @__PURE__ */ _jsx(SheetPrimitive.Close, {
|
|
208
208
|
"data-slot": "sheet-close",
|
|
209
209
|
asChild: true,
|
|
210
|
-
children: /* @__PURE__ */
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
children: "
|
|
217
|
-
|
|
210
|
+
children: /* @__PURE__ */ _jsx(MotionSlot, {
|
|
211
|
+
kind: "delayed-pop",
|
|
212
|
+
children: /* @__PURE__ */ _jsxs(Button, {
|
|
213
|
+
variant: "ghost",
|
|
214
|
+
className: "absolute top-4 right-4",
|
|
215
|
+
size: "icon-sm",
|
|
216
|
+
children: [/* @__PURE__ */ _jsx(XIcon, {}), /* @__PURE__ */ _jsx("span", {
|
|
217
|
+
className: "sr-only",
|
|
218
|
+
children: "Close"
|
|
219
|
+
})]
|
|
220
|
+
})
|
|
218
221
|
})
|
|
219
222
|
});
|
|
220
223
|
$[9] = showCloseButton;
|
|
@@ -7,6 +7,7 @@ import { useIsMobile } from "../hooks/use-mobile.js";
|
|
|
7
7
|
import { useSidebarPersistence, saveSidebarPreference } from "../hooks/use-sidebar-persistence.js";
|
|
8
8
|
import { GlideSlot } from "../motion/glide-slot.js";
|
|
9
9
|
import { MotionSlot } from "../motion/motion-slot.js";
|
|
10
|
+
import { MOTION_EASE_DRAWER } from "../motion/tokens.js";
|
|
10
11
|
import { cn } from "../lib/utils.js";
|
|
11
12
|
import { SIDEBAR_COOKIE_MAX_AGE, SIDEBAR_COOKIE_NAME } from "../constants/sidebar.js";
|
|
12
13
|
import { Button } from "./button.js";
|
|
@@ -21,6 +22,8 @@ const SIDEBAR_WIDTH = "16rem";
|
|
|
21
22
|
const SIDEBAR_WIDTH_MOBILE = "18rem";
|
|
22
23
|
const SIDEBAR_WIDTH_ICON = "3rem";
|
|
23
24
|
const SIDEBAR_KEYBOARD_SHORTCUT = "b";
|
|
25
|
+
/** Drawer curve shared by the collapse transitions: quick start, long gentle settle. */
|
|
26
|
+
const SIDEBAR_EASE = `cubic-bezier(${MOTION_EASE_DRAWER.join(", ")})`;
|
|
24
27
|
const SIDEBAR_MENU_SKELETON_TEXT_WIDTH = "70%";
|
|
25
28
|
function subscribeToClientMount() {
|
|
26
29
|
return () => {};
|
|
@@ -158,6 +161,7 @@ function SidebarProvider(t0) {
|
|
|
158
161
|
t7 = {
|
|
159
162
|
"--sidebar-width": SIDEBAR_WIDTH,
|
|
160
163
|
"--sidebar-width-icon": SIDEBAR_WIDTH_ICON,
|
|
164
|
+
"--sidebar-ease": SIDEBAR_EASE,
|
|
161
165
|
...style
|
|
162
166
|
};
|
|
163
167
|
$[26] = style;
|
|
@@ -339,7 +343,7 @@ function Sidebar(t0) {
|
|
|
339
343
|
const t5 = variant === "floating" || variant === "inset" ? "group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon)";
|
|
340
344
|
let t6;
|
|
341
345
|
if ($[27] !== t5) {
|
|
342
|
-
t6 = cn("relative w-(--sidebar-width) bg-transparent transition-[width] duration-
|
|
346
|
+
t6 = cn("relative w-(--sidebar-width) bg-transparent transition-[width] duration-300 ease-(--sidebar-ease)", "group-data-[collapsible=offcanvas]:w-0", "group-data-[side=right]:rotate-180", t5);
|
|
343
347
|
$[27] = t5;
|
|
344
348
|
$[28] = t6;
|
|
345
349
|
} else {
|
|
@@ -359,7 +363,7 @@ function Sidebar(t0) {
|
|
|
359
363
|
const t8 = 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";
|
|
360
364
|
let t9;
|
|
361
365
|
if ($[31] !== className || $[32] !== t8) {
|
|
362
|
-
t9 = cn("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-
|
|
366
|
+
t9 = cn("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-300 ease-(--sidebar-ease) 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", t8, className);
|
|
363
367
|
$[31] = className;
|
|
364
368
|
$[32] = t8;
|
|
365
369
|
$[33] = t9;
|
|
@@ -507,7 +511,7 @@ function SidebarRail(t0) {
|
|
|
507
511
|
const { toggleSidebar } = useSidebar();
|
|
508
512
|
let t1;
|
|
509
513
|
if ($[3] !== className) {
|
|
510
|
-
t1 = cn("absolute inset-y-0 z-20 hidden w-4 transition-all ease-
|
|
514
|
+
t1 = cn("absolute inset-y-0 z-20 hidden w-4 transition-all duration-300 ease-(--sidebar-ease) 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);
|
|
511
515
|
$[3] = className;
|
|
512
516
|
$[4] = t1;
|
|
513
517
|
} else {
|
|
@@ -812,7 +816,7 @@ function SidebarGroupLabel(t0) {
|
|
|
812
816
|
const Comp = asChild ? Slot.Root : "div";
|
|
813
817
|
let t2;
|
|
814
818
|
if ($[4] !== className) {
|
|
815
|
-
t2 = 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-
|
|
819
|
+
t2 = 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-300 ease-(--sidebar-ease) group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0", className);
|
|
816
820
|
$[4] = className;
|
|
817
821
|
$[5] = t2;
|
|
818
822
|
} else {
|
|
@@ -996,7 +1000,7 @@ const sidebarMenuButtonVariants = cva("peer/menu-button group/menu-button flex w
|
|
|
996
1000
|
variants: {
|
|
997
1001
|
variant: {
|
|
998
1002
|
default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
|
|
999
|
-
outline: "bg-background shadow-[
|
|
1003
|
+
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)]"
|
|
1000
1004
|
},
|
|
1001
1005
|
size: {
|
|
1002
1006
|
default: "h-8 text-sm",
|
|
@@ -1,2 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Placeholder with a soft shine that sweeps across it while content loads.
|
|
3
|
+
* The shine rests outside the box, so reduced motion shows a plain muted block.
|
|
4
|
+
* @param props - Native div properties and optional consumer overrides.
|
|
5
|
+
* @returns The placeholder element with its loading animation.
|
|
6
|
+
*/
|
|
1
7
|
declare function Skeleton({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
2
8
|
export { Skeleton };
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import { MotionSlot } from "../motion/motion-slot.js";
|
|
2
2
|
import { cn } from "../lib/utils.js";
|
|
3
3
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
4
|
+
/**
|
|
5
|
+
* Placeholder with a soft shine that sweeps across it while content loads.
|
|
6
|
+
* The shine rests outside the box, so reduced motion shows a plain muted block.
|
|
7
|
+
* @param props - Native div properties and optional consumer overrides.
|
|
8
|
+
* @returns The placeholder element with its loading animation.
|
|
9
|
+
*/
|
|
4
10
|
function Skeleton({ className, ...props }) {
|
|
5
11
|
return /* @__PURE__ */ _jsx(MotionSlot, {
|
|
6
12
|
kind: "skeleton",
|
|
7
13
|
children: /* @__PURE__ */ _jsx("div", {
|
|
8
14
|
"data-slot": "skeleton",
|
|
9
|
-
className: cn("rounded-md bg-muted", className),
|
|
15
|
+
className: cn("relative overflow-hidden rounded-md bg-muted after:pointer-events-none after:absolute after:inset-0 after:-translate-x-full after:bg-linear-to-r after:from-transparent after:via-foreground/6 after:to-transparent", className),
|
|
10
16
|
...props
|
|
11
17
|
})
|
|
12
18
|
});
|
|
@@ -36,7 +36,7 @@ function Switch(t0) {
|
|
|
36
36
|
kind: "thumb",
|
|
37
37
|
children: /* @__PURE__ */ _jsx(SwitchPrimitive.Thumb, {
|
|
38
38
|
"data-slot": "switch-thumb",
|
|
39
|
-
className: "pointer-events-none block rounded-full bg-background ring-0
|
|
39
|
+
className: "pointer-events-none block rounded-full bg-background shadow-sm ring-0 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"
|
|
40
40
|
})
|
|
41
41
|
});
|
|
42
42
|
$[6] = t3;
|
|
@@ -12,7 +12,7 @@ function Textarea({ className, ...props }) {
|
|
|
12
12
|
kind: "field",
|
|
13
13
|
children: /* @__PURE__ */ _jsx("textarea", {
|
|
14
14
|
"data-slot": "textarea",
|
|
15
|
-
className: cn("flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-
|
|
15
|
+
className: cn("flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-[color,background-color,border-color,box-shadow] outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 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),
|
|
16
16
|
...props
|
|
17
17
|
})
|
|
18
18
|
});
|