@andreagiugni/tailwind-dashboard-ui 1.0.2 → 1.0.4

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.js CHANGED
@@ -1,9 +1,9 @@
1
1
  "use client";
2
2
  export { BarChart } from './chunk-YAKIMPXZ.js';
3
3
  export { LineChart } from './chunk-NWIOJGF7.js';
4
- export { Calendar, Modal } from './chunk-PYZG7RY7.js';
5
- export { Editor } from './chunk-OYBYDSNI.js';
6
- export { ColorPicker } from './chunk-W3TC7P3Z.js';
4
+ export { Calendar, Modal } from './chunk-NJBVRPWW.js';
5
+ export { Editor } from './chunk-PFCUA2W2.js';
6
+ export { ColorPicker } from './chunk-OD6N6XWO.js';
7
7
  import { layers } from './chunk-VX7S6VYG.js';
8
8
  import { cn } from './chunk-ZLIYUUA4.js';
9
9
  export { cn } from './chunk-ZLIYUUA4.js';
@@ -234,7 +234,7 @@ var Alert = ({
234
234
  className: cn("rounded-xl border p-4", variantClasses2[variant].container, className),
235
235
  ...rest,
236
236
  children: /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-3", children: [
237
- /* @__PURE__ */ jsx("div", { className: cn("-mt-0.5", variantClasses2[variant].icon), children: icon ?? /* @__PURE__ */ jsx(Icon, { className: "h-6 w-6", "aria-hidden": "true" }) }),
237
+ /* @__PURE__ */ jsx("div", { className: cn("-mt-0.5", variantClasses2[variant].icon), children: icon ?? /* @__PURE__ */ jsx(Icon, { className: "size-4", "aria-hidden": "true" }) }),
238
238
  /* @__PURE__ */ jsxs("div", { children: [
239
239
  /* @__PURE__ */ jsx("h4", { className: "mb-1 text-sm font-semibold text-gray-800 dark:text-white/90", children: title }),
240
240
  /* @__PURE__ */ jsx("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: message }),
@@ -455,7 +455,7 @@ var DropdownItem = ({
455
455
  "span",
456
456
  {
457
457
  "aria-hidden": "true",
458
- className: "flex h-5 w-5 shrink-0 items-center justify-center [&>svg]:h-5 [&>svg]:w-5",
458
+ className: "flex h-5 w-5 shrink-0 items-center justify-center [&>svg]:size-4",
459
459
  children: icon
460
460
  }
461
461
  ),
@@ -521,7 +521,7 @@ var Dropzone = ({
521
521
  }
522
522
  ),
523
523
  /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center", children: [
524
- /* @__PURE__ */ jsx("div", { className: "mb-[22px] flex justify-center", children: /* @__PURE__ */ jsx("div", { className: "flex h-[68px] w-[68px] items-center justify-center rounded-full bg-gray-200 text-gray-700 dark:bg-gray-800 dark:text-gray-400", children: /* @__PURE__ */ jsx(Upload, { className: "h-7 w-7", "aria-hidden": "true" }) }) }),
524
+ /* @__PURE__ */ jsx("div", { className: "mb-[22px] flex justify-center", children: /* @__PURE__ */ jsx("div", { className: "flex h-[68px] w-[68px] items-center justify-center rounded-full bg-gray-200 text-gray-700 dark:bg-gray-800 dark:text-gray-400", children: /* @__PURE__ */ jsx(Upload, { className: "size-4", "aria-hidden": "true" }) }) }),
525
525
  /* @__PURE__ */ jsx("h4", { className: "mb-3 text-theme-xl font-semibold text-gray-800 dark:text-white/90", children: title ?? (isDragActive ? "Drop Files Here" : "Drag & Drop Files Here") }),
526
526
  /* @__PURE__ */ jsx("span", { className: "mb-5 block w-full max-w-[290px] text-center text-sm text-gray-700 dark:text-gray-400", children: description }),
527
527
  /* @__PURE__ */ jsx("span", { className: "text-theme-sm font-medium text-brand-500 underline", children: browseLabel })
@@ -677,7 +677,7 @@ function SortIcon({
677
677
  {
678
678
  "data-sort-direction": "asc",
679
679
  "aria-hidden": "true",
680
- className: cn("h-3 w-3", state === "asc" ? active : inactive)
680
+ className: cn("size-4", state === "asc" ? active : inactive)
681
681
  }
682
682
  ),
683
683
  /* @__PURE__ */ jsx(
@@ -685,7 +685,7 @@ function SortIcon({
685
685
  {
686
686
  "data-sort-direction": "desc",
687
687
  "aria-hidden": "true",
688
- className: cn("h-3 w-3", state === "desc" ? active : inactive)
688
+ className: cn("size-4", state === "desc" ? active : inactive)
689
689
  }
690
690
  )
691
691
  ]
@@ -784,7 +784,7 @@ function DataDrivenTable({
784
784
  ChevronDown,
785
785
  {
786
786
  "aria-hidden": "true",
787
- className: "pointer-events-none absolute right-3 top-1/2 h-4 w-4 -translate-y-1/2 text-gray-500 dark:text-gray-400"
787
+ className: "pointer-events-none absolute right-3 top-1/2 size-4 -translate-y-1/2 text-gray-500 dark:text-gray-400"
788
788
  }
789
789
  )
790
790
  ] }),
@@ -940,7 +940,7 @@ function Table({
940
940
  }
941
941
  return /* @__PURE__ */ jsx("table", { className: cn("min-w-full", className), ...rest, children });
942
942
  }
943
- var ChevronIcon = () => /* @__PURE__ */ jsx(ChevronRight, { className: "h-4 w-4", strokeWidth: 1.5, "aria-hidden": "true" });
943
+ var ChevronIcon = () => /* @__PURE__ */ jsx(ChevronRight, { className: "size-4", strokeWidth: 1.5, "aria-hidden": "true" });
944
944
  var Breadcrumb = ({ pageTitle, items }) => {
945
945
  return /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center justify-between gap-3 mb-6", children: [
946
946
  /* @__PURE__ */ jsx(
@@ -1010,8 +1010,8 @@ var ThemeToggleButton = ({
1010
1010
  ),
1011
1011
  ...rest,
1012
1012
  children: [
1013
- /* @__PURE__ */ jsx(Sun, { className: "hidden h-5 w-5 dark:block", "aria-hidden": "true" }),
1014
- /* @__PURE__ */ jsx(Moon, { className: "h-5 w-5 dark:hidden", "aria-hidden": "true" })
1013
+ /* @__PURE__ */ jsx(Sun, { className: "hidden size-4 dark:block", "aria-hidden": "true" }),
1014
+ /* @__PURE__ */ jsx(Moon, { className: "size-4 dark:hidden", "aria-hidden": "true" })
1015
1015
  ]
1016
1016
  }
1017
1017
  );
@@ -1126,7 +1126,7 @@ var Toast = ({
1126
1126
  "flex h-10 w-10 shrink-0 items-center justify-center rounded-lg",
1127
1127
  styles.iconWrap
1128
1128
  ),
1129
- children: icon ?? /* @__PURE__ */ jsx(Icon, { className: "h-5 w-5", "aria-hidden": "true" })
1129
+ children: icon ?? /* @__PURE__ */ jsx(Icon, { className: "size-4", "aria-hidden": "true" })
1130
1130
  }
1131
1131
  ),
1132
1132
  /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
@@ -1140,7 +1140,7 @@ var Toast = ({
1140
1140
  "aria-label": "Close",
1141
1141
  onClick: onClose,
1142
1142
  className: "absolute right-3 top-1/2 -translate-y-1/2 text-gray-400 transition hover:text-gray-700 dark:hover:text-gray-200",
1143
- children: /* @__PURE__ */ jsx(X, { className: "h-[18px] w-[18px]", "aria-hidden": "true" })
1143
+ children: /* @__PURE__ */ jsx(X, { className: "size-4", "aria-hidden": "true" })
1144
1144
  }
1145
1145
  ),
1146
1146
  !hideAccentBar && /* @__PURE__ */ jsx(
@@ -1159,7 +1159,7 @@ var ChevronIcon2 = ({ open }) => /* @__PURE__ */ jsx(
1159
1159
  ChevronDown,
1160
1160
  {
1161
1161
  className: cn(
1162
- "h-5 w-5 shrink-0 text-gray-500 transition-transform duration-200 dark:text-gray-400",
1162
+ "size-4 shrink-0 text-gray-500 transition-transform duration-200 dark:text-gray-400",
1163
1163
  open && "rotate-180"
1164
1164
  ),
1165
1165
  "aria-hidden": "true"
@@ -1638,7 +1638,7 @@ var Drawer = ({
1638
1638
  onClick: onClose,
1639
1639
  "aria-label": "Close drawer",
1640
1640
  className: "absolute right-3 top-3 z-99 flex h-9.5 w-9.5 items-center justify-center rounded-full bg-gray-100 text-gray-400 transition-colors hover:bg-gray-200 hover:text-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white",
1641
- children: /* @__PURE__ */ jsx(X, { className: "h-6 w-6", "aria-hidden": "true" })
1641
+ children: /* @__PURE__ */ jsx(X, { className: "size-4", "aria-hidden": "true" })
1642
1642
  }
1643
1643
  ),
1644
1644
  children
@@ -1711,7 +1711,7 @@ var Chip = ({
1711
1711
  "aria-label": "Remove",
1712
1712
  onClick: onClose,
1713
1713
  className: "ml-0.5 flex h-4 w-4 items-center justify-center rounded-full text-current opacity-70 transition hover:opacity-100 focus:outline-none",
1714
- children: /* @__PURE__ */ jsx(X, { className: "h-3 w-3", strokeWidth: 2, "aria-hidden": "true" })
1714
+ children: /* @__PURE__ */ jsx(X, { className: "size-4", strokeWidth: 2, "aria-hidden": "true" })
1715
1715
  }
1716
1716
  )
1717
1717
  ]
@@ -1977,7 +1977,7 @@ var Snippet = ({
1977
1977
  "absolute right-2 top-2 inline-flex h-7 w-7 items-center justify-center rounded-lg text-gray-500 transition hover:bg-gray-200 hover:text-gray-700 focus:outline-hidden focus:ring-3 focus:ring-brand-500/10 dark:text-gray-400 dark:hover:bg-white/10 dark:hover:text-white/90",
1978
1978
  copied && "text-success-500 dark:text-success-500"
1979
1979
  ),
1980
- children: copied ? /* @__PURE__ */ jsx(Check, { className: "h-4 w-4", "aria-hidden": "true" }) : /* @__PURE__ */ jsx(Copy, { className: "h-4 w-4", "aria-hidden": "true" })
1980
+ children: copied ? /* @__PURE__ */ jsx(Check, { className: "size-4", "aria-hidden": "true" }) : /* @__PURE__ */ jsx(Copy, { className: "size-4", "aria-hidden": "true" })
1981
1981
  }
1982
1982
  )
1983
1983
  ]
@@ -2077,7 +2077,7 @@ var Checkbox = ({
2077
2077
  checked && /* @__PURE__ */ jsx(
2078
2078
  Check,
2079
2079
  {
2080
- className: "pointer-events-none absolute left-1/2 top-1/2 h-3.5 w-3.5 -translate-x-1/2 -translate-y-1/2 text-white",
2080
+ className: "pointer-events-none absolute left-1/2 top-1/2 size-4 -translate-x-1/2 -translate-y-1/2 text-white",
2081
2081
  strokeWidth: 3,
2082
2082
  "aria-hidden": "true"
2083
2083
  }
@@ -2085,7 +2085,7 @@ var Checkbox = ({
2085
2085
  disabled && /* @__PURE__ */ jsx(
2086
2086
  Check,
2087
2087
  {
2088
- className: "pointer-events-none absolute left-1/2 top-1/2 h-3.5 w-3.5 -translate-x-1/2 -translate-y-1/2 text-gray-200",
2088
+ className: "pointer-events-none absolute left-1/2 top-1/2 size-4 -translate-x-1/2 -translate-y-1/2 text-gray-200",
2089
2089
  strokeWidth: 3,
2090
2090
  "aria-hidden": "true"
2091
2091
  }
@@ -2330,7 +2330,7 @@ var Select = ({
2330
2330
  "span",
2331
2331
  {
2332
2332
  "aria-hidden": "true",
2333
- className: "flex h-5 w-5 shrink-0 items-center justify-center [&>svg]:h-4 [&>svg]:w-4",
2333
+ className: "flex h-5 w-5 shrink-0 items-center justify-center [&>svg]:size-4",
2334
2334
  children: selectedOption.icon
2335
2335
  }
2336
2336
  ),
@@ -2340,7 +2340,7 @@ var Select = ({
2340
2340
  ChevronDown,
2341
2341
  {
2342
2342
  className: cn(
2343
- "ml-2 h-5 w-5 shrink-0 stroke-current text-gray-500 transition-transform dark:text-gray-400",
2343
+ "ml-2 size-4 shrink-0 stroke-current text-gray-500 transition-transform dark:text-gray-400",
2344
2344
  isOpen && "rotate-180"
2345
2345
  ),
2346
2346
  "aria-hidden": "true"
@@ -2375,7 +2375,7 @@ var Select = ({
2375
2375
  "span",
2376
2376
  {
2377
2377
  "aria-hidden": "true",
2378
- className: "flex h-5 w-5 shrink-0 items-center justify-center [&>svg]:h-4 [&>svg]:w-4",
2378
+ className: "flex h-5 w-5 shrink-0 items-center justify-center [&>svg]:size-4",
2379
2379
  children: option.icon
2380
2380
  }
2381
2381
  ),
@@ -2384,7 +2384,7 @@ var Select = ({
2384
2384
  isSelected && /* @__PURE__ */ jsx(
2385
2385
  Check,
2386
2386
  {
2387
- className: "ml-2 h-4 w-4 shrink-0 stroke-current",
2387
+ className: "ml-2 size-4 shrink-0 stroke-current",
2388
2388
  "aria-hidden": "true"
2389
2389
  }
2390
2390
  )
@@ -2438,7 +2438,7 @@ var MultiSelect = ({
2438
2438
  {
2439
2439
  onClick: () => removeOption(index, selectedOptions[index]),
2440
2440
  className: "pl-2 text-gray-500 cursor-pointer group-hover:text-gray-400 dark:text-gray-400",
2441
- children: /* @__PURE__ */ jsx(X, { className: "h-3.5 w-3.5", role: "button", "aria-hidden": "true" })
2441
+ children: /* @__PURE__ */ jsx(X, { className: "size-4", role: "button", "aria-hidden": "true" })
2442
2442
  }
2443
2443
  ) })
2444
2444
  ]
@@ -2462,7 +2462,7 @@ var MultiSelect = ({
2462
2462
  children: /* @__PURE__ */ jsx(
2463
2463
  ChevronDown,
2464
2464
  {
2465
- className: `stroke-current ${isOpen ? "rotate-180" : ""}`,
2465
+ className: `size-4 stroke-current ${isOpen ? "rotate-180" : ""}`,
2466
2466
  "aria-hidden": "true"
2467
2467
  }
2468
2468
  )
@@ -2499,7 +2499,7 @@ var MultiSelect = ({
2499
2499
  isSelected && /* @__PURE__ */ jsx(
2500
2500
  Check,
2501
2501
  {
2502
- className: "mr-2 h-4 w-4 shrink-0 stroke-current text-brand-500",
2502
+ className: "mr-2 size-4 shrink-0 stroke-current text-brand-500",
2503
2503
  "aria-hidden": "true"
2504
2504
  }
2505
2505
  )
@@ -2561,7 +2561,7 @@ var DatePicker = ({
2561
2561
  className: "h-11 w-full rounded-lg border appearance-none pl-4 pr-11 py-2.5 text-sm shadow-theme-xs placeholder:text-gray-400 focus:outline-hidden focus:ring-3 dark:bg-gray-900 dark:text-white/90 dark:placeholder:text-white/30 bg-white text-gray-800 border-gray-300 focus:border-brand-300 focus:ring-brand-500/20 dark:border-gray-700 dark:focus:border-brand-800"
2562
2562
  }
2563
2563
  ),
2564
- /* @__PURE__ */ jsx("span", { className: "absolute text-gray-500 -translate-y-1/2 pointer-events-none right-3 top-1/2 dark:text-gray-400", children: /* @__PURE__ */ jsx(Calendar, { className: "size-6", "aria-hidden": "true" }) })
2564
+ /* @__PURE__ */ jsx("span", { className: "absolute text-gray-500 -translate-y-1/2 pointer-events-none right-3 top-1/2 dark:text-gray-400", children: /* @__PURE__ */ jsx(Calendar, { className: "size-4", "aria-hidden": "true" }) })
2565
2565
  ] })
2566
2566
  ] });
2567
2567
  };
@@ -2637,7 +2637,7 @@ var DateTimePicker = ({
2637
2637
  className: "h-11 w-full appearance-none rounded-lg border border-gray-300 bg-white py-2.5 pl-4 pr-11 text-sm text-gray-800 shadow-theme-xs placeholder:text-gray-400 focus:border-brand-300 focus:outline-hidden focus:ring-3 focus:ring-brand-500/20 dark:border-gray-700 dark:bg-gray-900 dark:text-white/90 dark:placeholder:text-white/30 dark:focus:border-brand-800"
2638
2638
  }
2639
2639
  ),
2640
- /* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute right-3 top-1/2 -translate-y-1/2 text-gray-500 dark:text-gray-400", children: /* @__PURE__ */ jsx(Calendar, { className: "size-6", "aria-hidden": "true" }) })
2640
+ /* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute right-3 top-1/2 -translate-y-1/2 text-gray-500 dark:text-gray-400", children: /* @__PURE__ */ jsx(Calendar, { className: "size-4", "aria-hidden": "true" }) })
2641
2641
  ] }),
2642
2642
  /* @__PURE__ */ jsxs("div", { className: "flex h-11 items-center rounded-lg border border-gray-300 bg-white px-3 text-sm text-gray-800 shadow-theme-xs focus-within:border-brand-300 focus-within:ring-3 focus-within:ring-brand-500/20 dark:border-gray-700 dark:bg-gray-900 dark:text-white/90 dark:focus-within:border-brand-800", children: [
2643
2643
  /* @__PURE__ */ jsx(
@@ -2667,7 +2667,7 @@ var DateTimePicker = ({
2667
2667
  className: timeFieldClass
2668
2668
  }
2669
2669
  ),
2670
- /* @__PURE__ */ jsx("span", { className: "ml-1 text-gray-500 dark:text-gray-400", children: /* @__PURE__ */ jsx(Clock, { className: "h-5 w-5", "aria-hidden": "true" }) })
2670
+ /* @__PURE__ */ jsx("span", { className: "ml-1 text-gray-500 dark:text-gray-400", children: /* @__PURE__ */ jsx(Clock, { className: "size-4", "aria-hidden": "true" }) })
2671
2671
  ] })
2672
2672
  ] })
2673
2673
  ] });
@@ -2696,7 +2696,7 @@ var PasswordInput = ({
2696
2696
  onClick: () => setShow((s) => !s),
2697
2697
  "aria-label": show ? "Hide password" : "Show password",
2698
2698
  className: "absolute right-4 top-1/2 z-30 -translate-y-1/2 cursor-pointer text-gray-500 dark:text-gray-400",
2699
- children: show ? /* @__PURE__ */ jsx(Eye, { className: "h-5 w-5", "aria-hidden": "true" }) : /* @__PURE__ */ jsx(EyeOff, { className: "h-5 w-5", "aria-hidden": "true" })
2699
+ children: show ? /* @__PURE__ */ jsx(Eye, { className: "size-4", "aria-hidden": "true" }) : /* @__PURE__ */ jsx(EyeOff, { className: "size-4", "aria-hidden": "true" })
2700
2700
  }
2701
2701
  )
2702
2702
  ] });