@mdigital_ui/ui 0.3.0 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (471) hide show
  1. package/README.md +574 -994
  2. package/dist/accordion/index.d.ts +6 -0
  3. package/dist/accordion/index.d.ts.map +1 -0
  4. package/dist/accordion/index.js +1 -1
  5. package/dist/accordion/types.d.ts +125 -0
  6. package/dist/accordion/types.d.ts.map +1 -0
  7. package/dist/avatar/index.d.ts +14 -0
  8. package/dist/avatar/index.d.ts.map +1 -0
  9. package/dist/avatar/types.d.ts +147 -0
  10. package/dist/avatar/types.d.ts.map +1 -0
  11. package/dist/badge/index.d.ts +28 -0
  12. package/dist/badge/index.d.ts.map +1 -0
  13. package/dist/badge/index.js +1 -1
  14. package/dist/badge/types.d.ts +97 -0
  15. package/dist/badge/types.d.ts.map +1 -0
  16. package/dist/breadcrumbs/index.d.ts +13 -0
  17. package/dist/breadcrumbs/index.d.ts.map +1 -0
  18. package/dist/breadcrumbs/index.js +3 -3
  19. package/dist/breadcrumbs/types.d.ts +118 -0
  20. package/dist/breadcrumbs/types.d.ts.map +1 -0
  21. package/dist/button/index.d.ts +6 -0
  22. package/dist/button/index.d.ts.map +1 -0
  23. package/dist/button/index.js +1 -1
  24. package/dist/button/types.d.ts +86 -0
  25. package/dist/button/types.d.ts.map +1 -0
  26. package/dist/button-group/index.d.ts +34 -0
  27. package/dist/button-group/index.d.ts.map +1 -0
  28. package/dist/button-group/types.d.ts +75 -0
  29. package/dist/button-group/types.d.ts.map +1 -0
  30. package/dist/card/index.d.ts +71 -0
  31. package/dist/card/index.d.ts.map +1 -0
  32. package/dist/card/index.js +1 -1
  33. package/dist/card/types.d.ts +136 -0
  34. package/dist/card/types.d.ts.map +1 -0
  35. package/dist/carousel/carousel-navigation.d.ts +9 -0
  36. package/dist/carousel/carousel-navigation.d.ts.map +1 -0
  37. package/dist/carousel/index.d.ts +50 -0
  38. package/dist/carousel/index.d.ts.map +1 -0
  39. package/dist/carousel/index.js +1 -1
  40. package/dist/cascader/index.d.ts +27 -0
  41. package/dist/cascader/index.d.ts.map +1 -0
  42. package/dist/cascader/index.js +1 -1
  43. package/dist/cascader/types.d.ts +220 -0
  44. package/dist/cascader/types.d.ts.map +1 -0
  45. package/dist/checkbox/index.d.ts +6 -0
  46. package/dist/checkbox/index.d.ts.map +1 -0
  47. package/dist/checkbox/types.d.ts +21 -0
  48. package/dist/checkbox/types.d.ts.map +1 -0
  49. package/dist/checkbox-group/index.d.ts +6 -0
  50. package/dist/checkbox-group/index.d.ts.map +1 -0
  51. package/dist/checkbox-group/types.d.ts +43 -0
  52. package/dist/checkbox-group/types.d.ts.map +1 -0
  53. package/dist/{chunk-5JOJBDET.js → chunk-2K7MDR7K.js} +3 -3
  54. package/dist/chunk-2K7MDR7K.js.map +1 -0
  55. package/dist/{chunk-VY3X4SDU.js → chunk-2SYAIIJE.js} +3 -3
  56. package/dist/{chunk-VY3X4SDU.js.map → chunk-2SYAIIJE.js.map} +1 -1
  57. package/dist/{chunk-3HBMVZF5.js → chunk-623OVNLC.js} +4 -4
  58. package/dist/{chunk-3HBMVZF5.js.map → chunk-623OVNLC.js.map} +1 -1
  59. package/dist/{chunk-2NYVRAG4.js → chunk-6JGNJI5T.js} +2 -3
  60. package/dist/chunk-6JGNJI5T.js.map +1 -0
  61. package/dist/{chunk-UHVPOGNC.js → chunk-6QZFWSN7.js} +4 -4
  62. package/dist/chunk-6QZFWSN7.js.map +1 -0
  63. package/dist/{chunk-5VORB55Y.js → chunk-7P3Q6H2V.js} +3 -3
  64. package/dist/{chunk-5VORB55Y.js.map → chunk-7P3Q6H2V.js.map} +1 -1
  65. package/dist/{chunk-YWGWFGCY.js → chunk-BVO2BNFG.js} +129 -24
  66. package/dist/chunk-BVO2BNFG.js.map +1 -0
  67. package/dist/{chunk-CO766H7F.js → chunk-D53OQERO.js} +3 -4
  68. package/dist/chunk-D53OQERO.js.map +1 -0
  69. package/dist/{chunk-HWFI4GJE.js → chunk-DRCT6VZ7.js} +5 -5
  70. package/dist/{chunk-HWFI4GJE.js.map → chunk-DRCT6VZ7.js.map} +1 -1
  71. package/dist/{chunk-RPIJ2KY7.js → chunk-DUNER5Q3.js} +3 -3
  72. package/dist/{chunk-RPIJ2KY7.js.map → chunk-DUNER5Q3.js.map} +1 -1
  73. package/dist/{chunk-KTHWXHDN.js → chunk-E222IQHF.js} +3 -3
  74. package/dist/chunk-E222IQHF.js.map +1 -0
  75. package/dist/{chunk-CLLNXRYZ.js → chunk-GIWG6BCT.js} +26 -5
  76. package/dist/chunk-GIWG6BCT.js.map +1 -0
  77. package/dist/{chunk-FZLFCT6Q.js → chunk-HQVTIFXN.js} +4 -4
  78. package/dist/chunk-HQVTIFXN.js.map +1 -0
  79. package/dist/{chunk-Q57THXIU.js → chunk-HXPMYGSR.js} +16 -5
  80. package/dist/chunk-HXPMYGSR.js.map +1 -0
  81. package/dist/{chunk-OL2GU2O3.js → chunk-I75ZSXD6.js} +3 -3
  82. package/dist/{chunk-OL2GU2O3.js.map → chunk-I75ZSXD6.js.map} +1 -1
  83. package/dist/{chunk-XQJ6HZ4Q.js → chunk-I7MESP7F.js} +12 -12
  84. package/dist/chunk-I7MESP7F.js.map +1 -0
  85. package/dist/{chunk-UTKVWE76.js → chunk-ITCXCSUS.js} +7 -6
  86. package/dist/chunk-ITCXCSUS.js.map +1 -0
  87. package/dist/{chunk-7KA7JSRX.js → chunk-KJRKPYYZ.js} +88 -105
  88. package/dist/chunk-KJRKPYYZ.js.map +1 -0
  89. package/dist/{chunk-RZVEKAFR.js → chunk-M3AALH7G.js} +3 -3
  90. package/dist/chunk-M3AALH7G.js.map +1 -0
  91. package/dist/{chunk-HLY4VDIX.js → chunk-MBAZ7OW5.js} +7 -7
  92. package/dist/chunk-MBAZ7OW5.js.map +1 -0
  93. package/dist/{chunk-ILQQTKD4.js → chunk-MOQDO4XZ.js} +3 -3
  94. package/dist/chunk-MOQDO4XZ.js.map +1 -0
  95. package/dist/{chunk-L572AMB3.js → chunk-OKCKLIFP.js} +3 -3
  96. package/dist/{chunk-L572AMB3.js.map → chunk-OKCKLIFP.js.map} +1 -1
  97. package/dist/{chunk-J6IJBRYT.js → chunk-OSHJYIHC.js} +11 -11
  98. package/dist/{chunk-J6IJBRYT.js.map → chunk-OSHJYIHC.js.map} +1 -1
  99. package/dist/{chunk-ZRSSFP52.js → chunk-OV6K6GML.js} +3 -3
  100. package/dist/{chunk-ZRSSFP52.js.map → chunk-OV6K6GML.js.map} +1 -1
  101. package/dist/{chunk-4TQ4BZ3S.js → chunk-QC7XNMM7.js} +7 -7
  102. package/dist/chunk-QC7XNMM7.js.map +1 -0
  103. package/dist/{chunk-YTUB2Q7P.js → chunk-QLUGKHAA.js} +4 -5
  104. package/dist/chunk-QLUGKHAA.js.map +1 -0
  105. package/dist/{chunk-22MY7IWD.js → chunk-SJHNFRXG.js} +3 -3
  106. package/dist/{chunk-22MY7IWD.js.map → chunk-SJHNFRXG.js.map} +1 -1
  107. package/dist/{chunk-FJPMIXWU.js → chunk-SX5UNM6C.js} +3 -3
  108. package/dist/{chunk-FJPMIXWU.js.map → chunk-SX5UNM6C.js.map} +1 -1
  109. package/dist/{chunk-TBMY5EQC.js → chunk-TBH7QF26.js} +5 -4
  110. package/dist/chunk-TBH7QF26.js.map +1 -0
  111. package/dist/{chunk-HEV27FUK.js → chunk-UK4RHCMM.js} +3 -4
  112. package/dist/chunk-UK4RHCMM.js.map +1 -0
  113. package/dist/{chunk-2J57G7XG.js → chunk-UN3EW2PL.js} +13 -22
  114. package/dist/chunk-UN3EW2PL.js.map +1 -0
  115. package/dist/{chunk-ITZBSE5F.js → chunk-VKLDLJXG.js} +3 -3
  116. package/dist/chunk-VKLDLJXG.js.map +1 -0
  117. package/dist/{chunk-WUBMNJGC.js → chunk-VOODO2ZE.js} +64 -25
  118. package/dist/chunk-VOODO2ZE.js.map +1 -0
  119. package/dist/{chunk-FEMHXG2P.js → chunk-WAPZ4QAN.js} +3 -3
  120. package/dist/{chunk-FEMHXG2P.js.map → chunk-WAPZ4QAN.js.map} +1 -1
  121. package/dist/{chunk-KPM72QBO.js → chunk-X5XIBIEF.js} +4 -4
  122. package/dist/chunk-X5XIBIEF.js.map +1 -0
  123. package/dist/{chunk-IVOMN6DV.js → chunk-XHDUO3UW.js} +3 -4
  124. package/dist/chunk-XHDUO3UW.js.map +1 -0
  125. package/dist/{chunk-RW4RW4DV.js → chunk-XOIX5WIL.js} +5 -3
  126. package/dist/chunk-XOIX5WIL.js.map +1 -0
  127. package/dist/{chunk-CSRMVLPR.js → chunk-XWEI3MES.js} +32 -12
  128. package/dist/chunk-XWEI3MES.js.map +1 -0
  129. package/dist/{chunk-SAVEKACZ.js → chunk-YPHVSPWM.js} +4 -4
  130. package/dist/chunk-YPHVSPWM.js.map +1 -0
  131. package/dist/{chunk-ZFYEAPEL.js → chunk-ZHPYJTWP.js} +4 -4
  132. package/dist/{chunk-ZFYEAPEL.js.map → chunk-ZHPYJTWP.js.map} +1 -1
  133. package/dist/{chunk-DQQLJ5C5.js → chunk-ZPVBIQ2R.js} +3 -3
  134. package/dist/{chunk-DQQLJ5C5.js.map → chunk-ZPVBIQ2R.js.map} +1 -1
  135. package/dist/{chunk-WTGCXWNX.js → chunk-ZQTJBYKO.js} +3 -3
  136. package/dist/chunk-ZQTJBYKO.js.map +1 -0
  137. package/dist/{chunk-KPI7MN5V.js → chunk-ZSS6E4T2.js} +39 -14
  138. package/dist/chunk-ZSS6E4T2.js.map +1 -0
  139. package/dist/{chunk-N3ZVPIFC.js → chunk-ZYWDJMHF.js} +4 -4
  140. package/dist/chunk-ZYWDJMHF.js.map +1 -0
  141. package/dist/clipboard/index.d.ts +6 -0
  142. package/dist/clipboard/index.d.ts.map +1 -0
  143. package/dist/clipboard/index.js +1 -1
  144. package/dist/clipboard/types.d.ts +65 -0
  145. package/dist/clipboard/types.d.ts.map +1 -0
  146. package/dist/collapse/index.d.ts +6 -0
  147. package/dist/collapse/index.d.ts.map +1 -0
  148. package/dist/collapse/index.js +1 -1
  149. package/dist/collapse/types.d.ts +60 -0
  150. package/dist/collapse/types.d.ts.map +1 -0
  151. package/dist/command/index.d.ts +74 -0
  152. package/dist/command/index.d.ts.map +1 -0
  153. package/dist/command/index.js +2 -2
  154. package/dist/command/types.d.ts +24 -0
  155. package/dist/command/types.d.ts.map +1 -0
  156. package/dist/context-menu/index.d.ts +63 -0
  157. package/dist/context-menu/index.d.ts.map +1 -0
  158. package/dist/context-menu/index.js +1 -1
  159. package/dist/context-menu/types.d.ts +109 -0
  160. package/dist/context-menu/types.d.ts.map +1 -0
  161. package/dist/date-picker/index.d.ts +12 -0
  162. package/dist/date-picker/index.d.ts.map +1 -0
  163. package/dist/date-picker/index.js +2 -2
  164. package/dist/date-picker/types.d.ts +66 -0
  165. package/dist/date-picker/types.d.ts.map +1 -0
  166. package/dist/date-picker/utils.d.ts +10 -0
  167. package/dist/date-picker/utils.d.ts.map +1 -0
  168. package/dist/descriptions/index.d.ts +6 -0
  169. package/dist/descriptions/index.d.ts.map +1 -0
  170. package/dist/descriptions/index.js +1 -1
  171. package/dist/descriptions/types.d.ts +34 -0
  172. package/dist/descriptions/types.d.ts.map +1 -0
  173. package/dist/divider/index.d.ts +39 -0
  174. package/dist/divider/index.d.ts.map +1 -0
  175. package/dist/divider/index.js +1 -1
  176. package/dist/divider/types.d.ts +63 -0
  177. package/dist/divider/types.d.ts.map +1 -0
  178. package/dist/drawer/index.d.ts +23 -0
  179. package/dist/drawer/index.d.ts.map +1 -0
  180. package/dist/drawer/index.js +1 -1
  181. package/dist/drawer/types.d.ts +309 -0
  182. package/dist/drawer/types.d.ts.map +1 -0
  183. package/dist/dropdown/index.d.ts +6 -0
  184. package/dist/dropdown/index.d.ts.map +1 -0
  185. package/dist/dropdown/index.js +2 -2
  186. package/dist/dropdown/types.d.ts +116 -0
  187. package/dist/dropdown/types.d.ts.map +1 -0
  188. package/dist/empty/index.d.ts +6 -0
  189. package/dist/empty/index.d.ts.map +1 -0
  190. package/dist/empty/types.d.ts +62 -0
  191. package/dist/empty/types.d.ts.map +1 -0
  192. package/dist/fetching-overlay/index.d.ts +10 -0
  193. package/dist/fetching-overlay/index.d.ts.map +1 -0
  194. package/dist/fetching-overlay/index.js +1 -1
  195. package/dist/float-input/index.d.ts +6 -0
  196. package/dist/float-input/index.d.ts.map +1 -0
  197. package/dist/float-input/index.js +1 -1
  198. package/dist/float-input/types.d.ts +23 -0
  199. package/dist/float-input/types.d.ts.map +1 -0
  200. package/dist/form/index.d.ts +31 -0
  201. package/dist/form/index.d.ts.map +1 -0
  202. package/dist/form/types.d.ts +45 -0
  203. package/dist/form/types.d.ts.map +1 -0
  204. package/dist/grid/index.d.ts +6 -0
  205. package/dist/grid/index.d.ts.map +1 -0
  206. package/dist/grid/types.d.ts +21 -0
  207. package/dist/grid/types.d.ts.map +1 -0
  208. package/dist/image/index.d.ts +6 -0
  209. package/dist/image/index.d.ts.map +1 -0
  210. package/dist/image/index.js +1 -1
  211. package/dist/image/types.d.ts +53 -0
  212. package/dist/image/types.d.ts.map +1 -0
  213. package/dist/index.d.ts +139 -0
  214. package/dist/index.d.ts.map +1 -0
  215. package/dist/index.js +46 -46
  216. package/dist/input/index.d.ts +6 -0
  217. package/dist/input/index.d.ts.map +1 -0
  218. package/dist/input/index.js +1 -1
  219. package/dist/input/types.d.ts +28 -0
  220. package/dist/input/types.d.ts.map +1 -0
  221. package/dist/input-group/index.d.ts +9 -0
  222. package/dist/input-group/index.d.ts.map +1 -0
  223. package/dist/input-group/types.d.ts +68 -0
  224. package/dist/input-group/types.d.ts.map +1 -0
  225. package/dist/input-otp/index.d.ts +7 -0
  226. package/dist/input-otp/index.d.ts.map +1 -0
  227. package/dist/input-otp/index.js +1 -1
  228. package/dist/input-otp/types.d.ts +111 -0
  229. package/dist/input-otp/types.d.ts.map +1 -0
  230. package/dist/input-password/index.d.ts +7 -0
  231. package/dist/input-password/index.d.ts.map +1 -0
  232. package/dist/input-password/index.js +2 -2
  233. package/dist/input-password/types.d.ts +34 -0
  234. package/dist/input-password/types.d.ts.map +1 -0
  235. package/dist/kbd/index.d.ts +6 -0
  236. package/dist/kbd/index.d.ts.map +1 -0
  237. package/dist/kbd/types.d.ts +26 -0
  238. package/dist/kbd/types.d.ts.map +1 -0
  239. package/dist/link/index.d.ts +9 -0
  240. package/dist/link/index.d.ts.map +1 -0
  241. package/dist/link/types.d.ts +30 -0
  242. package/dist/link/types.d.ts.map +1 -0
  243. package/dist/menubar/index.d.ts +6 -0
  244. package/dist/menubar/index.d.ts.map +1 -0
  245. package/dist/menubar/index.js +2 -2
  246. package/dist/menubar/types.d.ts +40 -0
  247. package/dist/menubar/types.d.ts.map +1 -0
  248. package/dist/modal/index.d.ts +39 -0
  249. package/dist/modal/index.d.ts.map +1 -0
  250. package/dist/modal/index.js +1 -1
  251. package/dist/modal/types.d.ts +77 -0
  252. package/dist/modal/types.d.ts.map +1 -0
  253. package/dist/multi-select/index.d.ts +6 -0
  254. package/dist/multi-select/index.d.ts.map +1 -0
  255. package/dist/multi-select/index.js +2 -2
  256. package/dist/multi-select/types.d.ts +81 -0
  257. package/dist/multi-select/types.d.ts.map +1 -0
  258. package/dist/multi-select/utils.d.ts +12 -0
  259. package/dist/multi-select/utils.d.ts.map +1 -0
  260. package/dist/navigation-menu/index.d.ts +5 -0
  261. package/dist/navigation-menu/index.d.ts.map +1 -0
  262. package/dist/navigation-menu/index.js +1 -1
  263. package/dist/navigation-menu/types.d.ts +37 -0
  264. package/dist/navigation-menu/types.d.ts.map +1 -0
  265. package/dist/notification/index.d.ts +6 -0
  266. package/dist/notification/index.d.ts.map +1 -0
  267. package/dist/notification/index.js +1 -1
  268. package/dist/notification/types.d.ts +90 -0
  269. package/dist/notification/types.d.ts.map +1 -0
  270. package/dist/number-input/index.d.ts +6 -0
  271. package/dist/number-input/index.d.ts.map +1 -0
  272. package/dist/number-input/index.js +1 -1
  273. package/dist/number-input/types.d.ts +28 -0
  274. package/dist/number-input/types.d.ts.map +1 -0
  275. package/dist/pagination/index.d.ts +6 -0
  276. package/dist/pagination/index.d.ts.map +1 -0
  277. package/dist/pagination/index.js +1 -1
  278. package/dist/pagination/types.d.ts +87 -0
  279. package/dist/pagination/types.d.ts.map +1 -0
  280. package/dist/popover/index.d.ts +19 -0
  281. package/dist/popover/index.d.ts.map +1 -0
  282. package/dist/popover/index.js +1 -1
  283. package/dist/popover/types.d.ts +31 -0
  284. package/dist/popover/types.d.ts.map +1 -0
  285. package/dist/progress/index.d.ts +6 -0
  286. package/dist/progress/index.d.ts.map +1 -0
  287. package/dist/progress/index.js +1 -1
  288. package/dist/progress/types.d.ts +100 -0
  289. package/dist/progress/types.d.ts.map +1 -0
  290. package/dist/radio/index.d.ts +6 -0
  291. package/dist/radio/index.d.ts.map +1 -0
  292. package/dist/radio/index.js +1 -1
  293. package/dist/radio/types.d.ts +20 -0
  294. package/dist/radio/types.d.ts.map +1 -0
  295. package/dist/radio-group/index.d.ts +6 -0
  296. package/dist/radio-group/index.d.ts.map +1 -0
  297. package/dist/radio-group/types.d.ts +43 -0
  298. package/dist/radio-group/types.d.ts.map +1 -0
  299. package/dist/rating/index.d.ts +6 -0
  300. package/dist/rating/index.d.ts.map +1 -0
  301. package/dist/rating/types.d.ts +64 -0
  302. package/dist/rating/types.d.ts.map +1 -0
  303. package/dist/ribbon/index.d.ts +6 -0
  304. package/dist/ribbon/index.d.ts.map +1 -0
  305. package/dist/ribbon/types.d.ts +26 -0
  306. package/dist/ribbon/types.d.ts.map +1 -0
  307. package/dist/scroll-area/index.d.ts +10 -0
  308. package/dist/scroll-area/index.d.ts.map +1 -0
  309. package/dist/scroll-area/types.d.ts +24 -0
  310. package/dist/scroll-area/types.d.ts.map +1 -0
  311. package/dist/select/index.d.ts +6 -0
  312. package/dist/select/index.d.ts.map +1 -0
  313. package/dist/select/index.js +2 -2
  314. package/dist/select/types.d.ts +34 -0
  315. package/dist/select/types.d.ts.map +1 -0
  316. package/dist/skeleton/index.d.ts +6 -0
  317. package/dist/skeleton/index.d.ts.map +1 -0
  318. package/dist/skeleton/types.d.ts +10 -0
  319. package/dist/skeleton/types.d.ts.map +1 -0
  320. package/dist/slider/index.d.ts +6 -0
  321. package/dist/slider/index.d.ts.map +1 -0
  322. package/dist/slider/types.d.ts +70 -0
  323. package/dist/slider/types.d.ts.map +1 -0
  324. package/dist/spinner/index.d.ts +6 -0
  325. package/dist/spinner/index.d.ts.map +1 -0
  326. package/dist/spinner/types.d.ts +10 -0
  327. package/dist/spinner/types.d.ts.map +1 -0
  328. package/dist/stepper/index.d.ts +6 -0
  329. package/dist/stepper/index.d.ts.map +1 -0
  330. package/dist/stepper/index.js +1 -1
  331. package/dist/stepper/types.d.ts +86 -0
  332. package/dist/stepper/types.d.ts.map +1 -0
  333. package/dist/styles/global.css +7651 -0
  334. package/dist/styles/themes/dark.css +93 -0
  335. package/dist/styles/themes/index.d.ts +9 -0
  336. package/dist/styles/themes/index.d.ts.map +1 -0
  337. package/dist/styles/themes/light.css +89 -0
  338. package/dist/styles/themes/presets/corporate.css +126 -0
  339. package/dist/styles/themes/presets/index.d.ts +21 -0
  340. package/dist/styles/themes/presets/index.d.ts.map +1 -0
  341. package/dist/styles/themes/presets/minimal.css +126 -0
  342. package/dist/styles/themes/presets/vibrant.css +126 -0
  343. package/dist/styles/tokens.d.ts +428 -0
  344. package/dist/styles/tokens.d.ts.map +1 -0
  345. package/dist/switch/index.d.ts +6 -0
  346. package/dist/switch/index.d.ts.map +1 -0
  347. package/dist/switch/types.d.ts +80 -0
  348. package/dist/switch/types.d.ts.map +1 -0
  349. package/dist/table/EditableCell.d.ts +13 -0
  350. package/dist/table/EditableCell.d.ts.map +1 -0
  351. package/dist/table/TableActions.d.ts +21 -0
  352. package/dist/table/TableActions.d.ts.map +1 -0
  353. package/dist/table/TableCell.d.ts +12 -0
  354. package/dist/table/TableCell.d.ts.map +1 -0
  355. package/dist/table/TableHeaderCell.d.ts +16 -0
  356. package/dist/table/TableHeaderCell.d.ts.map +1 -0
  357. package/dist/table/TableRow.d.ts +16 -0
  358. package/dist/table/TableRow.d.ts.map +1 -0
  359. package/dist/table/TableSkeleton.d.ts +13 -0
  360. package/dist/table/TableSkeleton.d.ts.map +1 -0
  361. package/dist/table/index.d.ts +15 -0
  362. package/dist/table/index.d.ts.map +1 -0
  363. package/dist/table/index.js +6 -6
  364. package/dist/table/types.d.ts +110 -0
  365. package/dist/table/types.d.ts.map +1 -0
  366. package/dist/table/variants.d.ts +8 -0
  367. package/dist/table/variants.d.ts.map +1 -0
  368. package/dist/tabs/index.d.ts +7 -0
  369. package/dist/tabs/index.d.ts.map +1 -0
  370. package/dist/tabs/index.js +1 -1
  371. package/dist/tabs/types.d.ts +86 -0
  372. package/dist/tabs/types.d.ts.map +1 -0
  373. package/dist/tag/index.d.ts +49 -0
  374. package/dist/tag/index.d.ts.map +1 -0
  375. package/dist/tag/index.js +1 -1
  376. package/dist/tag/types.d.ts +23 -0
  377. package/dist/tag/types.d.ts.map +1 -0
  378. package/dist/textarea/index.d.ts +6 -0
  379. package/dist/textarea/index.d.ts.map +1 -0
  380. package/dist/textarea/index.js +1 -1
  381. package/dist/textarea/types.d.ts +84 -0
  382. package/dist/textarea/types.d.ts.map +1 -0
  383. package/dist/theme/ThemeProvider.d.ts +44 -0
  384. package/dist/theme/ThemeProvider.d.ts.map +1 -0
  385. package/dist/theme/index.d.ts +7 -0
  386. package/dist/theme/index.d.ts.map +1 -0
  387. package/dist/theme/types.d.ts +47 -0
  388. package/dist/theme/types.d.ts.map +1 -0
  389. package/dist/timeline/index.d.ts +13 -0
  390. package/dist/timeline/index.d.ts.map +1 -0
  391. package/dist/timeline/types.d.ts +25 -0
  392. package/dist/timeline/types.d.ts.map +1 -0
  393. package/dist/toast/index.d.ts +12 -0
  394. package/dist/toast/index.d.ts.map +1 -0
  395. package/dist/toast/types.d.ts +49 -0
  396. package/dist/toast/types.d.ts.map +1 -0
  397. package/dist/toggle/index.d.ts +6 -0
  398. package/dist/toggle/index.d.ts.map +1 -0
  399. package/dist/toggle/index.js +1 -1
  400. package/dist/toggle/types.d.ts +57 -0
  401. package/dist/toggle/types.d.ts.map +1 -0
  402. package/dist/toggle-group/index.d.ts +6 -0
  403. package/dist/toggle-group/index.d.ts.map +1 -0
  404. package/dist/toggle-group/index.js +1 -1
  405. package/dist/toggle-group/types.d.ts +80 -0
  406. package/dist/toggle-group/types.d.ts.map +1 -0
  407. package/dist/tooltip/index.d.ts +9 -0
  408. package/dist/tooltip/index.d.ts.map +1 -0
  409. package/dist/tooltip/index.js +1 -1
  410. package/dist/tooltip/types.d.ts +72 -0
  411. package/dist/tooltip/types.d.ts.map +1 -0
  412. package/dist/transfer/index.d.ts +6 -0
  413. package/dist/transfer/index.d.ts.map +1 -0
  414. package/dist/transfer/types.d.ts +83 -0
  415. package/dist/transfer/types.d.ts.map +1 -0
  416. package/dist/transfer/utils.d.ts +13 -0
  417. package/dist/transfer/utils.d.ts.map +1 -0
  418. package/dist/tree/index.d.ts +6 -0
  419. package/dist/tree/index.d.ts.map +1 -0
  420. package/dist/tree/index.js +1 -1
  421. package/dist/tree/types.d.ts +143 -0
  422. package/dist/tree/types.d.ts.map +1 -0
  423. package/dist/tree-select/index.d.ts +6 -0
  424. package/dist/tree-select/index.d.ts.map +1 -0
  425. package/dist/tree-select/index.js +3 -3
  426. package/dist/tree-select/types.d.ts +147 -0
  427. package/dist/tree-select/types.d.ts.map +1 -0
  428. package/dist/types.d.ts +53 -0
  429. package/dist/types.d.ts.map +1 -0
  430. package/dist/upload/index.d.ts +7 -0
  431. package/dist/upload/index.d.ts.map +1 -0
  432. package/dist/upload/index.js +1 -1
  433. package/dist/upload/types.d.ts +94 -0
  434. package/dist/upload/types.d.ts.map +1 -0
  435. package/dist/upload/utils.d.ts +26 -0
  436. package/dist/upload/utils.d.ts.map +1 -0
  437. package/dist/utils.d.ts +63 -0
  438. package/dist/utils.d.ts.map +1 -0
  439. package/dist/variants.d.ts +434 -0
  440. package/dist/variants.d.ts.map +1 -0
  441. package/package.json +157 -143
  442. package/dist/chunk-2J57G7XG.js.map +0 -1
  443. package/dist/chunk-2NYVRAG4.js.map +0 -1
  444. package/dist/chunk-4TQ4BZ3S.js.map +0 -1
  445. package/dist/chunk-5JOJBDET.js.map +0 -1
  446. package/dist/chunk-7KA7JSRX.js.map +0 -1
  447. package/dist/chunk-CLLNXRYZ.js.map +0 -1
  448. package/dist/chunk-CO766H7F.js.map +0 -1
  449. package/dist/chunk-CSRMVLPR.js.map +0 -1
  450. package/dist/chunk-FZLFCT6Q.js.map +0 -1
  451. package/dist/chunk-HEV27FUK.js.map +0 -1
  452. package/dist/chunk-HLY4VDIX.js.map +0 -1
  453. package/dist/chunk-ILQQTKD4.js.map +0 -1
  454. package/dist/chunk-ITZBSE5F.js.map +0 -1
  455. package/dist/chunk-IVOMN6DV.js.map +0 -1
  456. package/dist/chunk-KPI7MN5V.js.map +0 -1
  457. package/dist/chunk-KPM72QBO.js.map +0 -1
  458. package/dist/chunk-KTHWXHDN.js.map +0 -1
  459. package/dist/chunk-N3ZVPIFC.js.map +0 -1
  460. package/dist/chunk-Q57THXIU.js.map +0 -1
  461. package/dist/chunk-RW4RW4DV.js.map +0 -1
  462. package/dist/chunk-RZVEKAFR.js.map +0 -1
  463. package/dist/chunk-SAVEKACZ.js.map +0 -1
  464. package/dist/chunk-TBMY5EQC.js.map +0 -1
  465. package/dist/chunk-UHVPOGNC.js.map +0 -1
  466. package/dist/chunk-UTKVWE76.js.map +0 -1
  467. package/dist/chunk-WTGCXWNX.js.map +0 -1
  468. package/dist/chunk-WUBMNJGC.js.map +0 -1
  469. package/dist/chunk-XQJ6HZ4Q.js.map +0 -1
  470. package/dist/chunk-YTUB2Q7P.js.map +0 -1
  471. package/dist/chunk-YWGWFGCY.js.map +0 -1
