@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,23 +1,23 @@
1
1
  "use client";
2
- import { jsx as e, jsxs as d } from "react/jsx-runtime";
2
+ import { jsx as e, jsxs as m } from "react/jsx-runtime";
3
3
  import * as a from "react";
4
4
  import L from "react-markdown";
5
- import U from "remark-gfm";
5
+ import E from "remark-gfm";
6
6
  import { cn as p } from "../ui/lib/utils.js";
7
- import { springs as z, tweens as P } from "../ui/lib/motion.js";
7
+ import { springs as U, tweens as P } from "../ui/lib/motion.js";
8
8
  import { u as y } from "./motion-provider.js";
9
9
  import { Table as j, TableCaption as W, TableHeader as X, TableRow as _, TableHead as $, TableBody as H, TableCell as O } from "../ui/table.js";
10
- import { B as M } from "./badge-group.js";
10
+ import { B as R } from "./badge-group.js";
11
11
  import { m as x } from "./framer.js";
12
- import { Button as S } from "../ui/button.js";
13
- import { Collapsible as V, CollapsibleTrigger as F, CollapsibleContent as G } from "../ui/collapsible.js";
14
- import { Alert as w } from "../ui/alert.js";
15
- import { IconCircle as K, IconCircleX as q, IconCircleCheck as J } from "@tabler/icons-react";
12
+ import { Button as B } from "../ui/button.js";
13
+ import { Collapsible as V, CollapsibleTrigger as K, CollapsibleContent as F } from "../ui/collapsible.js";
14
+ import { Alert as S } from "../ui/alert.js";
15
+ import { IconCircle as G, IconCircleX as q, IconCircleCheck as J } from "@tabler/icons-react";
16
16
  import { Icon as C } from "../ui/icon.js";
17
17
  import { Skeleton as Q } from "../ui/skeleton.js";
