tuiuiu.js 0.1.1 → 0.1.4-next.64ff654

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 (402) hide show
  1. package/README.md +67 -36
  2. package/dist/atoms/button.d.ts.map +1 -1
  3. package/dist/atoms/button.js +17 -9
  4. package/dist/atoms/button.js.map +1 -1
  5. package/dist/atoms/text-input.d.ts +2 -0
  6. package/dist/atoms/text-input.d.ts.map +1 -1
  7. package/dist/atoms/text-input.js +13 -7
  8. package/dist/atoms/text-input.js.map +1 -1
  9. package/dist/atoms/tooltip.d.ts.map +1 -1
  10. package/dist/atoms/tooltip.js +2 -1
  11. package/dist/atoms/tooltip.js.map +1 -1
  12. package/dist/cli/commands/help.d.ts +5 -0
  13. package/dist/cli/commands/help.d.ts.map +1 -0
  14. package/dist/cli/commands/help.js +31 -0
  15. package/dist/cli/commands/help.js.map +1 -0
  16. package/dist/cli/commands/mcp.d.ts +11 -0
  17. package/dist/cli/commands/mcp.d.ts.map +1 -0
  18. package/dist/cli/commands/mcp.js +21 -0
  19. package/dist/cli/commands/mcp.js.map +1 -0
  20. package/dist/cli/commands/storybook.d.ts +5 -0
  21. package/dist/cli/commands/storybook.d.ts.map +1 -0
  22. package/dist/cli/commands/storybook.js +9 -0
  23. package/dist/cli/commands/storybook.js.map +1 -0
  24. package/dist/cli/index.d.ts +14 -0
  25. package/dist/cli/index.d.ts.map +1 -0
  26. package/dist/cli/index.js +50 -0
  27. package/dist/cli/index.js.map +1 -0
  28. package/dist/core/error-boundary.d.ts.map +1 -1
  29. package/dist/core/error-boundary.js +2 -1
  30. package/dist/core/error-boundary.js.map +1 -1
  31. package/dist/core/hotkeys.d.ts +62 -0
  32. package/dist/core/hotkeys.d.ts.map +1 -0
  33. package/dist/core/hotkeys.js +0 -0
  34. package/dist/core/hotkeys.js.map +1 -0
  35. package/dist/core/index.d.ts +3 -1
  36. package/dist/core/index.d.ts.map +1 -1
  37. package/dist/core/index.js +9 -1
  38. package/dist/core/index.js.map +1 -1
  39. package/dist/core/screen.d.ts.map +1 -1
  40. package/dist/core/screen.js +2 -0
  41. package/dist/core/screen.js.map +1 -1
  42. package/dist/core/theme.d.ts +79 -0
  43. package/dist/core/theme.d.ts.map +1 -1
  44. package/dist/core/theme.js +358 -0
  45. package/dist/core/theme.js.map +1 -1
  46. package/dist/design-system/data-display/index.d.ts +9 -6
  47. package/dist/design-system/data-display/index.d.ts.map +1 -1
  48. package/dist/design-system/data-display/index.js +16 -7
  49. package/dist/design-system/data-display/index.js.map +1 -1
  50. package/dist/design-system/feedback/badge.d.ts +21 -4
  51. package/dist/design-system/feedback/badge.d.ts.map +1 -1
  52. package/dist/design-system/feedback/badge.js +15 -2
  53. package/dist/design-system/feedback/badge.js.map +1 -1
  54. package/dist/design-system/forms/index.d.ts +11 -8
  55. package/dist/design-system/forms/index.d.ts.map +1 -1
  56. package/dist/design-system/forms/index.js +19 -10
  57. package/dist/design-system/forms/index.js.map +1 -1
  58. package/dist/design-system/layout/index.d.ts +7 -4
  59. package/dist/design-system/layout/index.d.ts.map +1 -1
  60. package/dist/design-system/layout/index.js +18 -6
  61. package/dist/design-system/layout/index.js.map +1 -1
  62. package/dist/design-system/media/picture.d.ts.map +1 -1
  63. package/dist/design-system/media/picture.js +2 -1
  64. package/dist/design-system/media/picture.js.map +1 -1
  65. package/dist/design-system/overlays/index.d.ts +6 -3
  66. package/dist/design-system/overlays/index.d.ts.map +1 -1
  67. package/dist/design-system/overlays/index.js +9 -3
  68. package/dist/design-system/overlays/index.js.map +1 -1
  69. package/dist/design-system/visual/splash-screen.d.ts.map +1 -1
  70. package/dist/design-system/visual/splash-screen.js +38 -18
  71. package/dist/design-system/visual/splash-screen.js.map +1 -1
  72. package/dist/hooks/index.d.ts +2 -0
  73. package/dist/hooks/index.d.ts.map +1 -1
  74. package/dist/hooks/index.js +2 -0
  75. package/dist/hooks/index.js.map +1 -1
  76. package/dist/hooks/use-hotkeys.d.ts +153 -0
  77. package/dist/hooks/use-hotkeys.d.ts.map +1 -0
  78. package/dist/hooks/use-hotkeys.js +379 -0
  79. package/dist/hooks/use-hotkeys.js.map +1 -0
  80. package/dist/hooks/use-input.d.ts +2 -10
  81. package/dist/hooks/use-input.d.ts.map +1 -1
  82. package/dist/hooks/use-input.js +2 -287
  83. package/dist/hooks/use-input.js.map +1 -1
  84. package/dist/hooks/use-mouse.d.ts +5 -0
  85. package/dist/hooks/use-mouse.d.ts.map +1 -1
  86. package/dist/hooks/use-mouse.js +29 -11
  87. package/dist/hooks/use-mouse.js.map +1 -1
  88. package/dist/index.d.ts +6 -4
  89. package/dist/index.d.ts.map +1 -1
  90. package/dist/index.js +15 -3
  91. package/dist/index.js.map +1 -1
  92. package/dist/mcp/docs-data.d.ts +31 -0
  93. package/dist/mcp/docs-data.d.ts.map +1 -0
  94. package/dist/mcp/docs-data.js +637 -0
  95. package/dist/mcp/docs-data.js.map +1 -0
  96. package/dist/mcp/index.d.ts +14 -0
  97. package/dist/mcp/index.d.ts.map +1 -0
  98. package/dist/mcp/index.js +12 -0
  99. package/dist/mcp/index.js.map +1 -0
  100. package/dist/mcp/server.d.ts +31 -0
  101. package/dist/mcp/server.d.ts.map +1 -0
  102. package/dist/mcp/server.js +597 -0
  103. package/dist/mcp/server.js.map +1 -0
  104. package/dist/mcp/types.d.ts +114 -0
  105. package/dist/mcp/types.d.ts.map +1 -0
  106. package/dist/mcp/types.js +16 -0
  107. package/dist/mcp/types.js.map +1 -0
  108. package/dist/molecules/autocomplete.d.ts.map +1 -1
  109. package/dist/molecules/autocomplete.js +2 -1
  110. package/dist/molecules/autocomplete.js.map +1 -1
  111. package/dist/molecules/calendar.d.ts.map +1 -1
  112. package/dist/molecules/calendar.js +5 -3
  113. package/dist/molecules/calendar.js.map +1 -1
  114. package/dist/molecules/data-viz/annotations.d.ts +75 -0
  115. package/dist/molecules/data-viz/annotations.d.ts.map +1 -0
  116. package/dist/molecules/data-viz/annotations.js +40 -0
  117. package/dist/molecules/data-viz/annotations.js.map +1 -0
  118. package/dist/molecules/data-viz/gantt-chart.d.ts +66 -0
  119. package/dist/molecules/data-viz/gantt-chart.d.ts.map +1 -0
  120. package/dist/molecules/data-viz/gantt-chart.js +134 -0
  121. package/dist/molecules/data-viz/gantt-chart.js.map +1 -0
  122. package/dist/molecules/data-viz/gauge.d.ts +2 -2
  123. package/dist/molecules/data-viz/gauge.d.ts.map +1 -1
  124. package/dist/molecules/data-viz/gauge.js +24 -8
  125. package/dist/molecules/data-viz/gauge.js.map +1 -1
  126. package/dist/molecules/data-viz/heatmap.d.ts +8 -2
  127. package/dist/molecules/data-viz/heatmap.d.ts.map +1 -1
  128. package/dist/molecules/data-viz/heatmap.js +41 -9
  129. package/dist/molecules/data-viz/heatmap.js.map +1 -1
  130. package/dist/molecules/data-viz/hooks.d.ts +264 -0
  131. package/dist/molecules/data-viz/hooks.d.ts.map +1 -0
  132. package/dist/molecules/data-viz/hooks.js +373 -0
  133. package/dist/molecules/data-viz/hooks.js.map +1 -0
  134. package/dist/molecules/data-viz/index.d.ts +14 -0
  135. package/dist/molecules/data-viz/index.d.ts.map +1 -1
  136. package/dist/molecules/data-viz/index.js +14 -0
  137. package/dist/molecules/data-viz/index.js.map +1 -1
  138. package/dist/molecules/data-viz/legend.d.ts +82 -0
  139. package/dist/molecules/data-viz/legend.d.ts.map +1 -0
  140. package/dist/molecules/data-viz/legend.js +146 -0
  141. package/dist/molecules/data-viz/legend.js.map +1 -0
  142. package/dist/molecules/data-viz/line-chart.d.ts.map +1 -1
  143. package/dist/molecules/data-viz/line-chart.js +48 -12
  144. package/dist/molecules/data-viz/line-chart.js.map +1 -1
  145. package/dist/molecules/data-viz/radar-chart.d.ts +61 -0
  146. package/dist/molecules/data-viz/radar-chart.d.ts.map +1 -0
  147. package/dist/molecules/data-viz/radar-chart.js +86 -0
  148. package/dist/molecules/data-viz/radar-chart.js.map +1 -0
  149. package/dist/molecules/data-viz/scatter-plot.d.ts +97 -0
  150. package/dist/molecules/data-viz/scatter-plot.d.ts.map +1 -0
  151. package/dist/molecules/data-viz/scatter-plot.js +205 -0
  152. package/dist/molecules/data-viz/scatter-plot.js.map +1 -0
  153. package/dist/molecules/data-viz/time-heatmap.d.ts +48 -0
  154. package/dist/molecules/data-viz/time-heatmap.d.ts.map +1 -0
  155. package/dist/molecules/data-viz/time-heatmap.js +145 -0
  156. package/dist/molecules/data-viz/time-heatmap.js.map +1 -0
  157. package/dist/molecules/select.d.ts +2 -0
  158. package/dist/molecules/select.d.ts.map +1 -1
  159. package/dist/molecules/select.js +4 -3
  160. package/dist/molecules/select.js.map +1 -1
  161. package/dist/molecules/tabs.d.ts.map +1 -1
  162. package/dist/molecules/tabs.js +14 -2
  163. package/dist/molecules/tabs.js.map +1 -1
  164. package/dist/organisms/command-palette.d.ts.map +1 -1
  165. package/dist/organisms/command-palette.js +2 -1
  166. package/dist/organisms/command-palette.js.map +1 -1
  167. package/dist/storybook/app.d.ts.map +1 -1
  168. package/dist/storybook/app.js +53 -44
  169. package/dist/storybook/app.js.map +1 -1
  170. package/dist/storybook/components/compare-view.d.ts.map +1 -1
  171. package/dist/storybook/components/compare-view.js +19 -18
  172. package/dist/storybook/components/compare-view.js.map +1 -1
  173. package/dist/storybook/components/log-viewer.d.ts.map +1 -1
  174. package/dist/storybook/components/log-viewer.js +9 -8
  175. package/dist/storybook/components/log-viewer.js.map +1 -1
  176. package/dist/storybook/components/preview.d.ts.map +1 -1
  177. package/dist/storybook/components/preview.js +34 -33
  178. package/dist/storybook/components/preview.js.map +1 -1
  179. package/dist/storybook/components/sidebar.d.ts.map +1 -1
  180. package/dist/storybook/components/sidebar.js +21 -20
  181. package/dist/storybook/components/sidebar.js.map +1 -1
  182. package/dist/storybook/stories/apps/index.d.ts.map +1 -1
  183. package/dist/storybook/stories/apps/index.js +306 -209
  184. package/dist/storybook/stories/apps/index.js.map +1 -1
  185. package/dist/storybook/stories/atoms/index.d.ts.map +1 -1
  186. package/dist/storybook/stories/atoms/index.js.map +1 -1
  187. package/dist/storybook/stories/molecules/index.d.ts +25 -0
  188. package/dist/storybook/stories/molecules/index.d.ts.map +1 -1
  189. package/dist/storybook/stories/molecules/index.js +402 -20
  190. package/dist/storybook/stories/molecules/index.js.map +1 -1
  191. package/dist/storybook/stories/organisms/index.d.ts.map +1 -1
  192. package/dist/storybook/stories/organisms/index.js +1 -1
  193. package/dist/storybook/stories/organisms/index.js.map +1 -1
  194. package/dist/utils/index.d.ts +2 -0
  195. package/dist/utils/index.d.ts.map +1 -1
  196. package/dist/utils/index.js +2 -0
  197. package/dist/utils/index.js.map +1 -1
  198. package/dist/utils/system-data.d.ts +73 -0
  199. package/dist/utils/system-data.d.ts.map +1 -0
  200. package/dist/utils/system-data.js +367 -0
  201. package/dist/utils/system-data.js.map +1 -0
  202. package/dist/version.d.ts +43 -0
  203. package/dist/version.d.ts.map +1 -0
  204. package/dist/version.js +82 -0
  205. package/dist/version.js.map +1 -0
  206. package/package.json +22 -22
  207. package/dist/components/canvas.d.ts +0 -322
  208. package/dist/components/canvas.d.ts.map +0 -1
  209. package/dist/components/canvas.js +0 -833
  210. package/dist/components/canvas.js.map +0 -1
  211. package/dist/components/code-block.d.ts +0 -75
  212. package/dist/components/code-block.d.ts.map +0 -1
  213. package/dist/components/code-block.js +0 -322
  214. package/dist/components/code-block.js.map +0 -1
  215. package/dist/components/components.d.ts +0 -122
  216. package/dist/components/components.d.ts.map +0 -1
  217. package/dist/components/components.js +0 -151
  218. package/dist/components/components.js.map +0 -1
  219. package/dist/components/data-viz/bar-chart.d.ts +0 -167
  220. package/dist/components/data-viz/bar-chart.d.ts.map +0 -1
  221. package/dist/components/data-viz/bar-chart.js +0 -375
  222. package/dist/components/data-viz/bar-chart.js.map +0 -1
  223. package/dist/components/data-viz/gauge.d.ts +0 -163
  224. package/dist/components/data-viz/gauge.d.ts.map +0 -1
  225. package/dist/components/data-viz/gauge.js +0 -451
  226. package/dist/components/data-viz/gauge.js.map +0 -1
  227. package/dist/components/data-viz/heatmap.d.ts +0 -154
  228. package/dist/components/data-viz/heatmap.d.ts.map +0 -1
  229. package/dist/components/data-viz/heatmap.js +0 -458
  230. package/dist/components/data-viz/heatmap.js.map +0 -1
  231. package/dist/components/data-viz/index.d.ts +0 -16
  232. package/dist/components/data-viz/index.d.ts.map +0 -1
  233. package/dist/components/data-viz/index.js +0 -16
  234. package/dist/components/data-viz/index.js.map +0 -1
  235. package/dist/components/data-viz/line-chart.d.ts +0 -157
  236. package/dist/components/data-viz/line-chart.d.ts.map +0 -1
  237. package/dist/components/data-viz/line-chart.js +0 -578
  238. package/dist/components/data-viz/line-chart.js.map +0 -1
  239. package/dist/components/data-viz/sparkline.d.ts +0 -156
  240. package/dist/components/data-viz/sparkline.d.ts.map +0 -1
  241. package/dist/components/data-viz/sparkline.js +0 -325
  242. package/dist/components/data-viz/sparkline.js.map +0 -1
  243. package/dist/components/grid.d.ts +0 -234
  244. package/dist/components/grid.d.ts.map +0 -1
  245. package/dist/components/grid.js +0 -719
  246. package/dist/components/grid.js.map +0 -1
  247. package/dist/components/index.d.ts +0 -33
  248. package/dist/components/index.d.ts.map +0 -1
  249. package/dist/components/index.js +0 -69
  250. package/dist/components/index.js.map +0 -1
  251. package/dist/components/markdown.d.ts +0 -52
  252. package/dist/components/markdown.d.ts.map +0 -1
  253. package/dist/components/markdown.js +0 -341
  254. package/dist/components/markdown.js.map +0 -1
  255. package/dist/components/modal.d.ts +0 -237
  256. package/dist/components/modal.d.ts.map +0 -1
  257. package/dist/components/modal.js +0 -396
  258. package/dist/components/modal.js.map +0 -1
  259. package/dist/components/progress-bar.d.ts +0 -89
  260. package/dist/components/progress-bar.d.ts.map +0 -1
  261. package/dist/components/progress-bar.js +0 -288
  262. package/dist/components/progress-bar.js.map +0 -1
  263. package/dist/components/select.d.ts +0 -114
  264. package/dist/components/select.d.ts.map +0 -1
  265. package/dist/components/select.js +0 -415
  266. package/dist/components/select.js.map +0 -1
  267. package/dist/components/spinner.d.ts +0 -71
  268. package/dist/components/spinner.d.ts.map +0 -1
  269. package/dist/components/spinner.js +0 -300
  270. package/dist/components/spinner.js.map +0 -1
  271. package/dist/components/split-panel.d.ts +0 -175
  272. package/dist/components/split-panel.d.ts.map +0 -1
  273. package/dist/components/split-panel.js +0 -322
  274. package/dist/components/split-panel.js.map +0 -1
  275. package/dist/components/table.d.ts +0 -103
  276. package/dist/components/table.d.ts.map +0 -1
  277. package/dist/components/table.js +0 -359
  278. package/dist/components/table.js.map +0 -1
  279. package/dist/components/text-input.d.ts +0 -79
  280. package/dist/components/text-input.d.ts.map +0 -1
  281. package/dist/components/text-input.js +0 -332
  282. package/dist/components/text-input.js.map +0 -1
  283. package/dist/design-system/data-display/calendar.d.ts +0 -141
  284. package/dist/design-system/data-display/calendar.d.ts.map +0 -1
  285. package/dist/design-system/data-display/calendar.js +0 -524
  286. package/dist/design-system/data-display/calendar.js.map +0 -1
  287. package/dist/design-system/data-display/code-block.d.ts +0 -75
  288. package/dist/design-system/data-display/code-block.d.ts.map +0 -1
  289. package/dist/design-system/data-display/code-block.js +0 -311
  290. package/dist/design-system/data-display/code-block.js.map +0 -1
  291. package/dist/design-system/data-display/data-table.d.ts +0 -173
  292. package/dist/design-system/data-display/data-table.d.ts.map +0 -1
  293. package/dist/design-system/data-display/data-table.js +0 -428
  294. package/dist/design-system/data-display/data-table.js.map +0 -1
  295. package/dist/design-system/data-display/markdown.d.ts +0 -52
  296. package/dist/design-system/data-display/markdown.d.ts.map +0 -1
  297. package/dist/design-system/data-display/markdown.js +0 -341
  298. package/dist/design-system/data-display/markdown.js.map +0 -1
  299. package/dist/design-system/data-display/table.d.ts +0 -103
  300. package/dist/design-system/data-display/table.d.ts.map +0 -1
  301. package/dist/design-system/data-display/table.js +0 -342
  302. package/dist/design-system/data-display/table.js.map +0 -1
  303. package/dist/design-system/data-display/tree.d.ts +0 -166
  304. package/dist/design-system/data-display/tree.d.ts.map +0 -1
  305. package/dist/design-system/data-display/tree.js +0 -428
  306. package/dist/design-system/data-display/tree.js.map +0 -1
  307. package/dist/design-system/forms/autocomplete.d.ts +0 -163
  308. package/dist/design-system/forms/autocomplete.d.ts.map +0 -1
  309. package/dist/design-system/forms/autocomplete.js +0 -455
  310. package/dist/design-system/forms/autocomplete.js.map +0 -1
  311. package/dist/design-system/forms/button.d.ts +0 -106
  312. package/dist/design-system/forms/button.d.ts.map +0 -1
  313. package/dist/design-system/forms/button.js +0 -170
  314. package/dist/design-system/forms/button.js.map +0 -1
  315. package/dist/design-system/forms/multi-select.d.ts +0 -102
  316. package/dist/design-system/forms/multi-select.d.ts.map +0 -1
  317. package/dist/design-system/forms/multi-select.js +0 -309
  318. package/dist/design-system/forms/multi-select.js.map +0 -1
  319. package/dist/design-system/forms/radio-group.d.ts +0 -88
  320. package/dist/design-system/forms/radio-group.d.ts.map +0 -1
  321. package/dist/design-system/forms/radio-group.js +0 -145
  322. package/dist/design-system/forms/radio-group.js.map +0 -1
  323. package/dist/design-system/forms/select.d.ts +0 -116
  324. package/dist/design-system/forms/select.d.ts.map +0 -1
  325. package/dist/design-system/forms/select.js +0 -441
  326. package/dist/design-system/forms/select.js.map +0 -1
  327. package/dist/design-system/forms/slider.d.ts +0 -134
  328. package/dist/design-system/forms/slider.d.ts.map +0 -1
  329. package/dist/design-system/forms/slider.js +0 -314
  330. package/dist/design-system/forms/slider.js.map +0 -1
  331. package/dist/design-system/forms/switch.d.ts +0 -99
  332. package/dist/design-system/forms/switch.d.ts.map +0 -1
  333. package/dist/design-system/forms/switch.js +0 -173
  334. package/dist/design-system/forms/switch.js.map +0 -1
  335. package/dist/design-system/forms/text-input.d.ts +0 -79
  336. package/dist/design-system/forms/text-input.d.ts.map +0 -1
  337. package/dist/design-system/forms/text-input.js +0 -344
  338. package/dist/design-system/forms/text-input.js.map +0 -1
  339. package/dist/design-system/layout/collapsible.d.ts +0 -166
  340. package/dist/design-system/layout/collapsible.d.ts.map +0 -1
  341. package/dist/design-system/layout/collapsible.js +0 -286
  342. package/dist/design-system/layout/collapsible.js.map +0 -1
  343. package/dist/design-system/layout/scroll-area.d.ts +0 -188
  344. package/dist/design-system/layout/scroll-area.d.ts.map +0 -1
  345. package/dist/design-system/layout/scroll-area.js +0 -348
  346. package/dist/design-system/layout/scroll-area.js.map +0 -1
  347. package/dist/design-system/layout/split-panel.d.ts +0 -183
  348. package/dist/design-system/layout/split-panel.d.ts.map +0 -1
  349. package/dist/design-system/layout/split-panel.js +0 -323
  350. package/dist/design-system/layout/split-panel.js.map +0 -1
  351. package/dist/design-system/layout/tabs.d.ts +0 -129
  352. package/dist/design-system/layout/tabs.d.ts.map +0 -1
  353. package/dist/design-system/layout/tabs.js +0 -373
  354. package/dist/design-system/layout/tabs.js.map +0 -1
  355. package/dist/design-system/overlays/command-palette.d.ts +0 -217
  356. package/dist/design-system/overlays/command-palette.d.ts.map +0 -1
  357. package/dist/design-system/overlays/command-palette.js +0 -443
  358. package/dist/design-system/overlays/command-palette.js.map +0 -1
  359. package/dist/design-system/overlays/modal.d.ts +0 -251
  360. package/dist/design-system/overlays/modal.d.ts.map +0 -1
  361. package/dist/design-system/overlays/modal.js +0 -461
  362. package/dist/design-system/overlays/modal.js.map +0 -1
  363. package/dist/design-system/overlays/overlay-stack.d.ts +0 -200
  364. package/dist/design-system/overlays/overlay-stack.d.ts.map +0 -1
  365. package/dist/design-system/overlays/overlay-stack.js +0 -341
  366. package/dist/design-system/overlays/overlay-stack.js.map +0 -1
  367. package/dist/design-system/primitives/box.d.ts +0 -16
  368. package/dist/design-system/primitives/box.d.ts.map +0 -1
  369. package/dist/design-system/primitives/box.js +0 -23
  370. package/dist/design-system/primitives/box.js.map +0 -1
  371. package/dist/design-system/primitives/divider.d.ts +0 -52
  372. package/dist/design-system/primitives/divider.d.ts.map +0 -1
  373. package/dist/design-system/primitives/divider.js +0 -72
  374. package/dist/design-system/primitives/divider.js.map +0 -1
  375. package/dist/design-system/primitives/helpers.d.ts +0 -10
  376. package/dist/design-system/primitives/helpers.d.ts.map +0 -1
  377. package/dist/design-system/primitives/helpers.js +0 -27
  378. package/dist/design-system/primitives/helpers.js.map +0 -1
  379. package/dist/design-system/primitives/index.d.ts +0 -11
  380. package/dist/design-system/primitives/index.d.ts.map +0 -1
  381. package/dist/design-system/primitives/index.js +0 -14
  382. package/dist/design-system/primitives/index.js.map +0 -1
  383. package/dist/design-system/primitives/slot.d.ts +0 -35
  384. package/dist/design-system/primitives/slot.d.ts.map +0 -1
  385. package/dist/design-system/primitives/slot.js +0 -17
  386. package/dist/design-system/primitives/slot.js.map +0 -1
  387. package/dist/design-system/primitives/spacer.d.ts +0 -34
  388. package/dist/design-system/primitives/spacer.d.ts.map +0 -1
  389. package/dist/design-system/primitives/spacer.js +0 -53
  390. package/dist/design-system/primitives/spacer.js.map +0 -1
  391. package/dist/design-system/primitives/text.d.ts +0 -12
  392. package/dist/design-system/primitives/text.d.ts.map +0 -1
  393. package/dist/design-system/primitives/text.js +0 -25
  394. package/dist/design-system/primitives/text.js.map +0 -1
  395. package/dist/design-system/primitives/utilities.d.ts +0 -70
  396. package/dist/design-system/primitives/utilities.d.ts.map +0 -1
  397. package/dist/design-system/primitives/utilities.js +0 -56
  398. package/dist/design-system/primitives/utilities.js.map +0 -1
  399. package/dist/storybook/cli.d.ts +0 -10
  400. package/dist/storybook/cli.d.ts.map +0 -1
  401. package/dist/storybook/cli.js +0 -14
  402. package/dist/storybook/cli.js.map +0 -1