package/README.md CHANGED
@@ -1,1050 +1,426 @@
1
1
  # @mdigital_ui/ui
2
2
 
3
- Modern React component library built with Tailwind CSS v4, designed for multi-brand support and maximum customization.
3
+ Modern React component library built with Tailwind CSS v4, CVA, and Radix UI primitives.
4
4
 
5
5
  ## Features
6
6
 
7
- - **57 Components** - Comprehensive UI component library
8
- - **Tailwind CSS v4** - Modern utility-first CSS with OKLCH colors
9
- - **TypeScript** - Full type safety and IntelliSense
10
- - **Dark Mode** - Built-in dark mode support via `.dark` class
11
- - **Theme Presets** - Pre-built color schemes (Corporate, Vibrant, Minimal)
12
- - **CSS Variables** - Override any design token without rebuilding
13
- - **Tree-Shakeable** - Optimal bundle size with ESM
14
- - **Accessible** - WCAG 2.1 AA compliant
15
- - **React 19** - Modern React patterns (no forwardRef)
7
+ - **Tailwind CSS v4** with OKLCH color system and CSS-first configuration
8
+ - **Full TypeScript** support with exported types for every component
9
+ - **Dark Mode** built-in via `.dark` class toggle
10
+ - **Theme Presets** (Corporate, Vibrant, Minimal) with CSS variable overrides
11
+ - **Tree-Shakeable** ESM with subpath imports
12
+ - **Accessible** keyboard navigation, ARIA attributes, focus management, reduced-motion support
13
+ - **ClassNames API** for granular styling of every component part
16
14
 
