@clubmed/trident-ui 1.6.0 → 1.6.1-beta.2

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 (472) hide show
  1. package/README.md +3 -2
  2. package/assets/icons/Utilities/LightBulb.svg +3 -0
  3. package/assets/trident-ui.css +1 -1
  4. package/atoms/Heading/Heading.d.ts +1 -6
  5. package/atoms/Heading/Heading.js +2 -11
  6. package/atoms/Heading/Heading.js.map +1 -1
  7. package/atoms/Heading/HeadingGroup.d.ts +1 -7
  8. package/atoms/Heading/HeadingGroup.js +2 -12
  9. package/atoms/Heading/HeadingGroup.js.map +1 -1
  10. package/atoms/Icons/IconsResolver.js +2 -2
  11. package/atoms/Icons/contexts/IconsContext.js +2 -2
  12. package/atoms/Icons/index.d.ts +0 -1
  13. package/atoms/Icons/index.js +8 -9
  14. package/atoms/Icons/index.js.map +1 -1
  15. package/atoms/Image/Image.d.ts +1 -7
  16. package/atoms/Image/Image.js +2 -15
  17. package/atoms/Image/Image.js.map +1 -1
  18. package/atoms/Prose/Prose.d.ts +1 -5
  19. package/atoms/Prose/Prose.js +2 -15
  20. package/atoms/Prose/Prose.js.map +1 -1
  21. package/chunks/ResizeObserver.js +13 -13
  22. package/chunks/ResizeObserver.js.map +1 -1
  23. package/chunks/_commonjsHelpers.js +4 -29
  24. package/chunks/_commonjsHelpers.js.map +1 -1
  25. package/chunks/clsx.js.map +1 -1
  26. package/chunks/plugin.js +4 -4
  27. package/chunks/plugin.js.map +1 -1
  28. package/molecules/Arrows/Arrows.d.ts +1 -16
  29. package/molecules/Arrows/Arrows.js +2 -63
  30. package/molecules/Arrows/Arrows.js.map +1 -1
  31. package/molecules/Arrows.d.ts +1 -1
  32. package/molecules/Arrows.js +1 -1
  33. package/molecules/Avatar.d.ts +1 -8
  34. package/molecules/Avatar.js +2 -47
  35. package/molecules/Avatar.js.map +1 -1
  36. package/molecules/Backdrop.d.ts +1 -23
  37. package/molecules/Backdrop.js +2 -115
  38. package/molecules/Backdrop.js.map +1 -1
  39. package/molecules/Breadcrumb.d.ts +1 -10
  40. package/molecules/Breadcrumb.js +2 -47
  41. package/molecules/Breadcrumb.js.map +1 -1
  42. package/molecules/Breadcrumb.themes.d.ts +1 -8
  43. package/molecules/Breadcrumb.themes.js +2 -12
  44. package/molecules/Breadcrumb.themes.js.map +1 -1
  45. package/molecules/Buttons/ArrowButton.js.map +1 -1
  46. package/molecules/Buttons/Button.d.ts +1 -1
  47. package/molecules/Buttons/Button.js +1 -1
  48. package/molecules/Buttons/Button.js.map +1 -1
  49. package/molecules/Buttons/ButtonAnchor.js +1 -1
  50. package/molecules/Buttons/ButtonAnchor.js.map +1 -1
  51. package/molecules/Buttons/ButtonContent.d.ts +1 -17
  52. package/molecules/Buttons/ButtonContent.js +2 -15
  53. package/molecules/Buttons/ButtonContent.js.map +1 -1
  54. package/molecules/Buttons/FakeButton.d.ts +1 -1
  55. package/molecules/Buttons/FakeButton.js +1 -1
  56. package/molecules/Buttons/FakeButton.js.map +1 -1
  57. package/molecules/Buttons/v2/Button.d.ts +1 -2288
  58. package/molecules/Buttons/v2/Button.js +3 -47
  59. package/molecules/Buttons/v2/Button.js.map +1 -1
  60. package/molecules/Buttons/v2/Button.type.d.ts +1 -57
  61. package/molecules/Buttons/v2/Button.type.js +6 -42
  62. package/molecules/Buttons/v2/Button.type.js.map +1 -1
  63. package/molecules/Card.d.ts +1 -1
  64. package/molecules/Card.js +1 -1
  65. package/molecules/Cards/Card.js +2 -2
  66. package/molecules/Cards/CardAspectRatios.d.ts +1 -6
  67. package/molecules/Cards/CardAspectRatios.js +2 -7
  68. package/molecules/Cards/CardAspectRatios.js.map +1 -1
  69. package/molecules/Cards/CardBackground.d.ts +1 -4
  70. package/molecules/Cards/CardBackground.js +2 -27
  71. package/molecules/Cards/CardBackground.js.map +1 -1
  72. package/molecules/Cards/CardBackgroundContext.d.ts +1 -6
  73. package/molecules/Cards/CardBackgroundContext.js +3 -7
  74. package/molecules/Cards/CardBackgroundContext.js.map +1 -1
  75. package/molecules/Cards/CardClickable.d.ts +1 -6
  76. package/molecules/Cards/CardClickable.js +2 -34
  77. package/molecules/Cards/CardClickable.js.map +1 -1
  78. package/molecules/Cards/ExpandableCard.d.ts +1 -14
  79. package/molecules/Cards/ExpandableCard.js +2 -77
  80. package/molecules/Cards/ExpandableCard.js.map +1 -1
  81. package/molecules/Cards/v2/Card.d.ts +1 -15
  82. package/molecules/Cards/v2/Card.js +2 -31
  83. package/molecules/Cards/v2/Card.js.map +1 -1
  84. package/molecules/Chip.d.ts +1 -9
  85. package/molecules/Chip.js +2 -28
  86. package/molecules/Chip.js.map +1 -1
  87. package/molecules/Chip.themes.d.ts +1 -12
  88. package/molecules/Chip.themes.js +3 -21
  89. package/molecules/Chip.themes.js.map +1 -1
  90. package/molecules/Clickable/Clickable.d.ts +1 -0
  91. package/molecules/Clickable/Clickable.js +5 -0
  92. package/molecules/Clickable/Clickable.js.map +1 -0
  93. package/molecules/ElasticHeight.d.ts +1 -8
  94. package/molecules/ElasticHeight.js +2 -33
  95. package/molecules/ElasticHeight.js.map +1 -1
  96. package/molecules/Forms/Checkboxes/Checkbox.d.ts +1 -6
  97. package/molecules/Forms/Checkboxes/Checkbox.js +2 -97
  98. package/molecules/Forms/Checkboxes/Checkbox.js.map +1 -1
  99. package/molecules/Forms/Checkboxes/Checkboxes.d.ts +1 -5
  100. package/molecules/Forms/Checkboxes/Checkboxes.js +2 -46
  101. package/molecules/Forms/Checkboxes/Checkboxes.js.map +1 -1
  102. package/molecules/Forms/Checkboxes/index.d.ts +2 -2
  103. package/molecules/Forms/Checkboxes/index.js +2 -2
  104. package/molecules/Forms/DateField.d.ts +1 -24
  105. package/molecules/Forms/DateField.js +2 -185
  106. package/molecules/Forms/DateField.js.map +1 -1
  107. package/molecules/Forms/Filter.d.ts +1 -9
  108. package/molecules/Forms/Filter.js +2 -65
  109. package/molecules/Forms/Filter.js.map +1 -1
  110. package/molecules/Forms/FormControl.d.ts +1 -14
  111. package/molecules/Forms/FormControl.js +2 -51
  112. package/molecules/Forms/FormControl.js.map +1 -1
  113. package/molecules/Forms/FormControlError.d.ts +1 -2
  114. package/molecules/Forms/FormControlError.js +2 -23
  115. package/molecules/Forms/FormControlError.js.map +1 -1
  116. package/molecules/Forms/FormLabel.d.ts +1 -8
  117. package/molecules/Forms/FormLabel.js +2 -34
  118. package/molecules/Forms/FormLabel.js.map +1 -1
  119. package/molecules/Forms/NumberField.d.ts +1 -320
  120. package/molecules/Forms/NumberField.js +3 -126
  121. package/molecules/Forms/NumberField.js.map +1 -1
  122. package/molecules/Forms/Password/Password.d.ts +1 -7
  123. package/molecules/Forms/Password/Password.js +2 -112
  124. package/molecules/Forms/Password/Password.js.map +1 -1
  125. package/molecules/Forms/Password/ValidationMessage.d.ts +1 -6
  126. package/molecules/Forms/Password/ValidationMessage.js +2 -25
  127. package/molecules/Forms/Password/ValidationMessage.js.map +1 -1
  128. package/molecules/Forms/Password/index.d.ts +2 -2
  129. package/molecules/Forms/Password/index.js +2 -2
  130. package/molecules/Forms/Radios/Radio.d.ts +1 -17
  131. package/molecules/Forms/Radios/Radio.js +2 -60
  132. package/molecules/Forms/Radios/Radio.js.map +1 -1
  133. package/molecules/Forms/Radios/RadioGroup.d.ts +1 -5
  134. package/molecules/Forms/Radios/RadioGroup.js +2 -73
  135. package/molecules/Forms/Radios/RadioGroup.js.map +1 -1
  136. package/molecules/Forms/Radios/index.d.ts +2 -2
  137. package/molecules/Forms/Radios/index.js +4 -4
  138. package/molecules/Forms/Range.d.ts +1 -40
  139. package/molecules/Forms/Range.js +2 -230
  140. package/molecules/Forms/Range.js.map +1 -1
  141. package/molecules/Forms/Select.d.ts +1 -10
  142. package/molecules/Forms/Select.js +2 -101
  143. package/molecules/Forms/Select.js.map +1 -1
  144. package/molecules/Forms/Switch.d.ts +1 -5
  145. package/molecules/Forms/Switch.js +2 -60
  146. package/molecules/Forms/Switch.js.map +1 -1
  147. package/molecules/Forms/TextField.d.ts +1 -12
  148. package/molecules/Forms/TextField.js +2 -95
  149. package/molecules/Forms/TextField.js.map +1 -1
  150. package/molecules/HamburgerIcon.d.ts +1 -6
  151. package/molecules/HamburgerIcon.js +2 -40
  152. package/molecules/HamburgerIcon.js.map +1 -1
  153. package/molecules/Link.d.ts +1 -35
  154. package/molecules/Link.js +2 -53
  155. package/molecules/Link.js.map +1 -1
  156. package/molecules/Loader.d.ts +1 -7
  157. package/molecules/Loader.js +2 -63
  158. package/molecules/Loader.js.map +1 -1
  159. package/molecules/Pagination.d.ts +1 -38
  160. package/molecules/Pagination.helper.d.ts +1 -48
  161. package/molecules/Pagination.helper.js +5 -27
  162. package/molecules/Pagination.helper.js.map +1 -1
  163. package/molecules/Pagination.js +2 -151
  164. package/molecules/Pagination.js.map +1 -1
  165. package/molecules/Popin.d.ts +1 -22
  166. package/molecules/Popin.js +2 -58
  167. package/molecules/Popin.js.map +1 -1
  168. package/molecules/Portal/Portal.d.ts +1 -11
  169. package/molecules/Portal/Portal.js +2 -28
  170. package/molecules/Portal/Portal.js.map +1 -1
  171. package/molecules/Spinner.d.ts +1 -9
  172. package/molecules/Spinner.js +2 -19
  173. package/molecules/Spinner.js.map +1 -1
  174. package/molecules/Tabs/Tab.d.ts +1 -31
  175. package/molecules/Tabs/Tab.js +2 -107
  176. package/molecules/Tabs/Tab.js.map +1 -1
  177. package/molecules/Tabs/TabList.d.ts +1 -10
  178. package/molecules/Tabs/TabList.js +2 -51
  179. package/molecules/Tabs/TabList.js.map +1 -1
  180. package/molecules/Tabs/TabPanel.d.ts +1 -17
  181. package/molecules/Tabs/TabPanel.js +2 -40
  182. package/molecules/Tabs/TabPanel.js.map +1 -1
  183. package/molecules/Tabs/Tabs.d.ts +1 -12
  184. package/molecules/Tabs/Tabs.js +2 -17
  185. package/molecules/Tabs/Tabs.js.map +1 -1
  186. package/molecules/Tabs/TabsBody.d.ts +0 -6
  187. package/molecules/Tabs/TabsBody.js +1 -6
  188. package/molecules/Tabs/TabsBody.js.map +1 -1
  189. package/molecules/Tabs/TabsHeader.js +1 -1
  190. package/molecules/Tabs/TabsHeading.js +1 -1
  191. package/molecules/Tabs/TabsPanel.js +1 -1
  192. package/molecules/Tabs/context/TabControl.d.ts +1 -52
  193. package/molecules/Tabs/context/TabControl.js +3 -87
  194. package/molecules/Tabs/context/TabControl.js.map +1 -1
  195. package/molecules/Tabs/hooks/tabControl.d.ts +1 -44
  196. package/molecules/Tabs/hooks/tabControl.js +7 -31
  197. package/molecules/Tabs/hooks/tabControl.js.map +1 -1
  198. package/molecules/Tabs/index.d.ts +7 -7
  199. package/molecules/Tabs/index.js +13 -14
  200. package/molecules/Tabs/theme.d.ts +1 -10
  201. package/molecules/Tabs/theme.js +1 -20
  202. package/molecules/Tabs/theme.js.map +1 -1
  203. package/molecules/Tag.d.ts +1 -45
  204. package/molecules/Tag.js +2 -76
  205. package/molecules/Tag.js.map +1 -1
  206. package/package.json +30 -93
  207. package/tailwind/tailwind.preset.js +232 -232
  208. package/tailwind/tailwind.preset.js.map +1 -1
  209. package/ui/Avatar.d.ts +8 -0
  210. package/ui/Avatar.js +50 -0
  211. package/ui/Avatar.js.map +1 -0
  212. package/ui/Backdrop.d.ts +23 -0
  213. package/ui/Backdrop.js +118 -0
  214. package/ui/Backdrop.js.map +1 -0
  215. package/ui/Breadcrumb.d.ts +10 -0
  216. package/ui/Breadcrumb.js +50 -0
  217. package/ui/Breadcrumb.js.map +1 -0
  218. package/ui/Breadcrumb.themes.d.ts +8 -0
  219. package/ui/Breadcrumb.themes.js +15 -0
  220. package/ui/Breadcrumb.themes.js.map +1 -0
  221. package/ui/Chip.d.ts +9 -0
  222. package/ui/Chip.js +31 -0
  223. package/ui/Chip.js.map +1 -0
  224. package/ui/Chip.themes.d.ts +12 -0
  225. package/ui/Chip.themes.js +24 -0
  226. package/ui/Chip.themes.js.map +1 -0
  227. package/{atoms/Clickable → ui}/Clickable.js +1 -1
  228. package/ui/Clickable.js.map +1 -0
  229. package/ui/ElasticHeight.d.ts +8 -0
  230. package/ui/ElasticHeight.js +36 -0
  231. package/ui/ElasticHeight.js.map +1 -0
  232. package/ui/HamburgerIcon.d.ts +6 -0
  233. package/ui/HamburgerIcon.js +43 -0
  234. package/ui/HamburgerIcon.js.map +1 -0
  235. package/ui/Image.d.ts +7 -0
  236. package/ui/Image.js +18 -0
  237. package/ui/Image.js.map +1 -0
  238. package/ui/Link.d.ts +35 -0
  239. package/ui/Link.js +56 -0
  240. package/ui/Link.js.map +1 -0
  241. package/ui/Loader.d.ts +7 -0
  242. package/ui/Loader.js +66 -0
  243. package/ui/Loader.js.map +1 -0
  244. package/ui/Pagination.d.ts +38 -0
  245. package/ui/Pagination.helper.d.ts +48 -0
  246. package/ui/Pagination.helper.js +30 -0
  247. package/ui/Pagination.helper.js.map +1 -0
  248. package/ui/Pagination.js +154 -0
  249. package/ui/Pagination.js.map +1 -0
  250. package/ui/Popin.d.ts +22 -0
  251. package/ui/Popin.js +61 -0
  252. package/ui/Popin.js.map +1 -0
  253. package/ui/Portal.d.ts +11 -0
  254. package/ui/Portal.js +31 -0
  255. package/ui/Portal.js.map +1 -0
  256. package/ui/Prose.d.ts +5 -0
  257. package/ui/Prose.js +18 -0
  258. package/ui/Prose.js.map +1 -0
  259. package/ui/Spinner.d.ts +9 -0
  260. package/ui/Spinner.js +22 -0
  261. package/ui/Spinner.js.map +1 -0
  262. package/ui/Tag.d.ts +45 -0
  263. package/ui/Tag.js +79 -0
  264. package/ui/Tag.js.map +1 -0
  265. package/ui/arrows/Arrows.d.ts +16 -0
  266. package/ui/arrows/Arrows.js +66 -0
  267. package/ui/arrows/Arrows.js.map +1 -0
  268. package/ui/buttons/ArrowButton.d.ts +6 -0
  269. package/ui/buttons/ArrowButton.js +7 -0
  270. package/ui/buttons/ArrowButton.js.map +1 -0
  271. package/ui/buttons/Button.d.ts +2392 -0
  272. package/ui/buttons/Button.js +50 -0
  273. package/ui/buttons/Button.js.map +1 -0
  274. package/ui/buttons/Button.type.d.ts +57 -0
  275. package/ui/buttons/Button.type.js +45 -0
  276. package/ui/buttons/Button.type.js.map +1 -0
  277. package/ui/buttons/ButtonContent.d.ts +17 -0
  278. package/ui/buttons/ButtonContent.js +18 -0
  279. package/ui/buttons/ButtonContent.js.map +1 -0
  280. package/ui/cards/Card.d.ts +15 -0
  281. package/ui/cards/Card.js +34 -0
  282. package/ui/cards/Card.js.map +1 -0
  283. package/ui/cards/CardAspectRatios.d.ts +6 -0
  284. package/ui/cards/CardAspectRatios.js +10 -0
  285. package/ui/cards/CardAspectRatios.js.map +1 -0
  286. package/ui/cards/CardBackground.d.ts +4 -0
  287. package/ui/cards/CardBackground.js +30 -0
  288. package/ui/cards/CardBackground.js.map +1 -0
  289. package/ui/cards/CardBackgroundContext.d.ts +6 -0
  290. package/ui/cards/CardBackgroundContext.js +10 -0
  291. package/ui/cards/CardBackgroundContext.js.map +1 -0
  292. package/ui/cards/CardClickable.d.ts +6 -0
  293. package/ui/cards/CardClickable.js +37 -0
  294. package/ui/cards/CardClickable.js.map +1 -0
  295. package/ui/cards/ExpandableCard.d.ts +14 -0
  296. package/ui/cards/ExpandableCard.js +80 -0
  297. package/ui/cards/ExpandableCard.js.map +1 -0
  298. package/{contexts → ui/contexts}/Device.d.ts +1 -1
  299. package/{contexts → ui/contexts}/Device.js +1 -1
  300. package/{contexts → ui/contexts}/TridentUIConfig.js +68 -68
  301. package/ui/contexts/TridentUIConfig.js.map +1 -0
  302. package/ui/contexts/devices/Device.js.map +1 -0
  303. package/{contexts/Devices → ui/contexts/devices}/hooks/useQueries.d.ts +8 -1
  304. package/ui/contexts/devices/hooks/useQueries.js.map +1 -0
  305. package/ui/contexts/devices/reducers/reducer.js.map +1 -0
  306. package/ui/forms/DateField.d.ts +24 -0
  307. package/ui/forms/DateField.js +162 -0
  308. package/ui/forms/DateField.js.map +1 -0
  309. package/ui/forms/Filter.d.ts +9 -0
  310. package/ui/forms/Filter.js +68 -0
  311. package/ui/forms/Filter.js.map +1 -0
  312. package/ui/forms/FormControl.d.ts +14 -0
  313. package/ui/forms/FormControl.js +54 -0
  314. package/ui/forms/FormControl.js.map +1 -0
  315. package/ui/forms/FormControlError.d.ts +2 -0
  316. package/ui/forms/FormControlError.js +26 -0
  317. package/ui/forms/FormControlError.js.map +1 -0
  318. package/ui/forms/FormLabel.d.ts +8 -0
  319. package/ui/forms/FormLabel.js +37 -0
  320. package/ui/forms/FormLabel.js.map +1 -0
  321. package/ui/forms/NumberField.d.ts +332 -0
  322. package/ui/forms/NumberField.js +129 -0
  323. package/ui/forms/NumberField.js.map +1 -0
  324. package/ui/forms/Range.d.ts +40 -0
  325. package/ui/forms/Range.js +161 -0
  326. package/ui/forms/Range.js.map +1 -0
  327. package/ui/forms/Select.d.ts +10 -0
  328. package/ui/forms/Select.js +104 -0
  329. package/ui/forms/Select.js.map +1 -0
  330. package/ui/forms/Switch.d.ts +5 -0
  331. package/ui/forms/Switch.js +63 -0
  332. package/ui/forms/Switch.js.map +1 -0
  333. package/ui/forms/TextField.d.ts +12 -0
  334. package/ui/forms/TextField.js +98 -0
  335. package/ui/forms/TextField.js.map +1 -0
  336. package/ui/forms/checkboxes/Checkbox.d.ts +6 -0
  337. package/ui/forms/checkboxes/Checkbox.js +100 -0
  338. package/ui/forms/checkboxes/Checkbox.js.map +1 -0
  339. package/ui/forms/checkboxes/Checkboxes.d.ts +5 -0
  340. package/ui/forms/checkboxes/Checkboxes.js +49 -0
  341. package/ui/forms/checkboxes/Checkboxes.js.map +1 -0
  342. package/ui/forms/checkboxes/index.d.ts +2 -0
  343. package/ui/forms/checkboxes/index.js +7 -0
  344. package/ui/forms/checkboxes/index.js.map +1 -0
  345. package/ui/forms/password/Password.d.ts +7 -0
  346. package/ui/forms/password/Password.js +115 -0
  347. package/ui/forms/password/Password.js.map +1 -0
  348. package/ui/forms/password/ValidationMessage.d.ts +6 -0
  349. package/ui/forms/password/ValidationMessage.js +28 -0
  350. package/ui/forms/password/ValidationMessage.js.map +1 -0
  351. package/ui/forms/password/index.d.ts +2 -0
  352. package/ui/forms/password/index.js +7 -0
  353. package/ui/forms/password/index.js.map +1 -0
  354. package/ui/forms/radios/Radio.d.ts +17 -0
  355. package/ui/forms/radios/Radio.js +63 -0
  356. package/ui/forms/radios/Radio.js.map +1 -0
  357. package/ui/forms/radios/RadioGroup.d.ts +5 -0
  358. package/ui/forms/radios/RadioGroup.js +76 -0
  359. package/ui/forms/radios/RadioGroup.js.map +1 -0
  360. package/ui/forms/radios/index.d.ts +2 -0
  361. package/ui/forms/radios/index.js +7 -0
  362. package/ui/forms/radios/index.js.map +1 -0
  363. package/ui/heading/Heading.d.ts +6 -0
  364. package/ui/heading/Heading.js +14 -0
  365. package/ui/heading/Heading.js.map +1 -0
  366. package/ui/heading/HeadingGroup.d.ts +7 -0
  367. package/ui/heading/HeadingGroup.js +15 -0
  368. package/ui/heading/HeadingGroup.js.map +1 -0
  369. package/ui/helpers/colors/colors.js.map +1 -0
  370. package/ui/helpers/twMerge.js.map +1 -0
  371. package/ui/hooks/keyboard.constants.js.map +1 -0
  372. package/{hooks → ui/hooks}/useInternalStatus.d.ts +1 -1
  373. package/ui/hooks/useInternalStatus.js.map +1 -0
  374. package/ui/hooks/useKeyboardControls.js.map +1 -0
  375. package/{hooks → ui/hooks}/useResizeObserver.js +1 -1
  376. package/ui/hooks/useResizeObserver.js.map +1 -0
  377. package/{hooks → ui/hooks}/useSafeBoop.js +674 -708
  378. package/ui/hooks/useSafeBoop.js.map +1 -0
  379. package/ui/hooks/useSlots.js.map +1 -0
  380. package/ui/hooks/useValue.js.map +1 -0
  381. package/ui/tabs/Tab.d.ts +31 -0
  382. package/ui/tabs/Tab.js +110 -0
  383. package/ui/tabs/Tab.js.map +1 -0
  384. package/ui/tabs/TabList.d.ts +10 -0
  385. package/ui/tabs/TabList.js +54 -0
  386. package/ui/tabs/TabList.js.map +1 -0
  387. package/ui/tabs/TabPanel.d.ts +17 -0
  388. package/ui/tabs/TabPanel.js +43 -0
  389. package/ui/tabs/TabPanel.js.map +1 -0
  390. package/ui/tabs/Tabs.d.ts +12 -0
  391. package/ui/tabs/Tabs.js +20 -0
  392. package/ui/tabs/Tabs.js.map +1 -0
  393. package/ui/tabs/TabsBody.d.ts +6 -0
  394. package/ui/tabs/TabsBody.js +7 -0
  395. package/ui/tabs/TabsBody.js.map +1 -0
  396. package/ui/tabs/context/TabControl.d.ts +52 -0
  397. package/ui/tabs/context/TabControl.js +90 -0
  398. package/ui/tabs/context/TabControl.js.map +1 -0
  399. package/ui/tabs/hooks/tabControl.d.ts +44 -0
  400. package/ui/tabs/hooks/tabControl.js +34 -0
  401. package/ui/tabs/hooks/tabControl.js.map +1 -0
  402. package/ui/tabs/index.d.ts +5 -0
  403. package/ui/tabs/index.js +13 -0
  404. package/ui/tabs/index.js.map +1 -0
  405. package/ui/tabs/theme.d.ts +10 -0
  406. package/ui/tabs/theme.js +24 -0
  407. package/ui/tabs/theme.js.map +1 -0
  408. package/ui/types/Devices.js.map +1 -0
  409. package/CHANGELOG.md +0 -1949
  410. package/atoms/Clickable/Clickable.js.map +0 -1
  411. package/atoms/Icons/Iconics.d.ts +0 -9
  412. package/atoms/Icons/Iconics.js +0 -2
  413. package/atoms/Icons/Iconics.js.map +0 -1
  414. package/contexts/Devices/Device.js.map +0 -1
  415. package/contexts/Devices/hooks/useQueries.js.map +0 -1
  416. package/contexts/Devices/reducers/reducer.js.map +0 -1
  417. package/contexts/TridentUIConfig.js.map +0 -1
  418. package/helpers/colors/colors.js.map +0 -1
  419. package/helpers/twMerge.js.map +0 -1
  420. package/hooks/keyboard.constants.js.map +0 -1
  421. package/hooks/useInternalStatus.js.map +0 -1
  422. package/hooks/useKeyboardControls.js.map +0 -1
  423. package/hooks/useResizeObserver.js.map +0 -1
  424. package/hooks/useSafeBoop.js.map +0 -1
  425. package/hooks/useSlots.js.map +0 -1
  426. package/hooks/useValue.js.map +0 -1
  427. package/types/Devices.js.map +0 -1
  428. /package/{atoms/Clickable → ui}/Clickable.d.ts +0 -0
  429. /package/{molecules/Arrows → ui/arrows}/ArrowsLabels.d.js +0 -0
  430. /package/{molecules/Arrows → ui/arrows}/ArrowsLabels.d.js.map +0 -0
  431. /package/{contexts → ui/contexts}/Device.js.map +0 -0
  432. /package/{contexts → ui/contexts}/TridentUIConfig.d.ts +0 -0
  433. /package/{contexts/Devices → ui/contexts/devices}/Device.d.ts +0 -0
  434. /package/{contexts/Devices → ui/contexts/devices}/Device.js +0 -0
  435. /package/{contexts/Devices → ui/contexts/devices}/hooks/useQueries.js +0 -0
  436. /package/{contexts/Devices → ui/contexts/devices}/reducers/reducer.d.ts +0 -0
  437. /package/{contexts/Devices → ui/contexts/devices}/reducers/reducer.js +0 -0
  438. /package/{helpers → ui/helpers}/colors/colors.d.ts +0 -0
  439. /package/{helpers → ui/helpers}/colors/colors.js +0 -0
  440. /package/{helpers → ui/helpers}/twMerge.d.ts +0 -0
  441. /package/{helpers → ui/helpers}/twMerge.js +0 -0
  442. /package/{hooks → ui/hooks}/keyboard.constants.d.ts +0 -0
  443. /package/{hooks → ui/hooks}/keyboard.constants.js +0 -0
  444. /package/{hooks → ui/hooks}/useInternalStatus.js +0 -0
  445. /package/{hooks → ui/hooks}/useKeyboardControls.d.ts +0 -0
  446. /package/{hooks → ui/hooks}/useKeyboardControls.js +0 -0
  447. /package/{hooks → ui/hooks}/useResizeObserver.d.ts +0 -0
  448. /package/{hooks → ui/hooks}/useSafeBoop.d.ts +0 -0
  449. /package/{hooks → ui/hooks}/useSlots.d.ts +0 -0
  450. /package/{hooks → ui/hooks}/useSlots.js +0 -0
  451. /package/{hooks → ui/hooks}/useValue.d.ts +0 -0
  452. /package/{hooks → ui/hooks}/useValue.js +0 -0
  453. /package/{types → ui/types}/Colors.d.ts +0 -0
  454. /package/{types → ui/types}/Colors.js +0 -0
  455. /package/{types → ui/types}/Colors.js.map +0 -0
  456. /package/{types → ui/types}/Devices.d.ts +0 -0
  457. /package/{types → ui/types}/Devices.js +0 -0
  458. /package/{types → ui/types}/Direction.d.ts +0 -0
  459. /package/{types → ui/types}/Direction.js +0 -0
  460. /package/{types → ui/types}/Direction.js.map +0 -0
  461. /package/{types → ui/types}/LiteralUnion.d.ts +0 -0
  462. /package/{types → ui/types}/LiteralUnion.js +0 -0
  463. /package/{types → ui/types}/LiteralUnion.js.map +0 -0
  464. /package/{types → ui/types}/ScrollerLabels.d.ts +0 -0
  465. /package/{types → ui/types}/ScrollerLabels.js +0 -0
  466. /package/{types → ui/types}/ScrollerLabels.js.map +0 -0
  467. /package/{types → ui/types}/Theme.d.ts +0 -0
  468. /package/{types → ui/types}/Theme.js +0 -0
  469. /package/{types → ui/types}/Theme.js.map +0 -0
  470. /package/{types → ui/types}/index.d.ts +0 -0
  471. /package/{types → ui/types}/index.js +0 -0
  472. /package/{types → ui/types}/index.js.map +0 -0
