@doscientos/ui 0.1.6 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -21,8 +21,34 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
21
21
  // src/index.ts
22
22
  var index_exports = {};
23
23
  __export(index_exports, {
24
+ Accordion: () => Accordion,
25
+ AccordionContent: () => AccordionContent,
26
+ AccordionItem: () => AccordionItem,
27
+ AccordionTrigger: () => AccordionTrigger,
28
+ Alert: () => Alert,
29
+ AlertAction: () => AlertAction,
30
+ AlertDescription: () => AlertDescription,
31
+ AlertTitle: () => AlertTitle,
32
+ AppShell: () => AppShell,
33
+ AppShellContent: () => AppShellContent,
34
+ AppShellHeader: () => AppShellHeader,
35
+ AppShellMain: () => AppShellMain,
36
+ AutocompleteCombobox: () => AutocompleteCombobox,
37
+ Avatar: () => Avatar,
38
+ AvatarBadge: () => AvatarBadge,
39
+ AvatarFallback: () => AvatarFallback,
40
+ AvatarGroup: () => AvatarGroup,
41
+ AvatarGroupCount: () => AvatarGroupCount,
42
+ AvatarImage: () => AvatarImage,
24
43
  Badge: () => Badge,
25
- Button: () => Button,
44
+ Breadcrumb: () => Breadcrumb,
45
+ BreadcrumbLink: () => BreadcrumbLink,
46
+ BreadcrumbPage: () => BreadcrumbPage,
47
+ BreadcrumbSeparator: () => BreadcrumbSeparator,
48
+ Breadcrumbs: () => Breadcrumbs,
49
+ Button: () => Button2,
50
+ ButtonGroup: () => ButtonGroup,
51
+ ButtonGroupText: () => ButtonGroupText,
26
52
  Card: () => Card,
27
53
  CardContent: () => CardContent,
28
54
  CardDescription: () => CardDescription,
@@ -35,7 +61,12 @@ __export(index_exports, {
35
61
  ComboboxInput: () => ComboboxInput,
36
62
  ComboboxItem: () => ComboboxItem,
37
63
  ComboboxList: () => ComboboxList,
38
- ComboboxValue: () => import_react_aria_components3.ComboBoxValue,
64
+ ComboboxValue: () => import_react_aria_components5.ComboBoxValue,
65
+ Command: () => Command,
66
+ CommandContent: () => CommandContent,
67
+ CommandInput: () => CommandInput,
68
+ CommandItem: () => CommandItem,
69
+ CommandList: () => CommandList,
39
70
  ConfirmDialog: () => ConfirmDialog,
40
71
  Dialog: () => Dialog,
41
72
  DialogClose: () => DialogClose,
@@ -44,25 +75,52 @@ __export(index_exports, {
44
75
  DialogFooter: () => DialogFooter,
45
76
  DialogHeader: () => DialogHeader,
46
77
  DialogTitle: () => DialogTitle,
78
+ Drawer: () => Drawer,
79
+ DrawerDescription: () => DrawerDescription,
80
+ DrawerFooter: () => DrawerFooter,
81
+ DrawerHeader: () => DrawerHeader,
82
+ DrawerTitle: () => DrawerTitle,
83
+ DropdownMenu: () => DropdownMenu,
84
+ DropdownMenuContent: () => DropdownMenuContent,
85
+ DropdownMenuItem: () => DropdownMenuItem,
86
+ DropdownMenuSeparator: () => DropdownMenuSeparator,
87
+ DropdownMenuTrigger: () => DropdownMenuTrigger,
47
88
  EmptyState: () => EmptyState,
48
89
  EmptyStateDescription: () => EmptyStateDescription,
49
90
  EmptyStateTitle: () => EmptyStateTitle,
50
91
  Field: () => Field,
51
92
  FieldDescription: () => FieldDescription,
52
- FieldError: () => FieldError,
93
+ FieldError: () => FieldError2,
53
94
  FieldLabel: () => FieldLabel,
95
+ FormFeedback: () => FormFeedback,
96
+ FormRow: () => FormRow,
54
97
  HighlightMatch: () => HighlightMatch,
98
+ IconButton: () => IconButton,
55
99
  Input: () => Input3,
100
+ InputGroup: () => InputGroup,
101
+ InputGroupAddon: () => InputGroupAddon,
102
+ InputGroupButton: () => InputGroupButton,
103
+ InputGroupInput: () => InputGroupInput,
104
+ InputGroupText: () => InputGroupText,
105
+ InputGroupTextarea: () => InputGroupTextarea,
56
106
  Kbd: () => Kbd,
57
107
  KbdGroup: () => KbdGroup,
58
- Label: () => Label,
108
+ Label: () => Label2,
109
+ LoadingOverlay: () => LoadingOverlay,
59
110
  Menu: () => Menu,
60
111
  MenuContent: () => MenuContent,
61
112
  MenuItem: () => MenuItem,
62
113
  MenuTrigger: () => MenuTrigger,
63
- Popover: () => Popover3,
114
+ PageHeader: () => PageHeader,
115
+ PageHeaderActions: () => PageHeaderActions,
116
+ PageHeaderDescription: () => PageHeaderDescription,
117
+ PageHeaderHeading: () => PageHeaderHeading,
118
+ PageHeaderTitle: () => PageHeaderTitle,
119
+ Pagination: () => Pagination,
120
+ Popover: () => Popover4,
64
121
  PopoverContent: () => PopoverContent,
65
122
  PopoverTrigger: () => PopoverTrigger,
123
+ QuantityInput: () => QuantityInput,
66
124
  SearchClearButton: () => SearchClearButton,
67
125
  SearchField: () => SearchField,
68
126
  SearchInput: () => SearchInput,
@@ -73,7 +131,20 @@ __export(index_exports, {
73
131
  SelectTrigger: () => SelectTrigger,
74
132
  SelectValue: () => SelectValue,
75
133
  Separator: () => Separator,
134
+ Sidebar: () => Sidebar,
135
+ SidebarContent: () => SidebarContent,
136
+ SidebarFooter: () => SidebarFooter,
137
+ SidebarGroup: () => SidebarGroup,
138
+ SidebarHeader: () => SidebarHeader,
139
+ SidebarItem: () => SidebarItem,
140
+ SidebarMore: () => SidebarMore,
141
+ SidebarProvider: () => SidebarProvider,
142
+ SidebarRail: () => SidebarRail,
143
+ SidebarSearch: () => SidebarSearch,
144
+ SidebarSeparator: () => SidebarSeparator,
145
+ SidebarTrigger: () => SidebarTrigger,
76
146
  Skeleton: () => Skeleton,
147
+ SubmitButton: () => SubmitButton,
77
148
  Switch: () => Switch,
78
149
  Table: () => Table,
79
150
  TableBody: () => TableBody,
@@ -88,6 +159,13 @@ __export(index_exports, {
88
159
  TabsPanels: () => TabsPanels,
89
160
  TabsTrigger: () => TabsTrigger,
90
161
  Textarea: () => Textarea2,
162
+ Toast: () => Toast,
163
+ ToastProvider: () => ToastProvider,
164
+ ToastViewport: () => ToastViewport,
165
+ Toaster: () => Toaster,
166
+ Toolbar: () => Toolbar,
167
+ ToolbarGroup: () => ToolbarGroup,
168
+ ToolbarSpacer: () => ToolbarSpacer,
91
169
  Tooltip: () => Tooltip,
92
170
  TooltipContent: () => TooltipContent,
93
171
  TooltipTrigger: () => TooltipTrigger,
@@ -96,9 +174,13 @@ __export(index_exports, {
96
174
  cn: () => cn,
97
175
  formSnapshot: () => formSnapshot,
98
176
  getTextMatchParts: () => getTextMatchParts,
177
+ toast: () => toast,
99
178
  useAutosave: () => useAutosave,
100
179
  useDebouncedValue: () => useDebouncedValue,
101
- useFormDirty: () => useFormDirty
180
+ useFormDirty: () => useFormDirty,
181
+ useFormFeedback: () => useFormFeedback,
182
+ useSidebar: () => useSidebar,
183
+ useToast: () => useToast
102
184
  });
103
185
  module.exports = __toCommonJS(index_exports);
104
186
 
@@ -134,12 +216,12 @@ function useAutosave({
134
216
  }, []);
135
217
  (0, import_react.useEffect)(() => {
136
218
  if (!enabled) return;
137
- const snapshot = serializeRef.current(data);
219
+ const snapshot2 = serializeRef.current(data);
138
220
  if (lastSaved.current === null) {
139
- lastSaved.current = snapshot;
221
+ lastSaved.current = snapshot2;
140
222
  return;
141
223
  }
142
- if (snapshot === lastSaved.current) return;
224
+ if (snapshot2 === lastSaved.current) return;
143
225
  const timeout = window.setTimeout(() => void save(data), debounceMs);
144
226
  return () => window.clearTimeout(timeout);
145
227
  }, [data, debounceMs, enabled, save]);
@@ -243,9 +325,90 @@ function getTextMatchParts(text, query) {
243
325
  return parts.length ? parts : [{ text, match: false }];
244
326
  }
245
327
 
246
- // src/ui/badge.tsx
247
- var import_class_variance_authority = require("class-variance-authority");
328
+ // src/ui/accordion/accordion.tsx
329
+ var import_react_aria_components = require("react-aria-components");
330
+ var import_react4 = require("@phosphor-icons/react");
248
331
  var import_jsx_runtime = require("react/jsx-runtime");
332
+ function Accordion({ className, ...props }) {
333
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_aria_components.DisclosureGroup, { "data-slot": "accordion", className: cn("flex w-full flex-col", className), ...props });
334
+ }
335
+ function AccordionItem({ className, ...props }) {
336
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_aria_components.Disclosure, { "data-slot": "accordion-item", className: cn("border-b border-border last:border-0", className), ...props });
337
+ }
338
+ function AccordionTrigger({ className, children, ...props }) {
339
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_aria_components.Button, { "data-slot": "accordion-trigger", className: cn("group/accordion-trigger flex w-full items-center justify-between py-3 text-left text-sm font-medium outline-none transition-colors hover:text-primary focus-visible:ring-3 focus-visible:ring-ring/50", className), ...props, children: (values) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
340
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: typeof children === "function" ? children(values) : children }),
341
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react4.CaretDownIcon, { "aria-hidden": "true", weight: "bold", className: "size-4 transition-transform group-data-expanded/accordion-trigger:rotate-180 motion-reduce:transition-none" })
342
+ ] }) });
343
+ }
344
+ function AccordionContent({ className, ...props }) {
345
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_aria_components.DisclosurePanel, { "data-slot": "accordion-content", className: cn("overflow-hidden pb-3 text-sm text-muted-foreground", className), ...props });
346
+ }
347
+
348
+ // src/ui/alert/alert.tsx
349
+ var import_jsx_runtime2 = require("react/jsx-runtime");
350
+ var variants = {
351
+ default: "border-border bg-card text-foreground",
352
+ destructive: "border-destructive/30 bg-destructive/5 text-destructive",
353
+ success: "border-success/30 bg-success/5 text-success",
354
+ warning: "border-warning/30 bg-warning/5 text-warning"
355
+ };
356
+ function Alert({ className, variant = "default", ...props }) {
357
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { role: "alert", "data-slot": "alert", "data-variant": variant, className: cn("grid w-full gap-1 rounded-lg border px-3 py-2.5 text-sm [&>svg]:size-4", variants[variant], className), ...props });
358
+ }
359
+ function AlertTitle({ className, ...props }) {
360
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { "data-slot": "alert-title", className: cn("font-medium", className), ...props });
361
+ }
362
+ function AlertDescription({ className, ...props }) {
363
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { "data-slot": "alert-description", className: cn("text-sm opacity-90", className), ...props });
364
+ }
365
+ function AlertAction({ className, children, ...props }) {
366
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { "data-slot": "alert-action", className: cn("absolute top-2 right-2", className), ...props, children });
367
+ }
368
+
369
+ // src/ui/app-shell/app-shell.tsx
370
+ var import_jsx_runtime3 = require("react/jsx-runtime");
371
+ function AppShell({ className, ...props }) {
372
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { "data-slot": "app-shell", className: cn("flex min-h-screen w-full bg-muted/30 text-foreground", className), ...props });
373
+ }
374
+ function AppShellMain({ className, ...props }) {
375
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("main", { "data-slot": "app-shell-main", className: cn("min-w-0 flex-1", className), ...props });
376
+ }
377
+ function AppShellHeader({ className, ...props }) {
378
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("header", { "data-slot": "app-shell-header", className: cn("sticky top-0 z-10 flex min-h-14 items-center border-b border-border bg-background/85 px-4 backdrop-blur-md supports-[backdrop-filter]:bg-background/70", className), ...props });
379
+ }
380
+ function AppShellContent({ className, ...props }) {
381
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { "data-slot": "app-shell-content", className: cn("mx-auto w-full max-w-[1600px] p-4 md:p-6", className), ...props });
382
+ }
383
+
384
+ // src/ui/avatar/avatar.tsx
385
+ var import_react5 = require("react");
386
+ var import_jsx_runtime4 = require("react/jsx-runtime");
387
+ var sizes = { xs: "size-5 text-[10px]", sm: "size-6 text-xs", default: "size-8 text-sm", lg: "size-10 text-base" };
388
+ function Avatar({ className, size = "default", ...props }) {
389
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { "data-slot": "avatar", "data-size": size, className: cn("group/avatar relative flex shrink-0 overflow-hidden rounded-full bg-muted text-muted-foreground", sizes[size], className), ...props });
390
+ }
391
+ function AvatarImage({ className, ...props }) {
392
+ const [failed, setFailed] = (0, import_react5.useState)(false);
393
+ if (failed) return null;
394
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("img", { "data-slot": "avatar-image", className: cn("aspect-square size-full object-cover", className), onError: () => setFailed(true), ...props });
395
+ }
396
+ function AvatarFallback({ className, ...props }) {
397
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { "data-slot": "avatar-fallback", className: cn("flex size-full items-center justify-center font-medium", className), ...props });
398
+ }
399
+ function AvatarBadge({ className, ...props }) {
400
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { "data-slot": "avatar-badge", className: cn("absolute right-0 bottom-0 size-2.5 rounded-full bg-success ring-2 ring-background", className), ...props });
401
+ }
402
+ function AvatarGroup({ className, ...props }) {
403
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { "data-slot": "avatar-group", className: cn("flex -space-x-2 [&>[data-slot=avatar]]:ring-2 [&>[data-slot=avatar]]:ring-background", className), ...props });
404
+ }
405
+ function AvatarGroupCount({ className, ...props }) {
406
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { "data-slot": "avatar-group-count", className: cn("flex size-8 items-center justify-center rounded-full bg-muted text-xs font-medium text-muted-foreground ring-2 ring-background", className), ...props });
407
+ }
408
+
409
+ // src/ui/badge/badge.tsx
410
+ var import_class_variance_authority = require("class-variance-authority");
411
+ var import_jsx_runtime5 = require("react/jsx-runtime");
249
412
  var badgeVariants = (0, import_class_variance_authority.cva)("inline-flex w-fit items-center gap-1 rounded-full px-2 py-0.5 text-xs font-medium", {
250
413
  variants: {
251
414
  variant: {
@@ -261,15 +424,34 @@ var badgeVariants = (0, import_class_variance_authority.cva)("inline-flex w-fit
261
424
  defaultVariants: { variant: "default" }
262
425
  });
263
426
  function Badge({ className, variant, ...props }) {
264
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { "data-slot": "badge", className: cn(badgeVariants({ variant }), className), ...props });
427
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { "data-slot": "badge", className: cn(badgeVariants({ variant }), className), ...props });
428
+ }
429
+
430
+ // src/ui/breadcrumb/breadcrumb.tsx
431
+ var import_react_aria_components2 = require("react-aria-components");
432
+ var import_jsx_runtime6 = require("react/jsx-runtime");
433
+ function Breadcrumbs({ className, ...props }) {
434
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components2.Breadcrumbs, { "data-slot": "breadcrumbs", className: cn("flex flex-wrap items-center gap-1.5 text-sm text-muted-foreground", className), ...props });
435
+ }
436
+ function Breadcrumb({ className, ...props }) {
437
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components2.Breadcrumb, { "data-slot": "breadcrumb", className: cn("inline-flex items-center gap-1.5", className), ...props });
438
+ }
439
+ function BreadcrumbLink({ className, ...props }) {
440
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components2.Link, { "data-slot": "breadcrumb-link", className: cn("transition-colors hover:text-foreground", className), ...props });
441
+ }
442
+ function BreadcrumbPage({ className, ...props }) {
443
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { "data-slot": "breadcrumb-page", "aria-current": "page", className: cn("font-medium text-foreground", className), ...props });
444
+ }
445
+ function BreadcrumbSeparator({ children = "/", className, ...props }) {
446
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { "data-slot": "breadcrumb-separator", "aria-hidden": "true", className: cn("text-muted-foreground/60", className), ...props, children });
265
447
  }