17
15
  ## Installation
18
16
 
19
17
  ```bash
20
- npm install @mdigital_ui/ui
21
- # or
22
18
  pnpm add @mdigital_ui/ui
19
+ # or
20
+ npm install @mdigital_ui/ui
23
21
  ```
24
22
 
25
23
  ### Peer Dependencies
26
24
 
27
- Required:
28
- ```bash
29
- npm install react react-dom
30
- ```
31
-
32
- Optional (for specific components):
33
25
  ```bash
34
- # For Carousel component
35
- npm install swiper
36
-
37
- # For Table component (advanced features)
38
- npm install @tanstack/react-table
39
-
40
- # For Chart components
41
- npm install recharts
42
-
43
- # For DatePicker component
44
- npm install react-datepicker
26
+ pnpm add react react-dom tailwindcss
45
27
  ```
46
28
 
47
29
  ## Quick Start
48
30
 
49
31
  ### 1. Import Styles
50
32
 
51
- In your main entry point (e.g., `app/layout.tsx` or `src/main.tsx`):
52
-
53
33
  ```tsx
54
- // Required: Global styles and light theme
34
+ // Required
55
35
  import '@mdigital_ui/ui/styles/global.css'
56
36
  import '@mdigital_ui/ui/styles/themes/light.css'
57
37
 
58
- // Optional: Dark mode support
38
+ // Optional: dark mode
59
39
  import '@mdigital_ui/ui/styles/themes/dark.css'
60
-
61
- // Optional: Theme presets
62
- import '@mdigital_ui/ui/styles/themes/presets/corporate.css'
63
- import '@mdigital_ui/ui/styles/themes/presets/vibrant.css'
64
- import '@mdigital_ui/ui/styles/themes/presets/minimal.css'
65
40
  ```
66
41
 
67
42
  ### 2. Use Components
68
43
 
69
44
  ```tsx
70
- import { Button, Input, Card } from '@mdigital_ui/ui'
45
+ import Button from '@mdigital_ui/ui/button'
46
+ import Input from '@mdigital_ui/ui/input'
47
+ import { Card, CardHeader, CardTitle, CardContent } from '@mdigital_ui/ui/card'
71
48
 
72
49
  function App() {
73
50
  return (
74
51
  <Card>
75
- <Input label="Email" placeholder="Enter your email" />
76
- <Button variant="solid" color="primary">
77
- Submit
78
- </Button>
52
+ <CardHeader>
53
+ <CardTitle>Sign In</CardTitle>
54
+ </CardHeader>
55
+ <CardContent>
56
+ <Input label="Email" placeholder="you@example.com" />
57
+ <Button color="primary" className="mt-4">Submit</Button>
58
+ </CardContent>
79
59
  </Card>
80
60
  )
81
61
  }
82
62
  ```
83
63
 
84
- ## Customization with ClassNames
64
+ ### Import Patterns
85
65
 
86
- Every component in the UI kit supports fine-grained styling through the `classNames` prop. This allows you to override styles for individual component parts without modifying the entire component.
87
-
88
- ### How ClassNames Work
66
+ ```tsx
67
+ // Subpath imports (recommended, best tree-shaking)
68
+ import Button from '@mdigital_ui/ui/button'
69
+ import Select from '@mdigital_ui/ui/select'
70
+
71
+ // Barrel import
72
+ import { Button, Select, Input } from '@mdigital_ui/ui'
73
+
74
+ // Type imports
75
+ import type { ButtonProps, SelectProps } from '@mdigital_ui/ui'
76
+ ```
77
+
78
+ ---
79
+
80
+ ## Components
81
+
82
+ ### Form Inputs
83
+
84
+ | Component | Import | Description |
85
+ |-----------|--------|-------------|
86
+ | **Input** | `input` | Text input with validation states, icons, clearable |
87
+ | **FloatInput** | `float-input` | Floating label input |
88
+ | **InputPassword** | `input-password` | Password input with visibility toggle |
89
+ | **InputOTP** | `input-otp` | One-time password code input |
90
+ | **InputGroup** | `input-group` | Input with prefix/suffix addons |
91
+ | **NumberInput** | `number-input` | Numeric input with increment/decrement buttons |
92
+ | **Textarea** | `textarea` | Multi-line text input with auto-resize |
93
+ | **Select** | `select` | Searchable dropdown with virtualization |
94
+ | **MultiSelect** | `multi-select` | Multiple selection with tags |
95
+ | **Cascader** | `cascader` | Cascading multi-level selection |
96
+ | **TreeSelect** | `tree-select` | Tree-based dropdown selection |
97
+ | **DatePicker** | `date-picker` | Date, range, and time pickers |
98
+ | **Upload** | `upload` | File upload (drag-drop, button, avatar variants) |
99
+ | **Checkbox** | `checkbox` | Single checkbox |
100
+ | **CheckboxGroup** | `checkbox-group` | Grouped checkboxes |
101
+ | **Radio** | `radio` | Single radio button |
102
+ | **RadioGroup** | `radio-group` | Grouped radio buttons |
103
+ | **Switch** | `switch` | Toggle switch |
104
+ | **Slider** | `slider` | Range slider |
105
+ | **Rating** | `rating` | Star rating |
106
+ | **Toggle** | `toggle` | Toggle button (pressed/unpressed) |
107
+ | **ToggleGroup** | `toggle-group` | Grouped toggle buttons |
108
+
109
+ ### Form Utilities
89
110
 
90
- The `classNames` prop accepts an object where each key corresponds to a specific part of the component. Values are CSS class strings that are merged with the component's default classes using semantic class names.
111
+ | Component | Import | Description |
112
+ |-----------|--------|-------------|
113
+ | **Form** | `form` | Form wrapper with react-hook-form + zod validation |
114
+ | **Clipboard** | `clipboard` | Copy-to-clipboard with visual feedback |
91
115
 
92
- **Key Principles:**
116
+ ### Layout & Containers
93
117
 
94
- 1. **Semantic Classes**: Each part uses a semantic class name in the format `{componentName}_{slot}` (e.g., `button_root`, `input_label`)
95
- 2. **Data Attributes**: All parts include `data-slot` attributes for CSS targeting
96
- 3. **Class Merging**: Custom classes are merged with default classes, allowing you to:
97
- - Add Tailwind utilities
98
- - Override specific properties
99
- - Add state-based styles
118
+ | Component | Import | Description |
119
+ |-----------|--------|-------------|
120
+ | **Button** | `button` | Button with solid, outline, soft, dashed, link, ghost variants |
121
+ | **ButtonGroup** | `button-group` | Grouped buttons |
122
+ | **Card** | `card` | Content card with header, body, footer, image sub-components |
123
+ | **Grid** | `grid` | Responsive CSS grid layout |
124
+ | **Divider** | `divider` | Horizontal/vertical content separator |
125
+ | **ScrollArea** | `scroll-area` | Custom scrollbar container |
100
126
 
