@spear-ai/spectral 1.3.67 → 1.4.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 (306) hide show
  1. package/dist/Accordion.js +7 -31
  2. package/dist/Alert/AlertBase.d.ts +10 -1
  3. package/dist/Alert/AlertBase.js +25 -42
  4. package/dist/Alert.d.ts +5 -5
  5. package/dist/Alert.js +43 -54
  6. package/dist/Avatar.js +4 -33
  7. package/dist/Badge.js +1 -6
  8. package/dist/Button.d.ts +1 -1
  9. package/dist/Button.js +32 -67
  10. package/dist/ButtonGroup/ButtonGroupButton.js +1 -10
  11. package/dist/ButtonGroup.js +6 -42
  12. package/dist/ButtonIcon.d.ts +4 -4
  13. package/dist/ButtonIcon.js +44 -53
  14. package/dist/Card.js +6 -13
  15. package/dist/Checkbox/CheckboxBase.js +4 -15
  16. package/dist/Checkbox.js +24 -40
  17. package/dist/Dialog/DialogBase.d.ts +17 -17
  18. package/dist/Dialog/DialogBase.js +13 -62
  19. package/dist/Dialog.d.ts +1 -1
  20. package/dist/Dialog.js +6 -44
  21. package/dist/Drawer.d.ts +6 -6
  22. package/dist/Drawer.js +6 -14
  23. package/dist/HoverCard.d.ts +5 -4
  24. package/dist/HoverCard.js +148 -138
  25. package/dist/Icons/AnalyzeIcon.js +52 -64
  26. package/dist/Icons/AnnotationsIcon.js +8 -20
  27. package/dist/Icons/ApprovedIcon.js +13 -34
  28. package/dist/Icons/CalendarIcon.js +15 -54
  29. package/dist/Icons/CheckCircleIcon.js +5 -21
  30. package/dist/Icons/CheckSquareIcon.js +5 -21
  31. package/dist/Icons/CheckmarkIcon.js +4 -20
  32. package/dist/Icons/ChevronDownIcon.js +4 -20
  33. package/dist/Icons/ChevronUpIcon.js +4 -20
  34. package/dist/Icons/ClockIcon.js +13 -34
  35. package/dist/Icons/CloseCircleIcon.js +5 -21
  36. package/dist/Icons/CloseIcon.js +4 -20
  37. package/dist/Icons/DashboardIcon.js +5 -44
  38. package/dist/Icons/DatabaseIcon.js +14 -44
  39. package/dist/Icons/DeleteIcon.js +14 -44
  40. package/dist/Icons/DurationIcon.js +17 -74
  41. package/dist/Icons/EmailIcon.js +5 -21
  42. package/dist/Icons/EraserIcon.js +16 -37
  43. package/dist/Icons/ErrorIcon.js +6 -22
  44. package/dist/Icons/EyeClosedIcon.js +8 -24
  45. package/dist/Icons/EyeClosedIcon2.js +6 -22
  46. package/dist/Icons/EyeOpenIcon.js +4 -20
  47. package/dist/Icons/GoToFirstIcon.js +4 -34
  48. package/dist/Icons/GoToLastIcon.js +4 -34
  49. package/dist/Icons/HarmonicCursorsIcon.js +4 -31
  50. package/dist/Icons/IconBase.js +5 -22
  51. package/dist/Icons/InfoIcon.js +5 -26
  52. package/dist/Icons/LabelIcon.js +7 -19
  53. package/dist/Icons/LassoIcon.js +23 -44
  54. package/dist/Icons/LineToolIcon.js +5 -17
  55. package/dist/Icons/LineToolIcon2.js +43 -64
  56. package/dist/Icons/LiveViewIcon.js +7 -64
  57. package/dist/Icons/LoaderIcon.js +18 -42
  58. package/dist/Icons/LocationIcon.js +22 -34
  59. package/dist/Icons/LogoutIcon.js +8 -20
  60. package/dist/Icons/MessagesIcon.js +13 -25
  61. package/dist/Icons/MetadataIcon.js +8 -20
  62. package/dist/Icons/MinusIcon.js +1 -17
  63. package/dist/Icons/OntologyIcon.js +66 -78
  64. package/dist/Icons/PanelIconClose.js +5 -21
  65. package/dist/Icons/PanelIconOpen.js +5 -21
  66. package/dist/Icons/PlayIcon.js +1 -22
  67. package/dist/Icons/PlusIcon.js +7 -20
  68. package/dist/Icons/ResetIcon.js +5 -17
  69. package/dist/Icons/ReviewedIcon.js +14 -35
  70. package/dist/Icons/ScissorsIcon.js +12 -30
  71. package/dist/Icons/SettingsIcon.js +22 -34
  72. package/dist/Icons/SortAscendingIcon.js +7 -64
  73. package/dist/Icons/SortDescendingIcon.js +7 -64
  74. package/dist/Icons/StackIcon.js +4 -34
  75. package/dist/Icons/StarIcon.js +1 -22
  76. package/dist/Icons/TrashIcon.js +5 -17
  77. package/dist/Icons/UndoIcon.js +8 -20
  78. package/dist/Icons/UserIcon.js +7 -19
  79. package/dist/Icons/WarningIcon.js +7 -19
  80. package/dist/Icons/ZoomAllIcon.js +10 -94
  81. package/dist/Icons/ZoomXIcon.js +5 -35
  82. package/dist/Icons/ZoomYIcon.js +5 -44
  83. package/dist/Input.d.ts +22 -20
  84. package/dist/Input.js +52 -92
  85. package/dist/InputGroup.js +2 -47
  86. package/dist/InputOTP.js +63 -99
  87. package/dist/Label.js +1 -12
  88. package/dist/MultiSelect/MultiSelectBase.d.ts +24 -24
  89. package/dist/MultiSelect/MultiSelectBase.js +82 -151
  90. package/dist/MultiSelect/MutiSelect.d.ts +6 -6
  91. package/dist/MultiSelect/MutiSelect.js +9 -21
  92. package/dist/Popover.js +2 -9
  93. package/dist/RadioButtonGroup/RadioButtonGroupBase.d.ts +8 -8
  94. package/dist/RadioButtonGroup/RadioButtonGroupBase.js +1 -27
  95. package/dist/RadioButtonGroup.d.ts +1 -1
  96. package/dist/RadioButtonGroup.js +1 -11
  97. package/dist/RadioGroup.d.ts +16 -16
  98. package/dist/RadioGroup.js +40 -92
  99. package/dist/Select.d.ts +7 -6
  100. package/dist/Select.js +81 -135
  101. package/dist/Separator.js +13 -15
  102. package/dist/Slider/SliderBase.js +129 -188
  103. package/dist/Slider.js +4 -41
  104. package/dist/Switch/SwitchBase.js +84 -106
  105. package/dist/Switch.d.ts +6 -6
  106. package/dist/Switch.js +34 -49
  107. package/dist/Tabs/TabsBase.d.ts +18 -18
  108. package/dist/Tabs/TabsBase.js +12 -71
  109. package/dist/Tabs/tabsStoryData.js +2 -2
  110. package/dist/Tabs/tabsUtils.d.ts +17 -17
  111. package/dist/Tabs.d.ts +14 -14
  112. package/dist/Tabs.js +67 -130
  113. package/dist/Textarea/TextareaUtils.d.ts +1 -1
  114. package/dist/Textarea.d.ts +9 -8
  115. package/dist/Textarea.js +49 -84
  116. package/dist/Toggle/ToggleBase.d.ts +4 -4
  117. package/dist/Toggle/ToggleBase.js +2 -27
  118. package/dist/Toggle.js +1 -11
  119. package/dist/ToggleGroup/ToggleGroupBase.d.ts +8 -8
  120. package/dist/ToggleGroup/ToggleGroupBase.js +6 -35
  121. package/dist/ToggleGroup.js +1 -1
  122. package/dist/Tooltip/TooltipBase.d.ts +1 -1
  123. package/dist/Tooltip/TooltipBase.js +5 -47
  124. package/dist/Tray/TrayStoriesData.d.ts +1 -1
  125. package/dist/Tray/TrayStoriesData.js +22 -134
  126. package/dist/Tray.d.ts +6 -2
  127. package/dist/Tray.js +55 -68
  128. package/dist/components/Accordion/Accordion.d.ts.map +1 -1
  129. package/dist/components/Alert/Alert.d.ts +5 -5
  130. package/dist/components/Alert/Alert.d.ts.map +1 -1
  131. package/dist/components/Alert/AlertBase.d.ts +10 -1
  132. package/dist/components/Alert/AlertBase.d.ts.map +1 -1
  133. package/dist/components/Avatar/Avatar.d.ts.map +1 -1
  134. package/dist/components/Badge/Badge.d.ts.map +1 -1
  135. package/dist/components/Button/Button.d.ts +1 -1
  136. package/dist/components/Button/Button.d.ts.map +1 -1
  137. package/dist/components/ButtonGroup/ButtonGroup.d.ts.map +1 -1
  138. package/dist/components/ButtonGroup/ButtonGroupButton.d.ts.map +1 -1
  139. package/dist/components/ButtonIcon/ButtonIcon.d.ts +4 -4
  140. package/dist/components/ButtonIcon/ButtonIcon.d.ts.map +1 -1
  141. package/dist/components/Card/Card.d.ts.map +1 -1
  142. package/dist/components/Checkbox/Checkbox.d.ts.map +1 -1
  143. package/dist/components/Checkbox/CheckboxBase.d.ts.map +1 -1
  144. package/dist/components/Dialog/Dialog.d.ts +1 -1
  145. package/dist/components/Dialog/Dialog.d.ts.map +1 -1
  146. package/dist/components/Dialog/DialogBase.d.ts +17 -17
  147. package/dist/components/Dialog/DialogBase.d.ts.map +1 -1
  148. package/dist/components/Drawer/Drawer.d.ts +6 -6
  149. package/dist/components/Drawer/Drawer.d.ts.map +1 -1
  150. package/dist/components/HoverCard/HoverCard.d.ts +5 -4
  151. package/dist/components/HoverCard/HoverCard.d.ts.map +1 -1
  152. package/dist/components/Icons/AnalyzeIcon.d.ts.map +1 -1
  153. package/dist/components/Icons/AnnotationsIcon.d.ts.map +1 -1
  154. package/dist/components/Icons/ApprovedIcon.d.ts.map +1 -1
  155. package/dist/components/Icons/CalendarIcon.d.ts.map +1 -1
  156. package/dist/components/Icons/CheckCircleIcon.d.ts.map +1 -1
  157. package/dist/components/Icons/CheckSquareIcon.d.ts.map +1 -1
  158. package/dist/components/Icons/CheckmarkIcon.d.ts.map +1 -1
  159. package/dist/components/Icons/ChevronDownIcon.d.ts.map +1 -1
  160. package/dist/components/Icons/ChevronUpIcon.d.ts.map +1 -1
  161. package/dist/components/Icons/ClockIcon.d.ts.map +1 -1
  162. package/dist/components/Icons/CloseCircleIcon.d.ts.map +1 -1
  163. package/dist/components/Icons/CloseIcon.d.ts.map +1 -1
  164. package/dist/components/Icons/DashboardIcon.d.ts.map +1 -1
  165. package/dist/components/Icons/DatabaseIcon.d.ts.map +1 -1
  166. package/dist/components/Icons/DeleteIcon.d.ts.map +1 -1
  167. package/dist/components/Icons/DurationIcon.d.ts.map +1 -1
  168. package/dist/components/Icons/EmailIcon.d.ts.map +1 -1
  169. package/dist/components/Icons/EraserIcon.d.ts.map +1 -1
  170. package/dist/components/Icons/ErrorIcon.d.ts.map +1 -1
  171. package/dist/components/Icons/EyeClosedIcon.d.ts.map +1 -1
  172. package/dist/components/Icons/EyeClosedIcon2.d.ts.map +1 -1
  173. package/dist/components/Icons/EyeOpenIcon.d.ts.map +1 -1
  174. package/dist/components/Icons/GoToFirstIcon.d.ts.map +1 -1
  175. package/dist/components/Icons/GoToLastIcon.d.ts.map +1 -1
  176. package/dist/components/Icons/HarmonicCursorsIcon.d.ts.map +1 -1
  177. package/dist/components/Icons/IconBase.d.ts.map +1 -1
  178. package/dist/components/Icons/InfoIcon.d.ts.map +1 -1
  179. package/dist/components/Icons/LabelIcon.d.ts.map +1 -1
  180. package/dist/components/Icons/LassoIcon.d.ts.map +1 -1
  181. package/dist/components/Icons/LineToolIcon.d.ts.map +1 -1
  182. package/dist/components/Icons/LineToolIcon2.d.ts.map +1 -1
  183. package/dist/components/Icons/LiveViewIcon.d.ts.map +1 -1
  184. package/dist/components/Icons/LoaderIcon.d.ts.map +1 -1
  185. package/dist/components/Icons/LocationIcon.d.ts.map +1 -1
  186. package/dist/components/Icons/LogoutIcon.d.ts.map +1 -1
  187. package/dist/components/Icons/MessagesIcon.d.ts.map +1 -1
  188. package/dist/components/Icons/MetadataIcon.d.ts.map +1 -1
  189. package/dist/components/Icons/MinusIcon.d.ts.map +1 -1
  190. package/dist/components/Icons/OntologyIcon.d.ts.map +1 -1
  191. package/dist/components/Icons/PanelIconClose.d.ts.map +1 -1
  192. package/dist/components/Icons/PanelIconOpen.d.ts.map +1 -1
  193. package/dist/components/Icons/PlayIcon.d.ts.map +1 -1
  194. package/dist/components/Icons/PlusIcon.d.ts.map +1 -1
  195. package/dist/components/Icons/ResetIcon.d.ts.map +1 -1
  196. package/dist/components/Icons/ReviewedIcon.d.ts.map +1 -1
  197. package/dist/components/Icons/ScissorsIcon.d.ts.map +1 -1
  198. package/dist/components/Icons/SettingsIcon.d.ts.map +1 -1
  199. package/dist/components/Icons/SortAscendingIcon.d.ts.map +1 -1
  200. package/dist/components/Icons/SortDescendingIcon.d.ts.map +1 -1
  201. package/dist/components/Icons/StackIcon.d.ts.map +1 -1
  202. package/dist/components/Icons/StarIcon.d.ts.map +1 -1
  203. package/dist/components/Icons/TrashIcon.d.ts.map +1 -1
  204. package/dist/components/Icons/UndoIcon.d.ts.map +1 -1
  205. package/dist/components/Icons/UserIcon.d.ts.map +1 -1
  206. package/dist/components/Icons/WarningIcon.d.ts.map +1 -1
  207. package/dist/components/Icons/ZoomAllIcon.d.ts.map +1 -1
  208. package/dist/components/Icons/ZoomXIcon.d.ts.map +1 -1
  209. package/dist/components/Icons/ZoomYIcon.d.ts.map +1 -1
  210. package/dist/components/Input/Input.d.ts +22 -20
  211. package/dist/components/Input/Input.d.ts.map +1 -1
  212. package/dist/components/Input/InputUtils.d.ts.map +1 -1
  213. package/dist/components/InputGroup/InputGroup.d.ts.map +1 -1
  214. package/dist/components/InputOTP/InputOTP.d.ts.map +1 -1
  215. package/dist/components/Label/Label.d.ts.map +1 -1
  216. package/dist/components/MultiSelect/MultiSelectBase.d.ts +24 -24
  217. package/dist/components/MultiSelect/MultiSelectBase.d.ts.map +1 -1
  218. package/dist/components/MultiSelect/MutiSelect.d.ts +6 -6
  219. package/dist/components/MultiSelect/MutiSelect.d.ts.map +1 -1
  220. package/dist/components/Popover/Popover.d.ts.map +1 -1
  221. package/dist/components/RadioButtonGroup/RadioButtonGroup.d.ts +1 -1
  222. package/dist/components/RadioButtonGroup/RadioButtonGroup.d.ts.map +1 -1
  223. package/dist/components/RadioButtonGroup/RadioButtonGroupBase.d.ts +8 -8
  224. package/dist/components/RadioButtonGroup/RadioButtonGroupBase.d.ts.map +1 -1
  225. package/dist/components/RadioGroup/RadioGroup.d.ts +16 -16
  226. package/dist/components/RadioGroup/RadioGroup.d.ts.map +1 -1
  227. package/dist/components/Select/Select.d.ts +7 -6
  228. package/dist/components/Select/Select.d.ts.map +1 -1
  229. package/dist/components/Separator/Separator.d.ts.map +1 -1
  230. package/dist/components/Slider/Slider.d.ts.map +1 -1
  231. package/dist/components/Slider/SliderBase.d.ts.map +1 -1
  232. package/dist/components/Switch/Switch.d.ts +6 -6
  233. package/dist/components/Switch/Switch.d.ts.map +1 -1
  234. package/dist/components/Switch/SwitchBase.d.ts.map +1 -1
  235. package/dist/components/Tabs/Tabs.d.ts +14 -14
  236. package/dist/components/Tabs/Tabs.d.ts.map +1 -1
  237. package/dist/components/Tabs/TabsBase.d.ts +18 -18
  238. package/dist/components/Tabs/TabsBase.d.ts.map +1 -1
  239. package/dist/components/Tabs/tabsStoryData.d.ts.map +1 -1
  240. package/dist/components/Tabs/tabsUtils.d.ts +17 -17
  241. package/dist/components/Tabs/tabsUtils.d.ts.map +1 -1
  242. package/dist/components/Textarea/Textarea.d.ts +9 -8
  243. package/dist/components/Textarea/Textarea.d.ts.map +1 -1
  244. package/dist/components/Textarea/TextareaUtils.d.ts +1 -1
  245. package/dist/components/Textarea/TextareaUtils.d.ts.map +1 -1
  246. package/dist/components/Toggle/Toggle.d.ts.map +1 -1
  247. package/dist/components/Toggle/ToggleBase.d.ts +4 -4
  248. package/dist/components/Toggle/ToggleBase.d.ts.map +1 -1
  249. package/dist/components/ToggleGroup/ToggleGroup.d.ts.map +1 -1
  250. package/dist/components/ToggleGroup/ToggleGroupBase.d.ts +8 -8
  251. package/dist/components/ToggleGroup/ToggleGroupBase.d.ts.map +1 -1
  252. package/dist/components/Tooltip/Tooltip.d.ts.map +1 -1
  253. package/dist/components/Tooltip/TooltipBase.d.ts +1 -1
  254. package/dist/components/Tooltip/TooltipBase.d.ts.map +1 -1
  255. package/dist/components/Tray/Tray.d.ts +6 -2
  256. package/dist/components/Tray/Tray.d.ts.map +1 -1
  257. package/dist/components/Tray/TrayStoriesData.d.ts +1 -1
  258. package/dist/components/Tray/TrayStoriesData.d.ts.map +1 -1
  259. package/dist/features/AuthCard/AuthCard.d.ts.map +1 -1
  260. package/dist/features/AuthCard/AuthToggle.d.ts.map +1 -1
  261. package/dist/features/AuthCard/AuthToggle.js +4 -20
  262. package/dist/features/AuthCard/ForgotPasswordEmailForm.d.ts +1 -1
  263. package/dist/features/AuthCard/ForgotPasswordEmailForm.d.ts.map +1 -1
  264. package/dist/features/AuthCard/ForgotPasswordEmailForm.js +5 -21
  265. package/dist/features/AuthCard/ForgotPasswordResetForm.d.ts +1 -1
  266. package/dist/features/AuthCard/ForgotPasswordResetForm.d.ts.map +1 -1
  267. package/dist/features/AuthCard/ForgotPasswordResetForm.js +5 -50
  268. package/dist/features/AuthCard/OTPInput.d.ts +1 -1
  269. package/dist/features/AuthCard/OTPInput.d.ts.map +1 -1
  270. package/dist/features/AuthCard/OTPInput.js +3 -21
  271. package/dist/features/AuthCard/PasswordInput.d.ts +1 -1
  272. package/dist/features/AuthCard/PasswordInput.d.ts.map +1 -1
  273. package/dist/features/AuthCard/PasswordInput.js +9 -50
  274. package/dist/features/AuthCard/SignInForm.d.ts.map +1 -1
  275. package/dist/features/AuthCard/SignInForm.js +7 -51
  276. package/dist/features/AuthCard/SignUpForm.d.ts.map +1 -1
  277. package/dist/features/AuthCard/SignUpForm.js +10 -55
  278. package/dist/features/AuthCard.js +144 -248
  279. package/dist/features/ClearDialog/ClearDialog.d.ts.map +1 -1
  280. package/dist/features/ClearDialog.js +10 -10
  281. package/dist/features/LabelingTools/LabelingTools.d.ts.map +1 -1
  282. package/dist/features/LabelingTools.js +21 -56
  283. package/dist/features/SensorMetadata/SensorMetadata.d.ts.map +1 -1
  284. package/dist/features/SensorMetadata.js +20 -20
  285. package/dist/features/SettingsPopover/SettingsPopover.d.ts.map +1 -1
  286. package/dist/features/SettingsPopover.js +14 -14
  287. package/dist/hooks/useAccordionAutoScroll.d.ts.map +1 -1
  288. package/dist/hooks/useControllableState.d.ts.map +1 -1
  289. package/dist/index.d.ts +2 -2
  290. package/dist/index.d.ts.map +1 -1
  291. package/dist/primitives/button.d.ts.map +1 -1
  292. package/dist/primitives/input.d.ts.map +1 -1
  293. package/dist/primitives/input.js +4 -1
  294. package/dist/primitives/select.d.ts +1 -1
  295. package/dist/primitives/select.d.ts.map +1 -1
  296. package/dist/primitives/select.js +7 -55
  297. package/dist/primitives/slot.d.ts.map +1 -1
  298. package/dist/primitives/slot.js +1 -4
  299. package/dist/primitives/textarea.d.ts.map +1 -1
  300. package/dist/primitives/textarea.js +3 -1
  301. package/dist/styles/main.css +1 -1
  302. package/dist/utils/formFieldUtils.d.ts +4 -2
  303. package/dist/utils/formFieldUtils.d.ts.map +1 -1
  304. package/dist/utils/formFieldUtils.js +3 -34
  305. package/dist/utils/refs.d.ts.map +1 -1
  306. package/package.json +26 -17
