@mohou/ui 1.0.20

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 (604) hide show
  1. package/README.md +10 -0
  2. package/lib/types/blocks/activity-feed.d.ts +12 -0
  3. package/lib/types/blocks/activity-feed.d.ts.map +1 -0
  4. package/lib/types/blocks/app-shell.d.ts +17 -0
  5. package/lib/types/blocks/app-shell.d.ts.map +1 -0
  6. package/lib/types/blocks/attachment-gallery.d.ts +15 -0
  7. package/lib/types/blocks/attachment-gallery.d.ts.map +1 -0
  8. package/lib/types/blocks/bar-chart.d.ts +19 -0
  9. package/lib/types/blocks/bar-chart.d.ts.map +1 -0
  10. package/lib/types/blocks/comment-thread.d.ts +17 -0
  11. package/lib/types/blocks/comment-thread.d.ts.map +1 -0
  12. package/lib/types/blocks/dashboard-shell.d.ts +35 -0
  13. package/lib/types/blocks/dashboard-shell.d.ts.map +1 -0
  14. package/lib/types/blocks/description-list.d.ts +14 -0
  15. package/lib/types/blocks/description-list.d.ts.map +1 -0
  16. package/lib/types/blocks/detail-panel.d.ts +16 -0
  17. package/lib/types/blocks/detail-panel.d.ts.map +1 -0
  18. package/lib/types/blocks/donut-chart.d.ts +21 -0
  19. package/lib/types/blocks/donut-chart.d.ts.map +1 -0
  20. package/lib/types/blocks/env-badge.d.ts +11 -0
  21. package/lib/types/blocks/env-badge.d.ts.map +1 -0
  22. package/lib/types/blocks/env-table.d.ts +29 -0
  23. package/lib/types/blocks/env-table.d.ts.map +1 -0
  24. package/lib/types/blocks/file-tree.d.ts +12 -0
  25. package/lib/types/blocks/file-tree.d.ts.map +1 -0
  26. package/lib/types/blocks/filter-bar.d.ts +15 -0
  27. package/lib/types/blocks/filter-bar.d.ts.map +1 -0
  28. package/lib/types/blocks/form-sheet.d.ts +47 -0
  29. package/lib/types/blocks/form-sheet.d.ts.map +1 -0
  30. package/lib/types/blocks/gauge.d.ts +14 -0
  31. package/lib/types/blocks/gauge.d.ts.map +1 -0
  32. package/lib/types/blocks/list-detail.d.ts +42 -0
  33. package/lib/types/blocks/list-detail.d.ts.map +1 -0
  34. package/lib/types/blocks/notification-center.d.ts +16 -0
  35. package/lib/types/blocks/notification-center.d.ts.map +1 -0
  36. package/lib/types/blocks/page-header.d.ts +15 -0
  37. package/lib/types/blocks/page-header.d.ts.map +1 -0
  38. package/lib/types/blocks/progress-ring.d.ts +13 -0
  39. package/lib/types/blocks/progress-ring.d.ts.map +1 -0
  40. package/lib/types/blocks/radar-chart.d.ts +19 -0
  41. package/lib/types/blocks/radar-chart.d.ts.map +1 -0
  42. package/lib/types/blocks/request-inspector.d.ts +14 -0
  43. package/lib/types/blocks/request-inspector.d.ts.map +1 -0
  44. package/lib/types/blocks/reveal.d.ts +30 -0
  45. package/lib/types/blocks/reveal.d.ts.map +1 -0
  46. package/lib/types/blocks/run-timeline.d.ts +12 -0
  47. package/lib/types/blocks/run-timeline.d.ts.map +1 -0
  48. package/lib/types/blocks/scrollspy.d.ts +15 -0
  49. package/lib/types/blocks/scrollspy.d.ts.map +1 -0
  50. package/lib/types/blocks/settings-split.d.ts +47 -0
  51. package/lib/types/blocks/settings-split.d.ts.map +1 -0
  52. package/lib/types/blocks/severity-chip.d.ts +23 -0
  53. package/lib/types/blocks/severity-chip.d.ts.map +1 -0
  54. package/lib/types/blocks/sparkline.d.ts +14 -0
  55. package/lib/types/blocks/sparkline.d.ts.map +1 -0
  56. package/lib/types/blocks/stat-card.d.ts +17 -0
  57. package/lib/types/blocks/stat-card.d.ts.map +1 -0
  58. package/lib/types/blocks/status-badge.d.ts +21 -0
  59. package/lib/types/blocks/status-badge.d.ts.map +1 -0
  60. package/lib/types/blocks/table-page.d.ts +35 -0
  61. package/lib/types/blocks/table-page.d.ts.map +1 -0
  62. package/lib/types/blocks/terminal.d.ts +12 -0
  63. package/lib/types/blocks/terminal.d.ts.map +1 -0
  64. package/lib/types/blocks/test-step-list.d.ts +17 -0
  65. package/lib/types/blocks/test-step-list.d.ts.map +1 -0
  66. package/lib/types/blocks/trend-card.d.ts +20 -0
  67. package/lib/types/blocks/trend-card.d.ts.map +1 -0
  68. package/lib/types/blocks/wizard-shell.d.ts +47 -0
  69. package/lib/types/blocks/wizard-shell.d.ts.map +1 -0
  70. package/lib/types/components/accordion.d.ts +14 -0
  71. package/lib/types/components/accordion.d.ts.map +1 -0
  72. package/lib/types/components/alert-dialog.d.ts +26 -0
  73. package/lib/types/components/alert-dialog.d.ts.map +1 -0
  74. package/lib/types/components/alert.d.ts +18 -0
  75. package/lib/types/components/alert.d.ts.map +1 -0
  76. package/lib/types/components/aspect-ratio.d.ts +9 -0
  77. package/lib/types/components/aspect-ratio.d.ts.map +1 -0
  78. package/lib/types/components/attachment.d.ts +28 -0
  79. package/lib/types/components/attachment.d.ts.map +1 -0
  80. package/lib/types/components/avatar.d.ts +16 -0
  81. package/lib/types/components/avatar.d.ts.map +1 -0
  82. package/lib/types/components/badge.d.ts +15 -0
  83. package/lib/types/components/badge.d.ts.map +1 -0
  84. package/lib/types/components/breadcrumb.d.ts +15 -0
  85. package/lib/types/components/breadcrumb.d.ts.map +1 -0
  86. package/lib/types/components/bubble.d.ts +21 -0
  87. package/lib/types/components/bubble.d.ts.map +1 -0
  88. package/lib/types/components/button-group.d.ts +17 -0
  89. package/lib/types/components/button-group.d.ts.map +1 -0
  90. package/lib/types/components/button.d.ts +16 -0
  91. package/lib/types/components/button.d.ts.map +1 -0
  92. package/lib/types/components/calendar.d.ts +15 -0
  93. package/lib/types/components/calendar.d.ts.map +1 -0
  94. package/lib/types/components/card.d.ts +19 -0
  95. package/lib/types/components/card.d.ts.map +1 -0
  96. package/lib/types/components/chart.d.ts +52 -0
  97. package/lib/types/components/chart.d.ts.map +1 -0
  98. package/lib/types/components/checkbox.d.ts +9 -0
  99. package/lib/types/components/checkbox.d.ts.map +1 -0
  100. package/lib/types/components/collapsible.d.ts +10 -0
  101. package/lib/types/components/collapsible.d.ts.map +1 -0
  102. package/lib/types/components/combobox.d.ts +29 -0
  103. package/lib/types/components/combobox.d.ts.map +1 -0
  104. package/lib/types/components/command.d.ts +26 -0
  105. package/lib/types/components/command.d.ts.map +1 -0
  106. package/lib/types/components/context-menu.d.ts +34 -0
  107. package/lib/types/components/context-menu.d.ts.map +1 -0
  108. package/lib/types/components/dialog.d.ts +30 -0
  109. package/lib/types/components/dialog.d.ts.map +1 -0
  110. package/lib/types/components/drawer.d.ts +21 -0
  111. package/lib/types/components/drawer.d.ts.map +1 -0
  112. package/lib/types/components/dropdown-menu.d.ts +37 -0
  113. package/lib/types/components/dropdown-menu.d.ts.map +1 -0
  114. package/lib/types/components/empty.d.ts +24 -0
  115. package/lib/types/components/empty.d.ts.map +1 -0
  116. package/lib/types/components/field.d.ts +31 -0
  117. package/lib/types/components/field.d.ts.map +1 -0
  118. package/lib/types/components/hover-card.d.ts +10 -0
  119. package/lib/types/components/hover-card.d.ts.map +1 -0
  120. package/lib/types/components/input-group.d.ts +23 -0
  121. package/lib/types/components/input-group.d.ts.map +1 -0
  122. package/lib/types/components/input.d.ts +11 -0
  123. package/lib/types/components/input.d.ts.map +1 -0
  124. package/lib/types/components/item.d.ts +27 -0
  125. package/lib/types/components/item.d.ts.map +1 -0
  126. package/lib/types/components/kbd.d.ts +8 -0
  127. package/lib/types/components/kbd.d.ts.map +1 -0
  128. package/lib/types/components/label.d.ts +11 -0
  129. package/lib/types/components/label.d.ts.map +1 -0
  130. package/lib/types/components/marker.d.ts +15 -0
  131. package/lib/types/components/marker.d.ts.map +1 -0
  132. package/lib/types/components/menubar.d.ts +34 -0
  133. package/lib/types/components/menubar.d.ts.map +1 -0
  134. package/lib/types/components/message-scroller.d.ts +15 -0
  135. package/lib/types/components/message-scroller.d.ts.map +1 -0
  136. package/lib/types/components/message.d.ts +15 -0
  137. package/lib/types/components/message.d.ts.map +1 -0
  138. package/lib/types/components/native-select.d.ts +13 -0
  139. package/lib/types/components/native-select.d.ts.map +1 -0
  140. package/lib/types/components/navigation-menu.d.ts +16 -0
  141. package/lib/types/components/navigation-menu.d.ts.map +1 -0
  142. package/lib/types/components/pagination.d.ts +22 -0
  143. package/lib/types/components/pagination.d.ts.map +1 -0
  144. package/lib/types/components/popover.d.ts +17 -0
  145. package/lib/types/components/popover.d.ts.map +1 -0
  146. package/lib/types/components/progress.d.ts +15 -0
  147. package/lib/types/components/progress.d.ts.map +1 -0
  148. package/lib/types/components/questionnaire.d.ts +24 -0
  149. package/lib/types/components/questionnaire.d.ts.map +1 -0
  150. package/lib/types/components/radio-group.d.ts +10 -0
  151. package/lib/types/components/radio-group.d.ts.map +1 -0
  152. package/lib/types/components/resizable.d.ts +15 -0
  153. package/lib/types/components/resizable.d.ts.map +1 -0
  154. package/lib/types/components/scroll-area.d.ts +9 -0
  155. package/lib/types/components/scroll-area.d.ts.map +1 -0
  156. package/lib/types/components/select.d.ts +23 -0
  157. package/lib/types/components/select.d.ts.map +1 -0
  158. package/lib/types/components/separator.d.ts +9 -0
  159. package/lib/types/components/separator.d.ts.map +1 -0
  160. package/lib/types/components/sheet.d.ts +28 -0
  161. package/lib/types/components/sheet.d.ts.map +1 -0
  162. package/lib/types/components/sidebar.d.ts +68 -0
  163. package/lib/types/components/sidebar.d.ts.map +1 -0
  164. package/lib/types/components/skeleton.d.ts +10 -0
  165. package/lib/types/components/skeleton.d.ts.map +1 -0
  166. package/lib/types/components/slider.d.ts +8 -0
  167. package/lib/types/components/slider.d.ts.map +1 -0
  168. package/lib/types/components/spinner.d.ts +9 -0
  169. package/lib/types/components/spinner.d.ts.map +1 -0
  170. package/lib/types/components/switch.d.ts +13 -0
  171. package/lib/types/components/switch.d.ts.map +1 -0
  172. package/lib/types/components/table.d.ts +18 -0
  173. package/lib/types/components/table.d.ts.map +1 -0
  174. package/lib/types/components/tabs.d.ts +18 -0
  175. package/lib/types/components/tabs.d.ts.map +1 -0
  176. package/lib/types/components/textarea.d.ts +11 -0
  177. package/lib/types/components/textarea.d.ts.map +1 -0
  178. package/lib/types/components/toast.d.ts +35 -0
  179. package/lib/types/components/toast.d.ts.map +1 -0
  180. package/lib/types/components/toggle-group.d.ts +16 -0
  181. package/lib/types/components/toggle-group.d.ts.map +1 -0
  182. package/lib/types/components/toggle.d.ts +13 -0
  183. package/lib/types/components/toggle.d.ts.map +1 -0
  184. package/lib/types/components/tooltip.d.ts +14 -0
  185. package/lib/types/components/tooltip.d.ts.map +1 -0
  186. package/lib/types/composites/autocomplete.d.ts +15 -0
  187. package/lib/types/composites/autocomplete.d.ts.map +1 -0
  188. package/lib/types/composites/cascader.d.ts +18 -0
  189. package/lib/types/composites/cascader.d.ts.map +1 -0
  190. package/lib/types/composites/color-picker.d.ts +12 -0
  191. package/lib/types/composites/color-picker.d.ts.map +1 -0
  192. package/lib/types/composites/confirm-dialog.d.ts +17 -0
  193. package/lib/types/composites/confirm-dialog.d.ts.map +1 -0
  194. package/lib/types/composites/copyable.d.ts +12 -0
  195. package/lib/types/composites/copyable.d.ts.map +1 -0
  196. package/lib/types/composites/currency-input.d.ts +13 -0
  197. package/lib/types/composites/currency-input.d.ts.map +1 -0
  198. package/lib/types/composites/date-chrome.d.ts +8 -0
  199. package/lib/types/composites/date-chrome.d.ts.map +1 -0
  200. package/lib/types/composites/date-picker.d.ts +17 -0
  201. package/lib/types/composites/date-picker.d.ts.map +1 -0
  202. package/lib/types/composites/date-range-picker.d.ts +18 -0
  203. package/lib/types/composites/date-range-picker.d.ts.map +1 -0
  204. package/lib/types/composites/date-time-picker.d.ts +18 -0
  205. package/lib/types/composites/date-time-picker.d.ts.map +1 -0
  206. package/lib/types/composites/date-time-range-picker.d.ts +17 -0
  207. package/lib/types/composites/date-time-range-picker.d.ts.map +1 -0
  208. package/lib/types/composites/duration-input.d.ts +14 -0
  209. package/lib/types/composites/duration-input.d.ts.map +1 -0
  210. package/lib/types/composites/live-refresh.d.ts +46 -0
  211. package/lib/types/composites/live-refresh.d.ts.map +1 -0
  212. package/lib/types/composites/mini-calendar.d.ts +13 -0
  213. package/lib/types/composites/mini-calendar.d.ts.map +1 -0
  214. package/lib/types/composites/number-field.d.ts +15 -0
  215. package/lib/types/composites/number-field.d.ts.map +1 -0
  216. package/lib/types/composites/password-field.d.ts +13 -0
  217. package/lib/types/composites/password-field.d.ts.map +1 -0
  218. package/lib/types/composites/phone-input.d.ts +12 -0
  219. package/lib/types/composites/phone-input.d.ts.map +1 -0
  220. package/lib/types/composites/rating.d.ts +13 -0
  221. package/lib/types/composites/rating.d.ts.map +1 -0
  222. package/lib/types/composites/relative-date-picker.d.ts +16 -0
  223. package/lib/types/composites/relative-date-picker.d.ts.map +1 -0
  224. package/lib/types/composites/search-input.d.ts +16 -0
  225. package/lib/types/composites/search-input.d.ts.map +1 -0
  226. package/lib/types/composites/slider-range.d.ts +14 -0
  227. package/lib/types/composites/slider-range.d.ts.map +1 -0
  228. package/lib/types/composites/tag-input.d.ts +14 -0
  229. package/lib/types/composites/tag-input.d.ts.map +1 -0
  230. package/lib/types/composites/time-picker.d.ts +28 -0
  231. package/lib/types/composites/time-picker.d.ts.map +1 -0
  232. package/lib/types/composites/time-range-picker.d.ts +16 -0
  233. package/lib/types/composites/time-range-picker.d.ts.map +1 -0
  234. package/lib/types/composites/timezone-select.d.ts +22 -0
  235. package/lib/types/composites/timezone-select.d.ts.map +1 -0
  236. package/lib/types/composites/transfer.d.ts +17 -0
  237. package/lib/types/composites/transfer.d.ts.map +1 -0
  238. package/lib/types/composites/user-picker.d.ts +17 -0
  239. package/lib/types/composites/user-picker.d.ts.map +1 -0
  240. package/lib/types/hooks/use-html-dark.d.ts +4 -0
  241. package/lib/types/hooks/use-html-dark.d.ts.map +1 -0
  242. package/lib/types/hooks/use-mobile.d.ts +2 -0
  243. package/lib/types/hooks/use-mobile.d.ts.map +1 -0
  244. package/lib/types/i18n/context.d.ts +310 -0
  245. package/lib/types/i18n/context.d.ts.map +1 -0
  246. package/lib/types/i18n/en.d.ts +290 -0
  247. package/lib/types/i18n/en.d.ts.map +1 -0
  248. package/lib/types/i18n/zh.d.ts +3 -0
  249. package/lib/types/i18n/zh.d.ts.map +1 -0
  250. package/lib/types/index.d.ts +151 -0
  251. package/lib/types/index.d.ts.map +1 -0
  252. package/lib/types/lib/clipboard.d.ts +3 -0
  253. package/lib/types/lib/clipboard.d.ts.map +1 -0
  254. package/lib/types/lib/defined.d.ts +3 -0
  255. package/lib/types/lib/defined.d.ts.map +1 -0
  256. package/lib/types/lib/icons.d.ts +16 -0
  257. package/lib/types/lib/icons.d.ts.map +1 -0
  258. package/lib/types/lib/illustrations.d.ts +18 -0
  259. package/lib/types/lib/illustrations.d.ts.map +1 -0
  260. package/lib/types/lib/utils.d.ts +3 -0
  261. package/lib/types/lib/utils.d.ts.map +1 -0
  262. package/lib/types/products/cells.d.ts +13 -0
  263. package/lib/types/products/cells.d.ts.map +1 -0
  264. package/lib/types/products/code-block.d.ts +14 -0
  265. package/lib/types/products/code-block.d.ts.map +1 -0
  266. package/lib/types/products/code-editor.d.ts +21 -0
  267. package/lib/types/products/code-editor.d.ts.map +1 -0
  268. package/lib/types/products/commit-graph.d.ts +38 -0
  269. package/lib/types/products/commit-graph.d.ts.map +1 -0
  270. package/lib/types/products/data-grid.d.ts +79 -0
  271. package/lib/types/products/data-grid.d.ts.map +1 -0
  272. package/lib/types/products/diff-viewer.d.ts +15 -0
  273. package/lib/types/products/diff-viewer.d.ts.map +1 -0
  274. package/lib/types/products/event-calendar.d.ts +23 -0
  275. package/lib/types/products/event-calendar.d.ts.map +1 -0
  276. package/lib/types/products/export-csv.d.ts +2 -0
  277. package/lib/types/products/export-csv.d.ts.map +1 -0
  278. package/lib/types/products/file-dropzone.d.ts +12 -0
  279. package/lib/types/products/file-dropzone.d.ts.map +1 -0
  280. package/lib/types/products/full-calendar/animations.d.ts +12 -0
  281. package/lib/types/products/full-calendar/animations.d.ts.map +1 -0
  282. package/lib/types/products/full-calendar/calendar-body.d.ts +2 -0
  283. package/lib/types/products/full-calendar/calendar-body.d.ts.map +1 -0
  284. package/lib/types/products/full-calendar/constants.d.ts +3 -0
  285. package/lib/types/products/full-calendar/constants.d.ts.map +1 -0
  286. package/lib/types/products/full-calendar/contexts/calendar-context.d.ts +42 -0
  287. package/lib/types/products/full-calendar/contexts/calendar-context.d.ts.map +1 -0
  288. package/lib/types/products/full-calendar/contexts/dnd-context.d.ts +16 -0
  289. package/lib/types/products/full-calendar/contexts/dnd-context.d.ts.map +1 -0
  290. package/lib/types/products/full-calendar/dialogs/add-edit-event-dialog.d.ts +21 -0
  291. package/lib/types/products/full-calendar/dialogs/add-edit-event-dialog.d.ts.map +1 -0
  292. package/lib/types/products/full-calendar/dialogs/delete-event-dialog.d.ts +4 -0
  293. package/lib/types/products/full-calendar/dialogs/delete-event-dialog.d.ts.map +1 -0
  294. package/lib/types/products/full-calendar/dialogs/event-details-dialog.d.ts +7 -0
  295. package/lib/types/products/full-calendar/dialogs/event-details-dialog.d.ts.map +1 -0
  296. package/lib/types/products/full-calendar/dialogs/events-list-dialog.d.ts +9 -0
  297. package/lib/types/products/full-calendar/dialogs/events-list-dialog.d.ts.map +1 -0
  298. package/lib/types/products/full-calendar/dnd/draggable-event.d.ts +11 -0
  299. package/lib/types/products/full-calendar/dnd/draggable-event.d.ts.map +1 -0
  300. package/lib/types/products/full-calendar/dnd/droppable-area.d.ts +11 -0
  301. package/lib/types/products/full-calendar/dnd/droppable-area.d.ts.map +1 -0
  302. package/lib/types/products/full-calendar/dnd/resizable-event.d.ts +10 -0
  303. package/lib/types/products/full-calendar/dnd/resizable-event.d.ts.map +1 -0
  304. package/lib/types/products/full-calendar/header/calendar-header.d.ts +2 -0
  305. package/lib/types/products/full-calendar/header/calendar-header.d.ts.map +1 -0
  306. package/lib/types/products/full-calendar/header/date-navigator.d.ts +9 -0
  307. package/lib/types/products/full-calendar/header/date-navigator.d.ts.map +1 -0
  308. package/lib/types/products/full-calendar/header/filter.d.ts +2 -0
  309. package/lib/types/products/full-calendar/header/filter.d.ts.map +1 -0
  310. package/lib/types/products/full-calendar/header/today-button.d.ts +2 -0
  311. package/lib/types/products/full-calendar/header/today-button.d.ts.map +1 -0
  312. package/lib/types/products/full-calendar/header/user-select.d.ts +2 -0
  313. package/lib/types/products/full-calendar/header/user-select.d.ts.map +1 -0
  314. package/lib/types/products/full-calendar/header/view-tabs.d.ts +4 -0
  315. package/lib/types/products/full-calendar/header/view-tabs.d.ts.map +1 -0
  316. package/lib/types/products/full-calendar/helpers.d.ts +42 -0
  317. package/lib/types/products/full-calendar/helpers.d.ts.map +1 -0
  318. package/lib/types/products/full-calendar/hooks/use-time-range-create.d.ts +25 -0
  319. package/lib/types/products/full-calendar/hooks/use-time-range-create.d.ts.map +1 -0
  320. package/lib/types/products/full-calendar/hooks.d.ts +11 -0
  321. package/lib/types/products/full-calendar/hooks.d.ts.map +1 -0
  322. package/lib/types/products/full-calendar/interfaces.d.ts +21 -0
  323. package/lib/types/products/full-calendar/interfaces.d.ts.map +1 -0
  324. package/lib/types/products/full-calendar/settings/settings.d.ts +2 -0
  325. package/lib/types/products/full-calendar/settings/settings.d.ts.map +1 -0
  326. package/lib/types/products/full-calendar/shims/avatar-group.d.ts +7 -0
  327. package/lib/types/products/full-calendar/shims/avatar-group.d.ts.map +1 -0
  328. package/lib/types/products/full-calendar/shims/day-picker.d.ts +2 -0
  329. package/lib/types/products/full-calendar/shims/day-picker.d.ts.map +1 -0
  330. package/lib/types/products/full-calendar/shims/motion.d.ts +32 -0
  331. package/lib/types/products/full-calendar/shims/motion.d.ts.map +1 -0
  332. package/lib/types/products/full-calendar/shims/next-themes.d.ts +5 -0
  333. package/lib/types/products/full-calendar/shims/next-themes.d.ts.map +1 -0
  334. package/lib/types/products/full-calendar/shims/re-resizable.d.ts +19 -0
  335. package/lib/types/products/full-calendar/shims/re-resizable.d.ts.map +1 -0
  336. package/lib/types/products/full-calendar/shims/sonner.d.ts +5 -0
  337. package/lib/types/products/full-calendar/shims/sonner.d.ts.map +1 -0
  338. package/lib/types/products/full-calendar/types.d.ts +3 -0
  339. package/lib/types/products/full-calendar/types.d.ts.map +1 -0
  340. package/lib/types/products/full-calendar/views/agenda-view/agenda-events.d.ts +3 -0
  341. package/lib/types/products/full-calendar/views/agenda-view/agenda-events.d.ts.map +1 -0
  342. package/lib/types/products/full-calendar/views/month-view/calendar-month-view.d.ts +8 -0
  343. package/lib/types/products/full-calendar/views/month-view/calendar-month-view.d.ts.map +1 -0
  344. package/lib/types/products/full-calendar/views/month-view/day-cell.d.ts +12 -0
  345. package/lib/types/products/full-calendar/views/month-view/day-cell.d.ts.map +1 -0
  346. package/lib/types/products/full-calendar/views/month-view/event-bullet.d.ts +6 -0
  347. package/lib/types/products/full-calendar/views/month-view/event-bullet.d.ts.map +1 -0
  348. package/lib/types/products/full-calendar/views/month-view/month-event-badge.d.ts +17 -0
  349. package/lib/types/products/full-calendar/views/month-view/month-event-badge.d.ts.map +1 -0
  350. package/lib/types/products/full-calendar/views/week-and-day-view/calendar-day-view.d.ts +8 -0
  351. package/lib/types/products/full-calendar/views/week-and-day-view/calendar-day-view.d.ts.map +1 -0
  352. package/lib/types/products/full-calendar/views/week-and-day-view/calendar-time-line.d.ts +2 -0
  353. package/lib/types/products/full-calendar/views/week-and-day-view/calendar-time-line.d.ts.map +1 -0
  354. package/lib/types/products/full-calendar/views/week-and-day-view/calendar-week-view.d.ts +8 -0
  355. package/lib/types/products/full-calendar/views/week-and-day-view/calendar-week-view.d.ts.map +1 -0
  356. package/lib/types/products/full-calendar/views/week-and-day-view/day-view-multi-day-events-row.d.ts +8 -0
  357. package/lib/types/products/full-calendar/views/week-and-day-view/day-view-multi-day-events-row.d.ts.map +1 -0
  358. package/lib/types/products/full-calendar/views/week-and-day-view/event-block.d.ts +12 -0
  359. package/lib/types/products/full-calendar/views/week-and-day-view/event-block.d.ts.map +1 -0
  360. package/lib/types/products/full-calendar/views/week-and-day-view/render-grouped-events.d.ts +8 -0
  361. package/lib/types/products/full-calendar/views/week-and-day-view/render-grouped-events.d.ts.map +1 -0
  362. package/lib/types/products/full-calendar/views/week-and-day-view/week-view-multi-day-events-row.d.ts +8 -0
  363. package/lib/types/products/full-calendar/views/week-and-day-view/week-view-multi-day-events-row.d.ts.map +1 -0
  364. package/lib/types/products/full-calendar/views/year-view/calendar-year-view.d.ts +8 -0
  365. package/lib/types/products/full-calendar/views/year-view/calendar-year-view.d.ts.map +1 -0
  366. package/lib/types/products/gantt.d.ts +17 -0
  367. package/lib/types/products/gantt.d.ts.map +1 -0
  368. package/lib/types/products/jira-wiki-parse.d.ts +55 -0
  369. package/lib/types/products/jira-wiki-parse.d.ts.map +1 -0
  370. package/lib/types/products/jira-wiki.d.ts +39 -0
  371. package/lib/types/products/jira-wiki.d.ts.map +1 -0
  372. package/lib/types/products/jql-input.d.ts +22 -0
  373. package/lib/types/products/jql-input.d.ts.map +1 -0
  374. package/lib/types/products/json-viewer.d.ts +12 -0
  375. package/lib/types/products/json-viewer.d.ts.map +1 -0
  376. package/lib/types/products/kanban-issue-panel.d.ts +15 -0
  377. package/lib/types/products/kanban-issue-panel.d.ts.map +1 -0
  378. package/lib/types/products/kanban.d.ts +43 -0
  379. package/lib/types/products/kanban.d.ts.map +1 -0
  380. package/lib/types/products/log-viewer.d.ts +25 -0
  381. package/lib/types/products/log-viewer.d.ts.map +1 -0
  382. package/lib/types/products/markdown-editor.d.ts +16 -0
  383. package/lib/types/products/markdown-editor.d.ts.map +1 -0
  384. package/lib/types/products/markdown.d.ts +13 -0
  385. package/lib/types/products/markdown.d.ts.map +1 -0
  386. package/lib/types/products/rich-text-editor.d.ts +13 -0
  387. package/lib/types/products/rich-text-editor.d.ts.map +1 -0
  388. package/lib/types/products/sortable-list.d.ts +16 -0
  389. package/lib/types/products/sortable-list.d.ts.map +1 -0
  390. package/lib/types/products/stepper.d.ts +39 -0
  391. package/lib/types/products/stepper.d.ts.map +1 -0
  392. package/lib/types/products/timeline.d.ts +17 -0
  393. package/lib/types/products/timeline.d.ts.map +1 -0
  394. package/lib/types/products/tree-view.d.ts +17 -0
  395. package/lib/types/products/tree-view.d.ts.map +1 -0
  396. package/lib/types/sdk/app-error-boundary.d.ts +33 -0
  397. package/lib/types/sdk/app-error-boundary.d.ts.map +1 -0
  398. package/lib/types/sdk/app-id.d.ts +6 -0
  399. package/lib/types/sdk/app-id.d.ts.map +1 -0
  400. package/lib/types/sdk/use-app.d.ts +32 -0
  401. package/lib/types/sdk/use-app.d.ts.map +1 -0
  402. package/package.json +67 -0
  403. package/src/blocks/activity-feed.tsx +16 -0
  404. package/src/blocks/app-shell.tsx +38 -0
  405. package/src/blocks/attachment-gallery.tsx +36 -0
  406. package/src/blocks/bar-chart.tsx +46 -0
  407. package/src/blocks/comment-thread.tsx +37 -0
  408. package/src/blocks/dashboard-shell.tsx +108 -0
  409. package/src/blocks/description-list.tsx +23 -0
  410. package/src/blocks/detail-panel.tsx +43 -0
  411. package/src/blocks/donut-chart.tsx +54 -0
  412. package/src/blocks/env-badge.tsx +30 -0
  413. package/src/blocks/env-table.tsx +315 -0
  414. package/src/blocks/file-tree.tsx +12 -0
  415. package/src/blocks/filter-bar.tsx +22 -0
  416. package/src/blocks/form-sheet.tsx +159 -0
  417. package/src/blocks/gauge.tsx +36 -0
  418. package/src/blocks/list-detail.tsx +120 -0
  419. package/src/blocks/notification-center.tsx +29 -0
  420. package/src/blocks/page-header.tsx +31 -0
  421. package/src/blocks/progress-ring.tsx +43 -0
  422. package/src/blocks/radar-chart.tsx +47 -0
  423. package/src/blocks/request-inspector.tsx +41 -0
  424. package/src/blocks/reveal.tsx +56 -0
  425. package/src/blocks/run-timeline.tsx +12 -0
  426. package/src/blocks/scrollspy.tsx +48 -0
  427. package/src/blocks/settings-split.tsx +153 -0
  428. package/src/blocks/severity-chip.tsx +34 -0
  429. package/src/blocks/sparkline.tsx +27 -0
  430. package/src/blocks/stat-card.tsx +50 -0
  431. package/src/blocks/status-badge.tsx +40 -0
  432. package/src/blocks/table-page.tsx +82 -0
  433. package/src/blocks/terminal.tsx +28 -0
  434. package/src/blocks/test-step-list.tsx +26 -0
  435. package/src/blocks/trend-card.tsx +57 -0
  436. package/src/blocks/wizard-shell.tsx +131 -0
  437. package/src/cdn-modules.d.ts +5 -0
  438. package/src/components/accordion.tsx +79 -0
  439. package/src/components/alert-dialog.tsx +192 -0
  440. package/src/components/alert.tsx +83 -0
  441. package/src/components/aspect-ratio.tsx +26 -0
  442. package/src/components/attachment.tsx +211 -0
  443. package/src/components/avatar.tsx +111 -0
  444. package/src/components/badge.tsx +59 -0
  445. package/src/components/breadcrumb.tsx +129 -0
  446. package/src/components/bubble.tsx +132 -0
  447. package/src/components/button-group.tsx +93 -0
  448. package/src/components/button.tsx +65 -0
  449. package/src/components/calendar.tsx +224 -0
  450. package/src/components/card.tsx +110 -0
  451. package/src/components/chart.tsx +378 -0
  452. package/src/components/checkbox.tsx +33 -0
  453. package/src/components/collapsible.tsx +23 -0
  454. package/src/components/combobox.tsx +299 -0
  455. package/src/components/command.tsx +201 -0
  456. package/src/components/context-menu.tsx +274 -0
  457. package/src/components/dialog.tsx +179 -0
  458. package/src/components/drawer.tsx +230 -0
  459. package/src/components/dropdown-menu.tsx +274 -0
  460. package/src/components/empty.tsx +130 -0
  461. package/src/components/field.tsx +242 -0
  462. package/src/components/hover-card.tsx +53 -0
  463. package/src/components/input-group.tsx +161 -0
  464. package/src/components/input.tsx +27 -0
  465. package/src/components/item.tsx +205 -0
  466. package/src/components/kbd.tsx +30 -0
  467. package/src/components/label.tsx +26 -0
  468. package/src/components/marker.tsx +75 -0
  469. package/src/components/menubar.tsx +283 -0
  470. package/src/components/message-scroller.tsx +133 -0
  471. package/src/components/message.tsx +96 -0
  472. package/src/components/native-select.tsx +65 -0
  473. package/src/components/navigation-menu.tsx +172 -0
  474. package/src/components/pagination.tsx +138 -0
  475. package/src/components/popover.tsx +95 -0
  476. package/src/components/progress.tsx +89 -0
  477. package/src/components/questionnaire.tsx +332 -0
  478. package/src/components/radio-group.tsx +40 -0
  479. package/src/components/resizable.tsx +56 -0
  480. package/src/components/scroll-area.tsx +56 -0
  481. package/src/components/select.tsx +207 -0
  482. package/src/components/separator.tsx +28 -0
  483. package/src/components/sheet.tsx +158 -0
  484. package/src/components/sidebar.tsx +725 -0
  485. package/src/components/skeleton.tsx +20 -0
  486. package/src/components/slider.tsx +56 -0
  487. package/src/components/spinner.tsx +16 -0
  488. package/src/components/switch.tsx +38 -0
  489. package/src/components/table.tsx +121 -0
  490. package/src/components/tabs.tsx +88 -0
  491. package/src/components/textarea.tsx +25 -0
  492. package/src/components/toast.tsx +273 -0
  493. package/src/components/toggle-group.tsx +92 -0
  494. package/src/components/toggle.tsx +47 -0
  495. package/src/components/tooltip.tsx +72 -0
  496. package/src/composites/autocomplete.tsx +61 -0
  497. package/src/composites/cascader.tsx +52 -0
  498. package/src/composites/color-picker.tsx +25 -0
  499. package/src/composites/confirm-dialog.tsx +62 -0
  500. package/src/composites/copyable.tsx +44 -0
  501. package/src/composites/currency-input.tsx +37 -0
  502. package/src/composites/date-chrome.tsx +156 -0
  503. package/src/composites/date-picker.tsx +97 -0
  504. package/src/composites/date-range-picker.tsx +99 -0
  505. package/src/composites/date-time-picker.tsx +121 -0
  506. package/src/composites/date-time-range-picker.tsx +57 -0
  507. package/src/composites/duration-input.tsx +128 -0
  508. package/src/composites/live-refresh.tsx +348 -0
  509. package/src/composites/mini-calendar.tsx +30 -0
  510. package/src/composites/number-field.tsx +59 -0
  511. package/src/composites/password-field.tsx +50 -0
  512. package/src/composites/phone-input.tsx +28 -0
  513. package/src/composites/rating.tsx +45 -0
  514. package/src/composites/relative-date-picker.tsx +68 -0
  515. package/src/composites/search-input.tsx +55 -0
  516. package/src/composites/slider-range.tsx +36 -0
  517. package/src/composites/tag-input.tsx +62 -0
  518. package/src/composites/time-picker.tsx +208 -0
  519. package/src/composites/time-range-picker.tsx +31 -0
  520. package/src/composites/timezone-select.tsx +257 -0
  521. package/src/composites/transfer.tsx +58 -0
  522. package/src/composites/user-picker.tsx +46 -0
  523. package/src/hooks/use-html-dark.ts +36 -0
  524. package/src/hooks/use-mobile.ts +22 -0
  525. package/src/i18n/context.tsx +71 -0
  526. package/src/i18n/en.ts +308 -0
  527. package/src/i18n/zh.ts +290 -0
  528. package/src/index.ts +151 -0
  529. package/src/lib/clipboard.ts +10 -0
  530. package/src/lib/defined.ts +8 -0
  531. package/src/lib/icons.tsx +16 -0
  532. package/src/lib/illustrations.tsx +573 -0
  533. package/src/lib/utils.ts +6 -0
  534. package/src/products/cells.tsx +18 -0
  535. package/src/products/code-block.tsx +91 -0
  536. package/src/products/code-editor.tsx +271 -0
  537. package/src/products/column-meta.d.ts +9 -0
  538. package/src/products/commit-graph.tsx +643 -0
  539. package/src/products/data-grid.tsx +692 -0
  540. package/src/products/diff-viewer.tsx +224 -0
  541. package/src/products/event-calendar.tsx +49 -0
  542. package/src/products/export-csv.ts +26 -0
  543. package/src/products/file-dropzone.tsx +47 -0
  544. package/src/products/full-calendar/animations.ts +38 -0
  545. package/src/products/full-calendar/calendar-body.tsx +76 -0
  546. package/src/products/full-calendar/constants.ts +10 -0
  547. package/src/products/full-calendar/contexts/calendar-context.tsx +254 -0
  548. package/src/products/full-calendar/contexts/dnd-context.tsx +156 -0
  549. package/src/products/full-calendar/dialogs/add-edit-event-dialog.tsx +186 -0
  550. package/src/products/full-calendar/dialogs/delete-event-dialog.tsx +39 -0
  551. package/src/products/full-calendar/dialogs/event-details-dialog.tsx +99 -0
  552. package/src/products/full-calendar/dialogs/events-list-dialog.tsx +86 -0
  553. package/src/products/full-calendar/dnd/draggable-event.tsx +45 -0
  554. package/src/products/full-calendar/dnd/droppable-area.tsx +45 -0
  555. package/src/products/full-calendar/dnd/resizable-event.tsx +178 -0
  556. package/src/products/full-calendar/header/calendar-header.tsx +64 -0
  557. package/src/products/full-calendar/header/date-navigator.tsx +110 -0
  558. package/src/products/full-calendar/header/filter.tsx +58 -0
  559. package/src/products/full-calendar/header/today-button.tsx +45 -0
  560. package/src/products/full-calendar/header/user-select.tsx +64 -0
  561. package/src/products/full-calendar/header/view-tabs.tsx +36 -0
  562. package/src/products/full-calendar/helpers.ts +463 -0
  563. package/src/products/full-calendar/hooks/use-time-range-create.ts +152 -0
  564. package/src/products/full-calendar/hooks.ts +70 -0
  565. package/src/products/full-calendar/interfaces.ts +23 -0
  566. package/src/products/full-calendar/settings/settings.tsx +80 -0
  567. package/src/products/full-calendar/shims/avatar-group.tsx +16 -0
  568. package/src/products/full-calendar/shims/day-picker.tsx +1 -0
  569. package/src/products/full-calendar/shims/motion.tsx +97 -0
  570. package/src/products/full-calendar/shims/next-themes.ts +6 -0
  571. package/src/products/full-calendar/shims/re-resizable.tsx +25 -0
  572. package/src/products/full-calendar/shims/sonner.ts +4 -0
  573. package/src/products/full-calendar/types.ts +8 -0
  574. package/src/products/full-calendar/views/agenda-view/agenda-events.tsx +140 -0
  575. package/src/products/full-calendar/views/month-view/calendar-month-view.tsx +69 -0
  576. package/src/products/full-calendar/views/month-view/day-cell.tsx +200 -0
  577. package/src/products/full-calendar/views/month-view/event-bullet.tsx +40 -0
  578. package/src/products/full-calendar/views/month-view/month-event-badge.tsx +143 -0
  579. package/src/products/full-calendar/views/week-and-day-view/calendar-day-view.tsx +295 -0
  580. package/src/products/full-calendar/views/week-and-day-view/calendar-time-line.tsx +35 -0
  581. package/src/products/full-calendar/views/week-and-day-view/calendar-week-view.tsx +251 -0
  582. package/src/products/full-calendar/views/week-and-day-view/day-view-multi-day-events-row.tsx +73 -0
  583. package/src/products/full-calendar/views/week-and-day-view/event-block.tsx +114 -0
  584. package/src/products/full-calendar/views/week-and-day-view/render-grouped-events.tsx +49 -0
  585. package/src/products/full-calendar/views/week-and-day-view/week-view-multi-day-events-row.tsx +145 -0
  586. package/src/products/full-calendar/views/year-view/calendar-year-view.tsx +161 -0
  587. package/src/products/gantt.tsx +47 -0
  588. package/src/products/jira-wiki-parse.ts +197 -0
  589. package/src/products/jira-wiki.tsx +287 -0
  590. package/src/products/jql-input.tsx +391 -0
  591. package/src/products/json-viewer.tsx +43 -0
  592. package/src/products/kanban-issue-panel.tsx +104 -0
  593. package/src/products/kanban.tsx +245 -0
  594. package/src/products/log-viewer.tsx +404 -0
  595. package/src/products/markdown-editor.tsx +77 -0
  596. package/src/products/markdown.tsx +50 -0
  597. package/src/products/rich-text-editor.tsx +89 -0
  598. package/src/products/sortable-list.tsx +67 -0
  599. package/src/products/stepper.tsx +237 -0
  600. package/src/products/timeline.tsx +39 -0
  601. package/src/products/tree-view.tsx +62 -0
  602. package/src/sdk/app-error-boundary.tsx +240 -0
  603. package/src/sdk/app-id.ts +7 -0
  604. package/src/sdk/use-app.ts +43 -0
