@moldable-ai/ui 0.2.21 → 0.2.24

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 (515) hide show
  1. package/dist/catalog/catalog-coverage.d.ts +1 -1
  2. package/dist/catalog/catalog-manifest.d.ts +1 -1
  3. package/dist/catalog/catalog-manifest.js +1 -1
  4. package/dist/catalog/catalog-types.d.ts +7 -0
  5. package/dist/catalog/catalog-types.d.ts.map +1 -1
  6. package/dist/catalog/catalog-types.js +1 -0
  7. package/dist/catalog/component-catalog.d.ts +1 -1
  8. package/dist/catalog/component-catalog.js +2 -2
  9. package/dist/catalog/core-catalog-exclusions.d.ts +1 -1
  10. package/dist/catalog/core-catalog-exclusions.d.ts.map +1 -1
  11. package/dist/catalog/core-catalog-exclusions.js +1 -146
  12. package/dist/catalog/core-catalog.d.ts +1 -1
  13. package/dist/catalog/core-catalog.d.ts.map +1 -1
  14. package/dist/catalog/core-catalog.js +11 -7
  15. package/dist/catalog/core-collection-stories.d.ts +1 -1
  16. package/dist/catalog/core-collection-stories.d.ts.map +1 -1
  17. package/dist/catalog/core-collection-stories.js +41 -9
  18. package/dist/catalog/core-control-stories.d.ts +1 -1
  19. package/dist/catalog/core-control-stories.d.ts.map +1 -1
  20. package/dist/catalog/core-control-stories.js +53 -22
  21. package/dist/catalog/core-feedback-stories.d.ts +1 -1
  22. package/dist/catalog/core-feedback-stories.d.ts.map +1 -1
  23. package/dist/catalog/core-feedback-stories.js +89 -10
  24. package/dist/catalog/core-form-stories.d.ts +3 -0
  25. package/dist/catalog/core-form-stories.d.ts.map +1 -0
  26. package/dist/catalog/core-form-stories.js +56 -0
  27. package/dist/catalog/core-foundation-stories.d.ts +1 -1
  28. package/dist/catalog/core-foundation-stories.js +7 -7
  29. package/dist/catalog/core-layout-stories.d.ts +3 -0
  30. package/dist/catalog/core-layout-stories.d.ts.map +1 -0
  31. package/dist/catalog/core-layout-stories.js +78 -0
  32. package/dist/catalog/core-navigation-stories.d.ts +1 -1
  33. package/dist/catalog/core-navigation-stories.d.ts.map +1 -1
  34. package/dist/catalog/core-navigation-stories.js +25 -3
  35. package/dist/catalog/core-overlay-stories.d.ts +1 -1
  36. package/dist/catalog/core-overlay-stories.d.ts.map +1 -1
  37. package/dist/catalog/core-overlay-stories.js +113 -8
  38. package/dist/catalog/index.d.ts +6 -6
  39. package/dist/catalog/index.js +6 -6
  40. package/dist/components/app-error-boundary.d.ts.map +1 -1
  41. package/dist/components/app-error-boundary.js +4 -3
  42. package/dist/components/chat/chat-image-lightbox.js +3 -3
  43. package/dist/components/chat/chat-input.js +5 -5
  44. package/dist/components/chat/chat-message.js +17 -17
  45. package/dist/components/chat/chat-messages.d.ts +1 -1
  46. package/dist/components/chat/chat-messages.js +3 -3
  47. package/dist/components/chat/chat-panel.d.ts +6 -6
  48. package/dist/components/chat/chat-panel.d.ts.map +1 -1
  49. package/dist/components/chat/chat-panel.js +33 -33
  50. package/dist/components/chat/checkpoint-badge.js +3 -3
  51. package/dist/components/chat/conversation-history.d.ts.map +1 -1
  52. package/dist/components/chat/conversation-history.js +13 -13
  53. package/dist/components/chat/index.d.ts +20 -15
  54. package/dist/components/chat/index.d.ts.map +1 -1
  55. package/dist/components/chat/index.js +20 -15
  56. package/dist/components/chat/markdown.js +1 -1
  57. package/dist/components/chat/model-effort-selector.js +10 -10
  58. package/dist/components/chat/model-selector.js +4 -4
  59. package/dist/components/chat/reasoning-effort-selector.js +4 -4
  60. package/dist/components/chat/restore-dialog.js +3 -3
  61. package/dist/components/chat/thinking-timeline.js +2 -2
  62. package/dist/components/chat/tool-approval.d.ts +1 -1
  63. package/dist/components/chat/tool-approval.d.ts.map +1 -1
  64. package/dist/components/chat/tool-approval.js +9 -9
  65. package/dist/components/chat/tool-handlers.d.ts +2 -2
  66. package/dist/components/chat/tool-handlers.js +90 -90
  67. package/dist/components/chat/voice-orb-audio.d.ts +16 -0
  68. package/dist/components/chat/voice-orb-audio.d.ts.map +1 -0
  69. package/dist/components/chat/voice-orb-audio.js +110 -0
  70. package/dist/components/chat/voice-orb-renderer.d.ts +51 -0
  71. package/dist/components/chat/voice-orb-renderer.d.ts.map +1 -0
  72. package/dist/components/chat/voice-orb-renderer.js +410 -0
  73. package/dist/components/chat/voice-orb-shaders.d.ts +3 -0
  74. package/dist/components/chat/voice-orb-shaders.d.ts.map +1 -0
  75. package/dist/components/chat/voice-orb-shaders.js +355 -0
  76. package/dist/components/chat/voice-orb-types.d.ts +24 -0
  77. package/dist/components/chat/voice-orb-types.d.ts.map +1 -0
  78. package/dist/components/chat/voice-orb-types.js +73 -0
  79. package/dist/components/chat/voice-orb.d.ts +20 -0
  80. package/dist/components/chat/voice-orb.d.ts.map +1 -0
  81. package/dist/components/chat/voice-orb.js +67 -0
  82. package/dist/components/code-block.js +1 -1
  83. package/dist/components/hardware/bluetooth-panel.d.ts +2 -2
  84. package/dist/components/hardware/bluetooth-panel.js +10 -10
  85. package/dist/components/hardware/camera-preview.js +6 -6
  86. package/dist/components/hardware/capability-badge.d.ts +2 -2
  87. package/dist/components/hardware/capability-badge.js +2 -2
  88. package/dist/components/hardware/capability-matrix.d.ts +1 -1
  89. package/dist/components/hardware/capability-matrix.js +5 -5
  90. package/dist/components/hardware/clipboard-button.d.ts +1 -1
  91. package/dist/components/hardware/clipboard-button.js +2 -2
  92. package/dist/components/hardware/device-list.js +1 -1
  93. package/dist/components/hardware/display-map.d.ts +1 -1
  94. package/dist/components/hardware/display-map.js +7 -7
  95. package/dist/components/hardware/haptic-button.d.ts +2 -2
  96. package/dist/components/hardware/haptic-button.js +3 -3
  97. package/dist/components/hardware/hardware-panel.js +1 -1
  98. package/dist/components/hardware/hid-panel.d.ts +2 -2
  99. package/dist/components/hardware/hid-panel.js +10 -10
  100. package/dist/components/hardware/index.d.ts +26 -26
  101. package/dist/components/hardware/index.js +26 -26
  102. package/dist/components/hardware/live-indicator.js +1 -1
  103. package/dist/components/hardware/local-auth-button.d.ts +2 -2
  104. package/dist/components/hardware/local-auth-button.js +4 -4
  105. package/dist/components/hardware/location-panel.d.ts +1 -1
  106. package/dist/components/hardware/location-panel.js +6 -6
  107. package/dist/components/hardware/microphone-meter.js +7 -7
  108. package/dist/components/hardware/midi-monitor.d.ts +2 -2
  109. package/dist/components/hardware/midi-monitor.js +9 -9
  110. package/dist/components/hardware/notification-panel.d.ts +1 -1
  111. package/dist/components/hardware/notification-panel.js +8 -8
  112. package/dist/components/hardware/power-blocker-controller.d.ts +1 -1
  113. package/dist/components/hardware/power-blocker-controller.js +1 -1
  114. package/dist/components/hardware/power-panel.d.ts +1 -1
  115. package/dist/components/hardware/power-panel.js +9 -9
  116. package/dist/components/hardware/readout.js +1 -1
  117. package/dist/components/hardware/screen-share-preview.js +5 -5
  118. package/dist/components/hardware/secure-storage-panel.d.ts +1 -1
  119. package/dist/components/hardware/secure-storage-panel.js +9 -9
  120. package/dist/components/hardware/serial-console.d.ts +2 -2
  121. package/dist/components/hardware/serial-console.js +10 -10
  122. package/dist/components/hardware/shortcut-recorder.d.ts +1 -1
  123. package/dist/components/hardware/shortcut-recorder.js +4 -4
  124. package/dist/components/hardware/stream-log.js +1 -1
  125. package/dist/components/hardware/system-audio-monitor.d.ts +1 -1
  126. package/dist/components/hardware/system-audio-monitor.js +9 -9
  127. package/dist/components/hardware/usb-panel.d.ts +5 -5
  128. package/dist/components/hardware/usb-panel.js +10 -10
  129. package/dist/components/hardware/use-capability.d.ts +1 -1
  130. package/dist/components/hardware/use-capability.js +1 -1
  131. package/dist/components/markdown.js +5 -5
  132. package/dist/components/native-capabilities/bluetooth-panel.d.ts +2 -2
  133. package/dist/components/native-capabilities/bluetooth-panel.d.ts.map +1 -1
  134. package/dist/components/native-capabilities/bluetooth-panel.js +17 -17
  135. package/dist/components/native-capabilities/camera-preview.d.ts.map +1 -1
  136. package/dist/components/native-capabilities/camera-preview.js +7 -7
  137. package/dist/components/native-capabilities/capability-badge.d.ts +2 -2
  138. package/dist/components/native-capabilities/capability-badge.js +4 -4
  139. package/dist/components/native-capabilities/capability-matrix.d.ts +1 -1
  140. package/dist/components/native-capabilities/capability-matrix.js +7 -7
  141. package/dist/components/native-capabilities/clipboard-button.d.ts +1 -1
  142. package/dist/components/native-capabilities/clipboard-button.js +2 -2
  143. package/dist/components/native-capabilities/device-list.js +4 -4
  144. package/dist/components/native-capabilities/display-map.d.ts +1 -1
  145. package/dist/components/native-capabilities/display-map.d.ts.map +1 -1
  146. package/dist/components/native-capabilities/display-map.js +11 -11
  147. package/dist/components/native-capabilities/haptic-button.d.ts +2 -2
  148. package/dist/components/native-capabilities/haptic-button.js +3 -3
  149. package/dist/components/native-capabilities/hid-panel.d.ts +2 -2
  150. package/dist/components/native-capabilities/hid-panel.d.ts.map +1 -1
  151. package/dist/components/native-capabilities/hid-panel.js +14 -14
  152. package/dist/components/native-capabilities/index.d.ts +26 -26
  153. package/dist/components/native-capabilities/index.js +26 -26
  154. package/dist/components/native-capabilities/live-indicator.js +3 -3
  155. package/dist/components/native-capabilities/local-auth-button.d.ts +2 -2
  156. package/dist/components/native-capabilities/local-auth-button.js +4 -4
  157. package/dist/components/native-capabilities/location-panel.d.ts +1 -1
  158. package/dist/components/native-capabilities/location-panel.d.ts.map +1 -1
  159. package/dist/components/native-capabilities/location-panel.js +8 -8
  160. package/dist/components/native-capabilities/microphone-meter.js +9 -9
  161. package/dist/components/native-capabilities/midi-monitor.d.ts +2 -2
  162. package/dist/components/native-capabilities/midi-monitor.d.ts.map +1 -1
  163. package/dist/components/native-capabilities/midi-monitor.js +11 -11
  164. package/dist/components/native-capabilities/native-capability-panel.js +6 -6
  165. package/dist/components/native-capabilities/notification-panel.d.ts +1 -1
  166. package/dist/components/native-capabilities/notification-panel.js +9 -9
  167. package/dist/components/native-capabilities/power-blocker-controller.d.ts +1 -1
  168. package/dist/components/native-capabilities/power-blocker-controller.js +1 -1
  169. package/dist/components/native-capabilities/power-panel.d.ts +1 -1
  170. package/dist/components/native-capabilities/power-panel.d.ts.map +1 -1
  171. package/dist/components/native-capabilities/power-panel.js +12 -12
  172. package/dist/components/native-capabilities/readout.d.ts.map +1 -1
  173. package/dist/components/native-capabilities/readout.js +2 -2
  174. package/dist/components/native-capabilities/screen-share-preview.js +6 -6
  175. package/dist/components/native-capabilities/secure-storage-panel.d.ts +1 -1
  176. package/dist/components/native-capabilities/secure-storage-panel.d.ts.map +1 -1
  177. package/dist/components/native-capabilities/secure-storage-panel.js +11 -11
  178. package/dist/components/native-capabilities/serial-console.d.ts +2 -2
  179. package/dist/components/native-capabilities/serial-console.d.ts.map +1 -1
  180. package/dist/components/native-capabilities/serial-console.js +11 -11
  181. package/dist/components/native-capabilities/shortcut-recorder.d.ts +1 -1
  182. package/dist/components/native-capabilities/shortcut-recorder.js +5 -5
  183. package/dist/components/native-capabilities/stream-log.js +3 -3
  184. package/dist/components/native-capabilities/system-audio-monitor.d.ts +1 -1
  185. package/dist/components/native-capabilities/system-audio-monitor.js +12 -12
  186. package/dist/components/native-capabilities/usb-panel.d.ts +5 -5
  187. package/dist/components/native-capabilities/usb-panel.js +15 -15
  188. package/dist/components/native-capabilities/use-capability.d.ts +1 -1
  189. package/dist/components/native-capabilities/use-capability.js +1 -1
  190. package/dist/components/rich-media-player.js +3 -3
  191. package/dist/components/ui/accordion.js +3 -3
  192. package/dist/components/ui/alert-dialog.d.ts +5 -3
  193. package/dist/components/ui/alert-dialog.d.ts.map +1 -1
  194. package/dist/components/ui/alert-dialog.js +20 -10
  195. package/dist/components/ui/alert.d.ts +2 -2
  196. package/dist/components/ui/alert.d.ts.map +1 -1
  197. package/dist/components/ui/alert.js +11 -11
  198. package/dist/components/ui/app-frame.d.ts +7 -1
  199. package/dist/components/ui/app-frame.d.ts.map +1 -1
  200. package/dist/components/ui/app-frame.js +52 -16
  201. package/dist/components/ui/avatar.js +5 -5
  202. package/dist/components/ui/badge.d.ts +1 -1
  203. package/dist/components/ui/badge.js +4 -4
  204. package/dist/components/ui/breadcrumb.js +2 -2
  205. package/dist/components/ui/button-group.d.ts +1 -1
  206. package/dist/components/ui/button-group.js +4 -4
  207. package/dist/components/ui/button.d.ts +6 -4
  208. package/dist/components/ui/button.d.ts.map +1 -1
  209. package/dist/components/ui/button.js +50 -18
  210. package/dist/components/ui/calendar.d.ts +1 -1
  211. package/dist/components/ui/calendar.d.ts.map +1 -1
  212. package/dist/components/ui/calendar.js +15 -15
  213. package/dist/components/ui/card.js +3 -3
  214. package/dist/components/ui/carousel.d.ts +1 -1
  215. package/dist/components/ui/carousel.js +4 -4
  216. package/dist/components/ui/chart.js +5 -5
  217. package/dist/components/ui/checkbox.d.ts.map +1 -1
  218. package/dist/components/ui/checkbox.js +2 -2
  219. package/dist/components/ui/collapsible.js +3 -3
  220. package/dist/components/ui/color-well.js +2 -2
  221. package/dist/components/ui/combobox.js +9 -9
  222. package/dist/components/ui/command.d.ts +1 -1
  223. package/dist/components/ui/command.d.ts.map +1 -1
  224. package/dist/components/ui/command.js +9 -9
  225. package/dist/components/ui/confirm-dialog.d.ts +1 -1
  226. package/dist/components/ui/confirm-dialog.d.ts.map +1 -1
  227. package/dist/components/ui/confirm-dialog.js +2 -2
  228. package/dist/components/ui/context-menu.d.ts +16 -5
  229. package/dist/components/ui/context-menu.d.ts.map +1 -1
  230. package/dist/components/ui/context-menu.js +92 -16
  231. package/dist/components/ui/date-field.d.ts.map +1 -1
  232. package/dist/components/ui/date-field.js +8 -8
  233. package/dist/components/ui/date-picker.d.ts +2 -2
  234. package/dist/components/ui/date-picker.js +7 -7
  235. package/dist/components/ui/dialog-primary-action.d.ts +4 -0
  236. package/dist/components/ui/dialog-primary-action.d.ts.map +1 -0
  237. package/dist/components/ui/dialog-primary-action.js +37 -0
  238. package/dist/components/ui/dialog.d.ts +6 -2
  239. package/dist/components/ui/dialog.d.ts.map +1 -1
  240. package/dist/components/ui/dialog.js +20 -7
  241. package/dist/components/ui/drawer.js +4 -4
  242. package/dist/components/ui/dropdown-menu.d.ts +15 -5
  243. package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
  244. package/dist/components/ui/dropdown-menu.js +98 -16
  245. package/dist/components/ui/edge-fade.js +1 -1
  246. package/dist/components/ui/empty.d.ts +1 -1
  247. package/dist/components/ui/empty.js +5 -5
  248. package/dist/components/ui/error-boundary-view.d.ts +12 -0
  249. package/dist/components/ui/error-boundary-view.d.ts.map +1 -0
  250. package/dist/components/ui/error-boundary-view.js +8 -0
  251. package/dist/components/ui/field.d.ts +1 -1
  252. package/dist/components/ui/field.d.ts.map +1 -1
  253. package/dist/components/ui/field.js +9 -9
  254. package/dist/components/ui/form.js +4 -4
  255. package/dist/components/ui/grid.d.ts.map +1 -1
  256. package/dist/components/ui/grid.js +5 -5
  257. package/dist/components/ui/hover-card.js +2 -2
  258. package/dist/components/ui/icon-button.d.ts +1 -1
  259. package/dist/components/ui/icon-button.d.ts.map +1 -1
  260. package/dist/components/ui/icon-button.js +3 -4
  261. package/dist/components/ui/index.d.ts +77 -76
  262. package/dist/components/ui/index.d.ts.map +1 -1
  263. package/dist/components/ui/index.js +77 -76
  264. package/dist/components/ui/input-group.d.ts +3 -3
  265. package/dist/components/ui/input-group.js +14 -14
  266. package/dist/components/ui/input-otp.js +3 -3
  267. package/dist/components/ui/input.js +2 -2
  268. package/dist/components/ui/inspector.d.ts +1 -1
  269. package/dist/components/ui/inspector.js +6 -6
  270. package/dist/components/ui/item.d.ts +1 -1
  271. package/dist/components/ui/item.js +7 -7
  272. package/dist/components/ui/kbd.js +2 -2
  273. package/dist/components/ui/label.js +2 -2
  274. package/dist/components/ui/list.d.ts.map +1 -1
  275. package/dist/components/ui/list.js +5 -5
  276. package/dist/components/ui/material.js +3 -3
  277. package/dist/components/ui/menu-items.d.ts +28 -0
  278. package/dist/components/ui/menu-items.d.ts.map +1 -0
  279. package/dist/components/ui/menu-items.js +111 -0
  280. package/dist/components/ui/menubar.js +11 -11
  281. package/dist/components/ui/message-scroller-controller.d.ts +1 -1
  282. package/dist/components/ui/message-scroller-controller.js +1 -1
  283. package/dist/components/ui/message-scroller-primitive.d.ts +1 -1
  284. package/dist/components/ui/message-scroller-primitive.js +1 -1
  285. package/dist/components/ui/message-scroller.d.ts +2 -2
  286. package/dist/components/ui/message-scroller.js +3 -3
  287. package/dist/components/ui/navigation-button-group.d.ts +2 -2
  288. package/dist/components/ui/navigation-button-group.js +2 -2
  289. package/dist/components/ui/navigation-menu.js +6 -6
  290. package/dist/components/ui/notification-dot.js +2 -2
  291. package/dist/components/ui/number-input.js +8 -8
  292. package/dist/components/ui/pagination.d.ts +1 -1
  293. package/dist/components/ui/pagination.js +2 -2
  294. package/dist/components/ui/panel.d.ts +1 -1
  295. package/dist/components/ui/panel.js +3 -3
  296. package/dist/components/ui/popover.d.ts +1 -1
  297. package/dist/components/ui/popover.js +3 -3
  298. package/dist/components/ui/progress.js +2 -2
  299. package/dist/components/ui/radio-group.d.ts.map +1 -1
  300. package/dist/components/ui/radio-group.js +2 -2
  301. package/dist/components/ui/resizable.d.ts +1 -1
  302. package/dist/components/ui/resizable.d.ts.map +1 -1
  303. package/dist/components/ui/resizable.js +15 -4
  304. package/dist/components/ui/scroll-area.d.ts.map +1 -1
  305. package/dist/components/ui/scroll-area.js +3 -3
  306. package/dist/components/ui/search-field.js +7 -7
  307. package/dist/components/ui/segmented-control.js +9 -9
  308. package/dist/components/ui/select.d.ts.map +1 -1
  309. package/dist/components/ui/select.js +6 -6
  310. package/dist/components/ui/separator.js +1 -1
  311. package/dist/components/ui/sheet.js +4 -4
  312. package/dist/components/ui/sidebar.d.ts +5 -5
  313. package/dist/components/ui/sidebar.d.ts.map +1 -1
  314. package/dist/components/ui/sidebar.js +111 -24
  315. package/dist/components/ui/skeleton.js +2 -2
  316. package/dist/components/ui/slider.d.ts +3 -1
  317. package/dist/components/ui/slider.d.ts.map +1 -1
  318. package/dist/components/ui/slider.js +3 -3
  319. package/dist/components/ui/sonner.js +1 -1
  320. package/dist/components/ui/spinner.d.ts.map +1 -1
  321. package/dist/components/ui/spinner.js +2 -2
  322. package/dist/components/ui/split-view.js +1 -1
  323. package/dist/components/ui/status.d.ts +1 -1
  324. package/dist/components/ui/status.d.ts.map +1 -1
  325. package/dist/components/ui/status.js +10 -9
  326. package/dist/components/ui/switch.js +2 -2
  327. package/dist/components/ui/table.d.ts.map +1 -1
  328. package/dist/components/ui/table.js +7 -7
  329. package/dist/components/ui/tabs.js +3 -3
  330. package/dist/components/ui/text.d.ts +2 -2
  331. package/dist/components/ui/text.js +19 -19
  332. package/dist/components/ui/textarea.js +2 -2
  333. package/dist/components/ui/toggle-group.d.ts +1 -1
  334. package/dist/components/ui/toggle-group.js +4 -4
  335. package/dist/components/ui/toggle.d.ts +1 -1
  336. package/dist/components/ui/toggle.js +10 -10
  337. package/dist/components/ui/toolbar.d.ts +7 -7
  338. package/dist/components/ui/toolbar.js +7 -7
  339. package/dist/components/ui/tooltip.d.ts +2 -2
  340. package/dist/components/ui/tooltip.js +5 -5
  341. package/dist/index.d.ts +21 -15
  342. package/dist/index.d.ts.map +1 -1
  343. package/dist/index.js +22 -15
  344. package/dist/lib/frame-lifecycle.d.ts +49 -0
  345. package/dist/lib/frame-lifecycle.d.ts.map +1 -1
  346. package/dist/lib/frame-lifecycle.js +163 -1
  347. package/dist/lib/host-date-time-picker.d.ts +36 -0
  348. package/dist/lib/host-date-time-picker.d.ts.map +1 -0
  349. package/dist/lib/host-date-time-picker.js +162 -0
  350. package/dist/lib/host-file-dialog.d.ts +66 -0
  351. package/dist/lib/host-file-dialog.d.ts.map +1 -0
  352. package/dist/lib/host-file-dialog.js +221 -0
  353. package/dist/lib/host-native-menu.d.ts +116 -0
  354. package/dist/lib/host-native-menu.d.ts.map +1 -0
  355. package/dist/lib/host-native-menu.js +242 -0
  356. package/dist/lib/host-services.d.ts +13 -0
  357. package/dist/lib/host-services.d.ts.map +1 -0
  358. package/dist/lib/host-services.js +161 -0
  359. package/dist/lib/host-share.d.ts +39 -0
  360. package/dist/lib/host-share.d.ts.map +1 -0
  361. package/dist/lib/host-share.js +161 -0
  362. package/dist/lib/host-web-surface.d.ts +31 -0
  363. package/dist/lib/host-web-surface.d.ts.map +1 -0
  364. package/dist/lib/host-web-surface.js +116 -0
  365. package/dist/lib/native-capabilities/access.d.ts +2 -2
  366. package/dist/lib/native-capabilities/access.js +2 -2
  367. package/dist/lib/native-capabilities/bluetooth-access.d.ts +1 -1
  368. package/dist/lib/native-capabilities/bluetooth-access.js +2 -2
  369. package/dist/lib/native-capabilities/bluetooth-connection.d.ts +1 -1
  370. package/dist/lib/native-capabilities/bluetooth-connection.js +1 -1
  371. package/dist/lib/native-capabilities/bluetooth-gatt.d.ts +1 -1
  372. package/dist/lib/native-capabilities/bluetooth-gatt.js +1 -1
  373. package/dist/lib/native-capabilities/bluetooth-internal.d.ts +2 -2
  374. package/dist/lib/native-capabilities/bluetooth-internal.js +1 -1
  375. package/dist/lib/native-capabilities/bluetooth-native-fallback.d.ts +2 -2
  376. package/dist/lib/native-capabilities/bluetooth-native-fallback.js +2 -2
  377. package/dist/lib/native-capabilities/bluetooth.d.ts +6 -6
  378. package/dist/lib/native-capabilities/bluetooth.js +4 -4
  379. package/dist/lib/native-capabilities/bridge.d.ts +1 -1
  380. package/dist/lib/native-capabilities/bridge.js +2 -2
  381. package/dist/lib/native-capabilities/capabilities.d.ts +1 -1
  382. package/dist/lib/native-capabilities/capabilities.js +1 -1
  383. package/dist/lib/native-capabilities/clipboard.js +2 -2
  384. package/dist/lib/native-capabilities/device-io-errors.d.ts +1 -1
  385. package/dist/lib/native-capabilities/device-io-errors.js +1 -1
  386. package/dist/lib/native-capabilities/displays.d.ts +1 -1
  387. package/dist/lib/native-capabilities/displays.js +1 -1
  388. package/dist/lib/native-capabilities/global-shortcuts.d.ts +2 -2
  389. package/dist/lib/native-capabilities/global-shortcuts.js +1 -1
  390. package/dist/lib/native-capabilities/haptics.d.ts +1 -1
  391. package/dist/lib/native-capabilities/haptics.js +1 -1
  392. package/dist/lib/native-capabilities/hid-native.d.ts +2 -2
  393. package/dist/lib/native-capabilities/hid-native.js +3 -3
  394. package/dist/lib/native-capabilities/hid.js +5 -5
  395. package/dist/lib/native-capabilities/index.d.ts +39 -39
  396. package/dist/lib/native-capabilities/index.js +21 -21
  397. package/dist/lib/native-capabilities/local-authentication.d.ts +1 -1
  398. package/dist/lib/native-capabilities/local-authentication.js +1 -1
  399. package/dist/lib/native-capabilities/location.js +1 -1
  400. package/dist/lib/native-capabilities/media-permissions.d.ts +1 -1
  401. package/dist/lib/native-capabilities/media-permissions.js +1 -1
  402. package/dist/lib/native-capabilities/media.d.ts +1 -1
  403. package/dist/lib/native-capabilities/media.js +2 -2
  404. package/dist/lib/native-capabilities/midi-access.d.ts +1 -1
  405. package/dist/lib/native-capabilities/midi-access.js +3 -3
  406. package/dist/lib/native-capabilities/midi-internal.d.ts +1 -1
  407. package/dist/lib/native-capabilities/midi-internal.js +1 -1
  408. package/dist/lib/native-capabilities/midi-native-fallback.d.ts +1 -1
  409. package/dist/lib/native-capabilities/midi-native-fallback.js +2 -2
  410. package/dist/lib/native-capabilities/midi-ports.d.ts +1 -1
  411. package/dist/lib/native-capabilities/midi-ports.js +1 -1
  412. package/dist/lib/native-capabilities/midi.d.ts +5 -5
  413. package/dist/lib/native-capabilities/midi.js +3 -3
  414. package/dist/lib/native-capabilities/native-device-io.d.ts +1 -1
  415. package/dist/lib/native-capabilities/native-device-io.js +1 -1
  416. package/dist/lib/native-capabilities/native-device-lifecycle.js +1 -1
  417. package/dist/lib/native-capabilities/notifications.d.ts +2 -2
  418. package/dist/lib/native-capabilities/notifications.js +1 -1
  419. package/dist/lib/native-capabilities/power-session.d.ts +2 -2
  420. package/dist/lib/native-capabilities/power-session.js +1 -1
  421. package/dist/lib/native-capabilities/secure-storage.d.ts +1 -1
  422. package/dist/lib/native-capabilities/secure-storage.js +1 -1
  423. package/dist/lib/native-capabilities/serial-native.d.ts +2 -2
  424. package/dist/lib/native-capabilities/serial-native.js +3 -3
  425. package/dist/lib/native-capabilities/serial.js +5 -5
  426. package/dist/lib/native-capabilities/system-audio.d.ts +1 -1
  427. package/dist/lib/native-capabilities/system-audio.js +1 -1
  428. package/dist/lib/native-capabilities/usb-native.d.ts +2 -2
  429. package/dist/lib/native-capabilities/usb-native.js +3 -3
  430. package/dist/lib/native-capabilities/usb.js +5 -5
  431. package/dist/lib/native-hardware/bluetooth-access.d.ts +1 -1
  432. package/dist/lib/native-hardware/bluetooth-access.js +1 -1
  433. package/dist/lib/native-hardware/bluetooth-connection.d.ts +1 -1
  434. package/dist/lib/native-hardware/bluetooth-connection.js +1 -1
  435. package/dist/lib/native-hardware/bluetooth-gatt.d.ts +1 -1
  436. package/dist/lib/native-hardware/bluetooth-gatt.js +1 -1
  437. package/dist/lib/native-hardware/bluetooth-internal.d.ts +2 -2
  438. package/dist/lib/native-hardware/bluetooth-internal.js +1 -1
  439. package/dist/lib/native-hardware/bluetooth-native-fallback.d.ts +2 -2
  440. package/dist/lib/native-hardware/bluetooth-native-fallback.js +2 -2
  441. package/dist/lib/native-hardware/bluetooth.d.ts +6 -6
  442. package/dist/lib/native-hardware/bluetooth.js +4 -4
  443. package/dist/lib/native-hardware/bridge.d.ts +1 -1
  444. package/dist/lib/native-hardware/bridge.js +2 -2
  445. package/dist/lib/native-hardware/capabilities.d.ts +1 -1
  446. package/dist/lib/native-hardware/capabilities.js +1 -1
  447. package/dist/lib/native-hardware/clipboard.js +1 -1
  448. package/dist/lib/native-hardware/device-io-errors.d.ts +1 -1
  449. package/dist/lib/native-hardware/device-io-errors.js +1 -1
  450. package/dist/lib/native-hardware/displays.d.ts +1 -1
  451. package/dist/lib/native-hardware/displays.js +1 -1
  452. package/dist/lib/native-hardware/global-shortcuts.d.ts +2 -2
  453. package/dist/lib/native-hardware/global-shortcuts.js +1 -1
  454. package/dist/lib/native-hardware/haptics.d.ts +1 -1
  455. package/dist/lib/native-hardware/haptics.js +1 -1
  456. package/dist/lib/native-hardware/hid-native.d.ts +2 -2
  457. package/dist/lib/native-hardware/hid-native.js +3 -3
  458. package/dist/lib/native-hardware/hid.js +4 -4
  459. package/dist/lib/native-hardware/index.d.ts +37 -37
  460. package/dist/lib/native-hardware/index.js +20 -20
  461. package/dist/lib/native-hardware/local-authentication.d.ts +1 -1
  462. package/dist/lib/native-hardware/local-authentication.js +1 -1
  463. package/dist/lib/native-hardware/location.js +1 -1
  464. package/dist/lib/native-hardware/media-permissions.d.ts +1 -1
  465. package/dist/lib/native-hardware/media-permissions.js +1 -1
  466. package/dist/lib/native-hardware/media.d.ts +1 -1
  467. package/dist/lib/native-hardware/media.js +1 -1
  468. package/dist/lib/native-hardware/midi-access.d.ts +1 -1
  469. package/dist/lib/native-hardware/midi-access.js +2 -2
  470. package/dist/lib/native-hardware/midi-internal.d.ts +1 -1
  471. package/dist/lib/native-hardware/midi-internal.js +1 -1
  472. package/dist/lib/native-hardware/midi-native-fallback.d.ts +1 -1
  473. package/dist/lib/native-hardware/midi-native-fallback.js +2 -2
  474. package/dist/lib/native-hardware/midi-ports.d.ts +1 -1
  475. package/dist/lib/native-hardware/midi-ports.js +1 -1
  476. package/dist/lib/native-hardware/midi.d.ts +5 -5
  477. package/dist/lib/native-hardware/midi.js +3 -3
  478. package/dist/lib/native-hardware/native-device-io.d.ts +1 -1
  479. package/dist/lib/native-hardware/native-device-io.js +1 -1
  480. package/dist/lib/native-hardware/native-device-lifecycle.js +1 -1
  481. package/dist/lib/native-hardware/notifications.d.ts +2 -2
  482. package/dist/lib/native-hardware/notifications.js +1 -1
  483. package/dist/lib/native-hardware/power-session.d.ts +2 -2
  484. package/dist/lib/native-hardware/power-session.js +1 -1
  485. package/dist/lib/native-hardware/secure-storage.d.ts +1 -1
  486. package/dist/lib/native-hardware/secure-storage.js +1 -1
  487. package/dist/lib/native-hardware/serial-native.d.ts +2 -2
  488. package/dist/lib/native-hardware/serial-native.js +3 -3
  489. package/dist/lib/native-hardware/serial.js +4 -4
  490. package/dist/lib/native-hardware/system-audio.d.ts +1 -1
  491. package/dist/lib/native-hardware/system-audio.js +1 -1
  492. package/dist/lib/native-hardware/usb-native.d.ts +2 -2
  493. package/dist/lib/native-hardware/usb-native.js +3 -3
  494. package/dist/lib/native-hardware/usb.js +4 -4
  495. package/dist/lib/theme.js +1 -1
  496. package/docs/README.md +1 -0
  497. package/docs/design-tokens.md +28 -6
  498. package/docs/foundations.md +4 -2
  499. package/docs/visual-regression.md +78 -0
  500. package/package.json +15 -4
  501. package/src/components/ui/alert-dialog.md +27 -0
  502. package/src/components/ui/button.md +10 -3
  503. package/src/components/ui/confirm-dialog.md +97 -0
  504. package/src/components/ui/context-menu.md +158 -0
  505. package/src/components/ui/dialog.md +23 -4
  506. package/src/components/ui/dropdown-menu.md +165 -0
  507. package/src/components/ui/error-boundary-view.md +98 -0
  508. package/src/components/ui/hover-card.md +90 -0
  509. package/src/components/ui/select.md +111 -0
  510. package/src/lib/host-date-time-picker.md +29 -0
  511. package/src/lib/host-file-dialog.md +76 -0
  512. package/src/lib/host-native-menu.md +67 -0
  513. package/src/lib/host-share.md +36 -0
  514. package/src/lib/host-web-surface.md +66 -0
  515. package/src/styles/index.css +141 -68
