@cocso-ui/react 0.2.20 → 1.0.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 (353) hide show
  1. package/README.md +2 -2
  2. package/dist/cjs/cn.d.ts +12 -0
  3. package/dist/cjs/cn.js +17 -0
  4. package/dist/cjs/components/accordion/accordion.d.ts +25 -0
  5. package/dist/cjs/components/accordion/accordion.js +54 -0
  6. package/dist/cjs/components/accordion/accordion.module.css.js +9 -0
  7. package/dist/cjs/components/alert/alert.d.ts +15 -0
  8. package/dist/cjs/components/alert/alert.js +44 -0
  9. package/dist/cjs/components/alert/alert.module.css.js +9 -0
  10. package/dist/cjs/components/avatar/avatar.d.ts +18 -0
  11. package/dist/cjs/components/avatar/avatar.js +52 -0
  12. package/dist/cjs/components/avatar/avatar.module.css.js +9 -0
  13. package/dist/cjs/components/badge/badge.d.ts +16 -0
  14. package/dist/cjs/components/badge/badge.js +60 -0
  15. package/dist/cjs/components/badge/badge.module.css.js +9 -0
  16. package/dist/cjs/components/breadcrumb/breadcrumb.d.ts +14 -0
  17. package/dist/cjs/components/breadcrumb/breadcrumb.js +50 -0
  18. package/dist/cjs/components/breadcrumb/breadcrumb.module.css.js +9 -0
  19. package/dist/cjs/components/button/button.d.ts +27 -0
  20. package/dist/cjs/components/button/button.js +83 -0
  21. package/dist/cjs/components/button/button.module.css.js +9 -0
  22. package/dist/cjs/components/card/card.d.ts +13 -0
  23. package/dist/cjs/components/card/card.js +30 -0
  24. package/dist/cjs/components/card/card.module.css.js +9 -0
  25. package/dist/cjs/components/checkbox/checkbox.d.ts +20 -0
  26. package/dist/cjs/components/checkbox/checkbox.js +116 -0
  27. package/dist/cjs/components/checkbox/checkbox.module.css.js +9 -0
  28. package/dist/cjs/components/day-picker/day-picker.d.ts +18 -0
  29. package/dist/cjs/components/day-picker/day-picker.js +117 -0
  30. package/dist/cjs/components/day-picker/day-picker.module.css.js +9 -0
  31. package/dist/cjs/components/dialog/dialog.d.ts +29 -0
  32. package/dist/cjs/components/dialog/dialog.js +103 -0
  33. package/dist/cjs/components/dialog/dialog.module.css.js +9 -0
  34. package/dist/cjs/components/dropdown/dropdown.d.ts +16 -0
  35. package/dist/cjs/components/dropdown/dropdown.js +43 -0
  36. package/dist/cjs/components/dropdown/dropdown.module.css.js +9 -0
  37. package/dist/cjs/components/field/field.d.ts +26 -0
  38. package/dist/cjs/components/field/field.js +49 -0
  39. package/dist/cjs/components/field/field.module.css.js +9 -0
  40. package/dist/cjs/components/input/input.d.ts +17 -0
  41. package/dist/cjs/components/input/input.js +69 -0
  42. package/dist/cjs/components/input/input.module.css.js +9 -0
  43. package/dist/cjs/components/link/link.d.ts +28 -0
  44. package/dist/cjs/components/link/link.js +64 -0
  45. package/dist/cjs/components/link/link.module.css.js +9 -0
  46. package/dist/cjs/components/month-picker/month-picker.d.ts +18 -0
  47. package/dist/cjs/components/month-picker/month-picker.js +108 -0
  48. package/dist/cjs/components/month-picker/month-picker.module.css.js +9 -0
  49. package/dist/cjs/components/one-time-password-field/one-time-password-field.d.ts +13 -0
  50. package/dist/cjs/components/one-time-password-field/one-time-password-field.js +44 -0
  51. package/dist/cjs/components/one-time-password-field/one-time-password-field.module.css.js +9 -0
  52. package/dist/cjs/components/pagination/pagination.d.ts +21 -0
  53. package/dist/cjs/{pagination/Pagination.js → components/pagination/pagination.js} +35 -20
  54. package/dist/cjs/components/pagination/pagination.module.css.js +9 -0
  55. package/dist/cjs/components/popover/popover.d.ts +14 -0
  56. package/dist/cjs/components/popover/popover.js +47 -0
  57. package/dist/cjs/components/popover/popover.module.css.js +9 -0
  58. package/dist/cjs/components/progress/progress.d.ts +17 -0
  59. package/dist/cjs/components/progress/progress.js +43 -0
  60. package/dist/cjs/components/progress/progress.module.css.js +9 -0
  61. package/dist/cjs/components/radio-group/radio-group.d.ts +23 -0
  62. package/dist/cjs/components/radio-group/radio-group.js +53 -0
  63. package/dist/cjs/components/radio-group/radio-group.module.css.js +9 -0
  64. package/dist/cjs/components/select/select.d.ts +17 -0
  65. package/dist/cjs/components/select/select.js +85 -0
  66. package/dist/cjs/components/select/select.module.css.js +9 -0
  67. package/dist/cjs/components/skeleton/skeleton.d.ts +15 -0
  68. package/dist/cjs/components/skeleton/skeleton.js +30 -0
  69. package/dist/cjs/components/skeleton/skeleton.module.css.js +9 -0
  70. package/dist/cjs/components/spinner/spinner.d.ts +17 -0
  71. package/dist/cjs/components/spinner/spinner.js +70 -0
  72. package/dist/cjs/components/spinner/spinner.module.css.js +9 -0
  73. package/dist/cjs/components/stock-quantity-status/stock-quantity-status.d.ts +12 -0
  74. package/dist/cjs/components/stock-quantity-status/stock-quantity-status.js +119 -0
  75. package/dist/cjs/components/stock-quantity-status/stock-quantity-status.module.css.js +9 -0
  76. package/dist/cjs/components/switch/switch.d.ts +19 -0
  77. package/dist/cjs/components/switch/switch.js +74 -0
  78. package/dist/cjs/components/switch/switch.module.css.js +9 -0
  79. package/dist/cjs/components/tab/tab.d.ts +16 -0
  80. package/dist/cjs/components/tab/tab.js +33 -0
  81. package/dist/cjs/components/tooltip/tooltip.d.ts +17 -0
  82. package/dist/cjs/components/tooltip/tooltip.js +48 -0
  83. package/dist/cjs/components/tooltip/tooltip.module.css.js +9 -0
  84. package/dist/cjs/components/typography/typography.d.ts +30 -0
  85. package/dist/cjs/components/typography/typography.js +81 -0
  86. package/dist/cjs/components/typography/typography.module.css.js +9 -0
  87. package/dist/cjs/ecosystem/codegen/generated/alert.css.js +6 -0
  88. package/dist/cjs/ecosystem/codegen/generated/alert.js +12 -0
  89. package/dist/cjs/ecosystem/codegen/generated/avatar.css.js +6 -0
  90. package/dist/cjs/ecosystem/codegen/generated/avatar.js +13 -0
  91. package/dist/cjs/ecosystem/codegen/generated/badge.css.js +6 -0
  92. package/dist/cjs/ecosystem/codegen/generated/badge.js +14 -0
  93. package/dist/cjs/ecosystem/codegen/generated/breadcrumb.css.js +6 -0
  94. package/dist/cjs/ecosystem/codegen/generated/breadcrumb.js +12 -0
  95. package/dist/cjs/ecosystem/codegen/generated/button.css.js +6 -0
  96. package/dist/cjs/ecosystem/codegen/generated/button.js +14 -0
  97. package/dist/cjs/ecosystem/codegen/generated/card.css.js +6 -0
  98. package/dist/cjs/ecosystem/codegen/generated/card.js +13 -0
  99. package/dist/cjs/ecosystem/codegen/generated/checkbox.css.js +6 -0
  100. package/dist/cjs/ecosystem/codegen/generated/checkbox.js +13 -0
  101. package/dist/cjs/ecosystem/codegen/generated/input.css.js +6 -0
  102. package/dist/cjs/ecosystem/codegen/generated/input.js +12 -0
  103. package/dist/cjs/ecosystem/codegen/generated/link.css.js +6 -0
  104. package/dist/cjs/ecosystem/codegen/generated/link.js +12 -0
  105. package/dist/cjs/ecosystem/codegen/generated/progress.css.js +6 -0
  106. package/dist/cjs/ecosystem/codegen/generated/progress.js +13 -0
  107. package/dist/cjs/ecosystem/codegen/generated/radio.css.js +6 -0
  108. package/dist/cjs/ecosystem/codegen/generated/radio.js +13 -0
  109. package/dist/cjs/ecosystem/codegen/generated/select.css.js +6 -0
  110. package/dist/cjs/ecosystem/codegen/generated/select.js +12 -0
  111. package/dist/cjs/ecosystem/codegen/generated/skeleton.css.js +6 -0
  112. package/dist/cjs/ecosystem/codegen/generated/skeleton.js +13 -0
  113. package/dist/cjs/ecosystem/codegen/generated/spinner-geometry.js +33 -0
  114. package/dist/cjs/ecosystem/codegen/generated/spinner.css.js +6 -0
  115. package/dist/cjs/ecosystem/codegen/generated/spinner.js +13 -0
  116. package/dist/cjs/ecosystem/codegen/generated/stock-quantity-status.css.js +6 -0
  117. package/dist/cjs/ecosystem/codegen/generated/stock-quantity-status.js +12 -0
  118. package/dist/cjs/ecosystem/codegen/generated/switch.css.js +6 -0
  119. package/dist/cjs/ecosystem/codegen/generated/switch.js +14 -0
  120. package/dist/cjs/index.d.ts +30 -19
  121. package/dist/cjs/index.js +65 -43
  122. package/dist/cjs/token/color.d.ts +12 -0
  123. package/dist/cjs/token/color.js +93 -81
  124. package/dist/cjs/token/radius.d.ts +12 -0
  125. package/dist/cjs/token/radius.js +14 -0
  126. package/dist/cjs/token/spacing.d.ts +24 -23
  127. package/dist/cjs/token/spacing.js +24 -23
  128. package/dist/cjs/token/typography.d.ts +17 -0
  129. package/dist/cjs/token/typography.js +17 -6
  130. package/dist/esm/cn.d.mts +12 -0
  131. package/dist/esm/cn.mjs +15 -0
  132. package/dist/esm/components/accordion/accordion.d.mts +25 -0
  133. package/dist/esm/components/accordion/accordion.mjs +52 -0
  134. package/dist/esm/components/accordion/accordion.module.css.mjs +3 -0
  135. package/dist/esm/components/alert/alert.d.mts +15 -0
  136. package/dist/esm/components/alert/alert.mjs +41 -0
  137. package/dist/esm/components/alert/alert.module.css.mjs +3 -0
  138. package/dist/esm/components/avatar/avatar.d.mts +18 -0
  139. package/dist/esm/components/avatar/avatar.mjs +49 -0
  140. package/dist/esm/components/avatar/avatar.module.css.mjs +3 -0
  141. package/dist/esm/components/badge/badge.d.mts +16 -0
  142. package/dist/esm/components/badge/badge.mjs +57 -0
  143. package/dist/esm/components/badge/badge.module.css.mjs +3 -0
  144. package/dist/esm/components/breadcrumb/breadcrumb.d.mts +14 -0
  145. package/dist/esm/components/breadcrumb/breadcrumb.mjs +47 -0
  146. package/dist/esm/components/breadcrumb/breadcrumb.module.css.mjs +3 -0
  147. package/dist/esm/components/button/button.d.mts +27 -0
  148. package/dist/esm/components/button/button.mjs +80 -0
  149. package/dist/esm/components/button/button.module.css.mjs +3 -0
  150. package/dist/esm/components/card/card.d.mts +13 -0
  151. package/dist/esm/components/card/card.mjs +27 -0
  152. package/dist/esm/components/card/card.module.css.mjs +3 -0
  153. package/dist/esm/components/checkbox/checkbox.d.mts +20 -0
  154. package/dist/esm/components/checkbox/checkbox.mjs +113 -0
  155. package/dist/esm/components/checkbox/checkbox.module.css.mjs +3 -0
  156. package/dist/esm/components/day-picker/day-picker.d.mts +18 -0
  157. package/dist/esm/components/day-picker/day-picker.mjs +115 -0
  158. package/dist/esm/components/day-picker/day-picker.module.css.mjs +3 -0
  159. package/dist/esm/components/dialog/dialog.d.mts +29 -0
  160. package/dist/esm/components/dialog/dialog.mjs +101 -0
  161. package/dist/esm/components/dialog/dialog.module.css.mjs +3 -0
  162. package/dist/esm/components/dropdown/dropdown.d.mts +16 -0
  163. package/dist/esm/components/dropdown/dropdown.mjs +41 -0
  164. package/dist/esm/components/dropdown/dropdown.module.css.mjs +3 -0
  165. package/dist/esm/components/field/field.d.mts +26 -0
  166. package/dist/esm/components/field/field.mjs +46 -0
  167. package/dist/esm/components/field/field.module.css.mjs +3 -0
  168. package/dist/esm/components/input/input.d.mts +17 -0
  169. package/dist/esm/components/input/input.mjs +66 -0
  170. package/dist/esm/components/input/input.module.css.mjs +3 -0
  171. package/dist/esm/components/link/link.d.mts +28 -0
  172. package/dist/esm/components/link/link.mjs +61 -0
  173. package/dist/esm/components/link/link.module.css.mjs +3 -0
  174. package/dist/esm/components/month-picker/month-picker.d.mts +18 -0
  175. package/dist/esm/components/month-picker/month-picker.mjs +106 -0
  176. package/dist/esm/components/month-picker/month-picker.module.css.mjs +3 -0
  177. package/dist/esm/components/one-time-password-field/one-time-password-field.d.mts +13 -0
  178. package/dist/esm/components/one-time-password-field/one-time-password-field.mjs +42 -0
  179. package/dist/esm/components/one-time-password-field/one-time-password-field.module.css.mjs +3 -0
  180. package/dist/esm/components/pagination/pagination.d.mts +21 -0
  181. package/dist/esm/{pagination/Pagination.mjs → components/pagination/pagination.mjs} +30 -15
  182. package/dist/esm/components/pagination/pagination.module.css.mjs +3 -0
  183. package/dist/esm/components/popover/popover.d.mts +14 -0
  184. package/dist/esm/components/popover/popover.mjs +45 -0
  185. package/dist/esm/components/popover/popover.module.css.mjs +3 -0
  186. package/dist/esm/components/progress/progress.d.mts +17 -0
  187. package/dist/esm/components/progress/progress.mjs +40 -0
  188. package/dist/esm/components/progress/progress.module.css.mjs +3 -0
  189. package/dist/esm/components/radio-group/radio-group.d.mts +23 -0
  190. package/dist/esm/components/radio-group/radio-group.mjs +50 -0
  191. package/dist/esm/components/radio-group/radio-group.module.css.mjs +3 -0
  192. package/dist/esm/components/select/select.d.mts +17 -0
  193. package/dist/esm/components/select/select.mjs +82 -0
  194. package/dist/esm/components/select/select.module.css.mjs +3 -0
  195. package/dist/esm/components/skeleton/skeleton.d.mts +15 -0
  196. package/dist/esm/components/skeleton/skeleton.mjs +27 -0
  197. package/dist/esm/components/skeleton/skeleton.module.css.mjs +3 -0
  198. package/dist/esm/components/spinner/spinner.d.mts +17 -0
  199. package/dist/esm/components/spinner/spinner.mjs +67 -0
  200. package/dist/esm/components/spinner/spinner.module.css.mjs +3 -0
  201. package/dist/esm/components/stock-quantity-status/stock-quantity-status.d.mts +12 -0
  202. package/dist/esm/components/stock-quantity-status/stock-quantity-status.mjs +116 -0
  203. package/dist/esm/components/stock-quantity-status/stock-quantity-status.module.css.mjs +3 -0
  204. package/dist/esm/components/switch/switch.d.mts +19 -0
  205. package/dist/esm/components/switch/switch.mjs +71 -0
  206. package/dist/esm/components/switch/switch.module.css.mjs +3 -0
  207. package/dist/esm/components/tab/tab.d.mts +16 -0
  208. package/dist/esm/components/tab/tab.mjs +31 -0
  209. package/dist/esm/components/tooltip/tooltip.d.mts +17 -0
  210. package/dist/esm/components/tooltip/tooltip.mjs +46 -0
  211. package/dist/esm/components/tooltip/tooltip.module.css.mjs +3 -0
  212. package/dist/esm/components/typography/typography.d.mts +30 -0
  213. package/dist/esm/components/typography/typography.mjs +79 -0
  214. package/dist/esm/components/typography/typography.module.css.mjs +3 -0
  215. package/dist/esm/ecosystem/codegen/generated/alert.mjs +10 -0
  216. package/dist/esm/ecosystem/codegen/generated/avatar.mjs +11 -0
  217. package/dist/esm/ecosystem/codegen/generated/badge.mjs +12 -0
  218. package/dist/esm/ecosystem/codegen/generated/breadcrumb.mjs +10 -0
  219. package/dist/esm/ecosystem/codegen/generated/button.mjs +12 -0
  220. package/dist/esm/ecosystem/codegen/generated/card.mjs +11 -0
  221. package/dist/esm/ecosystem/codegen/generated/checkbox.mjs +11 -0
  222. package/dist/esm/ecosystem/codegen/generated/input.mjs +10 -0
  223. package/dist/esm/ecosystem/codegen/generated/link.mjs +10 -0
  224. package/dist/esm/ecosystem/codegen/generated/progress.mjs +11 -0
  225. package/dist/esm/ecosystem/codegen/generated/radio.mjs +11 -0
  226. package/dist/esm/ecosystem/codegen/generated/select.mjs +10 -0
  227. package/dist/esm/ecosystem/codegen/generated/skeleton.mjs +11 -0
  228. package/dist/esm/ecosystem/codegen/generated/spinner-geometry.mjs +30 -0
  229. package/dist/esm/ecosystem/codegen/generated/spinner.mjs +11 -0
  230. package/dist/esm/ecosystem/codegen/generated/stock-quantity-status.mjs +10 -0
  231. package/dist/esm/ecosystem/codegen/generated/switch.mjs +12 -0
  232. package/dist/esm/index.css +7 -1
  233. package/dist/esm/index.d.mts +30 -19
  234. package/dist/esm/index.mjs +31 -20
  235. package/dist/esm/token/color.d.mts +12 -0
  236. package/dist/esm/token/color.mjs +93 -81
  237. package/dist/esm/token/radius.d.mts +12 -0
  238. package/dist/esm/token/radius.mjs +12 -0
  239. package/dist/esm/token/spacing.d.mts +24 -23
  240. package/dist/esm/token/spacing.mjs +24 -23
  241. package/dist/esm/token/typography.d.mts +17 -0
  242. package/dist/esm/token/typography.mjs +17 -6
  243. package/package.json +29 -26
  244. package/dist/cjs/accordion/Accordion.d.ts +0 -15
  245. package/dist/cjs/accordion/Accordion.js +0 -71
  246. package/dist/cjs/accordion/Accordion.module.css.js +0 -9
  247. package/dist/cjs/badge/Badge.d.ts +0 -13
  248. package/dist/cjs/badge/Badge.js +0 -50
  249. package/dist/cjs/badge/Badge.module.css.js +0 -9
  250. package/dist/cjs/button/Button.d.ts +0 -23
  251. package/dist/cjs/button/Button.js +0 -117
  252. package/dist/cjs/button/Button.module.css.js +0 -9
  253. package/dist/cjs/checkbox/Checkbox.d.ts +0 -18
  254. package/dist/cjs/checkbox/Checkbox.js +0 -117
  255. package/dist/cjs/checkbox/Checkbox.module.css.js +0 -9
  256. package/dist/cjs/day-picker/DayPicker.d.ts +0 -14
  257. package/dist/cjs/day-picker/DayPicker.js +0 -98
  258. package/dist/cjs/day-picker/DayPicker.module.css.js +0 -9
  259. package/dist/cjs/dropdown/Dropdown.d.ts +0 -11
  260. package/dist/cjs/dropdown/Dropdown.js +0 -55
  261. package/dist/cjs/dropdown/Dropdown.module.css.js +0 -9
  262. package/dist/cjs/link/Link.d.ts +0 -16
  263. package/dist/cjs/link/Link.js +0 -35
  264. package/dist/cjs/link/Link.module.css.js +0 -9
  265. package/dist/cjs/modal/Modal.d.ts +0 -12
  266. package/dist/cjs/modal/Modal.js +0 -106
  267. package/dist/cjs/modal/Modal.module.css.js +0 -9
  268. package/dist/cjs/month-picker/MonthPicker.d.ts +0 -14
  269. package/dist/cjs/month-picker/MonthPicker.js +0 -91
  270. package/dist/cjs/month-picker/MonthPicker.module.css.js +0 -9
  271. package/dist/cjs/one-time-password-field/OneTimePasswordField.d.ts +0 -8
  272. package/dist/cjs/one-time-password-field/OneTimePasswordField.js +0 -52
  273. package/dist/cjs/one-time-password-field/OneTimePasswordField.module.css.js +0 -9
  274. package/dist/cjs/pagination/Pagination.d.ts +0 -13
  275. package/dist/cjs/pagination/Pagination.module.css.js +0 -9
  276. package/dist/cjs/popover/Popover.d.ts +0 -10
  277. package/dist/cjs/popover/Popover.js +0 -44
  278. package/dist/cjs/popover/Popover.module.css.js +0 -9
  279. package/dist/cjs/radio-group/RadioGroup.d.ts +0 -9
  280. package/dist/cjs/radio-group/RadioGroup.js +0 -66
  281. package/dist/cjs/radio-group/RadioGroup.module.css.js +0 -9
  282. package/dist/cjs/select/Select.d.ts +0 -13
  283. package/dist/cjs/select/Select.js +0 -85
  284. package/dist/cjs/select/Select.module.css.js +0 -9
  285. package/dist/cjs/spinner/Spinner.d.ts +0 -14
  286. package/dist/cjs/spinner/Spinner.js +0 -40
  287. package/dist/cjs/spinner/Spinner.module.css.js +0 -9
  288. package/dist/cjs/stock-quantity-status/StockQuantityStatus.d.ts +0 -12
  289. package/dist/cjs/stock-quantity-status/StockQuantityStatus.js +0 -105
  290. package/dist/cjs/stock-quantity-status/StockQuantityStatus.module.css.js +0 -9
  291. package/dist/cjs/switch/Switch.d.ts +0 -16
  292. package/dist/cjs/switch/Switch.js +0 -89
  293. package/dist/cjs/switch/Switch.module.css.js +0 -9
  294. package/dist/cjs/tab/Tab.d.ts +0 -10
  295. package/dist/cjs/tab/Tab.js +0 -64
  296. package/dist/cjs/typography/Typography.d.ts +0 -33
  297. package/dist/cjs/typography/Typography.js +0 -90
  298. package/dist/cjs/typography/Typography.module.css.js +0 -9
  299. package/dist/esm/accordion/Accordion.d.mts +0 -15
  300. package/dist/esm/accordion/Accordion.mjs +0 -50
  301. package/dist/esm/accordion/Accordion.module.css.mjs +0 -3
  302. package/dist/esm/badge/Badge.d.mts +0 -13
  303. package/dist/esm/badge/Badge.mjs +0 -48
  304. package/dist/esm/badge/Badge.module.css.mjs +0 -3
  305. package/dist/esm/button/Button.d.mts +0 -23
  306. package/dist/esm/button/Button.mjs +0 -115
  307. package/dist/esm/button/Button.module.css.mjs +0 -3
  308. package/dist/esm/checkbox/Checkbox.d.mts +0 -18
  309. package/dist/esm/checkbox/Checkbox.mjs +0 -96
  310. package/dist/esm/checkbox/Checkbox.module.css.mjs +0 -3
  311. package/dist/esm/day-picker/DayPicker.d.mts +0 -14
  312. package/dist/esm/day-picker/DayPicker.mjs +0 -96
  313. package/dist/esm/day-picker/DayPicker.module.css.mjs +0 -3
  314. package/dist/esm/dropdown/Dropdown.d.mts +0 -11
  315. package/dist/esm/dropdown/Dropdown.mjs +0 -34
  316. package/dist/esm/dropdown/Dropdown.module.css.mjs +0 -3
  317. package/dist/esm/link/Link.d.mts +0 -16
  318. package/dist/esm/link/Link.mjs +0 -33
  319. package/dist/esm/link/Link.module.css.mjs +0 -3
  320. package/dist/esm/modal/Modal.d.mts +0 -12
  321. package/dist/esm/modal/Modal.mjs +0 -85
  322. package/dist/esm/modal/Modal.module.css.mjs +0 -3
  323. package/dist/esm/month-picker/MonthPicker.d.mts +0 -14
  324. package/dist/esm/month-picker/MonthPicker.mjs +0 -89
  325. package/dist/esm/month-picker/MonthPicker.module.css.mjs +0 -3
  326. package/dist/esm/one-time-password-field/OneTimePasswordField.d.mts +0 -8
  327. package/dist/esm/one-time-password-field/OneTimePasswordField.mjs +0 -31
  328. package/dist/esm/one-time-password-field/OneTimePasswordField.module.css.mjs +0 -3
  329. package/dist/esm/pagination/Pagination.d.mts +0 -13
  330. package/dist/esm/pagination/Pagination.module.css.mjs +0 -3
  331. package/dist/esm/popover/Popover.d.mts +0 -10
  332. package/dist/esm/popover/Popover.mjs +0 -23
  333. package/dist/esm/popover/Popover.module.css.mjs +0 -3
  334. package/dist/esm/radio-group/RadioGroup.d.mts +0 -9
  335. package/dist/esm/radio-group/RadioGroup.mjs +0 -45
  336. package/dist/esm/radio-group/RadioGroup.module.css.mjs +0 -3
  337. package/dist/esm/select/Select.d.mts +0 -13
  338. package/dist/esm/select/Select.mjs +0 -83
  339. package/dist/esm/select/Select.module.css.mjs +0 -3
  340. package/dist/esm/spinner/Spinner.d.mts +0 -14
  341. package/dist/esm/spinner/Spinner.mjs +0 -38
  342. package/dist/esm/spinner/Spinner.module.css.mjs +0 -3
  343. package/dist/esm/stock-quantity-status/StockQuantityStatus.d.mts +0 -12
  344. package/dist/esm/stock-quantity-status/StockQuantityStatus.mjs +0 -102
  345. package/dist/esm/stock-quantity-status/StockQuantityStatus.module.css.mjs +0 -3
  346. package/dist/esm/switch/Switch.d.mts +0 -16
  347. package/dist/esm/switch/Switch.mjs +0 -68
  348. package/dist/esm/switch/Switch.module.css.mjs +0 -3
  349. package/dist/esm/tab/Tab.d.mts +0 -10
  350. package/dist/esm/tab/Tab.mjs +0 -43
  351. package/dist/esm/typography/Typography.d.mts +0 -33
  352. package/dist/esm/typography/Typography.mjs +0 -88
  353. package/dist/esm/typography/Typography.module.css.mjs +0 -3
