@nexus-cross/design-system 1.0.13 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (285) hide show
  1. package/claude-rules/nexus/CLAUDE.md +85 -0
  2. package/claude-rules/nexus/commands/nexus-audit.md +79 -0
  3. package/claude-rules/nexus/commands/nexus-component-map.md +85 -0
  4. package/claude-rules/nexus/commands/nexus-token-check.md +68 -0
  5. package/claude-rules/nexus/skills/nexus-design-system/SKILL.md +92 -0
  6. package/cursor-rules/nexus-ui-api.mdc +824 -41
  7. package/cursor-rules/nexus-ui-decisions.mdc +259 -0
  8. package/dist/accordion.js +0 -1
  9. package/dist/accordion.mjs +0 -1
  10. package/dist/alert.js +0 -1
  11. package/dist/alert.mjs +0 -1
  12. package/dist/avatar.js +0 -1
  13. package/dist/avatar.mjs +0 -1
  14. package/dist/badge.js +0 -1
  15. package/dist/badge.mjs +0 -1
  16. package/dist/breadcrumb.js +0 -1
  17. package/dist/breadcrumb.mjs +0 -1
  18. package/dist/button.js +0 -1
  19. package/dist/button.mjs +0 -1
  20. package/dist/carousel.js +0 -1
  21. package/dist/carousel.mjs +0 -1
  22. package/dist/checkbox.js +0 -1
  23. package/dist/checkbox.mjs +0 -1
  24. package/dist/chip.js +0 -1
  25. package/dist/chip.mjs +0 -1
  26. package/dist/chunks/chunk-2Z52NPWB.js +78 -0
  27. package/dist/chunks/chunk-46P52MFM.mjs +56 -0
  28. package/dist/chunks/{chunk-X3CTJ7TD.js → chunk-4KBFVIKX.js} +41 -11
  29. package/dist/chunks/chunk-56ZOOQFE.mjs +514 -0
  30. package/dist/chunks/chunk-5ASTWFJW.js +538 -0
  31. package/dist/chunks/{chunk-33UFQJIO.mjs → chunk-BJMXZJWO.mjs} +16 -5
  32. package/dist/chunks/chunk-EILXBLEV.mjs +5 -0
  33. package/dist/chunks/chunk-G3RLK2HS.js +7 -0
  34. package/dist/chunks/{chunk-YZV6FWE7.js → chunk-JLDQNDFT.js} +16 -5
  35. package/dist/chunks/{chunk-K574BYHQ.js → chunk-K3CK7NTP.js} +22 -4
  36. package/dist/chunks/{chunk-Z4YM7LU3.mjs → chunk-PIGHBDK5.mjs} +22 -4
  37. package/dist/chunks/{chunk-PEIEVKD5.js → chunk-RCIBLLSF.js} +11 -12
  38. package/dist/chunks/{chunk-MMCA33FW.mjs → chunk-RSFLNWOM.mjs} +41 -11
  39. package/dist/chunks/{chunk-K2TBLM3F.mjs → chunk-THBE27U3.mjs} +11 -12
  40. package/dist/client-only.js +0 -1
  41. package/dist/client-only.mjs +0 -1
  42. package/dist/combobox.js +16 -0
  43. package/dist/combobox.mjs +3 -0
  44. package/dist/components/Combobox.d.ts +48 -0
  45. package/dist/components/Combobox.d.ts.map +1 -0
  46. package/dist/components/DataGrid.d.ts +44 -0
  47. package/dist/components/DataGrid.d.ts.map +1 -0
  48. package/dist/components/DataList.d.ts +3 -1
  49. package/dist/components/DataList.d.ts.map +1 -1
  50. package/dist/components/RadioGroup.d.ts +4 -0
  51. package/dist/components/RadioGroup.d.ts.map +1 -1
  52. package/dist/components/Stepper.d.ts.map +1 -1
  53. package/dist/components/ToggleGroup.d.ts +2 -1
  54. package/dist/components/ToggleGroup.d.ts.map +1 -1
  55. package/dist/countdown.js +0 -1
  56. package/dist/countdown.mjs +0 -1
  57. package/dist/counter.js +0 -1
  58. package/dist/counter.mjs +0 -1
  59. package/dist/data-grid.js +14 -0
  60. package/dist/data-grid.mjs +5 -0
  61. package/dist/data-list.js +2 -3
  62. package/dist/data-list.mjs +1 -2
  63. package/dist/date-picker.js +0 -1
  64. package/dist/date-picker.mjs +0 -1
  65. package/dist/divider.js +0 -1
  66. package/dist/divider.mjs +0 -1
  67. package/dist/drawer.js +0 -1
  68. package/dist/drawer.mjs +0 -1
  69. package/dist/dropdown-menu.js +0 -1
  70. package/dist/dropdown-menu.mjs +0 -1
  71. package/dist/ellipsis.js +0 -1
  72. package/dist/ellipsis.mjs +0 -1
  73. package/dist/empty-state.js +0 -1
  74. package/dist/empty-state.mjs +0 -1
  75. package/dist/error-boundary.js +0 -1
  76. package/dist/error-boundary.mjs +0 -1
  77. package/dist/hooks/useCheckDevice.js +0 -1
  78. package/dist/hooks/useCheckDevice.mjs +0 -1
  79. package/dist/hooks/useClickOutside.js +0 -1
  80. package/dist/hooks/useClickOutside.mjs +0 -1
  81. package/dist/hooks/useDraggableBottomSheet.js +0 -1
  82. package/dist/hooks/useDraggableBottomSheet.mjs +0 -1
  83. package/dist/hooks/useDraggableWindow.js +0 -1
  84. package/dist/hooks/useDraggableWindow.mjs +0 -1
  85. package/dist/hooks/useInView.js +0 -1
  86. package/dist/hooks/useInView.mjs +0 -1
  87. package/dist/hooks/useModal.js +0 -1
  88. package/dist/hooks/useModal.mjs +0 -1
  89. package/dist/image-upload.js +0 -1
  90. package/dist/image-upload.mjs +0 -1
  91. package/dist/index.d.ts +4 -2
  92. package/dist/index.d.ts.map +1 -1
  93. package/dist/index.js +92 -88
  94. package/dist/index.mjs +12 -12
  95. package/dist/infinite-scroll.js +0 -1
  96. package/dist/infinite-scroll.mjs +0 -1
  97. package/dist/marquee.js +0 -1
  98. package/dist/marquee.mjs +0 -1
  99. package/dist/modal/index.js +11 -12
  100. package/dist/modal/index.mjs +2 -3
  101. package/dist/number-input.js +0 -1
  102. package/dist/number-input.mjs +0 -1
  103. package/dist/nx-image.js +0 -1
  104. package/dist/nx-image.mjs +0 -1
  105. package/dist/pagination.js +0 -1
  106. package/dist/pagination.mjs +0 -1
  107. package/dist/popover.js +0 -1
  108. package/dist/popover.mjs +0 -1
  109. package/dist/price-input.js +0 -1
  110. package/dist/price-input.mjs +0 -1
  111. package/dist/progress.js +0 -1
  112. package/dist/progress.mjs +0 -1
  113. package/dist/radio-group.js +5 -6
  114. package/dist/radio-group.mjs +1 -2
  115. package/dist/schemas/_all.json +308 -117
  116. package/dist/schemas/accordion.d.ts.map +1 -1
  117. package/dist/schemas/accordion.json +1 -1
  118. package/dist/schemas/alert.d.ts.map +1 -1
  119. package/dist/schemas/alert.json +1 -1
  120. package/dist/schemas/avatar.d.ts.map +1 -1
  121. package/dist/schemas/avatar.json +1 -1
  122. package/dist/schemas/badge.d.ts.map +1 -1
  123. package/dist/schemas/badge.json +1 -1
  124. package/dist/schemas/breadcrumb.d.ts.map +1 -1
  125. package/dist/schemas/breadcrumb.json +1 -1
  126. package/dist/schemas/button.d.ts.map +1 -1
  127. package/dist/schemas/button.json +1 -1
  128. package/dist/schemas/carousel.d.ts.map +1 -1
  129. package/dist/schemas/carousel.json +1 -1
  130. package/dist/schemas/checkBox.json +1 -1
  131. package/dist/schemas/checkbox.d.ts.map +1 -1
  132. package/dist/schemas/chip.d.ts.map +1 -1
  133. package/dist/schemas/chip.json +1 -1
  134. package/dist/schemas/client-only.d.ts.map +1 -1
  135. package/dist/schemas/clientOnly.json +1 -1
  136. package/dist/schemas/combobox.d.ts +85 -0
  137. package/dist/schemas/combobox.d.ts.map +1 -0
  138. package/dist/schemas/combobox.json +98 -0
  139. package/dist/schemas/comboboxOption.json +30 -0
  140. package/dist/schemas/countdown.d.ts.map +1 -1
  141. package/dist/schemas/countdown.json +1 -1
  142. package/dist/schemas/counter.d.ts.map +1 -1
  143. package/dist/schemas/counter.json +1 -1
  144. package/dist/schemas/data-grid.d.ts +74 -0
  145. package/dist/schemas/data-grid.d.ts.map +1 -0
  146. package/dist/schemas/data-list.d.ts.map +1 -1
  147. package/dist/schemas/dataGrid.json +102 -0
  148. package/dist/schemas/dataList.json +1 -1
  149. package/dist/schemas/date-picker.d.ts.map +1 -1
  150. package/dist/schemas/datePicker.json +1 -1
  151. package/dist/schemas/divider.d.ts.map +1 -1
  152. package/dist/schemas/divider.json +1 -1
  153. package/dist/schemas/drawer.d.ts.map +1 -1
  154. package/dist/schemas/drawer.json +1 -1
  155. package/dist/schemas/dropdown-menu.d.ts.map +1 -1
  156. package/dist/schemas/dropdownMenu.json +1 -1
  157. package/dist/schemas/ellipsis.d.ts.map +1 -1
  158. package/dist/schemas/ellipsis.json +1 -1
  159. package/dist/schemas/empty-state.d.ts.map +1 -1
  160. package/dist/schemas/emptyState.json +1 -1
  161. package/dist/schemas/error-boundary.d.ts.map +1 -1
  162. package/dist/schemas/errorBoundary.json +1 -1
  163. package/dist/schemas/image-upload.d.ts.map +1 -1
  164. package/dist/schemas/imageUpload.json +1 -1
  165. package/dist/schemas/index.d.ts +2 -1
  166. package/dist/schemas/index.d.ts.map +1 -1
  167. package/dist/schemas/infinite-scroll.d.ts.map +1 -1
  168. package/dist/schemas/infiniteScroll.json +1 -1
  169. package/dist/schemas/marquee.d.ts.map +1 -1
  170. package/dist/schemas/marquee.json +1 -1
  171. package/dist/schemas/modal.d.ts.map +1 -1
  172. package/dist/schemas/modalTemplate.json +1 -1
  173. package/dist/schemas/number-input.d.ts.map +1 -1
  174. package/dist/schemas/numberInput.json +1 -1
  175. package/dist/schemas/nx-image.d.ts.map +1 -1
  176. package/dist/schemas/nxImage.json +1 -1
  177. package/dist/schemas/pagination.d.ts.map +1 -1
  178. package/dist/schemas/pagination.json +1 -1
  179. package/dist/schemas/popover.d.ts.map +1 -1
  180. package/dist/schemas/popover.json +1 -1
  181. package/dist/schemas/price-input.d.ts.map +1 -1
  182. package/dist/schemas/priceInput.json +1 -1
  183. package/dist/schemas/progress.d.ts.map +1 -1
  184. package/dist/schemas/progress.json +1 -1
  185. package/dist/schemas/radio-group.d.ts +9 -0
  186. package/dist/schemas/radio-group.d.ts.map +1 -1
  187. package/dist/schemas/radioGroup.json +10 -1
  188. package/dist/schemas/radioItem.json +11 -0
  189. package/dist/schemas/select.d.ts.map +1 -1
  190. package/dist/schemas/select.json +1 -1
  191. package/dist/schemas/skeleton.d.ts.map +1 -1
  192. package/dist/schemas/skeleton.json +1 -1
  193. package/dist/schemas/slider.d.ts.map +1 -1
  194. package/dist/schemas/slider.json +1 -1
  195. package/dist/schemas/spinner.d.ts.map +1 -1
  196. package/dist/schemas/spinner.json +1 -1
  197. package/dist/schemas/stepper.d.ts.map +1 -1
  198. package/dist/schemas/stepper.json +1 -1
  199. package/dist/schemas/switch.d.ts.map +1 -1
  200. package/dist/schemas/switch.json +1 -1
  201. package/dist/schemas/tab.d.ts.map +1 -1
  202. package/dist/schemas/tab.json +1 -1
  203. package/dist/schemas/table.d.ts.map +1 -1
  204. package/dist/schemas/table.json +1 -1
  205. package/dist/schemas/tableRow.json +1 -1
  206. package/dist/schemas/tag-input.d.ts.map +1 -1
  207. package/dist/schemas/tagInput.json +1 -1
  208. package/dist/schemas/tdColumn.json +1 -1
  209. package/dist/schemas/text-area.d.ts.map +1 -1
  210. package/dist/schemas/text-input.d.ts +2 -2
  211. package/dist/schemas/text-input.d.ts.map +1 -1
  212. package/dist/schemas/textArea.json +1 -1
  213. package/dist/schemas/textInput.json +1 -1
  214. package/dist/schemas/toast.d.ts.map +1 -1
  215. package/dist/schemas/toastOptions.json +1 -1
  216. package/dist/schemas/toaster.json +1 -1
  217. package/dist/schemas/toggle-group.d.ts +6 -3
  218. package/dist/schemas/toggle-group.d.ts.map +1 -1
  219. package/dist/schemas/toggleGroup.json +9 -3
  220. package/dist/schemas/tooltip.d.ts.map +1 -1
  221. package/dist/schemas/tooltip.json +1 -1
  222. package/dist/schemas/virtual-scroll.d.ts.map +1 -1
  223. package/dist/schemas/virtualGrid.json +1 -1
  224. package/dist/schemas/virtualList.json +1 -1
  225. package/dist/schemas.js +867 -66
  226. package/dist/schemas.mjs +865 -66
  227. package/dist/select.js +0 -1
  228. package/dist/select.mjs +0 -1
  229. package/dist/skeleton.js +0 -1
  230. package/dist/skeleton.mjs +0 -1
  231. package/dist/slider.js +0 -1
  232. package/dist/slider.mjs +0 -1
  233. package/dist/spinner.js +0 -1
  234. package/dist/spinner.mjs +0 -1
  235. package/dist/stepper.js +3 -4
  236. package/dist/stepper.mjs +1 -2
  237. package/dist/styles/.generated/built.d.ts +1 -1
  238. package/dist/styles/.generated/built.d.ts.map +1 -1
  239. package/dist/styles/layer.js +2 -3
  240. package/dist/styles/layer.mjs +1 -2
  241. package/dist/styles.css +554 -51
  242. package/dist/styles.js +2 -3
  243. package/dist/styles.layered.css +554 -51
  244. package/dist/styles.mjs +1 -2
  245. package/dist/switch.js +0 -1
  246. package/dist/switch.mjs +0 -1
  247. package/dist/tab.js +0 -1
  248. package/dist/tab.mjs +0 -1
  249. package/dist/table.js +0 -1
  250. package/dist/table.mjs +0 -1
  251. package/dist/tag-input.js +0 -1
  252. package/dist/tag-input.mjs +0 -1
  253. package/dist/text-area.js +0 -1
  254. package/dist/text-area.mjs +0 -1
  255. package/dist/text-input.js +0 -1
  256. package/dist/text-input.mjs +0 -1
  257. package/dist/toast.js +0 -1
  258. package/dist/toast.mjs +0 -1
  259. package/dist/toggle-group.js +3 -4
  260. package/dist/toggle-group.mjs +1 -2
  261. package/dist/tooltip.js +0 -1
  262. package/dist/tooltip.mjs +0 -1
  263. package/dist/utils/cn.js +0 -1
  264. package/dist/utils/cn.mjs +0 -1
  265. package/dist/utils/scroll.js +0 -1
  266. package/dist/utils/scroll.mjs +0 -1
  267. package/dist/virtual-scroll.js +0 -1
  268. package/dist/virtual-scroll.mjs +0 -1
  269. package/package.json +14 -8
  270. package/scripts/setup-cursor-rules.cjs +164 -27
  271. package/dist/chunks/chunk-22ULI3BF.js +0 -21
  272. package/dist/chunks/chunk-6ECGMUT6.mjs +0 -5
  273. package/dist/chunks/chunk-CVYXRSXT.mjs +0 -8
  274. package/dist/chunks/chunk-I252NERB.mjs +0 -21
  275. package/dist/chunks/chunk-JNMCYWGY.js +0 -10
  276. package/dist/chunks/chunk-V35IEPRL.js +0 -7
  277. package/dist/components/ThemeProvider.d.ts +0 -25
  278. package/dist/components/ThemeProvider.d.ts.map +0 -1
  279. package/dist/schemas/theme-provider.d.ts +0 -36
  280. package/dist/schemas/theme-provider.d.ts.map +0 -1
  281. package/dist/schemas/themeProvider.json +0 -65
  282. package/dist/theme-provider.js +0 -15
  283. package/dist/theme-provider.mjs +0 -2
  284. package/dist/chunks/{chunk-CWMLTXOH.mjs → chunk-5ZVPTIL3.mjs} +1 -1
  285. package/dist/chunks/{chunk-HFBTS42N.js → chunk-7F4SOLAC.js} +1 -1
