@major-tech/ui 0.0.0-stage → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (495) hide show
  1. package/CHANGELOG.md +101 -0
  2. package/THIRD_PARTY_NOTICES.md +27 -0
  3. package/dist/components/accordion.d.ts +33 -0
  4. package/dist/components/accordion.d.ts.map +1 -0
  5. package/dist/components/accordion.js +51 -0
  6. package/dist/components/accordion.js.map +1 -0
  7. package/dist/components/activity-chart.d.ts +26 -0
  8. package/dist/components/activity-chart.d.ts.map +1 -0
  9. package/dist/components/activity-chart.js +56 -0
  10. package/dist/components/activity-chart.js.map +1 -0
  11. package/dist/components/alert-dialog.d.ts +28 -0
  12. package/dist/components/alert-dialog.d.ts.map +1 -0
  13. package/dist/components/alert-dialog.js +51 -0
  14. package/dist/components/alert-dialog.js.map +1 -0
  15. package/dist/components/alert.d.ts +34 -0
  16. package/dist/components/alert.d.ts.map +1 -0
  17. package/dist/components/alert.js +59 -0
  18. package/dist/components/alert.js.map +1 -0
  19. package/dist/components/ask-user-question.d.ts +103 -0
  20. package/dist/components/ask-user-question.d.ts.map +1 -0
  21. package/dist/components/ask-user-question.js +401 -0
  22. package/dist/components/ask-user-question.js.map +1 -0
  23. package/dist/components/attachment-gallery.d.ts +137 -0
  24. package/dist/components/attachment-gallery.d.ts.map +1 -0
  25. package/dist/components/attachment-gallery.js +317 -0
  26. package/dist/components/attachment-gallery.js.map +1 -0
  27. package/dist/components/avatar.d.ts +37 -0
  28. package/dist/components/avatar.d.ts.map +1 -0
  29. package/dist/components/avatar.js +62 -0
  30. package/dist/components/avatar.js.map +1 -0
  31. package/dist/components/badge.d.ts +29 -0
  32. package/dist/components/badge.d.ts.map +1 -0
  33. package/dist/components/badge.js +50 -0
  34. package/dist/components/badge.js.map +1 -0
  35. package/dist/components/brand-tile.d.ts +33 -0
  36. package/dist/components/brand-tile.d.ts.map +1 -0
  37. package/dist/components/brand-tile.js +36 -0
  38. package/dist/components/brand-tile.js.map +1 -0
  39. package/dist/components/button.d.ts +51 -0
  40. package/dist/components/button.d.ts.map +1 -0
  41. package/dist/components/button.js +90 -0
  42. package/dist/components/button.js.map +1 -0
  43. package/dist/components/calendar.d.ts +18 -0
  44. package/dist/components/calendar.d.ts.map +1 -0
  45. package/dist/components/calendar.js +78 -0
  46. package/dist/components/calendar.js.map +1 -0
  47. package/dist/components/card.d.ts +18 -0
  48. package/dist/components/card.d.ts.map +1 -0
  49. package/dist/components/card.js +34 -0
  50. package/dist/components/card.js.map +1 -0
  51. package/dist/components/carousel.d.ts +48 -0
  52. package/dist/components/carousel.d.ts.map +1 -0
  53. package/dist/components/carousel.js +227 -0
  54. package/dist/components/carousel.js.map +1 -0
  55. package/dist/components/catalog-card.d.ts +29 -0
  56. package/dist/components/catalog-card.d.ts.map +1 -0
  57. package/dist/components/catalog-card.js +20 -0
  58. package/dist/components/catalog-card.js.map +1 -0
  59. package/dist/components/chart.d.ts +118 -0
  60. package/dist/components/chart.d.ts.map +1 -0
  61. package/dist/components/chart.js +209 -0
  62. package/dist/components/chart.js.map +1 -0
  63. package/dist/components/checkbox.d.ts +8 -0
  64. package/dist/components/checkbox.d.ts.map +1 -0
  65. package/dist/components/checkbox.js +14 -0
  66. package/dist/components/checkbox.js.map +1 -0
  67. package/dist/components/chip.d.ts +68 -0
  68. package/dist/components/chip.d.ts.map +1 -0
  69. package/dist/components/chip.js +100 -0
  70. package/dist/components/chip.js.map +1 -0
  71. package/dist/components/code-block.d.ts +99 -0
  72. package/dist/components/code-block.d.ts.map +1 -0
  73. package/dist/components/code-block.js +144 -0
  74. package/dist/components/code-block.js.map +1 -0
  75. package/dist/components/collapsible.d.ts +17 -0
  76. package/dist/components/collapsible.d.ts.map +1 -0
  77. package/dist/components/collapsible.js +25 -0
  78. package/dist/components/collapsible.js.map +1 -0
  79. package/dist/components/command.d.ts +51 -0
  80. package/dist/components/command.d.ts.map +1 -0
  81. package/dist/components/command.js +120 -0
  82. package/dist/components/command.js.map +1 -0
  83. package/dist/components/composer.d.ts +211 -0
  84. package/dist/components/composer.d.ts.map +1 -0
  85. package/dist/components/composer.js +605 -0
  86. package/dist/components/composer.js.map +1 -0
  87. package/dist/components/connector-request.d.ts +63 -0
  88. package/dist/components/connector-request.d.ts.map +1 -0
  89. package/dist/components/connector-request.js +57 -0
  90. package/dist/components/connector-request.js.map +1 -0
  91. package/dist/components/context-menu.d.ts +26 -0
  92. package/dist/components/context-menu.d.ts.map +1 -0
  93. package/dist/components/context-menu.js +33 -0
  94. package/dist/components/context-menu.js.map +1 -0
  95. package/dist/components/data-table.d.ts +61 -0
  96. package/dist/components/data-table.d.ts.map +1 -0
  97. package/dist/components/data-table.js +79 -0
  98. package/dist/components/data-table.js.map +1 -0
  99. package/dist/components/date-range-picker.d.ts +54 -0
  100. package/dist/components/date-range-picker.d.ts.map +1 -0
  101. package/dist/components/date-range-picker.js +451 -0
  102. package/dist/components/date-range-picker.js.map +1 -0
  103. package/dist/components/dialog.d.ts +46 -0
  104. package/dist/components/dialog.d.ts.map +1 -0
  105. package/dist/components/dialog.js +75 -0
  106. package/dist/components/dialog.js.map +1 -0
  107. package/dist/components/drawer.d.ts +85 -0
  108. package/dist/components/drawer.d.ts.map +1 -0
  109. package/dist/components/drawer.js +166 -0
  110. package/dist/components/drawer.js.map +1 -0
  111. package/dist/components/dropdown-menu.d.ts +77 -0
  112. package/dist/components/dropdown-menu.d.ts.map +1 -0
  113. package/dist/components/dropdown-menu.js +112 -0
  114. package/dist/components/dropdown-menu.js.map +1 -0
  115. package/dist/components/editor-tabs.d.ts +49 -0
  116. package/dist/components/editor-tabs.d.ts.map +1 -0
  117. package/dist/components/editor-tabs.js +157 -0
  118. package/dist/components/editor-tabs.js.map +1 -0
  119. package/dist/components/empty-state.d.ts +21 -0
  120. package/dist/components/empty-state.d.ts.map +1 -0
  121. package/dist/components/empty-state.js +14 -0
  122. package/dist/components/empty-state.js.map +1 -0
  123. package/dist/components/entity-card.d.ts +301 -0
  124. package/dist/components/entity-card.d.ts.map +1 -0
  125. package/dist/components/entity-card.js +392 -0
  126. package/dist/components/entity-card.js.map +1 -0
  127. package/dist/components/entity-row.d.ts +37 -0
  128. package/dist/components/entity-row.d.ts.map +1 -0
  129. package/dist/components/entity-row.js +65 -0
  130. package/dist/components/entity-row.js.map +1 -0
  131. package/dist/components/env-var-request.d.ts +51 -0
  132. package/dist/components/env-var-request.d.ts.map +1 -0
  133. package/dist/components/env-var-request.js +50 -0
  134. package/dist/components/env-var-request.js.map +1 -0
  135. package/dist/components/field.d.ts +30 -0
  136. package/dist/components/field.d.ts.map +1 -0
  137. package/dist/components/field.js +48 -0
  138. package/dist/components/field.js.map +1 -0
  139. package/dist/components/file-upload.d.ts +108 -0
  140. package/dist/components/file-upload.d.ts.map +1 -0
  141. package/dist/components/file-upload.js +217 -0
  142. package/dist/components/file-upload.js.map +1 -0
  143. package/dist/components/hover-card.d.ts +18 -0
  144. package/dist/components/hover-card.d.ts.map +1 -0
  145. package/dist/components/hover-card.js +84 -0
  146. package/dist/components/hover-card.js.map +1 -0
  147. package/dist/components/input-group.d.ts +29 -0
  148. package/dist/components/input-group.d.ts.map +1 -0
  149. package/dist/components/input-group.js +61 -0
  150. package/dist/components/input-group.js.map +1 -0
  151. package/dist/components/input.d.ts +9 -0
  152. package/dist/components/input.d.ts.map +1 -0
  153. package/dist/components/input.js +13 -0
  154. package/dist/components/input.js.map +1 -0
  155. package/dist/components/island.d.ts +18 -0
  156. package/dist/components/island.d.ts.map +1 -0
  157. package/dist/components/island.js +30 -0
  158. package/dist/components/island.js.map +1 -0
  159. package/dist/components/kbd.d.ts +7 -0
  160. package/dist/components/kbd.d.ts.map +1 -0
  161. package/dist/components/kbd.js +11 -0
  162. package/dist/components/kbd.js.map +1 -0
  163. package/dist/components/label.d.ts +8 -0
  164. package/dist/components/label.d.ts.map +1 -0
  165. package/dist/components/label.js +12 -0
  166. package/dist/components/label.js.map +1 -0
  167. package/dist/components/markdown.d.ts +24 -0
  168. package/dist/components/markdown.d.ts.map +1 -0
  169. package/dist/components/markdown.js +38 -0
  170. package/dist/components/markdown.js.map +1 -0
  171. package/dist/components/message.d.ts +38 -0
  172. package/dist/components/message.d.ts.map +1 -0
  173. package/dist/components/message.js +25 -0
  174. package/dist/components/message.js.map +1 -0
  175. package/dist/components/page-header.d.ts +31 -0
  176. package/dist/components/page-header.d.ts.map +1 -0
  177. package/dist/components/page-header.js +94 -0
  178. package/dist/components/page-header.js.map +1 -0
  179. package/dist/components/pagination.d.ts +22 -0
  180. package/dist/components/pagination.d.ts.map +1 -0
  181. package/dist/components/pagination.js +36 -0
  182. package/dist/components/pagination.js.map +1 -0
  183. package/dist/components/password-input.d.ts +5 -0
  184. package/dist/components/password-input.d.ts.map +1 -0
  185. package/dist/components/password-input.js +12 -0
  186. package/dist/components/password-input.js.map +1 -0
  187. package/dist/components/pepper.d.ts +92 -0
  188. package/dist/components/pepper.d.ts.map +1 -0
  189. package/dist/components/pepper.js +1279 -0
  190. package/dist/components/pepper.js.map +1 -0
  191. package/dist/components/permission-request.d.ts +53 -0
  192. package/dist/components/permission-request.d.ts.map +1 -0
  193. package/dist/components/permission-request.js +54 -0
  194. package/dist/components/permission-request.js.map +1 -0
  195. package/dist/components/popover.d.ts +42 -0
  196. package/dist/components/popover.d.ts.map +1 -0
  197. package/dist/components/popover.js +76 -0
  198. package/dist/components/popover.js.map +1 -0
  199. package/dist/components/progress.d.ts +9 -0
  200. package/dist/components/progress.d.ts.map +1 -0
  201. package/dist/components/progress.js +12 -0
  202. package/dist/components/progress.js.map +1 -0
  203. package/dist/components/progressive-blur.d.ts +31 -0
  204. package/dist/components/progressive-blur.d.ts.map +1 -0
  205. package/dist/components/progressive-blur.js +44 -0
  206. package/dist/components/progressive-blur.js.map +1 -0
  207. package/dist/components/radio-group.d.ts +8 -0
  208. package/dist/components/radio-group.d.ts.map +1 -0
  209. package/dist/components/radio-group.js +15 -0
  210. package/dist/components/radio-group.js.map +1 -0
  211. package/dist/components/request-card.d.ts +34 -0
  212. package/dist/components/request-card.d.ts.map +1 -0
  213. package/dist/components/request-card.js +50 -0
  214. package/dist/components/request-card.js.map +1 -0
  215. package/dist/components/resizable.d.ts +24 -0
  216. package/dist/components/resizable.d.ts.map +1 -0
  217. package/dist/components/resizable.js +40 -0
  218. package/dist/components/resizable.js.map +1 -0
  219. package/dist/components/responsive-overlay.d.ts +136 -0
  220. package/dist/components/responsive-overlay.d.ts.map +1 -0
  221. package/dist/components/responsive-overlay.js +302 -0
  222. package/dist/components/responsive-overlay.js.map +1 -0
  223. package/dist/components/scroll-shadows.d.ts +11 -0
  224. package/dist/components/scroll-shadows.d.ts.map +1 -0
  225. package/dist/components/scroll-shadows.js +53 -0
  226. package/dist/components/scroll-shadows.js.map +1 -0
  227. package/dist/components/search-field.d.ts +16 -0
  228. package/dist/components/search-field.d.ts.map +1 -0
  229. package/dist/components/search-field.js +50 -0
  230. package/dist/components/search-field.js.map +1 -0
  231. package/dist/components/searchable-select.d.ts +43 -0
  232. package/dist/components/searchable-select.d.ts.map +1 -0
  233. package/dist/components/searchable-select.js +39 -0
  234. package/dist/components/searchable-select.js.map +1 -0
  235. package/dist/components/select.d.ts +60 -0
  236. package/dist/components/select.d.ts.map +1 -0
  237. package/dist/components/select.js +94 -0
  238. package/dist/components/select.js.map +1 -0
  239. package/dist/components/separator.d.ts +7 -0
  240. package/dist/components/separator.d.ts.map +1 -0
  241. package/dist/components/separator.js +12 -0
  242. package/dist/components/separator.js.map +1 -0
  243. package/dist/components/settings-section.d.ts +41 -0
  244. package/dist/components/settings-section.d.ts.map +1 -0
  245. package/dist/components/settings-section.js +50 -0
  246. package/dist/components/settings-section.js.map +1 -0
  247. package/dist/components/sidebar-item.d.ts +41 -0
  248. package/dist/components/sidebar-item.d.ts.map +1 -0
  249. package/dist/components/sidebar-item.js +59 -0
  250. package/dist/components/sidebar-item.js.map +1 -0
  251. package/dist/components/skeleton.d.ts +7 -0
  252. package/dist/components/skeleton.d.ts.map +1 -0
  253. package/dist/components/skeleton.js +11 -0
  254. package/dist/components/skeleton.js.map +1 -0
  255. package/dist/components/slider.d.ts +10 -0
  256. package/dist/components/slider.d.ts.map +1 -0
  257. package/dist/components/slider.js +36 -0
  258. package/dist/components/slider.js.map +1 -0
  259. package/dist/components/sonner.d.ts +8 -0
  260. package/dist/components/sonner.d.ts.map +1 -0
  261. package/dist/components/sonner.js +21 -0
  262. package/dist/components/sonner.js.map +1 -0
  263. package/dist/components/spinner.d.ts +7 -0
  264. package/dist/components/spinner.d.ts.map +1 -0
  265. package/dist/components/spinner.js +12 -0
  266. package/dist/components/spinner.js.map +1 -0
  267. package/dist/components/stat-strip.d.ts +20 -0
  268. package/dist/components/stat-strip.d.ts.map +1 -0
  269. package/dist/components/stat-strip.js +11 -0
  270. package/dist/components/stat-strip.js.map +1 -0
  271. package/dist/components/status-dot.d.ts +25 -0
  272. package/dist/components/status-dot.d.ts.map +1 -0
  273. package/dist/components/status-dot.js +31 -0
  274. package/dist/components/status-dot.js.map +1 -0
  275. package/dist/components/subagent-run.d.ts +27 -0
  276. package/dist/components/subagent-run.d.ts.map +1 -0
  277. package/dist/components/subagent-run.js +38 -0
  278. package/dist/components/subagent-run.js.map +1 -0
  279. package/dist/components/switch.d.ts +8 -0
  280. package/dist/components/switch.d.ts.map +1 -0
  281. package/dist/components/switch.js +13 -0
  282. package/dist/components/switch.js.map +1 -0
  283. package/dist/components/system-notice.d.ts +34 -0
  284. package/dist/components/system-notice.d.ts.map +1 -0
  285. package/dist/components/system-notice.js +52 -0
  286. package/dist/components/system-notice.js.map +1 -0
  287. package/dist/components/table.d.ts +27 -0
  288. package/dist/components/table.d.ts.map +1 -0
  289. package/dist/components/table.js +37 -0
  290. package/dist/components/table.js.map +1 -0
  291. package/dist/components/tabs.d.ts +40 -0
  292. package/dist/components/tabs.d.ts.map +1 -0
  293. package/dist/components/tabs.js +52 -0
  294. package/dist/components/tabs.js.map +1 -0
  295. package/dist/components/textarea.d.ts +5 -0
  296. package/dist/components/textarea.d.ts.map +1 -0
  297. package/dist/components/textarea.js +9 -0
  298. package/dist/components/textarea.js.map +1 -0
  299. package/dist/components/thinking-indicator.d.ts +21 -0
  300. package/dist/components/thinking-indicator.d.ts.map +1 -0
  301. package/dist/components/thinking-indicator.js +136 -0
  302. package/dist/components/thinking-indicator.js.map +1 -0
  303. package/dist/components/thread-status.d.ts +25 -0
  304. package/dist/components/thread-status.d.ts.map +1 -0
  305. package/dist/components/thread-status.js +41 -0
  306. package/dist/components/thread-status.js.map +1 -0
  307. package/dist/components/todo-list.d.ts +52 -0
  308. package/dist/components/todo-list.d.ts.map +1 -0
  309. package/dist/components/todo-list.js +137 -0
  310. package/dist/components/todo-list.js.map +1 -0
  311. package/dist/components/toggle-group.d.ts +17 -0
  312. package/dist/components/toggle-group.d.ts.map +1 -0
  313. package/dist/components/toggle-group.js +26 -0
  314. package/dist/components/toggle-group.js.map +1 -0
  315. package/dist/components/toggle.d.ts +27 -0
  316. package/dist/components/toggle.d.ts.map +1 -0
  317. package/dist/components/toggle.js +44 -0
  318. package/dist/components/toggle.js.map +1 -0
  319. package/dist/components/tool-call.d.ts +60 -0
  320. package/dist/components/tool-call.d.ts.map +1 -0
  321. package/dist/components/tool-call.js +94 -0
  322. package/dist/components/tool-call.js.map +1 -0
  323. package/dist/components/tool-result.d.ts +127 -0
  324. package/dist/components/tool-result.d.ts.map +1 -0
  325. package/dist/components/tool-result.js +155 -0
  326. package/dist/components/tool-result.js.map +1 -0
  327. package/dist/components/tooltip.d.ts +18 -0
  328. package/dist/components/tooltip.d.ts.map +1 -0
  329. package/dist/components/tooltip.js +38 -0
  330. package/dist/components/tooltip.js.map +1 -0
  331. package/dist/components/trace.d.ts +38 -0
  332. package/dist/components/trace.d.ts.map +1 -0
  333. package/dist/components/trace.js +52 -0
  334. package/dist/components/trace.js.map +1 -0
  335. package/dist/components/turn-summary.d.ts +17 -0
  336. package/dist/components/turn-summary.d.ts.map +1 -0
  337. package/dist/components/turn-summary.js +19 -0
  338. package/dist/components/turn-summary.js.map +1 -0
  339. package/dist/components/usage-meter.d.ts +16 -0
  340. package/dist/components/usage-meter.d.ts.map +1 -0
  341. package/dist/components/usage-meter.js +10 -0
  342. package/dist/components/usage-meter.js.map +1 -0
  343. package/dist/components/view-switcher.d.ts +25 -0
  344. package/dist/components/view-switcher.d.ts.map +1 -0
  345. package/dist/components/view-switcher.js +196 -0
  346. package/dist/components/view-switcher.js.map +1 -0
  347. package/dist/docs/components/accordion.md +151 -0
  348. package/dist/docs/components/activity-chart.md +104 -0
  349. package/dist/docs/components/alert-dialog.md +216 -0
  350. package/dist/docs/components/alert.md +203 -0
  351. package/dist/docs/components/ask-user-question.md +429 -0
  352. package/dist/docs/components/attachment-gallery.md +377 -0
  353. package/dist/docs/components/avatar.md +197 -0
  354. package/dist/docs/components/badge.md +162 -0
  355. package/dist/docs/components/brand-tile.md +138 -0
  356. package/dist/docs/components/button.md +392 -0
  357. package/dist/docs/components/calendar.md +113 -0
  358. package/dist/docs/components/card.md +157 -0
  359. package/dist/docs/components/carousel.md +144 -0
  360. package/dist/docs/components/catalog-card.md +136 -0
  361. package/dist/docs/components/chart.md +608 -0
  362. package/dist/docs/components/checkbox.md +164 -0
  363. package/dist/docs/components/chip.md +411 -0
  364. package/dist/docs/components/code-block.md +389 -0
  365. package/dist/docs/components/collapsible.md +93 -0
  366. package/dist/docs/components/command.md +276 -0
  367. package/dist/docs/components/composer.md +1092 -0
  368. package/dist/docs/components/connector-request.md +497 -0
  369. package/dist/docs/components/context-menu.md +127 -0
  370. package/dist/docs/components/data-table.md +462 -0
  371. package/dist/docs/components/date-range-picker.md +425 -0
  372. package/dist/docs/components/dialog.md +263 -0
  373. package/dist/docs/components/drawer.md +505 -0
  374. package/dist/docs/components/dropdown-menu.md +336 -0
  375. package/dist/docs/components/editor-tabs.md +283 -0
  376. package/dist/docs/components/empty-state.md +134 -0
  377. package/dist/docs/components/entity-card.md +640 -0
  378. package/dist/docs/components/entity-row.md +291 -0
  379. package/dist/docs/components/env-var-request.md +223 -0
  380. package/dist/docs/components/field.md +272 -0
  381. package/dist/docs/components/file-upload.md +255 -0
  382. package/dist/docs/components/hover-card.md +335 -0
  383. package/dist/docs/components/input-group.md +134 -0
  384. package/dist/docs/components/input.md +97 -0
  385. package/dist/docs/components/island.md +97 -0
  386. package/dist/docs/components/kbd.md +91 -0
  387. package/dist/docs/components/markdown.md +180 -0
  388. package/dist/docs/components/message.md +336 -0
  389. package/dist/docs/components/page-header.md +203 -0
  390. package/dist/docs/components/pagination.md +211 -0
  391. package/dist/docs/components/password-input.md +68 -0
  392. package/dist/docs/components/pepper.md +238 -0
  393. package/dist/docs/components/permission-request.md +265 -0
  394. package/dist/docs/components/popover.md +206 -0
  395. package/dist/docs/components/progress.md +142 -0
  396. package/dist/docs/components/progressive-blur.md +195 -0
  397. package/dist/docs/components/radio-group.md +129 -0
  398. package/dist/docs/components/request-card.md +305 -0
  399. package/dist/docs/components/resizable.md +318 -0
  400. package/dist/docs/components/responsive-overlay.md +449 -0
  401. package/dist/docs/components/scroll-shadows.md +161 -0
  402. package/dist/docs/components/search-field.md +86 -0
  403. package/dist/docs/components/searchable-select.md +144 -0
  404. package/dist/docs/components/select.md +331 -0
  405. package/dist/docs/components/separator.md +80 -0
  406. package/dist/docs/components/settings-section.md +246 -0
  407. package/dist/docs/components/sidebar-item.md +307 -0
  408. package/dist/docs/components/skeleton.md +107 -0
  409. package/dist/docs/components/slider.md +171 -0
  410. package/dist/docs/components/sonner.md +122 -0
  411. package/dist/docs/components/spinner.md +112 -0
  412. package/dist/docs/components/stat-strip.md +85 -0
  413. package/dist/docs/components/status-dot.md +190 -0
  414. package/dist/docs/components/subagent-run.md +196 -0
  415. package/dist/docs/components/switch.md +91 -0
  416. package/dist/docs/components/system-notice.md +144 -0
  417. package/dist/docs/components/table.md +201 -0
  418. package/dist/docs/components/tabs.md +233 -0
  419. package/dist/docs/components/textarea.md +89 -0
  420. package/dist/docs/components/thinking-indicator.md +164 -0
  421. package/dist/docs/components/thread-status.md +143 -0
  422. package/dist/docs/components/todo-list.md +225 -0
  423. package/dist/docs/components/toggle-group.md +117 -0
  424. package/dist/docs/components/toggle.md +132 -0
  425. package/dist/docs/components/tool-call.md +237 -0
  426. package/dist/docs/components/tool-result.md +418 -0
  427. package/dist/docs/components/tooltip.md +136 -0
  428. package/dist/docs/components/trace.md +319 -0
  429. package/dist/docs/components/turn-summary.md +218 -0
  430. package/dist/docs/components/usage-meter.md +69 -0
  431. package/dist/docs/components/view-switcher.md +193 -0
  432. package/dist/docs/foundations/colors.md +83 -0
  433. package/dist/docs/foundations/elevation.md +19 -0
  434. package/dist/docs/foundations/iconography.md +34 -0
  435. package/dist/docs/foundations/layout.md +42 -0
  436. package/dist/docs/foundations/logo.md +111 -0
  437. package/dist/docs/foundations/motion.md +91 -0
  438. package/dist/docs/foundations/radius.md +13 -0
  439. package/dist/docs/foundations/spacing.md +23 -0
  440. package/dist/docs/foundations/typography.md +42 -0
  441. package/dist/docs/getting-started/installation.md +116 -0
  442. package/dist/docs/getting-started/releases.md +59 -0
  443. package/dist/docs/getting-started/theming.md +58 -0
  444. package/dist/docs/guidelines/accessibility.md +28 -0
  445. package/dist/docs/guidelines/content.md +36 -0
  446. package/dist/docs/guidelines/forms.md +36 -0
  447. package/dist/docs/guidelines/principles.md +30 -0
  448. package/dist/docs/hooks/use-is-mobile.md +134 -0
  449. package/dist/docs/index.md +182 -0
  450. package/dist/docs/overview.md +35 -0
  451. package/dist/docs/patterns/chat.md +477 -0
  452. package/dist/docs/patterns/index.md +13 -0
  453. package/dist/docs/patterns/login.md +311 -0
  454. package/dist/docs/patterns/share.md +415 -0
  455. package/dist/hooks/use-is-mobile.d.ts +9 -0
  456. package/dist/hooks/use-is-mobile.d.ts.map +1 -0
  457. package/dist/hooks/use-is-mobile.js +26 -0
  458. package/dist/hooks/use-is-mobile.js.map +1 -0
  459. package/dist/lib/cn.d.ts +4 -0
  460. package/dist/lib/cn.d.ts.map +1 -0
  461. package/dist/lib/cn.js +31 -0
  462. package/dist/lib/cn.js.map +1 -0
  463. package/dist/lib/code-language.d.ts +8 -0
  464. package/dist/lib/code-language.d.ts.map +1 -0
  465. package/dist/lib/code-language.js +48 -0
  466. package/dist/lib/code-language.js.map +1 -0
  467. package/dist/lib/date-range.d.ts +122 -0
  468. package/dist/lib/date-range.d.ts.map +1 -0
  469. package/dist/lib/date-range.js +281 -0
  470. package/dist/lib/date-range.js.map +1 -0
  471. package/dist/lib/major-tokens.d.ts +40 -0
  472. package/dist/lib/major-tokens.d.ts.map +1 -0
  473. package/dist/lib/major-tokens.js +602 -0
  474. package/dist/lib/major-tokens.js.map +1 -0
  475. package/dist/lib/markdown.d.ts +25 -0
  476. package/dist/lib/markdown.d.ts.map +1 -0
  477. package/dist/lib/markdown.js +87 -0
  478. package/dist/lib/markdown.js.map +1 -0
  479. package/dist/lib/overlay-portal-branch.d.ts +6 -0
  480. package/dist/lib/overlay-portal-branch.d.ts.map +1 -0
  481. package/dist/lib/overlay-portal-branch.js +15 -0
  482. package/dist/lib/overlay-portal-branch.js.map +1 -0
  483. package/dist/lib/pepper-matcap.d.ts +2 -0
  484. package/dist/lib/pepper-matcap.d.ts.map +1 -0
  485. package/dist/lib/pepper-matcap.js +4 -0
  486. package/dist/lib/pepper-matcap.js.map +1 -0
  487. package/dist/lib/scroll-fade.d.ts +28 -0
  488. package/dist/lib/scroll-fade.d.ts.map +1 -0
  489. package/dist/lib/scroll-fade.js +57 -0
  490. package/dist/lib/scroll-fade.js.map +1 -0
  491. package/dist/tailwind.css +7 -0
  492. package/dist/theme.css +428 -0
  493. package/package.json +145 -3
  494. package/tokens.json +841 -0
  495. package/README.md +0 -3