@@ -9,11 +9,14 @@
9
9
  * - Toast: Notification popups
10
10
  * - Tabs: Tab navigation
11
11
  * - Sparkline & Gauge: Simple data visualizations
12
+ * - Advanced Charts: LineChart, ScatterPlot, RadarChart, GanttChart, TimeHeatmap, Legend
12
13
  */
13
- import { Box, Text, When, Each, Fragment, Spacer } from '../../../primitives/nodes.js';
14
+ import { Box, Text, When, Each, Fragment, Spacer, Newline } from '../../../primitives/nodes.js';
14
15
  import { Divider } from '../../../primitives/divider.js';
15
16
  import { TextInput, Checkbox, Select, RadioGroup } from '../../../design-system/forms/index.js';
17
+ import { LineChart, ScatterPlot, RadarChart, GanttChart, TimeHeatmap, Legend, } from '../../../molecules/data-viz/index.js';
16
18
  import { story, defaultControls } from '../../core/registry.js';
19
+ import { getContrastColor } from '../../../core/theme.js';
17
20
  // Chart helpers
18
21
  const sparklineChars = ['▁', '▂', '▃', '▄', '▅', '▆', '▇', '█'];
19
22
  function textSparkline(data) {
@@ -325,13 +328,17 @@ export const alertStories = [
325
328
  story('Alert - Success')
326
329
  .category('Molecules')
327
330
  .description('Success alert')
328
- .render(() => Box({
329
- borderStyle: 'round',
330
- borderColor: 'green',
331
- backgroundColor: 'green',
332
- padding: 1,
333
- width: 50,
334
- }, Text({ color: 'white', bold: true }, '✓ Operation completed successfully!'))),
331
+ .render(() => {
332
+ const bg = 'green';
333
+ const fg = getContrastColor(bg);
334
+ return Box({
335
+ borderStyle: 'round',
336
+ borderColor: bg,
337
+ backgroundColor: bg,
338
+ padding: 1,
339
+ width: 50,
340
+ }, Text({ color: fg, backgroundColor: bg, bold: true }, '✓ Operation completed successfully!'));
341
+ }),
335
342
  story('Alert - Warning')
336
343
  .category('Molecules')
337
344
  .description('Warning alert')
@@ -405,18 +412,30 @@ export const tabsStories = [
405
412
  })
406
413
  .render((props) => {
407
414
  const tabs = ['Overview', 'Details', 'Settings'];
408
- return Box({ width: 50, flexDirection: 'column' }, Box({ flexDirection: 'row', borderStyle: 'single', borderColor: 'gray' }, ...tabs.map((tab, idx) => Box({
409
- paddingX: 2,
410
- backgroundColor: idx === props.activeTab ? 'blue' : undefined,
411
- }, Text({
412
- color: idx === props.activeTab ? 'white' : 'gray',
413
- bold: idx === props.activeTab,
414
- }, tab)))), Box({ borderStyle: 'single', borderColor: 'blue', padding: 1, height: 5 }, Text({}, `${tabs[props.activeTab]} content here...`)));
415
+ const activeBg = 'blue';
416
+ const activeFg = getContrastColor(activeBg);
417
+ return Box({ width: 50, flexDirection: 'column' }, Box({ flexDirection: 'row', borderStyle: 'single', borderColor: 'gray' }, ...tabs.map((tab, idx) => {
418
+ const isActive = idx === props.activeTab;
419
+ const bg = isActive ? activeBg : undefined;
420
+ const fg = isActive ? activeFg : 'gray';
421
+ return Box({
422
+ paddingX: 2,
423
+ backgroundColor: bg,
424
+ }, Text({
425
+ color: fg,
426
+ backgroundColor: bg,
427
+ bold: isActive,
428
+ }, tab));
429
+ })), Box({ borderStyle: 'single', borderColor: 'blue', padding: 1, height: 5 }, Text({}, `${tabs[props.activeTab]} content here...`)));
415
430
  }),
416
431
  story('Tabs - With Icons')
417
432
  .category('Molecules')
418
433
  .description('Tabs with icons')
419
- .render(() => Box({ width: 50, flexDirection: 'column' }, Box({ flexDirection: 'row', borderStyle: 'single', borderColor: 'gray' }, Box({ paddingX: 2, backgroundColor: 'blue' }, Text({ color: 'white', bold: true }, '🏠 Home')), Box({ paddingX: 2 }, Text({ color: 'gray' }, '📁 Files')), Box({ paddingX: 2 }, Text({ color: 'gray' }, '⚙️ Settings'))), Box({ borderStyle: 'single', borderColor: 'blue', padding: 1, height: 5 }, Text({}, 'Home content')))),
434
+ .render(() => {
435
+ const activeBg = 'blue';
436
+ const activeFg = getContrastColor(activeBg);
437
+ return Box({ width: 50, flexDirection: 'column' }, Box({ flexDirection: 'row', borderStyle: 'single', borderColor: 'gray' }, Box({ paddingX: 2, backgroundColor: activeBg }, Text({ color: activeFg, backgroundColor: activeBg, bold: true }, '🏠 Home')), Box({ paddingX: 2 }, Text({ color: 'gray' }, '📁 Files')), Box({ paddingX: 2 }, Text({ color: 'gray' }, '⚙️ Settings'))), Box({ borderStyle: 'single', borderColor: 'blue', padding: 1, height: 5 }, Text({}, 'Home content')));
438
+ }),
420
439
  story('Tabs - Styled')
421
440
  .category('Molecules')
422
441
  .description('Tabs with custom styling')
@@ -503,7 +522,11 @@ export const mouseStories = [
503
522
  story('Mouse - Position Tracker')
504
523
  .category('Molecules')
505
524
  .description('Real-time mouse position tracking')
506
- .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'double', borderColor: 'magenta' }, Text({ bold: true, color: 'magenta' }, '📍 Mouse Position Tracker'), Divider({}), Box({ flexDirection: 'row', gap: 4 }, Box({ flexDirection: 'column' }, Text({ color: 'gray' }, 'X Position'), Text({ color: 'cyan', bold: true }, ' 24 ')), Box({ flexDirection: 'column' }, Text({ color: 'gray' }, 'Y Position'), Text({ color: 'cyan', bold: true }, ' 12 '))), Spacer({ size: 1 }), Box({ flexDirection: 'column', backgroundColor: 'gray' }, Text({ color: 'white' }, ' '), Text({ color: 'white' }, ' Move mouse here... '), Text({ color: 'white' }, ' ● '), Text({ color: 'white' }, ' ')), Text({ color: 'gray', dim: true }, "action === 'move' for tracking"))),
525
+ .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'double', borderColor: 'magenta' }, Text({ bold: true, color: 'magenta' }, '📍 Mouse Position Tracker'), Divider({}), Box({ flexDirection: 'row', gap: 4 }, Box({ flexDirection: 'column' }, Text({ color: 'gray' }, 'X Position'), Text({ color: 'cyan', bold: true }, ' 24 ')), Box({ flexDirection: 'column' }, Text({ color: 'gray' }, 'Y Position'), Text({ color: 'cyan', bold: true }, ' 12 '))), Spacer({ size: 1 }), (() => {
526
+ const bg = 'gray';
527
+ const fg = getContrastColor(bg);
528
+ return Box({ flexDirection: 'column', backgroundColor: bg }, Text({ color: fg, backgroundColor: bg }, ' '), Text({ color: fg, backgroundColor: bg }, ' Move mouse here... '), Text({ color: fg, backgroundColor: bg }, ' ● '), Text({ color: fg, backgroundColor: bg }, ' '));
529
+ })(), Text({ color: 'gray', dim: true }, "action === 'move' for tracking"))),
507
530
  story('Mouse - Double Click')