@@ -1,50 +1,6 @@
1
- "use client";
2
- import { jsx as n } from "react/jsx-runtime";
3
- import { c as l } from "../../../chunks/clsx.js";
4
- import { getButtonClasses as B } from "./Button.type.js";
5
- import { ButtonContent as c } from "../ButtonContent.js";
6
- function p({ component: t, disabled: r, ...a }) {
7
- return t === "a" || "href" in a || typeof t == "object" ? {
8
- attrs: {
9
- "data-name": "ButtonAnchor",
10
- "aria-disabled": r ? "true" : void 0,
11
- ...a
12
- },
13
- Cmp: "a"
14
- } : t === "span" || t === "div" ? {
15
- attrs: {
16
- "data-name": "FakeButton",
17
- "aria-disabled": r ? "true" : void 0,
18
- ...a
19
- },
20
- Cmp: "span"
21
- } : {
22
- attrs: {
23
- "data-name": "Button",
24
- type: "button",
25
- disabled: r,
26
- ...a
27
- },
28
- Cmp: "button"
29
- };
30
- }
31
- const C = ({
32
- className: t,
33
- children: r,
34
- color: a = "saffron",
35
- icon: e,
36
- iconWidth: o,
37
- size: u = "medium",
38
- theme: i = "solid",
39
- variant: s = "pill",
40
- ...m
41
- }) => {
42
- const { Cmp: f, attrs: d } = p(m);
43
- return /* @__PURE__ */ n(f, { ...d, className: l(B({ color: a, size: u, theme: i, variant: s }), t), children: /* @__PURE__ */ n(c, { icon: e, iconWidth: o, children: r }) });
44
- };
45
- C.displayName = "Button";
1
+ import { Button as u, useButton as e } from "../../../ui/buttons/Button.js";
46
2
  export {
47
- C as Button,
48
- p as useButton
3
+ u as Button,
4
+ e as useButton
49
5
  };