@@ -2,7 +2,7 @@
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import { FastForward, Pause, Play, Rewind, Volume2, VolumeX, } from 'lucide-react';
4
4
  import { useCallback, useMemo, useRef, useState } from 'react';
5
- import { cn } from '../lib/utils';
5
+ import { cn } from '../lib/utils.js';
6
6
  const PLAYBACK_RATES = [0.75, 1, 1.25, 1.5, 2];
7
7
  function formatTime(value) {
8
8
  if (!Number.isFinite(value) || value < 0)
@@ -96,8 +96,8 @@ export function RichMediaPlayer({ className, kind, src, title, }) {
96
96
  };
97
97
  const controls = (_jsxs("div", { className: cn('flex flex-col gap-2 text-white', isAudio
98
98
  ? 'p-3'
99
- : 'bg-gradient-to-b from-transparent via-black/65 to-neutral-950 px-3 pb-3 pt-10'), children: [_jsx("input", { "aria-label": "Seek", className: "h-2 w-full cursor-pointer accent-white disabled:cursor-default disabled:opacity-50", disabled: !canSeek, max: durationValue, min: 0, onChange: (event) => seekTo(Number(event.currentTarget.value)), step: 0.1, type: "range", value: Math.min(currentTime, durationValue) }), _jsxs("div", { className: "flex h-10 items-center gap-3 px-1", children: [_jsx("button", { "aria-label": isPlaying ? 'Pause' : 'Play', className: "hover:text-primary cursor-pointer rounded-full p-1 text-white transition-colors focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-white", onClick: togglePlayback, type: "button", children: isPlaying ? (_jsx(Pause, { className: "size-6" })) : (_jsx(Play, { className: "size-6" })) }), _jsx("button", { "aria-label": "Rewind 10 seconds", className: "cursor-pointer rounded-full p-1 text-white/85 transition-colors hover:text-white focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-white", onClick: () => seekBy(-10), type: "button", children: _jsx(Rewind, { className: "size-5" }) }), _jsx("button", { "aria-label": "Forward 10 seconds", className: "cursor-pointer rounded-full p-1 text-white/85 transition-colors hover:text-white focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-white", onClick: () => seekBy(10), type: "button", children: _jsx(FastForward, { className: "size-5" }) }), _jsxs("div", { className: "group/volume flex items-center gap-2", children: [_jsx("button", { "aria-label": isMuted ? 'Unmute' : 'Mute', className: "cursor-pointer rounded-full p-1 text-white/85 transition-colors hover:text-white focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-white", onClick: toggleMuted, type: "button", children: isMuted || volume === 0 ? (_jsx(VolumeX, { className: "size-5" })) : (_jsx(Volume2, { className: "size-5" })) }), _jsx("input", { "aria-label": "Volume", className: "h-2 w-0 cursor-pointer accent-white opacity-0 transition-all focus:w-20 focus:opacity-100 group-hover/volume:w-20 group-hover/volume:opacity-100", max: 1, min: 0, onChange: (event) => changeVolume(Number(event.currentTarget.value)), step: 0.05, type: "range", value: isMuted ? 0 : volume })] }), _jsxs("span", { className: "ml-auto min-w-28 text-right font-mono text-xs text-white/80", children: [formatTime(currentTime), " / ", formatTime(durationValue)] }), _jsxs("button", { "aria-label": "Change playback speed", className: "cursor-pointer rounded px-2 py-1 font-mono text-xs text-white/85 transition-colors hover:text-white focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-white", onClick: cyclePlaybackRate, type: "button", children: [playbackRate, "x"] })] })] }));
100
- return (_jsx("div", { className: cn('not-prose overflow-hidden rounded-lg border border-black/5 bg-neutral-950 text-white shadow-sm dark:border-white/10', className), ref: containerRef, children: _jsxs("div", { className: cn('group/mediaplayer relative w-full overflow-hidden', !isAudio && 'bg-black'), children: [isAudio ? (_jsx("audio", { "aria-label": mediaTitle, onDurationChange: (event) => setDuration(event.currentTarget.duration), onEnded: () => setIsPlaying(false), onLoadedMetadata: (event) => setDuration(event.currentTarget.duration), onPause: () => setIsPlaying(false), onPlay: () => setIsPlaying(true), onTimeUpdate: (event) => setCurrentTime(event.currentTarget.currentTime), preload: "metadata", ref: setMediaElement, src: src })) : (_jsx("video", { className: "h-auto max-h-[600px] min-h-[225px] w-full bg-black object-contain", onClick: togglePlayback, onDurationChange: (event) => setDuration(event.currentTarget.duration), onEnded: () => setIsPlaying(false), onLoadedMetadata: (event) => setDuration(event.currentTarget.duration), onPause: () => setIsPlaying(false), onPlay: () => setIsPlaying(true), onTimeUpdate: (event) => setCurrentTime(event.currentTarget.currentTime), playsInline: true, preload: "metadata", ref: setMediaElement, src: src })), _jsx("div", { className: cn(isAudio
99
+ : 'bg-gradient-to-b from-transparent via-black/65 to-neutral-950 px-3 pb-3 pt-10'), children: [_jsx("input", { "aria-label": "Seek", className: "h-2 w-full cursor-pointer accent-white disabled:cursor-default disabled:opacity-50", disabled: !canSeek, max: durationValue, min: 0, onChange: (event) => seekTo(Number(event.currentTarget.value)), step: 0.1, type: "range", value: Math.min(currentTime, durationValue) }), _jsxs("div", { className: "flex h-toolbar items-center gap-control-gap px-1", children: [_jsx("button", { "aria-label": isPlaying ? 'Pause' : 'Play', className: "hover:text-primary focus-visible:ring-terminal-foreground/70 rounded-pill cursor-pointer p-1 text-white transition-colors focus-visible:outline-none focus-visible:ring-1", onClick: togglePlayback, type: "button", children: isPlaying ? (_jsx(Pause, { className: "size-6" })) : (_jsx(Play, { className: "size-6" })) }), _jsx("button", { "aria-label": "Rewind 10 seconds", className: "focus-visible:ring-terminal-foreground/70 rounded-pill cursor-pointer p-1 text-white/85 transition-colors hover:text-white focus-visible:outline-none focus-visible:ring-1", onClick: () => seekBy(-10), type: "button", children: _jsx(Rewind, { className: "size-5" }) }), _jsx("button", { "aria-label": "Forward 10 seconds", className: "focus-visible:ring-terminal-foreground/70 rounded-pill cursor-pointer p-1 text-white/85 transition-colors hover:text-white focus-visible:outline-none focus-visible:ring-1", onClick: () => seekBy(10), type: "button", children: _jsx(FastForward, { className: "size-5" }) }), _jsxs("div", { className: "group/volume flex items-center gap-2", children: [_jsx("button", { "aria-label": isMuted ? 'Unmute' : 'Mute', className: "focus-visible:ring-terminal-foreground/70 rounded-pill cursor-pointer p-1 text-white/85 transition-colors hover:text-white focus-visible:outline-none focus-visible:ring-1", onClick: toggleMuted, type: "button", children: isMuted || volume === 0 ? (_jsx(VolumeX, { className: "size-5" })) : (_jsx(Volume2, { className: "size-5" })) }), _jsx("input", { "aria-label": "Volume", className: "h-2 w-0 cursor-pointer accent-white opacity-0 transition-all focus:w-20 focus:opacity-100 group-hover/volume:w-20 group-hover/volume:opacity-100", max: 1, min: 0, onChange: (event) => changeVolume(Number(event.currentTarget.value)), step: 0.05, type: "range", value: isMuted ? 0 : volume })] }), _jsxs("span", { className: "text-ui-caption ml-auto min-w-28 text-right font-mono text-white/80", children: [formatTime(currentTime), " / ", formatTime(durationValue)] }), _jsxs("button", { "aria-label": "Change playback speed", className: "text-ui-caption focus-visible:ring-terminal-foreground/70 rounded-control cursor-pointer px-2 py-1 font-mono text-white/85 transition-colors hover:text-white focus-visible:outline-none focus-visible:ring-1", onClick: cyclePlaybackRate, type: "button", children: [playbackRate, "x"] })] })] }));
100
+ return (_jsx("div", { className: cn('not-prose rounded-container overflow-hidden border border-black/5 bg-neutral-950 text-white shadow-sm dark:border-white/10', className), ref: containerRef, children: _jsxs("div", { className: cn('group/mediaplayer relative w-full overflow-hidden', !isAudio && 'bg-black'), children: [isAudio ? (_jsx("audio", { "aria-label": mediaTitle, onDurationChange: (event) => setDuration(event.currentTarget.duration), onEnded: () => setIsPlaying(false), onLoadedMetadata: (event) => setDuration(event.currentTarget.duration), onPause: () => setIsPlaying(false), onPlay: () => setIsPlaying(true), onTimeUpdate: (event) => setCurrentTime(event.currentTarget.currentTime), preload: "metadata", ref: setMediaElement, src: src })) : (_jsx("video", { className: "h-auto max-h-[600px] min-h-[225px] w-full bg-black object-contain", onClick: togglePlayback, onDurationChange: (event) => setDuration(event.currentTarget.duration), onEnded: () => setIsPlaying(false), onLoadedMetadata: (event) => setDuration(event.currentTarget.duration), onPause: () => setIsPlaying(false), onPlay: () => setIsPlaying(true), onTimeUpdate: (event) => setCurrentTime(event.currentTarget.currentTime), playsInline: true, preload: "metadata", ref: setMediaElement, src: src })), _jsx("div", { className: cn(isAudio
101
101
  ? 'bg-neutral-950'
102
102
  : 'absolute bottom-0 left-0 right-0 transition-transform duration-300', !isAudio &&
103
103
  isPlaying &&
@@ -2,7 +2,7 @@
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import * as AccordionPrimitive from '@radix-ui/react-accordion';
4
4
  import { ChevronDownIcon } from 'lucide-react';
5
- import { cn } from '../../lib/utils';
5
+ import { cn } from '../../lib/utils.js';
6
6
  function Accordion({ ...props }) {
7
7
  return _jsx(AccordionPrimitive.Root, { "data-slot": "accordion", ...props });
8
8
  }
@@ -10,9 +10,9 @@ function AccordionItem({ className, ...props }) {
10
10
  return (_jsx(AccordionPrimitive.Item, { "data-slot": "accordion-item", className: cn('border-b last:border-b-0', className), ...props }));
11
11
  }
12
12
  function AccordionTrigger({ className, children, ...props }) {
13
- return (_jsx(AccordionPrimitive.Header, { className: "flex", children: _jsxs(AccordionPrimitive.Trigger, { "data-slot": "accordion-trigger", className: cn('focus-visible:border-ring focus-visible:ring-ring/50 flex flex-1 items-start justify-between gap-4 rounded-md py-4 text-left text-sm font-medium outline-none transition-all hover:underline focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>svg]:rotate-180', className), ...props, children: [children, _jsx(ChevronDownIcon, { className: "text-muted-foreground pointer-events-none size-4 shrink-0 translate-y-0.5 transition-transform duration-200" })] }) }));
13
+ return (_jsx(AccordionPrimitive.Header, { className: "flex", children: _jsxs(AccordionPrimitive.Trigger, { "data-slot": "accordion-trigger", className: cn('focus-visible:border-ring focus-visible:ring-ring rounded-control text-ui-body flex flex-1 items-start justify-between gap-4 py-4 text-left font-medium outline-none transition-all hover:underline focus-visible:ring-1 disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>svg]:rotate-180', className), ...props, children: [children, _jsx(ChevronDownIcon, { className: "text-muted-foreground pointer-events-none size-4 shrink-0 translate-y-0.5 transition-transform duration-200" })] }) }));
14
14
  }
15
15
  function AccordionContent({ className, children, ...props }) {
16
- return (_jsx(AccordionPrimitive.Content, { "data-slot": "accordion-content", className: "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm", ...props, children: _jsx("div", { className: cn('pb-4 pt-0', className), children: children }) }));
16
+ return (_jsx(AccordionPrimitive.Content, { "data-slot": "accordion-content", className: "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down text-ui-body overflow-hidden", ...props, children: _jsx("div", { className: cn('pb-4 pt-0', className), children: children }) }));
17
17
  }
18
18
  export { Accordion, AccordionItem, AccordionTrigger, AccordionContent };
@@ -1,11 +1,11 @@
1
1
  import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
2
2
  import * as React from 'react';
3
- import { Button } from './button';
3
+ import { Button } from './button.js';
4
4
  declare function AlertDialog({ ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
5
5
  declare function AlertDialogTrigger({ ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
6
6
  declare function AlertDialogPortal({ ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Portal>): import("react/jsx-runtime").JSX.Element;
7
7
  declare function AlertDialogOverlay({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Overlay>): import("react/jsx-runtime").JSX.Element;
8
- declare function AlertDialogContent({ className, size, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Content> & {
8
+ declare function AlertDialogContent({ className, onKeyDown, onOpenAutoFocus, size, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Content> & {
9
9
  size?: 'sm' | 'default' | 'lg';
10
10
  }): import("react/jsx-runtime").JSX.Element;
11
11
  declare function AlertDialogHeader({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
@@ -14,9 +14,11 @@ declare function AlertDialogBody({ className, ...props }: React.ComponentProps<'
14
14
  declare function AlertDialogTitle({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Title>): import("react/jsx-runtime").JSX.Element;
15
15
  declare function AlertDialogDescription({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Description>): import("react/jsx-runtime").JSX.Element;
16
16
  declare function AlertDialogMedia({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
17
- declare function AlertDialogAction({ className, children, disabled, pending, pendingLabel, variant, size, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Action> & Pick<React.ComponentProps<typeof Button>, 'variant' | 'size'> & {
17
+ declare function AlertDialogAction({ className, children, disabled, loading, pending, pendingLabel, primary, variant, size, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Action> & Pick<React.ComponentProps<typeof Button>, 'variant' | 'size'> & {
18
+ loading?: boolean;
18
19
  pending?: boolean;
19
20
  pendingLabel?: React.ReactNode;
21
+ primary?: boolean;
20
22
  }): import("react/jsx-runtime").JSX.Element;
21
23
  declare function AlertDialogCancel({ className, variant, size, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Cancel> & Pick<React.ComponentProps<typeof Button>, 'variant' | 'size'>): import("react/jsx-runtime").JSX.Element;
22
24
  export { AlertDialog, AlertDialogAction, AlertDialogBody, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, };
@@ -1 +1 @@
1
- {"version":3,"file":"alert-dialog.d.ts","sourceRoot":"","sources":["../../../src/components/ui/alert-dialog.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,oBAAoB,MAAM,8BAA8B,CAAA;AACpE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AAGjC,iBAAS,WAAW,CAAC,EACnB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,IAAI,CAAC,2CAExD;AAED,iBAAS,kBAAkB,CAAC,EAC1B,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,OAAO,CAAC,2CAI3D;AAED,iBAAS,iBAAiB,CAAC,EACzB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,MAAM,CAAC,2CAI1D;AAED,iBAAS,kBAAkB,CAAC,EAC1B,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,OAAO,CAAC,2CAW3D;AAED,iBAAS,kBAAkB,CAAC,EAC1B,SAAS,EACT,IAAgB,EAChB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,OAAO,CAAC,GAAG;IAC7D,IAAI,CAAC,EAAE,IAAI,GAAG,SAAS,GAAG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C,cAAc,CAAC,OAAO,oBAAoB,CAAC,MAAM,CAAC,GACzD,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,MAAM,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC,2CAU9D;AAED,OAAO,EACL,WAAW,EACX,iBAAiB,EACjB,eAAe,EACf,iBAAiB,EACjB,kBAAkB,EAClB,sBAAsB,EACtB,iBAAiB,EACjB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,EAClB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,GACnB,CAAA"}
1
+ {"version":3,"file":"alert-dialog.d.ts","sourceRoot":"","sources":["../../../src/components/ui/alert-dialog.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,oBAAoB,MAAM,8BAA8B,CAAA;AACpE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AAIjC,iBAAS,WAAW,CAAC,EACnB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,IAAI,CAAC,2CAExD;AAED,iBAAS,kBAAkB,CAAC,EAC1B,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,OAAO,CAAC,2CAI3D;AAED,iBAAS,iBAAiB,CAAC,EACzB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,MAAM,CAAC,2CAI1D;AAED,iBAAS,kBAAkB,CAAC,EAC1B,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,OAAO,CAAC,2CAW3D;AASD,iBAAS,kBAAkB,CAAC,EAC1B,SAAS,EACT,SAAS,EACT,eAAe,EACf,IAAgB,EAChB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,OAAO,CAAC,GAAG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O,CAAC,EAAE,OAAO,CAAA;CAClB,2CAsBF;AAED,iBAAS,iBAAiB,CAAC,EACzB,SAAS,EACT,OAAmB,EACnB,IAAgB,EAChB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,oBAAoB,CAAC,MAAM,CAAC,GACzD,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,MAAM,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC,2CAU9D;AAED,OAAO,EACL,WAAW,EACX,iBAAiB,EACjB,eAAe,EACf,iBAAiB,EACjB,kBAAkB,EAClB,sBAAsB,EACtB,iBAAiB,EACjB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,EAClB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,GACnB,CAAA"}
@@ -1,9 +1,10 @@
1
1
  'use client';
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
4
- import { cn } from '../../lib/utils';
5
- import { Button } from './button';
6
- import { Spinner } from './spinner';
4
+ import { cn } from '../../lib/utils.js';
5
+ import { Button } from './button.js';
6
+ import { handleDialogPrimaryActionKeyDown } from './dialog-primary-action.js';
7
+ import { Spinner } from './spinner.js';
7
8
  function AlertDialog({ ...props }) {
8
9
  return _jsx(AlertDialogPrimitive.Root, { "data-slot": "alert-dialog", ...props });
9
10
  }
@@ -16,8 +17,17 @@ function AlertDialogPortal({ ...props }) {
16
17
  function AlertDialogOverlay({ className, ...props }) {
17
18
  return (_jsx(AlertDialogPrimitive.Overlay, { "data-slot": "alert-dialog-overlay", className: cn('data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50', className), ...props }));
18
19
  }
19
- function AlertDialogContent({ className, size = 'default', ...props }) {
20
- return (_jsxs(AlertDialogPortal, { children: [_jsx(AlertDialogOverlay, {}), _jsx("div", { "data-slot": "alert-dialog-positioner", className: "pointer-events-none fixed bottom-[max(var(--window-content-inset-bottom),var(--chat-safe-padding),1rem)] left-[max(var(--window-content-inset-inline-start),1rem)] right-[max(var(--window-content-inset-inline-end),1rem)] top-[max(var(--window-content-inset-top),1rem)] z-50 grid place-items-center", children: _jsx(AlertDialogPrimitive.Content, { "data-slot": "alert-dialog-content", "data-size": size, className: cn('bg-background group/alert-dialog-content rounded-overlay border-separator shadow-overlay pointer-events-auto relative grid max-h-full min-h-0 w-full gap-4 overflow-hidden border p-6 outline-none', 'data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95', 'duration-[var(--motion-duration-normal)]', 'data-[size=default]:max-w-lg data-[size=lg]:max-w-2xl data-[size=sm]:max-w-xs', className), ...props }) })] }));
20
+ function focusAlertDialogContentOnOpen(event) {
21
+ event.preventDefault();
22
+ if (event.currentTarget instanceof HTMLElement) {
23
+ event.currentTarget.focus({ preventScroll: true });
24
+ }
25
+ }
26
+ function AlertDialogContent({ className, onKeyDown, onOpenAutoFocus, size = 'default', ...props }) {
27
+ return (_jsxs(AlertDialogPortal, { children: [_jsx(AlertDialogOverlay, {}), _jsx("div", { "data-slot": "alert-dialog-positioner", className: "pointer-events-none fixed bottom-[max(var(--window-content-inset-bottom),var(--chat-safe-padding),1rem)] left-[max(var(--window-content-inset-inline-start),1rem)] right-[max(var(--window-content-inset-inline-end),1rem)] top-[max(var(--window-content-inset-top),1rem)] z-50 grid place-items-center", children: _jsx(AlertDialogPrimitive.Content, { "data-slot": "alert-dialog-content", "data-size": size, tabIndex: -1, className: cn('bg-background group/alert-dialog-content border-separator shadow-dialog rounded-dialog pointer-events-auto relative grid max-h-full min-h-0 w-full gap-4 overflow-hidden border p-6 outline-none', 'data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95', 'duration-[var(--motion-duration-normal)]', 'data-[size=default]:max-w-lg data-[size=lg]:max-w-2xl data-[size=sm]:max-w-xs', className), onKeyDown: (event) => {
28
+ onKeyDown?.(event);
29
+ handleDialogPrimaryActionKeyDown(event);
30
+ }, onOpenAutoFocus: onOpenAutoFocus ?? focusAlertDialogContentOnOpen, ...props }) })] }));
21
31
  }
22
32
  function AlertDialogHeader({ className, ...props }) {
23
33
  return (_jsx("div", { "data-slot": "alert-dialog-header", className: cn('has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-6 sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr] grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left', className), ...props }));
@@ -29,16 +39,16 @@ function AlertDialogBody({ className, ...props }) {
29
39
  return (_jsx("div", { "data-slot": "alert-dialog-body", className: cn('min-h-0 overflow-y-auto overscroll-contain [scrollbar-gutter:stable]', className), ...props }));
30
40
  }
31
41
  function AlertDialogTitle({ className, ...props }) {
32
- return (_jsx(AlertDialogPrimitive.Title, { "data-slot": "alert-dialog-title", className: cn('sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2 text-lg font-semibold', className), ...props }));
42
+ return (_jsx(AlertDialogPrimitive.Title, { "data-slot": "alert-dialog-title", className: cn('text-ui-heading sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2', className), ...props }));
33
43
  }
34
44
  function AlertDialogDescription({ className, ...props }) {
35
- return (_jsx(AlertDialogPrimitive.Description, { "data-slot": "alert-dialog-description", className: cn('text-muted-foreground text-sm', className), ...props }));
45
+ return (_jsx(AlertDialogPrimitive.Description, { "data-slot": "alert-dialog-description", className: cn('text-text-secondary text-ui-body', className), ...props }));
36
46
  }
37
47
  function AlertDialogMedia({ className, ...props }) {
38
- return (_jsx("div", { "data-slot": "alert-dialog-media", className: cn("bg-muted *:[svg:not([class*='size-'])]:size-8 mb-2 inline-flex size-16 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2", className), ...props }));
48
+ return (_jsx("div", { "data-slot": "alert-dialog-media", className: cn("bg-muted rounded-container *:[svg:not([class*='size-'])]:size-8 mb-2 inline-flex size-16 items-center justify-center sm:group-data-[size=default]/alert-dialog-content:row-span-2", className), ...props }));
39
49
  }
40
- function AlertDialogAction({ className, children, disabled, pending = false, pendingLabel, variant = 'default', size = 'default', ...props }) {
41
- return (_jsx(Button, { variant: variant, size: size, disabled: disabled || pending, "aria-busy": pending || undefined, asChild: true, children: _jsxs(AlertDialogPrimitive.Action, { "data-slot": "alert-dialog-action", "data-pending": pending || undefined, className: cn(className), ...props, children: [pending ? _jsx(Spinner, { "aria-hidden": "true" }) : null, pending && pendingLabel !== undefined ? pendingLabel : children] }) }));
50
+ function AlertDialogAction({ className, children, disabled, loading = false, pending = false, pendingLabel, primary = false, variant = 'default', size = 'default', ...props }) {
51
+ return (_jsx(Button, { variant: variant, size: size, disabled: disabled || pending, loading: loading, "aria-busy": pending || undefined, asChild: true, children: _jsxs(AlertDialogPrimitive.Action, { "data-slot": "alert-dialog-action", "data-dialog-primary-action": primary || undefined, "data-pending": pending || undefined, className: cn(className), ...props, children: [pending ? _jsx(Spinner, { "aria-hidden": "true" }) : null, pending && pendingLabel !== undefined ? pendingLabel : children] }) }));
42
52
  }
43
53
  function AlertDialogCancel({ className, variant = 'outline', size = 'default', ...props }) {
44
54
  return (_jsx(Button, { variant: variant, size: size, asChild: true, children: _jsx(AlertDialogPrimitive.Cancel, { "data-slot": "alert-dialog-cancel", className: cn(className), ...props }) }));
@@ -1,8 +1,8 @@
1
1
  import * as React from 'react';
2
- import { type IconButtonProps } from './icon-button';
2
+ import { type IconButtonProps } from './icon-button.js';
3
3
  import { type VariantProps } from 'class-variance-authority';
4
4
  declare const alertVariants: (props?: ({
5
- tone?: "success" | "warning" | "neutral" | "info" | "danger" | null | undefined;
5
+ tone?: "neutral" | "info" | "success" | "warning" | "danger" | null | undefined;
6
6
  density?: "compact" | "default" | null | undefined;
7
7
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
8
8
  type AlertTone = NonNullable<VariantProps<typeof alertVariants>['tone']>;
@@ -1 +1 @@
1
- {"version":3,"file":"alert.d.ts","sourceRoot":"","sources":["../../../src/components/ui/alert.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAc,KAAK,eAAe,EAAE,MAAM,eAAe,CAAA;AAChE,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,0BAA0B,CAAA;AAEjE,QAAA,MAAM,aAAa;;;8EAwBlB,CAAA;AAED,KAAK,SAAS,GAAG,WAAW,CAAC,YAAY,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC,CAAA;AACxE,KAAK,YAAY,GAAG,WAAW,CAAC,YAAY,CAAC,OAAO,aAAa,CAAC,CAAC,SAAS,CAAC,CAAC,CAAA;AAE9E,UAAU,UACR,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,EAC/C,YAAY,CAAC,OAAO,aAAa,CAAC;IACpC;;OAEG;IACH,OAAO,CAAC,EAAE,SAAS,GAAG,aAAa,CAAA;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAA;CACtB;AAED,iBAAS,KAAK,CAAC,EACb,SAAS,EACT,OAAmB,EACnB,IAAI,EACJ,IAAI,EACJ,OAAO,EACP,GAAG,KAAK,EACT,EAAE,UAAU,2CAcZ;AAED,iBAAS,UAAU,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAWvE;AAED,iBAAS,gBA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AE,SAAS,GAAG,aAAa,CAAA;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAA;CACtB;AAED,iBAAS,KAAK,CAAC,EACb,SAAS,EACT,OAAmB,EACnB,IAAI,EACJ,IAAI,EACJ,OAAO,EACP,GAAG,KAAK,EACT,EAAE,UAAU,2CAcZ;AAED,iBAAS,UAAU,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAWvE;AAED,iBAAS,gBAAgB,CAAC,EACxB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAW7B;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAWzE;AAED,UAAU,iBACR,SAAQ,IAAI,CACV,eAAe,EACf,UAAU,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,CACpD;IACD,KAAK,EAAE,MAAM,CAAA;CACd;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,2CActE;AAED,OAAO,EACL,KAAK,EACL,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,aAAa,EACb,KAAK,YAAY,EACjB,KAAK,iBAAiB,EACtB,KAAK,UAAU,EACf,KAAK,SAAS,GACf,CAAA"}
@@ -1,21 +1,21 @@
1
1
  'use client';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import { XIcon } from 'lucide-react';
4
- import { cn } from '../../lib/utils';
5
- import { IconButton } from './icon-button';
4
+ import { cn } from '../../lib/utils.js';
5
+ import { IconButton } from './icon-button.js';
6
6
  import { cva } from 'class-variance-authority';
7
- const alertVariants = cva('relative grid w-full items-start rounded-container border text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 has-[>[data-slot=alert-dismiss]]:pr-10 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current', {
7
+ const alertVariants = cva('text-ui-body relative grid w-full grid-cols-[0_1fr] items-start rounded-container border has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 has-[>[data-slot=alert-dismiss]]:pr-10 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current', {
8
8
  variants: {
9
9
  tone: {
10
- neutral: 'border-border bg-card text-card-foreground',
11
- info: 'border-ring/35 bg-ring/8 text-foreground [&>svg]:text-ring',
12
- success: 'border-success/35 bg-success/10 text-foreground [&>svg]:text-success',
13
- warning: 'border-warning/40 bg-warning/12 text-foreground [&>svg]:text-warning',
14
- danger: 'border-destructive/35 bg-destructive/8 text-destructive [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90',
10
+ neutral: 'border-neutral/35 bg-neutral/8 text-neutral-foreground [&>svg]:text-neutral',
11
+ info: 'border-info/35 bg-info/8 text-info-foreground [&>svg]:text-info',
12
+ success: 'border-success/35 bg-success/10 text-success-foreground [&>svg]:text-success',
13
+ warning: 'border-warning/40 bg-warning/12 text-warning-foreground [&>svg]:text-warning',
14
+ danger: 'border-destructive/35 bg-destructive/8 text-destructive [&>svg]:text-current',
15
15
  },
16
16
  density: {
17
- compact: 'gap-y-0 px-3 py-2 text-xs',
18
- default: 'gap-y-0.5 px-4 py-3 text-sm',
17
+ compact: 'text-ui-caption gap-y-0 px-3 py-2',
18
+ default: 'text-ui-body gap-y-0.5 px-4 py-3',
19
19
  },
20
20
  },
21
21
  defaultVariants: {
@@ -31,7 +31,7 @@ function AlertTitle({ className, ...props }) {
31
31
  return (_jsx("div", { "data-slot": "alert-title", className: cn('col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight', className), ...props }));
32
32
  }
33
33
  function AlertDescription({ className, ...props }) {
34
- return (_jsx("div", { "data-slot": "alert-description", className: cn('text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed', className), ...props }));
34
+ return (_jsx("div", { "data-slot": "alert-description", className: cn('col-start-2 grid justify-items-start gap-1 text-current [&_p]:leading-relaxed', className), ...props }));
35
35
  }
36
36
  function AlertActions({ className, ...props }) {
37
37
  return (_jsx("div", { "data-slot": "alert-actions", className: cn('col-start-2 mt-2 flex flex-wrap items-center gap-1.5', className), ...props }));
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import type { MaterialVariant } from './material';
2
+ import type { MaterialVariant } from './material.js';
3
3
  export type AppFrameMode = 'auto' | 'embedded' | 'window';
4
4
  declare function resolveAppFrameMode(mode: AppFrameMode): Exclude<AppFrameMode, 'auto'>;
5
5
  export interface AppFrameProps extends React.ComponentProps<'div'> {
@@ -9,6 +9,12 @@ export interface AppFrameProps extends React.ComponentProps<'div'> {
9
9
  */
10
10
  mode?: AppFrameMode;
11
11
  }
12
+ interface AppFrameRuntimeContextValue {
13
+ mode: Exclude<AppFrameMode, 'auto'>;
14
+ sidebarMaterialAvailable: boolean;
15
+ sidebarMaterialRegionId: string | null;
16
+ }
17
+ export declare function useAppFrameRuntime(): AppFrameRuntimeContextValue | null;
12
18
  declare function AppFrame({ mode, className, style, ...props }: AppFrameProps): import("react/jsx-runtime").JSX.Element;
13
19
  export interface AppFrameTitlebarProps extends React.ComponentPropsWithoutRef<'header'> {
14
20
  material?: MaterialVariant | 'none';
@@ -1 +1 @@
1
- {"version":3,"file":"app-frame.d.ts","sourceRoot":"","sources":["../../../src/components/ui/app-frame.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAA;AAEjD,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,UAAU,GAAG,QAAQ,CAAA;AAEzD,iBAAS,mBAAmB,CAC1B,IAAI,EAAE,YAAY,GACjB,OAAO,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AAU,CAAC,EAAE,OAAO,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,iBAAS,eAAe,CAAC,EACvB,UAAiB,EACjB,QAAe,EACf,SAAS,EACT,KAAK,EACL,GAAG,KAAK,EACT,EAAE,oBAAoB,2CAoBtB;AAED,MAAM,WAAW,sBACf,SAAQ,KAAK,CAAC,wBAAwB,CAAC,QAAQ,CAAC;IAChD,QAAQ,CAAC,EAAE,eAAe,GAAG,MAAM,CAAA;CACpC;AAED,iBAAS,iBAAiB,CAAC,EACzB,SAAS,EACT,QAAoB,EACpB,KAAK,EACL,GAAG,KAAK,EACT,EAAE,sBAAsB,2CAmBxB;AAED,OAAO,EACL,QAAQ,EACR,eAAe,EACf,iBAAiB,EACjB,gBAAgB,EAChB,eAAe,EACf,mBAAmB,GACpB,CAAA"}
@@ -1,7 +1,8 @@
1
1
  'use client';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import * as React from 'react';
4
- import { cn } from '../../lib/utils';
4
+ import { MOLDABLE_MATERIAL_REGION_CHANGE_EVENT } from '../../lib/frame-lifecycle.js';
5
+ import { cn } from '../../lib/utils.js';
5
6
  function resolveAppFrameMode(mode) {
6
7
  if (mode !== 'auto')
7
8
  return mode;
@@ -12,21 +13,56 @@ function resolveAppFrameMode(mode) {
12
13
  return hostMode;
13
14
  return window.parent === window ? 'window' : 'embedded';
14
15
  }
16
+ const AppFrameRuntimeContext = React.createContext(null);
17
+ export function useAppFrameRuntime() {
18
+ return React.useContext(AppFrameRuntimeContext);
19
+ }
20
+ function activeSidebarMaterialRegionId() {
21
+ if (typeof document === 'undefined' ||
22
+ document.documentElement.dataset.moldableMaterialRegionSidebar !== 'active') {
23
+ return null;
24
+ }
25
+ return (document.documentElement.dataset.moldableMaterialRegionSidebarId ?? null);
26
+ }
27
+ function sidebarMaterialAvailable() {
28
+ return (typeof document !== 'undefined' &&
29
+ document.documentElement.dataset.moldableNativeMaterialSidebar ===
30
+ 'available');
31
+ }
15
32
  function AppFrame({ mode = 'auto', className, style, ...props }) {
16
33
  const [resolvedMode, setResolvedMode] = React.useState(() => resolveAppFrameMode(mode));
34
+ const [sidebarMaterialRegionId, setSidebarMaterialRegionId] = React.useState(activeSidebarMaterialRegionId);
35
+ const [nativeSidebarMaterialAvailable, setNativeSidebarMaterialAvailable] = React.useState(sidebarMaterialAvailable);
17
36
  React.useEffect(() => {
18
- setResolvedMode(resolveAppFrameMode(mode));
19
- if (mode !== 'auto')
20
- return;
21
- const updateMode = () => setResolvedMode(resolveAppFrameMode('auto'));
37
+ const updateHostState = () => {
38
+ setResolvedMode(resolveAppFrameMode(mode));
39
+ setNativeSidebarMaterialAvailable(sidebarMaterialAvailable());
40
+ setSidebarMaterialRegionId(activeSidebarMaterialRegionId());
41
+ };
42
+ updateHostState();
43
+ const updateMode = updateHostState;
22
44
  window.addEventListener('moldable:host-context-change', updateMode);
23
- return () => window.removeEventListener('moldable:host-context-change', updateMode);
45
+ window.addEventListener(MOLDABLE_MATERIAL_REGION_CHANGE_EVENT, updateHostState);
46
+ return () => {
47
+ window.removeEventListener('moldable:host-context-change', updateMode);
48
+ window.removeEventListener(MOLDABLE_MATERIAL_REGION_CHANGE_EVENT, updateHostState);
49
+ };
24
50
  }, [mode]);
25
- return (_jsx("div", { "data-slot": "app-frame", "data-mode": resolvedMode, className: cn('text-foreground flex h-dvh min-h-0 min-w-0 flex-col overflow-hidden bg-[var(--surface-canvas,var(--background))]', className), style: {
26
- paddingInlineStart: 'var(--window-safe-area-inline-start, 0px)',
27
- paddingInlineEnd: 'var(--window-safe-area-inline-end, 0px)',
28
- ...style,
29
- }, ...props }));
51
+ const sidebarMaterialActive = resolvedMode === 'window' && sidebarMaterialRegionId !== null;
52
+ return (_jsx(AppFrameRuntimeContext.Provider, { value: {
53
+ mode: resolvedMode,
54
+ sidebarMaterialAvailable: nativeSidebarMaterialAvailable,
55
+ sidebarMaterialRegionId,
56
+ }, children: _jsx("div", { "data-slot": "app-frame", "data-mode": resolvedMode, "data-native-material-sidebar": sidebarMaterialActive ? 'active' : undefined, className: cn('text-foreground flex h-dvh min-h-0 min-w-0 flex-col overflow-hidden bg-[var(--surface-canvas,var(--background))]', className), style: {
57
+ paddingInlineStart: 'var(--window-safe-area-inline-start, 0px)',
58
+ paddingInlineEnd: 'var(--window-safe-area-inline-end, 0px)',
59
+ ...style,
60
+ ...(sidebarMaterialActive
61
+ ? {
62
+ background: 'linear-gradient(to right, transparent 0 var(--moldable-material-region-sidebar-width), var(--surface-canvas, var(--background)) var(--moldable-material-region-sidebar-width) 100%)',
63
+ }
64
+ : {}),
65
+ }, ...props }) }));
30
66
  }
31
67
  const WINDOW_TITLEBAR_INTERACTIVE_SELECTOR = [
32
68
  'a',
@@ -54,9 +90,9 @@ function postWindowTitlebarMessage(type) {
54
90
  }
55
91
  function AppFrameTitlebar({ className, material = 'regular', onDoubleClick, onPointerDown, style, ...props }) {
56
92
  return (_jsx("header", { "data-slot": "app-frame-titlebar", "data-material": material === 'none' ? undefined : material, "data-material-elevation": material === 'none' ? undefined : 'none', className: cn('border-border/70 flex shrink-0 items-center gap-2 border-b', material !== 'none' && 'moldable-material', className), style: {
57
- minHeight: 'max(var(--density-toolbar-height, 2.5rem), var(--window-titlebar-height, 0px))',
58
- paddingInlineStart: 'max(var(--density-pane-padding, 0.75rem), var(--window-control-inset-inline-start, 0px))',
59
- paddingInlineEnd: 'max(var(--density-pane-padding, 0.75rem), var(--window-control-inset-inline-end, 0px))',
93
+ minHeight: 'max(var(--density-toolbar-height, 2.375rem), var(--window-titlebar-height, 0px))',
94
+ paddingInlineStart: 'max(var(--density-pane-padding, 0.625rem), var(--window-control-inset-inline-start, 0px))',
95
+ paddingInlineEnd: 'max(var(--density-pane-padding, 0.625rem), var(--window-control-inset-inline-end, 0px))',
60
96
  ...style,
61
97
  }, onPointerDown: (event) => {
62
98
  onPointerDown?.(event);
@@ -76,7 +112,7 @@ function AppFrameTitlebar({ className, material = 'regular', onDoubleClick, onPo
76
112
  }, ...props }));
77
113
  }
78
114
  function AppFrameToolbar({ className, ...props }) {
79
- return (_jsx("div", { "data-slot": "app-frame-toolbar", className: cn('flex min-h-9 min-w-0 flex-1 items-center gap-2 px-3 py-1.5', className), ...props }));
115
+ return (_jsx("div", { "data-slot": "app-frame-toolbar", className: cn('flex min-h-row min-w-0 flex-1 items-center gap-control-gap px-control-inline py-1', className), ...props }));
80
116
  }
81
117
  function AppFrameContent({ scrollable = true, chatSafe = true, className, style, ...props }) {
82
118
  return (_jsx("main", { "data-slot": "app-frame-content", "data-scrollable": scrollable, "data-chat-safe": chatSafe, className: cn('min-h-0 min-w-0 flex-1', scrollable ? 'overflow-auto' : 'overflow-hidden', className), style: {
@@ -87,7 +123,7 @@ function AppFrameContent({ scrollable = true, chatSafe = true, className, style,
87
123
  }, ...props }));
88
124
  }
89
125
  function AppFrameStatusbar({ className, material = 'regular', style, ...props }) {
90
- return (_jsx("footer", { "data-slot": "app-frame-statusbar", "data-material": material === 'none' ? undefined : material, "data-material-elevation": material === 'none' ? undefined : 'none', className: cn('border-border/70 text-muted-foreground flex min-h-7 shrink-0 items-center gap-2 border-t px-3 py-1 text-xs', material !== 'none' && 'moldable-material', className), style: {
126
+ return (_jsx("footer", { "data-slot": "app-frame-statusbar", "data-material": material === 'none' ? undefined : material, "data-material-elevation": material === 'none' ? undefined : 'none', className: cn('border-border/70 text-muted-foreground text-ui-caption flex min-h-7 shrink-0 items-center gap-2 border-t px-3 py-1', material !== 'none' && 'moldable-material', className), style: {
91
127
  paddingBlockEnd: 'calc(var(--window-content-inset-bottom, 0px) + 0.25rem)',
92
128
  ...style,
93
129
  }, ...props }));
@@ -1,23 +1,23 @@
1
1
  'use client';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import * as AvatarPrimitive from '@radix-ui/react-avatar';
4
- import { cn } from '../../lib/utils';
4
+ import { cn } from '../../lib/utils.js';
5
5
  function Avatar({ className, size = 'default', ...props }) {
6
- return (_jsx(AvatarPrimitive.Root, { "data-slot": "avatar", "data-size": size, className: cn('group/avatar relative flex size-8 shrink-0 select-none overflow-hidden rounded-full data-[size=lg]:size-10 data-[size=sm]:size-6', className), ...props }));
6
+ return (_jsx(AvatarPrimitive.Root, { "data-slot": "avatar", "data-size": size, className: cn('group/avatar rounded-pill relative flex size-8 shrink-0 select-none overflow-hidden data-[size=lg]:size-10 data-[size=sm]:size-6', className), ...props }));
7
7
  }
8
8
  function AvatarImage({ className, ...props }) {
9
9
  return (_jsx(AvatarPrimitive.Image, { "data-slot": "avatar-image", className: cn('aspect-square size-full', className), ...props }));
10
10
  }
11
11
  function AvatarFallback({ className, ...props }) {
12
- return (_jsx(AvatarPrimitive.Fallback, { "data-slot": "avatar-fallback", className: cn('bg-muted text-muted-foreground flex size-full items-center justify-center rounded-full text-sm group-data-[size=sm]/avatar:text-xs', className), ...props }));
12
+ return (_jsx(AvatarPrimitive.Fallback, { "data-slot": "avatar-fallback", className: cn('bg-muted text-muted-foreground rounded-pill text-ui-body group-data-[size=sm]/avatar:text-ui-caption flex size-full items-center justify-center', className), ...props }));
13
13
  }
14
14
  function AvatarBadge({ className, ...props }) {
15
- return (_jsx("span", { "data-slot": "avatar-badge", className: cn('bg-primary text-primary-foreground ring-background absolute bottom-0 right-0 z-10 inline-flex select-none items-center justify-center rounded-full ring-2', 'group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden', 'group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2', 'group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2', className), ...props }));
15
+ return (_jsx("span", { "data-slot": "avatar-badge", className: cn('bg-primary text-primary-foreground ring-background rounded-pill absolute bottom-0 right-0 z-10 inline-flex select-none items-center justify-center ring-2', 'group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden', 'group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2', 'group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2', className), ...props }));
16
16
  }
17
17
  function AvatarGroup({ className, ...props }) {
18
18
  return (_jsx("div", { "data-slot": "avatar-group", className: cn('*:data-[slot=avatar]:ring-background group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2', className), ...props }));
19
19
  }
20
20
  function AvatarGroupCount({ className, ...props }) {
21
- return (_jsx("div", { "data-slot": "avatar-group-count", className: cn('bg-muted text-muted-foreground ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3 relative flex size-8 shrink-0 items-center justify-center rounded-full text-sm ring-2 [&>svg]:size-4', className), ...props }));
21
+ return (_jsx("div", { "data-slot": "avatar-group-count", className: cn('bg-muted text-muted-foreground ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3 rounded-pill text-ui-body relative flex size-8 shrink-0 items-center justify-center ring-2 [&>svg]:size-4', className), ...props }));
22
22
  }
23
23
  export { Avatar, AvatarImage, AvatarFallback, AvatarBadge, AvatarGroup, AvatarGroupCount, };
@@ -1,7 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import { type VariantProps } from 'class-variance-authority';
3
3
  declare const badgeVariants: (props?: ({
4
- variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
4
+ variant?: "link" | "default" | "outline" | "destructive" | "secondary" | "ghost" | null | undefined;
5
5
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
6
  declare function Badge({ className, variant, asChild, ...props }: React.ComponentProps<'span'> & VariantProps<typeof badgeVariants> & {
7
7
  asChild?: boolean;
@@ -1,14 +1,14 @@
1
1
  'use client';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import { Slot } from '@radix-ui/react-slot';
4
- import { cn } from '../../lib/utils';
4
+ import { cn } from '../../lib/utils.js';
5
5
  import { cva } from 'class-variance-authority';
6
- const badgeVariants = cva('inline-flex items-center justify-center rounded-full border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden', {
6
+ const badgeVariants = cva('text-ui-caption inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-pill border border-transparent px-2 py-0.5 font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring aria-invalid:border-destructive [&>svg]:pointer-events-none [&>svg]:size-3', {
7
7
  variants: {
8
8
  variant: {
9
9
  default: 'bg-primary text-primary-foreground [a&]:hover:bg-primary/90',
10
- secondary: 'bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90',
11
- destructive: 'bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60',
10
+ secondary: 'bg-neutral/12 text-neutral-foreground [a&]:hover:bg-neutral/18',
11
+ destructive: 'bg-destructive text-white [a&]:hover:bg-destructive/90 dark:bg-destructive/60',
12
12
  outline: 'border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground',
13
13
  ghost: '[a&]:hover:bg-accent [a&]:hover:text-accent-foreground',
14
14
  link: 'text-primary underline-offset-4 [a&]:hover:underline',
@@ -2,12 +2,12 @@
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import { Slot } from '@radix-ui/react-slot';
4
4
  import { ChevronRight, MoreHorizontal } from 'lucide-react';
5
- import { cn } from '../../lib/utils';
5
+ import { cn } from '../../lib/utils.js';
6
6
  function Breadcrumb({ ...props }) {
7
7
  return _jsx("nav", { "aria-label": "breadcrumb", "data-slot": "breadcrumb", ...props });
8
8
  }
9
9
  function BreadcrumbList({ className, ...props }) {
10
- return (_jsx("ol", { "data-slot": "breadcrumb-list", className: cn('text-muted-foreground flex flex-wrap items-center gap-1.5 break-words text-sm sm:gap-2.5', className), ...props }));
10
+ return (_jsx("ol", { "data-slot": "breadcrumb-list", className: cn('text-muted-foreground text-ui-body flex flex-wrap items-center gap-1.5 break-words sm:gap-2.5', className), ...props }));
11
11
  }
12
12
  function BreadcrumbItem({ className, ...props }) {
13
13
  return (_jsx("li", { "data-slot": "breadcrumb-item", className: cn('inline-flex items-center gap-1.5', className), ...props }));
@@ -1,4 +1,4 @@
1
- import { Separator } from './separator';
1
+ import { Separator } from './separator.js';
2
2
  import { type VariantProps } from 'class-variance-authority';
3
3
  declare const buttonGroupVariants: (props?: ({
4
4
  orientation?: "vertical" | "horizontal" | null | undefined;
@@ -1,10 +1,10 @@
1
1
  'use client';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  import { Slot } from '@radix-ui/react-slot';
4
- import { cn } from '../../lib/utils';
5
- import { Separator } from './separator';
4
+ import { cn } from '../../lib/utils.js';
5
+ import { Separator } from './separator.js';
6
6
  import { cva } from 'class-variance-authority';
7
- const buttonGroupVariants = cva("flex w-fit items-stretch [&>*]:focus-visible:z-10 [&>*]:focus-visible:relative [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-md has-[>[data-slot=button-group]]:gap-2", {
7
+ const buttonGroupVariants = cva("flex w-fit items-stretch [&>*]:focus-visible:z-10 [&>*]:focus-visible:relative [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-control has-[>[data-slot=button-group]]:gap-2", {
8
8
  variants: {
9
9
  orientation: {
10
10
  horizontal: '[&>*:not(:first-child)]:rounded-l-none [&>*:not(:first-child)]:border-l-0 [&>*:not(:last-child)]:rounded-r-none',
@@ -20,7 +20,7 @@ function ButtonGroup({ className, orientation, ...props }) {
20
20
  }
21
21
  function ButtonGroupText({ className, asChild = false, ...props }) {
22
22
  const Comp = asChild ? Slot : 'div';
23
- return (_jsx(Comp, { className: cn("bg-muted shadow-xs flex items-center gap-2 rounded-md border px-4 text-sm font-medium [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none", className), ...props }));
23
+ return (_jsx(Comp, { className: cn("bg-muted shadow-xs rounded-control text-ui-body flex items-center gap-control-gap border px-control-inline font-medium [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none", className), ...props }));
24
24
  }
25
25
  function ButtonGroupSeparator({ className, orientation = 'vertical', ...props }) {
26
26
  return (_jsx(Separator, { "data-slot": "button-group-separator", orientation: orientation, className: cn('bg-input relative !m-0 self-stretch data-[orientation=vertical]:h-auto', className), ...props }));
@@ -1,11 +1,13 @@
1
1
  import * as React from 'react';
2
2
  import { type VariantProps } from 'class-variance-authority';
3
3
  declare const buttonVariants: (props?: ({
4
- variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
5
- size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
4
+ variant?: "link" | "default" | "outline" | "destructive" | "secondary" | "ghost" | null | undefined;
5
+ size?: "default" | "sm" | "xs" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
6
6
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
- declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
7
+ type ButtonProps = React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
8
8
  asChild?: boolean;
9
- }): import("react/jsx-runtime").JSX.Element;
9
+ loading?: boolean;
10
+ };
11
+ declare function Button({ 'aria-busy': ariaBusy, children, className, disabled, loading, onClick, onKeyDown, variant, size, asChild, ...props }: ButtonProps): import("react/jsx-runtime").JSX.Element;
10
12
  export { Button, buttonVariants };
11
13
  //# sourceMappingURL=button.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../src/components/ui/button.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,0BAA0B,CAAA;AAEjE,QAAA,MAAM,cAAc;;;8EAgCnB,CAAA;AAED,iBAAS,MAAM,CAAC,EACd,SAAS,EACT,OAAmB,EACnB,IAAgB,EAChB,OAAe,EACf,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,QAAQ,CAAC,GAC/B,YAAY,CAAC,OAAO,cAAc,CAAC,GAAG;IACpC,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,2CAYF;AAED,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,CAAA"}
1
+ {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../src/components/ui/button.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAG9B,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,0BAA0B,CAAA;AAEjE,QAAA,MAAM,cAAc;;;8EAmCnB,CAAA;AAED,KAAK,WAAW,GAAG,KAAK,CAAC,cAAc,CAAC,QAAQ,CAAC,GAC/C,YAAY,CAAC,OAAO,cAAc,CAAC,GAAG;IACpC,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,CAAA;AA4CH,iBAAS,MAAM,CAAC,EACd,WAAW,EAAE,QAAQ,EACrB,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,OAAe,EACf,OAAO,EACP,SAAS,EACT,OAAmB,EACnB,IAAgB,EAChB,OAAe,EACf,GAAG,KAAK,EACT,EAAE,WAAW,2CAqDb;AAED,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,CAAA"}