@@ -98,7 +98,7 @@
98
98
  "items"
99
99
  ],
100
100
  "additionalProperties": false,
101
- "description": "Accordion. Supports both items array and composable patterns."
101
+ "description": "Accordion collapsible content sections (FAQ, settings groups).\n\nWHEN TO USE:\n • FAQ, help docs, settings groups\n • Long page where each section is independently scannable\n • Hidden critical info — DO NOT bury what users always need\n • Tab-like content switching → Tab (Accordion is for stacked, not exclusive)\n\ntype=\"single\" + collapsible=true → all-closed allowed (recommended for FAQ).\ntype=\"multiple\" → multiple sections open at once.\n\nANTI-PATTERNS:\n ✗ Hiding the page's primary content inside collapsed Accordion\n ✗ Single-section Accordion (just show the content)\n ✗ Custom toggle div + state — use Accordion (gets a11y, keyboard nav)"
102
102
  }
103
103
  },
104
104
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -147,7 +147,7 @@
147
147
  }
148
148
  },
149
149
  "additionalProperties": false,
150
- "description": "Alert / Banner. Inline notification with icon, title, description."
150
+ "description": "Alert persistent inline notification (banner). Auto icon by variant.\n\nWHEN TO USE:\n • In-page status: form errors, server warnings, info banners, success confirmation\n • Transient toast/snackbar → use a toast library, NOT Alert\n • Modal-blocking error → Modal with semantic=\"danger\"\n • Inline form field error → use error/description prop on TextInput / Select / etc.\n\nvariant maps to semantic colors. closable=true gives users dismiss control. action prop reserved for inline buttons (e.g. \"Retry\").\n\nANTI-PATTERNS:\n ✗ Stacking 5 alerts at top of page (use one with summary)\n ✗ Critical destructive action confirmation in Alert → Modal\n ✗ Wrapping <div className=\"bg-red-100\"> manually → Alert (a11y role + tokens)"
151
151
  }
152
152
  },
153
153
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -202,7 +202,7 @@
202
202
  }
203
203
  },
204
204
  "additionalProperties": false,