50
6
  //# sourceMappingURL=Button.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Button.js","sources":["../../../../lib/molecules/Buttons/v2/Button.tsx"],"sourcesContent":["'use client';\nimport clsx from 'clsx';\nimport type {\n ComponentPropsWithoutRef,\n FunctionComponent,\n PropsWithChildren,\n ReactElement,\n ReactPortal,\n} from 'react';\n\nimport { type ButtonProps as Btn, getButtonClasses } from './Button.type';\nimport { ButtonContent } from '../ButtonContent';\n\nimport './Button.css';\n\nexport interface ButtonProps extends Btn, Omit<ComponentPropsWithoutRef<'button'>, 'color'> {\n component?: 'button';\n}\n\nexport interface ButtonAnchorProps extends Btn, Omit<ComponentPropsWithoutRef<'a'>, 'color'> {\n component: 'a';\n disabled?: boolean;\n}\n\nexport interface FakeButtonProps extends Btn, Omit<ComponentPropsWithoutRef<'span'>, 'color'> {\n component: 'span' | 'div';\n disabled?: boolean;\n}\n// For Button with React Router Link or similar components\nexport interface ReactButtonProps\n extends Btn,\n Omit<ComponentPropsWithoutRef<'a'>, 'href' | 'color'> {\n component: ReactElement | ReactPortal;\n disabled?: boolean;\n}\n\ntype AnyButtonProps = ButtonProps | ButtonAnchorProps | FakeButtonProps | ReactButtonProps;\n\nexport function useButton({ component, disabled, ...props }: AnyButtonProps) {\n if (component === 'a' || 'href' in props || typeof component === 'object') {\n return {\n attrs: {\n 'data-name': 'ButtonAnchor',\n 'aria-disabled': disabled ? 'true' : undefined,\n ...props,\n },\n Cmp: 'a' as unknown as FunctionComponent<PropsWithChildren<any>>,\n };\n }\n\n if (component === 'span' || component === 'div') {\n return {\n attrs: {\n 'data-name': 'FakeButton',\n 'aria-disabled': disabled ? 'true' : undefined,\n ...props,\n },\n Cmp: 'span' as unknown as FunctionComponent<PropsWithChildren<any>>,\n };\n }\n\n return {\n attrs: {\n 'data-name': 'Button',\n type: 'button',\n disabled,\n ...props,\n },\n Cmp: 'button' as unknown as FunctionComponent<PropsWithChildren<any>>,\n };\n}\n\n// Main Button component that handles both button and anchor functionality\nexport const Button: FunctionComponent<AnyButtonProps> = ({\n className,\n children,\n color = 'saffron',\n icon,\n iconWidth,\n size = 'medium',\n theme = 'solid',\n variant = 'pill',\n ...props\n}) => {\n const { Cmp, attrs } = useButton(props);\n\n return (\n <Cmp {...attrs} className={clsx(getButtonClasses({ color, size, theme, variant }), className)}>\n <ButtonContent icon={icon} iconWidth={iconWidth}>\n {children}\n </ButtonContent>\n </Cmp>\n );\n};\n\nButton.displayName = 'Button';\n"],"names":["useButton","component","disabled","props","Button","className","children","color","icon","iconWidth","size","theme","variant","Cmp","attrs","jsx","clsx","getButtonClasses","ButtonContent"],"mappings":";;;;;AAsCO,SAASA,EAAU,EAAE,WAAAC,GAAW,UAAAC,GAAU,GAAGC,KAAyB;AAC3E,SAAIF,MAAc,OAAO,UAAUE,KAAS,OAAOF,KAAc,WACxD;AAAA,IACL,OAAO;AAAA,MACL,aAAa;AAAA,MACb,iBAAiBC,IAAW,SAAS;AAAA,MACrC,GAAGC;AAAA,IAAA;AAAA,IAEL,KAAK;AAAA,EAAA,IAILF,MAAc,UAAUA,MAAc,QACjC;AAAA,IACL,OAAO;AAAA,MACL,aAAa;AAAA,MACb,iBAAiBC,IAAW,SAAS;AAAA,MACrC,GAAGC;AAAA,IAAA;AAAA,IAEL,KAAK;AAAA,EAAA,IAIF;AAAA,IACL,OAAO;AAAA,MACL,aAAa;AAAA,MACb,MAAM;AAAA,MACN,UAAAD;AAAA,MACA,GAAGC;AAAA,IAAA;AAAA,IAEL,KAAK;AAAA,EAAA;AAET;AAGO,MAAMC,IAA4C,CAAC;AAAA,EACxD,WAAAC;AAAA,EACA,UAAAC;AAAA,EACA,OAAAC,IAAQ;AAAA,EACR,MAAAC;AAAA,EACA,WAAAC;AAAA,EACA,MAAAC,IAAO;AAAA,EACP,OAAAC,IAAQ;AAAA,EACR,SAAAC,IAAU;AAAA,EACV,GAAGT;AACL,MAAM;AACJ,QAAM,EAAE,KAAAU,GAAK,OAAAC,MAAUd,EAAUG,CAAK;AAEtC,SACE,gBAAAY,EAACF,KAAK,GAAGC,GAAO,WAAWE,EAAKC,EAAiB,EAAE,OAAAV,GAAO,MAAAG,GAAM,OAAAC,GAAO,SAAAC,EAAA,CAAS,GAAGP,CAAS,GAC1F,4BAACa,GAAA,EAAc,MAAAV,GAAY,WAAAC,GACxB,UAAAH,EAAA,CACH,GACF;AAEJ;AAEAF,EAAO,cAAc;"}