101
- ### Basic Usage
127
+ ### Navigation
102
128
 
103
- ```tsx
104
- import Button from '@mdigital_ui/ui/button'
129
+ | Component | Import | Description |
130
+ |-----------|--------|-------------|
131
+ | **Tabs** | `tabs` | Tabbed content navigation |
132
+ | **Breadcrumbs** | `breadcrumbs` | Hierarchical breadcrumb trail |
133
+ | **Pagination** | `pagination` | Page navigation with page size control |
134
+ | **Stepper** | `stepper` | Step progress indicator |
135
+ | **Dropdown** | `dropdown` | Dropdown action menu |
136
+ | **ContextMenu** | `context-menu` | Right-click context menu with submenus |
137
+ | **Menubar** | `menubar` | Horizontal menu bar |
138
+ | **NavigationMenu** | `navigation-menu` | Navigation with dropdown panels |
139
+ | **Link** | `link` | Styled anchor element |
140
+ | **Command** | `command` | Command palette / search (Cmd+K) |
105
141
 
106
- function App() {
107
- return (
108
- <Button
109
- classNames={{
110
- root: 'shadow-lg hover:shadow-xl',
111
- icon: 'text-white',
112
- content: 'font-bold uppercase',
113
- }}
114
- >
115
- Click Me
116
- </Button>
117
- )
118
- }
119
- ```
142
+ ### Overlays & Feedback
120
143
 
121
- ### Targeting via Semantic Classes in CSS
144
+ | Component | Import | Description |
145
+ |-----------|--------|-------------|
146
+ | **Modal** | `modal` | Dialog overlay with Radix primitives |
147
+ | **Drawer** | `drawer` | Slide-in side panel |
148
+ | **Tooltip** | `tooltip` | Hover information popup |
149
+ | **Popover** | `popover` | Contextual popup with positioning |
150
+ | **Notification** | `notification` | Inline alert/notification |
151
+ | **Toast** | `toast` | Temporary toast notifications (Sonner) |
152
+ | **FetchingOverlay** | `fetching-overlay` | Loading overlay |
153
+ | **Progress** | `progress` | Progress bar (linear, circular, semicircle) |
154
+ | **Spinner** | `spinner` | Loading spinner |
155
+ | **Skeleton** | `skeleton` | Content loading placeholder |
156
+ | **Empty** | `empty` | Empty state with icon, title, action |
122
157
 
123
- Use semantic class names in your CSS files:
158
+ ### Data Display
124
159
 
125
- ```css
126
- /* Target the root button element */
127
- .button_root {
128
- border-radius: 12px;
129
- font-family: 'Inter', sans-serif;
130
- }
160
+ | Component | Import | Description |
161
+ |-----------|--------|-------------|
162
+ | **Table** | `table` | Data table with TanStack Table (sorting, filtering, pagination, pinning, editing) |
163
+ | **Tree** | `tree` | Hierarchical tree view with checkboxes |
164
+ | **Descriptions** | `descriptions` | Key-value description list |
165
+ | **Timeline** | `timeline` | Vertical timeline |
166
+ | **Transfer** | `transfer` | Dual-list transfer |
167
+ | **Carousel** | `carousel` | Content slider (Swiper) |
168
+ | **Image** | `image` | Lazy-loaded image with blur placeholder |
169
+ | **Collapse** | `collapse` | Collapsible content panel |
170
+ | **Accordion** | `accordion` | Accordion panels (single/multiple) |
131
171
 
132
- /* Target button icon */
133
- .button_icon {
134
- margin: 0 4px;
135
- }
172
+ ### Badges & Tags
136
173
 
137
- /* Combine with states */
138
- .button_root:hover {
139
- transform: scale(1.05);
140
- }
141
- ```
174
+ | Component | Import | Description |
175
+ |-----------|--------|-------------|
176
+ | **Badge** | `badge` | Status indicator label |
177
+ | **Tag** | `tag` | Removable tag/chip with keyboard support |
178
+ | **Avatar** | `avatar` | User avatar with image, fallback, status indicator |
179
+ | **Kbd** | `kbd` | Keyboard key indicator |
180
+ | **Ribbon** | `ribbon` | Corner ribbon overlay |
181
+
182
+ ### Theme
183
+
184
+ | Component | Import | Description |
185
+ |-----------|--------|-------------|
186
+ | **ThemeProvider** | `theme` | Theme context with dark mode persistence |
187
+
188
+ ---
189
+
190
+ ## Common Props
191
+
192
+ Most components share these variant props:
142
193
 
143
- ### Using Data-Slot Attributes
194
+ ### `color`
144
195
 
145
- Target component parts using `data-slot` attributes:
196
+ ```
197
+ "default" | "primary" | "secondary" | "accent" | "success" | "error" | "warning" | "info"
198
+ ```
146
199
 
147
- ```css
148
- /* Target via data attribute (highest specificity) */
149
- [data-slot="root"] {
150
- /* Styles */
151
- }
200
+ ### `size`
152
201
 
153
- [data-slot="content"] {
154
- /* Styles */
155
- }
202
+ ```
203
+ "xs" | "sm" | "md" | "lg"
156
204
  ```
157
205
 
158
- ### Combining with Tailwind Classes
206
+ ### `variant`
159
207
 
160
- Mix custom Tailwind classes with component classNames:
208
+ Varies per component. Common patterns:
161
209
 
162
- ```tsx
163
- <Input
164
- classNames={{
165
- root: 'custom-wrapper',
166
- input: 'bg-blue-50 text-blue-900 focus:ring-blue-500',
167
- label: 'font-semibold text-blue-700',
168
- }}
169
- />
170
- ```
210
+ - **Button**: `"solid" | "outline" | "soft" | "dashed" | "link" | "ghost"`
211
+ - **Card**: `"default" | "solid" | "outline" | "soft" | "ghost" | "elevated"`
212
+ - **Input/Textarea**: `"outline" | "filled"`
213
+ - **Notification**: `"default" | "solid" | "outline" | "soft"`
214
+ - **Badge/Tag**: `"default" | "solid" | "outline" | "soft"`
171
215
 
172
- ### TypeScript Support
216
+ ### Validation States
173
217
 
174
- Import type definitions for full IntelliSense:
218
+ Form components support validation via boolean or string props:
175
219
 
176
220
  ```tsx
177
- import type { ButtonClassNames, InputClassNames, SelectClassNames } from '@mdigital_ui/ui'
221
+ <Input error="Email is required" />
222
+ <Input warning="Weak password" />
223
+ <Input success />
224
+ <Input info="We'll never share your email" />
225
+ ```
178
226
 
179
- const buttonClasses: ButtonClassNames = {
180
- root: 'custom-root',
181
- icon: 'custom-icon',
182
- content: 'custom-content',
183
- spinner: 'custom-spinner',
184
- }
227
+ ---
185
228
 
186
- <Button classNames={buttonClasses}>Submit</Button>
187
- ```
229
+ ## Styling
188
230
 
189
- ### ClassNames Reference
231
+ ### className (Root Element)
190
232
 
