@devalok/shilp-sutra 0.30.0 → 0.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (266) hide show
  1. package/README.md +82 -239
  2. package/dist/_chunks/badge-group.js +123 -171
  3. package/dist/_chunks/document-preview.js +92 -0
  4. package/dist/_chunks/file-preview.js +511 -0
  5. package/dist/_chunks/image-preview.js +90 -0
  6. package/dist/_chunks/primitives.js +109 -109
  7. package/dist/_chunks/stat-row.js +144 -124
  8. package/dist/_chunks/use-calendar.js +558 -490
  9. package/dist/ai/block-renderer.d.ts +2 -1
  10. package/dist/ai/block-renderer.d.ts.map +1 -1
  11. package/dist/ai/block-renderer.js +30 -29
  12. package/dist/ai/blocks/block-table.d.ts.map +1 -1
  13. package/dist/ai/blocks/confirm.d.ts.map +1 -1
  14. package/dist/ai/blocks/divider.d.ts.map +1 -1
  15. package/dist/ai/blocks/error.d.ts.map +1 -1
  16. package/dist/ai/blocks/info.d.ts.map +1 -1
  17. package/dist/ai/blocks/loading.d.ts.map +1 -1
  18. package/dist/ai/blocks/stat-row.d.ts.map +1 -1
  19. package/dist/ai/blocks/success.d.ts.map +1 -1
  20. package/dist/ai/blocks/text.d.ts.map +1 -1
  21. package/dist/ai/command-bar.d.ts +18 -0
  22. package/dist/ai/command-bar.d.ts.map +1 -1
  23. package/dist/ai/command-bar.js +126 -125
  24. package/dist/ai/conversation.d.ts +13 -1
  25. package/dist/ai/conversation.d.ts.map +1 -1
  26. package/dist/ai/conversation.js +78 -78
  27. package/dist/ai/types.d.ts +0 -1
  28. package/dist/ai/types.d.ts.map +1 -1
  29. package/dist/ai/types.js +1 -0
  30. package/dist/composed/bulk-action-bar.d.ts +6 -4
  31. package/dist/composed/bulk-action-bar.d.ts.map +1 -1
  32. package/dist/composed/bulk-action-bar.js +102 -58
  33. package/dist/composed/command-palette.d.ts +9 -0
  34. package/dist/composed/command-palette.d.ts.map +1 -1
  35. package/dist/composed/command-palette.js +68 -68
  36. package/dist/composed/confirm-dialog.d.ts +1 -1
  37. package/dist/composed/confirm-dialog.d.ts.map +1 -1
  38. package/dist/composed/confirm-dialog.js +10 -10
  39. package/dist/composed/content-card.d.ts.map +1 -1
  40. package/dist/composed/date-picker/date-picker.d.ts +11 -1
  41. package/dist/composed/date-picker/date-picker.d.ts.map +1 -1
  42. package/dist/composed/date-picker/month-picker.d.ts.map +1 -1
  43. package/dist/composed/date-picker/year-picker.d.ts.map +1 -1
  44. package/dist/composed/deadline-indicator.d.ts +1 -1
  45. package/dist/composed/deadline-indicator.d.ts.map +1 -1
  46. package/dist/composed/deadline-indicator.js +39 -36
  47. package/dist/composed/emoji-picker.d.ts +6 -0
  48. package/dist/composed/emoji-picker.d.ts.map +1 -1
  49. package/dist/composed/emoji-picker.js +22 -20
  50. package/dist/composed/error-boundary.d.ts +21 -1
  51. package/dist/composed/error-boundary.d.ts.map +1 -1
  52. package/dist/composed/error-boundary.js +47 -32
  53. package/dist/composed/file-preview/audio-preview.d.ts +7 -0
  54. package/dist/composed/file-preview/audio-preview.d.ts.map +1 -0
  55. package/dist/composed/file-preview/document-preview.d.ts +7 -0
  56. package/dist/composed/file-preview/document-preview.d.ts.map +1 -0
  57. package/dist/composed/file-preview/embed-preview.d.ts +7 -0
  58. package/dist/composed/file-preview/embed-preview.d.ts.map +1 -0
  59. package/dist/composed/file-preview/image-preview.d.ts +7 -0
  60. package/dist/composed/file-preview/image-preview.d.ts.map +1 -0
  61. package/dist/composed/file-preview/shared.d.ts +20 -0
  62. package/dist/composed/file-preview/shared.d.ts.map +1 -0
  63. package/dist/composed/file-preview/video-preview.d.ts +6 -0
  64. package/dist/composed/file-preview/video-preview.d.ts.map +1 -0
  65. package/dist/composed/file-preview.d.ts.map +1 -1
  66. package/dist/composed/file-preview.js +10 -662
  67. package/dist/composed/filter-bar.d.ts +10 -2
  68. package/dist/composed/filter-bar.d.ts.map +1 -1
  69. package/dist/composed/filter-bar.js +42 -43
  70. package/dist/composed/form-section.d.ts +1 -1
  71. package/dist/composed/form-section.d.ts.map +1 -1
  72. package/dist/composed/form-section.js +22 -21
  73. package/dist/composed/index.d.ts +2 -2
  74. package/dist/composed/index.d.ts.map +1 -1
  75. package/dist/composed/index.js +58 -57
  76. package/dist/composed/inline-edit.d.ts +1 -1
  77. package/dist/composed/inline-edit.d.ts.map +1 -1
  78. package/dist/composed/inline-edit.js +33 -32
  79. package/dist/composed/lib/string-utils.d.ts.map +1 -1
  80. package/dist/composed/loading-skeleton.d.ts.map +1 -1
  81. package/dist/composed/markdown-viewer.d.ts +1 -1
  82. package/dist/composed/markdown-viewer.d.ts.map +1 -1
  83. package/dist/composed/markdown-viewer.js +60 -59
  84. package/dist/composed/master-detail.d.ts +11 -7
  85. package/dist/composed/master-detail.d.ts.map +1 -1
  86. package/dist/composed/master-detail.js +123 -84
  87. package/dist/composed/page-header.d.ts.map +1 -1
  88. package/dist/composed/page-skeletons.d.ts.map +1 -1
  89. package/dist/composed/priority-indicator.d.ts +1 -0
  90. package/dist/composed/priority-indicator.js +1 -0
  91. package/dist/composed/responsive-overlay.d.ts +8 -0
  92. package/dist/composed/responsive-overlay.d.ts.map +1 -1
  93. package/dist/composed/rich-text-editor.d.ts +11 -3
  94. package/dist/composed/rich-text-editor.d.ts.map +1 -1
  95. package/dist/composed/rich-text-editor.js +21 -20
  96. package/dist/composed/schedule-view.d.ts +9 -1
  97. package/dist/composed/schedule-view.d.ts.map +1 -1
  98. package/dist/hooks/index.d.ts +2 -0
  99. package/dist/hooks/index.d.ts.map +1 -1
  100. package/dist/hooks/index.js +8 -4
  101. package/dist/hooks/use-touch-device.d.ts +12 -0
  102. package/dist/hooks/use-touch-device.d.ts.map +1 -0
  103. package/dist/hooks/use-touch-device.js +13 -0
  104. package/dist/hooks/use-viewport-height.d.ts +11 -0
  105. package/dist/hooks/use-viewport-height.d.ts.map +1 -0
  106. package/dist/hooks/use-viewport-height.js +16 -0
  107. package/dist/shell/bottom-navbar.d.ts.map +1 -1
  108. package/dist/shell/bottom-navbar.js +72 -63
  109. package/dist/shell/command-registry.d.ts.map +1 -1
  110. package/dist/shell/notification-center.d.ts.map +1 -1
  111. package/dist/shell/notification-center.js +77 -77
  112. package/dist/shell/top-bar.d.ts +2 -2
  113. package/dist/shell/top-bar.d.ts.map +1 -1
  114. package/dist/shell/top-bar.js +61 -60
  115. package/dist/tailwind/index.cjs +51 -7
  116. package/dist/tailwind/preset.d.ts.map +1 -1
  117. package/dist/tailwind/preset.js +51 -7
  118. package/dist/tokens/primitives.css +3 -1
  119. package/dist/tokens/semantic.css +16 -13
  120. package/dist/tokens/typography.css +33 -4
  121. package/dist/ui/alert.d.ts +1 -0
  122. package/dist/ui/alert.d.ts.map +1 -1
  123. package/dist/ui/alert.js +42 -37
  124. package/dist/ui/autocomplete.d.ts.map +1 -1
  125. package/dist/ui/autocomplete.js +38 -39
  126. package/dist/ui/badge.d.ts +110 -2
  127. package/dist/ui/badge.d.ts.map +1 -1
  128. package/dist/ui/banner.d.ts.map +1 -1
  129. package/dist/ui/banner.js +8 -7
  130. package/dist/ui/button.d.ts +2 -2
  131. package/dist/ui/button.d.ts.map +1 -1
  132. package/dist/ui/button.js +54 -74
  133. package/dist/ui/card.d.ts +5 -1
  134. package/dist/ui/card.d.ts.map +1 -1
  135. package/dist/ui/card.js +111 -79
  136. package/dist/ui/charts/area-chart.d.ts +2 -0
  137. package/dist/ui/charts/area-chart.d.ts.map +1 -1
  138. package/dist/ui/charts/bar-chart.d.ts +2 -0
  139. package/dist/ui/charts/bar-chart.d.ts.map +1 -1
  140. package/dist/ui/charts/chart-container.d.ts +2 -0
  141. package/dist/ui/charts/chart-container.d.ts.map +1 -1
  142. package/dist/ui/charts/index.js +583 -577
  143. package/dist/ui/charts/line-chart.d.ts +2 -0
  144. package/dist/ui/charts/line-chart.d.ts.map +1 -1
  145. package/dist/ui/charts/pie-chart.d.ts +2 -0
  146. package/dist/ui/charts/pie-chart.d.ts.map +1 -1
  147. package/dist/ui/charts/radar-chart.d.ts +2 -0
  148. package/dist/ui/charts/radar-chart.d.ts.map +1 -1
  149. package/dist/ui/checkbox.d.ts +2 -0
  150. package/dist/ui/checkbox.d.ts.map +1 -1
  151. package/dist/ui/checkbox.js +36 -27
  152. package/dist/ui/code.d.ts.map +1 -1
  153. package/dist/ui/color-input.js +5 -5
  154. package/dist/ui/combobox.d.ts +6 -1
  155. package/dist/ui/combobox.d.ts.map +1 -1
  156. package/dist/ui/combobox.js +1 -1
  157. package/dist/ui/container.d.ts.map +1 -1
  158. package/dist/ui/context-menu.js +1 -1
  159. package/dist/ui/data-table-body.d.ts +12 -0
  160. package/dist/ui/data-table-body.d.ts.map +1 -0
  161. package/dist/ui/data-table-body.js +219 -0
  162. package/dist/ui/data-table-bulk-actions.d.ts +19 -0
  163. package/dist/ui/data-table-bulk-actions.d.ts.map +1 -0
  164. package/dist/ui/data-table-bulk-actions.js +61 -0
  165. package/dist/ui/data-table-card.d.ts +9 -0
  166. package/dist/ui/data-table-card.d.ts.map +1 -0
  167. package/dist/ui/data-table-card.js +73 -0
  168. package/dist/ui/data-table-context.d.ts +62 -0
  169. package/dist/ui/data-table-context.d.ts.map +1 -0
  170. package/dist/ui/data-table-context.js +48 -0
  171. package/dist/ui/data-table-header.d.ts +10 -0
  172. package/dist/ui/data-table-header.d.ts.map +1 -0
  173. package/dist/ui/data-table-header.js +141 -0
  174. package/dist/ui/data-table-pagination.d.ts +13 -0
  175. package/dist/ui/data-table-pagination.d.ts.map +1 -0
  176. package/dist/ui/data-table-pagination.js +84 -0
  177. package/dist/ui/data-table.d.ts +11 -9
  178. package/dist/ui/data-table.d.ts.map +1 -1
  179. package/dist/ui/data-table.js +258 -573
  180. package/dist/ui/dialog.d.ts +6 -2
  181. package/dist/ui/dialog.d.ts.map +1 -1
  182. package/dist/ui/dialog.js +84 -82
  183. package/dist/ui/dropdown-menu.js +1 -1
  184. package/dist/ui/hover-card.d.ts +7 -0
  185. package/dist/ui/hover-card.d.ts.map +1 -1
  186. package/dist/ui/hover-card.js +3 -3
  187. package/dist/ui/icon-group.d.ts +2 -4
  188. package/dist/ui/icon-group.d.ts.map +1 -1
  189. package/dist/ui/icon-group.js +22 -23
  190. package/dist/ui/index.d.ts +1 -2
  191. package/dist/ui/index.d.ts.map +1 -1
  192. package/dist/ui/index.js +94 -99
  193. package/dist/ui/label.js +1 -1
  194. package/dist/ui/lib/bottom-sheet.d.ts +16 -0
  195. package/dist/ui/lib/bottom-sheet.d.ts.map +1 -0
  196. package/dist/ui/lib/date-utils.d.ts.map +1 -1
  197. package/dist/ui/lib/motion.d.ts.map +1 -1
  198. package/dist/ui/lib/utils.d.ts.map +1 -1
  199. package/dist/ui/menubar.d.ts.map +1 -1
  200. package/dist/ui/menubar.js +64 -73
  201. package/dist/ui/navigation-menu.d.ts.map +1 -1
  202. package/dist/ui/navigation-menu.js +40 -44
  203. package/dist/ui/number-input.d.ts.map +1 -1
  204. package/dist/ui/number-input.js +19 -17
  205. package/dist/ui/popover.d.ts.map +1 -1
  206. package/dist/ui/popover.js +107 -32
  207. package/dist/ui/progress-ring.d.ts.map +1 -1
  208. package/dist/ui/progress-ring.js +80 -80
  209. package/dist/ui/progress.js +4 -4
  210. package/dist/ui/radio.d.ts +5 -2
  211. package/dist/ui/radio.d.ts.map +1 -1
  212. package/dist/ui/radio.js +29 -20
  213. package/dist/ui/search-input.d.ts.map +1 -1
  214. package/dist/ui/search-input.js +13 -12
  215. package/dist/ui/segmented-control.d.ts +6 -108
  216. package/dist/ui/segmented-control.d.ts.map +1 -1
  217. package/dist/ui/segmented-control.js +86 -272
  218. package/dist/ui/select.d.ts +3 -1
  219. package/dist/ui/select.d.ts.map +1 -1
  220. package/dist/ui/select.js +83 -71
  221. package/dist/ui/separator.js +5 -5
  222. package/dist/ui/sheet.d.ts +2 -0
  223. package/dist/ui/sheet.d.ts.map +1 -1
  224. package/dist/ui/sheet.js +102 -84
  225. package/dist/ui/sidebar.d.ts.map +1 -1
  226. package/dist/ui/sidebar.js +200 -175
  227. package/dist/ui/skeleton.d.ts.map +1 -1
  228. package/dist/ui/slider.js +14 -14
  229. package/dist/ui/stack.d.ts.map +1 -1
  230. package/dist/ui/status-dot.js +8 -8
  231. package/dist/ui/stepper.d.ts.map +1 -1
  232. package/dist/ui/stepper.js +33 -31
  233. package/dist/ui/switch.js +3 -3
  234. package/dist/ui/table.d.ts.map +1 -1
  235. package/dist/ui/tabs.d.ts +7 -0
  236. package/dist/ui/tabs.d.ts.map +1 -1
  237. package/dist/ui/tabs.js +102 -76
  238. package/dist/ui/text.d.ts.map +1 -1
  239. package/dist/ui/toast-types.d.ts +0 -1
  240. package/dist/ui/toast-types.d.ts.map +1 -1
  241. package/dist/ui/toast-types.js +0 -1
  242. package/dist/ui/toast.d.ts.map +1 -1
  243. package/dist/ui/toast.js +156 -150
  244. package/dist/ui/toggle-group.js +1 -1
  245. package/dist/ui/toggle.js +1 -1
  246. package/dist/ui/tooltip.js +3 -3
  247. package/dist/ui/visually-hidden.d.ts.map +1 -1
  248. package/docs/components/ui/alert.md +3 -0
  249. package/docs/components/ui/badge.md +3 -0
  250. package/docs/components/ui/card.md +4 -0
  251. package/docs/components/ui/data-table-body.md +13 -0
  252. package/docs/components/ui/data-table-bulk-actions.md +13 -0
  253. package/docs/components/ui/data-table-card.md +13 -0
  254. package/docs/components/ui/data-table-context.md +13 -0
  255. package/docs/components/ui/data-table-header.md +13 -0
  256. package/docs/components/ui/data-table-pagination.md +13 -0
  257. package/docs/components/ui/select.md +4 -0
  258. package/docs/components/ui/tabs.md +4 -0
  259. package/llms-full.txt +97 -48
  260. package/llms.txt +46 -1
  261. package/package.json +37 -7
  262. package/dist/ui/chip.d.ts +0 -19
  263. package/dist/ui/chip.d.ts.map +0 -1
  264. package/dist/ui/chip.js +0 -14
  265. package/dist/ui/lib/use-ripple.d.ts +0 -14
  266. package/dist/ui/lib/use-ripple.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"toast.d.ts","sourceRoot":"","sources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AAE,MAAM,GAAG,KAAK,CAAC,SAAS,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC,KAAK,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC,CAAA;QAC3E,KAAK,EACD,MAAM,GACN,KAAK,CAAC,SAAS,GACf,CAAC,CAAC,KAAK,EAAE,OAAO,KAAK,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC,CAAA;KACnD;wBA6CoB,MAAM,GAAG,KAAK,CAAC,SAAS,WAAW,gBAAgB;0BAgBjD,kBAAkB;yBAyBjC,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,KAAK,KAAK,CAAC,YAAY,YACzC,aAAa;uBASH,MAAM,GAAG,MAAM;;AAYrC,MAAM,MAAM,UAAU,GAAG,YAAY,CAAA;AAErC,OAAO,EACL,KAAK,EACL,cAAc,EACd,YAAY,EACZ,kBAAkB,EAClB,aAAa,EACb,QAAQ,GACT,CAAA;AACD,YAAY,EACV,YAAY,EACZ,SAAS,EACT,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,UAAU,GACX,MAAM,eAAe,CAAA"}