266
448
 
267
- // src/ui/button.tsx
449
+ // src/ui/button/button.tsx
268
450
  var import_class_variance_authority2 = require("class-variance-authority");
269
- var import_react_aria_components = require("react-aria-components");
270
- var import_jsx_runtime2 = require("react/jsx-runtime");
451
+ var import_react_aria_components3 = require("react-aria-components");
452
+ var import_jsx_runtime7 = require("react/jsx-runtime");
271
453
  var buttonVariants = (0, import_class_variance_authority2.cva)(
272
- "inline-flex shrink-0 items-center justify-center gap-1.5 rounded-lg border border-transparent text-sm font-medium whitespace-nowrap transition-colors outline-none focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
454
+ "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-[background-color,border-color,color,box-shadow,transform] duration-150 outline-none focus-visible:ring-3 focus-visible:ring-ring/50 data-pressed:scale-[0.98] disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 motion-reduce:transition-none motion-reduce:data-pressed:transform-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
273
455
  {
274
456
  variants: {
275
457
  variant: {
@@ -291,309 +473,1053 @@ var buttonVariants = (0, import_class_variance_authority2.cva)(
291
473
  defaultVariants: { variant: "default", size: "default" }
292
474
  }
293
475
  );
294
- function Button({ className, variant, size, ...props }) {
295
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_aria_components.Button, { "data-slot": "button", className: cn(buttonVariants({ variant, size }), className), ...props });
476
+ function Button2({ className, variant, size, ...props }) {
477
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_react_aria_components3.Button, { "data-slot": "button", className: cn(buttonVariants({ variant, size }), className), ...props });
296
478
  }
297
479
 
298
- // src/ui/card.tsx
299
- var import_jsx_runtime3 = require("react/jsx-runtime");
480
+ // src/ui/button-group/button-group.tsx
481
+ var import_jsx_runtime8 = require("react/jsx-runtime");
482
+ function ButtonGroup({ className, ...props }) {
483
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { role: "group", "data-slot": "button-group", className: cn("inline-flex items-center gap-2", className), ...props });
484
+ }
485
+ function ButtonGroupText({ className, ...props }) {
486
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { "data-slot": "button-group-text", className: cn("text-sm text-muted-foreground", className), ...props });
487
+ }
488
+
489
+ // src/ui/card/card.tsx
490
+ var import_jsx_runtime9 = require("react/jsx-runtime");
300
491
  function Card({ className, ...props }) {
301
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("section", { "data-slot": "card", className: cn("rounded-xl border border-border bg-card text-foreground shadow-sm", className), ...props });
492
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("section", { "data-slot": "card", className: cn("rounded-xl border border-border bg-card text-foreground shadow-sm", className), ...props });
302
493
  }
303
494
  function CardHeader({ className, ...props }) {
304
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("header", { "data-slot": "card-header", className: cn("flex flex-col gap-1.5 p-5", className), ...props });
495
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("header", { "data-slot": "card-header", className: cn("flex flex-col gap-1.5 p-5", className), ...props });
305
496
  }
306
497
  function CardTitle({ className, ...props }) {
307
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("h2", { "data-slot": "card-title", className: cn("text-base font-semibold", className), ...props });
498
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("h2", { "data-slot": "card-title", className: cn("text-base font-semibold", className), ...props });
308
499
  }
309
500
  function CardDescription({ className, ...props }) {
310
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("p", { "data-slot": "card-description", className: cn("text-sm text-muted-foreground", className), ...props });
501
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("p", { "data-slot": "card-description", className: cn("text-sm text-muted-foreground", className), ...props });
311
502
  }
312
503
  function CardContent({ className, ...props }) {
313
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { "data-slot": "card-content", className: cn("p-5 pt-0", className), ...props });
504
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { "data-slot": "card-content", className: cn("p-5 pt-0", className), ...props });
314
505
  }
315
506
  function CardFooter({ className, ...props }) {
316
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("footer", { "data-slot": "card-footer", className: cn("flex items-center gap-2 border-t border-border p-5", className), ...props });
507
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("footer", { "data-slot": "card-footer", className: cn("flex items-center gap-2 border-t border-border p-5", className), ...props });
317
508
  }
318
509
 
319
- // src/ui/checkbox.tsx
320
- var import_react_aria_components2 = require("react-aria-components");
321
- var import_jsx_runtime4 = require("react/jsx-runtime");
510
+ // src/ui/checkbox/checkbox.tsx
511
+ var import_react_aria_components4 = require("react-aria-components");
512
+ var import_react6 = require("@phosphor-icons/react");
513
+ var import_jsx_runtime10 = require("react/jsx-runtime");
322
514
  function Checkbox({ className, children, ...props }) {
323
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_react_aria_components2.Checkbox, { "data-slot": "checkbox", className: cn("group inline-flex items-center gap-2 text-sm text-foreground data-disabled:cursor-not-allowed data-disabled:opacity-50", className), ...props, children: (state) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
324
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { "aria-hidden": "true", className: "grid size-4 place-items-center rounded border border-border bg-background text-xs text-primary-foreground group-data-selected:border-primary group-data-selected:bg-primary group-data-focus-visible:ring-3 group-data-focus-visible:ring-ring/50", children: "\u2713" }),
515
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_aria_components4.Checkbox, { "data-slot": "checkbox", className: cn("group inline-flex items-center gap-2 text-sm text-foreground data-disabled:cursor-not-allowed data-disabled:opacity-50", className), ...props, children: (state) => /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
516
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { "aria-hidden": "true", className: "grid size-4 place-items-center rounded border border-border bg-background text-primary-foreground transition-colors group-data-selected:border-primary group-data-selected:bg-primary group-data-focus-visible:ring-3 group-data-focus-visible:ring-ring/50", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react6.CheckIcon, { weight: "bold", className: "size-3 opacity-0 transition-opacity group-data-selected:opacity-100 motion-reduce:transition-none" }) }),
325
517
  typeof children === "function" ? children(state) : children
326
518
  ] }) });
327
519
  }
328
520
 
329
- // src/ui/combobox.tsx
330
- var import_react4 = require("react");
331
- var import_react_aria_components3 = require("react-aria-components");
332
- var import_jsx_runtime5 = require("react/jsx-runtime");
333
- var Combobox = import_react_aria_components3.ComboBox;
521
+ // src/ui/combobox/combobox.tsx
522
+ var import_react7 = require("react");
523
+ var import_react_aria_components5 = require("react-aria-components");
524
+ var import_jsx_runtime11 = require("react/jsx-runtime");
525
+ var Combobox = import_react_aria_components5.ComboBox;
334
526
  function ComboboxInput({ className, ...props }) {
335
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_aria_components3.Input, { "data-slot": "combobox-input", className: cn("h-8 w-full rounded-lg border border-border bg-background px-2.5 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50", className), ...props });
527
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.Input, { "data-slot": "combobox-input", className: cn("h-9 w-full rounded-lg border border-border bg-background px-2.5 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50", className), ...props });
336
528
  }