508
531
  .category('Molecules')
509
532
  .description('Detect double-click events')
@@ -523,7 +546,11 @@ export const mouseStories = [
523
546
  story('Mouse - Click Hitbox')
524
547
  .category('Molecules')
525
548
  .description('Detect clicks on specific regions')
526
- .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '🎯 Hitbox Detection'), Divider({}), Box({ flexDirection: 'row', gap: 1 }, Box({ padding: 1, borderStyle: 'round', borderColor: 'green', backgroundColor: 'green' }, Text({ color: 'white', bold: true }, ' Button 1 ')), Box({ padding: 1, borderStyle: 'round', borderColor: 'blue' }, Text({ color: 'blue' }, ' Button 2 ')), Box({ padding: 1, borderStyle: 'round', borderColor: 'red' }, Text({ color: 'red' }, ' Button 3 '))), Spacer({ size: 1 }), Text({}, 'Clicked: Button 1'), Text({ color: 'gray', dim: true }, 'Check x,y against element bounds'))),
549
+ .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '🎯 Hitbox Detection'), Divider({}), Box({ flexDirection: 'row', gap: 1 }, (() => {
550
+ const bg = 'green';
551
+ const fg = getContrastColor(bg);
552
+ return Box({ padding: 1, borderStyle: 'round', borderColor: bg, backgroundColor: bg }, Text({ color: fg, backgroundColor: bg, bold: true }, ' Button 1 '));
553
+ })(), Box({ padding: 1, borderStyle: 'round', borderColor: 'blue' }, Text({ color: 'blue' }, ' Button 2 ')), Box({ padding: 1, borderStyle: 'round', borderColor: 'red' }, Text({ color: 'red' }, ' Button 3 '))), Spacer({ size: 1 }), Text({}, 'Clicked: Button 1'), Text({ color: 'gray', dim: true }, 'Check x,y against element bounds'))),
527
554
  story('Mouse - Interactive Canvas')