205
- "description": "Avatar. Supports image, fallback text, and children."
205
+ "description": "Avatar user/entity profile image with text fallback.\n\nWHEN TO USE:\n • User profiles, comment authors, team member lists, message sender icons\n • Image fails / not provided → fallback (initials or icon) shown automatically\n • Need optimized image (Next.js) → pass <Image> via children, omit src\n • Larger illustration / logo → use NxImage instead\n\nshape=\"square\" for organization/team logos; \"circle\" for people (default).\n\nANTI-PATTERNS:\n ✗ <img> + manual fallback handling → Avatar (handles error)\n ✗ Avatar without alt for screen readers (always set alt or aria-label)\n ✗ Mixing avatar sizes inconsistently in a list — pick one size"
206
206
  }
207
207
  },
208
208
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -278,7 +278,7 @@
278
278
  }
279
279
  },
280
280
  "additionalProperties": false,
281
- "description": "Badge indicator. Dot or count display. Wraps children when provided."
281
+ "description": "Badge — small status / count indicator overlaid on an anchor (icon, avatar, button).\n\nWHEN TO USE:\n • Notification count on bell icon\n • Unread message count on inbox tab\n • Status dot (online/offline) → dot=true\n • Status label with text (e.g. \"PRO\", \"NEW\") → Chip variant=\"accent\"\n • Removable filter token → Chip with onClose\n\ncount={0} hides badge by default; pass showZero=true to keep visible.\n\nANTI-PATTERNS:\n ✗ Using Badge as standalone label without anchor → Chip\n ✗ count > 999 without max → ugly layout; default max=99 (\"99+\")\n ✗ Multiple badges on same anchor (visual noise)"
282
282
  }
283
283
  },
284
284
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -305,7 +305,7 @@
305
305
  }
306
306
  },
307
307
  "additionalProperties": false,
308
- "description": "Breadcrumb navigation (compound component pattern). Use <Breadcrumb.Item> children instead of items array. Each Item can wrap arbitrary ReactNode (Link, Select, plain text, etc.)."
308
+ "description": "Breadcrumb — hierarchical location navigation (Home > Settings > Profile).\n\nWHEN TO USE:\n • Multi-level information architecture (>=3 levels deep)\n • Hierarchical category drill-down (file system, taxonomy)\n • Step-based linear flow → Stepper (not Breadcrumb)\n • Tab switching → Tab\n • Single-level navigation → page title alone\n\nCompound pattern: use <Breadcrumb.Item> children. Each Item wraps any ReactNode (Link, Select, plain text). Use maxItems for long paths (auto-collapse with \"…\").\n\nANTI-PATTERNS:\n ✗ Breadcrumb with 1 level — just show page title\n ✗ Breadcrumb with > 6 visible items → set maxItems\n ✗ Last item as a link (it's the current page; should be plain text)"
309
309
  }
310
310
  },
311
311
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -394,7 +394,7 @@
394
394
  }
395
395
  },
396
396
  "additionalProperties": false,
397
- "description": "Interactive button. semantic(color) x variant(style) 2-axis system. Rendering element changeable via asChild."
397
+ "description": "Interactive button (always prefer over native <button>).\n\nWHEN TO USE: any clickable action — submit, navigate (with asChild), open modal, trigger menu.\n2-axis: semantic (color intent) × variant (visual weight). Use semantic=\"primary\" for the page's main CTA, \"danger\" for destructive actions, \"secondary\" for sub actions, \"normal\" for neutral.\n\nANTI-PATTERNS:\n ✗ <button className=\"bg-blue-500\"> <Button semantic=\"primary\">\n ✗ <a className=\"...\"> styled as button → <Button asChild><a href=\"...\"/></Button>\n ✗ Mixing variants randomly within one row — pick one per visual hierarchy level\n ✗ Using primary + contained for every button → only ONE primary CTA per view\n ✗ <Button className=\"!bg-red-500\"> → <Button semantic=\"danger\"> (no !important)"
398
398
  }
399
399
  },
400
400
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -426,7 +426,7 @@
426
426
  }
427
427
  },
428
428
  "additionalProperties": false,
429
- "description": "Carousel. Based on Embla Carousel. Sub-components: CarouselSlide, CarouselPrev, CarouselNext, CarouselDots."
429
+ "description": "Carousel — horizontal slide gallery. Based on Embla Carousel. Compound: CarouselSlide, CarouselPrev/Next, CarouselDots.\n\nWHEN TO USE:\n • Hero banners, image gallery, product showcase\n • Multi-card horizontal scroll with snap behavior\n • Vertical scrolling list → Marquee or VirtualList (not Carousel)\n • Critical content that must always be visible — Carousel hides slides\n\nopts={{ loop: true, align: 'start' }} for endless loop. Add Embla autoplay plugin for auto-advance.\n\nANTI-PATTERNS:\n ✗ Critical CTA inside non-first slide (users might never scroll)\n ✗ Auto-advance without pause-on-hover (a11y)\n ✗ Manual scroll-snap div → Carousel (gets keyboard nav, indicators)"
430
430
  }
431
431
  },
432
432
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -558,7 +558,7 @@
558
558
  }
559
559
  },
560
560
  "additionalProperties": false,
561
- "description": "Checkbox. Native input-based, supports square/round shapes."
561
+ "description": "Checkbox for multi-select form fields. Native input-based, supports square/round shapes.\n\nWHEN TO USE:\n • Form field with multiple independent options (T&C agreements, multi-select filters submitted later)\n • Tri-state (parent-child selection) — use indeterminate prop\n • Single binary that takes effect immediately → Switch instead\n • Many options with search → Combobox (multiple)\n\nINDETERMINATE: set indeterminate=true when some children are checked, others not. aria-checked becomes \"mixed\" automatically.\n\nANTI-PATTERNS:\n ✗ <CheckBox> for \"Enable dark mode\" toggle → <Switch>\n ✗ Native <input type=\"checkbox\"> + manual styling → <CheckBox>\n ✗ Forgetting indeterminate for \"select all\" parent"
562
562
  }
563
563
  },
564
564
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -613,7 +613,7 @@
613
613
  }
614
614
  },
615
615
  "additionalProperties": false,
616
- "description": "Chip/tag/badge. Close button displayed via onClose prop."
616
+ "description": "Chip — small interactive token for filters, tags, removable selections, status labels.\n\nWHEN TO USE:\n • Filter token / removable selection (set onClose for X button)\n • Tag/category indicator\n • Status indicator with color (variant=\"accent\")\n • Pure count badge Badge instead\n • Toggleable filter → ToggleGroup or Chip with onClick + active state\n\nANTI-PATTERNS:\n ✗ Building dismiss UI manually with custom div + X icon → use onClose prop\n ✗ Using Chip as a primary CTA → Button\n ✗ Using Chip for hover-only labels → Tooltip"
617
617
  }
618
618
  },
619
619
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -632,7 +632,135 @@
632
632
  }
633
633
  },
634
634
  "additionalProperties": false,
635
- "description": "Client-only rendering. Prevents hydration mismatch in SSR environments."
635
+ "description": "ClientOnly — defers children to client-side render, preventing SSR hydration mismatch.\n\nWHEN TO USE:\n • Wrap components that read window/document/localStorage at render time\n • Components depending on browser-only APIs (IntersectionObserver eager init, geolocation)\n • Server-renderable content → DON'T wrap (loses SEO/SSR perf benefits)\n • Conditional based on data → use proper SSR-safe state instead\n\nPass fallback to avoid layout shift during hydration.\n\nANTI-PATTERNS:\n ✗ Wrapping the entire page in ClientOnly (defeats SSR)\n ✗ ClientOnly without fallback for above-the-fold UI (CLS)\n ✗ Using ClientOnly to \"fix\" any hydration warning — root-cause the mismatch first"
636
+ }
637
+ },
638
+ "$schema": "http://json-schema.org/draft-07/schema#"
639
+ },
640
+ "comboboxOption": {
641
+ "$ref": "#/definitions/comboboxOptionSchema",
642
+ "definitions": {
643
+ "comboboxOptionSchema": {
644
+ "type": "object",
645
+ "properties": {
646
+ "value": {
647
+ "type": "string",
648
+ "description": "Option value (unique key)"
649
+ },
650
+ "label": {
651
+ "description": "Display label (string | ReactNode)"
652
+ },
653
+ "description": {
654
+ "description": "Secondary text below label (ReactNode)"
655
+ },
656
+ "disabled": {
657
+ "type": "boolean",
658
+ "description": "Disabled option"
659
+ }
660
+ },
661
+ "required": [
662
+ "value"
663
+ ],
664
+ "additionalProperties": false,
665
+ "description": "Single Combobox option."
666
+ }
667
+ },
668
+ "$schema": "http://json-schema.org/draft-07/schema#"
669
+ },
670
+ "combobox": {
671
+ "$ref": "#/definitions/comboboxPropsSchema",
672
+ "definitions": {
673
+ "comboboxPropsSchema": {
674
+ "type": "object",
675
+ "properties": {
676
+ "options": {
677
+ "description": "Available options array (ComboboxOption[], required)"
678
+ },
679
+ "value": {
680
+ "description": "Selected value. string for single, string[] for multiple"
681
+ },
682
+ "defaultValue": {
683
+ "description": "Initial value (uncontrolled)"
684
+ },
685
+ "onValueChange": {
686
+ "description": "Value change callback. (value: string | string[]) => void"
687
+ },
688
+ "multiple": {
689
+ "type": "boolean",
690
+ "default": false,
691
+ "description": "Multi-select mode. Selected values shown as chips inside input"
692
+ },
693
+ "onSearch": {
694
+ "description": "Async search callback. (query: string) => void. Triggers external data fetching with debounce"
695
+ },
696
+ "searchDebounce": {
697
+ "type": "number",
698
+ "default": 250,
699
+ "description": "Debounce delay (ms) before onSearch fires"
700
+ },
701
+ "loading": {
702
+ "type": "boolean",
703
+ "default": false,
704
+ "description": "Externally-controlled loading state. Shows spinner in input suffix"
705
+ },
706
+ "filter": {
707
+ "description": "Custom client-side filter. (option, query) => boolean. Default: case-insensitive label includes match"
708
+ },
709
+ "placeholder": {
710
+ "type": "string",
711
+ "description": "Input placeholder"
712
+ },
713
+ "emptyMessage": {
714
+ "description": "Message when no options match (string | ReactNode). Default: \"검색 결과 없음\""
715
+ },
716
+ "loadingMessage": {
717
+ "description": "Message during loading state inside popover (string | ReactNode). Default: \"검색 중…\""
718
+ },
719
+ "size": {
720
+ "type": "string",
721
+ "enum": [
722
+ "md",
723
+ "lg",
724
+ "xl"
725
+ ],
726
+ "default": "md",
727
+ "description": "Input size (matches TextInput tokens)"
728
+ },
729
+ "disabled": {
730
+ "type": "boolean",
731
+ "description": "Disabled"
732
+ },
733
+ "error": {
734
+ "type": "boolean",
735
+ "description": "Error state"
736
+ },
737
+ "clearable": {
738
+ "type": "boolean",
739
+ "default": true,
740
+ "description": "Show clear button when value(s) exist"
741
+ },
742
+ "autoOpenOnFocus": {
743
+ "type": "boolean",
744
+ "default": true,
745
+ "description": "Open popover automatically when input gains focus"
746
+ },
747
+ "label": {
748
+ "description": "Field label (ReactNode)"
749
+ },
750
+ "description": {
751
+ "description": "Helper text below input (ReactNode)"
752
+ },
753
+ "className": {
754
+ "type": "string",
755
+ "description": "Wrapper className"
756
+ },
757
+ "popoverClassName": {
758
+ "type": "string",
759
+ "description": "Popover content className"
760
+ }
761
+ },
762
+ "additionalProperties": false,
763
+ "description": "Searchable select. Text input + popover listbox. Single/multi-select. Sync (auto-filter) or async (onSearch + loading) modes.\n\nWHEN TO USE:\n • Options ≥ 7, OR labels are long, OR search/filter is needed → Combobox (not Select)\n • Multi-select form field → Combobox with multiple (chips render inside input)\n • Async data from server → set onSearch + loading\nFor ≤7 simple options use Select. For free-text tags use TagInput.\n\nASYNC PATTERN:\n <Combobox options={results} loading={isFetching} onSearch={(q) => mutate(q)} />\n — onSearch fires after searchDebounce (default 250ms). Do NOT clear input on result update; component preserves user's typing.\n\nIME (Korean/Japanese/Chinese): Enter during composition is ignored automatically — do not add custom keydown handlers.\n\nANTI-PATTERNS:\n ✗ <Select> with 20 options → <Combobox>\n ✗ Manual <input> + dropdown div + filter logic → <Combobox>\n ✗ Setting value externally to clear input mid-typing → use onValueChange instead"
636
764
  }
637
765
  },
638
766
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -690,7 +818,7 @@
690
818
  "endTimestamp"
691
819
  ],