337
529
  function ComboboxContent({ className, ...props }) {
338
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_aria_components3.Popover, { "data-slot": "combobox-content", className: cn("max-h-72 w-(--trigger-width) overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
530
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.Popover, { "data-slot": "combobox-content", className: cn("max-h-72 w-(--trigger-width) overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
339
531
  }
340
532
  function ComboboxList({ className, emptyState, ...props }) {
341
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_aria_components3.ListBox, { "data-slot": "combobox-list", className: cn("max-h-64 overflow-y-auto", className), renderEmptyState: emptyState ? () => emptyState : void 0, ...props });
533
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.ListBox, { "data-slot": "combobox-list", className: cn("max-h-64 overflow-y-auto", className), renderEmptyState: emptyState ? () => emptyState : void 0, ...props });
342
534
  }
343
535
  function ComboboxItem({ className, children, ...props }) {
344
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_aria_components3.ListBoxItem, { "data-slot": "combobox-item", className: cn("flex w-full cursor-default items-center justify-between rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props, children });
536
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.ListBoxItem, { "data-slot": "combobox-item", className: cn("flex w-full cursor-default items-center justify-between rounded-md px-2 py-2 text-sm outline-none transition-colors data-focused:bg-muted data-focused:text-foreground data-hovered:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props, children });
345
537
  }
346
538
  function HighlightMatch({ text, query, className }) {
347
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className, children: getTextMatchParts(text, query).map((part, index) => part.match ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("mark", { className: "rounded bg-accent px-0.5 text-accent-foreground", children: part.text }, `${part.text}-${index}`) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react4.Fragment, { children: part.text }, `${part.text}-${index}`)) });
539
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { className, children: getTextMatchParts(text, query).map((part, index) => part.match ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("mark", { className: "rounded bg-accent px-0.5 text-accent-foreground", children: part.text }, `${part.text}-${index}`) : /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react7.Fragment, { children: part.text }, `${part.text}-${index}`)) });
540
+ }
541
+ function AutocompleteCombobox({ items, getItemKey, getItemLabel, renderItem, inputValue: controlledInputValue, onInputChange, selectedKey, onSelectionChange, label, description, errorMessage, emptyState = /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("p", { className: "px-3 py-7 text-center text-sm text-muted-foreground", children: "No hay resultados." }), suggestion = true, placeholder, className, onKeyDown: _onKeyDown, ...props }) {
542
+ const [internalInputValue, setInternalInputValue] = (0, import_react7.useState)("");
543
+ const inputValue = controlledInputValue ?? internalInputValue;
544
+ const setInputValue = (value) => {
545
+ setInternalInputValue(value);
546
+ onInputChange?.(value);
547
+ };
548
+ const normalizedQuery = inputValue.trim().toLocaleLowerCase();
549
+ const filteredItems = (0, import_react7.useMemo)(() => normalizedQuery ? items.filter((item) => getItemLabel(item).toLocaleLowerCase().includes(normalizedQuery)) : [...items], [getItemLabel, items, normalizedQuery]);
550
+ const suggestedItem = (0, import_react7.useMemo)(() => !suggestion || !normalizedQuery ? void 0 : items.find((item) => getItemLabel(item).toLocaleLowerCase().startsWith(normalizedQuery) && getItemLabel(item).length > inputValue.length), [getItemLabel, inputValue.length, items, normalizedQuery, suggestion]);
551
+ const suggestionLabel = suggestedItem ? getItemLabel(suggestedItem) : void 0;
552
+ const acceptSuggestion = () => {
553
+ if (!suggestedItem || !suggestionLabel) return false;
554
+ setInputValue(suggestionLabel);
555
+ onSelectionChange?.(getItemKey(suggestedItem), suggestedItem);
556
+ return true;
557
+ };
558
+ const handleKeyDown = (event) => {
559
+ if ((event.key === "Tab" || event.key === "Enter") && acceptSuggestion()) event.preventDefault();
560
+ };
561
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_react_aria_components5.ComboBox, { ...props, className: cn("group/combobox flex w-full flex-col gap-1.5", className), items: filteredItems, selectedKey, inputValue, onInputChange: setInputValue, onSelectionChange: (key) => {
562
+ const item = filteredItems.find((candidate) => String(getItemKey(candidate)) === String(key));
563
+ if (item) setInputValue(getItemLabel(item));
564
+ onSelectionChange?.(key, item);
565
+ }, children: [
566
+ label && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.Label, { className: "text-sm font-medium text-foreground", children: label }),
567
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "relative", children: [
568
+ suggestionLabel && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("span", { "aria-hidden": "true", className: "pointer-events-none absolute inset-y-0 left-2.5 z-0 flex items-center whitespace-pre text-sm text-muted-foreground/60", children: [
569
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { className: "text-transparent", children: inputValue }),
570
+ suggestionLabel.slice(inputValue.length)
571
+ ] }),
572
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxInput, { "aria-autocomplete": suggestionLabel ? "both" : "list", placeholder, onKeyDown: handleKeyDown, className: "relative z-10 bg-transparent" })
573
+ ] }),
574
+ description && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.Text, { slot: "description", className: "text-xs text-muted-foreground", children: description }),
575
+ errorMessage && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components5.FieldError, { className: "text-xs text-destructive", children: errorMessage }),
576
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxContent, { children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxList, { emptyState, children: (item) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxItem, { id: getItemKey(item), textValue: getItemLabel(item), children: renderItem ? renderItem(item, inputValue) : /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(HighlightMatch, { text: getItemLabel(item), query: inputValue }) }) }) })
577
+ ] });
348
578
  }
349
579
 
350
- // src/ui/dialog.tsx
351
- var import_react5 = require("react");
352
- var import_react_aria_components4 = require("react-aria-components");
353
- var import_jsx_runtime6 = require("react/jsx-runtime");
354
- var DialogCloseContext = (0, import_react5.createContext)(null);
580
+ // src/ui/command/command.tsx
581
+ var import_react_aria_components6 = require("react-aria-components");
582
+ var import_jsx_runtime12 = require("react/jsx-runtime");
583
+ function Command({ className, ...props }) {
584
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_aria_components6.ComboBox, { "data-slot": "command", className: cn("w-full", className), ...props });
585
+ }
586
+ function CommandInput({ className, ...props }) {
587
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_aria_components6.Input, { "data-slot": "command-input", className: cn("h-9 w-full border-0 bg-transparent px-3 text-sm text-foreground outline-none placeholder:text-muted-foreground", className), ...props });
588
+ }
589
+ function CommandContent({ className, ...props }) {
590
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_aria_components6.Popover, { "data-slot": "command-content", className: cn("w-(--trigger-width) overflow-hidden rounded-xl border border-border bg-background p-1.5 shadow-lg outline-none", className), ...props });
591
+ }
592
+ function CommandList({ className, ...props }) {
593
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_aria_components6.ListBox, { "data-slot": "command-list", className: cn("max-h-72 overflow-y-auto", className), ...props });
594
+ }
595
+ function CommandItem({ className, ...props }) {
596
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_aria_components6.ListBoxItem, { "data-slot": "command-item", className: cn("flex cursor-default items-center rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props });
597
+ }
598
+
599
+ // src/ui/dialog/dialog.tsx
600
+ var import_react8 = require("react");
601
+ var import_react9 = require("@phosphor-icons/react");
602
+ var import_react_aria_components7 = require("react-aria-components");
603
+ var import_jsx_runtime13 = require("react/jsx-runtime");
604
+ var DialogCloseContext = (0, import_react8.createContext)(null);
355
605
  function Dialog({ open, children, ...props }) {
356
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components4.ModalOverlay, { isOpen: open, className: "fixed inset-0 z-50 grid place-items-center bg-black/20 p-4 backdrop-blur-[1px] motion-safe:data-entering:animate-ui-overlay-in motion-safe:data-exiting:animate-ui-overlay-out", ...props, children });
606
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.ModalOverlay, { isOpen: open, className: "fixed inset-0 z-50 grid place-items-center bg-black/20 p-4 backdrop-blur-[1px] motion-safe:data-entering:animate-ui-overlay-in motion-safe:data-exiting:animate-ui-overlay-out", ...props, children });
357
607
  }
358
608
  function DialogClose({ onPress, ...props }) {
359
- const close = (0, import_react5.useContext)(DialogCloseContext);
360
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Button, { onPress: (event) => {
609
+ const close = (0, import_react8.useContext)(DialogCloseContext);
610
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Button2, { onPress: (event) => {
361
611
  onPress?.(event);
362
612
  close?.();
363
613
  }, ...props });
364
614
  }
365
615
  function DialogContent({ className, children, showCloseButton = true, ...props }) {
366
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components4.Modal, { className: "w-full max-w-md outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components4.Dialog, { "data-slot": "dialog-content", className: cn("relative grid max-h-[calc(100dvh-2rem)] gap-4 overflow-y-auto rounded-xl bg-background p-5 text-foreground shadow-xl outline-none", className), ...props, children: ({ close }) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(DialogCloseContext.Provider, { value: close, children: [
616
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.Modal, { className: "w-full max-w-md outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.Dialog, { "data-slot": "dialog-content", className: cn("relative grid max-h-[calc(100dvh-2rem)] gap-4 overflow-y-auto rounded-xl bg-background p-5 text-foreground shadow-xl outline-none", className), ...props, children: ({ close }) => /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(DialogCloseContext.Provider, { value: close, children: [
367
617
  typeof children === "function" ? children({ close }) : children,
368
- showCloseButton && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DialogClose, { "aria-label": "Cerrar di\xE1logo", variant: "ghost", size: "icon", className: "absolute top-2 right-2", children: "\xD7" })
618
+ showCloseButton && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(DialogClose, { "aria-label": "Cerrar di\xE1logo", variant: "ghost", size: "icon", className: "absolute top-2 right-2", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react9.XIcon, { "aria-hidden": "true", weight: "bold", className: "size-4" }) })
369
619
  ] }) }) });
370
620
  }
371
621
  function DialogHeader({ className, ...props }) {
372
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { "data-slot": "dialog-header", className: cn("flex flex-col gap-2", className), ...props });
622
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { "data-slot": "dialog-header", className: cn("flex flex-col gap-2", className), ...props });
373
623
  }
374
624
  function DialogFooter({ className, ...props }) {
375
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { "data-slot": "dialog-footer", className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className), ...props });
625
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { "data-slot": "dialog-footer", className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className), ...props });
376
626
  }
377
627
  function DialogTitle({ className, ...props }) {
378
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components4.Heading, { slot: "title", className: cn("text-base font-semibold", className), ...props });
628
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.Heading, { slot: "title", className: cn("text-base font-semibold", className), ...props });
379
629
  }
380
630
  function DialogDescription({ className, ...props }) {
381
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_react_aria_components4.Text, { slot: "description", className: cn("text-sm text-muted-foreground", className), ...props });
631
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.Text, { slot: "description", className: cn("text-sm text-muted-foreground", className), ...props });
382
632
  }
383
633
 
384
- // src/ui/confirm-dialog.tsx
385
- var import_jsx_runtime7 = require("react/jsx-runtime");
634
+ // src/ui/confirm-dialog/confirm-dialog.tsx
635
+ var import_jsx_runtime14 = require("react/jsx-runtime");
386
636
  function ConfirmDialog({ open, onOpenChange, title, description, confirmLabel = "Confirmar", cancelLabel = "Cancelar", destructive = false, pending = false, onConfirm }) {
387
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Dialog, { open, onOpenChange, children: /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(DialogContent, { showCloseButton: false, children: [
388
- /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(DialogHeader, { children: [
389
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(DialogTitle, { children: title }),
390
- description && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(DialogDescription, { children: description })
637
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Dialog, { open, onOpenChange, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(DialogContent, { showCloseButton: false, children: [
638
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(DialogHeader, { children: [
639
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(DialogTitle, { children: title }),
640
+ description && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(DialogDescription, { children: description })
391
641
  ] }),
392
- /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(DialogFooter, { children: [
393
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Button, { variant: "outline", isDisabled: pending, onPress: () => onOpenChange(false), children: cancelLabel }),
394
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Button, { variant: destructive ? "destructive" : "default", isDisabled: pending, onPress: onConfirm, children: confirmLabel })
642
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(DialogFooter, { children: [
643
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Button2, { variant: "outline", isDisabled: pending, onPress: () => onOpenChange(false), children: cancelLabel }),
644
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Button2, { variant: destructive ? "destructive" : "default", isDisabled: pending, onPress: onConfirm, children: confirmLabel })
395
645
  ] })
396
646
  ] }) });
397
647
  }
398
648
 
399
- // src/ui/empty-state.tsx
400
- var import_jsx_runtime8 = require("react/jsx-runtime");
649
+ // src/ui/drawer/drawer.tsx
650
+ var import_react_aria_components8 = require("react-aria-components");
651
+ var import_jsx_runtime15 = require("react/jsx-runtime");
652
+ var sideStyles = { left: "inset-y-0 left-0 h-full w-[min(22rem,calc(100%-2rem))] data-entering:animate-ui-surface-in", right: "inset-y-0 right-0 h-full w-[min(22rem,calc(100%-2rem))] data-entering:animate-ui-surface-in", bottom: "inset-x-0 bottom-0 max-h-[85vh] w-full data-entering:animate-ui-surface-in" };
653
+ function Drawer({ children, side = "right", className, ...props }) {
654
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_aria_components8.ModalOverlay, { isDismissable: true, className: "fixed inset-0 z-50 bg-black/20 backdrop-blur-[1px] motion-safe:data-entering:animate-ui-overlay-in motion-safe:data-exiting:animate-ui-overlay-out", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_aria_components8.Modal, { className: cn("absolute grid gap-4 overflow-y-auto rounded-xl border border-border bg-background p-5 text-foreground shadow-xl outline-none", sideStyles[side], className), children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_aria_components8.Dialog, { "data-slot": "drawer", className: "outline-none", children }) }) });
655
+ }
656
+ function DrawerHeader({ className, ...props }) {
657
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { "data-slot": "drawer-header", className: cn("flex flex-col gap-1.5", className), ...props });
658
+ }
659
+ function DrawerFooter({ className, ...props }) {
660
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { "data-slot": "drawer-footer", className: cn("mt-auto flex flex-col-reverse gap-2 pt-4 sm:flex-row sm:justify-end", className), ...props });
661
+ }
662
+ function DrawerTitle({ className, ...props }) {
663
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("h2", { "data-slot": "drawer-title", className: cn("text-base font-semibold", className), ...props });
664
+ }
665
+ function DrawerDescription({ className, ...props }) {
666
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { "data-slot": "drawer-description", className: cn("text-sm text-muted-foreground", className), ...props });
667
+ }
668
+
669
+ // src/ui/dropdown-menu/dropdown-menu.tsx
670
+ var import_react_aria_components9 = require("react-aria-components");
671
+ var import_jsx_runtime16 = require("react/jsx-runtime");
672
+ var DropdownMenu = import_react_aria_components9.Menu;
673
+ var DropdownMenuTrigger = import_react_aria_components9.MenuTrigger;
674
+ function DropdownMenuContent({ className, ...props }) {
675
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components9.Popover, { "data-slot": "dropdown-menu-content", offset: 6, className: cn("min-w-40 overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
676
+ }
677
+ function DropdownMenuItem({ className, ...props }) {
678
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components9.MenuItem, { "data-slot": "dropdown-menu-item", className: cn("flex cursor-default items-center gap-2 rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props });
679
+ }
680
+ function DropdownMenuSeparator({ className, ...props }) {
681
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components9.Separator, { "data-slot": "dropdown-menu-separator", className: cn("my-1 h-px bg-border", className), ...props });
682
+ }
683
+
684
+ // src/ui/empty-state/empty-state.tsx
685
+ var import_jsx_runtime17 = require("react/jsx-runtime");
401
686
  function EmptyState({ className, ...props }) {
402
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { "data-slot": "empty-state", className: cn("flex min-h-44 w-full flex-col items-center justify-center gap-3 rounded-xl border border-dashed border-border p-6 text-center", className), ...props });
687
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { "data-slot": "empty-state", className: cn("flex min-h-44 w-full flex-col items-center justify-center gap-3 rounded-xl border border-dashed border-border p-6 text-center", className), ...props });
403
688
  }
404
689
  function EmptyStateTitle({ className, ...props }) {
405
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("h3", { "data-slot": "empty-state-title", className: cn("text-sm font-medium text-foreground", className), ...props });
690
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("h3", { "data-slot": "empty-state-title", className: cn("text-sm font-medium text-foreground", className), ...props });
406
691
  }
407
692
  function EmptyStateDescription({ className, ...props }) {
408
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { "data-slot": "empty-state-description", className: cn("max-w-sm text-sm text-muted-foreground", className), ...props });
693
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("p", { "data-slot": "empty-state-description", className: cn("max-w-sm text-sm text-muted-foreground", className), ...props });
409
694
  }