528
555
  .category('Molecules')
529
556
  .description('Draw with mouse clicks')
@@ -552,11 +579,19 @@ export const mouseStories = [
552
579
  story('Mouse - Hover State')
553
580
  .category('Molecules')
554
581
  .description('Track hover state over elements')
555
- .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '👆 Hover Detection'), Divider({}), Box({ flexDirection: 'row', gap: 2 }, Box({ padding: 1, borderStyle: 'round', borderColor: 'cyan', backgroundColor: 'blue' }, Text({ color: 'white', bold: true }, ' Hovered! ')), Box({ padding: 1, borderStyle: 'round', borderColor: 'gray' }, Text({ color: 'gray' }, ' Normal ')), Box({ padding: 1, borderStyle: 'round', borderColor: 'gray' }, Text({ color: 'gray' }, ' Normal '))), Spacer({ size: 1 }), Text({ color: 'gray' }, 'Hovering: Item 1'), Text({ color: 'gray', dim: true }, "Track mouse position for hover effects"))),
582
+ .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '👆 Hover Detection'), Divider({}), Box({ flexDirection: 'row', gap: 2 }, (() => {
583
+ const bg = 'blue';
584
+ const fg = getContrastColor(bg);
585
+ return Box({ padding: 1, borderStyle: 'round', borderColor: 'cyan', backgroundColor: bg }, Text({ color: fg, backgroundColor: bg, bold: true }, ' Hovered! '));
586
+ })(), Box({ padding: 1, borderStyle: 'round', borderColor: 'gray' }, Text({ color: 'gray' }, ' Normal ')), Box({ padding: 1, borderStyle: 'round', borderColor: 'gray' }, Text({ color: 'gray' }, ' Normal '))), Spacer({ size: 1 }), Text({ color: 'gray' }, 'Hovering: Item 1'), Text({ color: 'gray', dim: true }, "Track mouse position for hover effects"))),
556
587
  story('Mouse - Context Menu')