692
820
  "additionalProperties": false,
693
- "description": "Countdown timer."
821
+ "description": "Countdown — live timer counting down to endTimestamp (Unix ms).\n\nWHEN TO USE:\n • Sale ends in / event starts in / token claim window\n • OTP / verification code expiry\n • Counting up (since X) → not Countdown; use Counter or custom interval\n • Persistent server time → pass server-synced endTimestamp (not Date.now offset)\n\nshowDays=false for short timers (<24h) to declutter. Use render prop for fully custom layouts.\n\nANTI-PATTERNS:\n ✗ Countdown without onEnd handler — UI stuck at 0\n ✗ Countdown across SSR without hydration safety — pass endTimestamp from server\n ✗ Updating endTimestamp every render — causes jitter"
694
822
  }
695
823
  },
696
824
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -750,7 +878,109 @@
750
878
  "endValue"
751
879
  ],
752
880
  "additionalProperties": false,
753
- "description": "Number count animation."
881
+ "description": "Counter animated number tick from startValue to endValue.\n\nWHEN TO USE:\n • Marketing landing — \"10,000+ users\" KPI displays\n • Stat dashboards (animate when value changes)\n • Live tickers / real-time data — re-render plain text instead (Counter is one-shot animation)\n • Currency input / editable number → NumberInput / PriceInput\n\ntriggerOnView=true delays animation until element scrolls into view (good for landing pages).\n\nANTI-PATTERNS:\n ✗ Counter for values that update frequently — animation queue conflicts\n ✗ Long duration on critical numbers (users wait to read)\n ✗ Counter without separator for large numbers (hard to read)"
882
+ }
883
+ },
884
+ "$schema": "http://json-schema.org/draft-07/schema#"
885
+ },
886
+ "dataGrid": {
887
+ "$ref": "#/definitions/dataGridPropsSchema",
888
+ "definitions": {
889
+ "dataGridPropsSchema": {
890
+ "type": "object",
891
+ "properties": {
892
+ "list": {
893
+ "anyOf": [
894
+ {
895
+ "type": "array"
896
+ },
897
+ {
898
+ "type": "null"
899
+ }
900
+ ],
901
+ "description": "Data array to render. null = loading state (required)"
902
+ },
903
+ "columns": {
904
+ "anyOf": [
905
+ {
906
+ "type": "number"
907
+ },
908
+ {
909
+ "type": "object",
910
+ "properties": {
911
+ "base": {
912
+ "type": "number",
913
+ "description": "Default column count (mobile-first)"
914
+ },
915
+ "sm": {
916
+ "type": "number",
917
+ "description": ">= 640px"
918
+ },
919
+ "md": {
920
+ "type": "number",
921
+ "description": ">= 768px"
922
+ },
923
+ "lg": {
924
+ "type": "number",
925
+ "description": ">= 1024px"
926
+ },
927
+ "xl": {
928
+ "type": "number",
929
+ "description": ">= 1280px"
930
+ },
931
+ "2xl": {
932
+ "type": "number",
933
+ "description": ">= 1536px"
934
+ }
935
+ },
936
+ "additionalProperties": false
937
+ }
938
+ ],
939
+ "description": "Column count. number = fixed | { base, sm, md, lg, xl, 2xl } = responsive (required)"
940
+ },
941
+ "gap": {
942
+ "type": [
943
+ "number",
944
+ "string"
945
+ ],
946
+ "description": "Item gap. number = px | string = CSS value"
947
+ },
948
+ "noDataMessage": {
949
+ "description": "Message for empty array (string | ReactElement)"
950
+ },
951
+ "errorFallback": {
952
+ "description": "Fallback on error (ReactNode)"
953
+ },
954
+ "loadingElement": {
955
+ "description": "Custom loading element (default: Spinner)"
956
+ },
957
+ "skeletonElement": {
958
+ "description": "Skeleton element during loading (ReactElement)"
959
+ },
960
+ "skeletonCount": {
961
+ "type": "number",
962
+ "default": 3,
963
+ "description": "Skeleton repeat count"
964
+ },
965
+ "loading": {
966
+ "type": "boolean",
967
+ "default": false,
968
+ "description": "Force loading state"
969
+ },
970
+ "children": {
971
+ "description": "Item render function: ({ item, index }) => ReactNode (required)"
972
+ },
973
+ "className": {
974
+ "type": "string",
975
+ "description": "Root element style"
976
+ }
977
+ },
978
+ "required": [
979
+ "list",
980
+ "columns"
981
+ ],
982
+ "additionalProperties": false,
983
+ "description": "DataGrid — card grid version of DataList with responsive columns. Built-in ErrorBoundary, loading/skeleton/empty/error states.\n\nWHEN TO USE:\n • Card grids: products, gallery, team members, posts\n • Need responsive column count → pass { base: 1, sm: 2, lg: 3, xl: 4 }\n • Single column / row layout → DataList\n • Tabular data → table component (not DataGrid)\n • Huge dataset → VirtualGrid\n\nANTI-PATTERNS:\n ✗ Tabular data forced into card grid (use a table)\n ✗ Hardcoded column count for responsive layouts → use responsive object\n ✗ Manual loading/empty handling → DataGrid does it"
754
984
  }
755
985
  },
756
986
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -806,7 +1036,7 @@
806
1036
  "list"
807
1037
  ],
808
1038
  "additionalProperties": false,
809
- "description": "Data list. Automatically handles loading/skeleton/empty/data states based on list. Built-in ErrorBoundary."
1039
+ "description": "DataList — render-prop list that handles loading / skeleton / empty / error / data in one component. Built-in ErrorBoundary.\n\nWHEN TO USE:\n • Any async list (<200 items) — feed, comments, dashboard rows\n • Pass list={null} during loading (auto-shows skeleton/spinner)\n • Pass list=[] for empty state (auto-shows noDataMessage)\n • Card grid → DataGrid (same API + columns prop)\n • Huge dataset → VirtualList\n\nchildren is render fn: ({ item, index }) => ReactNode.\n\nANTI-PATTERNS:\n ✗ Manual if (loading) {...} else if (!data.length) {...} chains → DataList handles all\n ✗ DataList without skeletonElement when component shape is known (use Skeleton)\n ✗ list=undefined (treated as data, not loading) — use null for loading"
810
1040
  }
811
1041
  },
812
1042
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -862,7 +1092,7 @@
862
1092
  }
863
1093
  },
864
1094
  "additionalProperties": false,
865
- "description": "DatePicker. Calendar popup for date selection. Based on react-day-picker."
1095
+ "description": "DatePicker calendar popup for date selection. Based on react-day-picker.\n\nWHEN TO USE:\n • Single date selection: birthday, due date, appointment\n • Date range → use two DatePickers with minDate/maxDate cross-bound\n • Time selection → not yet supported; use TextInput with type=\"time\" + DatePicker combo\n • Quick relative ranges (Today/Last 7 days) → DropdownMenu of preset Buttons + DatePicker for \"Custom\"\n\nminDate/maxDate disable out-of-range dates. locale=\"ko\" for Korean labels.\n\nANTI-PATTERNS:\n ✗ Native <input type=\"date\"> for branded UI (inconsistent across browsers) → DatePicker\n ✗ Free-text date with parsing → DatePicker (consistent UX)\n ✗ DatePicker without minDate for past-date-invalid fields (e.g. booking)"
866
1096
  }