@@ -1,23 +0,0 @@
1
- import * as react from 'react';
2
- import { ComponentPropsWithoutRef, ReactNode } from 'react';
3
- import { FontWeight } from '../token/typography.mjs';
4
-
5
- type ButtonSize = 'xl' | 'lg' | 'md' | 'sm' | 'xs';
6
- type ButtonVariant = 'primary' | 'secondary' | 'tertiary' | 'success' | 'error' | 'warning' | 'neutral';
7
- type ButtonShape = 'square' | 'circle' | 'rounded';
8
- interface ButtonProps extends Omit<ComponentPropsWithoutRef<'button'>, 'prefix'> {
9
- asChild?: boolean;
10
- size?: ButtonSize;
11
- variant?: ButtonVariant;
12
- weight?: FontWeight;
13
- shape?: ButtonShape;
14
- prefix?: ReactNode;
15
- suffix?: ReactNode;
16
- svgOnly?: boolean;
17
- disabled?: boolean;
18
- loading?: boolean;
19
- }
20
- declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
21
-
22
- export { Button };
23
- export type { ButtonProps, ButtonShape, ButtonSize, ButtonVariant };
@@ -1,115 +0,0 @@
1
- import { Primitive } from '@radix-ui/react-primitive';
2
- import { clsx } from 'clsx';
3
- import { forwardRef, isValidElement, cloneElement } from 'react';
4
- import { match } from 'ts-pattern';
5
- import styles from './Button.module.css.mjs';
6
- import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
7
- import { Spinner } from '../spinner/Spinner.mjs';
8
- import { fontWeight } from '../token/typography.mjs';
9
- import { colors } from '../token/color.mjs';
10
-
11
- const Button = /*#__PURE__*/forwardRef(({
12
- asChild,
13
- className,
14
- style: _style,
15
- children,
16
- size = 'md',
17
- variant = 'primary',
18
- weight = 'medium',
19
- shape = 'square',
20
- prefix,
21
- suffix,
22
- svgOnly = false,
23
- disabled = false,
24
- loading = false,
25
- ...props
26
- }, ref) => {
27
- const style = {
28
- ..._style,
29
- ...getSizeStyles(size),
30
- '--cocso-button-font-color': getColor(variant),
31
- '--cocso-button-font-weight': fontWeight[weight],
32
- '--cocso-button-border': getBorder(variant),
33
- '--cocso-button-border-radius': getBorderRadius(shape, size),
34
- '--cocso-button-bg-color': getBackgroundColor(variant),
35
- '--cocso-button-bg-color-hover': getBackgroundColorHover(variant),
36
- '--cocso-button-bg-color-active': getBackgroundColorActive(variant)
37
- };
38
- const isDisabled = disabled || loading;
39
- const cn = clsx(styles.button, isDisabled && styles.disabled, svgOnly && styles.svgOnly, className);
40
- const renderButtonContent = ctx => /*#__PURE__*/jsxs(Fragment, {
41
- children: [loading && /*#__PURE__*/jsx(Spinner, {
42
- size: "sm",
43
- color: "white"
44
- }), prefix && /*#__PURE__*/jsx("span", {
45
- className: styles.prefix,
46
- children: prefix
47
- }), /*#__PURE__*/jsx("span", {
48
- className: styles.content,
49
- children: ctx
50
- }), suffix && /*#__PURE__*/jsx("span", {
51
- className: styles.suffix,
52
- children: suffix
53
- })]
54
- });
55
- if (asChild) {
56
- if (! /*#__PURE__*/isValidElement(children)) {
57
- throw new Error('Button: asChild requires a single React element as a child');
58
- }
59
- const target = children;
60
- const ctx = target.props.children;
61
- return /*#__PURE__*/cloneElement(target, {
62
- ref,
63
- ...props,
64
- ...target.props,
65
- className: clsx(cn, target.props.className),
66
- style: {
67
- ...style,
68
- ...target.props.style
69
- },
70
- children: renderButtonContent(ctx)
71
- });
72
- }
73
- return /*#__PURE__*/jsx(Primitive.button, {
74
- ref: ref,
75
- className: cn,
76
- disabled: isDisabled,
77
- style: style,
78
- ...props,
79
- children: renderButtonContent(children)
80
- });
81
- });
82
- const getSizeStyles = size => {
83
- const height = match(size).with('xl', () => 56).with('lg', () => 48).with('md', () => 40).with('sm', () => 32).with('xs', () => 28).exhaustive();
84
- const inlinePadding = match(size).with('xl', () => 16).with('lg', () => 14).with('md', () => 10).with('sm', () => 8).with('xs', () => 6).exhaustive();
85
- const contentPadding = match(size).with('xl', () => '0 6px').with('lg', () => '0 6px').with('md', () => '0 6px').with('sm', () => '0 2px').with('xs', () => '0').exhaustive();
86
- const fontSize = match(size).with('xl', () => 16).with('lg', () => 16).with('xs', () => 12).otherwise(() => 14);
87
- return {
88
- '--cocso-button-height': `${height}px`,
89
- '--cocso-button-padding-inline': `${inlinePadding}px`,
90
- '--cocso-button-content-padding': contentPadding,
91
- '--cocso-button-font-size': `${fontSize}px`
92
- };
93
- };
94
- const getBorderRadius = (shape, size) => {
95
- return match(shape).with('square', () => {
96
- return match(size).with('xs', () => '4px').otherwise(() => '6px');
97
- }).with('circle', () => '100%').with('rounded', () => '100px').exhaustive();
98
- };
99
- const getColor = variant => {
100
- return match(variant).with('primary', 'success', 'error', 'neutral', () => colors.white).with('secondary', 'tertiary', 'warning', () => colors.neutral950).exhaustive();
101
- };
102
- const getBorder = variant => {
103
- return match(variant).with('tertiary', () => `1px solid ${colors.neutral100}`).otherwise(() => 'none');
104
- };
105
- const getBackgroundColor = variant => {
106
- return match(variant).with('primary', () => colors.primary500).with('secondary', () => colors.white).with('tertiary', () => colors.transparent).with('success', () => colors.success500).with('error', () => colors.danger500).with('warning', () => colors.warning300).with('neutral', () => colors.neutral950).exhaustive();
107
- };
108
- const getBackgroundColorHover = variant => {
109
- return match(variant).with('primary', () => colors.primary600).with('secondary', () => colors.neutral50).with('tertiary', () => colors.neutral50).with('success', () => colors.success600).with('error', () => colors.danger600).with('warning', () => colors.warning400).with('neutral', () => colors.neutral800).exhaustive();
110
- };
111
- const getBackgroundColorActive = variant => {
112
- return match(variant).with('primary', () => colors.primary700).with('secondary', () => colors.neutral100).with('tertiary', () => colors.neutral100).with('success', () => colors.success700).with('error', () => colors.danger700).with('warning', () => colors.warning500).with('neutral', () => colors.neutral700).exhaustive();
113
- };
114
-
115
- export { Button };
@@ -1,3 +0,0 @@
1
- var styles = {"button":"Button-module_button__eiKKZ","disabled":"Button-module_disabled__M6r1w","content":"Button-module_content__SVjwi","prefix":"Button-module_prefix__d7ljt","suffix":"Button-module_suffix__9oysT","svgOnly":"Button-module_svgOnly__8RcZ7"};
2
-
3
- export { styles as default };
@@ -1,18 +0,0 @@
1
- import * as react from 'react';
2
- import { ComponentPropsWithoutRef } from 'react';
3
- import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
4
-
5
- type CheckboxSize = 'lg' | 'md' | 'sm';
6
- type CheckboxStatus = 'on' | 'off' | 'intermediate';
7
- interface CheckboxProps extends Omit<ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root>, 'checked' | 'onCheckedChange' | 'onChange'> {
8
- id?: string;
9
- size?: CheckboxSize;
10
- status: CheckboxStatus;
11
- onChange: (status: CheckboxStatus) => void;
12
- label?: string;
13
- disabled?: boolean;
14
- }
15
- declare const Checkbox: react.ForwardRefExoticComponent<CheckboxProps & react.RefAttributes<HTMLButtonElement>>;
16
-
17
- export { Checkbox };
18
- export type { CheckboxProps, CheckboxSize, CheckboxStatus };
@@ -1,96 +0,0 @@
1
- import { CheckIcon } from '@cocso-ui/react-icons';
2
- import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
3
- import { clsx } from 'clsx';
4
- import { forwardRef, useId } from 'react';
5
- import { match } from 'ts-pattern';
6
- import styles from './Checkbox.module.css.mjs';
7
- import { jsxs, jsx } from 'react/jsx-runtime';
8
- import { spacing } from '../token/spacing.mjs';
9
- import { colors } from '../token/color.mjs';
10
- import { Typography } from '../typography/Typography.mjs';
11
-
12
- const Checkbox = /*#__PURE__*/forwardRef(({
13
- id: _id,
14
- className,
15
- style: _style,
16
- size = 'md',
17
- status,
18
- onChange,
19
- label,
20
- disabled,
21
- ...props
22
- }, ref) => {
23
- const generatedId = useId();
24
- const id = _id ?? generatedId;
25
- const handleCheckedChange = checked => {
26
- if (!disabled) {
27
- const nextStatus = match(checked).with(true, () => 'on').with('indeterminate', () => 'intermediate').with(false, () => 'off').exhaustive();
28
- onChange(nextStatus);
29
- }
30
- };
31
- const getCheckedState = () => {
32
- return match(status).with('on', () => true).with('intermediate', () => 'indeterminate').with('off', () => false).exhaustive();
33
- };
34
- const style = {
35
- ..._style,
36
- '--cocso-checkbox-size': getSize(size),
37
- '--cocso-checkbox-color': colors.white,
38
- '--cocso-checkbox-border-color': getBorderColor(status),
39
- '--cocso-checkbox-bg-color': getBackgroundColor(status)
40
- };
41
- return /*#__PURE__*/jsxs("div", {
42
- className: clsx(styles.wrapper, className),
43
- style: style,
44
- children: [/*#__PURE__*/jsxs(CheckboxPrimitive.Root, {
45
- ref: ref,
46
- id: id,
47
- className: styles.checkbox,
48
- checked: getCheckedState(),
49
- onCheckedChange: handleCheckedChange,
50
- disabled: disabled,
51
- ...props,
52
- children: [/*#__PURE__*/jsx(CheckboxPrimitive.Indicator, {
53
- className: styles.indicator,
54
- style: {
55
- opacity: status === 'on' ? 1 : 0
56
- },
57
- "aria-hidden": "true",
58
- children: /*#__PURE__*/jsx(CheckIcon, {
59
- className: styles.icon,
60
- size: 24
61
- })
62
- }), /*#__PURE__*/jsx("div", {
63
- className: styles.indicator,
64
- style: {
65
- opacity: status === 'intermediate' ? 1 : 0
66
- },
67
- "aria-hidden": "true",
68
- children: /*#__PURE__*/jsx(CheckIcon, {
69
- className: styles.icon,
70
- size: 24
71
- })
72
- })]
73
- }), label && /*#__PURE__*/jsx(Typography, {
74
- type: "body",
75
- className: styles.label,
76
- size: size,
77
- "aria-disabled": disabled,
78
- asChild: true,
79
- children: /*#__PURE__*/jsx("label", {
80
- htmlFor: id,
81
- children: label
82
- })
83
- })]
84
- });
85
- });
86
- const getSize = size => {
87
- return match(size).with('lg', () => spacing.s10).with('md', () => spacing.s9).with('sm', () => spacing.s8).exhaustive();
88
- };
89
- const getBorderColor = status => {
90
- return match(status).with('on', () => colors.primary500).with('intermediate', () => colors.primary500).with('off', () => colors.neutral100).exhaustive();
91
- };
92
- const getBackgroundColor = status => {
93
- return match(status).with('on', () => colors.primary500).with('intermediate', () => colors.primary500).with('off', () => colors.white).exhaustive();
94
- };
95
-
96
- export { Checkbox };
@@ -1,3 +0,0 @@
1
- var styles = {"wrapper":"Checkbox-module_wrapper__5uqJp","checkbox":"Checkbox-module_checkbox__05Z5t","icon":"Checkbox-module_icon__hEcKq","indicator":"Checkbox-module_indicator__MLpNt","label":"Checkbox-module_label__ubb5U"};
2
-
3
- export { styles as default };
@@ -1,14 +0,0 @@
1
- import * as react from 'react';
2
- import { ComponentPropsWithoutRef } from 'react';
3
-
4
- interface DayPickerProps extends ComponentPropsWithoutRef<'div'> {
5
- value?: Date;
6
- onValueChange?: (value: Date | null) => void;
7
- minDate?: Date;
8
- maxDate?: Date;
9
- disabled?: boolean;
10
- }
11
- declare const DayPicker: react.ForwardRefExoticComponent<DayPickerProps & react.RefAttributes<HTMLDivElement>>;
12
-
13
- export { DayPicker };
14
- export type { DayPickerProps };
@@ -1,96 +0,0 @@
1
- "use client";
2
- import { ArrowIOSBackwardIcon, ArrowIOSForwardIcon } from '@cocso-ui/react-icons';
3
- import { clsx } from 'clsx';
4
- import { ko } from 'date-fns/locale';
5
- import { forwardRef, useState } from 'react';
6
- import DatePicker from 'react-datepicker';
7
- import styles from './DayPicker.module.css.mjs';
8
- import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
9
- import { Dropdown } from '../dropdown/Dropdown.mjs';
10
- import { Button } from '../button/Button.mjs';
11
- import { Typography } from '../typography/Typography.mjs';
12
-
13
- const DayPicker = /*#__PURE__*/forwardRef(({
14
- className,
15
- value,
16
- onValueChange,
17
- disabled,
18
- children,
19
- minDate,
20
- maxDate,
21
- ...props
22
- }, ref) => {
23
- const [open, setOpen] = useState(false);
24
- const handleChange = date => {
25
- onValueChange?.(date);
26
- setOpen(false);
27
- };
28
- return /*#__PURE__*/jsx("div", {
29
- ref: ref,
30
- className: clsx(styles.root, className),
31
- ...props,
32
- children: /*#__PURE__*/jsxs(Dropdown, {
33
- open: open,
34
- onOpenChange: setOpen,
35
- children: [/*#__PURE__*/jsx(Dropdown.Trigger, {
36
- asChild: true,
37
- children: children
38
- }), /*#__PURE__*/jsx(Dropdown.Portal, {
39
- children: /*#__PURE__*/jsx(Dropdown.Content, {
40
- className: styles.content,
41
- "aria-label": "\uB0A0\uC9DC \uC120\uD0DD",
42
- children: /*#__PURE__*/jsx(DatePicker, {
43
- selected: value,
44
- onChange: handleChange,
45
- disabled: disabled,
46
- locale: ko,
47
- minDate: minDate,
48
- maxDate: maxDate,
49
- dateFormat: "yyyy\uB144 MM\uC6D4 dd\uC77C",
50
- showPopperArrow: false,
51
- dayClassName: date => {
52
- const day = date.getDay();
53
- if (day === 0) return styles.sunday;
54
- if (day === 6) return styles.saturday;
55
- return '';
56
- },
57
- renderCustomHeader: ({
58
- date,
59
- decreaseMonth,
60
- increaseMonth,
61
- prevMonthButtonDisabled,
62
- nextMonthButtonDisabled
63
- }) => /*#__PURE__*/jsxs(Fragment, {
64
- children: [/*#__PURE__*/jsx(Button, {
65
- type: "button",
66
- variant: "secondary",
67
- size: "xs",
68
- onClick: decreaseMonth,
69
- disabled: prevMonthButtonDisabled,
70
- children: /*#__PURE__*/jsx(ArrowIOSBackwardIcon, {})
71
- }), /*#__PURE__*/jsx(Typography, {
72
- type: "body",
73
- weight: "semibold",
74
- children: date.toLocaleDateString('ko-KR', {
75
- year: 'numeric',
76
- month: 'long'
77
- })
78
- }), /*#__PURE__*/jsx(Button, {
79
- type: "button",
80
- variant: "secondary",
81
- size: "xs",
82
- onClick: increaseMonth,
83
- disabled: nextMonthButtonDisabled,
84
- children: /*#__PURE__*/jsx(ArrowIOSForwardIcon, {})
85
- })]
86
- }),
87
- inline: true
88
- })
89
- })
90
- })]
91
- })
92
- });
93
- });
94
- DayPicker.displayName = 'DayPicker';
95
-
96
- export { DayPicker };
@@ -1,3 +0,0 @@
1
- var styles = {"root":"DayPicker-module_root__lDrAw","content":"DayPicker-module_content__VVh4Y","sunday":"DayPicker-module_sunday__RaZuV","saturday":"DayPicker-module_saturday__e-AQO"};
2
-
3
- export { styles as default };
@@ -1,11 +0,0 @@
1
- import * as react from 'react';
2
- import * as DropdownPrimitive from '@radix-ui/react-dropdown-menu';
3
-
4
- declare const Dropdown: react.FC<DropdownPrimitive.DropdownMenuProps> & {
5
- Trigger: react.ForwardRefExoticComponent<DropdownPrimitive.DropdownMenuTriggerProps & react.RefAttributes<HTMLButtonElement>>;
6
- Portal: react.FC<DropdownPrimitive.DropdownMenuPortalProps>;
7
- Content: react.ForwardRefExoticComponent<Omit<Omit<DropdownPrimitive.DropdownMenuContentProps & react.RefAttributes<HTMLDivElement>, "ref">, "ref"> & react.RefAttributes<HTMLDivElement>>;
8
- Item: react.ForwardRefExoticComponent<Omit<DropdownPrimitive.DropdownMenuItemProps & react.RefAttributes<HTMLDivElement>, "ref"> & react.RefAttributes<HTMLDivElement>>;
9
- };
10
-
11
- export { Dropdown };
@@ -1,34 +0,0 @@
1
- import * as DropdownPrimitive from '@radix-ui/react-dropdown-menu';
2
- import { clsx } from 'clsx';
3
- import { forwardRef } from 'react';
4
- import styles from './Dropdown.module.css.mjs';
5
- import { jsx } from 'react/jsx-runtime';
6
-
7
- const DropdownContent = /*#__PURE__*/forwardRef(({
8
- className,
9
- ...props
10
- }, ref) => {
11
- return /*#__PURE__*/jsx(DropdownPrimitive.Content, {
12
- ref: ref,
13
- className: clsx(styles.content, className),
14
- ...props
15
- });
16
- });
17
- const DropdownItem = /*#__PURE__*/forwardRef(({
18
- className,
19
- ...props
20
- }, ref) => {
21
- return /*#__PURE__*/jsx(DropdownPrimitive.Item, {
22
- ref: ref,
23
- className: clsx(styles.item, className),
24
- ...props
25
- });
26
- });
27
- const Dropdown = Object.assign(DropdownPrimitive.Root, {
28
- Trigger: DropdownPrimitive.Trigger,
29
- Portal: DropdownPrimitive.Portal,
30
- Content: DropdownContent,
31
- Item: DropdownItem
32
- });
33
-
34
- export { Dropdown };
@@ -1,3 +0,0 @@
1
- var styles = {"content":"Dropdown-module_content__S3TRi","item":"Dropdown-module_item__MIltz"};
2
-
3
- export { styles as default };
@@ -1,16 +0,0 @@
1
- import * as react from 'react';
2
- import { ComponentPropsWithoutRef } from 'react';
3
- import { FontWeight, LineHeight } from '../token/typography.mjs';
4
-
5
- type LinkSize = 'lg' | 'md' | 'sm' | 'xs';
6
- interface LinkProps extends ComponentPropsWithoutRef<'a'> {
7
- asChild?: boolean;
8
- size?: LinkSize;
9
- weight?: FontWeight;
10
- lineHeight?: LineHeight;
11
- indicator?: boolean;
12
- }
13
- declare const Link: react.ForwardRefExoticComponent<LinkProps & react.RefAttributes<HTMLAnchorElement>>;
14
-
15
- export { Link };
16
- export type { LinkProps, LinkSize };
@@ -1,33 +0,0 @@
1
- import { Primitive } from '@radix-ui/react-primitive';
2
- import { Slot } from '@radix-ui/react-slot';
3
- import { clsx } from 'clsx';
4
- import { forwardRef } from 'react';
5
- import styles from './Link.module.css.mjs';
6
- import { jsx } from 'react/jsx-runtime';
7
- import { Typography } from '../typography/Typography.mjs';
8
-
9
- const Link = /*#__PURE__*/forwardRef(({
10
- asChild,
11
- className,
12
- size,
13
- weight,
14
- lineHeight,
15
- indicator = true,
16
- ...props
17
- }, ref) => {
18
- const Comp = asChild ? Slot : Primitive.a;
19
- return /*#__PURE__*/jsx(Typography, {
20
- type: "body",
21
- size: size,
22
- weight: weight,
23
- lineHeight: lineHeight,
24
- asChild: true,
25
- children: /*#__PURE__*/jsx(Comp, {
26
- ref: ref,
27
- className: clsx(styles.link, indicator && styles.indicator, className),
28
- ...props
29
- })
30
- });
31
- });
32
-
33
- export { Link };
@@ -1,3 +0,0 @@
1
- var styles = {"link":"Link-module_link__J9CFb","indicator":"Link-module_indicator__DIUaW"};
2
-
3
- export { styles as default };
@@ -1,12 +0,0 @@
1
- import * as react from 'react';
2
- import * as ModalPrimitive from '@radix-ui/react-dialog';
3
-
4
- declare const Modal: react.FC<ModalPrimitive.DialogProps> & {
5
- Trigger: react.ForwardRefExoticComponent<ModalPrimitive.DialogTriggerProps & react.RefAttributes<HTMLButtonElement>>;
6
- Content: react.ForwardRefExoticComponent<Omit<Omit<ModalPrimitive.DialogContentProps & react.RefAttributes<HTMLDivElement>, "ref">, "ref"> & react.RefAttributes<HTMLDivElement>>;
7
- Close: react.ForwardRefExoticComponent<Omit<ModalPrimitive.DialogCloseProps & react.RefAttributes<HTMLButtonElement>, "ref"> & react.RefAttributes<HTMLButtonElement>>;
8
- Title: react.ForwardRefExoticComponent<Omit<ModalPrimitive.DialogTitleProps & react.RefAttributes<HTMLHeadingElement>, "ref"> & react.RefAttributes<HTMLHeadingElement>>;
9
- Description: react.ForwardRefExoticComponent<Omit<ModalPrimitive.DialogDescriptionProps & react.RefAttributes<HTMLParagraphElement>, "ref"> & react.RefAttributes<HTMLParagraphElement>>;
10
- };
11
-
12
- export { Modal };
@@ -1,85 +0,0 @@
1
- import { CloseIcon } from '@cocso-ui/react-icons';
2
- import * as ModalPrimitive from '@radix-ui/react-dialog';
3
- import { clsx } from 'clsx';
4
- import { forwardRef } from 'react';
5
- import styles from './Modal.module.css.mjs';
6
- import { jsx, jsxs } from 'react/jsx-runtime';
7
- import { Typography } from '../typography/Typography.mjs';
8
- import { colors } from '../token/color.mjs';
9
-
10
- const ModalContent = /*#__PURE__*/forwardRef(({
11
- className,
12
- children,
13
- ...props
14
- }, ref) => {
15
- return /*#__PURE__*/jsxs(ModalPrimitive.Portal, {
16
- children: [/*#__PURE__*/jsx(ModalPrimitive.Overlay, {
17
- className: styles.overlay
18
- }), /*#__PURE__*/jsx(ModalPrimitive.Content, {
19
- ref: ref,
20
- className: clsx(styles.content, className),
21
- ...props,
22
- children: children
23
- })]
24
- });
25
- });
26
- const ModalClose = /*#__PURE__*/forwardRef(({
27
- asChild,
28
- className,
29
- children,
30
- ...props
31
- }, ref) => {
32
- return /*#__PURE__*/jsx(ModalPrimitive.Close, {
33
- ref: ref,
34
- className: clsx(!asChild && styles.close, className),
35
- asChild: asChild,
36
- ...props,
37
- children: asChild ? children : /*#__PURE__*/jsx(CloseIcon, {
38
- size: 24
39
- })
40
- });
41
- });
42
- const ModalTitle = /*#__PURE__*/forwardRef(({
43
- className,
44
- children,
45
- ...props
46
- }, ref) => {
47
- return /*#__PURE__*/jsx(ModalPrimitive.Title, {
48
- ref: ref,
49
- className: clsx(styles.title, className),
50
- asChild: true,
51
- ...props,
52
- children: /*#__PURE__*/jsx(Typography, {
53
- size: 20,
54
- weight: "bold",
55
- children: children
56
- })
57
- });
58
- });
59
- const ModalDescription = /*#__PURE__*/forwardRef(({
60
- className,
61
- children,
62
- ...props
63
- }, ref) => {
64
- return /*#__PURE__*/jsx(ModalPrimitive.Description, {
65
- ref: ref,
66
- className: clsx(styles.description, className),
67
- asChild: true,
68
- ...props,
69
- children: /*#__PURE__*/jsx(Typography, {
70
- size: 14,
71
- color: colors.textSecondary,
72
- weight: "medium",
73
- children: children
74
- })
75
- });
76
- });
77
- const Modal = Object.assign(ModalPrimitive.Root, {
78
- Trigger: ModalPrimitive.Trigger,
79
- Content: ModalContent,
80
- Close: ModalClose,
81
- Title: ModalTitle,
82
- Description: ModalDescription
83
- });
84
-
85
- export { Modal };
@@ -1,3 +0,0 @@
1
- var styles = {"overlay":"Modal-module_overlay__7ZBDB","content":"Modal-module_content__M1b6Q","close":"Modal-module_close__UbAF7","title":"Modal-module_title__oTluo","description":"Modal-module_description__RgMC5"};
2
-
3
- export { styles as default };
@@ -1,14 +0,0 @@
1
- import * as react from 'react';
2
- import { ComponentPropsWithoutRef } from 'react';
3
-
4
- interface MonthPickerProps extends ComponentPropsWithoutRef<'div'> {
5
- value?: Date;
6
- onValueChange?: (value: Date | null) => void;
7
- minDate?: Date;
8
- maxDate?: Date;
9
- disabled?: boolean;
10
- }
11
- declare const MonthPicker: react.ForwardRefExoticComponent<MonthPickerProps & react.RefAttributes<HTMLDivElement>>;
12
-
13
- export { MonthPicker };
14
- export type { MonthPickerProps };