1
+ {"version":3,"file":"Button.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,57 +1 @@
1
- import { IconicNames, IconicTypes } from '@clubmed/trident-icons';
2
- import { Colors } from '../../../types/Colors';
3
- export interface ButtonProps {
4
- color?: Colors;
5
- /**
6
- * Optional icon name
7
- */
8
- icon?: IconicNames;
9
- /**
10
- * Force the icon type to be svg, font or default
11
- */
12
- iconType?: IconicTypes;
13
- iconWidth?: string;
14
- size?: 'small' | 'medium' | 'large';
15
- theme?: 'outline' | 'solid';
16
- variant?: 'circle' | 'pill';
17
- }
18
- type Params = {
19
- color: ButtonProps['color'];
20
- size: ButtonProps['size'];
21
- theme: ButtonProps['theme'];
22
- variant: ButtonProps['variant'];
23
- };
24
- export declare const BUTTON_COLORS: {
25
- readonly black: "button-black";
26
- readonly green: "button-green";
27
- readonly lavender: "button-lavender";
28
- readonly lightSand: "button-lightSand";
29
- readonly marygold: "button-marygold";
30
- readonly orange: "button-orange";
31
- readonly red: "button-red";
32
- readonly saffron: "button-saffron";
33
- readonly sand: "button-sand";
34
- readonly sienna: "button-sienna";
35
- readonly ultramarine: "button-ultramarine";
36
- readonly verdigris: "button-verdigris";
37
- readonly wave: "button-wave";
38
- readonly white: "button-white";
39
- readonly darkGrey: "button-darkGrey";
40
- readonly lightGrey: "button-lightGrey";
41
- readonly current: "button-current";
42
- };
43
- export declare const BUTTON_THEMES: {
44
- readonly outline: "button-outline";
45
- readonly solid: "button-solid";
46
- };
47
- export declare const BUTTON_VARIANTS: {
48
- readonly circle: "button-circle";
49
- readonly pill: "button-pill";
50
- };
51
- export declare const BUTTON_SIZES: {
52
- readonly small: "button-small";
53
- readonly medium: "button-medium";
54
- readonly large: "button-large";
55
- };
56
- export declare const getButtonClasses: ({ color, size, theme, variant }: Params) => string;
57
- export {};
1
+ export * from '../../../ui/buttons/Button.type';
@@ -1,45 +1,9 @@
1
- import { c as r } from "../../../chunks/clsx.js";
2
- const u = {
3
- black: "button-black",
4
- green: "button-green",
5
- lavender: "button-lavender",
6
- lightSand: "button-lightSand",
7
- marygold: "button-marygold",
8
- orange: "button-orange",
9
- red: "button-red",
10
- saffron: "button-saffron",
11
- sand: "button-sand",
12
- sienna: "button-sienna",
13
- ultramarine: "button-ultramarine",
14
- verdigris: "button-verdigris",
15
- wave: "button-wave",
16
- white: "button-white",
17
- darkGrey: "button-darkGrey",
18
- lightGrey: "button-lightGrey",
19
- current: "button-current"
20
- }, l = (t) => u[t || "saffron"], a = {
21
- outline: "button-outline",
22
- solid: "button-solid"
23
- }, i = (t) => a[t || "solid"], s = {
24
- circle: "button-circle",
25
- pill: "button-pill"
26
- }, b = (t) => s[t || "pill"], d = {
27
- small: "button-small",
28
- medium: "button-medium",
29
- large: "button-large"
30
- }, c = (t) => d[t || "medium"], m = ({ color: t, size: n, theme: o, variant: e }) => r(
31
- "flex",
32
- "button",
33
- i(o),
34
- l(t),
35
- b(e),
36
- c(n)
37
- );
1
+ import { BUTTON_COLORS as B, BUTTON_SIZES as N, BUTTON_THEMES as S, BUTTON_VARIANTS as t, getButtonClasses as U } from "../../../ui/buttons/Button.type.js";
38
2
  export {
39
- u as BUTTON_COLORS,
40
- d as BUTTON_SIZES,
41
- a as BUTTON_THEMES,
42
- s as BUTTON_VARIANTS,
43
- m as getButtonClasses
3
+ B as BUTTON_COLORS,
4
+ N as BUTTON_SIZES,
5
+ S as BUTTON_THEMES,
6
+ t as BUTTON_VARIANTS,
7
+ U as getButtonClasses
44
8
  };
45
9
  //# sourceMappingURL=Button.type.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Button.type.js","sources":["../../../../lib/molecules/Buttons/v2/Button.type.ts"],"sourcesContent":["import clsx from 'clsx';\n\nimport type { IconicNames, IconicTypes } from '@clubmed/trident-icons';\nimport type { Colors } from '@/types/Colors';\n\nexport interface ButtonProps {\n color?: Colors;\n /**\n * Optional icon name\n */\n icon?: IconicNames;\n /**\n * Force the icon type to be svg, font or default\n */\n iconType?: IconicTypes;\n iconWidth?: string;\n size?: 'small' | 'medium' | 'large';\n theme?: 'outline' | 'solid';\n variant?: 'circle' | 'pill';\n}\n\ntype Params = {\n color: ButtonProps['color'];\n size: ButtonProps['size'];\n theme: ButtonProps['theme'];\n variant: ButtonProps['variant'];\n};\n\nexport const BUTTON_COLORS = {\n black: 'button-black',\n green: 'button-green',\n lavender: 'button-lavender',\n lightSand: 'button-lightSand',\n marygold: 'button-marygold',\n orange: 'button-orange',\n red: 'button-red',\n saffron: 'button-saffron',\n sand: 'button-sand',\n sienna: 'button-sienna',\n ultramarine: 'button-ultramarine',\n verdigris: 'button-verdigris',\n wave: 'button-wave',\n white: 'button-white',\n darkGrey: 'button-darkGrey',\n lightGrey: 'button-lightGrey',\n current: 'button-current',\n} as const satisfies Record<Colors, `button-${string}`>;\n\nconst getButtonColor = (color: ButtonProps['color']) => {\n return BUTTON_COLORS[color || 'saffron'];\n};\n\nexport const BUTTON_THEMES = {\n outline: 'button-outline',\n solid: 'button-solid',\n} as const satisfies Record<string, `button-${string}`>;\n\nconst getButtonTheme = (theme: ButtonProps['theme']) => {\n return BUTTON_THEMES[theme || 'solid'];\n};\n\nexport const BUTTON_VARIANTS = {\n circle: 'button-circle',\n pill: 'button-pill',\n} as const satisfies Record<string, `button-${string}`>;\n\nconst getButtonVariant = (variant: ButtonProps['variant']) => {\n return BUTTON_VARIANTS[variant || 'pill'];\n};\n\nexport const BUTTON_SIZES = {\n small: 'button-small',\n medium: 'button-medium',\n large: 'button-large',\n} as const satisfies Record<string, `button-${string}`>;\n\nconst getButtonSize = (size: ButtonProps['size']) => {\n return BUTTON_SIZES[size || 'medium'];\n};\n\nexport const getButtonClasses = ({ color, size, theme, variant }: Params) => {\n /* keep the \"flex\" class outside of \"button-*\" so that it can be overridden in responsive */\n return clsx(\n 'flex',\n 'button',\n getButtonTheme(theme),\n getButtonColor(color),\n getButtonVariant(variant),\n getButtonSize(size),\n );\n};\n"],"names":["BUTTON_COLORS","getButtonColor","color","BUTTON_THEMES","getButtonTheme","theme","BUTTON_VARIANTS","getButtonVariant","variant","BUTTON_SIZES","getButtonSize","size","getButtonClasses","clsx"],"mappings":";AA4BO,MAAMA,IAAgB;AAAA,EAC3B,OAAO;AAAA,EACP,OAAO;AAAA,EACP,UAAU;AAAA,EACV,WAAW;AAAA,EACX,UAAU;AAAA,EACV,QAAQ;AAAA,EACR,KAAK;AAAA,EACL,SAAS;AAAA,EACT,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,aAAa;AAAA,EACb,WAAW;AAAA,EACX,MAAM;AAAA,EACN,OAAO;AAAA,EACP,UAAU;AAAA,EACV,WAAW;AAAA,EACX,SAAS;AACX,GAEMC,IAAiB,CAACC,MACfF,EAAcE,KAAS,SAAS,GAG5BC,IAAgB;AAAA,EAC3B,SAAS;AAAA,EACT,OAAO;AACT,GAEMC,IAAiB,CAACC,MACfF,EAAcE,KAAS,OAAO,GAG1BC,IAAkB;AAAA,EAC7B,QAAQ;AAAA,EACR,MAAM;AACR,GAEMC,IAAmB,CAACC,MACjBF,EAAgBE,KAAW,MAAM,GAG7BC,IAAe;AAAA,EAC1B,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,OAAO;AACT,GAEMC,IAAgB,CAACC,MACdF,EAAaE,KAAQ,QAAQ,GAGzBC,IAAmB,CAAC,EAAE,OAAAV,GAAO,MAAAS,GAAM,OAAAN,GAAO,SAAAG,QAE9CK;AAAA,EACL;AAAA,EACA;AAAA,EACAT,EAAeC,CAAK;AAAA,EACpBJ,EAAeC,CAAK;AAAA,EACpBK,EAAiBC,CAAO;AAAA,EACxBE,EAAcC,CAAI;AAAA;"}
1
+ {"version":3,"file":"Button.type.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1 +1 @@
1
- export * from './Cards/Card';
1
+ export * from '../ui/cards/Card';
package/molecules/Card.js CHANGED
@@ -1,4 +1,4 @@
1
- import { Card as a } from "./Cards/Card.js";
1
+ import { Card as a } from "../ui/cards/Card.js";
2
2
  export {
3
3
  a as Card
4
4
  };
@@ -1,7 +1,7 @@
1
1
  import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
- import { Card as n } from "./v2/Card.js";
2
+ import { Card as n } from "../../ui/cards/Card.js";
3
3
  import { Icon as d } from "@clubmed/trident-icons";
4
- import { Chip as l } from "../Chip.js";
4
+ import { Chip as l } from "../../ui/Chip.js";
5
5
  const h = ({
6
6
  title: a,
7
7
  children: s,
@@ -1,6 +1 @@
1
- export declare const CARD_ASPECT_RATIOS: {
2
- readonly horizontal: "aspect-horizontal";
3
- readonly vertical: "aspect-vertical";
4
- readonly square: "aspect-square";
5
- readonly custom: "";
6
- };
1
+ export * from '../../ui/cards/CardAspectRatios';
@@ -1,10 +1,5 @@
1
- const t = {
2
- horizontal: "aspect-horizontal",
3
- vertical: "aspect-vertical",
4
- square: "aspect-square",
5
- custom: ""
6
- };
1
+ import { CARD_ASPECT_RATIOS as r } from "../../ui/cards/CardAspectRatios.js";
7
2
  export {
8
- t as CARD_ASPECT_RATIOS
3
+ r as CARD_ASPECT_RATIOS
9
4
  };
10
5
  //# sourceMappingURL=CardAspectRatios.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CardAspectRatios.js","sources":["../../../lib/molecules/Cards/CardAspectRatios.ts"],"sourcesContent":["export const CARD_ASPECT_RATIOS = {\n horizontal: 'aspect-horizontal',\n vertical: 'aspect-vertical',\n square: 'aspect-square',\n custom: '',\n} as const;\n"],"names":["CARD_ASPECT_RATIOS"],"mappings":"AAAO,MAAMA,IAAqB;AAAA,EAChC,YAAY;AAAA,EACZ,UAAU;AAAA,EACV,QAAQ;AAAA,EACR,QAAQ;AACV;"}
1
+ {"version":3,"file":"CardAspectRatios.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,4 +1 @@
1
- import { ComponentPropsWithoutRef, FunctionComponent } from 'react';
2
- import { ImageProps } from '../../atoms/Image/Image';
3
- export type CardBackgroundProps = ComponentPropsWithoutRef<'div'> & Partial<ImageProps>;
4
- export declare const CardBackground: FunctionComponent<CardBackgroundProps>;
1
+ export * from '../../ui/cards/CardBackground';
@@ -1,30 +1,5 @@
1
- import { jsxs as c, Fragment as a, jsx as e } from "react/jsx-runtime";
2
- import { c as s } from "../../chunks/clsx.js";
3
- import "react";
4
- import { Image as l } from "../../atoms/Image/Image.js";
5
- import { CardBackgroundContext as m } from "./CardBackgroundContext.js";
6
- const u = ({
7
- children: o,
8
- className: n,
9
- ...r
10
- }) => /* @__PURE__ */ c(a, { children: [
11
- r?.src && /* @__PURE__ */ e(l, { ...r, src: r.src, className: "h-full w-full object-cover" }),
12
- /* @__PURE__ */ e(
13
- "div",
14
- {
15
- ...r,
16
- className: s(
17
- "pointer-events-none absolute inset-0 flex flex-col rounded-16",
18
- {
19
- "bg-gradient-to-b from-transparent via-transparent to-black/40": r?.src
20
- },
21
- n
22
- ),
23
- children: /* @__PURE__ */ e(m.Provider, { value: { hasImage: !!r?.src }, children: o })
24
- }
25
- )
26
- ] });
1
+ import { CardBackground as a } from "../../ui/cards/CardBackground.js";
27
2
  export {
28
- u as CardBackground
3
+ a as CardBackground
29
4
  };
30
5
  //# sourceMappingURL=CardBackground.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CardBackground.js","sources":["../../../lib/molecules/Cards/CardBackground.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport { type ComponentPropsWithoutRef, type FunctionComponent } from 'react';\nimport { Image, type ImageProps } from '@/atoms/Image/Image';\nimport { CardBackgroundContext } from './CardBackgroundContext';\n\nexport type CardBackgroundProps = ComponentPropsWithoutRef<'div'> & Partial<ImageProps>;\n\nexport const CardBackground: FunctionComponent<CardBackgroundProps> = ({\n children,\n className,\n ...attrs\n}) => {\n return (\n <>\n {attrs?.src && <Image {...attrs} src={attrs.src} className=\"h-full w-full object-cover\" />}\n\n <div\n {...attrs}\n className={clsx(\n 'pointer-events-none absolute inset-0 flex flex-col rounded-16',\n {\n 'bg-gradient-to-b from-transparent via-transparent to-black/40': attrs?.src,\n },\n className,\n )}\n >\n <CardBackgroundContext.Provider value={{ hasImage: !!attrs?.src }}>\n {children}\n </CardBackgroundContext.Provider>\n </div>\n </>\n );\n};\n"],"names":["CardBackground","children","className","attrs","jsxs","Fragment","Image","jsx","clsx","CardBackgroundContext"],"mappings":";;;;;AAOO,MAAMA,IAAyD,CAAC;AAAA,EACrE,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,GAAGC;AACL,MAEI,gBAAAC,EAAAC,GAAA,EACG,UAAA;AAAA,EAAAF,GAAO,yBAAQG,GAAA,EAAO,GAAGH,GAAO,KAAKA,EAAM,KAAK,WAAU,6BAAA,CAA6B;AAAA,EAExF,gBAAAI;AAAA,IAAC;AAAA,IAAA;AAAA,MACE,GAAGJ;AAAA,MACJ,WAAWK;AAAA,QACT;AAAA,QACA;AAAA,UACE,iEAAiEL,GAAO;AAAA,QAAA;AAAA,QAE1ED;AAAA,MAAA;AAAA,MAGF,UAAA,gBAAAK,EAACE,EAAsB,UAAtB,EAA+B,OAAO,EAAE,UAAU,CAAC,CAACN,GAAO,IAAA,GACzD,UAAAF,EAAA,CACH;AAAA,IAAA;AAAA,EAAA;AACF,GACF;"}
1
+ {"version":3,"file":"CardBackground.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,6 +1 @@
1
- export declare const CardBackgroundContext: import('react').Context<{
2
- hasImage: boolean;
3
- }>;
4
- export declare function useCardBackground(): {
5
- hasImage: boolean;
6
- };
1
+ export * from '../../ui/cards/CardBackgroundContext';
@@ -1,10 +1,6 @@
1
- import { createContext as t, useContext as e } from "react";
2
- const r = t({ hasImage: !0 });
3
- function n() {
4
- return e(r);
5
- }
1
+ import { CardBackgroundContext as a, useCardBackground as d } from "../../ui/cards/CardBackgroundContext.js";
6
2
  export {
7
- r as CardBackgroundContext,
8
- n as useCardBackground
3
+ a as CardBackgroundContext,
4
+ d as useCardBackground
9
5
  };
10
6
  //# sourceMappingURL=CardBackgroundContext.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CardBackgroundContext.js","sources":["../../../lib/molecules/Cards/CardBackgroundContext.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\nexport const CardBackgroundContext = createContext<{ hasImage: boolean }>({ hasImage: true });\n\nexport function useCardBackground() {\n return useContext(CardBackgroundContext);\n}\n"],"names":["CardBackgroundContext","createContext","useCardBackground","useContext"],"mappings":";AAEO,MAAMA,IAAwBC,EAAqC,EAAE,UAAU,IAAM;AAErF,SAASC,IAAoB;AAClC,SAAOC,EAAWH,CAAqB;AACzC;"}
1
+ {"version":3,"file":"CardBackgroundContext.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,6 +1 @@
1
- import { FunctionComponent, HTMLAttributes } from 'react';
2
- export interface CartTitleProps extends HTMLAttributes<HTMLDivElement | HTMLAnchorElement> {
3
- coverLink?: boolean;
4
- href?: string;
5
- }
6
- export declare const CardClickable: FunctionComponent<CartTitleProps>;
1
+ export * from '../../ui/cards/CardClickable';
@@ -1,37 +1,5 @@
1
- import { jsx as l } from "react/jsx-runtime";
2
- import { c as x } from "../../chunks/clsx.js";
3
- import "react";
4
- import { useCardBackground as i } from "./CardBackgroundContext.js";
5
- const d = ({
6
- children: t,
7
- className: m,
8
- coverLink: a = !1,
9
- href: s,
10
- onClick: r,
11
- ...p
12
- }) => {
13
- const e = !!s, { hasImage: o } = i(), c = e ? "a" : "div", n = e ? { href: s, onClick: r } : {};
14
- return /* @__PURE__ */ l(
15
- c,
16
- {
17
- className: x(
18
- "pointer-events-auto flex w-full gap-x-8 px-12 pb-12 sm:px-24 sm:pb-24",
19
- {
20
- "justify-center text-center": !t,
21
- "h-full items-end": a,
22
- "mt-auto h-auto": !a,
23
- "text-white": o,
24
- "text-black": !o
25
- },
26
- m
27
- ),
28
- ...n,
29
- ...p,
30
- children: t
31
- }
32
- );
33
- };
1
+ import { CardClickable as e } from "../../ui/cards/CardClickable.js";
34
2
  export {
35
- d as CardClickable
3
+ e as CardClickable
36
4
  };
37
5
  //# sourceMappingURL=CardClickable.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CardClickable.js","sources":["../../../lib/molecules/Cards/CardClickable.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport { type FunctionComponent, type HTMLAttributes } from 'react';\nimport { useCardBackground } from '@/molecules/Cards/CardBackgroundContext';\n\nexport interface CartTitleProps extends HTMLAttributes<HTMLDivElement | HTMLAnchorElement> {\n coverLink?: boolean;\n href?: string;\n}\n\nexport const CardClickable: FunctionComponent<CartTitleProps> = ({\n children,\n className,\n coverLink = false,\n href,\n onClick,\n ...attrs\n}) => {\n const hasLink = !!href;\n const { hasImage } = useCardBackground();\n const TagName = hasLink ? 'a' : 'div';\n const tagProps = hasLink ? { href, onClick } : {};\n\n return (\n <TagName\n className={clsx(\n 'pointer-events-auto flex w-full gap-x-8 px-12 pb-12 sm:px-24 sm:pb-24',\n {\n 'justify-center text-center': !children,\n 'h-full items-end': coverLink,\n 'mt-auto h-auto': !coverLink,\n 'text-white': hasImage,\n 'text-black': !hasImage,\n },\n className,\n )}\n {...tagProps}\n {...attrs}\n >\n {children}\n </TagName>\n );\n};\n"],"names":["CardClickable","children","className","coverLink","href","onClick","attrs","hasLink","hasImage","useCardBackground","TagName","tagProps","jsx","clsx"],"mappings":";;;;AASO,MAAMA,IAAmD,CAAC;AAAA,EAC/D,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,MAAAC;AAAA,EACA,SAAAC;AAAA,EACA,GAAGC;AACL,MAAM;AACJ,QAAMC,IAAU,CAAC,CAACH,GACZ,EAAE,UAAAI,EAAA,IAAaC,EAAA,GACfC,IAAUH,IAAU,MAAM,OAC1BI,IAAWJ,IAAU,EAAE,MAAAH,GAAM,SAAAC,EAAA,IAAY,CAAA;AAE/C,SACE,gBAAAO;AAAA,IAACF;AAAA,IAAA;AAAA,MACC,WAAWG;AAAA,QACT;AAAA,QACA;AAAA,UACE,8BAA8B,CAACZ;AAAA,UAC/B,oBAAoBE;AAAA,UACpB,kBAAkB,CAACA;AAAA,UACnB,cAAcK;AAAA,UACd,cAAc,CAACA;AAAA,QAAA;AAAA,QAEjBN;AAAA,MAAA;AAAA,MAED,GAAGS;AAAA,MACH,GAAGL;AAAA,MAEH,UAAAL;AAAA,IAAA;AAAA,EAAA;AAGP;"}
1
+ {"version":3,"file":"CardClickable.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,14 +1 @@
1
- import { ComponentProps, FunctionComponent } from 'react';
2
- import { Heading } from '../../atoms/Heading/Heading';
3
- import { Tag } from '../Tag';
4
- import { CardBackgroundProps } from './CardBackground';
5
- import { CardProps } from './v2/Card';
6
- export interface ExpandableCardProps extends Omit<CardProps<'article'>, 'onClick'> {
7
- hLevel?: ComponentProps<typeof Heading>['level'];
8
- image?: CardBackgroundProps;
9
- onClick?: (isExpanded: boolean) => void;
10
- subtitle?: string | null;
11
- tags?: ComponentProps<typeof Tag>[] | null;
12
- title: string;
13
- }
14
- export declare const ExpandableCard: FunctionComponent<ExpandableCardProps>;
1
+ export * from '../../ui/cards/ExpandableCard';
@@ -1,80 +1,5 @@
1
- "use client";
2
- import { jsxs as r, jsx as a } from "react/jsx-runtime";
3
- import { useState as b, createElement as k } from "react";
4
- import { c as d } from "../../chunks/clsx.js";
5
- import { Clickable as w } from "../../atoms/Clickable/Clickable.js";
6
- import { Tag as v } from "../Tag.js";
7
- import { CardBackground as C } from "./CardBackground.js";
8
- import { ElasticHeight as E } from "../ElasticHeight.js";
9
- import { Card as g } from "./v2/Card.js";
10
- import { HeadingGroup as N } from "../../atoms/Heading/HeadingGroup.js";
11
- import { Button as B } from "../Buttons/v2/Button.js";
12
- const q = ({
13
- children: i,
14
- className: c,
15
- hLevel: s = 3,
16
- image: t,
17
- onClick: m,
18
- subtitle: p,
19
- tags: o,
20
- title: l,
21
- component: f = "article",
22
- ...x
23
- }) => {
24
- const h = !!l, [e, u] = b(!1);
25
- return /* @__PURE__ */ r(
26
- g,
27
- {
28
- component: f,
29
- "data-name": "ExpandableCard",
30
- "data-testid": "expandable-card",
31
- ...x,
32
- className: d({ "border-t-0": t?.src }, c),
33
- "data-open": e,
34
- children: [
35
- /* @__PURE__ */ a(
36
- w,
37
- {
38
- className: "group relative -m-1 block aspect-horizontal overflow-hidden rounded-16 text-start",
39
- "data-testid": "expandable-card-clickable",
40
- onClick: () => {
41
- m?.(!e), u(!e);
42
- },
43
- children: /* @__PURE__ */ r(C, { ...t || {}, children: [
44
- !!o?.length && /* @__PURE__ */ a("div", { className: "flex flex-wrap gap-4 self-start p-20", children: o?.map((n) => /* @__PURE__ */ k(v, { ...n, key: n.label })) }),
45
- /* @__PURE__ */ r(
46
- "div",
47
- {
48
- className: d("mt-auto flex justify-between gap-x-8 p-20", {
49
- "text-white": t?.src
50
- }),
51
- children: [
52
- h && /* @__PURE__ */ a(N, { subtitle: p, level: s, children: l }),
53
- /* @__PURE__ */ a(
54
- B,
55
- {
56
- component: "span",
57
- className: "!transition duration-500",
58
- color: t?.src ? "white" : "black",
59
- icon: "ArrowDefaultDown",
60
- style: { rotate: e ? "-180deg" : "0deg" },
61
- tabIndex: -1,
62
- theme: "outline",
63
- variant: "circle"
64
- }
65
- )
66
- ]
67
- }
68
- )
69
- ] })
70
- }
71
- ),
72
- /* @__PURE__ */ a(E, { isExpanded: e, children: i })
73
- ]
74
- }
75
- );
76
- };
1
+ import { ExpandableCard as d } from "../../ui/cards/ExpandableCard.js";
77
2
  export {
78
- q as ExpandableCard
3
+ d as ExpandableCard
79
4
  };
80
5
  //# sourceMappingURL=ExpandableCard.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExpandableCard.js","sources":["../../../lib/molecules/Cards/ExpandableCard.tsx"],"sourcesContent":["'use client';\n\nimport clsx from 'clsx';\nimport { type ComponentProps, type FunctionComponent, useState } from 'react';\n\nimport { Clickable } from '../../atoms/Clickable/Clickable';\nimport { Heading } from '../../atoms/Heading/Heading';\nimport { Tag } from '../Tag';\nimport { CardBackground, type CardBackgroundProps } from '@/molecules/Cards/CardBackground';\nimport { ElasticHeight } from '@/molecules/ElasticHeight';\nimport { Card, type CardProps } from '@/molecules/Cards/v2/Card';\nimport { HeadingGroup } from '@/atoms/Heading/HeadingGroup';\nimport { Button } from '@/molecules/Buttons/v2/Button';\n\nexport interface ExpandableCardProps extends Omit<CardProps<'article'>, 'onClick'> {\n hLevel?: ComponentProps<typeof Heading>['level'];\n image?: CardBackgroundProps;\n onClick?: (isExpanded: boolean) => void;\n subtitle?: string | null;\n tags?: ComponentProps<typeof Tag>[] | null;\n title: string;\n}\n\nexport const ExpandableCard: FunctionComponent<ExpandableCardProps> = ({\n children,\n className,\n hLevel = 3,\n image,\n onClick,\n subtitle,\n tags,\n title,\n component = 'article',\n ...attrs\n}) => {\n const hasTitle = Boolean(title);\n\n const [isExpanded, setIsExpanded] = useState(false);\n\n return (\n <Card<'article'>\n component={component}\n data-name=\"ExpandableCard\"\n data-testid=\"expandable-card\"\n {...attrs}\n className={clsx({ 'border-t-0': image?.src }, className)}\n data-open={isExpanded}\n >\n <Clickable\n className=\"group relative -m-1 block aspect-horizontal overflow-hidden rounded-16 text-start\"\n data-testid=\"expandable-card-clickable\"\n onClick={() => {\n onClick?.(!isExpanded);\n setIsExpanded(!isExpanded);\n }}\n >\n <CardBackground {...(image || {})}>\n {Boolean(tags?.length) && (\n <div className=\"flex flex-wrap gap-4 self-start p-20\">\n {tags?.map((tag) => <Tag {...tag} key={tag.label} />)}\n </div>\n )}\n <div\n className={clsx('mt-auto flex justify-between gap-x-8 p-20', {\n 'text-white': image?.src,\n })}\n >\n {hasTitle && (\n <HeadingGroup subtitle={subtitle} level={hLevel}>\n {title}\n </HeadingGroup>\n )}\n <Button\n component=\"span\"\n className=\"!transition duration-500\"\n color={image?.src ? 'white' : 'black'}\n icon=\"ArrowDefaultDown\"\n style={{ rotate: isExpanded ? '-180deg' : '0deg' }}\n tabIndex={-1}\n theme=\"outline\"\n variant=\"circle\"\n />\n </div>\n </CardBackground>\n </Clickable>\n <ElasticHeight isExpanded={isExpanded}>{children}</ElasticHeight>\n </Card>\n );\n};\n"],"names":["ExpandableCard","children","className","hLevel","image","onClick","subtitle","tags","title","component","attrs","hasTitle","isExpanded","setIsExpanded","useState","jsxs","Card","clsx","jsx","Clickable","CardBackground","tag","createElement","Tag","HeadingGroup","Button","ElasticHeight"],"mappings":";;;;;;;;;;;AAuBO,MAAMA,IAAyD,CAAC;AAAA,EACrE,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,QAAAC,IAAS;AAAA,EACT,OAAAC;AAAA,EACA,SAAAC;AAAA,EACA,UAAAC;AAAA,EACA,MAAAC;AAAA,EACA,OAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,GAAGC;AACL,MAAM;AACJ,QAAMC,IAAW,EAAQH,GAEnB,CAACI,GAAYC,CAAa,IAAIC,EAAS,EAAK;AAElD,SACE,gBAAAC;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAAP;AAAA,MACA,aAAU;AAAA,MACV,eAAY;AAAA,MACX,GAAGC;AAAA,MACJ,WAAWO,EAAK,EAAE,cAAcb,GAAO,IAAA,GAAOF,CAAS;AAAA,MACvD,aAAWU;AAAA,MAEX,UAAA;AAAA,QAAA,gBAAAM;AAAA,UAACC;AAAA,UAAA;AAAA,YACC,WAAU;AAAA,YACV,eAAY;AAAA,YACZ,SAAS,MAAM;AACb,cAAAd,IAAU,CAACO,CAAU,GACrBC,EAAc,CAACD,CAAU;AAAA,YAC3B;AAAA,YAEA,UAAA,gBAAAG,EAACK,GAAA,EAAgB,GAAIhB,KAAS,CAAA,GAC3B,UAAA;AAAA,cAAA,EAAQG,GAAM,4BACZ,OAAA,EAAI,WAAU,wCACZ,UAAAA,GAAM,IAAI,CAACc,MAAQ,gBAAAC,EAACC,KAAK,GAAGF,GAAK,KAAKA,EAAI,OAAO,CAAE,GACtD;AAAA,cAEF,gBAAAN;AAAA,gBAAC;AAAA,gBAAA;AAAA,kBACC,WAAWE,EAAK,6CAA6C;AAAA,oBAC3D,cAAcb,GAAO;AAAA,kBAAA,CACtB;AAAA,kBAEA,UAAA;AAAA,oBAAAO,KACC,gBAAAO,EAACM,GAAA,EAAa,UAAAlB,GAAoB,OAAOH,GACtC,UAAAK,GACH;AAAA,oBAEF,gBAAAU;AAAA,sBAACO;AAAA,sBAAA;AAAA,wBACC,WAAU;AAAA,wBACV,WAAU;AAAA,wBACV,OAAOrB,GAAO,MAAM,UAAU;AAAA,wBAC9B,MAAK;AAAA,wBACL,OAAO,EAAE,QAAQQ,IAAa,YAAY,OAAA;AAAA,wBAC1C,UAAU;AAAA,wBACV,OAAM;AAAA,wBACN,SAAQ;AAAA,sBAAA;AAAA,oBAAA;AAAA,kBACV;AAAA,gBAAA;AAAA,cAAA;AAAA,YACF,EAAA,CACF;AAAA,UAAA;AAAA,QAAA;AAAA,QAEF,gBAAAM,EAACQ,GAAA,EAAc,YAAAd,GAAyB,UAAAX,EAAA,CAAS;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGvD;"}
1
+ {"version":3,"file":"ExpandableCard.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,15 +1 @@
1
- import { ComponentPropsWithoutRef, ElementType } from 'react';
2
- import { CARD_ASPECT_RATIOS } from '../CardAspectRatios';
3
- type CARD_THEME = 'none' | 'bordered' | 'frame';
4
- export type CardProps<T extends ElementType = 'div'> = {
5
- component?: string;
6
- /**
7
- * By default the card has a border.
8
- * Set to false to remove it.
9
- */
10
- border?: boolean;
11
- format?: keyof typeof CARD_ASPECT_RATIOS;
12
- theme?: CARD_THEME | CARD_THEME[];
13
- } & ComponentPropsWithoutRef<T>;
14
- export declare function Card<T extends ElementType = 'div'>({ children, className, component, format, theme, ...attrs }: CardProps<T>): import("react/jsx-runtime").JSX.Element;
15
- export {};
1
+ export * from '../../../ui/cards/Card';
@@ -1,34 +1,5 @@
1
- import { jsx as s } from "react/jsx-runtime";
2
- import { c as m } from "../../../chunks/clsx.js";
3
- import { CARD_ASPECT_RATIOS as l } from "../CardAspectRatios.js";
4
- function f({
5
- children: o,
6
- className: r,
7
- component: d = "div",
8
- format: i = "custom",
9
- theme: t = "bordered",
10
- ...n
11
- }) {
12
- const c = d, e = [].concat(t).join(" ");
13
- return /* @__PURE__ */ s(
14
- c,
15
- {
16
- ...n,
17
- className: m(
18
- l[i],
19
- "relative isolate rounded-16",
20
- {
21
- "bg-white": !r?.includes("bg-"),
22
- "group overflow-hidden": e.includes("frame"),
23
- "border border-lightGrey": e.includes("bordered")
24
- },
25
- r
26
- ),
27
- children: o
28
- }
29
- );
30
- }
1
+ import { Card as a } from "../../../ui/cards/Card.js";
31
2
  export {
32
- f as Card
3
+ a as Card
33
4
  };
34
5
  //# sourceMappingURL=Card.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Card.js","sources":["../../../../lib/molecules/Cards/v2/Card.tsx"],"sourcesContent":["import type { ComponentPropsWithoutRef, ElementType } from 'react';\nimport cx from 'clsx';\nimport { CARD_ASPECT_RATIOS } from '../CardAspectRatios';\n\ntype CARD_THEME = 'none' | 'bordered' | 'frame';\n\nexport type CardProps<T extends ElementType = 'div'> = {\n component?: string;\n /**\n * By default the card has a border.\n * Set to false to remove it.\n */\n border?: boolean;\n format?: keyof typeof CARD_ASPECT_RATIOS;\n theme?: CARD_THEME | CARD_THEME[];\n} & ComponentPropsWithoutRef<T>;\n\nexport function Card<T extends ElementType = 'div'>({\n children,\n className,\n component = 'div',\n format = 'custom',\n theme = 'bordered',\n ...attrs\n}: CardProps<T>) {\n const Cmp = component as ElementType;\n const resolvedTheme = ([] as CARD_THEME[]).concat(theme).join(' ');\n\n return (\n <Cmp\n {...attrs}\n className={cx(\n CARD_ASPECT_RATIOS[format],\n 'relative isolate rounded-16',\n {\n 'bg-white': !className?.includes('bg-'),\n 'group overflow-hidden': resolvedTheme.includes('frame'),\n 'border border-lightGrey': resolvedTheme.includes('bordered'),\n },\n className,\n )}\n >\n {children}\n </Cmp>\n );\n}\n"],"names":["Card","children","className","component","format","theme","attrs","Cmp","resolvedTheme","jsx","cx","CARD_ASPECT_RATIOS"],"mappings":";;;AAiBO,SAASA,EAAoC;AAAA,EAClD,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,QAAAC,IAAS;AAAA,EACT,OAAAC,IAAQ;AAAA,EACR,GAAGC;AACL,GAAiB;AACf,QAAMC,IAAMJ,GACNK,IAAiB,CAAA,EAAoB,OAAOH,CAAK,EAAE,KAAK,GAAG;AAEjE,SACE,gBAAAI;AAAA,IAACF;AAAA,IAAA;AAAA,MACE,GAAGD;AAAA,MACJ,WAAWI;AAAAA,QACTC,EAAmBP,CAAM;AAAA,QACzB;AAAA,QACA;AAAA,UACE,YAAY,CAACF,GAAW,SAAS,KAAK;AAAA,UACtC,yBAAyBM,EAAc,SAAS,OAAO;AAAA,UACvD,2BAA2BA,EAAc,SAAS,UAAU;AAAA,QAAA;AAAA,QAE9DN;AAAA,MAAA;AAAA,MAGD,UAAAD;AAAA,IAAA;AAAA,EAAA;AAGP;"}
1
+ {"version":3,"file":"Card.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,9 +1 @@
1
- import { ComponentPropsWithoutRef } from 'react';
2
- import { Theme } from './Chip.themes';
3
- import { Colors } from '../types/Colors';
4
- export interface ChipProps extends ComponentPropsWithoutRef<'span'> {
5
- color?: Colors;
6
- size?: string;
7
- theme?: Theme;
8
- }
9
- export declare const Chip: ({ className, color, size, theme, children, ...attrs }: ChipProps) => import("react/jsx-runtime").JSX.Element;
1
+ export * from '../ui/Chip';
package/molecules/Chip.js CHANGED
@@ -1,31 +1,5 @@
1
- import { jsx as a } from "react/jsx-runtime";
2
- import { c as m } from "../chunks/clsx.js";
3
- import { getTheme as c } from "./Chip.themes.js";
4
- const f = ({
5
- className: e,
6
- color: r = "sienna",
7
- size: o = "size-32",
8
- theme: s = "solid",
9
- children: t,
10
- ...i
11
- }) => {
12
- const { thRoot: n } = c(s, { color: r });
13
- return /* @__PURE__ */ a(
14
- "span",
15
- {
16
- ...i,
17
- className: m(
18
- "inline-flex aspect-square shrink-0 items-center justify-center overflow-hidden rounded-full border",
19
- o,
20
- n,
21
- e
22
- ),
23
- "data-name": "Chip",
24
- children: t
25
- }
26
- );
27
- };
1
+ import { Chip as r } from "../ui/Chip.js";
28
2
  export {
29
- f as Chip
3
+ r as Chip
30
4
  };
31
5
  //# sourceMappingURL=Chip.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Chip.js","sources":["../../lib/molecules/Chip.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport type { ComponentPropsWithoutRef } from 'react';\n\nimport { getTheme, type Theme } from './Chip.themes';\n\nimport type { Colors } from '@/types/Colors';\n\nexport interface ChipProps extends ComponentPropsWithoutRef<'span'> {\n color?: Colors;\n size?: string;\n theme?: Theme;\n}\n\nexport const Chip = ({\n className,\n color = 'sienna',\n size = 'size-32',\n theme = 'solid',\n children,\n ...attrs\n}: ChipProps) => {\n const { thRoot } = getTheme(theme, { color });\n\n return (\n <span\n {...attrs}\n className={clsx(\n 'inline-flex aspect-square shrink-0 items-center justify-center overflow-hidden rounded-full border',\n size,\n thRoot,\n className,\n )}\n data-name=\"Chip\"\n >\n {children}\n </span>\n );\n};\n"],"names":["Chip","className","color","size","theme","children","attrs","thRoot","getTheme","jsx","clsx"],"mappings":";;;AAaO,MAAMA,IAAO,CAAC;AAAA,EACnB,WAAAC;AAAA,EACA,OAAAC,IAAQ;AAAA,EACR,MAAAC,IAAO;AAAA,EACP,OAAAC,IAAQ;AAAA,EACR,UAAAC;AAAA,EACA,GAAGC;AACL,MAAiB;AACf,QAAM,EAAE,QAAAC,EAAA,IAAWC,EAASJ,GAAO,EAAE,OAAAF,GAAO;AAE5C,SACE,gBAAAO;AAAA,IAAC;AAAA,IAAA;AAAA,MACE,GAAGH;AAAA,MACJ,WAAWI;AAAA,QACT;AAAA,QACAP;AAAA,QACAI;AAAA,QACAN;AAAA,MAAA;AAAA,MAEF,aAAU;AAAA,MAET,UAAAI;AAAA,IAAA;AAAA,EAAA;AAGP;"}
1
+ {"version":3,"file":"Chip.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,12 +1 @@
1
- import { Colors } from '../types/Colors';
2
- export type Theme = 'solid' | 'outline' | 'light' | 'dark';
3
- type Options = {
4
- color: Colors;
5
- };
6
- export declare const themes: (color: Colors) => Record<Theme, {
7
- thRoot: string;
8
- }>;
9
- export declare const getTheme: (theme: Theme, { color }: Options) => {
10
- thRoot: string;
11
- };
12
- export {};
1
+ export * from '../ui/Chip.themes';