410
695
 
411
- // src/ui/label.tsx
412
- var import_react6 = require("react");
413
- var import_react_aria_components5 = require("react-aria-components");
414
- var import_jsx_runtime9 = require("react/jsx-runtime");
415
- var Label = (0, import_react6.forwardRef)(function Label2({ className, ...props }, ref) {
416
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_aria_components5.Label, { ref, "data-slot": "label", className: cn("flex items-center gap-2 text-sm font-medium leading-none select-none", className), ...props });
696
+ // src/ui/label/label.tsx
697
+ var import_react10 = require("react");
698
+ var import_react_aria_components10 = require("react-aria-components");
699
+ var import_jsx_runtime18 = require("react/jsx-runtime");
700
+ var Label2 = (0, import_react10.forwardRef)(function Label3({ className, ...props }, ref) {
701
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react_aria_components10.Label, { ref, "data-slot": "label", className: cn("flex items-center gap-2 text-sm font-medium leading-none select-none", className), ...props });
417
702
  });
418
703
 
419
- // src/ui/field.tsx
420
- var import_jsx_runtime10 = require("react/jsx-runtime");
704
+ // src/ui/field/field.tsx
705
+ var import_jsx_runtime19 = require("react/jsx-runtime");
421
706
  function Field({ className, ...props }) {
422
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { "data-slot": "field", className: cn("flex w-full flex-col gap-2", className), ...props });
707
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { "data-slot": "field", className: cn("flex w-full flex-col gap-2", className), ...props });
423
708
  }
424
709
  function FieldLabel({ className, ...props }) {
425
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Label, { "data-slot": "field-label", className: cn("text-foreground", className), ...props });
710
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Label2, { "data-slot": "field-label", className: cn("text-foreground", className), ...props });
426
711
  }
427
712
  function FieldDescription({ className, ...props }) {
428
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { "data-slot": "field-description", className: cn("text-sm text-muted-foreground", className), ...props });
713
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("p", { "data-slot": "field-description", className: cn("text-sm text-muted-foreground", className), ...props });
429
714
  }
430
- function FieldError({ className, children, ...props }) {
715
+ function FieldError2({ className, children, ...props }) {
431
716
  if (!children) return null;
432
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { role: "alert", "data-slot": "field-error", className: cn("text-sm text-destructive", className), ...props, children });
717
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("p", { role: "alert", "data-slot": "field-error", className: cn("text-sm text-destructive", className), ...props, children });
433
718
  }
434
719
 
435
- // src/ui/input.tsx
436
- var import_react7 = require("react");
437
- var import_react_aria_components6 = require("react-aria-components");
438
- var import_jsx_runtime11 = require("react/jsx-runtime");
439
- var InputImpl = (0, import_react7.forwardRef)(function Input2({ className, type, ...props }, ref) {
440
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_aria_components6.Input, { ref, type, "data-slot": "input", className: cn("h-8 w-full min-w-0 rounded-lg border border-border bg-background px-2.5 py-1 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive", className), ...props });
720
+ // src/ui/form-feedback/form-feedback.tsx
721
+ var import_react11 = require("react");
722
+ var import_react12 = require("@phosphor-icons/react");
723
+ var import_jsx_runtime20 = require("react/jsx-runtime");
724
+ function useFormFeedback(options) {
725
+ const resetMs = options?.successResetMs ?? 2500;
726
+ const [state, setState] = (0, import_react11.useState)({ status: "idle" });
727
+ const timer = (0, import_react11.useRef)(null);
728
+ const clearTimer = (0, import_react11.useCallback)(() => {
729
+ if (timer.current) clearTimeout(timer.current);
730
+ timer.current = null;
731
+ }, []);
732
+ (0, import_react11.useEffect)(() => () => clearTimer(), [clearTimer]);
733
+ const setPending = (0, import_react11.useCallback)(() => {
734
+ clearTimer();
735
+ setState({ status: "pending" });
736
+ }, [clearTimer]);
737
+ const setSuccess = (0, import_react11.useCallback)((message) => {
738
+ clearTimer();
739
+ setState({ status: "success", message });
740
+ if (resetMs > 0) timer.current = setTimeout(() => setState({ status: "idle" }), resetMs);
741
+ }, [clearTimer, resetMs]);
742
+ const setError = (0, import_react11.useCallback)((message) => {
743
+ clearTimer();
744
+ setState({ status: "error", message });
745
+ }, [clearTimer]);
746
+ const reset = (0, import_react11.useCallback)(() => {
747
+ clearTimer();
748
+ setState({ status: "idle" });
749
+ }, [clearTimer]);
750
+ return { state, pending: state.status === "pending", setPending, setSuccess, setError, reset };
751
+ }
752
+ function FormFeedback({ state, className, pendingLabel = "Guardando\u2026", successLabel = "Guardado" }) {
753
+ if (state.status === "idle") return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { "aria-hidden": "true", className: cn("inline-flex h-5 items-center", className) });
754
+ const error = state.status === "error";
755
+ const success = state.status === "success";
756
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("span", { role: error ? "alert" : "status", "aria-live": "polite", className: cn("inline-flex h-5 items-center gap-1.5 text-xs", error && "text-destructive", success && "text-success", state.status === "pending" && "text-muted-foreground", className), children: [
757
+ state.status === "pending" && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react12.CircleNotchIcon, { "aria-hidden": "true", className: "size-3.5 animate-spin" }),
758
+ success && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react12.CheckCircleIcon, { "aria-hidden": "true", className: "size-3.5", weight: "fill" }),
759
+ error && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react12.WarningCircleIcon, { "aria-hidden": "true", className: "size-3.5", weight: "fill" }),
760
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { children: state.status === "pending" ? pendingLabel : success ? state.message ?? successLabel : state.message })
761
+ ] });
762
+ }
763
+
764
+ // src/ui/form-row/form-row.tsx
765
+ var import_jsx_runtime21 = require("react/jsx-runtime");
766
+ function FormRow({ label, htmlFor, required, hint, error, className, children }) {
767
+ const hintId = hint ? `${htmlFor}-hint` : void 0;
768
+ const errorId = error ? `${htmlFor}-error` : void 0;
769
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { "data-slot": "form-row", className: cn("flex flex-col gap-1.5", className), children: [
770
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("label", { htmlFor, className: "text-sm font-medium text-foreground", children: [
771
+ label,
772
+ required && /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(import_jsx_runtime21.Fragment, { children: [
773
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { "aria-hidden": "true", className: "ml-0.5 text-destructive", children: "*" }),
774
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "sr-only", children: " (obligatorio)" })
775
+ ] })
776
+ ] }),
777
+ children,
778
+ hint && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { id: hintId, className: "text-xs text-muted-foreground", children: hint }),
779
+ error && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { id: errorId, role: "alert", className: "text-xs font-medium text-destructive", children: error })
780
+ ] });
781
+ }
782
+
783
+ // src/ui/icon-button/icon-button.tsx
784
+ var import_react_aria_components12 = require("react-aria-components");
785
+
786
+ // src/ui/tooltip/tooltip.tsx
787
+ var import_react_aria_components11 = require("react-aria-components");
788
+ var import_jsx_runtime22 = require("react/jsx-runtime");
789
+ var TooltipTrigger = import_react_aria_components11.TooltipTrigger;
790
+ function Tooltip({ className, ...props }) {
791
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_react_aria_components11.Tooltip, { "data-slot": "tooltip", offset: 6, className: cn("max-w-xs rounded-md bg-foreground px-2.5 py-1.5 text-xs text-background shadow-md outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
792
+ }
793
+ var TooltipContent = Tooltip;
794
+
795
+ // src/ui/icon-button/icon-button.tsx
796
+ var import_jsx_runtime23 = require("react/jsx-runtime");
797
+ function IconButton({
798
+ label,
799
+ children,
800
+ href,
801
+ className,
802
+ variant,
803
+ ...props
804
+ }) {
805
+ const linkClassName = cn(
806
+ buttonVariants({ variant, size: "icon" }),
807
+ className
808
+ );
809
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(TooltipTrigger, { children: [
810
+ href ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
811
+ import_react_aria_components12.Link,
812
+ {
813
+ "data-slot": "icon-button",
814
+ "aria-label": label,
815
+ href,
816
+ className: linkClassName,
817
+ children
818
+ }
819
+ ) : /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
820
+ Button2,
821
+ {
822
+ "data-slot": "icon-button",
823
+ "aria-label": label,
824
+ variant,
825
+ size: "icon",
826
+ className,
827
+ ...props,
828
+ children
829
+ }
830
+ ),
831
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Tooltip, { children: label })
832
+ ] });
833
+ }
834
+
835
+ // src/ui/input/input.tsx
836
+ var import_react13 = require("react");
837
+ var import_react_aria_components13 = require("react-aria-components");
838
+ var import_jsx_runtime24 = require("react/jsx-runtime");
839
+ var InputImpl = (0, import_react13.forwardRef)(function Input2({ className, type, ...props }, ref) {
840
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react_aria_components13.Input, { ref, type, "data-slot": "input", className: cn("h-8 w-full min-w-0 rounded-lg border border-border bg-background px-2.5 py-1 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive", className), ...props });
441
841
  });
442
842
  var Input3 = InputImpl;
443
843
 
