@cambly/syntax-core 9.6.0 → 9.7.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 (354) hide show
  1. package/dist/Avatar/Avatar.css +28 -0
  2. package/dist/Avatar/Avatar.css.map +1 -0
  3. package/dist/Avatar/Avatar.d.ts +27 -0
  4. package/dist/Avatar/Avatar.js +8 -0
  5. package/dist/Avatar/Avatar.js.map +1 -0
  6. package/dist/Avatar/Avatar.mjs +8 -0
  7. package/dist/Avatar/Avatar.mjs.map +1 -0
  8. package/dist/Badge/Badge.css +1870 -0
  9. package/dist/Badge/Badge.css.map +1 -0
  10. package/dist/Badge/Badge.d.ts +25 -0
  11. package/dist/Badge/Badge.js +13 -0
  12. package/dist/Badge/Badge.js.map +1 -0
  13. package/dist/Badge/Badge.mjs +13 -0
  14. package/dist/Badge/Badge.mjs.map +1 -0
  15. package/dist/Box/Box.css +1783 -0
  16. package/dist/Box/Box.css.map +1 -0
  17. package/dist/Box/Box.d.ts +371 -0
  18. package/dist/Box/Box.js +11 -0
  19. package/dist/Box/Box.js.map +1 -0
  20. package/dist/Box/Box.mjs +11 -0
  21. package/dist/Box/Box.mjs.map +1 -0
  22. package/dist/Button/Button.css +1956 -0
  23. package/dist/Button/Button.css.map +1 -0
  24. package/dist/Button/Button.d.ts +85 -0
  25. package/dist/Button/Button.js +21 -0
  26. package/dist/Button/Button.js.map +1 -0
  27. package/dist/Button/Button.mjs +21 -0
  28. package/dist/Button/Button.mjs.map +1 -0
  29. package/dist/Button/constants/iconSize.css +92 -0
  30. package/dist/Button/constants/iconSize.css.map +1 -0
  31. package/dist/Button/constants/iconSize.d.ts +7 -0
  32. package/dist/Button/constants/iconSize.js +8 -0
  33. package/dist/Button/constants/iconSize.js.map +1 -0
  34. package/dist/Button/constants/iconSize.mjs +8 -0
  35. package/dist/Button/constants/iconSize.mjs.map +1 -0
  36. package/dist/Button/constants/loadingIconSize.d.ts +7 -0
  37. package/dist/Button/constants/loadingIconSize.js +8 -0
  38. package/dist/Button/constants/loadingIconSize.js.map +1 -0
  39. package/dist/Button/constants/loadingIconSize.mjs +8 -0
  40. package/dist/Button/constants/loadingIconSize.mjs.map +1 -0
  41. package/dist/Button/constants/textVariant.d.ts +7 -0
  42. package/dist/Button/constants/textVariant.js +8 -0
  43. package/dist/Button/constants/textVariant.js.map +1 -0
  44. package/dist/Button/constants/textVariant.mjs +8 -0
  45. package/dist/Button/constants/textVariant.mjs.map +1 -0
  46. package/dist/ButtonGroup/ButtonGroup.css +20 -0
  47. package/dist/ButtonGroup/ButtonGroup.css.map +1 -0
  48. package/dist/ButtonGroup/ButtonGroup.d.ts +29 -0
  49. package/dist/ButtonGroup/ButtonGroup.js +8 -0
  50. package/dist/ButtonGroup/ButtonGroup.js.map +1 -0
  51. package/dist/ButtonGroup/ButtonGroup.mjs +8 -0
  52. package/dist/ButtonGroup/ButtonGroup.mjs.map +1 -0
  53. package/dist/Card/Card.css +1783 -0
  54. package/dist/Card/Card.css.map +1 -0
  55. package/dist/Card/Card.d.ts +27 -0
  56. package/dist/Card/Card.js +12 -0
  57. package/dist/Card/Card.js.map +1 -0
  58. package/dist/Card/Card.mjs +12 -0
  59. package/dist/Card/Card.mjs.map +1 -0
  60. package/dist/Checkbox/Checkbox.css +313 -0
  61. package/dist/Checkbox/Checkbox.css.map +1 -0
  62. package/dist/Checkbox/Checkbox.d.ts +48 -0
  63. package/dist/Checkbox/Checkbox.js +14 -0
  64. package/dist/Checkbox/Checkbox.js.map +1 -0
  65. package/dist/Checkbox/Checkbox.mjs +14 -0
  66. package/dist/Checkbox/Checkbox.mjs.map +1 -0
  67. package/dist/Chip/Chip.css +1902 -0
  68. package/dist/Chip/Chip.css.map +1 -0
  69. package/dist/Chip/Chip.d.ts +45 -0
  70. package/dist/Chip/Chip.js +14 -0
  71. package/dist/Chip/Chip.js.map +1 -0
  72. package/dist/Chip/Chip.mjs +14 -0
  73. package/dist/Chip/Chip.mjs.map +1 -0
  74. package/dist/Divider/Divider.css +10 -0
  75. package/dist/Divider/Divider.css.map +1 -0
  76. package/dist/Divider/Divider.d.ts +9 -0
  77. package/dist/Divider/Divider.js +8 -0
  78. package/dist/Divider/Divider.js.map +1 -0
  79. package/dist/Divider/Divider.mjs +8 -0
  80. package/dist/Divider/Divider.mjs.map +1 -0
  81. package/dist/Heading/Heading.css +248 -0
  82. package/dist/Heading/Heading.css.map +1 -0
  83. package/dist/Heading/Heading.d.ts +52 -0
  84. package/dist/Heading/Heading.js +11 -0
  85. package/dist/Heading/Heading.js.map +1 -0
  86. package/dist/Heading/Heading.mjs +11 -0
  87. package/dist/Heading/Heading.mjs.map +1 -0
  88. package/dist/IconButton/IconButton.css +227 -0
  89. package/dist/IconButton/IconButton.css.map +1 -0
  90. package/dist/IconButton/IconButton.d.ts +55 -0
  91. package/dist/IconButton/IconButton.js +13 -0
  92. package/dist/IconButton/IconButton.js.map +1 -0
  93. package/dist/IconButton/IconButton.mjs +13 -0
  94. package/dist/IconButton/IconButton.mjs.map +1 -0
  95. package/dist/LinkButton/LinkButton.css +353 -0
  96. package/dist/LinkButton/LinkButton.css.map +1 -0
  97. package/dist/LinkButton/LinkButton.d.ts +72 -0
  98. package/dist/LinkButton/LinkButton.js +17 -0
  99. package/dist/LinkButton/LinkButton.js.map +1 -0
  100. package/dist/LinkButton/LinkButton.mjs +17 -0
  101. package/dist/LinkButton/LinkButton.mjs.map +1 -0
  102. package/dist/Modal/FocusTrap.d.ts +10 -0
  103. package/dist/Modal/FocusTrap.js +8 -0
  104. package/dist/Modal/FocusTrap.js.map +1 -0
  105. package/dist/Modal/FocusTrap.mjs +8 -0
  106. package/dist/Modal/FocusTrap.mjs.map +1 -0
  107. package/dist/Modal/Layer.css +1783 -0
  108. package/dist/Modal/Layer.css.map +1 -0
  109. package/dist/Modal/Layer.d.ts +8 -0
  110. package/dist/Modal/Layer.js +12 -0
  111. package/dist/Modal/Layer.js.map +1 -0
  112. package/dist/Modal/Layer.mjs +12 -0
  113. package/dist/Modal/Layer.mjs.map +1 -0
  114. package/dist/Modal/Modal.css +1898 -0
  115. package/dist/Modal/Modal.css.map +1 -0
  116. package/dist/Modal/Modal.d.ts +113 -0
  117. package/dist/Modal/Modal.js +17 -0
  118. package/dist/Modal/Modal.js.map +1 -0
  119. package/dist/Modal/Modal.mjs +17 -0
  120. package/dist/Modal/Modal.mjs.map +1 -0
  121. package/dist/Modal/StopScroll.d.ts +7 -0
  122. package/dist/Modal/StopScroll.js +8 -0
  123. package/dist/Modal/StopScroll.js.map +1 -0
  124. package/dist/Modal/StopScroll.mjs +8 -0
  125. package/dist/Modal/StopScroll.mjs.map +1 -0
  126. package/dist/RadioButton/RadioButton.css +318 -0
  127. package/dist/RadioButton/RadioButton.css.map +1 -0
  128. package/dist/RadioButton/RadioButton.d.ts +60 -0
  129. package/dist/RadioButton/RadioButton.js +14 -0
  130. package/dist/RadioButton/RadioButton.js.map +1 -0
  131. package/dist/RadioButton/RadioButton.mjs +14 -0
  132. package/dist/RadioButton/RadioButton.mjs.map +1 -0
  133. package/dist/SelectList/SelectList.css +335 -0
  134. package/dist/SelectList/SelectList.css.map +1 -0
  135. package/dist/SelectList/SelectList.d.ts +72 -0
  136. package/dist/SelectList/SelectList.js +15 -0
  137. package/dist/SelectList/SelectList.js.map +1 -0
  138. package/dist/SelectList/SelectList.mjs +15 -0
  139. package/dist/SelectList/SelectList.mjs.map +1 -0
  140. package/dist/SelectList/SelectOption.d.ts +10 -0
  141. package/dist/SelectList/SelectOption.js +8 -0
  142. package/dist/SelectList/SelectOption.js.map +1 -0
  143. package/dist/SelectList/SelectOption.mjs +8 -0
  144. package/dist/SelectList/SelectOption.mjs.map +1 -0
  145. package/dist/TapArea/TapArea.css +53 -0
  146. package/dist/TapArea/TapArea.css.map +1 -0
  147. package/dist/TapArea/TapArea.d.ts +53 -0
  148. package/dist/TapArea/TapArea.js +10 -0
  149. package/dist/TapArea/TapArea.js.map +1 -0
  150. package/dist/TapArea/TapArea.mjs +10 -0
  151. package/dist/TapArea/TapArea.mjs.map +1 -0
  152. package/dist/TextField/TextField.css +1913 -0
  153. package/dist/TextField/TextField.css.map +1 -0
  154. package/dist/TextField/TextField.d.ts +68 -0
  155. package/dist/TextField/TextField.js +14 -0
  156. package/dist/TextField/TextField.js.map +1 -0
  157. package/dist/TextField/TextField.mjs +14 -0
  158. package/dist/TextField/TextField.mjs.map +1 -0
  159. package/dist/Typography/Typography.css +248 -0
  160. package/dist/Typography/Typography.css.map +1 -0
  161. package/dist/Typography/Typography.d.ts +83 -0
  162. package/dist/Typography/Typography.js +10 -0
  163. package/dist/Typography/Typography.js.map +1 -0
  164. package/dist/Typography/Typography.mjs +10 -0
  165. package/dist/Typography/Typography.mjs.map +1 -0
  166. package/dist/__chunks/2JWMSFS7.js +31 -0
  167. package/dist/__chunks/2JWMSFS7.js.map +1 -0
  168. package/dist/__chunks/2O6FDRTF.js +7 -0
  169. package/dist/__chunks/2O6FDRTF.js.map +1 -0
  170. package/dist/__chunks/2PHVTRWC.js +86 -0
  171. package/dist/__chunks/2PHVTRWC.js.map +1 -0
  172. package/dist/__chunks/37CQV3RS.js +111 -0
  173. package/dist/__chunks/37CQV3RS.js.map +1 -0
  174. package/dist/__chunks/3PCHHAIY.mjs +7 -0
  175. package/dist/__chunks/3PCHHAIY.mjs.map +1 -0
  176. package/dist/__chunks/3VUMTAUX.js +68 -0
  177. package/dist/__chunks/3VUMTAUX.js.map +1 -0
  178. package/dist/__chunks/42YPEAFS.js +70 -0
  179. package/dist/__chunks/42YPEAFS.js.map +1 -0
  180. package/dist/__chunks/4PWSK5GI.js +15 -0
  181. package/dist/__chunks/4PWSK5GI.js.map +1 -0
  182. package/dist/__chunks/5AR53MHD.js +1 -0
  183. package/dist/__chunks/5AR53MHD.js.map +1 -0
  184. package/dist/__chunks/5DBWL6IK.js +12 -0
  185. package/dist/__chunks/5DBWL6IK.js.map +1 -0
  186. package/dist/__chunks/5R6HCJP6.mjs +68 -0
  187. package/dist/__chunks/5R6HCJP6.mjs.map +1 -0
  188. package/dist/__chunks/6VWFOSQZ.js +14 -0
  189. package/dist/__chunks/6VWFOSQZ.js.map +1 -0
  190. package/dist/__chunks/A7UVLRKG.mjs +15 -0
  191. package/dist/__chunks/A7UVLRKG.mjs.map +1 -0
  192. package/dist/__chunks/AFINOME7.js +17 -0
  193. package/dist/__chunks/AFINOME7.js.map +1 -0
  194. package/dist/__chunks/AGAHNSZM.js +127 -0
  195. package/dist/__chunks/AGAHNSZM.js.map +1 -0
  196. package/dist/__chunks/AMBZXKUQ.mjs +12 -0
  197. package/dist/__chunks/AMBZXKUQ.mjs.map +1 -0
  198. package/dist/__chunks/BCWLWS7W.mjs +74 -0
  199. package/dist/__chunks/BCWLWS7W.mjs.map +1 -0
  200. package/dist/__chunks/BJXYKZMK.mjs +53 -0
  201. package/dist/__chunks/BJXYKZMK.mjs.map +1 -0
  202. package/dist/__chunks/BSFWQWVJ.js +36 -0
  203. package/dist/__chunks/BSFWQWVJ.js.map +1 -0
  204. package/dist/__chunks/BSWWGQAS.js +111 -0
  205. package/dist/__chunks/BSWWGQAS.js.map +1 -0
  206. package/dist/__chunks/BWTLHCW3.mjs +111 -0
  207. package/dist/__chunks/BWTLHCW3.mjs.map +1 -0
  208. package/dist/__chunks/CATJI2RJ.js +26 -0
  209. package/dist/__chunks/CATJI2RJ.js.map +1 -0
  210. package/dist/__chunks/CGGEM6XS.mjs +96 -0
  211. package/dist/__chunks/CGGEM6XS.mjs.map +1 -0
  212. package/dist/__chunks/CPBWDVD4.mjs +110 -0
  213. package/dist/__chunks/CPBWDVD4.mjs.map +1 -0
  214. package/dist/__chunks/CQ2HIJ62.js +35 -0
  215. package/dist/__chunks/CQ2HIJ62.js.map +1 -0
  216. package/dist/__chunks/CUDAH5IW.mjs +38 -0
  217. package/dist/__chunks/CUDAH5IW.mjs.map +1 -0
  218. package/dist/__chunks/D24RSGYP.js +7 -0
  219. package/dist/__chunks/D24RSGYP.js.map +1 -0
  220. package/dist/__chunks/DVVFHZBW.mjs +120 -0
  221. package/dist/__chunks/DVVFHZBW.mjs.map +1 -0
  222. package/dist/__chunks/EKJ4XOIM.mjs +12 -0
  223. package/dist/__chunks/EKJ4XOIM.mjs.map +1 -0
  224. package/dist/__chunks/ERJ5XXDH.js +96 -0
  225. package/dist/__chunks/ERJ5XXDH.js.map +1 -0
  226. package/dist/__chunks/ERXGNP37.js +7 -0
  227. package/dist/__chunks/ERXGNP37.js.map +1 -0
  228. package/dist/__chunks/F3ZST4RL.js +74 -0
  229. package/dist/__chunks/F3ZST4RL.js.map +1 -0
  230. package/dist/__chunks/FCX7QDZS.mjs +94 -0
  231. package/dist/__chunks/FCX7QDZS.mjs.map +1 -0
  232. package/dist/__chunks/FOTKCGZZ.js +53 -0
  233. package/dist/__chunks/FOTKCGZZ.js.map +1 -0
  234. package/dist/__chunks/FUBK3VZO.js +28 -0
  235. package/dist/__chunks/FUBK3VZO.js.map +1 -0
  236. package/dist/__chunks/FWVHWU47.mjs +7 -0
  237. package/dist/__chunks/FWVHWU47.mjs.map +1 -0
  238. package/dist/__chunks/G4DDTGDI.js +31 -0
  239. package/dist/__chunks/G4DDTGDI.js.map +1 -0
  240. package/dist/__chunks/GPS2XNQI.js +120 -0
  241. package/dist/__chunks/GPS2XNQI.js.map +1 -0
  242. package/dist/__chunks/GVNDZZAU.mjs +14 -0
  243. package/dist/__chunks/GVNDZZAU.mjs.map +1 -0
  244. package/dist/__chunks/HAZN2FCY.mjs +28 -0
  245. package/dist/__chunks/HAZN2FCY.mjs.map +1 -0
  246. package/dist/__chunks/HOUO3WV6.js +14 -0
  247. package/dist/__chunks/HOUO3WV6.js.map +1 -0
  248. package/dist/__chunks/HQVZUEWO.js +22 -0
  249. package/dist/__chunks/HQVZUEWO.js.map +1 -0
  250. package/dist/__chunks/IXDA4ZXP.mjs +1 -0
  251. package/dist/__chunks/IXDA4ZXP.mjs.map +1 -0
  252. package/dist/__chunks/JSEHOGL7.mjs +7 -0
  253. package/dist/__chunks/JSEHOGL7.mjs.map +1 -0
  254. package/dist/__chunks/LJHH6KUW.js +28 -0
  255. package/dist/__chunks/LJHH6KUW.js.map +1 -0
  256. package/dist/__chunks/LKQ7PJ4S.mjs +229 -0
  257. package/dist/__chunks/LKQ7PJ4S.mjs.map +1 -0
  258. package/dist/__chunks/LULBCTQR.js +38 -0
  259. package/dist/__chunks/LULBCTQR.js.map +1 -0
  260. package/dist/__chunks/LZSDWT4M.mjs +110 -0
  261. package/dist/__chunks/LZSDWT4M.mjs.map +1 -0
  262. package/dist/__chunks/M6YFAP6P.mjs +28 -0
  263. package/dist/__chunks/M6YFAP6P.mjs.map +1 -0
  264. package/dist/__chunks/MX7C572C.mjs +36 -0
  265. package/dist/__chunks/MX7C572C.mjs.map +1 -0
  266. package/dist/__chunks/MZEIZAZH.mjs +35 -0
  267. package/dist/__chunks/MZEIZAZH.mjs.map +1 -0
  268. package/dist/__chunks/OGJDUOWP.js +94 -0
  269. package/dist/__chunks/OGJDUOWP.js.map +1 -0
  270. package/dist/__chunks/OQ26OWU4.mjs +111 -0
  271. package/dist/__chunks/OQ26OWU4.mjs.map +1 -0
  272. package/dist/__chunks/PGVLU6C3.mjs +70 -0
  273. package/dist/__chunks/PGVLU6C3.mjs.map +1 -0
  274. package/dist/__chunks/PYNS67IV.js +229 -0
  275. package/dist/__chunks/PYNS67IV.js.map +1 -0
  276. package/dist/__chunks/Q2TIB7ZC.mjs +26 -0
  277. package/dist/__chunks/Q2TIB7ZC.mjs.map +1 -0
  278. package/dist/__chunks/R6CDK4GP.mjs +31 -0
  279. package/dist/__chunks/R6CDK4GP.mjs.map +1 -0
  280. package/dist/__chunks/RRE7PRE5.mjs +86 -0
  281. package/dist/__chunks/RRE7PRE5.mjs.map +1 -0
  282. package/dist/__chunks/RSU3GDHB.mjs +73 -0
  283. package/dist/__chunks/RSU3GDHB.mjs.map +1 -0
  284. package/dist/__chunks/RVT6EXR3.mjs +31 -0
  285. package/dist/__chunks/RVT6EXR3.mjs.map +1 -0
  286. package/dist/__chunks/SAEVPDUP.js +12 -0
  287. package/dist/__chunks/SAEVPDUP.js.map +1 -0
  288. package/dist/__chunks/SXTRSFG5.mjs +14 -0
  289. package/dist/__chunks/SXTRSFG5.mjs.map +1 -0
  290. package/dist/__chunks/TKYRBLSM.js +110 -0
  291. package/dist/__chunks/TKYRBLSM.js.map +1 -0
  292. package/dist/__chunks/TPMQI44L.js +7 -0
  293. package/dist/__chunks/TPMQI44L.js.map +1 -0
  294. package/dist/__chunks/UCMB6MFN.mjs +17 -0
  295. package/dist/__chunks/UCMB6MFN.mjs.map +1 -0
  296. package/dist/__chunks/UNIBFDXV.js +73 -0
  297. package/dist/__chunks/UNIBFDXV.js.map +1 -0
  298. package/dist/__chunks/WCEOAOUO.mjs +127 -0
  299. package/dist/__chunks/WCEOAOUO.mjs.map +1 -0
  300. package/dist/__chunks/WJDAVT5R.mjs +7 -0
  301. package/dist/__chunks/WJDAVT5R.mjs.map +1 -0
  302. package/dist/__chunks/X74O4HUS.js +110 -0
  303. package/dist/__chunks/X74O4HUS.js.map +1 -0
  304. package/dist/__chunks/XFKGXL73.mjs +14 -0
  305. package/dist/__chunks/XFKGXL73.mjs.map +1 -0
  306. package/dist/__chunks/XN5AALLC.mjs +22 -0
  307. package/dist/__chunks/XN5AALLC.mjs.map +1 -0
  308. package/dist/__chunks/YJ7YDIGB.js +14 -0
  309. package/dist/__chunks/YJ7YDIGB.js.map +1 -0
  310. package/dist/colors/allColors.d.ts +3 -0
  311. package/dist/colors/allColors.js +58 -0
  312. package/dist/colors/allColors.js.map +1 -0
  313. package/dist/colors/allColors.mjs +58 -0
  314. package/dist/colors/allColors.mjs.map +1 -0
  315. package/dist/colors/backgroundColor.css +167 -0
  316. package/dist/colors/backgroundColor.css.map +1 -0
  317. package/dist/colors/backgroundColor.d.ts +5 -0
  318. package/dist/colors/backgroundColor.js +10 -0
  319. package/dist/colors/backgroundColor.js.map +1 -0
  320. package/dist/colors/backgroundColor.mjs +10 -0
  321. package/dist/colors/backgroundColor.mjs.map +1 -0
  322. package/dist/colors/foregroundColor.css +167 -0
  323. package/dist/colors/foregroundColor.css.map +1 -0
  324. package/dist/colors/foregroundColor.d.ts +5 -0
  325. package/dist/colors/foregroundColor.js +10 -0
  326. package/dist/colors/foregroundColor.js.map +1 -0
  327. package/dist/colors/foregroundColor.mjs +10 -0
  328. package/dist/colors/foregroundColor.mjs.map +1 -0
  329. package/dist/colors/foregroundTypographyColor.d.ts +5 -0
  330. package/dist/colors/foregroundTypographyColor.js +8 -0
  331. package/dist/colors/foregroundTypographyColor.js.map +1 -0
  332. package/dist/colors/foregroundTypographyColor.mjs +8 -0
  333. package/dist/colors/foregroundTypographyColor.mjs.map +1 -0
  334. package/dist/constants.d.ts +4 -0
  335. package/dist/constants.js +26 -0
  336. package/dist/constants.js.map +1 -0
  337. package/dist/constants.mjs +26 -0
  338. package/dist/constants.mjs.map +1 -0
  339. package/dist/index.d.ts +21 -1250
  340. package/dist/index.js +38 -1676
  341. package/dist/index.js.map +1 -1
  342. package/dist/index.mjs +70 -1682
  343. package/dist/index.mjs.map +1 -1
  344. package/dist/useFocusVisible.d.ts +5 -0
  345. package/dist/useFocusVisible.js +8 -0
  346. package/dist/useFocusVisible.js.map +1 -0
  347. package/dist/useFocusVisible.mjs +8 -0
  348. package/dist/useFocusVisible.mjs.map +1 -0
  349. package/dist/useIsHydrated.d.ts +3 -0
  350. package/dist/useIsHydrated.js +8 -0
  351. package/dist/useIsHydrated.js.map +1 -0
  352. package/dist/useIsHydrated.mjs +8 -0
  353. package/dist/useIsHydrated.mjs.map +1 -0
  354. package/package.json +4 -4
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/LinkButton/LinkButton.tsx","css-module:../Button/Button.module.css#css-module","css-module:./LinkButton.module.css#css-module"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,SAAS,kBAA2C;AACpD,OAAO,gBAAgB;;;ACDqE,IAAO,wBAAQ,EAAC,UAAS,mBAAkB,aAAY,sBAAqB,aAAY,uBAAsB,MAAK,gBAAe,MAAK,gBAAe,MAAK,gBAAe,QAAO,kBAAiB,UAAS,oBAAmB,UAAS,oBAAmB,UAAS,oBAAmB,mBAAkB,8BAA6B,8BAA6B,yCAAwC,WAAU,sBAAqB,6BAA4B,sCAAqC,iBAAgB,2BAA0B;;;ACA5gB,IAAO,4BAAQ,EAAC,cAAa,uBAAsB,cAAa,uBAAsB;;;AFwGpL,SAwBI,KAxBJ;AAlBN,IAAM,aAAa;AAAA,EACjB,CACE;AAAA,IACE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,eAAe;AAAA,IACf,QAAQ;AAAA,IACR,OAAO;AAAA,IACP,YAAY;AAAA,IACZ,WAAW;AAAA,IACX,SAAS;AAAA,IACT;AAAA,EACF,GACA,QACG;AACH,WACE;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA,eAAa;AAAA,QACb;AAAA,QACA;AAAA,QACA;AAAA,QACA,WAAW;AAAA,UACT,0BAAO;AAAA,UACP,sBAAa;AAAA,UACb,gBAAgB,KAAK;AAAA,UACrB,gBAAgB,KAAK;AAAA,UACrB,sBAAa,IAAI;AAAA,UACjB;AAAA,YACE,CAAC,sBAAa,SAAS,GAAG;AAAA,YAC1B,CAAC,0BAAO,UAAU,GAAG,CAAC;AAAA,YACtB,CAAC,sBAAa,SAAS,GAAG,SAAS,QAAQ,SAAS;AAAA,YACpD,CAAC,sBAAa,eAAe,GAAG,UAAU;AAAA,YAC1C,CAAC,sBAAa,0BAA0B,GACtC,UAAU;AAAA,UACd;AAAA,QACF;AAAA,QACA;AAAA,QAEC;AAAA,uBACC;AAAA,YAAC;AAAA;AAAA,cACC,WAAW,WAAW,sBAAa,MAAM,iBAAS,IAAI,CAAC;AAAA;AAAA,UACzD;AAAA,UAEF;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,0BAA0B,KAAK;AAAA,cACtC,MAAM,oBAAY,IAAI;AAAA,cAEtB,8BAAC,UAAK,OAAO,EAAE,YAAY,IAAI,GAAI,gBAAK;AAAA;AAAA,UAC1C;AAAA,UACC,WACC,oBAAC,WAAQ,WAAW,WAAW,sBAAa,MAAM,iBAAS,IAAI,CAAC,GAAG;AAAA;AAAA;AAAA,IAEvE;AAAA,EAEJ;AACF;AAEA,WAAW,cAAc;AAEzB,IAAO,qBAAQ","sourcesContent":["import { forwardRef, type HtmlHTMLAttributes } from \"react\";\nimport classNames from \"classnames\";\nimport backgroundColor from \"../colors/backgroundColor\";\nimport foregroundColor from \"../colors/foregroundColor\";\nimport foregroundTypographyColor from \"../colors/foregroundTypographyColor\";\nimport React from \"react\";\nimport { type Size } from \"../constants\";\nimport Typography from \"../Typography/Typography\";\n\nimport buttonStyles from \"../Button/Button.module.css\";\nimport iconSize from \"../Button/constants/iconSize\";\nimport textVariant from \"../Button/constants/textVariant\";\n\nimport styles from \"./LinkButton.module.css\";\n\ntype LinkButtonProps = {\n /**\n * Test id for the button\n */\n \"data-testid\"?: string;\n /**\n * The text to be displayed inside the button\n */\n text: string;\n /**\n * The link that the LinkButton should route to.\n *\n */\n href?: string;\n /**\n * The target attribute specifies where to open the linked document.\n *\n */\n target?: \"_blank\" | \"_self\" | \"_parent\" | \"_top\";\n /**\n * The rel attribute specifies the relationship between the document and the link.\n *\n */\n rel?: HtmlHTMLAttributes<HTMLAnchorElement>[\"rel\"];\n /**\n * The color of the button\n *\n * @defaultValue \"primary\"\n */\n color?:\n | \"primary\"\n | \"secondary\"\n | \"tertiary\"\n | \"destructive-primary\"\n | \"destructive-secondary\"\n | \"destructive-tertiary\"\n | \"branded\"\n | \"success\";\n /**\n * The size of the button\n *\n * * `sm`: 32px\n * * `md`: 40px\n * * `lg`: 48px\n *\n * @defaultValue \"md\"\n */\n size?: (typeof Size)[number];\n /**\n * If `true`, the button will take up the full width of its container\n *\n * @defaultValue false\n */\n fullWidth?: boolean;\n /**\n * The icon to be displayed at the start of the button. Please use a [Rounded Material Icon](https://material.io/resources/icons/?style=round)\n */\n startIcon?: React.ComponentType<{ className?: string }>;\n /**\n * The icon to be displayed at the end of the button. Please use a [Rounded Material Icon](https://material.io/resources/icons/?style=round)\n */\n endIcon?: React.ComponentType<{ className?: string }>;\n /**\n * An optional onClick event. This is used for certain wrapper's support (such as react-router-dom).\n */\n onClick?: React.MouseEventHandler<HTMLAnchorElement>;\n};\n\n/**\n * [LinkButton](https://cambly-syntax.vercel.app/?path=/docs/components-linkbutton--docs) is a \"variation\" of Button that should look identical to Button, but should be used to render links instead.\n */\nconst LinkButton = forwardRef<HTMLAnchorElement, LinkButtonProps>(\n (\n {\n text,\n href,\n target,\n rel,\n \"data-testid\": dataTestId,\n color = \"primary\",\n size = \"md\",\n fullWidth = false,\n startIcon: StartIcon,\n endIcon: EndIcon,\n onClick,\n }: LinkButtonProps,\n ref,\n ) => {\n return (\n <a\n href={href}\n data-testid={dataTestId}\n target={target}\n ref={ref}\n rel={rel}\n className={classNames(\n styles.linkButton,\n buttonStyles.button,\n foregroundColor(color),\n backgroundColor(color),\n buttonStyles[size],\n {\n [buttonStyles.fullWidth]: fullWidth,\n [styles.fitContent]: !fullWidth,\n [buttonStyles.buttonGap]: size === \"lg\" || size === \"md\",\n [buttonStyles.secondaryBorder]: color === \"secondary\",\n [buttonStyles.secondaryDestructiveBorder]:\n color === \"destructive-secondary\",\n },\n )}\n onClick={onClick}\n >\n {StartIcon && (\n <StartIcon\n className={classNames(buttonStyles.icon, iconSize[size])}\n />\n )}\n <Typography\n color={foregroundTypographyColor(color)}\n size={textVariant[size]}\n >\n <span style={{ fontWeight: 500 }}>{text}</span>\n </Typography>\n {EndIcon && (\n <EndIcon className={classNames(buttonStyles.icon, iconSize[size])} />\n )}\n </a>\n );\n },\n);\n\nLinkButton.displayName = \"LinkButton\";\n\nexport default LinkButton;\n","import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/Button/Button.module.css\"; export default {\"button\":\"_button_1iunh_1\",\"buttonGap\":\"_buttonGap_1iunh_9\",\"fullWidth\":\"_fullWidth_1iunh_50\",\"sm\":\"_sm_1iunh_54\",\"md\":\"_md_1iunh_61\",\"lg\":\"_lg_1iunh_68\",\"icon\":\"_icon_1iunh_75\",\"smIcon\":\"_smIcon_1iunh_79\",\"mdIcon\":\"_mdIcon_1iunh_86\",\"lgIcon\":\"_lgIcon_1iunh_93\",\"secondaryBorder\":\"_secondaryBorder_1iunh_100\",\"secondaryDestructiveBorder\":\"_secondaryDestructiveBorder_1iunh_104\",\"loading\":\"_loading_1iunh_118\",\"syntaxButtonLoadingRotate\":\"_syntaxButtonLoadingRotate_1iunh_1\",\"loadingCircle\":\"_loadingCircle_1iunh_122\"}","import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/LinkButton/LinkButton.module.css\"; export default {\"linkButton\":\"_linkButton_1qjrb_1\",\"fitContent\":\"_fitContent_1qjrb_11\"}"]}
@@ -0,0 +1,7 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});// css-module:../colors/colors.module.css#css-module
2
+ var colors_module_default = { "inheritColor": "_inheritColor_11l4y_2", "destructive700Color": "_destructive700Color_11l4y_6", "gray700Color": "_gray700Color_11l4y_10", "gray900Color": "_gray900Color_11l4y_14", "primary700Color": "_primary700Color_11l4y_18", "success700Color": "_success700Color_11l4y_22", "whiteColor": "_whiteColor_11l4y_26", "blackBackgroundColor": "_blackBackgroundColor_11l4y_31", "destructive100BackgroundColor": "_destructive100BackgroundColor_11l4y_35", "destructive200BackgroundColor": "_destructive200BackgroundColor_11l4y_39", "destructive300BackgroundColor": "_destructive300BackgroundColor_11l4y_43", "destructive700BackgroundColor": "_destructive700BackgroundColor_11l4y_47", "destructive800BackgroundColor": "_destructive800BackgroundColor_11l4y_51", "destructive900BackgroundColor": "_destructive900BackgroundColor_11l4y_55", "gray10BackgroundColor": "_gray10BackgroundColor_11l4y_59", "gray30BackgroundColor": "_gray30BackgroundColor_11l4y_63", "gray60BackgroundColor": "_gray60BackgroundColor_11l4y_67", "gray80BackgroundColor": "_gray80BackgroundColor_11l4y_71", "gray100BackgroundColor": "_gray100BackgroundColor_11l4y_75", "gray200BackgroundColor": "_gray200BackgroundColor_11l4y_79", "gray300BackgroundColor": "_gray300BackgroundColor_11l4y_83", "gray700BackgroundColor": "_gray700BackgroundColor_11l4y_87", "gray800BackgroundColor": "_gray800BackgroundColor_11l4y_91", "gray900BackgroundColor": "_gray900BackgroundColor_11l4y_95", "orange100BackgroundColor": "_orange100BackgroundColor_11l4y_99", "orange200BackgroundColor": "_orange200BackgroundColor_11l4y_103", "orange300BackgroundColor": "_orange300BackgroundColor_11l4y_107", "orange700BackgroundColor": "_orange700BackgroundColor_11l4y_111", "orange800BackgroundColor": "_orange800BackgroundColor_11l4y_115", "orange900BackgroundColor": "_orange900BackgroundColor_11l4y_119", "primary100BackgroundColor": "_primary100BackgroundColor_11l4y_123", "primary200BackgroundColor": "_primary200BackgroundColor_11l4y_127", "primary300BackgroundColor": "_primary300BackgroundColor_11l4y_131", "primary700BackgroundColor": "_primary700BackgroundColor_11l4y_135", "primary800BackgroundColor": "_primary800BackgroundColor_11l4y_139", "primary900BackgroundColor": "_primary900BackgroundColor_11l4y_143", "success100BackgroundColor": "_success100BackgroundColor_11l4y_147", "success200BackgroundColor": "_success200BackgroundColor_11l4y_151", "success300BackgroundColor": "_success300BackgroundColor_11l4y_155", "success700BackgroundColor": "_success700BackgroundColor_11l4y_159", "success800BackgroundColor": "_success800BackgroundColor_11l4y_163", "success900BackgroundColor": "_success900BackgroundColor_11l4y_167", "purple100BackgroundColor": "_purple100BackgroundColor_11l4y_171", "purple200BackgroundColor": "_purple200BackgroundColor_11l4y_175", "purple300BackgroundColor": "_purple300BackgroundColor_11l4y_179", "purple700BackgroundColor": "_purple700BackgroundColor_11l4y_183", "purple800BackgroundColor": "_purple800BackgroundColor_11l4y_187", "purple900BackgroundColor": "_purple900BackgroundColor_11l4y_191", "whiteBackgroundColor": "_whiteBackgroundColor_11l4y_195", "yellow100BackgroundColor": "_yellow100BackgroundColor_11l4y_199", "yellow200BackgroundColor": "_yellow200BackgroundColor_11l4y_203", "yellow300BackgroundColor": "_yellow300BackgroundColor_11l4y_207", "yellow700BackgroundColor": "_yellow700BackgroundColor_11l4y_211", "yellow800BackgroundColor": "_yellow800BackgroundColor_11l4y_215", "yellow900BackgroundColor": "_yellow900BackgroundColor_11l4y_219" };
3
+
4
+
5
+
6
+ exports.colors_module_default = colors_module_default;
7
+ //# sourceMappingURL=ERXGNP37.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["css-module:../colors/colors.module.css#css-module"],"names":[],"mappings":";AAA4F,IAAO,wBAAQ,EAAC,gBAAe,yBAAwB,uBAAsB,gCAA+B,gBAAe,0BAAyB,gBAAe,0BAAyB,mBAAkB,6BAA4B,mBAAkB,6BAA4B,cAAa,wBAAuB,wBAAuB,kCAAiC,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,yBAAwB,mCAAkC,yBAAwB,mCAAkC,yBAAwB,mCAAkC,yBAAwB,mCAAkC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,4BAA2B,sCAAqC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,wBAAuB,mCAAkC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,sCAAqC","sourcesContent":["import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/colors/colors.module.css\"; export default {\"inheritColor\":\"_inheritColor_11l4y_2\",\"destructive700Color\":\"_destructive700Color_11l4y_6\",\"gray700Color\":\"_gray700Color_11l4y_10\",\"gray900Color\":\"_gray900Color_11l4y_14\",\"primary700Color\":\"_primary700Color_11l4y_18\",\"success700Color\":\"_success700Color_11l4y_22\",\"whiteColor\":\"_whiteColor_11l4y_26\",\"blackBackgroundColor\":\"_blackBackgroundColor_11l4y_31\",\"destructive100BackgroundColor\":\"_destructive100BackgroundColor_11l4y_35\",\"destructive200BackgroundColor\":\"_destructive200BackgroundColor_11l4y_39\",\"destructive300BackgroundColor\":\"_destructive300BackgroundColor_11l4y_43\",\"destructive700BackgroundColor\":\"_destructive700BackgroundColor_11l4y_47\",\"destructive800BackgroundColor\":\"_destructive800BackgroundColor_11l4y_51\",\"destructive900BackgroundColor\":\"_destructive900BackgroundColor_11l4y_55\",\"gray10BackgroundColor\":\"_gray10BackgroundColor_11l4y_59\",\"gray30BackgroundColor\":\"_gray30BackgroundColor_11l4y_63\",\"gray60BackgroundColor\":\"_gray60BackgroundColor_11l4y_67\",\"gray80BackgroundColor\":\"_gray80BackgroundColor_11l4y_71\",\"gray100BackgroundColor\":\"_gray100BackgroundColor_11l4y_75\",\"gray200BackgroundColor\":\"_gray200BackgroundColor_11l4y_79\",\"gray300BackgroundColor\":\"_gray300BackgroundColor_11l4y_83\",\"gray700BackgroundColor\":\"_gray700BackgroundColor_11l4y_87\",\"gray800BackgroundColor\":\"_gray800BackgroundColor_11l4y_91\",\"gray900BackgroundColor\":\"_gray900BackgroundColor_11l4y_95\",\"orange100BackgroundColor\":\"_orange100BackgroundColor_11l4y_99\",\"orange200BackgroundColor\":\"_orange200BackgroundColor_11l4y_103\",\"orange300BackgroundColor\":\"_orange300BackgroundColor_11l4y_107\",\"orange700BackgroundColor\":\"_orange700BackgroundColor_11l4y_111\",\"orange800BackgroundColor\":\"_orange800BackgroundColor_11l4y_115\",\"orange900BackgroundColor\":\"_orange900BackgroundColor_11l4y_119\",\"primary100BackgroundColor\":\"_primary100BackgroundColor_11l4y_123\",\"primary200BackgroundColor\":\"_primary200BackgroundColor_11l4y_127\",\"primary300BackgroundColor\":\"_primary300BackgroundColor_11l4y_131\",\"primary700BackgroundColor\":\"_primary700BackgroundColor_11l4y_135\",\"primary800BackgroundColor\":\"_primary800BackgroundColor_11l4y_139\",\"primary900BackgroundColor\":\"_primary900BackgroundColor_11l4y_143\",\"success100BackgroundColor\":\"_success100BackgroundColor_11l4y_147\",\"success200BackgroundColor\":\"_success200BackgroundColor_11l4y_151\",\"success300BackgroundColor\":\"_success300BackgroundColor_11l4y_155\",\"success700BackgroundColor\":\"_success700BackgroundColor_11l4y_159\",\"success800BackgroundColor\":\"_success800BackgroundColor_11l4y_163\",\"success900BackgroundColor\":\"_success900BackgroundColor_11l4y_167\",\"purple100BackgroundColor\":\"_purple100BackgroundColor_11l4y_171\",\"purple200BackgroundColor\":\"_purple200BackgroundColor_11l4y_175\",\"purple300BackgroundColor\":\"_purple300BackgroundColor_11l4y_179\",\"purple700BackgroundColor\":\"_purple700BackgroundColor_11l4y_183\",\"purple800BackgroundColor\":\"_purple800BackgroundColor_11l4y_187\",\"purple900BackgroundColor\":\"_purple900BackgroundColor_11l4y_191\",\"whiteBackgroundColor\":\"_whiteBackgroundColor_11l4y_195\",\"yellow100BackgroundColor\":\"_yellow100BackgroundColor_11l4y_199\",\"yellow200BackgroundColor\":\"_yellow200BackgroundColor_11l4y_203\",\"yellow300BackgroundColor\":\"_yellow300BackgroundColor_11l4y_207\",\"yellow700BackgroundColor\":\"_yellow700BackgroundColor_11l4y_211\",\"yellow800BackgroundColor\":\"_yellow800BackgroundColor_11l4y_215\",\"yellow900BackgroundColor\":\"_yellow900BackgroundColor_11l4y_219\"}"]}
@@ -0,0 +1,74 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
2
+
3
+ var _ERXGNP37js = require('./ERXGNP37.js');
4
+
5
+ // src/Typography/Typography.tsx
6
+ var _classnames = require('classnames'); var _classnames2 = _interopRequireDefault(_classnames);
7
+
8
+ // css-module:./Typography.module.css#css-module
9
+ var Typography_module_default = { "typography": "_typography_1vnry_1", "size100": "_size100_1vnry_8", "size200": "_size200_1vnry_12", "size300": "_size300_1vnry_16", "size500": "_size500_1vnry_20", "size600": "_size600_1vnry_24", "size700": "_size700_1vnry_28", "size800": "_size800_1vnry_32", "center": "_center_1vnry_37", "forceLeft": "_forceLeft_1vnry_41", "forceRight": "_forceRight_1vnry_45", "start": "_start_1vnry_49", "end": "_end_1vnry_53", "bold": "_bold_1vnry_58", "regular": "_regular_1vnry_62", "interactive": "_interactive_1vnry_66", "semiBold": "_semiBold_1vnry_70", "heavy": "_heavy_1vnry_74", "underline": "_underline_1vnry_78", "inline": "_inline_1vnry_82", "uppercase": "_uppercase_1vnry_86", "lineClamp": "_lineClamp_1vnry_90" };
10
+
11
+ // src/Typography/Typography.tsx
12
+ var _jsxruntime = require('react/jsx-runtime');
13
+ function textColor(color) {
14
+ switch (color) {
15
+ case "gray700":
16
+ return _ERXGNP37js.colors_module_default.gray700Color;
17
+ case "white":
18
+ return _ERXGNP37js.colors_module_default.whiteColor;
19
+ case "inherit":
20
+ return _ERXGNP37js.colors_module_default.inheritColor;
21
+ case "primary":
22
+ return _ERXGNP37js.colors_module_default.primary700Color;
23
+ case "destructive-primary":
24
+ return _ERXGNP37js.colors_module_default.destructive700Color;
25
+ case "success":
26
+ return _ERXGNP37js.colors_module_default.success700Color;
27
+ default:
28
+ return _ERXGNP37js.colors_module_default.gray900Color;
29
+ }
30
+ }
31
+ var Typography = ({
32
+ align = "start",
33
+ as = "div",
34
+ children,
35
+ color = "gray900",
36
+ "data-testid": dataTestId,
37
+ inline = false,
38
+ lineClamp = void 0,
39
+ size = 200,
40
+ tooltip,
41
+ transform = "none",
42
+ underline = false,
43
+ weight = "regular"
44
+ }) => {
45
+ const Tag = as;
46
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
47
+ Tag,
48
+ {
49
+ className: _classnames2.default.call(void 0,
50
+ Typography_module_default.typography,
51
+ Typography_module_default[align],
52
+ Typography_module_default[weight],
53
+ textColor(color),
54
+ inline && Typography_module_default.inline,
55
+ Typography_module_default[`size${size}`],
56
+ transform === "uppercase" && Typography_module_default.uppercase,
57
+ underline && Typography_module_default.underline,
58
+ lineClamp != null && Typography_module_default.lineClamp
59
+ ),
60
+ "data-testid": dataTestId,
61
+ style: {
62
+ WebkitLineClamp: lineClamp
63
+ },
64
+ title: tooltip,
65
+ children
66
+ }
67
+ );
68
+ };
69
+ var Typography_default = Typography;
70
+
71
+
72
+
73
+ exports.Typography_default = Typography_default;
74
+ //# sourceMappingURL=F3ZST4RL.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/Typography/Typography.tsx","css-module:./Typography.module.css#css-module"],"names":[],"mappings":";;;;;AAAA,OAAO,gBAAgB;;;ACA6E,IAAO,4BAAQ,EAAC,cAAa,uBAAsB,WAAU,oBAAmB,WAAU,qBAAoB,WAAU,qBAAoB,WAAU,qBAAoB,WAAU,qBAAoB,WAAU,qBAAoB,WAAU,qBAAoB,UAAS,oBAAmB,aAAY,uBAAsB,cAAa,wBAAuB,SAAQ,mBAAkB,OAAM,iBAAgB,QAAO,kBAAiB,WAAU,qBAAoB,eAAc,yBAAwB,YAAW,sBAAqB,SAAQ,mBAAkB,aAAY,uBAAsB,UAAS,oBAAmB,aAAY,uBAAsB,aAAY,sBAAqB;;;ADwH7wB;AAlHJ,SAAS,UAAU,OAAuC;AACxD,UAAQ,OAAO;AAAA,IACb,KAAK;AACH,aAAO,sBAAY;AAAA,IACrB,KAAK;AACH,aAAO,sBAAY;AAAA,IACrB,KAAK;AACH,aAAO,sBAAY;AAAA,IACrB,KAAK;AACH,aAAO,sBAAY;AAAA,IACrB,KAAK;AACH,aAAO,sBAAY;AAAA,IACrB,KAAK;AACH,aAAO,sBAAY;AAAA,IACrB;AACE,aAAO,sBAAY;AAAA,EACvB;AACF;AAKA,IAAM,aAAa,CAAC;AAAA,EAClB,QAAQ;AAAA,EACR,KAAK;AAAA,EACL;AAAA,EACA,QAAQ;AAAA,EACR,eAAe;AAAA,EACf,SAAS;AAAA,EACT,YAAY;AAAA,EACZ,OAAO;AAAA,EACP;AAAA,EACA,YAAY;AAAA,EACZ,YAAY;AAAA,EACZ,SAAS;AACX,MA2EoB;AAClB,QAAM,MAAM;AAEZ,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW;AAAA,QACT,0BAAO;AAAA,QACP,0BAAO,KAAK;AAAA,QACZ,0BAAO,MAAM;AAAA,QACb,UAAU,KAAK;AAAA,QACf,UAAU,0BAAO;AAAA,QACjB,0BAAO,OAAO,MAAM;AAAA,QACpB,cAAc,eAAe,0BAAO;AAAA,QACpC,aAAa,0BAAO;AAAA,QACpB,aAAa,QAAQ,0BAAO;AAAA,MAC9B;AAAA,MACA,eAAa;AAAA,MACb,OAAO;AAAA,QACL,iBAAiB;AAAA,MACnB;AAAA,MACA,OAAO;AAAA,MAEN;AAAA;AAAA,EACH;AAEJ;AAEA,IAAO,qBAAQ","sourcesContent":["import classNames from \"classnames\";\nimport { type ReactElement, type ReactNode } from \"react\";\nimport { type Color } from \"../constants\";\nimport styles from \"./Typography.module.css\";\nimport colorStyles from \"../colors/colors.module.css\";\n\nfunction textColor(color: (typeof Color)[number]): string {\n switch (color) {\n case \"gray700\":\n return colorStyles.gray700Color;\n case \"white\":\n return colorStyles.whiteColor;\n case \"inherit\":\n return colorStyles.inheritColor;\n case \"primary\":\n return colorStyles.primary700Color;\n case \"destructive-primary\":\n return colorStyles.destructive700Color;\n case \"success\":\n return colorStyles.success700Color;\n default:\n return colorStyles.gray900Color;\n }\n}\n\n/**\n * [Typography](https://cambly-syntax.vercel.app/?path=/docs/components-typography--docs) is a component that renders text.\n */\nconst Typography = ({\n align = \"start\",\n as = \"div\",\n children,\n color = \"gray900\",\n \"data-testid\": dataTestId,\n inline = false,\n lineClamp = undefined,\n size = 200,\n tooltip,\n transform = \"none\",\n underline = false,\n weight = \"regular\",\n}: {\n /**\n * Aligns the text to the left, right, or center of the container.\n * * `start` and `end` will align the text to the left or right of the container depending on the locale.\n * * `forceLeft` and `forceRight` will align the text to the left or right of the container regardless of the locale (should be used sparingly).\n *\n * @defaultValue \"start\"\n */\n align?: \"start\" | \"end\" | \"forceLeft\" | \"center\" | \"forceRight\";\n /**\n * DOM element to render as.\n *\n * @defaultValue \"div\"\n */\n as?: \"div\" | \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n /**\n * The text to be rendered\n */\n children?: ReactNode;\n /**\n * The color of the text.\n *\n * @defaultValue \"gray900\"\n */\n color?: (typeof Color)[number];\n /**\n * Test id for the text\n */\n \"data-testid\"?: string;\n /**\n * Whether the text should flow inline with other elements.\n *\n * @defaultValue false\n */\n inline?: boolean;\n /**\n * The number of lines we should truncate the text at\n */\n lineClamp?: number | undefined;\n /**\n * Size of the text.\n *\n * * `100`: 12px\n * * `200`: 14px\n * * `300`: 16px\n * * `500`: 20px\n * * `600`: 28px\n * * `700`: 40px\n * * `800`: 64px\n *\n * @defaultValue 200\n */\n size?: 100 | 200 | 300 | 500 | 600 | 700 | 800;\n /**\n * The tooltip to be displayed when the user hovers the text\n */\n tooltip?: string;\n /**\n * Whether the text should be transformed to uppercase.\n *\n * @defaultValue \"none\"\n */\n transform?: \"none\" | \"uppercase\";\n /**\n * Whether the text has an underline.\n *\n * @defaultValue false\n */\n underline?: boolean;\n /**\n * Indicates the boldness of the text.\n *\n * @defaultValue \"regular\"\n */\n weight?: \"regular\" | \"interactive\" | \"semiBold\" | \"bold\" | \"heavy\";\n}): ReactElement => {\n const Tag = as;\n\n return (\n <Tag\n className={classNames(\n styles.typography,\n styles[align],\n styles[weight],\n textColor(color),\n inline && styles.inline,\n styles[`size${size}`],\n transform === \"uppercase\" && styles.uppercase,\n underline && styles.underline,\n lineClamp != null && styles.lineClamp,\n )}\n data-testid={dataTestId}\n style={{\n WebkitLineClamp: lineClamp,\n }}\n title={tooltip}\n >\n {children}\n </Tag>\n );\n};\n\nexport default Typography;\n","import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/Typography/Typography.module.css\"; export default {\"typography\":\"_typography_1vnry_1\",\"size100\":\"_size100_1vnry_8\",\"size200\":\"_size200_1vnry_12\",\"size300\":\"_size300_1vnry_16\",\"size500\":\"_size500_1vnry_20\",\"size600\":\"_size600_1vnry_24\",\"size700\":\"_size700_1vnry_28\",\"size800\":\"_size800_1vnry_32\",\"center\":\"_center_1vnry_37\",\"forceLeft\":\"_forceLeft_1vnry_41\",\"forceRight\":\"_forceRight_1vnry_45\",\"start\":\"_start_1vnry_49\",\"end\":\"_end_1vnry_53\",\"bold\":\"_bold_1vnry_58\",\"regular\":\"_regular_1vnry_62\",\"interactive\":\"_interactive_1vnry_66\",\"semiBold\":\"_semiBold_1vnry_70\",\"heavy\":\"_heavy_1vnry_74\",\"underline\":\"_underline_1vnry_78\",\"inline\":\"_inline_1vnry_82\",\"uppercase\":\"_uppercase_1vnry_86\",\"lineClamp\":\"_lineClamp_1vnry_90\"}"]}
@@ -0,0 +1,94 @@
1
+ // src/useFocusVisible.tsx
2
+ import { useState, useEffect } from "react";
3
+ var hasSetupGlobalListeners = false;
4
+ var currentModality = null;
5
+ var changeHandlers = /* @__PURE__ */ new Set();
6
+ var hasEventBeforeFocus = false;
7
+ var isMac = (
8
+ // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
9
+ typeof window !== "undefined" && window.navigator != null ? (
10
+ // eslint-disable-next-line @typescript-eslint/prefer-string-starts-ends-with
11
+ /^Mac/.test(window.navigator.platform)
12
+ ) : false
13
+ );
14
+ function isValidKey(e) {
15
+ return !(e.metaKey || !isMac && e.altKey || e.ctrlKey);
16
+ }
17
+ function triggerChangeHandlers(modality, e) {
18
+ changeHandlers.forEach((handler) => {
19
+ handler(modality, e);
20
+ });
21
+ }
22
+ function handleKeyboardEvent(e) {
23
+ hasEventBeforeFocus = true;
24
+ if (isValidKey(e)) {
25
+ currentModality = "keyboard";
26
+ triggerChangeHandlers("keyboard", e);
27
+ }
28
+ }
29
+ function handlePointerEvent(e) {
30
+ currentModality = "pointer";
31
+ if (e.type === "mousedown" || e.type === "pointerdown") {
32
+ hasEventBeforeFocus = true;
33
+ triggerChangeHandlers("pointer", e);
34
+ }
35
+ }
36
+ function handleFocusEvent(e) {
37
+ if (e.target === window || e.target === document) {
38
+ return;
39
+ }
40
+ if (!hasEventBeforeFocus) {
41
+ currentModality = "keyboard";
42
+ triggerChangeHandlers("keyboard", e);
43
+ }
44
+ hasEventBeforeFocus = false;
45
+ }
46
+ function handleWindowBlur() {
47
+ hasEventBeforeFocus = false;
48
+ }
49
+ function isFocusVisible() {
50
+ return currentModality !== "pointer";
51
+ }
52
+ function setupGlobalFocusEvents() {
53
+ if (typeof window === "undefined" || hasSetupGlobalListeners) {
54
+ return;
55
+ }
56
+ const { focus } = HTMLElement.prototype;
57
+ HTMLElement.prototype.focus = function focusElement(...args) {
58
+ hasEventBeforeFocus = true;
59
+ focus.apply(this, args);
60
+ };
61
+ document.addEventListener("keydown", handleKeyboardEvent, true);
62
+ document.addEventListener("keyup", handleKeyboardEvent, true);
63
+ window.addEventListener("focus", handleFocusEvent, true);
64
+ window.addEventListener("blur", handleWindowBlur, false);
65
+ if (typeof PointerEvent !== "undefined") {
66
+ document.addEventListener("pointerdown", handlePointerEvent, true);
67
+ document.addEventListener("pointermove", handlePointerEvent, true);
68
+ document.addEventListener("pointerup", handlePointerEvent, true);
69
+ } else {
70
+ document.addEventListener("mousedown", handlePointerEvent, true);
71
+ document.addEventListener("mousemove", handlePointerEvent, true);
72
+ document.addEventListener("mouseup", handlePointerEvent, true);
73
+ }
74
+ hasSetupGlobalListeners = true;
75
+ }
76
+ function useFocusVisible() {
77
+ setupGlobalFocusEvents();
78
+ const [isFocusVisibleState, setFocusVisible] = useState(isFocusVisible());
79
+ useEffect(() => {
80
+ const handler = () => {
81
+ setFocusVisible(isFocusVisible());
82
+ };
83
+ changeHandlers.add(handler);
84
+ return () => {
85
+ changeHandlers.delete(handler);
86
+ };
87
+ }, []);
88
+ return { isFocusVisible: isFocusVisibleState };
89
+ }
90
+
91
+ export {
92
+ useFocusVisible
93
+ };
94
+ //# sourceMappingURL=FCX7QDZS.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/useFocusVisible.tsx"],"sourcesContent":["// Portions of the code in this file are based on code from react & react-spectrum:\n// https://github.com/facebook/react/blob/cc7c1aece46a6b69b41958d731e0fd27c94bfc6c/packages/react-interactions/events/src/dom/create-event-handle/Focus.js\n// https://github.com/adobe/react-spectrum/blob/c700898916bbd076bcc63e49d77c16d80623a8e7/packages/@react-aria/interactions/src/useFocusVisible.ts\n\nimport { useState, useEffect } from \"react\";\n\ntype Modality = \"keyboard\" | \"pointer\";\ntype HandlerEvent = PointerEvent | MouseEvent | KeyboardEvent | FocusEvent;\ntype Handler = (modality: Modality, e: HandlerEvent) => void;\n\nlet hasSetupGlobalListeners = false;\nlet currentModality: Modality | null = null;\nconst changeHandlers = new Set<Handler>();\nlet hasEventBeforeFocus = false;\n\nconst isMac =\n // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition\n typeof window !== \"undefined\" && window.navigator != null\n ? // eslint-disable-next-line @typescript-eslint/prefer-string-starts-ends-with\n /^Mac/.test(window.navigator.platform)\n : false;\n\nfunction isValidKey(e: KeyboardEvent) {\n return !(e.metaKey || (!isMac && e.altKey) || e.ctrlKey);\n}\n\nfunction triggerChangeHandlers(modality: Modality, e: HandlerEvent) {\n changeHandlers.forEach((handler) => {\n handler(modality, e);\n });\n}\n\nfunction handleKeyboardEvent(e: KeyboardEvent) {\n hasEventBeforeFocus = true;\n if (isValidKey(e)) {\n currentModality = \"keyboard\";\n triggerChangeHandlers(\"keyboard\", e);\n }\n}\n\nfunction handlePointerEvent(e: PointerEvent | MouseEvent) {\n currentModality = \"pointer\";\n if (e.type === \"mousedown\" || e.type === \"pointerdown\") {\n hasEventBeforeFocus = true;\n triggerChangeHandlers(\"pointer\", e);\n }\n}\n\nfunction handleFocusEvent(e: FocusEvent) {\n // Firefox fires two extra focus events when the user first clicks into an iframe:\n // first on the window, then on the document. We ignore these events so they don't\n // cause keyboard focus rings to appear.\n if (e.target === window || e.target === document) {\n return;\n }\n\n // If a focus event occurs without a preceding keyboard or pointer event, switch to keyboard modality.\n // This occurs, for example, when navigating a form with the next/previous buttons on iOS.\n if (!hasEventBeforeFocus) {\n currentModality = \"keyboard\";\n triggerChangeHandlers(\"keyboard\", e);\n }\n\n hasEventBeforeFocus = false;\n}\n\nfunction handleWindowBlur() {\n // When the window is blurred, reset state. This is necessary when tabbing out of the window,\n // for example, since a subsequent focus event won't be fired.\n hasEventBeforeFocus = false;\n}\n\nfunction isFocusVisible(): boolean {\n return currentModality !== \"pointer\";\n}\n\nfunction setupGlobalFocusEvents() {\n if (typeof window === \"undefined\" || hasSetupGlobalListeners) {\n return;\n }\n\n // Programmatic focus() calls shouldn't affect the current input modality.\n // However, we need to detect other cases when a focus event occurs without\n // a preceding user event (e.g. screen reader focus). Overriding the focus\n // method on HTMLElement.prototype is a bit hacky, but works.\n // $FlowExpectedError[method-unbinding]\n // eslint-disable-next-line @typescript-eslint/unbound-method\n const { focus } = HTMLElement.prototype;\n // $FlowIssue[cannot-write]\n HTMLElement.prototype.focus = function focusElement(...args) {\n hasEventBeforeFocus = true;\n focus.apply(this, args);\n };\n\n document.addEventListener(\"keydown\", handleKeyboardEvent, true);\n document.addEventListener(\"keyup\", handleKeyboardEvent, true);\n\n // Register focus events on the window so they are sure to happen\n // before React's event listeners (registered on the document).\n window.addEventListener(\"focus\", handleFocusEvent, true);\n window.addEventListener(\"blur\", handleWindowBlur, false);\n\n if (typeof PointerEvent !== \"undefined\") {\n document.addEventListener(\"pointerdown\", handlePointerEvent, true);\n document.addEventListener(\"pointermove\", handlePointerEvent, true);\n document.addEventListener(\"pointerup\", handlePointerEvent, true);\n } else {\n document.addEventListener(\"mousedown\", handlePointerEvent, true);\n document.addEventListener(\"mousemove\", handlePointerEvent, true);\n document.addEventListener(\"mouseup\", handlePointerEvent, true);\n }\n\n hasSetupGlobalListeners = true;\n}\n\nexport default function useFocusVisible(): {\n isFocusVisible: boolean;\n} {\n setupGlobalFocusEvents();\n const [isFocusVisibleState, setFocusVisible] = useState(isFocusVisible());\n useEffect(() => {\n const handler = () => {\n setFocusVisible(isFocusVisible());\n };\n\n changeHandlers.add(handler);\n return () => {\n changeHandlers.delete(handler);\n };\n }, []);\n\n return { isFocusVisible: isFocusVisibleState };\n}\n"],"mappings":";AAIA,SAAS,UAAU,iBAAiB;AAMpC,IAAI,0BAA0B;AAC9B,IAAI,kBAAmC;AACvC,IAAM,iBAAiB,oBAAI,IAAa;AACxC,IAAI,sBAAsB;AAE1B,IAAM;AAAA;AAAA,EAEJ,OAAO,WAAW,eAAe,OAAO,aAAa;AAAA;AAAA,IAEjD,OAAO,KAAK,OAAO,UAAU,QAAQ;AAAA,MACrC;AAAA;AAEN,SAAS,WAAW,GAAkB;AACpC,SAAO,EAAE,EAAE,WAAY,CAAC,SAAS,EAAE,UAAW,EAAE;AAClD;AAEA,SAAS,sBAAsB,UAAoB,GAAiB;AAClE,iBAAe,QAAQ,CAAC,YAAY;AAClC,YAAQ,UAAU,CAAC;AAAA,EACrB,CAAC;AACH;AAEA,SAAS,oBAAoB,GAAkB;AAC7C,wBAAsB;AACtB,MAAI,WAAW,CAAC,GAAG;AACjB,sBAAkB;AAClB,0BAAsB,YAAY,CAAC;AAAA,EACrC;AACF;AAEA,SAAS,mBAAmB,GAA8B;AACxD,oBAAkB;AAClB,MAAI,EAAE,SAAS,eAAe,EAAE,SAAS,eAAe;AACtD,0BAAsB;AACtB,0BAAsB,WAAW,CAAC;AAAA,EACpC;AACF;AAEA,SAAS,iBAAiB,GAAe;AAIvC,MAAI,EAAE,WAAW,UAAU,EAAE,WAAW,UAAU;AAChD;AAAA,EACF;AAIA,MAAI,CAAC,qBAAqB;AACxB,sBAAkB;AAClB,0BAAsB,YAAY,CAAC;AAAA,EACrC;AAEA,wBAAsB;AACxB;AAEA,SAAS,mBAAmB;AAG1B,wBAAsB;AACxB;AAEA,SAAS,iBAA0B;AACjC,SAAO,oBAAoB;AAC7B;AAEA,SAAS,yBAAyB;AAChC,MAAI,OAAO,WAAW,eAAe,yBAAyB;AAC5D;AAAA,EACF;AAQA,QAAM,EAAE,MAAM,IAAI,YAAY;AAE9B,cAAY,UAAU,QAAQ,SAAS,gBAAgB,MAAM;AAC3D,0BAAsB;AACtB,UAAM,MAAM,MAAM,IAAI;AAAA,EACxB;AAEA,WAAS,iBAAiB,WAAW,qBAAqB,IAAI;AAC9D,WAAS,iBAAiB,SAAS,qBAAqB,IAAI;AAI5D,SAAO,iBAAiB,SAAS,kBAAkB,IAAI;AACvD,SAAO,iBAAiB,QAAQ,kBAAkB,KAAK;AAEvD,MAAI,OAAO,iBAAiB,aAAa;AACvC,aAAS,iBAAiB,eAAe,oBAAoB,IAAI;AACjE,aAAS,iBAAiB,eAAe,oBAAoB,IAAI;AACjE,aAAS,iBAAiB,aAAa,oBAAoB,IAAI;AAAA,EACjE,OAAO;AACL,aAAS,iBAAiB,aAAa,oBAAoB,IAAI;AAC/D,aAAS,iBAAiB,aAAa,oBAAoB,IAAI;AAC/D,aAAS,iBAAiB,WAAW,oBAAoB,IAAI;AAAA,EAC/D;AAEA,4BAA0B;AAC5B;AAEe,SAAR,kBAEL;AACA,yBAAuB;AACvB,QAAM,CAAC,qBAAqB,eAAe,IAAI,SAAS,eAAe,CAAC;AACxE,YAAU,MAAM;AACd,UAAM,UAAU,MAAM;AACpB,sBAAgB,eAAe,CAAC;AAAA,IAClC;AAEA,mBAAe,IAAI,OAAO;AAC1B,WAAO,MAAM;AACX,qBAAe,OAAO,OAAO;AAAA,IAC/B;AAAA,EACF,GAAG,CAAC,CAAC;AAEL,SAAO,EAAE,gBAAgB,oBAAoB;AAC/C;","names":[]}
@@ -0,0 +1,53 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+ var _PYNS67IVjs = require('./PYNS67IV.js');
4
+
5
+
6
+ var _F3ZST4RLjs = require('./F3ZST4RL.js');
7
+
8
+ // css-module:./Badge.module.css#css-module
9
+ var Badge_module_default = { "icon": "_icon_1g9xb_1" };
10
+
11
+ // src/Badge/Badge.tsx
12
+ var _jsxruntime = require('react/jsx-runtime');
13
+ var textColorForBackgroundColor = (color) => {
14
+ switch (color) {
15
+ case "gray200":
16
+ case "yellow700":
17
+ return "gray900";
18
+ default:
19
+ return "white";
20
+ }
21
+ };
22
+ var Badge = ({
23
+ icon: Icon,
24
+ text,
25
+ color = "primary700"
26
+ }) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
27
+ _PYNS67IVjs.Box_default,
28
+ {
29
+ display: "inlineBlock",
30
+ paddingX: 2,
31
+ paddingY: 1,
32
+ rounding: "full",
33
+ backgroundColor: color,
34
+ children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _F3ZST4RLjs.Typography_default, { color: textColorForBackgroundColor(color), size: 100, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _PYNS67IVjs.Box_default, { display: "flex", gap: 1, alignItems: "center", justifyContent: "start", children: [
35
+ Icon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Icon, { className: Badge_module_default.icon }),
36
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
37
+ _F3ZST4RLjs.Typography_default,
38
+ {
39
+ color: textColorForBackgroundColor(color),
40
+ size: 100,
41
+ weight: "bold",
42
+ children: text
43
+ }
44
+ )
45
+ ] }) })
46
+ }
47
+ );
48
+ var Badge_default = Badge;
49
+
50
+
51
+
52
+ exports.Badge_default = Badge_default;
53
+ //# sourceMappingURL=FOTKCGZZ.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["css-module:./Badge.module.css#css-module","../../src/Badge/Badge.tsx"],"names":[],"mappings":";;;;;;;;AAA0F,IAAO,uBAAQ,EAAC,QAAO,gBAAe;;;AC0D1H,SACW,KADX;AA3CN,IAAM,8BAA8B,CAClC,UACwB;AACxB,UAAQ,OAAO;AAAA,IACb,KAAK;AAAA,IACL,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAKA,IAAM,QAAQ,CAAC;AAAA,EACb,MAAM;AAAA,EACN;AAAA,EACA,QAAQ;AACV,MAgBE;AAAA,EAAC;AAAA;AAAA,IACC,SAAQ;AAAA,IACR,UAAU;AAAA,IACV,UAAU;AAAA,IACV,UAAS;AAAA,IACT,iBAAiB;AAAA,IAEjB,8BAAC,sBAAW,OAAO,4BAA4B,KAAK,GAAG,MAAM,KAC3D,+BAAC,eAAI,SAAQ,QAAO,KAAK,GAAG,YAAW,UAAS,gBAAe,SAC5D;AAAA,cAAQ,oBAAC,QAAK,WAAW,qBAAO,MAAM;AAAA,MACvC;AAAA,QAAC;AAAA;AAAA,UACC,OAAO,4BAA4B,KAAK;AAAA,UACxC,MAAM;AAAA,UACN,QAAO;AAAA,UAEN;AAAA;AAAA,MACH;AAAA,OACF,GACF;AAAA;AACF;AAGF,IAAO,gBAAQ","sourcesContent":["import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/Badge/Badge.module.css\"; export default {\"icon\":\"_icon_1g9xb_1\"}","import Typography from \"../Typography/Typography\";\nimport Box from \"../Box/Box\";\nimport styles from \"./Badge.module.css\";\n\nconst BadgeColor = [\n \"gray200\",\n \"gray900\",\n \"destructive700\",\n \"orange700\",\n \"yellow700\",\n \"success700\",\n \"primary700\",\n \"purple700\",\n] as const;\n\nconst textColorForBackgroundColor = (\n color: (typeof BadgeColor)[number],\n): \"gray900\" | \"white\" => {\n switch (color) {\n case \"gray200\":\n case \"yellow700\":\n return \"gray900\";\n default:\n return \"white\";\n }\n};\n\n/**\n * [Badge](https://cambly-syntax.vercel.app/?path=/docs/components-badge--docs) is a component to display short text and give additional context to features and other components.\n */\nconst Badge = ({\n icon: Icon,\n text,\n color = \"primary700\",\n}: {\n /**\n * The icon to be displayed. Please use a [Material Icon](https://material.io/resources/icons/)\n */\n icon?: React.ComponentType<{ className?: string }>;\n /**\n * The text to display inside the badge\n */\n text: string;\n /**\n * The color of the badge\n *\n * @defaultValue \"primary700\"\n */\n color?: (typeof BadgeColor)[number];\n}): JSX.Element => (\n <Box\n display=\"inlineBlock\"\n paddingX={2}\n paddingY={1}\n rounding=\"full\"\n backgroundColor={color}\n >\n <Typography color={textColorForBackgroundColor(color)} size={100}>\n <Box display=\"flex\" gap={1} alignItems=\"center\" justifyContent=\"start\">\n {Icon && <Icon className={styles.icon} />}\n <Typography\n color={textColorForBackgroundColor(color)}\n size={100}\n weight=\"bold\"\n >\n {text}\n </Typography>\n </Box>\n </Typography>\n </Box>\n);\n\nexport default Badge;\n"]}
@@ -0,0 +1,28 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }// src/Avatar/Avatar.tsx
2
+ var _classnames = require('classnames'); var _classnames2 = _interopRequireDefault(_classnames);
3
+
4
+ // css-module:./Avatar.module.css#css-module
5
+ var Avatar_module_default = { "avatar": "_avatar_1anoj_5", "sm": "_sm_1anoj_13", "md": "_md_1anoj_18", "lg": "_lg_1anoj_23", "xl": "_xl_1anoj_28" };
6
+
7
+ // src/Avatar/Avatar.tsx
8
+ var _jsxruntime = require('react/jsx-runtime');
9
+ var Avatar = ({
10
+ src,
11
+ accessibilityLabel,
12
+ size = "md"
13
+ }) => {
14
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
15
+ "img",
16
+ {
17
+ alt: accessibilityLabel,
18
+ src,
19
+ className: _classnames2.default.call(void 0, Avatar_module_default.avatar, Avatar_module_default[size])
20
+ }
21
+ );
22
+ };
23
+ var Avatar_default = Avatar;
24
+
25
+
26
+
27
+ exports.Avatar_default = Avatar_default;
28
+ //# sourceMappingURL=FUBK3VZO.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/Avatar/Avatar.tsx","css-module:./Avatar.module.css#css-module"],"names":[],"mappings":";AAAA,OAAO,gBAAgB;;;ACAqE,IAAO,wBAAQ,EAAC,UAAS,mBAAkB,MAAK,gBAAe,MAAK,gBAAe,MAAK,gBAAe,MAAK,eAAc;;;ADiClN;AA3BJ,IAAM,SAAS,CAAC;AAAA,EACd;AAAA,EACA;AAAA,EACA,OAAO;AACT,MAqBmB;AACjB,SACE;AAAA,IAAC;AAAA;AAAA,MACC,KAAK;AAAA,MACL;AAAA,MACA,WAAW,WAAW,sBAAO,QAAQ,sBAAO,IAAI,CAAC;AAAA;AAAA,EACnD;AAEJ;AAEA,IAAO,iBAAQ","sourcesContent":["import classNames from \"classnames\";\nimport styles from \"./Avatar.module.css\";\n\n/**\n * [Avatar](https://cambly-syntax.vercel.app/?path=/docs/components-avatar--docs) is a circular image that represents a user.\n */\nconst Avatar = ({\n src,\n accessibilityLabel,\n size = \"md\",\n}: {\n /**\n * URL of the image to display as the avatar.\n */\n src: string;\n /**\n * Alt text to use for the image.\n * This should describe the image to people using screen readers.\n */\n accessibilityLabel: string;\n /**\n * Size of the avatar.\n *\n * * `sm`: 24px\n * * `md`: 40px\n * * `lg`: 72px\n * * `xl`: 128px\n *\n * @defaultValue `md`\n */\n size?: \"sm\" | \"md\" | \"lg\" | \"xl\";\n}): JSX.Element => {\n return (\n <img\n alt={accessibilityLabel}\n src={src}\n className={classNames(styles.avatar, styles[size])}\n />\n );\n};\n\nexport default Avatar;\n","import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/Avatar/Avatar.module.css\"; export default {\"avatar\":\"_avatar_1anoj_5\",\"sm\":\"_sm_1anoj_13\",\"md\":\"_md_1anoj_18\",\"lg\":\"_lg_1anoj_23\",\"xl\":\"_xl_1anoj_28\"}"]}
@@ -0,0 +1,7 @@
1
+ // css-module:../colors/colors.module.css#css-module
2
+ var colors_module_default = { "inheritColor": "_inheritColor_11l4y_2", "destructive700Color": "_destructive700Color_11l4y_6", "gray700Color": "_gray700Color_11l4y_10", "gray900Color": "_gray900Color_11l4y_14", "primary700Color": "_primary700Color_11l4y_18", "success700Color": "_success700Color_11l4y_22", "whiteColor": "_whiteColor_11l4y_26", "blackBackgroundColor": "_blackBackgroundColor_11l4y_31", "destructive100BackgroundColor": "_destructive100BackgroundColor_11l4y_35", "destructive200BackgroundColor": "_destructive200BackgroundColor_11l4y_39", "destructive300BackgroundColor": "_destructive300BackgroundColor_11l4y_43", "destructive700BackgroundColor": "_destructive700BackgroundColor_11l4y_47", "destructive800BackgroundColor": "_destructive800BackgroundColor_11l4y_51", "destructive900BackgroundColor": "_destructive900BackgroundColor_11l4y_55", "gray10BackgroundColor": "_gray10BackgroundColor_11l4y_59", "gray30BackgroundColor": "_gray30BackgroundColor_11l4y_63", "gray60BackgroundColor": "_gray60BackgroundColor_11l4y_67", "gray80BackgroundColor": "_gray80BackgroundColor_11l4y_71", "gray100BackgroundColor": "_gray100BackgroundColor_11l4y_75", "gray200BackgroundColor": "_gray200BackgroundColor_11l4y_79", "gray300BackgroundColor": "_gray300BackgroundColor_11l4y_83", "gray700BackgroundColor": "_gray700BackgroundColor_11l4y_87", "gray800BackgroundColor": "_gray800BackgroundColor_11l4y_91", "gray900BackgroundColor": "_gray900BackgroundColor_11l4y_95", "orange100BackgroundColor": "_orange100BackgroundColor_11l4y_99", "orange200BackgroundColor": "_orange200BackgroundColor_11l4y_103", "orange300BackgroundColor": "_orange300BackgroundColor_11l4y_107", "orange700BackgroundColor": "_orange700BackgroundColor_11l4y_111", "orange800BackgroundColor": "_orange800BackgroundColor_11l4y_115", "orange900BackgroundColor": "_orange900BackgroundColor_11l4y_119", "primary100BackgroundColor": "_primary100BackgroundColor_11l4y_123", "primary200BackgroundColor": "_primary200BackgroundColor_11l4y_127", "primary300BackgroundColor": "_primary300BackgroundColor_11l4y_131", "primary700BackgroundColor": "_primary700BackgroundColor_11l4y_135", "primary800BackgroundColor": "_primary800BackgroundColor_11l4y_139", "primary900BackgroundColor": "_primary900BackgroundColor_11l4y_143", "success100BackgroundColor": "_success100BackgroundColor_11l4y_147", "success200BackgroundColor": "_success200BackgroundColor_11l4y_151", "success300BackgroundColor": "_success300BackgroundColor_11l4y_155", "success700BackgroundColor": "_success700BackgroundColor_11l4y_159", "success800BackgroundColor": "_success800BackgroundColor_11l4y_163", "success900BackgroundColor": "_success900BackgroundColor_11l4y_167", "purple100BackgroundColor": "_purple100BackgroundColor_11l4y_171", "purple200BackgroundColor": "_purple200BackgroundColor_11l4y_175", "purple300BackgroundColor": "_purple300BackgroundColor_11l4y_179", "purple700BackgroundColor": "_purple700BackgroundColor_11l4y_183", "purple800BackgroundColor": "_purple800BackgroundColor_11l4y_187", "purple900BackgroundColor": "_purple900BackgroundColor_11l4y_191", "whiteBackgroundColor": "_whiteBackgroundColor_11l4y_195", "yellow100BackgroundColor": "_yellow100BackgroundColor_11l4y_199", "yellow200BackgroundColor": "_yellow200BackgroundColor_11l4y_203", "yellow300BackgroundColor": "_yellow300BackgroundColor_11l4y_207", "yellow700BackgroundColor": "_yellow700BackgroundColor_11l4y_211", "yellow800BackgroundColor": "_yellow800BackgroundColor_11l4y_215", "yellow900BackgroundColor": "_yellow900BackgroundColor_11l4y_219" };
3
+
4
+ export {
5
+ colors_module_default
6
+ };
7
+ //# sourceMappingURL=FWVHWU47.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["css-module:../colors/colors.module.css#css-module"],"sourcesContent":["import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/colors/colors.module.css\"; export default {\"inheritColor\":\"_inheritColor_11l4y_2\",\"destructive700Color\":\"_destructive700Color_11l4y_6\",\"gray700Color\":\"_gray700Color_11l4y_10\",\"gray900Color\":\"_gray900Color_11l4y_14\",\"primary700Color\":\"_primary700Color_11l4y_18\",\"success700Color\":\"_success700Color_11l4y_22\",\"whiteColor\":\"_whiteColor_11l4y_26\",\"blackBackgroundColor\":\"_blackBackgroundColor_11l4y_31\",\"destructive100BackgroundColor\":\"_destructive100BackgroundColor_11l4y_35\",\"destructive200BackgroundColor\":\"_destructive200BackgroundColor_11l4y_39\",\"destructive300BackgroundColor\":\"_destructive300BackgroundColor_11l4y_43\",\"destructive700BackgroundColor\":\"_destructive700BackgroundColor_11l4y_47\",\"destructive800BackgroundColor\":\"_destructive800BackgroundColor_11l4y_51\",\"destructive900BackgroundColor\":\"_destructive900BackgroundColor_11l4y_55\",\"gray10BackgroundColor\":\"_gray10BackgroundColor_11l4y_59\",\"gray30BackgroundColor\":\"_gray30BackgroundColor_11l4y_63\",\"gray60BackgroundColor\":\"_gray60BackgroundColor_11l4y_67\",\"gray80BackgroundColor\":\"_gray80BackgroundColor_11l4y_71\",\"gray100BackgroundColor\":\"_gray100BackgroundColor_11l4y_75\",\"gray200BackgroundColor\":\"_gray200BackgroundColor_11l4y_79\",\"gray300BackgroundColor\":\"_gray300BackgroundColor_11l4y_83\",\"gray700BackgroundColor\":\"_gray700BackgroundColor_11l4y_87\",\"gray800BackgroundColor\":\"_gray800BackgroundColor_11l4y_91\",\"gray900BackgroundColor\":\"_gray900BackgroundColor_11l4y_95\",\"orange100BackgroundColor\":\"_orange100BackgroundColor_11l4y_99\",\"orange200BackgroundColor\":\"_orange200BackgroundColor_11l4y_103\",\"orange300BackgroundColor\":\"_orange300BackgroundColor_11l4y_107\",\"orange700BackgroundColor\":\"_orange700BackgroundColor_11l4y_111\",\"orange800BackgroundColor\":\"_orange800BackgroundColor_11l4y_115\",\"orange900BackgroundColor\":\"_orange900BackgroundColor_11l4y_119\",\"primary100BackgroundColor\":\"_primary100BackgroundColor_11l4y_123\",\"primary200BackgroundColor\":\"_primary200BackgroundColor_11l4y_127\",\"primary300BackgroundColor\":\"_primary300BackgroundColor_11l4y_131\",\"primary700BackgroundColor\":\"_primary700BackgroundColor_11l4y_135\",\"primary800BackgroundColor\":\"_primary800BackgroundColor_11l4y_139\",\"primary900BackgroundColor\":\"_primary900BackgroundColor_11l4y_143\",\"success100BackgroundColor\":\"_success100BackgroundColor_11l4y_147\",\"success200BackgroundColor\":\"_success200BackgroundColor_11l4y_151\",\"success300BackgroundColor\":\"_success300BackgroundColor_11l4y_155\",\"success700BackgroundColor\":\"_success700BackgroundColor_11l4y_159\",\"success800BackgroundColor\":\"_success800BackgroundColor_11l4y_163\",\"success900BackgroundColor\":\"_success900BackgroundColor_11l4y_167\",\"purple100BackgroundColor\":\"_purple100BackgroundColor_11l4y_171\",\"purple200BackgroundColor\":\"_purple200BackgroundColor_11l4y_175\",\"purple300BackgroundColor\":\"_purple300BackgroundColor_11l4y_179\",\"purple700BackgroundColor\":\"_purple700BackgroundColor_11l4y_183\",\"purple800BackgroundColor\":\"_purple800BackgroundColor_11l4y_187\",\"purple900BackgroundColor\":\"_purple900BackgroundColor_11l4y_191\",\"whiteBackgroundColor\":\"_whiteBackgroundColor_11l4y_195\",\"yellow100BackgroundColor\":\"_yellow100BackgroundColor_11l4y_199\",\"yellow200BackgroundColor\":\"_yellow200BackgroundColor_11l4y_203\",\"yellow300BackgroundColor\":\"_yellow300BackgroundColor_11l4y_207\",\"yellow700BackgroundColor\":\"_yellow700BackgroundColor_11l4y_211\",\"yellow800BackgroundColor\":\"_yellow800BackgroundColor_11l4y_215\",\"yellow900BackgroundColor\":\"_yellow900BackgroundColor_11l4y_219\"}"],"mappings":";AAA4F,IAAO,wBAAQ,EAAC,gBAAe,yBAAwB,uBAAsB,gCAA+B,gBAAe,0BAAyB,gBAAe,0BAAyB,mBAAkB,6BAA4B,mBAAkB,6BAA4B,cAAa,wBAAuB,wBAAuB,kCAAiC,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,iCAAgC,2CAA0C,yBAAwB,mCAAkC,yBAAwB,mCAAkC,yBAAwB,mCAAkC,yBAAwB,mCAAkC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,0BAAyB,oCAAmC,4BAA2B,sCAAqC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,6BAA4B,wCAAuC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,wBAAuB,mCAAkC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,uCAAsC,4BAA2B,sCAAqC;","names":[]}
@@ -0,0 +1,31 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+ var _D24RSGYPjs = require('./D24RSGYP.js');
4
+
5
+ // src/colors/backgroundColor.ts
6
+ function backgroundColor(color) {
7
+ switch (color) {
8
+ case "secondary":
9
+ return _D24RSGYPjs.colors_module_default.primary100BackgroundColor;
10
+ case "destructive-primary":
11
+ return _D24RSGYPjs.colors_module_default.destructive700BackgroundColor;
12
+ case "destructive-secondary":
13
+ return _D24RSGYPjs.colors_module_default.destructive100BackgroundColor;
14
+ case "success":
15
+ return _D24RSGYPjs.colors_module_default.success700BackgroundColor;
16
+ case "tertiary":
17
+ case "destructive-tertiary":
18
+ return _D24RSGYPjs.colors_module_default.whiteBackgroundColor;
19
+ case "branded":
20
+ return _D24RSGYPjs.colors_module_default.yellow700BackgroundColor;
21
+ case "inverse":
22
+ return _D24RSGYPjs.colors_module_default.gray60BackgroundColor;
23
+ default:
24
+ return _D24RSGYPjs.colors_module_default.primary700BackgroundColor;
25
+ }
26
+ }
27
+
28
+
29
+
30
+ exports.backgroundColor = backgroundColor;
31
+ //# sourceMappingURL=G4DDTGDI.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/colors/backgroundColor.ts"],"names":[],"mappings":";;;;;AAGe,SAAR,gBAAiC,OAAuC;AAC7E,UAAQ,OAAO;AAAA,IACb,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB,KAAK;AAAA,IACL,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB,KAAK;AACH,aAAO,sBAAO;AAAA,IAChB;AACE,aAAO,sBAAO;AAAA,EAClB;AACF","sourcesContent":["import { type Color } from \"../constants\";\nimport styles from \"./colors.module.css\";\n\nexport default function backgroundColor(color: (typeof Color)[number]): string {\n switch (color) {\n case \"secondary\":\n return styles.primary100BackgroundColor;\n case \"destructive-primary\":\n return styles.destructive700BackgroundColor;\n case \"destructive-secondary\":\n return styles.destructive100BackgroundColor;\n case \"success\":\n return styles.success700BackgroundColor;\n case \"tertiary\":\n case \"destructive-tertiary\":\n return styles.whiteBackgroundColor;\n case \"branded\":\n return styles.yellow700BackgroundColor;\n case \"inverse\":\n return styles.gray60BackgroundColor;\n default:\n return styles.primary700BackgroundColor;\n }\n}\n"]}
@@ -0,0 +1,120 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
2
+
3
+ var _SAEVPDUPjs = require('./SAEVPDUP.js');
4
+
5
+
6
+ var _5DBWL6IKjs = require('./5DBWL6IK.js');
7
+
8
+
9
+ var _4PWSK5GIjs = require('./4PWSK5GI.js');
10
+
11
+
12
+ var _PYNS67IVjs = require('./PYNS67IV.js');
13
+
14
+
15
+ var _F3ZST4RLjs = require('./F3ZST4RL.js');
16
+
17
+
18
+ var _YJ7YDIGBjs = require('./YJ7YDIGB.js');
19
+
20
+
21
+ var _HQVZUEWOjs = require('./HQVZUEWO.js');
22
+
23
+
24
+ var _CATJI2RJjs = require('./CATJI2RJ.js');
25
+
26
+
27
+ var _G4DDTGDIjs = require('./G4DDTGDI.js');
28
+
29
+ // src/Button/Button.tsx
30
+ var _react = require('react');
31
+ var _classnames = require('classnames'); var _classnames2 = _interopRequireDefault(_classnames);
32
+
33
+ // css-module:./Button.module.css#css-module
34
+ var Button_module_default = { "button": "_button_1iunh_1", "buttonGap": "_buttonGap_1iunh_9", "fullWidth": "_fullWidth_1iunh_50", "sm": "_sm_1iunh_54", "md": "_md_1iunh_61", "lg": "_lg_1iunh_68", "icon": "_icon_1iunh_75", "smIcon": "_smIcon_1iunh_79", "mdIcon": "_mdIcon_1iunh_86", "lgIcon": "_lgIcon_1iunh_93", "secondaryBorder": "_secondaryBorder_1iunh_100", "secondaryDestructiveBorder": "_secondaryDestructiveBorder_1iunh_104", "loading": "_loading_1iunh_118", "syntaxButtonLoadingRotate": "_syntaxButtonLoadingRotate_1iunh_1", "loadingCircle": "_loadingCircle_1iunh_122" };
35
+
36
+ // src/Button/Button.tsx
37
+ var _jsxruntime = require('react/jsx-runtime');
38
+ var Button = _react.forwardRef.call(void 0,
39
+ ({
40
+ "data-testid": dataTestId,
41
+ text,
42
+ loadingText,
43
+ color = "primary",
44
+ size = "md",
45
+ accessibilityLabel,
46
+ disabled = false,
47
+ loading = false,
48
+ fullWidth = false,
49
+ startIcon: StartIcon,
50
+ endIcon: EndIcon,
51
+ onClick,
52
+ tooltip,
53
+ type = "button"
54
+ }, ref) => {
55
+ const isHydrated = _YJ7YDIGBjs.useIsHydrated.call(void 0, );
56
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
57
+ "button",
58
+ {
59
+ "data-testid": dataTestId,
60
+ ref,
61
+ "aria-label": accessibilityLabel,
62
+ type,
63
+ title: tooltip,
64
+ disabled: !isHydrated || disabled || loading,
65
+ onClick,
66
+ className: _classnames2.default.call(void 0,
67
+ Button_module_default.button,
68
+ _CATJI2RJjs.foregroundColor.call(void 0, color),
69
+ _G4DDTGDIjs.backgroundColor.call(void 0, color),
70
+ Button_module_default[size],
71
+ {
72
+ [Button_module_default.fullWidth]: fullWidth,
73
+ [Button_module_default.buttonGap]: size === "lg" || size === "md",
74
+ [Button_module_default.secondaryBorder]: color === "secondary",
75
+ [Button_module_default.secondaryDestructiveBorder]: color === "destructive-secondary"
76
+ }
77
+ ),
78
+ children: [
79
+ !loading && StartIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StartIcon, { className: _classnames2.default.call(void 0, Button_module_default.icon, _4PWSK5GIjs.iconSize_default[size]) }),
80
+ (loading && loadingText || !loading && text) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _PYNS67IVjs.Box_default, { paddingX: 1, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
81
+ _F3ZST4RLjs.Typography_default,
82
+ {
83
+ size: _5DBWL6IKjs.textVariant_default[size],
84
+ color: _HQVZUEWOjs.foregroundTypographyColor.call(void 0, color),
85
+ children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { style: { fontWeight: 500 }, children: loading ? loadingText : text })
86
+ }
87
+ ) }),
88
+ !loading && EndIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, EndIcon, { className: _classnames2.default.call(void 0, Button_module_default.icon, _4PWSK5GIjs.iconSize_default[size]) }),
89
+ loading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
90
+ "svg",
91
+ {
92
+ className: _classnames2.default.call(void 0, Button_module_default.loading, _CATJI2RJjs.foregroundColor.call(void 0, color)),
93
+ viewBox: "22 22 44 44",
94
+ width: _SAEVPDUPjs.loadingIconSize_default[size],
95
+ height: _SAEVPDUPjs.loadingIconSize_default[size],
96
+ children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
97
+ "circle",
98
+ {
99
+ className: Button_module_default.loadingCircle,
100
+ cx: "44",
101
+ cy: "44",
102
+ r: "20.2",
103
+ fill: "none",
104
+ strokeWidth: "3.6"
105
+ }
106
+ )
107
+ }
108
+ )
109
+ ]
110
+ }
111
+ );
112
+ }
113
+ );
114
+ Button.displayName = "Button";
115
+ var Button_default = Button;
116
+
117
+
118
+
119
+ exports.Button_default = Button_default;
120
+ //# sourceMappingURL=GPS2XNQI.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/Button/Button.tsx","css-module:./Button.module.css#css-module"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,SAAgB,kBAAkB;AAClC,OAAO,gBAAgB;;;ACDqE,IAAO,wBAAQ,EAAC,UAAS,mBAAkB,aAAY,sBAAqB,aAAY,uBAAsB,MAAK,gBAAe,MAAK,gBAAe,MAAK,gBAAe,QAAO,kBAAiB,UAAS,oBAAmB,UAAS,oBAAmB,UAAS,oBAAmB,mBAAkB,8BAA6B,8BAA6B,yCAAwC,WAAU,sBAAqB,6BAA4B,sCAAqC,iBAAgB,2BAA0B;;;AD4H1mB,SAuBI,KAvBJ;AAvBN,IAAM,SAAS;AAAA,EACb,CACE;AAAA,IACE,eAAe;AAAA,IACf;AAAA,IACA;AAAA,IACA,QAAQ;AAAA,IACR,OAAO;AAAA,IACP;AAAA,IACA,WAAW;AAAA,IACX,UAAU;AAAA,IACV,YAAY;AAAA,IACZ,WAAW;AAAA,IACX,SAAS;AAAA,IACT;AAAA,IACA;AAAA,IACA,OAAO;AAAA,EACT,GACA,QACG;AACH,UAAM,aAAa,cAAc;AAEjC,WACE;AAAA,MAAC;AAAA;AAAA,QACC,eAAa;AAAA,QACb;AAAA,QACA,cAAY;AAAA,QACZ;AAAA,QACA,OAAO;AAAA,QACP,UAAU,CAAC,cAAc,YAAY;AAAA,QACrC;AAAA,QACA,WAAW;AAAA,UACT,sBAAO;AAAA,UACP,gBAAgB,KAAK;AAAA,UACrB,gBAAgB,KAAK;AAAA,UACrB,sBAAO,IAAI;AAAA,UACX;AAAA,YACE,CAAC,sBAAO,SAAS,GAAG;AAAA,YACpB,CAAC,sBAAO,SAAS,GAAG,SAAS,QAAQ,SAAS;AAAA,YAC9C,CAAC,sBAAO,eAAe,GAAG,UAAU;AAAA,YACpC,CAAC,sBAAO,0BAA0B,GAChC,UAAU;AAAA,UACd;AAAA,QACF;AAAA,QAEC;AAAA,WAAC,WAAW,aACX,oBAAC,aAAU,WAAW,WAAW,sBAAO,MAAM,iBAAS,IAAI,CAAC,GAAG;AAAA,WAE9D,WAAW,eAAiB,CAAC,WAAW,SACzC,oBAAC,eAAI,UAAU,GACb;AAAA,YAAC;AAAA;AAAA,cACC,MAAM,oBAAY,IAAI;AAAA,cACtB,OAAO,0BAA0B,KAAK;AAAA,cAEtC,8BAAC,UAAK,OAAO,EAAE,YAAY,IAAI,GAC5B,oBAAU,cAAc,MAC3B;AAAA;AAAA,UACF,GACF;AAAA,UAED,CAAC,WAAW,WACX,oBAAC,WAAQ,WAAW,WAAW,sBAAO,MAAM,iBAAS,IAAI,CAAC,GAAG;AAAA,UAE9D,WACC;AAAA,YAAC;AAAA;AAAA,cACC,WAAW,WAAW,sBAAO,SAAS,gBAAgB,KAAK,CAAC;AAAA,cAC5D,SAAQ;AAAA,cACR,OAAO,wBAAgB,IAAI;AAAA,cAC3B,QAAQ,wBAAgB,IAAI;AAAA,cAE5B;AAAA,gBAAC;AAAA;AAAA,kBACC,WAAW,sBAAO;AAAA,kBAClB,IAAG;AAAA,kBACH,IAAG;AAAA,kBACH,GAAE;AAAA,kBACF,MAAK;AAAA,kBACL,aAAY;AAAA;AAAA,cACd;AAAA;AAAA,UACF;AAAA;AAAA;AAAA,IAEJ;AAAA,EAEJ;AACF;AAEA,OAAO,cAAc;AAErB,IAAO,iBAAQ","sourcesContent":["import React, { forwardRef } from \"react\";\nimport classNames from \"classnames\";\n\nimport backgroundColor from \"../colors//backgroundColor\";\nimport foregroundColor from \"../colors/foregroundColor\";\nimport foregroundTypographyColor from \"../colors/foregroundTypographyColor\";\nimport { type Size } from \"../constants\";\nimport Typography from \"../Typography/Typography\";\nimport Box from \"../Box/Box\";\n\nimport iconSize from \"./constants/iconSize\";\nimport textVariant from \"./constants/textVariant\";\nimport loadingIconSize from \"./constants/loadingIconSize\";\nimport styles from \"./Button.module.css\";\nimport useIsHydrated from \"../useIsHydrated\";\n\ntype ButtonProps = {\n /**\n * Test id for the button\n */\n \"data-testid\"?: string;\n /**\n * The text to be displayed inside the button\n */\n text: string;\n /**\n * The text to be displayed inside the button when it is in a loading state\n */\n loadingText?: string;\n /**\n * The color of the button\n *\n * @defaultValue \"primary\"\n */\n color?:\n | \"primary\"\n | \"secondary\"\n | \"tertiary\"\n | \"destructive-primary\"\n | \"destructive-secondary\"\n | \"destructive-tertiary\"\n | \"branded\"\n | \"success\"\n | \"inverse\";\n /**\n * The size of the button\n *\n * * `sm`: 32px\n * * `md`: 40px\n * * `lg`: 48px\n *\n * @defaultValue \"md\"\n */\n size?: (typeof Size)[number];\n /**\n * The label to be used for accessibility\n */\n accessibilityLabel?: string;\n /**\n * If `true`, the button will be disabled\n *\n * @defaultValue false\n */\n disabled?: boolean;\n /**\n * If `true`, the button will be in a loading state\n *\n * @defaultValue false\n */\n loading?: boolean;\n /**\n * If `true`, the button will take up the full width of its container\n *\n * @defaultValue false\n */\n fullWidth?: boolean;\n /**\n * The icon to be displayed at the start of the button. Please use a [Rounded Material Icon](https://material.io/resources/icons/?style=round)\n */\n startIcon?: React.ComponentType<{ className?: string }>;\n /**\n * The icon to be displayed at the end of the button. Please use a [Rounded Material Icon](https://material.io/resources/icons/?style=round)\n */\n endIcon?: React.ComponentType<{ className?: string }>;\n /**\n * The callback to be called when the button is clicked\n */\n onClick?: React.MouseEventHandler<HTMLButtonElement>;\n /**\n * The tooltip to be displayed when the user hovers over the button\n */\n tooltip?: string;\n /**\n * The type you want to set for the primitive <button/>\n */\n type?: \"button\" | \"submit\" | \"reset\";\n};\n\n/**\n * [Button](https://cambly-syntax.vercel.app/?path=/docs/components-button--docs) is used to trigger an action or event, such as submitting a form, opening a dialog, canceling an action, or performing a delete operation.\n */\nconst Button = forwardRef<HTMLButtonElement, ButtonProps>(\n (\n {\n \"data-testid\": dataTestId,\n text,\n loadingText,\n color = \"primary\",\n size = \"md\",\n accessibilityLabel,\n disabled = false,\n loading = false,\n fullWidth = false,\n startIcon: StartIcon,\n endIcon: EndIcon,\n onClick,\n tooltip,\n type = \"button\",\n }: ButtonProps,\n ref,\n ) => {\n const isHydrated = useIsHydrated();\n\n return (\n <button\n data-testid={dataTestId}\n ref={ref}\n aria-label={accessibilityLabel}\n type={type}\n title={tooltip}\n disabled={!isHydrated || disabled || loading}\n onClick={onClick}\n className={classNames(\n styles.button,\n foregroundColor(color),\n backgroundColor(color),\n styles[size],\n {\n [styles.fullWidth]: fullWidth,\n [styles.buttonGap]: size === \"lg\" || size === \"md\",\n [styles.secondaryBorder]: color === \"secondary\",\n [styles.secondaryDestructiveBorder]:\n color === \"destructive-secondary\",\n },\n )}\n >\n {!loading && StartIcon && (\n <StartIcon className={classNames(styles.icon, iconSize[size])} />\n )}\n {((loading && loadingText) || (!loading && text)) && (\n <Box paddingX={1}>\n <Typography\n size={textVariant[size]}\n color={foregroundTypographyColor(color)}\n >\n <span style={{ fontWeight: 500 }}>\n {loading ? loadingText : text}\n </span>\n </Typography>\n </Box>\n )}\n {!loading && EndIcon && (\n <EndIcon className={classNames(styles.icon, iconSize[size])} />\n )}\n {loading && (\n <svg\n className={classNames(styles.loading, foregroundColor(color))}\n viewBox=\"22 22 44 44\"\n width={loadingIconSize[size]}\n height={loadingIconSize[size]}\n >\n <circle\n className={styles.loadingCircle}\n cx=\"44\"\n cy=\"44\"\n r=\"20.2\"\n fill=\"none\"\n strokeWidth=\"3.6\"\n />\n </svg>\n )}\n </button>\n );\n },\n);\n\nButton.displayName = \"Button\";\n\nexport default Button;\n","import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/Button/Button.module.css\"; export default {\"button\":\"_button_1iunh_1\",\"buttonGap\":\"_buttonGap_1iunh_9\",\"fullWidth\":\"_fullWidth_1iunh_50\",\"sm\":\"_sm_1iunh_54\",\"md\":\"_md_1iunh_61\",\"lg\":\"_lg_1iunh_68\",\"icon\":\"_icon_1iunh_75\",\"smIcon\":\"_smIcon_1iunh_79\",\"mdIcon\":\"_mdIcon_1iunh_86\",\"lgIcon\":\"_lgIcon_1iunh_93\",\"secondaryBorder\":\"_secondaryBorder_1iunh_100\",\"secondaryDestructiveBorder\":\"_secondaryDestructiveBorder_1iunh_104\",\"loading\":\"_loading_1iunh_118\",\"syntaxButtonLoadingRotate\":\"_syntaxButtonLoadingRotate_1iunh_1\",\"loadingCircle\":\"_loadingCircle_1iunh_122\"}"]}
@@ -0,0 +1,14 @@
1
+ // src/SelectList/SelectOption.tsx
2
+ import { jsx } from "react/jsx-runtime";
3
+ var SelectOption = ({
4
+ "data-testid": dataTestId,
5
+ value,
6
+ label,
7
+ disabled = false
8
+ }) => /* @__PURE__ */ jsx("option", { "data-testid": dataTestId, value, disabled, children: label });
9
+ var SelectOption_default = SelectOption;
10
+
11
+ export {
12
+ SelectOption_default
13
+ };
14
+ //# sourceMappingURL=GVNDZZAU.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/SelectList/SelectOption.tsx"],"sourcesContent":["import React, { type ReactElement } from \"react\";\n\nconst SelectOption = ({\n \"data-testid\": dataTestId,\n value,\n label,\n disabled = false,\n}: {\n \"data-testid\"?: string;\n value: string;\n label: string;\n disabled?: boolean;\n}): ReactElement => (\n <option data-testid={dataTestId} value={value} disabled={disabled}>\n {label}\n </option>\n);\n\nexport default SelectOption;\n"],"mappings":";AAaE;AAXF,IAAM,eAAe,CAAC;AAAA,EACpB,eAAe;AAAA,EACf;AAAA,EACA;AAAA,EACA,WAAW;AACb,MAME,oBAAC,YAAO,eAAa,YAAY,OAAc,UAC5C,iBACH;AAGF,IAAO,uBAAQ;","names":[]}
@@ -0,0 +1,28 @@
1
+ // css-module:./ButtonGroup.module.css#css-module
2
+ var ButtonGroup_module_default = { "buttonGroup": "_buttonGroup_1f9x9_1", "horizontal": "_horizontal_1f9x9_5", "vertical": "_vertical_1f9x9_9", "smallGap": "_smallGap_1f9x9_13", "mediumGap": "_mediumGap_1f9x9_17", "largeGap": "_largeGap_1f9x9_21" };
3
+
4
+ // src/ButtonGroup/ButtonGroup.tsx
5
+ import classNames from "classnames";
6
+ import { jsx } from "react/jsx-runtime";
7
+ var gap = {
8
+ ["sm"]: ButtonGroup_module_default.smallGap,
9
+ ["md"]: ButtonGroup_module_default.mediumGap,
10
+ ["lg"]: ButtonGroup_module_default.largeGap
11
+ };
12
+ var ButtonGroup = ({
13
+ orientation = "horizontal",
14
+ size = "md",
15
+ children
16
+ }) => {
17
+ const classnames = classNames(ButtonGroup_module_default.buttonGroup, gap[size], {
18
+ [ButtonGroup_module_default.horizontal]: orientation === "horizontal",
19
+ [ButtonGroup_module_default.vertical]: orientation === "vertical"
20
+ });
21
+ return /* @__PURE__ */ jsx("div", { className: classnames, children });
22
+ };
23
+ var ButtonGroup_default = ButtonGroup;
24
+
25
+ export {
26
+ ButtonGroup_default
27
+ };
28
+ //# sourceMappingURL=HAZN2FCY.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["css-module:./ButtonGroup.module.css#css-module","../../src/ButtonGroup/ButtonGroup.tsx"],"sourcesContent":["import \"/home/runner/work/syntax/syntax/packages/syntax-core/src/ButtonGroup/ButtonGroup.module.css\"; export default {\"buttonGroup\":\"_buttonGroup_1f9x9_1\",\"horizontal\":\"_horizontal_1f9x9_5\",\"vertical\":\"_vertical_1f9x9_9\",\"smallGap\":\"_smallGap_1f9x9_13\",\"mediumGap\":\"_mediumGap_1f9x9_17\",\"largeGap\":\"_largeGap_1f9x9_21\"}","import { type ReactElement, type ReactNode } from \"react\";\nimport styles from \"./ButtonGroup.module.css\";\nimport { type Size } from \"../constants\";\nimport classNames from \"classnames\";\n\nconst gap = {\n [\"sm\"]: styles.smallGap,\n [\"md\"]: styles.mediumGap,\n [\"lg\"]: styles.largeGap,\n} as const;\n\n/**\n * [ButtonGroup](https://cambly-syntax.vercel.app/?path=/docs/components-buttongroup--docs) groups buttons in a row or column with consistent spacing between each button.\n */\nconst ButtonGroup = ({\n orientation = \"horizontal\",\n size = \"md\",\n children,\n}: {\n /**\n * The orientation of the button group\n *\n * @defaultValue \"horizontal\"\n */\n orientation?: \"horizontal\" | \"vertical\";\n /**\n * The size of the button group defines the spacing between each button\n *\n * * `sm`: 8px\n * * `md`: 12px\n * * `lg`: 16px\n *\n * @defaultValue \"md\"\n */\n size?: (typeof Size)[number];\n /**\n * Buttons to be rendered inside the button group\n */\n children?: ReactNode;\n}): ReactElement => {\n const classnames = classNames(styles.buttonGroup, gap[size], {\n [styles.horizontal]: orientation === \"horizontal\",\n [styles.vertical]: orientation === \"vertical\",\n });\n\n return <div className={classnames}>{children}</div>;\n};\n\nexport default ButtonGroup;\n"],"mappings":";AAAsG,IAAO,6BAAQ,EAAC,eAAc,wBAAuB,cAAa,uBAAsB,YAAW,qBAAoB,YAAW,sBAAqB,aAAY,uBAAsB,YAAW,qBAAoB;;;ACG9T,OAAO,gBAAgB;AA0Cd;AAxCT,IAAM,MAAM;AAAA,EACV,CAAC,IAAI,GAAG,2BAAO;AAAA,EACf,CAAC,IAAI,GAAG,2BAAO;AAAA,EACf,CAAC,IAAI,GAAG,2BAAO;AACjB;AAKA,IAAM,cAAc,CAAC;AAAA,EACnB,cAAc;AAAA,EACd,OAAO;AAAA,EACP;AACF,MAqBoB;AAClB,QAAM,aAAa,WAAW,2BAAO,aAAa,IAAI,IAAI,GAAG;AAAA,IAC3D,CAAC,2BAAO,UAAU,GAAG,gBAAgB;AAAA,IACrC,CAAC,2BAAO,QAAQ,GAAG,gBAAgB;AAAA,EACrC,CAAC;AAED,SAAO,oBAAC,SAAI,WAAW,YAAa,UAAS;AAC/C;AAEA,IAAO,sBAAQ;","names":[]}