package/dist/Accordion.js CHANGED
@@ -403,7 +403,7 @@ const Be = {
403
403
  "data-auto-scroll": t,
404
404
  "data-scroll-padding": r,
405
405
  ...a.type === "single" ? { collapsible: !0 } : {},
406
- className: _("accordion-wrapper flex flex-col", Be[e]),
406
+ className: _("flex flex-col accordion-wrapper", Be[e]),
407
407
  children: ve.map(n, (p) => Ce(p) ? be(p, { variant: e }) : p)
408
408
  }
409
409
  ) });
@@ -411,15 +411,7 @@ const Be = {
411
411
  qe.displayName = "Accordion";
412
412
  const Je = w(({ className: e, ...a }, o) => {
413
413
  const { variant: t = "default" } = ge(de);
414
- return /* @__PURE__ */ i(
415
- Ke,
416
- {
417
- ref: o,
418
- "data-slot": "accordion-item",
419
- className: _("border-level-four w-full border-b p-4", Ue[t], e),
420
- ...a
421
- }
422
- );
414
+ return /* @__PURE__ */ i(Ke, { ref: o, "data-slot": "accordion-item", className: _("w-full border-b border-level-four p-4", Ue[t], e), ...a });
423
415
  });
424
416
  Je.displayName = "AccordionItem";
425
417
  const Ye = w(({ className: e, title: a, subtitle: o, ...t }, r) => {
@@ -434,17 +426,13 @@ const Ye = w(({ className: e, title: a, subtitle: o, ...t }, r) => {
434
426
  {
435
427
  ref: l,
436
428
  "data-slot": "accordion-trigger",
437
- className: _(
438
- "text-text-primary flex flex-1 items-center justify-between text-sm font-normal transition-all hover:no-underline",
439
- "disabled:cursor-not-allowed [&[data-state=open]>svg]:rotate-180",
440
- e
441
- ),
429
+ className: _("flex flex-1 items-center justify-between text-sm font-normal text-text-primary transition-all hover:no-underline", "disabled:cursor-not-allowed [&[data-state=open]>svg]:rotate-180", e),
442
430
  onClick: c,
443
431
  ...t,
444
432
  children: [
445
- /* @__PURE__ */ F("div", { className: "flex w-full flex-col space-y-0.5 text-start", children: [
446
- /* @__PURE__ */ i("div", { className: "text-text-primary text-base font-medium", children: a }),
447
- o && /* @__PURE__ */ i("div", { className: "text-text-secondary text-sm font-normal", children: o })
433
+ /* @__PURE__ */ F("div", { className: "flex flex-col space-y-0.5 text-start w-full", children: [
434
+ /* @__PURE__ */ i("div", { className: "text-base font-medium text-text-primary", children: a }),
435
+ o && /* @__PURE__ */ i("div", { className: "text-sm font-normal text-text-secondary", children: o })
448
436
  ] }),
449
437
  /* @__PURE__ */ i(me, { className: "shrink-0 transition-transform duration-200" })
450
438
  ]
@@ -452,19 +440,7 @@ const Ye = w(({ className: e, title: a, subtitle: o, ...t }, r) => {
452
440
  ) });
453
441
  });
454
442
  Ye.displayName = "AccordionTrigger";
455
- const Qe = w(({ className: e, children: a, ...o }, t) => /* @__PURE__ */ i(
456
- ze,
457
- {
458
- ref: t,
459
- "data-slot": "accordion-content",
460
- className: _(
461
- "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden pt-4 text-sm",
462
- e
463
- ),
464
- ...o,
465
- children: /* @__PURE__ */ i("div", { className: "px-1 pt-0 pb-4", "data-slot": "accordion-content-inner", children: a })
466
- }
467
- ));
443
+ const Qe = w(({ className: e, children: a, ...o }, t) => /* @__PURE__ */ i(ze, { ref: t, "data-slot": "accordion-content", className: _("overflow-hidden pt-4 text-sm data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down", e), ...o, children: /* @__PURE__ */ i("div", { className: "px-1 pb-4 pt-0", "data-slot": "accordion-content-inner", children: a }) }));
468
444
  Qe.displayName = "AccordionContent";
469
445
  export {
470
446
  qe as Accordion,
@@ -1,9 +1,18 @@
1
1
  import { VariantProps } from 'class-variance-authority';
2
2
  import { HTMLAttributes, ReactNode } from 'react';
3
+ declare const titleIconColors: {
4
+ success: string;
5
+ warning: string;
6
+ danger: string;
7
+ info: string;
8
+ default: string;
9
+ };
3
10
  export declare const AlertBase: import('react').ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
4
11
  variant?: "default" | "success" | "warning" | "danger" | "info" | null | undefined;
5
12
  } & import('class-variance-authority/types').ClassProp) | undefined) => string> & import('react').RefAttributes<HTMLDivElement>>;
6
- export declare const AlertTitle: import('react').ForwardRefExoticComponent<HTMLAttributes<HTMLHeadingElement> & import('react').RefAttributes<HTMLParagraphElement>>;
13
+ export declare const AlertTitle: import('react').ForwardRefExoticComponent<HTMLAttributes<HTMLHeadingElement> & {
14
+ variant: keyof typeof titleIconColors;
15
+ } & import('react').RefAttributes<HTMLParagraphElement>>;
7
16
  export declare const AlertDescription: import('react').ForwardRefExoticComponent<HTMLAttributes<HTMLParagraphElement> & import('react').RefAttributes<HTMLParagraphElement>>;
8
17
  type AlertPortalProps = {
9
18
  children: ReactNode;
@@ -1,63 +1,46 @@
1
1
  "use client";
2
2
  import "../styles/main.css";
3
- import { jsx as s } from "react/jsx-runtime";
4
- import { cn as l } from "../utils/twUtils.js";
5
- import { c as i } from "../index-D29mdTf5.js";
6
- import { forwardRef as o, useState as n, useEffect as d } from "react";
7
- import { createPortal as c } from "react-dom";
8
- const g = i(
9
- `fixed top-2 left-1/2 -translate-x-1/2 z-50 w-full max-w-md rounded-md border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4
10
- [&>svg]:translate-y-0.5 [&>svg]:text-current transform transition-all duration-300 ease-in-out translate-y-0 opacity-100 scale-100 animate-in slide-in-from-top-full fade-in duration-300`,
3
+ import { jsx as l } from "react/jsx-runtime";
4
+ import { cn as s } from "../utils/twUtils.js";
5
+ import { c as n } from "../index-D29mdTf5.js";
6
+ import { forwardRef as i, useState as o, useEffect as d } from "react";
7
+ import { createPortal as g } from "react-dom";
8
+ const c = n(
9
+ `fixed top-2 left-1/2 -translate-x-1/2 z-50 w-full max-w-md rounded-md border px-4 py-3 text-sm flex has-[>svg]:grid-cols-[6_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-2 gap-y-0.5
10
+ items-start [&>svg]:size-6 [&>svg]:translate-y-0.5 transform transition-all duration-300 ease-in-out translate-y-0 opacity-100 scale-100 animate-in slide-in-from-top-full fade-in duration-300`,
11
11
  {
12
12
  variants: {
13
13
  variant: {
14
14
  default: "bg-alert-bg text-alert-text border-alert-border",
15
- success: "bg-alert-success-bg text-alert-success-text border-alert-success-border",
16
- warning: "bg-alert-warning-bg text-alert-warning-text border-alert-warning-border",
17
- danger: "bg-alert-danger-bg text-alert-danger-text border-alert-danger-border",
18
- info: "bg-alert-info-bg text-alert-info-text border-alert-info-border"
15
+ success: "bg-alert-success-bg border-alert-success-border [&>svg]:!text-alert-success-text [&>svg]items-start",
16
+ warning: "bg-alert-warning-bg border-alert-warning-border [&>svg]:!text-alert-warning-text [&_[data-slot='alert-title']]:!text-alert-warning-text",
17
+ danger: "bg-alert-danger-bg border-alert-danger-border [&>svg]:!text-alert-danger-text [&_[data-slot='alert-title']]:!text-alert-danger-text",
18
+ info: "bg-alert-info-bg border-alert-info-border [&>svg]:!text-alert-info-text [&_[data-slot='alert-title']]:!text-alert-info-text"
19
19
  }
20
20
  },
21
21
  defaultVariants: {
22
22
  variant: "default"
23
23
  }
24
24
  }
25
- ), f = o(({ className: t, variant: e, ...r }, a) => /* @__PURE__ */ s("div", { "data-slot": "alert", role: "alert", className: l(g({ variant: e }), t), ref: a, ...r }));
25
+ ), x = {
26
+ success: "text-alert-success-text",
27
+ warning: "text-alert-warning-text",
28
+ danger: "text-alert-danger-text",
29
+ info: "text-alert-info-text",
30
+ default: "text-alert-text"
31
+ }, f = i(({ className: t, variant: e, ...r }, a) => /* @__PURE__ */ l("div", { "data-slot": "alert", role: "alert", className: s(c({ variant: e }), t), ref: a, ...r }));
26
32
  f.displayName = "AlertBase";
27
- const m = o(
28
- ({ className: t, ...e }, r) => /* @__PURE__ */ s(
29
- "div",
30
- {
31
- "data-slot": "alert-title",
32
- ref: r,
33
- className: l("col-start-2 line-clamp-1 min-h-4 text-base font-semibold tracking-tight", t),
34
- ...e
35
- }
36
- )
37
- );
33
+ const m = i(({ className: t, variant: e, ...r }, a) => /* @__PURE__ */ l("div", { "data-slot": "alert-title", ref: a, className: s(x[e], "col-start-2 line-clamp-1 min-h-4 font-semibold text-base tracking-tight h-6 flex items-center", t), ...r }));
38
34
  m.displayName = "AlertTitle";
39
- const u = o(
40
- ({ className: t, ...e }, r) => /* @__PURE__ */ s(
41
- "div",
42
- {
43
- "data-slot": "alert-description",
44
- className: l(
45
- "text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",
46
- t
47
- ),
48
- ref: r,
49
- ...e
50
- }
51
- )
52
- );
35
+ const u = i(({ className: t, ...e }, r) => /* @__PURE__ */ l("div", { "data-slot": "alert-description", className: s("text-primary-inverse col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed", t), ref: r, ...e }));
53
36
  u.displayName = "AlertDescription";
54
- function w({ children: t, container: e }) {
55
- const [r, a] = n(!1);
56
- return d(() => (a(!0), () => a(!1)), []), r ? c(t, e ?? document.body) : null;
37
+ function A({ children: t, container: e }) {
38
+ const [r, a] = o(!1);
39
+ return d(() => (a(!0), () => a(!1)), []), r ? g(t, e ?? document.body) : null;
57
40
  }
58
41
  export {
59
42
  f as AlertBase,
60
43
  u as AlertDescription,
61
- w as AlertPortal,
44
+ A as AlertPortal,
62
45
  m as AlertTitle
63
46
  };
package/dist/Alert.d.ts CHANGED
@@ -2,11 +2,11 @@ import { ReactNode } from 'react';
2
2
  export interface AlertProps {
3
3
  onClose?: () => void;
4
4
  className?: string;
5
- readonly description: string | ReactNode | undefined;
6
- readonly icon?: ReactNode;
7
- readonly id: string | undefined;
8
- readonly title: string | undefined;
9
- readonly variant?: 'default' | 'info' | 'success' | 'warning' | 'danger';
5
+ description: string | ReactNode | undefined;
6
+ icon?: ReactNode;
7
+ id: string | undefined;
8
+ title: string | undefined;
9
+ variant?: 'default' | 'info' | 'success' | 'warning' | 'danger';
10
10
  }
11
11
  export declare const Alert: ({ id, description, onClose, icon, title, className, variant }: AlertProps) => import("react/jsx-runtime").JSX.Element;
12
12
  //# sourceMappingURL=Alert.d.ts.map
package/dist/Alert.js CHANGED
@@ -1,19 +1,19 @@
1
1
  "use client";
2
2
  import "./styles/main.css";
3
- import { jsx as r, jsxs as m } from "react/jsx-runtime";
4
- import { AlertPortal as v, AlertBase as w, AlertTitle as y, AlertDescription as I } from "./Alert/AlertBase.js";
3
+ import { jsx as t, jsxs as m } from "react/jsx-runtime";
4
+ import { AlertPortal as y, AlertBase as h, AlertTitle as v, AlertDescription as A } from "./Alert/AlertBase.js";
5
5
  import "./Icons/AnalyzeIcon.js";
6
6
  import "./Icons/AnnotationsIcon.js";
7
7
  import "./Icons/ApprovedIcon.js";
8
8
  import "./Icons/CalendarIcon.js";
9
9
  import "./Icons/CheckCircleIcon.js";
10
- import { CheckSquareIcon as A } from "./Icons/CheckSquareIcon.js";
10
+ import { CheckSquareIcon as w } from "./Icons/CheckSquareIcon.js";
11
11
  import "./Icons/CheckmarkIcon.js";
12
12
  import "./Icons/ChevronDownIcon.js";
13
13
  import "./Icons/ChevronUpIcon.js";
14
14
  import "./Icons/ClockIcon.js";
15
15
  import { CloseCircleIcon as b } from "./Icons/CloseCircleIcon.js";
16
- import { CloseIcon as N } from "./Icons/CloseIcon.js";
16
+ import { CloseIcon as C } from "./Icons/CloseIcon.js";
17
17
  import "./Icons/DashboardIcon.js";
18
18
  import "./Icons/DatabaseIcon.js";
19
19
  import "./Icons/DeleteIcon.js";
@@ -27,7 +27,7 @@ import "./Icons/EyeOpenIcon.js";
27
27
  import "./Icons/GoToFirstIcon.js";
28
28
  import "./Icons/GoToLastIcon.js";
29
29
  import "./Icons/HarmonicCursorsIcon.js";
30
- import { InfoIcon as C } from "./Icons/InfoIcon.js";
30
+ import { InfoIcon as E } from "./Icons/InfoIcon.js";
31
31
  import "./Icons/LabelIcon.js";
32
32
  import "./Icons/LassoIcon.js";
33
33
  import "./Icons/LineToolIcon.js";
@@ -55,66 +55,55 @@ import "./Icons/StarIcon.js";
55
55
  import "./Icons/TrashIcon.js";
56
56
  import "./Icons/UndoIcon.js";
57
57
  import "./Icons/UserIcon.js";
58
- import { WarningIcon as E } from "./Icons/WarningIcon.js";
58
+ import { WarningIcon as N } from "./Icons/WarningIcon.js";
59
59
  import "./Icons/ZoomAllIcon.js";
60
60
  import "./Icons/ZoomXIcon.js";
61
61
  import "./Icons/ZoomYIcon.js";
62
62
  import { cn as g } from "./utils/twUtils.js";
63
- import { useRef as x, useEffect as R } from "react";
64
- const Vr = ({ id: a, description: s, onClose: c, icon: l, title: d, className: u, variant: o = "default" }) => {
65
- const t = x(null), i = l || {
66
- info: /* @__PURE__ */ r(C, {}),
67
- success: /* @__PURE__ */ r(A, {}),
68
- warning: /* @__PURE__ */ r(E, {}),
69
- danger: /* @__PURE__ */ r(b, {}),
63
+ import { useRef as R, useEffect as T } from "react";
64
+ const Vt = ({ id: n, description: a, onClose: s, icon: l, title: c, className: d, variant: o = "default" }) => {
65
+ const r = R(null), u = l || {
66
+ info: /* @__PURE__ */ t(E, {}),
67
+ success: /* @__PURE__ */ t(w, {}),
68
+ warning: /* @__PURE__ */ t(N, {}),
69
+ danger: /* @__PURE__ */ t(b, {}),
70
70
  default: null
71
71
  }[o];
72
- R(() => {
73
- const p = (n) => {
74
- n.key === "Escape" && t.current && (n.preventDefault(), e());
72
+ T(() => {
73
+ const e = (p) => {
74
+ p.key === "Escape" && r.current && (p.preventDefault(), i());
75
75
  };
76
- return document.addEventListener("keydown", p), () => {
77
- document.removeEventListener("keydown", p);
76
+ return document.addEventListener("keydown", e), () => {
77
+ document.removeEventListener("keydown", e);
78
78
  };
79
79
  }, []);
80
- const e = () => {
81
- t.current && (t.current.style.opacity = "0", setTimeout(() => {
82
- t.current && (t.current.style.display = "none"), c?.();
80
+ const i = () => {
81
+ r.current && (r.current.style.opacity = "0", setTimeout(() => {
82
+ r.current && (r.current.style.display = "none"), s?.();
83
83
  }, 300));
84
84
  }, f = () => {
85
- e();
86
- }, h = (/* @__PURE__ */ new Set(["danger", "warning"])).has(o) ? "assertive" : "polite";
87
- return /* @__PURE__ */ r(v, { children: /* @__PURE__ */ m(
88
- w,
89
- {
90
- ref: t,
91
- id: a,
92
- "aria-live": h,
93
- variant: o,
94
- "data-variant": o,
95
- className: g("alert-wrapper tw-transition-opacity tw-duration-300 flex", u),
96
- children: [
97
- i && /* @__PURE__ */ r("div", { className: "icon-wrapper aria-hidden mr-2", children: i }),
98
- /* @__PURE__ */ m("div", { className: "content-wrapper", children: [
99
- /* @__PURE__ */ r(y, { children: d }),
100
- /* @__PURE__ */ r(I, { children: s })
101
- ] }),
102
- /* @__PURE__ */ r(
103
- "button",
104
- {
105
- type: "button",
106
- tabIndex: 0,
107
- className: "close-icon-wrapper focus-visible:outline-text-secondary absolute top-2 right-2 cursor-pointer rounded outline-transparent focus-visible:outline-1 focus-visible:outline-offset-1",
108
- onClick: f,
109
- "aria-label": "Close alert",
110
- "data-testid": "alert-close-button",
111
- children: /* @__PURE__ */ r(N, { size: 20, "aria-hidden": "true" })
112
- }
113
- )
114
- ]
115
- }
116
- ) });
85
+ i();
86
+ }, I = (/* @__PURE__ */ new Set(["danger", "warning"])).has(o) ? "assertive" : "polite";
87
+ return /* @__PURE__ */ t(y, { children: /* @__PURE__ */ m(h, { "aria-live": I, className: g("alert-wrapper transition-opacity duration-300", d), "data-slot": "alert", "data-variant": o, id: n, ref: r, variant: o, children: [
88
+ u,
89
+ /* @__PURE__ */ m("div", { className: "content-wrapper", children: [
90
+ /* @__PURE__ */ t(v, { "data-slot": "alert-title", variant: o, children: c }),
91
+ /* @__PURE__ */ t(A, { "data-slot": "alert-description", children: a })
92
+ ] }),
93
+ /* @__PURE__ */ t(
94
+ C,
95
+ {
96
+ "aria-label": "Close alert",
97
+ className: "close-icon-wrapper absolute right-2 top-2 cursor-pointer focus-visible:outline-1 outline-transparent focus-visible:outline-text-secondary focus-visible:outline-offset-1 rounded",
98
+ "data-slot": "close-icon",
99
+ "data-testid": "alert-close-button",
100
+ onClick: f,
101
+ size: 20,
102
+ tabIndex: 0
103
+ }
104
+ )
105
+ ] }) });
117
106
  };
118
107
  export {
119
- Vr as Alert
108
+ Vt as Alert
120
109
  };
package/dist/Avatar.js CHANGED
@@ -32,20 +32,10 @@ const y = {
32
32
  }, [t]);
33
33
  const p = () => {
34
34
  if (l)
35
- return /* @__PURE__ */ n(
36
- "span",
37
- {
38
- className: i(
39
- "text-text-primary flex h-full w-full items-center justify-center font-bold tracking-tighter",
40
- v[a]
41
- ),
42
- "aria-label": `${l} avatar`,
43
- children: N(l)
44
- }
45
- );
35
+ return /* @__PURE__ */ n("span", { className: i("flex items-center justify-center w-full h-full font-bold text-text-primary tracking-tighter", v[a]), "aria-label": `${l} avatar`, children: N(l) });
46
36
  if (e) {
47
37
  const r = j[a];
48
- return /* @__PURE__ */ n("span", { className: "flex h-full w-full items-center justify-center", children: w(e) ? (() => {
38
+ return /* @__PURE__ */ n("span", { className: "flex items-center justify-center w-full h-full", children: w(e) ? (() => {
49
39
  const m = {
50
40
  className: i("shrink-0", e.props.className),
51
41
  "aria-hidden": "true"
@@ -60,28 +50,9 @@ const y = {
60
50
  return u(e, m);
61
51
  })() : e });
62
52
  }
63
- return t && f === "loaded" ? /* @__PURE__ */ n(
64
- "img",
65
- {
66
- src: t,
67
- "aria-label": c || "Avatar",
68
- alt: c || "Avatar",
69
- className: "absolute inset-0 h-full w-full rounded-full object-cover"
70
- }
71
- ) : t && f === "error" && s ? /* @__PURE__ */ n("span", { className: "flex h-full w-full items-center justify-center", children: s }) : s ? /* @__PURE__ */ n("span", { className: "text-text-primary flex h-full w-full items-center justify-center", children: s }) : /* @__PURE__ */ n("span", { className: "border-danger-300 text-danger-300 flex h-full w-full items-center justify-center rounded-full border-2 font-bold", children: "?" });
53
+ return t && f === "loaded" ? /* @__PURE__ */ n("img", { src: t, "aria-label": c || "Avatar", alt: c || "Avatar", className: "absolute inset-0 w-full h-full object-cover rounded-full" }) : t && f === "error" && s ? /* @__PURE__ */ n("span", { className: "flex items-center justify-center w-full h-full", children: s }) : s ? /* @__PURE__ */ n("span", { className: "flex items-center justify-center w-full h-full text-text-primary", children: s }) : /* @__PURE__ */ n("span", { className: "flex items-center justify-center w-full h-full font-bold border-2 border-danger-300 text-danger-300 rounded-full", children: "?" });
72
54
  };
73
- return /* @__PURE__ */ n(
74
- "span",
75
- {
76
- className: i(
77
- "bg-level-two relative inline-flex shrink-0 items-center justify-center overflow-hidden rounded-full",
78
- y[a],
79
- d
80
- ),
81
- "data-slot": "avatar",
82
- children: p()
83
- }
84
- );
55
+ return /* @__PURE__ */ n("span", { className: i("relative inline-flex items-center justify-center overflow-hidden rounded-full shrink-0 bg-level-two", y[a], d), "data-slot": "avatar", children: p() });
85
56
  };
86
57
  export {
87
58
  E as Avatar
package/dist/Badge.js CHANGED
@@ -20,12 +20,7 @@ const s = d(
20
20
  variant: "default"
21
21
  }
22
22
  }
23
- ), m = ({
24
- className: e,
25
- variant: r,
26
- asChild: a = !1,
27
- ...t
28
- }) => /* @__PURE__ */ o(a ? i : "span", { "data-slot": "badge", className: n(s({ variant: r }), e), ...t });
23
+ ), m = ({ className: e, variant: r, asChild: a = !1, ...t }) => /* @__PURE__ */ o(a ? i : "span", { "data-slot": "badge", className: n(s({ variant: r }), e), ...t });
29
24
  export {
30
25
  m as Badge
31
26
  };
package/dist/Button.d.ts CHANGED
@@ -2,7 +2,7 @@ import { VariantProps } from 'class-variance-authority';
2
2
  import { ButtonHTMLAttributes, MouseEvent, ReactNode } from 'react';
3
3
  declare const buttonVariants: (props?: ({
4
4
  variant?: "secondary" | "outline" | "primary" | "ghost" | "card" | null | undefined;
5
- size?: "default" | "card" | "fullWidth" | null | undefined;
5
+ size?: "default" | "fullWidth" | null | undefined;
6
6
  state?: "default" | "error" | "loading" | null | undefined;
7
7
  } & import('class-variance-authority/types').ClassProp) | undefined) => string;
8
8
  export interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'color'>, VariantProps<typeof buttonVariants> {
package/dist/Button.js CHANGED
@@ -5,7 +5,7 @@ import { cn as u } from "./utils/twUtils.js";
5
5
  import { c as y } from "./index-D29mdTf5.js";
6
6
  import { forwardRef as h } from "react";
7
7
  import { L as f } from "./loader-circle-CdRVlFhN.js";
8
- const w = y(
8
+ const N = y(
9
9
  `
10
10
  !font-sans flex relative items-center justify-center gap-2 whitespace-nowrap transition-colors cursor-pointer rounded-lg border font-semibold focus:outline-none focus:outline-none
11
11
  focus-visible:outline-1 focus-visible:outline-offset-2 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0
@@ -20,12 +20,11 @@ const w = y(
20
20
  outline: `bg-button-outline-bg border-button-outline-border text-button-outline-text hover:bg-button-outline-bg--hover hover:text-button-outline-text--hover focus-visible:outline-button-outline-border
21
21
  disabled:text-button-outline-text--disabled disabled:border-button-outline-border--disabled`,
22
22
  ghost: "bg-button-ghost-bg border-none text-button-ghost-text hover:bg-button-ghost-bg--hover hover:text-button-ghost-text--hover focus-visible:outline-none disabled:text-button-ghost-text--disabled",
23
- card: "bg-button-card-bg border-button-card-border"
23
+ card: "bg-button-card-bg border-button-card-border text-button-card-text !py-1 hover:text-button-card-text--hover"
24
24
  },
25
25
  size: {
26
26
  default: "py-2 px-6 w-fit",
27
- fullWidth: "py-2 px-6 w-full",
28
- card: "py-2 px-3 w-fit"
27
+ fullWidth: "py-2 px-6 w-full"
29
28
  },
30
29
  state: {
31
30
  default: "",
@@ -39,68 +38,34 @@ const w = y(
39
38
  size: "default"
40
39
  }
41
40
  }
42
- ), N = h(
43
- ({
44
- className: l,
45
- dataTestId: g,
46
- disabled: n,
47
- endIcon: b,
48
- errorMessage: d,
49
- label: p,
50
- size: r,
51
- startIcon: a,
52
- state: t,
53
- type: c = "button",
54
- variant: e,
55
- ...x
56
- }, v) => {
57
- const i = {
58
- error: {
59
- primary: "bg-button-danger border-button-danger text-button-primary-text pointer-events-none",
60
- secondary: "bg-button-danger border-button-danger text-button-secondary-text pointer-events-none",
61
- outline: "bg-transparent border-button-danger text-button-danger pointer-events-none",
62
- ghost: "bg-transparent text-button-danger pointer-events-none",
63
- card: "bg-transparent border-button-danger text-button-danger pointer-events-none"
64
- },
65
- loading: {
66
- primary: "bg-button-primary-bg--disabled border-button-primary-border--disabled text-button-primary-text--disabled pointer-events-none",
67
- secondary: "bg-button-secondary-bg--disabled border-button-secondary-border--disabled text-button-secondary-text--disabled pointer-events-none",
68
- outline: "bg-button-outline-bg--disabled border-button-outline-border--disabled text-button-outline-text--disabled pointer-events-none",
69
- ghost: "bg-transparent text-button-ghost-text--disabled pointer-events-none",
70
- card: "bg-button-card-bg--disabled border-button-card-border--disabled text-button-card-text--disabled pointer-events-none"
71
- }
72
- }, m = u(
73
- w({ variant: e, state: t, size: r }),
74
- t === "error" && i.error[e || "primary"],
75
- t === "loading" && i.loading[e || "primary"],
76
- r,
77
- l
78
- );
79
- return /* @__PURE__ */ s("div", { className: u("flex flex-col justify-items-center", r), children: [
80
- /* @__PURE__ */ s(
81
- "button",
82
- {
83
- "aria-disabled": n,
84
- className: m,
85
- "data-state": t,
86
- "data-testid": g || `button-${e}`,
87
- disabled: n,
88
- ref: v,
89
- type: c,
90
- ...x,
91
- children: [
92
- a && /* @__PURE__ */ o("span", { className: "flex pr-2", "aria-hidden": !0, children: a }),
93
- t === "loading" && /* @__PURE__ */ o(f, { className: "ml-2 animate-spin", size: 16 }),
94
- b && t !== "loading" && /* @__PURE__ */ o("span", { className: "flex pl-2", "aria-hidden": !0, children: b }),
95
- p
96
- ]
97
- }
98
- ),
99
- t === "error" && d && /* @__PURE__ */ o("p", { className: "text-danger-100 mt-2 text-xs", role: "alert", "aria-live": "assertive", children: d })
100
- ] });
101
- }
102
- );
103
- N.displayName = "Button";
41
+ ), w = h(({ className: l, dataTestId: g, disabled: n, endIcon: b, errorMessage: d, label: c, size: r, startIcon: a, state: t, type: p = "button", variant: e, ...x }, v) => {
42
+ const i = {
43
+ error: {
44
+ primary: "bg-button-danger border-button-danger text-button-primary-text pointer-events-none",
45
+ secondary: "bg-button-danger border-button-danger text-button-secondary-text pointer-events-none",
46
+ outline: "bg-transparent border-button-danger text-button-danger pointer-events-none",
47
+ ghost: "bg-transparent text-button-danger pointer-events-none",
48
+ card: "bg-transparent border-button-danger text-button-danger pointer-events-none"
49
+ },
50
+ loading: {
51
+ primary: "bg-button-primary-bg--disabled border-button-primary-border--disabled text-button-primary-text--disabled pointer-events-none",
52
+ secondary: "bg-button-secondary-bg--disabled border-button-secondary-border--disabled text-button-secondary-text--disabled pointer-events-none",
53
+ outline: "bg-button-outline-bg--disabled border-button-outline-border--disabled text-button-outline-text--disabled pointer-events-none",
54
+ ghost: "bg-transparent text-button-ghost-text--disabled pointer-events-none",
55
+ card: "bg-button-card-bg--disabled border-button-card-border--disabled text-button-card-text--disabled pointer-events-none"
56
+ }
57
+ }, m = u(N({ variant: e, state: t, size: r }), t === "error" && i.error[e || "primary"], t === "loading" && i.loading[e || "primary"], r, l);
58
+ return /* @__PURE__ */ s("div", { className: u("flex flex-col justify-items-center", r), children: [
59
+ /* @__PURE__ */ s("button", { "aria-disabled": n, className: m, "data-state": t, "data-testid": g || `button-${e}`, disabled: n, ref: v, type: p, ...x, children: [
60
+ a && /* @__PURE__ */ o("span", { className: "flex pr-2", "aria-hidden": !0, children: a }),
61
+ t === "loading" && /* @__PURE__ */ o(f, { className: "ml-2 animate-spin", size: 16 }),
62
+ b && t !== "loading" && /* @__PURE__ */ o("span", { className: "flex pl-2", "aria-hidden": !0, children: b }),
63
+ c
64
+ ] }),
65
+ t === "error" && d && /* @__PURE__ */ o("p", { className: "text-danger-100 mt-2 text-xs", role: "alert", "aria-live": "assertive", children: d })
66
+ ] });
67
+ });
68
+ w.displayName = "Button";
104
69
  export {
105
- N as Button
70
+ w as Button
106
71
  };
@@ -34,16 +34,7 @@ const c = l(
34
34
  size: e,
35
35
  asChild: o = !1,
36
36
  ...a
37
- }) => /* @__PURE__ */ n(
38
- o ? s : "button",
39
- {
40
- "data-slot": "button-group-item",
41
- "data-variant": t,
42
- "data-size": e,
43
- className: r(c({ variant: t, size: e, className: i })),
44
- ...a
45
- }
46
- );
37
+ }) => /* @__PURE__ */ n(o ? s : "button", { "data-slot": "button-group-item", "data-variant": t, "data-size": e, className: r(c({ variant: t, size: e, className: i })), ...a });
47
38
  u.displayName = "ButtonGroupButton";
48
39
  export {
49
40
  u as ButtonGroupButton,
@@ -21,28 +21,10 @@ const g = c(
21
21
  orientation: "horizontal"
22
22
  }
23
23
  }
24
- ), h = ({
25
- className: o,
26
- orientation: t,
27
- variant: r,
28
- size: a,
29
- children: i,
30
- ...l
31
- }) => /* @__PURE__ */ n(
32
- "div",
33
- {
34
- role: "group",
35
- "data-slot": "button-group",
36
- "aria-label": l["aria-label"],
37
- "data-orientation": t,
38
- className: s(g({ orientation: t }), o),
39
- ...l,
40
- children: f.map(i, (e) => v(e) && e.type === u ? b(e, {
41
- variant: e.props.variant ?? r,
42
- size: e.props.size ?? a
43
- }) : e)
44
- }
45
- );
24
+ ), h = ({ className: o, orientation: t, variant: r, size: a, children: i, ...l }) => /* @__PURE__ */ n("div", { role: "group", "data-slot": "button-group", "aria-label": l["aria-label"], "data-orientation": t, className: s(g({ orientation: t }), o), ...l, children: f.map(i, (e) => v(e) && e.type === u ? b(e, {
25
+ variant: e.props.variant ?? r,
26
+ size: e.props.size ?? a
27
+ }) : e) });
46
28
  h.displayName = "ButtonGroup";
47
29
  const u = ({
48
30
  children: o,
@@ -56,29 +38,11 @@ const C = ({
56
38
  className: o,
57
39
  asChild: t = !1,
58
40
  ...r
59
- }) => /* @__PURE__ */ n(
60
- t ? m : "div",
61
- {
62
- "data-slot": "button-group-text",
63
- className: s(
64
- "bg-muted flex items-center gap-2 rounded-md border px-4 text-sm font-medium shadow-xs [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
65
- o
66
- ),
67
- ...r
68
- }
69
- ), x = ({
41
+ }) => /* @__PURE__ */ n(t ? m : "div", { "data-slot": "button-group-text", className: s("bg-muted flex items-center gap-2 rounded-md border px-4 text-sm font-medium shadow-xs [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4", o), ...r }), x = ({
70
42
  className: o,
71
43
  orientation: t = "vertical",
72
44
  ...r
73
- }) => /* @__PURE__ */ n(
74
- p,
75
- {
76
- "data-slot": "button-group-separator",
77
- orientation: t,
78
- className: s("bg-level-three relative !m-0 self-stretch data-[orientation=vertical]:h-auto", o),
79
- ...r
80
- }
81
- );
45
+ }) => /* @__PURE__ */ n(p, { "data-slot": "button-group-separator", orientation: t, className: s("bg-level-three relative !m-0 self-stretch data-[orientation=vertical]:h-auto", o), ...r });
82
46
  x.displayName = "ButtonGroupSeparator";
83
47
  export {
84
48
  h as ButtonGroup,