444
- // src/ui/kbd.tsx
445
- var import_jsx_runtime12 = require("react/jsx-runtime");
844
+ // src/ui/input-group/input-group.tsx
845
+ var import_class_variance_authority3 = require("class-variance-authority");
846
+
847
+ // src/ui/textarea/textarea.tsx
848
+ var import_react14 = require("react");
849
+ var import_react_aria_components14 = require("react-aria-components");
850
+ var import_jsx_runtime25 = require("react/jsx-runtime");
851
+ var TextareaImpl = (0, import_react14.forwardRef)(function Textarea({ className, ...props }, ref) {
852
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_react_aria_components14.TextArea, { ref, "data-slot": "textarea", className: cn("min-h-20 w-full rounded-lg border border-border bg-background px-2.5 py-2 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive", className), ...props });
853
+ });
854
+ var Textarea2 = TextareaImpl;
855
+
856
+ // src/ui/input-group/input-group.tsx
857
+ var import_jsx_runtime26 = require("react/jsx-runtime");
858
+ function InputGroup({ className, ...props }) {
859
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { role: "group", "data-slot": "input-group", className: cn("group/input-group flex min-h-8 w-full min-w-0 items-center rounded-lg border border-border transition-colors 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", className), ...props });
860
+ }
861
+ var addonVariants = (0, import_class_variance_authority3.cva)("flex items-center justify-center gap-2 px-2 text-sm text-muted-foreground", { variants: { align: { "inline-start": "order-first", "inline-end": "order-last", "block-start": "w-full justify-start border-b py-2", "block-end": "w-full justify-start border-t py-2" } }, defaultVariants: { align: "inline-start" } });
862
+ function InputGroupAddon({ className, align, ...props }) {
863
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { "data-slot": "input-group-addon", "data-align": align, className: cn(addonVariants({ align }), className), ...props });
864
+ }
865
+ function InputGroupButton({ className, ...props }) {
866
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Button2, { "data-slot": "input-group-button", size: "icon", variant: "ghost", className: cn("size-7 shrink-0", className), ...props });
867
+ }
868
+ function InputGroupText({ className, ...props }) {
869
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { "data-slot": "input-group-text", className: cn("px-2 text-sm text-muted-foreground", className), ...props });
870
+ }
871
+ function InputGroupInput({ className, ...props }) {
872
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Input3, { "data-slot": "input-group-control", className: cn("flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0", className), ...props });
873
+ }
874
+ function InputGroupTextarea({ className, ...props }) {
875
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Textarea2, { "data-slot": "input-group-control", className: cn("flex-1 resize-none rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0", className), ...props });
876
+ }
877
+
878
+ // src/ui/kbd/kbd.tsx
879
+ var import_jsx_runtime27 = require("react/jsx-runtime");
446
880
  function Kbd({ className, ...props }) {
447
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("kbd", { "data-slot": "kbd", className: cn("pointer-events-none inline-flex h-5 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", className), ...props });
881
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("kbd", { "data-slot": "kbd", className: cn("pointer-events-none inline-flex h-5 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", className), ...props });
448
882
  }
449
883
  function KbdGroup({ className, ...props }) {
450
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { "data-slot": "kbd-group", className: cn("inline-flex items-center gap-1", className), ...props });
884
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { "data-slot": "kbd-group", className: cn("inline-flex items-center gap-1", className), ...props });
451
885
  }
452
886
 
453
- // src/ui/menu.tsx
454
- var import_react_aria_components7 = require("react-aria-components");
455
- var import_jsx_runtime13 = require("react/jsx-runtime");
456
- var MenuTrigger = import_react_aria_components7.MenuTrigger;
887
+ // src/ui/loading-overlay/loading-overlay.tsx
888
+ var import_react15 = require("@phosphor-icons/react");
889
+ var import_jsx_runtime28 = require("react/jsx-runtime");
890
+ function LoadingOverlay({ label = "Cargando", className, ...props }) {
891
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { role: "status", "aria-live": "polite", className: cn("absolute inset-0 z-10 flex items-center justify-center bg-background/70 backdrop-blur-[2px]", className), ...props, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "flex items-center gap-2 rounded-lg border border-border bg-background px-3 py-2 text-sm shadow-sm", children: [
892
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react15.CircleNotchIcon, { className: "animate-spin", "aria-hidden": "true" }),
893
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { children: label })
894
+ ] }) });
895
+ }
896
+
897
+ // src/ui/menu/menu.tsx
898
+ var import_react_aria_components15 = require("react-aria-components");
899
+ var import_jsx_runtime29 = require("react/jsx-runtime");
900
+ var MenuTrigger = import_react_aria_components15.MenuTrigger;
457
901
  function MenuContent({ className, ...props }) {
458
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.Popover, { "data-slot": "menu-content", className: cn("min-w-40 overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
902
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_aria_components15.Popover, { "data-slot": "menu-content", className: cn("min-w-40 overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
459
903
  }
460
904
  function Menu({ className, ...props }) {
461
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.Menu, { "data-slot": "menu", className: cn("outline-none", className), ...props });
905
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_aria_components15.Menu, { "data-slot": "menu", className: cn("outline-none", className), ...props });
462
906
  }
463
907
  function MenuItem({ className, children, ...props }) {
464
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_aria_components7.MenuItem, { "data-slot": "menu-item", className: cn("flex cursor-default items-center gap-2 rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props, children });
908
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_aria_components15.MenuItem, { "data-slot": "menu-item", className: cn("flex cursor-default items-center gap-2 rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props, children });
465
909
  }
466
910
 
467
- // src/ui/popover.tsx
468
- var import_react_aria_components8 = require("react-aria-components");
469
- var import_jsx_runtime14 = require("react/jsx-runtime");
470
- var PopoverTrigger = import_react_aria_components8.DialogTrigger;
471
- function Popover3({ className, ...props }) {
472
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_react_aria_components8.Popover, { "data-slot": "popover", offset: 6, className: cn("min-w-48 rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
911
+ // src/ui/page-header/page-header.tsx
912
+ var import_jsx_runtime30 = require("react/jsx-runtime");
913
+ function PageHeader({ className, ...props }) {
914
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("header", { "data-slot": "page-header", className: cn("flex flex-col gap-4 py-2 sm:flex-row sm:items-center sm:justify-between", className), ...props });
915
+ }
916
+ function PageHeaderHeading({ className, ...props }) {
917
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { "data-slot": "page-header-heading", className: cn("min-w-0", className), ...props });
918
+ }
919
+ function PageHeaderTitle({ className, ...props }) {
920
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("h1", { "data-slot": "page-header-title", className: cn("truncate text-xl font-semibold tracking-tight md:text-2xl", className), ...props });
921
+ }
922
+ function PageHeaderDescription({ className, ...props }) {
923
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("p", { "data-slot": "page-header-description", className: cn("mt-1 text-sm text-muted-foreground", className), ...props });
924
+ }
925
+ function PageHeaderActions({ className, ...props }) {
926
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { "data-slot": "page-header-actions", className: cn("flex shrink-0 items-center gap-2", className), ...props });
473
927
  }
474
- var PopoverContent = Popover3;
475
928
 
476
- // src/ui/search-field.tsx
477
- var import_react_aria_components9 = require("react-aria-components");
478
- var import_jsx_runtime15 = require("react/jsx-runtime");
479
- var SearchField = import_react_aria_components9.SearchField;
929
+ // src/ui/pagination/pagination.tsx
930
+ var import_react16 = require("@phosphor-icons/react");
931
+ var import_jsx_runtime31 = require("react/jsx-runtime");
932
+ function Pagination({ page, pageCount, onPageChange, className }) {
933
+ const pages = Array.from({ length: pageCount }, (_, index) => index + 1);
934
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("nav", { "aria-label": "Paginaci\xF3n", className: cn("flex items-center justify-between gap-4", className), children: [
935
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("p", { className: "text-sm text-muted-foreground", children: [
936
+ "P\xE1gina ",
937
+ page,
938
+ " de ",
939
+ pageCount
940
+ ] }),
941
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("div", { className: "flex items-center gap-1", children: [
942
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Button2, { "aria-label": "P\xE1gina anterior", isDisabled: page <= 1, onPress: () => onPageChange(page - 1), size: "icon", variant: "ghost", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react16.CaretLeftIcon, {}) }),
943
+ pages.map((item) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Button2, { "aria-current": item === page ? "page" : void 0, "aria-label": `P\xE1gina ${item}`, onPress: () => onPageChange(item), size: "icon", variant: item === page ? "secondary" : "ghost", children: item }, item)),
944
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Button2, { "aria-label": "P\xE1gina siguiente", isDisabled: page >= pageCount, onPress: () => onPageChange(page + 1), size: "icon", variant: "ghost", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react16.CaretRightIcon, {}) })
945
+ ] })
946
+ ] });
947
+ }
948
+
949
+ // src/ui/popover/popover.tsx
950
+ var import_react_aria_components16 = require("react-aria-components");
951
+ var import_jsx_runtime32 = require("react/jsx-runtime");
952
+ var PopoverTrigger = import_react_aria_components16.DialogTrigger;
953
+ function Popover4({ className, ...props }) {
954
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_aria_components16.Popover, { "data-slot": "popover", offset: 6, className: cn("min-w-48 rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
955
+ }
956
+ var PopoverContent = Popover4;
957
+
958
+ // src/ui/quantity-input/quantity-input.tsx
959
+ var import_react17 = require("@phosphor-icons/react");
960
+ var import_react_aria_components17 = require("react-aria-components");
961
+ var import_jsx_runtime33 = require("react/jsx-runtime");
962
+ function QuantityInput({
963
+ className,
964
+ inputClassName,
965
+ decrementAriaLabel = "Disminuir cantidad",
966
+ incrementAriaLabel = "Aumentar cantidad",
967
+ minValue = 0,
968
+ step = 1,
969
+ ...props
970
+ }) {
971
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
972
+ import_react_aria_components17.NumberField,
973
+ {
974
+ ...props,
975
+ minValue,
976
+ step,
977
+ "data-slot": "quantity-input",
978
+ className: cn("group/quantity-input inline-flex min-w-0 data-disabled:cursor-not-allowed data-disabled:opacity-50", className),
979
+ children: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
980
+ import_react_aria_components17.Group,
981
+ {
982
+ "data-slot": "quantity-input-group",
983
+ className: "flex h-8 min-w-0 items-stretch overflow-hidden rounded-lg border border-border bg-background text-foreground transition-[border-color,box-shadow] focus-within:border-ring focus-within:ring-3 focus-within:ring-ring/50 group-data-invalid/quantity-input:border-destructive",
984
+ children: [
985
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_aria_components17.Button, { slot: "decrement", "aria-label": decrementAriaLabel, "data-slot": "quantity-input-decrement", className: "flex size-8 shrink-0 cursor-pointer items-center justify-center border-r border-border text-muted-foreground outline-none transition-colors hover:bg-muted hover:text-foreground data-focus-visible:bg-muted data-pressed:bg-muted data-disabled:pointer-events-none", children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react17.MinusIcon, { "aria-hidden": "true", weight: "bold", className: "size-4" }) }),
986
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_aria_components17.Input, { "data-slot": "quantity-input-value", className: cn("w-14 min-w-0 bg-transparent px-1 text-center text-sm tabular-nums outline-none", inputClassName) }),
987
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_aria_components17.Button, { slot: "increment", "aria-label": incrementAriaLabel, "data-slot": "quantity-input-increment", className: "flex size-8 shrink-0 cursor-pointer items-center justify-center border-l border-border text-muted-foreground outline-none transition-colors hover:bg-muted hover:text-foreground data-focus-visible:bg-muted data-pressed:bg-muted data-disabled:pointer-events-none", children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react17.PlusIcon, { "aria-hidden": "true", weight: "bold", className: "size-4" }) })
988
+ ]
989
+ }
990
+ )
991
+ }
992
+ );
993
+ }
994
+
995
+ // src/ui/search-field/search-field.tsx
996
+ var import_react_aria_components18 = require("react-aria-components");
997
+ var import_react18 = require("@phosphor-icons/react");
998
+ var import_jsx_runtime34 = require("react/jsx-runtime");
999
+ var SearchField = import_react_aria_components18.SearchField;
480
1000
  function SearchInput({ className, ...props }) {
481
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_aria_components9.Input, { "data-slot": "search-input", className: cn("h-8 w-full min-w-0 rounded-lg border border-border bg-background px-2.5 py-1 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50", className), ...props });
1001
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(import_react_aria_components18.Input, { "data-slot": "search-input", className: cn("h-8 w-full min-w-0 rounded-lg border border-border bg-background px-2.5 py-1 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50", className), ...props });
482
1002
  }
483
- function SearchClearButton({ className, children = "\xD7", ...props }) {
484
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_aria_components9.Button, { slot: "clear", "data-slot": "search-clear", className: cn("absolute top-1/2 right-1 -translate-y-1/2 rounded p-1 text-muted-foreground outline-none hover:bg-muted data-focus-visible:ring-2 data-focus-visible:ring-ring", className), ...props, children });
1003
+ function SearchClearButton({ className, children = /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(import_react18.XIcon, { "aria-hidden": "true", weight: "bold", className: "size-4" }), ...props }) {
1004
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(import_react_aria_components18.Button, { slot: "clear", "data-slot": "search-clear", className: cn("absolute top-1/2 right-1 rounded p-1 text-muted-foreground outline-none hover:bg-muted data-focus-visible:ring-2 data-focus-visible:ring-ring", className), ...props, children });
485
1005
  }