557
588
  .category('Molecules')
558
589
  .description('Right-click context menu trigger')
559
- .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '📜 Context Menu'), Divider({}), Box({ flexDirection: 'row', gap: 0 }, Box({ flexDirection: 'column', width: 20 }, Text({}, ' 📄 Document.txt'), Text({}, ' 📁 Folder'), Text({ backgroundColor: 'blue', color: 'white' }, ' 📄 Selected.md ')), Box({ flexDirection: 'column', borderStyle: 'single', borderColor: 'cyan', padding: 1 }, Text({ color: 'cyan' }, ' Open '), Text({}, ' Edit '), Text({}, ' Copy '), Text({ color: 'gray' }, ' ────────── '), Text({ color: 'red' }, ' Delete '))), Text({ color: 'gray', dim: true }, "if (event.button === 'right') showMenu()"))),
590
+ .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '📜 Context Menu'), Divider({}), Box({ flexDirection: 'row', gap: 0 }, (() => {
591
+ const selBg = 'blue';
592
+ const selFg = getContrastColor(selBg);
593
+ return Box({ flexDirection: 'column', width: 20 }, Text({}, ' 📄 Document.txt'), Text({}, ' 📁 Folder'), Text({ backgroundColor: selBg, color: selFg }, ' 📄 Selected.md '));
594
+ })(), Box({ flexDirection: 'column', borderStyle: 'single', borderColor: 'cyan', padding: 1 }, Text({ color: 'cyan' }, ' Open '), Text({}, ' Edit '), Text({}, ' Copy '), Text({ color: 'gray' }, ' ────────── '), Text({ color: 'red' }, ' Delete '))), Text({ color: 'gray', dim: true }, "if (event.button === 'right') showMenu()"))),
560
595
  story('Mouse - Drag & Drop')