package/dist/ui/toast.js CHANGED
@@ -1,15 +1,15 @@
1
1
  "use client";
2
- import { jsx as t, jsxs as d } from "react/jsx-runtime";
3
- import * as p from "react";
4
- import { t as f } from "../_chunks/sonner.js";
5
- import { IconInfoCircle as D, IconAlertTriangle as M, IconCircleX as O, IconCircleCheck as P, IconCheck as z, IconAlertCircle as U, IconPhoto as j, IconFile as L, IconRefresh as _, IconX as G, IconUpload as X } from "@tabler/icons-react";
6
- import { cn as I } from "./lib/utils.js";
7
- import { springs as x, tweens as N } from "./lib/motion.js";
8
- import { Spinner as E } from "./spinner.js";
9
- import { Progress as H } from "./progress.js";
2
+ import { jsx as t, jsxs as l } from "react/jsx-runtime";
3
+ import * as f from "react";
4
+ import { t as p } from "../_chunks/sonner.js";
5
+ import { IconInfoCircle as P, IconAlertTriangle as j, IconCircleX as L, IconCircleCheck as _, IconCheck as U, IconAlertCircle as E, IconPhoto as G, IconFile as X, IconRefresh as H, IconX as Y, IconUpload as K } from "@tabler/icons-react";
6
+ import { cn as k } from "./lib/utils.js";
7
+ import { springs as v, tweens as b } from "./lib/motion.js";
8
+ import { Spinner as A } from "./spinner.js";
9
+ import { Progress as V } from "./progress.js";
10
10
  import { Icon as g } from "./icon.js";