486
1006
 
487
- // src/ui/select.tsx
488
- var import_react_aria_components10 = require("react-aria-components");
489
- var import_jsx_runtime16 = require("react/jsx-runtime");
490
- var Select = import_react_aria_components10.Select;
1007
+ // src/ui/select/select.tsx
1008
+ var import_react_aria_components19 = require("react-aria-components");
1009
+ var import_react19 = require("@phosphor-icons/react");
1010
+ var import_jsx_runtime35 = require("react/jsx-runtime");
1011
+ var Select = import_react_aria_components19.Select;
491
1012
  function SelectTrigger({ className, children, ...props }) {
492
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components10.Button, { "data-slot": "select-trigger", className: cn("flex h-8 w-full min-w-36 items-center gap-2 rounded-lg border border-border bg-background px-2.5 text-left text-sm text-foreground outline-none data-focus-visible:ring-3 data-focus-visible:ring-ring/50 data-disabled:cursor-not-allowed data-disabled:opacity-50", className), ...props, children: (state) => /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, { children: [
1013
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react_aria_components19.Button, { "data-slot": "select-trigger", className: cn("group/select-trigger flex h-8 w-full min-w-36 items-center gap-2 rounded-lg border border-border bg-background px-2.5 text-left text-sm text-foreground outline-none data-focus-visible:ring-3 data-focus-visible:ring-ring/50 data-disabled:cursor-not-allowed data-disabled:opacity-50", className), ...props, children: (state) => /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx_runtime35.Fragment, { children: [
493
1014
  typeof children === "function" ? children(state) : children,
494
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { "aria-hidden": "true", className: "ml-auto text-muted-foreground", children: "\u2304" })
1015
+ /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react19.CaretDownIcon, { "aria-hidden": "true", weight: "bold", className: "ml-auto size-4 text-muted-foreground transition-transform group-data-pressed/select-trigger:rotate-180 motion-reduce:transition-none" })
495
1016
  ] }) });
496
1017
  }
497
1018
  function SelectValue({ className, ...props }) {
498
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components10.SelectValue, { "data-slot": "select-value", className: cn("flex-1 truncate data-placeholder:text-muted-foreground", className), ...props });
1019
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react_aria_components19.SelectValue, { "data-slot": "select-value", className: cn("flex-1 truncate data-placeholder:text-muted-foreground", className), ...props });
499
1020
  }
500
1021
  function SelectContent({ className, ...props }) {
501
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components10.Popover, { "data-slot": "select-content", className: cn("w-(--trigger-width) overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
1022
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react_aria_components19.Popover, { "data-slot": "select-content", className: cn("w-(--trigger-width) overflow-hidden rounded-xl border border-border bg-background p-1.5 text-foreground shadow-lg motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
502
1023
  }
503
1024
  function SelectList({ className, ...props }) {
504
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components10.ListBox, { "data-slot": "select-list", className: cn("max-h-64 overflow-y-auto", className), ...props });
1025
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react_aria_components19.ListBox, { "data-slot": "select-list", className: cn("max-h-64 overflow-y-auto", className), ...props });
505
1026
  }
506
1027
  function SelectItem({ className, children, ...props }) {
507
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_aria_components10.ListBoxItem, { "data-slot": "select-item", className: cn("flex cursor-default items-center gap-2 rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-selected:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props, children });
1028
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react_aria_components19.ListBoxItem, { "data-slot": "select-item", className: cn("flex cursor-default items-center gap-2 rounded-md px-2 py-1.5 text-sm outline-none data-focused:bg-muted data-selected:bg-muted data-disabled:pointer-events-none data-disabled:opacity-50", className), ...props, children });
508
1029
  }
509
1030
 
510
- // src/ui/separator.tsx
511
- var import_react_aria_components11 = require("react-aria-components");
512
- var import_jsx_runtime17 = require("react/jsx-runtime");
1031
+ // src/ui/separator/separator.tsx
1032
+ var import_react_aria_components20 = require("react-aria-components");
1033
+ var import_jsx_runtime36 = require("react/jsx-runtime");
513
1034
  function Separator({ className, orientation = "horizontal", ...props }) {
514
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_react_aria_components11.Separator, { "data-slot": "separator", orientation, className: cn("shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch", className), ...props });
1035
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_react_aria_components20.Separator, { "data-slot": "separator", orientation, className: cn("shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch", className), ...props });
515
1036
  }
516
1037
 
517
- // src/ui/skeleton.tsx
518
- var import_jsx_runtime18 = require("react/jsx-runtime");
1038
+ // src/ui/sidebar/sidebar.tsx
1039
+ var import_react20 = require("@phosphor-icons/react");
1040
+ var import_react21 = require("react");
1041
+ var import_react_aria_components21 = require("react-aria-components");
1042
+ var import_jsx_runtime37 = require("react/jsx-runtime");
1043
+ var SidebarContext = (0, import_react21.createContext)(null);
1044
+ function useSidebar() {
1045
+ const context = (0, import_react21.useContext)(SidebarContext);
1046
+ if (!context)
1047
+ throw new Error("useSidebar must be used inside SidebarProvider");
1048
+ return context;
1049
+ }
1050
+ function SidebarProvider({
1051
+ defaultCollapsed = false,
1052
+ children
1053
+ }) {
1054
+ const [collapsed, setCollapsed] = (0, import_react21.useState)(defaultCollapsed);
1055
+ const value = (0, import_react21.useMemo)(
1056
+ () => ({
1057
+ collapsed,
1058
+ setCollapsed,
1059
+ toggle: () => setCollapsed((current) => !current)
1060
+ }),
1061
+ [collapsed]
1062
+ );
1063
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(SidebarContext.Provider, { value, children });
1064
+ }
1065
+ function Sidebar({
1066
+ className,
1067
+ ...props
1068
+ }) {
1069
+ const { collapsed } = useSidebar();
1070
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1071
+ "aside",
1072
+ {
1073
+ "data-slot": "sidebar",
1074
+ "data-collapsed": collapsed || void 0,
1075
+ className: cn(
1076
+ "group/sidebar flex h-full w-56 shrink-0 flex-col border-r border-border bg-card text-foreground transition-[width] duration-200 ease-out motion-reduce:transition-none data-[collapsed]:w-16",
1077
+ className
1078
+ ),
1079
+ ...props
1080
+ }
1081
+ );
1082
+ }
1083
+ function SidebarHeader({
1084
+ className,
1085
+ ...props
1086
+ }) {
1087
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1088
+ "div",
1089
+ {
1090
+ "data-slot": "sidebar-header",
1091
+ className: cn("flex items-center gap-2 px-4 py-5", className),
1092
+ ...props
1093
+ }
1094
+ );
1095
+ }
1096
+ function SidebarSearch({
1097
+ label = "Buscar\u2026",
1098
+ shortcut = "\u2318K",
1099
+ className,
1100
+ ...props
1101
+ }) {
1102
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
1103
+ "button",
1104
+ {
1105
+ type: "button",
1106
+ "data-slot": "sidebar-search",
1107
+ className: cn(
1108
+ "group flex w-full items-center gap-2 rounded-md border border-border bg-background px-2.5 py-1.5 text-sm text-muted-foreground transition-colors hover:border-primary/40 hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
1109
+ className
1110
+ ),
1111
+ ...props,
1112
+ children: [
1113
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react20.MagnifyingGlassIcon, { className: "size-4 shrink-0" }),
1114
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "flex-1 text-left", children: label }),
1115
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("kbd", { className: "rounded bg-secondary px-1.5 py-0.5 font-mono text-[10px] text-muted-foreground", children: shortcut })
1116
+ ]
1117
+ }
1118
+ );
1119
+ }
1120
+ function SidebarContent({
1121
+ className,
1122
+ ...props
1123
+ }) {
1124
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1125
+ "nav",
1126
+ {
1127
+ "data-slot": "sidebar-content",
1128
+ "aria-label": "Navegaci\xF3n principal",
1129
+ className: cn("min-h-0 flex-1 overflow-y-auto px-2 py-1", className),
1130
+ ...props
1131
+ }
1132
+ );
1133
+ }
1134
+ function SidebarFooter({
1135
+ className,
1136
+ ...props
1137
+ }) {
1138
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1139
+ "div",
1140
+ {
1141
+ "data-slot": "sidebar-footer",
1142
+ className: cn(
1143
+ "mt-auto flex flex-col gap-2 border-t border-border p-2",
1144
+ className
1145
+ ),
1146
+ ...props
1147
+ }
1148
+ );
1149
+ }
1150
+ function SidebarGroup({
1151
+ label,
1152
+ className,
1153
+ children,
1154
+ ...props
1155
+ }) {
1156
+ const { collapsed } = useSidebar();
1157
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
1158
+ "section",
1159
+ {
1160
+ "data-slot": "sidebar-group",
1161
+ className: cn("mb-4 last:mb-0", className),
1162
+ ...props,
1163
+ children: [
1164
+ label && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1165
+ "h2",
1166
+ {
1167
+ className: cn(
1168
+ "mb-1 px-3 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground",
1169
+ collapsed && "sr-only"
1170
+ ),
1171
+ children: label
1172
+ }
1173
+ ),
1174
+ children
1175
+ ]
1176
+ }
1177
+ );
1178
+ }
1179
+ function SidebarItem({
1180
+ icon,
1181
+ active,
1182
+ badge,
1183
+ label,
1184
+ children,
1185
+ className,
1186
+ ...props
1187
+ }) {
1188
+ const { collapsed } = useSidebar();
1189
+ const content = typeof children === "function" ? label : children ?? label;
1190
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1191
+ import_react_aria_components21.Link,
1192
+ {
1193
+ "data-slot": "sidebar-item",
1194
+ "aria-current": active ? "page" : void 0,
1195
+ "aria-label": collapsed && label ? label : void 0,
1196
+ className: cn(
1197
+ "group/item relative flex min-h-9 items-center gap-2.5 rounded-md px-2.5 py-2 text-sm text-muted-foreground outline-none transition-[background-color,color,transform] duration-150 hover:bg-secondary/60 hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring/40 data-[current=page]:bg-secondary data-[current=page]:font-medium data-[current=page]:text-foreground data-pressed:scale-[0.98] motion-reduce:transition-none",
1198
+ collapsed && "justify-center px-0",
1199
+ typeof className === "function" ? className : className
1200
+ ),
1201
+ ...props,
1202
+ children: (values) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_jsx_runtime37.Fragment, { children: [
1203
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "flex size-4 shrink-0 items-center justify-center", children: icon }),
1204
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1205
+ "span",
1206
+ {
1207
+ className: cn("min-w-0 flex-1 truncate", collapsed && "sr-only"),
1208
+ children: typeof children === "function" ? children(values) : content
1209
+ }
1210
+ ),
1211
+ badge && !collapsed && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "text-xs text-muted-foreground", children: badge })
1212
+ ] })
1213
+ }
1214
+ );
1215
+ }
1216
+ function SidebarSeparator({
1217
+ className,
1218
+ ...props
1219
+ }) {
1220
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1221
+ "hr",
1222
+ {
1223
+ "data-slot": "sidebar-separator",
1224
+ className: cn("my-2 h-px border-0 bg-border", className),
1225
+ ...props
1226
+ }
1227
+ );
1228
+ }
1229
+ function SidebarTrigger({ className, ...props }) {
1230
+ const { collapsed, toggle } = useSidebar();
1231
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1232
+ Button2,
1233
+ {
1234
+ "aria-label": collapsed ? "Expandir navegaci\xF3n" : "Colapsar navegaci\xF3n",
1235
+ onPress: toggle,
1236
+ size: "icon",
1237
+ variant: "ghost",
1238
+ className: cn("ml-auto", className),
1239
+ ...props,
1240
+ children: collapsed ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react20.CaretRightIcon, {}) : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react20.CaretLeftIcon, {})
1241
+ }
1242
+ );
1243
+ }
1244
+ function SidebarRail({
1245
+ className,
1246
+ ...props
1247
+ }) {
1248
+ const { toggle } = useSidebar();
1249
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1250
+ "button",
1251
+ {
1252
+ type: "button",
1253
+ "aria-label": "Alternar navegaci\xF3n",
1254
+ onClick: toggle,
1255
+ className: cn(
1256
+ "absolute inset-y-0 right-0 z-20 hidden w-1 -translate-x-1/2 cursor-ew-resize bg-transparent transition-colors hover:bg-border lg:block",
1257
+ className
1258
+ ),
1259
+ ...props
1260
+ }
1261
+ );
1262
+ }
1263
+ function SidebarMore({ className, ...props }) {
1264
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1265
+ Button2,
1266
+ {
1267
+ "aria-label": "M\xE1s opciones",
1268
+ size: "icon",
1269
+ variant: "ghost",
1270
+ className: cn("size-7", className),
1271
+ ...props,
1272
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react20.DotsThreeIcon, { weight: "bold" })
1273
+ }
1274
+ );
1275
+ }
1276
+
1277
+ // src/ui/skeleton/skeleton.tsx
1278
+ var import_jsx_runtime38 = require("react/jsx-runtime");
519
1279
  function Skeleton({ className, ...props }) {
520
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { "aria-hidden": "true", "data-slot": "skeleton", className: cn("animate-pulse rounded-md bg-muted", className), ...props });
1280
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { "aria-hidden": "true", "data-slot": "skeleton", className: cn("animate-pulse rounded-md bg-muted", className), ...props });
521
1281
  }