@@ -0,0 +1,83 @@
1
+ import * as React from 'react'
2
+ import { cva, type VariantProps } from 'class-variance-authority'
3
+
4
+ import { cn } from '@mohou/ui/lib/utils'
5
+
6
+ const alertVariants = cva(
7
+ "group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4",
8
+ {
9
+ variants: {
10
+ variant: {
11
+ default: 'bg-card text-card-foreground',
12
+ destructive:
13
+ 'bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current',
14
+ },
15
+ },
16
+ defaultVariants: {
17
+ variant: 'default',
18
+ },
19
+ },
20
+ )
21
+
22
+ /**
23
+ * Inline message block (info/warning/error).
24
+ * @when Explaining a failed state in place. Transient → `toast()`.
25
+ * @example
26
+ * <Alert variant="destructive"><AlertTitle>拉取失败</AlertTitle><AlertDescription>上游 502,已用缓存</AlertDescription></Alert>
27
+ * @family Feedback & status
28
+ */
29
+ function Alert({
30
+ className,
31
+ variant,
32
+ ...props
33
+ }: React.ComponentProps<'div'> & VariantProps<typeof alertVariants>) {
34
+ return (
35
+ <div
36
+ data-slot="alert"
37
+ role="alert"
38
+ className={cn(alertVariants({ variant }), className)}
39
+ {...props}
40
+ />
41
+ )
42
+ }
43
+
44
+ function AlertTitle({ className, ...props }: React.ComponentProps<'div'>) {
45
+ return (
46
+ <div
47
+ data-slot="alert-title"
48
+ className={cn(
49
+ 'font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground',
50
+ className,
51
+ )}
52
+ {...props}
53
+ />
54
+ )
55
+ }
56
+
57
+ function AlertDescription({
58
+ className,
59
+ ...props
60
+ }: React.ComponentProps<'div'>) {
61
+ return (
62
+ <div
63
+ data-slot="alert-description"
64
+ className={cn(
65
+ 'text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4',
66
+ className,
67
+ )}
68
+ {...props}
69
+ />
70
+ )
71
+ }
72
+
73
+ function AlertAction({ className, ...props }: React.ComponentProps<'div'>) {
74
+ return (
75
+ <div
76
+ data-slot="alert-action"
77
+ className={cn('absolute top-2 right-2', className)}
78
+ {...props}
79
+ />
80
+ )
81
+ }
82
+
83
+ export { Alert, AlertTitle, AlertDescription, AlertAction }
@@ -0,0 +1,26 @@
1
+ import { cn } from '@mohou/ui/lib/utils'
2
+
3
+ /**
4
+ * @family Layout & structure
5
+ * @when Keeping an image/video/embed from shifting the layout while loading.
6
+ */
7
+ function AspectRatio({
8
+ ratio,
9
+ className,
10
+ ...props
11
+ }: React.ComponentProps<'div'> & { ratio: number }) {
12
+ return (
13
+ <div
14
+ data-slot="aspect-ratio"
15
+ style={
16
+ {
17
+ '--ratio': ratio,
18
+ } as React.CSSProperties
19
+ }
20
+ className={cn('relative aspect-(--ratio)', className)}
21
+ {...props}
22
+ />
23
+ )
24
+ }
25
+
26
+ export { AspectRatio }
@@ -0,0 +1,211 @@
1
+ import * as React from 'react'
2
+ import { mergeProps } from '@base-ui/react/merge-props'
3
+ import { useRender } from '@base-ui/react/use-render'
4
+ import { cva, type VariantProps } from 'class-variance-authority'
5
+
6
+ import { cn } from '@mohou/ui/lib/utils'
7
+ import { Button } from '@mohou/ui/components/button'
8
+
9
+ const attachmentVariants = cva(
10
+ 'group/attachment relative flex w-fit max-w-full min-w-0 shrink-0 flex-wrap rounded-xl border bg-card text-card-foreground transition-colors focus-within:ring-1 focus-within:ring-ring/50 has-[>a,>button]:hover:bg-muted/50 data-[state=error]:border-destructive/30 data-[state=idle]:border-dashed',
11
+ {
12
+ variants: {
13
+ size: {
14
+ default:
15
+ 'gap-2 text-sm has-data-[slot=attachment-content]:px-2.5 has-data-[slot=attachment-content]:py-2 has-data-[slot=attachment-media]:p-2',
16
+ sm: 'gap-2.5 text-xs has-data-[slot=attachment-content]:px-2 has-data-[slot=attachment-content]:py-1.5 has-data-[slot=attachment-media]:p-1.5',
17
+ xs: 'gap-1.5 rounded-lg text-xs has-data-[slot=attachment-content]:px-1.5 has-data-[slot=attachment-content]:py-1 has-data-[slot=attachment-media]:p-1',
18
+ },
19
+ orientation: {
20
+ horizontal: 'min-w-40 items-center',
21
+ vertical: 'w-24 flex-col has-data-[slot=attachment-content]:w-30',
22
+ },
23
+ },
24
+ },
25
+ )
26
+
27
+ /**
28
+ * @family Discovery & inspect
29
+ * @when One selected file inside a form. A grid of many → `AttachmentGallery`.
30
+ */
31
+ function Attachment({
32
+ className,
33
+ state = 'done',
34
+ size = 'default',
35
+ orientation = 'horizontal',
36
+ ...props
37
+ }: React.ComponentProps<'div'> &
38
+ VariantProps<typeof attachmentVariants> & {
39
+ state?: 'idle' | 'uploading' | 'processing' | 'error' | 'done'
40
+ }) {
41
+ return (
42
+ <div
43
+ data-slot="attachment"
44
+ data-state={state}
45
+ data-size={size}
46
+ data-orientation={orientation}
47
+ className={cn(attachmentVariants({ size, orientation }), className)}
48
+ {...props}
49
+ />
50
+ )
51
+ }
52
+
53
+ const attachmentMediaVariants = cva(
54
+ "relative flex aspect-square w-10 shrink-0 items-center justify-center overflow-hidden rounded-lg bg-muted text-foreground group-data-[orientation=vertical]/attachment:w-full group-data-[size=sm]/attachment:w-8 group-data-[size=xs]/attachment:w-7 group-data-[size=xs]/attachment:rounded-md group-data-[state=error]/attachment:bg-destructive/10 group-data-[state=error]/attachment:text-destructive group-data-[orientation=vertical]/attachment:*:data-[slot=spinner]:size-6! [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 group-data-[orientation=vertical]/attachment:[&_svg:not([class*='size-'])]:size-6 group-data-[size=xs]/attachment:[&_svg:not([class*='size-'])]:size-3.5",
55
+ {
56
+ variants: {
57
+ variant: {
58
+ icon: '',
59
+ image:
60
+ 'opacity-60 group-data-[state=done]/attachment:opacity-100 group-data-[state=idle]/attachment:opacity-100 *:[img]:aspect-square *:[img]:w-full *:[img]:object-cover',
61
+ },
62
+ },
63
+ defaultVariants: {
64
+ variant: 'icon',
65
+ },
66
+ },
67
+ )
68
+
69
+ function AttachmentMedia({
70
+ className,
71
+ variant = 'icon',
72
+ ...props
73
+ }: React.ComponentProps<'div'> & VariantProps<typeof attachmentMediaVariants>) {
74
+ return (
75
+ <div
76
+ data-slot="attachment-media"
77
+ data-variant={variant}
78
+ className={cn(attachmentMediaVariants({ variant }), className)}
79
+ {...props}
80
+ />
81
+ )
82
+ }
83
+
84
+ function AttachmentContent({
85
+ className,
86
+ ...props
87
+ }: React.ComponentProps<'div'>) {
88
+ return (
89
+ <div
90
+ data-slot="attachment-content"
91
+ className={cn(
92
+ 'max-w-full min-w-0 flex-1 leading-tight group-data-[orientation=vertical]/attachment:px-1',
93
+ className,
94
+ )}
95
+ {...props}
96
+ />
97
+ )
98
+ }
99
+
100
+ function AttachmentTitle({
101
+ className,
102
+ ...props
103
+ }: React.ComponentProps<'span'>) {
104
+ return (
105
+ <span
106
+ data-slot="attachment-title"
107
+ className={cn(
108
+ 'block max-w-full min-w-0 truncate font-medium group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer',
109
+ className,
110
+ )}
111
+ {...props}
112
+ />
113
+ )
114
+ }
115
+
116
+ function AttachmentDescription({
117
+ className,
118
+ ...props
119
+ }: React.ComponentProps<'span'>) {
120
+ return (
121
+ <span
122
+ data-slot="attachment-description"
123
+ className={cn(
124
+ 'mt-0.5 block min-w-0 truncate text-xs text-muted-foreground group-data-[state=error]/attachment:text-destructive/80',
125
+ 'max-w-full',
126
+ className,
127
+ )}
128
+ {...props}
129
+ />
130
+ )
131
+ }
132
+
133
+ function AttachmentActions({
134
+ className,
135
+ ...props
136
+ }: React.ComponentProps<'div'>) {
137
+ return (
138
+ <div
139
+ data-slot="attachment-actions"
140
+ className={cn(
141
+ 'relative z-20 flex shrink-0 items-center group-data-[orientation=vertical]/attachment:absolute group-data-[orientation=vertical]/attachment:top-3 group-data-[orientation=vertical]/attachment:right-3 group-data-[orientation=vertical]/attachment:gap-1',
142
+ className,
143
+ )}
144
+ {...props}
145
+ />
146
+ )
147
+ }
148
+
149
+ function AttachmentAction({
150
+ className,
151
+ variant,
152
+ size = 'icon-xs',
153
+ ...props
154
+ }: React.ComponentProps<typeof Button>) {
155
+ return (
156
+ <Button
157
+ data-slot="attachment-action"
158
+ variant={variant ?? 'ghost'}
159
+ size={size}
160
+ className={cn(className)}
161
+ {...props}
162
+ />
163
+ )
164
+ }
165
+
166
+ function AttachmentTrigger({
167
+ className,
168
+ render,
169
+ type,
170
+ ...props
171
+ }: useRender.ComponentProps<'button'>) {
172
+ return useRender({
173
+ defaultTagName: 'button',
174
+ props: mergeProps<'button'>(
175
+ {
176
+ type: render ? type : (type ?? 'button'),
177
+ className: cn('absolute inset-0 z-10 outline-none', className),
178
+ },
179
+ props,
180
+ ),
181
+ render,
182
+ state: {
183
+ slot: 'attachment-trigger',
184
+ },
185
+ })
186
+ }
187
+
188
+ function AttachmentGroup({ className, ...props }: React.ComponentProps<'div'>) {
189
+ return (
190
+ <div
191
+ data-slot="attachment-group"
192
+ className={cn(
193
+ 'flex min-w-0 scroll-fade-x snap-x snap-mandatory scroll-px-1 scrollbar-none gap-3 overflow-x-auto overscroll-x-contain py-1 *:data-[slot=attachment]:flex-none *:data-[slot=attachment]:snap-start',
194
+ className,
195
+ )}
196
+ {...props}
197
+ />
198
+ )
199
+ }
200
+
201
+ export {
202
+ Attachment,
203
+ AttachmentGroup,
204
+ AttachmentMedia,
205
+ AttachmentContent,
206
+ AttachmentTitle,
207
+ AttachmentDescription,
208
+ AttachmentActions,
209
+ AttachmentAction,
210
+ AttachmentTrigger,
211
+ }
@@ -0,0 +1,111 @@
1
+ import * as React from 'react'
2
+ import { Avatar as AvatarPrimitive } from '@base-ui/react/avatar'
3
+
4
+ import { cn } from '@mohou/ui/lib/utils'
5
+
6
+ /**
7
+ * @family Layout & structure
8
+ * @when User initials/photo next to a name in rows, comments, pickers.
9
+ */
10
+ function Avatar({
11
+ className,
12
+ size = 'default',
13
+ ...props
14
+ }: AvatarPrimitive.Root.Props & {
15
+ size?: 'default' | 'sm' | 'lg'
16
+ }) {
17
+ return (
18
+ <AvatarPrimitive.Root
19
+ data-slot="avatar"
20
+ data-size={size}
21
+ className={cn(
22
+ 'group/avatar relative flex size-8 shrink-0 rounded-full select-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken data-[size=lg]:size-10 data-[size=sm]:size-6 dark:after:mix-blend-lighten',
23
+ className,
24
+ )}
25
+ {...props}
26
+ />
27
+ )
28
+ }
29
+
30
+ function AvatarImage({ className, ...props }: AvatarPrimitive.Image.Props) {
31
+ return (
32
+ <AvatarPrimitive.Image
33
+ data-slot="avatar-image"
34
+ className={cn(
35
+ 'aspect-square size-full rounded-full object-cover',
36
+ className,
37
+ )}
38
+ {...props}
39
+ />
40
+ )
41
+ }
42
+
43
+ function AvatarFallback({
44
+ className,
45
+ ...props
46
+ }: AvatarPrimitive.Fallback.Props) {
47
+ return (
48
+ <AvatarPrimitive.Fallback
49
+ data-slot="avatar-fallback"
50
+ className={cn(
51
+ 'flex size-full items-center justify-center rounded-full bg-muted text-sm text-muted-foreground group-data-[size=sm]/avatar:text-xs',
52
+ className,
53
+ )}
54
+ {...props}
55
+ />
56
+ )
57
+ }
58
+
59
+ function AvatarBadge({ className, ...props }: React.ComponentProps<'span'>) {
60
+ return (
61
+ <span
62
+ data-slot="avatar-badge"
63
+ className={cn(
64
+ 'absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground bg-blend-color ring-2 ring-background select-none',
65
+ 'group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden',
66
+ 'group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2',
67
+ 'group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2',
68
+ className,
69
+ )}
70
+ {...props}
71
+ />
72
+ )
73
+ }
74
+
75
+ function AvatarGroup({ className, ...props }: React.ComponentProps<'div'>) {
76
+ return (
77
+ <div
78
+ data-slot="avatar-group"
79
+ className={cn(
80
+ 'group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background',
81
+ className,
82
+ )}
83
+ {...props}
84
+ />
85
+ )
86
+ }
87
+
88
+ function AvatarGroupCount({
89
+ className,
90
+ ...props
91
+ }: React.ComponentProps<'div'>) {
92
+ return (
93
+ <div
94
+ data-slot="avatar-group-count"
95
+ className={cn(
96
+ 'relative flex size-8 shrink-0 items-center justify-center rounded-full bg-muted text-sm text-muted-foreground ring-2 ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3',
97
+ className,
98
+ )}
99
+ {...props}
100
+ />
101
+ )
102
+ }
103
+
104
+ export {
105
+ Avatar,
106
+ AvatarImage,
107
+ AvatarFallback,
108
+ AvatarGroup,
109
+ AvatarGroupCount,
110
+ AvatarBadge,
111
+ }
@@ -0,0 +1,59 @@
1
+ import { mergeProps } from '@base-ui/react/merge-props'
2
+ import { useRender } from '@base-ui/react/use-render'
3
+ import { cva, type VariantProps } from 'class-variance-authority'
4
+
5
+ import { cn } from '@mohou/ui/lib/utils'
6
+
7
+ const badgeVariants = cva(
8
+ 'group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!',
9
+ {
10
+ variants: {
11
+ variant: {
12
+ default: 'bg-primary text-primary-foreground [a]:hover:bg-primary/80',
13
+ secondary:
14
+ 'bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80',
15
+ destructive:
16
+ 'bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20',
17
+ outline:
18
+ 'border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground',
19
+ ghost:
20
+ 'hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50',
21
+ link: 'text-primary underline-offset-4 hover:underline',
22
+ },
23
+ },
24
+ defaultVariants: {
25
+ variant: 'default',
26
+ },
27
+ },
28
+ )
29
+
30
+ /**
31
+ * Inline label chip.
32
+ * @when Static tags/counts. Status → `StatusBadge`, severity → `SeverityChip`.
33
+ * @example
34
+ * <Badge variant="secondary">草稿</Badge>
35
+ * @family Feedback & status
36
+ */
37
+ function Badge({
38
+ className,
39
+ variant = 'default',
40
+ render,
41
+ ...props
42
+ }: useRender.ComponentProps<'span'> & VariantProps<typeof badgeVariants>) {
43
+ return useRender({
44
+ defaultTagName: 'span',
45
+ props: mergeProps<'span'>(
46
+ {
47
+ className: cn(badgeVariants({ variant }), className),
48
+ },
49
+ props,
50
+ ),
51
+ render,
52
+ state: {
53
+ slot: 'badge',
54
+ variant,
55
+ },
56
+ })
57
+ }
58
+
59
+ export { Badge, badgeVariants }
@@ -0,0 +1,129 @@
1
+ import * as React from 'react'
2
+ import { mergeProps } from '@base-ui/react/merge-props'
3
+ import { useRender } from '@base-ui/react/use-render'
4
+
5
+ import { cn } from '@mohou/ui/lib/utils'
6
+ import { ChevronRightIcon, MoreHorizontalIcon } from 'lucide-react'
7
+
8
+ /**
9
+ * @family Navigation
10
+ * @when Deep mini-app views; usually one level is enough — prefer `Tabs`/`AppShell` nav.
11
+ */
12
+ function Breadcrumb({ className, ...props }: React.ComponentProps<'nav'>) {
13
+ return (
14
+ <nav
15
+ aria-label="breadcrumb"
16
+ data-slot="breadcrumb"
17
+ className={cn(className)}
18
+ {...props}
19
+ />
20
+ )
21
+ }
22
+
23
+ function BreadcrumbList({ className, ...props }: React.ComponentProps<'ol'>) {
24
+ return (
25
+ <ol
26
+ data-slot="breadcrumb-list"
27
+ className={cn(
28
+ 'flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground',
29
+ className,
30
+ )}
31
+ {...props}
32
+ />
33
+ )
34
+ }
35
+
36
+ function BreadcrumbItem({ className, ...props }: React.ComponentProps<'li'>) {
37
+ return (
38
+ <li
39
+ data-slot="breadcrumb-item"
40
+ className={cn('inline-flex items-center gap-1', className)}
41
+ {...props}
42
+ />
43
+ )
44
+ }
45
+
46
+ function BreadcrumbLink({
47
+ className,
48
+ render,
49
+ ...props
50
+ }: useRender.ComponentProps<'a'>) {
51
+ return useRender({
52
+ defaultTagName: 'a',
53
+ props: mergeProps<'a'>(
54
+ {
55
+ className: cn('transition-colors hover:text-foreground', className),
56
+ },
57
+ props,
58
+ ),
59
+ render,
60
+ state: {
61
+ slot: 'breadcrumb-link',
62
+ },
63
+ })
64
+ }
65
+
66
+ function BreadcrumbPage({ className, ...props }: React.ComponentProps<'span'>) {
67
+ return (
68
+ <span
69
+ data-slot="breadcrumb-page"
70
+ role="link"
71
+ aria-disabled="true"
72
+ aria-current="page"
73
+ className={cn('font-normal text-foreground', className)}
74
+ {...props}
75
+ />
76
+ )
77
+ }
78
+
79
+ function BreadcrumbSeparator({
80
+ children,
81
+ className,
82
+ ...props
83
+ }: React.ComponentProps<'li'>) {
84
+ return (
85
+ <li
86
+ data-slot="breadcrumb-separator"
87
+ role="presentation"
88
+ aria-hidden="true"
89
+ className={cn('[&>svg]:size-3.5', className)}
90
+ {...props}
91
+ >
92
+ {children ?? (
93
+ <ChevronRightIcon />
94
+ )}
95
+ </li>
96
+ )
97
+ }
98
+
99
+ function BreadcrumbEllipsis({
100
+ className,
101
+ ...props
102
+ }: React.ComponentProps<'span'>) {
103
+ return (
104
+ <span
105
+ data-slot="breadcrumb-ellipsis"
106
+ role="presentation"
107
+ aria-hidden="true"
108
+ className={cn(
109
+ 'flex size-5 items-center justify-center [&>svg]:size-4',
110
+ className,
111
+ )}
112
+ {...props}
113
+ >
114
+ <MoreHorizontalIcon
115
+ />
116
+ <span className="sr-only">More</span>
117
+ </span>
118
+ )
119
+ }
120
+
121
+ export {
122
+ Breadcrumb,
123
+ BreadcrumbList,
124
+ BreadcrumbItem,
125
+ BreadcrumbLink,
126
+ BreadcrumbPage,
127
+ BreadcrumbSeparator,
128
+ BreadcrumbEllipsis,
129
+ }