@chotot/clad-ui 3.0.0-next.3 → 3.0.0-next.5

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 (541) hide show
  1. package/CHANGELOG.md +675 -0
  2. package/README.md +156 -156
  3. package/dist/brand/ChototLogoText.d.ts +5 -0
  4. package/dist/brand/CtC2C.d.ts +5 -0
  5. package/dist/brand/CtProperty.d.ts +5 -0
  6. package/dist/brand/CtVehicle.d.ts +5 -0
  7. package/dist/brand/Tot.d.ts +5 -0
  8. package/dist/brand/index.d.ts +5 -0
  9. package/dist/chunk-Bmb41Sf3.cjs +1 -0
  10. package/dist/clad-ui.cjs +2 -0
  11. package/dist/clad-ui.d.ts +2 -0
  12. package/dist/clad-ui.es.js +9127 -4278
  13. package/dist/components/Announcer/Announcer.d.ts +3 -54
  14. package/dist/components/Announcer/announcer.styles.d.ts +39 -0
  15. package/dist/components/Announcer/index.d.ts +2 -0
  16. package/dist/components/Announcer/types.d.ts +41 -0
  17. package/dist/components/Badge/Badge.d.ts +2 -44
  18. package/dist/components/Badge/badge.styles.d.ts +57 -0
  19. package/dist/components/Badge/index.d.ts +4 -0
  20. package/dist/components/Badge/types.d.ts +33 -0
  21. package/dist/components/Box/Box.d.ts +7 -99
  22. package/dist/components/Box/index.d.ts +2 -0
  23. package/dist/components/Box/types.d.ts +89 -0
  24. package/dist/components/Breadcrumbs/BreadcrumbItem.d.ts +3 -5
  25. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +3 -17
  26. package/dist/components/Breadcrumbs/breadcrumbs.styles.d.ts +2 -0
  27. package/dist/components/Breadcrumbs/index.d.ts +3 -0
  28. package/dist/components/Breadcrumbs/types.d.ts +18 -0
  29. package/dist/components/Button/Button.d.ts +3 -76
  30. package/dist/components/Button/ButtonLink.d.ts +2 -3
  31. package/dist/components/Button/GhostButton.d.ts +3 -47
  32. package/dist/components/Button/IconButton.d.ts +2 -10
  33. package/dist/components/Button/button.styles.d.ts +242 -0
  34. package/dist/components/Button/constant.d.ts +1 -2
  35. package/dist/components/Button/index.d.ts +5 -0
  36. package/dist/components/Button/types.d.ts +72 -0
  37. package/dist/components/Checkbox/Checkbox.d.ts +3 -46
  38. package/dist/components/Checkbox/checkbox.styles.d.ts +27 -0
  39. package/dist/components/Checkbox/index.d.ts +2 -0
  40. package/dist/components/Checkbox/types.d.ts +40 -0
  41. package/dist/components/Chip/Chip.d.ts +3 -70
  42. package/dist/components/Chip/chip.styles.d.ts +66 -0
  43. package/dist/components/Chip/index.d.ts +2 -0
  44. package/dist/components/Chip/types.d.ts +22 -0
  45. package/dist/components/CurrencyInput/CurrencyInput.d.ts +3 -39
  46. package/dist/components/CurrencyInput/currency-input.styles.d.ts +21 -0
  47. package/dist/components/CurrencyInput/index.d.ts +5 -0
  48. package/dist/components/CurrencyInput/types.d.ts +96 -0
  49. package/dist/components/CurrencyInput/utils.d.ts +18 -0
  50. package/dist/components/DatePicker/DatePicker.d.ts +2 -138
  51. package/dist/components/DatePicker/DateTimePicker.d.ts +2 -137
  52. package/dist/components/DatePicker/date-picker.styles.d.ts +9 -0
  53. package/dist/components/DatePicker/date-time-picker.styles.d.ts +10 -0
  54. package/dist/components/DatePicker/index.d.ts +4 -0
  55. package/dist/components/DatePicker/types.d.ts +294 -0
  56. package/dist/components/Drawer/Drawer.d.ts +36 -0
  57. package/dist/components/Drawer/Drawer.pw.fixtures.d.ts +9 -0
  58. package/dist/components/Drawer/index.d.ts +3 -0
  59. package/dist/components/Drawer/types.d.ts +196 -0
  60. package/dist/components/Dropdown/Dropdown.d.ts +3 -94
  61. package/dist/components/Dropdown/dropdown.styles.d.ts +18 -0
  62. package/dist/components/Dropdown/index.d.ts +4 -0
  63. package/dist/components/Dropdown/types.d.ts +89 -0
  64. package/dist/components/EmptyState/EmptyState.d.ts +4 -0
  65. package/dist/components/EmptyState/empty-state.styles.d.ts +3 -0
  66. package/dist/components/EmptyState/index.d.ts +2 -0
  67. package/dist/components/EmptyState/types.d.ts +55 -0
  68. package/dist/components/Grid/Col.d.ts +4 -35
  69. package/dist/components/Grid/Grid.d.ts +8 -55
  70. package/dist/components/Grid/Grid.pw.fixtures.d.ts +3 -0
  71. package/dist/components/Grid/index.d.ts +3 -0
  72. package/dist/components/Grid/types.d.ts +66 -0
  73. package/dist/components/Input/Input.d.ts +3 -116
  74. package/dist/components/Input/index.d.ts +2 -0
  75. package/dist/components/Input/input.styles.d.ts +24 -0
  76. package/dist/components/Input/types.d.ts +55 -0
  77. package/dist/components/InputGroup/InputGroup.d.ts +4 -0
  78. package/dist/components/InputGroup/index.d.ts +4 -0
  79. package/dist/components/InputGroup/input-group.styles.d.ts +18 -0
  80. package/dist/components/InputGroup/types.d.ts +20 -0
  81. package/dist/components/LegacyDialog/DialogMainIcon.d.ts +3 -0
  82. package/dist/components/LegacyDialog/LegacyDialog.d.ts +5 -0
  83. package/dist/components/LegacyDialog/index.d.ts +3 -0
  84. package/dist/{patterns/LegacyDialog/LegacyDialog.d.ts → components/LegacyDialog/types.d.ts} +3 -11
  85. package/dist/components/LegacyPopup/LegacyPopup.d.ts +6 -0
  86. package/dist/components/LegacyPopup/index.d.ts +2 -0
  87. package/dist/{patterns/LegacyPopup/LegacyPopup.d.ts → components/LegacyPopup/types.d.ts} +5 -16
  88. package/dist/components/MultiSearchDropdown/MultiSearchDropdown.d.ts +10 -0
  89. package/dist/components/MultiSearchDropdown/index.d.ts +4 -0
  90. package/dist/components/MultiSearchDropdown/multi-search-dropdown.styles.d.ts +18 -0
  91. package/dist/{patterns/MultiSearchDropdown/MultiSearchDropdown.d.ts → components/MultiSearchDropdown/types.d.ts} +6 -19
  92. package/dist/components/Pagination/PageItem.d.ts +3 -21
  93. package/dist/components/Pagination/Pagination.d.ts +2 -46
  94. package/dist/components/Pagination/index.d.ts +5 -0
  95. package/dist/components/Pagination/pagination.styles.d.ts +37 -0
  96. package/dist/components/Pagination/types.d.ts +66 -0
  97. package/dist/components/Popover/Popover.d.ts +4 -44
  98. package/dist/components/Popover/Popover.pw.fixtures.d.ts +6 -0
  99. package/dist/components/Popover/index.d.ts +2 -0
  100. package/dist/components/Popover/popover.styles.d.ts +1 -0
  101. package/dist/components/Popover/types.d.ts +44 -0
  102. package/dist/components/Popup/Popup.d.ts +31 -0
  103. package/dist/components/Popup/Popup.pw.fixtures.d.ts +5 -0
  104. package/dist/components/Popup/index.d.ts +3 -0
  105. package/dist/components/Popup/types.d.ts +145 -0
  106. package/dist/components/RadioButton/RadioButton.d.ts +3 -51
  107. package/dist/components/RadioButton/index.d.ts +4 -0
  108. package/dist/components/RadioButton/radio-button.styles.d.ts +27 -0
  109. package/dist/components/RadioButton/types.d.ts +46 -0
  110. package/dist/components/RangeInput/RangeInput.d.ts +4 -0
  111. package/dist/components/RangeInput/index.d.ts +3 -0
  112. package/dist/components/RangeInput/range-input.styles.d.ts +1 -0
  113. package/dist/{patterns/RangeInput/RangeInput.d.ts → components/RangeInput/types.d.ts} +2 -5
  114. package/dist/components/RowItem/RowItem.d.ts +8 -76
  115. package/dist/components/RowItem/index.d.ts +2 -0
  116. package/dist/components/RowItem/rowitem.styles.d.ts +36 -0
  117. package/dist/components/RowItem/types.d.ts +66 -0
  118. package/dist/components/SearchInput/SearchInput.d.ts +5 -0
  119. package/dist/components/SearchInput/index.d.ts +3 -0
  120. package/dist/components/SearchInput/search-input.styles.d.ts +18 -0
  121. package/dist/{patterns/SearchInput/SearchInput.d.ts → components/SearchInput/types.d.ts} +19 -25
  122. package/dist/components/Searchbar/Searchbar.d.ts +3 -0
  123. package/dist/components/Searchbar/index.d.ts +3 -0
  124. package/dist/components/Searchbar/searchbar.styles.d.ts +1 -0
  125. package/dist/{patterns/Searchbar/Searchbar.d.ts → components/Searchbar/types.d.ts} +6 -9
  126. package/dist/components/ShapeIcon/ShapeIcon.d.ts +3 -53
  127. package/dist/components/ShapeIcon/index.d.ts +2 -0
  128. package/dist/components/ShapeIcon/shape-icon.styles.d.ts +156 -0
  129. package/dist/components/ShapeIcon/types.d.ts +5 -0
  130. package/dist/components/Slider/Slider.d.ts +3 -57
  131. package/dist/components/Slider/index.d.ts +3 -0
  132. package/dist/components/Slider/slider.styles.d.ts +1 -0
  133. package/dist/components/Slider/types.d.ts +59 -0
  134. package/dist/components/Snack/Snack.d.ts +4 -48
  135. package/dist/components/Snack/index.d.ts +3 -0
  136. package/dist/components/Snack/snack.styles.d.ts +21 -0
  137. package/dist/components/Snack/types.d.ts +48 -0
  138. package/dist/components/Tabs/Tab.d.ts +3 -67
  139. package/dist/components/Tabs/Tabs.d.ts +5 -61
  140. package/dist/components/Tabs/index.d.ts +4 -0
  141. package/dist/components/Tabs/tabs.styles.d.ts +59 -0
  142. package/dist/components/Tabs/types.d.ts +97 -0
  143. package/dist/components/TagCloud/TagCloud.d.ts +275 -0
  144. package/dist/components/TagCloud/index.d.ts +2 -0
  145. package/dist/components/TagCloud/tagcloud.styles.d.ts +18 -0
  146. package/dist/components/TagCloud/types.d.ts +26 -0
  147. package/dist/components/TextArea/TextArea.d.ts +3 -100
  148. package/dist/components/TextArea/index.d.ts +4 -0
  149. package/dist/components/TextArea/text-area.styles.d.ts +21 -0
  150. package/dist/components/TextArea/types.d.ts +98 -0
  151. package/dist/components/TextLabel/TextLabel.d.ts +3 -35
  152. package/dist/components/TextLabel/index.d.ts +2 -0
  153. package/dist/components/TextLabel/textlabel.styles.d.ts +51 -0
  154. package/dist/components/TextLabel/types.d.ts +32 -0
  155. package/dist/components/ToggleSwitch/ToggleSwitch.d.ts +3 -41
  156. package/dist/components/ToggleSwitch/index.d.ts +4 -0
  157. package/dist/components/ToggleSwitch/toggle-switch.styles.d.ts +39 -0
  158. package/dist/components/ToggleSwitch/types.d.ts +33 -0
  159. package/dist/components/Tooltip/Tooltip.d.ts +4 -98
  160. package/dist/components/Tooltip/Tooltip.pw.fixtures.d.ts +1 -0
  161. package/dist/components/Tooltip/index.d.ts +2 -0
  162. package/dist/components/Tooltip/tooltip.styles.d.ts +18 -0
  163. package/dist/components/Tooltip/types.d.ts +24 -0
  164. package/dist/forge/index.cjs +0 -0
  165. package/dist/forge/index.d.ts +8 -0
  166. package/dist/forge/index.es.js +0 -0
  167. package/dist/icons.cjs +1 -0
  168. package/dist/icons.d.ts +1 -0
  169. package/dist/icons.es.js +1 -0
  170. package/dist/index.d.ts +82 -71
  171. package/dist/styles.css +2 -0
  172. package/dist/{utils/types.d.ts → types/index.d.ts} +0 -1
  173. package/dist/typography/BodyAnnotation.d.ts +8 -6
  174. package/dist/typography/BodyCaption.d.ts +8 -6
  175. package/dist/typography/BodyPage.d.ts +8 -6
  176. package/dist/typography/BodySection.d.ts +8 -6
  177. package/dist/typography/DisplayAnnotation.d.ts +8 -6
  178. package/dist/typography/DisplayCaption.d.ts +8 -6
  179. package/dist/typography/DisplayPage.d.ts +8 -6
  180. package/dist/typography/DisplayPrice.d.ts +21 -0
  181. package/dist/typography/DisplaySection.d.ts +8 -6
  182. package/dist/typography/HeaderAnnotation.d.ts +8 -6
  183. package/dist/typography/HeaderCaption.d.ts +8 -6
  184. package/dist/typography/HeaderPage.d.ts +8 -6
  185. package/dist/typography/HeaderSection.d.ts +8 -6
  186. package/dist/typography/LabelAnnotation.d.ts +8 -6
  187. package/dist/typography/LabelCaption.d.ts +8 -6
  188. package/dist/typography/LabelPage.d.ts +8 -6
  189. package/dist/typography/LabelSection.d.ts +8 -6
  190. package/dist/typography/NoteCaption.d.ts +8 -6
  191. package/dist/typography/NotePage.d.ts +8 -6
  192. package/dist/typography/NoteSection.d.ts +8 -6
  193. package/dist/typography/TaglineAnnotation.d.ts +8 -6
  194. package/dist/typography/TaglineCaption.d.ts +8 -6
  195. package/dist/typography/TaglineFootext.d.ts +8 -6
  196. package/dist/typography/TaglineSection.d.ts +8 -6
  197. package/dist/typography/index.d.ts +25 -24
  198. package/dist/utils/_inlineCreatePortal.d.ts +0 -1
  199. package/dist/utils/bundleCss.cjs +1 -0
  200. package/dist/utils/bundleCss.d.ts +6 -0
  201. package/dist/utils/bundleCss.es.js +18 -0
  202. package/dist/utils/cleanHtml.d.ts +4 -7
  203. package/dist/utils/cn.d.ts +5 -0
  204. package/dist/utils/createUniversalPortal.d.ts +4 -14
  205. package/dist/utils/floating.d.ts +52 -0
  206. package/dist/utils/getBreakpointsValues.d.ts +4 -9
  207. package/dist/utils/sizes.d.ts +28 -0
  208. package/dist/utils/storyStyles.d.ts +21 -0
  209. package/dist/utils/themeTokens.d.ts +327 -0
  210. package/dist/utils/{scrollLock/useBodyScrollLock.d.ts → useBodyScrollLock.d.ts} +0 -1
  211. package/dist/utils/useScrollTop.d.ts +8 -0
  212. package/package.json +98 -104
  213. package/scripts/postinstall.cjs +180 -0
  214. package/skills/clad-ui/SKILL.md +109 -0
  215. package/skills/clad-ui/agents/openai.yaml +4 -0
  216. package/skills/clad-ui/references/components-display-layout.md +297 -0
  217. package/skills/clad-ui/references/components-inputs.md +451 -0
  218. package/skills/clad-ui/references/components-overlays-nav.md +314 -0
  219. package/skills/clad-ui/references/tokens.md +134 -0
  220. package/skills/clad-ui-feedback/SKILL.md +128 -0
  221. package/skills/migrate-clad-ui-v3/SKILL.md +124 -0
  222. package/skills/migrate-clad-ui-v3/agents/openai.yaml +4 -0
  223. package/skills/migrate-clad-ui-v3/references/component-api-changes.md +145 -0
  224. package/skills/migrate-clad-ui-v3/references/token-and-linaria-mapping.md +194 -0
  225. package/src/styles/base/base.css +440 -0
  226. package/src/styles/components/announcer.css +182 -0
  227. package/src/styles/components/badge.css +102 -0
  228. package/src/styles/components/box.css +61 -0
  229. package/src/styles/components/breadcrumbs.css +75 -0
  230. package/src/styles/components/button.css +527 -0
  231. package/src/styles/components/checkbox.css +115 -0
  232. package/src/styles/components/chip.css +155 -0
  233. package/src/styles/components/currency-input.css +146 -0
  234. package/src/styles/components/date-picker.css +305 -0
  235. package/src/styles/components/date-time-picker.css +64 -0
  236. package/src/styles/components/drawer.css +496 -0
  237. package/src/styles/components/dropdown.css +186 -0
  238. package/src/styles/components/empty-state.css +30 -0
  239. package/src/styles/components/grid.css +212 -0
  240. package/src/styles/components/index.css +36 -0
  241. package/src/styles/components/input-group.css +85 -0
  242. package/src/styles/components/input.css +255 -0
  243. package/src/styles/components/legacy-dialog.css +129 -0
  244. package/src/styles/components/legacy-popup.css +209 -0
  245. package/src/styles/components/multi-search-dropdown.css +240 -0
  246. package/src/styles/components/pagination.css +68 -0
  247. package/src/styles/components/popover.css +8 -0
  248. package/src/styles/components/popup.css +331 -0
  249. package/src/styles/components/radio-button.css +130 -0
  250. package/src/styles/components/range-input.css +40 -0
  251. package/src/styles/components/rowitem.css +75 -0
  252. package/src/styles/components/search-input.css +89 -0
  253. package/src/styles/components/searchbar.css +46 -0
  254. package/src/styles/components/shape-icon.css +199 -0
  255. package/src/styles/components/slider.css +232 -0
  256. package/src/styles/components/snack.css +144 -0
  257. package/src/styles/components/tabs.css +128 -0
  258. package/src/styles/components/tagcloud.css +50 -0
  259. package/src/styles/components/text-area.css +176 -0
  260. package/src/styles/components/textlabel.css +75 -0
  261. package/src/styles/components/toggle-switch.css +147 -0
  262. package/src/styles/components/tooltip.css +93 -0
  263. package/src/styles/index.css +10 -0
  264. package/src/styles/preset.css +6 -0
  265. package/src/styles/theme/colors/base.css +108 -0
  266. package/src/styles/theme/colors/semantic.css +135 -0
  267. package/src/styles/theme/index.css +57 -0
  268. package/src/styles/theme/typography/base.css +53 -0
  269. package/src/styles/theme/typography/semantic.css +176 -0
  270. package/src/styles/theme/variables.css +83 -0
  271. package/ai/clad-ui-helper.js +0 -267
  272. package/ai/knowledge-base/README.md +0 -154
  273. package/ai/knowledge-base/clad-ui-database.json +0 -9378
  274. package/ai/knowledge-base/component-categories.json +0 -616
  275. package/ai/knowledge-base/components/metadata/charts-axis.json +0 -31
  276. package/ai/knowledge-base/components/metadata/charts-barchart.json +0 -57
  277. package/ai/knowledge-base/components/metadata/charts-basechart.tsx.json +0 -31
  278. package/ai/knowledge-base/components/metadata/charts-chartshared.json +0 -31
  279. package/ai/knowledge-base/components/metadata/charts-linechart.json +0 -189
  280. package/ai/knowledge-base/components/metadata/charts-piechart.json +0 -57
  281. package/ai/knowledge-base/components/metadata/components-announcer.json +0 -215
  282. package/ai/knowledge-base/components/metadata/components-badge.json +0 -168
  283. package/ai/knowledge-base/components/metadata/components-box.json +0 -348
  284. package/ai/knowledge-base/components/metadata/components-breadcrumbs.json +0 -75
  285. package/ai/knowledge-base/components/metadata/components-button.json +0 -187
  286. package/ai/knowledge-base/components/metadata/components-checkbox.json +0 -161
  287. package/ai/knowledge-base/components/metadata/components-chip.json +0 -266
  288. package/ai/knowledge-base/components/metadata/components-currencyinput.json +0 -136
  289. package/ai/knowledge-base/components/metadata/components-datepicker.json +0 -87
  290. package/ai/knowledge-base/components/metadata/components-dropdown.json +0 -282
  291. package/ai/knowledge-base/components/metadata/components-grid.json +0 -92
  292. package/ai/knowledge-base/components/metadata/components-input.json +0 -432
  293. package/ai/knowledge-base/components/metadata/components-pagination.json +0 -111
  294. package/ai/knowledge-base/components/metadata/components-popover.json +0 -63
  295. package/ai/knowledge-base/components/metadata/components-radiobutton.json +0 -170
  296. package/ai/knowledge-base/components/metadata/components-rowitem.json +0 -281
  297. package/ai/knowledge-base/components/metadata/components-shapeicon.json +0 -139
  298. package/ai/knowledge-base/components/metadata/components-slider.json +0 -177
  299. package/ai/knowledge-base/components/metadata/components-snack.json +0 -181
  300. package/ai/knowledge-base/components/metadata/components-tabs.json +0 -169
  301. package/ai/knowledge-base/components/metadata/components-textarea.json +0 -285
  302. package/ai/knowledge-base/components/metadata/components-textlabel.json +0 -129
  303. package/ai/knowledge-base/components/metadata/components-toggleswitch.json +0 -134
  304. package/ai/knowledge-base/components/metadata/components-tooltip.json +0 -291
  305. package/ai/knowledge-base/components/metadata/patterns-drawer.json +0 -310
  306. package/ai/knowledge-base/components/metadata/patterns-emptystate.json +0 -106
  307. package/ai/knowledge-base/components/metadata/patterns-inputgroup.json +0 -105
  308. package/ai/knowledge-base/components/metadata/patterns-legacydialog.json +0 -177
  309. package/ai/knowledge-base/components/metadata/patterns-legacypopup.json +0 -236
  310. package/ai/knowledge-base/components/metadata/patterns-multisearchdropdown.json +0 -249
  311. package/ai/knowledge-base/components/metadata/patterns-popup.json +0 -268
  312. package/ai/knowledge-base/components/metadata/patterns-rangeinput.json +0 -105
  313. package/ai/knowledge-base/components/metadata/patterns-searchbar.json +0 -150
  314. package/ai/knowledge-base/components/metadata/patterns-searchinput.json +0 -312
  315. package/ai/knowledge-base/components/metadata/patterns-tagcloud.json +0 -244
  316. package/ai/knowledge-base/components/metadata/summaries.json +0 -610
  317. package/ai/knowledge-base/design-tokens/tokens.json +0 -483
  318. package/ai/knowledge-base/patterns/documentation.json +0 -131
  319. package/ai/knowledge-base/prompts/common-system-prompt.md +0 -592
  320. package/ai/knowledge-base/prompts/figma-system-prompt.md +0 -396
  321. package/ai/knowledge-base/search-index/icons/asset-icons.json +0 -1
  322. package/ai/knowledge-base/search-index/icons/collection.json +0 -5
  323. package/ai/knowledge-base/search-index/icons/system-icons.json +0 -1
  324. package/ai/knowledge-base/search-index/search-index.json +0 -899
  325. package/ai/knowledge-base/validation-rules/component-rules.json +0 -658
  326. package/ai/skill/SKILL.md +0 -103
  327. package/dist/components/Announcer/Announcer.d.ts.map +0 -1
  328. package/dist/components/Announcer/Announcer.styles.d.ts +0 -30
  329. package/dist/components/Announcer/Announcer.styles.d.ts.map +0 -1
  330. package/dist/components/Badge/Badge.d.ts.map +0 -1
  331. package/dist/components/Badge/Badge.styles.d.ts +0 -26
  332. package/dist/components/Badge/Badge.styles.d.ts.map +0 -1
  333. package/dist/components/Box/Box.d.ts.map +0 -1
  334. package/dist/components/Box/Box.styles.d.ts +0 -21
  335. package/dist/components/Box/Box.styles.d.ts.map +0 -1
  336. package/dist/components/Breadcrumbs/BreadcrumbItem.d.ts.map +0 -1
  337. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts.map +0 -1
  338. package/dist/components/Breadcrumbs/Breadcrumbs.styles.d.ts +0 -10
  339. package/dist/components/Breadcrumbs/Breadcrumbs.styles.d.ts.map +0 -1
  340. package/dist/components/Button/Button.d.ts.map +0 -1
  341. package/dist/components/Button/Button.styles.d.ts +0 -3
  342. package/dist/components/Button/Button.styles.d.ts.map +0 -1
  343. package/dist/components/Button/ButtonLink.d.ts.map +0 -1
  344. package/dist/components/Button/GhostButton.d.ts.map +0 -1
  345. package/dist/components/Button/GhostButton.styles.d.ts +0 -3
  346. package/dist/components/Button/GhostButton.styles.d.ts.map +0 -1
  347. package/dist/components/Button/IconButton.d.ts.map +0 -1
  348. package/dist/components/Button/constant.d.ts.map +0 -1
  349. package/dist/components/Checkbox/Checkbox.d.ts.map +0 -1
  350. package/dist/components/Checkbox/Checkbox.styles.d.ts +0 -5
  351. package/dist/components/Checkbox/Checkbox.styles.d.ts.map +0 -1
  352. package/dist/components/Chip/Chip.d.ts.map +0 -1
  353. package/dist/components/Chip/Chip.styles.d.ts +0 -13
  354. package/dist/components/Chip/Chip.styles.d.ts.map +0 -1
  355. package/dist/components/CurrencyInput/CurrencyInput.d.ts.map +0 -1
  356. package/dist/components/CurrencyInput/CurrencyInput.styles.d.ts +0 -27
  357. package/dist/components/CurrencyInput/CurrencyInput.styles.d.ts.map +0 -1
  358. package/dist/components/CurrencyInput/utils/_cleanValue.d.ts +0 -12
  359. package/dist/components/CurrencyInput/utils/_cleanValue.d.ts.map +0 -1
  360. package/dist/components/CurrencyInput/utils/_formatValue.d.ts +0 -6
  361. package/dist/components/CurrencyInput/utils/_formatValue.d.ts.map +0 -1
  362. package/dist/components/DatePicker/DatePicker.d.ts.map +0 -1
  363. package/dist/components/DatePicker/DateTimePicker.d.ts.map +0 -1
  364. package/dist/components/DatePicker/DateTimePicker.styles.d.ts +0 -61
  365. package/dist/components/DatePicker/DateTimePicker.styles.d.ts.map +0 -1
  366. package/dist/components/Dropdown/Dropdown.d.ts.map +0 -1
  367. package/dist/components/Dropdown/Dropdown.styles.d.ts +0 -11
  368. package/dist/components/Dropdown/Dropdown.styles.d.ts.map +0 -1
  369. package/dist/components/Grid/Col.d.ts.map +0 -1
  370. package/dist/components/Grid/Grid.d.ts.map +0 -1
  371. package/dist/components/Grid/Grid.styles.d.ts +0 -33
  372. package/dist/components/Grid/Grid.styles.d.ts.map +0 -1
  373. package/dist/components/Input/Input.d.ts.map +0 -1
  374. package/dist/components/Input/Input.styles.d.ts +0 -36
  375. package/dist/components/Input/Input.styles.d.ts.map +0 -1
  376. package/dist/components/Pagination/PageItem.d.ts.map +0 -1
  377. package/dist/components/Pagination/Pagination.d.ts.map +0 -1
  378. package/dist/components/Pagination/Pagination.style.d.ts +0 -7
  379. package/dist/components/Pagination/Pagination.style.d.ts.map +0 -1
  380. package/dist/components/Popover/Popover.d.ts.map +0 -1
  381. package/dist/components/Popover/Popover.styles.d.ts +0 -4
  382. package/dist/components/Popover/Popover.styles.d.ts.map +0 -1
  383. package/dist/components/RadioButton/RadioButton.d.ts.map +0 -1
  384. package/dist/components/RadioButton/RadioButton.styles.d.ts +0 -12
  385. package/dist/components/RadioButton/RadioButton.styles.d.ts.map +0 -1
  386. package/dist/components/RowItem/RowItem.d.ts.map +0 -1
  387. package/dist/components/RowItem/RowItem.styles.d.ts +0 -33
  388. package/dist/components/RowItem/RowItem.styles.d.ts.map +0 -1
  389. package/dist/components/ShapeIcon/ShapeIcon.d.ts.map +0 -1
  390. package/dist/components/ShapeIcon/ShapeIcon.styles.d.ts +0 -15
  391. package/dist/components/ShapeIcon/ShapeIcon.styles.d.ts.map +0 -1
  392. package/dist/components/Slider/Slider.d.ts.map +0 -1
  393. package/dist/components/Slider/Slider.styles.d.ts +0 -24
  394. package/dist/components/Slider/Slider.styles.d.ts.map +0 -1
  395. package/dist/components/Snack/Snack.d.ts.map +0 -1
  396. package/dist/components/Snack/Snack.styles.d.ts +0 -20
  397. package/dist/components/Snack/Snack.styles.d.ts.map +0 -1
  398. package/dist/components/Tabs/Tab.d.ts.map +0 -1
  399. package/dist/components/Tabs/Tabs.d.ts.map +0 -1
  400. package/dist/components/Tabs/Tabs.styles.d.ts +0 -43
  401. package/dist/components/Tabs/Tabs.styles.d.ts.map +0 -1
  402. package/dist/components/TextArea/TextArea.d.ts.map +0 -1
  403. package/dist/components/TextArea/TextArea.styles.d.ts +0 -19
  404. package/dist/components/TextArea/TextArea.styles.d.ts.map +0 -1
  405. package/dist/components/TextLabel/TextLabel.d.ts.map +0 -1
  406. package/dist/components/TextLabel/TextLabel.styles.d.ts +0 -10
  407. package/dist/components/TextLabel/TextLabel.styles.d.ts.map +0 -1
  408. package/dist/components/ToggleSwitch/ToggleSwitch.d.ts.map +0 -1
  409. package/dist/components/ToggleSwitch/ToggleSwitch.styles.d.ts +0 -22
  410. package/dist/components/ToggleSwitch/ToggleSwitch.styles.d.ts.map +0 -1
  411. package/dist/components/Tooltip/Tooltip.d.ts.map +0 -1
  412. package/dist/components/Tooltip/Tooltip.styles.d.ts +0 -33
  413. package/dist/components/Tooltip/Tooltip.styles.d.ts.map +0 -1
  414. package/dist/components/index.d.ts +0 -62
  415. package/dist/components/index.d.ts.map +0 -1
  416. package/dist/css/baseline.d.ts +0 -15
  417. package/dist/css/baseline.d.ts.map +0 -1
  418. package/dist/index.d.ts.map +0 -1
  419. package/dist/patterns/Drawer/Drawer.d.ts +0 -110
  420. package/dist/patterns/Drawer/Drawer.d.ts.map +0 -1
  421. package/dist/patterns/Drawer/Drawer.styles.d.ts +0 -39
  422. package/dist/patterns/Drawer/Drawer.styles.d.ts.map +0 -1
  423. package/dist/patterns/EmptyState/EmptyState.d.ts +0 -36
  424. package/dist/patterns/EmptyState/EmptyState.d.ts.map +0 -1
  425. package/dist/patterns/EmptyState/EmptyState.styles.d.ts +0 -4
  426. package/dist/patterns/EmptyState/EmptyState.styles.d.ts.map +0 -1
  427. package/dist/patterns/InputGroup/InputGroup.d.ts +0 -26
  428. package/dist/patterns/InputGroup/InputGroup.d.ts.map +0 -1
  429. package/dist/patterns/InputGroup/InputGroup.styles.d.ts +0 -8
  430. package/dist/patterns/InputGroup/InputGroup.styles.d.ts.map +0 -1
  431. package/dist/patterns/LegacyDialog/DialogMainIcon.d.ts +0 -2
  432. package/dist/patterns/LegacyDialog/DialogMainIcon.d.ts.map +0 -1
  433. package/dist/patterns/LegacyDialog/LegacyDialog.d.ts.map +0 -1
  434. package/dist/patterns/LegacyDialog/LegacyDialog.styles.d.ts +0 -13
  435. package/dist/patterns/LegacyDialog/LegacyDialog.styles.d.ts.map +0 -1
  436. package/dist/patterns/LegacyPopup/LegacyPopup.d.ts.map +0 -1
  437. package/dist/patterns/LegacyPopup/LegacyPopup.styles.d.ts +0 -27
  438. package/dist/patterns/LegacyPopup/LegacyPopup.styles.d.ts.map +0 -1
  439. package/dist/patterns/MultiSearchDropdown/MultiSearchDropdown.d.ts.map +0 -1
  440. package/dist/patterns/MultiSearchDropdown/MultiSearchDropdown.styles.d.ts +0 -26
  441. package/dist/patterns/MultiSearchDropdown/MultiSearchDropdown.styles.d.ts.map +0 -1
  442. package/dist/patterns/Popup/Popup.d.ts +0 -92
  443. package/dist/patterns/Popup/Popup.d.ts.map +0 -1
  444. package/dist/patterns/Popup/Popup.styles.d.ts +0 -41
  445. package/dist/patterns/Popup/Popup.styles.d.ts.map +0 -1
  446. package/dist/patterns/RangeInput/RangeInput.d.ts.map +0 -1
  447. package/dist/patterns/RangeInput/RangeInput.styles.d.ts +0 -5
  448. package/dist/patterns/RangeInput/RangeInput.styles.d.ts.map +0 -1
  449. package/dist/patterns/SearchInput/SearchInput.d.ts.map +0 -1
  450. package/dist/patterns/SearchInput/SearchInput.styles.d.ts +0 -10
  451. package/dist/patterns/SearchInput/SearchInput.styles.d.ts.map +0 -1
  452. package/dist/patterns/Searchbar/Searchbar.d.ts.map +0 -1
  453. package/dist/patterns/Searchbar/Searchbar.styles.d.ts +0 -3
  454. package/dist/patterns/Searchbar/Searchbar.styles.d.ts.map +0 -1
  455. package/dist/patterns/TagCloud/TagCloud.d.ts +0 -76
  456. package/dist/patterns/TagCloud/TagCloud.d.ts.map +0 -1
  457. package/dist/patterns/TagCloud/TagCloud.styles.d.ts +0 -15
  458. package/dist/patterns/TagCloud/TagCloud.styles.d.ts.map +0 -1
  459. package/dist/patterns/TagCloud/TagCloudMultiActive.d.ts +0 -25
  460. package/dist/patterns/TagCloud/TagCloudMultiActive.d.ts.map +0 -1
  461. package/dist/patterns/TagCloud/TagCloudSingleActive.d.ts +0 -22
  462. package/dist/patterns/TagCloud/TagCloudSingleActive.d.ts.map +0 -1
  463. package/dist/patterns/index.d.ts +0 -23
  464. package/dist/patterns/index.d.ts.map +0 -1
  465. package/dist/theme/chotot.d.ts +0 -1371
  466. package/dist/theme/chotot.d.ts.map +0 -1
  467. package/dist/theme/ct-job.d.ts +0 -826
  468. package/dist/theme/ct-job.d.ts.map +0 -1
  469. package/dist/theme/ct-pty.d.ts +0 -826
  470. package/dist/theme/ct-pty.d.ts.map +0 -1
  471. package/dist/theme/ct-veh.d.ts +0 -591
  472. package/dist/theme/ct-veh.d.ts.map +0 -1
  473. package/dist/theme/index.d.ts +0 -5
  474. package/dist/theme/index.d.ts.map +0 -1
  475. package/dist/theme/mudah.d.ts +0 -248
  476. package/dist/theme/mudah.d.ts.map +0 -1
  477. package/dist/theme/types.d.ts +0 -58
  478. package/dist/theme/types.d.ts.map +0 -1
  479. package/dist/theme-chotot.css +0 -2
  480. package/dist/theme-job.css +0 -2
  481. package/dist/theme-pty.css +0 -2
  482. package/dist/theme-veh.css +0 -2
  483. package/dist/typography/BodyAnnotation.d.ts.map +0 -1
  484. package/dist/typography/BodyCaption.d.ts.map +0 -1
  485. package/dist/typography/BodyPage.d.ts.map +0 -1
  486. package/dist/typography/BodySection.d.ts.map +0 -1
  487. package/dist/typography/DisplayAnnotation.d.ts.map +0 -1
  488. package/dist/typography/DisplayCaption.d.ts.map +0 -1
  489. package/dist/typography/DisplayPage.d.ts.map +0 -1
  490. package/dist/typography/DisplaySection.d.ts.map +0 -1
  491. package/dist/typography/HeaderAnnotation.d.ts.map +0 -1
  492. package/dist/typography/HeaderCaption.d.ts.map +0 -1
  493. package/dist/typography/HeaderPage.d.ts.map +0 -1
  494. package/dist/typography/HeaderSection.d.ts.map +0 -1
  495. package/dist/typography/LabelAnnotation.d.ts.map +0 -1
  496. package/dist/typography/LabelCaption.d.ts.map +0 -1
  497. package/dist/typography/LabelPage.d.ts.map +0 -1
  498. package/dist/typography/LabelSection.d.ts.map +0 -1
  499. package/dist/typography/NoteCaption.d.ts.map +0 -1
  500. package/dist/typography/NotePage.d.ts.map +0 -1
  501. package/dist/typography/NoteSection.d.ts.map +0 -1
  502. package/dist/typography/TaglineAnnotation.d.ts.map +0 -1
  503. package/dist/typography/TaglineCaption.d.ts.map +0 -1
  504. package/dist/typography/TaglineFootext.d.ts.map +0 -1
  505. package/dist/typography/TaglineSection.d.ts.map +0 -1
  506. package/dist/typography/index.d.ts.map +0 -1
  507. package/dist/utils/_inlineCreatePortal.d.ts.map +0 -1
  508. package/dist/utils/_normalizeArrowKey.d.ts +0 -10
  509. package/dist/utils/_normalizeArrowKey.d.ts.map +0 -1
  510. package/dist/utils/_simulateChangeEvent.d.ts +0 -25
  511. package/dist/utils/_simulateChangeEvent.d.ts.map +0 -1
  512. package/dist/utils/cleanHtml.d.ts.map +0 -1
  513. package/dist/utils/createUniversalPortal.d.ts.map +0 -1
  514. package/dist/utils/cx.d.ts +0 -22
  515. package/dist/utils/cx.d.ts.map +0 -1
  516. package/dist/utils/getBreakpointsValues.d.ts.map +0 -1
  517. package/dist/utils/index.d.ts +0 -7
  518. package/dist/utils/index.d.ts.map +0 -1
  519. package/dist/utils/noop.d.ts +0 -9
  520. package/dist/utils/noop.d.ts.map +0 -1
  521. package/dist/utils/scrollLock/index.d.ts +0 -7
  522. package/dist/utils/scrollLock/index.d.ts.map +0 -1
  523. package/dist/utils/scrollLock/scrollLock.styles.d.ts +0 -6
  524. package/dist/utils/scrollLock/scrollLock.styles.d.ts.map +0 -1
  525. package/dist/utils/scrollLock/useBodyScrollLock.d.ts.map +0 -1
  526. package/dist/utils/scrollTop.d.ts +0 -8
  527. package/dist/utils/scrollTop.d.ts.map +0 -1
  528. package/dist/utils/sx.d.ts +0 -174
  529. package/dist/utils/sx.d.ts.map +0 -1
  530. package/dist/utils/types.d.ts.map +0 -1
  531. package/theme/__snapshots__/chotot.spec.js.snap +0 -519
  532. package/theme/__snapshots__/mudah.spec.js.snap +0 -161
  533. package/theme/chotot.js +0 -1336
  534. package/theme/chotot.spec.js +0 -72
  535. package/theme/ct-job.js +0 -92
  536. package/theme/ct-pty.js +0 -92
  537. package/theme/ct-veh.js +0 -92
  538. package/theme/index.ts +0 -10
  539. package/theme/mudah.js +0 -333
  540. package/theme/mudah.spec.js +0 -9
  541. package/theme/types.ts +0 -61
