@opengeni/react 6.36.0 → 6.36.1-canary.45113772604001

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 (1087) hide show
  1. package/dist/app/app-state.js +10 -10
  2. package/dist/app/components/Composer.js +19 -19
  3. package/dist/app/components/agent/agent-capability-picker.js +6 -6
  4. package/dist/app/components/agents/agent-can-use.js +21 -20
  5. package/dist/app/components/agents/agent-form-page.js +69 -65
  6. package/dist/app/components/agents/agent-form-page.js.map +1 -1
  7. package/dist/app/components/agents/agent-page.js +68 -64
  8. package/dist/app/components/agents/agent-setup-sections.js +40 -36
  9. package/dist/app/components/agents/agent-skills.js +5 -5
  10. package/dist/app/components/agents/agent-trigger-chat-field.js +4 -4
  11. package/dist/app/components/agents/agent-trigger-dialog.js +20 -17
  12. package/dist/app/components/agents/agent-trigger-model.d.ts +14 -0
  13. package/dist/app/components/agents/agent-trigger-picker.js +6 -5
  14. package/dist/app/components/agents/agent-trigger-repositories.d.ts +9 -0
  15. package/dist/app/components/agents/agent-trigger-repositories.js +31 -0
  16. package/dist/app/components/agents/agents-page.css +1905 -0
  17. package/dist/app/components/agents/agents-page.css.map +1 -0
  18. package/dist/app/components/agents/agents-page.js +106 -61
  19. package/dist/app/components/agents/agents-page.js.map +1 -1
  20. package/dist/app/components/agents/composer-agent-chip.js +29 -29
  21. package/dist/app/components/agents/session-agent-chip.js +29 -29
  22. package/dist/app/components/artifacts/app-package.js +3 -3
  23. package/dist/app/components/artifacts/app-server-status.d.ts +22 -0
  24. package/dist/app/components/artifacts/app-server-status.js +13 -0
  25. package/dist/app/components/artifacts/artifact-library.css +1905 -0
  26. package/dist/app/components/artifacts/artifact-library.css.map +1 -0
  27. package/dist/app/components/artifacts/artifact-library.js +8 -8
  28. package/dist/app/components/artifacts/artifact-viewer.css +1905 -0
  29. package/dist/app/components/artifacts/artifact-viewer.css.map +1 -0
  30. package/dist/app/components/artifacts/artifact-viewer.js +30 -30
  31. package/dist/app/components/artifacts/chat-interactive-block.js +16 -16
  32. package/dist/app/components/artifacts/file-reach-dialog.js +6 -6
  33. package/dist/app/components/artifacts/inline-chat-image.js +28 -28
  34. package/dist/app/components/artifacts/ready-made-apps.css +1905 -0
  35. package/dist/app/components/artifacts/ready-made-apps.css.map +1 -0
  36. package/dist/app/components/artifacts/ready-made-apps.d.ts +3 -0
  37. package/dist/app/components/artifacts/ready-made-apps.js +40 -0
  38. package/dist/app/components/artifacts/retained-file-preview.js +30 -30
  39. package/dist/app/components/artifacts/retained-text-preview.js +3 -3
  40. package/dist/app/components/artifacts/site-actions.js +1 -1
  41. package/dist/app/components/artifacts/site-audience.js +3 -3
  42. package/dist/app/components/artifacts/site-conversations.js +15 -15
  43. package/dist/app/components/artifacts/site-data.js +11 -11
  44. package/dist/app/components/artifacts/site-publishing-page.js +32 -32
  45. package/dist/app/components/artifacts/site-publishing.js +24 -24
  46. package/dist/app/components/artifacts/site-settings.js +31 -31
  47. package/dist/app/components/artifacts/site-version-menu.js +4 -4
  48. package/dist/app/components/billing-class-mark.js +3 -3
  49. package/dist/app/components/capabilities/capability-detail-sheet.js +7 -7
  50. package/dist/app/components/capabilities/capability-logo-source.js +15 -14
  51. package/dist/app/components/capabilities/connector-tool-permissions.js +4 -4
  52. package/dist/app/components/capabilities/native-connect-setup.js +16 -15
  53. package/dist/app/components/capabilities/own-logins-shared-heads-up.js +3 -3
  54. package/dist/app/components/capabilities/perform-capability-action.js +1 -1
  55. package/dist/app/components/capabilities/prepared-mcp-setup-card.js +17 -16
  56. package/dist/app/components/capabilities/session-capability-card.js +70 -69
  57. package/dist/app/components/capabilities/session-capability-card.js.map +1 -1
  58. package/dist/app/components/capabilities/session-chrome-card.js +22 -22
  59. package/dist/app/components/capabilities/session-connect-inputs-card.js +16 -15
  60. package/dist/app/components/capabilities/session-custom-mcp-card.js +18 -17
  61. package/dist/app/components/capabilities/session-github-card.js +19 -18
  62. package/dist/app/components/capabilities/session-machine-card.js +21 -21
  63. package/dist/app/components/capabilities/session-personal-github-card.js +16 -15
  64. package/dist/app/components/capabilities/session-plugin-card.js +9 -9
  65. package/dist/app/components/capabilities/use-connection-accounts.js +1 -1
  66. package/dist/app/components/command-menu/chat-status.js +18 -18
  67. package/dist/app/components/command-menu/chat-switcher.js +47 -47
  68. package/dist/app/components/command-menu/command-menu.js +58 -58
  69. package/dist/app/components/command-menu/shortcut-sheet.js +15 -15
  70. package/dist/app/components/composer-capabilities-menu-body.js +4 -4
  71. package/dist/app/components/composer-mobile-plus-panel.js +9 -9
  72. package/dist/app/components/composer-mobile-plus.js +1 -1
  73. package/dist/app/components/credit-required-gate.js +1 -1
  74. package/dist/app/components/credit-required-prompt.js +11 -11
  75. package/dist/app/components/credits/checkout-credits-celebration.js +2 -2
  76. package/dist/app/components/credits/checkout-return.js +2 -2
  77. package/dist/app/components/credits/credit-refusal-notice.js +2 -2
  78. package/dist/app/components/desktop/app-shots.js +7 -7
  79. package/dist/app/components/desktop/computer-use.js +2 -2
  80. package/dist/app/components/desktop/this-computer.js +5 -5
  81. package/dist/app/components/feedback.js +3 -3
  82. package/dist/app/components/follow-up-repository-menu-body.js +2 -2
  83. package/dist/app/components/follow-up-repository-picker.js +1 -1
  84. package/dist/app/components/github-app-connect-launcher.js +1 -1
  85. package/dist/app/components/machines/connect-machine-dialog.js +11 -11
  86. package/dist/app/components/markdown.js +7 -7
  87. package/dist/app/components/models/models-ui.js +6 -6
  88. package/dist/app/components/models/subscription-usage.js +5 -5
  89. package/dist/app/components/my-things.js +4 -4
  90. package/dist/app/components/own-where-it-works.js +3 -3
  91. package/dist/app/components/personal-resource-attachment-surface.js +4 -4
  92. package/dist/app/components/pickers.js +6 -6
  93. package/dist/app/components/rail/channel-create-dialog.js +3 -3
  94. package/dist/app/components/rail/project-glyph.js +29 -29
  95. package/dist/app/components/rail/project-profile.js +36 -36
  96. package/dist/app/components/rail/rail-context.js +1 -1
  97. package/dist/app/components/rail/rail-sections.js +80 -80
  98. package/dist/app/components/rail/session-header.js +64 -64
  99. package/dist/app/components/rail/session-list.js +78 -78
  100. package/dist/app/components/rail/session-row-content.js +4 -4
  101. package/dist/app/components/rail/session-row-hover-details.js +20 -20
  102. package/dist/app/components/rail/session-shell.js +102 -102
  103. package/dist/app/components/rail/site-session-group-heading.js +14 -14
  104. package/dist/app/components/repository-picker.js +2 -2
  105. package/dist/app/components/session/agent-configuration-panel.js +16 -16
  106. package/dist/app/components/session/artifact-session-page.js +1 -1
  107. package/dist/app/components/session/banners.js +9 -9
  108. package/dist/app/components/session/chat-avatar.js +29 -29
  109. package/dist/app/components/session/console-new-conversation.js +51 -51
  110. package/dist/app/components/session/descendant-requests.js +46 -46
  111. package/dist/app/components/session/editable-artifacts-workspace.css +1905 -0
  112. package/dist/app/components/session/editable-artifacts-workspace.css.map +1 -0
  113. package/dist/app/components/session/editable-artifacts-workspace.js +22 -22
  114. package/dist/app/components/session/failed-session-banner.js +10 -10
  115. package/dist/app/components/session/failure-recovery-boundary.js +3 -3
  116. package/dist/app/components/session/human-input-delegation-record.js +2 -2
  117. package/dist/app/components/session/human-input.js +42 -42
  118. package/dist/app/components/session/inspector.js +56 -56
  119. package/dist/app/components/session/linked-panel.js +3 -3
  120. package/dist/app/components/session/message-actions.js +3 -3
  121. package/dist/app/components/session/model-recovery-notice.js +3 -3
  122. package/dist/app/components/session/new-session-settings-menu.js +11 -11
  123. package/dist/app/components/session/new-session-setup-strip.js +30 -30
  124. package/dist/app/components/session/pull-request-panel.js +11 -11
  125. package/dist/app/components/session/sandbox-recovery-actions.js +3 -3
  126. package/dist/app/components/session/sandbox-switcher.js +8 -8
  127. package/dist/app/components/session/sandbox-workspace.js +58 -58
  128. package/dist/app/components/session/search-markdown-highlight.js +8 -8
  129. package/dist/app/components/session/search-results-view.js +9 -9
  130. package/dist/app/components/session/session-admin-access.js +4 -4
  131. package/dist/app/components/session/session-admission-notice.js +4 -4
  132. package/dist/app/components/session/session-avatar-picker.js +30 -30
  133. package/dist/app/components/session/session-avatar.js +28 -28
  134. package/dist/app/components/session/session-machine-access-notice.js +4 -4
  135. package/dist/app/components/session/session-profile-dialog.js +34 -34
  136. package/dist/app/components/session/session-profile-editor.js +35 -35
  137. package/dist/app/components/session/session-retention.js +4 -4
  138. package/dist/app/components/session/session-search-dialog.js +9 -9
  139. package/dist/app/components/session/session-tenancy-control.js +8 -8
  140. package/dist/app/components/session/session-usage-limit-section.js +4 -4
  141. package/dist/app/components/session/share-chat-dialog.js +6 -6
  142. package/dist/app/components/session/subagents.js +13 -13
  143. package/dist/app/components/session/subscription-account-indicator.js +11 -11
  144. package/dist/app/components/session/subscription-account-menu.js +6 -6
  145. package/dist/app/components/settings/row-select.js +4 -4
  146. package/dist/app/components/toaster.js +2 -2
  147. package/dist/app/components/transcription-settings.js +6 -6
  148. package/dist/app/components/ui/destructive-confirm.js +5 -5
  149. package/dist/app/components/usage/usage-entry.js +3 -3
  150. package/dist/app/components/window-bar.js +13 -13
  151. package/dist/app/components/workspace-composer-plus.js +18 -17
  152. package/dist/app/components/workspace-reach.js +4 -4
  153. package/dist/app/embed/session-app.js +241 -240
  154. package/dist/app/lib/actions/actions-provider.js +12 -12
  155. package/dist/app/lib/agent-capabilities.js +3 -3
  156. package/dist/app/lib/app-connect-card.js +9 -9
  157. package/dist/app/lib/app-shared-key-dialog.js +4 -4
  158. package/dist/app/lib/app-sync-opt-in.js +3 -3
  159. package/dist/app/lib/codex-usage-query.js +2 -2
  160. package/dist/app/lib/composer-connectors.js +16 -15
  161. package/dist/app/lib/console-site.js +5 -5
  162. package/dist/app/lib/console-text.js +2 -2
  163. package/dist/app/lib/events.js +18 -18
  164. package/dist/app/lib/failed-session-copy.js +3 -3
  165. package/dist/app/lib/model-access-onboarding.js +3 -3
  166. package/dist/app/lib/move-chat-to-machine.js +3 -3
  167. package/dist/app/lib/needs-you.d.ts +2 -1
  168. package/dist/app/lib/needs-you.js +1 -1
  169. package/dist/app/lib/ready-made-apps.d.ts +14 -0
  170. package/dist/app/lib/ready-made-apps.js +8 -0
  171. package/dist/app/lib/session-branch-cache.js +13 -13
  172. package/dist/app/lib/session-capabilities.js +1 -1
  173. package/dist/app/lib/session-create.js +4 -4
  174. package/dist/app/lib/session-group-pagination.js +13 -13
  175. package/dist/app/lib/session-hover-facts.js +17 -17
  176. package/dist/app/lib/session-list-dirty-scopes.js +14 -14
  177. package/dist/app/lib/session-model.js +2 -2
  178. package/dist/app/lib/session-rail.js +10 -10
  179. package/dist/app/lib/session-rename.js +3 -3
  180. package/dist/app/lib/sessions-group.js +12 -12
  181. package/dist/app/lib/site-tool-consent-dialog.js +8 -8
  182. package/dist/app/lib/site-tool-consent.js +1 -1
  183. package/dist/app/lib/turn-failure-analytics.js +4 -4
  184. package/dist/app/lib/use-follow-up-repositories.js +3 -3
  185. package/dist/app/lib/use-workspace-machines.js +4 -4
  186. package/dist/app/lib/use-workspace-model-catalog.js +3 -3
  187. package/dist/app/lib/use-workspace-rigs.js +2 -2
  188. package/dist/app/lib/workspace-navigation-preference.js +4 -4
  189. package/dist/app/lib/workspace-scope-context.js +3 -3
  190. package/dist/app/routes/app-page-view.js +10 -10
  191. package/dist/app/routes/app-page.js +1 -1
  192. package/dist/app/routes/artifacts.css +1905 -0
  193. package/dist/app/routes/artifacts.css.map +1 -0
  194. package/dist/app/routes/artifacts.js +105 -94
  195. package/dist/app/routes/artifacts.js.map +1 -1
  196. package/dist/app/routes/retained-artifact.js +47 -47
  197. package/dist/app/routes/session-unavailable.js +2 -2
  198. package/dist/app/routes/session.js +131 -130
  199. package/dist/app/routes/sessions-index-hydration.js +5 -5
  200. package/dist/app/routes/sessions-index.js +108 -107
  201. package/dist/app/routes/site-view.js +107 -95
  202. package/dist/app/routes/site-view.js.map +1 -1
  203. package/dist/approval-review-model.js +2 -2
  204. package/dist/artifacts-document.js +4 -4
  205. package/dist/artifacts-presentation.js +5 -5
  206. package/dist/artifacts-spreadsheet.js +4 -4
  207. package/dist/artifacts.js +15 -15
  208. package/dist/automation-model.js +5 -5
  209. package/dist/automations.d.ts +1 -0
  210. package/dist/automations.js +29 -22
  211. package/dist/automations.js.map +1 -1
  212. package/dist/browser-viewer-EPGAK2W6.js +23 -0
  213. package/dist/chat-interactive-block-65YU6TMO.js +22 -0
  214. package/dist/chunk-25ODMMHH.js +403 -0
  215. package/dist/chunk-266ZPUMH.js +400 -0
  216. package/dist/chunk-2A7SB7UR.js +168 -0
  217. package/dist/chunk-2EU4Y7A7.js +100 -0
  218. package/dist/chunk-2F7VSGRS.js +1177 -0
  219. package/dist/chunk-2F7VSGRS.js.map +1 -0
  220. package/dist/chunk-2L6B6766.js +5915 -0
  221. package/dist/chunk-2L6B6766.js.map +1 -0
  222. package/dist/chunk-2LBYEHBH.js +570 -0
  223. package/dist/chunk-2MHIIF4N.js +141 -0
  224. package/dist/chunk-2SHWGDAA.js +283 -0
  225. package/dist/chunk-2VX42S4W.js +773 -0
  226. package/dist/chunk-2WGJQ4XK.js +311 -0
  227. package/dist/chunk-2XSF44TY.js +15 -0
  228. package/dist/chunk-33HUZMNE.js +639 -0
  229. package/dist/chunk-36IKHM4Q.js +148 -0
  230. package/dist/chunk-3JVQZAXQ.js +4480 -0
  231. package/dist/chunk-3SDESU6U.js +287 -0
  232. package/dist/chunk-3VXZFBP6.js +292 -0
  233. package/dist/chunk-3WDNCSVU.js +197 -0
  234. package/dist/chunk-3WDNCSVU.js.map +1 -0
  235. package/dist/chunk-3YKED2ZV.js +307 -0
  236. package/dist/chunk-3ZNOKD3S.js +1019 -0
  237. package/dist/chunk-45SB4UK3.js +2580 -0
  238. package/dist/chunk-47BETTVA.js +133 -0
  239. package/dist/chunk-4BTQ473O.js +274 -0
  240. package/dist/chunk-4JQRWJVR.js +249 -0
  241. package/dist/chunk-4NGIKV2W.js +316 -0
  242. package/dist/chunk-4NGIKV2W.js.map +1 -0
  243. package/dist/chunk-4R6WFQKZ.js +202 -0
  244. package/dist/chunk-4WEPVL7X.js +283 -0
  245. package/dist/chunk-4YWHOAB4.js +201 -0
  246. package/dist/chunk-52XGYRVS.js +155 -0
  247. package/dist/chunk-5G6UHUJZ.js +43 -0
  248. package/dist/chunk-5HFITPHH.js +229 -0
  249. package/dist/chunk-5LVVN2K7.js +650 -0
  250. package/dist/chunk-5PVXFVIT.js +48 -0
  251. package/dist/chunk-5WFGW7B7.js +187 -0
  252. package/dist/chunk-5YMSLKJP.js +92 -0
  253. package/dist/chunk-5YMSLKJP.js.map +1 -0
  254. package/dist/chunk-66M7RVM6.js +3070 -0
  255. package/dist/chunk-6AGNZI2W.js +437 -0
  256. package/dist/chunk-6ENO634Y.js +373 -0
  257. package/dist/chunk-6LQ5KEMP.js +200 -0
  258. package/dist/chunk-6QGIWLH5.js +428 -0
  259. package/dist/chunk-6WEDWD4N.js +170 -0
  260. package/dist/chunk-6YCYPXDA.js +114 -0
  261. package/dist/chunk-6YTNMDFP.js +318 -0
  262. package/dist/chunk-73O7NO3F.js +50 -0
  263. package/dist/chunk-76VXLTQF.js +251 -0
  264. package/dist/chunk-7EJ7PSZT.js +93 -0
  265. package/dist/chunk-7GS2MGFU.js +27 -0
  266. package/dist/chunk-7MF6MFHS.js +406 -0
  267. package/dist/chunk-7N35XBSC.js +386 -0
  268. package/dist/chunk-7ND2VMKV.js +270 -0
  269. package/dist/chunk-7RVJLO3N.js +154 -0
  270. package/dist/chunk-7VAILBP6.js +353 -0
  271. package/dist/chunk-7VSJQWFO.js +37 -0
  272. package/dist/chunk-7YKUIKGH.js +335 -0
  273. package/dist/chunk-A7DS77WC.js +138 -0
  274. package/dist/chunk-ABGHRGID.js +376 -0
  275. package/dist/chunk-ABGHRGID.js.map +1 -0
  276. package/dist/chunk-AEH34OOU.js +298 -0
  277. package/dist/chunk-ANWMRO2G.js +554 -0
  278. package/dist/chunk-APGUIORF.js +247 -0
  279. package/dist/chunk-ASCVQJB4.js +1309 -0
  280. package/dist/chunk-AVYFJKQS.js +10044 -0
  281. package/dist/chunk-AVYFJKQS.js.map +1 -0
  282. package/dist/chunk-AY4XH73V.js +1333 -0
  283. package/dist/chunk-B6AH43UQ.js +2434 -0
  284. package/dist/chunk-BBZUHH4F.js +154 -0
  285. package/dist/chunk-BBZUHH4F.js.map +1 -0
  286. package/dist/chunk-BGT43KDL.js +42 -0
  287. package/dist/chunk-BHS4KW4W.js +3851 -0
  288. package/dist/chunk-BJUDGPOD.js +1803 -0
  289. package/dist/chunk-BJUDGPOD.js.map +1 -0
  290. package/dist/chunk-BNWO72C2.js +851 -0
  291. package/dist/chunk-BSPIASSQ.js +2551 -0
  292. package/dist/chunk-BVWJEZXG.js +230 -0
  293. package/dist/chunk-BZ47G3VP.js +366 -0
  294. package/dist/chunk-C6KI5P3H.js +72 -0
  295. package/dist/chunk-CLERWAEA.js +2317 -0
  296. package/dist/chunk-CNRFFCAE.js +572 -0
  297. package/dist/chunk-CPC6CYVW.js +236 -0
  298. package/dist/chunk-D23UAPXK.js +107 -0
  299. package/dist/chunk-DAPZEB4R.js +29 -0
  300. package/dist/chunk-DEDEA3WS.js +205 -0
  301. package/dist/chunk-DHVA3T3K.js +271 -0
  302. package/dist/chunk-DJQ6TKIP.js +391 -0
  303. package/dist/chunk-DK2CDAMR.js +33 -0
  304. package/dist/chunk-DPOB6MUS.js +278 -0
  305. package/dist/chunk-DSO7S6PZ.js +137 -0
  306. package/dist/chunk-DV3OECO6.js +333 -0
  307. package/dist/chunk-DW2IQRMB.js +1187 -0
  308. package/dist/chunk-DWLPQTDL.js +134 -0
  309. package/dist/chunk-DXMKECFR.js +3176 -0
  310. package/dist/chunk-DYQRNIID.js +73 -0
  311. package/dist/chunk-DZLWO73N.js +129 -0
  312. package/dist/chunk-DZZSFPMW.js +66 -0
  313. package/dist/chunk-DZZSFPMW.js.map +1 -0
  314. package/dist/chunk-E2GNUL64.js +107 -0
  315. package/dist/chunk-E7XU2KHD.js +192 -0
  316. package/dist/chunk-ENYULVQW.js +114 -0
  317. package/dist/chunk-EWHQ3DFM.js +41 -0
  318. package/dist/chunk-F2T4J7CK.js +4957 -0
  319. package/dist/chunk-F2T4J7CK.js.map +1 -0
  320. package/dist/chunk-F3LIUDXN.js +738 -0
  321. package/dist/chunk-F5C7DTVR.js +103 -0
  322. package/dist/chunk-F5NFGBIN.js +391 -0
  323. package/dist/chunk-F6XJLGOV.js +175 -0
  324. package/dist/chunk-F7T2STMX.js +158 -0
  325. package/dist/chunk-FAEVOM6B.js +371 -0
  326. package/dist/chunk-FCFAXQDM.js +276 -0
  327. package/dist/chunk-FEQVCQMK.js +138 -0
  328. package/dist/chunk-FLD4VOJW.js +4565 -0
  329. package/dist/chunk-FLD4VOJW.js.map +1 -0
  330. package/dist/chunk-FLDF2Z44.js +396 -0
  331. package/dist/chunk-GADABL3P.js +772 -0
  332. package/dist/chunk-GFUDB3SA.js +140 -0
  333. package/dist/chunk-GGPZPBHS.js +215 -0
  334. package/dist/chunk-GIEGIEMT.js +311 -0
  335. package/dist/chunk-GKWFQEO3.js +187 -0
  336. package/dist/chunk-GMMB4NCN.js +250 -0
  337. package/dist/chunk-GN4FOL2G.js +269 -0
  338. package/dist/chunk-GQJAMANY.js +469 -0
  339. package/dist/chunk-H7F4ANJQ.js +379 -0
  340. package/dist/chunk-HEPFJ3XQ.js +3110 -0
  341. package/dist/chunk-HLRAQITA.js +234 -0
  342. package/dist/chunk-HXYSZKCC.js +117 -0
  343. package/dist/chunk-I5Q6FVHP.js +828 -0
  344. package/dist/chunk-I7M5BYJU.js +265 -0
  345. package/dist/chunk-IH3J7VWW.js +85 -0
  346. package/dist/chunk-IMMDXSZ4.js +178 -0
  347. package/dist/chunk-IOMZDY5D.js +199 -0
  348. package/dist/chunk-IQTCUUDF.js +1236 -0
  349. package/dist/chunk-ISR6KXWT.js +898 -0
  350. package/dist/chunk-IWPPGXUZ.js +3321 -0
  351. package/dist/chunk-IYKO6BBK.js +3854 -0
  352. package/dist/chunk-IYKO6BBK.js.map +1 -0
  353. package/dist/chunk-IYUZPNMU.js +79 -0
  354. package/dist/chunk-IYUZPNMU.js.map +1 -0
  355. package/dist/chunk-JNPCRNPA.js +84 -0
  356. package/dist/chunk-JSJGGP32.js +505 -0
  357. package/dist/chunk-JZZUEJYD.js +56 -0
  358. package/dist/chunk-K5XFZKK5.js +270 -0
  359. package/dist/chunk-K6GRTSEA.js +65 -0
  360. package/dist/chunk-KA4PZU3Q.js +103 -0
  361. package/dist/chunk-KGZ35ESO.js +83 -0
  362. package/dist/chunk-KRM4PW5N.js +1021 -0
  363. package/dist/chunk-KSNKF6FE.js +551 -0
  364. package/dist/chunk-KSNKF6FE.js.map +1 -0
  365. package/dist/chunk-LEZGGRDQ.js +1095 -0
  366. package/dist/chunk-LFWMFFKT.js +144 -0
  367. package/dist/chunk-LKSPUZPH.js +849 -0
  368. package/dist/chunk-LLX4S6BI.js +401 -0
  369. package/dist/chunk-M4WEF4DZ.js +850 -0
  370. package/dist/chunk-MATYGLUT.js +121 -0
  371. package/dist/chunk-MDI6SH7B.js +27 -0
  372. package/dist/chunk-MQO7MSA6.js +43 -0
  373. package/dist/chunk-MQO7MSA6.js.map +1 -0
  374. package/dist/chunk-MQTYIBY6.js +263 -0
  375. package/dist/chunk-MRKY2GL5.js +1185 -0
  376. package/dist/chunk-MSIQ42IY.js +794 -0
  377. package/dist/chunk-MVGU7BET.js +357 -0
  378. package/dist/chunk-MWY4TBDY.js +404 -0
  379. package/dist/chunk-NGQCWCD6.js +234 -0
  380. package/dist/chunk-NKXMIOYN.js +538 -0
  381. package/dist/chunk-NMVRFFCR.js +256 -0
  382. package/dist/chunk-NNTDIKJP.js +407 -0
  383. package/dist/chunk-NQXCPP4G.js +98 -0
  384. package/dist/chunk-NYGS6FNV.js +132 -0
  385. package/dist/chunk-O3LOQDTI.js +176 -0
  386. package/dist/chunk-O5HRZ2KG.js +818 -0
  387. package/dist/chunk-O5PZRVQR.js +214 -0
  388. package/dist/chunk-O6KR5SN7.js +399 -0
  389. package/dist/chunk-OBKDRV2H.js +259 -0
  390. package/dist/chunk-OBKKUBGL.js +107 -0
  391. package/dist/chunk-OFYXDB6I.js +52 -0
  392. package/dist/chunk-OLMWJGSJ.js +50 -0
  393. package/dist/chunk-OO7N6APA.js +598 -0
  394. package/dist/chunk-OO7N6APA.js.map +1 -0
  395. package/dist/chunk-ORRACKLB.js +1263 -0
  396. package/dist/chunk-P426WWAB.js +351 -0
  397. package/dist/chunk-P4GOY3ZL.js +177 -0
  398. package/dist/chunk-P4KVJLUC.js +129 -0
  399. package/dist/chunk-P4N7ZS6W.js +56 -0
  400. package/dist/chunk-P6LSLNSL.js +209 -0
  401. package/dist/chunk-P7MQCSML.js +77 -0
  402. package/dist/chunk-P7MQCSML.js.map +1 -0
  403. package/dist/chunk-PAFSIDM2.js +111 -0
  404. package/dist/chunk-PC2JAIAH.js +117 -0
  405. package/dist/chunk-PGSXT5OY.js +207 -0
  406. package/dist/chunk-QDMGUTOU.js +2984 -0
  407. package/dist/chunk-QEMDQKQT.js +1356 -0
  408. package/dist/chunk-QK7VU5N3.js +2412 -0
  409. package/dist/chunk-QL4Q332Z.js +12 -0
  410. package/dist/chunk-QL5227KT.js +1184 -0
  411. package/dist/chunk-QREYGVWO.js +297 -0
  412. package/dist/chunk-QREYGVWO.js.map +1 -0
  413. package/dist/chunk-QUFCZMHG.js +114 -0
  414. package/dist/chunk-QXPKUKOV.js +227 -0
  415. package/dist/chunk-QZE3KD34.js +441 -0
  416. package/dist/chunk-RAIUIXCY.js +166 -0
  417. package/dist/chunk-RDLS6IZY.js +723 -0
  418. package/dist/chunk-RKPETJDJ.js +175 -0
  419. package/dist/chunk-RMDLTRLI.js +372 -0
  420. package/dist/chunk-RR6DQN4X.js +523 -0
  421. package/dist/chunk-RVPH6BB7.js +218 -0
  422. package/dist/chunk-RVXLSVJH.js +931 -0
  423. package/dist/chunk-RVY5EZNU.js +246 -0
  424. package/dist/chunk-RWHBX4MN.js +1024 -0
  425. package/dist/chunk-RWHDMGFG.js +214 -0
  426. package/dist/chunk-RYB3WBMZ.js +113 -0
  427. package/dist/chunk-S7EO77EE.js +449 -0
  428. package/dist/chunk-S7J4HBPP.js +584 -0
  429. package/dist/chunk-SA3XI7FB.js +108 -0
  430. package/dist/chunk-SKRTCSUL.js +196 -0
  431. package/dist/chunk-SUWDILUY.js +5089 -0
  432. package/dist/chunk-SWTPVMR4.js +251 -0
  433. package/dist/chunk-T5BYEE66.js +191 -0
  434. package/dist/chunk-T652Q4R6.js +48 -0
  435. package/dist/chunk-TBUOHK6R.js +608 -0
  436. package/dist/chunk-TCUAGCAX.js +1628 -0
  437. package/dist/chunk-TLWH4E3P.js +126 -0
  438. package/dist/chunk-TNHGSWG3.js +1152 -0
  439. package/dist/chunk-TO6VBJI3.js +383 -0
  440. package/dist/chunk-TOL7MOAN.js +162 -0
  441. package/dist/chunk-U243CBVZ.js +2553 -0
  442. package/dist/chunk-U2CEPRDH.js +46 -0
  443. package/dist/chunk-UAZPXKPH.js +3996 -0
  444. package/dist/chunk-UHRGUMLJ.js +412 -0
  445. package/dist/chunk-UNDSD6UA.js +131 -0
  446. package/dist/chunk-USU2SS4V.js +3690 -0
  447. package/dist/chunk-USWA5GQQ.js +340 -0
  448. package/dist/chunk-UXGTI4HR.js +184 -0
  449. package/dist/chunk-UZKAHEQO.js +172 -0
  450. package/dist/chunk-VALESBNH.js +113 -0
  451. package/dist/chunk-VMSMVWCJ.js +515 -0
  452. package/dist/chunk-VPERSFGV.js +158 -0
  453. package/dist/chunk-VVW2CBWK.js +21 -0
  454. package/dist/chunk-VVW2CBWK.js.map +1 -0
  455. package/dist/chunk-VXPY2GF3.js +124 -0
  456. package/dist/chunk-W7RKXZDV.js +112 -0
  457. package/dist/chunk-WEGZPK4I.js +532 -0
  458. package/dist/chunk-WPKY3BGG.js +380 -0
  459. package/dist/chunk-X3T3N6W5.js +1022 -0
  460. package/dist/chunk-X4OGMBY6.js +110 -0
  461. package/dist/chunk-X7ZHIJEI.js +82 -0
  462. package/dist/chunk-XR7Y2HPZ.js +67 -0
  463. package/dist/chunk-Y2NMKJ7F.js +57 -0
  464. package/dist/chunk-Y2QYPJDN.js +26 -0
  465. package/dist/chunk-Y47EPVCD.js +211 -0
  466. package/dist/chunk-Y5Q4ETIW.js +162 -0
  467. package/dist/chunk-YMQVVFXI.js +105 -0
  468. package/dist/chunk-YQ6FP33X.js +378 -0
  469. package/dist/chunk-YUA42N5A.js +406 -0
  470. package/dist/chunk-YXFNW64N.js +91 -0
  471. package/dist/chunk-Z76RJPZF.js +389 -0
  472. package/dist/chunk-ZD67RM6G.js +60 -0
  473. package/dist/chunk-ZE4RD7U5.js +231 -0
  474. package/dist/chunk-ZGR7LNXC.js +432 -0
  475. package/dist/chunk-ZNA65Q6Y.js +20 -0
  476. package/dist/chunk-ZRNK6FK6.js +188 -0
  477. package/dist/chunk-ZVAIKQMC.js +296 -0
  478. package/dist/chunk-ZZ3KNGTJ.js +246 -0
  479. package/dist/components/automations/pasted-webhook-steps.d.ts +29 -0
  480. package/dist/components/browser-viewer.d.ts +4 -1
  481. package/dist/components/human-input-form.d.ts +3 -4
  482. package/dist/components/use-fit-browser-viewport.d.ts +10 -0
  483. package/dist/composer.js +8 -8
  484. package/dist/computer-viewer-M5N3GWBR.js +21 -0
  485. package/dist/connect.js +17 -15
  486. package/dist/connection-step-up-CNVFVWYO.js +146 -0
  487. package/dist/connection-step-up-CNVFVWYO.js.map +1 -0
  488. package/dist/desktop-dictation.js +8 -8
  489. package/dist/desktop.js +2 -2
  490. package/dist/editor.js +2 -2
  491. package/dist/embedded-new-voice-QZJG5DZ3.js +25 -0
  492. package/dist/embedded-voice-7KOQNGKU.js +25 -0
  493. package/dist/fleet-decision-row-FJPAWNOQ.js +361 -0
  494. package/dist/in-chat-connect-model.js +5 -5
  495. package/dist/index.js +65 -65
  496. package/dist/interaction.js +5 -5
  497. package/dist/latest-question-F3VPDR7U.js +124 -0
  498. package/dist/machines.js +3 -3
  499. package/dist/meetings-recorder.js +1 -1
  500. package/dist/meetings.js +20 -20
  501. package/dist/messages/en.d.ts +1 -1
  502. package/dist/messages.js +1 -1
  503. package/dist/model-policy-picker-menu-UNI5B6N6.js +23 -0
  504. package/dist/model-policy-picker-menu-UNI5B6N6.js.map +1 -0
  505. package/dist/payment-page-card-HZJVN3F4.js +226 -0
  506. package/dist/platform-activity-row-NPEGG2VE.js +156 -0
  507. package/dist/queue-surface-implementation-RTCTPF5T.js +932 -0
  508. package/dist/realtime.js +4 -4
  509. package/dist/recorder-host-YPWPLMS6.js +80 -0
  510. package/dist/recordings.js +3 -3
  511. package/dist/sandbox-files-BJKCREOU.js +28 -0
  512. package/dist/sandbox-files-BJKCREOU.js.map +1 -0
  513. package/dist/session-app.js +242 -241
  514. package/dist/session-connect-cards-DK3UJZRY.js +27 -0
  515. package/dist/session-connect-cards-DK3UJZRY.js.map +1 -0
  516. package/dist/session-list-model.js +2 -2
  517. package/dist/session-realtime-AKDUKFY4.js +30 -0
  518. package/dist/session-realtime-AKDUKFY4.js.map +1 -0
  519. package/dist/session-realtime.js +2 -2
  520. package/dist/session-ui.js +42 -42
  521. package/dist/session.js +11 -11
  522. package/dist/sites.js +2 -2
  523. package/dist/terminal.js +2 -2
  524. package/dist/this-computer.js +3 -3
  525. package/dist/timeline-annotation-markers-7QSYK22C.js +157 -0
  526. package/dist/timeline-annotation-selection-XYNMESWL.js +208 -0
  527. package/dist/timeline-annotations-dialog-WSI6L2CP.js +283 -0
  528. package/dist/timeline-model.js +26 -26
  529. package/dist/ui/access-list.js +5 -5
  530. package/dist/ui/cadence-picker.js +5 -5
  531. package/dist/ui/choice-cards.js +3 -3
  532. package/dist/ui/confirm-dialog.js +2 -2
  533. package/dist/ui/copy-field.js +3 -3
  534. package/dist/ui/detail-page.js +2 -2
  535. package/dist/ui/detail-sheet.js +2 -2
  536. package/dist/ui/disclosure.js +3 -3
  537. package/dist/ui/email-chips-input.js +3 -3
  538. package/dist/ui/field.js +2 -2
  539. package/dist/ui/flush-form-page.js +3 -3
  540. package/dist/ui/form-dialog.js +2 -2
  541. package/dist/ui/list-row.js +4 -4
  542. package/dist/ui/relative-time.js +3 -3
  543. package/dist/ui/revision-history.js +5 -5
  544. package/dist/ui/role-select.js +5 -5
  545. package/dist/ui/select-menu.js +3 -3
  546. package/dist/ui/usage-meter.js +4 -4
  547. package/dist/usage.js +2 -2
  548. package/dist/workbench.js +4 -4
  549. package/package.json +6 -5
  550. package/src/app/components/agents/agent-skills.tsx +21 -18
  551. package/src/app/components/agents/agent-trigger-dialog.tsx +80 -119
  552. package/src/app/components/agents/agent-trigger-model.ts +47 -0
  553. package/src/app/components/agents/agent-trigger-repositories.tsx +88 -0
  554. package/src/app/components/agents/agents-page.tsx +118 -38
  555. package/src/app/components/artifacts/app-server-status.test.tsx +33 -0
  556. package/src/app/components/artifacts/app-server-status.tsx +93 -0
  557. package/src/app/components/artifacts/ready-made-apps.tsx +84 -0
  558. package/src/app/lib/codex-model-switch.ts +1 -0
  559. package/src/app/lib/needs-you.test.ts +8 -0
  560. package/src/app/lib/needs-you.tsx +3 -1
  561. package/src/app/lib/ready-made-apps.tsx +42 -0
  562. package/src/app/lib/session-capabilities.tsx +1 -0
  563. package/src/app/routes/artifacts.tsx +11 -0
  564. package/src/app/routes/site-view.tsx +9 -0
  565. package/src/automations.ts +8 -2
  566. package/src/components/automations/pasted-webhook-steps.tsx +89 -0
  567. package/src/components/browser-viewer.tsx +49 -7
  568. package/src/components/human-input-form.tsx +16 -5
  569. package/src/components/secret-question-field.tsx +42 -32
  570. package/src/components/use-fit-browser-viewport.ts +84 -0
  571. package/src/messages/en.ts +1 -1
  572. package/src/timeline/projection.ts +5 -2
  573. package/src/timeline/tool-steps.ts +2 -0
  574. package/dist/browser-viewer-EIEMRVFF.js +0 -23
  575. package/dist/chat-interactive-block-FV37LWYZ.js +0 -22
  576. package/dist/chunk-2COBAJC7.js +0 -818
  577. package/dist/chunk-2HS3IUXE.js +0 -170
  578. package/dist/chunk-2JTMFYCT.js +0 -296
  579. package/dist/chunk-2JXKP4M6.js +0 -114
  580. package/dist/chunk-2P5K7CBH.js +0 -269
  581. package/dist/chunk-2XGRHMRI.js +0 -250
  582. package/dist/chunk-332BYSAZ.js +0 -65
  583. package/dist/chunk-3EM5GTP3.js +0 -158
  584. package/dist/chunk-3L5ATO4A.js +0 -52
  585. package/dist/chunk-3S3PJB7J.js +0 -107
  586. package/dist/chunk-3SBKYPNM.js +0 -270
  587. package/dist/chunk-3Z7VA6ET.js +0 -114
  588. package/dist/chunk-43BRJBEV.js +0 -207
  589. package/dist/chunk-46LZO4ZO.js +0 -188
  590. package/dist/chunk-4AH4EEHE.js +0 -298
  591. package/dist/chunk-4D3YJNVN.js +0 -270
  592. package/dist/chunk-4E5QVAT4.js +0 -4480
  593. package/dist/chunk-4I4RTI4D.js +0 -37
  594. package/dist/chunk-4KASGJTF.js +0 -287
  595. package/dist/chunk-4RUKLIOF.js +0 -1263
  596. package/dist/chunk-4UU7FN3I.js +0 -650
  597. package/dist/chunk-4ZRNASBF.js +0 -2551
  598. package/dist/chunk-5EJBPQI2.js +0 -41
  599. package/dist/chunk-5G4IGG7F.js +0 -209
  600. package/dist/chunk-5JAYZOAW.js +0 -131
  601. package/dist/chunk-5JOKVDSR.js +0 -789
  602. package/dist/chunk-5JOKVDSR.js.map +0 -1
  603. package/dist/chunk-5MP3G7ZV.js +0 -1236
  604. package/dist/chunk-5OVRMKP5.js +0 -42
  605. package/dist/chunk-5SGTRULO.js +0 -1184
  606. package/dist/chunk-5SOL4INY.js +0 -572
  607. package/dist/chunk-5Y34P32B.js +0 -27
  608. package/dist/chunk-62HIKJ5F.js +0 -72
  609. package/dist/chunk-63VNZRLY.js +0 -386
  610. package/dist/chunk-63WDQV5X.js +0 -148
  611. package/dist/chunk-6DOIINY4.js +0 -201
  612. package/dist/chunk-6DQBUKGJ.js +0 -112
  613. package/dist/chunk-6SETNFNH.js +0 -1399
  614. package/dist/chunk-6SETNFNH.js.map +0 -1
  615. package/dist/chunk-6XYFMHNT.js +0 -56
  616. package/dist/chunk-6YU3WV2P.js +0 -33
  617. package/dist/chunk-6YUHDFOZ.js +0 -351
  618. package/dist/chunk-72EOXOR7.js +0 -1185
  619. package/dist/chunk-72ND4ALI.js +0 -532
  620. package/dist/chunk-757LE32E.js +0 -283
  621. package/dist/chunk-7S2S4MXR.js +0 -138
  622. package/dist/chunk-7SYCHMXS.js +0 -200
  623. package/dist/chunk-7TVAPQOV.js +0 -5089
  624. package/dist/chunk-7UDLRDHK.js +0 -214
  625. package/dist/chunk-7YLQCMZP.js +0 -357
  626. package/dist/chunk-A5GX3CAE.js +0 -849
  627. package/dist/chunk-A7EBV2EB.js +0 -318
  628. package/dist/chunk-AB5SPXUR.js +0 -114
  629. package/dist/chunk-AHVQGL5A.js +0 -202
  630. package/dist/chunk-AI77ZKEV.js +0 -26
  631. package/dist/chunk-AIX2D6RB.js +0 -1019
  632. package/dist/chunk-AVSIHP7Q.js +0 -192
  633. package/dist/chunk-AWK23Q32.js +0 -107
  634. package/dist/chunk-AYM3UFP2.js +0 -43
  635. package/dist/chunk-AYM3UFP2.js.map +0 -1
  636. package/dist/chunk-AYVWA6KD.js +0 -432
  637. package/dist/chunk-AYVWA6KD.js.map +0 -1
  638. package/dist/chunk-AYZXE4IM.js +0 -2553
  639. package/dist/chunk-AZGGSPTE.js +0 -124
  640. package/dist/chunk-B45TB4HY.js +0 -931
  641. package/dist/chunk-BC7PTVXW.js +0 -140
  642. package/dist/chunk-BIUJHNVR.js +0 -46
  643. package/dist/chunk-BJUOKUE5.js +0 -234
  644. package/dist/chunk-BMT5IXQW.js +0 -154
  645. package/dist/chunk-BMT5IXQW.js.map +0 -1
  646. package/dist/chunk-BPEEVMKH.js +0 -292
  647. package/dist/chunk-BXMND6YU.js +0 -307
  648. package/dist/chunk-C6OM2SRG.js +0 -117
  649. package/dist/chunk-CIRCUDKF.js +0 -1309
  650. package/dist/chunk-CLKR4UG3.js +0 -403
  651. package/dist/chunk-CPX6BHER.js +0 -554
  652. package/dist/chunk-CVC4RO7D.js +0 -155
  653. package/dist/chunk-D3YJAQGK.js +0 -103
  654. package/dist/chunk-DFQ72BLS.js +0 -1024
  655. package/dist/chunk-DG65PJOZ.js +0 -4564
  656. package/dist/chunk-DG65PJOZ.js.map +0 -1
  657. package/dist/chunk-DNAXAS5R.js +0 -406
  658. package/dist/chunk-DO247ITS.js +0 -175
  659. package/dist/chunk-DONBARLL.js +0 -154
  660. package/dist/chunk-DTLXQ3ZU.js +0 -373
  661. package/dist/chunk-EAXTACI4.js +0 -274
  662. package/dist/chunk-EDPH7AJH.js +0 -412
  663. package/dist/chunk-EER3B3G5.js +0 -10036
  664. package/dist/chunk-EER3B3G5.js.map +0 -1
  665. package/dist/chunk-EFKQHCGJ.js +0 -276
  666. package/dist/chunk-EILSPMVD.js +0 -133
  667. package/dist/chunk-EMWT6GOK.js +0 -437
  668. package/dist/chunk-EO22NST7.js +0 -259
  669. package/dist/chunk-ER5MYLIE.js +0 -256
  670. package/dist/chunk-ES5HKVQF.js +0 -234
  671. package/dist/chunk-EXRQ5ATC.js +0 -738
  672. package/dist/chunk-F26YBYAZ.js +0 -111
  673. package/dist/chunk-F6QP4GSK.js +0 -515
  674. package/dist/chunk-F7QEO7M2.js +0 -851
  675. package/dist/chunk-FJFGDLXB.js +0 -12
  676. package/dist/chunk-FLLJ2WXW.js +0 -113
  677. package/dist/chunk-FMBJKMT4.js +0 -107
  678. package/dist/chunk-FPN4I4CG.js +0 -3690
  679. package/dist/chunk-FUXFJTXL.js +0 -3070
  680. package/dist/chunk-FZI4QOAV.js +0 -3996
  681. package/dist/chunk-G6SSSX5R.js +0 -158
  682. package/dist/chunk-GBGCMHBB.js +0 -608
  683. package/dist/chunk-GJ4GTYOD.js +0 -372
  684. package/dist/chunk-GLSDWNFV.js +0 -432
  685. package/dist/chunk-GMGAW3T6.js +0 -278
  686. package/dist/chunk-GNGI6XFN.js +0 -43
  687. package/dist/chunk-GSW4YHZE.js +0 -229
  688. package/dist/chunk-GUC6IWEY.js +0 -407
  689. package/dist/chunk-GWAY3SO5.js +0 -15
  690. package/dist/chunk-GXOTNT5D.js +0 -168
  691. package/dist/chunk-GZZCVF76.js +0 -3851
  692. package/dist/chunk-H4VMHFOX.js +0 -214
  693. package/dist/chunk-HA5RFQAF.js +0 -110
  694. package/dist/chunk-HJLHGXWL.js +0 -103
  695. package/dist/chunk-HKNMNL7B.js +0 -2984
  696. package/dist/chunk-HT7MBHLY.js +0 -1021
  697. package/dist/chunk-I5FSUZVW.js +0 -584
  698. package/dist/chunk-II376XH3.js +0 -117
  699. package/dist/chunk-IINQO425.js +0 -246
  700. package/dist/chunk-IIXNEOK4.js +0 -1022
  701. package/dist/chunk-IM3WA5AL.js +0 -311
  702. package/dist/chunk-IX4P4OGR.js +0 -399
  703. package/dist/chunk-IX5VHZYS.js +0 -129
  704. package/dist/chunk-J7QHW2KS.js +0 -549
  705. package/dist/chunk-J7QHW2KS.js.map +0 -1
  706. package/dist/chunk-JB3TSUZO.js +0 -263
  707. package/dist/chunk-JD6LHU26.js +0 -3852
  708. package/dist/chunk-JD6LHU26.js.map +0 -1
  709. package/dist/chunk-JIC6RLUB.js +0 -27
  710. package/dist/chunk-JNJIZCTN.js +0 -172
  711. package/dist/chunk-JNV5ZPUV.js +0 -828
  712. package/dist/chunk-JPQFVR24.js +0 -50
  713. package/dist/chunk-JPZVMXDP.js +0 -1333
  714. package/dist/chunk-JVPF34MX.js +0 -215
  715. package/dist/chunk-KED67KAF.js +0 -85
  716. package/dist/chunk-KJ72GMZ2.js +0 -378
  717. package/dist/chunk-KVPQUADA.js +0 -5915
  718. package/dist/chunk-KVPQUADA.js.map +0 -1
  719. package/dist/chunk-KXBLLFOO.js +0 -249
  720. package/dist/chunk-LIOZ2MXJ.js +0 -380
  721. package/dist/chunk-LPEFULJY.js +0 -73
  722. package/dist/chunk-LRMGPO7E.js +0 -98
  723. package/dist/chunk-LVKTKORH.js +0 -121
  724. package/dist/chunk-MFVUNNFN.js +0 -205
  725. package/dist/chunk-MIUJ3EH5.js +0 -60
  726. package/dist/chunk-MIUMNTIJ.js +0 -175
  727. package/dist/chunk-ML46TXRM.js +0 -113
  728. package/dist/chunk-MQRHTOQ2.js +0 -218
  729. package/dist/chunk-NIPON7YB.js +0 -850
  730. package/dist/chunk-NPBEUU22.js +0 -196
  731. package/dist/chunk-NSXKGS2K.js +0 -178
  732. package/dist/chunk-NUEFORM6.js +0 -2317
  733. package/dist/chunk-NZOFNQNC.js +0 -176
  734. package/dist/chunk-OATXCLTY.js +0 -211
  735. package/dist/chunk-OG3ELROW.js +0 -538
  736. package/dist/chunk-OI4WS7FW.js +0 -162
  737. package/dist/chunk-OITGZUDC.js +0 -82
  738. package/dist/chunk-OKD2LBMK.js +0 -333
  739. package/dist/chunk-OSA4CGST.js +0 -134
  740. package/dist/chunk-OXYAKUFU.js +0 -401
  741. package/dist/chunk-OYMSMU5O.js +0 -396
  742. package/dist/chunk-P4NZ72KY.js +0 -162
  743. package/dist/chunk-PBYL2VIM.js +0 -379
  744. package/dist/chunk-PDW3OOSZ.js +0 -505
  745. package/dist/chunk-PGRKTQIW.js +0 -523
  746. package/dist/chunk-Q273Q33U.js +0 -166
  747. package/dist/chunk-Q4CLS2HL.js +0 -340
  748. package/dist/chunk-QFOBUA2J.js +0 -428
  749. package/dist/chunk-QLIM4D56.js +0 -1095
  750. package/dist/chunk-QMQF5U2D.js +0 -20
  751. package/dist/chunk-QPOUPVPD.js +0 -144
  752. package/dist/chunk-QTJAQ6DS.js +0 -48
  753. package/dist/chunk-QUOFP3G7.js +0 -404
  754. package/dist/chunk-QVOTPOXK.js +0 -29
  755. package/dist/chunk-QYZ5RVGM.js +0 -184
  756. package/dist/chunk-R7CVDKRN.js +0 -2580
  757. package/dist/chunk-RB7MXNZD.js +0 -639
  758. package/dist/chunk-RDZQFZOQ.js +0 -187
  759. package/dist/chunk-RIHKEGWS.js +0 -194
  760. package/dist/chunk-RIHKEGWS.js.map +0 -1
  761. package/dist/chunk-ROSB7GF6.js +0 -57
  762. package/dist/chunk-RP3YMYCX.js +0 -723
  763. package/dist/chunk-RPHXJHNX.js +0 -271
  764. package/dist/chunk-RVC3M66H.js +0 -191
  765. package/dist/chunk-S3OTJAAC.js +0 -283
  766. package/dist/chunk-SBWPMVRN.js +0 -56
  767. package/dist/chunk-SERECSAR.js +0 -138
  768. package/dist/chunk-SHSEF3GJ.js +0 -187
  769. package/dist/chunk-SMS2M3RG.js +0 -772
  770. package/dist/chunk-SRDHDIRQ.js +0 -177
  771. package/dist/chunk-SXRYA7NN.js +0 -389
  772. package/dist/chunk-SYA3WYG4.js +0 -1187
  773. package/dist/chunk-T2QDSTBH.js +0 -371
  774. package/dist/chunk-TFSCGFYV.js +0 -251
  775. package/dist/chunk-TGCKZOSX.js +0 -246
  776. package/dist/chunk-THILLYQM.js +0 -132
  777. package/dist/chunk-TI6LGUEZ.js +0 -2412
  778. package/dist/chunk-TSY6YZL2.js +0 -366
  779. package/dist/chunk-TW2RHTLH.js +0 -3321
  780. package/dist/chunk-TWA5G277.js +0 -141
  781. package/dist/chunk-TZZ2S4XI.js +0 -247
  782. package/dist/chunk-UECD27LX.js +0 -251
  783. package/dist/chunk-UFJDETKG.js +0 -108
  784. package/dist/chunk-UHBIXNRW.js +0 -100
  785. package/dist/chunk-UHCFYX4I.js +0 -570
  786. package/dist/chunk-UHTURYJO.js +0 -898
  787. package/dist/chunk-UJH63JT3.js +0 -67
  788. package/dist/chunk-UMLPIMGW.js +0 -105
  789. package/dist/chunk-UOLDS6S5.js +0 -1152
  790. package/dist/chunk-UUE3OGXI.js +0 -84
  791. package/dist/chunk-UUNJ2E57.js +0 -391
  792. package/dist/chunk-UYQVWRAH.js +0 -199
  793. package/dist/chunk-UYWWUEL4.js +0 -126
  794. package/dist/chunk-V4CQKX5H.js +0 -48
  795. package/dist/chunk-V4QM7GDQ.js +0 -3176
  796. package/dist/chunk-V5Y74WII.js +0 -91
  797. package/dist/chunk-VGGZLUQK.js +0 -129
  798. package/dist/chunk-VGX636MB.js +0 -311
  799. package/dist/chunk-VGZLFQO2.js +0 -773
  800. package/dist/chunk-VJWZATNF.js +0 -137
  801. package/dist/chunk-VMWCIC2N.js +0 -50
  802. package/dist/chunk-VPWKTIU5.js +0 -227
  803. package/dist/chunk-VXOLG6YB.js +0 -469
  804. package/dist/chunk-W2NAU5VB.js +0 -1628
  805. package/dist/chunk-WGORKMR3.js +0 -353
  806. package/dist/chunk-WMIDELSJ.js +0 -391
  807. package/dist/chunk-WSOSGL2G.js +0 -383
  808. package/dist/chunk-WXUUOM4X.js +0 -400
  809. package/dist/chunk-WZ74QHLE.js +0 -4863
  810. package/dist/chunk-WZ74QHLE.js.map +0 -1
  811. package/dist/chunk-X2OWM2ME.js +0 -1870
  812. package/dist/chunk-X2OWM2ME.js.map +0 -1
  813. package/dist/chunk-XDXKB25W.js +0 -93
  814. package/dist/chunk-XE4PHI74.js +0 -231
  815. package/dist/chunk-XLJ4SQFS.js +0 -230
  816. package/dist/chunk-XOD4FX6M.js +0 -2434
  817. package/dist/chunk-XODQ2GPF.js +0 -3110
  818. package/dist/chunk-XT54RTAM.js +0 -441
  819. package/dist/chunk-YDQHFJM2.js +0 -83
  820. package/dist/chunk-YH6O6OQ6.js +0 -1356
  821. package/dist/chunk-YIKPC2QP.js +0 -794
  822. package/dist/chunk-ZD7PKYC4.js +0 -335
  823. package/dist/chunk-ZEQYHEWP.js +0 -406
  824. package/dist/chunk-ZRVUCTSI.js +0 -265
  825. package/dist/chunk-ZSI3ITRK.js +0 -449
  826. package/dist/chunk-ZZMEQCIZ.js +0 -236
  827. package/dist/computer-viewer-ZBY3BPYW.js +0 -21
  828. package/dist/connection-step-up-JQ4OFSQN.js +0 -145
  829. package/dist/connection-step-up-JQ4OFSQN.js.map +0 -1
  830. package/dist/embedded-new-voice-ZB5XLKLU.js +0 -25
  831. package/dist/embedded-voice-MZJISDCS.js +0 -25
  832. package/dist/fleet-decision-row-LG3SYVR3.js +0 -361
  833. package/dist/latest-question-QWJTXMFA.js +0 -124
  834. package/dist/model-policy-picker-menu-5Y72PLNF.js +0 -23
  835. package/dist/payment-page-card-YPSXRHBA.js +0 -226
  836. package/dist/platform-activity-row-ZU4MEBNK.js +0 -156
  837. package/dist/queue-surface-implementation-6Q25RPH6.js +0 -932
  838. package/dist/recorder-host-JD4GWJ2Z.js +0 -80
  839. package/dist/sandbox-files-HCLEEJMU.js +0 -28
  840. package/dist/session-connect-cards-DRKEN3Z4.js +0 -27
  841. package/dist/session-realtime-IZOTTRH6.js +0 -30
  842. package/dist/timeline-annotation-markers-WWXNJOXI.js +0 -157
  843. package/dist/timeline-annotation-selection-ZKRIQFIQ.js +0 -208
  844. package/dist/timeline-annotations-dialog-4IMKTOXJ.js +0 -283
  845. /package/dist/{browser-viewer-EIEMRVFF.js.map → app/components/agents/agent-trigger-repositories.js.map} +0 -0
  846. /package/dist/{chat-interactive-block-FV37LWYZ.js.map → app/components/artifacts/app-server-status.js.map} +0 -0
  847. /package/dist/{computer-viewer-ZBY3BPYW.js.map → app/components/artifacts/ready-made-apps.js.map} +0 -0
  848. /package/dist/{embedded-new-voice-ZB5XLKLU.js.map → app/lib/ready-made-apps.js.map} +0 -0
  849. /package/dist/{embedded-voice-MZJISDCS.js.map → browser-viewer-EPGAK2W6.js.map} +0 -0
  850. /package/dist/{model-policy-picker-menu-5Y72PLNF.js.map → chat-interactive-block-65YU6TMO.js.map} +0 -0
  851. /package/dist/{chunk-CLKR4UG3.js.map → chunk-25ODMMHH.js.map} +0 -0
  852. /package/dist/{chunk-WXUUOM4X.js.map → chunk-266ZPUMH.js.map} +0 -0
  853. /package/dist/{chunk-GXOTNT5D.js.map → chunk-2A7SB7UR.js.map} +0 -0
  854. /package/dist/{chunk-UHBIXNRW.js.map → chunk-2EU4Y7A7.js.map} +0 -0
  855. /package/dist/{chunk-UHCFYX4I.js.map → chunk-2LBYEHBH.js.map} +0 -0
  856. /package/dist/{chunk-TWA5G277.js.map → chunk-2MHIIF4N.js.map} +0 -0
  857. /package/dist/{chunk-757LE32E.js.map → chunk-2SHWGDAA.js.map} +0 -0
  858. /package/dist/{chunk-VGZLFQO2.js.map → chunk-2VX42S4W.js.map} +0 -0
  859. /package/dist/{chunk-VGX636MB.js.map → chunk-2WGJQ4XK.js.map} +0 -0
  860. /package/dist/{chunk-GWAY3SO5.js.map → chunk-2XSF44TY.js.map} +0 -0
  861. /package/dist/{chunk-RB7MXNZD.js.map → chunk-33HUZMNE.js.map} +0 -0
  862. /package/dist/{chunk-63WDQV5X.js.map → chunk-36IKHM4Q.js.map} +0 -0
  863. /package/dist/{chunk-4E5QVAT4.js.map → chunk-3JVQZAXQ.js.map} +0 -0
  864. /package/dist/{chunk-4KASGJTF.js.map → chunk-3SDESU6U.js.map} +0 -0
  865. /package/dist/{chunk-BPEEVMKH.js.map → chunk-3VXZFBP6.js.map} +0 -0
  866. /package/dist/{chunk-BXMND6YU.js.map → chunk-3YKED2ZV.js.map} +0 -0
  867. /package/dist/{chunk-AIX2D6RB.js.map → chunk-3ZNOKD3S.js.map} +0 -0
  868. /package/dist/{chunk-R7CVDKRN.js.map → chunk-45SB4UK3.js.map} +0 -0
  869. /package/dist/{chunk-EILSPMVD.js.map → chunk-47BETTVA.js.map} +0 -0
  870. /package/dist/{chunk-EAXTACI4.js.map → chunk-4BTQ473O.js.map} +0 -0
  871. /package/dist/{chunk-KXBLLFOO.js.map → chunk-4JQRWJVR.js.map} +0 -0
  872. /package/dist/{chunk-AHVQGL5A.js.map → chunk-4R6WFQKZ.js.map} +0 -0
  873. /package/dist/{chunk-S3OTJAAC.js.map → chunk-4WEPVL7X.js.map} +0 -0
  874. /package/dist/{chunk-6DOIINY4.js.map → chunk-4YWHOAB4.js.map} +0 -0
  875. /package/dist/{chunk-CVC4RO7D.js.map → chunk-52XGYRVS.js.map} +0 -0
  876. /package/dist/{chunk-GNGI6XFN.js.map → chunk-5G6UHUJZ.js.map} +0 -0
  877. /package/dist/{chunk-GSW4YHZE.js.map → chunk-5HFITPHH.js.map} +0 -0
  878. /package/dist/{chunk-4UU7FN3I.js.map → chunk-5LVVN2K7.js.map} +0 -0
  879. /package/dist/{chunk-V4CQKX5H.js.map → chunk-5PVXFVIT.js.map} +0 -0
  880. /package/dist/{chunk-RDZQFZOQ.js.map → chunk-5WFGW7B7.js.map} +0 -0
  881. /package/dist/{chunk-FUXFJTXL.js.map → chunk-66M7RVM6.js.map} +0 -0
  882. /package/dist/{chunk-EMWT6GOK.js.map → chunk-6AGNZI2W.js.map} +0 -0
  883. /package/dist/{chunk-DTLXQ3ZU.js.map → chunk-6ENO634Y.js.map} +0 -0
  884. /package/dist/{chunk-7SYCHMXS.js.map → chunk-6LQ5KEMP.js.map} +0 -0
  885. /package/dist/{chunk-QFOBUA2J.js.map → chunk-6QGIWLH5.js.map} +0 -0
  886. /package/dist/{chunk-2HS3IUXE.js.map → chunk-6WEDWD4N.js.map} +0 -0
  887. /package/dist/{chunk-AB5SPXUR.js.map → chunk-6YCYPXDA.js.map} +0 -0
  888. /package/dist/{chunk-A7EBV2EB.js.map → chunk-6YTNMDFP.js.map} +0 -0
  889. /package/dist/{chunk-JPQFVR24.js.map → chunk-73O7NO3F.js.map} +0 -0
  890. /package/dist/{chunk-UECD27LX.js.map → chunk-76VXLTQF.js.map} +0 -0
  891. /package/dist/{chunk-XDXKB25W.js.map → chunk-7EJ7PSZT.js.map} +0 -0
  892. /package/dist/{chunk-JIC6RLUB.js.map → chunk-7GS2MGFU.js.map} +0 -0
  893. /package/dist/{chunk-DNAXAS5R.js.map → chunk-7MF6MFHS.js.map} +0 -0
  894. /package/dist/{chunk-63VNZRLY.js.map → chunk-7N35XBSC.js.map} +0 -0
  895. /package/dist/{chunk-3SBKYPNM.js.map → chunk-7ND2VMKV.js.map} +0 -0
  896. /package/dist/{chunk-DONBARLL.js.map → chunk-7RVJLO3N.js.map} +0 -0
  897. /package/dist/{chunk-WGORKMR3.js.map → chunk-7VAILBP6.js.map} +0 -0
  898. /package/dist/{chunk-4I4RTI4D.js.map → chunk-7VSJQWFO.js.map} +0 -0
  899. /package/dist/{chunk-ZD7PKYC4.js.map → chunk-7YKUIKGH.js.map} +0 -0
  900. /package/dist/{chunk-SERECSAR.js.map → chunk-A7DS77WC.js.map} +0 -0
  901. /package/dist/{chunk-4AH4EEHE.js.map → chunk-AEH34OOU.js.map} +0 -0
  902. /package/dist/{chunk-CPX6BHER.js.map → chunk-ANWMRO2G.js.map} +0 -0
  903. /package/dist/{chunk-TZZ2S4XI.js.map → chunk-APGUIORF.js.map} +0 -0
  904. /package/dist/{chunk-CIRCUDKF.js.map → chunk-ASCVQJB4.js.map} +0 -0
  905. /package/dist/{chunk-JPZVMXDP.js.map → chunk-AY4XH73V.js.map} +0 -0
  906. /package/dist/{chunk-XOD4FX6M.js.map → chunk-B6AH43UQ.js.map} +0 -0
  907. /package/dist/{chunk-5OVRMKP5.js.map → chunk-BGT43KDL.js.map} +0 -0
  908. /package/dist/{chunk-GZZCVF76.js.map → chunk-BHS4KW4W.js.map} +0 -0
  909. /package/dist/{chunk-F7QEO7M2.js.map → chunk-BNWO72C2.js.map} +0 -0
  910. /package/dist/{chunk-4ZRNASBF.js.map → chunk-BSPIASSQ.js.map} +0 -0
  911. /package/dist/{chunk-XLJ4SQFS.js.map → chunk-BVWJEZXG.js.map} +0 -0
  912. /package/dist/{chunk-TSY6YZL2.js.map → chunk-BZ47G3VP.js.map} +0 -0
  913. /package/dist/{chunk-62HIKJ5F.js.map → chunk-C6KI5P3H.js.map} +0 -0
  914. /package/dist/{chunk-NUEFORM6.js.map → chunk-CLERWAEA.js.map} +0 -0
  915. /package/dist/{chunk-5SOL4INY.js.map → chunk-CNRFFCAE.js.map} +0 -0
  916. /package/dist/{chunk-ZZMEQCIZ.js.map → chunk-CPC6CYVW.js.map} +0 -0
  917. /package/dist/{chunk-FMBJKMT4.js.map → chunk-D23UAPXK.js.map} +0 -0
  918. /package/dist/{chunk-QVOTPOXK.js.map → chunk-DAPZEB4R.js.map} +0 -0
  919. /package/dist/{chunk-MFVUNNFN.js.map → chunk-DEDEA3WS.js.map} +0 -0
  920. /package/dist/{chunk-RPHXJHNX.js.map → chunk-DHVA3T3K.js.map} +0 -0
  921. /package/dist/{chunk-UUNJ2E57.js.map → chunk-DJQ6TKIP.js.map} +0 -0
  922. /package/dist/{chunk-6YU3WV2P.js.map → chunk-DK2CDAMR.js.map} +0 -0
  923. /package/dist/{chunk-GMGAW3T6.js.map → chunk-DPOB6MUS.js.map} +0 -0
  924. /package/dist/{chunk-VJWZATNF.js.map → chunk-DSO7S6PZ.js.map} +0 -0
  925. /package/dist/{chunk-OKD2LBMK.js.map → chunk-DV3OECO6.js.map} +0 -0
  926. /package/dist/{chunk-SYA3WYG4.js.map → chunk-DW2IQRMB.js.map} +0 -0
  927. /package/dist/{chunk-OSA4CGST.js.map → chunk-DWLPQTDL.js.map} +0 -0
  928. /package/dist/{chunk-V4QM7GDQ.js.map → chunk-DXMKECFR.js.map} +0 -0
  929. /package/dist/{chunk-LPEFULJY.js.map → chunk-DYQRNIID.js.map} +0 -0
  930. /package/dist/{chunk-VGGZLUQK.js.map → chunk-DZLWO73N.js.map} +0 -0
  931. /package/dist/{chunk-AWK23Q32.js.map → chunk-E2GNUL64.js.map} +0 -0
  932. /package/dist/{chunk-AVSIHP7Q.js.map → chunk-E7XU2KHD.js.map} +0 -0
  933. /package/dist/{chunk-2JXKP4M6.js.map → chunk-ENYULVQW.js.map} +0 -0
  934. /package/dist/{chunk-5EJBPQI2.js.map → chunk-EWHQ3DFM.js.map} +0 -0
  935. /package/dist/{chunk-EXRQ5ATC.js.map → chunk-F3LIUDXN.js.map} +0 -0
  936. /package/dist/{chunk-D3YJAQGK.js.map → chunk-F5C7DTVR.js.map} +0 -0
  937. /package/dist/{chunk-WMIDELSJ.js.map → chunk-F5NFGBIN.js.map} +0 -0
  938. /package/dist/{chunk-DO247ITS.js.map → chunk-F6XJLGOV.js.map} +0 -0
  939. /package/dist/{chunk-G6SSSX5R.js.map → chunk-F7T2STMX.js.map} +0 -0
  940. /package/dist/{chunk-T2QDSTBH.js.map → chunk-FAEVOM6B.js.map} +0 -0
  941. /package/dist/{chunk-EFKQHCGJ.js.map → chunk-FCFAXQDM.js.map} +0 -0
  942. /package/dist/{chunk-7S2S4MXR.js.map → chunk-FEQVCQMK.js.map} +0 -0
  943. /package/dist/{chunk-OYMSMU5O.js.map → chunk-FLDF2Z44.js.map} +0 -0
  944. /package/dist/{chunk-SMS2M3RG.js.map → chunk-GADABL3P.js.map} +0 -0
  945. /package/dist/{chunk-BC7PTVXW.js.map → chunk-GFUDB3SA.js.map} +0 -0
  946. /package/dist/{chunk-JVPF34MX.js.map → chunk-GGPZPBHS.js.map} +0 -0
  947. /package/dist/{chunk-IM3WA5AL.js.map → chunk-GIEGIEMT.js.map} +0 -0
  948. /package/dist/{chunk-SHSEF3GJ.js.map → chunk-GKWFQEO3.js.map} +0 -0
  949. /package/dist/{chunk-2XGRHMRI.js.map → chunk-GMMB4NCN.js.map} +0 -0
  950. /package/dist/{chunk-2P5K7CBH.js.map → chunk-GN4FOL2G.js.map} +0 -0
  951. /package/dist/{chunk-VXOLG6YB.js.map → chunk-GQJAMANY.js.map} +0 -0
  952. /package/dist/{chunk-PBYL2VIM.js.map → chunk-H7F4ANJQ.js.map} +0 -0
  953. /package/dist/{chunk-XODQ2GPF.js.map → chunk-HEPFJ3XQ.js.map} +0 -0
  954. /package/dist/{chunk-ES5HKVQF.js.map → chunk-HLRAQITA.js.map} +0 -0
  955. /package/dist/{chunk-II376XH3.js.map → chunk-HXYSZKCC.js.map} +0 -0
  956. /package/dist/{chunk-JNV5ZPUV.js.map → chunk-I5Q6FVHP.js.map} +0 -0
  957. /package/dist/{chunk-ZRVUCTSI.js.map → chunk-I7M5BYJU.js.map} +0 -0
  958. /package/dist/{chunk-KED67KAF.js.map → chunk-IH3J7VWW.js.map} +0 -0
  959. /package/dist/{chunk-NSXKGS2K.js.map → chunk-IMMDXSZ4.js.map} +0 -0
  960. /package/dist/{chunk-UYQVWRAH.js.map → chunk-IOMZDY5D.js.map} +0 -0
  961. /package/dist/{chunk-5MP3G7ZV.js.map → chunk-IQTCUUDF.js.map} +0 -0
  962. /package/dist/{chunk-UHTURYJO.js.map → chunk-ISR6KXWT.js.map} +0 -0
  963. /package/dist/{chunk-TW2RHTLH.js.map → chunk-IWPPGXUZ.js.map} +0 -0
  964. /package/dist/{chunk-UUE3OGXI.js.map → chunk-JNPCRNPA.js.map} +0 -0
  965. /package/dist/{chunk-PDW3OOSZ.js.map → chunk-JSJGGP32.js.map} +0 -0
  966. /package/dist/{chunk-SBWPMVRN.js.map → chunk-JZZUEJYD.js.map} +0 -0
  967. /package/dist/{chunk-4D3YJNVN.js.map → chunk-K5XFZKK5.js.map} +0 -0
  968. /package/dist/{chunk-332BYSAZ.js.map → chunk-K6GRTSEA.js.map} +0 -0
  969. /package/dist/{chunk-HJLHGXWL.js.map → chunk-KA4PZU3Q.js.map} +0 -0
  970. /package/dist/{chunk-YDQHFJM2.js.map → chunk-KGZ35ESO.js.map} +0 -0
  971. /package/dist/{chunk-HT7MBHLY.js.map → chunk-KRM4PW5N.js.map} +0 -0
  972. /package/dist/{chunk-QLIM4D56.js.map → chunk-LEZGGRDQ.js.map} +0 -0
  973. /package/dist/{chunk-QPOUPVPD.js.map → chunk-LFWMFFKT.js.map} +0 -0
  974. /package/dist/{chunk-A5GX3CAE.js.map → chunk-LKSPUZPH.js.map} +0 -0
  975. /package/dist/{chunk-OXYAKUFU.js.map → chunk-LLX4S6BI.js.map} +0 -0
  976. /package/dist/{chunk-NIPON7YB.js.map → chunk-M4WEF4DZ.js.map} +0 -0
  977. /package/dist/{chunk-LVKTKORH.js.map → chunk-MATYGLUT.js.map} +0 -0
  978. /package/dist/{chunk-5Y34P32B.js.map → chunk-MDI6SH7B.js.map} +0 -0
  979. /package/dist/{chunk-JB3TSUZO.js.map → chunk-MQTYIBY6.js.map} +0 -0
  980. /package/dist/{chunk-72EOXOR7.js.map → chunk-MRKY2GL5.js.map} +0 -0
  981. /package/dist/{chunk-YIKPC2QP.js.map → chunk-MSIQ42IY.js.map} +0 -0
  982. /package/dist/{chunk-7YLQCMZP.js.map → chunk-MVGU7BET.js.map} +0 -0
  983. /package/dist/{chunk-QUOFP3G7.js.map → chunk-MWY4TBDY.js.map} +0 -0
  984. /package/dist/{chunk-BJUOKUE5.js.map → chunk-NGQCWCD6.js.map} +0 -0
  985. /package/dist/{chunk-OG3ELROW.js.map → chunk-NKXMIOYN.js.map} +0 -0
  986. /package/dist/{chunk-ER5MYLIE.js.map → chunk-NMVRFFCR.js.map} +0 -0
  987. /package/dist/{chunk-GUC6IWEY.js.map → chunk-NNTDIKJP.js.map} +0 -0
  988. /package/dist/{chunk-LRMGPO7E.js.map → chunk-NQXCPP4G.js.map} +0 -0
  989. /package/dist/{chunk-THILLYQM.js.map → chunk-NYGS6FNV.js.map} +0 -0
  990. /package/dist/{chunk-NZOFNQNC.js.map → chunk-O3LOQDTI.js.map} +0 -0
  991. /package/dist/{chunk-2COBAJC7.js.map → chunk-O5HRZ2KG.js.map} +0 -0
  992. /package/dist/{chunk-H4VMHFOX.js.map → chunk-O5PZRVQR.js.map} +0 -0
  993. /package/dist/{chunk-IX4P4OGR.js.map → chunk-O6KR5SN7.js.map} +0 -0
  994. /package/dist/{chunk-EO22NST7.js.map → chunk-OBKDRV2H.js.map} +0 -0
  995. /package/dist/{chunk-3S3PJB7J.js.map → chunk-OBKKUBGL.js.map} +0 -0
  996. /package/dist/{chunk-3L5ATO4A.js.map → chunk-OFYXDB6I.js.map} +0 -0
  997. /package/dist/{chunk-VMWCIC2N.js.map → chunk-OLMWJGSJ.js.map} +0 -0
  998. /package/dist/{chunk-4RUKLIOF.js.map → chunk-ORRACKLB.js.map} +0 -0
  999. /package/dist/{chunk-6YUHDFOZ.js.map → chunk-P426WWAB.js.map} +0 -0
  1000. /package/dist/{chunk-SRDHDIRQ.js.map → chunk-P4GOY3ZL.js.map} +0 -0
  1001. /package/dist/{chunk-IX5VHZYS.js.map → chunk-P4KVJLUC.js.map} +0 -0
  1002. /package/dist/{chunk-6XYFMHNT.js.map → chunk-P4N7ZS6W.js.map} +0 -0
  1003. /package/dist/{chunk-5G4IGG7F.js.map → chunk-P6LSLNSL.js.map} +0 -0
  1004. /package/dist/{chunk-F26YBYAZ.js.map → chunk-PAFSIDM2.js.map} +0 -0
  1005. /package/dist/{chunk-C6OM2SRG.js.map → chunk-PC2JAIAH.js.map} +0 -0
  1006. /package/dist/{chunk-43BRJBEV.js.map → chunk-PGSXT5OY.js.map} +0 -0
  1007. /package/dist/{chunk-HKNMNL7B.js.map → chunk-QDMGUTOU.js.map} +0 -0
  1008. /package/dist/{chunk-YH6O6OQ6.js.map → chunk-QEMDQKQT.js.map} +0 -0
  1009. /package/dist/{chunk-TI6LGUEZ.js.map → chunk-QK7VU5N3.js.map} +0 -0
  1010. /package/dist/{chunk-FJFGDLXB.js.map → chunk-QL4Q332Z.js.map} +0 -0
  1011. /package/dist/{chunk-5SGTRULO.js.map → chunk-QL5227KT.js.map} +0 -0
  1012. /package/dist/{chunk-3Z7VA6ET.js.map → chunk-QUFCZMHG.js.map} +0 -0
  1013. /package/dist/{chunk-VPWKTIU5.js.map → chunk-QXPKUKOV.js.map} +0 -0
  1014. /package/dist/{chunk-XT54RTAM.js.map → chunk-QZE3KD34.js.map} +0 -0
  1015. /package/dist/{chunk-Q273Q33U.js.map → chunk-RAIUIXCY.js.map} +0 -0
  1016. /package/dist/{chunk-RP3YMYCX.js.map → chunk-RDLS6IZY.js.map} +0 -0
  1017. /package/dist/{chunk-MIUMNTIJ.js.map → chunk-RKPETJDJ.js.map} +0 -0
  1018. /package/dist/{chunk-GJ4GTYOD.js.map → chunk-RMDLTRLI.js.map} +0 -0
  1019. /package/dist/{chunk-PGRKTQIW.js.map → chunk-RR6DQN4X.js.map} +0 -0
  1020. /package/dist/{chunk-MQRHTOQ2.js.map → chunk-RVPH6BB7.js.map} +0 -0
  1021. /package/dist/{chunk-B45TB4HY.js.map → chunk-RVXLSVJH.js.map} +0 -0
  1022. /package/dist/{chunk-IINQO425.js.map → chunk-RVY5EZNU.js.map} +0 -0
  1023. /package/dist/{chunk-DFQ72BLS.js.map → chunk-RWHBX4MN.js.map} +0 -0
  1024. /package/dist/{chunk-7UDLRDHK.js.map → chunk-RWHDMGFG.js.map} +0 -0
  1025. /package/dist/{chunk-FLLJ2WXW.js.map → chunk-RYB3WBMZ.js.map} +0 -0
  1026. /package/dist/{chunk-ZSI3ITRK.js.map → chunk-S7EO77EE.js.map} +0 -0
  1027. /package/dist/{chunk-I5FSUZVW.js.map → chunk-S7J4HBPP.js.map} +0 -0
  1028. /package/dist/{chunk-UFJDETKG.js.map → chunk-SA3XI7FB.js.map} +0 -0
  1029. /package/dist/{chunk-NPBEUU22.js.map → chunk-SKRTCSUL.js.map} +0 -0
  1030. /package/dist/{chunk-7TVAPQOV.js.map → chunk-SUWDILUY.js.map} +0 -0
  1031. /package/dist/{chunk-TFSCGFYV.js.map → chunk-SWTPVMR4.js.map} +0 -0
  1032. /package/dist/{chunk-RVC3M66H.js.map → chunk-T5BYEE66.js.map} +0 -0
  1033. /package/dist/{chunk-QTJAQ6DS.js.map → chunk-T652Q4R6.js.map} +0 -0
  1034. /package/dist/{chunk-GBGCMHBB.js.map → chunk-TBUOHK6R.js.map} +0 -0
  1035. /package/dist/{chunk-W2NAU5VB.js.map → chunk-TCUAGCAX.js.map} +0 -0
  1036. /package/dist/{chunk-UYWWUEL4.js.map → chunk-TLWH4E3P.js.map} +0 -0
  1037. /package/dist/{chunk-UOLDS6S5.js.map → chunk-TNHGSWG3.js.map} +0 -0
  1038. /package/dist/{chunk-WSOSGL2G.js.map → chunk-TO6VBJI3.js.map} +0 -0
  1039. /package/dist/{chunk-OI4WS7FW.js.map → chunk-TOL7MOAN.js.map} +0 -0
  1040. /package/dist/{chunk-AYZXE4IM.js.map → chunk-U243CBVZ.js.map} +0 -0
  1041. /package/dist/{chunk-BIUJHNVR.js.map → chunk-U2CEPRDH.js.map} +0 -0
  1042. /package/dist/{chunk-FZI4QOAV.js.map → chunk-UAZPXKPH.js.map} +0 -0
  1043. /package/dist/{chunk-EDPH7AJH.js.map → chunk-UHRGUMLJ.js.map} +0 -0
  1044. /package/dist/{chunk-5JAYZOAW.js.map → chunk-UNDSD6UA.js.map} +0 -0
  1045. /package/dist/{chunk-FPN4I4CG.js.map → chunk-USU2SS4V.js.map} +0 -0
  1046. /package/dist/{chunk-Q4CLS2HL.js.map → chunk-USWA5GQQ.js.map} +0 -0
  1047. /package/dist/{chunk-QYZ5RVGM.js.map → chunk-UXGTI4HR.js.map} +0 -0
  1048. /package/dist/{chunk-JNJIZCTN.js.map → chunk-UZKAHEQO.js.map} +0 -0
  1049. /package/dist/{chunk-ML46TXRM.js.map → chunk-VALESBNH.js.map} +0 -0
  1050. /package/dist/{chunk-F6QP4GSK.js.map → chunk-VMSMVWCJ.js.map} +0 -0
  1051. /package/dist/{chunk-3EM5GTP3.js.map → chunk-VPERSFGV.js.map} +0 -0
  1052. /package/dist/{chunk-AZGGSPTE.js.map → chunk-VXPY2GF3.js.map} +0 -0
  1053. /package/dist/{chunk-6DQBUKGJ.js.map → chunk-W7RKXZDV.js.map} +0 -0
  1054. /package/dist/{chunk-72ND4ALI.js.map → chunk-WEGZPK4I.js.map} +0 -0
  1055. /package/dist/{chunk-LIOZ2MXJ.js.map → chunk-WPKY3BGG.js.map} +0 -0
  1056. /package/dist/{chunk-IIXNEOK4.js.map → chunk-X3T3N6W5.js.map} +0 -0
  1057. /package/dist/{chunk-HA5RFQAF.js.map → chunk-X4OGMBY6.js.map} +0 -0
  1058. /package/dist/{chunk-OITGZUDC.js.map → chunk-X7ZHIJEI.js.map} +0 -0
  1059. /package/dist/{chunk-UJH63JT3.js.map → chunk-XR7Y2HPZ.js.map} +0 -0
  1060. /package/dist/{chunk-ROSB7GF6.js.map → chunk-Y2NMKJ7F.js.map} +0 -0
  1061. /package/dist/{chunk-AI77ZKEV.js.map → chunk-Y2QYPJDN.js.map} +0 -0
  1062. /package/dist/{chunk-OATXCLTY.js.map → chunk-Y47EPVCD.js.map} +0 -0
  1063. /package/dist/{chunk-P4NZ72KY.js.map → chunk-Y5Q4ETIW.js.map} +0 -0
  1064. /package/dist/{chunk-UMLPIMGW.js.map → chunk-YMQVVFXI.js.map} +0 -0
  1065. /package/dist/{chunk-KJ72GMZ2.js.map → chunk-YQ6FP33X.js.map} +0 -0
  1066. /package/dist/{chunk-ZEQYHEWP.js.map → chunk-YUA42N5A.js.map} +0 -0
  1067. /package/dist/{chunk-V5Y74WII.js.map → chunk-YXFNW64N.js.map} +0 -0
  1068. /package/dist/{chunk-SXRYA7NN.js.map → chunk-Z76RJPZF.js.map} +0 -0
  1069. /package/dist/{chunk-MIUJ3EH5.js.map → chunk-ZD67RM6G.js.map} +0 -0
  1070. /package/dist/{chunk-XE4PHI74.js.map → chunk-ZE4RD7U5.js.map} +0 -0
  1071. /package/dist/{chunk-GLSDWNFV.js.map → chunk-ZGR7LNXC.js.map} +0 -0
  1072. /package/dist/{chunk-QMQF5U2D.js.map → chunk-ZNA65Q6Y.js.map} +0 -0
  1073. /package/dist/{chunk-46LZO4ZO.js.map → chunk-ZRNK6FK6.js.map} +0 -0
  1074. /package/dist/{chunk-2JTMFYCT.js.map → chunk-ZVAIKQMC.js.map} +0 -0
  1075. /package/dist/{chunk-TGCKZOSX.js.map → chunk-ZZ3KNGTJ.js.map} +0 -0
  1076. /package/dist/{sandbox-files-HCLEEJMU.js.map → computer-viewer-M5N3GWBR.js.map} +0 -0
  1077. /package/dist/{session-connect-cards-DRKEN3Z4.js.map → embedded-new-voice-QZJG5DZ3.js.map} +0 -0
  1078. /package/dist/{session-realtime-IZOTTRH6.js.map → embedded-voice-7KOQNGKU.js.map} +0 -0
  1079. /package/dist/{fleet-decision-row-LG3SYVR3.js.map → fleet-decision-row-FJPAWNOQ.js.map} +0 -0
  1080. /package/dist/{latest-question-QWJTXMFA.js.map → latest-question-F3VPDR7U.js.map} +0 -0
  1081. /package/dist/{payment-page-card-YPSXRHBA.js.map → payment-page-card-HZJVN3F4.js.map} +0 -0
  1082. /package/dist/{platform-activity-row-ZU4MEBNK.js.map → platform-activity-row-NPEGG2VE.js.map} +0 -0
  1083. /package/dist/{queue-surface-implementation-6Q25RPH6.js.map → queue-surface-implementation-RTCTPF5T.js.map} +0 -0
  1084. /package/dist/{recorder-host-JD4GWJ2Z.js.map → recorder-host-YPWPLMS6.js.map} +0 -0
  1085. /package/dist/{timeline-annotation-markers-WWXNJOXI.js.map → timeline-annotation-markers-7QSYK22C.js.map} +0 -0
  1086. /package/dist/{timeline-annotation-selection-ZKRIQFIQ.js.map → timeline-annotation-selection-XYNMESWL.js.map} +0 -0
  1087. /package/dist/{timeline-annotations-dialog-4IMKTOXJ.js.map → timeline-annotations-dialog-WSI6L2CP.js.map} +0 -0