11
- import { m as o, A as T } from "../_chunks/framer.js";
12
- const R = 5e3, Y = 8e3, B = 3e3, F = {
11
+ import { m as o, A as R } from "../_chunks/framer.js";
12
+ const F = 5e3, W = 8e3, z = 3e3, D = {
13
13
  message: {
14
14
  accentClass: "",
15
15
  iconClass: "",
@@ -19,25 +19,25 @@ const R = 5e3, Y = 8e3, B = 3e3, F = {
19
19
  success: {
20
20
  accentClass: "bg-success-9",
21
21
  iconClass: "text-success-11",
22
- icon: P,
22
+ icon: _,
23
23
  timerBarClass: "bg-success-9"
24
24
  },
25
25
  error: {
26
26
  accentClass: "bg-error-9",
27
27
  iconClass: "text-error-11",
28
- icon: O,
28
+ icon: L,
29
29
  timerBarClass: "bg-error-9"
30
30
  },
31
31
  warning: {
32
32
  accentClass: "bg-warning-9",
33
33
  iconClass: "text-warning-11",
34
- icon: M,
34
+ icon: j,
35
35
  timerBarClass: "bg-warning-9"
36
36
  },
37
37
  info: {
38
38
  accentClass: "bg-info-9",
39
39
  iconClass: "text-info-11",
40
- icon: D,
40
+ icon: P,
41
41
  timerBarClass: "bg-info-9"
42
42
  },
43
43
  loading: {
@@ -47,16 +47,16 @@ const R = 5e3, Y = 8e3, B = 3e3, F = {
47
47
  timerBarClass: "bg-accent-9"
48
48
  }
49
49
  };
50
- function S({
50
+ function M({
51
51
  duration: e,
52
52
  type: s,
53
53
  paused: a
54
54
  }) {
55
- const r = F[s];
55
+ const r = D[s];
56
56
  return /* @__PURE__ */ t("div", { className: "absolute bottom-0 left-0 right-0 h-[2px] overflow-hidden", children: /* @__PURE__ */ t(
57
57
  "div",
58
58
  {
59
- className: I(
59
+ className: k(
60
60
  "h-full w-full origin-left opacity-30",
61
61
  r.timerBarClass,
62
62
  "motion-safe:animate-timer-bar"
@@ -68,83 +68,85 @@ function S({
68
68
  }
69
69
  ) });
70
70
  }
71
- function k({
71
+ function B({
72
72
  type: e,
73
73
  title: s,
74
74
  description: a,
75
75
  action: r,
76
76
  cancel: n,
77
- duration: c = R,
78
- showTimerBar: w = !0,
79
- selfDismissId: l
77
+ duration: c = F,
78
+ showTimerBar: $ = !0,
79
+ selfDismissId: N
80
80
  }) {
81
- const [u, y] = p.useState(!1), h = F[e], C = h.icon, b = p.useRef(c), i = p.useRef(0);
82
- return p.useEffect(() => {
83
- if (l == null || c === 1 / 0) return;
84
- if (u) {
85
- const A = Date.now() - i.current;
86
- b.current = Math.max(0, b.current - A);
81
+ const [I, w] = f.useState(!1), [m, u] = f.useState(!1), h = I || m, x = D[e], T = x.icon, C = f.useRef(c), i = f.useRef(0);
82
+ return f.useEffect(() => {
83
+ if (N == null || c === 1 / 0) return;
84
+ if (h) {
85
+ const O = Date.now() - i.current;
86
+ C.current = Math.max(0, C.current - O);
87
87
  return;
88
88
  }
89
89
  i.current = Date.now();
90
- const $ = setTimeout(() => {
91
- f.dismiss(l);
92
- }, b.current);
93
- return () => clearTimeout($);
94
- }, [l, c, u]), /* @__PURE__ */ d(
90
+ const S = setTimeout(() => {
91
+ p.dismiss(N);
92
+ }, C.current);
93
+ return () => clearTimeout(S);
94
+ }, [N, c, h]), /* @__PURE__ */ l(
95
95
  o.div,
96
96
  {
97
97
  layout: "position",
98
98
  role: "status",
99
99
  "aria-live": "polite",
100
100
  className: "group relative flex w-full overflow-hidden rounded-ds-md border border-surface-border-strong bg-surface-overlay shadow-floating",
101
- onMouseEnter: () => y(!0),
102
- onMouseLeave: () => y(!1),
103
- transition: x.smooth,
101
+ onMouseEnter: () => w(!0),
102
+ onMouseLeave: () => w(!1),
103
+ onFocusCapture: () => u(!0),
104
+ onBlurCapture: () => u(!1),
105
+ transition: v.smooth,
104
106
  children: [
105
- h.accentClass && /* @__PURE__ */ t(
107
+ x.accentClass && /* @__PURE__ */ t(
106
108
  "div",
107
109
  {
108
- className: I("w-1 shrink-0 rounded-l-ds-md", h.accentClass)
110
+ className: k("w-1 shrink-0 rounded-l-ds-md", x.accentClass)
109
111
  }
110
112
  ),
111
- /* @__PURE__ */ d("div", { className: "flex min-w-0 flex-1 items-start gap-ds-03 p-ds-04", children: [
112
- /* @__PURE__ */ t(T, { mode: "wait", children: e === "loading" ? /* @__PURE__ */ t(
113
+ /* @__PURE__ */ l("div", { className: "flex min-w-0 flex-1 items-start gap-ds-03 p-ds-04", children: [
114
+ /* @__PURE__ */ t(R, { mode: "wait", children: e === "loading" ? /* @__PURE__ */ t(
113
115
  o.div,
114
116
  {
115
117
  initial: { opacity: 0, scale: 0.5 },
116
118
  animate: { opacity: 1, scale: 1 },
117
119
  exit: { opacity: 0, scale: 0.5 },
118
- transition: N.fade,
120
+ transition: b.fade,
119
121
  className: "mt-0.5 shrink-0",
120
- children: /* @__PURE__ */ t(E, { size: "sm", className: "h-4 w-4" })
122
+ children: /* @__PURE__ */ t(A, { size: "sm", className: "h-4 w-4" })
121
123
  },
122
124
  "loading"
123
- ) : C ? /* @__PURE__ */ t(
125
+ ) : T ? /* @__PURE__ */ t(
124
126
  o.div,
125
127
  {
126
128
  initial: { opacity: 0, scale: 0.5 },
127
129
  animate: { opacity: 1, scale: 1 },
128
130
  exit: { opacity: 0, scale: 0.5 },
129
- transition: x.bouncy,
131
+ transition: v.bouncy,
130
132
  className: "mt-0.5 shrink-0",
131
- children: /* @__PURE__ */ t(g, { icon: C, size: "sm", className: h.iconClass })
133
+ children: /* @__PURE__ */ t(g, { icon: T, size: "sm", className: x.iconClass })
132
134
  },
133
135
  e
134
136
  ) : null }),
135
- /* @__PURE__ */ d("div", { className: "min-w-0 flex-1", children: [
137
+ /* @__PURE__ */ l("div", { className: "min-w-0 flex-1", children: [
136
138
  s && /* @__PURE__ */ t("p", { className: "text-ds-md font-semibold text-surface-fg", children: s }),
137
139
  a && /* @__PURE__ */ t(
138
140
  "p",
139
141
  {
140
- className: I(
142
+ className: k(
141
143
  "text-ds-sm text-surface-fg-muted",
142
144
  s && "mt-0.5"
143
145
  ),
144
146
  children: a
145
147
  }
146
148
  ),
147
- (r || n) && /* @__PURE__ */ d("div", { className: "mt-ds-03 flex items-center gap-ds-03", children: [
149
+ (r || n) && /* @__PURE__ */ l("div", { className: "mt-ds-03 flex items-center gap-ds-03", children: [
148
150
  r && /* @__PURE__ */ t(
149
151
  "button",
150
152
  {
@@ -166,12 +168,12 @@ function k({
166
168
  ] })
167
169
  ] })
168
170
  ] }),
169
- w && e !== "loading" && /* @__PURE__ */ t(S, { duration: c, type: e, paused: u })
171
+ $ && e !== "loading" && /* @__PURE__ */ t(M, { duration: c, type: e, paused: h })
170
172
  ]
171
173
  }
172
174
  );
173
175
  }
174
- const K = /* @__PURE__ */ new Set([
176
+ const q = /* @__PURE__ */ new Set([
175
177
  "jpg",
176
178
  "jpeg",
177
179
  "png",
@@ -182,12 +184,12 @@ const K = /* @__PURE__ */ new Set([
182
184
  "ico",
183
185
  "avif"
184
186
  ]);
185
- function V(e) {
187
+ function J(e) {
186
188
  if (e.previewUrl) return !0;
187
189
  const s = e.name.split(".").pop()?.toLowerCase() ?? "";
188
- return K.has(s);
190
+ return q.has(s);
189
191
  }
190
- function W(e) {
192
+ function Q(e) {
191
193
  switch (e) {
192
194
  case "complete":
193
195
  return "success";
@@ -197,7 +199,7 @@ function W(e) {
197
199
  return "default";
198
200
  }
199
201
  }
200
- function q(e) {
202
+ function Z(e) {
201
203
  switch (e.status) {
202
204
  case "pending":
203
205
  return 0;
@@ -211,16 +213,16 @@ function q(e) {
211
213
  return e.progress ?? 0;
212
214
  }
213
215
  }
214
- function J(e) {
216
+ function ee(e) {
215
217
  return !e || e < 0 || !Number.isFinite(e) ? "0 B" : e < 1024 ? `${e} B` : e < 1024 * 1024 ? `${(e / 1024).toFixed(1)} KB` : e < 1024 * 1024 * 1024 ? `${(e / (1024 * 1024)).toFixed(1)} MB` : `${(e / (1024 * 1024 * 1024)).toFixed(2)} GB`;
216
218
  }
217
- function Q({
219
+ function te({
218
220
  file: e,
219
221
  onRetry: s,
220
222
  onRemove: a
221
223
  }) {
222
224
  const r = e.status === "complete" || e.status === "error", n = e.status === "uploading" || e.status === "processing";
223
- return /* @__PURE__ */ d(
225
+ return /* @__PURE__ */ l(
224
226
  o.div,
225
227
  {
226
228
  layout: !0,
@@ -228,16 +230,16 @@ function Q({
228
230
  initial: !1,
229
231
  animate: { opacity: 1, y: 0 },
230
232
  exit: { opacity: 0, x: -20, height: 0 },
231
- transition: x.snappy,
233
+ transition: v.snappy,
232
234
  children: [
233
- /* @__PURE__ */ t("div", { className: "flex h-5 w-5 shrink-0 items-center justify-center", children: /* @__PURE__ */ t(T, { mode: "wait", children: e.status === "complete" ? /* @__PURE__ */ t(
235
+ /* @__PURE__ */ t("div", { className: "flex h-5 w-5 shrink-0 items-center justify-center", children: /* @__PURE__ */ t(R, { mode: "wait", children: e.status === "complete" ? /* @__PURE__ */ t(
234
236
  o.div,
235
237
  {
236
238
  initial: { opacity: 0, scale: 0.5 },
237
239
  animate: { opacity: 1, scale: 1 },
238
240
  exit: { opacity: 0, scale: 0.5 },
239
- transition: x.bouncy,
240
- children: /* @__PURE__ */ t(g, { icon: z, size: "xs", className: "text-success-11" })
241
+ transition: v.bouncy,
242
+ children: /* @__PURE__ */ t(g, { icon: U, size: "xs", className: "text-success-11" })
241
243
  },
242
244
  "complete"
243
245
  ) : e.status === "error" ? /* @__PURE__ */ t(
@@ -246,8 +248,8 @@ function Q({
246
248
  initial: { opacity: 0, scale: 0.5 },
247
249
  animate: { opacity: 1, scale: 1 },
248
250
  exit: { opacity: 0, scale: 0.5 },
249
- transition: N.fade,
250
- children: /* @__PURE__ */ t(g, { icon: U, size: "xs", className: "text-error-11" })
251
+ transition: b.fade,
252
+ children: /* @__PURE__ */ t(g, { icon: E, size: "xs", className: "text-error-11" })
251
253
  },
252
254
  "error"
253
255
  ) : e.status === "processing" ? /* @__PURE__ */ t(
@@ -256,18 +258,18 @@ function Q({
256
258
  initial: { opacity: 0 },
257
259
  animate: { opacity: 1 },
258
260
  exit: { opacity: 0 },
259
- transition: N.fade,
260
- children: /* @__PURE__ */ t(E, { size: "sm", className: "h-3.5 w-3.5" })
261
+ transition: b.fade,
262
+ children: /* @__PURE__ */ t(A, { size: "sm", className: "h-3.5 w-3.5" })
261
263
  },
262
264
  "processing"
263
- ) : V(e) ? /* @__PURE__ */ t(
265
+ ) : J(e) ? /* @__PURE__ */ t(
264
266
  o.div,
265
267
  {
266
268
  initial: { opacity: 0 },
267
269
  animate: { opacity: 1 },
268
270
  exit: { opacity: 0 },
269
- transition: N.fade,
270
- children: /* @__PURE__ */ t(g, { icon: j, size: "xs", className: "text-surface-fg-muted" })
271
+ transition: b.fade,
272
+ children: /* @__PURE__ */ t(g, { icon: G, size: "xs", className: "text-surface-fg-muted" })
271
273
  },
272
274
  "image"
273
275
  ) : /* @__PURE__ */ t(
@@ -276,35 +278,36 @@ function Q({
276
278
  initial: { opacity: 0 },
277
279
  animate: { opacity: 1 },
278
280
  exit: { opacity: 0 },
279
- transition: N.fade,
280
- children: /* @__PURE__ */ t(g, { icon: L, size: "xs", className: "text-surface-fg-muted" })
281
+ transition: b.fade,
282
+ children: /* @__PURE__ */ t(g, { icon: X, size: "xs", className: "text-surface-fg-muted" })
281
283
  },
282
284
  "file"
283
285
  ) }) }),
284
286
  /* @__PURE__ */ t("span", { className: "min-w-0 flex-1 truncate text-ds-xs text-surface-fg", children: e.name }),
285
- n ? /* @__PURE__ */ d("div", { className: "flex w-16 items-center gap-1", children: [
287
+ n ? /* @__PURE__ */ l("div", { className: "flex w-16 items-center gap-1", children: [
286
288
  /* @__PURE__ */ t(
287
- H,
289
+ V,
288
290
  {
289
291
  size: "sm",
290
- color: W(e.status),
291
- value: q(e),
292
+ color: Q(e.status),
293
+ value: Z(e),
292
294
  className: "flex-1"
293
295
  }
294
296
  ),
295
- e.progress !== void 0 && /* @__PURE__ */ d("span", { className: "shrink-0 text-[10px] tabular-nums text-surface-fg-muted", children: [
297
+ e.progress !== void 0 && /* @__PURE__ */ l("span", { className: "shrink-0 text-ds-xs tabular-nums text-surface-fg-muted", children: [
296
298
  e.progress,
297
299
  "%"
298
300
  ] })
299
- ] }) : e.status === "complete" ? /* @__PURE__ */ t("span", { className: "text-[10px] text-success-11", children: "Done" }) : e.status === "error" ? /* @__PURE__ */ t("span", { className: "max-w-[60px] truncate text-[10px] text-error-11", children: e.error || "Failed" }) : /* @__PURE__ */ t("span", { className: "text-[10px] text-surface-fg-muted", children: J(e.size) }),
301
+ ] }) : e.status === "complete" ? /* @__PURE__ */ t("span", { className: "text-ds-xs text-success-11", children: "Done" }) : e.status === "error" ? /* @__PURE__ */ t("span", { className: "max-w-[60px] truncate text-ds-xs text-error-11", children: e.error || "Failed" }) : /* @__PURE__ */ t("span", { className: "text-ds-xs text-surface-fg-muted", children: ee(e.size) }),
300
302
  e.status === "error" && s && /* @__PURE__ */ t(
301
303
  "button",
302
304
  {
303
305
  type: "button",
304
306
  onClick: () => s(e.id),
305
- className: "flex h-4 w-4 items-center justify-center rounded-ds-sm text-surface-fg-muted hover:text-surface-fg",
307
+ className: "touch-target flex min-h-6 min-w-6 items-center justify-center rounded-ds-sm text-surface-fg-muted hover:text-surface-fg",
306
308
  "aria-label": `Retry ${e.name}`,
307
- children: /* @__PURE__ */ t(_, { className: "h-3 w-3" })
309
+ title: "Retry",
310
+ children: /* @__PURE__ */ t(H, { className: "h-3.5 w-3.5" })
308
311
  }
309
312
  ),
310
313
  !r && a && /* @__PURE__ */ t(
@@ -312,39 +315,40 @@ function Q({
312
315
  {
313
316
  type: "button",
314
317
  onClick: () => a(e.id),
315
- className: "flex h-4 w-4 items-center justify-center rounded-ds-sm text-surface-fg-muted hover:text-surface-fg",
318
+ className: "touch-target flex min-h-6 min-w-6 items-center justify-center rounded-ds-sm text-surface-fg-muted hover:text-surface-fg",
316
319
  "aria-label": `Cancel ${e.name}`,
317
- children: /* @__PURE__ */ t(G, { className: "h-3 w-3" })
320
+ title: "Remove",
321
+ children: /* @__PURE__ */ t(Y, { className: "h-3.5 w-3.5" })
318
322
  }
319
323
  )
320
324
  ]
321
325
  }
322
326
  );
323
327
  }
324
- function Z({
328
+ function se({
325
329
  files: e,
326
330
  onRetry: s,
327
331
  onRemove: a,
328
332
  selfDismissId: r
329
333
  }) {
330
- const [n, c] = p.useState(!1), w = e.filter((i) => i.status === "complete").length, l = e.filter((i) => i.status === "error").length, u = e.every(
334
+ const [n, c] = f.useState(!1), [$, N] = f.useState(!1), I = n || $, w = e.filter((i) => i.status === "complete").length, m = e.filter((i) => i.status === "error").length, u = e.every(
331
335
  (i) => i.status === "complete" || i.status === "error"
332
- ), y = p.useRef(B), h = p.useRef(0);
333
- p.useEffect(() => {
336
+ ), h = f.useRef(z), x = f.useRef(0);
337
+ f.useEffect(() => {
334
338
  if (r == null || !u) return;
335
- if (n) {
336
- const $ = Date.now() - h.current;
337
- y.current = Math.max(0, y.current - $);
339
+ if (I) {
340
+ const S = Date.now() - x.current;
341
+ h.current = Math.max(0, h.current - S);
338
342
  return;
339
343
  }
340
- h.current = Date.now();
344
+ x.current = Date.now();
341
345
  const i = setTimeout(() => {
342
- f.dismiss(r);
343
- }, y.current);
346
+ p.dismiss(r);
347
+ }, h.current);
344
348
  return () => clearTimeout(i);
345
- }, [r, u, n]);
346
- const C = u ? l > 0 ? "bg-error-7" : "bg-success-7" : "bg-accent-9", b = u ? l > 0 ? "error" : "success" : "loading";
347
- return /* @__PURE__ */ d(
349
+ }, [r, u, I]);
350
+ const T = u ? m > 0 ? "bg-error-7" : "bg-success-7" : "bg-accent-9", C = u ? m > 0 ? "error" : "success" : "loading";
351
+ return /* @__PURE__ */ l(
348
352
  o.div,
349
353
  {
350
354
  layout: !0,
@@ -354,19 +358,21 @@ function Z({
354
358
  className: "group relative flex w-full overflow-hidden rounded-ds-md border border-surface-border-strong bg-surface-overlay shadow-floating",
355
359
  onMouseEnter: () => c(!0),
356
360
  onMouseLeave: () => c(!1),
357
- transition: x.smooth,
361
+ onFocusCapture: () => N(!0),
362
+ onBlurCapture: () => N(!1),
363
+ transition: v.smooth,
358
364
  children: [
359
- /* @__PURE__ */ t("div", { className: I("w-1 shrink-0 rounded-l-ds-md", C) }),
360
- /* @__PURE__ */ d("div", { className: "min-w-0 flex-1 p-ds-04", children: [
361
- /* @__PURE__ */ d("div", { className: "flex items-center gap-ds-02", children: [
362
- /* @__PURE__ */ t(T, { mode: "wait", children: u ? l > 0 ? /* @__PURE__ */ t(
365
+ /* @__PURE__ */ t("div", { className: k("w-1 shrink-0 rounded-l-ds-md", T) }),
366
+ /* @__PURE__ */ l("div", { className: "min-w-0 flex-1 p-ds-04", children: [
367
+ /* @__PURE__ */ l("div", { className: "flex items-center gap-ds-02", children: [
368
+ /* @__PURE__ */ t(R, { mode: "wait", children: u ? m > 0 ? /* @__PURE__ */ t(
363
369
  o.div,
364
370
  {
365
371
  initial: { opacity: 0, scale: 0.5 },
366
372
  animate: { opacity: 1, scale: 1 },
367
373
  exit: { opacity: 0, scale: 0.5 },
368
- transition: x.bouncy,
369
- children: /* @__PURE__ */ t(g, { icon: U, size: "sm", className: "shrink-0 text-error-11" })
374
+ transition: v.bouncy,
375
+ children: /* @__PURE__ */ t(g, { icon: E, size: "sm", className: "shrink-0 text-error-11" })
370
376
  },
371
377
  "error-icon"
372
378
  ) : /* @__PURE__ */ t(
@@ -375,8 +381,8 @@ function Z({
375
381
  initial: { opacity: 0, scale: 0.5 },
376
382
  animate: { opacity: 1, scale: 1 },
377
383
  exit: { opacity: 0, scale: 0.5 },
378
- transition: x.bouncy,
379
- children: /* @__PURE__ */ t(g, { icon: z, size: "sm", className: "shrink-0 text-success-11" })
384
+ transition: v.bouncy,
385
+ children: /* @__PURE__ */ t(g, { icon: U, size: "sm", className: "shrink-0 text-success-11" })
380
386
  },
381
387
  "success-icon"
382
388
  ) : /* @__PURE__ */ t(
@@ -385,22 +391,22 @@ function Z({
385
391
  initial: { opacity: 0 },
386
392
  animate: { opacity: 1 },
387
393
  exit: { opacity: 0 },
388
- transition: N.fade,
389
- children: /* @__PURE__ */ t(g, { icon: X, size: "sm", className: "shrink-0 text-surface-fg-muted" })
394
+ transition: b.fade,
395
+ children: /* @__PURE__ */ t(g, { icon: K, size: "sm", className: "shrink-0 text-surface-fg-muted" })
390
396
  },
391
397
  "upload-icon"
392
398
  ) }),
393
- /* @__PURE__ */ t("p", { className: "text-ds-md font-semibold text-surface-fg", children: u ? l > 0 ? `${w} of ${e.length} uploaded` : `${e.length} file${e.length > 1 ? "s" : ""} uploaded` : `Uploading ${e.length} file${e.length > 1 ? "s" : ""}` })
399
+ /* @__PURE__ */ t("p", { className: "text-ds-md font-semibold text-surface-fg", children: u ? m > 0 ? `${w} of ${e.length} uploaded` : `${e.length} file${e.length > 1 ? "s" : ""} uploaded` : `Uploading ${e.length} file${e.length > 1 ? "s" : ""}` })
394
400
  ] }),
395
- !u && /* @__PURE__ */ d("p", { className: "mt-0.5 text-ds-xs text-surface-fg-muted", children: [
401
+ !u && /* @__PURE__ */ l("p", { className: "mt-0.5 text-ds-xs text-surface-fg-muted", children: [
396
402
  w,
397
403
  " of ",
398
404
  e.length,
399
405
  " complete",
400
- l > 0 && ` · ${l} failed`
406
+ m > 0 && ` · ${m} failed`
401
407
  ] }),
402
- /* @__PURE__ */ t("div", { className: "mt-ds-02 max-h-[140px] overflow-y-auto", children: /* @__PURE__ */ t(T, { children: e.map((i) => /* @__PURE__ */ t(
403
- Q,
408
+ /* @__PURE__ */ t("div", { className: "mt-ds-02 max-h-[140px] overflow-y-auto", children: /* @__PURE__ */ t(R, { children: e.map((i) => /* @__PURE__ */ t(
409
+ te,
404
410
  {
405
411
  file: i,
406
412
  onRetry: s,
@@ -408,19 +414,19 @@ function Z({
408
414
  },
409
415
  i.id
410
416
  )) }) }),
411
- /* @__PURE__ */ d("div", { className: "sr-only", "aria-live": "polite", children: [
417
+ /* @__PURE__ */ l("div", { className: "sr-only", "aria-live": "polite", children: [
412
418
  w,
413
419
  " of ",
414
420
  e.length,
415
421
  " files uploaded",
416
- l > 0 && `, ${l} failed`
422
+ m > 0 && `, ${m} failed`
417
423
  ] })
418
424
  ] }),
419
425
  u && /* @__PURE__ */ t(
420
- S,
426
+ M,
421
427
  {
422
- duration: B,
423
- type: b,
428
+ duration: z,
429
+ type: C,
424
430
  paused: !1
425
431
  }
426
432
  )
@@ -428,19 +434,19 @@ function Z({
428
434
  }
429
435
  );
430
436
  }
431
- function ee(e, s) {
437
+ function ae(e, s) {
432
438
  return {
433
439
  id: e?.id,
434
- duration: e?.duration ?? s ?? R,
440
+ duration: e?.duration ?? s ?? F,
435
441
  unstyled: !0,
436
442
  classNames: { toast: "w-full" }
437
443
  };
438
444
  }
439
- function v(e, s, a) {
440
- const r = a?.duration ?? R;
441
- return f.custom(
445
+ function y(e, s, a) {
446
+ const r = a?.duration ?? F;
447
+ return p.custom(
442
448
  () => /* @__PURE__ */ t(
443
- k,
449
+ B,
444
450
  {
445
451
  type: e,
446
452
  title: s,
@@ -450,33 +456,33 @@ function v(e, s, a) {
450
456
  duration: r
451
457
  }
452
458
  ),
453
- ee(a, r)
459
+ ae(a, r)
454
460
  );
455
461
  }
456
- function m(e, s) {
457
- return v("message", e, s);
462
+ function d(e, s) {
463
+ return y("message", e, s);
458
464
  }
459
- m.message = (e, s) => v("message", e, s);
460
- m.success = (e, s) => v("success", e, s);
461
- m.error = (e, s) => v("error", e, s);
462
- m.warning = (e, s) => v("warning", e, s);
463
- m.info = (e, s) => v("info", e, s);
464
- m.loading = (e, s) => v("loading", e, {
465
+ d.message = (e, s) => y("message", e, s);
466
+ d.success = (e, s) => y("success", e, s);
467
+ d.error = (e, s) => y("error", e, s);
468
+ d.warning = (e, s) => y("warning", e, s);
469
+ d.info = (e, s) => y("info", e, s);
470
+ d.loading = (e, s) => y("loading", e, {
465
471
  ...s,
466
472
  duration: s?.duration ?? 1 / 0
467
473
  });
468
- m.promise = (e, s) => {
469
- const a = f.custom(
470
- () => /* @__PURE__ */ t(k, { type: "loading", title: s.loading, showTimerBar: !1 }),
474
+ d.promise = (e, s) => {
475
+ const a = p.custom(
476
+ () => /* @__PURE__ */ t(B, { type: "loading", title: s.loading, showTimerBar: !1 }),
471
477
  { duration: 1 / 0, unstyled: !0, classNames: { toast: "w-full" } }
472
478
  ), r = (n, c) => {
473
- f.custom(
479
+ p.custom(
474
480
  () => /* @__PURE__ */ t(
475
- k,
481
+ B,
476
482
  {
477
483
  type: n,
478
484
  title: c,
479
- duration: R,
485
+ duration: F,
480
486
  selfDismissId: a
481
487
  }
482
488
  ),
@@ -491,11 +497,11 @@ m.promise = (e, s) => {
491
497
  r("error", c);
492
498
  }), a;
493
499
  };
494
- m.undo = (e, s) => {
495
- const a = s.duration ?? Y;
496
- return f.custom(
500
+ d.undo = (e, s) => {
501
+ const a = s.duration ?? W;
502
+ return p.custom(
497
503
  () => /* @__PURE__ */ t(
498
- k,
504
+ B,
499
505
  {
500
506
  type: "message",
501
507
  title: e,
@@ -507,11 +513,11 @@ m.undo = (e, s) => {
507
513
  { duration: a, unstyled: !0, classNames: { toast: "w-full" } }
508
514
  );
509
515
  };
510
- m.upload = (e) => {
516
+ d.upload = (e) => {
511
517
  const s = e.id ?? String(Date.now());
512
- return f.custom(
518
+ return p.custom(
513
519
  () => /* @__PURE__ */ t(
514
- Z,
520
+ se,
515
521
  {
516
522
  files: e.files,
517
523
  onRetry: e.onRetry,
@@ -527,19 +533,19 @@ m.upload = (e) => {
527
533
  }
528
534
  ), s;
529
535
  };
530
- m.custom = (e, s) => f.custom(e, {
536
+ d.custom = (e, s) => p.custom(e, {
531
537
  ...s,
532
538
  unstyled: !0,
533
539
  classNames: { toast: "w-full", ...s?.classNames }
534
540
  });
535
- m.dismiss = (e) => {
536
- e !== void 0 ? f.dismiss(e) : f.dismiss();
541
+ d.dismiss = (e) => {
542
+ e !== void 0 ? p.dismiss(e) : p.dismiss();
537
543
  };
538
544
  export {
539
- S as TimerBar,
540
- k as ToastContent,
541
- Q as UploadFileRow,
542
- Z as UploadToastContent,
543
- J as formatFileSize,
544
- m as toast
545
+ M as TimerBar,
546
+ B as ToastContent,
547
+ te as UploadFileRow,
548
+ se as UploadToastContent,
549
+ ee as formatFileSize,
550
+ d as toast
545
551
  };
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as n } from "react/jsx-runtime";
3
3
  import * as e from "react";
4
- import { aJ as i, aK as l } from "../_chunks/primitives.js";
4
+ import { aI as i, aJ as l } from "../_chunks/primitives.js";
5
5
  import { cn as c } from "./lib/utils.js";
6
6
  import { toggleVariants as f } from "./toggle.js";
7
7
  const p = e.createContext({