522
1282
 
523
- // src/ui/switch.tsx
524
- var import_react_aria_components12 = require("react-aria-components");
525
- var import_jsx_runtime19 = require("react/jsx-runtime");
526
- function Switch({ className, children, ...props }) {
527
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_react_aria_components12.Switch, { "data-slot": "switch", className: cn("group inline-flex items-center gap-2 text-sm text-foreground data-disabled:cursor-not-allowed data-disabled:opacity-50", className), ...props, children: (state) => /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(import_jsx_runtime19.Fragment, { children: [
528
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { "aria-hidden": "true", className: "flex h-5 w-9 items-center rounded-full bg-muted p-0.5 transition-colors group-data-selected:bg-primary group-data-focus-visible:ring-3 group-data-focus-visible:ring-ring/50", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "size-4 rounded-full bg-background shadow-sm transition-transform group-data-selected:translate-x-4" }) }),
529
- typeof children === "function" ? children(state) : children
530
- ] }) });
1283
+ // src/ui/submit-button/submit-button.tsx
1284
+ var import_react_dom = require("react-dom");
1285
+ var import_react22 = require("@phosphor-icons/react");
1286
+ var import_jsx_runtime39 = require("react/jsx-runtime");
1287
+ function SubmitButton({ pendingLabel = "Guardando\u2026", loading = false, children, isDisabled, size = "sm", ...props }) {
1288
+ const { pending } = (0, import_react_dom.useFormStatus)();
1289
+ const busy = pending || loading;
1290
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Button2, { type: "submit", size, isDisabled: busy || isDisabled, "aria-busy": busy || void 0, ...props, children: busy ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_jsx_runtime39.Fragment, { children: [
1291
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react22.CircleNotchIcon, { "aria-hidden": "true", className: "size-3.5 animate-spin" }),
1292
+ pendingLabel
1293
+ ] }) : children });
531
1294
  }
532
1295
 
533
- // src/ui/table.tsx
534
- var import_jsx_runtime20 = require("react/jsx-runtime");
1296
+ // src/ui/switch/switch.tsx
1297
+ var import_react_aria_components22 = require("react-aria-components");
1298
+ var import_jsx_runtime40 = require("react/jsx-runtime");
1299
+ var sizeStyles = {
1300
+ sm: { track: "h-5 w-9 p-0.5", thumb: "size-4", travel: "group-data-selected/switch:translate-x-4" },
1301
+ md: { track: "h-6 w-11 p-0.5", thumb: "size-5", travel: "group-data-selected/switch:translate-x-5" }
1302
+ };
1303
+ function Switch({ className, children, size = "sm", ...props }) {
1304
+ const styles = sizeStyles[size];
1305
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_aria_components22.SwitchField, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1306
+ import_react_aria_components22.SwitchButton,
1307
+ {
1308
+ "data-slot": "switch",
1309
+ "data-size": size,
1310
+ className: (state) => cn(
1311
+ "group/switch inline-flex w-max items-center gap-2 text-sm text-foreground outline-none",
1312
+ "data-disabled:cursor-not-allowed data-disabled:opacity-50",
1313
+ typeof className === "function" ? className(state) : className
1314
+ ),
1315
+ children: (state) => /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_jsx_runtime40.Fragment, { children: [
1316
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1317
+ "span",
1318
+ {
1319
+ "aria-hidden": "true",
1320
+ className: cn(
1321
+ "relative inline-flex shrink-0 items-center rounded-full border border-transparent bg-secondary",
1322
+ "shadow-[inset_0_1px_2px_rgb(0_0_0/0.08)]",
1323
+ "transition-[background-color,box-shadow] duration-200 ease-out",
1324
+ "group-data-selected/switch:bg-primary group-data-hovered/switch:bg-secondary/80",
1325
+ "group-data-selected/switch:group-data-hovered/switch:bg-primary/90",
1326
+ "group-data-focus-visible/switch:ring-3 group-data-focus-visible/switch:ring-ring/40",
1327
+ "group-data-pressed/switch:ring-4 group-data-pressed/switch:ring-primary/10",
1328
+ "motion-reduce:transition-none",
1329
+ styles.track
1330
+ ),
1331
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1332
+ "span",
1333
+ {
1334
+ className: cn(
1335
+ "pointer-events-none block rounded-full bg-background shadow-[0_1px_2px_rgb(0_0_0/0.18)]",
1336
+ "transition-[transform,background-color,box-shadow] duration-200 ease-[cubic-bezier(0.22,1,0.36,1)]",
1337
+ "group-data-selected/switch:bg-primary-foreground group-data-selected/switch:shadow-[0_1px_3px_rgb(0_0_0/0.22)]",
1338
+ "group-data-pressed/switch:scale-[0.94] motion-reduce:transition-none",
1339
+ styles.travel,
1340
+ styles.thumb
1341
+ )
1342
+ }
1343
+ )
1344
+ }
1345
+ ),
1346
+ children != null && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("span", { className: "select-none font-medium leading-5 text-foreground", children: typeof children === "function" ? children(state) : children })
1347
+ ] })
1348
+ }
1349
+ ) });
1350
+ }
1351
+
1352
+ // src/ui/table/table.tsx
1353
+ var import_jsx_runtime41 = require("react/jsx-runtime");
535
1354
  function Table({ className, ...props }) {
536
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { "data-slot": "table-container", className: "relative w-full overflow-x-auto", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("table", { "data-slot": "table", className: cn("w-full caption-bottom text-sm", className), ...props }) });
1355
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { "data-slot": "table-container", className: "relative w-full overflow-x-auto", children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("table", { "data-slot": "table", className: cn("w-full caption-bottom text-sm", className), ...props }) });
537
1356
  }
538
1357
  function TableHeader({ className, ...props }) {
539
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("thead", { "data-slot": "table-header", className: cn("border-b border-border", className), ...props });
1358
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("thead", { "data-slot": "table-header", className: cn("border-b border-border", className), ...props });
540
1359
  }
541
1360
  function TableBody({ className, ...props }) {
542
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("tbody", { "data-slot": "table-body", className: cn("[&_tr:last-child]:border-0", className), ...props });
1361
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("tbody", { "data-slot": "table-body", className: cn("[&_tr:last-child]:border-0", className), ...props });
543
1362
  }
544
1363
  function TableRow({ className, ...props }) {
545
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("tr", { "data-slot": "table-row", className: cn("border-b border-border transition-colors hover:bg-muted/50", className), ...props });
1364
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("tr", { "data-slot": "table-row", className: cn("border-b border-border transition-colors hover:bg-muted/50", className), ...props });
546
1365
  }
547
1366
  function TableHead({ className, ...props }) {
548
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("th", { "data-slot": "table-head", className: cn("h-10 px-3 text-left align-middle text-xs font-medium text-muted-foreground", className), ...props });
1367
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("th", { "data-slot": "table-head", className: cn("h-10 px-3 text-left align-middle text-xs font-medium text-muted-foreground", className), ...props });
549
1368
  }
550
1369
  function TableCell({ className, ...props }) {
551
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("td", { "data-slot": "table-cell", className: cn("p-3 align-middle", className), ...props });
1370
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("td", { "data-slot": "table-cell", className: cn("p-3 align-middle", className), ...props });
552
1371
  }
553
1372
  function TableCaption({ className, ...props }) {
554
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("caption", { "data-slot": "table-caption", className: cn("mt-4 text-sm text-muted-foreground", className), ...props });
1373
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("caption", { "data-slot": "table-caption", className: cn("mt-4 text-sm text-muted-foreground", className), ...props });
555
1374
  }
556
1375
 
557
- // src/ui/tabs.tsx
558
- var import_react_aria_components13 = require("react-aria-components");
559
- var import_jsx_runtime21 = require("react/jsx-runtime");
1376
+ // src/ui/tabs/tabs.tsx
1377
+ var import_react_aria_components23 = require("react-aria-components");
1378
+ var import_jsx_runtime42 = require("react/jsx-runtime");
560
1379
  function Tabs({ className, ...props }) {
561
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_aria_components13.Tabs, { "data-slot": "tabs", className: (0, import_react_aria_components13.composeRenderProps)(className, (value) => cn("flex flex-col gap-2", value)), ...props });
1380
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_aria_components23.Tabs, { "data-slot": "tabs", className: (0, import_react_aria_components23.composeRenderProps)(className, (value) => cn("flex flex-col gap-2", value)), ...props });
562
1381
  }
563
1382
  function TabsList({ className, ...props }) {
564
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_aria_components13.TabList, { "data-slot": "tabs-list", className: (0, import_react_aria_components13.composeRenderProps)(className, (value) => cn("inline-flex w-fit items-center gap-1 rounded-lg bg-muted p-1 text-muted-foreground", value)), ...props });
1383
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_aria_components23.TabList, { "data-slot": "tabs-list", className: (0, import_react_aria_components23.composeRenderProps)(className, (value) => cn("inline-flex w-fit items-center gap-1 rounded-lg bg-muted p-1 text-muted-foreground", value)), ...props });
565
1384
  }
566
1385
  function TabsTrigger({ className, ...props }) {
567
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_aria_components13.Tab, { "data-slot": "tabs-trigger", className: (0, import_react_aria_components13.composeRenderProps)(className, (value) => cn("inline-flex h-7 items-center justify-center gap-1.5 rounded-md px-2.5 text-sm font-medium outline-none transition-colors data-hovered:text-foreground data-selected:bg-background data-selected:text-foreground data-selected:shadow-sm data-focus-visible:ring-3 data-focus-visible:ring-ring/50 data-disabled:cursor-not-allowed data-disabled:opacity-50", value)), ...props });
1386
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_aria_components23.Tab, { "data-slot": "tabs-trigger", className: (0, import_react_aria_components23.composeRenderProps)(className, (value) => cn("inline-flex h-7 items-center justify-center gap-1.5 rounded-md px-2.5 text-sm font-medium outline-none transition-colors data-hovered:text-foreground data-selected:bg-background data-selected:text-foreground data-selected:shadow-sm data-focus-visible:ring-3 data-focus-visible:ring-ring/50 data-disabled:cursor-not-allowed data-disabled:opacity-50", value)), ...props });
568
1387
  }
569
1388
  function TabsPanels({ className, ...props }) {
570
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_aria_components13.TabPanels, { "data-slot": "tabs-panels", className: cn("min-w-0", className), ...props });
1389
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_aria_components23.TabPanels, { "data-slot": "tabs-panels", className: cn("min-w-0", className), ...props });
571
1390
  }
572
1391
  function TabsContent({ className, ...props }) {
573
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_aria_components13.TabPanel, { "data-slot": "tabs-content", className: (0, import_react_aria_components13.composeRenderProps)(className, (value) => cn("text-sm outline-none data-focus-visible:ring-3 data-focus-visible:ring-ring/50", value)), ...props });
1392
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_aria_components23.TabPanel, { "data-slot": "tabs-content", className: (0, import_react_aria_components23.composeRenderProps)(className, (value) => cn("text-sm outline-none data-focus-visible:ring-3 data-focus-visible:ring-ring/50", value)), ...props });
574
1393
  }
575
1394
 