191
- Each component below documents all available `classNames` keys. Use these to target specific parts of the component for styling.
192
-
193
- #### Form Components
194
-
195
- **Input**
196
-
197
- | Key | Semantic Class | Purpose |
198
- |-----|----------------|---------|
199
- | root | input_root | Wrapper div containing label and input |
200
- | wrapper | input_wrapper | Input wrapper with positioning context |
201
- | label | input_label | Label element |
202
- | input | input_input | Input element |
203
- | leftIcon | input_leftIcon | Left icon container |
204
- | rightIcon | input_rightIcon | Right icon container |
205
- | clearButton | input_clearButton | Clear button element |
206
- | helper | input_helper | Helper/hint text |
207
- | error | input_error | Error message text |
208
-
209
- **InputPassword**
210
-
211
- | Key | Semantic Class | Purpose |
212
- |-----|----------------|---------|
213
- | root | inputPassword_root | Wrapper div |
214
- | wrapper | inputPassword_wrapper | Input wrapper with positioning |
215
- | label | inputPassword_label | Label element |
216
- | input | inputPassword_input | Password input element |
217
- | toggleButton | inputPassword_toggleButton | Show/hide toggle button |
218
- | toggleIcon | inputPassword_toggleIcon | Toggle icon element |
219
- | helper | inputPassword_helper | Helper text |
220
- | error | inputPassword_error | Error message text |
221
-
222
- **InputOTP**
223
-
224
- | Key | Semantic Class | Purpose |
225
- |-----|----------------|---------|
226
- | root | inputOTP_root | Root wrapper |
227
- | wrapper | inputOTP_wrapper | Input slots container |
228
- | label | inputOTP_label | Label element |
229
- | slot | inputOTP_slot | Individual OTP input slot |
230
- | slotActive | inputOTP_slotActive | Active/focused slot |
231
- | separator | inputOTP_separator | Separator between slots |
232
- | helper | inputOTP_helper | Helper text |
233
-
234
- **InputGroup**
235
-
236
- | Key | Semantic Class | Purpose |
237
- |-----|----------------|---------|
238
- | root | inputGroup_root | Root wrapper |
239
- | addon | inputGroup_addon | Addon (prefix/suffix) element |
240
- | input | inputGroup_input | Input element |
241
-
242
- **Textarea**
243
-
244
- | Key | Semantic Class | Purpose |
245
- |-----|----------------|---------|
246
- | root | textarea_root | Wrapper div |
247
- | wrapper | textarea_wrapper | Textarea wrapper |
248
- | label | textarea_label | Label element |
249
- | textarea | textarea_textarea | Textarea element |
250
- | counter | textarea_counter | Character count display |
251
- | helper | textarea_helper | Helper text |
252
- | error | textarea_error | Error message |
253
-
254
- **Select**
255
-
256
- | Key | Semantic Class | Purpose |
257
- |-----|----------------|---------|
258
- | root | select_root | Root wrapper |
259
- | trigger | select_trigger | Dropdown trigger button |
260
- | triggerIcon | select_triggerIcon | Icon in trigger |
261
- | dropdown | select_dropdown | Dropdown menu container |
262
- | search | select_search | Search input in dropdown |
263
- | option | select_option | Individual option item |
264
- | optionSelected | select_optionSelected | Selected option |
265
- | group | select_group | Option group container |
266
- | groupLabel | select_groupLabel | Group label |
267
- | empty | select_empty | Empty state message |
268
- | label | select_label | Form label |
269
- | helper | select_helper | Helper text |
270
-
271
- **MultiSelect**
272
-
273
- | Key | Semantic Class | Purpose |
274
- |-----|----------------|---------|
275
- | root | multiSelect_root | Root wrapper |
276
- | trigger | multiSelect_trigger | Trigger button |
277
- | tag | multiSelect_tag | Selected item tag |
278
- | tagRemove | multiSelect_tagRemove | Remove button in tag |
279
- | dropdown | multiSelect_dropdown | Dropdown menu |
280
- | option | multiSelect_option | Option item |
281
- | optionSelected | multiSelect_optionSelected | Selected option |
282
- | selectAll | multiSelect_selectAll | Select all checkbox |
283
- | empty | multiSelect_empty | Empty state |
284
- | label | multiSelect_label | Form label |
285
- | helper | multiSelect_helper | Helper text |
286
-
287
- **Checkbox**
288
-
289
- | Key | Semantic Class | Purpose |
290
- |-----|----------------|---------|
291
- | root | checkbox_root | Root wrapper |
292
- | checkbox | checkbox_checkbox | Checkbox element |
293
- | indicator | checkbox_indicator | Checkmark indicator |
294
- | label | checkbox_label | Label text |
295
- | description | checkbox_description | Description text |
296
-
297
- **CheckboxGroup**
298
-
299
- | Key | Semantic Class | Purpose |
300
- |-----|----------------|---------|
301
- | root | checkboxGroup_root | Root wrapper |
302
- | label | checkboxGroup_label | Group label |
303
- | group | checkboxGroup_group | Items container |
304
- | item | checkboxGroup_item | Individual checkbox |
305
- | helper | checkboxGroup_helper | Helper text |
306
- | error | checkboxGroup_error | Error message |
307
-
308
- **Radio**
309
-
310
- | Key | Semantic Class | Purpose |
311
- |-----|----------------|---------|
312
- | root | radio_root | Root wrapper |
313
- | radio | radio_radio | Radio button element |
314
- | indicator | radio_indicator | Selection indicator |
315
- | label | radio_label | Label text |
316
- | description | radio_description | Description text |
317
-
318
- **RadioGroup**
319
-
320
- | Key | Semantic Class | Purpose |
321
- |-----|----------------|---------|
322
- | root | radioGroup_root | Root wrapper |
323
- | label | radioGroup_label | Group label |
324
- | group | radioGroup_group | Items container |
325
- | item | radioGroup_item | Individual radio |
326
- | helper | radioGroup_helper | Helper text |
327
- | error | radioGroup_error | Error message |
328
-
329
- **Switch**
330
-
331
- | Key | Semantic Class | Purpose |
332
- |-----|----------------|---------|
333
- | root | switch_root | Root wrapper |
334
- | track | switch_track | Track/background |
335
- | thumb | switch_thumb | Animated thumb |
336
- | label | switch_label | Label text |
337
- | description | switch_description | Description text |
338
-
339
- **Slider**
340
-
341
- | Key | Semantic Class | Purpose |
342
- |-----|----------------|---------|
343
- | root | slider_root | Root wrapper |
344
- | track | slider_track | Track background |
345
- | range | slider_range | Active range fill |
346
- | thumb | slider_thumb | Draggable thumb |
347
- | label | slider_label | Label text |
348
- | value | slider_value | Value display |
349
-
350
- **Rating**
351
-
352
- | Key | Semantic Class | Purpose |
353
- |-----|----------------|---------|
354
- | root | rating_root | Root wrapper |
355
- | star | rating_star | Star element |
356
- | starFilled | rating_starFilled | Filled star |
357
- | label | rating_label | Label text |
358
-
359
- **DatePicker**
360
-
361
- | Key | Semantic Class | Purpose |
362
- |-----|----------------|---------|
363
- | root | datePicker_root | Root wrapper |
364
- | trigger | datePicker_trigger | Input trigger |
365
- | calendar | datePicker_calendar | Calendar container |
366
- | header | datePicker_header | Calendar header |
367
- | navigation | datePicker_navigation | Navigation controls |
368
- | day | datePicker_day | Day cell |
369
- | daySelected | datePicker_daySelected | Selected day |
370
- | dayToday | datePicker_dayToday | Today indicator |
371
-
372
- **Upload**
373
-
374
- | Key | Semantic Class | Purpose |
375
- |-----|----------------|---------|
376
- | root | upload_root | Root wrapper |
377
- | dropzone | upload_dropzone | Drag-drop area |
378
- | input | upload_input | File input |
379
- | icon | upload_icon | Icon element |
380
- | text | upload_text | Text content |
381
- | hint | upload_hint | Hint/instructions |
382
- | fileList | upload_fileList | Files list container |
383
- | fileItem | upload_fileItem | Individual file item |
384
- | progress | upload_progress | Upload progress bar |
385
-
386
- #### Layout & Action Components
387
-
388
- **Button**
389
-
390
- | Key | Semantic Class | Purpose |
391
- |-----|----------------|---------|
392
- | root | button_root | Root button element |
393
- | icon | button_icon | Icon container |
394
- | spinner | button_spinner | Loading spinner container |
395
- | content | button_content | Button text content |
396
-
397
- **ButtonGroup**
398
-
399
- | Key | Semantic Class | Purpose |
400
- |-----|----------------|---------|
401
- | root | buttonGroup_root | Root wrapper |
402
- | button | buttonGroup_button | Individual button |
403
-
404
- **Card**
405
-
406
- | Key | Semantic Class | Purpose |
407
- |-----|----------------|---------|
408
- | root | card_root | Root card element |
409
- | header | card_header | Header section |
410
- | title | card_title | Title element |
411
- | description | card_description | Description text |
412
- | content | card_content | Main content area |
413
- | footer | card_footer | Footer section |
414
- | action | card_action | Action buttons area |
415
- | image | card_image | Image element |
416
-
417
- **Modal**
418
-
419
- | Key | Semantic Class | Purpose |
420
- |-----|----------------|---------|
421
- | root | modal_root | Root wrapper |
422
- | overlay | modal_overlay | Backdrop overlay |
423
- | content | modal_content | Modal content box |
424
- | header | modal_header | Header section |
425
- | title | modal_title | Title element |
426
- | description | modal_description | Description text |
427
- | body | modal_body | Body content |
428
- | footer | modal_footer | Footer section |
429
- | closeButton | modal_closeButton | Close button |
430
-
431
- **Drawer**
432
-
433
- | Key | Semantic Class | Purpose |
434
- |-----|----------------|---------|
435
- | root | drawer_root | Root wrapper |
436
- | overlay | drawer_overlay | Backdrop overlay |
437
- | content | drawer_content | Drawer content box |
438
- | header | drawer_header | Header section |
439
- | title | drawer_title | Title element |
440
- | description | drawer_description | Description text |
441
- | body | drawer_body | Body content |
442
- | footer | drawer_footer | Footer section |
443
- | handle | drawer_handle | Drag handle (mobile) |
444
- | closeButton | drawer_closeButton | Close button |
445
-
446
- **Accordion**
447
-
448
- | Key | Semantic Class | Purpose |
449
- |-----|----------------|---------|
450
- | root | accordion_root | Root wrapper |
451
- | item | accordion_item | Individual accordion item |
452
- | trigger | accordion_trigger | Item trigger/header |
453
- | content | accordion_content | Item content |
454
- | icon | accordion_icon | Expand/collapse icon |
455
-
456
- **Tabs**
457
-
458
- | Key | Semantic Class | Purpose |
459
- |-----|----------------|---------|
460
- | root | tabs_root | Root wrapper |
461
- | list | tabs_list | Tab list container |
462
- | tab | tabs_tab | Individual tab |
463
- | tabActive | tabs_tabActive | Active tab |
464
- | panel | tabs_panel | Tab panel content |
465
-
466
- **Collapse**
467
-
468
- | Key | Semantic Class | Purpose |
469
- |-----|----------------|---------|
470
- | root | collapse_root | Root wrapper |
471
- | header | collapse_header | Header/trigger |
472
- | content | collapse_content | Collapsible content |
473
- | icon | collapse_icon | Toggle icon |
474
-
475
- **Toggle**
476
-
477
- | Key | Semantic Class | Purpose |
478
- |-----|----------------|---------|
479
- | root | toggle_root | Root toggle element |
480
-
481
- **ToggleGroup**
482
-
483
- | Key | Semantic Class | Purpose |
484
- |-----|----------------|---------|
485
- | root | toggleGroup_root | Root wrapper |
486
- | item | toggleGroup_item | Individual toggle item |
487
-
488
- #### Navigation Components
489
-
490
- **Dropdown**
491
-
492
- | Key | Semantic Class | Purpose |
493
- |-----|----------------|---------|
494
- | root | dropdown_root | Root wrapper |
495
- | trigger | dropdown_trigger | Trigger button |
496
- | menu | dropdown_menu | Menu container |
497
- | item | dropdown_item | Menu item |
498
- | itemIcon | dropdown_itemIcon | Item icon |
499
- | itemLabel | dropdown_itemLabel | Item label |
500
- | divider | dropdown_divider | Divider line |
501
-
502
- **ContextMenu**
503
-
504
- | Key | Semantic Class | Purpose |
505
- |-----|----------------|---------|
506
- | root | contextMenu_root | Root wrapper |
507
- | content | contextMenu_content | Menu content |
508
- | item | contextMenu_item | Menu item |
509
- | itemIcon | contextMenu_itemIcon | Item icon |
510
- | itemLabel | contextMenu_itemLabel | Item label |
511
- | divider | contextMenu_divider | Divider line |
512
- | submenu | contextMenu_submenu | Submenu container |
513
-
514
- **Breadcrumbs**
515
-
516
- | Key | Semantic Class | Purpose |
517
- |-----|----------------|---------|
518
- | root | breadcrumbs_root | Root wrapper |
519
- | list | breadcrumbs_list | Breadcrumb list |
520
- | item | breadcrumbs_item | Individual breadcrumb |
521
- | link | breadcrumbs_link | Link element |
522
- | separator | breadcrumbs_separator | Separator between items |
523
- | current | breadcrumbs_current | Current page indicator |
524
-
525
- **Pagination**
526
-
527
- | Key | Semantic Class | Purpose |
528
- |-----|----------------|---------|
529
- | root | pagination_root | Root wrapper |
530
- | list | pagination_list | Items list |
531
- | item | pagination_item | Individual page item |
532
- | button | pagination_button | Page button |
533
- | buttonActive | pagination_buttonActive | Active page button |
534
- | ellipsis | pagination_ellipsis | Ellipsis indicator |
535
- | info | pagination_info | Info text |
536
-
537
- **Stepper**
538
-
539
- | Key | Semantic Class | Purpose |
540
- |-----|----------------|---------|
541
- | root | stepper_root | Root wrapper |
542
- | step | stepper_step | Individual step |
543
- | stepActive | stepper_stepActive | Active step |
544
- | stepCompleted | stepper_stepCompleted | Completed step |
545
- | icon | stepper_icon | Step icon |
546
- | label | stepper_label | Step label |
547
- | description | stepper_description | Step description |
548
- | connector | stepper_connector | Connector line between steps |
549
-
550
- #### Feedback Components
551
-
552
- **Notification**
553
-
554
- | Key | Semantic Class | Purpose |
555
- |-----|----------------|---------|
556
- | root | notification_root | Root wrapper |
557
- | icon | notification_icon | Icon element |
558
- | content | notification_content | Content container |
559
- | title | notification_title | Title text |
560
- | description | notification_description | Description text |
561
- | action | notification_action | Action button |
562
- | closeButton | notification_closeButton | Close button |
563
-
564
- **Tooltip**
565
-
566
- | Key | Semantic Class | Purpose |
567
- |-----|----------------|---------|
568
- | root | tooltip_root | Root wrapper |
569
- | trigger | tooltip_trigger | Trigger element |
570
- | content | tooltip_content | Tooltip content |
571
- | arrow | tooltip_arrow | Arrow element |
572
-
573
- **Popover**
574
-
575
- | Key | Semantic Class | Purpose |
576
- |-----|----------------|---------|
577
- | root | popover_root | Root wrapper |
578
- | trigger | popover_trigger | Trigger element |
579
- | content | popover_content | Popover content |
580
- | arrow | popover_arrow | Arrow element |
581
- | closeButton | popover_closeButton | Close button |
582
-
583
- **Progress**
584
-
585
- | Key | Semantic Class | Purpose |
586
- |-----|----------------|---------|
587
- | root | progress_root | Root wrapper |
588
- | track | progress_track | Background track |
589
- | fill | progress_fill | Progress fill |
590
- | label | progress_label | Label text |
591
- | value | progress_value | Value display |
592
-
593
- #### Data Display Components
594
-
595
- **Table**
596
-
597
- | Key | Semantic Class | Purpose |
598
- |-----|----------------|---------|
599
- | root | table_root | Root wrapper |
600
- | wrapper | table_wrapper | Table container |
601
- | header | table_header | Table head |
602
- | headerRow | table_headerRow | Header row |
603
- | headerCell | table_headerCell | Header cell |
604
- | body | table_body | Table body |
605
- | row | table_row | Table row |
606
- | cell | table_cell | Table cell |
607
- | footer | table_footer | Table footer |
608
- | pagination | table_pagination | Pagination area |
609
- | empty | table_empty | Empty state |
610
- | skeleton | table_skeleton | Loading skeleton |
611
- | actions | table_actions | Actions column |
612
-
613
- **Tree**
614
-
615
- | Key | Semantic Class | Purpose |
616
- |-----|----------------|---------|
617
- | root | tree_root | Root wrapper |
618
- | node | tree_node | Tree node |
619
- | nodeContent | tree_nodeContent | Node content |
620
- | icon | tree_icon | Node icon |
621
- | expandIcon | tree_expandIcon | Expand/collapse icon |
622
- | label | tree_label | Node label |
623
- | children | tree_children | Children container |
624
-
625
- **TreeSelect**
626
-
627
- | Key | Semantic Class | Purpose |
628
- |-----|----------------|---------|
629
- | root | treeSelect_root | Root wrapper |
630
- | trigger | treeSelect_trigger | Trigger button |
631
- | dropdown | treeSelect_dropdown | Dropdown menu |
632
- | tree | treeSelect_tree | Tree container |
633
- | node | treeSelect_node | Tree node |
634
- | checkbox | treeSelect_checkbox | Node checkbox |
635
- | label | treeSelect_label | Node label |
636
-
637
- **Tag**
638
-
639
- | Key | Semantic Class | Purpose |
640
- |-----|----------------|---------|
641
- | root | tag_root | Root wrapper |
642
- | content | tag_content | Tag content |
643
- | closeButton | tag_closeButton | Remove button |
644
-
645
- **Avatar**
646
-
647
- | Key | Semantic Class | Purpose |
648
- |-----|----------------|---------|
649
- | root | avatar_root | Root element |
650
- | image | avatar_image | Image element |
651
- | fallback | avatar_fallback | Fallback text |
652
- | status | avatar_status | Status indicator |
653
-
654
- **AvatarGroup**
655
-
656
- | Key | Semantic Class | Purpose |
657
- |-----|----------------|---------|
658
- | root | avatarGroup_root | Root wrapper |
659
- | overflow | avatarGroup_overflow | Overflow indicator |
660
-
661
- **Descriptions**
662
-
663
- | Key | Semantic Class | Purpose |
664
- |-----|----------------|---------|
665
- | root | descriptions_root | Root wrapper |
666
- | item | descriptions_item | Description item |
667
- | label | descriptions_label | Label text |
668
- | content | descriptions_content | Content text |
669
-
670
- **Empty**
671
-
672
- | Key | Semantic Class | Purpose |
673
- |-----|----------------|---------|
674
- | root | empty_root | Root wrapper |
675
- | icon | empty_icon | Icon element |
676
- | title | empty_title | Title text |
677
- | description | empty_description | Description text |
678
- | action | empty_action | Action buttons |
679
-
680
- **Image**
681
-
682
- | Key | Semantic Class | Purpose |
683
- |-----|----------------|---------|
684
- | root | image_root | Root wrapper |
685
- | image | image_image | Image element |
686
- | placeholder | image_placeholder | Placeholder |
687
- | error | image_error | Error state |
688
-
689
- **Carousel**
690
-
691
- | Key | Semantic Class | Purpose |
692
- |-----|----------------|---------|
693
- | root | carousel_root | Root wrapper |
694
- | wrapper | carousel_wrapper | Slides wrapper |
695
- | slide | carousel_slide | Individual slide |
696
- | navigation | carousel_navigation | Navigation area |
697
- | navButton | carousel_navButton | Navigation button |
698
- | pagination | carousel_pagination | Pagination area |
699
- | dot | carousel_dot | Pagination dot |
700
- | dotActive | carousel_dotActive | Active dot |
701
-
702
- **Command**
703
-
704
- | Key | Semantic Class | Purpose |
705
- |-----|----------------|---------|
706
- | root | command_root | Root wrapper |
707
- | input | command_input | Command input |
708
- | inputIcon | command_inputIcon | Input icon |
709
- | list | command_list | Commands list |
710
- | empty | command_empty | Empty state |
711
- | group | command_group | Command group |
712
- | groupLabel | command_groupLabel | Group label |
713
- | item | command_item | Command item |
714
- | itemIcon | command_itemIcon | Item icon |
715
- | shortcut | command_shortcut | Keyboard shortcut |
716
-
717
- **Cascader**
718
-
719
- | Key | Semantic Class | Purpose |
720
- |-----|----------------|---------|
721
- | root | cascader_root | Root wrapper |
722
- | trigger | cascader_trigger | Trigger button |
723
- | dropdown | cascader_dropdown | Dropdown menu |
724
- | menu | cascader_menu | Menu column |
725
- | option | cascader_option | Menu option |
726
-
727
- **Transfer**
728
-
729
- | Key | Semantic Class | Purpose |
730
- |-----|----------------|---------|
731
- | root | transfer_root | Root wrapper |
732
- | list | transfer_list | Individual list |
733
- | header | transfer_header | List header |
734
- | search | transfer_search | Search input |
735
- | item | transfer_item | Transfer item |
736
- | actions | transfer_actions | Action buttons |
737
-
738
- **Clipboard**
739
-
740
- | Key | Semantic Class | Purpose |
741
- |-----|----------------|---------|
742
- | root | clipboard_root | Root wrapper |
743
- | input | clipboard_input | Hidden input |
744
- | button | clipboard_button | Copy button |
745
-
746
- #### Single-Element Components
747
-
748
- Single-element components don't have a `classNames` prop. Instead, pass classes directly via the `className` prop or target via semantic CSS classes:
749
-
750
- | Component | Semantic Class |
751
- |-----------|----------------|
752
- | Badge | badge_root |
753
- | Divider | divider_root |
754
- | Kbd | kbd_root |
755
- | Skeleton | skeleton_root |
756
- | Spinner | spinner_root |
757
- | Ribbon | ribbon_root |
758
- | Grid | grid_root |
759
- | FetchingOverlay | fetchingOverlay_root |
760
- | Chart | chart_root |
233
+ Every component accepts `className` for the root element:
761
234
 