561
596
  .category('Molecules')
562
597
  .description('Visual drag and drop interface')
@@ -566,6 +601,347 @@ export const mouseStories = [
566
601
  .description('Drag to create selection rectangle')
567
602
  .render(() => Box({ flexDirection: 'column', gap: 1, padding: 1, borderStyle: 'single' }, Text({ bold: true }, '⬜ Selection Box'), Divider({}), Box({ flexDirection: 'column' }, Text({ color: 'gray' }, '┌──────────────────────────────┐'), Text({ color: 'gray' }, '│ ○ ● ○ ○ │'), Text({ color: 'gray' }, '│ ┏━━━━━━━━━━━┓ │'), Text({ color: 'gray' }, '│ ○ ┃ ● ● ┃ ○ │'), Text({ color: 'gray' }, '│ ┃ ● ┃ │'), Text({ color: 'gray' }, '│ ┗━━━━━━━━━━━┛ ○ │'), Text({ color: 'gray' }, '│ ○ ○ │'), Text({ color: 'gray' }, '└──────────────────────────────┘')), Text({ color: 'cyan' }, 'Selected: 4 items'), Text({ color: 'gray', dim: true }, 'Track start & end drag positions'))),
568
603
  ];
604
+ /**
605
+ * LineChart stories - Multi-series with color coding
606
+ */
607
+ export const lineChartStories = [
608
+ story('LineChart - Single Series')
609
+ .category('Molecules')
610
+ .description('Single data series line chart')
611
+ .render(() => LineChart({
612
+ series: [
613
+ { name: 'Usage', data: [10, 25, 30, 45, 60, 55, 70], color: 'cyan' },
614
+ ],
615
+ width: 50,
616
+ height: 8,
617
+ title: 'System Usage Over Time',
618
+ showLegend: true,
619
+ })),
620
+ story('LineChart - Multi-Series Colors')
621
+ .category('Molecules')
622
+ .description('Multiple series with automatic color assignment')
623
+ .render(() => LineChart({
624
+ series: [
625
+ { name: 'Frontend', data: [10, 25, 30, 45, 60, 55, 70] },
626
+ { name: 'Backend', data: [15, 20, 35, 40, 55, 65, 75] },
627
+ { name: 'Database', data: [5, 15, 25, 35, 45, 50, 60] },
628
+ ],
629
+ width: 50,
630
+ height: 10,
631
+ title: 'Performance Metrics',
632
+ showLegend: true,
633
+ })),
634
+ story('LineChart - Custom Colors')
635
+ .category('Molecules')
636
+ .description('Line chart with custom series colors')
637
+ .controls({
638
+ color1: defaultControls.color('Series 1 Color', 'green'),
639
+ color2: defaultControls.color('Series 2 Color', 'yellow'),
640
+ })
641
+ .render((props) => LineChart({
642
+ series: [
643
+ { name: 'Profit', data: [50, 65, 75, 70, 85, 90, 95], color: props.color1 },
644
+ { name: 'Costs', data: [30, 35, 40, 45, 40, 38, 35], color: props.color2 },
645
+ ],
646
+ width: 50,
647
+ height: 8,
648
+ title: 'Revenue Analysis',
649
+ showLegend: true,
650
+ })),
651
+ ];
652
+ /**
653
+ * ScatterPlot stories - 2D correlation analysis
654
+ */
655
+ export const scatterPlotStories = [
656
+ story('ScatterPlot - Basic Correlation')
657
+ .category('Molecules')
658
+ .description('2D scatter plot for correlation analysis')
659
+ .render(() => ScatterPlot({
660
+ points: [
661
+ { x: 1, y: 2 },
662
+ { x: 2, y: 4 },
663
+ { x: 3, y: 6 },
664
+ { x: 4, y: 8 },
665
+ { x: 5, y: 10 },
666
+ { x: 6, y: 12 },
667
+ ],
668
+ width: 40,
669
+ height: 10,
670
+ title: 'X vs Y Correlation',
671
+ markerStyle: 'circle',
672
+ })),
673
+ story('ScatterPlot - Multiple Markers')
674
+ .category('Molecules')
675
+ .description('Scatter plot with different marker styles')
676
+ .controls({
677
+ markerStyle: defaultControls.select('Marker Style', ['circle', 'square', 'diamond', 'plus', 'star', 'cross']),
678
+ })
679
+ .render((props) => ScatterPlot({
680
+ points: [
681
+ { x: 1, y: 3 },
682
+ { x: 2, y: 5 },
683
+ { x: 3, y: 4 },
684
+ { x: 4, y: 7 },
685
+ { x: 5, y: 6 },
686
+ { x: 6, y: 9 },
687
+ { x: 7, y: 8 },
688
+ ],
689
+ width: 40,
690
+ height: 10,
691
+ title: 'Data Distribution',
692
+ markerStyle: props.markerStyle,
693
+ })),
694
+ story('ScatterPlot - Scatter with Color')
695
+ .category('Molecules')
696
+ .description('Scatter plot with color highlighting')
697
+ .render(() => ScatterPlot({
698
+ points: Array.from({ length: 15 }, () => ({
699
+ x: Math.floor(Math.random() * 10) + 1,
700
+ y: Math.floor(Math.random() * 10) + 1,
701
+ })),
702
+ width: 40,
703
+ height: 10,
704
+ title: 'Random Distribution',
705
+ markerStyle: 'circle',
706
+ color: 'green',
707
+ })),
708
+ ];
709
+ /**
710
+ * RadarChart stories - Multi-dimensional comparison
711
+ */
712
+ export const radarChartStories = [
713
+ story('RadarChart - Product Comparison')
714
+ .category('Molecules')
715
+ .description('Compare multiple products across dimensions')
716
+ .render(() => RadarChart({
717
+ axes: [
718
+ { name: 'Speed', max: 100 },
719
+ { name: 'Power', max: 100 },
720
+ { name: 'Efficiency', max: 100 },
721
+ { name: 'Durability', max: 100 },
722
+ { name: 'Cost', max: 100 },
723
+ ],
724
+ series: [
725
+ { name: 'Model A', values: [80, 75, 70, 85, 60], color: 'cyan' },
726
+ { name: 'Model B', values: [70, 85, 80, 75, 80], color: 'green' },
727
+ ],
728
+ showLegend: true,
729
+ })),
730
+ story('RadarChart - Skills Assessment')
731
+ .category('Molecules')
732
+ .description('Compare skill levels across multiple domains')
733
+ .render(() => RadarChart({
734
+ axes: [
735
+ { name: 'Frontend', max: 100 },
736
+ { name: 'Backend', max: 100 },
737
+ { name: 'DevOps', max: 100 },
738
+ { name: 'Security', max: 100 },
739
+ { name: 'Testing', max: 100 },
740
+ { name: 'Documentation', max: 100 },
741
+ ],
742
+ series: [
743
+ { name: 'Developer 1', values: [85, 75, 65, 70, 80, 75], color: 'yellow' },
744
+ { name: 'Developer 2', values: [70, 85, 80, 75, 70, 80], color: 'magenta' },
745
+ ],
746
+ showLegend: true,
747
+ })),
748
+ ];
749
+ /**
750
+ * GanttChart stories - Project timeline
751
+ */
752
+ export const ganttChartStories = [
753
+ story('GanttChart - Project Timeline')
754
+ .category('Molecules')
755
+ .description('Project timeline with task dependencies')
756
+ .render(() => GanttChart({
757
+ tasks: [
758
+ {
759
+ id: '1',
760
+ name: 'Design',
761
+ startDate: '2024-01-01',
762
+ endDate: '2024-01-15',
763
+ progress: 100,
764
+ status: 'complete',
765
+ },
766
+ {
767
+ id: '2',
768
+ name: 'Development',
769
+ startDate: '2024-01-15',
770
+ endDate: '2024-02-15',
771
+ progress: 65,
772
+ status: 'in-progress',
773
+ },
774
+ {
775
+ id: '3',
776
+ name: 'Testing',
777
+ startDate: '2024-02-01',
778
+ endDate: '2024-02-20',
779
+ progress: 30,
780
+ status: 'in-progress',
781
+ dependsOn: '2',
782
+ },
783
+ {
784
+ id: '4',
785
+ name: 'Deployment',
786
+ startDate: '2024-02-20',
787
+ endDate: '2024-02-25',
788
+ progress: 0,
789
+ status: 'pending',
790
+ dependsOn: '3',
791
+ },
792
+ ],
793
+ width: 60,
794
+ title: 'Project Timeline Q1 2024',
795
+ showLegend: true,
796
+ })),
797
+ story('GanttChart - Sprint Planning')
798
+ .category('Molecules')
799
+ .description('Sprint timeline with multiple tasks')
800
+ .render(() => GanttChart({
801
+ tasks: [
802
+ {
803
+ id: '1',
804
+ name: 'Epic Planning',
805
+ startDate: '2024-01-01',
806
+ endDate: '2024-01-03',
807
+ progress: 100,
808
+ status: 'complete',
809
+ },
810
+ {
811
+ id: '2',
812
+ name: 'Feature A',
813
+ startDate: '2024-01-03',
814
+ endDate: '2024-01-07',
815
+ progress: 100,
816
+ status: 'complete',
817
+ },
818
+ {
819
+ id: '3',
820
+ name: 'Feature B',
821
+ startDate: '2024-01-05',
822
+ endDate: '2024-01-10',
823
+ progress: 75,
824
+ status: 'in-progress',
825
+ },
826
+ {
827
+ id: '4',
828
+ name: 'QA Review',
829
+ startDate: '2024-01-07',
830
+ endDate: '2024-01-12',
831
+ progress: 50,
832
+ status: 'in-progress',
833
+ },
834
+ {
835
+ id: '5',
836
+ name: 'Release',
837
+ startDate: '2024-01-12',
838
+ endDate: '2024-01-15',
839
+ progress: 0,
840
+ status: 'pending',
841
+ },
842
+ ],
843
+ width: 60,
844
+ title: 'Sprint 2024-01',
845
+ showLegend: true,
846
+ })),
847
+ ];
848
+ /**
849
+ * TimeHeatmap stories - Activity calendar
850
+ */
851
+ export const timeHeatmapStories = [
852
+ story('TimeHeatmap - Daily Activity')
853
+ .category('Molecules')
854
+ .description('Daily activity heatmap')
855
+ .render(() => TimeHeatmap({
856
+ data: [
857
+ { date: '2024-12-01', value: 5 },
858
+ { date: '2024-12-02', value: 10 },
859
+ { date: '2024-12-03', value: 8 },
860
+ { date: '2024-12-04', value: 15 },
861
+ { date: '2024-12-05', value: 12 },
862
+ { date: '2024-12-06', value: 20 },
863
+ { date: '2024-12-07', value: 18 },
864
+ { date: '2024-12-08', value: 5 },
865
+ { date: '2024-12-09', value: 10 },
866
+ { date: '2024-12-10', value: 25 },
867
+ { date: '2024-12-11', value: 30 },
868
+ { date: '2024-12-12', value: 22 },
869
+ ],
870
+ granularity: 'day',
871
+ colorScale: 'greens',
872
+ title: 'Daily Activity Heatmap',
873
+ showLegend: true,
874
+ })),
875
+ story('TimeHeatmap - Color Scales')
876
+ .category('Molecules')
877
+ .description('Heatmap with different color scales')
878
+ .controls({
879
+ colorScale: defaultControls.select('Color Scale', ['greens', 'blues', 'reds', 'heat']),
880
+ })
881
+ .render((props) => TimeHeatmap({
882
+ data: [
883
+ { date: '2024-12-01', value: 5 },
884
+ { date: '2024-12-02', value: 15 },
885
+ { date: '2024-12-03', value: 8 },
886
+ { date: '2024-12-04', value: 25 },
887
+ { date: '2024-12-05', value: 12 },
888
+ { date: '2024-12-06', value: 30 },
889
+ { date: '2024-12-07', value: 18 },
890
+ { date: '2024-12-08', value: 10 },
891
+ { date: '2024-12-09', value: 20 },
892
+ { date: '2024-12-10', value: 28 },
893
+ { date: '2024-12-11', value: 22 },
894
+ { date: '2024-12-12', value: 15 },
895
+ ],
896
+ granularity: 'day',
897
+ colorScale: props.colorScale,
898
+ title: 'Activity Distribution',
899
+ showLegend: true,
900
+ })),
901
+ ];
902
+ /**
903
+ * Legend stories - Reusable legend component
904
+ */
905
+ export const legendStories = [
906
+ story('Legend - Horizontal Bottom')
907
+ .category('Molecules')
908
+ .description('Legend positioned at bottom')
909
+ .render(() => Box({ flexDirection: 'column', gap: 1 }, Box({ flexDirection: 'row', height: 5, borderStyle: 'single', borderColor: 'gray', padding: 1 }, Text({ color: 'gray' }, 'Chart Area')), Legend({
910
+ items: [
911
+ { label: 'Series 1', color: 'cyan' },
912
+ { label: 'Series 2', color: 'green' },
913
+ { label: 'Series 3', color: 'yellow' },
914
+ ],
915
+ position: 'bottom',
916
+ showSymbols: true,
917
+ }))),
918
+ story('Legend - Priority Levels')
919
+ .category('Molecules')
920
+ .description('Legend for priority classification')
921
+ .render(() => Box({ flexDirection: 'column', gap: 2, padding: 1 }, Text({ bold: true, color: 'cyan' }, 'Task Priority Levels'), Newline(), Legend({
922
+ items: [
923
+ { label: 'Critical', color: 'red' },
924
+ { label: 'High', color: 'yellow' },
925
+ { label: 'Medium', color: 'blue' },
926
+ { label: 'Low', color: 'green' },
927
+ ],
928
+ position: 'bottom',
929
+ showSymbols: true,
930
+ }))),
931
+ story('Legend - Status Indicators')
932
+ .category('Molecules')
933
+ .description('Legend for status tracking')
934
+ .render(() => Box({ flexDirection: 'column', gap: 2, padding: 1 }, Text({ bold: true, color: 'magenta' }, 'Build Status Legend'), Newline(), Legend({
935
+ items: [
936
+ { label: 'Passing', color: 'green' },
937
+ { label: 'Failing', color: 'red' },
938
+ { label: 'Pending', color: 'yellow' },
939
+ { label: 'Skipped', color: 'gray' },
940
+ ],
941
+ position: 'bottom',
942
+ showSymbols: true,
943
+ }))),
944
+ ];
569
945
  /**
570
946
  * All molecule stories
571
947
  */
@@ -581,6 +957,12 @@ export const allMoleculeStories = [
581
957
  ...tabsStories,
582
958
  ...sparklineStories,
583
959
  ...gaugeStories,
960
+ ...lineChartStories,
961
+ ...scatterPlotStories,
962
+ ...radarChartStories,
963
+ ...ganttChartStories,
964
+ ...timeHeatmapStories,
965
+ ...legendStories,
584
966
  ...mouseStories,
585
967
  ];
586
968
  export default allMoleculeStories;