576
- // src/ui/textarea.tsx
577
- var import_react8 = require("react");
578
- var import_react_aria_components14 = require("react-aria-components");
579
- var import_jsx_runtime22 = require("react/jsx-runtime");
580
- var TextareaImpl = (0, import_react8.forwardRef)(function Textarea({ className, ...props }, ref) {
581
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_react_aria_components14.TextArea, { ref, "data-slot": "textarea", className: cn("min-h-20 w-full rounded-lg border border-border bg-background px-2.5 py-2 text-sm text-foreground outline-none placeholder:text-muted-foreground focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive", className), ...props });
1395
+ // src/ui/toast/toast.tsx
1396
+ var import_react23 = require("react");
1397
+ var import_react24 = require("@phosphor-icons/react");
1398
+ var import_jsx_runtime43 = require("react/jsx-runtime");
1399
+ var records = [];
1400
+ var listeners = /* @__PURE__ */ new Set();
1401
+ var snapshot = () => records;
1402
+ var emit = () => listeners.forEach((listener) => listener());
1403
+ var subscribe = (listener) => {
1404
+ listeners.add(listener);
1405
+ return () => listeners.delete(listener);
1406
+ };
1407
+ var remove = (id) => {
1408
+ records = records.filter((record) => record.id !== id);
1409
+ emit();
1410
+ };
1411
+ function create(options) {
1412
+ const id = `${Date.now()}-${Math.random().toString(36).slice(2)}`;
1413
+ records = [...records, { ...options, id, state: "open", variant: options.variant ?? "default", duration: options.duration ?? 5e3, position: options.position ?? "bottom-right" }];
1414
+ emit();
1415
+ return id;
1416
+ }
1417
+ function dismiss(id) {
1418
+ if (!records.some((record) => record.id === id && record.state === "open")) return;
1419
+ records = records.map((record) => record.id === id ? { ...record, state: "closing" } : record);
1420
+ emit();
1421
+ window.setTimeout(() => remove(id), 180);
1422
+ }
1423
+ function update(id, patch) {
1424
+ records = records.map((record) => record.id === id ? { ...record, ...patch, state: "open" } : record);
1425
+ emit();
1426
+ }
1427
+ var toast = Object.assign((options) => create(options), {
1428
+ success: (title, options) => create({ ...options, title, variant: "success" }),
1429
+ error: (title, options) => create({ ...options, title, variant: "error" }),
1430
+ warning: (title, options) => create({ ...options, title, variant: "warning" }),
1431
+ info: (title, options) => create({ ...options, title, variant: "info" }),
1432
+ dismiss,
1433
+ promise: (promise, options) => {
1434
+ const id = create({ title: options.loading, description: options.description, variant: "default", duration: 0, position: options.position });
1435
+ promise.then((value) => update(id, { title: typeof options.success === "function" ? options.success(value) : options.success, variant: "success", duration: 4e3 })).catch((error) => update(id, { title: typeof options.error === "function" ? options.error(error) : options.error, variant: "error", duration: 6e3 }));
1436
+ return promise;
1437
+ }
582
1438
  });
583
- var Textarea2 = TextareaImpl;
1439
+ function useToast() {
1440
+ return toast;
1441
+ }
1442
+ function ToastProvider({ children }) {
1443
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_jsx_runtime43.Fragment, { children: [
1444
+ children,
1445
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Toaster, {})
1446
+ ] });
1447
+ }
1448
+ var positionClasses = {
1449
+ "top-left": "top-4 left-4 items-start",
1450
+ "top-center": "top-4 left-1/2 -translate-x-1/2 items-center",
1451
+ "top-right": "top-4 right-4 items-end",
1452
+ "bottom-left": "bottom-4 left-4 items-start",
1453
+ "bottom-center": "bottom-4 left-1/2 -translate-x-1/2 items-center",
1454
+ "bottom-right": "bottom-4 right-4 items-end"
1455
+ };
1456
+ function Toaster({ position = "bottom-right" }) {
1457
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_jsx_runtime43.Fragment, { children: Object.keys(positionClasses).map((item) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(ToastViewport, { position: item, visiblePosition: position }, item)) });
1458
+ }
1459
+ function ToastViewport({ position, visiblePosition, className }) {
1460
+ const toasts = (0, import_react23.useSyncExternalStore)(subscribe, snapshot, snapshot).filter((item) => item.position === position);
1461
+ if (visiblePosition && position !== visiblePosition && toasts.length === 0) return null;
1462
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { "aria-label": `Notificaciones ${position}`, className: cn("pointer-events-none fixed z-50 flex w-[min(24rem,calc(100vw-2rem))] flex-col gap-2", positionClasses[position], className), children: toasts.map((item) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Toast, { ...item, onDismiss: () => dismiss(item.id) }, item.id)) });
1463
+ }
1464
+ function Toast({ id, title, description, variant = "default", action, state = "open", duration = 0, onDismiss }) {
1465
+ (0, import_react23.useEffect)(() => {
1466
+ if (state !== "open" || duration <= 0) return;
1467
+ const timeout = window.setTimeout(() => dismiss(id), duration);
1468
+ return () => window.clearTimeout(timeout);
1469
+ }, [duration, id, state]);
1470
+ const Icon = variant === "success" ? import_react24.CheckCircleIcon : variant === "error" ? import_react24.XCircleIcon : variant === "warning" ? import_react24.WarningCircleIcon : variant === "info" ? import_react24.InfoIcon : import_react24.InfoIcon;
1471
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { role: variant === "error" ? "alert" : "status", "data-state": state, className: cn("pointer-events-auto w-full overflow-hidden rounded-xl border border-border/80 bg-background/95 p-3.5 text-foreground shadow-xl shadow-black/10 backdrop-blur-md animate-ui-toast-in", "data-[state=closing]:animate-ui-toast-out motion-reduce:animate-none", variant === "success" && "border-success/30", variant === "error" && "border-destructive/30", variant === "warning" && "border-warning/40"), children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex items-start gap-3", children: [
1472
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Icon, { "aria-hidden": "true", weight: "duotone", className: cn("mt-0.5 size-5 shrink-0", variant === "success" && "text-success", variant === "error" && "text-destructive", variant === "warning" && "text-warning", variant === "info" && "text-primary") }),
1473
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "min-w-0 flex-1", children: [
1474
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("p", { className: "animate-ui-toast-title text-sm font-semibold", children: title }),
1475
+ description && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("p", { className: "mt-1 max-h-20 animate-ui-toast-description overflow-hidden text-sm leading-5 text-muted-foreground data-[state=closing]:max-h-0", "data-state": state, children: description }),
1476
+ action && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Button2, { size: "sm", variant: "link", onPress: action.onPress, className: "mt-1 h-auto px-0", children: action.label })
1477
+ ] }),
1478
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Button2, { "aria-label": "Cerrar notificaci\xF3n", onPress: onDismiss, size: "icon", variant: "ghost", className: "-mr-2 -mt-2 size-7", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react24.XIcon, {}) })
1479
+ ] }) });
1480
+ }
584
1481
 
585
- // src/ui/tooltip.tsx
586
- var import_react_aria_components15 = require("react-aria-components");
587
- var import_jsx_runtime23 = require("react/jsx-runtime");
588
- var TooltipTrigger = import_react_aria_components15.TooltipTrigger;
589
- function Tooltip({ className, ...props }) {
590
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_react_aria_components15.Tooltip, { "data-slot": "tooltip", offset: 6, className: cn("max-w-xs rounded-md bg-foreground px-2.5 py-1.5 text-xs text-background shadow-md outline-none motion-safe:data-entering:animate-ui-surface-in motion-safe:data-exiting:animate-ui-surface-out", className), ...props });
1482
+ // src/ui/toolbar/toolbar.tsx
1483
+ var import_jsx_runtime44 = require("react/jsx-runtime");
1484
+ function Toolbar({ className, ...props }) {
1485
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { role: "toolbar", "data-slot": "toolbar", className: cn("flex flex-wrap items-center gap-2", className), ...props });
1486
+ }
1487
+ function ToolbarGroup({ className, ...props }) {
1488
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { "data-slot": "toolbar-group", className: cn("flex items-center gap-2", className), ...props });
1489
+ }
1490
+ function ToolbarSpacer({ className, ...props }) {
1491
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { "aria-hidden": "true", className: cn("hidden flex-1 sm:block", className), ...props });
591
1492
  }
592
- var TooltipContent = Tooltip;
593
1493
  // Annotate the CommonJS export names for ESM import in node:
594
1494
  0 && (module.exports = {
1495
+ Accordion,
1496
+ AccordionContent,
1497
+ AccordionItem,
1498
+ AccordionTrigger,
1499
+ Alert,
1500
+ AlertAction,
1501
+ AlertDescription,
1502
+ AlertTitle,
1503
+ AppShell,
1504
+ AppShellContent,
1505
+ AppShellHeader,
1506
+ AppShellMain,
1507
+ AutocompleteCombobox,
1508
+ Avatar,
1509
+ AvatarBadge,
1510
+ AvatarFallback,
1511
+ AvatarGroup,
1512
+ AvatarGroupCount,
1513
+ AvatarImage,
595
1514
  Badge,
1515
+ Breadcrumb,
1516
+ BreadcrumbLink,
1517
+ BreadcrumbPage,
1518
+ BreadcrumbSeparator,
1519
+ Breadcrumbs,
596
1520
  Button,
1521
+ ButtonGroup,
1522
+ ButtonGroupText,
597
1523
  Card,
598
1524
  CardContent,
599
1525
  CardDescription,
@@ -607,6 +1533,11 @@ var TooltipContent = Tooltip;
607
1533
  ComboboxItem,
608
1534
  ComboboxList,
609
1535
  ComboboxValue,
1536
+ Command,
1537
+ CommandContent,
1538
+ CommandInput,
1539
+ CommandItem,
1540
+ CommandList,
610
1541
  ConfirmDialog,
611
1542
  Dialog,
612
1543
  DialogClose,
@@ -615,6 +1546,16 @@ var TooltipContent = Tooltip;
615
1546
  DialogFooter,
616
1547
  DialogHeader,
617
1548
  DialogTitle,
1549
+ Drawer,
1550
+ DrawerDescription,
1551
+ DrawerFooter,
1552
+ DrawerHeader,
1553
+ DrawerTitle,
1554
+ DropdownMenu,
1555
+ DropdownMenuContent,
1556
+ DropdownMenuItem,
1557
+ DropdownMenuSeparator,
1558
+ DropdownMenuTrigger,
618
1559
  EmptyState,
619
1560
  EmptyStateDescription,
620
1561
  EmptyStateTitle,
@@ -622,18 +1563,35 @@ var TooltipContent = Tooltip;
622
1563
  FieldDescription,
623
1564
  FieldError,
624
1565
  FieldLabel,
1566
+ FormFeedback,
1567
+ FormRow,
625
1568
  HighlightMatch,
1569
+ IconButton,
626
1570
  Input,
1571
+ InputGroup,
1572
+ InputGroupAddon,
1573
+ InputGroupButton,
1574
+ InputGroupInput,
1575
+ InputGroupText,
1576
+ InputGroupTextarea,
627
1577
  Kbd,
628
1578
  KbdGroup,
629
1579
  Label,
1580
+ LoadingOverlay,
630
1581
  Menu,
631
1582
  MenuContent,
632
1583
  MenuItem,
633
1584
  MenuTrigger,
1585
+ PageHeader,
1586
+ PageHeaderActions,
1587
+ PageHeaderDescription,
1588
+ PageHeaderHeading,
1589
+ PageHeaderTitle,
1590
+ Pagination,
634
1591
  Popover,
635
1592
  PopoverContent,
636
1593
  PopoverTrigger,
1594
+ QuantityInput,
637
1595
  SearchClearButton,
638
1596
  SearchField,
639
1597
  SearchInput,
@@ -644,7 +1602,20 @@ var TooltipContent = Tooltip;
644
1602
  SelectTrigger,
645
1603
  SelectValue,
646
1604
  Separator,
1605
+ Sidebar,
1606
+ SidebarContent,
1607
+ SidebarFooter,
1608
+ SidebarGroup,
1609
+ SidebarHeader,
1610
+ SidebarItem,
1611
+ SidebarMore,
1612
+ SidebarProvider,
1613
+ SidebarRail,
1614
+ SidebarSearch,
1615
+ SidebarSeparator,
1616
+ SidebarTrigger,
647
1617
  Skeleton,
1618
+ SubmitButton,
648
1619
  Switch,
649
1620
  Table,
650
1621
  TableBody,
@@ -659,6 +1630,13 @@ var TooltipContent = Tooltip;
659
1630
  TabsPanels,
660
1631
  TabsTrigger,
661
1632
  Textarea,
1633
+ Toast,
1634
+ ToastProvider,
1635
+ ToastViewport,
1636
+ Toaster,
1637
+ Toolbar,
1638
+ ToolbarGroup,
1639
+ ToolbarSpacer,
662
1640
  Tooltip,
663
1641
  TooltipContent,
664
1642
  TooltipTrigger,
@@ -667,8 +1645,12 @@ var TooltipContent = Tooltip;
667
1645
  cn,
668
1646
  formSnapshot,
669
1647
  getTextMatchParts,
1648
+ toast,
670
1649
  useAutosave,
671
1650
  useDebouncedValue,
672
- useFormDirty
1651
+ useFormDirty,
1652
+ useFormFeedback,
1653
+ useSidebar,
1654
+ useToast
673
1655
  });
674
1656
  //# sourceMappingURL=index.cjs.map