762
235
  ```tsx
763
- // Direct className
764
- <Badge className="custom-badge-style">New</Badge>
765
-
766
- // Or target via CSS
767
- <style>
768
- .badge_root {
769
- background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
770
- }
771
- </style>
236
+ <Button className="shadow-lg my-4">Submit</Button>
772
237
  ```
773
238
 
774
- ### Advanced Examples
239
+ ### classNames (Component Parts)
775
240
 
776
- **Theme-based customization:**
241
+ Most components expose a `classNames` prop for styling internal parts:
777
242
 
778
243
  ```tsx
779
- const isDark = useTheme()
780
-
781
244
  <Button
782
245
  classNames={{
783
- root: isDark ? 'dark:bg-slate-800 dark:text-white' : 'bg-white',
784
- content: 'font-semibold uppercase tracking-wide',
246
+ root: 'shadow-lg',
247
+ icon: 'text-white',
248
+ content: 'font-bold uppercase',
249
+ spinner: 'opacity-50',
785
250
  }}
786
251
  >
787
- Themed Button
252
+ Submit
788
253
  </Button>
789
254
  ```
790
255
 
791
- **Combining multiple approaches:**
256
+ ### Semantic CSS Classes
792
257
 
793
- ```tsx
794
- <Input
795
- className="mx-4 my-2"
796
- classNames={{
797
- root: 'my-custom-wrapper',
798
- input: 'border-2 border-blue-300 focus:border-blue-600',
799
- label: 'text-blue-900 font-bold',
800
- }}
801
- style={{ maxWidth: '400px' }}
802
- />
258
+ Every component part has a semantic class in the format `{component}_{slot}`:
259
+
260
+ ```css
261
+ /* Target in CSS */
262
+ .button_root { border-radius: 12px; }
263
+ .input_label { font-weight: 700; }
264
+ .card_header { padding: 2rem; }
265
+ .modal_overlay { backdrop-filter: blur(8px); }
803
266
  ```
804
267
 
805
- **Component composition with consistent styling:**
268
+ ### data-slot Attributes
806
269
 
807
- ```tsx
808
- const formClasses = {
809
- label: 'text-sm font-semibold text-gray-700',
810
- helper: 'text-xs text-gray-500 mt-1',
811
- error: 'text-xs text-red-600 mt-1',
812
- }
270
+ All component parts include `data-slot` attributes for CSS targeting:
813
271
 
814
- <div>
815
- <Input classNames={formClasses} label="Email" />
816
- <Input classNames={formClasses} label="Password" type="password" />
817
- <Button classNames={{ content: 'font-bold' }}>Submit</Button>
818
- </div>
272
+ ```css
273
+ [data-slot="root"] { /* ... */ }
274
+ [data-slot="content"] { /* ... */ }
819
275
  ```
820
276
 
821
- ## Available Components
822
-
823
- ### Form Components (16)
824
-
825
- | Component | Description | Import |
826
- |-----------|-------------|--------|
827
- | **Input** | Text input with validation states | `@mdigital_ui/ui/input` |
828
- | **InputGroup** | Input with addons (icons, buttons) | `@mdigital_ui/ui/input-group` |
829
- | **InputPassword** | Password input with visibility toggle | `@mdigital_ui/ui/input-password` |
830
- | **InputOTP** | One-time password input | `@mdigital_ui/ui/input-otp` |
831
- | **Textarea** | Multi-line text input | `@mdigital_ui/ui/textarea` |
832
- | **Select** | Dropdown selection | `@mdigital_ui/ui/select` |
833
- | **MultiSelect** | Multiple selection dropdown | `@mdigital_ui/ui/multi-select` |
834
- | **Checkbox** | Toggle option | `@mdigital_ui/ui/checkbox` |
835
- | **CheckboxGroup** | Grouped checkboxes | `@mdigital_ui/ui/checkbox-group` |
836
- | **Radio** | Single selection | `@mdigital_ui/ui/radio` |
837
- | **RadioGroup** | Grouped radio buttons | `@mdigital_ui/ui/radio-group` |
838
- | **Switch** | Toggle switch | `@mdigital_ui/ui/switch` |
839
- | **Toggle** | Toggle button | `@mdigital_ui/ui/toggle` |
840
- | **Slider** | Range slider | `@mdigital_ui/ui/slider` |
841
- | **Rating** | Star rating | `@mdigital_ui/ui/rating` |
842
- | **DatePicker** | Date selection (requires react-datepicker) | `@mdigital_ui/ui/date-picker` |
843
- | **Upload** | File upload | `@mdigital_ui/ui/upload` |
844
-
845
- ### Display Components (13)
846
-
847
- | Component | Description | Import |
848
- |-----------|-------------|--------|
849
- | **Card** | Content container | `@mdigital_ui/ui/card` |
850
- | **Badge** | Status indicator | `@mdigital_ui/ui/badge` |
851
- | **Tag** | Label chip | `@mdigital_ui/ui/tag` |
852
- | **Avatar** | User profile image | `@mdigital_ui/ui/avatar` |
853
- | **Skeleton** | Loading placeholder | `@mdigital_ui/ui/skeleton` |
854
- | **Empty** | Empty state | `@mdigital_ui/ui/empty` |
855
- | **Spinner** | Loading indicator | `@mdigital_ui/ui/spinner` |
856
- | **Progress** | Progress bar | `@mdigital_ui/ui/progress` |
857
- | **Ribbon** | Corner ribbon | `@mdigital_ui/ui/ribbon` |
858
- | **Divider** | Content separator | `@mdigital_ui/ui/divider` |
859
- | **Kbd** | Keyboard key | `@mdigital_ui/ui/kbd` |
860
- | **Descriptions** | Key-value display | `@mdigital_ui/ui/descriptions` |
861
- | **Image** | Optimized image with blur loading | `@mdigital_ui/ui/image` |
862
-
863
- ### Navigation Components (6)
864
-
865
- | Component | Description | Import |
866
- |-----------|-------------|--------|
867
- | **Tabs** | Tabbed navigation | `@mdigital_ui/ui/tabs` |
868
- | **Breadcrumbs** | Hierarchical navigation | `@mdigital_ui/ui/breadcrumbs` |
869
- | **Pagination** | Page navigation | `@mdigital_ui/ui/pagination` |
870
- | **Dropdown** | Dropdown menu | `@mdigital_ui/ui/dropdown` |
871
- | **Stepper** | Step progress indicator | `@mdigital_ui/ui/stepper` |
872
-
873
- ### Feedback Components (6)
874
-
875
- | Component | Description | Import |
876
- |-----------|-------------|--------|
877
- | **Modal** | Dialog overlay | `@mdigital_ui/ui/modal` |
878
- | **Drawer** | Side panel | `@mdigital_ui/ui/drawer` |
879
- | **Tooltip** | Hover information | `@mdigital_ui/ui/tooltip` |
880
- | **Popover** | Contextual popup | `@mdigital_ui/ui/popover` |
881
- | **Notification** | Toast messages | `@mdigital_ui/ui/notification` |
882
- | **FetchingOverlay** | Loading overlay | `@mdigital_ui/ui/fetching-overlay` |
883
-
884
- ### Data Display Components (8)
885
-
886
- | Component | Description | Import |
887
- |-----------|-------------|--------|
888
- | **Table** | Data table with sorting/filtering | `@mdigital_ui/ui/table` |
889
- | **Tree** | Hierarchical tree view | `@mdigital_ui/ui/tree` |
890
- | **TreeSelect** | Tree selection dropdown | `@mdigital_ui/ui/tree-select` |
891
- | **Transfer** | Dual list selector | `@mdigital_ui/ui/transfer` |
892
- | **Cascader** | Cascading selection | `@mdigital_ui/ui/cascader` |
893
- | **Collapse** | Collapsible panels | `@mdigital_ui/ui/collapse` |
894
- | **Accordion** | Accordion panels | `@mdigital_ui/ui/accordion` |
895
-
896
- ### Layout Components (4)
897
-
898
- | Component | Description | Import |
899
- |-----------|-------------|--------|
900
- | **Button** | Button with variants | `@mdigital_ui/ui/button` |
901
- | **ButtonGroup** | Grouped buttons | `@mdigital_ui/ui/button-group` |
902
- | **ToggleGroup** | Toggle button group | `@mdigital_ui/ui/toggle-group` |
903
- | **Grid** | Responsive grid system | `@mdigital_ui/ui/grid` |
904
-
905
- ### Advanced Components (5)
906
-
907
- | Component | Description | Import |
908
- |-----------|-------------|--------|
909
- | **Chart** | LineChart, BarChart, AreaChart, PieChart | `@mdigital_ui/ui/chart` |
910
- | **Carousel** | Image/content slider (requires Swiper) | `@mdigital_ui/ui/carousel` |
911
- | **Command** | Command palette | `@mdigital_ui/ui/command` |
912
- | **ContextMenu** | Right-click menu | `@mdigital_ui/ui/context-menu` |
913
- | **Clipboard** | Copy to clipboard | `@mdigital_ui/ui/clipboard` |
914
-
915
- ### Utilities (1)
916
-
917
- | Component | Description | Import |
918
- |-----------|-------------|--------|
919
- | **ThemeProvider** | Theme management with persistence | `@mdigital_ui/ui/theme` |
920
-
921
- ## Import Patterns
922
-
923
- ### Subpath Imports (Recommended for tree-shaking)
277
+ ### ClassNames Reference
924
278
 
925
- ```tsx
926
- import Button from '@mdigital_ui/ui/button'
927
- import Input from '@mdigital_ui/ui/input'
928
- import Table from '@mdigital_ui/ui/table'
929
- ```
279
+ Every `classNames` key maps to a semantic class `{component}_{key}` and a `data-slot="{key}"` attribute.
930
280
 
931
- ### Named Imports
281
+ <details>
282
+ <summary><strong>Form Components</strong></summary>
932
283
 