18
- import { Separator as R } from "../ui/separator.js";
19
- import { StatCard as D } from "../ui/stat-card.js";
20
- const ve = a.memo(function({
18
+ import { Separator as D } from "../ui/separator.js";
19
+ import { StatCard as M } from "../ui/stat-card.js";
20
+ const Y = a.memo(function({
21
21
  data: r,
22
22
  confidence: t
23
23
  }) {
@@ -33,39 +33,40 @@ const ve = a.memo(function({
33
33
  "prose-strong:text-surface-fg",
34
34
  t === "low" && "border-l-2 border-warning-7 pl-3"
35
35
  ),
36
- children: /* @__PURE__ */ e(L, { remarkPlugins: [U], children: r.content })
36
+ children: /* @__PURE__ */ e(L, { remarkPlugins: [E], children: r.content })
37
37
  }
38
38
  );
39
39
  });
40
- function Y(s, r) {
40
+ Y.displayName = "TextBlock";
41
+ function Z(s, r) {
41
42
  if (r.variant === "badge") {
42
43
  if (s && typeof s == "object" && "label" in s) {
43
44
  const t = s;
44
- return /* @__PURE__ */ e(M, { variant: "subtle", size: "sm", color: t.color, children: t.label });
45
+ return /* @__PURE__ */ e(R, { variant: "subtle", size: "sm", color: t.color, children: t.label });
45
46
  }
46
- return /* @__PURE__ */ e(M, { variant: "subtle", size: "sm", children: String(s ?? "") });
47
+ return /* @__PURE__ */ e(R, { variant: "subtle", size: "sm", children: String(s ?? "") });
47
48
  }
48
49
  return String(s ?? "");
49
50
  }
50
- function Z(s, r, t) {
51
- return !r || !t ? s : [...s].sort((c, n) => {
52
- const l = c[r], i = n[r], m = String(l ?? ""), v = String(i ?? ""), f = Number(l), g = Number(i);
51
+ function A(s, r, t) {
52
+ return !r || !t ? s : [...s].sort((l, n) => {
53
+ const d = l[r], o = n[r], u = String(d ?? ""), k = String(o ?? ""), f = Number(d), g = Number(o);
53
54
  if (!Number.isNaN(f) && !Number.isNaN(g))
54
55
  return t === "asc" ? f - g : g - f;
55
- const o = m.localeCompare(v);
56
- return t === "asc" ? o : -o;
56
+ const i = u.localeCompare(k);
57
+ return t === "asc" ? i : -i;
57
58
  });
58
59
  }
59
- const ke = a.memo(function({
60
+ const ee = a.memo(function({
60
61
  data: r,
61
62
  confidence: t
62
63
  }) {
63
- const { reducedMotion: c } = y(), [n, l] = a.useState(null), [i, m] = a.useState(null), v = a.useCallback(
64
- (o) => {
65
- r.sortable && (n !== o ? (l(o), m("asc")) : i === "asc" ? m("desc") : i === "desc" && (l(null), m(null)));
64
+ const { reducedMotion: l } = y(), [n, d] = a.useState(null), [o, u] = a.useState(null), k = a.useCallback(
65
+ (i) => {
66
+ r.sortable && (n !== i ? (d(i), u("asc")) : o === "asc" ? u("desc") : o === "desc" && (d(null), u(null)));
66
67
  },
67
- [r.sortable, n, i]
68
- ), f = r.columns ?? [], g = Z(r.rows ?? [], n, i);
68
+ [r.sortable, n, o]
69
+ ), f = r.columns ?? [], g = A(r.rows ?? [], n, o);
69
70
  return /* @__PURE__ */ e(
70
71
  "div",
71
72
  {
@@ -73,36 +74,41 @@ const ke = a.memo(function({
73
74
  "overflow-x-auto",
74
75
  t === "low" && "border-l-2 border-warning-7 pl-3"
75
76
  ),
76
- children: /* @__PURE__ */ d(j, { children: [
77
+ children: /* @__PURE__ */ m(j, { children: [
77
78
  r.caption && /* @__PURE__ */ e(W, { children: r.caption }),
78
- /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(_, { children: f.map((o) => {
79
- const h = n === o.key, k = h ? i === "asc" ? "ascending" : "descending" : void 0;
79
+ /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(_, { children: f.map((i) => {
80
+ const h = n === i.key, v = r.sortable ? h ? o === "asc" ? "ascending" : "descending" : "none" : void 0;
80
81
  return /* @__PURE__ */ e(
81
82
  $,
82
83
  {
84
+ role: "columnheader",
83
85
  className: p(
84
- o.variant === "number" && "text-right",
86
+ i.variant === "number" && "text-right",
85
87
  r.sortable && "cursor-pointer select-none"
86
88
  ),
87
- onClick: r.sortable ? () => v(o.key) : void 0,
88
- "aria-sort": k,
89
- children: /* @__PURE__ */ d("span", { className: "inline-flex items-center gap-1", children: [
90
- o.label,
91
- h && i === "asc" && /* @__PURE__ */ e("span", { "aria-hidden": "true", children: "▲" }),
92
- h && i === "desc" && /* @__PURE__ */ e("span", { "aria-hidden": "true", children: "▼" })
89
+ tabIndex: r.sortable ? 0 : void 0,
90
+ onClick: r.sortable ? () => k(i.key) : void 0,
91
+ onKeyDown: r.sortable ? (c) => {
92
+ (c.key === "Enter" || c.key === " ") && (c.preventDefault(), k(i.key));
93
+ } : void 0,
94
+ "aria-sort": v,
95
+ children: /* @__PURE__ */ m("span", { className: "inline-flex items-center gap-1", children: [
96
+ i.label,
97
+ h && o === "asc" && /* @__PURE__ */ e("span", { "aria-hidden": "true", children: "▲" }),
98
+ h && o === "desc" && /* @__PURE__ */ e("span", { "aria-hidden": "true", children: "▼" })
93
99
  ] })
94
100
  },
95
- o.key
101
+ i.key
96
102
  );
97
103
  }) }) }),
98
- /* @__PURE__ */ e(H, { children: g.map((o, h) => {
99
- const k = typeof o.id == "string" || typeof o.id == "number" ? String(o.id) : `row-${h}`, u = c ? "tr" : x.tr, N = c ? {} : {
104
+ /* @__PURE__ */ e(H, { children: g.map((i, h) => {
105
+ const v = typeof i.id == "string" || typeof i.id == "number" ? String(i.id) : `row-${h}`, c = l ? "tr" : x.tr, N = l ? {} : {
100
106
  initial: { opacity: 0, y: 6 },
101
107
  animate: { opacity: 1, y: 0 },
102
- transition: { ...z.responsive, delay: h * 0.03 }
108
+ transition: { ...U.responsive, delay: h * 0.03 }
103
109
  };
104
110
  return /* @__PURE__ */ e(
105
- u,
111
+ c,
106
112
  {
107
113
  className: "hover:bg-surface-raised-hover transition-colors",
108
114
  ...N,
@@ -113,28 +119,30 @@ const ke = a.memo(function({
113
119
  "text-ds-sm py-ds-02b px-ds-04",
114
120
  b.variant === "number" && "text-right tabular-nums font-medium"
115
121
  ),
116
- children: Y(o[b.key], b)
122
+ children: Z(i[b.key], b)
117
123
  },
118
124
  b.key
119
125
  ))
120
126
  },
121
- k
127
+ v
122
128
  );
123
129
  }) })
124
130
  ] })
125
131
  }
126
132
  );
127
- }), Ne = a.memo(function({
133
+ });
134
+ ee.displayName = "BlockTable";
135
+ const re = a.memo(function({
128
136
  data: r,
129
137
  confidence: t,
130
- onAction: c
138
+ onAction: l
131
139
  }) {
132
140
  const n = a.useCallback(() => {
133
- c?.(r.actionId, "confirm");
134
- }, [r.actionId, c]), l = a.useCallback(() => {
135
- c?.(r.actionId, "cancel");
136
- }, [r.actionId, c]);
137
- return /* @__PURE__ */ d(
141
+ l?.(r.actionId, "confirm");
142
+ }, [r.actionId, l]), d = a.useCallback(() => {
143
+ l?.(r.actionId, "cancel");
144
+ }, [r.actionId, l]);
145
+ return /* @__PURE__ */ m(
138
146
  "div",
139
147
  {
140
148
  className: p(
@@ -142,9 +150,9 @@ const ke = a.memo(function({
142
150
  ),
143
151
  children: [
144
152
  r.description && /* @__PURE__ */ e("p", { className: "text-ds-sm text-surface-fg-muted mb-3", children: r.description }),
145
- /* @__PURE__ */ d("div", { className: "flex items-center gap-3", children: [
153
+ /* @__PURE__ */ m("div", { className: "flex items-center gap-3", children: [
146
154
  /* @__PURE__ */ e(
147
- S,
155
+ B,
148
156
  {
149
157
  variant: "solid",
150
158
  color: r.destructive ? "error" : void 0,
@@ -152,10 +160,10 @@ const ke = a.memo(function({
152
160
  children: r.label
153
161
  }
154
162
  ),
155
- /* @__PURE__ */ e(S, { variant: "ghost", onClick: l, children: "Cancel" })
163
+ /* @__PURE__ */ e(B, { variant: "ghost", onClick: d, children: "Cancel" })
156
164
  ] }),
157
- r.rationale && /* @__PURE__ */ d(V, { className: "mt-3", children: [
158
- /* @__PURE__ */ e(F, { asChild: !0, children: /* @__PURE__ */ e(
165
+ r.rationale && /* @__PURE__ */ m(V, { className: "mt-3", children: [
166
+ /* @__PURE__ */ e(K, { asChild: !0, children: /* @__PURE__ */ e(
159
167
  "button",
160
168
  {
161
169
  type: "button",
@@ -163,40 +171,42 @@ const ke = a.memo(function({
163
171
  children: "Why this action?"
164
172
  }
165
173
  ) }),
166
- /* @__PURE__ */ e(G, { children: /* @__PURE__ */ e("p", { className: "text-ds-sm text-surface-fg-muted mt-2 p-3 bg-surface-raised rounded-ds-lg", children: r.rationale }) })
174
+ /* @__PURE__ */ e(F, { children: /* @__PURE__ */ e("p", { className: "text-ds-sm text-surface-fg-muted mt-2 p-3 bg-surface-raised rounded-ds-lg", children: r.rationale }) })
167
175
  ] })
168
176
  ]
169
177
  }
170
178
  );
171
- }), A = 5e3, ye = a.memo(function({
179
+ });
180
+ re.displayName = "ConfirmBlock";
181
+ const ne = 5e3, te = a.memo(function({
172
182
  data: r,
173
183
  blockId: t,
174
- confidence: c,
184
+ confidence: l,
175
185
  onAction: n
176
186
  }) {
177
- const { reducedMotion: l } = y(), i = l, m = r.undoTimeout ?? A, [v, f] = a.useState(m), [g, o] = a.useState(!!r.undoable);
187
+ const { reducedMotion: d } = y(), o = d, u = r.undoTimeout ?? ne, [k, f] = a.useState(u), [g, i] = a.useState(!!r.undoable);
178
188
  a.useEffect(() => {
179
189
  if (!r.undoable) return;
180
190
  const T = setInterval(() => {
181
- f((E) => {
182
- const I = E - 100;
183
- return I <= 0 ? (clearInterval(T), o(!1), 0) : I;
191
+ f((z) => {
192
+ const I = z - 100;
193
+ return I <= 0 ? (clearInterval(T), i(!1), 0) : I;
184
194
  });
185
195
  }, 100);
186
196
  return () => clearInterval(T);
187
- }, [r.undoable, m]);
197
+ }, [r.undoable, u]);
188
198
  const h = a.useCallback(() => {
189
199
  n?.(t || "unknown", "undo");
190
- }, [t, n]), k = Math.ceil(v / 1e3), u = 20, N = 2, b = (u - N) / 2, B = 2 * Math.PI * b;
191
- return /* @__PURE__ */ d(
200
+ }, [t, n]), v = Math.ceil(k / 1e3), c = 20, N = 2, b = (c - N) / 2, w = 2 * Math.PI * b;
201
+ return /* @__PURE__ */ m(
192
202
  "div",
193
203
  {
194
204
  className: p(
195
- c === "low" && "border-l-2 border-warning-7 pl-3"
205
+ l === "low" && "border-l-2 border-warning-7 pl-3"
196
206
  ),
197
207
  children: [
198
208
  /* @__PURE__ */ e(
199
- w,
209
+ S,
200
210
  {
201
211
  color: "success",
202
212
  variant: "subtle",
@@ -205,27 +215,27 @@ const ke = a.memo(function({
205
215
  }
206
216
  ),
207
217
  g && r.undoable && /* @__PURE__ */ e("div", { className: "mt-2 flex items-center gap-2", children: /* @__PURE__ */ e(
208
- S,
218
+ B,
209
219
  {
210
220
  variant: "ghost",
211
221
  size: "sm",
212
222
  onClick: h,
213
- "aria-label": `Undo action, ${k} seconds remaining`,
214
- children: /* @__PURE__ */ d("span", { className: "flex items-center gap-1.5", children: [
215
- /* @__PURE__ */ d(
223
+ "aria-label": `Undo action, ${v} seconds remaining`,
224
+ children: /* @__PURE__ */ m("span", { className: "flex items-center gap-1.5", children: [
225
+ /* @__PURE__ */ m(
216
226
  "svg",
217
227
  {
218
- width: u,
219
- height: u,
220
- viewBox: `0 0 ${u} ${u}`,
228
+ width: c,
229
+ height: c,
230
+ viewBox: `0 0 ${c} ${c}`,
221
231
  className: "shrink-0 -rotate-90",
222
232
  "aria-hidden": "true",
223
233
  children: [
224
234
  /* @__PURE__ */ e(
225
235
  "circle",
226
236
  {
227
- cx: u / 2,
228
- cy: u / 2,
237
+ cx: c / 2,
238
+ cy: c / 2,
229
239
  r: b,
230
240
  fill: "none",
231
241
  stroke: "currentColor",
@@ -236,19 +246,19 @@ const ke = a.memo(function({
236
246
  /* @__PURE__ */ e(
237
247
  x.circle,
238
248
  {
239
- cx: u / 2,
240
- cy: u / 2,
249
+ cx: c / 2,
250
+ cy: c / 2,
241
251
  r: b,
242
252
  fill: "none",
243
253
  stroke: "currentColor",
244
254
  strokeWidth: N,
245
- strokeDasharray: B,
246
- initial: i ? void 0 : { strokeDashoffset: 0 },
255
+ strokeDasharray: w,
256
+ initial: o ? void 0 : { strokeDashoffset: 0 },
247
257
  animate: {
248
- strokeDashoffset: B
258
+ strokeDashoffset: w
249
259
  },
250
- transition: i ? { duration: 0 } : {
251
- duration: m / 1e3,
260
+ transition: o ? { duration: 0 } : {
261
+ duration: u / 1e3,
252
262
  ease: "linear"
253
263
  }
254
264
  }
@@ -263,28 +273,33 @@ const ke = a.memo(function({
263
273
  ]
264
274
  }
265
275
  );
266
- }), Ce = a.memo(function({
276
+ });
277
+ te.displayName = "SuccessBlock";
278
+ const se = a.memo(function({
267
279
  data: r,
268
280
  confidence: t
269
281
  }) {
270
- return /* @__PURE__ */ d(
282
+ return /* @__PURE__ */ m(
271
283
  "div",
272
284
  {
273
285
  className: p(
274
286
  t === "low" && "border-l-2 border-warning-7 pl-3"
275
287
  ),
276
288
  children: [
277
- /* @__PURE__ */ e(w, { color: "error", variant: "subtle", title: r.title, children: /* @__PURE__ */ e("div", { className: "prose prose-sm", children: /* @__PURE__ */ e(L, { remarkPlugins: [U], children: r.message }) }) }),
289
+ /* @__PURE__ */ e(S, { color: "error", variant: "subtle", title: r.title, children: /* @__PURE__ */ e("div", { className: "prose prose-sm", children: /* @__PURE__ */ e(L, { remarkPlugins: [E], children: r.message }) }) }),
278
290
  r.suggestion && /* @__PURE__ */ e("p", { className: "mt-2 text-ds-sm text-surface-fg-muted", children: r.suggestion })
279
291
  ]
280
292
  }
281
293
  );
282
- }), Se = a.memo(function({
294
+ });
295
+ se.displayName = "ErrorBlock";
296
+ const oe = a.memo(function({
283
297
  data: r
284
298
  }) {
285
- return /* @__PURE__ */ e(w, { color: "info", variant: "subtle", children: r.message });
299
+ return /* @__PURE__ */ e(S, { color: "info", variant: "subtle", role: "status", children: r.message });
286
300
  });
287
- function ee() {
301
+ oe.displayName = "InfoBlock";
302
+ function ie() {
288
303
  return /* @__PURE__ */ e(
289
304
  x.span,
290
305
  {
@@ -296,25 +311,25 @@ function ee() {
296
311
  }
297
312
  );
298
313
  }
299
- function re({ status: s }) {
314
+ function ae({ status: s }) {
300
315
  switch (s) {
301
316
  case "done":
302
317
  return /* @__PURE__ */ e("span", { "data-testid": "step-icon-done", children: /* @__PURE__ */ e(C, { icon: J, size: "sm", className: "text-success-11" }) });
303
318
  case "active":
304
- return /* @__PURE__ */ e(ee, {});
319
+ return /* @__PURE__ */ e(ie, {});
305
320
  case "error":
306
321
  return /* @__PURE__ */ e("span", { "data-testid": "step-icon-error", children: /* @__PURE__ */ e(C, { icon: q, size: "sm", className: "text-error-11" }) });
307
322
  default:
308
- return /* @__PURE__ */ e("span", { "data-testid": "step-icon-pending", children: /* @__PURE__ */ e(C, { icon: K, size: "sm", className: "text-surface-fg-subtle opacity-50" }) });
323
+ return /* @__PURE__ */ e("span", { "data-testid": "step-icon-pending", children: /* @__PURE__ */ e(C, { icon: G, size: "sm", className: "text-surface-fg-subtle opacity-50" }) });
309
324
  }
310
325
  }
311
- const we = a.memo(function({
326
+ const le = a.memo(function({
312
327
  data: r
313
328
  }) {
314
- const { reducedMotion: t } = y(), c = t;
329
+ const { reducedMotion: t } = y(), l = t;
315
330
  if (r.lines != null) {
316
331
  const n = Math.max(1, r.lines);
317
- return /* @__PURE__ */ d(
332
+ return /* @__PURE__ */ m(
318
333
  "div",
319
334
  {
320
335
  role: "status",
@@ -322,23 +337,23 @@ const we = a.memo(function({
322
337
  "aria-label": "Loading",
323
338
  className: "flex flex-col gap-2",
324
339
  children: [
325
- Array.from({ length: n }).map((l, i) => /* @__PURE__ */ e(
340
+ Array.from({ length: n }).map((d, o) => /* @__PURE__ */ e(
326
341
  Q,
327
342
  {
328
343
  animation: "shimmer",
329
344
  className: p(
330
345
  "h-4",
331
- i === n - 1 ? "w-3/5" : "w-full"
346
+ o === n - 1 ? "w-3/5" : "w-full"
332
347
  )
333
348
  },
334
- i
349
+ o
335
350
  )),
336
351
  /* @__PURE__ */ e("span", { className: "sr-only", children: "Loading" })
337
352
  ]
338
353
  }
339
354
  );
340
355
  }
341
- return r.steps ? /* @__PURE__ */ d(
356
+ return r.steps ? /* @__PURE__ */ m(
342
357
  "div",
343
358
  {
344
359
  role: "status",
@@ -346,15 +361,15 @@ const we = a.memo(function({
346
361
  "aria-label": "Processing",
347
362
  className: "flex flex-col gap-2",
348
363
  children: [
349
- r.steps.map((n, l) => /* @__PURE__ */ d(
364
+ r.steps.map((n, d) => /* @__PURE__ */ m(
350
365
  x.div,
351
366
  {
352
367
  className: "flex items-center gap-2",
353
- initial: c ? void 0 : { opacity: 0, x: -8 },
368
+ initial: l ? void 0 : { opacity: 0, x: -8 },
354
369
  animate: { opacity: 1, x: 0 },
355
- transition: c ? { duration: 0 } : { duration: 0.2, delay: l * 0.06 },
370
+ transition: l ? { duration: 0 } : { duration: 0.2, delay: d * 0.06 },
356
371
  children: [
357
- /* @__PURE__ */ e(re, { status: n.status }),
372
+ /* @__PURE__ */ e(ae, { status: n.status }),
358
373
  /* @__PURE__ */ e(
359
374
  "span",
360
375
  {
@@ -373,33 +388,37 @@ const we = a.memo(function({
373
388
  ]
374
389
  }
375
390
  ) : /* @__PURE__ */ e("div", { role: "status", "aria-busy": "true", "aria-label": "Loading", children: /* @__PURE__ */ e("span", { className: "sr-only", children: "Loading" }) });
376
- }), Be = a.memo(function(r) {
391
+ });
392
+ le.displayName = "LoadingBlock";
393
+ const ce = a.memo(function(r) {
377
394
  const { reducedMotion: t } = y();
378
- return t ? /* @__PURE__ */ e(R, {}) : /* @__PURE__ */ e(
395
+ return t ? /* @__PURE__ */ e(D, {}) : /* @__PURE__ */ e(
379
396
  x.div,
380
397
  {
381
398
  initial: { scaleX: 0 },
382
399
  animate: { scaleX: 1 },
383
400
  style: { originX: 0.5 },
384
401
  transition: P.elegant,
385
- children: /* @__PURE__ */ e(R, {})
402
+ children: /* @__PURE__ */ e(D, {})
386
403
  }
387
404
  );
388
- }), Te = a.memo(function({
405
+ });
406
+ ce.displayName = "DividerBlock";
407
+ const de = a.memo(function({
389
408
  data: r
390
409
  }) {
391
- const { reducedMotion: t } = y(), c = r.stats ?? [];
392
- return c.length === 0 ? null : /* @__PURE__ */ e("div", { className: "flex flex-wrap gap-ds-05", children: c.map((n, l) => {
393
- const i = n.change ? {
410
+ const { reducedMotion: t } = y(), l = r.stats ?? [];
411
+ return l.length === 0 ? null : /* @__PURE__ */ e("div", { className: "flex flex-wrap gap-ds-05", children: l.map((n, d) => {
412
+ const o = n.change ? {
394
413
  value: n.change.value,
395
414
  direction: n.change.direction
396
415
  } : void 0;
397
416
  return t ? /* @__PURE__ */ e("div", { className: "flex-1 min-w-[140px]", children: /* @__PURE__ */ e(
398
- D,
417
+ M,
399
418
  {
400
419
  label: n.label,
401
420
  value: n.value,
402
- delta: i
421
+ delta: o
403
422
  }
404
423
  ) }, n.label) : /* @__PURE__ */ e(
405
424
  x.div,
@@ -407,13 +426,13 @@ const we = a.memo(function({
407
426
  className: "flex-1 min-w-[140px]",
408
427
  initial: { opacity: 0, y: 8 },
409
428
  animate: { opacity: 1, y: 0 },
410
- transition: { ...z.responsive, delay: l * 0.08 },
429
+ transition: { ...U.responsive, delay: d * 0.08 },
411
430
  children: /* @__PURE__ */ e(
412
- D,
431
+ M,
413
432
  {
414
433
  label: n.label,
415
434
  value: n.value,
416
- delta: i
435
+ delta: o
417
436
  }
418
437
  )
419
438
  },
@@ -421,14 +440,15 @@ const we = a.memo(function({
421
440
  );
422
441
  }) });
423
442
  });
443
+ de.displayName = "StatRowBlock";
424
444
  export {
425
- ke as B,
426
- Ne as C,
427
- Be as D,
428
- Ce as E,
429
- Se as I,
430
- we as L,
431
- Te as S,
432
- ve as T,
433
- ye as a
445
+ ee as B,
446
+ re as C,
447
+ ce as D,
448
+ se as E,
449
+ oe as I,
450
+ le as L,
451
+ de as S,
452
+ Y as T,
453
+ te as a
434
454
  };