@@ -0,0 +1,124 @@
1
+ ---
2
+ name: migrate-clad-ui-v3
3
+ description: Migrate consumer React/Next.js code from @chotot/clad-ui v2 (Linaria) to @chotot/clad-ui v3 (Tailwind CSS v4) and @chotot/icons. Supports incremental file/feature migration (coexistence via @chotot/clad-ui-v2 alias) and full-repo cutover. Not for building new v3 UI from scratch, use clad-ui instead.
4
+ metadata:
5
+ purpose: Migrate consumer React/Next.js code from @chotot/clad-ui v2 (Linaria) to @chotot/clad-ui v3 (Tailwind CSS v4) and @chotot/icons. Supports incremental file/feature migration (coexistence via @chotot/clad-ui-v2 alias) and full-repo cutover. Not for building new v3 UI from scratch, use clad-ui instead.
6
+ type: lifecycle
7
+ library: '@chotot/clad-ui'
8
+ library_version: '3.0.0-next.5'
9
+ requires:
10
+ - clad-ui
11
+ sources:
12
+ - 'carousell/clad-ui:packages/clad-ui/src/**'
13
+ ---
14
+
15
+ # Migrate `@chotot/clad-ui` v2 (Linaria) → `@chotot/clad-ui` v3 (Tailwind CSS v4)
16
+
17
+ ## Role
18
+
19
+ You are a Clad UI v2-to-v3 migration operator for consumer repositories.
20
+ You convert `@chotot/clad-ui` v2 (or `@chotot/clad-ui-v2` alias) imports, legacy component props, and Linaria `css`/`styled` blocks to `@chotot/clad-ui` v3 and `@chotot/icons` without breaking visual parity or unmigrated files.
21
+
22
+ ## Purpose
23
+
24
+ Use this skill to migrate a specific file, feature folder, or an entire consumer repository from `@chotot/clad-ui` v2 (Linaria) to `@chotot/clad-ui` v3 (Tailwind CSS v4) + `@chotot/icons`.
25
+
26
+ ## Inputs
27
+
28
+ Required:
29
+ - `target`: file path, directory path, or `"repo"` (full repository migration)
30
+
31
+ Optional:
32
+ - `theme`: vertical theme (`"chotot"` | `"pty"` | `"job"` | `"veh"`, defaults to existing repo theme or `"chotot"`)
33
+
34
+ Missing required input:
35
+ - do not continue with unresolved required input
36
+ - try to infer `target` from the explicit user request or currently open/modified files
37
+ - if one safe candidate exists, use it and report the assumption
38
+ - if multiple risky candidates exist, ask one clear question
39
+ - if it still cannot be resolved safely, return a stop output
40
+
41
+ ## Read Path
42
+
43
+ Required reads:
44
+ - [references/component-api-changes.md](references/component-api-changes.md) — import path rewrites, `data-theme` setup, `extraClasses` → `className`, and per-component prop/variant migrations.
45
+
46
+ Conditional reads:
47
+ - [references/token-and-linaria-mapping.md](references/token-and-linaria-mapping.md) — read when target files contain `@linaria/core` (`css`), `@linaria/react` (`styled`), `theme.*` tokens, or `var(--clad-*)` CSS variables.
48
+ - `../clad-ui/SKILL.md` (and its `references/*.md`) — read when verifying v3 component props or event payloads during complex rewrites.
49
+
50
+ Discovery reads:
51
+ - Root `package.json` and root layout (`_app.tsx`, `layout.tsx`, or global `.css`) to check whether `@chotot/clad-ui` v3 and its stylesheet are already wired.
52
+ - `node_modules/@chotot/clad-ui/dist/components/<Name>/types.d.ts` when an edge-case component prop is unclear.
53
+
54
+ ## Workflow
55
+
56
+ 1. **Verify root package & stylesheet setup (`package.json` + root layout).**
57
+ - Inspect `package.json`. Ensure `@chotot/clad-ui` (`^3.0.0`) is installed (`pnpm add @chotot/clad-ui@^3.0.0`; `@chotot/icons` is automatically installed as a direct dependency of `@chotot/clad-ui`) and `"@chotot/clad-ui"` is listed in `pnpm.onlyBuiltDependencies`. (For **Incremental Coexistence mode** where unmigrated files still rely on v2 Linaria, alias v2 as `"@chotot/clad-ui-v2": "npm:@chotot/clad-ui@^2"` per [references/component-api-changes.md](references/component-api-changes.md)).
58
+ - Check the root layout (`_app.tsx` / `layout.tsx` / global CSS):
59
+ - Ensure `@chotot/clad-ui/styles.css` (or `@import "@chotot/clad-ui/preset.css"`) is imported once.
60
+ - Ensure the root wrapper sets `data-theme="chotot|pty|job|veh"` (coexisting with or replacing legacy `chototTheme`/`baselineStyles` per [references/component-api-changes.md](references/component-api-changes.md)).
61
+
62
+ 2. **Rewrite imports in `target` files.**
63
+ - Follow [references/component-api-changes.md](references/component-api-changes.md) Section 1:
64
+ - `@chotot/clad-ui/components/*`, `@chotot/clad-ui/patterns/*`, `@chotot/clad-ui/typography`, `@chotot/clad-ui/brand` (and any `@chotot/clad-ui-v2*` alias imports) → named imports from root `@chotot/clad-ui`.
65
+ - `@chotot/clad-ui/icons` named imports stay unchanged (`import { Close } from '@chotot/clad-ui/icons'`); rewrite any deep icon imports (`@chotot/clad-ui/icons/<Name>` or `/icons/index`) to named imports from `@chotot/clad-ui/icons`.
66
+ - `@chotot/clad-ui/utils/bundleCss` → `import { getBundledCss } from '@chotot/clad-ui/utils/bundleCss'`.
67
+
68
+ 3. **Migrate component props & variants in `target` files.**
69
+ - Apply [references/component-api-changes.md](references/component-api-changes.md) Sections 3–4:
70
+ - Rename `extraClasses` → `className`.
71
+ - Map deprecated `Button` colors (`critical` → `error`, `positive` → `success`, `chotot`/`caution`/`accent` → `primary`); both shorthand (`sm` | `md` | `lg` | `xl`) and word (`small` | `medium` | `large` | `xlarge`) sizes are supported.
72
+ - Map `Chip` / `TagCloud` `variant="normal"` → `variant="fill"` (and review `Chip` `size`: v3 default `'md'` is 32px, `'sm'` is 24px, `'lg'` is 40px).
73
+ - Map `RowItem` `type="menu"` → `type="chevron"`.
74
+ - Map `Badge` `bg` → `backgroundColor`.
75
+
76
+ 4. **Convert Linaria `css` / `styled` blocks and `theme.*` tokens in `target` files.**
77
+ - If the file imports `@linaria/core`, `@linaria/react`, or `@chotot/clad-ui/theme/*`, read [references/token-and-linaria-mapping.md](references/token-and-linaria-mapping.md).
78
+ - Replace `styled.<tag>` and `css\`...\`` with Tailwind utility classes and Clad semantic tokens (`bg-background-*`, `text-text-*`, `border-border-*`, `text-icon-*`, `text-{display,header,label,body}-*`), merging conditional classes via `cn` from `@chotot/clad-ui`.
79
+ - Map `theme.mediaQueries.tablet` → `md:` (`768px`) and `theme.mediaQueries.desktop` → `min-[992px]:`.
80
+ - Avoid the 3 common Linaria-to-Tailwind pitfalls in [references/token-and-linaria-mapping.md](references/token-and-linaria-mapping.md) Section 1.1: use `text-[24px]`/`text-[20px]` instead of `text-2xl`/`text-xl` when only `font-size` was set without `line-height`; strip spaces inside `var(--x,0px)` arbitrary values; and map wrapper `gap` props via `cn(gapClass, className)` rather than inline `style={{ gap }}`.
81
+
82
+ 5. **Run Coexistence vs Full-Repo Cutover check and verify.**
83
+ - Run across the entire repo:
84
+ ```bash
85
+ rg "@chotot/clad-ui-v2|@chotot/clad-ui/(components|patterns|typography|brand|theme)|@linaria/(core|react)" src/ pages/ app/ components/ 2>/dev/null
86
+ ```
87
+ - **If matches remain outside `target` (Incremental Coexistence mode):** do **not** remove `@chotot/clad-ui-v2`, `@linaria/*`, `next-linaria`, `.babelrc`, `@clad-ui/theme` aliases, or `withCladUi` / `withLinaria` in `next.config.js`.
88
+ - **If 0 matches remain across the entire repo (Full-Repo Cutover mode):** remove `@chotot/clad-ui-v2` (if aliased), `@linaria/*`, `next-linaria`, `react-laag`, `@chotot/clad-ui/babel`, `@clad-ui/theme` aliases, and `withCladUi` / `withLinaria` from `package.json`, `.babelrc` / `babel.config.js`, and `next.config.js` per [references/component-api-changes.md](references/component-api-changes.md) Section 5.
89
+ - Verify `target` has 0 remaining v2 subpath/alias or `@linaria/*` imports and 0 leftover codemod placeholders (`rg "__[A-Z0-9_]+__"`), then run the repo's typecheck (`pnpm type-check` / `tsc --noEmit`) and lint (`pnpm lint`).
90
+
91
+ ## Guardrails
92
+
93
+ - Do not remove `@chotot/clad-ui-v2`, `@linaria/*`, `next-linaria`, or Babel/Next Linaria plugins while any file in the repository still imports them.
94
+ - Do not replace `theme.colors.*` with raw hex values (`bg-[#ffd400]`) or base Tailwind palette colors (`bg-gray-100`); always use Clad semantic tokens from [references/token-and-linaria-mapping.md](references/token-and-linaria-mapping.md).
95
+ - Do not map `theme.mediaQueries.desktop` (`992px`) to default `md:` (`768px`); use `min-[992px]:`.
96
+ - Do not invent component props; verify against `references/` or `node_modules/@chotot/clad-ui/dist/components/<Name>/types.d.ts`.
97
+ - Do not commit, push, or publish unless the user explicitly asks.
98
+
99
+ ## Feedback Protocol (Consumer Persona)
100
+
101
+ Only when you hit a real migration gap, component parity bug, or missing prop/icon in `@chotot/clad-ui` / `@chotot/icons` during consumer migration:
102
+ - Finish the current migration step first (stay silent if migration worked cleanly; max 1 callout per turn).
103
+ - Append a 1-line callout at the very end of your response:
104
+ > 💡 **clad-ui**: <1-sentence description of the migration gap or bug>. Bạn có muốn tạo GitHub issue lên `carousell/clad-ui` (qua skill `clad-ui-feedback`) không?
105
+ - If the user agrees, follow [../clad-ui-feedback/SKILL.md](../clad-ui-feedback/SKILL.md).
106
+
107
+ ## Output
108
+
109
+ ```yaml
110
+ - step: <completed workflow step>
111
+ - result: continue | waiting_for_user | stop
112
+ - mode: incremental-coexistence | full-repo-cutover
113
+ - files_migrated:
114
+ - <path>
115
+ - remaining_v2_files_in_repo: <count>
116
+ - verification:
117
+ - v2_imports_in_target: 0
118
+ - typecheck: pass | fail | skipped
119
+ - lint: pass | fail | skipped
120
+ - open_questions:
121
+ - <question if any>
122
+ - next_action:
123
+ - <suggested next action>
124
+ ```
@@ -0,0 +1,4 @@
1
+ interface:
2
+ display_name: "Migrate Clad UI v2 to v3"
3
+ short_description: "Migrate consumer React/Next.js files or repositories from @chotot/clad-ui v2 (Linaria) to @chotot/clad-ui v3 (Tailwind CSS v4) and @chotot/icons."
4
+ default_prompt: "Use $migrate-clad-ui-v3 to migrate the target files or repository from @chotot/clad-ui v2 (Linaria) to @chotot/clad-ui v3 and @chotot/icons following the 5-step dual-mode workflow."
@@ -0,0 +1,145 @@
1
+ # Clad UI v2 → v3 Component & Import API Changes
2
+
3
+ ## Contents
4
+
5
+ - [1. Import Path Rewrites](#1-import-path-rewrites)
6
+ - [2. Theme Provider & Global CSS Setup](#2-theme-provider--global-css-setup)
7
+ - [3. Universal Component Prop Changes](#3-universal-component-prop-changes)
8
+ - [4. Per-Component Prop & Variant Migrations](#4-per-component-prop--variant-migrations)
9
+ - [5. Full-Repo Dependency & Build Config Cleanup](#5-full-repo-dependency--build-config-cleanup)
10
+
11
+ ---
12
+
13
+ ## 1. Import Path Rewrites
14
+
15
+ All components, 24 Typography components, layout primitives, and utilities are exported from the root `@chotot/clad-ui` (v3) entry point. Icons are exported from `@chotot/clad-ui/icons` (backed by `@chotot/icons` as a direct dependency of `@chotot/clad-ui`).
16
+ *(If migrating incrementally while v2 and v3 coexist in `package.json`, alias v2 as `"@chotot/clad-ui-v2": "npm:@chotot/clad-ui@^2"` while installing v3 as `"@chotot/clad-ui": "^3.0.0"`).*
17
+
18
+ | v2 Import Path | v3 Import Path |
19
+ |---|---|
20
+ | `import { Button, Drawer, cx } from '@chotot/clad-ui'` | `import { Button, Drawer, cn } from '@chotot/clad-ui'` |
21
+ | `import Button from '@chotot/clad-ui/components/Button'` | `import { Button } from '@chotot/clad-ui'` (named export) |
22
+ | `import { BodySection, HeaderPage } from '@chotot/clad-ui/typography'` | `import { BodySection, HeaderPage } from '@chotot/clad-ui'` |
23
+ | `import { ChototLogoText, CtC2C, CtProperty, CtVehicle, Tot } from '@chotot/clad-ui/brand'` | `import { ChototLogoText, CtC2C, CtProperty, CtVehicle, Tot } from '@chotot/clad-ui'` |
24
+ | `import { Close, ChevronRight } from '@chotot/clad-ui/icons'` | `import { Close, ChevronRight } from '@chotot/clad-ui/icons'` (unchanged!) |
25
+ | `import Close from '@chotot/clad-ui/icons/Close'` (or `/icons/index`) | `import { Close } from '@chotot/clad-ui/icons'` (named export) |
26
+ | `import bundleCss from '@chotot/clad-ui/utils/bundleCss'` | `import { getBundledCss } from '@chotot/clad-ui/utils/bundleCss'` |
27
+ | `import clsx from 'clsx'` / `import { twMerge } from 'tailwind-merge'` | `import { cn } from '@chotot/clad-ui'` (token-aware `shadcn-ui/cn`) |
28
+
29
+ > **Important:** v2 allowed default imports from deep paths (`import Button from '@chotot/clad-ui/components/Button'`). In v3, always use **named imports** from `'@chotot/clad-ui'`.
30
+
31
+ ---
32
+
33
+ ## 2. Theme Provider & Global CSS Setup
34
+
35
+ ### 2.1 Stylesheet Import (Root `_app.tsx` or `layout.tsx`)
36
+ - Pre-compiled CSS (any bundler):
37
+ ```tsx
38
+ import '@chotot/clad-ui/styles.css';
39
+ ```
40
+ - Tailwind CSS v4 preset (inside global `.css`, omitting Tailwind preflight so Clad UI's `baseline.css` is not overridden):
41
+ ```css
42
+ @layer theme, base, components, utilities;
43
+ @import "tailwindcss/theme.css" layer(theme);
44
+ @import "tailwindcss/utilities.css" layer(utilities);
45
+ @import "@chotot/clad-ui/preset.css";
46
+ ```
47
+
48
+ ### 2.2 Replace `chototTheme` / `baselineStyles` with `data-theme`
49
+ ```tsx
50
+ // @ts-nocheck — legacy v2 example
51
+ // BEFORE (v2)
52
+ import { baselineStyles, cx } from '@chotot/clad-ui';
53
+ import ptyTheme from '@chotot/clad-ui/theme/ct-pty';
54
+
55
+ <div className={cx(String(ptyTheme), baselineStyles)}>{children}</div>
56
+ ```
57
+
58
+ ```tsx
59
+ // AFTER (v3)
60
+ // Values: "chotot" (default), "pty" (Nhà Tốt), "job" (Việc Làm Tốt), "veh" (Chợ Tốt Xe)
61
+ <div data-theme="pty">{children}</div>
62
+ ```
63
+
64
+ ---
65
+
66
+ ## 3. Universal Component Prop Changes
67
+
68
+ | v2 Pattern | v3 Replacement |
69
+ |---|---|
70
+ | `extraClasses="my-class"` | `className="my-class"` (`className` is merged after variant classes via `cn`) |
71
+ | `import { cx } from '@chotot/clad-ui/utils'` (or `@chotot/clad-ui`) | `import { cn } from '@chotot/clad-ui'` |
72
+
73
+ ---
74
+
75
+ ## 4. Per-Component Prop & Variant Migrations
76
+
77
+ ### Button (`IconButton`, `GhostButton`, `ButtonLink`)
78
+ - **Dropped deprecated `color` values:**
79
+ - `color="chotot"` → `color="primary"`
80
+ - `color="critical"` → `color="error"`
81
+ - `color="positive"` → `color="success"`
82
+ - `color="caution"` / `color="accent"` → `color="primary"` (or `color="neutral"`)
83
+ - Valid v3 `color` values: `'primary' | 'info' | 'success' | 'error' | 'neutral' | 'tertiary'`.
84
+ - **Valid `variant` values:** `'solid' | 'outline' | 'tonal'`.
85
+ - **Valid `size` values:** `'sm' | 'md' | 'lg' | 'xl'` (or `'small' | 'medium' | 'large' | 'xlarge'`).
86
+
87
+ ### Chip & TagCloud
88
+ - `variant="normal"` → `variant="fill"` (`'normal'` is kept as a backward-compatible alias).
89
+ - `Chip` `size` is standardized to `'sm'` (24px) | `'md'` (32px, default) | `'lg'` (40px, with `'xl'` kept as a backward-compatible alias for 40px). Note that in v2 `size="lg"` was 32px; in v3 32px is `size="md"` (default) and `size="lg"` is 40px.
90
+ - `TagCloud` also accepts `variant?: 'fill' | 'normal' | 'outline'` (defaults to `'fill'`).
91
+
92
+ ### Input Family (`Input`, `CurrencyInput`, `TextArea`, `Dropdown`, `MultiSearchDropdown`, `SearchInput`, `InputGroup`)
93
+ - `Input`, `CurrencyInput`, and `TextArea` now support `status?: 'default' | 'error' | 'warning' | 'success'` (adds `'warning'` with `--color-border-warning` / `--color-text-warning`).
94
+ - Across the entire input family, resting border is unified to `1px solid var(--color-border-thin)` (`#e8e8e8`), disabled border is `2px solid var(--color-border-disabled)` (`#c0c0c0`), and default helptext color is `var(--color-text-secondary)` (`#595959`).
95
+ - **Legacy wrapper descendant selectors (migrate-only):** Do not introduce new descendant selectors targeting internal DOM classes (Hyrum's Law). However, when migrating an existing v2 wrapper component (e.g. `InputPhoneWrapper`) that already targets v2 internal classes, update the selectors to v3's BEM classes:
96
+ - `.hasLeftIcon` (wrapper) → `.input--has-left-icon` (wrapper) and `.input-icon-left` (left icon container)
97
+ - `.noLabel` (wrapper) → `.input--no-label`
98
+ - `input.hasValue` → `.input-el.has-value`
99
+ - `input.required` → `.input-el.is-required`
100
+
101
+ ### Checkbox
102
+ - Supports `indeterminate?: boolean` (renders the minus indicator, applies `.checkbox--indeterminate`, sets `aria-checked="mixed"`, and syncs the native `input.indeterminate` DOM property).
103
+
104
+ ### EmptyState
105
+ - `type` now supports 4 additional Figma v3.0 presets alongside the original 8 types: `'notFoundWhite' | 'working' | 'waitingCv' | 'noReward'`.
106
+ - Supports optional visibility toggles: `showTitle?: boolean`, `showDescription?: boolean`, `showButton?: boolean` (all default to `true`).
107
+
108
+ ### Box & Grid
109
+ - Style-prop token maps (`themeTokens.ts`) additionally accept v3 semantic keys on `borderRadius` (`'adSmall' | 'ad' | 'cardSmall' | 'card' | 'decoration' | 'modal'`), `boxShadow` (`'below' | 'floating'`), and `color` / `bg` (`'backgroundApp' | 'backgroundBrandLightSecondary' | 'backgroundDisable' | 'buttonNeutral' | 'skeletonBackground' | 'skeletonItem' | 'logoPrimary' | 'logoSecondary' | 'logoOnBlack'`).
110
+
111
+ ### RowItem
112
+ - `type="menu"` (v2 alias) → `type="chevron"` (valid v3 `type` values: `'list' | 'radio' | 'checkbox' | 'chevron' | 'accordion'`).
113
+ - Main row title is passed as `children`; secondary text is `description="..."`.
114
+ - `onChange` signature for `checkbox`/`radio`: `(e: { value: string, checked: boolean }) => void`.
115
+
116
+ ### Badge
117
+ - `bg` prop → `backgroundColor` (`'error' | 'warning' | 'info' | 'success' | 'neutral'`).
118
+ - Uses `variant` (`'solid' | 'tonal'`), `size` (`'sm' | 'md' | 'lg' | 'dot'`), `position` (`'topRight' | 'topLeft' | 'right'`), and `borderRadius` (`'none' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'pill' | 'circle'`).
119
+
120
+ ### TextLabel
121
+ - Valid props: `color` (`'info' | 'success' | 'error' | 'warning' | 'neutral'`), `size` (`'md' | 'sm'`), `type` (`'text' | 'status'`), `label` (`string`), `icon` (`ReactNode`).
122
+
123
+ ### Drawer & Popup
124
+ - Both legacy monolithic props (`<Drawer open={open} title="..." primaryBtnLabel="..." disablePrimaryButton onClose={fn}>`) and compound slots (`<Drawer.Container>`, `<Drawer.Header>`, `<Drawer.Body>`, `<Drawer.Button>`) are supported in v3.
125
+ - `data-clad="Drawer"` is placed exclusively on the root `.drawer` dialog element (1 open Drawer = 1 `[data-clad="Drawer"]`), while inner slots use `data-clad="Drawer.Header"`, `data-clad="Drawer.Body"`, and `data-clad="Drawer.Button"`. Pass `id` or `data-testid` to distinguish multiple open Drawers/Popups, and use `contentClassName` (applied to `.drawer-children-content`) when styling the scrollable body of a legacy `<Drawer>`.
126
+ - `LegacyDialog` (`DialogMainIcon`) and `LegacyPopup` are also exported from `@chotot/clad-ui` for 1:1 drop-in compatibility.
127
+
128
+ ### Floating Components (`Tooltip`, `Popover`, `Dropdown`, `MultiSearchDropdown`, `SearchInput`, `DatePicker`, `DateTimePicker`)
129
+ - Migrated internally from `react-laag` to `@floating-ui/react-dom`.
130
+ - Public React props (`placement`, `open`, `anchorEl`, `onOutsideClick`, etc.) remain 100% compatible; consumer repos no longer need `react-laag` in `package.json`.
131
+
132
+ ---
133
+
134
+ ## 5. Full-Repo Dependency & Build Config Cleanup
135
+
136
+ **Only run this step when `rg "@chotot/clad-ui-v2|@chotot/clad-ui/(components|patterns|typography|brand|theme)|@linaria/"` returns 0 matches across the entire repository:**
137
+
138
+ 1. **`package.json`:**
139
+ - Remove `@chotot/clad-ui-v2` (if aliased), `@linaria/core`, `@linaria/react`, `@linaria/babel-preset`, `@linaria/webpack-loader`, `next-linaria`, `react-laag`.
140
+ - Ensure `@chotot/clad-ui` (`^3.0.0`) is present in `dependencies`.
141
+ - Ensure `"@chotot/clad-ui"` is listed in `pnpm.onlyBuiltDependencies`.
142
+ 2. **Babel (`.babelrc` / `babel.config.js`):**
143
+ - Remove `@chotot/clad-ui/babel`, `@linaria` presets/plugins, and any `module-resolver` alias for `@clad-ui/theme`.
144
+ 3. **Next.js (`next.config.js` / `next.config.mjs` / `withCladUi.js`):**
145
+ - Remove `withCladUi(...)` / `withLinaria(...)` wrappers, `@clad-ui/theme` webpack aliases, and `transpilePackages: ['@chotot/clad-ui']`.
@@ -0,0 +1,194 @@
1
+ # Clad UI v2 (Linaria) → v3 (Tailwind) Token & Style Mapping
2
+
3
+ ## Contents
4
+
5
+ - [1. Replacing Linaria `css` and `styled` Blocks](#1-replacing-linaria-css-and-styled-blocks)
6
+ - [2. Semantic Color Tokens (`theme.colors.*` & `var(--clad-*)`)](#2-semantic-color-tokens-themecolors--var--clad-)
7
+ - [3. Legacy `@deprecated` v2 Colors → v3 Semantic Tokens](#3-legacy-deprecated-v2-colors--v3-semantic-tokens)
8
+ - [4. Interaction State Tokens](#4-interaction-state-tokens)
9
+ - [5. Typography (`theme.typo.*` & `theme.fontSizes.*`)](#5-typography-themetypo--themefontsizes)
10
+ - [6. Spacing, Sizes, Radii, Strokes, Shadows & Z-Index](#6-spacing-sizes-radii-strokes-shadows--z-index)
11
+ - [7. Breakpoints & Media Queries (`theme.mediaQueries.*`)](#7-breakpoints--media-queries-thememediaqueries)
12
+
13
+ ---
14
+
15
+ ## 1. Replacing Linaria `css` and `styled` Blocks
16
+
17
+ Remove `import { css } from '@linaria/core'` and `import { styled } from '@linaria/react'`. Convert static styles to Tailwind utility classes and `cn` from `@chotot/clad-ui`:
18
+
19
+ ```tsx
20
+ // @ts-nocheck — legacy v2 example
21
+ // BEFORE (v2 Linaria)
22
+ import { css } from '@linaria/core';
23
+ import { styled } from '@linaria/react';
24
+ import { cx } from '@chotot/clad-ui';
25
+ import theme from '@chotot/clad-ui/theme/chotot';
26
+
27
+ const Card = styled.div`
28
+ background-color: ${theme.colors.backgroundPrimary};
29
+ border: 1px solid ${theme.colors.borderRegular};
30
+ border-radius: ${theme.radii.md};
31
+ padding: ${theme.space.md};
32
+ @media ${theme.mediaQueries.tablet} {
33
+ padding: ${theme.space.lg};
34
+ }
35
+ `;
36
+
37
+ const titleStyle = css`
38
+ ${theme.typo.header.section};
39
+ color: ${theme.colors.textPrimary};
40
+ `;
41
+ ```
42
+
43
+ ```tsx
44
+ // AFTER (v3 Tailwind)
45
+ import { cn } from '@chotot/clad-ui';
46
+
47
+ <div className={cn('bg-background-primary border border-border-regular rounded-lg p-4 md:p-6', className)}>
48
+ <h2 className="text-header-section text-text-primary">{title}</h2>
49
+ </div>
50
+ ```
51
+
52
+ ### 1.1 Three Common Linaria → Tailwind Layout Pitfalls
53
+ 1. **Standalone `font-size` without `line-height` (`text-[24px]` vs `text-2xl`):**
54
+ - When a v2 Linaria rule only sets `font-size: 24px` (or `${theme.fontSizes.xxl}` / `${theme.fontSizes.xl}`) without setting `line-height` (common on icon wrappers and compact buttons), **do not** convert it to Tailwind's `text-2xl` (`font-size: 1.5rem; line-height: 2rem`) or `text-xl` (`line-height: 1.75rem`). Tailwind's built-in `line-height` will inflate the element's height (`24px` → `32px`). Use arbitrary font-size `text-[24px]` / `text-[20px]` to preserve inherited `line-height`.
55
+ 2. **CSS `var(--custom, fallback)` inside shorthand properties:**
56
+ - Never split a CSS `var()` fallback containing spaces across multiple utilities (e.g., converting `padding: var(--global-padding, 0px)` into broken `py-[var(--global-padding,] px-[0px)]`). Strip spaces inside `var(...)` and use a single arbitrary utility: `p-[var(--global-padding,0px)]`.
57
+ 3. **Layout wrapper props (`gap`, etc.) vs `className` override:**
58
+ - When migrating a reusable layout primitive (`Stack`, `Flex`) that accepts both a `gap` prop and `className`, map `gap` to a Tailwind `gap-*` class placed **before** `className` inside `cn(gapClass, className)`. Do not assign `style={{ gap }}` when `className` is also used to pass `gap-*` overrides, because inline `style.gap` always wins over CSS classes.
59
+
60
+ ---
61
+
62
+ ## 2. Semantic Color Tokens (`theme.colors.*` & `var(--clad-*)`)
63
+
64
+ General rule: `theme.colors.fooBarBaz` / `var(--clad-foo-bar-baz)` → CSS variable `var(--color-foo-bar-baz)`.
65
+
66
+ | v2 `theme.colors.*` | v2 CSS Variable | v3 Tailwind Utility | v3 CSS Variable |
67
+ |---|---|---|---|
68
+ | `backgroundApp` *(new in v3)* | — | `bg-background-app` | `var(--color-background-app)` (`#f7f7f7`) |
69
+ | `backgroundBrand` | `var(--clad-background-brand)` | `bg-background-brand` | `var(--color-background-brand)` |
70
+ | `backgroundBrandLight` | `var(--clad-background-brand-light)` | `bg-background-brand-light` | `var(--color-background-brand-light)` |
71
+ | `backgroundBrandLightSecondary` *(new in v3)* | — | `bg-background-brand-light-secondary` | `var(--color-background-brand-light-secondary)` |
72
+ | `backgroundChotot` | `var(--clad-background-chotot)` | `bg-background-chotot` | `var(--color-background-chotot)` |
73
+ | `backgroundAppwrapper` | `var(--clad-background-appwrapper)` | `bg-background-appwrapper` | `var(--color-background-appwrapper)` (`#ffd400`) |
74
+ | `backgroundPrimary` | `var(--clad-background-primary)` | `bg-background-primary` | `var(--color-background-primary)` |
75
+ | `backgroundSecondary` | `var(--clad-background-secondary)` | `bg-background-secondary` | `var(--color-background-secondary)` |
76
+ | `backgroundTertiary` | `var(--clad-background-tertiary)` | `bg-background-tertiary` | `var(--color-background-tertiary)` |
77
+ | `backgroundInverted` | `var(--clad-background-inverted)` | `bg-background-inverted` | `var(--color-background-inverted)` |
78
+ | `backgroundDisabled` / `backgroundDisable` | `var(--clad-background-disabled)` | `bg-background-disabled` / `bg-background-disable` | `var(--color-background-disabled)` (`#c0c0c0`) |
79
+ | `backgroundOverlay` | `var(--clad-background-overlay)` | `bg-background-overlay` | `var(--color-background-overlay)` |
80
+ | `backgroundInfo` / `backgroundInfoLight` | `var(--clad-background-info*)` | `bg-background-info` / `bg-background-info-light` | `var(--color-background-info*)` |
81
+ | `backgroundSuccess` / `backgroundSuccessLight` | `var(--clad-background-success*)` | `bg-background-success` / `bg-background-success-light` | `var(--color-background-success*)` |
82
+ | `backgroundError` / `backgroundErrorLight` | `var(--clad-background-error*)` | `bg-background-error` / `bg-background-error-light` | `var(--color-background-error*)` |
83
+ | `backgroundWarning` / `backgroundWarningLight` | `var(--clad-background-warning*)` | `bg-background-warning` / `bg-background-warning-light` | `var(--color-background-warning*)` |
84
+ | `buttonPrimary` / `buttonSecondary` / `buttonNeutral` | `var(--clad-button-*)` | `bg-button-primary` / `bg-button-secondary` / `bg-button-neutral` | `var(--color-button-*)` |
85
+ | `skeletonBackground` / `skeletonItem` *(new in v3)* | — | `bg-skeleton-background` / `bg-skeleton-item` | `var(--color-skeleton-background)` / `var(--color-skeleton-item)` |
86
+ | `logoPrimary` / `logoSecondary` / `logoOnBlack` *(new in v3)* | — | `text-logo-primary` / `text-logo-secondary` / `text-logo-on-black` | `var(--color-logo-*)` |
87
+ | `textPrimary` | `var(--clad-text-primary)` | `text-text-primary` | `var(--color-text-primary)` |
88
+ | `textSecondary` | `var(--clad-text-secondary)` | `text-text-secondary` | `var(--color-text-secondary)` |
89
+ | `textTertiary` | `var(--clad-text-tertiary)` | `text-text-tertiary` | `var(--color-text-tertiary)` |
90
+ | `textDisabled` | `var(--clad-text-disabled)` | `text-text-disabled` | `var(--color-text-disabled)` |
91
+ | `textBlank` | `var(--clad-text-blank)` | `text-text-blank` | `var(--color-text-blank)` |
92
+ | `textBrand` / `textChotot` | `var(--clad-text-brand)` | `text-text-brand` / `text-text-chotot` | `var(--color-text-brand)` |
93
+ | `textOnBackground` | `var(--clad-text-on-background)` | `text-text-on-background` | `var(--color-text-on-background)` |
94
+ | `textLink` / `textInfo` | `var(--clad-text-link)` | `text-text-link` / `text-text-info` | `var(--color-text-link)` |
95
+ | `textSuccess` / `textError` / `textWarning` | `var(--clad-text-*)` | `text-text-success` / `text-text-error` / `text-text-warning` | `var(--color-text-*)` (`text-warning`: `#fb7328`) |
96
+ | `borderDivider` | `var(--clad-border-divider)` | `border-border-divider` | `var(--color-border-divider)` |
97
+ | `borderThin` | `var(--clad-border-thin)` | `border-border-thin` | `var(--color-border-thin)` |
98
+ | `borderRegular` | `var(--clad-border-regular)` | `border-border-regular` | `var(--color-border-regular)` (`#dddddd`) |
99
+ | `borderBold` | `var(--clad-border-bold)` | `border-border-bold` | `var(--color-border-bold)` |
100
+ | `borderActive` / `borderBrand` | `var(--clad-border-active)` | `border-border-active` / `border-border-brand` | `var(--color-border-active)` |
101
+ | `borderError` / `borderSuccess` / `borderWarning` / `borderInfo` | `var(--clad-border-*)` | `border-border-{error,success,warning,info}` | `var(--color-border-*)` |
102
+ | `iconPrimary` / `iconSecondary` / `iconTertiary` | `var(--clad-icon-*)` | `text-icon-{primary,secondary,tertiary}` | `var(--color-icon-*)` |
103
+ | `iconBrand` / `iconError` / `iconSuccess` / `iconWarning` / `iconInfo` | `var(--clad-icon-*)` | `text-icon-{brand,error,success,warning,info}` | `var(--color-icon-*)` |
104
+
105
+ > **v3.0 Palette Refinements:** `--color-gray100` (`border-regular`) is updated from `#dadada` to `#dddddd`; `--color-yellow75` is updated from `#ffe884` to `#ffed9f`; `--color-background-disabled` is `#c0c0c0` (`gray200`); `--color-text-warning` is `#fb7328` (`orange300`); `--color-interaction-brand-pressed` is `#ffba00` (`vertical300`); `--color-interaction-brand-light-pressed` is `#ffd400` (`vertical100`); and `[data-theme="pty"]` light vertical steps (`vertical50`–`vertical200`) are `#fff1e3`, `#ffe5cf`, `#ffcfab`, `#ffaf7a`.
106
+
107
+ ---
108
+
109
+ ## 3. Legacy `@deprecated` v2 Colors → v3 Semantic Tokens
110
+
111
+ Many older consumer files reference v1/v2 deprecated keys on `theme.colors`. Map them to their non-deprecated v3 semantic equivalents:
112
+
113
+ | Legacy v2 `theme.colors.*` | v3 Background Utility | v3 Text / Icon Utility | v3 Border Utility |
114
+ |---|---|---|---|
115
+ | `critical`, `criticalDark`, `negative` (`red500`) | `bg-background-error` | `text-text-error` / `text-icon-error` | `border-border-error` |
116
+ | `criticalBG`, `criticalBGLight` (`red50`/`red75`) | `bg-background-error-light` | — | — |
117
+ | `positive`, `secondary` (`green400`) | `bg-background-success` | `text-text-success` / `text-icon-success` | `border-border-success` |
118
+ | `positiveBG`, `positiveBGLight`, `secondaryBGLight` | `bg-background-success-light` | — | — |
119
+ | `accent`, `accentDark` (`orange300`/`400`) | `bg-background-warning` | `text-text-warning` / `text-icon-warning` | `border-border-warning` |
120
+ | `accentBG`, `accentBGLight` (`orange50`) | `bg-background-warning-light` | — | — |
121
+ | `caution`, `cautionLight` (`yellow100`/`200`) | `bg-background-brand` | `text-text-brand` | `border-border-brand` |
122
+ | `cautionBG`, `cautionBGLight` (`yellow50`) | `bg-background-brand-light` | — | — |
123
+ | `info`, `infoDark` (`blue400`/`500`) | `bg-background-info` | `text-text-info` / `text-icon-info` | `border-border-info` |
124
+ | `infoBG`, `infoBGLight` (`blue50`) | `bg-background-info-light` | — | — |
125
+ | `neutralBG`, `neutralBGLight` (`gray50`) | `bg-background-secondary` | — | `border-border-divider` |
126
+ | `neutralLight` (`gray75`) | `bg-background-tertiary` | — | `border-border-thin` |
127
+ | `neutral` (`gray200`) | `bg-background-disabled` | `text-text-disabled` | `border-border-disabled` |
128
+ | `neutralDark` (`gray400`) | — | `text-text-tertiary` | `border-border-bold` |
129
+
130
+ ---
131
+
132
+ ## 4. Interaction State Tokens
133
+
134
+ | v2 `theme.colors.*` | v3 Tailwind Utility |
135
+ |---|---|
136
+ | `interactionBrandHover` / `interactionBrandPressed` | `hover:bg-interaction-brand-hover` / `active:bg-interaction-brand-pressed` |
137
+ | `interactionBrandLightHover` / `interactionBrandLightPressed` | `hover:bg-interaction-brand-light-hover` / `active:bg-interaction-brand-light-pressed` |
138
+ | `interactionInfoHover` / `interactionInfoPressed` | `hover:bg-interaction-info-hover` / `active:bg-interaction-info-pressed` |
139
+ | `interactionSuccessHover` / `interactionSuccessPressed` | `hover:bg-interaction-success-hover` / `active:bg-interaction-success-pressed` |
140
+ | `interactionErrorHover` / `interactionErrorPressed` | `hover:bg-interaction-error-hover` / `active:bg-interaction-error-pressed` |
141
+ | `interactionNeutralLightHover` / `interactionNeutralLightPressed` | `hover:bg-interaction-neutral-light-hover` / `active:bg-interaction-neutral-light-pressed` |
142
+ | `interactionPrimaryHover` | `hover:bg-interaction-primary-hover` |
143
+
144
+ ---
145
+
146
+ ## 5. Typography (`theme.typo.*` & `theme.fontSizes.*`)
147
+
148
+ | v2 Linaria Spread / Token | v3 Tailwind Utility | v3 React Component |
149
+ |---|---|---|
150
+ | `${theme.typo.display.page}` (`32px` bold) | `text-display-page` | `<DisplayPage>` |
151
+ | `${theme.typo.display.section}` (`24px` bold) | `text-display-section` | `<DisplaySection>` |
152
+ | `${theme.typo.display.caption}` (`20px` bold) | `text-display-caption` | `<DisplayCaption>` |
153
+ | `${theme.typo.display.annotation}` (`18px` bold) | `text-display-annotation` | `<DisplayAnnotation>` |
154
+ | `${theme.typo.header.page}` (`20px` semiBold) | `text-header-page` | `<HeaderPage>` |
155
+ | `${theme.typo.header.section}` (`16px` semiBold) | `text-header-section` | `<HeaderSection>` |
156
+ | `${theme.typo.header.caption}` (`14px` semiBold) | `text-header-caption` | `<HeaderCaption>` |
157
+ | `${theme.typo.header.annotation}` (`12px` semiBold) | `text-header-annotation` | `<HeaderAnnotation>` |
158
+ | `${theme.typo.label.page}` (`16px` bold) | `text-label-page` | `<LabelPage>` |
159
+ | `${theme.typo.label.section}` (`14px` bold) | `text-label-section` | `<LabelSection>` |
160
+ | `${theme.typo.label.caption}` (`12px` bold) | `text-label-caption` | `<LabelCaption>` |
161
+ | `${theme.typo.label.annotation}` (`10px` bold) | `text-label-annotation` | `<LabelAnnotation>` |
162
+ | `${theme.typo.body.page}` (`16px` regular) | `text-body-page` | `<BodyPage>` |
163
+ | `${theme.typo.body.section}` (`14px` regular) | `text-body-section` | `<BodySection>` |
164
+ | `${theme.typo.body.caption}` (`12px` regular) | `text-body-caption` | `<BodyCaption>` |
165
+ | `${theme.typo.body.annotation}` (`10px` regular) | `text-body-annotation` | `<BodyAnnotation>` |
166
+ | `${theme.typo.note.page\|section\|caption}` | `text-note-{page,section,caption}` | `<NotePage>`, `<NoteSection>`, `<NoteCaption>` |
167
+ | `${theme.typo.tagline.section\|caption\|annotation\|footext}` | `text-tagline-{section,caption,annotation,footext}` | `<TaglineSection>`, `<TaglineCaption>`, `<TaglineAnnotation>`, `<TaglineFootext>` |
168
+
169
+ ---
170
+
171
+ ## 6. Spacing, Sizes, Radii, Strokes, Shadows & Z-Index
172
+
173
+ | v2 Token | Value | v3 Tailwind Utility / Semantic Token |
174
+ |---|---|---|
175
+ | `space.none` / `space.xxxs` / `space.xxs` / `space.xs` | `0px` / `2px` / `4px` / `8px` | `p-0` / `p-0.5` / `p-1` / `p-2` (also `m-*`, `gap-*`, or `--spacing-tiny-2`, `--spacing-tiny-4`, `--spacing-extra-small-8`) |
176
+ | `space.sm` / `space.md` / `space.mdl` / `space.lg` | `12px` / `16px` / `20px` / `24px` | `p-3` / `p-4` / `p-5` / `p-6` (or `--spacing-small-12`, `--spacing-medium-16`, `--spacing-large-20`, `--spacing-extra-large-24`) |
177
+ | `space.xl` / `space.xxl` / `space.xxxl` / `space.xxxxl` | `32px` / `48px` / `64px` / `96px` | `p-8` / `p-12` / `p-16` / `p-24` (or `--spacing-huge-32`, `--spacing-massive-40`) |
178
+ | `sizes.xxxs` / `xxs` / `xs` / `sm` / `md` / `lg` / `lxl` / `xl` / `xxl` | `12` / `16` / `20` / `24` / `28` / `32` / `40` / `48` / `64px` | `h-3` / `h-4` / `h-5` / `h-6` / `h-7` / `h-8` / `h-10` / `h-12` / `h-16` (also `w-*`, `size-*`) |
179
+ | `radii.sm` / `radii.$sm` / `radii.md` / `radii.lg` / `radii.xl` / `radii.pill` | `4px` / `6px` / `8px` / `12px` / `20px` / `999px` | `rounded-ad-small` (`4px`) / `rounded-ad` (`6px`) / `rounded-card-small` (`8px`) / `rounded-card` (`12px`) / `rounded-decoration` (`16px`) / `rounded-modal` (`20px`) / `rounded-pill` (`999px`) |
180
+ | `borderWidths.strokeDivider` / `strokeAction` / `strokeEmphasize` | `1px` / `2px` / `3px` | `border` (`var(--stroke-divider)`) / `border-2` (`var(--stroke-action)`) / `border-[3px]` (`var(--stroke-emphasize)`) |
181
+ | `shadows.sm` / `shadows.md` / `shadows.lg` | Elevation shadows | `shadow-below` (`var(--shadow-below)`) / `shadow-floating` (`var(--shadow-floating)`) |
182
+
183
+ ---
184
+
185
+ ## 7. Breakpoints & Media Queries (`theme.mediaQueries.*`)
186
+
187
+ | v2 Media Query / Breakpoint | Viewport Width | v3 Tailwind Responsive Prefix |
188
+ |---|---|---|
189
+ | `theme.mediaQueries.ip5` | `max-width: 320px` | `max-[320px]:` |
190
+ | `theme.breakpoints.sm` (`breakpoints[0]`) | `min-width: 576px` | `min-[576px]:` (or `sm:` if Tailwind `sm` is configured to 576px) |
191
+ | `theme.mediaQueries.tablet` / `breakpoints.md` (`breakpoints[1]`) | `min-width: 768px` | `md:` (`768px`) |
192
+ | `theme.mediaQueries.desktop` / `breakpoints.lg` (`breakpoints[2]`) | `min-width: 992px` | `min-[992px]:` (note: default Tailwind `lg:` is `1024px`) |
193
+ | `theme.breakpoints.xl` (`breakpoints[3]`) | `min-width: 1280px` | `xl:` (`1280px`) |
194
+ | `theme.breakpoints.xxl` (`breakpoints[4]`) | `min-width: 1440px` | `min-[1440px]:` |