933
- ```tsx
934
- import { Button, Input, Select } from '@mdigital_ui/ui'
935
- ```
284
+ | Component | classNames keys |
285
+ |-----------|----------------|
286
+ | **Input** | `root`, `wrapper`, `label`, `input`, `leftIcon`, `rightIcon`, `clearButton`, `helper`, `error` |
287
+ | **FloatInput** | `root`, `wrapper`, `label`, `input`, `helper`, `error` |
288
+ | **InputPassword** | `root`, `wrapper`, `label`, `input`, `toggleButton`, `toggleIcon`, `helper`, `error` |
289
+ | **InputOTP** | `root`, `wrapper`, `label`, `slot`, `slotActive`, `helper` |
290
+ | **InputGroup** | `root`, `addon`, `input` |
291
+ | **NumberInput** | `root`, `wrapper`, `label`, `input`, `increment`, `decrement`, `helper`, `error` |
292
+ | **Textarea** | `root`, `wrapper`, `label`, `textarea`, `counter`, `helper`, `error` |
293
+ | **Select** | `root`, `trigger`, `triggerIcon`, `search`, `dropdown`, `option`, `optionSelected`, `group`, `groupLabel`, `empty`, `label`, `helper` |
294
+ | **MultiSelect** | `root`, `trigger`, `tag`, `tagRemove`, `dropdown`, `option`, `optionSelected`, `selectAll`, `empty`, `label`, `helper` |
295
+ | **Cascader** | `root`, `trigger`, `dropdown`, `menu`, `option` |
296
+ | **TreeSelect** | `root`, `trigger`, `dropdown`, `tree`, `node`, `checkbox`, `label` |
297
+ | **DatePicker** | `root`, `trigger`, `calendar`, `header`, `navigation`, `day`, `daySelected`, `dayToday` |
298
+ | **Upload** | `root`, `dropzone`, `input`, `icon`, `text`, `hint`, `fileList`, `fileItem`, `progress` |
299
+ | **Checkbox** | `root`, `checkbox`, `indicator`, `label`, `description` |
300
+ | **CheckboxGroup** | `root`, `label`, `group`, `item`, `helper`, `error` |
301
+ | **Radio** | `root`, `radio`, `indicator`, `label`, `description` |
302
+ | **RadioGroup** | `root`, `label`, `group`, `item`, `helper`, `error` |
303
+ | **Switch** | `root`, `track`, `thumb`, `label`, `description` |
304
+ | **Slider** | `root`, `track`, `range`, `thumb`, `label`, `value` |
305
+ | **Rating** | `root`, `star`, `starFilled`, `label` |
306
+ | **Toggle** | `root` |
307
+ | **ToggleGroup** | `root`, `item` |
308
+ | **Clipboard** | `root`, `input`, `button` |
309
+ | **Form** | `root`, `field`, `label`, `control`, `description`, `message` |
310
+
311
+ </details>
312
+
313
+ <details>
314
+ <summary><strong>Layout & Navigation Components</strong></summary>
315
+
316
+ | Component | classNames keys |
317
+ |-----------|----------------|
318
+ | **Button** | `root`, `icon`, `leftIcon`, `rightIcon`, `content`, `spinner` |
319
+ | **ButtonGroup** | `root`, `button` |
320
+ | **Card** | `root`, `header`, `title`, `description`, `content`, `footer`, `action`, `image` |
321
+ | **Tabs** | `root`, `list`, `tab`, `tabActive`, `panel` |
322
+ | **Accordion** | `root`, `item`, `trigger`, `content`, `icon` |
323
+ | **Collapse** | `root`, `header`, `content`, `icon` |
324
+ | **Breadcrumbs** | `root`, `list`, `item`, `link`, `separator`, `current` |
325
+ | **Pagination** | `root`, `list`, `item`, `button`, `buttonActive`, `ellipsis`, `info` |
326
+ | **Stepper** | `root`, `step`, `stepActive`, `stepCompleted`, `icon`, `label`, `description`, `connector` |
327
+ | **Dropdown** | `root`, `trigger`, `menu`, `item`, `itemIcon`, `itemLabel`, `divider` |
328
+ | **ContextMenu** | `root`, `content`, `item`, `itemIcon`, `itemLabel`, `divider`, `submenu` |
329
+ | **Menubar** | `root`, `menu`, `trigger`, `content`, `item`, `separator` |
330
+ | **NavigationMenu** | `root`, `list`, `item`, `trigger`, `link`, `content` |
331
+ | **Link** | `root` |
332
+ | **Command** | `root`, `input`, `inputIcon`, `list`, `empty`, `group`, `groupLabel`, `item`, `itemIcon`, `shortcut` |
333
+ | **ScrollArea** | `root`, `viewport`, `scrollbar`, `thumb` |
334
+
335
+ </details>
336
+
337
+ <details>
338
+ <summary><strong>Overlay & Feedback Components</strong></summary>
339
+
340
+ | Component | classNames keys |
341
+ |-----------|----------------|
342
+ | **Modal** | `root`, `overlay`, `content`, `header`, `title`, `description`, `body`, `footer`, `closeButton` |
343
+ | **Drawer** | `root`, `overlay`, `content`, `header`, `title`, `description`, `body`, `footer`, `handle`, `closeButton` |
344
+ | **Tooltip** | `root`, `trigger`, `content`, `arrow` |
345
+ | **Popover** | `content` |
346
+ | **Notification** | `root`, `icon`, `content`, `title`, `description`, `action`, `closeButton` |
347
+ | **Toast** | `root`, `title`, `description`, `action`, `closeButton` |
348
+ | **Progress** | `root`, `track`, `fill`, `label`, `value` |
349
+ | **Empty** | `root`, `icon`, `title`, `description`, `action` |
936
350
 
937
- ### Type Imports
351
+ </details>
938
352
 
939
- ```tsx
940
- import type { ButtonProps, InputProps } from '@mdigital_ui/ui'
941
- ```
353
+ <details>
354
+ <summary><strong>Data Display Components</strong></summary>
355
+
356
+ | Component | classNames keys |
357
+ |-----------|----------------|
358
+ | **Table** | `root`, `wrapper`, `header`, `headerRow`, `headerCell`, `body`, `row`, `cell`, `footer`, `pagination`, `empty`, `skeleton`, `actions` |
359
+ | **Tree** | `root`, `node`, `nodeContent`, `icon`, `expandIcon`, `label` |
360
+ | **Descriptions** | `root`, `item`, `label`, `content` |
361
+ | **Timeline** | `root`, `item`, `dot`, `connector`, `content`, `title`, `description` |
362
+ | **Transfer** | `root`, `list`, `header`, `search`, `item`, `actions` |
363
+ | **Carousel** | `root`, `wrapper`, `slide`, `navigation`, `navButton`, `pagination`, `dot`, `dotActive` |
364
+ | **Image** | `root`, `image`, `placeholder`, `error` |
365
+ | **Avatar** | `root`, `image`, `fallback`, `status` |
366
+ | **AvatarGroup** | `root`, `overflow` |
367
+ | **Tag** | `root`, `content`, `closeButton` |
368
+
369
+ </details>
370
+
371
+ **Single-element components** (use `className` directly): Badge, Divider, Kbd, Skeleton, Spinner, Ribbon, Grid, FetchingOverlay
372
+
373
+ ---
942
374
 
943
375
  ## Theming
944
376
 
945
377
  ### Dark Mode
946
378
 
947
- Enable dark mode by adding the `dark` class to your `<html>` element:
379
+ Add the `dark` class to `<html>`:
948
380
 
949
381
  ```tsx
950
382
  <html className={isDark ? 'dark' : ''}>
951
- <body>{children}</body>
952
- </html>
953
383
  ```
954
384
 
955
- All components automatically adapt via CSS variables.
385
+ All components adapt automatically via CSS variables.
956
386
 
957
387
  ### Theme Presets
958
388
 
959
- Pre-built color schemes for quick brand customization:
960
-
961
- | Preset | Style | Use Case |
962
- |--------|-------|----------|
963
- | `corporate` | Professional navy blue | Enterprise, dashboards |
964
- | `vibrant` | Bold purple/magenta | Creative apps, consumer products |
965
- | `minimal` | Muted grayscale | Content-focused, reading interfaces |
966
-
967
- **Usage:**
968
-
969
389
  ```tsx
970
- // 1. Import preset CSS
971
390
  import '@mdigital_ui/ui/styles/themes/presets/corporate.css'
391
+ // or vibrant.css, minimal.css
972
392
 
973
- // 2. Apply via data-theme attribute on <html>
974
393
  <html data-theme="corporate">
975
- <body>{children}</body>
976
- </html>
977
- ```
978
-
979
- **Combine with dark mode:**
980
-
981
- ```tsx
982
- <html className="dark" data-theme="vibrant">
983
- <body>{children}</body>
984
- </html>
985
394
  ```
986
395
 
987
- **Dynamic switching:**
396
+ | Preset | Style |
397
+ |--------|-------|
398
+ | `corporate` | Professional navy blue |
399
+ | `vibrant` | Bold purple/magenta |
400
+ | `minimal` | Muted grayscale |
988
401
 
989
- ```tsx
990
- import '@mdigital_ui/ui/styles/themes/presets/corporate.css'
991
- import '@mdigital_ui/ui/styles/themes/presets/vibrant.css'
992
- import '@mdigital_ui/ui/styles/themes/presets/minimal.css'
993
-
994
- function App() {
995
- const [preset, setPreset] = useState<'corporate' | 'vibrant' | 'minimal'>('corporate')
996
-
997
- useEffect(() => {
998
- document.documentElement.setAttribute('data-theme', preset)
999
- }, [preset])
1000
-
1001
- return (
1002
- <Select
1003
- value={preset}
1004
- onChange={(e) => setPreset(e.target.value)}
1005
- options={[
1006
- { value: 'corporate', label: 'Corporate' },
1007
- { value: 'vibrant', label: 'Vibrant' },
1008
- { value: 'minimal', label: 'Minimal' },
1009
- ]}
1010
- />
1011
- )
1012
- }
1013
- ```
402
+ Combine with dark mode: `<html className="dark" data-theme="vibrant">`
1014
403
 
1015
404
  ### ThemeProvider
1016
405
 
1017
- For full theme management with persistence and SSR support:
1018
-
1019
406
  ```tsx
1020
- import { ThemeProvider, useTheme } from '@mdigital_ui/ui'
1021
-
1022
- function App() {
1023
- return (
1024
- <ThemeProvider defaultTheme="system" storageKey="my-app-theme">
1025
- <YourApp />
1026
- </ThemeProvider>
1027
- )
1028
- }
407
+ import { ThemeProvider, useTheme } from '@mdigital_ui/ui/theme'
1029
408
 
1030
- function ThemeToggle() {
1031
- const { theme, setTheme, resolvedTheme } = useTheme()
409
+ <ThemeProvider defaultTheme="system" storageKey="my-app-theme">
410
+ <App />
411
+ </ThemeProvider>
1032
412
 
1033
- return (
1034
- <button onClick={() => setTheme(resolvedTheme === 'dark' ? 'light' : 'dark')}>
1035
- {resolvedTheme === 'dark' ? '☀️' : '🌙'}
1036
- </button>
1037
- )
1038
- }
413
+ // In any component:
414
+ const { theme, setTheme, resolvedTheme } = useTheme()
1039
415
  ```
1040
416
 
1041
417
  ### Custom CSS Variables
1042
418
 
1043
- Override any design token in your CSS:
419
+ Override any design token after the UI kit styles:
1044
420
 
1045
421
  ```css
1046
422
  :root {
1047
- /* Brand Colors */
423
+ /* Brand Colors (OKLCH) */
1048
424
  --color-primary: oklch(0.55 0.22 270);
1049
425
  --color-primary-hover: oklch(0.50 0.24 270);
1050
426
  --color-accent: oklch(0.75 0.18 45);
@@ -1052,135 +428,339 @@ Override any design token in your CSS:
1052
428
  /* Component Sizing */
1053
429
  --button-height-md: 2.5rem;
1054
430
  --input-height-md: 2.5rem;
1055
- --radius-md: 0.5rem;
1056
431
 
1057
432
  /* Typography */
1058
433
  --font-sans: 'Inter', ui-sans-serif, system-ui, sans-serif;
1059
434
  }
1060
435
  ```
1061
436
 
1062
- Import after UI Kit styles:
437
+ <details>
438
+ <summary><strong>All CSS Variables</strong></summary>
1063
439
 
1064
- ```tsx
1065
- import '@mdigital_ui/ui/styles/global.css'
1066
- import '@mdigital_ui/ui/styles/themes/light.css'
1067
- import './your-theme.css' // Your overrides
440
+ **Colors**
1068
441
  ```
1069
-
1070
- ### Available CSS Variables
1071
-
1072
- #### Colors
1073
- ```css
1074
- /* Brand */
1075
- --color-primary, --color-primary-hover, --color-primary-active, --color-primary-foreground
1076
- --color-secondary, --color-secondary-hover, --color-secondary-active, --color-secondary-foreground
1077
- --color-accent, --color-accent-hover, --color-accent-active, --color-accent-foreground
1078
-
1079
- /* Semantic */
1080
- --color-success, --color-error, --color-warning, --color-info (with hover/active variants)
1081
-
1082
- /* Surfaces */
1083
- --color-background, --color-background-secondary, --color-surface, --color-card
442
+ --color-primary / -hover / -active / -foreground
443
+ --color-secondary / -hover / -active / -foreground
444
+ --color-accent / -hover / -active / -foreground
445
+ --color-success / -hover / -active / -foreground
446
+ --color-error / -hover / -active / -foreground
447
+ --color-warning / -hover / -active / -foreground
448
+ --color-info / -hover / -active / -foreground
449
+ --color-background / -secondary
450
+ --color-surface, --color-card, --color-card-foreground
1084
451
  --color-border, --color-border-primary
1085
-
1086
- /* Text */
1087
452
  --color-text-primary, --color-text-secondary, --color-text-muted
1088
-
1089
- /* Grayscale */
1090
453
  --color-gray-50 through --color-gray-950
1091
454
  ```
1092
455
 
1093
- #### Sizing
1094
- ```css
1095
- /* Buttons */
456
+ **Sizing**
457
+ ```
1096
458
  --button-height-xs/sm/md/lg
1097
459
  --button-padding-x-xs/sm/md/lg
1098
-
1099
- /* Inputs */
1100
460
  --input-height-xs/sm/md/lg
1101
461
  --input-padding-x-xs/sm/md/lg
1102
-
1103
- /* Switch */
462
+ --select-height-xs/sm/md/lg
463
+ --select-padding-x-xs/sm/md/lg
1104
464
  --switch-width-xs/sm/md/lg/xl
1105
465
  --switch-height-xs/sm/md/lg/xl