867
1097
  },
868
1098
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -905,7 +1135,7 @@
905
1135
  }
906
1136
  },
907
1137
  "additionalProperties": false,
908
- "description": "Divider. Supports horizontal/vertical, solid/dashed/dotted."
1138
+ "description": "Divider visual separator (horizontal/vertical line).\n\nWHEN TO USE:\n • Separating sections within a card / list\n • Vertical separator between inline items (orientation=\"vertical\")\n • Use color prop sparingly — defaults to border-default token\n • For grouping form sections, prefer larger spacing over Divider\n • Tab/Accordion already provide visual separation — don't add Divider\n\nANTI-PATTERNS:\n ✗ Stacking many Dividers — increase spacing instead\n ✗ Using Divider as decorative line with bright color → use Tailwind border utility on container\n ✗ Inline <hr> with custom CSS → Divider (consistent token)"
909
1139
  }
910
1140
  },
911
1141
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -951,7 +1181,7 @@
951
1181
  }
952
1182
  },
953
1183
  "additionalProperties": false,
954
- "description": "Drawer/bottom sheet. Based on Vaul. Compound component pattern."
1184
+ "description": "Drawer / bottom sheet. Based on Vaul. Compound component pattern.\n\nWHEN TO USE:\n • Side panel for secondary action while user can still see main content (filter panel, item details)\n • Mobile bottom sheet (direction=\"bottom\")\n • Force decision blocking main flow → Modal instead\n • Inline anchor-positioned UI → Popover instead\n\nDIRECTION: bottom (default, mobile-friendly), top, left, right.\ndismissible=true (default) allows swipe/outside-click close. Set false for blocking flows.\n\nANTI-PATTERNS:\n ✗ Drawer for confirmation dialogs → Modal (decision-forcing)\n ✗ Always shouldScaleBackground → only enable for true mobile bottom-sheets\n ✗ Forgetting Drawer.Title → required for screen readers (a11y)"
955
1185
  }
956
1186
  },
957
1187
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1172,7 +1402,7 @@
1172
1402
  "items"
1173
1403
  ],
1174
1404
  "additionalProperties": false,
1175
- "description": "Dropdown menu. Based on Radix DropdownMenu. Action menu for context/more menus."
1405
+ "description": "Dropdown menu — list of actions/commands triggered by a button. Based on Radix DropdownMenu (role=\"menu\" + keyboard nav).\n\nWHEN TO USE:\n • \"More\" / context menu (•••, ⋮)\n • Action lists where each item triggers a function (save, share, delete)\n • Selecting a value (form field) → Select / Combobox (not DropdownMenu)\n • Multi-select toggles → ToggleGroup or CheckBox group\n • Anchored info panel → Popover\n\nUse danger=true on destructive items (Delete) for visual + semantic emphasis.\nUse separator=true to group related actions.\n\nANTI-PATTERNS:\n ✗ DropdownMenu for value selection submitted later → Select / Combobox\n ✗ Custom <div onClick> with isOpen state → DropdownMenu\n ✗ Long form inputs inside menu items → Popover instead"
1176
1406
  }
1177
1407
  },
1178
1408
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1221,7 +1451,7 @@
1221
1451
  }
1222
1452
  },
1223
1453
  "additionalProperties": false,
1224
- "description": "Text ellipsis. Built-in show more/less toggle."
1454
+ "description": "Ellipsis clamp long text to N lines with \"show more / less\" toggle.\n\nWHEN TO USE:\n • Long descriptions in cards, comments, post previews\n • Single-line truncation only → CSS line-clamp utility (lighter)\n • Tooltip on hover for full text → Tooltip + truncate utility\n • Critical content that must be fully readable — don't truncate\n\ntriggerMore/triggerLess accept ReactNode for icons or styled buttons.\n\nANTI-PATTERNS:\n ✗ Ellipsis on titles / labels — confusing UX\n ✗ Always-collapsed (defaultShortened=true) for short text — measurement waste\n ✗ Overriding triggerMore/Less with HTML that breaks accessibility (use button-like)"
1225
1455
  }
1226
1456
  },
1227
1457
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1265,7 +1495,7 @@
1265
1495
  }
1266
1496
  },
1267
1497
  "additionalProperties": false,
1268
- "description": "Empty state placeholder. Shown when data is empty or unavailable."
1498
+ "description": "EmptyState friendly placeholder for empty lists, no search results, first-time setup.\n\nWHEN TO USE:\n • Empty inbox / list / search results\n • First-time use (onboarding nudge with action button)\n • Loading → Skeleton/Spinner (NOT EmptyState)\n • Error → Alert (or pass icon + title to EmptyState only when conceptually \"nothing here\")\n\nDataList/DataGrid have built-in noDataMessage that wraps EmptyState — use that prop instead of conditional rendering.\n\nANTI-PATTERNS:\n ✗ Showing EmptyState during loading (confuses users into thinking data is missing)\n ✗ EmptyState without action when user can fix it (\"Create your first X\" button)\n ✗ Cluttered EmptyState (too much text/multiple CTAs) — keep one primary action"
1269
1499
  }
1270
1500
  },
1271
1501
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1287,7 +1517,7 @@
1287
1517
  }
1288
1518
  },
1289
1519
  "additionalProperties": false,
1290
- "description": "Error boundary. Catches child component render errors and displays fallback UI."
1520
+ "description": "ErrorBoundary catches render-time errors in subtree and shows fallback UI.\n\nWHEN TO USE:\n • Wrap risky areas: third-party widgets, dynamic imports, untrusted content rendering\n • Async errors / promise rejections → NOT caught (use try/catch in handlers)\n • Per-route error wrapping → use framework's error.tsx (Next.js) where possible\n\nDataList / DataGrid have ErrorBoundary built-in — don't double-wrap.\n\nANTI-PATTERNS:\n ✗ ErrorBoundary at app root only — granular boundaries give better UX (one widget fails, page survives)\n ✗ Showing raw Error.message in production (leak risk) — use friendly fallback\n ✗ Forgetting onError logging → silent failures in production"
1291
1521
  }
1292
1522
  },
1293
1523
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1370,7 +1600,7 @@
1370
1600
  }
1371
1601
  },
1372
1602
  "additionalProperties": false,
1373
- "description": "ImageUpload. Drag-and-drop image upload with preview, file validation, and field label/description support."
1603
+ "description": "ImageUpload — drag-and-drop image upload with preview, file-type/size validation, label/description.\n\nWHEN TO USE:\n • Single image upload: avatar, cover, KYC document, post thumbnail\n • Multiple files / non-image → not yet supported; build custom or use a file dropzone\n • Inline image picker without preview → custom <input type=\"file\">\n\naccept whitelist + maxSize together cover validation. onError fires with i18n-ready string.\n\nANTI-PATTERNS:\n ✗ <input type=\"file\"> + manual preview → ImageUpload (handles drag, validation, preview)\n ✗ ImageUpload without onError handler → silent failure on validation reject\n ✗ Storing image as data-URL value (use File via onChange and upload to server)"
1374
1604
  }
1375
1605
  },
1376
1606
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1435,7 +1665,7 @@
1435
1665
  "list"
1436
1666
  ],
1437
1667
  "additionalProperties": false,
1438
- "description": "Infinite scroll. Based on IntersectionObserver."
1668
+ "description": "InfiniteScroll — auto-load more when sentinel enters viewport. Based on IntersectionObserver.\n\nWHEN TO USE:\n • Feeds, social timelines, search-as-you-scroll\n • Continuous browsing where total isn't critical\n • Need jump-to-page → Pagination (not InfiniteScroll)\n • Need to render 1000s of already-loaded items efficiently → VirtualList\n • Combine with VirtualList for huge + paginated data\n\nPass either totalCount or hasMore (not both). handleLoadMore is required.\n\nANTI-PATTERNS:\n ✗ InfiniteScroll without footer/loading element (looks broken at the bottom)\n ✗ InfiniteScroll without debouncing handleLoadMore — duplicate fetches\n ✗ Auto-loading critical actions in footer (links, contact) — they become unreachable"
1439
1669
  }
1440
1670
  },
1441
1671
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1484,7 +1714,7 @@
1484
1714
  }
1485
1715
  },
1486
1716
  "additionalProperties": false,
1487
- "description": "Marquee (scrolling text/elements)."
1717
+ "description": "Marquee — endless scrolling content (logo strip, promo banner, news ticker).\n\nWHEN TO USE:\n • Logo cloud, partner brands strip, social proof\n • Critical info that must be read → not Marquee (auto-scroll hurts a11y)\n • Long static list → VirtualList\n • User-paced gallery → Carousel\n\npauseOnHover=true is recommended whenever content is readable text.\n\nANTI-PATTERNS:\n ✗ Marquee with action buttons inside (hard to click)\n ✗ Fast-speed marquee on important text (unreadable, a11y violation)\n ✗ Multiple Marquees on same page in different directions (visual chaos)"
1488
1718
  }
1489
1719
  },
1490
1720
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1610,7 +1840,7 @@
1610
1840
  }
1611
1841
  },
1612
1842
  "additionalProperties": false,
1613
- "description": "Modal template. All modal components must be wrapped with ModalTemplate."
1843
+ "description": "Modal template. All modal components must be wrapped with ModalTemplate.\n\nWHEN TO USE:\n • Force user decision (delete confirm, submit confirm, blocking dialog)\n • Long form/flow that needs full attention\n • Side panel that doesn't block main flow → Drawer instead\n • Inline contextual UI → Popover instead\n • Short hint → Tooltip instead\n\nPREFERRED API: use modal() / useModal() imperative API rather than mounting <ModalTemplate> directly. modal() handles stacking, focus return, ESC, and background scroll automatically.\n\nANTI-PATTERNS:\n ✗ Custom <div className=\"fixed inset-0\"> → modal() (loses focus trap, a11y)\n ✗ Direct <ModalTemplate> mount in render tree → wrap with modal()\n ✗ Modal with no title for screen readers → always pass title prop\n ✗ Multiple modals stacking confusingly → use isAlone:true to close prior modals"
1614
1844
  }