@@ -0,0 +1,2580 @@
1
+ "use client";
2
+ import {
3
+ connectionStatusForState
4
+ } from "./chunk-MSXVGGFQ.js";
5
+ import {
6
+ machinePlatformLabel,
7
+ machineScopeLabel,
8
+ machineScreenLabel,
9
+ machineSystemDetail
10
+ } from "./chunk-2TBRW7I6.js";
11
+ import {
12
+ cn
13
+ } from "./chunk-TXS65BB2.js";
14
+ import {
15
+ useOpenGeniText
16
+ } from "./chunk-2L6B6766.js";
17
+ import {
18
+ formatBytes,
19
+ formatRelativeTime
20
+ } from "./chunk-UIK52VL4.js";
21
+
22
+ // src/components/machine-status-pill.tsx
23
+ import { jsx, jsxs } from "react/jsx-runtime";
24
+ var CONNECTION_STATUS_META = (t) => ({
25
+ online: {
26
+ label: t("machineStatusPill.online"),
27
+ dotClassName: "bg-og-status-running",
28
+ badgeClassName: "text-og-status-running border-og-status-running/30 bg-og-status-running/10",
29
+ pulse: false
30
+ },
31
+ reconnecting: {
32
+ label: t("machineStatusPill.reconnecting"),
33
+ dotClassName: "bg-og-status-waiting",
34
+ badgeClassName: "text-og-status-waiting border-og-status-waiting/35 bg-og-status-waiting/10",
35
+ pulse: true
36
+ },
37
+ offline: {
38
+ label: t("machineStatusPill.offline"),
39
+ dotClassName: "bg-og-status-failed",
40
+ badgeClassName: "text-og-fg-subtle border-og-border bg-og-status-failed/10",
41
+ pulse: false
42
+ }
43
+ });
44
+ var MACHINE_STATE_BADGE_META = (t) => ({
45
+ consent_required: {
46
+ label: t("machineStatusPill.consentRequired"),
47
+ badgeClassName: "text-og-status-waiting border-og-status-waiting/35 bg-og-status-waiting/10"
48
+ },
49
+ display_unavailable: {
50
+ label: t("machineStatusPill.noDisplay"),
51
+ badgeClassName: "text-og-fg-muted border-og-border bg-og-surface-2"
52
+ },
53
+ enrolling: {
54
+ label: t("machineStatusPill.enrolling"),
55
+ badgeClassName: "text-og-accent border-og-accent/30 bg-og-accent-soft"
56
+ }
57
+ });
58
+ function ConnectionStatusPill({
59
+ status,
60
+ label,
61
+ size = "md",
62
+ className
63
+ }) {
64
+ const t = useOpenGeniText();
65
+ const meta = CONNECTION_STATUS_META(t)[status];
66
+ return /* @__PURE__ */ jsxs(
67
+ "span",
68
+ {
69
+ "data-connection-status": status,
70
+ className: cn(
71
+ "og-root inline-flex shrink-0 items-center rounded-full border font-medium",
72
+ size === "sm" ? "gap-1 px-1.5 py-px text-og-xs" : "gap-1.5 px-2 py-0.5 text-og-sm",
73
+ meta.badgeClassName,
74
+ className
75
+ ),
76
+ children: [
77
+ /* @__PURE__ */ jsx(ConnectionDot, { status, className: size === "sm" ? "size-1" : "size-1.5" }),
78
+ label ?? meta.label
79
+ ]
80
+ }
81
+ );
82
+ }
83
+ function ConnectionDot({ status, className }) {
84
+ const t = useOpenGeniText();
85
+ const meta = CONNECTION_STATUS_META(t)[status];
86
+ return /* @__PURE__ */ jsx(
87
+ "span",
88
+ {
89
+ className: cn(
90
+ "relative inline-flex size-1.5 shrink-0 rounded-full",
91
+ meta.dotClassName,
92
+ className
93
+ ),
94
+ children: meta.pulse ? /* @__PURE__ */ jsx("span", { className: cn("absolute inset-0 animate-og-pulse rounded-full", meta.dotClassName) }) : null
95
+ }
96
+ );
97
+ }
98
+ function MachineStatusPill({
99
+ state,
100
+ sharedSessionCount,
101
+ size = "md",
102
+ className
103
+ }) {
104
+ const t = useOpenGeniText();
105
+ const stateBadge = MACHINE_STATE_BADGE_META(t)[state];
106
+ const shared = (sharedSessionCount ?? 0) > 1;
107
+ return /* @__PURE__ */ jsxs(
108
+ "span",
109
+ {
110
+ className: cn("og-root inline-flex flex-wrap items-center gap-1", className),
111
+ "data-machine-state": state,
112
+ children: [
113
+ /* @__PURE__ */ jsx(ConnectionStatusPill, { status: connectionStatusForState(state), size }),
114
+ stateBadge ? /* @__PURE__ */ jsx(
115
+ "span",
116
+ {
117
+ "data-state-badge": state,
118
+ className: cn(
119
+ "inline-flex shrink-0 items-center rounded-full border font-medium",
120
+ size === "sm" ? "px-1.5 py-px text-og-xs" : "px-2 py-0.5 text-og-sm",
121
+ stateBadge.badgeClassName
122
+ ),
123
+ children: stateBadge.label
124
+ }
125
+ ) : null,
126
+ shared ? /* @__PURE__ */ jsx(
127
+ "span",
128
+ {
129
+ "data-shared-chip": true,
130
+ className: cn(
131
+ "inline-flex shrink-0 items-center gap-1 rounded-full border font-medium",
132
+ "text-og-accent border-og-accent/30 bg-og-accent-soft",
133
+ size === "sm" ? "px-1.5 py-px text-og-xs" : "px-2 py-0.5 text-og-sm"
134
+ ),
135
+ title: t("machineStatusPill.sessionsOnThisMachine", { count: sharedSessionCount ?? 0 }),
136
+ children: t("machineStatusPill.sharedCount", { count: sharedSessionCount ?? 0 })
137
+ }
138
+ ) : null
139
+ ]
140
+ }
141
+ );
142
+ }
143
+
144
+ // src/components/machine-metrics.tsx
145
+ import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
146
+ function pct(value) {
147
+ if (!Number.isFinite(value)) return 0;
148
+ return Math.max(0, Math.min(100, value));
149
+ }
150
+ function Meter({
151
+ label,
152
+ value,
153
+ fillPct,
154
+ tone
155
+ }) {
156
+ const fillClass = tone === "hot" ? "bg-og-status-failed" : tone === "warn" ? "bg-og-status-running" : "bg-og-status-idle";
157
+ return /* @__PURE__ */ jsxs2("div", { className: "flex min-w-0 flex-col gap-1", "data-metric": label.toLowerCase(), children: [
158
+ /* @__PURE__ */ jsxs2("div", { className: "flex items-baseline justify-between gap-2", children: [
159
+ /* @__PURE__ */ jsx2("span", { className: "text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: label }),
160
+ /* @__PURE__ */ jsx2("span", { className: "font-og-mono text-[11px] tabular-nums text-og-fg-muted", children: value })
161
+ ] }),
162
+ /* @__PURE__ */ jsx2("div", { className: "h-1 w-full overflow-hidden rounded-full bg-og-surface-2", children: /* @__PURE__ */ jsx2(
163
+ "div",
164
+ {
165
+ className: cn("h-full rounded-full transition-[width] duration-500", fillClass),
166
+ style: { width: `${pct(fillPct)}%` }
167
+ }
168
+ ) })
169
+ ] });
170
+ }
171
+ function toneFor(p) {
172
+ if (p >= 90) return "hot";
173
+ if (p >= 70) return "warn";
174
+ return "ok";
175
+ }
176
+ function StatTriple({
177
+ load1,
178
+ load5,
179
+ load15,
180
+ runQueue
181
+ }) {
182
+ const t = useOpenGeniText();
183
+ const stats = [
184
+ { label: "1m", value: load1 },
185
+ { label: "5m", value: load5 },
186
+ { label: "15m", value: load15 }
187
+ ];
188
+ return /* @__PURE__ */ jsxs2("div", { className: "flex items-center justify-between gap-3", "data-metric": "load", children: [
189
+ /* @__PURE__ */ jsxs2("div", { className: "flex min-w-0 flex-col gap-1", children: [
190
+ /* @__PURE__ */ jsx2("span", { className: "text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: t("machineMetrics.load") }),
191
+ /* @__PURE__ */ jsx2("div", { className: "flex items-baseline gap-3", children: stats.map((s) => /* @__PURE__ */ jsxs2("div", { className: "flex items-baseline gap-1", children: [
192
+ /* @__PURE__ */ jsx2("span", { className: "text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: s.label }),
193
+ /* @__PURE__ */ jsx2("span", { className: "font-og-mono text-[12px] tabular-nums text-og-fg", children: s.value.toFixed(2) })
194
+ ] }, s.label)) })
195
+ ] }),
196
+ runQueue > 0 ? /* @__PURE__ */ jsxs2(
197
+ "div",
198
+ {
199
+ className: "flex shrink-0 items-baseline gap-1.5 rounded-og-sm bg-og-surface-2 px-2 py-1 text-[11px] text-og-fg-subtle",
200
+ "data-metric": "runqueue",
201
+ children: [
202
+ /* @__PURE__ */ jsx2("span", { className: "font-medium uppercase tracking-wide", children: t("machineMetrics.queue") }),
203
+ /* @__PURE__ */ jsx2("span", { className: "font-og-mono tabular-nums text-og-fg-muted", children: runQueue })
204
+ ]
205
+ }
206
+ ) : null
207
+ ] });
208
+ }
209
+ function MachineMetrics({ metrics, density = "compact", className }) {
210
+ const t = useOpenGeniText();
211
+ if (!metrics) {
212
+ return /* @__PURE__ */ jsx2("div", { className: cn("text-[11px] text-og-fg-subtle", className), "data-metrics-empty": true, children: t("machineMetrics.noMetricsYet") });
213
+ }
214
+ const memPct2 = metrics.memTotalBytes > 0 ? metrics.memUsedBytes / metrics.memTotalBytes * 100 : 0;
215
+ const diskPct2 = metrics.diskTotalBytes > 0 ? metrics.diskUsedBytes / metrics.diskTotalBytes * 100 : 0;
216
+ const hasGpu = metrics.gpuUtilPct !== null;
217
+ const gpuMemLabel = metrics.gpuMemBytes !== null ? formatBytes(metrics.gpuMemBytes) : null;
218
+ const ratioGridClass = density === "full" ? "grid-cols-1" : "grid-cols-1 sm:grid-cols-2";
219
+ return /* @__PURE__ */ jsxs2("div", { className: cn("flex flex-col gap-3", className), "data-machine-metrics": true, children: [
220
+ /* @__PURE__ */ jsxs2("div", { className: cn("grid gap-x-4 gap-y-2.5", ratioGridClass), children: [
221
+ /* @__PURE__ */ jsx2(
222
+ Meter,
223
+ {
224
+ label: t("machineMetrics.memory"),
225
+ value: `${formatBytes(metrics.memUsedBytes)} / ${formatBytes(metrics.memTotalBytes)}`,
226
+ fillPct: memPct2,
227
+ tone: toneFor(memPct2)
228
+ }
229
+ ),
230
+ /* @__PURE__ */ jsx2(
231
+ Meter,
232
+ {
233
+ label: t("machineMetrics.disk"),
234
+ value: `${formatBytes(metrics.diskUsedBytes)} / ${formatBytes(metrics.diskTotalBytes)}`,
235
+ fillPct: diskPct2,
236
+ tone: toneFor(diskPct2)
237
+ }
238
+ )
239
+ ] }),
240
+ /* @__PURE__ */ jsxs2("div", { className: "grid grid-cols-2 gap-x-4 gap-y-2.5", children: [
241
+ /* @__PURE__ */ jsx2(
242
+ Meter,
243
+ {
244
+ label: t("machineMetrics.cpu"),
245
+ value: `${metrics.cpuPct.toFixed(0)}%`,
246
+ fillPct: metrics.cpuPct,
247
+ tone: toneFor(metrics.cpuPct)
248
+ }
249
+ ),
250
+ hasGpu ? /* @__PURE__ */ jsx2(
251
+ Meter,
252
+ {
253
+ label: t("machineMetrics.gpu"),
254
+ value: gpuMemLabel ? `${metrics.gpuUtilPct.toFixed(0)}% \xB7 ${gpuMemLabel}` : `${metrics.gpuUtilPct.toFixed(0)}%`,
255
+ fillPct: metrics.gpuUtilPct,
256
+ tone: toneFor(metrics.gpuUtilPct)
257
+ }
258
+ ) : null
259
+ ] }),
260
+ density === "full" ? /* @__PURE__ */ jsx2(
261
+ StatTriple,
262
+ {
263
+ load1: metrics.load1,
264
+ load5: metrics.load5,
265
+ load15: metrics.load15,
266
+ runQueue: metrics.runQueue
267
+ }
268
+ ) : null
269
+ ] });
270
+ }
271
+
272
+ // src/components/machine-card.tsx
273
+ import {
274
+ AlertTriangleIcon,
275
+ ArrowRightIcon,
276
+ CpuIcon,
277
+ LaptopIcon,
278
+ MonitorIcon,
279
+ MonitorOffIcon,
280
+ ServerIcon,
281
+ UsersIcon
282
+ } from "lucide-react";
283
+
284
+ // src/components/machines/health.ts
285
+ var PRESSURE = {
286
+ cpu: { warn: 90, crit: 98 },
287
+ mem: { warn: 85, crit: 95 },
288
+ disk: { warn: 90, crit: 96 }
289
+ };
290
+ var STALE_AFTER_MS = 45e3;
291
+ function pct2(used, total) {
292
+ if (!Number.isFinite(used) || !Number.isFinite(total) || total <= 0) return 0;
293
+ return used / total * 100;
294
+ }
295
+ function deriveHealth(msg, state, metrics, now = Date.now()) {
296
+ if (state === "offline") {
297
+ return {
298
+ level: "offline",
299
+ label: msg("machines.health.offline"),
300
+ reason: msg("machines.health.notReachable"),
301
+ stale: true
302
+ };
303
+ }
304
+ if (state === "enrolling") {
305
+ return {
306
+ level: "unknown",
307
+ label: msg("machines.health.enrolling"),
308
+ reason: msg("machines.health.completingEnrollment"),
309
+ stale: false
310
+ };
311
+ }
312
+ const stale = metrics ? now - new Date(metrics.sampledAt).getTime() > STALE_AFTER_MS : true;
313
+ if (state === "reconnecting") {
314
+ return {
315
+ level: "degraded",
316
+ label: msg("machines.health.reconnecting"),
317
+ reason: msg("machines.health.reEstablishingLink"),
318
+ stale
319
+ };
320
+ }
321
+ if (!metrics) {
322
+ return {
323
+ level: "unknown",
324
+ label: msg("machines.health.online"),
325
+ reason: msg("machines.health.awaitingFirstSample"),
326
+ stale
327
+ };
328
+ }
329
+ if (stale) {
330
+ return {
331
+ level: "degraded",
332
+ label: msg("machines.health.telemetryStale"),
333
+ reason: msg("machines.health.noRecentSample"),
334
+ stale: true
335
+ };
336
+ }
337
+ const memPct2 = pct2(metrics.memUsedBytes, metrics.memTotalBytes);
338
+ const diskPct2 = pct2(metrics.diskUsedBytes, metrics.diskTotalBytes);
339
+ const cpu = metrics.cpuPct;
340
+ const pressures = [
341
+ resolve(msg("machines.health.disk"), diskPct2, PRESSURE.disk),
342
+ resolve(msg("machines.health.memory"), memPct2, PRESSURE.mem),
343
+ resolve("CPU", cpu, PRESSURE.cpu)
344
+ ];
345
+ const worst = pressures.reduce((a, b) => b.sev > a.sev ? b : a);
346
+ if (worst.sev === 2)
347
+ return {
348
+ level: "critical",
349
+ label: msg("machines.health.critical"),
350
+ reason: worst.reason,
351
+ stale
352
+ };
353
+ if (worst.sev === 1)
354
+ return {
355
+ level: "degraded",
356
+ label: msg("machines.health.underLoad"),
357
+ reason: worst.reason,
358
+ stale
359
+ };
360
+ return {
361
+ level: "healthy",
362
+ label: msg("machines.health.healthy"),
363
+ reason: msg("machines.health.allSystemsNominal"),
364
+ stale
365
+ };
366
+ }
367
+ function resolve(name, value, t) {
368
+ const rounded = Math.round(value);
369
+ if (value >= t.crit) return { level: "critical", reason: `${name} ${rounded}%`, sev: 2 };
370
+ if (value >= t.warn) return { level: "degraded", reason: `${name} ${rounded}%`, sev: 1 };
371
+ return { level: "healthy", reason: `${name} ${rounded}%`, sev: 0 };
372
+ }
373
+ var HEALTH_TOKEN = {
374
+ healthy: {
375
+ text: "text-og-status-idle",
376
+ dot: "bg-og-status-idle",
377
+ soft: "bg-og-status-idle/10 border-og-status-idle/25"
378
+ },
379
+ degraded: {
380
+ text: "text-og-status-running",
381
+ dot: "bg-og-status-running",
382
+ soft: "bg-og-status-running/10 border-og-status-running/25"
383
+ },
384
+ critical: {
385
+ text: "text-og-status-failed",
386
+ dot: "bg-og-status-failed",
387
+ soft: "bg-og-status-failed/10 border-og-status-failed/30"
388
+ },
389
+ offline: {
390
+ text: "text-og-fg-subtle",
391
+ dot: "bg-og-fg-subtle",
392
+ soft: "bg-og-surface-2 border-og-border"
393
+ },
394
+ unknown: {
395
+ text: "text-og-fg-muted",
396
+ dot: "bg-og-fg-muted",
397
+ soft: "bg-og-surface-2 border-og-border"
398
+ }
399
+ };
400
+ function healthPulses(level) {
401
+ return level === "degraded" || level === "critical";
402
+ }
403
+
404
+ // src/components/machine-health-pill.tsx
405
+ import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
406
+ function MachineHealthPill({
407
+ state,
408
+ metrics,
409
+ now,
410
+ size = "sm",
411
+ className
412
+ }) {
413
+ const t = useOpenGeniText();
414
+ const health = deriveHealth(t, state, metrics, now ?? Date.now());
415
+ const tone = HEALTH_TOKEN[health.level];
416
+ const badge = MACHINE_STATE_BADGE_META(t)[state];
417
+ const pad = size === "md" ? "px-2.5 py-1 text-og-sm" : "px-2 py-0.5 text-og-xs";
418
+ return /* @__PURE__ */ jsxs3("div", { className: cn("flex shrink-0 items-center gap-1.5", className), children: [
419
+ badge ? /* @__PURE__ */ jsx3(
420
+ "span",
421
+ {
422
+ className: cn(
423
+ "rounded-full border px-2 py-0.5 text-og-xs font-medium",
424
+ badge.badgeClassName
425
+ ),
426
+ children: badge.label
427
+ }
428
+ ) : null,
429
+ /* @__PURE__ */ jsxs3(
430
+ "span",
431
+ {
432
+ className: cn(
433
+ "inline-flex items-center gap-1.5 rounded-full border font-medium",
434
+ pad,
435
+ tone.soft,
436
+ tone.text
437
+ ),
438
+ "data-health": health.level,
439
+ title: health.reason,
440
+ children: [
441
+ /* @__PURE__ */ jsxs3("span", { className: "relative flex size-2", children: [
442
+ healthPulses(health.level) && /* @__PURE__ */ jsx3(
443
+ "span",
444
+ {
445
+ className: cn(
446
+ "absolute inline-flex size-full animate-og-pulse rounded-full opacity-60",
447
+ tone.dot
448
+ )
449
+ }
450
+ ),
451
+ /* @__PURE__ */ jsx3("span", { className: cn("relative inline-flex size-2 rounded-full", tone.dot) })
452
+ ] }),
453
+ health.label
454
+ ]
455
+ }
456
+ )
457
+ ] });
458
+ }
459
+
460
+ // src/components/machines/agent-status-icon.tsx
461
+ import {
462
+ CircleAlertIcon,
463
+ CircleCheckIcon,
464
+ ClockIcon,
465
+ DownloadIcon,
466
+ LoaderCircleIcon,
467
+ TriangleAlertIcon
468
+ } from "lucide-react";
469
+ import { jsx as jsx4 } from "react/jsx-runtime";
470
+ function AgentStatusIcon({ tone, className }) {
471
+ const size = cn("size-3.5 shrink-0", className);
472
+ switch (tone) {
473
+ case "ok":
474
+ return /* @__PURE__ */ jsx4(CircleCheckIcon, { className: cn(size, "text-og-status-idle"), "aria-hidden": true });
475
+ case "progress":
476
+ return /* @__PURE__ */ jsx4(LoaderCircleIcon, { className: cn(size, "animate-og-spin text-og-accent"), "aria-hidden": true });
477
+ case "waiting":
478
+ return /* @__PURE__ */ jsx4(ClockIcon, { className: cn(size, "text-og-fg-subtle"), "aria-hidden": true });
479
+ case "attention":
480
+ return /* @__PURE__ */ jsx4(TriangleAlertIcon, { className: cn(size, "text-og-status-waiting"), "aria-hidden": true });
481
+ case "failed":
482
+ return /* @__PURE__ */ jsx4(CircleAlertIcon, { className: cn(size, "text-og-status-failed"), "aria-hidden": true });
483
+ default:
484
+ return /* @__PURE__ */ jsx4(DownloadIcon, { className: cn(size, "text-og-fg-subtle"), "aria-hidden": true });
485
+ }
486
+ }
487
+
488
+ // src/components/machines/machine-status.ts
489
+ var UPDATE_CONFIRMATION_GRACE_MS = 3e4;
490
+ var UPDATE_HOLD_ATTENTION_MS = 10 * 6e4;
491
+ function elapsedDuration(t, ms) {
492
+ const minutes = Math.max(1, Math.floor(ms / 6e4));
493
+ return minutes < 60 ? t("lib.format.minutes", { count: minutes }) : minutes < 1440 ? t("lib.format.hours", { count: Math.floor(minutes / 60) }) : t("lib.format.days", { count: Math.floor(minutes / 1440) });
494
+ }
495
+ function updateWaitingReason(t, update, now) {
496
+ const labels = {
497
+ browser_action: t("machines.machineStatus.blockerBrowserAction"),
498
+ browser_session: t("machines.machineStatus.blockerBrowserSession"),
499
+ browser_creation: t("machines.machineStatus.blockerBrowserCreation"),
500
+ browser_closing: t("machines.machineStatus.blockerBrowserClosing"),
501
+ browser_recovery: t("machines.machineStatus.blockerBrowserRecovery"),
502
+ browser_authentication: t("machines.machineStatus.blockerBrowserAuth"),
503
+ browser_state_transfer: t("machines.machineStatus.blockerBrowserTransfer"),
504
+ computer_action: t("machines.machineStatus.blockerComputerAction"),
505
+ computer_virtual_seat: t("machines.machineStatus.blockerVirtualDesktop"),
506
+ computer_session: t("machines.machineStatus.blockerComputerSession"),
507
+ computer_creation: t("machines.machineStatus.blockerComputerCreation"),
508
+ computer_closing: t("machines.machineStatus.blockerComputerClosing"),
509
+ computer_seat_transfer: t("machines.machineStatus.blockerSeatTransfer"),
510
+ controller_request: t("machines.machineStatus.blockerControllerRequest"),
511
+ controller_lifecycle: t("machines.machineStatus.blockerControllerLifecycle"),
512
+ controller_stream: t("machines.machineStatus.blockerStream"),
513
+ controller_producer: t("machines.machineStatus.blockerProducer"),
514
+ controller_previous_update: t("machines.machineStatus.blockerPreviousUpdate"),
515
+ other_work: t("machines.machineStatus.blockerOtherWork"),
516
+ upload: t("machines.machineStatus.blockerUpload"),
517
+ native_request: t("machines.machineStatus.blockerNativeRequest"),
518
+ native_operation: t("machines.machineStatus.blockerNativeOperation"),
519
+ native_light_running: t("machines.machineStatus.blockerNativeRequest"),
520
+ native_light_queued: t("machines.machineStatus.blockerQueuedRequest"),
521
+ native_heavy_running: t("machines.machineStatus.blockerNativeOperation"),
522
+ native_heavy_queued: t("machines.machineStatus.blockerQueuedOperation")
523
+ };
524
+ const raw = update.blockers ?? [];
525
+ const native = raw.filter(
526
+ (blocker) => blocker.kind.startsWith("native_") && !blocker.kind.includes("cleanup")
527
+ );
528
+ const blockers = raw.filter((blocker) => !native.includes(blocker));
529
+ if (native.length)
530
+ blockers.push({
531
+ kind: "native_work",
532
+ count: Math.max(...native.map((blocker) => blocker.count))
533
+ });
534
+ labels.native_work = t("machines.machineStatus.blockerNativeCounters");
535
+ if (blockers.length) {
536
+ const details = blockers.map((blocker) => {
537
+ const label = labels[blocker.kind] ?? (blocker.kind.includes("cleanup") ? t("machines.machineStatus.blockerCleanup") : t("machines.machineStatus.blockerUnknown"));
538
+ return t("machines.machineStatus.blockerCount", { label, count: blocker.count });
539
+ }).join("; ");
540
+ return t("machines.machineStatus.reportedBlockers", {
541
+ details,
542
+ duration: elapsedDuration(t, now - Date.parse(update.updatedAt))
543
+ });
544
+ }
545
+ switch (update.errorCode) {
546
+ case "update_busy_interactions":
547
+ case "update_busy_browsers":
548
+ return t("machines.machineStatus.waitingForInteractions");
549
+ case "update_busy_uploads":
550
+ return t("machines.machineStatus.waitingForUploads");
551
+ case "update_busy_updating":
552
+ return t("machines.machineStatus.waitingForAnotherUpdate");
553
+ default:
554
+ return t("machines.machineStatus.waitingForUnspecifiedWork");
555
+ }
556
+ }
557
+ function isPostponedUpdate(errorCode) {
558
+ return typeof errorCode === "string" && errorCode.startsWith("update_busy");
559
+ }
560
+ var FAILURE_REASON = (t) => ({
561
+ update_cleanup_unconfirmed: t("machines.machineStatus.previousWorkCleanupUnconfirmed"),
562
+ update_state_unavailable: t("machines.machineStatus.theAgentCouldnTCheck"),
563
+ agent_offline: t("machines.machineStatus.theMachineWasOffline"),
564
+ update_dispatch_rejected: t("machines.machineStatus.theAgentRefusedTheRequest"),
565
+ invalid_agent_response: t("machines.machineStatus.theAgentSentAnUnexpected")
566
+ });
567
+ function failureReason(t, code) {
568
+ if (!code) return null;
569
+ return FAILURE_REASON(t)[code] ?? code.replaceAll("_", " ");
570
+ }
571
+ var ACTIVE_STATUSES = /* @__PURE__ */ new Set([
572
+ "requested",
573
+ "accepted",
574
+ "waiting_for_idle",
575
+ "downloading",
576
+ "verifying",
577
+ "applying",
578
+ "restarting"
579
+ ]);
580
+ function describeAgentRuntime(t, runtime, now, online = true) {
581
+ const installed = runtime.installedVersion;
582
+ const title = installed ? t("machines.machineStatus.agentVInstalled", { installed }) : t("machines.machineStatus.agentVersionUnknown");
583
+ const blocked = runtime.updateBlockedReason?.trim() || null;
584
+ const update = runtime.update;
585
+ const target = update ? `v${update.targetVersion}` : null;
586
+ const alreadyInstalled = update !== null && (update.targetVersion === installed || runtime.versionState === "current" || runtime.versionState === "ahead");
587
+ if (update && ACTIVE_STATUSES.has(update.status) && !alreadyInstalled) {
588
+ const base = { title, tone: "progress", note: null, action: null };
589
+ switch (update.status) {
590
+ case "requested": {
591
+ const stalled = now - new Date(update.updatedAt).getTime() >= UPDATE_CONFIRMATION_GRACE_MS;
592
+ return stalled ? {
593
+ title,
594
+ status: t("machines.machineStatus.theAgentHasnTConfirmed", { target }),
595
+ tone: "attention",
596
+ note: null,
597
+ action: { kind: "resend", label: t("machines.machineStatus.sendAgain") }
598
+ } : { ...base, status: t("machines.machineStatus.sendingTheUpdateToTarget", { target }) };
599
+ }
600
+ case "accepted":
601
+ return { ...base, status: t("machines.machineStatus.updatingToTarget", { target }) };
602
+ case "waiting_for_idle": {
603
+ const heldMs = Math.max(0, now - Date.parse(update.requestedAt));
604
+ const duration = elapsedDuration(t, heldMs);
605
+ return {
606
+ ...base,
607
+ tone: !online ? "muted" : heldMs >= UPDATE_HOLD_ATTENTION_MS ? "attention" : "waiting",
608
+ status: !online ? t("machines.machineStatus.offlineUpdateReport") : heldMs >= UPDATE_HOLD_ATTENTION_MS ? t("machines.machineStatus.updateHeldDuration", { target, duration }) : t("machines.machineStatus.updatesToTargetWhenCurrent", { target }),
609
+ note: blocked ?? updateWaitingReason(t, update, now)
610
+ };
611
+ }
612
+ case "downloading":
613
+ return { ...base, status: `Downloading ${target}\u2026` };
614
+ case "verifying":
615
+ return { ...base, status: `Verifying ${target}\u2026` };
616
+ case "applying":
617
+ return { ...base, status: `Installing ${target}\u2026` };
618
+ default:
619
+ return { ...base, status: t("machines.machineStatus.restartingTheAgent") };
620
+ }
621
+ }
622
+ if (update?.status === "failed" && !alreadyInstalled) {
623
+ if (isPostponedUpdate(update.errorCode)) {
624
+ const browsersWouldClose = update.errorCode === "update_busy_browsers";
625
+ return {
626
+ title,
627
+ status: browsersWouldClose ? t("machines.machineStatus.updateToTargetPostponedOpen", { target }) : t("machines.machineStatus.updateToTargetPostponedWhile", { target }),
628
+ tone: "waiting",
629
+ note: blocked ?? (browsersWouldClose ? t("machines.machineStatus.theInstalledAgentClosesIts") : updateWaitingReason(t, update, now)),
630
+ action: blocked ? null : { kind: "update", label: t("machines.machineStatus.updateNow") }
631
+ };
632
+ }
633
+ const reason = failureReason(t, update.errorCode);
634
+ const retry = update.retryable && !blocked ? { kind: "retry", label: t("machines.machineStatus.tryAgain") } : null;
635
+ if (update.rolledBack) {
636
+ return {
637
+ title,
638
+ status: t("machines.machineStatus.couldnTUpdateToTarget", { target }),
639
+ tone: "attention",
640
+ note: blocked ?? (reason ? t("machines.machineStatus.reasonReason", { reason }) : null),
641
+ action: retry
642
+ };
643
+ }
644
+ return {
645
+ title,
646
+ status: t("machines.machineStatus.updateToTargetFailed", { target }),
647
+ tone: "failed",
648
+ note: blocked ?? (reason ? t("machines.machineStatus.reasonReason", { reason }) : null),
649
+ action: retry
650
+ };
651
+ }
652
+ const desired = runtime.desiredVersion;
653
+ switch (runtime.versionState) {
654
+ case "current":
655
+ return {
656
+ title,
657
+ status: runtime.updateChannel === "beta" ? t("machines.machineStatus.upToDateBeta") : t("machines.machineStatus.upToDate"),
658
+ tone: "ok",
659
+ note: null,
660
+ action: null
661
+ };
662
+ case "ahead":
663
+ return {
664
+ title,
665
+ status: desired ? t("machines.machineStatus.newerThanTheReleasedV", { desired }) : t("machines.machineStatus.newerThanTheRelease"),
666
+ tone: "muted",
667
+ note: null,
668
+ action: null
669
+ };
670
+ case "unknown":
671
+ return {
672
+ title,
673
+ status: desired ? t("machines.machineStatus.latestIsVDesired", { desired }) : t("machines.machineStatus.noReleaseConfigured"),
674
+ tone: "muted",
675
+ note: blocked,
676
+ action: null
677
+ };
678
+ default:
679
+ if (!desired || desired === installed) {
680
+ return {
681
+ title,
682
+ status: t("machines.machineStatus.upToDate"),
683
+ tone: "ok",
684
+ note: null,
685
+ action: null
686
+ };
687
+ }
688
+ return {
689
+ title,
690
+ status: `v${desired} available`,
691
+ tone: "waiting",
692
+ note: blocked,
693
+ action: blocked ? null : { kind: "update", label: t("machines.machineStatus.update") }
694
+ };
695
+ }
696
+ }
697
+ var RUNNER_CONFLICT_ACTIVE_MS = 2 * 6e4;
698
+ function runnerConflict(authority, now) {
699
+ if (authority.duplicateRunnerDeniedCount <= 0) return null;
700
+ const lastAt = authority.duplicateRunnerDeniedAt;
701
+ const last = lastAt ? new Date(lastAt).getTime() : Number.NaN;
702
+ return {
703
+ active: Number.isFinite(last) && now - last < RUNNER_CONFLICT_ACTIVE_MS,
704
+ count: authority.duplicateRunnerDeniedCount,
705
+ lastAt
706
+ };
707
+ }
708
+ function describeAgentConnection(t, authority) {
709
+ if (authority.state !== "active" && authority.authenticationError === "credentials_expired") {
710
+ return {
711
+ label: t("machines.machineStatus.credentialsExpired"),
712
+ detail: t("machines.machineStatus.credentialsRecovery")
713
+ };
714
+ }
715
+ const label = authority.state === "active" ? t("machines.machineStatus.agentConnected") : authority.state === "expired" ? t("machines.machineStatus.agentConnectionLapsed") : t("machines.machineStatus.agentNotConnectedYet");
716
+ const n = authority.supersededCount;
717
+ return {
718
+ label,
719
+ detail: authority.state === "expired" || authority.state === "unclaimed" ? t("machines.machineStatus.offlineRecovery") : n > 0 ? t("machines.machineStatus.reconnectedTimesSinceSetup", { count: n }) : null
720
+ };
721
+ }
722
+ var STATUS_TONE_TEXT = {
723
+ ok: "text-og-status-idle",
724
+ progress: "text-og-accent",
725
+ waiting: "text-og-fg-muted",
726
+ attention: "text-og-status-waiting",
727
+ failed: "text-og-status-failed",
728
+ muted: "text-og-fg-subtle"
729
+ };
730
+
731
+ // src/components/machines/metric-sparkline.tsx
732
+ import { jsx as jsx5, jsxs as jsxs4 } from "react/jsx-runtime";
733
+ var VW = 120;
734
+ function MetricSparkline({
735
+ points,
736
+ color = "var(--og-color-accent)",
737
+ yMax = "auto",
738
+ height = 28,
739
+ className
740
+ }) {
741
+ const valued = points.filter(
742
+ (p) => p.v != null && Number.isFinite(p.v)
743
+ );
744
+ if (valued.length < 2) {
745
+ return /* @__PURE__ */ jsx5("div", { className, style: { height }, "aria-hidden": true });
746
+ }
747
+ const vh = height;
748
+ const top = yMax === "auto" ? Math.max(1, ...valued.map((p) => p.v)) * 1.1 : yMax;
749
+ const tMin = valued[0].t;
750
+ const tSpan = Math.max(1, valued[valued.length - 1].t - tMin);
751
+ const xy = valued.map((p) => ({
752
+ x: (p.t - tMin) / tSpan * VW,
753
+ y: vh - Math.min(top, Math.max(0, p.v)) / Math.max(1e-6, top) * (vh - 2) - 1
754
+ }));
755
+ let d = `M${xy[0].x},${xy[0].y}`;
756
+ for (let i = 0; i < xy.length - 1; i++) {
757
+ const p0 = xy[i - 1] ?? xy[i];
758
+ const p1 = xy[i];
759
+ const p2 = xy[i + 1];
760
+ const p3 = xy[i + 2] ?? p2;
761
+ d += `C${p1.x + (p2.x - p0.x) / 6},${p1.y + (p2.y - p0.y) / 6} ${p2.x - (p3.x - p1.x) / 6},${p2.y - (p3.y - p1.y) / 6} ${p2.x},${p2.y}`;
762
+ }
763
+ const last = xy[xy.length - 1];
764
+ const gid = `spark-${Math.round(top)}-${color.length}`;
765
+ return /* @__PURE__ */ jsxs4(
766
+ "svg",
767
+ {
768
+ viewBox: `0 0 ${VW} ${vh}`,
769
+ preserveAspectRatio: "none",
770
+ className,
771
+ style: { height, width: "100%" },
772
+ "aria-hidden": true,
773
+ children: [
774
+ /* @__PURE__ */ jsx5("defs", { children: /* @__PURE__ */ jsxs4("linearGradient", { id: gid, x1: "0", y1: "0", x2: "0", y2: "1", children: [
775
+ /* @__PURE__ */ jsx5("stop", { offset: "0%", stopColor: color, stopOpacity: "0.22" }),
776
+ /* @__PURE__ */ jsx5("stop", { offset: "100%", stopColor: color, stopOpacity: "0" })
777
+ ] }) }),
778
+ /* @__PURE__ */ jsx5("path", { d: `${d} L${last.x},${vh} L${xy[0].x},${vh} Z`, fill: `url(#${gid})` }),
779
+ /* @__PURE__ */ jsx5(
780
+ "path",
781
+ {
782
+ d,
783
+ fill: "none",
784
+ stroke: color,
785
+ strokeWidth: 1.25,
786
+ strokeLinejoin: "round",
787
+ strokeLinecap: "round",
788
+ vectorEffect: "non-scaling-stroke"
789
+ }
790
+ ),
791
+ /* @__PURE__ */ jsx5("circle", { cx: last.x, cy: last.y, r: 1.6, fill: color, vectorEffect: "non-scaling-stroke" })
792
+ ]
793
+ }
794
+ );
795
+ }
796
+
797
+ // src/components/machine-card.tsx
798
+ import { Fragment, jsx as jsx6, jsxs as jsxs5 } from "react/jsx-runtime";
799
+ function KindIcon({ machine }) {
800
+ if (machine.kind === "local" || machine.kind === "selfhosted")
801
+ return /* @__PURE__ */ jsx6(LaptopIcon, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
802
+ if (machine.kind === "docker" || machine.isSessionGroup)
803
+ return /* @__PURE__ */ jsx6(ServerIcon, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
804
+ if (machine.kind === "modal") return /* @__PURE__ */ jsx6(CpuIcon, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
805
+ return /* @__PURE__ */ jsx6(ServerIcon, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
806
+ }
807
+ function MachineCard({
808
+ machine,
809
+ onAttach,
810
+ attaching,
811
+ onUpdateAgent,
812
+ updatingAgent,
813
+ series,
814
+ onOpenDetail,
815
+ now,
816
+ className
817
+ }) {
818
+ const msg = useOpenGeniText();
819
+ const offline = machine.state === "offline";
820
+ const attachable = !machine.active && !offline && Boolean(onAttach);
821
+ const shared = machine.sharedSessionCount > 1;
822
+ const clockNow = now ?? Date.now();
823
+ const sampledAgo = machine.metrics ? formatRelativeTime(msg, machine.metrics.sampledAt, new Date(clockNow)) : null;
824
+ const cpuPts = (series ?? []).map((s) => ({ t: new Date(s.sampledAt).getTime(), v: s.cpuPct }));
825
+ const openable = Boolean(onOpenDetail);
826
+ const runtime = machine.runtime;
827
+ const agent = runtime ? describeAgentRuntime(
828
+ msg,
829
+ runtime,
830
+ clockNow,
831
+ connectionStatusForState(machine.state) === "online"
832
+ ) : null;
833
+ const updateAction = agent?.action && machine.enrollmentId && onUpdateAgent && !offline ? agent.action : null;
834
+ const conflict = runnerConflict(machine.connectionAuthority, clockNow);
835
+ return /* @__PURE__ */ jsxs5(
836
+ "div",
837
+ {
838
+ "data-machine-card": machine.sandboxId,
839
+ "data-active": machine.active ? "true" : "false",
840
+ role: openable ? "button" : void 0,
841
+ tabIndex: openable ? 0 : void 0,
842
+ onClick: openable ? () => onOpenDetail?.(machine) : void 0,
843
+ onKeyDown: openable ? (e) => {
844
+ if (e.key === "Enter" || e.key === " ") {
845
+ e.preventDefault();
846
+ onOpenDetail?.(machine);
847
+ }
848
+ } : void 0,
849
+ className: cn(
850
+ "og-root group relative flex flex-col gap-3 overflow-hidden rounded-og-lg border border-og-border",
851
+ "bg-og-surface-1 p-4 shadow-og-sm transition-colors",
852
+ openable && "cursor-pointer hover:border-og-border-strong focus-visible:border-og-accent/60 focus-visible:outline-hidden",
853
+ machine.active && "border-og-accent/40",
854
+ className
855
+ ),
856
+ children: [
857
+ machine.active ? /* @__PURE__ */ jsx6("span", { "aria-hidden": true, className: "absolute inset-y-0 left-0 w-0.5 bg-og-accent" }) : null,
858
+ /* @__PURE__ */ jsxs5("div", { className: "flex items-start justify-between gap-3", children: [
859
+ /* @__PURE__ */ jsxs5("div", { className: "flex min-w-0 items-start gap-2.5", children: [
860
+ /* @__PURE__ */ jsx6("span", { className: "mt-0.5 shrink-0", children: /* @__PURE__ */ jsx6(KindIcon, { machine }) }),
861
+ /* @__PURE__ */ jsxs5("div", { className: "min-w-0", children: [
862
+ /* @__PURE__ */ jsxs5("div", { className: "flex items-center gap-2", children: [
863
+ /* @__PURE__ */ jsx6("span", { className: "truncate text-og-base font-medium text-og-fg", children: machine.name }),
864
+ machine.active ? /* @__PURE__ */ jsx6(
865
+ "span",
866
+ {
867
+ "data-active-marker": true,
868
+ className: "shrink-0 rounded-full border border-og-accent/30 bg-og-accent-soft px-1.5 py-px text-og-xs font-medium text-og-accent",
869
+ children: msg("machineCard.active")
870
+ }
871
+ ) : null
872
+ ] }),
873
+ /* @__PURE__ */ jsxs5("div", { className: "mt-0.5 flex flex-col gap-0.5 text-og-xs text-og-fg-subtle", children: [
874
+ /* @__PURE__ */ jsxs5("span", { className: "flex flex-wrap items-center gap-x-2", children: [
875
+ /* @__PURE__ */ jsx6("span", { "data-machine-scope": machine.scope, children: machineScopeLabel(msg, machine.scope) }),
876
+ /* @__PURE__ */ jsx6("span", { "aria-hidden": true, children: "\xB7" }),
877
+ /* @__PURE__ */ jsx6("span", { "data-machine-platform": true, title: machineSystemDetail(machine), children: machinePlatformLabel(msg, machine.os) })
878
+ ] }),
879
+ /* @__PURE__ */ jsxs5("span", { "data-machine-screen": true, className: "inline-flex items-center gap-1", children: [
880
+ machine.hasDisplay && machine.allowScreenControl ? /* @__PURE__ */ jsx6(MonitorIcon, { className: "size-3", "aria-hidden": true }) : /* @__PURE__ */ jsx6(MonitorOffIcon, { className: "size-3", "aria-hidden": true }),
881
+ machineScreenLabel(msg, machine)
882
+ ] })
883
+ ] })
884
+ ] })
885
+ ] }),
886
+ /* @__PURE__ */ jsx6(
887
+ MachineHealthPill,
888
+ {
889
+ state: machine.state,
890
+ metrics: machine.metrics,
891
+ now: clockNow,
892
+ size: "sm",
893
+ className: "shrink-0"
894
+ }
895
+ )
896
+ ] }),
897
+ shared ? /* @__PURE__ */ jsxs5(
898
+ "p",
899
+ {
900
+ "data-shared-disclosure": true,
901
+ className: "flex items-center gap-1.5 rounded-og-md border border-og-accent/25 bg-og-accent-soft px-2.5 py-1.5 text-og-xs text-og-fg-muted",
902
+ children: [
903
+ /* @__PURE__ */ jsx6(UsersIcon, { className: "size-3.5 shrink-0 text-og-accent", "aria-hidden": true }),
904
+ msg("machineCard.sharedSharedsessioncountSessionsAreOn", {
905
+ sharedSessionCount: machine.sharedSessionCount
906
+ })
907
+ ]
908
+ }
909
+ ) : null,
910
+ conflict?.active ? /* @__PURE__ */ jsxs5(
911
+ "p",
912
+ {
913
+ "data-runner-conflict": true,
914
+ className: "flex items-start gap-1.5 rounded-og-md border border-og-status-waiting/30 bg-og-status-waiting/5 px-2.5 py-1.5 text-og-xs text-og-fg-muted",
915
+ children: [
916
+ /* @__PURE__ */ jsx6(
917
+ AlertTriangleIcon,
918
+ {
919
+ className: "mt-px size-3.5 shrink-0 text-og-status-waiting",
920
+ "aria-hidden": true
921
+ }
922
+ ),
923
+ /* @__PURE__ */ jsx6("span", { children: msg("machineCard.aSecondCopyOfThe") })
924
+ ]
925
+ }
926
+ ) : null,
927
+ agent ? /* @__PURE__ */ jsxs5(
928
+ "div",
929
+ {
930
+ "data-agent-runtime": true,
931
+ className: "flex items-center justify-between gap-3 rounded-og-md border border-og-border/70 bg-og-surface-2/35 px-2.5 py-2 text-og-xs",
932
+ children: [
933
+ /* @__PURE__ */ jsxs5("div", { className: "min-w-0", children: [
934
+ /* @__PURE__ */ jsxs5("div", { className: "flex items-center gap-1.5 text-og-fg-muted", children: [
935
+ /* @__PURE__ */ jsx6(AgentStatusIcon, { tone: agent.tone }),
936
+ /* @__PURE__ */ jsx6("span", { className: "truncate", children: agent.title })
937
+ ] }),
938
+ /* @__PURE__ */ jsx6(
939
+ "p",
940
+ {
941
+ "data-agent-status": agent.tone,
942
+ className: cn("mt-0.5", STATUS_TONE_TEXT[agent.tone]),
943
+ children: agent.status
944
+ }
945
+ ),
946
+ agent.note ? /* @__PURE__ */ jsx6("p", { className: "mt-1 text-og-fg-muted", children: agent.note }) : null
947
+ ] }),
948
+ updateAction ? /* @__PURE__ */ jsx6(
949
+ "button",
950
+ {
951
+ type: "button",
952
+ "data-update-agent": true,
953
+ "data-update-action": updateAction.kind,
954
+ disabled: updatingAgent,
955
+ onClick: (event) => {
956
+ event.stopPropagation();
957
+ onUpdateAgent?.(machine);
958
+ },
959
+ className: "shrink-0 rounded-og-sm border border-og-border px-2 py-1 font-medium text-og-fg-muted transition-colors hover:border-og-border-strong hover:text-og-fg disabled:cursor-not-allowed disabled:opacity-50 pointer-coarse:min-h-11",
960
+ children: updatingAgent ? msg("machineCard.starting") : updateAction.label
961
+ }
962
+ ) : null
963
+ ]
964
+ }
965
+ ) : null,
966
+ /* @__PURE__ */ jsx6(MachineMetrics, { metrics: machine.metrics }),
967
+ cpuPts.length > 1 ? /* @__PURE__ */ jsxs5("div", { className: "flex flex-col gap-1 rounded-og-md bg-og-surface-2/40 p-2.5", children: [
968
+ /* @__PURE__ */ jsxs5("div", { className: "flex items-center justify-between text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: [
969
+ /* @__PURE__ */ jsx6("span", { children: msg("machineCard.cpuLast15m") }),
970
+ openable ? /* @__PURE__ */ jsxs5("span", { className: "flex items-center gap-0.5 opacity-0 transition-opacity group-hover:opacity-100", children: [
971
+ msg("machineCard.telemetry"),
972
+ " ",
973
+ /* @__PURE__ */ jsx6(ArrowRightIcon, { className: "size-2.5", "aria-hidden": true })
974
+ ] }) : null
975
+ ] }),
976
+ /* @__PURE__ */ jsx6(MetricSparkline, { points: cpuPts, color: "var(--og-color-accent)", yMax: 100, height: 26 })
977
+ ] }) : null,
978
+ /* @__PURE__ */ jsxs5("div", { className: "mt-1 flex items-center justify-between gap-3 text-og-xs text-og-fg-subtle", children: [
979
+ /* @__PURE__ */ jsx6("span", { className: "inline-flex items-center gap-1.5", children: sampledAgo ? /* @__PURE__ */ jsxs5(Fragment, { children: [
980
+ /* @__PURE__ */ jsx6(
981
+ "span",
982
+ {
983
+ className: cn(
984
+ "size-1.5 rounded-full",
985
+ sampledAgo === "now" ? "bg-og-status-idle" : "bg-og-fg-subtle"
986
+ ),
987
+ "aria-hidden": true
988
+ }
989
+ ),
990
+ sampledAgo === "now" ? msg("machineCard.live") : msg("machineCard.updatedSampledagoAgo", { sampledAgo })
991
+ ] }) : machine.lastSeenAt ? /* @__PURE__ */ jsxs5(Fragment, { children: [
992
+ msg("machineCard.lastSeen"),
993
+ " ",
994
+ formatRelativeTime(msg, machine.lastSeenAt, new Date(clockNow))
995
+ ] }) : msg("machineCard.neverConnected") }),
996
+ machine.active ? /* @__PURE__ */ jsx6("span", { className: "text-og-accent", children: msg("machineCard.routingHere") }) : attachable ? /* @__PURE__ */ jsx6(
997
+ "button",
998
+ {
999
+ type: "button",
1000
+ "data-attach": true,
1001
+ disabled: attaching,
1002
+ onClick: (e) => {
1003
+ e.stopPropagation();
1004
+ onAttach?.(machine);
1005
+ },
1006
+ className: cn(
1007
+ "rounded-og-sm border border-og-border px-2.5 py-1 text-og-xs font-medium text-og-fg-muted transition-colors pointer-coarse:min-h-11",
1008
+ "hover:border-og-border-strong hover:text-og-fg disabled:cursor-not-allowed disabled:opacity-50"
1009
+ ),
1010
+ children: attaching ? msg("machineCard.switching") : msg("machineCard.attach")
1011
+ }
1012
+ ) : /* @__PURE__ */ jsx6("span", { className: "text-og-fg-subtle/70", children: offline ? msg("machineCard.unavailable") : "\u2014" })
1013
+ ] })
1014
+ ]
1015
+ }
1016
+ );
1017
+ }
1018
+
1019
+ // src/components/machines/metric-history-chart.tsx
1020
+ import { useLayoutEffect, useRef, useState } from "react";
1021
+ import { jsx as jsx7, jsxs as jsxs6 } from "react/jsx-runtime";
1022
+ var PAD = { top: 10, right: 12, bottom: 18, left: 40 };
1023
+ function niceCeil(v) {
1024
+ if (v <= 0) return 1;
1025
+ const mag = 10 ** Math.floor(Math.log10(v));
1026
+ const n = v / mag;
1027
+ const step = n <= 1 ? 1 : n <= 2 ? 2 : n <= 5 ? 5 : 10;
1028
+ return step * mag;
1029
+ }
1030
+ function smoothPath(pts) {
1031
+ if (pts.length === 0) return "";
1032
+ if (pts.length === 1) return `M${pts[0].x},${pts[0].y}`;
1033
+ let d = `M${pts[0].x},${pts[0].y}`;
1034
+ for (let i = 0; i < pts.length - 1; i++) {
1035
+ const p0 = pts[i - 1] ?? pts[i];
1036
+ const p1 = pts[i];
1037
+ const p2 = pts[i + 1];
1038
+ const p3 = pts[i + 2] ?? p2;
1039
+ const cp1x = p1.x + (p2.x - p0.x) / 6;
1040
+ const cp1y = p1.y + (p2.y - p0.y) / 6;
1041
+ const cp2x = p2.x - (p3.x - p1.x) / 6;
1042
+ const cp2y = p2.y - (p3.y - p1.y) / 6;
1043
+ d += `C${cp1x},${cp1y} ${cp2x},${cp2y} ${p2.x},${p2.y}`;
1044
+ }
1045
+ return d;
1046
+ }
1047
+ function fmtClock(t) {
1048
+ const d = new Date(t);
1049
+ return `${d.getHours().toString().padStart(2, "0")}:${d.getMinutes().toString().padStart(2, "0")}`;
1050
+ }
1051
+ function MetricHistoryChart({
1052
+ points,
1053
+ yMax = "auto",
1054
+ yMin = 0,
1055
+ format,
1056
+ unit = "",
1057
+ color = "var(--og-color-accent)",
1058
+ thresholds,
1059
+ height = 132,
1060
+ rangeLabel: rangeLabelProp,
1061
+ className
1062
+ }) {
1063
+ const msg = useOpenGeniText();
1064
+ const rangeLabel = rangeLabelProp === void 0 ? msg("machines.metricHistoryChart.inThisRange") : rangeLabelProp;
1065
+ const ref = useRef(null);
1066
+ const [w, setW] = useState(560);
1067
+ const [hover, setHover] = useState(null);
1068
+ useLayoutEffect(() => {
1069
+ const el = ref.current;
1070
+ if (!el) return;
1071
+ const ro = new ResizeObserver((entries) => {
1072
+ const cw = entries[0]?.contentRect.width;
1073
+ if (cw && cw > 0) setW(cw);
1074
+ });
1075
+ ro.observe(el);
1076
+ return () => ro.disconnect();
1077
+ }, []);
1078
+ const valued = points.filter(
1079
+ (p) => p.v != null && Number.isFinite(p.v)
1080
+ );
1081
+ const fmt = format ?? ((v) => `${Math.round(v)}${unit}`);
1082
+ const H = height;
1083
+ const plotW = Math.max(1, w - PAD.left - PAD.right);
1084
+ const plotH = Math.max(1, H - PAD.top - PAD.bottom);
1085
+ const dataMax = valued.length ? Math.max(...valued.map((p) => p.v)) : 1;
1086
+ const top = yMax === "auto" ? niceCeil(Math.max(dataMax * 1.15, thresholds?.warn ?? 0, 1)) : yMax;
1087
+ const span = Math.max(1e-6, top - yMin);
1088
+ const tMin = valued.length ? valued[0].t : 0;
1089
+ const tMax = valued.length ? valued[valued.length - 1].t : 1;
1090
+ const tSpan = Math.max(1, tMax - tMin);
1091
+ const xOf = (t) => PAD.left + (t - tMin) / tSpan * plotW;
1092
+ const yOf = (v) => PAD.top + (1 - (Math.min(top, Math.max(yMin, v)) - yMin) / span) * plotH;
1093
+ const pxPts = valued.map((p) => ({ x: xOf(p.t), y: yOf(p.v), t: p.t, v: p.v }));
1094
+ const sparse = pxPts.length > 0 && pxPts.length <= 4;
1095
+ const line = smoothPath(pxPts);
1096
+ const area = pxPts.length > 1 ? `${line} L${pxPts[pxPts.length - 1].x},${PAD.top + plotH} L${pxPts[0].x},${PAD.top + plotH} Z` : "";
1097
+ const yTicks = [yMin, yMin + span / 2, top];
1098
+ const gid = `og-mh-${Math.round(top)}-${Math.round(color.length)}`;
1099
+ const hoverPt = hover != null ? pxPts[hover] : null;
1100
+ return /* @__PURE__ */ jsxs6(
1101
+ "div",
1102
+ {
1103
+ ref,
1104
+ className: cn("relative w-full select-none", className),
1105
+ style: { height: H },
1106
+ "data-metric-chart": true,
1107
+ children: [
1108
+ valued.length === 0 ? /* @__PURE__ */ jsx7("div", { className: "absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx7("span", { className: "text-og-xs text-og-fg-subtle", children: msg("machines.metricHistoryChart.noSamplesRangelabel", { rangeLabel }) }) }) : /* @__PURE__ */ jsxs6(
1109
+ "svg",
1110
+ {
1111
+ width: w,
1112
+ height: H,
1113
+ className: "overflow-visible",
1114
+ role: "img",
1115
+ onMouseLeave: () => setHover(null),
1116
+ onMouseMove: (e) => {
1117
+ const rect = e.currentTarget.getBoundingClientRect();
1118
+ const mx = e.clientX - rect.left;
1119
+ let best = 0;
1120
+ let bestD = Infinity;
1121
+ for (let i = 0; i < pxPts.length; i++) {
1122
+ const d = Math.abs(pxPts[i].x - mx);
1123
+ if (d < bestD) {
1124
+ bestD = d;
1125
+ best = i;
1126
+ }
1127
+ }
1128
+ setHover(best);
1129
+ },
1130
+ children: [
1131
+ /* @__PURE__ */ jsx7("defs", { children: /* @__PURE__ */ jsxs6("linearGradient", { id: gid, x1: "0", y1: "0", x2: "0", y2: "1", children: [
1132
+ /* @__PURE__ */ jsx7("stop", { offset: "0%", stopColor: color, stopOpacity: "0.26" }),
1133
+ /* @__PURE__ */ jsx7("stop", { offset: "100%", stopColor: color, stopOpacity: "0" })
1134
+ ] }) }),
1135
+ yTicks.map((v, i) => {
1136
+ const y = yOf(v);
1137
+ return /* @__PURE__ */ jsxs6("g", { children: [
1138
+ /* @__PURE__ */ jsx7(
1139
+ "line",
1140
+ {
1141
+ x1: PAD.left,
1142
+ x2: w - PAD.right,
1143
+ y1: y,
1144
+ y2: y,
1145
+ stroke: "var(--og-color-border)",
1146
+ strokeOpacity: i === 0 ? 0.9 : 0.4,
1147
+ strokeWidth: 1
1148
+ }
1149
+ ),
1150
+ /* @__PURE__ */ jsx7(
1151
+ "text",
1152
+ {
1153
+ x: PAD.left - 8,
1154
+ y: y + 3,
1155
+ textAnchor: "end",
1156
+ className: "font-og-mono",
1157
+ fontSize: 10,
1158
+ fill: "var(--og-color-fg-subtle)",
1159
+ children: fmt(v)
1160
+ }
1161
+ )
1162
+ ] }, `yt-${v}`);
1163
+ }),
1164
+ ["warn", "crit"].map((k) => {
1165
+ const tv = thresholds?.[k];
1166
+ if (tv == null || tv > top) return null;
1167
+ const y = yOf(tv);
1168
+ const stroke = k === "crit" ? "var(--og-color-status-failed)" : "var(--og-color-status-waiting)";
1169
+ return /* @__PURE__ */ jsx7(
1170
+ "line",
1171
+ {
1172
+ x1: PAD.left,
1173
+ x2: w - PAD.right,
1174
+ y1: y,
1175
+ y2: y,
1176
+ stroke,
1177
+ strokeOpacity: 0.5,
1178
+ strokeWidth: 1,
1179
+ strokeDasharray: "3 4"
1180
+ },
1181
+ k
1182
+ );
1183
+ }),
1184
+ valued.length > 1 && [tMin, tMax].map((t, i) => /* @__PURE__ */ jsx7(
1185
+ "text",
1186
+ {
1187
+ x: i === 0 ? PAD.left : w - PAD.right,
1188
+ y: H - 4,
1189
+ textAnchor: i === 0 ? "start" : "end",
1190
+ className: "font-og-mono",
1191
+ fontSize: 10,
1192
+ fill: "var(--og-color-fg-subtle)",
1193
+ children: fmtClock(t)
1194
+ },
1195
+ i === 0 ? "x-start" : "x-end"
1196
+ )),
1197
+ area && /* @__PURE__ */ jsx7("path", { d: area, fill: `url(#${gid})` }),
1198
+ /* @__PURE__ */ jsx7(
1199
+ "path",
1200
+ {
1201
+ d: line,
1202
+ fill: "none",
1203
+ stroke: color,
1204
+ strokeWidth: 1.75,
1205
+ strokeLinejoin: "round",
1206
+ strokeLinecap: "round",
1207
+ pathLength: 1,
1208
+ className: "og-mh-draw"
1209
+ }
1210
+ ),
1211
+ sparse && pxPts.map((p) => /* @__PURE__ */ jsx7("circle", { cx: p.x, cy: p.y, r: 2.5, fill: color }, `m-${p.t}`)),
1212
+ hoverPt && /* @__PURE__ */ jsxs6("g", { pointerEvents: "none", children: [
1213
+ /* @__PURE__ */ jsx7(
1214
+ "line",
1215
+ {
1216
+ x1: hoverPt.x,
1217
+ x2: hoverPt.x,
1218
+ y1: PAD.top,
1219
+ y2: PAD.top + plotH,
1220
+ stroke: "var(--og-color-border-strong)",
1221
+ strokeWidth: 1
1222
+ }
1223
+ ),
1224
+ /* @__PURE__ */ jsx7(
1225
+ "circle",
1226
+ {
1227
+ cx: hoverPt.x,
1228
+ cy: hoverPt.y,
1229
+ r: 3.5,
1230
+ fill: color,
1231
+ stroke: "var(--og-color-bg)",
1232
+ strokeWidth: 1.5
1233
+ }
1234
+ )
1235
+ ] })
1236
+ ]
1237
+ }
1238
+ ),
1239
+ hoverPt && /* @__PURE__ */ jsxs6(
1240
+ "div",
1241
+ {
1242
+ className: "pointer-events-none absolute z-10 flex flex-col rounded-og-sm border border-og-border-strong bg-og-surface-3/95 px-2 py-1 shadow-og-md backdrop-blur-sm",
1243
+ style: {
1244
+ left: Math.min(Math.max(hoverPt.x - 30, 0), w - 78),
1245
+ top: Math.max(hoverPt.y - 42, 0)
1246
+ },
1247
+ children: [
1248
+ /* @__PURE__ */ jsx7("span", { className: "font-og-mono text-og-sm font-medium tabular-nums text-og-fg", children: fmt(hoverPt.v) }),
1249
+ /* @__PURE__ */ jsx7("span", { className: "font-og-mono text-[10px] tabular-nums text-og-fg-subtle", children: fmtClock(hoverPt.t) })
1250
+ ]
1251
+ }
1252
+ )
1253
+ ]
1254
+ }
1255
+ );
1256
+ }
1257
+
1258
+ // src/components/machines/machine-detail.tsx
1259
+ import {
1260
+ ArrowLeftIcon,
1261
+ BuildingIcon,
1262
+ ChevronRightIcon,
1263
+ CpuIcon as CpuIcon2,
1264
+ LayersIcon,
1265
+ LaptopIcon as LaptopIcon2,
1266
+ PlugIcon,
1267
+ RadioIcon,
1268
+ ServerIcon as ServerIcon2,
1269
+ TriangleAlertIcon as TriangleAlertIcon2,
1270
+ Trash2Icon,
1271
+ UserIcon,
1272
+ UsersIcon as UsersIcon2
1273
+ } from "lucide-react";
1274
+
1275
+ // src/components/machines/series.ts
1276
+ var METRIC_WINDOWS = ["15m", "1h", "6h", "24h"];
1277
+ var WINDOW_LABEL = (msg) => ({
1278
+ "15m": msg("machines.series.inTheLast15Min"),
1279
+ "1h": msg("machines.series.inTheLastHour"),
1280
+ "6h": msg("machines.series.inTheLast6Hours"),
1281
+ "24h": msg("machines.series.inTheLast24Hours")
1282
+ });
1283
+ function ptsFrom(samples, pick) {
1284
+ return samples.map((s) => ({ t: new Date(s.sampledAt).getTime(), v: pick(s) }));
1285
+ }
1286
+ var memPct = (s) => s.memTotalBytes > 0 ? s.memUsedBytes / s.memTotalBytes * 100 : null;
1287
+ var diskPct = (s) => s.diskTotalBytes > 0 ? s.diskUsedBytes / s.diskTotalBytes * 100 : null;
1288
+ var fmtBytes = (b) => {
1289
+ if (b < 1024) return `${b} B`;
1290
+ const u = ["KB", "MB", "GB", "TB"];
1291
+ let v = b / 1024;
1292
+ for (const unit of u) {
1293
+ if (v < 1024 || unit === "TB") return `${v.toFixed(v < 10 ? 1 : 0)} ${unit}`;
1294
+ v /= 1024;
1295
+ }
1296
+ return `${b} B`;
1297
+ };
1298
+ var METRICS = (msg) => [
1299
+ {
1300
+ key: "cpu",
1301
+ title: "CPU",
1302
+ unit: "%",
1303
+ yMax: 100,
1304
+ color: "var(--og-color-accent)",
1305
+ thresholds: { warn: 90, crit: 98 },
1306
+ pick: (s) => s.cpuPct,
1307
+ current: (s) => `${Math.round(s.cpuPct)}%`,
1308
+ sub: (s) => msg("machines.series.runqueueInRunQueue", { runQueue: s.runQueue })
1309
+ },
1310
+ {
1311
+ key: "mem",
1312
+ title: msg("machines.series.memory"),
1313
+ unit: "%",
1314
+ yMax: 100,
1315
+ color: "var(--og-color-status-idle)",
1316
+ thresholds: { warn: 85, crit: 95 },
1317
+ pick: memPct,
1318
+ current: (s) => `${Math.round(memPct(s) ?? 0)}%`,
1319
+ sub: (s) => `${fmtBytes(s.memUsedBytes)} / ${fmtBytes(s.memTotalBytes)}`
1320
+ },
1321
+ {
1322
+ key: "disk",
1323
+ title: msg("machines.series.disk"),
1324
+ unit: "%",
1325
+ yMax: 100,
1326
+ color: "var(--og-color-status-waiting)",
1327
+ thresholds: { warn: 90, crit: 96 },
1328
+ pick: diskPct,
1329
+ current: (s) => `${Math.round(diskPct(s) ?? 0)}%`,
1330
+ sub: (s) => `${fmtBytes(s.diskUsedBytes)} / ${fmtBytes(s.diskTotalBytes)}`
1331
+ },
1332
+ {
1333
+ key: "load",
1334
+ title: msg("machines.series.loadAverage"),
1335
+ unit: "",
1336
+ yMax: "auto",
1337
+ color: "var(--og-color-accent-strong)",
1338
+ pick: (s) => s.load1,
1339
+ current: (s) => s.load1.toFixed(2),
1340
+ sub: (s) => `5m ${s.load5.toFixed(2)} \xB7 15m ${s.load15.toFixed(2)}`
1341
+ },
1342
+ {
1343
+ key: "gpu",
1344
+ title: "GPU",
1345
+ unit: "%",
1346
+ yMax: 100,
1347
+ color: "var(--og-color-status-running)",
1348
+ thresholds: { warn: 90, crit: 98 },
1349
+ pick: (s) => s.gpuUtilPct,
1350
+ current: (s) => s.gpuUtilPct == null ? "\u2014" : `${Math.round(s.gpuUtilPct)}%`,
1351
+ sub: (s) => s.gpuMemBytes == null ? null : `${fmtBytes(s.gpuMemBytes)} used`
1352
+ }
1353
+ ];
1354
+ function pointsFor(def, samples) {
1355
+ return ptsFrom(samples, def.pick);
1356
+ }
1357
+
1358
+ // src/components/machines/machine-operation-policy.tsx
1359
+ import { AlertTriangleIcon as AlertTriangleIcon2, Loader2Icon } from "lucide-react";
1360
+ import { useEffect, useState as useState2 } from "react";
1361
+ import { errorMessage } from "@opengeni/contracts/values";
1362
+ import { jsx as jsx8, jsxs as jsxs7 } from "react/jsx-runtime";
1363
+ function fieldValue(value) {
1364
+ return value === null ? "" : String(value);
1365
+ }
1366
+ function parseByteCount(t, label, value) {
1367
+ const trimmed = value.trim();
1368
+ if (!trimmed) return null;
1369
+ if (!/^\d+$/.test(trimmed)) {
1370
+ throw new Error(t("machines.machineOperationPolicy.bytesNotWholeNumber", { label }));
1371
+ }
1372
+ const parsed = Number(trimmed);
1373
+ if (!Number.isSafeInteger(parsed) || parsed <= 0) {
1374
+ throw new Error(t("machines.machineOperationPolicy.bytesNotPositive", { label }));
1375
+ }
1376
+ return parsed;
1377
+ }
1378
+ function parseCpuMillicores(t, value) {
1379
+ const trimmed = value.trim();
1380
+ if (!trimmed) return null;
1381
+ if (!/^\d+$/.test(trimmed)) {
1382
+ throw new Error(t("machines.machineOperationPolicy.cpuNotWholeNumber"));
1383
+ }
1384
+ const parsed = Number(trimmed);
1385
+ if (!Number.isSafeInteger(parsed) || parsed <= 0 || parsed > 4294967295) {
1386
+ throw new Error(t("machines.machineOperationPolicy.cpuOutOfRange"));
1387
+ }
1388
+ return parsed;
1389
+ }
1390
+ function MachineOperationPolicyEditor({
1391
+ policy,
1392
+ memorySupported,
1393
+ cpuSupported,
1394
+ saving = false,
1395
+ onSave
1396
+ }) {
1397
+ const t = useOpenGeniText();
1398
+ const [memoryMaxBytes, setMemoryMaxBytes] = useState2(fieldValue(policy.memoryMaxBytes));
1399
+ const [memoryHighBytes, setMemoryHighBytes] = useState2(fieldValue(policy.memoryHighBytes));
1400
+ const [cpuMaxMillicores, setCpuMaxMillicores] = useState2(fieldValue(policy.cpuMaxMillicores));
1401
+ const [validationError, setValidationError] = useState2(null);
1402
+ useEffect(() => {
1403
+ setMemoryMaxBytes(fieldValue(policy.memoryMaxBytes));
1404
+ setMemoryHighBytes(fieldValue(policy.memoryHighBytes));
1405
+ setCpuMaxMillicores(fieldValue(policy.cpuMaxMillicores));
1406
+ setValidationError(null);
1407
+ }, [policy.memoryMaxBytes, policy.memoryHighBytes, policy.cpuMaxMillicores, policy.revision]);
1408
+ const submit = async (event) => {
1409
+ event.preventDefault();
1410
+ try {
1411
+ const max = parseByteCount(
1412
+ t,
1413
+ t("machines.machineOperationPolicy.hardCeiling"),
1414
+ memoryMaxBytes
1415
+ );
1416
+ const high = parseByteCount(
1417
+ t,
1418
+ t("machines.machineOperationPolicy.reclaimThreshold"),
1419
+ memoryHighBytes
1420
+ );
1421
+ if (max !== null && high !== null && high > max) {
1422
+ throw new Error(t("machines.machineOperationPolicy.reclaimAboveCeiling"));
1423
+ }
1424
+ const cpuMax = parseCpuMillicores(t, cpuMaxMillicores);
1425
+ setValidationError(null);
1426
+ await onSave({
1427
+ memoryMaxBytes: max,
1428
+ memoryHighBytes: high,
1429
+ cpuMaxMillicores: cpuMax,
1430
+ expectedRevision: policy.revision
1431
+ });
1432
+ } catch (error) {
1433
+ setValidationError(errorMessage(error));
1434
+ }
1435
+ };
1436
+ const configured = policy.memoryMaxBytes !== null || policy.memoryHighBytes !== null || policy.cpuMaxMillicores !== null;
1437
+ const memoryConfigured = policy.memoryMaxBytes !== null || policy.memoryHighBytes !== null;
1438
+ const unsupportedMemory = memoryConfigured && !memorySupported;
1439
+ const unsupportedCpu = policy.cpuMaxMillicores !== null && (!memorySupported || !cpuSupported);
1440
+ return /* @__PURE__ */ jsxs7(
1441
+ "section",
1442
+ {
1443
+ "data-machine-operation-policy": true,
1444
+ className: "rounded-og-lg border border-og-border bg-og-surface-1 p-4 shadow-og-sm",
1445
+ children: [
1446
+ /* @__PURE__ */ jsxs7("div", { className: "flex flex-col gap-1", children: [
1447
+ /* @__PURE__ */ jsx8("h2", { className: "text-og-sm font-semibold text-og-fg", children: t("machines.machineOperationPolicy.perCommandResourcePolicy") }),
1448
+ /* @__PURE__ */ jsx8("p", { className: "text-og-xs leading-relaxed text-og-fg-muted", children: t("machines.machineOperationPolicy.optionalLimitsAppliedSeparatelyTo") })
1449
+ ] }),
1450
+ configured && (unsupportedMemory || unsupportedCpu) ? /* @__PURE__ */ jsxs7("div", { className: "mt-3 flex gap-2 rounded-og-md border border-og-status-failed/40 bg-og-status-failed/5 p-3 text-og-xs text-og-status-failed", children: [
1451
+ /* @__PURE__ */ jsx8(AlertTriangleIcon2, { className: "mt-0.5 size-3.5 shrink-0", "aria-hidden": true }),
1452
+ /* @__PURE__ */ jsxs7("span", { children: [
1453
+ unsupportedCpu ? t("machines.machineOperationPolicy.thisRunnerCannotEnforceThe") : t("machines.machineOperationPolicy.thisRunnerCannotEnforceThe2"),
1454
+ " ",
1455
+ t("machines.machineOperationPolicy.commandExecutionFailsClosedUntil")
1456
+ ] })
1457
+ ] }) : null,
1458
+ /* @__PURE__ */ jsxs7("form", { className: "mt-4 grid gap-3 sm:grid-cols-2", onSubmit: submit, children: [
1459
+ /* @__PURE__ */ jsxs7("label", { className: "flex flex-col gap-1.5 text-og-xs text-og-fg-muted", children: [
1460
+ t("machines.machineOperationPolicy.hardCeilingBytes"),
1461
+ /* @__PURE__ */ jsx8(
1462
+ "input",
1463
+ {
1464
+ inputMode: "numeric",
1465
+ pattern: "[0-9]*",
1466
+ value: memoryMaxBytes,
1467
+ onChange: (event) => setMemoryMaxBytes(event.target.value),
1468
+ placeholder: t("machines.machineOperationPolicy.unlimited"),
1469
+ disabled: saving,
1470
+ className: "min-h-9 rounded-og-sm border border-og-border bg-og-bg px-2.5 font-og-mono text-og-sm text-og-fg outline-hidden focus-visible:ring-2 focus-visible:ring-og-accent/50 disabled:opacity-60"
1471
+ }
1472
+ )
1473
+ ] }),
1474
+ /* @__PURE__ */ jsxs7("label", { className: "flex flex-col gap-1.5 text-og-xs text-og-fg-muted", children: [
1475
+ t("machines.machineOperationPolicy.reclaimThresholdBytes"),
1476
+ /* @__PURE__ */ jsx8(
1477
+ "input",
1478
+ {
1479
+ inputMode: "numeric",
1480
+ pattern: "[0-9]*",
1481
+ value: memoryHighBytes,
1482
+ onChange: (event) => setMemoryHighBytes(event.target.value),
1483
+ placeholder: t("machines.machineOperationPolicy.unlimited"),
1484
+ disabled: saving,
1485
+ className: "min-h-9 rounded-og-sm border border-og-border bg-og-bg px-2.5 font-og-mono text-og-sm text-og-fg outline-hidden focus-visible:ring-2 focus-visible:ring-og-accent/50 disabled:opacity-60"
1486
+ }
1487
+ )
1488
+ ] }),
1489
+ /* @__PURE__ */ jsxs7("label", { className: "flex flex-col gap-1.5 text-og-xs text-og-fg-muted", children: [
1490
+ t("machines.machineOperationPolicy.cpuMaximumMillicores"),
1491
+ /* @__PURE__ */ jsx8(
1492
+ "input",
1493
+ {
1494
+ inputMode: "numeric",
1495
+ pattern: "[0-9]*",
1496
+ value: cpuMaxMillicores,
1497
+ onChange: (event) => setCpuMaxMillicores(event.target.value),
1498
+ placeholder: t("machines.machineOperationPolicy.unlimited"),
1499
+ disabled: saving,
1500
+ className: "min-h-9 rounded-og-sm border border-og-border bg-og-bg px-2.5 font-og-mono text-og-sm text-og-fg outline-hidden focus-visible:ring-2 focus-visible:ring-og-accent/50 disabled:opacity-60"
1501
+ }
1502
+ ),
1503
+ /* @__PURE__ */ jsx8("span", { children: t("machines.machineOperationPolicy.n1000MillicoresOneCpuCore") })
1504
+ ] }),
1505
+ /* @__PURE__ */ jsxs7("div", { className: "flex min-h-9 items-center justify-between gap-3 sm:col-span-2", children: [
1506
+ /* @__PURE__ */ jsx8(
1507
+ "span",
1508
+ {
1509
+ role: validationError ? "alert" : void 0,
1510
+ className: "text-og-xs text-og-status-failed",
1511
+ children: validationError
1512
+ }
1513
+ ),
1514
+ /* @__PURE__ */ jsxs7(
1515
+ "button",
1516
+ {
1517
+ type: "submit",
1518
+ disabled: saving,
1519
+ className: "inline-flex min-h-9 items-center gap-1.5 rounded-og-sm border border-og-primary-border bg-og-primary text-og-primary-fg px-3 py-1.5 text-og-xs font-medium transition-colors hover:bg-og-primary-hover disabled:cursor-not-allowed disabled:opacity-60",
1520
+ children: [
1521
+ saving ? /* @__PURE__ */ jsx8(Loader2Icon, { className: "size-3.5 animate-spin", "aria-hidden": true }) : null,
1522
+ t("machines.machineOperationPolicy.savePolicy")
1523
+ ]
1524
+ }
1525
+ )
1526
+ ] })
1527
+ ] })
1528
+ ]
1529
+ }
1530
+ );
1531
+ }
1532
+
1533
+ // src/components/machines/machine-detail.tsx
1534
+ import { Fragment as Fragment2, jsx as jsx9, jsxs as jsxs8 } from "react/jsx-runtime";
1535
+ var AUDIENCE = (t) => ({
1536
+ user: {
1537
+ label: t("machines.machineDetail.onlyMe"),
1538
+ description: t("machines.machineDetail.onlyItsOwnerCanRun"),
1539
+ Icon: UserIcon
1540
+ },
1541
+ workspace: {
1542
+ label: t("machines.machineDetail.thisWorkspace"),
1543
+ description: t("machines.machineDetail.everyoneInThisWorkspaceCan"),
1544
+ Icon: UsersIcon2
1545
+ },
1546
+ organization: {
1547
+ label: t("machines.machineDetail.wholeOrganization"),
1548
+ description: t("machines.machineDetail.membersCanUseItWhere"),
1549
+ Icon: BuildingIcon
1550
+ }
1551
+ });
1552
+ function MachineAudienceRow({
1553
+ machine,
1554
+ onChange
1555
+ }) {
1556
+ const t = useOpenGeniText();
1557
+ const audience = AUDIENCE(t)[machine.scope];
1558
+ const changeable = onChange !== void 0 && machine.scope !== "organization";
1559
+ const content = /* @__PURE__ */ jsxs8(Fragment2, { children: [
1560
+ /* @__PURE__ */ jsx9(audience.Icon, { className: "size-4 shrink-0 text-og-fg-subtle", "aria-hidden": true }),
1561
+ /* @__PURE__ */ jsxs8("span", { className: "flex min-w-0 flex-1 flex-col gap-0.5 text-left", children: [
1562
+ /* @__PURE__ */ jsx9("span", { className: "text-og-sm font-medium text-og-fg", children: t("machines.machineDetail.whoCanUseIt") }),
1563
+ /* @__PURE__ */ jsx9("span", { className: "text-og-xs text-og-fg-muted", children: audience.description })
1564
+ ] }),
1565
+ /* @__PURE__ */ jsx9("span", { className: "shrink-0 text-og-sm text-og-fg-muted", children: audience.label }),
1566
+ changeable ? /* @__PURE__ */ jsx9(ChevronRightIcon, { className: "size-4 shrink-0 text-og-fg-subtle", "aria-hidden": true }) : null
1567
+ ] });
1568
+ const frame = "flex w-full min-h-14 items-center gap-3 rounded-og-lg border border-og-border bg-og-surface-1 px-4 py-3 shadow-og-sm";
1569
+ return changeable ? /* @__PURE__ */ jsx9(
1570
+ "button",
1571
+ {
1572
+ type: "button",
1573
+ "data-machine-audience": machine.scope,
1574
+ onClick: () => onChange(machine),
1575
+ "aria-label": t("machines.machineDetail.whoCanUseNameLabel", {
1576
+ name: machine.name,
1577
+ label: audience.label
1578
+ }),
1579
+ className: cn(
1580
+ frame,
1581
+ "transition-colors hover:bg-og-surface-2 focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-og-accent/50"
1582
+ ),
1583
+ children: content
1584
+ }
1585
+ ) : /* @__PURE__ */ jsx9("div", { "data-machine-audience": machine.scope, className: frame, children: content });
1586
+ }
1587
+ function MachineReachRow({
1588
+ machine,
1589
+ summary,
1590
+ onChange
1591
+ }) {
1592
+ const t = useOpenGeniText();
1593
+ const content = /* @__PURE__ */ jsxs8(Fragment2, { children: [
1594
+ /* @__PURE__ */ jsx9(LayersIcon, { className: "size-4 shrink-0 text-og-fg-subtle", "aria-hidden": true }),
1595
+ /* @__PURE__ */ jsxs8("span", { className: "flex min-w-0 flex-1 flex-col gap-0.5 text-left", children: [
1596
+ /* @__PURE__ */ jsx9("span", { className: "text-og-sm font-medium text-og-fg", children: t("machines.machineDetail.availableIn") }),
1597
+ /* @__PURE__ */ jsx9("span", { className: "text-og-xs text-og-fg-muted", children: t("machines.machineDetail.organizationOwnersChooseWhere") })
1598
+ ] }),
1599
+ /* @__PURE__ */ jsx9("span", { className: "shrink-0 text-og-sm text-og-fg-muted", children: summary }),
1600
+ onChange ? /* @__PURE__ */ jsx9(ChevronRightIcon, { className: "size-4 shrink-0 text-og-fg-subtle", "aria-hidden": true }) : null
1601
+ ] });
1602
+ const frame = "flex w-full min-h-14 items-center gap-3 rounded-og-lg border border-og-border bg-og-surface-1 px-4 py-3 shadow-og-sm";
1603
+ return onChange ? /* @__PURE__ */ jsx9(
1604
+ "button",
1605
+ {
1606
+ type: "button",
1607
+ "data-machine-reach": true,
1608
+ onClick: () => onChange(machine),
1609
+ "aria-label": t("machines.machineDetail.availableInNameLabel", {
1610
+ name: machine.name,
1611
+ summary
1612
+ }),
1613
+ className: cn(
1614
+ frame,
1615
+ "transition-colors hover:bg-og-surface-2 focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-og-accent/50"
1616
+ ),
1617
+ children: content
1618
+ }
1619
+ ) : /* @__PURE__ */ jsx9("div", { "data-machine-reach": true, className: frame, children: content });
1620
+ }
1621
+ function KindIcon2({ kind, session }) {
1622
+ if (kind === "local" || kind === "selfhosted")
1623
+ return /* @__PURE__ */ jsx9(LaptopIcon2, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
1624
+ if (kind === "docker" || session)
1625
+ return /* @__PURE__ */ jsx9(ServerIcon2, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
1626
+ if (kind === "modal") return /* @__PURE__ */ jsx9(CpuIcon2, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
1627
+ return /* @__PURE__ */ jsx9(ServerIcon2, { className: "size-4 text-og-fg-subtle", "aria-hidden": true });
1628
+ }
1629
+ function MachineAgentPanel({
1630
+ machine,
1631
+ now,
1632
+ onUpdateAgent,
1633
+ updatingAgent
1634
+ }) {
1635
+ const t = useOpenGeniText();
1636
+ const authority = machine.connectionAuthority;
1637
+ const runtime = machine.runtime;
1638
+ if (!runtime && authority.state === "not_applicable") return null;
1639
+ const agent = runtime ? describeAgentRuntime(t, runtime, now, connectionStatusForState(machine.state) === "online") : null;
1640
+ const action = agent?.action && machine.enrollmentId && onUpdateAgent && machine.state !== "offline" ? agent.action : null;
1641
+ const connection = authority.state === "not_applicable" ? null : describeAgentConnection(t, authority);
1642
+ const conflict = runnerConflict(authority, now);
1643
+ const conflictAgo = conflict?.lastAt ? formatRelativeTime(t, conflict.lastAt, new Date(now)) : null;
1644
+ return /* @__PURE__ */ jsxs8(
1645
+ "section",
1646
+ {
1647
+ "data-machine-agent": true,
1648
+ "aria-label": t("machines.machineDetail.agent"),
1649
+ className: "flex flex-col divide-y divide-og-border rounded-og-lg border border-og-border bg-og-surface-1 shadow-og-sm",
1650
+ children: [
1651
+ agent ? /* @__PURE__ */ jsxs8("div", { "data-agent-runtime": true, className: "flex min-h-14 items-center gap-3 px-4 py-3", children: [
1652
+ /* @__PURE__ */ jsx9(AgentStatusIcon, { tone: agent.tone, className: "size-4" }),
1653
+ /* @__PURE__ */ jsxs8("div", { className: "flex min-w-0 flex-1 flex-col gap-0.5", children: [
1654
+ /* @__PURE__ */ jsx9("span", { className: "text-og-sm font-medium text-og-fg", children: agent.title }),
1655
+ /* @__PURE__ */ jsx9(
1656
+ "span",
1657
+ {
1658
+ "data-agent-status": agent.tone,
1659
+ className: cn("text-og-xs", STATUS_TONE_TEXT[agent.tone]),
1660
+ children: agent.status
1661
+ }
1662
+ ),
1663
+ agent.note ? /* @__PURE__ */ jsx9("span", { className: "text-og-xs text-og-fg-muted", children: agent.note }) : null
1664
+ ] }),
1665
+ action ? /* @__PURE__ */ jsx9(
1666
+ "button",
1667
+ {
1668
+ type: "button",
1669
+ "data-update-agent": true,
1670
+ "data-update-action": action.kind,
1671
+ disabled: updatingAgent,
1672
+ onClick: () => onUpdateAgent?.(machine),
1673
+ className: "inline-flex min-h-9 shrink-0 items-center rounded-og-sm border border-og-border px-3 py-1 text-og-xs font-medium text-og-fg-muted transition-colors hover:border-og-border-strong hover:text-og-fg focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-og-accent/50 disabled:cursor-not-allowed disabled:opacity-50 pointer-coarse:min-h-11",
1674
+ children: updatingAgent ? t("machines.machineDetail.starting") : action.label
1675
+ }
1676
+ ) : null
1677
+ ] }) : null,
1678
+ connection ? /* @__PURE__ */ jsxs8(
1679
+ "div",
1680
+ {
1681
+ "data-connection-authority": authority.state,
1682
+ className: "flex min-h-14 items-start gap-3 px-4 py-3",
1683
+ children: [
1684
+ /* @__PURE__ */ jsx9(PlugIcon, { className: "mt-0.5 size-4 shrink-0 text-og-fg-subtle", "aria-hidden": true }),
1685
+ /* @__PURE__ */ jsxs8("div", { className: "flex min-w-0 flex-1 flex-col gap-0.5", children: [
1686
+ /* @__PURE__ */ jsx9("span", { className: "text-og-sm font-medium text-og-fg", children: connection.label }),
1687
+ connection.detail ? /* @__PURE__ */ jsx9("span", { className: "text-og-xs text-og-fg-muted", children: connection.detail }) : null,
1688
+ conflict?.active ? /* @__PURE__ */ jsxs8(
1689
+ "span",
1690
+ {
1691
+ "data-runner-conflict": "active",
1692
+ className: "mt-1 flex items-start gap-1.5 text-og-xs text-og-fg-muted",
1693
+ children: [
1694
+ /* @__PURE__ */ jsx9(
1695
+ TriangleAlertIcon2,
1696
+ {
1697
+ className: "mt-px size-3.5 shrink-0 text-og-status-waiting",
1698
+ "aria-hidden": true
1699
+ }
1700
+ ),
1701
+ t("machines.machineDetail.aSecondCopyOfThe")
1702
+ ]
1703
+ }
1704
+ ) : conflict ? /* @__PURE__ */ jsxs8("span", { "data-runner-conflict": "past", className: "text-og-xs text-og-fg-subtle", children: [
1705
+ t("machines.machineDetail.keptOutExtraCopiesOf", { count: conflict.count }),
1706
+ conflictAgo ? t("machines.machineDetail.mostRecentlyValue", {
1707
+ value: conflictAgo === "now" ? t("machines.machineDetail.justNow") : `${conflictAgo} ago`
1708
+ }) : ""
1709
+ ] }) : null
1710
+ ] })
1711
+ ]
1712
+ }
1713
+ ) : null
1714
+ ]
1715
+ }
1716
+ );
1717
+ }
1718
+ function MachineDetail({
1719
+ machine,
1720
+ series,
1721
+ window,
1722
+ onWindowChange,
1723
+ loadingSeries,
1724
+ onBack,
1725
+ onRemove,
1726
+ onUpdateOperationPolicy,
1727
+ updatingOperationPolicy,
1728
+ onChangeAudience,
1729
+ reachSummary,
1730
+ onChangeReach,
1731
+ whereItWorks,
1732
+ onUpdateAgent,
1733
+ updatingAgent,
1734
+ now = Date.now(),
1735
+ className
1736
+ }) {
1737
+ const t = useOpenGeniText();
1738
+ const health = deriveHealth(t, machine.state, machine.metrics, now);
1739
+ const tone = HEALTH_TOKEN[health.level];
1740
+ const latest = machine.metrics;
1741
+ const sampledAgo = latest ? formatRelativeTime(t, latest.sampledAt, new Date(now)) : null;
1742
+ const visible = METRICS(t).filter((m) => !(m.key === "gpu" && latest?.gpuUtilPct == null));
1743
+ const tileCols = visible.length >= 5 ? "grid-cols-2 sm:grid-cols-3 lg:grid-cols-5" : "grid-cols-2 sm:grid-cols-4";
1744
+ return /* @__PURE__ */ jsxs8("div", { className: cn("og-root mx-auto flex w-full max-w-5xl flex-col gap-5", className), children: [
1745
+ /* @__PURE__ */ jsxs8("div", { className: "flex items-center justify-between gap-3", children: [
1746
+ /* @__PURE__ */ jsxs8("div", { className: "flex min-w-0 items-center gap-2.5", children: [
1747
+ onBack && /* @__PURE__ */ jsx9(
1748
+ "button",
1749
+ {
1750
+ type: "button",
1751
+ onClick: onBack,
1752
+ className: "flex size-7 shrink-0 items-center justify-center rounded-og-sm border border-og-border bg-og-surface-1 text-og-fg-muted transition-colors hover:bg-og-surface-2 hover:text-og-fg",
1753
+ "aria-label": t("machines.machineDetail.backToMachines"),
1754
+ children: /* @__PURE__ */ jsx9(ArrowLeftIcon, { className: "size-3.5", "aria-hidden": true })
1755
+ }
1756
+ ),
1757
+ /* @__PURE__ */ jsx9(KindIcon2, { kind: machine.kind, session: machine.isSessionGroup }),
1758
+ /* @__PURE__ */ jsx9("h1", { className: "truncate text-og-md font-semibold text-og-fg", children: machine.name }),
1759
+ /* @__PURE__ */ jsxs8("span", { className: "hidden shrink-0 rounded-og-sm border border-og-border bg-og-surface-1 px-1.5 py-0.5 font-og-mono text-og-xs text-og-fg-subtle sm:inline", children: [
1760
+ machine.os,
1761
+ " \xB7 ",
1762
+ machine.arch
1763
+ ] })
1764
+ ] }),
1765
+ /* @__PURE__ */ jsxs8("div", { className: "flex shrink-0 items-center gap-2", children: [
1766
+ onRemove && machine.enrollmentId && !machine.isSessionGroup ? /* @__PURE__ */ jsxs8(
1767
+ "button",
1768
+ {
1769
+ type: "button",
1770
+ "data-remove-machine": true,
1771
+ "aria-label": t("machines.machineDetail.removeMachineName", { name: machine.name }),
1772
+ onClick: () => onRemove(machine),
1773
+ className: "inline-flex min-h-9 items-center gap-1.5 rounded-og-sm border border-og-status-failed/40 px-2.5 py-1 font-medium text-og-xs text-og-status-failed transition-colors hover:bg-og-status-failed/10 focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-og-status-failed/50 pointer-coarse:min-h-11",
1774
+ children: [
1775
+ /* @__PURE__ */ jsx9(Trash2Icon, { className: "size-3.5", "aria-hidden": true }),
1776
+ /* @__PURE__ */ jsx9("span", { className: "hidden sm:inline", children: t("machines.machineDetail.removeMachine") })
1777
+ ]
1778
+ }
1779
+ ) : null,
1780
+ /* @__PURE__ */ jsx9("div", { className: "flex items-center gap-0.5 rounded-og-md border border-og-border bg-og-surface-1 p-0.5", children: METRIC_WINDOWS.map((w) => /* @__PURE__ */ jsx9(
1781
+ "button",
1782
+ {
1783
+ type: "button",
1784
+ onClick: () => onWindowChange(w),
1785
+ "data-active": w === window,
1786
+ className: cn(
1787
+ "rounded-og-sm px-2 py-1 font-og-mono text-og-xs transition-colors",
1788
+ w === window ? "bg-og-surface-3 text-og-fg shadow-og-sm" : "text-og-fg-subtle hover:text-og-fg-muted"
1789
+ ),
1790
+ children: w
1791
+ },
1792
+ w
1793
+ )) })
1794
+ ] })
1795
+ ] }),
1796
+ /* @__PURE__ */ jsxs8(
1797
+ "div",
1798
+ {
1799
+ className: cn(
1800
+ "relative flex flex-col gap-4 overflow-hidden rounded-og-lg border p-5 shadow-og-sm",
1801
+ tone.soft
1802
+ ),
1803
+ children: [
1804
+ /* @__PURE__ */ jsx9("span", { "aria-hidden": true, className: cn("absolute inset-y-0 left-0 w-1", tone.dot) }),
1805
+ /* @__PURE__ */ jsxs8("div", { className: "flex flex-wrap items-center justify-between gap-3 pl-1", children: [
1806
+ /* @__PURE__ */ jsxs8("div", { className: "flex items-center gap-3", children: [
1807
+ /* @__PURE__ */ jsxs8("span", { className: "relative flex size-3", children: [
1808
+ healthPulses(health.level) && /* @__PURE__ */ jsx9(
1809
+ "span",
1810
+ {
1811
+ className: cn(
1812
+ "absolute inline-flex size-full animate-og-pulse rounded-full opacity-60",
1813
+ tone.dot
1814
+ )
1815
+ }
1816
+ ),
1817
+ /* @__PURE__ */ jsx9("span", { className: cn("relative inline-flex size-3 rounded-full", tone.dot) })
1818
+ ] }),
1819
+ /* @__PURE__ */ jsxs8("div", { className: "flex flex-col", children: [
1820
+ /* @__PURE__ */ jsx9("span", { className: cn("text-og-md font-semibold", tone.text), children: health.label }),
1821
+ /* @__PURE__ */ jsx9("span", { className: "text-og-sm text-og-fg-muted", children: health.reason })
1822
+ ] })
1823
+ ] }),
1824
+ /* @__PURE__ */ jsxs8("div", { className: "flex items-start gap-5 pr-1", children: [
1825
+ sampledAgo && /* @__PURE__ */ jsxs8("div", { className: "flex flex-col items-end gap-0.5", children: [
1826
+ /* @__PURE__ */ jsx9("span", { className: "text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: t("machines.machineDetail.sampled") }),
1827
+ /* @__PURE__ */ jsxs8("span", { className: "flex items-center gap-1 font-og-mono text-og-sm tabular-nums text-og-fg", children: [
1828
+ /* @__PURE__ */ jsx9(
1829
+ RadioIcon,
1830
+ {
1831
+ className: cn("size-3", health.stale ? "text-og-fg-subtle" : tone.text),
1832
+ "aria-hidden": true
1833
+ }
1834
+ ),
1835
+ sampledAgo === "now" ? t("machines.machineDetail.live") : t("machines.machineDetail.sampledagoAgo", { sampledAgo })
1836
+ ] })
1837
+ ] }),
1838
+ machine.lastSeenAt && /* @__PURE__ */ jsxs8("div", { className: "hidden flex-col items-end gap-0.5 sm:flex", children: [
1839
+ /* @__PURE__ */ jsx9("span", { className: "text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: t("machines.machineDetail.lastSeen") }),
1840
+ /* @__PURE__ */ jsx9("span", { className: "font-og-mono text-og-sm tabular-nums text-og-fg-muted", children: formatRelativeTime(t, machine.lastSeenAt, new Date(now)) })
1841
+ ] })
1842
+ ] })
1843
+ ] }),
1844
+ latest && /* @__PURE__ */ jsx9(
1845
+ "div",
1846
+ {
1847
+ className: cn(
1848
+ "grid gap-px overflow-hidden rounded-og-md border border-og-border bg-og-border",
1849
+ tileCols
1850
+ ),
1851
+ children: visible.map((m) => {
1852
+ const pts = pointsFor(m, series);
1853
+ return /* @__PURE__ */ jsxs8("div", { className: "flex flex-col gap-1.5 bg-og-surface-1 p-3", children: [
1854
+ /* @__PURE__ */ jsx9("span", { className: "text-[10px] font-medium uppercase tracking-wide text-og-fg-subtle", children: m.title }),
1855
+ /* @__PURE__ */ jsx9("span", { className: "font-og-mono text-og-md font-medium tabular-nums text-og-fg", children: m.current(latest) }),
1856
+ /* @__PURE__ */ jsx9(MetricSparkline, { points: pts, color: m.color, yMax: m.yMax, height: 22 }),
1857
+ m.sub && /* @__PURE__ */ jsx9("span", { className: "truncate font-og-mono text-[10px] text-og-fg-subtle", children: m.sub(latest) })
1858
+ ] }, m.key);
1859
+ })
1860
+ }
1861
+ )
1862
+ ]
1863
+ }
1864
+ ),
1865
+ /* @__PURE__ */ jsx9(
1866
+ MachineAgentPanel,
1867
+ {
1868
+ machine,
1869
+ now,
1870
+ onUpdateAgent,
1871
+ updatingAgent
1872
+ }
1873
+ ),
1874
+ machine.enrollmentId && !machine.isSessionGroup ? /* @__PURE__ */ jsx9(MachineAudienceRow, { machine, onChange: onChangeAudience }) : null,
1875
+ machine.scope === "organization" && machine.enrollmentId && reachSummary ? /* @__PURE__ */ jsx9(MachineReachRow, { machine, summary: reachSummary, onChange: onChangeReach }) : null,
1876
+ whereItWorks,
1877
+ onUpdateOperationPolicy && machine.enrollmentId && machine.operationPolicy ? /* @__PURE__ */ jsx9(
1878
+ MachineOperationPolicyEditor,
1879
+ {
1880
+ policy: machine.operationPolicy,
1881
+ memorySupported: machine.runtime?.capabilities.operationResourcePolicy === true,
1882
+ cpuSupported: machine.runtime?.capabilities.operationCpuQuota === true,
1883
+ saving: updatingOperationPolicy,
1884
+ onSave: (request) => onUpdateOperationPolicy(machine, request)
1885
+ }
1886
+ ) : null,
1887
+ /* @__PURE__ */ jsx9("div", { className: "grid grid-cols-1 gap-3 lg:grid-cols-2", children: visible.map((m) => {
1888
+ const pts = pointsFor(m, series);
1889
+ return /* @__PURE__ */ jsxs8(
1890
+ "div",
1891
+ {
1892
+ className: "flex flex-col gap-3 rounded-og-lg border border-og-border bg-og-surface-1 p-4 shadow-og-sm",
1893
+ children: [
1894
+ /* @__PURE__ */ jsxs8("div", { className: "flex items-baseline justify-between", children: [
1895
+ /* @__PURE__ */ jsx9("span", { className: "text-og-sm font-medium text-og-fg", children: m.title }),
1896
+ latest && /* @__PURE__ */ jsx9("span", { className: "font-og-mono text-og-sm tabular-nums text-og-fg-muted", children: m.current(latest) })
1897
+ ] }),
1898
+ /* @__PURE__ */ jsx9(
1899
+ MetricHistoryChart,
1900
+ {
1901
+ points: pts,
1902
+ yMax: m.yMax,
1903
+ unit: m.unit,
1904
+ color: m.color,
1905
+ thresholds: m.thresholds,
1906
+ rangeLabel: WINDOW_LABEL(t)[window],
1907
+ height: 128,
1908
+ className: cn(loadingSeries && "opacity-50 transition-opacity")
1909
+ }
1910
+ )
1911
+ ]
1912
+ },
1913
+ m.key
1914
+ );
1915
+ }) })
1916
+ ] });
1917
+ }
1918
+
1919
+ // src/components/machines-dashboard.tsx
1920
+ import { LaptopIcon as LaptopIcon3, PlusIcon, RefreshCwIcon } from "lucide-react";
1921
+ import { jsx as jsx10, jsxs as jsxs9 } from "react/jsx-runtime";
1922
+ function EmptyState({ onEnroll }) {
1923
+ const t = useOpenGeniText();
1924
+ return /* @__PURE__ */ jsxs9(
1925
+ "div",
1926
+ {
1927
+ "data-machines-empty": true,
1928
+ className: "flex flex-col items-center justify-center gap-3 rounded-og-lg border border-dashed border-og-border bg-og-surface-1 px-6 py-12 text-center",
1929
+ children: [
1930
+ /* @__PURE__ */ jsx10("span", { className: "flex size-10 items-center justify-center rounded-full bg-og-surface-2 text-og-fg-subtle", children: /* @__PURE__ */ jsx10(LaptopIcon3, { className: "size-5", "aria-hidden": true }) }),
1931
+ /* @__PURE__ */ jsxs9("div", { className: "space-y-1", children: [
1932
+ /* @__PURE__ */ jsx10("p", { className: "text-og-base font-medium text-og-fg", children: t("machinesDashboard.noMachinesYet") }),
1933
+ /* @__PURE__ */ jsx10("p", { className: "max-w-xs text-og-sm text-og-fg-muted", children: t("machinesDashboard.connectYourOwnComputerTo") })
1934
+ ] }),
1935
+ onEnroll ? /* @__PURE__ */ jsxs9(
1936
+ "button",
1937
+ {
1938
+ type: "button",
1939
+ "data-enroll-cta": true,
1940
+ onClick: onEnroll,
1941
+ className: "inline-flex items-center gap-1.5 rounded-og-sm border border-og-primary-border bg-og-primary text-og-primary-fg px-3 py-1.5 text-og-sm font-medium transition-colors hover:bg-og-primary-hover pointer-coarse:min-h-11",
1942
+ children: [
1943
+ /* @__PURE__ */ jsx10(PlusIcon, { className: "size-3.5", "aria-hidden": true }),
1944
+ t("machinesDashboard.connectAMachine")
1945
+ ]
1946
+ }
1947
+ ) : null
1948
+ ]
1949
+ }
1950
+ );
1951
+ }
1952
+ function Header({
1953
+ count,
1954
+ onEnroll
1955
+ }) {
1956
+ const t = useOpenGeniText();
1957
+ return /* @__PURE__ */ jsxs9("div", { className: "flex items-center justify-between gap-3", children: [
1958
+ /* @__PURE__ */ jsxs9("div", { className: "flex items-baseline gap-2", children: [
1959
+ /* @__PURE__ */ jsx10("h2", { className: "text-og-base font-semibold text-og-fg", children: t("machinesDashboard.machines") }),
1960
+ /* @__PURE__ */ jsx10("span", { className: "font-og-mono text-og-xs text-og-fg-subtle", children: count })
1961
+ ] }),
1962
+ /* @__PURE__ */ jsx10("div", { className: "flex items-center gap-1.5", children: onEnroll ? /* @__PURE__ */ jsxs9(
1963
+ "button",
1964
+ {
1965
+ type: "button",
1966
+ "data-enroll-cta": true,
1967
+ onClick: onEnroll,
1968
+ className: "inline-flex items-center gap-1.5 rounded-og-sm border border-og-border px-2.5 py-1 text-og-sm font-medium text-og-fg-muted transition-colors hover:border-og-border-strong hover:text-og-fg pointer-coarse:min-h-11",
1969
+ children: [
1970
+ /* @__PURE__ */ jsx10(PlusIcon, { className: "size-3.5", "aria-hidden": true }),
1971
+ t("machinesDashboard.connectAMachine")
1972
+ ]
1973
+ }
1974
+ ) : null })
1975
+ ] });
1976
+ }
1977
+ function MachinesDashboard({
1978
+ machines,
1979
+ activeSandboxId,
1980
+ loading,
1981
+ error,
1982
+ onAttach,
1983
+ attachingSandboxId,
1984
+ onUpdateAgent,
1985
+ canUpdateMachine,
1986
+ updatingEnrollmentId,
1987
+ seriesByMachine,
1988
+ onOpenDetail,
1989
+ now,
1990
+ onEnroll,
1991
+ onRefresh,
1992
+ className
1993
+ }) {
1994
+ const t = useOpenGeniText();
1995
+ const isEmpty = !loading && !error && machines.length === 0;
1996
+ return /* @__PURE__ */ jsxs9("section", { "data-machines-dashboard": true, className: cn("og-root flex flex-col gap-3", className), children: [
1997
+ /* @__PURE__ */ jsx10(Header, { count: machines.length, onEnroll }),
1998
+ error ? /* @__PURE__ */ jsxs9(
1999
+ "div",
2000
+ {
2001
+ "data-machines-error": true,
2002
+ className: "flex flex-wrap items-center justify-between gap-2 rounded-og-md border border-og-status-failed/30 bg-og-status-failed/10 px-3 py-2 text-og-sm text-og-status-failed",
2003
+ children: [
2004
+ /* @__PURE__ */ jsx10("span", { children: t("machinesDashboard.couldNotLoadMachinesMessage", { message: error.message }) }),
2005
+ onRefresh ? /* @__PURE__ */ jsxs9(
2006
+ "button",
2007
+ {
2008
+ type: "button",
2009
+ "data-machines-retry": true,
2010
+ onClick: onRefresh,
2011
+ disabled: loading,
2012
+ className: "inline-flex items-center gap-1.5 rounded-og-sm border border-og-status-failed/30 px-2 py-1 text-og-xs font-medium transition-colors hover:border-og-status-failed/50 disabled:cursor-not-allowed disabled:opacity-60 pointer-coarse:min-h-11",
2013
+ children: [
2014
+ /* @__PURE__ */ jsx10(RefreshCwIcon, { className: cn("size-3.5", loading && "animate-og-spin"), "aria-hidden": true }),
2015
+ loading ? t("machinesDashboard.retrying") : t("machinesDashboard.retry")
2016
+ ]
2017
+ }
2018
+ ) : null
2019
+ ]
2020
+ }
2021
+ ) : null,
2022
+ loading && machines.length === 0 ? /* @__PURE__ */ jsx10("div", { "data-machines-loading": true, className: "grid gap-3 sm:grid-cols-2", children: [0, 1].map((i) => /* @__PURE__ */ jsx10(
2023
+ "div",
2024
+ {
2025
+ className: "h-36 animate-og-pulse rounded-og-lg border border-og-border bg-og-surface-1"
2026
+ },
2027
+ i
2028
+ )) }) : isEmpty ? /* @__PURE__ */ jsx10(EmptyState, { onEnroll }) : /* @__PURE__ */ jsx10("div", { className: "grid gap-3 sm:grid-cols-2 xl:grid-cols-3", "data-machines-grid": true, children: machines.map((machine) => /* @__PURE__ */ jsx10(
2029
+ MachineCard,
2030
+ {
2031
+ machine: {
2032
+ ...machine,
2033
+ active: machine.active || machine.sandboxId === activeSandboxId
2034
+ },
2035
+ onAttach,
2036
+ attaching: attachingSandboxId === machine.sandboxId,
2037
+ onUpdateAgent: canUpdateMachine && !canUpdateMachine(machine) ? void 0 : onUpdateAgent,
2038
+ updatingAgent: updatingEnrollmentId === machine.enrollmentId,
2039
+ series: seriesByMachine?.[machine.sandboxId],
2040
+ onOpenDetail,
2041
+ now
2042
+ },
2043
+ machine.sandboxId
2044
+ )) })
2045
+ ] });
2046
+ }
2047
+
2048
+ // src/components/machine-dock-bar.tsx
2049
+ import { LaptopIcon as LaptopIcon4, CpuIcon as CpuIcon3, UsersIcon as UsersIcon3 } from "lucide-react";
2050
+ import { jsx as jsx11, jsxs as jsxs10 } from "react/jsx-runtime";
2051
+ function MachineDockBar({ name, kind, state, className }) {
2052
+ const t = useOpenGeniText();
2053
+ const Icon = kind === "selfhosted" || kind === "local" ? LaptopIcon4 : CpuIcon3;
2054
+ const stateBadge = MACHINE_STATE_BADGE_META(t)[state];
2055
+ return /* @__PURE__ */ jsxs10(
2056
+ "div",
2057
+ {
2058
+ "data-machine-dock-bar": true,
2059
+ className: cn(
2060
+ "flex shrink-0 items-center justify-between gap-2 border-b border-og-border bg-og-surface-1 px-2.5 py-1",
2061
+ className
2062
+ ),
2063
+ children: [
2064
+ /* @__PURE__ */ jsxs10("div", { className: "flex min-w-0 items-center gap-1.5", children: [
2065
+ /* @__PURE__ */ jsx11(Icon, { className: "size-3.5 shrink-0 text-og-fg-subtle", "aria-hidden": true }),
2066
+ /* @__PURE__ */ jsx11("span", { className: "truncate text-[11px] font-medium text-og-fg", children: name }),
2067
+ stateBadge ? /* @__PURE__ */ jsx11(
2068
+ "span",
2069
+ {
2070
+ "data-state-badge": state,
2071
+ className: cn(
2072
+ "shrink-0 rounded-full border px-1.5 py-px text-[10px] font-medium",
2073
+ stateBadge.badgeClassName
2074
+ ),
2075
+ children: stateBadge.label
2076
+ }
2077
+ ) : null
2078
+ ] }),
2079
+ /* @__PURE__ */ jsx11(
2080
+ ConnectionStatusPill,
2081
+ {
2082
+ status: connectionStatusForState(state),
2083
+ size: "sm",
2084
+ className: "shrink-0"
2085
+ }
2086
+ )
2087
+ ]
2088
+ }
2089
+ );
2090
+ }
2091
+ function SharedMachineDisclosure({
2092
+ sharedSessionCount,
2093
+ density = "compact",
2094
+ className
2095
+ }) {
2096
+ const t = useOpenGeniText();
2097
+ const others = Math.max(0, sharedSessionCount - 1);
2098
+ return /* @__PURE__ */ jsxs10(
2099
+ "div",
2100
+ {
2101
+ "data-shared-disclosure": true,
2102
+ className: cn(
2103
+ "flex items-center gap-1.5 border-og-accent/25 bg-og-accent-soft text-og-fg-muted",
2104
+ density === "full" ? "rounded-og-md border px-3 py-2 text-[12px]" : "border-b px-2.5 py-1 text-[11px]",
2105
+ className
2106
+ ),
2107
+ children: [
2108
+ /* @__PURE__ */ jsx11(UsersIcon3, { className: "size-3.5 shrink-0 text-og-accent", "aria-hidden": true }),
2109
+ /* @__PURE__ */ jsxs10("span", { children: [
2110
+ t("machineDockBar.shared"),
2111
+ " ",
2112
+ others === 1 ? t("machineDockBar.anotherSessionIs") : t("machineDockBar.othersOtherSessionsAre", { others }),
2113
+ " ",
2114
+ t("machineDockBar.onThisMachineTheySee")
2115
+ ] })
2116
+ ]
2117
+ }
2118
+ );
2119
+ }
2120
+
2121
+ // src/components/enrollment-device-flow.tsx
2122
+ import { CopyIcon, ExternalLinkIcon, LaptopIcon as LaptopIcon5, TerminalIcon } from "lucide-react";
2123
+ import { Fragment as Fragment3, jsx as jsx12, jsxs as jsxs11 } from "react/jsx-runtime";
2124
+ var PHASE_TO_STATE = {
2125
+ pending: "enrolling",
2126
+ authorized: "online",
2127
+ denied: "offline",
2128
+ expired: "offline",
2129
+ disabled: "offline"
2130
+ };
2131
+ function PhaseLabel({ phase }) {
2132
+ const t = useOpenGeniText();
2133
+ const text = {
2134
+ pending: t("enrollmentDeviceFlow.waitingForApproval"),
2135
+ authorized: t("enrollmentDeviceFlow.connected"),
2136
+ denied: t("enrollmentDeviceFlow.denied"),
2137
+ expired: t("enrollmentDeviceFlow.codeExpired"),
2138
+ disabled: t("enrollmentDeviceFlow.enrollmentDisabled")
2139
+ };
2140
+ return /* @__PURE__ */ jsx12("span", { children: text[phase] });
2141
+ }
2142
+ function EnrollmentDeviceFlow({
2143
+ userCode,
2144
+ verificationUri,
2145
+ verificationUriComplete,
2146
+ installCommand,
2147
+ phase = "pending",
2148
+ expiresInSeconds,
2149
+ onCopyCode,
2150
+ onCopyInstall,
2151
+ onOpenVerification,
2152
+ className
2153
+ }) {
2154
+ const t = useOpenGeniText();
2155
+ const href = verificationUriComplete ?? verificationUri;
2156
+ const codeIsPlaceholder = !/[A-Za-z0-9]/.test(userCode);
2157
+ const awaitingCode = phase === "pending" && codeIsPlaceholder;
2158
+ return /* @__PURE__ */ jsxs11(
2159
+ "div",
2160
+ {
2161
+ "data-enrollment-device-flow": true,
2162
+ className: cn(
2163
+ "og-root flex w-full max-w-md flex-col gap-4 rounded-og-lg border border-og-border bg-og-surface-1 p-5 shadow-og-sm",
2164
+ className
2165
+ ),
2166
+ children: [
2167
+ /* @__PURE__ */ jsxs11("div", { className: "flex items-center justify-between gap-3", children: [
2168
+ /* @__PURE__ */ jsxs11("div", { className: "flex items-center gap-2", children: [
2169
+ /* @__PURE__ */ jsx12("span", { className: "flex size-7 items-center justify-center rounded-full bg-og-surface-2 text-og-fg-muted", children: /* @__PURE__ */ jsx12(LaptopIcon5, { className: "size-4", "aria-hidden": true }) }),
2170
+ /* @__PURE__ */ jsx12("h2", { className: "text-og-menu font-semibold text-og-fg", children: t("enrollmentDeviceFlow.connectAMachine") })
2171
+ ] }),
2172
+ /* @__PURE__ */ jsx12(
2173
+ ConnectionStatusPill,
2174
+ {
2175
+ status: PHASE_TO_STATE[phase] === "online" ? "online" : PHASE_TO_STATE[phase] === "offline" ? "offline" : "reconnecting",
2176
+ label: /* @__PURE__ */ jsx12(PhaseLabel, { phase }),
2177
+ size: "sm"
2178
+ }
2179
+ )
2180
+ ] }),
2181
+ installCommand ? /* @__PURE__ */ jsxs11("div", { className: "flex flex-col gap-1.5", children: [
2182
+ /* @__PURE__ */ jsx12("span", { className: "text-[11px] font-medium uppercase tracking-wide text-og-fg-subtle", children: t("enrollmentDeviceFlow.n1RunOnTheMachine") }),
2183
+ /* @__PURE__ */ jsxs11("div", { className: "flex items-center justify-between gap-2 overflow-hidden rounded-og-md border border-og-border bg-og-bg px-2.5 py-1.5", children: [
2184
+ /* @__PURE__ */ jsxs11("code", { className: "flex min-w-0 items-center gap-2 overflow-x-auto font-og-mono text-[12px] text-og-fg", children: [
2185
+ /* @__PURE__ */ jsx12(TerminalIcon, { className: "size-3.5 shrink-0 text-og-fg-subtle", "aria-hidden": true }),
2186
+ installCommand
2187
+ ] }),
2188
+ /* @__PURE__ */ jsx12(
2189
+ "button",
2190
+ {
2191
+ type: "button",
2192
+ "data-copy-install": true,
2193
+ onClick: onCopyInstall,
2194
+ title: t("enrollmentDeviceFlow.copyCommand"),
2195
+ className: "shrink-0 rounded-og-sm p-1.5 text-og-fg-subtle transition-colors hover:bg-og-surface-2 hover:text-og-fg",
2196
+ children: /* @__PURE__ */ jsx12(CopyIcon, { className: "size-4", "aria-hidden": true })
2197
+ }
2198
+ )
2199
+ ] })
2200
+ ] }) : null,
2201
+ /* @__PURE__ */ jsxs11("div", { className: "flex flex-col gap-1.5", children: [
2202
+ /* @__PURE__ */ jsx12("span", { className: "text-[11px] font-medium uppercase tracking-wide text-og-fg-subtle", children: installCommand ? t("enrollmentDeviceFlow.n2ApproveTheMachine") : t("enrollmentDeviceFlow.approveTheMachine") }),
2203
+ /* @__PURE__ */ jsxs11("div", { className: "flex items-center justify-between gap-3 rounded-og-md border border-og-border bg-og-bg px-3 py-2.5", children: [
2204
+ awaitingCode ? /* @__PURE__ */ jsx12("span", { "data-user-code": true, className: "font-og-mono text-[13px] text-og-fg-subtle", children: t("enrollmentDeviceFlow.runTheCommandAboveYour") }) : /* @__PURE__ */ jsx12(
2205
+ "span",
2206
+ {
2207
+ "data-user-code": true,
2208
+ className: "select-all font-og-mono text-2xl font-semibold tracking-[0.25em] text-og-fg",
2209
+ children: userCode
2210
+ }
2211
+ ),
2212
+ /* @__PURE__ */ jsx12(
2213
+ "button",
2214
+ {
2215
+ type: "button",
2216
+ "data-copy-code": true,
2217
+ onClick: onCopyCode,
2218
+ disabled: awaitingCode,
2219
+ title: t("enrollmentDeviceFlow.copyCode"),
2220
+ className: "shrink-0 rounded-og-sm p-1.5 text-og-fg-subtle transition-colors hover:bg-og-surface-2 hover:text-og-fg disabled:cursor-not-allowed disabled:opacity-40 disabled:hover:bg-transparent disabled:hover:text-og-fg-subtle",
2221
+ children: /* @__PURE__ */ jsx12(CopyIcon, { className: "size-4", "aria-hidden": true })
2222
+ }
2223
+ )
2224
+ ] })
2225
+ ] }),
2226
+ /* @__PURE__ */ jsxs11(
2227
+ "a",
2228
+ {
2229
+ href,
2230
+ "data-open-verification": true,
2231
+ target: "_blank",
2232
+ rel: "noreferrer",
2233
+ onClick: onOpenVerification,
2234
+ className: "inline-flex items-center justify-center gap-1.5 rounded-og-sm border border-og-primary-border bg-og-primary text-og-primary-fg px-3 py-2 text-og-menu font-medium transition-colors hover:bg-og-primary-hover",
2235
+ children: [
2236
+ t("enrollmentDeviceFlow.openApprovalPage"),
2237
+ /* @__PURE__ */ jsx12(ExternalLinkIcon, { className: "size-3.5", "aria-hidden": true })
2238
+ ]
2239
+ }
2240
+ ),
2241
+ /* @__PURE__ */ jsx12("p", { className: "text-center text-[11px] text-og-fg-subtle", children: awaitingCode ? /* @__PURE__ */ jsxs11(Fragment3, { children: [
2242
+ t("enrollmentDeviceFlow.theOneLinerPrintsA"),
2243
+ " ",
2244
+ /* @__PURE__ */ jsx12("span", { className: "font-og-mono text-og-fg-muted", children: verificationUri }),
2245
+ " ",
2246
+ t("enrollmentDeviceFlow.andConfirmTheCodeShown")
2247
+ ] }) : /* @__PURE__ */ jsxs11(Fragment3, { children: [
2248
+ t("enrollmentDeviceFlow.confirmCode"),
2249
+ " ",
2250
+ /* @__PURE__ */ jsx12("span", { className: "font-og-mono text-og-fg-muted", children: userCode }),
2251
+ " ",
2252
+ t("enrollmentDeviceFlow.theOnePrintedByThe"),
2253
+ " ",
2254
+ /* @__PURE__ */ jsx12("span", { className: "font-og-mono text-og-fg-muted", children: verificationUri }),
2255
+ ".",
2256
+ typeof expiresInSeconds === "number" ? /* @__PURE__ */ jsxs11(Fragment3, { children: [
2257
+ " ",
2258
+ t("enrollmentDeviceFlow.expiresIn"),
2259
+ " ",
2260
+ Math.max(0, Math.round(expiresInSeconds / 60)),
2261
+ " ",
2262
+ t("enrollmentDeviceFlow.min")
2263
+ ] }) : null
2264
+ ] }) })
2265
+ ]
2266
+ }
2267
+ );
2268
+ }
2269
+
2270
+ // src/components/enrollment-consent.tsx
2271
+ import { useState as useState3 } from "react";
2272
+ import {
2273
+ CircleAlertIcon as CircleAlertIcon2,
2274
+ LaptopIcon as LaptopIcon6,
2275
+ MonitorIcon as MonitorIcon2,
2276
+ ScreenShareIcon,
2277
+ ShieldAlertIcon,
2278
+ TerminalIcon as TerminalIcon2,
2279
+ UsersIcon as UsersIcon4
2280
+ } from "lucide-react";
2281
+ import { jsx as jsx13, jsxs as jsxs12 } from "react/jsx-runtime";
2282
+ function Capability({ icon, title, body }) {
2283
+ return /* @__PURE__ */ jsxs12("li", { className: "flex items-start gap-2.5", children: [
2284
+ /* @__PURE__ */ jsx13("span", { className: "mt-0.5 shrink-0 text-og-status-failed", children: icon }),
2285
+ /* @__PURE__ */ jsxs12("span", { className: "min-w-0", children: [
2286
+ /* @__PURE__ */ jsx13("span", { className: "block text-og-base font-medium text-og-fg", children: title }),
2287
+ /* @__PURE__ */ jsx13("span", { className: "block text-og-sm text-og-fg-muted", children: body })
2288
+ ] })
2289
+ ] });
2290
+ }
2291
+ function EnrollmentConsent({
2292
+ userCode,
2293
+ machine,
2294
+ phase = "review",
2295
+ allowWorkspaceScope = true,
2296
+ allowOrganizationScope = false,
2297
+ onApprove,
2298
+ onDeny,
2299
+ errorMessage: errorMessage2,
2300
+ className
2301
+ }) {
2302
+ const t = useOpenGeniText();
2303
+ const [allowScreenControl, setAllowScreenControl] = useState3(machine.requestsScreenControl);
2304
+ const [scope, setScope] = useState3("user");
2305
+ const busy = phase === "approving";
2306
+ const scopeCopy = {
2307
+ user: {
2308
+ label: t("enrollmentConsent.personal"),
2309
+ body: t("enrollmentConsent.onlyYouCanUseThis")
2310
+ },
2311
+ workspace: {
2312
+ label: t("enrollmentConsent.workspace"),
2313
+ body: t("enrollmentConsent.everyoneWithAccessToThis")
2314
+ },
2315
+ organization: {
2316
+ label: t("enrollmentConsent.organization"),
2317
+ body: t("enrollmentConsent.membersOfThisOrganizationCan")
2318
+ }
2319
+ };
2320
+ if (phase === "approved") {
2321
+ return /* @__PURE__ */ jsx13(
2322
+ ConsentResult,
2323
+ {
2324
+ className,
2325
+ tone: "ok",
2326
+ title: t("enrollmentConsent.machineConnected"),
2327
+ body: t("enrollmentConsent.machinenameIsNowConnectedWith", {
2328
+ machineName: machine.machineName,
2329
+ lowerCase: scopeCopy[scope].label.toLowerCase()
2330
+ })
2331
+ }
2332
+ );
2333
+ }
2334
+ if (phase === "denied") {
2335
+ return /* @__PURE__ */ jsx13(
2336
+ ConsentResult,
2337
+ {
2338
+ className,
2339
+ tone: "muted",
2340
+ title: t("enrollmentConsent.enrollmentDenied"),
2341
+ body: t("enrollmentConsent.youDeclinedToConnectMachinename", {
2342
+ machineName: machine.machineName
2343
+ })
2344
+ }
2345
+ );
2346
+ }
2347
+ if (phase === "error") {
2348
+ return /* @__PURE__ */ jsx13(
2349
+ ConsentResult,
2350
+ {
2351
+ className,
2352
+ tone: "danger",
2353
+ title: t("enrollmentConsent.couldNotCompleteEnrollment"),
2354
+ body: errorMessage2 ?? t("enrollmentConsent.theCodeMayHaveExpired")
2355
+ }
2356
+ );
2357
+ }
2358
+ return /* @__PURE__ */ jsxs12(
2359
+ "div",
2360
+ {
2361
+ "data-enrollment-consent": true,
2362
+ className: cn(
2363
+ "og-root mx-auto flex w-full max-w-md flex-col gap-5 rounded-og-lg border border-og-status-failed/30 bg-og-surface-1 p-6 shadow-og-md",
2364
+ className
2365
+ ),
2366
+ children: [
2367
+ /* @__PURE__ */ jsxs12("div", { className: "flex items-start gap-3", children: [
2368
+ /* @__PURE__ */ jsx13("span", { className: "flex size-9 shrink-0 items-center justify-center rounded-full bg-og-status-failed/15 text-og-status-failed", children: /* @__PURE__ */ jsx13(ShieldAlertIcon, { className: "size-5", "aria-hidden": true }) }),
2369
+ /* @__PURE__ */ jsxs12("div", { className: "min-w-0", children: [
2370
+ /* @__PURE__ */ jsx13("h1", { className: "text-og-md font-semibold text-og-fg", children: t("enrollmentConsent.giveTheAgentYourWhole") }),
2371
+ /* @__PURE__ */ jsxs12("p", { className: "mt-1 text-og-base text-og-fg-muted", children: [
2372
+ t("enrollmentConsent.approvingLetsTheOpengeniAgent"),
2373
+ " ",
2374
+ /* @__PURE__ */ jsx13("span", { className: "font-medium text-og-fg", children: machine.machineName }),
2375
+ " ",
2376
+ t("enrollmentConsent.withFullAccessThisIs")
2377
+ ] })
2378
+ ] })
2379
+ ] }),
2380
+ /* @__PURE__ */ jsxs12("div", { className: "flex flex-wrap items-center gap-2 rounded-og-md border border-og-border bg-og-surface-2 px-3 py-2 text-og-sm", children: [
2381
+ /* @__PURE__ */ jsx13(LaptopIcon6, { className: "size-4 text-og-fg-subtle", "aria-hidden": true }),
2382
+ /* @__PURE__ */ jsx13("span", { className: "font-medium text-og-fg", children: machine.machineName }),
2383
+ /* @__PURE__ */ jsxs12("span", { className: "font-og-mono text-og-fg-subtle", children: [
2384
+ machine.os,
2385
+ "/",
2386
+ machine.arch
2387
+ ] }),
2388
+ /* @__PURE__ */ jsx13("span", { "aria-hidden": true, className: "text-og-fg-subtle", children: "\xB7" }),
2389
+ /* @__PURE__ */ jsxs12("span", { className: "text-og-fg-subtle", children: [
2390
+ t("enrollmentConsent.code"),
2391
+ " ",
2392
+ /* @__PURE__ */ jsx13("span", { className: "font-og-mono font-medium text-og-fg", children: userCode })
2393
+ ] })
2394
+ ] }),
2395
+ /* @__PURE__ */ jsxs12("ul", { className: "flex flex-col gap-3", children: [
2396
+ /* @__PURE__ */ jsx13(
2397
+ Capability,
2398
+ {
2399
+ icon: /* @__PURE__ */ jsx13(TerminalIcon2, { className: "size-4", "aria-hidden": true }),
2400
+ title: t("enrollmentConsent.readWriteRunAnything"),
2401
+ body: t("enrollmentConsent.theAgentCanReadAnd")
2402
+ }
2403
+ ),
2404
+ machine.canOfferDisplay ? /* @__PURE__ */ jsx13(
2405
+ Capability,
2406
+ {
2407
+ icon: /* @__PURE__ */ jsx13(MonitorIcon2, { className: "size-4", "aria-hidden": true }),
2408
+ title: t("enrollmentConsent.seeYourScreen"),
2409
+ body: t("enrollmentConsent.theAgentCanCaptureThis")
2410
+ }
2411
+ ) : null,
2412
+ /* @__PURE__ */ jsx13(
2413
+ Capability,
2414
+ {
2415
+ icon: /* @__PURE__ */ jsx13(UsersIcon4, { className: "size-4", "aria-hidden": true }),
2416
+ title: t("enrollmentConsent.labelAccessWhileConnected", {
2417
+ label: scopeCopy[scope].label
2418
+ }),
2419
+ body: t("enrollmentConsent.bodyDisconnectTheAgentTo", { body: scopeCopy[scope].body })
2420
+ }
2421
+ )
2422
+ ] }),
2423
+ /* @__PURE__ */ jsxs12("fieldset", { className: "flex flex-col gap-2", disabled: busy, children: [
2424
+ /* @__PURE__ */ jsx13("legend", { className: "mb-1 text-og-sm font-medium text-og-fg", children: t("enrollmentConsent.whoCanUseThisMachine") }),
2425
+ ["user", "workspace", "organization"].map((candidate) => {
2426
+ const disabled = candidate === "organization" && !allowOrganizationScope || candidate === "workspace" && !allowWorkspaceScope;
2427
+ return /* @__PURE__ */ jsxs12(
2428
+ "label",
2429
+ {
2430
+ "data-enrollment-scope": candidate,
2431
+ "data-disabled": disabled ? "true" : "false",
2432
+ className: cn(
2433
+ "flex items-start gap-2.5 rounded-og-md border border-og-border bg-og-bg px-3 py-2.5",
2434
+ disabled ? "cursor-not-allowed opacity-50" : "cursor-pointer"
2435
+ ),
2436
+ children: [
2437
+ /* @__PURE__ */ jsx13(
2438
+ "input",
2439
+ {
2440
+ type: "radio",
2441
+ name: "enrollment-scope",
2442
+ value: candidate,
2443
+ checked: scope === candidate,
2444
+ disabled: disabled || busy,
2445
+ onChange: () => setScope(candidate),
2446
+ className: "mt-0.5 size-4 accent-og-accent"
2447
+ }
2448
+ ),
2449
+ /* @__PURE__ */ jsxs12("span", { className: "min-w-0", children: [
2450
+ /* @__PURE__ */ jsxs12("span", { className: "block text-og-base font-medium text-og-fg", children: [
2451
+ scopeCopy[candidate].label,
2452
+ disabled ? candidate === "organization" ? " \xB7 organization admin required" : " \xB7 workspace admin required" : ""
2453
+ ] }),
2454
+ /* @__PURE__ */ jsx13("span", { className: "block text-og-sm text-og-fg-muted", children: scopeCopy[candidate].body })
2455
+ ] })
2456
+ ]
2457
+ },
2458
+ candidate
2459
+ );
2460
+ })
2461
+ ] }),
2462
+ machine.canOfferDisplay ? /* @__PURE__ */ jsxs12(
2463
+ "label",
2464
+ {
2465
+ "data-screen-control-toggle": true,
2466
+ className: "flex cursor-pointer items-start gap-3 rounded-og-md border border-og-border bg-og-bg px-3 py-2.5",
2467
+ children: [
2468
+ /* @__PURE__ */ jsx13(
2469
+ "input",
2470
+ {
2471
+ type: "checkbox",
2472
+ checked: allowScreenControl,
2473
+ disabled: busy,
2474
+ onChange: (e) => setAllowScreenControl(e.target.checked),
2475
+ className: "mt-0.5 size-4 accent-og-accent"
2476
+ }
2477
+ ),
2478
+ /* @__PURE__ */ jsxs12("span", { className: "min-w-0", children: [
2479
+ /* @__PURE__ */ jsxs12("span", { className: "flex items-center gap-1.5 text-og-base font-medium text-og-fg", children: [
2480
+ /* @__PURE__ */ jsx13(ScreenShareIcon, { className: "size-3.5 text-og-fg-muted", "aria-hidden": true }),
2481
+ t("enrollmentConsent.alsoLetTheAgentControl")
2482
+ ] }),
2483
+ /* @__PURE__ */ jsx13("span", { className: "mt-0.5 block text-og-sm text-og-fg-muted", children: t("enrollmentConsent.optionalEnablesComputerUseThe") })
2484
+ ] })
2485
+ ]
2486
+ }
2487
+ ) : /* @__PURE__ */ jsxs12("p", { className: "flex items-start gap-2 rounded-og-md border border-og-border bg-og-bg px-3 py-2 text-og-sm text-og-fg-muted", children: [
2488
+ /* @__PURE__ */ jsx13(CircleAlertIcon2, { className: "mt-px size-3.5 shrink-0 text-og-fg-subtle", "aria-hidden": true }),
2489
+ t("enrollmentConsent.thisMachineHasNoDisplay")
2490
+ ] }),
2491
+ /* @__PURE__ */ jsxs12("div", { className: "flex items-center gap-2", children: [
2492
+ /* @__PURE__ */ jsx13(
2493
+ "button",
2494
+ {
2495
+ type: "button",
2496
+ "data-deny": true,
2497
+ disabled: busy,
2498
+ onClick: () => onDeny?.(),
2499
+ className: "flex-1 rounded-og-sm border border-og-border px-3 py-2 text-og-sm font-medium text-og-fg-muted transition-colors hover:border-og-border-strong hover:text-og-fg disabled:opacity-50 pointer-coarse:min-h-11",
2500
+ children: t("enrollmentConsent.cancel")
2501
+ }
2502
+ ),
2503
+ /* @__PURE__ */ jsx13(
2504
+ "button",
2505
+ {
2506
+ type: "button",
2507
+ "data-approve": true,
2508
+ disabled: busy,
2509
+ onClick: () => onApprove?.(allowScreenControl, scope),
2510
+ className: "flex-1 rounded-og-sm bg-og-status-failed px-3 py-2 text-og-sm font-semibold text-og-accent-fg transition-colors hover:opacity-90 disabled:opacity-50 pointer-coarse:min-h-11",
2511
+ children: busy ? t("enrollmentConsent.connecting") : t("enrollmentConsent.grantFullAccess")
2512
+ }
2513
+ )
2514
+ ] })
2515
+ ]
2516
+ }
2517
+ );
2518
+ }
2519
+ function ConsentResult({
2520
+ tone,
2521
+ title,
2522
+ body,
2523
+ className
2524
+ }) {
2525
+ const ring = tone === "ok" ? "border-og-status-running/30" : tone === "danger" ? "border-og-status-failed/30" : "border-og-border";
2526
+ const iconClass = tone === "ok" ? "text-og-status-running" : tone === "danger" ? "text-og-status-failed" : "text-og-fg-subtle";
2527
+ return /* @__PURE__ */ jsxs12(
2528
+ "div",
2529
+ {
2530
+ "data-enrollment-result": tone,
2531
+ className: cn(
2532
+ "og-root mx-auto flex w-full max-w-md flex-col items-center gap-3 rounded-og-lg border bg-og-surface-1 p-6 text-center shadow-og-md",
2533
+ ring,
2534
+ className
2535
+ ),
2536
+ children: [
2537
+ /* @__PURE__ */ jsx13(
2538
+ "span",
2539
+ {
2540
+ className: cn(
2541
+ "flex size-10 items-center justify-center rounded-full bg-og-surface-2",
2542
+ iconClass
2543
+ ),
2544
+ children: /* @__PURE__ */ jsx13(LaptopIcon6, { className: "size-5", "aria-hidden": true })
2545
+ }
2546
+ ),
2547
+ /* @__PURE__ */ jsx13("h1", { className: "text-og-md font-semibold text-og-fg", children: title }),
2548
+ /* @__PURE__ */ jsx13("p", { className: "max-w-sm text-og-base text-og-fg-muted", children: body })
2549
+ ]
2550
+ }
2551
+ );
2552
+ }
2553
+
2554
+ export {
2555
+ CONNECTION_STATUS_META,
2556
+ MACHINE_STATE_BADGE_META,
2557
+ ConnectionStatusPill,
2558
+ ConnectionDot,
2559
+ MachineStatusPill,
2560
+ MachineMetrics,
2561
+ deriveHealth,
2562
+ HEALTH_TOKEN,
2563
+ healthPulses,
2564
+ MachineHealthPill,
2565
+ MetricSparkline,
2566
+ MachineCard,
2567
+ MetricHistoryChart,
2568
+ METRIC_WINDOWS,
2569
+ WINDOW_LABEL,
2570
+ METRICS,
2571
+ pointsFor,
2572
+ MachineOperationPolicyEditor,
2573
+ MachineDetail,
2574
+ MachinesDashboard,
2575
+ MachineDockBar,
2576
+ SharedMachineDisclosure,
2577
+ EnrollmentDeviceFlow,
2578
+ EnrollmentConsent
2579
+ };
2580
+ //# sourceMappingURL=chunk-45SB4UK3.js.map