466
+ --textarea-min-height-xs/sm/md/lg
467
+ --textarea-padding-xs/sm/md/lg
468
+ ```
1106
469
 
1107
- /* Spacing */
1108
- --spacing-0 through --spacing-12
470
+ **Effects**
471
+ ```
472
+ --radius-none / -sm / -md / -lg / -xl / -full
473
+ --shadow-sm / -md / -lg / -xl / -2xl
474
+ --transition-fast / -base / -slow
475
+ --z-dropdown / -sticky / -modal / -popover / -tooltip
1109
476
  ```
1110
477
 
1111
- #### Effects
1112
- ```css
1113
- /* Border Radius */
1114
- --radius-none, --radius-sm, --radius-md, --radius-lg, --radius-xl, --radius-full
478
+ </details>
479
+
480
+ ---
481
+
482
+ ## Component Examples
1115
483
 
1116
- /* Shadows */
1117
- --shadow-sm, --shadow-md, --shadow-lg, --shadow-xl, --shadow-2xl
484
+ ### Button
1118
485
 
1119
- /* Transitions */
1120
- --transition-fast, --transition-base, --transition-slow
486
+ ```tsx
487
+ import Button from '@mdigital_ui/ui/button'
1121
488
 
1122
- /* Z-Index */
1123
- --z-dropdown, --z-sticky, --z-modal, --z-popover, --z-tooltip
489
+ <Button variant="solid" color="primary" size="md">Click me</Button>
490
+ <Button variant="outline" color="error">Delete</Button>
491
+ <Button variant="ghost" loading loadingText="Saving...">Save</Button>
492
+ <Button icon={<Plus />} iconOnly aria-label="Add item" />
1124
493
  ```
1125
494
 
1126
- ## External Dependencies
495
+ **Props**: `variant`, `color`, `size`, `shape` (`rounded` | `pill` | `square`), `loading`, `loadingText`, `loadingPosition`, `icon`, `iconPlacement`, `leftIcon`, `rightIcon`, `fullWidth`, `iconOnly`
1127
496
 
1128
- Some components require additional setup:
497
+ ### Input
1129
498
 
1130
- ### Carousel (Swiper)
1131
499
  ```tsx
1132
- npm install swiper
500
+ import Input from '@mdigital_ui/ui/input'
501
+
502
+ <Input label="Email" placeholder="you@example.com" />
503
+ <Input variant="filled" leftIcon={<Search />} clearable onClear={() => {}} />
504
+ <Input error="Required" required />
505
+ <Input loading showCount maxLength={100} />
506
+ ```
507
+
508
+ **Props**: `variant`, `size`, `label`, `error`, `warning`, `info`, `success`, `helperText`, `messagePosition`, `leftIcon`, `rightIcon`, `clearable`, `onClear`, `loading`, `maxLength`, `showCount`, `fullWidth`
1133
509
 
1134
- // Import CSS in your entry file
1135
- import 'swiper/css'
1136
- import 'swiper/css/pagination'
1137
- import 'swiper/css/navigation'
510
+ ### Select
511
+
512
+ ```tsx
513
+ import Select from '@mdigital_ui/ui/select'
514
+
515
+ <Select
516
+ label="Country"
517
+ placeholder="Choose..."
518
+ options={[
519
+ { value: 'us', label: 'United States' },
520
+ { value: 'uk', label: 'United Kingdom' },
521
+ { value: 'de', label: 'Germany', group: 'Europe' },
522
+ ]}
523
+ value={value}
524
+ onChange={setValue}
525
+ clearable
526
+ />
1138
527
  ```
1139
528
 
1140
- ### DatePicker (react-datepicker)
529
+ **Props**: `size`, `label`, `options`, `placeholder`, `value`, `defaultValue`, `onChange`, `clearable`, `loading`, `disabled`, `fullWidth`, `error`, `warning`, `info`, `success`, `helperText`, `virtualizeThreshold`, `maxDropdownHeight`
530
+
531
+ ### Table
532
+
1141
533
  ```tsx
1142
- npm install react-datepicker
534
+ import Table from '@mdigital_ui/ui/table'
535
+
536
+ <Table
537
+ data={users}
538
+ columns={[
539
+ { accessorKey: 'name', header: 'Name' },
540
+ { accessorKey: 'email', header: 'Email' },
541
+ { accessorKey: 'role', header: 'Role' },
542
+ ]}
543
+ enableSorting
544
+ enablePagination
545
+ enableRowSelection
546
+ pageSize={10}
547
+ color="primary"
548
+ variant="outline"
549
+ striped
550
+ hoverable
551
+ />
1143
552
  ```
1144
553
 
1145
- ### Table (TanStack Table)
554
+ **Props**: `data`, `columns`, `variant` (`outline` | `line` | `minimal`), `color`, `size`, `striped`, `hoverable`, `bordered`, `enableSorting`, `enableFiltering`, `enablePagination`, `enableRowSelection`, `enableColumnPinning`, `pageSize`, `onRowClick`
555
+
556
+ ### Modal
557
+
1146
558
  ```tsx
1147
- npm install @tanstack/react-table
559
+ import Modal, { ModalContent, ModalHeader, ModalTitle, ModalFooter } from '@mdigital_ui/ui/modal'
560
+ import Button from '@mdigital_ui/ui/button'
561
+
562
+ <Modal open={open} onOpenChange={setOpen}>
563
+ <ModalContent size="md">
564
+ <ModalHeader>
565
+ <ModalTitle>Confirm Delete</ModalTitle>
566
+ </ModalHeader>
567
+ <div className="p-4">Are you sure?</div>
568
+ <ModalFooter>
569
+ <Button variant="ghost" onClick={() => setOpen(false)}>Cancel</Button>
570
+ <Button color="error" onClick={handleDelete}>Delete</Button>
571
+ </ModalFooter>
572
+ </ModalContent>
573
+ </Modal>
1148
574
  ```
1149
575
 
1150
- ### Charts (Recharts)
576
+ ### Card
577
+
1151
578
  ```tsx
1152
- npm install recharts
579
+ import { Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter } from '@mdigital_ui/ui/card'
580
+
581
+ <Card variant="elevated" hoverable>
582
+ <CardHeader>
583
+ <CardTitle>Dashboard</CardTitle>
584
+ <CardDescription>Overview of your metrics</CardDescription>
585
+ </CardHeader>
586
+ <CardContent>Charts and data here</CardContent>
587
+ <CardFooter>
588
+ <Button variant="ghost">View Details</Button>
589
+ </CardFooter>
590
+ </Card>
1153
591
  ```
1154
592
 
1155
- ## TypeScript
593
+ **Props**: `variant`, `color`, `size`, `shadow`, `hoverable`, `clickable`, `bordered`, `loading`
1156
594
 
1157
- Full TypeScript support:
595
+ ### Drawer
1158
596
 
1159
597
  ```tsx
1160
- import type { ButtonProps, ButtonColor, ButtonVariant } from '@mdigital_ui/ui'
598
+ import { Drawer, DrawerTrigger, DrawerContent, DrawerHeader, DrawerTitle, DrawerBody } from '@mdigital_ui/ui/drawer'
599
+
600
+ <Drawer>
601
+ <DrawerTrigger asChild>
602
+ <Button>Open Panel</Button>
603
+ </DrawerTrigger>
604
+ <DrawerContent side="right" size="md">
605
+ <DrawerHeader>
606
+ <DrawerTitle>Settings</DrawerTitle>
607
+ </DrawerHeader>
608
+ <DrawerBody>Content here</DrawerBody>
609
+ </DrawerContent>
610
+ </Drawer>
611
+ ```
612
+
613
+ ### Tabs
1161
614
 
1162
- const MyButton: React.FC<ButtonProps> = (props) => {
1163
- return <Button {...props} />
615
+ ```tsx
616
+ import Tabs from '@mdigital_ui/ui/tabs'
617
+
618
+ <Tabs
619
+ items={[
620
+ { key: 'overview', label: 'Overview', content: <Overview /> },
621
+ { key: 'settings', label: 'Settings', content: <Settings /> },
622
+ { key: 'billing', label: 'Billing', content: <Billing />, disabled: true },
623
+ ]}
624
+ variant="underline"
625
+ color="primary"
626
+ />
627
+ ```
628
+
629
+ **Props**: `items`, `variant` (`underline` | `pills` | `enclosed` | `lifted`), `color`, `size`, `defaultValue`, `value`, `onChange`, `orientation`
630
+
631
+ ### Form (react-hook-form + zod)
632
+
633
+ ```tsx
634
+ import { Form, FormField, FormItem, FormLabel, FormControl, FormMessage } from '@mdigital_ui/ui/form'
635
+ import { useForm } from 'react-hook-form'
636
+ import { zodResolver } from '@hookform/resolvers/zod'
637
+ import { z } from 'zod'
638
+
639
+ const schema = z.object({ email: z.string().email() })
640
+
641
+ function MyForm() {
642
+ const form = useForm({ resolver: zodResolver(schema) })
643
+
644
+ return (
645
+ <Form form={form} onSubmit={(data) => console.log(data)}>
646
+ <FormField name="email" control={form.control} render={({ field }) => (
647
+ <FormItem>
648
+ <FormLabel>Email</FormLabel>
649
+ <FormControl>
650
+ <Input {...field} />
651
+ </FormControl>
652
+ <FormMessage />
653
+ </FormItem>
654
+ )} />
655
+ </Form>
656
+ )
1164
657
  }
1165
658
  ```
1166
659
 
660
+ ### Toast
661
+
662
+ ```tsx
663
+ import { ToastProvider, useToast } from '@mdigital_ui/ui/toast'
664
+
665
+ // Wrap your app
666
+ <ToastProvider position="top-right">
667
+ <App />
668
+ </ToastProvider>
669
+
670
+ // Use anywhere
671
+ const { toast } = useToast()
672
+ toast({ title: 'Saved', description: 'Changes saved successfully', variant: 'success' })
673
+ ```
674
+
675
+ ### Command Palette
676
+
677
+ ```tsx
678
+ import { Command, CommandInput, CommandList, CommandGroup, CommandItem } from '@mdigital_ui/ui/command'
679
+
680
+ <Command>
681
+ <CommandInput placeholder="Search..." />
682
+ <CommandList>
683
+ <CommandGroup heading="Actions">
684
+ <CommandItem onSelect={() => {}}>Create new file</CommandItem>
685
+ <CommandItem onSelect={() => {}}>Open settings</CommandItem>
686
+ </CommandGroup>
687
+ </CommandList>
688
+ </Command>
689
+ ```
690
+
691
+ ### Upload
692
+
693
+ ```tsx
694
+ import Upload from '@mdigital_ui/ui/upload'
695
+
696
+ <Upload
697
+ variant="dragger"
698
+ accept="image/*"
699
+ maxSize={5 * 1024 * 1024}
700
+ maxCount={3}
701
+ onChange={(files) => console.log(files)}
702
+ color="primary"
703
+ />
704
+ ```
705
+
706
+ **Props**: `variant` (`dragger` | `button` | `avatar`), `accept`, `maxSize`, `maxCount`, `multiple`, `disabled`, `onChange`, `onRemove`, `color`, `size`
707
+
708
+ ### Tree
709
+
710
+ ```tsx
711
+ import Tree from '@mdigital_ui/ui/tree'
712
+
713
+ <Tree
714
+ data={[
715
+ { key: '1', label: 'Documents', children: [
716
+ { key: '1-1', label: 'Resume.pdf', isLeaf: true },
717
+ { key: '1-2', label: 'Cover Letter.docx', isLeaf: true },
718
+ ]},
719
+ ]}
720
+ checkable
721
+ defaultExpandAll
722
+ onCheck={(keys, info) => console.log(keys)}
723
+ />
724
+ ```
725
+
726
+ ### Progress
727
+
728
+ ```tsx
729
+ import Progress from '@mdigital_ui/ui/progress'
730
+
731
+ <Progress value={65} color="primary" size="md" showValue />
732
+ <Progress type="circular" value={80} color="success" />
733
+ <Progress type="semicircle" value={45} color="warning" />
734
+ ```
735
+
736
+ ---
737
+
738
+ ## TypeScript
739
+
740
+ All components export their props and classNames types:
741
+
742
+ ```tsx
743
+ import type { ButtonProps, ButtonClassNames, ButtonVariant, ButtonColor } from '@mdigital_ui/ui'
744
+ import type { TableProps, TableClassNames } from '@mdigital_ui/ui'
745
+ import type { InputProps, SelectProps, ModalClassNames } from '@mdigital_ui/ui'
746
+ ```
747
+
748
+ ---
749
+
1167
750
  ## Accessibility
1168
751
 
1169
- All components follow WCAG 2.1 AA standards:
752
+ - Keyboard navigation on all interactive components
753
+ - ARIA roles, labels, and live regions
754
+ - Focus rings with `focus-visible` (no outline on mouse click)
755
+ - `prefers-reduced-motion` respected globally (all animations disabled)
756
+ - Color contrast following WCAG 2.1 AA
1170
757
 
1171
- - Keyboard navigation
1172
- - Screen reader support
1173
- - Focus indicators
1174
- - ARIA attributes
1175
- - Color contrast compliance
758
+ ---
1176
759
 
1177
760
  ## Browser Support
1178
761
 
1179
- - Chrome (latest 2 versions)
1180
- - Firefox (latest 2 versions)
1181
- - Safari (latest 2 versions)
1182
- - Edge (latest 2 versions)
762
+ Chrome, Firefox, Safari, Edge (latest 2 versions)
1183
763
 
1184
764
  ## License
1185
765
 
1186
- MIT © MDigital
766
+ MIT