1615
1845
  },
1616
1846
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1823,7 +2053,7 @@
1823
2053
  }
1824
2054
  },
1825
2055
  "additionalProperties": false,
1826
- "description": "Number input with two variants: basic (chevron arrows) and bind (+/- buttons). Supports label, description, max display (click to fill), accelerated increment on long press. numberInputBind(ref, direction) binds acceleration to external buttons."
2056
+ "description": "Number input with two variants: basic (chevron arrows) and bind (+/- buttons). Supports label, description, max display (click to fill), accelerated increment on long press. numberInputBind(ref, direction) binds acceleration to external buttons.\n\nWHEN TO USE:\n • Any numeric field — quantity, score, age, count\n • Currency with thousand separators → PriceInput instead\n • Date / time → DatePicker instead\n\nANTI-PATTERNS:\n ✗ <TextInput type=\"number\"> → <NumberInput> (loses keyboard ↑↓, step, accelerated long-press, max click)\n ✗ Custom +/- buttons + <input> → variant=\"bind\" (or numberInputBind for external)\n ✗ Manual thousand separators for currency → PriceInput"
1827
2057
  }
1828
2058
  },
1829
2059
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1879,7 +2109,7 @@
1879
2109
  }
1880
2110
  },
1881
2111
  "additionalProperties": false,
1882
- "description": "Enhanced image. Lazy loading, fallback, aspect-ratio support."
2112
+ "description": "NxImage lazy-loaded <img> with fallback, fixed aspect-ratio, object-fit. Always prefer over native <img>.\n\nWHEN TO USE:\n • Content images: covers, banners, illustrations, hero images\n • Profile/user avatar (with text fallback) → Avatar\n • Background image / decorative → CSS bg-image\n • Need Next.js optimization → use next/image directly (NxImage doesn't optimize)\n\naspectRatio reserves space, preventing CLS (layout shift).\n\nANTI-PATTERNS:\n ✗ <img> with manual onError handling → NxImage (built-in fallback)\n ✗ NxImage without alt for content images (a11y violation)\n ✗ NxImage without aspectRatio in fluid layouts → CLS jank"
1883
2113
  }
1884
2114
  },
1885
2115
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1929,7 +2159,7 @@
1929
2159
  "totalPages"
1930
2160
  ],
1931
2161
  "additionalProperties": false,
1932
- "description": "Pagination. Previous/next + page number buttons."
2162
+ "description": "Pagination page-by-page navigation for long datasets.\n\nWHEN TO USE:\n • User needs to jump to specific pages (search results, blog archives)\n • Total count is known and stable\n • Continuous browsing → InfiniteScroll instead\n • Real-time stream → InfiniteScroll\n • Both fit → Pagination is more accessible (keyboard, deep-linkable URL)\n\nANTI-PATTERNS:\n ✗ Pagination with totalPages=1 — hide it\n ✗ Mixing Pagination + InfiniteScroll on same list (confusing)\n ✗ Custom page button divs → Pagination (a11y, edge cases like ellipsis)"
1933
2163
  }
1934
2164
  },
1935
2165
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -1996,7 +2226,7 @@
1996
2226
  }
1997
2227
  },
1998
2228
  "additionalProperties": false,
1999
- "description": "Popover. Based on Radix Popover."
2229
+ "description": "Popover — anchor-positioned panel with interactive content. Based on Radix Popover.\n\nWHEN TO USE:\n • Trigger-anchored UI with buttons, inputs, or rich content\n • Filter/option panel near a button (not a full sidebar)\n • Hover-only text hint → Tooltip (lighter)\n • Action menu list → DropdownMenu (gives role=menu, keyboard nav)\n • Decision dialog → Modal\n\nANTI-PATTERNS:\n ✗ Action lists with onClick handlers → DropdownMenu (a11y semantics)\n ✗ Implementing dropdown manually with Popover + custom buttons → DropdownMenu\n ✗ Long forms inside Popover → Drawer or Modal"
2000
2230
  }
2001
2231
  },
2002
2232
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2100,7 +2330,7 @@
2100
2330
  }
2101
2331
  },
2102
2332
  "additionalProperties": false,
2103
- "description": "Price/amount input field with prefix, suffix, balance display, and auto-fill on balance click."
2333
+ "description": "PriceInput — currency / amount input with prefix, suffix, balance display, click-to-fill.\n\nWHEN TO USE:\n • Money / token amounts: payment, transfer, swap, withdraw\n • Need balance hint with auto-fill UX (set balance + onBalanceClick)\n • Pure number (count, age, score) → NumberInput\n • Generic text → TextInput\n\nseparator=true displays commas; onValueChange always returns raw value (no commas). maxBalance auto-applies error styling on overflow.\n\nANTI-PATTERNS:\n ✗ <TextInput type=\"number\"> + manual currency formatting → PriceInput\n ✗ NumberInput for currency (loses prefix/suffix/balance UX)\n ✗ Using string input for amounts then parseFloat — lose precision; use this component"
2104
2334
  }
2105
2335
  },
2106
2336
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2163,7 +2393,7 @@
2163
2393
  }
2164
2394
  },
2165
2395
  "additionalProperties": false,
2166
- "description": "Progress bar. Linear progress indicator with percentage display."
2396
+ "description": "Progress linear progress bar (file upload, multi-step form, loading with known %).\n\nWHEN TO USE:\n • Quantifiable progress (% complete, X of Y)\n • Unknown duration spinner → Spinner\n • Stable component shape during load → Skeleton\n • Step-based navigation → Stepper\n • Indeterminate (loading without %) → set indeterminate=true\n\nvariant follows semantic colors (success when complete, danger on error).\n\nANTI-PATTERNS:\n ✗ Indeterminate Progress for short loads (<1s) — Spinner is lighter\n ✗ Custom <div style={{ width: x% }}> → Progress (a11y, tokens)\n ✗ Progress without label/showValue when % is critical info"
2167
2397
  }
2168
2398
  },
2169
2399
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2195,6 +2425,15 @@
2195
2425
  "default": "md",
2196
2426
  "description": "Size"
2197
2427
  },
2428
+ "variant": {
2429
+ "type": "string",
2430
+ "enum": [
2431
+ "default",
2432
+ "ring"
2433
+ ],
2434
+ "default": "default",
2435
+ "description": "Visual style. default=outline circle with inner dot, ring=thick border replaces dot when checked"
2436
+ },
2198
2437
  "orientation": {
2199
2438
  "type": "string",
2200
2439
  "enum": [
@@ -2231,7 +2470,7 @@
2231
2470
  "name"
2232
2471
  ],
2233
2472
  "additionalProperties": false,
2234
- "description": "Radio group. Used with RadioItem."
2473
+ "description": "Radio group for single-choice form fields. Used with RadioItem.\n\nWHEN TO USE:\n • Form field where user picks ONE of small set (≤4-7) and submits later → RadioGroup\n • All options should be visible at once for comparison → RadioGroup (not Select)\n • Immediate effect on selection (no submit) → ToggleGroup instead\n • Page area switching (tabs) → Tab (not RadioGroup)\n • Many options → Select / Combobox\n\nVARIANTS:\n • variant=\"default\" — outline circle with inner dot when checked (classic)\n • variant=\"ring\" — thick border replaces inner dot when checked (modern, Figma \"ring\" style)\n\nANTI-PATTERNS:\n ✗ Using RadioGroup for tab-like content switching → Tab\n ✗ Using RadioGroup for immediate filters → ToggleGroup\n ✗ Mixing RadioGroup and ToggleGroup in same form → pick one pattern\n ✗ Native <input type=\"radio\"> → RadioItem (gets a11y, focus ring, tokens)"
2235
2474
  }
2236
2475
  },
2237
2476
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2254,9 +2493,20 @@
2254
2493
  ],
2255
2494
  "description": "Size (overrides group)"
2256
2495
  },
2496
+ "variant": {
2497
+ "type": "string",
2498
+ "enum": [
2499
+ "default",
2500
+ "ring"
2501
+ ],
2502
+ "description": "Visual style (overrides group)"
2503
+ },
2257
2504
  "label": {
2258
2505
  "description": "Label text (ReactNode)"
2259
2506
  },
2507
+ "description": {
2508
+ "description": "Help text shown beneath the label (ReactNode)"
2509
+ },
2260
2510
  "children": {
2261
2511
  "description": "Label alternative content (ReactNode)"
2262
2512
  },
@@ -2335,7 +2585,7 @@
2335
2585
  }
2336
2586
  },
2337
2587
  "additionalProperties": false,
2338
- "description": "Dropdown select. Based on Radix Select. Used with SelectItem."
2588
+ "description": "Dropdown select for short option lists. Based on Radix Select. Used with SelectItem.\n\nWHEN TO USE:\n • Options ≤ 7, no search needed → Select\n • Options ≥ 7 OR search needed OR async → Combobox instead\n • Need multi-select → Combobox (multiple)\n • Action menu (save/delete/share) → DropdownMenu (not Select; values vs actions)\n\nANTI-PATTERNS:\n ✗ Select with 20+ options → Combobox\n ✗ Using Select for menu items that trigger functions → DropdownMenu\n ✗ Manual <select> styling → Select gives consistent token styling\n ✗ Wrapping each SelectItem with Tooltip — instead put hint in item label"
2339
2589
  }
2340
2590
  },
2341
2591
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2417,7 +2667,7 @@
2417
2667
  }
2418
2668
  },
2419
2669
  "additionalProperties": false,
2420
- "description": "Skeleton loading placeholder. Size/shape via className. With children, wraps transparently to maintain actual size."
2670
+ "description": "Skeleton loading placeholder. Size/shape via className. With children, wraps transparently to maintain actual size.\n\nWHEN TO USE:\n • Long load with known component shape (cards, lists, profile headers)\n • Reduces perceived wait time when layout is predictable\n • Short loads (<1s) → Spinner\n • Quantifiable progress → Progress\n • DataList/DataGrid loading → set list={null} (uses skeletonElement prop automatically)\n\nGOLDEN RULE: Skeleton must match the real component's shape and size. Mismatch causes layout shift.\n\nANTI-PATTERNS:\n ✗ Generic gray rectangle for everything → match real component shape\n ✗ Skeleton for instant loads (causes flash)\n ✗ Many skeletons of different shapes when component is uniform → use a single skeleton in DataList"
2421
2671
  }