@@ -0,0 +1,238 @@
1
+ ---
2
+ name: Pepper
3
+ slug: pepper
4
+ description: "Major's assistant character in 3D: a glowing glass drop with moods and reactions."
5
+ group: AI
6
+ layer: composed
7
+ status: beta
8
+ since: 0.4.0
9
+ import: import { Pepper, PEPPER_MOODS, PEPPER_REACTIONS, PEPPER_SIZES, PEPPER_THEMES, PEPPER_GLOW_DIRECTIONS } from "@major-tech/ui/pepper";
10
+ requires: three
11
+ source: packages/ui/src/components/pepper.tsx
12
+ ---
13
+
14
+ # Pepper
15
+
16
+ > **Install `three` too.** Pepper doesn't work without it, and the package doesn't install it for you: `pnpm add three` (0.182 or later).
17
+
18
+ ## Usage
19
+
20
+ ### Moods and reactions
21
+
22
+ Pepper is Major's assistant: a glass drop that glows from below, with two pill eyes. He floats, breathes, blinks and glances around on his own. A mood is his resting face; a reaction plays once on top of it and returns to it. Drag him to turn him, click him to poke him.
23
+
24
+ Example: `reactions`
25
+
26
+ ```tsx
27
+ "use client";
28
+
29
+ import { useRef, useState } from "react";
30
+ import { Button } from "@major-tech/ui/button";
31
+ import { PEPPER_MOODS, PEPPER_REACTIONS, PEPPER_SIZES, Pepper, type PepperHandle, type PepperMood } from "@major-tech/ui/pepper";
32
+ import { ToggleGroup, ToggleGroupItem } from "@major-tech/ui/toggle-group";
33
+
34
+ const MOOD_LABELS: Record<PepperMood, string> = {
35
+ [PEPPER_MOODS.NEUTRAL]: "Neutral",
36
+ [PEPPER_MOODS.UNIMPRESSED]: "Unimpressed",
37
+ [PEPPER_MOODS.SPICY]: "Spicy",
38
+ [PEPPER_MOODS.CONCERNED]: "Concerned",
39
+ };
40
+
41
+ const REACTION_BUTTONS = [
42
+ { reaction: PEPPER_REACTIONS.HELLO, label: "Hello" },
43
+ { reaction: PEPPER_REACTIONS.QUESTION, label: "I have a question" },
44
+ { reaction: PEPPER_REACTIONS.LOOK, label: "Look at this" },
45
+ { reaction: PEPPER_REACTIONS.THINK, label: "Thinking" },
46
+ { reaction: PEPPER_REACTIONS.AGREE, label: "Agree" },
47
+ { reaction: PEPPER_REACTIONS.DISAGREE, label: "Disagree" },
48
+ { reaction: PEPPER_REACTIONS.WAITING, label: "Are you still here?" },
49
+ { reaction: PEPPER_REACTIONS.BACKFLIP, label: "Backflip" },
50
+ ];
51
+
52
+ export default function PepperReactions() {
53
+ const pepperRef = useRef<PepperHandle>(null);
54
+ const [mood, setMood] = useState<PepperMood>(PEPPER_MOODS.NEUTRAL);
55
+
56
+ const handleMoodChange = (value: string[]) => {
57
+ const [nextMood] = value;
58
+
59
+ if (nextMood) {
60
+ setMood(nextMood as PepperMood);
61
+ }
62
+ };
63
+
64
+ const handleEntranceClick = () => pepperRef.current?.playEntrance();
65
+
66
+ return (
67
+ <div className="flex flex-wrap items-center gap-space-24">
68
+ <Pepper ref={pepperRef} mood={mood} size={PEPPER_SIZES.LG} />
69
+ <div className="flex max-w-90 flex-col gap-space-16">
70
+ <div className="flex flex-col gap-space-8">
71
+ <span className="text-small text-muted">Mood</span>
72
+ <ToggleGroup value={[mood]} onValueChange={handleMoodChange} aria-label="Mood">
73
+ {Object.values(PEPPER_MOODS).map((value) => (
74
+ <ToggleGroupItem key={value} value={value}>
75
+ {MOOD_LABELS[value]}
76
+ </ToggleGroupItem>
77
+ ))}
78
+ </ToggleGroup>
79
+ </div>
80
+ <div className="flex flex-col gap-space-8">
81
+ <span className="text-small text-muted">Reactions</span>
82
+ <div className="flex flex-wrap gap-space-8">
83
+ {REACTION_BUTTONS.map(({ reaction, label }) => (
84
+ <Button key={reaction} variant="outline" size="sm" onClick={() => pepperRef.current?.play(reaction)}>
85
+ {label}
86
+ </Button>
87
+ ))}
88
+ <Button variant="ghost" size="sm" onClick={handleEntranceClick}>
89
+ Play entrance
90
+ </Button>
91
+ </div>
92
+ </div>
93
+ </div>
94
+ </div>
95
+ );
96
+ }
97
+ ```
98
+
99
+ - **The entrance** plays when he first appears: he pops up from the floor, spins in, his eyes boot up and he says hello. Turn it off with `entrance={false}` where he is already on screen.
100
+ - **Are you still here?** After 10 seconds with no input on the page he leans in and taps on the glass, then again every 15 seconds. Turn it off with `idleCheck={false}`.
101
+ - Reactions are played from a ref: `pepperRef.current.play("agree")`. A new reaction replaces one that is still playing.
102
+
103
+ ### Moods
104
+
105
+ Neutral is calm and looks at you. Unimpressed half-closes his eyes. Spicy slants them, warms his contour and makes him tremble now and then. Concerned raises his brows and tilts his head.
106
+
107
+ Example: `moods`
108
+
109
+ ```tsx
110
+ "use client";
111
+
112
+ import { PEPPER_MOODS, PEPPER_SIZES, Pepper } from "@major-tech/ui/pepper";
113
+
114
+ const MOODS = [
115
+ { mood: PEPPER_MOODS.NEUTRAL, label: "Neutral" },
116
+ { mood: PEPPER_MOODS.UNIMPRESSED, label: "Unimpressed" },
117
+ { mood: PEPPER_MOODS.SPICY, label: "Spicy" },
118
+ { mood: PEPPER_MOODS.CONCERNED, label: "Concerned" },
119
+ ];
120
+
121
+ export default function PepperMoods() {
122
+ return (
123
+ <div className="flex flex-wrap items-end gap-space-16">
124
+ {MOODS.map(({ mood, label }) => (
125
+ <div key={mood} className="flex flex-col items-center gap-space-4">
126
+ <Pepper mood={mood} size={PEPPER_SIZES.SM} entrance={false} idleCheck={false} aria-label={`Pepper, ${label.toLowerCase()}`} />
127
+ <span className="text-small text-muted">{label}</span>
128
+ </div>
129
+ ))}
130
+ </div>
131
+ );
132
+ }
133
+ ```
134
+
135
+ ### Sizes
136
+
137
+ sm 152 × 192, md 228 × 288 (the default), lg 304 × 384. The box is taller than Pepper: its top part is room for jumps, the backflip and the glyphs beside him (?, !, …, a check, a cross). Keep that room clear rather than cropping it.
138
+
139
+ Example: `sizes`
140
+
141
+ ```tsx
142
+ "use client";
143
+
144
+ import { PEPPER_SIZES, Pepper } from "@major-tech/ui/pepper";
145
+
146
+ export default function PepperSizes() {
147
+ return (
148
+ <div className="flex flex-wrap items-end gap-space-16">
149
+ {Object.values(PEPPER_SIZES).map((size) => (
150
+ <div key={size} className="flex flex-col items-center gap-space-4">
151
+ <Pepper size={size} entrance={false} idleCheck={false} />
152
+ <span className="text-small text-muted">{size}</span>
153
+ </div>
154
+ ))}
155
+ </div>
156
+ );
157
+ }
158
+ ```
159
+
160
+ ### Following the cursor
161
+
162
+ With `followCursor` his eyes follow the pointer anywhere on the page, and his body turns after them, a little slower. Use it where Pepper is the focus, such as onboarding; elsewhere he looks at the person.
163
+
164
+ Example: `follow-cursor`
165
+
166
+ ```tsx
167
+ import { Pepper } from "@major-tech/ui/pepper";
168
+
169
+ export default function PepperFollowCursor() {
170
+ return <Pepper followCursor entrance={false} idleCheck={false} />;
171
+ }
172
+ ```
173
+
174
+ ### Light and dark
175
+
176
+ Pepper follows the theme of the page around him, like every token: glowing green glass with bloom in dark, silver glass in light. Switch an example's preview to see both. `theme` fixes one material where the page doesn't decide it.
177
+
178
+ ### Guidelines
179
+
180
+ Do:
181
+
182
+ - One Pepper on screen at a time: he is one character who moves to wherever he is needed.
183
+ - Play a reaction in answer to something the person did or something Pepper has to say.
184
+ - Give him a calm background: a panel, the page, a dialog.
185
+
186
+ Don't:
187
+
188
+ - Several Peppers side by side in a product (this page shows several only to compare).
189
+ - Reactions on a loop or on a timer: he would feel restless.
190
+ - Recolour, crop or stretch him.
191
+ - Use him as a loading spinner.
192
+
193
+ ## API
194
+
195
+ ```bash
196
+ yarn add three
197
+ # or: pnpm add three
198
+ ```
199
+
200
+ ```tsx
201
+ import { Pepper, PEPPER_MOODS, PEPPER_REACTIONS, PEPPER_SIZES, PEPPER_THEMES, PEPPER_GLOW_DIRECTIONS } from "@major-tech/ui/pepper";
202
+ ```
203
+
204
+ ### `<Pepper />`
205
+
206
+ Also accepts every `<div>` attribute.
207
+
208
+ | Prop | Type | Default | Description |
209
+ | --- | --- | --- | --- |
210
+ | `mood` | `"neutral" \| "unimpressed" \| "spicy" \| "concerned"` | `"neutral"` | His resting expression. Use `PEPPER_MOODS`. |
211
+ | `size` | `"sm" \| "md" \| "lg"` | `"md"` | 152 × 192, 228 × 288 or 304 × 384. Use `PEPPER_SIZES`. |
212
+ | `theme` | `"auto" \| "dark" \| "light"` | `"auto"` | `auto` follows the page's theme; `dark` and `light` fix the material. Use `PEPPER_THEMES`. |
213
+ | `interactive` | `boolean` | `true` | Drag to turn him, click to poke him. |
214
+ | `followCursor` | `boolean` | `false` | His eyes follow the pointer and his body turns after them. |
215
+ | `idleCheck` | `boolean` | `true` | “Are you still here?” after 10 s with no input, then every 15 s. |
216
+ | `entrance` | `boolean` | `true` | Pops up from the floor and says hello when he first appears. |
217
+ | `shadow` | `boolean` | `true` | The soft ground shadow under him. |
218
+ | `glowFrom` | `"below" \| "above"` | `"below"` | Which side of him glows. Use `PEPPER_GLOW_DIRECTIONS`. |
219
+ | `ref` | `Ref<PepperHandle>` | — | Plays reactions and the entrance. |
220
+ | `aria-label` | `string` | `"Pepper"` | His name for screen readers. |
221
+
222
+ ### `PepperHandle`
223
+
224
+ | Prop | Type | Default | Description |
225
+ | --- | --- | --- | --- |
226
+ | `play` | `(reaction: PepperReaction) => void` | — | hello, question, look, think, agree, disagree, waiting, backflip or poke. Use `PEPPER_REACTIONS`. |
227
+ | `playEntrance` | `() => void` | — | Plays the entrance again. |
228
+
229
+ ### Loading
230
+
231
+ Pepper is drawn with three.js, which the product installs (see above). It loads the first time he renders, so pages without Pepper never download it. Until it has loaded, and where WebGL isn't available, the box stays empty.
232
+
233
+ ### Accessibility
234
+
235
+ - He is one image to screen readers (`role="img"`) named by `aria-label`. Whatever he says goes in text next to him, never only in his face.
236
+ - With reduced motion he holds still: no entrance, float, blinks, glances or hair bounce. Moods and reactions still change his face.
237
+ - Poking and turning him are play, never the only way to do something.
238
+ - He only animates while on screen and while the tab is visible.
@@ -0,0 +1,265 @@
1
+ ---
2
+ name: PermissionRequest
3
+ slug: permission-request
4
+ description: "Major asks before it runs a tool that needs a yes: the tool, why, what it will run, and Approve, Deny or Always approve; then the decision as one line."
5
+ group: AI
6
+ layer: composed
7
+ status: beta
8
+ since: 0.4.0
9
+ import: import { PermissionRequest, PermissionDecision, PERMISSION_DECISIONS } from "@major-tech/ui/permission-request";
10
+ source: packages/ui/src/components/permission-request.tsx
11
+ ---
12
+
13
+ # PermissionRequest
14
+
15
+ ## Usage
16
+
17
+ ### Before a tool runs
18
+
19
+ When a tool needs a yes, Major stops and asks in its reply: the tool's name, why it wants to run it, and what it will run. Deny or Approve; once decided, the card gives way to the decision.
20
+
21
+ Example: `what-it-runs`
22
+
23
+ ```tsx
24
+ "use client";
25
+
26
+ import { useState } from "react";
27
+ import { PERMISSION_DECISIONS, PermissionDecision, PermissionRequest } from "@major-tech/ui/permission-request";
28
+
29
+ type Decision = (typeof PERMISSION_DECISIONS)[keyof typeof PERMISSION_DECISIONS];
30
+
31
+ const MIGRATION = `CREATE TABLE users (
32
+ id SERIAL PRIMARY KEY,
33
+ name TEXT NOT NULL,
34
+ email TEXT UNIQUE NOT NULL
35
+ );`;
36
+
37
+ const SLACK_ARGS = { channel: "#deploys", text: "Joke archive v8 is live." };
38
+
39
+ export default function PermissionRequestWhatItRuns() {
40
+ const [migrationDecision, setMigrationDecision] = useState<Decision | null>(null);
41
+ const [slackDecision, setSlackDecision] = useState<Decision | null>(null);
42
+
43
+ return (
44
+ <div className="flex w-full flex-col items-start gap-space-24">
45
+ {migrationDecision ? (
46
+ <PermissionDecision decision={migrationDecision} description="Add users table" />
47
+ ) : (
48
+ <PermissionRequest
49
+ toolName="Run migration"
50
+ reason="Add users table"
51
+ code={MIGRATION}
52
+ language="sql"
53
+ onApprove={() => setMigrationDecision(PERMISSION_DECISIONS.APPROVED)}
54
+ onDeny={() => setMigrationDecision(PERMISSION_DECISIONS.DENIED)}
55
+ />
56
+ )}
57
+ {slackDecision ? (
58
+ <PermissionDecision decision={slackDecision} description="Tell the team the deploy finished" />
59
+ ) : (
60
+ <PermissionRequest
61
+ toolName="Send Slack message"
62
+ reason="Tell the team the deploy finished"
63
+ args={SLACK_ARGS}
64
+ onApprove={() => setSlackDecision(PERMISSION_DECISIONS.APPROVED)}
65
+ onDeny={() => setSlackDecision(PERMISSION_DECISIONS.DENIED)}
66
+ />
67
+ )}
68
+ </div>
69
+ );
70
+ }
71
+ ```
72
+
73
+ - A [RequestCard](request-card.md) with the ShieldQuestionMark kicker “Permission request”; the tool’s display name is the title, the reason follows “Reason:”.
74
+ - When the call runs code (a query, a migration, a command), the card widens to 480px and shows it in a wrapped CodeBlock that scrolls past 192px.
75
+ - Otherwise its arguments wait behind “Show details” as JSON, which opens with a height animation.
76
+ - The code takes its language's colours: `language` names it (sql for a query or a migration, graphql, json); the arguments are always JSON. The product knows the language from the tool (the web's `detectToolCode`).
77
+
78
+ ### A warning
79
+
80
+ A tool that costs more than it looks gets a warning Alert under the reason, separate from it: the reason is Major's, the warning is the product's.
81
+
82
+ Example: `warning`
83
+
84
+ ```tsx
85
+ "use client";
86
+
87
+ import { useState } from "react";
88
+ import { PERMISSION_DECISIONS, PermissionDecision, PermissionRequest } from "@major-tech/ui/permission-request";
89
+
90
+ type Decision = (typeof PERMISSION_DECISIONS)[keyof typeof PERMISSION_DECISIONS];
91
+
92
+ const REASON = "Research every competitor in parallel";
93
+
94
+ export default function PermissionRequestWarning() {
95
+ const [decision, setDecision] = useState<Decision | null>(null);
96
+
97
+ if (decision) {
98
+ return <PermissionDecision decision={decision} description={REASON} />;
99
+ }
100
+
101
+ return (
102
+ <PermissionRequest
103
+ toolName="Workflow"
104
+ reason={REASON}
105
+ warning="Workflows run many agents in parallel and can lead to significant token spend."
106
+ onApprove={() => setDecision(PERMISSION_DECISIONS.APPROVED)}
107
+ onDeny={() => setDecision(PERMISSION_DECISIONS.DENIED)}
108
+ />
109
+ );
110
+ }
111
+ ```
112
+
113
+ ### Always approve
114
+
115
+ Where the product can save a rule for the call (a connector's tool, an app's endpoint), a quiet third action approves it and keeps approving it. It sits at the left, apart from Deny and Approve.
116
+
117
+ Example: `always-approve`
118
+
119
+ ```tsx
120
+ "use client";
121
+
122
+ import { useState } from "react";
123
+ import { PERMISSION_DECISIONS, PermissionDecision, PermissionRequest } from "@major-tech/ui/permission-request";
124
+
125
+ type Decision = (typeof PERMISSION_DECISIONS)[keyof typeof PERMISSION_DECISIONS];
126
+
127
+ const QUERY = "SELECT id, name FROM customers WHERE churned_at IS NULL LIMIT 50;";
128
+
129
+ /** On an agent the rule applies to everyone who runs it; in a person's own chat, to their chats only. */
130
+ const SCOPE_LABELS = { agent: "Approve for Everyone", own: "Always approve" } as const;
131
+
132
+ type Scope = keyof typeof SCOPE_LABELS;
133
+
134
+ function QueryRequest({ scope }: { scope: Scope }) {
135
+ const [decision, setDecision] = useState<Decision | null>(null);
136
+
137
+ if (decision) {
138
+ return <PermissionDecision decision={decision} />;
139
+ }
140
+
141
+ return (
142
+ <PermissionRequest
143
+ toolName="PostgreSQL query"
144
+ code={QUERY}
145
+ language="sql"
146
+ alwaysApproveLabel={SCOPE_LABELS[scope]}
147
+ onAlwaysApprove={() => setDecision(PERMISSION_DECISIONS.APPROVED)}
148
+ onApprove={() => setDecision(PERMISSION_DECISIONS.APPROVED)}
149
+ onDeny={() => setDecision(PERMISSION_DECISIONS.DENIED)}
150
+ />
151
+ );
152
+ }
153
+
154
+ export default function PermissionRequestAlwaysApprove() {
155
+ return (
156
+ <div className="flex w-full flex-col items-start gap-space-24">
157
+ <QueryRequest scope="agent" />
158
+ <QueryRequest scope="own" />
159
+ </div>
160
+ );
161
+ }
162
+ ```
163
+
164
+ - The label says who the rule applies to: “Approve for Everyone” on an agent, where it applies to everyone who runs it; “Always approve” in a person's own chats.
165
+ - Deny is always one-off: there's no “always deny”.
166
+
167
+ ### The decision
168
+
169
+ Once decided, one 12px muted line under the call it resolves: a success check or a danger cross and who decided, with the call's reason and any feedback in faint under it.
170
+
171
+ Example: `decisions`
172
+
173
+ ```tsx
174
+ "use client";
175
+
176
+ import { PERMISSION_DECISIONS, PermissionDecision } from "@major-tech/ui/permission-request";
177
+
178
+ export default function PermissionRequestDecisions() {
179
+ return (
180
+ <div className="flex w-full flex-col gap-space-12">
181
+ <PermissionDecision decision={PERMISSION_DECISIONS.APPROVED} approverName="Ana" />
182
+ <PermissionDecision
183
+ decision={PERMISSION_DECISIONS.APPROVED}
184
+ description="Reinstall dependencies after the lockfile changed"
185
+ />
186
+ <PermissionDecision
187
+ decision={PERMISSION_DECISIONS.DENIED}
188
+ description="Drop the staging customers table"
189
+ feedback="Use a soft delete instead"
190
+ />
191
+ </div>
192
+ );
193
+ }
194
+ ```
195
+
196
+ - It names no tool: the call is right above it.
197
+ - “Approved by Ana” when someone else decided, “Approved” when it was you.
198
+ - Feedback only follows a denial, quoted in italics.
199
+
200
+ ### Guidelines
201
+
202
+ Do:
203
+
204
+ - Title it with the tool's display name: “Run migration”, not run_migration.
205
+ - Give a reason in a few words: what the call is for.
206
+ - Show exactly what will run when it's code.
207
+
208
+ Don't:
209
+
210
+ - Ask for calls that can't change anything: read-only tools run without a yes.
211
+ - Offer Always approve where no rule can be saved.
212
+ - Put the warning in the reason, or the reason in the warning.
213
+
214
+ ## API
215
+
216
+ ```tsx
217
+ import { PermissionRequest, PermissionDecision, PERMISSION_DECISIONS } from "@major-tech/ui/permission-request";
218
+ ```
219
+
220
+ ### `<PermissionRequest />`
221
+
222
+ A RequestCard: also accepts its `<div>` attributes. `aria-label` defaults to “Permission request”.
223
+
224
+ | Prop | Type | Default | Description |
225
+ | --- | --- | --- | --- |
226
+ | `toolName`* | `string` | — | The tool's display name, the card's title. |
227
+ | `reason` | `ReactNode` | — | Why Major wants to run it, after “Reason:”. |
228
+ | `warning` | `ReactNode` | — | What to know before approving, in a warning Alert. |
229
+ | `code` | `string` | — | What it will run, highlighted; the card widens to 480px. |
230
+ | `language` | `string` | `"text"` | The Prism language of code: “sql”, “graphql”, “json”. Plain text by default. |
231
+ | `args` | `Record<string, unknown>` | — | The call's arguments, as JSON behind “Show details”. Shown only when there's no code. |
232
+ | `onApprove`* | `() => void` | — | Approve. |
233
+ | `onDeny`* | `() => void` | — | Deny. |
234
+ | `onAlwaysApprove` | `() => void` | — | Approve and save a rule; leave it out where none can be saved. |
235
+ | `alwaysApproveLabel` | `string` | `"Always approve"` | “Approve for Everyone” for a rule on an agent. |
236
+ | `isSubmitting` | `boolean` | `false` | The decision is on its way: every action waits, so a second click can't decide twice. |
237
+
238
+ `*` marks a required prop.
239
+
240
+ ### `<PermissionDecision />`
241
+
242
+ Renders a `<div>`; also accepts its attributes.
243
+
244
+ | Prop | Type | Default | Description |
245
+ | --- | --- | --- | --- |
246
+ | `decision`* | `"approved" \| "denied"` | — | The icon and the label's verb. |
247
+ | `approverName` | `string` | — | Who decided: “Approved by Ana”. |
248
+ | `label` | `string` | — | Replaces the whole label. |
249
+ | `description` | `ReactNode` | — | The call's reason, under the label. |
250
+ | `feedback` | `string` | — | What the person said when they denied it. |
251
+
252
+ `*` marks a required prop.
253
+
254
+ ### `PERMISSION_DECISIONS`
255
+
256
+ | Prop | Type | Default | Description |
257
+ | --- | --- | --- | --- |
258
+ | `APPROVED · DENIED` | `PermissionDecisionValue` | — | The decisions. |
259
+
260
+ ### Accessibility
261
+
262
+ - The card is a group named “Permission request”; its buttons say what they do.
263
+ - “Show details” is a button with `aria-expanded` (Base UI Collapsible), 24px tall.
264
+ - The code block is focusable, so it scrolls from the keyboard.
265
+ - The decision's icons are decorative: its text says approved or denied.