2422
2672
  },
2423
2673
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2495,7 +2745,7 @@
2495
2745
  }
2496
2746
  },
2497
2747
  "additionalProperties": false,
2498
- "description": "Slider / Range input. Based on Radix Slider. Supports single and range mode."
2748
+ "description": "Slider numeric range selector. Based on Radix Slider. Single thumb or range (two thumbs).\n\nWHEN TO USE:\n • Continuous range with visual feedback: volume, brightness, price filter\n • Range filter (min-max) → defaultValue=[20, 80]\n • Precise number entry → NumberInput\n • Discrete few options → ToggleGroup or RadioGroup\n • Boolean → Switch\n\nstep controls increments. onValueCommit fires only after pointer release (good for expensive recomputations).\n\nANTI-PATTERNS:\n ✗ Slider for required precise input (typing 47 is faster than dragging)\n ✗ Long step count without showValue / labels (users have no reference)\n ✗ Calling expensive API on every onValueChange tick → use onValueCommit"
2499
2749
  }
2500
2750
  },
2501
2751
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2529,7 +2779,7 @@
2529
2779
  }
2530
2780
  },
2531
2781
  "additionalProperties": false,
2532
- "description": "Loading indicator. SVG-based. Built-in role=\"status\"."
2782
+ "description": "Loading indicator (spinner). SVG-based. role=\"status\" + aria-label built-in.\n\nWHEN TO USE:\n • Short loads (<1s), inline indicator (button content while submitting)\n • Long loads with known structure → Skeleton (better perceived performance)\n • Quantifiable progress → Progress\n • Page-level loading boundary inside DataList/DataGrid → use their loading prop instead\n\nANTI-PATTERNS:\n ✗ Custom CSS spinning div → Spinner (a11y + tokens)\n ✗ Using Spinner where Skeleton fits (long loads with stable layout)\n ✗ Forgetting aria-label override when meaning differs from \"Loading\""
2533
2783
  }
2534
2784
  },
2535
2785
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2602,7 +2852,7 @@
2602
2852
  "steps"
2603
2853
  ],
2604
2854
  "additionalProperties": false,
2605
- "description": "Stepper. Step-by-step progress indicator."
2855
+ "description": "Stepper — multi-step linear flow indicator (checkout, onboarding, wizard).\n\nWHEN TO USE:\n • Sequential workflow with finite steps (3-7)\n • Show user's current position in flow + completed/upcoming steps\n • Independent navigation between unrelated sections → Tab\n • Continuous % progress → Progress\n • Hierarchy / location → Breadcrumb\n\nstatus=\"error\" highlights the current step with danger color when validation fails.\n\nANTI-PATTERNS:\n ✗ Stepper with 2 steps (use Progress or just navigation)\n ✗ Stepper with 10+ steps (overwhelming) — chunk into sub-flows\n ✗ Letting users skip ahead by clicking future steps (only mark completed → current is allowed)"
2606
2856
  }
2607
2857
  },
2608
2858
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2654,7 +2904,7 @@
2654
2904
  }
2655
2905
  },
2656
2906
  "additionalProperties": false,
2657
- "description": "Toggle switch. Native checkbox-based, role=\"switch\"."
2907
+ "description": "Toggle switch for immediate on/off binary state. Native checkbox-based, role=\"switch\".\n\nWHEN TO USE:\n • Setting that takes effect immediately (notifications on/off, dark mode)\n • Binary state with no submit step\n • Form field submitted later → CheckBox instead (semantics: checkbox is form data)\n • Multiple related options → CheckBox group or ToggleGroup (multiple)\n\nANTI-PATTERNS:\n ✗ <CheckBox> for \"Enable notifications\" toggle → <Switch>\n ✗ <Switch> inside form requiring submit → <CheckBox>\n ✗ Wrapping Switch in <label onClick> manually → use label prop or htmlFor pattern"
2658
2908
  }
2659
2909
  },
2660
2910
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2743,7 +2993,7 @@
2743
2993
  "items"
2744
2994
  ],
2745
2995
  "additionalProperties": false,
2746
- "description": "Tab navigation. line/pill variants."
2996
+ "description": "Tab navigation — switch between content panels (settings sections, profile views).\n\nWHEN TO USE:\n • Page area swap where only one panel is visible at a time\n • Mutually exclusive content with stable section labels\n • Form field selection → RadioGroup (semantics: not navigation)\n • Immediate filter/option toggle → ToggleGroup\n • Stacked collapsible sections → Accordion\n\ndestroyInactive=true unmounts hidden panels (saves memory but loses state).\n\nANTI-PATTERNS:\n ✗ Tab with 1 item — just render the panel\n ✗ Tab with 8+ items — consider sub-routing or DropdownMenu\n ✗ Using Tab for form value selection → RadioGroup\n ✗ Custom <button> + onClick + state → Tab (a11y, keyboard, focus management)"
2747
2997
  }
2748
2998
  },
2749
2999
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2818,7 +3068,7 @@
2818
3068
  "list"
2819
3069
  ],
2820
3070
  "additionalProperties": false,
2821
- "description": "Table. Column definitions via TdColumn, row wrapping via TableRow. Built-in sorting/skeleton loading."
3071
+ "description": "Table — tabular data with sortable columns, skeleton/loading/empty states. Compound: TableRow + TdColumn.\n\nWHEN TO USE:\n • Comparable structured data (financial reports, transaction history, leaderboard)\n • Sortable per-column → enableSorting on TdColumn\n • Card-style entities → DataGrid\n • Single-column read-only list → DataList\n • Huge dataset (>500 rows) → wrap with VirtualList logic or paginate\n\nlist={null} → loading state. list=[] → noDataMsg. children: ({ item, index }) => <TableRow>...</TableRow>.\n\nANTI-PATTERNS:\n ✗ Native <table> + manual loading/empty handling → Table component\n ✗ Forcing card-style data into Table (use DataGrid)\n ✗ Sorting in client when server pagination is in use → server-side sort"
2822
3072
  }
2823
3073
  },
2824
3074
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2850,7 +3100,7 @@
2850
3100
  }
2851
3101
  },
2852
3102
  "additionalProperties": false,
2853
- "description": "Table row. Used inside Table."
3103
+ "description": "TableRow — a single row inside Table. Wraps TdColumn cells.\n\nWHEN TO USE:\n • variant=\"accent\" highlights selected/current row\n • onClick for row-level navigation (e.g. open detail page)\n • Per-row checkbox/action → place inside a TdColumn child"
2854
3104
  }
2855
3105
  },
2856
3106
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -2957,7 +3207,7 @@
2957
3207
  "fieldId"
2958
3208
  ],
2959
3209
  "additionalProperties": false,
2960
- "description": "Table cell/column definition. Used inside TableRow."
3210
+ "description": "TdColumn — table cell. Drives both <th> and <td> for the column. Provides sorting, alignment, overflow handling.\n\nWHEN TO USE:\n • textOverflow=\"truncate\" (default) for fixed-width columns; \"wrap\" for narrative\n • align=\"right\" for numeric/currency columns (a11y readability)\n • enableSorting=true when column is sortable; supply order + handleClickSort for controlled sort\n • highlightKey to group columns that highlight together on hover\n\nANTI-PATTERNS:\n ✗ enableSorting without handleClickSort → sort indicator is dead\n ✗ align=\"left\" for currency/number columns\n ✗ Mixing text and numeric in one column without consistent align"
2961
3211
  }
2962
3212
  },
2963
3213
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3027,7 +3277,7 @@
3027
3277
  }
3028
3278
  },
3029
3279
  "additionalProperties": false,
3030
- "description": "Tag input. Enter key to add, Backspace to delete last tag."
3280
+ "description": "TagInput free-form multi-value entry (Enter to add, Backspace to remove last).\n\nWHEN TO USE:\n • Free-form labels: skills, hashtags, email recipients, keywords\n • Predefined options → Combobox with multi-select (NOT TagInput)\n • Single value → TextInput\n • Limited options → Select / RadioGroup / Checkbox\n\nallowDuplicates=false (default) prevents repeats. Use max to cap count.\n\nANTI-PATTERNS:\n ✗ TagInput for predefined taxonomy → Combobox (controlled options)\n ✗ TagInput without max for spam-prone fields\n ✗ Custom comma-split string field → TagInput (proper UX + a11y)"
3031
3281
  }
3032
3282
  },
3033
3283
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3129,7 +3379,7 @@
3129
3379
  }
3130
3380
  },
3131
3381
  "additionalProperties": false,
3132
- "description": "Multi-line text input with label, description, character counter, and resize modes."
3382
+ "description": "Multi-line text input. Always prefer over native <textarea>.\n\nWHEN TO USE:\n • Long-form text — comments, descriptions, memos, bios\n • Single-line input → TextInput\n • Numeric → NumberInput\n\nresize=\"auto\" auto-grows with content (great for chat input). resize=\"none\" locks size for fixed UI.\n\nANTI-PATTERNS:\n ✗ Native <textarea> + custom counter → showCount + maxLength\n ✗ <TextArea> for short labels — use TextInput (smaller affordance)\n ✗ Wrapping with custom <label>/<p> → use built-in label/description props (auto a11y binding)"
3133
3383
  }
3134
3384
  },
3135
3385
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3236,72 +3486,7 @@
3236
3486
  }
3237
3487
  },
3238
3488
  "additionalProperties": false,
3239
- "description": "Text input field. Supports label, description, prefix/suffix icons, clearable, character counter."
3240
- }
3241
- },
3242
- "$schema": "http://json-schema.org/draft-07/schema#"
3243
- },
3244
- "themeProvider": {
3245
- "$ref": "#/definitions/themeProviderPropsSchema",
3246
- "definitions": {
3247
- "themeProviderPropsSchema": {
3248
- "type": "object",
3249
- "properties": {
3250
- "children": {
3251
- "description": "App root element (ReactNode, required)"
3252
- },
3253
- "defaultTheme": {
3254
- "type": "string",
3255
- "description": "Default theme (e.g. \"dark\", \"light\")"
3256
- },
3257
- "storageKey": {
3258
- "type": "string",
3259
- "description": "localStorage storage key (default: \"theme\")"
3260
- },
3261
- "themes": {
3262
- "type": "array",
3263
- "items": {
3264
- "type": "string"
3265
- },
3266
- "description": "Available theme list (default: [\"light\", \"dark\"])"
3267
- },
3268
- "attribute": {
3269
- "anyOf": [
3270
- {
3271
- "type": "string"
3272
- },
3273
- {
3274
- "type": "array",
3275
- "items": {
3276
- "type": "string"
3277
- }
3278
- }
3279
- ],
3280
- "description": "Theme HTML attribute (default: \"data-theme\")"
3281
- },
3282
- "enableSystem": {
3283
- "type": "boolean",
3284
- "description": "Enable system theme detection"
3285
- },
3286
- "disableTransitionOnChange": {
3287
- "type": "boolean",
3288
- "description": "Disable transitions on theme change"
3289
- },
3290
- "forcedTheme": {
3291
- "type": "string",
3292
- "description": "Forced theme (user cannot change)"
3293
- },
3294
- "enableColorScheme": {
3295
- "type": "boolean",
3296
- "description": "Auto-set color-scheme CSS property"
3297
- },
3298
- "nonce": {
3299
- "type": "string",
3300
- "description": "CSP nonce"
3301
- }
3302
- },
3303
- "additionalProperties": false,
3304
- "description": "Theme provider. Based on next-themes. Access theme state via useTheme() hook."
3489
+ "description": "Single-line text input (always prefer over native <input type=\"text\">).\n\nWHEN TO USE: any short text — name, email, search, URL, password.\nUse the built-in label/description props instead of wrapping with your own <label>/<p> tags (auto-binds htmlFor/aria-describedby for accessibility).\nFor numeric input use NumberInput; for currency PriceInput; for long text TextArea; for date DatePicker.\n\nANTI-PATTERNS:\n ✗ <TextInput type=\"number\"> → <NumberInput> (gives unit, step, ↑↓ keys)\n ✗ <label>Email <input ...></label> + <p>helper</p> → <TextInput label=\"Email\" description=\"helper\">\n ✗ Custom red border for error → use error prop (auto aria-invalid + token color)\n ✗ Manual character counter → use showCount + maxLength\n ✗ Manual clear X button → use clearable prop"
3305
3490
  }
3306
3491
  },
3307
3492
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3382,7 +3567,7 @@
3382
3567
  }
3383
3568
  },
3384
3569
  "additionalProperties": false,
3385
- "description": "toast() call options. Used as toast(message, options). Fully customizable via toast.custom(jsx)."
3570
+ "description": "toast() options. Used as toast(message, options) / toast.success / .error / .warning / .info / .promise / .custom(jsx).\n\nWHEN TO USE TOAST:\n • Transient feedback after user action: \"Saved\", \"Copied\", \"Network error\"\n • Persistent in-page banner → Alert\n • Critical destructive confirmation → Modal (toast can be missed)\n • Form field error → use error/description prop on the input\n\nrichColors=true gives strong success/error/warning/info colors. Use action for \"Undo\" patterns.\n\nANTI-PATTERNS:\n ✗ Toast for confirmation that user MUST acknowledge → Modal\n ✗ Stacking many toasts → set visibleToasts on Toaster\n ✗ Long-form content in toast (toast is for short messages)"
3386
3571
  }
3387
3572
  },
3388
3573
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3458,7 +3643,7 @@
3458
3643
  }
3459
3644
  },
3460
3645
  "additionalProperties": false,
3461
- "description": "Toaster config. Place once at app root. Display notifications via toast(). Based on sonner."
3646
+ "description": "Toaster — toast container. Mount ONCE at app root. Then call toast() anywhere. Based on sonner.\n\nWHEN TO USE:\n • Mount in app shell (layout.tsx / _app.tsx) — exactly one instance globally\n • Set position once here; per-toast position only when needed\n • Provide visibleToasts cap to avoid stacking\n\nANTI-PATTERNS:\n ✗ Multiple Toasters across pages — only one global Toaster\n ✗ Mounting Toaster inside conditional render — toasts vanish on remount\n ✗ Forgetting Toaster mount — toast() calls do nothing"
3462
3647
  }
3463
3648
  },
3464
3649
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3523,10 +3708,11 @@
3523
3708
  "enum": [
3524
3709
  "default",
3525
3710
  "primary",
3526
- "secondary"
3711
+ "secondary",
3712
+ "outline"
3527
3713
  ],
3528
3714
  "default": "default",
3529
- "description": "Style variant (default=slider, primary=accent filled, secondary=accent filled)"
3715
+ "description": "Style variant (default=slider, primary/secondary=accent filled, outline=bordered buttons with no background)"
3530
3716
  },
3531
3717
  "size": {
3532
3718
  "type": "string",
@@ -3538,6 +3724,11 @@
3538
3724
  "default": "md",
3539
3725
  "description": "Size"
3540
3726
  },
3727
+ "fullWidth": {
3728
+ "type": "boolean",
3729
+ "default": false,
3730
+ "description": "Stretch the group to parent width and split items equally"
3731
+ },
3541
3732
  "disabled": {
3542
3733
  "type": "boolean",
3543
3734
  "description": "Disable all items"
@@ -3556,7 +3747,7 @@
3556
3747
  "items"
3557
3748
  ],
3558
3749
  "additionalProperties": false,
3559
- "description": "Toggle group / Segment control. Based on Radix ToggleGroup."
3750
+ "description": "Toggle group / Segment control for immediate-effect option selection. Based on Radix ToggleGroup.\n\nWHEN TO USE:\n • Sort order, view mode (grid/list), filter chips — selection takes effect immediately\n • Visual comparison important (icons or short labels)\n • Form field that submits later → RadioGroup or CheckBox instead\n • Page area switching (settings tabs) → Tab instead\n\nVARIANTS:\n • default — slider-style background (sleek)\n • primary / secondary — accent-filled selected state\n • outline — bordered buttons with no background (button-style toolbar)\n\nfullWidth=true distributes items equally across parent width (use with outline variant for button-row look).\n\ntype=\"single\" requires at least one selection by default (required=true). Set required=false to allow deselection.\n\nANTI-PATTERNS:\n ✗ Using ToggleGroup for content tabs → Tab\n ✗ Using ToggleGroup as form field submitted later → RadioGroup (semantics + a11y)\n ✗ Mixing icons and text labels of different sizes — keep visual rhythm consistent"
3560
3751
  }
3561
3752
  },
3562
3753
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3623,7 +3814,7 @@
3623
3814
  }
3624
3815
  },
3625
3816
  "additionalProperties": false,
3626
- "description": "Tooltip. Based on Radix Tooltip. Built-in Provider."
3817
+ "description": "Tooltip — short text hint shown on hover/focus. Based on Radix Tooltip. Provider built-in.\n\nWHEN TO USE:\n • Brief explanation of an icon button or truncated label\n • Hover-only, non-interactive content (text only)\n • Need clickable content inside → Popover (not Tooltip)\n • Action menu → DropdownMenu\n • Force user attention → Modal\n\nANTI-PATTERNS:\n ✗ Buttons/links inside content → use Popover (Tooltip not focusable)\n ✗ Long paragraphs in tooltip → consider Popover or Drawer\n ✗ Tooltip on disabled buttons (won't show in some browsers) — wrap in span instead\n ✗ Critical info only in tooltip — duplicate visible elsewhere for mobile/touch"
3627
3818
  }
3628
3819
  },
3629
3820
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3680,7 +3871,7 @@
3680
3871
  "items"
3681
3872
  ],
3682
3873
  "additionalProperties": false,
3683
- "description": "Virtual scroll list. Based on @tanstack/react-virtual."
3874
+ "description": "VirtualList performant rendering of huge lists (1000+ items). Based on @tanstack/react-virtual.\n\nWHEN TO USE:\n • Large datasets (>200 rows): chat history, transactions, logs, leaderboard\n • Stable item height (or measurable per-item via estimateSize fn)\n • Small list (<100 items) → DataList (much simpler API)\n • Grid layout → VirtualGrid\n • Server-side pagination → InfiniteScroll wrapping plain list\n\nestimateSize is critical — wrong values cause scroll jumps. Pair with onEndReached for server pagination.\n\nANTI-PATTERNS:\n ✗ VirtualList for short lists (DataList is simpler and renders faster)\n ✗ Variable estimateSize for uniform items — use a single number\n ✗ Putting interactive overlays inside virtual rows (mounted/unmounted on scroll)"
3684
3875
  }
3685
3876
  },
3686
3877
  "$schema": "http://json-schema.org/draft-07/schema#"
@@ -3742,7 +3933,7 @@
3742
3933
  "columns"
3743
3934
  ],
3744
3935
  "additionalProperties": false,
3745
- "description": "Virtual scroll grid. Based on @tanstack/react-virtual."
3936
+ "description": "VirtualGrid performant grid for huge lists. Based on @tanstack/react-virtual.\n\nWHEN TO USE:\n • Image gallery / card grid with 200+ items\n • Fixed column count (responsive via JS — recompute columns on breakpoint)\n • Small grid → DataGrid (no virtualization, simpler API)\n • Single-column list → VirtualList\n\nANTI-PATTERNS:\n ✗ VirtualGrid with <50 items — DataGrid is simpler\n ✗ Cards with hover-expanding height (breaks virtualization)\n ✗ Forgetting to recompute columns on resize → visible empty space"
3746
3937
  }
3747
3938
  },
3748
3939
  "$schema": "http://json-schema.org/draft-07/schema#"