@vellumai/web 0.10.0 → 0.10.1-staging.1

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 (311) hide show
  1. package/dist/assets/{BundleConfirmPage-CkXUMWg6.js → BundleConfirmPage-B1RL5CT5.js} +1 -1
  2. package/dist/assets/{Combination-DmnhUZru.js → Combination-CDqVzelh.js} +1 -1
  3. package/dist/assets/{about-page-Bue2vNnY.js → about-page-CW4mH7w7.js} +1 -1
  4. package/dist/assets/account-page-DcjAe3ze.js +1 -0
  5. package/dist/assets/{account-shell-oWV1wIYb.js → account-shell-BBL0HqTX.js} +1 -1
  6. package/dist/assets/add-credits-modal-BRZVeZOI.js +1 -0
  7. package/dist/assets/advanced-page-axzblMww.js +1 -0
  8. package/dist/assets/ai-page-DrDDpvgG.js +1 -0
  9. package/dist/assets/{api-BSHLYsxJ.js → api-kMnfZUPa.js} +1 -1
  10. package/dist/assets/{api-key-screen-CUKjlF2C.js → api-key-screen-CM-BLcGz.js} +1 -1
  11. package/dist/assets/{archive-BCoY55bM.js → archive-D-fnxeQf.js} +1 -1
  12. package/dist/assets/{archive-page-YsBlmevd.js → archive-page-DabK-GNm.js} +1 -1
  13. package/dist/assets/arrow-left-CEu7Dsda.js +1 -0
  14. package/dist/assets/arrow-up-BHPaHiHe.js +1 -0
  15. package/dist/assets/assistant-api-c0d65GPi.js +1 -0
  16. package/dist/assets/assistant-feature-flag-store-BD9zTDcP.js +6 -0
  17. package/dist/assets/assistant-identity-store-DaDnhbxy.js +1 -0
  18. package/dist/assets/assistant-status-panel-Cm8ComZV.js +1 -0
  19. package/dist/assets/auth-store-6CnXVIAL.js +7 -0
  20. package/dist/assets/ban-DOB4wT-M.js +1 -0
  21. package/dist/assets/{bell-CSP2EUlP.js → bell-tEVVOFRL.js} +1 -1
  22. package/dist/assets/billing-page-CvQeoBjS.js +3 -0
  23. package/dist/assets/{bookmark-Cj14Qikr.js → bookmark-Bw04OiC7.js} +1 -1
  24. package/dist/assets/{bookmarks-page-DRcIBBva.js → bookmarks-page-CvfOEvF0.js} +1 -1
  25. package/dist/assets/{bug-BIPj7Nbx.js → bug-Dyqld0Aa.js} +1 -1
  26. package/dist/assets/{build-state-DqzVxR37.js → build-state-CjVnPOtQ.js} +1 -1
  27. package/dist/assets/{cable-R_YO6j5x.js → cable-CYB4K1nY.js} +1 -1
  28. package/dist/assets/{calendar-Dm2Jn-zV.js → calendar-DUv7hzHD.js} +1 -1
  29. package/dist/assets/{capture-error-B0wqOYKY.js → capture-error-CN7ObyIk.js} +1 -1
  30. package/dist/assets/{checkbox-Dc9gjmAy.js → checkbox-ChtGq7OI.js} +1 -1
  31. package/dist/assets/chevron-left-BFX62ERI.js +1 -0
  32. package/dist/assets/chevron-right-Cc3NZhAF.js +1 -0
  33. package/dist/assets/{chevron-up-Ck7_ou16.js → chevron-up-BT6xIbCo.js} +1 -1
  34. package/dist/assets/{circle-alert-C5TvMkJV.js → circle-alert-D58pfVBz.js} +1 -1
  35. package/dist/assets/circle-check-BKkxjdE1.js +1 -0
  36. package/dist/assets/{client-feature-flag-store-ivPVcKfH.js → client-feature-flag-store-DjN8fxHA.js} +1 -1
  37. package/dist/assets/{cloud-off-DJomNBuZ.js → cloud-off-DfVAWu4D.js} +1 -1
  38. package/dist/assets/code-CfKv4BKJ.js +1 -0
  39. package/dist/assets/{command-palette-BXEAR93M.js → command-palette-AsmJHeEk.js} +1 -1
  40. package/dist/assets/{command-palette-window-page-5SP_Ft4Y.js → command-palette-window-page-DrgvLRov.js} +1 -1
  41. package/dist/assets/{community-page-D5-exeNr.js → community-page-sWODbqYS.js} +1 -1
  42. package/dist/assets/confirm-dialog-SpCsmAdG.js +1 -0
  43. package/dist/assets/{connect-page-Bvs0EgCJ.js → connect-page-DsRXJyfd.js} +1 -1
  44. package/dist/assets/consent-controls-Bk8etO5C.js +1 -0
  45. package/dist/assets/{contacts-gateway-Cf32jSYa.js → contacts-gateway-CZMULd7Z.js} +1 -1
  46. package/dist/assets/contacts-page-route-eK-_KwLV.js +1 -0
  47. package/dist/assets/{conversation-queries-Dt4RoWIo.js → conversation-queries-Hwr6Ce8U.js} +1 -1
  48. package/dist/assets/{conversation-store-BSxi0r0X.js → conversation-store-I2d3A6Tv.js} +1 -1
  49. package/dist/assets/{cpu-CT8bAyOk.js → cpu-fIfNq834.js} +1 -1
  50. package/dist/assets/{credit-card-XOxZwKz-.js → credit-card-CcU-1-nT.js} +1 -1
  51. package/dist/assets/{danger-zone-redirect-page-5H-AuIvi.js → danger-zone-redirect-page-BsyYvQrZ.js} +1 -1
  52. package/dist/assets/debug-page-BeqbpC6w.js +2 -0
  53. package/dist/assets/{deploy-dialogs-BtpYB7B8.js → deploy-dialogs-CDE1JAyP.js} +1 -1
  54. package/dist/assets/{detail-card-CLwQ17AA.js → detail-card-QPVpO5cj.js} +1 -1
  55. package/dist/assets/developer-page-Bh9POaRZ.js +1 -0
  56. package/dist/assets/devices-page-br5aQnJ6.js +1 -0
  57. package/dist/assets/dictation-overlay-page-D_kPOJmY.js +1 -0
  58. package/dist/assets/{dist-DhhV5jI1.js → dist-cZPU9ZZL.js} +1 -1
  59. package/dist/assets/{document-viewer-page-BLBwWqM4.js → document-viewer-page-BWNgq5A7.js} +1 -1
  60. package/dist/assets/{dollar-sign-Ctayw6dD.js → dollar-sign-Bi1OUcqU.js} +1 -1
  61. package/dist/assets/{domain-field-yW8B9mxj.js → domain-field-BqCbfaBb.js} +1 -1
  62. package/dist/assets/earn-credits-modal-BQlDvHQX.js +1 -0
  63. package/dist/assets/emails-page-DCEa8uJF.js +1 -0
  64. package/dist/assets/{environment-store-Ck7wXCrL.js → environment-store-DoO5ZqXZ.js} +1 -1
  65. package/dist/assets/{esm-DkmmS1Rg.js → esm-B9FuN3Io.js} +2 -2
  66. package/dist/assets/esm-BIUrrGWd.js +2 -0
  67. package/dist/assets/esm-BT7uz_mC.js +2 -0
  68. package/dist/assets/esm-BU45yXtJ.js +2 -0
  69. package/dist/assets/esm-D51SsTmc.js +2 -0
  70. package/dist/assets/esm-KT7CwnAY.js +1 -0
  71. package/dist/assets/{external-link-B3skagqt.js → external-link-CyRCaWBE.js} +1 -1
  72. package/dist/assets/{feature-flag-catalog-DEr38CMM.js → feature-flag-catalog-RZLmDa1F.js} +1 -1
  73. package/dist/assets/{file-editor-HQXiGdH-.js → file-editor-D0SuRz-y.js} +1 -1
  74. package/dist/assets/general-page-Cxl-qtRp.js +1 -0
  75. package/dist/assets/{globe-BV8ouh66.js → globe-CiNEZj-J.js} +1 -1
  76. package/dist/assets/google-logo-DNkI-jCf.js +1 -0
  77. package/dist/assets/{hard-drive-C6sJQKXL.js → hard-drive-BbaHN7Gp.js} +1 -1
  78. package/dist/assets/hatching-screen-CHqDiHaW.js +1 -0
  79. package/dist/assets/home-page-route-CAziCmHd.js +1 -0
  80. package/dist/assets/{hosting-screen-dPfTLCnv.js → hosting-screen-DVJZyhOt.js} +1 -1
  81. package/dist/assets/identity-page-route-DmpOhvmv.js +1 -0
  82. package/dist/assets/index-BvIwFdLE.css +2 -0
  83. package/dist/assets/index-Chr1kHBM.js +155 -0
  84. package/dist/assets/{octagon-x-DV9qasaC.js → info-BGLlcyt6.js} +1 -1
  85. package/dist/assets/{info-BJtskZc-.js → info-CUuJWmsF.js} +1 -1
  86. package/dist/assets/inspect-page-CBpmIz3n.js +7 -0
  87. package/dist/assets/{install-CHMiF_Hw.js → install-CFvX5wtl.js} +1 -1
  88. package/dist/assets/integrations-page-C2AgksrD.js +1 -0
  89. package/dist/assets/{intelligence-layout-CjDxFKQO.js → intelligence-layout-BzBg1Kci.js} +1 -1
  90. package/dist/assets/{keyboard-shortcuts-page-DIhG1FK_.js → keyboard-shortcuts-page-CfAeD2Ca.js} +1 -1
  91. package/dist/assets/lib-BVvJNDCQ.js +14 -0
  92. package/dist/assets/library-detail-page-D6RDZtML.js +1 -0
  93. package/dist/assets/{library-page-BFIPthR_.js → library-page-CrI--_3N.js} +1 -1
  94. package/dist/assets/{link-2-BedDg97D.js → link-2-C6BJ3RH_.js} +1 -1
  95. package/dist/assets/loader-circle-YAV9sMh_.js +1 -0
  96. package/dist/assets/local-mode-Bg6wpc5q.js +39 -0
  97. package/dist/assets/{log-in-DOSWwTiS.js → log-in-BPJxI98d.js} +1 -1
  98. package/dist/assets/{login-flow-BMwbZfKA.js → login-flow-sr2DI9LC.js} +1 -1
  99. package/dist/assets/login-page-JTaRfldA.js +1 -0
  100. package/dist/assets/{logout-page-DI7i4Hok.js → logout-page-DjT8j4Lw.js} +1 -1
  101. package/dist/assets/{logs-layout-BEMQQY7S.js → logs-layout-DsCE83mN.js} +1 -1
  102. package/dist/assets/mcp-page-BgOwigD-.js +1 -0
  103. package/dist/assets/{memory-router-playground-page-JdkTEwPy.js → memory-router-playground-page-BFeqOyw_.js} +1 -1
  104. package/dist/assets/{menu-BvyV91Np.js → menu-CdoNX1qx.js} +1 -1
  105. package/dist/assets/{metric-card-B3EBP9m4.js → metric-card-DxrlxUKS.js} +1 -1
  106. package/dist/assets/{minimize-2-CwIqAxPY.js → minimize-2-BFkjQhB_.js} +1 -1
  107. package/dist/assets/{mobile-sidebar-drawer-DuJUmy0b.js → mobile-sidebar-drawer-ChpPfZ8u.js} +1 -1
  108. package/dist/assets/{modal-DX6UN7b0.js → modal-CHuPOsJJ.js} +1 -1
  109. package/dist/assets/{moon-C0wLM1iN.js → moon-D-eeNLvA.js} +1 -1
  110. package/dist/assets/mutation-error-BjiE6W0q.js +1 -0
  111. package/dist/assets/{native-file-CbhjzPxL.js → native-file-LJQTmnKy.js} +2 -2
  112. package/dist/assets/notice-CynJKEow.js +1 -0
  113. package/dist/assets/notifications-page-Bg_7pXfR.js +1 -0
  114. package/dist/assets/{oauth-complete-page-R_1ODIIi.js → oauth-complete-page-BuJCcg8E.js} +1 -1
  115. package/dist/assets/{oauth-popup-complete-page-YECuZtPs.js → oauth-popup-complete-page-Cfh_5DAx.js} +1 -1
  116. package/dist/assets/{page-shell-C0oiLAoY.js → page-shell-W5IMIXQq.js} +1 -1
  117. package/dist/assets/{pairing-page-BtaFWq0w.js → pairing-page-Jt95f3cN.js} +1 -1
  118. package/dist/assets/{panel-item-BFOUNXY1.js → panel-item-BLQE_l-g.js} +1 -1
  119. package/dist/assets/{password-reset-page-Cf5SQHDV.js → password-reset-page-BD2oysNq.js} +1 -1
  120. package/dist/assets/{pencil-lwgMCqyH.js → pencil-Cyrr5VNX.js} +1 -1
  121. package/dist/assets/platform-loopback-page-B3Q7OUNO.js +1 -0
  122. package/dist/assets/{plugin-detail-page-D6Gve0qx.js → plugin-detail-page-C4bk1LvY.js} +1 -1
  123. package/dist/assets/{plugins-page-DA-JrehF.js → plugins-page-CtHfLqtX.js} +1 -1
  124. package/dist/assets/{popover-PnyzuDx3.js → popover-BsF65jZY.js} +1 -1
  125. package/dist/assets/prechat-route-CEPNmia4.js +1 -0
  126. package/dist/assets/{prefs-Mrqh1A7Y.js → prefs-CrgkSe-_.js} +1 -1
  127. package/dist/assets/privacy-page-BX4CkH3k.js +1 -0
  128. package/dist/assets/{privacy-screen-ccjT4S0F.js → privacy-screen-CXDDLFzO.js} +1 -1
  129. package/dist/assets/{provider-callback-page-BS-DqV_M.js → provider-callback-page-D2guKVyJ.js} +1 -1
  130. package/dist/assets/{provider-key-DH6JmPXt.js → provider-key-CK_U6Kex.js} +1 -1
  131. package/dist/assets/{provider-signup-page-Beuafn_s.js → provider-signup-page-DiyM7dV8.js} +1 -1
  132. package/dist/assets/proxy-l3iqYpig.js +1 -0
  133. package/dist/assets/{quick-input-page-0PEcj6WT.js → quick-input-page-B8bRJhco.js} +1 -1
  134. package/dist/assets/react-query.gen-CRARj4mG.js +1 -0
  135. package/dist/assets/{react-query.gen-DdB0sQgj.js → react-query.gen-DfnbKPpc.js} +1 -1
  136. package/dist/assets/refresh-cw-C7wug6Q3.js +1 -0
  137. package/dist/assets/research-mock-page-DB4eGyYW.js +1 -0
  138. package/dist/assets/research-onboarding-route-BCepmvL-.js +30 -0
  139. package/dist/assets/{resize-errors-tz_Tui32.js → resize-errors-D0YsLvoI.js} +1 -1
  140. package/dist/assets/resolved-assistants-store-IMxY1_w9.js +1 -0
  141. package/dist/assets/return-to-BcgKmS7W.js +1 -0
  142. package/dist/assets/review-terms-screen-BdGybDri.js +1 -0
  143. package/dist/assets/{routes-BKwsRssF.js → routes-BLyehs4B.js} +1 -1
  144. package/dist/assets/{save-WZktF4Xe.js → save-DdguSDQ1.js} +1 -1
  145. package/dist/assets/{schedules-DqkGi2Lm.js → schedules-Dbclu3k6.js} +1 -1
  146. package/dist/assets/{sdk.gen-DRL3oRwz.js → sdk.gen-0RzHFsEa.js} +1 -1
  147. package/dist/assets/{sdk.gen-Bew9wO5C.js → sdk.gen-W0KlW-sG.js} +1 -1
  148. package/dist/assets/select-assistant-screen-CHBqN3LE.js +1 -0
  149. package/dist/assets/{semver-DmouQEQK.js → semver-aan9RUyA.js} +1 -1
  150. package/dist/assets/{setting-row-IILQu7AE.js → setting-row-BHlMSre_.js} +1 -1
  151. package/dist/assets/settings-layout-CLYztcN0.js +1 -0
  152. package/dist/assets/share-feedback-modal-CRvX8jqz.js +1 -0
  153. package/dist/assets/sidebar-tree-CLtH7ULI.js +1 -0
  154. package/dist/assets/signup-page-Bh-8V-o6.js +1 -0
  155. package/dist/assets/{signup-shell-D6LXKfGy.js → signup-shell-CEJE1QSw.js} +1 -1
  156. package/dist/assets/skill-row-DDoJmniT.js +1 -0
  157. package/dist/assets/skills-page-B5SANwyR.js +1 -0
  158. package/dist/assets/{sound-manager-CC2af7bI.js → sound-manager-BJ26N0gf.js} +1 -1
  159. package/dist/assets/{sounds-page-DE47aZrz.js → sounds-page-wAXxaGjk.js} +1 -1
  160. package/dist/assets/{sparkles-B9QIWdq0.js → sparkles-BoIJjAXt.js} +1 -1
  161. package/dist/assets/{src-D6Nu2Lol.js → src-BJj2O5XB.js} +3 -3
  162. package/dist/assets/{step-indicator-dots-BOKv1I4C.js → step-indicator-dots-JQQwRvNU.js} +1 -1
  163. package/dist/assets/{subagent-detail-panel-BdPp2LMK.js → subagent-detail-panel-Csn2eZm-.js} +2 -2
  164. package/dist/assets/system-events-page-CY9869ly.js +1 -0
  165. package/dist/assets/{system-events-redirect-page-CmooXfba.js → system-events-redirect-page-DygqxqRr.js} +1 -1
  166. package/dist/assets/{tag-BadGF3FB.js → tag-CE_o2aao.js} +1 -1
  167. package/dist/assets/{tiptap-document-editor-DjIQ9tCC.js → tiptap-document-editor-B-jptvl0.js} +1 -1
  168. package/dist/assets/toast-CxaZ5f1d.js +1 -0
  169. package/dist/assets/{tool-detail-panel-C6uFi3_6.js → tool-detail-panel-TULCfc-h.js} +2 -2
  170. package/dist/assets/trace-page-CHASnwBH.js +1 -0
  171. package/dist/assets/{triangle-alert-M_S_Pe8C.js → triangle-alert-CoIDviBm.js} +1 -1
  172. package/dist/assets/triangle-alert-DnZC45c-.js +1 -0
  173. package/dist/assets/{upgrade-cancel-page-D2-xTACq.js → upgrade-cancel-page-DDp_V51G.js} +1 -1
  174. package/dist/assets/upgrade-success-page-jXr4wakw.js +1 -0
  175. package/dist/assets/usage-page-giUgsD1Z.js +1 -0
  176. package/dist/assets/{usage-window-BO_9IIjX.js → usage-window-DbWHZkbr.js} +1 -1
  177. package/dist/assets/{use-active-assistant-id-512RohBL.js → use-active-assistant-id-DOx36WGk.js} +1 -1
  178. package/dist/assets/{use-bus-subscription-RUbeQDfy.js → use-bus-subscription-D-1qIPnj.js} +1 -1
  179. package/dist/assets/use-is-org-ready-D3HBLwJJ.js +1 -0
  180. package/dist/assets/{use-onboarding-login-CxXV3Iue.js → use-onboarding-login-Bp9jhDR4.js} +1 -1
  181. package/dist/assets/{use-plugin-drift-BUHRYq2W.js → use-plugin-drift-B5uLDuHi.js} +1 -1
  182. package/dist/assets/{use-reduced-motion-CXbk4fYO.js → use-reduced-motion-DgX4o6QR.js} +1 -1
  183. package/dist/assets/utils-DugRzWBW.js +1 -0
  184. package/dist/assets/{viewer-store-CInCucV8.js → viewer-store-CTNS5BCs.js} +1 -1
  185. package/dist/assets/{voice-page-VrJ7AZrg.js → voice-page-BV-46kzi.js} +1 -1
  186. package/dist/assets/{weather-forecast-display-DKMPxDv5.js → weather-forecast-display-CdImQdck.js} +1 -1
  187. package/dist/assets/{web-BorhjBfF.js → web-B4ULoQq5.js} +1 -1
  188. package/dist/assets/{web-DKvxfNu_.js → web-ByMNu3A_.js} +1 -1
  189. package/dist/assets/{web-BEsXuN9d.js → web-CUTiBnsF.js} +1 -1
  190. package/dist/assets/{web-4XHemeeJ.js → web-CvCsdCeT.js} +1 -1
  191. package/dist/assets/{web-CVJTgRoJ.js → web-CyTCBnAZ.js} +1 -1
  192. package/dist/assets/{web-DALQZUJ4.js → web-DTFLfPeG.js} +1 -1
  193. package/dist/assets/{web-BcNl6r2T.js → web-DuA0h7oK.js} +1 -1
  194. package/dist/assets/{welcome-screen-DVeLGZKg.js → welcome-screen-TWxcbCdx.js} +1 -1
  195. package/dist/assets/{workflow-detail-panel-BgDWu3_4.js → workflow-detail-panel-FzbZ4bE5.js} +1 -1
  196. package/dist/assets/workspace-page-C4tstjYv.js +1 -0
  197. package/dist/assets/x-b3o2p6YU.js +1 -0
  198. package/dist/index.html +112 -107
  199. package/package.json +1 -1
  200. package/dist/assets/account-page-B5rB7loj.js +0 -1
  201. package/dist/assets/add-credits-modal-BEX4_5jj.js +0 -1
  202. package/dist/assets/advanced-page-9RUi4YCF.js +0 -1
  203. package/dist/assets/ai-page-CZj92XF4.js +0 -1
  204. package/dist/assets/arrow-left-DpZuwfUr.js +0 -1
  205. package/dist/assets/arrow-up-BsbPgGtM.js +0 -1
  206. package/dist/assets/assistant-api-D7r6RWoh.js +0 -39
  207. package/dist/assets/assistant-feature-flag-store-D2CUHsmL.js +0 -1
  208. package/dist/assets/assistant-identity-store-BFaMpt_3.js +0 -1
  209. package/dist/assets/assistant-status-panel-CMdqv7mF.js +0 -1
  210. package/dist/assets/auth-store-CrTf0uWL.js +0 -7
  211. package/dist/assets/ban-BMsomjPu.js +0 -1
  212. package/dist/assets/billing-page-DgX2YBSA.js +0 -3
  213. package/dist/assets/chevron-left-CySeFTW4.js +0 -1
  214. package/dist/assets/chevron-right-HpmykQ8I.js +0 -1
  215. package/dist/assets/circle-check-D3yd2el7.js +0 -1
  216. package/dist/assets/code-CXddtaOh.js +0 -1
  217. package/dist/assets/confirm-dialog-DbNUkFt6.js +0 -1
  218. package/dist/assets/consent-controls-cNdj_gb8.js +0 -1
  219. package/dist/assets/contacts-page-route-C9T-8Sdr.js +0 -1
  220. package/dist/assets/debug-page-ClQetFUa.js +0 -2
  221. package/dist/assets/developer-page-DQs8SZ8K.js +0 -1
  222. package/dist/assets/devices-page-VsRsz6XP.js +0 -1
  223. package/dist/assets/dictation-overlay-page-C5HFJIsY.js +0 -1
  224. package/dist/assets/earn-credits-modal-Dig03UD-.js +0 -1
  225. package/dist/assets/emails-page-D9R72EQW.js +0 -1
  226. package/dist/assets/esm--X8IY1ec.js +0 -1
  227. package/dist/assets/esm-Cs-ixW_a.js +0 -2
  228. package/dist/assets/esm-DxJBeF-2.js +0 -2
  229. package/dist/assets/esm-JmlvYCir.js +0 -2
  230. package/dist/assets/esm-LyzWW9Z1.js +0 -2
  231. package/dist/assets/general-page-CMr5RhNh.js +0 -1
  232. package/dist/assets/hatching-screen-BAzE4aGD.js +0 -1
  233. package/dist/assets/home-page-route-JenDSLBl.js +0 -1
  234. package/dist/assets/identity-page-route-r9ZgIw8g.js +0 -1
  235. package/dist/assets/index-BiN-6kWM.js +0 -140
  236. package/dist/assets/index-DIEDlrdu.css +0 -2
  237. package/dist/assets/inspect-page-2cNMjT4e.js +0 -7
  238. package/dist/assets/integrations-page-BiLM3QyR.js +0 -1
  239. package/dist/assets/lib-CQbq3OZw.js +0 -29
  240. package/dist/assets/library-detail-page-CjeBxuMc.js +0 -1
  241. package/dist/assets/loader-circle-CTs38Ovl.js +0 -1
  242. package/dist/assets/local-mode-9ZkSq1Fr.js +0 -1
  243. package/dist/assets/login-page-KDH0IZ6y.js +0 -1
  244. package/dist/assets/mcp-page-B7tUTzT0.js +0 -1
  245. package/dist/assets/notice-G5Imd5pC.js +0 -1
  246. package/dist/assets/notifications-page-CmOvbV59.js +0 -1
  247. package/dist/assets/platform-loopback-page-Wie5xEwr.js +0 -1
  248. package/dist/assets/prechat-route-BhzvRsw3.js +0 -1
  249. package/dist/assets/privacy-page-Yex5OJjZ.js +0 -1
  250. package/dist/assets/proxy-CQsxT9tJ.js +0 -1
  251. package/dist/assets/research-mock-page-D0-sKBpu.js +0 -1
  252. package/dist/assets/research-onboarding-route-ZTgUGnrN.js +0 -38
  253. package/dist/assets/resolved-assistants-store-DMuRxkZC.js +0 -1
  254. package/dist/assets/return-to-Bc7amvZZ.js +0 -1
  255. package/dist/assets/review-terms-screen-DLWgKysx.js +0 -1
  256. package/dist/assets/select-assistant-screen-LNX6PpzR.js +0 -1
  257. package/dist/assets/settings-layout-BA0suokL.js +0 -1
  258. package/dist/assets/share-feedback-modal-CFgHvfgR.js +0 -1
  259. package/dist/assets/sidebar-tree-DALLHIeG.js +0 -1
  260. package/dist/assets/signup-page-13TRI3CC.js +0 -1
  261. package/dist/assets/skills-page-DiopOlcy.js +0 -1
  262. package/dist/assets/system-events-page-DcaF2EuX.js +0 -1
  263. package/dist/assets/toast-DLWkiWW6.js +0 -1
  264. package/dist/assets/trace-page-4MU66DDM.js +0 -1
  265. package/dist/assets/upgrade-success-page-DLjl6978.js +0 -1
  266. package/dist/assets/usage-page-CCBqWkRU.js +0 -1
  267. package/dist/assets/use-is-org-ready-BoWiaeMc.js +0 -1
  268. package/dist/assets/utils-B5-aBe5u.js +0 -1
  269. package/dist/assets/workspace-page-BlVlfXIt.js +0 -1
  270. package/dist/assets/x-Dz7msELe.js +0 -1
  271. /package/dist/assets/{api-errors-CwAGZ-xJ.js → api-errors-C3sAdlZQ.js} +0 -0
  272. /package/dist/assets/{avatar-bundled-components-UfXe4Pfu.js → avatar-bundled-components-f4-fradg.js} +0 -0
  273. /package/dist/assets/{avatar-svg-compositor-Bbqkq_FE.js → avatar-svg-compositor-DMT4wmUm.js} +0 -0
  274. /package/dist/assets/{build.umd-TjHHwLRY.js → build.umd-CPG-O6Se.js} +0 -0
  275. /package/dist/assets/{client.gen-CWZrHbc9.js → client.gen-Bx3pJMXa.js} +0 -0
  276. /package/dist/assets/{client.gen-Cuv6iN0E.js → client.gen-DzaL5PKF.js} +0 -0
  277. /package/dist/assets/{composer-focus-DP3jFn8K.js → composer-focus-D-P0cGAF.js} +0 -0
  278. /package/dist/assets/{conversation-selection-BMndnV1U.js → conversation-selection-CrdMTnwx.js} +0 -0
  279. /package/dist/assets/{create-selectors-ClYkcuKo.js → create-selectors-BE0_e_Ed.js} +0 -0
  280. /package/dist/assets/{createLucideIcon-DIlBzeWM.js → createLucideIcon-KBgJOpms.js} +0 -0
  281. /package/dist/assets/{definitions-BqAtozTh.js → definitions-B4RRVbRh.js} +0 -0
  282. /package/dist/assets/{dist-nMnxT9pm.js → dist-3i_EPbLt.js} +0 -0
  283. /package/dist/assets/{dist-D7Zr-ONk.js → dist-BQHdyjQ3.js} +0 -0
  284. /package/dist/assets/{edit-chat-session-B1tanC3Z.js → edit-chat-session-DXSCprPw.js} +0 -0
  285. /package/dist/assets/{effective-timezone-wo2Bhl1P.js → effective-timezone-DBaPUyaX.js} +0 -0
  286. /package/dist/assets/{emoji-catalog-data-B6Q5tPZJ.js → emoji-catalog-data-C0EjtsOi.js} +0 -0
  287. /package/dist/assets/{event-bus-DntJgYuJ.js → event-bus-CFhOgvB8.js} +0 -0
  288. /package/dist/assets/{format-B12w_G9l.js → format-B2A6k4bb.js} +0 -0
  289. /package/dist/assets/{format-date-B6hTwbOM.js → format-date-Cx9GZ7-D.js} +0 -0
  290. /package/dist/assets/{format-file-size-DxhjMSDx.js → format-file-size-Br1LCKQi.js} +0 -0
  291. /package/dist/assets/{haptics-BtSYrQNK.js → haptics-BCTVEX6s.js} +0 -0
  292. /package/dist/assets/{impersonate-version-flag-ZdQOgpO3.js → impersonate-version-flag-BksY65Mo.js} +0 -0
  293. /package/dist/assets/{input-CwdmSRlD.js → input-Ch7OC6ME.js} +0 -0
  294. /package/dist/assets/{is-electron-BuSDabCt.js → is-electron-CcgCla1v.js} +0 -0
  295. /package/dist/assets/{llm-dimension-Cs4q1Ovq.js → llm-dimension-ovOt_D6t.js} +0 -0
  296. /package/dist/assets/{misc-Bo3spjOe.js → misc-Dm72afTZ.js} +0 -0
  297. /package/dist/assets/{native-deep-link-_WT_7c80.js → native-deep-link-CYaeyOfj.js} +0 -0
  298. /package/dist/assets/{pdf-CMJp1GoR.js → pdf-DhvXjkis.js} +0 -0
  299. /package/dist/assets/{prechat-names-BZIP2Y-H.js → prechat-names-CkLrL-Jh.js} +0 -0
  300. /package/dist/assets/{progress-bar-BOKTRqXE.js → progress-bar-DFH5aT1D.js} +0 -0
  301. /package/dist/assets/{public-asset-Dp-i4xhW.js → public-asset-CH9GPeL_.js} +0 -0
  302. /package/dist/assets/{reduced-motion-Do7LyjE6.js → reduced-motion-8QnGN6lg.js} +0 -0
  303. /package/dist/assets/{shortcut-keys-WNQqv5_X.js → shortcut-keys-vM6sNj7W.js} +0 -0
  304. /package/dist/assets/{stat-square-B5tBfA4w.js → stat-square-CraPxMcl.js} +0 -0
  305. /package/dist/assets/{subagent-status-CaVVlphf.js → subagent-status-DOJQZKTk.js} +0 -0
  306. /package/dist/assets/{toggle-_vZlLDBV.js → toggle-95p73HGd.js} +0 -0
  307. /package/dist/assets/{typed-storage-SkUUNYR1.js → typed-storage-qVehRaS3.js} +0 -0
  308. /package/dist/assets/{use-is-mobile-CvT53Qs1.js → use-is-mobile-D_0cze0t.js} +0 -0
  309. /package/dist/assets/{x-CaVViVFn.js → x-DE8JhiDZ.js} +0 -0
  310. /package/dist/assets/{xterm-BJ2bbKsF.js → xterm-B74sC241.js} +0 -0
  311. /package/dist/assets/{xterm-addon-fit-BJTajn72.js → xterm-addon-fit-By7PlC-c.js} +0 -0
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{a as t,m as n,o as r}from"./capture-error-CN7ObyIk.js";import{t as i}from"./react-DJZBPgpf.js";import{t as a}from"./button-D7s2Q_uG.js";import{d as o,h as s,r as c}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{n as l}from"./QueryClientProvider-DKhXIxGb.js";import{t as u}from"./useQuery-B45lW1Kk.js";import{t as d}from"./jsx-runtime-CVSDxk6A.js";import{t as f}from"./cn-DvW5mxZR.js";import{t as p}from"./dropdown-yOV5eJnU.js";import"./src-BJj2O5XB.js";import{t as m}from"./confirm-dialog-SpCsmAdG.js";import{t as h}from"./tag-CE_o2aao.js";import{t as g}from"./toggle-95p73HGd.js";import{n as _}from"./toast-CxaZ5f1d.js";import{S as v,f as y}from"./local-mode-Bg6wpc5q.js";import{t as b}from"./createLucideIcon-KBgJOpms.js";import{t as x}from"./bug-Dyqld0Aa.js";import{t as S}from"./info-CUuJWmsF.js";import{t as C}from"./loader-circle-YAV9sMh_.js";import{t as ee}from"./triangle-alert-CoIDviBm.js";import{l as te}from"./auth-store-6CnXVIAL.js";import{t as ne}from"./client.gen-DzaL5PKF.js";import{c as w,o as T}from"./api-kMnfZUPa.js";import{a as E}from"./routes-BLyehs4B.js";import{t as D}from"./use-is-org-ready-D3HBLwJJ.js";import{a as O,l as k,o as A}from"./feature-flag-catalog-RZLmDa1F.js";import{t as j}from"./client-feature-flag-store-DjN8fxHA.js";import{t as M}from"./assistant-feature-flag-store-BD9zTDcP.js";import{k as re,v as N}from"./react-query.gen-CRARj4mG.js";import{t as ie}from"./misc-Dm72afTZ.js";import{Gr as P,Ji as F}from"./index-Chr1kHBM.js";import{t as I}from"./use-active-assistant-id-DOx36WGk.js";import{t as L}from"./detail-card-QPVpO5cj.js";import{t as R}from"./environment-store-DoO5ZqXZ.js";var z=b(`flame`,[[`path`,{d:`M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4`,key:`1slcih`}]]),B=b(`timer`,[[`line`,{x1:`10`,x2:`14`,y1:`2`,y2:`2`,key:`14vaq8`}],[`line`,{x1:`12`,x2:`15`,y1:`14`,y2:`11`,key:`17fdiu`}],[`circle`,{cx:`12`,cy:`14`,r:`8`,key:`1e1u0o`}]]),V=e(i(),1),H=d();function U(){let e=l(),[t,n]=(0,V.useState)(!1),[r,i]=(0,V.useState)(!1),o=D(),s=I(),{data:c,isLoading:d}=u({...re({path:{id:s}}),enabled:o}),{data:f,isLoading:p}=u({...N({query:{hosting:`all`}}),enabled:o}),h=d||p,g=f?.results??[];return(0,H.jsxs)(`div`,{className:`space-y-6`,children:[(0,H.jsx)(W,{assistant:c??null,loading:h}),(0,H.jsx)(G,{assistants:g,activeAssistantId:s,loading:h}),(0,H.jsxs)(L,{title:`Hatch New Assistant`,subtitle:`Create a new assistant instance.`,children:[(0,H.jsxs)(`div`,{className:`flex items-center justify-between gap-4`,children:[(0,H.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--content-tertiary)]`,children:`Provision a new assistant. This may take a moment.`}),(0,H.jsx)(a,{variant:`outlined`,leftIcon:t?(0,H.jsx)(C,{className:`animate-spin`}):void 0,onClick:()=>i(!0),disabled:t,className:`shrink-0`,children:`Hatch`})]}),(0,H.jsx)(m,{open:r,title:`Hatch New Assistant`,message:`Are you sure you want to create a new assistant? This will provision new infrastructure.`,confirmLabel:`Hatch`,onConfirm:async()=>{i(!1),n(!0);try{let t=await T(void 0,`create`);if(t.ok){if(y())try{let e=await w();e.ok&&await v(e.data,te.getState().currentOrganizationId??void 0)}catch{}_.success(t.status===201?`New assistant hatched successfully.`:`Returned your existing assistant — no new one was created.`),e.invalidateQueries({queryKey:[{_id:`assistantsRetrieve`}]}),e.invalidateQueries({queryKey:N({query:{hosting:`all`}}).queryKey})}else{let e=typeof t.error?.detail==`string`?t.error.detail:`Failed to hatch assistant.`;_.error(e)}}catch{_.error(`Failed to hatch assistant.`)}finally{n(!1)}},onCancel:()=>i(!1)})]})]})}function W({assistant:e,loading:t}){return t?(0,H.jsx)(L,{title:`Assistant Info`,children:(0,H.jsxs)(`div`,{className:`flex items-center gap-2 text-body-medium-lighter text-[var(--content-tertiary)]`,children:[(0,H.jsx)(C,{className:`h-4 w-4 animate-spin`}),`Loading assistant info...`]})}):e?(0,H.jsx)(L,{title:`Assistant Info`,subtitle:`Current assistant details.`,children:(0,H.jsxs)(`div`,{className:`grid grid-cols-[140px_minmax(0,1fr)] gap-y-3`,children:[(0,H.jsx)(K,{children:`Name`}),(0,H.jsx)(q,{children:e.name??`Unnamed`}),(0,H.jsx)(K,{children:`Status`}),(0,H.jsx)(`div`,{children:(0,H.jsx)(h,{tone:e.status===`active`?`positive`:`neutral`,children:e.status})}),(0,H.jsx)(K,{children:`Assistant ID`}),(0,H.jsx)(`span`,{className:`break-all font-mono text-body-small-default text-[var(--content-tertiary)]`,children:e.id}),e.machine_id&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(K,{children:`Machine ID`}),(0,H.jsx)(`span`,{className:`break-all font-mono text-body-small-default text-[var(--content-tertiary)]`,children:e.machine_id})]}),(0,H.jsx)(K,{children:`Created`}),(0,H.jsx)(q,{children:new Date(e.created).toLocaleDateString()}),(0,H.jsx)(K,{children:`Last Modified`}),(0,H.jsx)(q,{children:new Date(e.modified).toLocaleDateString()}),e.current_release_version&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(K,{children:`Version`}),(0,H.jsx)(q,{children:e.current_release_version})]})]})}):(0,H.jsx)(L,{title:`Assistant Info`,children:(0,H.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--content-tertiary)]`,children:`No assistant found. Hatch an assistant to get started.`})})}function G({assistants:e,activeAssistantId:t,loading:n}){return n||e.length===0?null:(0,H.jsx)(L,{title:`All Assistants`,subtitle:`${e.length} assistant${e.length===1?``:`s`} found.`,children:(0,H.jsx)(`div`,{className:`max-h-[300px] space-y-2 overflow-y-auto`,children:e.map(e=>{let n=e.id===t;return(0,H.jsx)(`div`,{className:`flex items-center justify-between gap-4 rounded-lg border px-4 py-3 ${n?`border-[var(--border-focus)] bg-[var(--surface-lift)]`:`border-[var(--border-base)] bg-[var(--surface-default)]`}`,children:(0,H.jsxs)(`div`,{className:`min-w-0`,children:[(0,H.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,H.jsx)(`span`,{className:`truncate text-body-medium-default text-[var(--content-default)]`,children:e.name||`Unnamed`}),(0,H.jsx)(h,{tone:e.status===`active`?`positive`:`neutral`,children:e.status}),n&&(0,H.jsx)(h,{tone:`warning`,children:`Current`})]}),(0,H.jsx)(`span`,{className:`font-mono text-body-small-default text-[var(--content-tertiary)]`,children:e.id})]})},e.id)})})})}function K({children:e}){return(0,H.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-tertiary)]`,children:e})}function q({children:e}){return(0,H.jsx)(`span`,{className:`text-body-medium-lighter text-[var(--content-default)]`,children:e})}function J(){let e=R.use.emailRootDomain(),t=R.use.isNonProduction(),n=R.use.setEnvironment();return(0,H.jsx)(L,{title:`Environment`,subtitle:`Environment configuration overrides for this session.`,children:(0,H.jsxs)(`div`,{className:`space-y-2`,children:[(0,H.jsxs)(`div`,{className:`flex items-start gap-3 py-3`,children:[(0,H.jsx)(`div`,{className:`shrink-0 pt-0.5`,children:(0,H.jsx)(g,{checked:t,onChange:e=>n({isNonProduction:e}),"aria-label":`Non-Production is ${t?`on`:`off`}`})}),(0,H.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-0.5`,children:[(0,H.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-default)]`,children:`Non-Production`}),(0,H.jsx)(`span`,{className:`block text-body-small-default text-[var(--content-tertiary)]`,children:`Indicates a non-production environment. Enables dev-only UI surfaces and diagnostics.`})]})]}),(0,H.jsxs)(`div`,{className:`flex items-start gap-3 py-3`,children:[(0,H.jsx)(`div`,{className:`shrink-0 pt-0.5`,children:(0,H.jsx)(h,{tone:`neutral`,children:e})}),(0,H.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-0.5`,children:[(0,H.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-default)]`,children:`Email Root Domain`}),(0,H.jsx)(`span`,{className:`block text-body-small-default text-[var(--content-tertiary)]`,children:`Root domain used for assistant email addresses (e.g. vellum.me).`})]})]})]})})}async function ae(){let{data:e,response:t}=await ne.get({url:`/v1/feature-flags/`,throwOnError:!1});return t?.ok?e?.flags??[]:[]}var Y={client:`warning`,assistant:`positive`};function oe(){let e=I(),{data:t}=u({queryKey:[`feature-flag-definitions`],queryFn:ae,enabled:D(),staleTime:300*1e3}),n=(0,V.useMemo)(()=>{let e=new Map;if(!t)return e;for(let n of t)n.type===`string`&&n.values?.length&&e.set(n.key,n.values);return e},[t]),[r,i]=(0,V.useState)(``),a=j(),o=M(),s=(0,V.useMemo)(()=>{let e=[];for(let t of A){let r=O(t.key);if(typeof t.defaultEnabled==`boolean`){let n=a[r],i=o[r],s=t.scope===`both`?n===!0||i===!0:t.scope===`assistant`?i:n;if(typeof s!=`boolean`)continue;e.push({kind:`boolean`,storeKey:r,scope:t.scope,label:t.label,description:t.description,value:s,defaultValue:t.defaultEnabled})}else if(typeof t.defaultEnabled==`string`){let i=a.stringFlags?.[r],s=o.stringFlags?.[r],c=t.scope===`assistant`?s??t.defaultEnabled:i??t.defaultEnabled;e.push({kind:`string`,storeKey:r,scope:t.scope,label:t.label,description:t.description,value:c,defaultValue:t.defaultEnabled,values:n.get(t.key)??t.values})}}return e.sort((e,t)=>e.label.localeCompare(t.label,void 0,{sensitivity:`base`}))},[a,o,n]),c=(0,V.useMemo)(()=>{if(!r.trim())return s;let e=r.trim().toLowerCase();return s.filter(t=>t.label.toLowerCase().includes(e)||t.description.toLowerCase().includes(e)||t.storeKey.toLowerCase().includes(e)||t.scope.includes(e)||t.scope===`both`&&(`client`.includes(e)||`assistant`.includes(e)))},[s,r]);return(0,H.jsx)(L,{title:`Feature Flags`,subtitle:`Active feature flags evaluated for the current session.`,children:(0,H.jsxs)(`div`,{className:`space-y-4`,children:[(0,H.jsxs)(`div`,{className:`relative`,children:[(0,H.jsx)(P,{className:`absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-[var(--content-tertiary)]`}),(0,H.jsx)(`input`,{type:`text`,placeholder:`Search flags...`,value:r,onChange:e=>i(e.target.value),className:`w-full rounded-lg border border-[var(--border-base)] bg-[var(--surface-default)] py-2 pl-9 pr-3 text-body-medium-default text-[var(--content-default)] placeholder:text-[var(--content-tertiary)] focus:border-[var(--border-focus)] focus:outline-none`})]}),c.length===0&&(0,H.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--content-tertiary)]`,children:`No matching flags.`}),c.length>0&&(0,H.jsx)(`div`,{className:`max-h-[500px] space-y-2 overflow-y-auto`,children:c.map(t=>(0,H.jsx)(Z,{flag:t,assistantId:e},t.storeKey))})]})})}function X({scope:e}){return e===`both`?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(h,{tone:Y.client,children:`client`}),(0,H.jsx)(h,{tone:Y.assistant,children:`assistant`})]}):(0,H.jsx)(h,{tone:Y[e],children:e})}function se({flag:e,assistantId:t}){let n=j.use.setFlag(),r=M.use.setFlag();return(0,H.jsxs)(`div`,{className:`flex items-start gap-3 py-3`,children:[(0,H.jsx)(`div`,{className:`shrink-0 pt-0.5`,children:(0,H.jsx)(g,{checked:e.value,onChange:i=>{k(e.scope,`client`)&&n(e.storeKey,i),k(e.scope,`assistant`)&&r(e.storeKey,i,t)},"aria-label":`${e.label} is ${e.value?`on`:`off`}`})}),(0,H.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-0.5`,children:[(0,H.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,H.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-default)]`,children:e.label}),(0,H.jsx)(X,{scope:e.scope})]}),(0,H.jsx)(`span`,{className:`block text-body-small-default text-[var(--content-tertiary)]`,children:e.description}),(0,H.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,H.jsx)(`span`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:`Default:`}),(0,H.jsx)(h,{tone:`neutral`,children:e.defaultValue?`On`:`Off`})]})]})]})}function ce({flag:e,assistantId:t}){let n=j.use.setStringFlag(),r=M.use.setStringFlag(),[i,a]=(0,V.useState)(e.value);(0,V.useEffect)(()=>{a(e.value)},[e.value]);let o=i=>{i!==e.value&&(k(e.scope,`client`)&&n(e.storeKey,i),k(e.scope,`assistant`)&&r(e.storeKey,i,t))},s=i!==e.value,c=e.values&&e.values.length>0?e.values:null,l=s&&c!=null&&!c.includes(i),u=()=>{l||o(i)},d=e=>{e.key===`Enter`&&e.currentTarget.blur()},m=c!=null&&c.includes(e.value);return(0,H.jsx)(`div`,{className:`flex items-start gap-3 py-3`,children:(0,H.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-1.5`,children:[(0,H.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,H.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-default)]`,children:e.label}),(0,H.jsx)(X,{scope:e.scope})]}),(0,H.jsx)(`span`,{className:`block text-body-small-default text-[var(--content-tertiary)]`,children:e.description}),m?(0,H.jsx)(p,{value:e.value,onChange:e=>{a(e),o(e)},options:c.map(e=>({value:e,label:e})),className:`w-48`,"aria-label":`${e.label} value`}):(0,H.jsxs)(`div`,{className:`space-y-1`,children:[(0,H.jsx)(`input`,{type:`text`,value:i,onChange:e=>a(e.target.value),onBlur:u,onKeyDown:d,className:f(`w-full rounded-lg border bg-[var(--surface-default)] px-3 py-1.5 text-body-small-default text-[var(--content-default)] placeholder:text-[var(--content-tertiary)] focus:outline-none`,l?`border-[var(--system-negative-strong)]`:`border-[var(--border-base)] focus:border-[var(--border-focus)]`),placeholder:e.defaultValue||`Enter value...`}),l&&(0,H.jsxs)(`span`,{className:`block text-body-small-default text-[var(--system-negative-strong)]`,children:[`Expected one of: `,c.join(`, `)]})]}),(0,H.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,H.jsx)(`span`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:`Default:`}),(0,H.jsx)(h,{tone:`neutral`,children:e.defaultValue||`(empty)`})]})]})})}function Z({flag:e,assistantId:t}){return e.kind===`string`?(0,H.jsx)(ce,{flag:e,assistantId:t}):(0,H.jsx)(se,{flag:e,assistantId:t})}function le(){let e=(0,V.useCallback)(()=>{t(Error(`[Dev Settings] Test error event`)),_.success(`Sentry error event sent.`)},[]),i=(0,V.useCallback)(()=>{r(`[Dev Settings] Test warning event`,`warning`),_.success(`Sentry warning event sent.`)},[]),a=(0,V.useCallback)(()=>{r(`[Dev Settings] Test info event`,`info`),_.success(`Sentry info event sent.`)},[]),o=(0,V.useCallback)(()=>{r(`[Dev Settings] Test fatal event`,`fatal`),_.success(`Sentry fatal event sent.`)},[]),s=(0,V.useCallback)(()=>{n({name:`[Dev Settings] Test transaction`,op:`test.transaction`,forceTransaction:!0}).end(),_.success(`Sentry performance transaction sent.`)},[]);return(0,H.jsx)(L,{title:`Sentry Testing`,subtitle:`Fire test events to verify Sentry integration is working.`,children:(0,H.jsxs)(`div`,{className:`space-y-3`,children:[(0,H.jsx)(Q,{icon:(0,H.jsx)(z,{className:`h-4 w-4 text-[var(--system-negative-strong)]`}),label:`Fatal Event`,description:`Send a fatal-level event to Sentry.`,onClick:o}),(0,H.jsx)(Q,{icon:(0,H.jsx)(F,{className:`h-4 w-4 text-[var(--system-negative-default)]`}),label:`Error Event`,description:`Capture a test Error exception.`,onClick:e}),(0,H.jsx)(Q,{icon:(0,H.jsx)(ee,{className:`h-4 w-4 text-[var(--system-warning-default)]`}),label:`Warning Event`,description:`Send a warning-level message.`,onClick:i}),(0,H.jsx)(Q,{icon:(0,H.jsx)(S,{className:`h-4 w-4 text-[var(--content-tertiary)]`}),label:`Info Event`,description:`Send an info-level message.`,onClick:a}),(0,H.jsx)(Q,{icon:(0,H.jsx)(B,{className:`h-4 w-4 text-[var(--system-positive-default)]`}),label:`Performance Transaction`,description:`Start and end a test transaction span.`,onClick:s})]})})}function Q({icon:e,label:t,description:n,onClick:r}){return(0,H.jsxs)(`div`,{className:`flex items-center justify-between gap-4 rounded-lg border border-[var(--border-base)] px-4 py-3`,children:[(0,H.jsxs)(`div`,{className:`flex min-w-0 items-center gap-3`,children:[(0,H.jsx)(`div`,{className:`shrink-0`,children:e}),(0,H.jsxs)(`div`,{className:`min-w-0`,children:[(0,H.jsx)(`p`,{className:`text-body-medium-default text-[var(--content-default)]`,children:t}),(0,H.jsx)(`p`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:n})]})]}),(0,H.jsxs)(a,{variant:`outlined`,size:`compact`,onClick:r,children:[(0,H.jsx)(x,{className:`h-4 w-4`}),`Send`]})]})}var $=[{id:`feature-flags`,label:`Feature Flags`},{id:`lifecycle`,label:`Assistant Lifecycle`},{id:`sentry`,label:`Sentry Testing`}];function ue(){let e=o(),[t,n]=s(),r=M.use.settingsDeveloperNav(),i=M.use.hasHydrated(),l=(0,V.useMemo)(()=>{let e=t.get(`tab`);return $.find(t=>t.id===e)?.id??`feature-flags`},[t]);if(i&&!r)return(0,H.jsx)(c,{replace:!0,to:E.settings.general});let u=e=>{let r=new URLSearchParams(t.toString());e===`feature-flags`?r.delete(`tab`):r.set(`tab`,e),n(r,{replace:!0})};return(0,H.jsxs)(`div`,{"data-slot":`developer-page`,className:`flex min-h-0 flex-1 flex-col`,children:[(0,H.jsxs)(`div`,{className:`flex shrink-0 items-center justify-between gap-4 border-b border-[var(--border-base)]`,children:[(0,H.jsx)(`div`,{role:`tablist`,"aria-label":`Developer sections`,className:`flex items-center gap-1`,children:$.map(e=>{let t=e.id===l;return(0,H.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":t,"aria-controls":`developer-tab-panel-${e.id}`,id:`developer-tab-${e.id}`,onClick:()=>u(e.id),className:ie(`relative -mb-px cursor-pointer border-b-2 px-4 py-2 text-body-medium-default transition-colors`,t?`border-[var(--system-positive-strong)] text-[var(--system-positive-strong)]`:`border-transparent text-[var(--content-tertiary)] hover:text-[var(--content-default)] dark:text-[var(--content-disabled)] dark:hover:text-[var(--content-default)]`),children:e.label},e.id)})}),y()&&(0,H.jsx)(a,{variant:`outlined`,className:`mb-1 shrink-0`,onClick:()=>void e(`${E.selectAssistant}?noAutoSkip=1`),children:`Choose Assistant`})]}),(0,H.jsxs)(`div`,{id:`developer-tab-panel-${l}`,role:`tabpanel`,"aria-labelledby":`developer-tab-${l}`,className:`flex min-h-0 flex-1 flex-col pt-6`,children:[l===`feature-flags`&&(0,H.jsxs)(`div`,{className:`space-y-6`,children:[(0,H.jsx)(oe,{}),(0,H.jsx)(J,{})]}),l===`lifecycle`&&(0,H.jsx)(U,{}),l===`sentry`&&(0,H.jsx)(le,{})]})]})}export{ue as DeveloperPage};
@@ -0,0 +1 @@
1
+ import{r as e}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{t}from"./useQuery-B45lW1Kk.js";import{t as n}from"./jsx-runtime-CVSDxk6A.js";import{t as r}from"./notice-CynJKEow.js";import{t as i}from"./loader-circle-YAV9sMh_.js";import{a}from"./routes-BLyehs4B.js";import{v as o}from"./react-query.gen-CRARj4mG.js";import{Gt as s,Kt as c,Rr as l,qt as u,si as d,x as f}from"./index-Chr1kHBM.js";import{t as p}from"./detail-card-QPVpO5cj.js";var m=n();function h(e){return new Intl.DateTimeFormat(`en`,{month:`short`,day:`numeric`,year:`numeric`}).format(new Date(e))}function g({assistant:e}){let t=e,n=t.platform===`ios`,r=n?l:d,i=e.name||(n?`iOS Device`:t.hostname||`Unknown Device`);return(0,m.jsxs)(`div`,{className:`flex items-center gap-3 rounded-lg border border-[var(--border-base)] px-4 py-3`,children:[(0,m.jsx)(r,{className:`h-5 w-5 shrink-0 text-[var(--content-secondary)]`}),(0,m.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,m.jsx)(`div`,{className:`truncate text-body-medium-default text-[var(--content-default)]`,children:i}),(0,m.jsxs)(`div`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:[t.hostname&&(0,m.jsx)(`span`,{className:`mr-3`,children:t.hostname}),e.created&&(0,m.jsxs)(`span`,{children:[`Registered `,h(e.created)]})]})]})]})}function _(){let n=u({platformHostedOnly:!0}),l=s(),d=c(),{data:h,isLoading:_}=t({...o({query:{hosting:`local`}}),enabled:n===`full`&&l}),v=h?.results??[];return n===`gated`?(0,m.jsx)(e,{replace:!0,to:a.settings.general}):n===`disabled`?(0,m.jsx)(`div`,{className:`space-y-4`,children:(0,m.jsx)(f,{children:`Log in to the Vellum platform to manage self-hosted assistants.`})}):d?(0,m.jsx)(`div`,{className:`space-y-4`,children:(0,m.jsxs)(`div`,{className:`flex items-center gap-2 py-6 text-body-medium-lighter text-[var(--content-secondary)]`,children:[(0,m.jsx)(i,{className:`h-4 w-4 animate-spin`}),`Loading devices…`]})}):l?(0,m.jsx)(`div`,{className:`space-y-4`,children:(0,m.jsx)(p,{title:`Self-Hosted Assistants`,subtitle:`Self-hosted assistants registered with your Vellum account. Registration lets these assistants use Vellum managed services — inference, web search, integrations — so that you don't have to bring your own API keys.`,children:_?(0,m.jsxs)(`div`,{className:`flex items-center gap-2 text-body-medium-lighter text-[var(--content-tertiary)]`,children:[(0,m.jsx)(i,{className:`h-4 w-4 animate-spin`}),`Loading devices...`]}):v.length===0?(0,m.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--content-tertiary)]`,children:`No self-hosted assistants registered.`}):(0,m.jsx)(`div`,{className:`space-y-2`,children:v.map(e=>(0,m.jsx)(g,{assistant:e},e.id))})})}):(0,m.jsx)(`div`,{className:`space-y-4`,children:(0,m.jsx)(r,{tone:`warning`,children:`Self-hosted assistant management isn't available for the current assistant state.`})})}export{_ as DevicesPage};
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{t as n}from"./jsx-runtime-CVSDxk6A.js";import{t as r}from"./loader-circle-YAV9sMh_.js";import{t as i}from"./triangle-alert-CoIDviBm.js";import{Yi as a,dn as o,fn as s,ln as c,ta as l,un as u}from"./index-Chr1kHBM.js";var d=e(t(),1),f=n();function p(){let[e,t]=(0,d.useState)(null),n=(0,d.useRef)(null),r=(0,d.useRef)(!1);if((0,d.useEffect)(()=>{let e=s(t);return c().then(e=>{e&&t(t=>t??e)}),e},[]),(0,d.useEffect)(()=>()=>{o(!1)},[]),(0,d.useEffect)(()=>{e?.kind===`recording`||!r.current||(r.current=!1,o(!1))},[e?.kind]),!e)return null;let i=e.kind===`recording`?e.transcription.trim():``,a=e.kind===`recording`?e.audioLevel??0:0,l=e=>{r.current!==e&&(r.current=e,o(e))};return(0,f.jsx)(`div`,{className:`flex h-screen w-screen items-start justify-center bg-transparent p-4`,onMouseMove:t=>{if(e.kind!==`recording`){l(!1);return}let r=n.current;if(!r){l(!1);return}let i=r.getBoundingClientRect();l(t.clientX>=i.left&&t.clientX<=i.right&&t.clientY>=i.top&&t.clientY<=i.bottom)},onMouseLeave:()=>l(!1),children:(0,f.jsxs)(`div`,{className:`flex w-[min(28rem,calc(100vw-2rem))] flex-col gap-1 rounded-xl border border-[var(--border-default)] bg-[var(--surface-base)] px-4 py-2.5 shadow-lg`,children:[(0,f.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[(0,f.jsx)(_,{state:e}),(0,f.jsx)(`span`,{className:`truncate text-[11px] font-medium text-[var(--content-secondary)]`,children:g(e)}),e.kind===`recording`&&(0,f.jsx)(m,{level:a,stopButtonRef:n,onInteractiveChange:l,onStop:()=>{u(),l(!1)}})]}),i&&(0,f.jsx)(`div`,{className:`flex max-h-7 flex-col justify-end overflow-hidden`,children:(0,f.jsx)(`p`,{className:`break-words text-[10px] leading-snug text-[var(--content-tertiary)]`,children:i})})]})})}function m({level:e,stopButtonRef:t,onInteractiveChange:n,onStop:r}){return(0,f.jsxs)(`div`,{className:`ml-auto flex shrink-0 items-center gap-2`,children:[(0,f.jsx)(h,{level:e}),(0,f.jsx)(`button`,{ref:t,type:`button`,className:`flex size-5 items-center justify-center rounded-full text-[var(--content-secondary)] transition-colors hover:bg-[var(--surface-overlay)] hover:text-[var(--system-negative-strong)] focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-[var(--system-negative-strong)]`,"aria-label":`Stop recording`,title:`Stop recording`,onMouseEnter:()=>n(!0),onMouseLeave:()=>n(!1),onFocus:()=>n(!0),onBlur:()=>n(!1),onClick:r,children:(0,f.jsx)(a,{className:`size-4`,strokeWidth:2,"aria-hidden":!0})})]})}function h({level:e}){let t=Math.max(0,Math.min(1,e));return(0,f.jsx)(`div`,{className:`flex h-4 w-16 shrink-0 items-end gap-0.5`,"aria-hidden":!0,children:[.16,.32,.48,.64,.8,.96].map((e,n)=>(0,f.jsx)(`span`,{className:`w-1 rounded-full bg-[var(--system-negative-strong)] transition-[height,opacity] duration-75`,style:{height:`${6+n*1.5}px`,opacity:t>=e?1:.22}},e))})}function g(e){switch(e.kind){case`recording`:return`Recording…`;case`processing`:return`Processing…`;case`done`:return`Done`;case`error`:return e.message}}function _({state:e}){switch(e.kind){case`recording`:return(0,f.jsx)(`span`,{className:`size-2 shrink-0 rounded-full bg-[var(--system-negative-strong)]`,"aria-hidden":!0});case`processing`:return(0,f.jsx)(r,{className:`size-4 shrink-0 animate-spin text-[var(--content-secondary)]`,"aria-hidden":!0});case`done`:return(0,f.jsx)(l,{className:`size-4 shrink-0 text-[var(--system-positive-strong)]`,"aria-hidden":!0});case`error`:return(0,f.jsx)(i,{className:`size-4 shrink-0 text-[var(--system-negative-strong)]`,"aria-hidden":!0})}}export{p as DictationOverlayPage};
@@ -1,4 +1,4 @@
1
- import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{C as n,E as r,T as i,o as a,s as o,y as s}from"./button-D7s2Q_uG.js";import{t as c}from"./jsx-runtime-CVSDxk6A.js";import{a as l,o as u}from"./cn-DvW5mxZR.js";import{n as d,t as f}from"./dist-D7Zr-ONk.js";import{a as p,i as m,n as h,r as ee,t as g}from"./Combination-DmnhUZru.js";var _=e(t(),1),v=c();function y(e){let t=b(e),n=_.forwardRef((e,n)=>{let{children:r,...i}=e,a=_.Children.toArray(r),o=a.find(te);if(o){let e=o.props.children,r=a.map(t=>t===o?_.Children.count(e)>1?_.Children.only(null):_.isValidElement(e)?e.props.children:null:t);return(0,v.jsx)(t,{...i,ref:n,children:_.isValidElement(e)?_.cloneElement(e,void 0,r):null})}return(0,v.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}function b(e){let t=_.forwardRef((e,t)=>{let{children:n,...r}=e;if(_.isValidElement(n)){let e=C(n),i=S(r,n.props);return n.type!==_.Fragment&&(i.ref=t?l(t,e):e),_.cloneElement(n,i)}return _.Children.count(n)>1?_.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var x=Symbol(`radix.slottable`);function te(e){return _.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===x}function S(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function C(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var w=`Dialog`,[T,ne]=r(w),[E,D]=T(w),O=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:c=!0}=e,l=_.useRef(null),u=_.useRef(null),[d,f]=a({prop:r,defaultProp:i??!1,onChange:o,caller:w});return(0,v.jsx)(E,{scope:t,triggerRef:l,contentRef:u,contentId:s(),titleId:s(),descriptionId:s(),open:d,onOpenChange:f,onOpenToggle:_.useCallback(()=>f(e=>!e),[f]),modal:c,children:n})};O.displayName=w;var k=`DialogTrigger`,A=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(k,r),o=u(t,a.triggerRef);return(0,v.jsx)(n.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":a.open,"aria-controls":a.contentId,"data-state":X(a.open),...i,ref:o,onClick:d(e.onClick,a.onOpenToggle)})});A.displayName=k;var j=`DialogPortal`,[M,N]=T(j,{forceMount:void 0}),P=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=D(j,t);return(0,v.jsx)(M,{scope:t,forceMount:n,children:_.Children.map(r,e=>(0,v.jsx)(f,{present:n||a.open,children:(0,v.jsx)(o,{asChild:!0,container:i,children:e})}))})};P.displayName=j;var F=`DialogOverlay`,I=_.forwardRef((e,t)=>{let n=N(F,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=D(F,e.__scopeDialog);return a.modal?(0,v.jsx)(f,{present:r||a.open,children:(0,v.jsx)(R,{...i,ref:t})}):null});I.displayName=F;var L=y(`DialogOverlay.RemoveScroll`),R=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(F,r);return(0,v.jsx)(g,{as:L,allowPinchZoom:!0,shards:[a.contentRef],children:(0,v.jsx)(n.div,{"data-state":X(a.open),...i,ref:t,style:{pointerEvents:`auto`,...i.style}})})}),z=`DialogContent`,B=_.forwardRef((e,t)=>{let n=N(z,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=D(z,e.__scopeDialog);return(0,v.jsx)(f,{present:r||a.open,children:a.modal?(0,v.jsx)(V,{...i,ref:t}):(0,v.jsx)(H,{...i,ref:t})})});B.displayName=z;var V=_.forwardRef((e,t)=>{let n=D(z,e.__scopeDialog),r=_.useRef(null),i=u(t,n.contentRef,r);return _.useEffect(()=>{let e=r.current;if(e)return h(e)},[]),(0,v.jsx)(U,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:d(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:d(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:d(e.onFocusOutside,e=>e.preventDefault())})}),H=_.forwardRef((e,t)=>{let n=D(z,e.__scopeDialog),r=_.useRef(!1),i=_.useRef(!1);return(0,v.jsx)(U,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),U=_.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=D(z,n),c=_.useRef(null),l=u(t,c);return m(),(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)(ee,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,v.jsx)(p,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":X(s.open),...o,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)(ie,{titleId:s.titleId}),(0,v.jsx)(ae,{contentRef:c,descriptionId:s.descriptionId})]})]})}),W=`DialogTitle`,G=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(W,r);return(0,v.jsx)(n.h2,{id:a.titleId,...i,ref:t})});G.displayName=W;var K=`DialogDescription`,q=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(K,r);return(0,v.jsx)(n.p,{id:a.descriptionId,...i,ref:t})});q.displayName=K;var J=`DialogClose`,Y=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(J,r);return(0,v.jsx)(n.button,{type:`button`,...i,ref:t,onClick:d(e.onClick,()=>a.onOpenChange(!1))})});Y.displayName=J;function X(e){return e?`open`:`closed`}var Z=`DialogTitleWarning`,[re,Q]=i(Z,{contentName:z,titleName:W,docsSlug:`dialog`}),ie=({titleId:e})=>{let t=Q(Z),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{C as n,E as r,T as i,o as a,s as o,y as s}from"./button-D7s2Q_uG.js";import{t as c}from"./jsx-runtime-CVSDxk6A.js";import{a as l,o as u}from"./cn-DvW5mxZR.js";import{n as d,t as f}from"./dist-BQHdyjQ3.js";import{a as p,i as m,n as h,r as ee,t as g}from"./Combination-CDqVzelh.js";var _=e(t(),1),v=c();function y(e){let t=b(e),n=_.forwardRef((e,n)=>{let{children:r,...i}=e,a=_.Children.toArray(r),o=a.find(te);if(o){let e=o.props.children,r=a.map(t=>t===o?_.Children.count(e)>1?_.Children.only(null):_.isValidElement(e)?e.props.children:null:t);return(0,v.jsx)(t,{...i,ref:n,children:_.isValidElement(e)?_.cloneElement(e,void 0,r):null})}return(0,v.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}function b(e){let t=_.forwardRef((e,t)=>{let{children:n,...r}=e;if(_.isValidElement(n)){let e=C(n),i=S(r,n.props);return n.type!==_.Fragment&&(i.ref=t?l(t,e):e),_.cloneElement(n,i)}return _.Children.count(n)>1?_.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var x=Symbol(`radix.slottable`);function te(e){return _.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===x}function S(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function C(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var w=`Dialog`,[T,ne]=r(w),[E,D]=T(w),O=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:c=!0}=e,l=_.useRef(null),u=_.useRef(null),[d,f]=a({prop:r,defaultProp:i??!1,onChange:o,caller:w});return(0,v.jsx)(E,{scope:t,triggerRef:l,contentRef:u,contentId:s(),titleId:s(),descriptionId:s(),open:d,onOpenChange:f,onOpenToggle:_.useCallback(()=>f(e=>!e),[f]),modal:c,children:n})};O.displayName=w;var k=`DialogTrigger`,A=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(k,r),o=u(t,a.triggerRef);return(0,v.jsx)(n.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":a.open,"aria-controls":a.contentId,"data-state":X(a.open),...i,ref:o,onClick:d(e.onClick,a.onOpenToggle)})});A.displayName=k;var j=`DialogPortal`,[M,N]=T(j,{forceMount:void 0}),P=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=D(j,t);return(0,v.jsx)(M,{scope:t,forceMount:n,children:_.Children.map(r,e=>(0,v.jsx)(f,{present:n||a.open,children:(0,v.jsx)(o,{asChild:!0,container:i,children:e})}))})};P.displayName=j;var F=`DialogOverlay`,I=_.forwardRef((e,t)=>{let n=N(F,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=D(F,e.__scopeDialog);return a.modal?(0,v.jsx)(f,{present:r||a.open,children:(0,v.jsx)(R,{...i,ref:t})}):null});I.displayName=F;var L=y(`DialogOverlay.RemoveScroll`),R=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(F,r);return(0,v.jsx)(g,{as:L,allowPinchZoom:!0,shards:[a.contentRef],children:(0,v.jsx)(n.div,{"data-state":X(a.open),...i,ref:t,style:{pointerEvents:`auto`,...i.style}})})}),z=`DialogContent`,B=_.forwardRef((e,t)=>{let n=N(z,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=D(z,e.__scopeDialog);return(0,v.jsx)(f,{present:r||a.open,children:a.modal?(0,v.jsx)(V,{...i,ref:t}):(0,v.jsx)(H,{...i,ref:t})})});B.displayName=z;var V=_.forwardRef((e,t)=>{let n=D(z,e.__scopeDialog),r=_.useRef(null),i=u(t,n.contentRef,r);return _.useEffect(()=>{let e=r.current;if(e)return h(e)},[]),(0,v.jsx)(U,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:d(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:d(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:d(e.onFocusOutside,e=>e.preventDefault())})}),H=_.forwardRef((e,t)=>{let n=D(z,e.__scopeDialog),r=_.useRef(!1),i=_.useRef(!1);return(0,v.jsx)(U,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),U=_.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=D(z,n),c=_.useRef(null),l=u(t,c);return m(),(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)(ee,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,v.jsx)(p,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":X(s.open),...o,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)(ie,{titleId:s.titleId}),(0,v.jsx)(ae,{contentRef:c,descriptionId:s.descriptionId})]})]})}),W=`DialogTitle`,G=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(W,r);return(0,v.jsx)(n.h2,{id:a.titleId,...i,ref:t})});G.displayName=W;var K=`DialogDescription`,q=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(K,r);return(0,v.jsx)(n.p,{id:a.descriptionId,...i,ref:t})});q.displayName=K;var J=`DialogClose`,Y=_.forwardRef((e,t)=>{let{__scopeDialog:r,...i}=e,a=D(J,r);return(0,v.jsx)(n.button,{type:`button`,...i,ref:t,onClick:d(e.onClick,()=>a.onOpenChange(!1))})});Y.displayName=J;function X(e){return e?`open`:`closed`}var Z=`DialogTitleWarning`,[re,Q]=i(Z,{contentName:z,titleName:W,docsSlug:`dialog`}),ie=({titleId:e})=>{let t=Q(Z),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2
2
 
3
3
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
4
4
 
@@ -1 +1 @@
1
- import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{d as n,p as r}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{t as i}from"./jsx-runtime-CVSDxk6A.js";import{t as a}from"./typography-BscuIPxA.js";import"./src-D6Nu2Lol.js";import{n as o}from"./resolved-assistants-store-DMuRxkZC.js";import{t as s}from"./loader-circle-CTs38Ovl.js";import{dt as c,ft as l,ut as u}from"./sdk.gen-Bew9wO5C.js";import{a as d}from"./routes-BKwsRssF.js";import{t as f}from"./use-bus-subscription-RUbeQDfy.js";import{n as p}from"./viewer-store-CInCucV8.js";import{r as m,t as h}from"./edit-chat-session-B1tanC3Z.js";import{Y as g}from"./index-BiN-6kWM.js";var _=e(t(),1);function v({surfaceId:e,enabled:t,onCommentsChanged:n}){let r=(0,_.useRef)(n);return(0,_.useLayoutEffect)(()=>{r.current=n},[n]),(0,_.useCallback)(n=>{if(!t)return;let i=n.message;switch(i.type){case`document_comment_created`:case`document_comment_resolved`:case`document_comment_reopened`:case`document_comment_deleted`:i.surfaceId===e&&r.current();break;default:break}},[e,t])}var y=i();function b(){let{surfaceId:e}=r(),t=n(),i=o.use.activeAssistantId(),[b,x]=(0,_.useState)(null),[S,C]=(0,_.useState)(!0),[w,T]=(0,_.useState)(null),E=(0,_.useRef)(null);(0,_.useEffect)(()=>{if(!e){T(`No document ID provided.`),C(!1);return}if(!i)return;let t=!1;return(async()=>{try{let{data:n}=await c({path:{assistant_id:i,id:e},throwOnError:!0});if(t)return;x(n)}catch{t||T(`Failed to load document.`)}finally{t||C(!1)}})(),()=>{t=!0}},[e,i]);let D=(0,_.useCallback)(()=>{E.current?.refreshComments()},[]);f(`sse.event`,v({surfaceId:e??``,enabled:!!e,onCommentsChanged:D}));let O=(0,_.useCallback)(()=>{t(-1)},[t]),k=(0,_.useCallback)(async()=>{if(!b||!i||!e)return;let n=b.conversationId||h(i,e)||(typeof globalThis.crypto?.randomUUID==`function`?globalThis.crypto.randomUUID():`draft-${Date.now()}-${Math.random().toString(16).slice(2)}`);if(m(i,e,n),n!==b.conversationId)try{await u({path:{assistant_id:i,id:e},body:{conversationId:n},throwOnError:!0})}catch{}p.getState().openDocument(),p.getState().setLoadedDocument({surfaceId:b.surfaceId,conversationId:n,documentName:b.title,content:b.content});let r=`Please review and address my comments on "${b.title}".`;t(`${d.conversation(n)}?prompt=${encodeURIComponent(r)}`)},[b,i,e,t]),A=(0,_.useCallback)(async()=>{if(!b||!i)return;let{data:e,response:t}=await l({path:{assistant_id:i,id:b.surfaceId},throwOnError:!1,parseAs:`blob`});if(!t?.ok||!e)return;let n=URL.createObjectURL(e);Object.assign(document.createElement(`a`),{href:n,download:`${b.title||`document`}.pdf`}).click(),URL.revokeObjectURL(n)},[b,i]);return S?(0,y.jsx)(`div`,{className:`flex h-full items-center justify-center`,children:(0,y.jsx)(s,{size:24,className:`animate-spin`,style:{color:`var(--content-tertiary)`}})}):w||!b||!i?(0,y.jsx)(`div`,{className:`flex h-full items-center justify-center`,children:(0,y.jsx)(a,{variant:`body-small-default`,className:`text-[var(--content-tertiary)]`,children:w??`Document not found.`})}):(0,y.jsx)(g,{surfaceId:b.surfaceId,assistantId:i,conversationId:b.conversationId,documentName:b.title,content:b.content,onClose:O,onExport:A,onSubmitFeedback:k,handleRef:E})}export{b as DocumentViewerPage};
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{d as n,p as r}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{t as i}from"./jsx-runtime-CVSDxk6A.js";import{t as a}from"./typography-BscuIPxA.js";import"./src-BJj2O5XB.js";import{n as o}from"./resolved-assistants-store-IMxY1_w9.js";import{t as s}from"./loader-circle-YAV9sMh_.js";import{dt as c,ft as l,ut as u}from"./sdk.gen-W0KlW-sG.js";import{a as d}from"./routes-BLyehs4B.js";import{t as f}from"./use-bus-subscription-D-1qIPnj.js";import{n as p}from"./viewer-store-CTNS5BCs.js";import{r as m,t as h}from"./edit-chat-session-DXSCprPw.js";import{$ as g}from"./index-Chr1kHBM.js";var _=e(t(),1);function v({surfaceId:e,enabled:t,onCommentsChanged:n}){let r=(0,_.useRef)(n);return(0,_.useLayoutEffect)(()=>{r.current=n},[n]),(0,_.useCallback)(n=>{if(!t)return;let i=n.message;switch(i.type){case`document_comment_created`:case`document_comment_resolved`:case`document_comment_reopened`:case`document_comment_deleted`:i.surfaceId===e&&r.current();break;default:break}},[e,t])}var y=i();function b(){let{surfaceId:e}=r(),t=n(),i=o.use.activeAssistantId(),[b,x]=(0,_.useState)(null),[S,C]=(0,_.useState)(!0),[w,T]=(0,_.useState)(null),E=(0,_.useRef)(null);(0,_.useEffect)(()=>{if(!e){T(`No document ID provided.`),C(!1);return}if(!i)return;let t=!1;return(async()=>{try{let{data:n}=await c({path:{assistant_id:i,id:e},throwOnError:!0});if(t)return;x(n)}catch{t||T(`Failed to load document.`)}finally{t||C(!1)}})(),()=>{t=!0}},[e,i]);let D=(0,_.useCallback)(()=>{E.current?.refreshComments()},[]);f(`sse.event`,v({surfaceId:e??``,enabled:!!e,onCommentsChanged:D}));let O=(0,_.useCallback)(()=>{t(-1)},[t]),k=(0,_.useCallback)(async()=>{if(!b||!i||!e)return;let n=b.conversationId||h(i,e)||(typeof globalThis.crypto?.randomUUID==`function`?globalThis.crypto.randomUUID():`draft-${Date.now()}-${Math.random().toString(16).slice(2)}`);if(m(i,e,n),n!==b.conversationId)try{await u({path:{assistant_id:i,id:e},body:{conversationId:n},throwOnError:!0})}catch{}p.getState().openDocument(),p.getState().setLoadedDocument({surfaceId:b.surfaceId,conversationId:n,documentName:b.title,content:b.content});let r=`Please review and address my comments on "${b.title}".`;t(`${d.conversation(n)}?prompt=${encodeURIComponent(r)}`)},[b,i,e,t]),A=(0,_.useCallback)(async()=>{if(!b||!i)return;let{data:e,response:t}=await l({path:{assistant_id:i,id:b.surfaceId},throwOnError:!1,parseAs:`blob`});if(!t?.ok||!e)return;let n=URL.createObjectURL(e);Object.assign(document.createElement(`a`),{href:n,download:`${b.title||`document`}.pdf`}).click(),URL.revokeObjectURL(n)},[b,i]);return S?(0,y.jsx)(`div`,{className:`flex h-full items-center justify-center`,children:(0,y.jsx)(s,{size:24,className:`animate-spin`,style:{color:`var(--content-tertiary)`}})}):w||!b||!i?(0,y.jsx)(`div`,{className:`flex h-full items-center justify-center`,children:(0,y.jsx)(a,{variant:`body-small-default`,className:`text-[var(--content-tertiary)]`,children:w??`Document not found.`})}):(0,y.jsx)(g,{surfaceId:b.surfaceId,assistantId:i,conversationId:b.conversationId,documentName:b.title,content:b.content,onClose:O,onExport:A,onSubmitFeedback:k,handleRef:E})}export{b as DocumentViewerPage};
@@ -1 +1 @@
1
- import{t as e}from"./createLucideIcon-DIlBzeWM.js";var t=e(`dollar-sign`,[[`line`,{x1:`12`,x2:`12`,y1:`2`,y2:`22`,key:`7eqyqh`}],[`path`,{d:`M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6`,key:`1b0p4s`}]]);export{t};
1
+ import{t as e}from"./createLucideIcon-KBgJOpms.js";var t=e(`dollar-sign`,[[`line`,{x1:`12`,x2:`12`,y1:`2`,y2:`22`,key:`7eqyqh`}],[`path`,{d:`M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6`,key:`1b0p4s`}]]);export{t};
@@ -1 +1 @@
1
- import{t as e}from"./jsx-runtime-CVSDxk6A.js";import{t}from"./createLucideIcon-DIlBzeWM.js";var n=t(`crown`,[[`path`,{d:`M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z`,key:`1vdc57`}],[`path`,{d:`M5 21h14`,key:`11awu3`}]]),r=e();function i({subdomain:e,onSubdomainChange:t,domainSuffix:n,subdomainPlaceholder:i=`my-assistant`,disabled:a,autoFocus:o,prefix:s,error:c,locked:l,lockedMessage:u}){return(0,r.jsxs)(`div`,{children:[(0,r.jsxs)(`div`,{className:`flex h-9 w-full items-center rounded-md border bg-[var(--field-bg)] text-body-medium-lighter transition-[border-color] duration-150 ${c?`border-[var(--system-negative-strong)]`:`border-[var(--field-border)] focus-within:border-[var(--border-active)]`}`,children:[s,(0,r.jsx)(`input`,{value:e,onChange:e=>t(e.target.value.toLowerCase().trim()),disabled:a||l,readOnly:l,autoFocus:o,placeholder:i,"aria-label":`Subdomain`,"aria-invalid":!!c,className:`h-full min-w-0 flex-1 bg-transparent ${s?`pl-1.5`:`pl-3`} pr-1 text-[var(--content-default)] placeholder:text-[var(--content-tertiary)] outline-none disabled:cursor-not-allowed disabled:opacity-60`}),(0,r.jsxs)(`span`,{className:`shrink-0 pr-3 font-mono text-[var(--content-secondary)]`,children:[`.`,n]})]}),c&&(0,r.jsx)(`p`,{className:`mt-1.5 text-body-small-default text-[var(--system-negative-strong)]`,children:c}),l&&u&&(0,r.jsx)(`p`,{className:`mt-1.5 text-body-small-default text-[var(--content-tertiary)]`,children:u})]})}export{n,i as t};
1
+ import{t as e}from"./jsx-runtime-CVSDxk6A.js";import{t}from"./createLucideIcon-KBgJOpms.js";var n=t(`crown`,[[`path`,{d:`M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z`,key:`1vdc57`}],[`path`,{d:`M5 21h14`,key:`11awu3`}]]),r=e();function i({subdomain:e,onSubdomainChange:t,domainSuffix:n,subdomainPlaceholder:i=`my-assistant`,disabled:a,autoFocus:o,prefix:s,error:c,locked:l,lockedMessage:u}){return(0,r.jsxs)(`div`,{children:[(0,r.jsxs)(`div`,{className:`flex h-9 w-full items-center rounded-md border bg-[var(--field-bg)] text-body-medium-lighter transition-[border-color] duration-150 ${c?`border-[var(--system-negative-strong)]`:`border-[var(--field-border)] focus-within:border-[var(--border-active)]`}`,children:[s,(0,r.jsx)(`input`,{value:e,onChange:e=>t(e.target.value.toLowerCase().trim()),disabled:a||l,readOnly:l,autoFocus:o,placeholder:i,"aria-label":`Subdomain`,"aria-invalid":!!c,className:`h-full min-w-0 flex-1 bg-transparent ${s?`pl-1.5`:`pl-3`} pr-1 text-[var(--content-default)] placeholder:text-[var(--content-tertiary)] outline-none disabled:cursor-not-allowed disabled:opacity-60`}),(0,r.jsxs)(`span`,{className:`shrink-0 pr-3 font-mono text-[var(--content-secondary)]`,children:[`.`,n]})]}),c&&(0,r.jsx)(`p`,{className:`mt-1.5 text-body-small-default text-[var(--system-negative-strong)]`,children:c}),l&&u&&(0,r.jsx)(`p`,{className:`mt-1.5 text-body-small-default text-[var(--content-tertiary)]`,children:u})]})}export{n,i as t};
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{t as n}from"./button-D7s2Q_uG.js";import{t as r}from"./useQuery-B45lW1Kk.js";import{t as i}from"./jsx-runtime-CVSDxk6A.js";import"./src-BJj2O5XB.js";import{t as a}from"./input-Ch7OC6ME.js";import{t as o}from"./modal-CHuPOsJJ.js";import{t as s}from"./createLucideIcon-KBgJOpms.js";import{t as c}from"./arrow-left-CEu7Dsda.js";import{t as l}from"./credit-card-CcU-1-nT.js";import{t as u}from"./loader-circle-YAV9sMh_.js";import{ht as d}from"./react-query.gen-CRARj4mG.js";import{Ei as f,Or as p,Ri as m,ta as h}from"./index-Chr1kHBM.js";var g=s(`share-2`,[[`circle`,{cx:`18`,cy:`5`,r:`3`,key:`gq8acd`}],[`circle`,{cx:`6`,cy:`12`,r:`3`,key:`w7nqdw`}],[`circle`,{cx:`18`,cy:`19`,r:`3`,key:`1xt0gg`}],[`line`,{x1:`8.59`,x2:`15.42`,y1:`13.51`,y2:`17.49`,key:`47mynk`}],[`line`,{x1:`15.41`,x2:`8.59`,y1:`6.51`,y2:`10.49`,key:`1n3mei`}]]),_=e(t(),1),v=i();function y(e){return e.replace(/\.00$/,``)}function b(e,t,n){let r=y(n),i=y(e),a=y(t);return i===a?`Share Vellum with friends — you'll each earn ${i} credits when they sign up, up to ${r} total.`:`Share Vellum with friends — you'll earn ${i} credits and they'll get ${a} when they sign up, up to ${r} total.`}function x({open:e,onClose:t}){return(0,v.jsx)(o.Root,{open:e,onOpenChange:e=>{e||t()},children:e?(0,v.jsx)(S,{}):null})}function S(){let[e,t]=(0,_.useState)(!1),[i,s]=(0,_.useState)(!1),{data:x,isLoading:S,isError:E,refetch:D,isFetching:O}=r(d()),k=(0,_.useCallback)(e=>{navigator.clipboard.writeText(e).then(()=>{t(!0),setTimeout(()=>t(!1),2e3)})},[]),A=x?b(x.referrer_credit_amount,x.credit_amount,x.earning_cap):`Refer friends to earn free credits.`,j=x?y(x.earning_cap):``,M=i?`Referral Program Terms`:`Earn free credits`;return(0,v.jsxs)(o.Content,{size:`sm`,children:[(0,v.jsx)(o.Header,{children:(0,v.jsxs)(`div`,{className:`flex min-w-0 items-start gap-2`,children:[i&&(0,v.jsx)(n,{variant:`ghost`,size:`compact`,iconOnly:(0,v.jsx)(c,{}),onClick:()=>s(!1),"aria-label":`Back`,className:`mt-0.5`,tintColor:`var(--content-secondary)`}),(0,v.jsxs)(`div`,{className:`min-w-0`,children:[(0,v.jsx)(o.Title,{children:M}),!i&&(0,v.jsx)(o.Description,{children:A})]})]})}),(0,v.jsx)(o.Body,{children:i&&x?(0,v.jsx)(T,{cap:j}):S?(0,v.jsxs)(`div`,{className:`flex items-center gap-2 py-2 text-body-medium-lighter`,style:{color:`var(--content-tertiary)`},children:[(0,v.jsx)(u,{className:`h-4 w-4 animate-spin`}),`Loading referral information…`]}):E||!x?(0,v.jsxs)(`div`,{className:`space-y-3`,children:[(0,v.jsx)(`p`,{className:`!m-0 text-body-medium-lighter`,style:{color:`var(--content-secondary)`},children:`Failed to load referral information.`}),(0,v.jsx)(n,{variant:`outlined`,onClick:()=>void D(),disabled:O,children:O?`Retrying…`:`Try Again`})]}):(0,v.jsxs)(`div`,{className:`space-y-4`,children:[(0,v.jsxs)(`div`,{className:`space-y-2`,children:[(0,v.jsx)(C,{icon:(0,v.jsx)(g,{className:`h-4 w-4`}),label:`Share your invite link`}),(0,v.jsx)(C,{icon:(0,v.jsx)(p,{className:`h-4 w-4`}),label:`They sign up`}),(0,v.jsx)(C,{icon:(0,v.jsx)(f,{className:`h-4 w-4`}),label:`You earn credits`})]}),(0,v.jsx)(`div`,{style:{borderTop:`1px solid var(--border-base)`}}),(0,v.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,v.jsx)(a,{type:`text`,readOnly:!0,value:x.referral_url,fullWidth:!0,wrapperClassName:`flex-1`,className:`font-mono`,onFocus:e=>e.currentTarget.select()}),(0,v.jsx)(n,{variant:`outlined`,iconOnly:e?(0,v.jsx)(h,{}):(0,v.jsx)(m,{}),onClick:()=>k(x.referral_url),"aria-label":`Copy referral link`,className:`h-9 w-9`})]}),(0,v.jsx)(`div`,{style:{borderTop:`1px solid var(--border-base)`}}),(0,v.jsxs)(`div`,{className:`flex items-center justify-between gap-4`,children:[(0,v.jsx)(w,{icon:(0,v.jsx)(p,{className:`h-3.5 w-3.5`}),value:String(x.referred_count),label:`Friends Referred`}),(0,v.jsx)(w,{icon:(0,v.jsx)(l,{className:`h-3.5 w-3.5`}),value:y(x.total_earned),label:`Credits Earned`})]}),(0,v.jsx)(`div`,{style:{borderTop:`1px solid var(--border-base)`}}),(0,v.jsx)(n,{variant:`ghost`,size:`compact`,onClick:()=>s(!0),fullWidth:!0,className:`text-body-small-default`,tintColor:`var(--content-tertiary)`,children:`View Terms and Conditions`})]})})]})}function C({icon:e,label:t}){return(0,v.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,v.jsx)(`div`,{className:`flex h-7 w-7 shrink-0 items-center justify-center rounded-md`,style:{background:`var(--surface-base)`,color:`var(--content-secondary)`},children:e}),(0,v.jsx)(`span`,{className:`text-body-medium-default`,style:{color:`var(--content-default)`},children:t})]})}function w({icon:e,value:t,label:n}){return(0,v.jsxs)(`div`,{className:`flex items-center gap-1.5 text-body-medium-lighter`,children:[(0,v.jsx)(`span`,{style:{color:`var(--content-tertiary)`},children:e}),(0,v.jsx)(`span`,{className:`text-body-medium-default`,style:{color:`var(--content-default)`},children:t}),(0,v.jsx)(`span`,{style:{color:`var(--content-tertiary)`},children:n})]})}function T({cap:e}){return(0,v.jsx)(`ul`,{className:`!m-0 !list-none space-y-2 !p-0`,children:[`This promotion is available to new users who sign up through your referral link only.`,`Rewards are earned once your invitee completes the creation of their Vellum account.`,`You may earn up to ${e} free credits through the Referral Program. We may change this limit at any time.`,`We do not grant credits for disposable or high-risk email accounts.`,`Each new user can generate only one (1) reward. No stacking or loophole hunting.`,`Please avoid spamming or misusing your referral link. Our systems actively monitor referral engagement.`,`If we detect suspicious or non-compliant activity, we reserve the right to withhold rewards or deactivate your referral link.`,`We may update, pause, or discontinue this program at any time.`].map(e=>(0,v.jsxs)(`li`,{className:`flex items-start gap-2 text-body-medium-lighter`,style:{color:`var(--content-secondary)`},children:[(0,v.jsx)(`span`,{"aria-hidden":`true`,className:`mt-0.5`,children:`•`}),(0,v.jsx)(`span`,{children:e})]},e))})}export{x as EarnCreditsModal};
@@ -0,0 +1 @@
1
+ import{r as e,t}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{t as n}from"./useQuery-B45lW1Kk.js";import{t as r}from"./jsx-runtime-CVSDxk6A.js";import"./src-BJj2O5XB.js";import{t as i}from"./tag-CE_o2aao.js";import{t as a}from"./loader-circle-YAV9sMh_.js";import{t as o}from"./triangle-alert-CoIDviBm.js";import{a as s}from"./routes-BLyehs4B.js";import{_ as c,h as l,p as u}from"./react-query.gen-CRARj4mG.js";import{Ki as d,Si as f,Wr as p,qt as m,x as h}from"./index-Chr1kHBM.js";import{t as g}from"./use-active-assistant-id-DOx36WGk.js";var _=r();function v(e){return new Date(e).toLocaleString(void 0,{month:`short`,day:`numeric`,hour:`2-digit`,minute:`2-digit`})}function y({title:e,children:t}){return(0,_.jsxs)(`div`,{className:`space-y-3`,children:[(0,_.jsx)(`h2`,{className:`text-title-small`,style:{color:`var(--content-default)`},children:e}),t]})}function b({tone:e=`info`,children:t}){let n=e===`error`;return(0,_.jsx)(`div`,{className:`rounded-md border px-4 py-3 text-body-medium-lighter`,style:{background:n?`var(--surface-negative-subtle, var(--surface-lift))`:`var(--surface-lift)`,borderColor:n?`var(--border-negative, var(--border-base))`:`var(--border-base)`,color:n?`var(--content-negative, var(--content-default))`:`var(--content-default)`},children:(0,_.jsxs)(`div`,{className:`flex items-start gap-2`,children:[n&&(0,_.jsx)(o,{className:`mt-0.5 h-4 w-4 shrink-0`,"aria-hidden":`true`}),(0,_.jsx)(`div`,{className:`flex-1`,children:t})]})})}function x({message:e,onRetry:t,retrying:n}){return(0,_.jsx)(b,{tone:`error`,children:(0,_.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,_.jsx)(`span`,{children:e}),(0,_.jsx)(`button`,{type:`button`,onClick:t,disabled:n,className:`text-body-small-default underline disabled:opacity-50`,style:{color:`var(--content-default)`},children:n?`Retrying…`:`Retry`})]})})}function S({label:e,value:t,sub:n}){return(0,_.jsxs)(`div`,{className:`rounded-xl border p-3`,style:{background:`var(--surface-lift)`,borderColor:`var(--border-base)`},children:[(0,_.jsx)(`p`,{className:`text-body-small-default`,style:{color:`var(--content-tertiary)`},children:e}),(0,_.jsx)(`p`,{className:`mt-1 text-title-large tabular-nums`,style:{color:`var(--content-default)`},children:t??`—`}),n&&(0,_.jsx)(`p`,{className:`text-body-small-default`,style:{color:`var(--content-disabled)`},children:n})]})}function C({email:e}){let t=e.direction===`inbound`;return(0,_.jsx)(`div`,{className:`rounded-xl border p-4`,style:{background:`var(--surface-lift)`,borderColor:`var(--border-base)`},children:(0,_.jsxs)(`div`,{className:`flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between`,children:[(0,_.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-1`,children:[(0,_.jsxs)(`div`,{className:`flex flex-wrap items-center gap-2`,children:[(0,_.jsx)(i,{tone:t?`positive`:`neutral`,leftIcon:t?(0,_.jsx)(f,{}):(0,_.jsx)(p,{}),children:t?`Inbound`:`Outbound`}),(0,_.jsx)(`span`,{className:`truncate text-body-small-default`,style:{color:`var(--content-tertiary)`},children:e.from_address})]}),(0,_.jsx)(`p`,{className:`truncate text-body-medium-default`,style:{color:`var(--content-default)`},children:e.subject||`(no subject)`})]}),(0,_.jsxs)(`div`,{className:`flex shrink-0 items-center gap-1.5 text-body-small-default`,style:{color:`var(--content-tertiary)`},children:[(0,_.jsx)(d,{className:`h-3 w-3`}),(0,_.jsx)(`span`,{children:v(e.created_at)})]})]})})}function w({assistantId:e,platformGate:r}){let i=r===`full`,o=n({...u({path:{assistant_id:e}}),enabled:i}),d=o.data?.results?.[0],f=n({...l({path:{assistant_id:e,id:d?.id??``}}),enabled:i&&!!d?.id}),p=n({...c({path:{assistant_id:e},query:{limit:10}}),enabled:i}),m=f.data?.usage,h=p.data?.results??[];return o.isLoading?(0,_.jsx)(`div`,{className:`flex items-center justify-center py-24`,children:(0,_.jsx)(a,{className:`h-8 w-8 animate-spin`,style:{color:`var(--content-tertiary)`}})}):o.isError?(0,_.jsx)(x,{message:`Couldn't load email addresses.`,onRetry:()=>{o.refetch()},retrying:o.isFetching}):d?(0,_.jsxs)(`div`,{className:`flex flex-col gap-6`,children:[(0,_.jsx)(y,{title:`Totals`,children:(0,_.jsxs)(`div`,{className:`grid grid-cols-2 gap-3 sm:grid-cols-4`,children:[(0,_.jsx)(S,{label:`Sent today`,value:m?.sent_today,sub:m?`of ${m.daily_limit} daily limit`:void 0}),(0,_.jsx)(S,{label:`Received today`,value:m?.received_today}),(0,_.jsx)(S,{label:`Sent this month`,value:m?.sent_this_month}),(0,_.jsx)(S,{label:`Received this month`,value:m?.received_this_month})]})}),(0,_.jsx)(y,{title:`Recent Emails`,children:p.isLoading?(0,_.jsxs)(`div`,{className:`flex items-center gap-2 text-body-small-default`,style:{color:`var(--content-tertiary)`},children:[(0,_.jsx)(a,{className:`h-4 w-4 animate-spin`}),`Loading…`]}):p.isError?(0,_.jsx)(x,{message:`Couldn't load recent emails.`,onRetry:()=>{p.refetch()},retrying:p.isFetching}):h.length===0?(0,_.jsx)(b,{children:`No emails yet.`}):(0,_.jsx)(`div`,{className:`space-y-2`,children:h.map(e=>(0,_.jsx)(C,{email:e},e.id))})})]}):(0,_.jsxs)(b,{children:[`No email address registered yet.`,` `,(0,_.jsx)(t,{to:s.settings.ai,className:`underline`,style:{color:`var(--content-tertiary)`},children:`Set one up in AI Settings → Email.`})]})}function T(){let t=m(),n=g();return t===`gated`?(0,_.jsx)(e,{replace:!0,to:s.logs.root}):t===`disabled`?(0,_.jsx)(h,{children:`Log in to the Vellum platform to view emails.`}):(0,_.jsx)(w,{assistantId:n,platformGate:t})}export{T as EmailsPage};
@@ -1 +1 @@
1
- import{n as e,t}from"./create-selectors-ClYkcuKo.js";function n(){return{emailRootDomain:`local.vellum.me`,isNonProduction:!0}}var r=t(e()(e=>({...n(),setEnvironment:t=>e(t)})));export{r as t};
1
+ import{n as e,t}from"./create-selectors-BE0_e_Ed.js";function n(){return{emailRootDomain:`local.vellum.me`,isNonProduction:!0}}var r=t(e()(e=>({...n(),setEnvironment:t=>e(t)})));export{r as t};
@@ -1,2 +1,2 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/web-DKvxfNu_.js","assets/dist-nMnxT9pm.js","assets/definitions-BqAtozTh.js"])))=>i.map(i=>d[i]);
2
- import{t as e}from"./preload-helper-BewR0kVT.js";import{i as t}from"./dist-nMnxT9pm.js";import{t as n}from"./definitions-BqAtozTh.js";function r(e){e.CapacitorUtils.Synapse=new Proxy({},{get(t,n){return new Proxy({},{get(t,r){return(t,i,a)=>{let o=e.Capacitor.Plugins[n];if(o===void 0){a(Error(`Capacitor plugin ${n} not found`));return}if(typeof o[r]!=`function`){a(Error(`Method ${r} not found in Capacitor plugin ${n}`));return}(async()=>{try{i(await o[r](t))}catch(e){a(e)}})()}}})}})}function i(e){e.CapacitorUtils.Synapse=new Proxy({},{get(t,n){return e.cordova.plugins[n]}})}function a(e=!1){typeof window>`u`||(window.CapacitorUtils=window.CapacitorUtils||{},window.Capacitor!==void 0&&!e?r(window):window.cordova!==void 0&&i(window))}var o=t(`Filesystem`,{web:()=>e(()=>import(`./web-DKvxfNu_.js`).then(e=>new e.FilesystemWeb),__vite__mapDeps([0,1,2]))});a();export{n as Directory,o as Filesystem};
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/web-ByMNu3A_.js","assets/dist-3i_EPbLt.js","assets/definitions-B4RRVbRh.js"])))=>i.map(i=>d[i]);
2
+ import{t as e}from"./preload-helper-BewR0kVT.js";import{i as t}from"./dist-3i_EPbLt.js";import{t as n}from"./definitions-B4RRVbRh.js";function r(e){e.CapacitorUtils.Synapse=new Proxy({},{get(t,n){return new Proxy({},{get(t,r){return(t,i,a)=>{let o=e.Capacitor.Plugins[n];if(o===void 0){a(Error(`Capacitor plugin ${n} not found`));return}if(typeof o[r]!=`function`){a(Error(`Method ${r} not found in Capacitor plugin ${n}`));return}(async()=>{try{i(await o[r](t))}catch(e){a(e)}})()}}})}})}function i(e){e.CapacitorUtils.Synapse=new Proxy({},{get(t,n){return e.cordova.plugins[n]}})}function a(e=!1){typeof window>`u`||(window.CapacitorUtils=window.CapacitorUtils||{},window.Capacitor!==void 0&&!e?r(window):window.cordova!==void 0&&i(window))}var o=t(`Filesystem`,{web:()=>e(()=>import(`./web-ByMNu3A_.js`).then(e=>new e.FilesystemWeb),__vite__mapDeps([0,1,2]))});a();export{n as Directory,o as Filesystem};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/web-CyTCBnAZ.js","assets/dist-3i_EPbLt.js"])))=>i.map(i=>d[i]);
2
+ import{t as e}from"./preload-helper-BewR0kVT.js";import{i as t}from"./dist-3i_EPbLt.js";var n=t(`Share`,{web:()=>e(()=>import(`./web-CyTCBnAZ.js`).then(e=>new e.ShareWeb),__vite__mapDeps([0,1]))});export{n as Share};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/web-DuA0h7oK.js","assets/dist-3i_EPbLt.js"])))=>i.map(i=>d[i]);
2
+ import{t as e}from"./preload-helper-BewR0kVT.js";import{i as t}from"./dist-3i_EPbLt.js";var n;(function(e){e.Light=`light`,e.Dark=`dark`})(n||={});var r=t(`SafeArea`,{web:()=>e(()=>import(`./web-DuA0h7oK.js`).then(e=>new e.SafeAreaWeb),__vite__mapDeps([0,1]))});export{r as SafeArea};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/web-B4ULoQq5.js","assets/dist-3i_EPbLt.js"])))=>i.map(i=>d[i]);
2
+ import{t as e}from"./preload-helper-BewR0kVT.js";import{i as t}from"./dist-3i_EPbLt.js";var n=t(`Browser`,{web:()=>e(()=>import(`./web-B4ULoQq5.js`).then(e=>new e.BrowserWeb),__vite__mapDeps([0,1]))});export{n as Browser};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/web-CvCsdCeT.js","assets/dist-3i_EPbLt.js"])))=>i.map(i=>d[i]);
2
+ import{t as e}from"./preload-helper-BewR0kVT.js";import{i as t}from"./dist-3i_EPbLt.js";var n=t(`App`,{web:()=>e(()=>import(`./web-CvCsdCeT.js`).then(e=>new e.AppWeb),__vite__mapDeps([0,1]))});export{n as App};
@@ -0,0 +1 @@
1
+ import{i as e}from"./dist-3i_EPbLt.js";var t=e(`PushNotifications`,{});export{t as PushNotifications};
@@ -1 +1 @@
1
- import{t as e}from"./createLucideIcon-DIlBzeWM.js";var t=e(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]);export{t};
1
+ import{t as e}from"./createLucideIcon-KBgJOpms.js";var t=e(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]);export{t};
@@ -1 +1 @@
1
- var e={version:1,flags:[{id:`auto-analyze`,scope:`assistant`,key:`auto-analyze`,label:`Auto-analyze conversations`,description:`Automatically trigger conversation analysis on the same cadence as memory extraction (batch threshold, idle debounce, end-of-conversation). The analysis agent has full tool access and writes back to memory and skills without user approval.`,defaultEnabled:!1},{id:`user-hosted-enabled`,scope:`client`,key:`user-hosted-enabled`,label:`User Hosted Enabled`,description:`Enable user-hosted onboarding flow`,defaultEnabled:!1},{id:`pre-chat-onboarding-experiment-2026-06-06`,scope:`client`,key:`pre-chat-onboarding-experiment-2026-06-06`,label:`Pre-chat Onboarding Experiment 2026-06-06`,description:`Pre-chat onboarding experiment with control and variant-a arms. Control shows the full funnel; variant-a shows the condensed pared-down flow.`,defaultEnabled:`control`,values:[`control`,`variant-a`]},{id:`experiment-activation-flow-2026-06-03`,scope:`both`,key:`experiment-activation-flow-2026-06-03`,label:`Activation Flow Experiment 2026-06-03`,description:`Multivariate activation-flow experiment. control = standard flow; variant-a = activation rail; personal-page = new sign-up-page variant (front-end only). Targeted via LaunchDarkly.`,defaultEnabled:`control`,values:[`control`,`variant-a`,`personal-page`]},{id:`local-docker-enabled`,scope:`client`,key:`local-docker-enabled`,label:`Local Docker Mode`,description:`When enabled, the Local hosting option uses Docker under the hood for sandboxed execution, hiding the separate Docker card`,defaultEnabled:!1},{id:`a2a-channel`,scope:`assistant`,key:`a2a-channel`,label:`A2A Channel`,description:`Enable the A2A (Agent-to-Agent) channel for inter-assistant communication via the open A2A protocol`,defaultEnabled:!1},{id:`trace-collection`,scope:`assistant`,key:`trace-collection`,label:`Trace Collection`,description:`Gate per-turn conversation trace (user/assistant/tool-call/tool-response) collection. The daemon attaches a trace to its turn telemetry only when this flag AND the owner's share_diagnostics consent are both on. Defaults off (fail-closed) — the live value is delivered from LaunchDarkly.`,defaultEnabled:!1},{id:`workspace-tools-watcher`,scope:`assistant`,key:`workspace-tools-watcher`,label:`Workspace tools file watcher`,description:"Hot-reload workspace tool overrides under `<workspaceDir>/tools/` by watching the directory and re-registering tools as files change. When disabled, workspace tools still load from disk once at daemon startup, but live edits require a restart to take effect.",defaultEnabled:!1},{id:`settings-developer-nav`,scope:`assistant`,key:`settings-developer-nav`,label:`Settings Developer Nav`,description:`Control Developer nav visibility in macOS settings`,defaultEnabled:!1},{id:`developer-menu-items`,scope:`client`,key:`developer-menu-items`,label:`Developer Menu Items`,description:`Show Component Gallery and Replay Onboarding in the menu bar`,defaultEnabled:!1},{id:`ces-tools`,scope:`assistant`,key:`ces-tools`,label:`CES Tool Exposure`,description:`Register Credential Execution Service tools (credential-grant, credential-revoke, credential-list) in the agent loop`,defaultEnabled:!1},{id:`ces-shell-lockdown`,scope:`assistant`,key:`ces-shell-lockdown`,label:`CES Shell Lockdown`,description:`Enforce untrusted-agent shell lockdown when CES credentials are active, restricting direct shell access to credentialed services`,defaultEnabled:!1},{id:`ces-secure-install`,scope:`assistant`,key:`ces-secure-install`,label:`CES Secure Command Installation`,description:`Enable secure tool/command installation via CES instead of direct shell execution for untrusted agents`,defaultEnabled:!1},{id:`ces-grant-audit`,scope:`assistant`,key:`ces-grant-audit`,label:`CES Grant & Audit Inspection`,description:`Surface credential grant and audit inspection endpoints for reviewing active grants and access logs`,defaultEnabled:!1},{id:`settings-embedding-provider`,scope:`assistant`,key:`settings-embedding-provider`,label:`Embedding Provider Settings`,description:`Show the Embedding service card in Models & Services settings`,defaultEnabled:!1},{id:`multi-platform-assistant`,scope:`client`,key:`multi-platform-assistant`,label:`Multi-Platform Assistant Switcher`,description:`Enable the menu-bar assistant switcher for managing multiple platform-hosted assistants (new/switch/retire)`,defaultEnabled:!1},{id:`quick-input`,scope:`client`,key:`quick-input`,label:`Quick Input`,description:`Enable the Quick Input popover on right-click of the menu bar icon`,defaultEnabled:!1},{id:`expand-completed-steps`,scope:`client`,key:`expand-completed-steps`,label:`Expand Completed Steps`,description:`Auto-expand completed tool call step groups instead of showing them collapsed`,defaultEnabled:!1},{id:`message-tts`,scope:`assistant`,key:`message-tts`,label:`Message Text-to-Speech`,description:`Show a speaker button on assistant messages to generate and play the message as audio via Fish Audio TTS`,defaultEnabled:!1},{id:`backward-releases`,scope:`assistant`,key:`backward-releases`,label:`Backward Releases`,description:`Show older versions in the version picker, allowing rollback to previous releases`,defaultEnabled:!1},{id:`voice-mode`,scope:`assistant`,key:`voice-mode`,label:`Voice Mode`,description:`Show the live voice conversation button in the composer`,defaultEnabled:!1},{id:`fast-mode`,scope:`assistant`,key:`fast-mode`,label:`Fast Mode`,description:`Enable Anthropic fast mode for Opus models (4.6, 4.7, 4.8), delivering up to 2.5x higher output tokens per second at premium pricing`,defaultEnabled:!1},{id:`teleport`,scope:`client`,key:`teleport`,label:`Teleport`,description:`Enable teleport UI in General settings for moving assistants between hosting environments`,defaultEnabled:!1},{id:`apple-container`,scope:`client`,key:`apple-container`,label:`Apple Container`,description:`Enable assistant sandboxing via Apple Containers on macOS 26+, providing a lightweight native sandbox without third-party dependencies`,defaultEnabled:!1},{id:`bookmarks`,scope:`client`,key:`bookmarks`,label:`Message Bookmarks`,description:`Show the bookmark icon on messages and enable the Bookmarks tab in Settings`,defaultEnabled:!1},{id:`fork-from-message`,scope:`client`,key:`fork-from-message`,label:`Fork from Message`,description:`Show the 'Fork from here' option in message overflow menus`,defaultEnabled:!1},{id:`home-tab`,scope:`client`,key:`home-tab`,label:`Home Tab`,description:`Replace the knowledge graph top-level tab with a new Home page showing relationship progression, facts, and capability tiers`,defaultEnabled:!1},{id:`meet`,scope:`assistant`,key:`meet`,label:`Google Meet`,description:`Enables the Google Meet joining bot and the meet-join skill.`,defaultEnabled:!1},{id:`scroll-debug-overlay`,scope:`client`,key:`scroll-debug-overlay`,label:`Scroll Debug Overlay`,description:`Show a live HUD in the top-right of the conversation with scroll geometry, velocity, update rate, and anchor-preserver activity. Developer diagnostic for investigating scroll jank.`,defaultEnabled:!1},{id:`coding-agents-panel`,scope:`client`,key:`coding-agents-panel`,label:`Coding Agents Panel`,description:`Gate native macOS Coding Agents panel entry points and inline ACP session deep links.`,defaultEnabled:!1},{id:`compaction-playground`,scope:`assistant`,key:`compaction-playground`,label:`Compaction Playground`,description:`Expose the developer-only Compaction Playground tab in macOS Settings and enable the /playground/* HTTP endpoints for exercising compaction conditions. Dev-only; default off.`,defaultEnabled:!1},{id:`app-control`,scope:`assistant`,key:`app-control`,label:`App Control`,description:`Enable the app-control skill (per-app screenshot + raw input bypassing AX tree)`,defaultEnabled:!1},{id:`analyze-conversation`,scope:`assistant`,key:`analyze-conversation`,label:`Analyze Conversation`,description:`Show the 'Analyze' / 'Analyze conversation' option in conversation context menus and the conversation title actions dropdown.`,defaultEnabled:!1},{id:`external-plugins`,scope:`assistant`,key:`external-plugins`,label:`External Plugins`,description:"Enable the external-plugin install path: the `assistant plugins` CLI subcommand and the declarative external-plugin loader convention (`<workspaceDir>/plugins/<name>/` directories containing `package.json` plus interface dirs). Gates an unstable surface that may change shape before stabilizing.",defaultEnabled:!1},{id:`velvet-theme`,scope:`client`,key:`velvet-theme`,label:`Velvet Theme`,description:`Show the Velvet theme option in the macOS appearance settings. Velvet is a dark-mode variant with red/pink accent colors.`,defaultEnabled:!1},{id:`query-complexity-routing`,scope:`assistant`,key:`query-complexity-routing`,label:`Query Complexity Routing`,description:`Automatically route user messages to the most appropriate inference profile based on query complexity. Simple queries use the speed profile, complex queries escalate to the quality profile. The user is notified of each switch and can opt out by pinning a profile on the conversation.`,defaultEnabled:!1},{id:`queue-steering`,scope:`assistant`,key:`queue-steering`,label:`Queue Steering`,description:`Enable the 'Push to agent' button on queued messages, allowing users to steer the assistant to a specific queued message by aborting the current generation and promoting the message to the head of the queue.`,defaultEnabled:!1},{id:`chat-pull-to-refresh-enabled`,scope:`client`,key:`chat-pull-to-refresh-enabled`,label:`Chat Pull to Refresh`,description:`Enable pull-to-refresh gesture in the chat view.`,defaultEnabled:!1},{id:`platform-notifications`,scope:`client`,key:`platform-notifications`,label:`Platform Notifications`,description:`Enable the Notifications tab in settings.`,defaultEnabled:!1},{id:`centralized-assistant-status`,scope:`client`,key:`centralized-assistant-status`,label:`Centralized Assistant Status`,description:`Enable client polling of the centralized assistant operational status endpoint.`,defaultEnabled:!1},{id:`preview-channel`,scope:`client`,key:`preview-channel`,label:`Preview Channel`,description:`Enable user-facing Preview release channel controls in assistant settings.`,defaultEnabled:!1},{id:`rollback-enabled`,scope:`assistant`,key:`rollback-enabled`,label:`Rollback Enabled`,description:`Show older versions in the version picker, allowing rollback to previous releases.`,defaultEnabled:!1},{id:`self-hosted-assistant`,scope:`client`,key:`self-hosted-assistant`,label:`Self-Hosted Assistant`,description:`Enable self-hosted assistant configuration.`,defaultEnabled:!1},{id:`web-remote-ingress`,scope:`assistant`,key:`web-remote-ingress`,label:`Web Remote Ingress`,description:`Serve the web client over a public tunnel and enable browser pairing for self-hosted assistants.`,defaultEnabled:!1},{id:`settings-sleep-policy`,scope:`assistant`,key:`settings-sleep-policy`,label:`Settings Sleep Policy`,description:`Enable sleep policy settings.`,defaultEnabled:!1},{id:`velvet`,scope:`client`,key:`velvet`,label:`Velvet`,description:`Enable the Velvet design theme.`,defaultEnabled:!1},{id:`memory-router-playground`,scope:`client`,key:`memory-router-playground`,label:`Memory Router Playground`,description:`Expose the developer-only Memory Router Playground tab in macOS Settings and the /assistant/memory-router-playground web page for dry-running v4 router config overrides against the live page index. Dev-only; default off.`,defaultEnabled:!1},{id:`memory-v3-shadow`,scope:`assistant`,key:`memory-v3-shadow`,label:`Memory v3 Shadow`,description:`When on, runs the new memory-v3 topic-tree retrieval alongside v2 in shadow mode: logs selections to memory_v3_selections, does not modify injected context. Off by default.`,defaultEnabled:!1},{id:`self-intro-greeting`,scope:`both`,key:`self-intro-greeting`,label:`Self-intro first message`,description:`On the first conversation, send a natural self-introduction (e.g. "Hi Vela, I'm alex. Nice to meet you.") on the user's behalf and route it through real LLM inference, instead of serving the canned first greeting. Names come from the onboarding context; falls back to the canned greeting when no name is known. Exposed to clients so pre-hatch onboarding can compute the source-of-truth initial message, and to the assistant so older clients can still be gated server-side. See assistant/src/daemon/first-greeting.ts (buildSelfIntroMessage).`,defaultEnabled:!1},{id:`research-onboarding`,scope:`client`,key:`research-onboarding`,label:`Research onboarding (spike)`,description:`Spike: replace pre-chat onboarding with a web-research "here's what I know about you" flow, including a Google Calendar "Let's chat tomorrow" step shown over the streaming research. Gates the /assistant/onboarding/research route and the research mock harness. Off by default; enable locally via the feature-flags panel.`,defaultEnabled:!1},{id:`channel-trust-floors`,scope:`assistant`,key:`channel-trust-floors`,label:`Channel Trust Floors`,description:`Expose the Channel Trust Floors settings card (per-channel inbound admission policy) on the Privacy settings page. When off, the card is hidden and channels fall back to their default admission floors. Off by default while the feature is in development.`,defaultEnabled:!1},{id:`mcp-settings`,scope:`assistant`,key:`mcp-settings`,label:`MCP Settings`,description:`Show the MCP page in Settings for managing Model Context Protocol server connections: view status, enable/disable, configure, and inspect registered tools per server.`,defaultEnabled:!1},{id:`os-beta`,scope:`assistant`,key:`os-beta`,label:`OS Beta`,description:`Enable the OS Beta model profile (GLM 5.2 / Fireworks) in the assistant's model profile selection.`,defaultEnabled:!1}]};function t(e,t){return e===t||e===`both`}var n=e.flags,r={};function i(e){return r[e]||e.split(`-`).map((e,t)=>e===`ui`?`UI`:t===0?e:e[0].toUpperCase()+e.slice(1)).join(``)}function a(e){let r={};for(let a of n)typeof a.defaultEnabled==`boolean`&&t(a.scope,e)&&(r[i(a.key)]=a.defaultEnabled);return r}function o(e){let r={};for(let a of n)typeof a.defaultEnabled==`string`&&t(a.scope,e)&&(r[i(a.key)]=a.defaultEnabled);return r}var s=a(`client`),c=a(`assistant`),l=o(`client`),u=o(`assistant`),d=new Map;for(let e of n)d.set(i(e.key),e);var f=new Map;for(let e of n)f.set(i(e.key),e.key);function p(e){return i(e)}function m(e){return f.get(e)}function h(e){return d.get(e)}var g=`VITE_VELLUM_FLAG_`;function _(e){return e.toLowerCase().replace(/_/g,`-`)}var v=new Set([`true`,`1`,`yes`,`on`]),y=new Set([`false`,`0`,`no`,`off`]);function b(e){let t=e.toLowerCase();return v.has(t)?!0:y.has(t)?!1:e}function x(){if(typeof window<`u`&&window.__VELLUM_FLAG_OVERRIDES__!=null)return{...window.__VELLUM_FLAG_OVERRIDES__};let e={},t={BASE_URL:`/assistant/`,DEV:!1,MODE:`production`,PROD:!0,SSR:!1,VITE_PLATFORM_MODE:`false`};for(let n of Object.keys(t))if(n.startsWith(g)){let r=_(n.slice(17)),i=t[n];i!=null&&(e[r]=b(i))}return e}var S=null;function C(){return S===null&&(S=x()),S}var w=new Map;for(let e of n)w.set(e.key,e);function T(e){let n=C(),r={},i={};for(let[a,o]of Object.entries(n)){let n=w.get(a);if(!n||!t(n.scope,e))continue;let s=p(a);typeof o==`boolean`?r[s]=o:i[s]=o}return{bool:r,str:i}}export{p as a,h as c,l as i,t as l,u as n,n as o,s as r,T as s,c as t,m as u};
1
+ var e={version:1,flags:[{id:`auto-analyze`,scope:`assistant`,key:`auto-analyze`,label:`Auto-analyze conversations`,description:`Automatically trigger conversation analysis on the same cadence as memory extraction (batch threshold, idle debounce, end-of-conversation). The analysis agent has full tool access and writes back to memory and skills without user approval.`,defaultEnabled:!1},{id:`user-hosted-enabled`,scope:`client`,key:`user-hosted-enabled`,label:`User Hosted Enabled`,description:`Enable user-hosted onboarding flow`,defaultEnabled:!1},{id:`pre-chat-onboarding-experiment-2026-06-06`,scope:`client`,key:`pre-chat-onboarding-experiment-2026-06-06`,label:`Pre-chat Onboarding Experiment 2026-06-06`,description:`Pre-chat onboarding experiment with control and variant-a arms. Control shows the full funnel; variant-a shows the condensed pared-down flow.`,defaultEnabled:`control`,values:[`control`,`variant-a`]},{id:`experiment-activation-flow-2026-06-03`,scope:`both`,key:`experiment-activation-flow-2026-06-03`,label:`Activation Flow Experiment 2026-06-03`,description:`Multivariate activation-flow experiment. control = standard flow; variant-a = activation rail; personal-page = new sign-up-page variant (front-end only). Targeted via LaunchDarkly.`,defaultEnabled:`control`,values:[`control`,`variant-a`,`personal-page`]},{id:`local-docker-enabled`,scope:`client`,key:`local-docker-enabled`,label:`Local Docker Mode`,description:`When enabled, the Local hosting option uses Docker under the hood for sandboxed execution, hiding the separate Docker card`,defaultEnabled:!1},{id:`a2a-channel`,scope:`assistant`,key:`a2a-channel`,label:`A2A Channel`,description:`Enable the A2A (Agent-to-Agent) channel for inter-assistant communication via the open A2A protocol`,defaultEnabled:!1},{id:`trace-collection`,scope:`assistant`,key:`trace-collection`,label:`Trace Collection`,description:`Gate per-turn conversation trace (user/assistant/tool-call/tool-response) collection. The daemon attaches a trace to its turn telemetry only when this flag AND the owner's share_diagnostics consent are both on. Defaults off (fail-closed) — the live value is delivered from LaunchDarkly.`,defaultEnabled:!1},{id:`workspace-tools-watcher`,scope:`assistant`,key:`workspace-tools-watcher`,label:`Workspace tools file watcher`,description:"Hot-reload workspace tool overrides under `<workspaceDir>/tools/` by watching the directory and re-registering tools as files change. When disabled, workspace tools still load from disk once at daemon startup, but live edits require a restart to take effect.",defaultEnabled:!1},{id:`settings-developer-nav`,scope:`assistant`,key:`settings-developer-nav`,label:`Settings Developer Nav`,description:`Control Developer nav visibility in macOS settings`,defaultEnabled:!1},{id:`developer-menu-items`,scope:`client`,key:`developer-menu-items`,label:`Developer Menu Items`,description:`Show Component Gallery and Replay Onboarding in the menu bar`,defaultEnabled:!1},{id:`ces-tools`,scope:`assistant`,key:`ces-tools`,label:`CES Tool Exposure`,description:`Register Credential Execution Service tools (credential-grant, credential-revoke, credential-list) in the agent loop`,defaultEnabled:!1},{id:`ces-shell-lockdown`,scope:`assistant`,key:`ces-shell-lockdown`,label:`CES Shell Lockdown`,description:`Enforce untrusted-agent shell lockdown when CES credentials are active, restricting direct shell access to credentialed services`,defaultEnabled:!1},{id:`ces-secure-install`,scope:`assistant`,key:`ces-secure-install`,label:`CES Secure Command Installation`,description:`Enable secure tool/command installation via CES instead of direct shell execution for untrusted agents`,defaultEnabled:!1},{id:`ces-grant-audit`,scope:`assistant`,key:`ces-grant-audit`,label:`CES Grant & Audit Inspection`,description:`Surface credential grant and audit inspection endpoints for reviewing active grants and access logs`,defaultEnabled:!1},{id:`settings-embedding-provider`,scope:`assistant`,key:`settings-embedding-provider`,label:`Embedding Provider Settings`,description:`Show the Embedding service card in Models & Services settings`,defaultEnabled:!1},{id:`multi-platform-assistant`,scope:`client`,key:`multi-platform-assistant`,label:`Multi-Platform Assistant Switcher`,description:`Enable the menu-bar assistant switcher for managing multiple platform-hosted assistants (new/switch/retire)`,defaultEnabled:!1},{id:`quick-input`,scope:`client`,key:`quick-input`,label:`Quick Input`,description:`Enable the Quick Input popover on right-click of the menu bar icon`,defaultEnabled:!1},{id:`expand-completed-steps`,scope:`client`,key:`expand-completed-steps`,label:`Expand Completed Steps`,description:`Auto-expand completed tool call step groups instead of showing them collapsed`,defaultEnabled:!1},{id:`message-tts`,scope:`assistant`,key:`message-tts`,label:`Message Text-to-Speech`,description:`Show a speaker button on assistant messages to generate and play the message as audio via Fish Audio TTS`,defaultEnabled:!1},{id:`backward-releases`,scope:`assistant`,key:`backward-releases`,label:`Backward Releases`,description:`Show older versions in the version picker, allowing rollback to previous releases`,defaultEnabled:!1},{id:`voice-mode`,scope:`assistant`,key:`voice-mode`,label:`Voice Mode`,description:`Show the live voice conversation button in the composer`,defaultEnabled:!1},{id:`fast-mode`,scope:`assistant`,key:`fast-mode`,label:`Fast Mode`,description:`Enable Anthropic fast mode for Opus models (4.6, 4.7, 4.8), delivering up to 2.5x higher output tokens per second at premium pricing`,defaultEnabled:!1},{id:`teleport`,scope:`client`,key:`teleport`,label:`Teleport`,description:`Enable teleport UI in General settings for moving assistants between hosting environments`,defaultEnabled:!1},{id:`apple-container`,scope:`client`,key:`apple-container`,label:`Apple Container`,description:`Enable assistant sandboxing via Apple Containers on macOS 26+, providing a lightweight native sandbox without third-party dependencies`,defaultEnabled:!1},{id:`bookmarks`,scope:`client`,key:`bookmarks`,label:`Message Bookmarks`,description:`Show the bookmark icon on messages and enable the Bookmarks tab in Settings`,defaultEnabled:!1},{id:`fork-from-message`,scope:`client`,key:`fork-from-message`,label:`Fork from Message`,description:`Show the 'Fork from here' option in message overflow menus`,defaultEnabled:!1},{id:`home-tab`,scope:`client`,key:`home-tab`,label:`Home Tab`,description:`Replace the knowledge graph top-level tab with a new Home page showing relationship progression, facts, and capability tiers`,defaultEnabled:!1},{id:`meet`,scope:`assistant`,key:`meet`,label:`Google Meet`,description:`Enables the Google Meet joining bot and the meet-join skill.`,defaultEnabled:!1},{id:`scroll-debug-overlay`,scope:`client`,key:`scroll-debug-overlay`,label:`Scroll Debug Overlay`,description:`Show a live HUD in the top-right of the conversation with scroll geometry, velocity, update rate, and anchor-preserver activity. Developer diagnostic for investigating scroll jank.`,defaultEnabled:!1},{id:`coding-agents-panel`,scope:`client`,key:`coding-agents-panel`,label:`Coding Agents Panel`,description:`Gate native macOS Coding Agents panel entry points and inline ACP session deep links.`,defaultEnabled:!1},{id:`compaction-playground`,scope:`assistant`,key:`compaction-playground`,label:`Compaction Playground`,description:`Expose the developer-only Compaction Playground tab in macOS Settings and enable the /playground/* HTTP endpoints for exercising compaction conditions. Dev-only; default off.`,defaultEnabled:!1},{id:`app-control`,scope:`assistant`,key:`app-control`,label:`App Control`,description:`Enable the app-control skill (per-app screenshot + raw input bypassing AX tree)`,defaultEnabled:!1},{id:`analyze-conversation`,scope:`assistant`,key:`analyze-conversation`,label:`Analyze Conversation`,description:`Show the 'Analyze' / 'Analyze conversation' option in conversation context menus and the conversation title actions dropdown.`,defaultEnabled:!1},{id:`external-plugins`,scope:`assistant`,key:`external-plugins`,label:`External Plugins`,description:"Enable the external-plugin install path: the `assistant plugins` CLI subcommand and the declarative external-plugin loader convention (`<workspaceDir>/plugins/<name>/` directories containing `package.json` plus interface dirs). Gates an unstable surface that may change shape before stabilizing.",defaultEnabled:!1},{id:`velvet-theme`,scope:`client`,key:`velvet-theme`,label:`Velvet Theme`,description:`Show the Velvet theme option in the macOS appearance settings. Velvet is a dark-mode variant with red/pink accent colors.`,defaultEnabled:!1},{id:`queue-steering`,scope:`assistant`,key:`queue-steering`,label:`Queue Steering`,description:`Enable the 'Push to agent' button on queued messages, allowing users to steer the assistant to a specific queued message by aborting the current generation and promoting the message to the head of the queue.`,defaultEnabled:!1},{id:`chat-pull-to-refresh-enabled`,scope:`client`,key:`chat-pull-to-refresh-enabled`,label:`Chat Pull to Refresh`,description:`Enable pull-to-refresh gesture in the chat view.`,defaultEnabled:!1},{id:`platform-notifications`,scope:`client`,key:`platform-notifications`,label:`Platform Notifications`,description:`Enable the Notifications tab in settings.`,defaultEnabled:!1},{id:`centralized-assistant-status`,scope:`client`,key:`centralized-assistant-status`,label:`Centralized Assistant Status`,description:`Enable client polling of the centralized assistant operational status endpoint.`,defaultEnabled:!1},{id:`preview-channel`,scope:`client`,key:`preview-channel`,label:`Preview Channel`,description:`Enable user-facing Preview release channel controls in assistant settings.`,defaultEnabled:!1},{id:`rollback-enabled`,scope:`assistant`,key:`rollback-enabled`,label:`Rollback Enabled`,description:`Show older versions in the version picker, allowing rollback to previous releases.`,defaultEnabled:!1},{id:`self-hosted-assistant`,scope:`client`,key:`self-hosted-assistant`,label:`Self-Hosted Assistant`,description:`Enable self-hosted assistant configuration.`,defaultEnabled:!1},{id:`web-remote-ingress`,scope:`assistant`,key:`web-remote-ingress`,label:`Web Remote Ingress`,description:`Serve the web client over a public tunnel and enable browser pairing for self-hosted assistants.`,defaultEnabled:!1},{id:`settings-sleep-policy`,scope:`assistant`,key:`settings-sleep-policy`,label:`Settings Sleep Policy`,description:`Enable sleep policy settings.`,defaultEnabled:!1},{id:`velvet`,scope:`client`,key:`velvet`,label:`Velvet`,description:`Enable the Velvet design theme.`,defaultEnabled:!1},{id:`memory-router-playground`,scope:`client`,key:`memory-router-playground`,label:`Memory Router Playground`,description:`Expose the developer-only Memory Router Playground tab in macOS Settings and the /assistant/memory-router-playground web page for dry-running v4 router config overrides against the live page index. Dev-only; default off.`,defaultEnabled:!1},{id:`memory-v3-shadow`,scope:`assistant`,key:`memory-v3-shadow`,label:`Memory v3 Shadow`,description:`When on, runs the new memory-v3 topic-tree retrieval alongside v2 in shadow mode: logs selections to memory_v3_selections, does not modify injected context. Off by default.`,defaultEnabled:!1},{id:`self-intro-greeting`,scope:`both`,key:`self-intro-greeting`,label:`Self-intro first message`,description:`On the first conversation, send a natural self-introduction (e.g. "Hi Vela, I'm alex. Nice to meet you.") on the user's behalf and route it through real LLM inference, instead of serving the canned first greeting. Names come from the onboarding context; falls back to the canned greeting when no name is known. Exposed to clients so pre-hatch onboarding can compute the source-of-truth initial message, and to the assistant so older clients can still be gated server-side. See assistant/src/daemon/first-greeting.ts (buildSelfIntroMessage).`,defaultEnabled:!1},{id:`research-onboarding`,scope:`client`,key:`research-onboarding`,label:`Research onboarding (spike)`,description:`Spike: replace pre-chat onboarding with a web-research "here's what I know about you" flow, including a Google Calendar "Let's chat tomorrow" step shown over the streaming research. Gates the /assistant/onboarding/research route and the research mock harness. Off by default; enable locally via the feature-flags panel.`,defaultEnabled:!1},{id:`channel-trust-floors`,scope:`assistant`,key:`channel-trust-floors`,label:`Channel Trust Floors`,description:`Expose the Channel Trust Floors settings card (per-channel inbound admission policy) on the Privacy settings page. When off, the card is hidden and channels fall back to their default admission floors. Off by default while the feature is in development.`,defaultEnabled:!1},{id:`mcp-settings`,scope:`assistant`,key:`mcp-settings`,label:`MCP Settings`,description:`Show the MCP page in Settings for managing Model Context Protocol server connections: view status, enable/disable, configure, and inspect registered tools per server.`,defaultEnabled:!1},{id:`os-beta`,scope:`assistant`,key:`os-beta`,label:`OS Beta`,description:`Enable the OS Beta model profile (GLM 5.2 / Fireworks) in the assistant's model profile selection.`,defaultEnabled:!1}]};function t(e,t){return e===t||e===`both`}var n=e.flags,r={};function i(e){return r[e]||e.split(`-`).map((e,t)=>e===`ui`?`UI`:t===0?e:e[0].toUpperCase()+e.slice(1)).join(``)}function a(e){let r={};for(let a of n)typeof a.defaultEnabled==`boolean`&&t(a.scope,e)&&(r[i(a.key)]=a.defaultEnabled);return r}function o(e){let r={};for(let a of n)typeof a.defaultEnabled==`string`&&t(a.scope,e)&&(r[i(a.key)]=a.defaultEnabled);return r}var s=a(`client`),c=a(`assistant`),l=o(`client`),u=o(`assistant`),d=new Map;for(let e of n)d.set(i(e.key),e);var f=new Map;for(let e of n)f.set(i(e.key),e.key);function p(e){return i(e)}function m(e){return f.get(e)}function h(e){return d.get(e)}var g=`VITE_VELLUM_FLAG_`;function _(e){return e.toLowerCase().replace(/_/g,`-`)}var v=new Set([`true`,`1`,`yes`,`on`]),y=new Set([`false`,`0`,`no`,`off`]);function b(e){let t=e.toLowerCase();return v.has(t)?!0:y.has(t)?!1:e}function x(){if(typeof window<`u`&&window.__VELLUM_FLAG_OVERRIDES__!=null)return{...window.__VELLUM_FLAG_OVERRIDES__};let e={},t={BASE_URL:`/assistant/`,DEV:!1,MODE:`production`,PROD:!0,SSR:!1,VITE_PLATFORM_MODE:`false`};for(let n of Object.keys(t))if(n.startsWith(g)){let r=_(n.slice(17)),i=t[n];i!=null&&(e[r]=b(i))}return e}var S=null;function C(){return S===null&&(S=x()),S}var w=new Map;for(let e of n)w.set(e.key,e);function T(e){let n=C(),r={},i={};for(let[a,o]of Object.entries(n)){let n=w.get(a);if(!n||!t(n.scope,e))continue;let s=p(a);typeof o==`boolean`?r[s]=o:i[s]=o}return{bool:r,str:i}}export{p as a,h as c,l as i,t as l,u as n,n as o,s as r,T as s,c as t,m as u};
@@ -1 +1 @@
1
- import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{t as n}from"./button-D7s2Q_uG.js";import{t as r}from"./jsx-runtime-CVSDxk6A.js";import{t as i}from"./pencil-lwgMCqyH.js";import{$a as a,Za as o,ho as s}from"./index-BiN-6kWM.js";var c=e(t(),1),l=r(),u=`ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace`;function d({content:e,downloadContent:t,fileName:r,mimeType:u=`text/plain`,showEdit:d,isEditing:f,onToggleEdit:p,extraActions:m}){let[h,g]=(0,c.useState)(!1),_=(0,c.useRef)(null),v=(0,c.useCallback)(()=>{navigator.clipboard.writeText(e).then(()=>{g(!0),_.current&&clearTimeout(_.current),_.current=setTimeout(()=>g(!1),1500)})},[e]),y=t??e,b=(0,c.useCallback)(()=>{let e=new Blob([y],{type:u}),t=URL.createObjectURL(e),n=document.createElement(`a`);n.href=t,n.download=r,n.click(),URL.revokeObjectURL(t)},[y,r,u]);return(0,c.useEffect)(()=>()=>{_.current&&clearTimeout(_.current)},[]),f?null:(0,l.jsxs)(`div`,{className:`absolute right-3 top-3 z-10 flex items-center gap-1 rounded-md bg-[var(--surface-primary)] shadow-sm`,children:[d&&p&&(0,l.jsx)(n,{variant:`ghost`,size:`regular`,iconOnly:(0,l.jsx)(i,{"aria-hidden":!0}),onClick:p,"aria-label":`Edit file`,className:`hover:bg-[var(--surface-base)]`}),m,(0,l.jsx)(n,{variant:`ghost`,size:`regular`,iconOnly:h?(0,l.jsx)(s,{"aria-hidden":!0}):(0,l.jsx)(a,{"aria-hidden":!0}),onClick:v,"aria-label":h?`Copied`:`Copy file contents`,className:`hover:bg-[var(--surface-base)]`}),(0,l.jsx)(n,{variant:`ghost`,size:`regular`,iconOnly:(0,l.jsx)(o,{"aria-hidden":!0}),onClick:b,"aria-label":`Download file`,className:`hover:bg-[var(--surface-base)]`})]})}function f({value:e,onChange:t,onSave:n}){return(0,l.jsx)(`textarea`,{className:`m-0 h-full w-full resize-none overflow-auto border-none bg-transparent p-4 text-body-medium-lighter leading-relaxed outline-none`,style:{color:`var(--content-default)`,fontFamily:u},value:e,onChange:e=>t(e.target.value),onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&e.key===`s`&&(e.preventDefault(),n())},spellCheck:!1})}function p({isDirty:e,isSaving:t,error:r,onSave:i,onDiscard:a}){return(0,l.jsxs)(`div`,{className:`flex items-center justify-end gap-2 border-t px-3 py-2`,style:{borderColor:`var(--border-element)`},children:[r&&(0,l.jsx)(`span`,{className:`mr-auto text-body-small-default`,style:{color:`var(--system-error)`},children:r}),(0,l.jsx)(n,{variant:`ghost`,size:`compact`,disabled:t,onClick:a,children:`Discard`}),(0,l.jsx)(n,{variant:`primary`,size:`compact`,disabled:!e||t,onClick:i,children:t?`Saving…`:`Save`})]})}function m({content:e,readOnly:t,whiteSpace:n=`pre-wrap`,onStartEdit:r}){return(0,l.jsx)(`pre`,{className:`m-0 h-full overflow-auto p-4 text-body-medium-lighter leading-relaxed${t?``:` cursor-text`}`,style:{color:`var(--content-default)`,fontFamily:u,whiteSpace:n},onClick:t?void 0:r,children:e})}export{m as i,p as n,f as r,d as t};
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{t}from"./react-DJZBPgpf.js";import{t as n}from"./button-D7s2Q_uG.js";import{t as r}from"./jsx-runtime-CVSDxk6A.js";import{t as i}from"./pencil-Cyrr5VNX.js";import{Ii as a,Ri as o,ta as s}from"./index-Chr1kHBM.js";var c=e(t(),1),l=r(),u=`ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace`;function d({content:e,downloadContent:t,fileName:r,mimeType:u=`text/plain`,showEdit:d,isEditing:f,onToggleEdit:p,extraActions:m}){let[h,g]=(0,c.useState)(!1),_=(0,c.useRef)(null),v=(0,c.useCallback)(()=>{navigator.clipboard.writeText(e).then(()=>{g(!0),_.current&&clearTimeout(_.current),_.current=setTimeout(()=>g(!1),1500)})},[e]),y=t??e,b=(0,c.useCallback)(()=>{let e=new Blob([y],{type:u}),t=URL.createObjectURL(e),n=document.createElement(`a`);n.href=t,n.download=r,n.click(),URL.revokeObjectURL(t)},[y,r,u]);return(0,c.useEffect)(()=>()=>{_.current&&clearTimeout(_.current)},[]),f?null:(0,l.jsxs)(`div`,{className:`absolute right-3 top-3 z-10 flex items-center gap-1 rounded-md bg-[var(--surface-primary)] shadow-sm`,children:[d&&p&&(0,l.jsx)(n,{variant:`ghost`,size:`regular`,iconOnly:(0,l.jsx)(i,{"aria-hidden":!0}),onClick:p,"aria-label":`Edit file`,className:`hover:bg-[var(--surface-base)]`}),m,(0,l.jsx)(n,{variant:`ghost`,size:`regular`,iconOnly:h?(0,l.jsx)(s,{"aria-hidden":!0}):(0,l.jsx)(o,{"aria-hidden":!0}),onClick:v,"aria-label":h?`Copied`:`Copy file contents`,className:`hover:bg-[var(--surface-base)]`}),(0,l.jsx)(n,{variant:`ghost`,size:`regular`,iconOnly:(0,l.jsx)(a,{"aria-hidden":!0}),onClick:b,"aria-label":`Download file`,className:`hover:bg-[var(--surface-base)]`})]})}function f({value:e,onChange:t,onSave:n}){return(0,l.jsx)(`textarea`,{className:`m-0 h-full w-full resize-none overflow-auto border-none bg-transparent p-4 text-body-medium-lighter leading-relaxed outline-none`,style:{color:`var(--content-default)`,fontFamily:u},value:e,onChange:e=>t(e.target.value),onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&e.key===`s`&&(e.preventDefault(),n())},spellCheck:!1})}function p({isDirty:e,isSaving:t,error:r,onSave:i,onDiscard:a}){return(0,l.jsxs)(`div`,{className:`flex items-center justify-end gap-2 border-t px-3 py-2`,style:{borderColor:`var(--border-element)`},children:[r&&(0,l.jsx)(`span`,{className:`mr-auto text-body-small-default`,style:{color:`var(--system-error)`},children:r}),(0,l.jsx)(n,{variant:`ghost`,size:`compact`,disabled:t,onClick:a,children:`Discard`}),(0,l.jsx)(n,{variant:`primary`,size:`compact`,disabled:!e||t,onClick:i,children:t?`Saving…`:`Save`})]})}function m({content:e,readOnly:t,whiteSpace:n=`pre-wrap`,onStartEdit:r}){return(0,l.jsx)(`pre`,{className:`m-0 h-full overflow-auto p-4 text-body-medium-lighter leading-relaxed${t?``:` cursor-text`}`,style:{color:`var(--content-default)`,fontFamily:u,whiteSpace:n},onClick:t?void 0:r,children:e})}export{m as i,p as n,f as r,d as t};
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{a as t,n,o as r,r as i,s as a}from"./device-settings-BBwtGKJb.js";import{t as o}from"./capture-error-CN7ObyIk.js";import{t as s}from"./react-DJZBPgpf.js";import{t as c}from"./button-D7s2Q_uG.js";import{d as l,t as u}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{n as d}from"./QueryClientProvider-DKhXIxGb.js";import{t as f}from"./useQuery-B45lW1Kk.js";import{t as p}from"./useMutation-Lj4VunQV.js";import{t as m}from"./jsx-runtime-CVSDxk6A.js";import{t as h}from"./cn-DvW5mxZR.js";import{t as g}from"./dropdown-yOV5eJnU.js";import{c as _,l as v,n as y}from"./src-BJj2O5XB.js";import{t as b}from"./confirm-dialog-SpCsmAdG.js";import{t as x}from"./notice-CynJKEow.js";import{t as S}from"./tag-CE_o2aao.js";import{t as C}from"./input-Ch7OC6ME.js";import{t as w}from"./toggle-95p73HGd.js";import{n as T}from"./stat-square-CraPxMcl.js";import{t as E}from"./modal-CHuPOsJJ.js";import{n as D}from"./toast-CxaZ5f1d.js";import{c as O,d as k,f as A,h as j}from"./local-mode-Bg6wpc5q.js";import{t as M}from"./is-electron-CcgCla1v.js";import{n as N}from"./resolved-assistants-store-IMxY1_w9.js";import{t as P}from"./createLucideIcon-KBgJOpms.js";import{t as F}from"./bell-tEVVOFRL.js";import{t as I}from"./chevron-right-Cc3NZhAF.js";import{t as L}from"./circle-alert-D58pfVBz.js";import{t as ee}from"./hard-drive-BbaHN7Gp.js";import{t as R}from"./loader-circle-YAV9sMh_.js";import{t as te}from"./moon-D-eeNLvA.js";import{t as z}from"./refresh-cw-C7wug6Q3.js";import{a as ne,c as re,o as ie,r as ae,s as oe,t as se}from"./resize-errors-D0YsLvoI.js";import{t as ce}from"./sparkles-BoIJjAXt.js";import{t as B}from"./triangle-alert-CoIDviBm.js";import{n as V,r as H,t as U}from"./api-errors-C3sAdlZQ.js";import{C as W,J as le,S as ue,a as de,f as fe,n as pe,v as me,x as he,y as ge}from"./auth-store-6CnXVIAL.js";import{t as _e}from"./client.gen-DzaL5PKF.js";import{S as ve,V as ye,Y as be,j as xe}from"./sdk.gen-0RzHFsEa.js";import{a as G}from"./routes-BLyehs4B.js";import{t as K}from"./client-feature-flag-store-DjN8fxHA.js";import{r as q,t as Se}from"./semver-aan9RUyA.js";import{t as Ce}from"./assistant-feature-flag-store-BD9zTDcP.js";import{A as we,D as Te,E as Ee,M as De,Q as Oe,T as ke,bt as Ae,c as je,et as Me,gt as Ne,j as Pe,k as Fe,v as Ie,w as Le,wt as Re,xt as ze}from"./react-query.gen-CRARj4mG.js";import{t as Be}from"./proxy-l3iqYpig.js";import{t as Ve}from"./use-reduced-motion-DgX4o6QR.js";import{Dt as He,Gt as Ue,Hn as We,Ht as Ge,Jr as Ke,Kt as qe,Mn as Je,Mr as Ye,Ot as Xe,Pr as Ze,Q as Qe,Rr as $e,Un as et,Ut as tt,Vn as nt,Y as rt,Yr as it,cn as at,d as ot,ea as st,f as ct,it as lt,kt as ut,l as dt,qt as ft,s as pt,si as mt,ta as ht,u as gt,wi as _t,x as J}from"./index-Chr1kHBM.js";import{t as vt}from"./use-active-assistant-id-DOx36WGk.js";import{t as Y}from"./detail-card-QPVpO5cj.js";import{t as yt}from"./environment-store-DoO5ZqXZ.js";import{i as bt,n as X,r as xt,t as St}from"./assistant-status-panel-Cm8ComZV.js";var Ct=P(`fingerprint-pattern`,[[`path`,{d:`M12 10a2 2 0 0 0-2 2c0 1.02-.1 2.51-.26 4`,key:`1nerag`}],[`path`,{d:`M14 13.12c0 2.38 0 6.38-1 8.88`,key:`o46ks0`}],[`path`,{d:`M17.29 21.02c.12-.6.43-2.3.5-3.02`,key:`ptglia`}],[`path`,{d:`M2 12a10 10 0 0 1 18-6`,key:`ydlgp0`}],[`path`,{d:`M2 16h.01`,key:`1gqxmh`}],[`path`,{d:`M21.8 16c.2-2 .131-5.354 0-6`,key:`drycrb`}],[`path`,{d:`M5 19.5C5.5 18 6 15 6 12a6 6 0 0 1 .34-2`,key:`1tidbn`}],[`path`,{d:`M8.65 22c.21-.66.45-1.32.57-2`,key:`13wd9y`}],[`path`,{d:`M9 6.8a6 6 0 0 1 9 5.2v2`,key:`1fr1j5`}]]),wt=P(`vibrate`,[[`path`,{d:`m2 8 2 2-2 2 2 2-2 2`,key:`sv1b1`}],[`path`,{d:`m22 8-2 2 2 2-2 2 2 2`,key:`101i4y`}],[`rect`,{width:`8`,height:`14`,x:`8`,y:`5`,rx:`1`,key:`1oyrl4`}]]),Z=e(s(),1),Tt=me,Et=`Please choose a different handle.`;async function Dt(e,t){let{data:n,error:r,response:i}=await xe({path:{id:e},body:{handle:t},throwOnError:!1});if(!i)return{kind:`error`,message:H(r,void 0,`Failed to save handle.`)??`Failed to save handle.`};if(i.ok&&n)return{kind:`ok`,data:n};if(i.status===409){let{message:e}=W(r,`handle`,Tt.taken);return{kind:`taken`,message:e}}if(i.status===400){let{code:e,message:t}=W(r,`handle`,Et);return{kind:`invalid`,code:e,message:t}}return{kind:`error`,message:H(r,i,`Failed to save handle.`)}}async function Ot(e,t,n){let{data:r,error:i,response:a}=await ve({path:{assistant_id:e},query:{handle:t},signal:n,throwOnError:!1});if(V(a,i,`Failed to check handle availability.`),!a.ok||!r)throw new U(a.status,a.status===429?`Too many checks — try again in a moment.`:H(i,a,`Failed to check handle availability.`));return{available:r.available,code:r.code??null,message:r.message??null}}function kt(e){return/\d{2,}$/.test(e)}var Q=m(),At=300,jt=1400;function Mt({initialHandle:e,inputLabel:t,helperText:n,idleHelperText:r,checkAvailable:i,save:a,onSaved:o,saveSuccessToast:s,fieldId:l}){let[u,d]=(0,Z.useState)(e),[f,p]=(0,Z.useState)(null),[m,h]=(0,Z.useState)(!1),[g,_]=(0,Z.useState)(`idle`),[v,y]=(0,Z.useState)(null),b=Ve(),x=(0,Z.useRef)(null),S=(0,Z.useMemo)(()=>u.trim().toLowerCase(),[u]),w=S===e.toLowerCase();(0,Z.useEffect)(()=>{if(w||S.length===0){h(!1),x.current?.abort();return}let e=new AbortController;x.current?.abort(),x.current=e,h(!0);let t=window.setTimeout(async()=>{try{let t=await i(S,e.signal);e.signal.aborted||p(t)}catch(t){e.signal.aborted||y(t instanceof Error?t.message:`Couldn't check availability.`)}finally{e.signal.aborted||h(!1)}},At);return()=>{window.clearTimeout(t),e.abort()}},[S,w,i]);let T=(()=>{if(v)return v;if(f&&!f.available){let e=f.code;return f.message??(e?Tt[e]:`Please choose a different handle.`)}return null})(),E=T?n:w?r??null:m?`Checking availability…`:f?.available?`Available.`:null,O=!w&&!m&&f?.available!==!1&&g!==`saving`,k=(0,Z.useCallback)(async()=>{if(!O)return;_(`saving`),y(null);let e=await a(S);if(e.kind===`ok`){_(`saved`),o(e.data),D.success(s),window.setTimeout(()=>_(`idle`),jt);return}if(e.kind===`taken`){_(`idle`),p({available:!1,code:`taken`,message:e.message});return}if(e.kind===`invalid`){_(`idle`),p({available:!1,code:e.code,message:e.message});return}_(`error`),y(e.message),D.error(e.message)},[O,S,o,a,s]),A=(()=>{if(w&&u.length>0||u.length===0)return null;let e=m?`checking`:f?.available?`available`:f?.available===!1?`invalid`:null;return e?(0,Q.jsx)(Qe,{mode:`wait`,initial:!1,children:(0,Q.jsxs)(Be.span,{initial:b?!1:{opacity:0,scale:.85},animate:{opacity:1,scale:1},exit:b?void 0:{opacity:0,scale:.85},transition:{duration:.14,ease:`easeOut`},className:`flex items-center`,"aria-hidden":e!==`available`&&e!==`invalid`,children:[e===`checking`&&(0,Q.jsx)(R,{className:`h-4 w-4 animate-spin text-[var(--content-tertiary)]`}),e===`available`&&(0,Q.jsx)(ht,{className:`h-4 w-4 text-[var(--system-positive-strong)]`,"aria-label":`Available`}),e===`invalid`&&(0,Q.jsx)(L,{className:`h-4 w-4 text-[var(--system-negative-strong)]`,"aria-label":`Not available`})]},e)}):null})(),j=(()=>{switch(g){case`saving`:return(0,Q.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,Q.jsx)(R,{className:`h-3.5 w-3.5 animate-spin`,"aria-hidden":!0}),`Saving…`]});case`saved`:return(0,Q.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,Q.jsx)(ht,{className:`h-3.5 w-3.5`,"aria-hidden":!0}),`Saved`]});default:return`Save`}})();return(0,Q.jsxs)(`div`,{className:`flex flex-col gap-4`,children:[(0,Q.jsx)(C,{label:t,value:u,onChange:e=>{d(e.target.value.replace(/\s+/g,``)),p(null),y(null)},autoCorrect:`off`,autoCapitalize:`none`,spellCheck:!1,maxLength:30,leftIcon:(0,Q.jsx)(`span`,{className:`select-none font-mono text-[var(--content-tertiary)]`,"aria-hidden":!0,children:`@`}),rightIcon:A,errorText:T??void 0,helperText:E??void 0,"aria-invalid":!!T,fullWidth:!0,"data-testid":`${l}-input`}),(!w||g!==`idle`)&&(0,Q.jsx)(`div`,{className:`flex justify-end`,children:(0,Q.jsx)(c,{variant:`primary`,size:`compact`,onClick:k,disabled:!O,"aria-live":`polite`,"data-testid":`${l}-save`,children:j})})]})}function Nt({initial:e,onSaved:t}){let n=pe.use.refreshSession(),r=kt(e.username)?`Your handle was auto-generated at signup — pick one you like.`:void 0,i=(0,Z.useCallback)(async e=>await ue({username:e}),[]),a=(0,Z.useCallback)((e,t)=>ge(e,t),[]),o=(0,Z.useCallback)(e=>{t(e),n()},[t,n]);return(0,Q.jsx)(Mt,{initialHandle:e.username,inputLabel:`User handle`,helperText:`Lowercase letters, digits, hyphens, and underscores. 3–30 characters.`,idleHelperText:r,checkAvailable:a,save:i,onSaved:o,saveSuccessToast:`Profile updated.`,fieldId:`user-handle`})}function Pt({assistant:e,onSaved:t}){let n=e.handle??``,r=f({...je({path:{assistant_id:e.id}})}).data?.results?.[0],i=!!r&&r.subdomain.toLowerCase()===n.toLowerCase(),a=n.length===0?`Your assistant doesn't have a handle yet — claim one to make it mentionable.`:void 0,o=(0,Z.useCallback)(async t=>await Dt(e.id,t),[e.id]),s=(0,Z.useCallback)((t,n)=>Ot(e.id,t,n),[e.id]);return i?(0,Q.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,Q.jsx)(C,{label:`Assistant handle`,value:n,readOnly:!0,disabled:!0,leftIcon:(0,Q.jsx)(`span`,{className:`select-none font-mono text-[var(--content-tertiary)]`,"aria-hidden":!0,children:`@`}),fullWidth:!0,"data-testid":`assistant-handle-input`}),(0,Q.jsxs)(`p`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:[`Your assistant's handle is locked because it's used as its email subdomain. To change it,`,` `,(0,Q.jsx)(u,{to:`${G.settings.ai}?release=1#email`,className:`text-[var(--content-link)] underline hover:text-[var(--content-link-hover)]`,children:`release the subdomain`}),` `,`first.`]})]}):(0,Q.jsx)(Mt,{initialHandle:n,inputLabel:`Assistant handle`,helperText:`Lowercase letters, digits, hyphens, and underscores. 3–30 characters.`,idleHelperText:a,checkAvailable:s,save:o,onSaved:t,saveSuccessToast:`Assistant handle updated.`,fieldId:`assistant-handle`})}function Ft(){return(0,Q.jsxs)(`div`,{className:`flex flex-col gap-4`,"aria-busy":!0,"aria-live":`polite`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,Q.jsx)(`div`,{className:`h-3 w-16 animate-pulse rounded bg-[var(--surface-muted)]`}),(0,Q.jsx)(`div`,{className:`h-9 w-full animate-pulse rounded-md bg-[var(--surface-muted)]`}),(0,Q.jsx)(`div`,{className:`h-3 w-72 animate-pulse rounded bg-[var(--surface-muted)]`})]}),(0,Q.jsx)(`div`,{className:`h-9 w-full animate-pulse rounded-md bg-[var(--surface-muted)]`}),(0,Q.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,Q.jsx)(`div`,{className:`h-3 w-60 animate-pulse rounded bg-[var(--surface-muted)]`}),(0,Q.jsx)(`div`,{className:`h-7 w-16 animate-pulse rounded-md bg-[var(--surface-muted)]`})]}),(0,Q.jsx)(`span`,{className:`sr-only`,children:`Loading your profile…`})]})}function It({assistant:e}={}){let[t,n]=(0,Z.useState)(null),[r,i]=(0,Z.useState)(null),a=Ve(),[o,s]=(0,Z.useState)(e??null);return(0,Z.useEffect)(()=>{s(e??null)},[e]),(0,Z.useEffect)(()=>{let e=!1;return he().then(t=>{e||n(t)}).catch(t=>{e||i(t instanceof Error?t.message:`Failed to load profile.`)}),()=>{e=!0}},[]),(0,Q.jsx)(Y,{title:`Profile`,subtitle:`Manage your user and assistant public handles.`,children:r?(0,Q.jsx)(`p`,{className:`text-body-small-default text-[var(--system-negative-strong)]`,children:r}):t?(0,Q.jsxs)(Be.div,{initial:a?!1:{opacity:0,y:4},animate:{opacity:1,y:0},transition:{duration:.22,ease:`easeOut`},className:`flex flex-col gap-6`,children:[(0,Q.jsx)(Nt,{initial:t,onSaved:n}),o&&(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(`div`,{className:`border-t border-[var(--border-subtle)]`}),(0,Q.jsx)(Pt,{assistant:o,onSaved:s})]})]}):(0,Q.jsx)(Ft,{})})}var Lt=Ie({query:{hosting:`platform`}});function Rt(){let e=vt(),t=f(Lt),n=t.data?.results??[];return t.isPending||n.length<2?null:(0,Q.jsx)(Y,{title:`Switch Assistant`,subtitle:`Choose which assistant is active for this account.`,children:(0,Q.jsx)(`div`,{className:`space-y-2`,children:n.map(t=>{let n=t.id===e;return(0,Q.jsxs)(`div`,{className:`flex items-center justify-between gap-4 rounded-lg border px-4 py-3 ${n?`border-[var(--border-focus)] bg-[var(--surface-lift)]`:`border-[var(--border-base)] bg-[var(--surface-default)]`}`,children:[(0,Q.jsxs)(`div`,{className:`flex min-w-0 items-center gap-3`,children:[(0,Q.jsx)(mt,{className:`h-4 w-4 shrink-0 text-[var(--content-tertiary)]`}),(0,Q.jsx)(`div`,{className:`min-w-0`,children:(0,Q.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Q.jsx)(`span`,{className:`truncate text-body-medium-default text-[var(--content-default)]`,children:t.name||`Unnamed`}),t.status!==`active`&&(0,Q.jsx)(S,{tone:`warning`,children:t.status})]})})]}),(0,Q.jsx)(`div`,{className:`shrink-0`,children:n?(0,Q.jsxs)(`span`,{className:`flex items-center gap-1.5 text-body-small-default text-[var(--system-positive-default)]`,children:[(0,Q.jsx)(ht,{className:`h-4 w-4`}),`Active`]}):(0,Q.jsx)(c,{variant:`outlined`,size:`compact`,disabled:t.status!==`active`,onClick:()=>{le(t.id),D.success(`Switched active assistant.`)},children:`Switch`})})]},t.id)})})})}var zt=[{label:`Never`,seconds:0},{label:`5 min`,seconds:300,devOnly:!0},{label:`10 min`,seconds:600,devOnly:!0},{label:`1 hour`,seconds:3600},{label:`3 hours`,seconds:10800},{label:`1 day`,seconds:86400},{label:`3 days`,seconds:259200},{label:`7 days`,seconds:604800},{label:`14 days`,seconds:1209600},{label:`30 days`,seconds:2592e3}];function Bt(e){if(e===0)return`Never (sleep disabled)`;let t=Math.floor(e/86400),n=Math.floor(e%86400/3600);if(t>0&&n>0)return`${t}d ${n}h`;if(t>0)return`${t} day${t===1?``:`s`}`;if(n>0)return`${n} hour${n===1?``:`s`}`;let r=Math.floor(e/60);return r>0?`${r} minute${r===1?``:`s`}`:`${e}s`}function Vt({assistantId:e}){let t=d(),n=yt.use.isNonProduction(),r=(0,Z.useMemo)(()=>zt.filter(e=>!e.devOnly||n),[n]),{data:i,isLoading:a,isError:o}=f(Pe({path:{id:e}})),s=(0,Z.useMemo)(()=>i?.idle_timeout_seconds??259200,[i]),[l,u]=(0,Z.useState)(null),p=l??s,m=l!==null,h=ze({onSuccess:()=>{D.success(`Sleep policy saved.`),u(null),t.invalidateQueries({queryKey:De({path:{id:e}})})},onError:()=>{D.error(`Failed to save sleep policy. Please try again.`)}});return a?(0,Q.jsxs)(`div`,{className:`flex items-center gap-2 text-body-medium-lighter text-[var(--content-tertiary)]`,children:[(0,Q.jsx)(R,{className:`h-4 w-4 animate-spin`}),`Loading sleep settings...`]}):o?(0,Q.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--system-negative-strong)]`,children:`Failed to load sleep policy. Refresh the page to try again.`}):(0,Q.jsxs)(`div`,{className:`space-y-4`,children:[(0,Q.jsxs)(`div`,{children:[(0,Q.jsx)(`label`,{className:`block text-body-medium-default text-[var(--content-default)]`,children:`Idle timeout`}),(0,Q.jsx)(`p`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:`How long the assistant can be idle before it is put to sleep. "Never" disables idle sleep entirely.`}),(0,Q.jsx)(`div`,{className:`mt-2 flex flex-wrap gap-2`,children:r.map(e=>(0,Q.jsx)(c,{variant:`outlined`,active:p===e.seconds,onClick:()=>u(e.seconds),children:e.label},e.seconds))}),(0,Q.jsxs)(`p`,{className:`mt-2 text-body-small-default text-[var(--content-tertiary)]`,children:[`Current: `,Bt(p)]})]}),m&&(0,Q.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,Q.jsx)(c,{variant:`primary`,leftIcon:h.isPending?(0,Q.jsx)(R,{className:`animate-spin`}):void 0,onClick:()=>h.mutate({path:{id:e},body:{idle_timeout_seconds:p}}),disabled:h.isPending,children:`Save`}),(0,Q.jsx)(c,{variant:`outlined`,onClick:()=>u(null),disabled:h.isPending,children:`Cancel`})]})]})}function Ht(e,t,n){let r=[e.version];return e.version===n&&r.push(`(latest)`),t&&e.version===t&&r.push(`(current)`),r.join(` `)}var Ut=3e3;function Wt(e,t){return t&&e===`preview`?`preview`:`stable`}function Gt({assistantId:e,currentVersion:t,releaseChannel:n,onUpgradeComplete:r}){let i=Ce.use.rollbackEnabled(),a=K.use.previewChannel(),o=d(),s=Wt(n,a),l=s===`preview`,[u,m]=(0,Z.useState)(!1),h=(0,Z.useRef)(null),[_,v]=(0,Z.useState)(null),[y,x]=(0,Z.useState)(!1),[S,C]=(0,Z.useState)(!1),[w,T]=(0,Z.useState)(null),E=e=>e&&h.current&&e===h.current?(queueMicrotask(()=>{T(S?`Successfully rolled back to version ${h.current}.`:`Successfully updated to version ${h.current}.`),m(!1),h.current=null,v(null),D.success(S?`Rollback complete — assistant is healthy.`:`Update complete — assistant is healthy.`),r?.()}),!1):Ut;f({...Fe({path:{id:e}}),refetchInterval:u?e=>E(e.state.data?.current_release_version):!1});let{data:O,isLoading:k}=f(Ne({query:{channel:s}})),A=O?.find(e=>e.is_stable!==!1)??O?.[0],j=_??A?.version??null,M=(0,Z.useMemo)(()=>{if(!i||!j||!t)return!1;let e=q(j),n=q(t);return!e||!n?!1:Se(e,n)<0},[i,j,t]),N=(0,Z.useMemo)(()=>{if(!j)return!1;if(!t)return!0;let e=q(j),n=q(t);if(!e||!n)return j!==t;let r=Se(e,n);return i?r!==0:r>0},[i,j,t]),P=p({mutationFn:async t=>{let{data:n}=await be({path:{id:e},body:t,throwOnError:!0});return n}}),F=p({mutationFn:async t=>{let{data:n}=await ye({path:{id:e},body:t,throwOnError:!0});return n}});return(0,Q.jsxs)(`div`,{className:`space-y-5`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-4 md:grid md:grid-cols-[auto_minmax(0,1fr)] md:items-center md:gap-x-8 md:gap-y-4`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1 md:contents`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-tertiary)]`,children:`Current`}),(0,Q.jsx)(`span`,{className:`block min-w-0 break-all text-body-medium-lighter text-[var(--content-default)]`,children:t??`—`})]}),(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1 md:contents`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-tertiary)]`,children:l?`Preview release`:N?M?`Rollback to`:`Update to`:`Selected`}),(0,Q.jsx)(`span`,{className:`block min-w-0`,children:k?(0,Q.jsxs)(`span`,{className:`flex items-center gap-1 text-body-medium-lighter text-[var(--content-tertiary)]`,children:[(0,Q.jsx)(R,{className:`h-3 w-3 animate-spin`}),`Loading...`]}):O&&O.length>0?i?(0,Q.jsx)(g,{value:j??``,onChange:e=>v(e===A?.version?null:e),disabled:u||P.isPending||F.isPending,options:O.map(e=>({value:e.version,label:Ht(e,t,A?.version)}))}):(0,Q.jsx)(`span`,{className:`block min-w-0 break-all text-body-medium-lighter text-[var(--content-default)]`,children:A?Ht(A,t,A.version):`—`}):`No releases available`})]})]}),(0,Q.jsx)(c,{variant:M?`outlined`:`primary`,className:`min-w-[160px]`,leftIcon:P.isPending||F.isPending||u?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(z,{}),onClick:()=>x(!0),disabled:!N||P.isPending||F.isPending||u||k||!O?.length,children:u?S?`Rolling back...`:`Updating...`:M?`Rollback`:l?`Update preview`:`Update`}),l&&(0,Q.jsxs)(`p`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:[`Using Preview releases.`,` `,(0,Q.jsx)(`a`,{href:`#preview-release-channel`,className:`text-[var(--primary-base)] underline-offset-2 hover:underline`,children:`Switch back to Stable`})]}),!N&&t&&j&&!k&&(0,Q.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--system-positive-strong)]`,children:w??`You are already on this version.`}),(0,Q.jsx)(b,{open:y,title:M?`Rollback assistant`:l?`Update preview release`:`Update assistant`,message:M?`Rollback to version ${j??`unknown`}? The assistant will be briefly unavailable.`:l?`Update to preview version ${j??`latest`}? The assistant will be briefly unavailable during the update.`:`Update to version ${j??`latest`}? The assistant will be briefly unavailable during the update.`,confirmLabel:M?`Rollback`:l?`Update preview`:`Update`,onConfirm:async()=>{x(!1),T(null);let t=_??void 0;try{if(M){let e=await F.mutateAsync({version:t});h.current=e.version??t??null,D.success(e.detail||`Rollback to ${t} initiated.`)}else{let e=await P.mutateAsync({version:t});if(e.detail?.includes(`Already on the latest`)){D.warning(e.detail);return}h.current=e.version??t??null,D.success(e.detail||`Update to ${e.version??t??`latest`} initiated.`)}C(M),m(!0),o.invalidateQueries({queryKey:we({path:{id:e}})})}catch{D.error(M?`Failed to trigger rollback. Please try again.`:`Failed to trigger update. Please try again.`)}},onCancel:()=>x(!1)})]})}function Kt({assistantId:e,currentVersion:t,onUpgradeComplete:n}){let[r,i]=(0,Z.useState)(!1),[a,o]=(0,Z.useState)(null),{data:s,isLoading:l}=f(Ne({query:{stable:!0,limit:100}})),u=(0,Z.useMemo)(()=>He(s),[s]),d=u?.version,p=t?Xe(t,d):!!d,m=ut({assistantId:e,targetVersion:d});return(0,Q.jsxs)(`div`,{className:`space-y-5`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-4 md:grid md:grid-cols-[auto_minmax(0,1fr)] md:items-center md:gap-x-8 md:gap-y-4`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1 md:contents`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-tertiary)]`,children:`Current`}),(0,Q.jsx)(`span`,{className:`block min-w-0 break-all text-body-medium-lighter text-[var(--content-default)]`,children:t??`—`})]}),(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1 md:contents`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-tertiary)]`,children:`Update to`}),(0,Q.jsx)(`span`,{className:`block min-w-0 break-all text-body-medium-lighter text-[var(--content-default)]`,children:l?`Loading...`:d&&u?Ht(u,t,d):`No releases available`})]})]}),(0,Q.jsx)(c,{variant:`primary`,className:`min-w-[160px]`,leftIcon:m.isPending?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(z,{}),onClick:()=>i(!0),disabled:m.isPending||l||!d||!p,children:m.isPending?`Updating...`:d?`Update to ${d}`:`Update`}),a&&(0,Q.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--system-positive-strong)]`,children:a}),!a&&!p&&d&&!l&&(0,Q.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--system-positive-strong)]`,children:`You are already on this version.`}),(0,Q.jsx)(b,{open:r,title:`Update assistant`,message:`Update to version ${d??`latest`}? The assistant will be briefly unavailable during the update.`,confirmLabel:`Update`,onConfirm:async()=>{i(!1),o(null);try{let e=await m.upgrade();o(e.version?`Successfully updated to version ${e.version}.`:`Successfully updated to version ${d??`latest`}.`),D.success(`Update complete — assistant is healthy.`),n?.()}catch(e){D.error(e instanceof Error?e.message:`Failed to trigger update. Please try again.`)}},onCancel:()=>i(!1)})]})}function qt(){let e=ct.useValue();if(at())return null;let t=gt()?`Cmd`:`Ctrl`;return(0,Q.jsx)(Y,{title:`Composer`,children:(0,Q.jsx)(w,{checked:e,onChange:ct.save,label:`Send with ${t}+Enter`,helperText:`When enabled, Enter inserts a new line and ${t}+Enter sends.`})})}function Jt(){let e=ft({platformHostedOnly:!0}),t=qe(),n=pe.use.user()?.id??null,r=pe.use.logout(),[i,a]=(0,Z.useState)(!1),o=Re({onSuccess:async()=>{D.success(`Account deletion requested. You will be logged out shortly.`),fe(n),await r(),Je(G.account.login)},onError:()=>{D.error(`Failed to request account deletion. Please try again.`)}}),s=e===`full`&&t;return(0,Z.useEffect)(()=>{s&&i&&a(!1)},[s,i]),e===`gated`?null:(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(Y,{title:`Delete Account`,subtitle:`Permanently delete your account and all associated data.`,variant:`danger`,children:e===`disabled`?(0,Q.jsx)(J,{children:`Log in to the Vellum platform to delete your account.`}):(0,Q.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Q.jsx)(c,{variant:`dangerOutline`,onClick:()=>a(!0),disabled:o.isPending||s,className:`self-start`,children:`Delete My Account`}),s&&(0,Q.jsx)(R,{className:`h-4 w-4 animate-spin text-[var(--content-tertiary)]`})]})}),(0,Q.jsx)(b,{open:i,title:`Delete Account`,message:`This will permanently delete your account and all associated data. This action cannot be undone.`,confirmLabel:`Delete Account`,destructive:!0,onConfirm:()=>{if(s){a(!1);return}a(!1),o.mutate({})},onCancel:()=>a(!1)})]})}function Yt({title:e,subtitle:t,benefits:n,ctaLabel:r,ctaLeftIcon:i,onAction:a}){return(0,Q.jsx)(Y,{title:e,subtitle:t,children:(0,Q.jsxs)(`div`,{className:`flex flex-col gap-4`,children:[(0,Q.jsx)(`ul`,{className:`space-y-3`,children:n.map(({icon:e,text:t})=>(0,Q.jsxs)(`li`,{className:`flex items-center gap-3`,children:[(0,Q.jsx)(`span`,{className:`flex size-7 shrink-0 items-center justify-center rounded-md`,style:{background:`var(--surface-base)`},children:(0,Q.jsx)(e,{size:14,style:{color:`var(--content-secondary)`},"aria-hidden":!0})}),(0,Q.jsx)(`span`,{className:`text-body-medium-lighter text-[color:var(--content-secondary)]`,children:t})]},t))}),(0,Q.jsx)(c,{variant:`primary`,size:`regular`,leftIcon:i,onClick:a,className:`self-start`,children:r})]})})}function Xt(){return ot()?(0,Q.jsx)(Yt,{title:`Get the iOS App`,subtitle:`The Vellum iOS app gives you a native experience.`,benefits:[{icon:F,text:`Push notifications`},{icon:Ct,text:`Biometric login`},{icon:wt,text:`Native haptics`},{icon:$e,text:`Home screen access`}],ctaLabel:`Download`,ctaLeftIcon:(0,Q.jsx)($e,{size:16}),onAction:()=>{dt(),pt()}}):null}async function Zt(){if(!M())return!1;let e=window.vellum;return e?.launchAtLogin?e.launchAtLogin.get():!1}async function Qt(e){if(!M())return;let t=window.vellum;t?.launchAtLogin&&await t.launchAtLogin.set(e)}function $t(){let[e,t]=(0,Z.useState)(!1);(0,Z.useEffect)(()=>{Zt().then(t)},[]);let n=async e=>{t(e);try{await Qt(e)}catch{t(!e)}};return(0,Q.jsx)(Y,{title:`Launch at Login`,subtitle:`Automatically start Vellum when you log in to your Mac.`,children:(0,Q.jsx)(w,{checked:e,onChange:e=>void n(e),"aria-label":`Launch at Login`})})}function en({className:e}){return(0,Q.jsx)(`div`,{role:`presentation`,className:h(`h-px w-full bg-[var(--border-base)]`,e)})}var $=[`youtube.com`,`youtu.be`,`vimeo.com`,`loom.com`];function tn(e){try{let t=JSON.parse(e);if(Array.isArray(t))return t.filter(e=>typeof e==`string`)}catch{}return[...$]}function nn(){return n(`mediaEmbedsEnabled`,!0)}function rn(){let e=i(`mediaEmbedDomains`,``);return e?tn(e):[...$]}function an(){let[e,n]=(0,Z.useState)(()=>nn()),[i,a]=(0,Z.useState)(()=>rn()),[o,s]=(0,Z.useState)(!1),[l,u]=(0,Z.useState)(``),d=(0,Z.useMemo)(()=>l.trim().toLowerCase(),[l]),f=e=>{n(e),t(`mediaEmbedsEnabled`,e)},p=e=>{a(e),r(`mediaEmbedDomains`,JSON.stringify(e))},m=()=>{if(d){if(i.includes(d)){u(``);return}p([...i,d]),u(``)}},h=e=>{p(i.filter(t=>t!==e))},g=()=>{p([...$])},_=i.length===$.length&&i.every((e,t)=>e===$[t]);return(0,Q.jsxs)(Y,{title:`Media Embeds`,subtitle:`Automatically embed images, videos, and other media shared in chat messages.`,children:[(0,Q.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,Q.jsx)(`div`,{className:`text-body-medium-lighter text-[var(--content-default)]`,children:`Auto Media Embeds`}),(0,Q.jsx)(w,{checked:e,onChange:f})]}),e&&(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(`div`,{className:`mt-4`,children:(0,Q.jsx)(en,{})}),(0,Q.jsxs)(c,{type:`button`,variant:`ghost`,onClick:()=>s(e=>!e),className:`mt-4 w-full justify-between px-3`,"aria-expanded":o,children:[(0,Q.jsxs)(`span`,{className:`flex items-center gap-2`,children:[o?(0,Q.jsx)(st,{className:`h-4 w-4`,"aria-hidden":!0}):(0,Q.jsx)(I,{className:`h-4 w-4`,"aria-hidden":!0}),`Video Domain Allowlist`]}),(0,Q.jsxs)(`span`,{className:`text-body-small-default text-[var(--content-tertiary)]`,children:[i.length,` domain`,i.length===1?``:`s`]})]}),o&&(0,Q.jsxs)(`div`,{className:`mt-3 space-y-3`,children:[(0,Q.jsxs)(`div`,{className:`flex items-end gap-2`,children:[(0,Q.jsx)(C,{label:`Add Domain`,type:`text`,value:l,onChange:e=>u(e.target.value),onKeyDown:e=>{e.key===`Enter`&&(e.preventDefault(),m())},placeholder:`Add domain (e.g. example.com)`,fullWidth:!0,wrapperClassName:`flex-1`}),(0,Q.jsx)(c,{variant:`primary`,size:`compact`,onClick:m,disabled:!d,children:`Add`})]}),i.length>0&&(0,Q.jsx)(`div`,{className:`flex justify-end`,children:(0,Q.jsx)(c,{type:`button`,variant:`ghost`,size:`compact`,onClick:g,disabled:_,tintColor:`var(--content-tertiary)`,children:`Reset to Defaults`})}),i.length>0&&(0,Q.jsx)(`ul`,{className:`space-y-2`,children:i.map(e=>(0,Q.jsxs)(`li`,{className:`flex items-center justify-between rounded-md border border-[var(--border-base)] px-3 py-2 text-body-medium-lighter`,children:[(0,Q.jsx)(`span`,{className:`font-mono text-[var(--content-default)]`,children:e}),(0,Q.jsx)(c,{variant:`dangerGhost`,size:`compact`,iconOnly:(0,Q.jsx)(Ye,{}),onClick:()=>h(e),"aria-label":`Remove ${e}`})]},e))})]})]})]})}function on(e){return e===`preview`?`preview`:`stable`}function sn(e){if(!e)return`Unknown`;let t=new Date(e);return Number.isNaN(t.getTime())?`Unknown`:t.toLocaleString(void 0,{year:`numeric`,month:`short`,day:`numeric`,hour:`numeric`,minute:`2-digit`})}function cn(e){return e.source_release_version?`Stable ${e.source_release_version}`:e.snapshot_name}function ln(e){return e.filter(e=>e.ready_to_use)}function un(e){return e?.feature_enabled===!1}function dn({assistantId:e,onComplete:t}){let n=K.use.previewChannel(),r=d(),[i,a]=(0,Z.useState)(),[o,s]=(0,Z.useState)(!1),[c,l]=(0,Z.useState)(!1),[u,m]=(0,Z.useState)(`restore_backup`),[h,g]=(0,Z.useState)(``),_=Ee({path:{assistant_id:e}}),v=Te({path:{assistant_id:e}}),b=we({path:{id:e}}),{data:C,isLoading:w,isError:T}=f({..._,enabled:n,retry:!1}),E=C?.preview_backups??[],O=(0,Z.useMemo)(()=>ln(E),[E]),k=O[0],A=O.find(e=>e.snapshot_name===h)??k,j=()=>{r.invalidateQueries({queryKey:v}),r.invalidateQueries({queryKey:b}),t?.()},M=p(Le()),N=p(ke()),P=on(C?.current_channel),F=M.isPending||N.isPending,I=F||un(C)||!C?.latest_preview_release,L=u===`restore_backup`&&!A;if((0,Z.useEffect)(()=>{a(P===`preview`?`release-channel`:void 0)},[P]),!n)return null;let ee=C?.standard_upgrade_available??!1;return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(y.Root,{type:`single`,collapsible:!0,value:i,onValueChange:e=>a(e||void 0),className:`mt-5 border-t border-[var(--border-base)] pt-5`,children:(0,Q.jsxs)(y.Item,{value:`release-channel`,id:`preview-release-channel`,children:[(0,Q.jsxs)(y.Trigger,{className:`group justify-between gap-3`,children:[(0,Q.jsxs)(`span`,{className:`flex min-w-0 items-center gap-2`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-default text-[var(--content-secondary)]`,children:`Release Channel`}),C&&(0,Q.jsx)(S,{tone:P===`preview`?`warning`:`neutral`,children:P===`preview`?`Preview`:`Stable`})]}),(0,Q.jsx)(st,{className:`h-4 w-4 shrink-0 text-[var(--content-tertiary)] transition-transform group-data-[state=open]:rotate-180`})]}),(0,Q.jsx)(y.Content,{children:(0,Q.jsxs)(`div`,{className:`mt-4 space-y-4`,children:[w&&(0,Q.jsxs)(`div`,{className:`flex items-center gap-2 text-body-medium-lighter text-[var(--content-tertiary)]`,children:[(0,Q.jsx)(R,{className:`h-4 w-4 animate-spin`}),`Loading release channel...`]}),T&&(0,Q.jsx)(x,{tone:`error`,title:`Could not load release channel status`,children:`Refresh this page before changing release channels.`}),C&&(0,Q.jsxs)(Q.Fragment,{children:[un(C)&&(0,Q.jsx)(x,{tone:`neutral`,title:`Preview channel is unavailable`,children:`The Preview channel is not enabled for this assistant.`}),P===`stable`?(0,Q.jsx)(fn,{status:C,isChangingChannel:F,optInDisabled:I,onOptIn:()=>s(!0)}):(0,Q.jsx)(pn,{status:C,isChangingChannel:F,onOptOut:()=>{let e=k;g(e?.snapshot_name??``),m(e?`restore_backup`:ee?`standard_upgrade`:`restore_backup`),l(!0)}})]})]})})]})}),(0,Q.jsx)(hn,{open:o,isPending:M.isPending,previewVersion:C?.latest_preview_release?.version,onConfirm:async()=>{try{let t=await M.mutateAsync({path:{assistant_id:e}});D.success(t.detail||`Preview channel enabled.`),s(!1),j()}catch(e){D.error(H(e,void 0,`Could not enable Preview channel.`))}},onCancel:()=>s(!1)}),(0,Q.jsx)(gn,{open:c,backups:O,mode:u,selectedSnapshotName:A?.snapshot_name??``,isPending:N.isPending,restoreModeDisabled:L,standardUpgradeAvailable:ee,onModeChange:m,onSnapshotChange:g,onConfirm:async()=>{if(!L)try{let t=await N.mutateAsync({path:{assistant_id:e},body:u===`restore_backup`?{mode:`restore_backup`,snapshot_name:A?.snapshot_name}:{mode:`standard_upgrade`}});D.success(t.detail||`Stable channel enabled.`),l(!1),j()}catch(e){D.error(H(e,void 0,`Could not switch to Stable.`))}},onCancel:()=>l(!1)})]})}function fn({status:e,isChangingChannel:t,optInDisabled:n,onOptIn:r}){return(0,Q.jsxs)(`div`,{className:`space-y-4`,children:[(0,Q.jsx)(mn,{status:e}),!e.latest_preview_release&&(0,Q.jsx)(x,{tone:`neutral`,title:`No Preview release is available`,children:`Stable remains the only available release channel.`}),(0,Q.jsx)(c,{variant:`outlined`,leftIcon:t?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(it,{}),disabled:n,onClick:r,children:`Opt in to Preview`})]})}function pn({status:e,isChangingChannel:t,onOptOut:n}){return(0,Q.jsxs)(`div`,{className:`space-y-4`,children:[(0,Q.jsx)(mn,{status:e}),(0,Q.jsx)(c,{variant:`outlined`,leftIcon:t?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(Ke,{}),disabled:t,onClick:n,children:`Switch back to Stable`})]})}function mn({status:e}){return(0,Q.jsxs)(`dl`,{className:`grid gap-3 text-body-medium-lighter sm:grid-cols-2`,children:[(0,Q.jsxs)(`div`,{children:[(0,Q.jsx)(`dt`,{className:`text-[var(--content-tertiary)]`,children:`Latest Stable`}),(0,Q.jsx)(`dd`,{className:`break-all text-[var(--content-default)]`,children:e.latest_stable_release?.version??`None`})]}),(0,Q.jsxs)(`div`,{children:[(0,Q.jsx)(`dt`,{className:`text-[var(--content-tertiary)]`,children:`Latest Preview`}),(0,Q.jsx)(`dd`,{className:`break-all text-[var(--content-default)]`,children:e.latest_preview_release?.version??`None`})]})]})}function hn({open:e,isPending:t,previewVersion:n,onConfirm:r,onCancel:i}){return(0,Q.jsx)(E.Root,{open:e,onOpenChange:e=>!e&&i(),children:(0,Q.jsxs)(E.Content,{size:`md`,hideCloseButton:t,children:[(0,Q.jsxs)(E.Header,{children:[(0,Q.jsx)(E.Title,{icon:B,children:`Opt in to Preview`}),(0,Q.jsx)(E.Description,{children:`Preview releases may be unstable. A 90-day safety backup is taken before the image changes.`})]}),(0,Q.jsx)(E.Body,{children:(0,Q.jsxs)(`div`,{className:`space-y-3`,children:[(0,Q.jsx)(x,{tone:`warning`,title:`Data loss may occur when returning to Stable`,children:`Preview data may not be compatible with the Stable channel. The safety backup lets you restore the Stable-channel data that existed before opt-in.`}),(0,Q.jsxs)(`ol`,{className:`list-decimal space-y-2 pl-5 text-body-medium-lighter text-[var(--content-secondary)]`,children:[(0,Q.jsx)(`li`,{children:`Create and verify a Preview safety backup.`}),(0,Q.jsxs)(`li`,{children:[`Switch to Preview image `,n??`latest`,`.`]}),(0,Q.jsx)(`li`,{children:`Run the normal upgrade path and wait for health.`})]})]})}),(0,Q.jsxs)(E.Footer,{children:[(0,Q.jsx)(c,{variant:`outlined`,disabled:t,onClick:i,children:`Cancel`}),(0,Q.jsx)(c,{variant:`primary`,disabled:t,leftIcon:t?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(it,{}),onClick:r,children:t?`Switching...`:`Take Backup and Switch`})]})]})})}function gn({open:e,backups:t,mode:n,selectedSnapshotName:r,isPending:i,restoreModeDisabled:a,standardUpgradeAvailable:o,onModeChange:s,onSnapshotChange:l,onConfirm:u,onCancel:d}){return(0,Q.jsx)(E.Root,{open:e,onOpenChange:e=>!e&&d(),children:(0,Q.jsxs)(E.Content,{size:`md`,hideCloseButton:i,children:[(0,Q.jsxs)(E.Header,{children:[(0,Q.jsx)(E.Title,{icon:B,children:`Switch back to Stable`}),(0,Q.jsx)(E.Description,{children:`Choose how this assistant should leave the Preview channel.`})]}),(0,Q.jsx)(E.Body,{children:(0,Q.jsxs)(`div`,{className:`space-y-4`,children:[(0,Q.jsxs)(v,{value:n,onValueChange:s,disabled:i,"aria-label":`Stable channel return method`,children:[(0,Q.jsx)(_,{value:`restore_backup`,disabled:t.length===0,label:`Restore safety backup`,helperText:`Return to the Stable-channel data captured before Preview opt-in.`}),(0,Q.jsx)(_,{value:`standard_upgrade`,disabled:!o,label:`Switch to Stable without restoring backup`,helperText:o?`Keep the current data and directly switch to the Stable image.`:`Unavailable because the latest Stable release is older than this assistant's Preview release.`})]}),n===`restore_backup`&&t.length>0&&(0,Q.jsxs)(`label`,{className:`flex flex-col gap-1 text-body-medium-default text-[var(--content-secondary)]`,children:[`Safety backup`,(0,Q.jsx)(g,{value:r,onChange:l,disabled:i,options:t.map(e=>({value:e.snapshot_name,label:`${cn(e)} - ${sn(e.created_at)}`}))})]}),n===`restore_backup`&&t.length===0&&!o&&(0,Q.jsx)(x,{tone:`error`,title:`Stable requires a safety backup`,children:`This Preview release is newer than the latest Stable release, so switching directly is blocked. Wait for a newer Stable release, or run Vellum Doctor if the safety backup is missing.`}),n===`standard_upgrade`&&(0,Q.jsx)(x,{tone:`error`,title:`Preview data may not survive this`,children:`Switching directly to the Stable image without restoring the safety backup may cause data loss or leave the assistant unusable if Preview data is incompatible with Stable.`})]})}),(0,Q.jsxs)(E.Footer,{children:[(0,Q.jsx)(c,{variant:`outlined`,disabled:i,onClick:d,children:`Cancel`}),(0,Q.jsx)(c,{variant:n===`standard_upgrade`?`danger`:`primary`,disabled:i||a||n===`standard_upgrade`&&!o,leftIcon:i?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(z,{}),onClick:u,children:i?`Switching...`:`Switch to Stable`})]})]})})}function _n({assistant:e,healthz:t,healthzLoading:n,healthzPolling:r,refetch:i,refetchUntilResized:a}){let o=l(),s=f(Me()),d=s.data,p=!e.is_local,m=d?.plan_id===`pro`,h=f({...Oe(),enabled:m}),_=e.machine_size||`small`,v=ne(h.data?.max_machine_tier??null),y=(0,Z.useMemo)(()=>ie(v,_,(0,Q.jsx)(S,{tone:`positive`,children:`Current`})),[v,_]),b=h.data?.selected_storage_gib??null,[C,w]=(0,Z.useState)(!1),T=v.length>0?v[v.length-1]:null,[O,k]=(0,Z.useState)(null),A=O??T??_,[j,M]=(0,Z.useState)(null),[N,P]=(0,Z.useState)(null),F=Ae({onSuccess:(e,n)=>{D.success(`Resize started. Changes will apply shortly.`,{id:`assistant-resize`}),P(null),k(null),w(!1),n.body?.machine_size==null?i():a(t)},onError:e=>{P(se(e,`Failed to resize assistant. Please try again.`))}});if(s.isError&&d==null)return(0,Q.jsx)(Y,{id:`storage-resources`,title:`Compute & Resources`,subtitle:`Monitor resource usage and manage your assistant's compute profile.`,children:(0,Q.jsx)(x,{tone:`error`,children:`Could not load your subscription. Please try again.`})});let I=m&&v.includes(A)&&A!==_?A:null,L=m&&b!=null&&!0,te=m&&v.length>0&&oe(_)<oe(v[v.length-1]),B=F.isPending||r,V=b==null?t?.disk?.totalMb??null:b*1024,H=t?.disk&&V!=null?{value:t.disk.usedMb,max:V,caption:`${X(t.disk.usedMb)} of ${X(V)}`}:null,U=t?.cpu?{value:t.cpu.currentPercent,max:100,caption:`${t.cpu.currentPercent.toFixed(1)}%`}:null,W=t?.memory?{value:t.memory.currentMb,max:t.memory.maxMb,caption:`${X(t.memory.currentMb)} of ${X(t.memory.maxMb)}`}:null,le=p?m?L?(0,Q.jsxs)(`button`,{type:`button`,disabled:B,onClick:()=>w(!0),className:`flex items-center gap-1.5 rounded-lg border border-amber-500/30 bg-amber-500/15 px-3 py-1.5 text-body-small-default font-medium text-amber-400 transition-colors hover:bg-amber-500/25 disabled:opacity-50`,children:[(0,Q.jsx)(ce,{className:`h-3.5 w-3.5`}),`Increase Storage`]}):(0,Q.jsx)(c,{variant:`ghost`,size:`compact`,disabled:B,onClick:()=>w(!0),children:`Resize`}):(0,Q.jsx)(c,{variant:`ghost`,size:`compact`,onClick:()=>M(`storage`),children:`Resize`}):null,ue=p?m?te?(0,Q.jsxs)(`button`,{type:`button`,disabled:B,onClick:()=>w(!0),className:`flex items-center gap-1.5 rounded-lg border border-amber-500/30 bg-amber-500/15 px-3 py-1.5 text-body-small-default font-medium text-amber-400 transition-colors hover:bg-amber-500/25 disabled:opacity-50`,children:[(0,Q.jsx)(ce,{className:`h-3.5 w-3.5`}),`Increase Size`]}):(0,Q.jsx)(c,{variant:`ghost`,size:`compact`,disabled:B,onClick:()=>w(!0),children:`Resize`}):(0,Q.jsx)(c,{variant:`ghost`,size:`compact`,onClick:()=>M(`machine`),children:`Resize`}):null;return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(Y,{id:`storage-resources`,title:`Compute & Resources`,subtitle:`Monitor resource usage and manage your assistant's compute profile.`,compactAccessory:!0,accessory:(0,Q.jsx)(c,{variant:`ghost`,size:`compact`,iconOnly:n||r?(0,Q.jsx)(R,{className:`animate-spin`}):(0,Q.jsx)(z,{}),tooltip:r?`Applying resize…`:`Refresh resource metrics`,"aria-label":`Refresh resource metrics`,disabled:n||r,onClick:()=>void i()}),children:(0,Q.jsxs)(`div`,{className:`grid grid-cols-1 gap-2 sm:grid-cols-[1fr_2fr]`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col rounded-lg bg-[var(--surface-base)] p-3`,children:[(0,Q.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,Q.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[(0,Q.jsx)(`span`,{className:`text-[var(--content-tertiary)]`,children:(0,Q.jsx)(ee,{className:`h-3.5 w-3.5`})}),(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`Disk`})]}),le]}),(0,Q.jsxs)(`div`,{className:`mt-auto flex flex-col gap-1 pt-3`,children:[(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`Storage`}),H?(0,Q.jsx)(bt,{value:H.value,max:H.max,caption:H.caption}):n?(0,Q.jsx)(`div`,{className:`flex items-center gap-2 text-[var(--content-tertiary)]`,children:(0,Q.jsx)(R,{className:`h-3 w-3 animate-spin`})}):(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`Unavailable`})]})]}),(0,Q.jsxs)(`div`,{className:`flex flex-col rounded-lg bg-[var(--surface-base)] p-3`,children:[(0,Q.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,Q.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[(0,Q.jsx)(`span`,{className:`text-[var(--content-tertiary)]`,children:(0,Q.jsx)(re,{className:`h-3.5 w-3.5`})}),(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`Machine`}),(0,Q.jsx)(S,{tone:`neutral`,children:ae[_]})]}),ue]}),(0,Q.jsxs)(`div`,{className:`mt-auto grid grid-cols-2 gap-3 pt-3`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`CPU`}),U?(0,Q.jsx)(bt,{value:U.value,max:U.max,caption:U.caption}):n?(0,Q.jsx)(`div`,{className:`flex items-center gap-2 text-[var(--content-tertiary)]`,children:(0,Q.jsx)(R,{className:`h-3 w-3 animate-spin`})}):(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`—`})]}),(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`Memory`}),W?(0,Q.jsx)(bt,{value:W.value,max:W.max,caption:W.caption}):n?(0,Q.jsx)(`div`,{className:`flex items-center gap-2 text-[var(--content-tertiary)]`,children:(0,Q.jsx)(R,{className:`h-3 w-3 animate-spin`})}):(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-tertiary)]`,children:`—`})]})]})]})]})}),(0,Q.jsx)(E.Root,{open:j!=null,onOpenChange:e=>{e||M(null)},children:(0,Q.jsxs)(E.Content,{size:`sm`,children:[(0,Q.jsxs)(E.Header,{children:[(0,Q.jsx)(E.Title,{children:`Upgrade to Pro`}),(0,Q.jsx)(E.Description,{children:j===`storage`?`Upgrade to the Pro plan to increase your storage allocation and get more space for your assistant.`:`Upgrade to the Pro plan to unlock larger machine sizes with more CPU and memory for your assistant.`})]}),(0,Q.jsxs)(E.Footer,{children:[(0,Q.jsx)(c,{variant:`ghost`,onClick:()=>M(null),children:`Cancel`}),(0,Q.jsx)(c,{onClick:()=>{M(null),o(`${G.settings.billing}?adjust_plan=1`)},children:`Upgrade`})]})]})}),(0,Q.jsx)(E.Root,{open:C,onOpenChange:e=>{e||(w(!1),k(null),P(null))},children:(0,Q.jsxs)(E.Content,{size:`sm`,children:[(0,Q.jsxs)(E.Header,{children:[(0,Q.jsx)(E.Title,{icon:re,children:`Resize Assistant`}),(0,Q.jsx)(E.Description,{children:`Resize your assistant's compute and storage. Your assistant will briefly restart.`})]}),(0,Q.jsx)(E.Body,{children:(0,Q.jsxs)(`div`,{className:`flex flex-col gap-3`,children:[v.length===0?(0,Q.jsx)(x,{tone:`warning`,children:`No machine tier configured. Visit the community for help.`}):(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,Q.jsx)(`span`,{className:`text-label-medium-default text-[var(--content-secondary)]`,children:`Machine Size`}),(0,Q.jsx)(g,{options:y,value:A,onChange:k,"aria-label":`Compute machine size`,"data-testid":`resize-machine-size`})]}),L?(0,Q.jsx)(x,{tone:`info`,children:`Storage will be expanded to ${b} GiB.`}):(0,Q.jsx)(x,{tone:`neutral`,children:`Storage will not change.`}),N&&(0,Q.jsx)(x,{tone:`error`,children:N})]})}),(0,Q.jsxs)(E.Footer,{className:`items-center justify-between`,children:[(0,Q.jsxs)(`span`,{className:`text-label-small-default text-[var(--content-tertiary)]`,children:[`Need more?`,` `,(0,Q.jsx)(u,{to:`${G.settings.billing}?adjust_plan=1`,className:`text-[var(--content-secondary)] underline decoration-[var(--border-element)] underline-offset-2 transition-colors hover:text-[var(--content-default)]`,onClick:()=>w(!1),children:`Upgrade plan`})]}),(0,Q.jsxs)(`div`,{className:`flex gap-2`,children:[(0,Q.jsx)(c,{variant:`ghost`,onClick:()=>{w(!1),k(null),P(null)},children:`Cancel`}),(0,Q.jsx)(c,{disabled:I==null&&!L||B,leftIcon:B?(0,Q.jsx)(R,{className:`animate-spin`}):void 0,onClick:()=>{P(null);let t={};I!=null&&(t.machine_size=I),L&&b!=null&&(t.storage_gib=b),F.mutate({path:{id:e.id},body:t})},children:N?`Retry`:`Apply`})]})]})]})})]})}function vn({assistantId:e}){let t=l(),[n,r]=(0,Z.useState)(!1),[i,a]=(0,Z.useState)(!1);return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(c,{variant:`dangerOutline`,onClick:()=>r(!0),className:`shrink-0`,children:`Retire Assistant`}),(0,Q.jsx)(Ge,{open:n,isPending:i,onConfirm:async()=>{a(!0);let n=await tt(e);if(n.ok){r(!1),t(n.nextRoute,{replace:!0});return}D.error(n.error),a(!1),r(!1)},onCancel:()=>r(!1)})]})}var yn=`UTC.Africa/Cairo.Africa/Johannesburg.Africa/Lagos.Africa/Nairobi.America/Anchorage.America/Argentina/Buenos_Aires.America/Bogota.America/Chicago.America/Denver.America/Halifax.America/Lima.America/Los_Angeles.America/Mexico_City.America/New_York.America/Phoenix.America/Santiago.America/Sao_Paulo.America/Toronto.America/Vancouver.Asia/Bangkok.Asia/Dubai.Asia/Hong_Kong.Asia/Jakarta.Asia/Jerusalem.Asia/Karachi.Asia/Kolkata.Asia/Kuala_Lumpur.Asia/Manila.Asia/Seoul.Asia/Shanghai.Asia/Singapore.Asia/Taipei.Asia/Tokyo.Australia/Melbourne.Australia/Perth.Australia/Sydney.Europe/Amsterdam.Europe/Athens.Europe/Berlin.Europe/Brussels.Europe/Dublin.Europe/Istanbul.Europe/Lisbon.Europe/London.Europe/Madrid.Europe/Moscow.Europe/Paris.Europe/Rome.Europe/Stockholm.Europe/Vienna.Europe/Warsaw.Europe/Zurich.Pacific/Auckland.Pacific/Honolulu`.split(`.`);function bn(){let e=Intl;if(typeof e.supportedValuesOf==`function`)try{let t=e.supportedValuesOf(`timeZone`);if(t.length>0)return[...t].sort()}catch{}return[...yn].sort()}function xn(e){let t=e.split(`/`),n=(t[t.length-1]??e).replace(/_/g,` `),r=t.length>1?(t[0]??``).replace(/_/g,` `):``,i=0,a=``;try{let t=new Intl.DateTimeFormat(`en-US`,{timeZone:e,timeZoneName:`shortOffset`}).formatToParts(new Date).find(e=>e.type===`timeZoneName`)?.value??`GMT`;a=t.startsWith(`GMT`)||t.startsWith(`UTC`)?t:`GMT ${t}`;let n=t.match(/([+-])(\d{1,2})(?::(\d{2}))?/);if(n){let e=n[1]===`-`?-1:1,t=parseInt(n[2]??`0`,10),r=parseInt(n[3]??`0`,10);i=e*(t*60+r)}}catch{return null}return{identifier:e,city:n,region:r,offsetLabel:a,offsetMinutes:i}}function Sn(e){try{return new Intl.DateTimeFormat(`en-US`,{timeZone:e,hour:`numeric`,minute:`2-digit`,hour12:!0}).format(new Date)}catch{return``}}function Cn(e){if(!e)return`Not set`;try{let t=new Intl.DateTimeFormat(`en-US`,{timeZone:e,timeZoneName:`long`}).formatToParts(new Date).find(e=>e.type===`timeZoneName`)?.value;if(t)return t}catch{}return e.replace(/_/g,` `)}function wn({value:e,onChange:t}){let[n,r]=(0,Z.useState)(``),[i,a]=(0,Z.useState)(``),[o,s]=(0,Z.useState)(!1),c=(0,Z.useRef)(null),l=(0,Z.useRef)(null),u=(0,Z.useMemo)(()=>bn().map(e=>xn(e)).filter(e=>e!==null),[]);(0,Z.useEffect)(()=>{let e=window.setTimeout(()=>{a(n.trim().toLowerCase())},200);return()=>window.clearTimeout(e)},[n]),(0,Z.useEffect)(()=>{if(!o)return;let e=e=>{c.current&&!c.current.contains(e.target)&&s(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[o]);let d=(0,Z.useMemo)(()=>i?u.filter(e=>e.city.toLowerCase().includes(i)||e.region.toLowerCase().includes(i)||e.offsetLabel.toLowerCase().includes(i)||e.identifier.toLowerCase().includes(i)):u,[u,i]),f=(0,Z.useMemo)(()=>{if(!e)return``;let t=e.split(`/`);return(t[t.length-1]??e).replace(/_/g,` `)},[e]),p=e=>{t(e),r(``),s(!1),l.current?.blur()};return(0,Q.jsxs)(`div`,{ref:c,className:`space-y-3`,children:[(0,Q.jsxs)(`div`,{className:`flex flex-col gap-1.5 md:flex-row md:items-center md:justify-between md:gap-4`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-lighter text-[var(--content-tertiary)]`,children:`Closest city`}),(0,Q.jsxs)(`div`,{className:`relative w-full md:max-w-[280px]`,children:[(0,Q.jsx)(C,{ref:l,type:`text`,value:n,placeholder:f||`Search city or country...`,onChange:e=>{r(e.target.value),s(!0)},onFocus:()=>s(!0),onKeyDown:e=>{e.key===`Escape`&&(r(``),s(!1),l.current?.blur())},fullWidth:!0}),o&&d.length>0&&(0,Q.jsx)(`div`,{className:`absolute left-0 right-0 top-full z-20 mt-1 max-h-[240px] overflow-y-auto rounded-md border border-[var(--border-base)] bg-[var(--surface-lift)] shadow-lg`,children:d.slice(0,200).map(t=>(0,Q.jsxs)(`button`,{type:`button`,onClick:()=>p(t.identifier),className:`flex w-full cursor-pointer items-center justify-between gap-3 px-3 py-2 text-left text-body-medium-lighter transition-colors ${t.identifier===e?`bg-[var(--surface-active)] text-[var(--content-default)]`:`text-[var(--content-default)] hover:bg-[var(--surface-active)]`}`,children:[(0,Q.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,Q.jsx)(`div`,{className:`truncate text-body-medium-default`,children:t.city}),t.region&&(0,Q.jsx)(`div`,{className:`truncate text-body-small-default text-[var(--content-tertiary)]`,children:t.region})]}),(0,Q.jsxs)(`div`,{className:`flex shrink-0 flex-col items-end gap-0.5 text-body-small-default text-[var(--content-tertiary)]`,children:[(0,Q.jsx)(`span`,{children:Sn(t.identifier)}),(0,Q.jsx)(`span`,{children:t.offsetLabel})]})]},t.identifier))})]})]}),(0,Q.jsx)(en,{}),(0,Q.jsxs)(`div`,{className:`flex items-center justify-between gap-4`,children:[(0,Q.jsx)(`span`,{className:`text-body-medium-lighter text-[var(--content-tertiary)]`,children:`Time zone`}),(0,Q.jsx)(`span`,{className:`text-body-medium-lighter text-[var(--content-default)]`,children:Cn(e)})]})]})}function Tn(){let e=K.use.velvet(),[t,n]=(0,Z.useState)(()=>We({velvetEnabled:e}));return(0,Z.useEffect)(()=>{n(We({velvetEnabled:e}))},[e]),(0,Z.useEffect)(()=>a(`theme`,()=>{n(We({velvetEnabled:e}))}),[e]),(0,Z.useEffect)(()=>{nt(t)},[t]),(0,Q.jsx)(Y,{title:`Theme`,children:(0,Q.jsx)(`div`,{className:`max-w-[360px]`,children:(0,Q.jsx)(T,{ariaLabel:`Theme`,value:t,onChange:e=>{n(e),et(e),nt(e)},items:[{value:`system`,label:`System`,icon:(0,Q.jsx)(mt,{className:`h-4 w-4`})},{value:`light`,label:`Light`,icon:(0,Q.jsx)(Ze,{className:`h-4 w-4`})},{value:`dark`,label:`Dark`,icon:(0,Q.jsx)(te,{className:`h-4 w-4`})},...e?[{value:`velvet`,label:`Velvet`,icon:(0,Q.jsx)(_t,{className:`h-4 w-4`})}]:[]]})})})}function En(){let e=N.use.activeAssistantId(),[t,n]=(0,Z.useState)(()=>i(`timezone`,``)),a=(0,Z.useRef)(e);(0,Z.useEffect)(()=>{a.current=e},[e]);let s=(0,Z.useRef)(!1),c=(0,Z.useRef)(null),l=(0,Z.useRef)(()=>{}),u=e=>{if(s.current){c.current=e;return}let t=a.current;if(!t){c.current=null;return}s.current=!0,c.current=null,_e.patch({url:`/v1/assistants/{assistant_id}/config`,path:{assistant_id:t},body:{ui:{userTimezone:e}},throwOnError:!0}).catch(e=>{o(e,{context:`settings-timezone-override`})}).finally(()=>{s.current=!1;let e=c.current;c.current=null,e!==null&&l.current(e)})};return(0,Z.useEffect)(()=>{l.current=u}),(0,Q.jsx)(Y,{title:`Timezone`,subtitle:`Used when displaying times and scheduling reminders.`,children:(0,Q.jsx)(wn,{value:t,onChange:e=>{n(e),r(`timezone`,e),u(e)}})})}function Dn(){let{assistant:e,assistantLoading:t,healthz:n,healthzLoading:r,healthzPolling:i,refetch:a,refetchUntilResized:o}=xt(),s=K.use.multiPlatformAssistant(),c=Ce.use.settingsSleepPolicy(),u=de(),d=l(),f=ft(),p=ft({platformHostedOnly:!0}),m=Ue(),h=lt({assistantId:e?.id??null,enabled:p===`full`&&m}),g=e?.is_local&&!A()?null:e,_=O(),v=A()&&!!e&&!!_&&k(_),y=v,b=v&&!j();return(0,Z.useEffect)(()=>{!e||window.location.hash!==`#storage-resources`||requestAnimationFrame(()=>{document.getElementById(`storage-resources`)?.scrollIntoView({block:`start`})})},[e]),(0,Q.jsxs)(`div`,{className:`space-y-4`,children:[h.status&&h.mode!==`inactive`&&(0,Q.jsx)(rt,{status:h.status,mode:h.mode,isAcknowledging:h.isAcknowledging,acknowledgeError:h.acknowledgeError?.message??null,onAcknowledge:()=>void h.acknowledge(),onReviewWorkspaceData:()=>void d(`${G.workspace}?sort=size`),onUpgradeStorage:p===`full`?()=>void d(`${G.settings.billing}?adjust_plan=1`):null}),(0,Q.jsx)(Y,{title:`General`,children:(0,Q.jsx)(St,{assistant:g,assistantLoading:t,healthz:n,healthzLoading:r})}),u&&f===`full`&&(0,Q.jsx)(It,{assistant:m?g:null}),p===`full`&&e&&(0,Q.jsx)(_n,{assistant:e,healthz:n,healthzLoading:r,healthzPolling:i,refetch:a,refetchUntilResized:o}),p===`disabled`&&(0,Q.jsx)(Y,{id:`storage-resources`,title:`Compute & Resources`,subtitle:`Monitor resource usage and manage your assistant's compute profile.`,children:(0,Q.jsx)(J,{children:`Log in to the Vellum platform to manage compute resources.`})}),(0,Q.jsx)(Tn,{}),(0,Q.jsx)(qt,{}),M()&&(0,Q.jsx)($t,{}),p===`full`&&g&&(0,Q.jsxs)(Y,{title:`Software Updates`,children:[(0,Q.jsx)(Gt,{assistantId:g.id,currentVersion:n?.version??g.current_release_version??null,releaseChannel:g.release_channel,onUpgradeComplete:()=>{a()}}),(0,Q.jsx)(dn,{assistantId:g.id,onComplete:()=>{a()}})]}),b&&e&&(0,Q.jsx)(Y,{title:`Software Updates`,children:(0,Q.jsx)(Kt,{assistantId:e.id,currentVersion:n?.version??e.current_release_version??null,onUpgradeComplete:()=>{a()}})}),p===`disabled`&&!b&&(0,Q.jsx)(Y,{title:`Software Updates`,children:(0,Q.jsx)(J,{children:`Log in to the Vellum platform to manage software updates.`})}),(0,Q.jsx)(Xt,{}),p===`full`&&g&&c&&(0,Q.jsx)(Y,{title:`Sleep Policy`,subtitle:`Control how long this assistant stays awake when idle.`,children:(0,Q.jsx)(Vt,{assistantId:g.id})}),p===`disabled`&&c&&(0,Q.jsx)(Y,{title:`Sleep Policy`,subtitle:`Control how long this assistant stays awake when idle.`,children:(0,Q.jsx)(J,{children:`Log in to the Vellum platform to manage sleep policy.`})}),(0,Q.jsx)(En,{}),(0,Q.jsx)(an,{}),s&&(0,Q.jsx)(Rt,{}),(f===`full`||y)&&g&&(0,Q.jsx)(Y,{variant:`danger`,title:`Retire Assistant`,subtitle:`Permanently retire this assistant and delete all associated data.`,children:(0,Q.jsx)(vn,{assistantId:g.id})}),f===`disabled`&&!y&&(0,Q.jsx)(Y,{variant:`danger`,title:`Retire Assistant`,subtitle:`Permanently retire this assistant and delete all associated data.`,children:(0,Q.jsx)(J,{children:`Log in to the Vellum platform to retire this assistant.`})}),(0,Q.jsx)(Jt,{})]})}export{Dn as GeneralPage};
@@ -1 +1 @@
1
- import{t as e}from"./createLucideIcon-DIlBzeWM.js";var t=e(`globe`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,key:`13o1zl`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}]]);export{t};
1
+ import{t as e}from"./createLucideIcon-KBgJOpms.js";var t=e(`globe`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,key:`13o1zl`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}]]);export{t};
@@ -0,0 +1 @@
1
+ import{t as e}from"./jsx-runtime-CVSDxk6A.js";var t=e();function n({size:e=24,className:n,style:r}){return(0,t.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 48 48`,width:e,height:e,className:n,style:r,"aria-hidden":!0,children:[(0,t.jsx)(`path`,{fill:`#EA4335`,d:`M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z`}),(0,t.jsx)(`path`,{fill:`#4285F4`,d:`M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z`}),(0,t.jsx)(`path`,{fill:`#FBBC05`,d:`M10.53 28.59a14.5 14.5 0 0 1 0-9.18l-7.97-6.19A23.99 23.99 0 0 0 0 24c0 3.77.9 7.35 2.56 10.78l7.97-6.19z`}),(0,t.jsx)(`path`,{fill:`#34A853`,d:`M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z`})]})}export{n as t};
@@ -1 +1 @@
1
- import{t as e}from"./createLucideIcon-DIlBzeWM.js";var t=e(`hard-drive`,[[`path`,{d:`M10 16h.01`,key:`1bzywj`}],[`path`,{d:`M2.212 11.577a2 2 0 0 0-.212.896V18a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-5.527a2 2 0 0 0-.212-.896L18.55 5.11A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`,key:`18tbho`}],[`path`,{d:`M21.946 12.013H2.054`,key:`zqlbp7`}],[`path`,{d:`M6 16h.01`,key:`1pmjb7`}]]);export{t};
1
+ import{t as e}from"./createLucideIcon-KBgJOpms.js";var t=e(`hard-drive`,[[`path`,{d:`M10 16h.01`,key:`1bzywj`}],[`path`,{d:`M2.212 11.577a2 2 0 0 0-.212.896V18a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-5.527a2 2 0 0 0-.212-.896L18.55 5.11A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`,key:`18tbho`}],[`path`,{d:`M21.946 12.013H2.054`,key:`zqlbp7`}],[`path`,{d:`M6 16h.01`,key:`1pmjb7`}]]);export{t};
@@ -0,0 +1 @@
1
+ import{o as e}from"./chunk-jRWAZmH_.js";import{o as t,t as n}from"./capture-error-CN7ObyIk.js";import{t as r}from"./react-DJZBPgpf.js";import{t as i}from"./button-D7s2Q_uG.js";import{d as a,h as o}from"./chunk-5KNZJZUH-DdS6bb-3.js";import{n as s}from"./QueryClientProvider-DKhXIxGb.js";import{t as c}from"./jsx-runtime-CVSDxk6A.js";import{t as l}from"./progress-bar-DFH5aT1D.js";import{J as ee,T as te,_ as ne,b as u,f as d,g as re,i as ie,s as f}from"./local-mode-Bg6wpc5q.js";import{t as p}from"./is-electron-CcgCla1v.js";import{n as m}from"./resolved-assistants-store-IMxY1_w9.js";import{r as ae}from"./api-errors-C3sAdlZQ.js";import{$ as h,J as g,M as oe,Y as _,at as se,it as v,l as y,n as b,nt as ce,rt as le}from"./auth-store-6CnXVIAL.js";import{a as ue,o as de,r as x}from"./api-kMnfZUPa.js";import{a as S}from"./routes-BLyehs4B.js";import{r as C,t as w}from"./build-state-CjVnPOtQ.js";import{i as fe,p as pe}from"./prefs-CrgkSe-_.js";import{t as T}from"./avatar-svg-compositor-DMT4wmUm.js";import{On as E,Tn as D,_t as O,kn as k}from"./index-Chr1kHBM.js";import{t as me}from"./provider-key-CK_U6Kex.js";import{BUNDLED_COMPONENTS as A}from"./avatar-bundled-components-f4-fradg.js";var j=e(r(),1);async function he(e,t,r){try{await E(e)||await k(e,t),r.invalidateQueries({queryKey:D(e)})}catch(e){n(e,{context:`onboarding_avatar_sync`})}}function M(e){let t=e=>e[Math.floor(Math.random()*e.length)];return{bodyShape:t(e.bodyShapes).id,eyeStyle:t(e.eyeStyles).id,color:t(e.colors).id}}var N=c(),P=3e3,ge=800,F=3e5,I=null,L=null,_e={initializing:0,provisioning:.33,connecting:.66,ready:1},R=1500,ve={initializing:`Getting things ready…`,provisioning:`Setting up your assistant…`,connecting:`Connecting to your assistant…`,ready:`Ready`};function z(e,t,n){if(e>=t)return t;let r=1-(1-Math.min(1,n/R))**3;return e+(t-e)*r}function ye(){let e=C(w(),{kind:`hatch-gate`});return e.action===`redirect`?{kind:`redirect`,to:e.to}:e.action===`wait`?{kind:`wait`}:{kind:`proceed`}}function B(){let e=a(),r=s(),[c]=o(),C=c.get(`hosting`),w=c.get(`fail`),E=p(),D=d()&&C!==null&&C!==`vellum-cloud`,k=b.use.sessionStatus(),R=D?h(k):k,[B]=(0,j.useState)(()=>M(A)),V=(0,j.useMemo)(()=>{let e=T(A,B.bodyShape,B.eyeStyle,B.color,320);return`data:image/svg+xml;charset=utf-8,${encodeURIComponent(e)}`},[B]),[H,U]=(0,j.useState)(`initializing`),[W,G]=(0,j.useState)(null),[be,K]=(0,j.useState)(!1),[xe,Se]=(0,j.useState)(0),[Ce,q]=(0,j.useState)(0),[we,J]=(0,j.useState)(0),Y=(0,j.useRef)(H),X=(0,j.useRef)(0),Z=(0,j.useRef)(0),Q=(0,j.useRef)(0),$=(0,j.useCallback)(e=>{X.current=Q.current,Z.current=Date.now(),Y.current=e,U(e),J(e=>e+1)},[]);return(0,j.useEffect)(()=>{if(w!==null){G(`Simulated hatch failure (developer menu → Replay Hatch Failure).`);return}let i=ye();if(i.kind===`redirect`){e(i.to,{replace:!0});return}if(i.kind===`wait`)return;K(!1);let a=!1,o=null,s=null,c=null,l=Date.now(),p,h=!1,T=!1,E=fe(),O=()=>{try{pe(``)}catch(e){n(e,{context:`onboarding_mark_completed`})}q(1),Q.current=1,X.current=1,U(`ready`),Y.current=`ready`,s=setTimeout(()=>{a||(async()=>{if(await _.checkAssistant(),!a){if(oe()){_.markExpectingFirstMessage(),e(`${S.assistant}?onboarding=1`,{replace:!0});return}e(S.onboarding.prechat,{replace:!0})}})()},ge)},k=e=>he(e,B,r),A=async()=>{if($(`provisioning`),!D){try{let e=await x(),t=v(e);if(!a&&e.ok&&t.kind===`active`){d()&&u({assistantId:e.data.id,name:e.data.name,cloud:`vellum`,runtimeUrl:f(),hatchedAt:new Date().toISOString(),organizationId:y.getState().currentOrganizationId??void 0}),O();return}t.kind===`auto_hatch`&&(T=!0)}catch{}if(a)return}if(D){try{I||=te(void 0,C===`docker`?`docker`:void 0);let e=await I;if(I=null,a)return;if(!e.ok){G(e.error??`Failed to hatch local assistant.`);return}await re(),e.assistantId&&g(e.assistantId),$(`connecting`);let t=!1;for(;!a&&!t;){let e=ie();if(e)try{let n=await fetch(`${e}/readyz`);if(n.ok){let e=await n.json();if(e&&typeof e==`object`&&`status`in e&&e.status===`ok`){ee(),await ne(),t=!0;break}}}catch{}if(Date.now()-l>=F){G(`Your assistant is taking longer than expected. Please try again.`);return}await new Promise(e=>{c=setTimeout(e,P)}),c=null}if(a)return;if(e.assistantId&&await b.getState().connectLocalAssistant(e.assistantId),e.assistantId){try{await me(e.assistantId)}catch(e){n(e,{context:`onboarding_apply_provider_key`})}m.getState().upsertFromApi({id:e.assistantId,name:e.assistantId,status:`active`,is_local:!0,created:new Date().toISOString()}),g(e.assistantId),k(e.assistantId)}O()}catch{if(I=null,a)return;G(`Failed to hatch local assistant. Check CLI logs for details.`)}return}try{L||=de(E?{version:E}:void 0);let e=await L;if(L=null,a)return;if(e.ok&&(p=e.data.id),h=e.ok&&e.status===201,!e.ok){if(t(`Onboarding hatch request failed`,{level:`warning`,extra:{status:e.status,error:e.error}}),le(e.status,e.error)){G(ce),K(!0);return}if(!se(e.status)){G(ae(e.error,void 0,`Failed to start your assistant. Please try again.`));return}}}catch(e){if(L=null,n(e,{context:`onboarding_hatch_assistant`}),a)return}j(0)},j=e=>{a||(o=setTimeout(M,e))},M=async()=>{if(!a){if(Date.now()-l>=F){t(`Onboarding hatch wait exceeded timeout`,{level:`warning`,extra:{maxWaitMs:F}}),G(`Your assistant is taking longer than expected. Please try again.`);return}try{let e=await x(p);if(a||p&&!e.ok&&e.status===404&&(p=void 0,e=await x(),a))return;let t=v(e);if(t.kind===`active`){if(e.ok){let t=e.data.id;for(m.getState().upsertFromApi(e.data),g(t),(h||T)&&k(t),d()&&u({assistantId:t,name:e.data.name,cloud:`vellum`,runtimeUrl:f(),hatchedAt:new Date().toISOString(),organizationId:y.getState().currentOrganizationId??void 0}),$(`connecting`);!a;){try{if((await ue(t)).ok)break}catch{}if(Date.now()-l>=F){G(`Your assistant is taking longer than expected. Please try again.`);return}await new Promise(e=>{o=setTimeout(e,P)}),o=null}if(a)return}O();return}if(t.kind===`error`){G(t.message);return}t.kind!==`auto_hatch`&&Y.current===`provisioning`&&$(`connecting`),j(P)}catch(e){if(n(e,{context:`onboarding_poll_assistant`}),a)return;j(P)}}};return A(),()=>{a=!0,o&&clearTimeout(o),s&&clearTimeout(s),c&&clearTimeout(c)}},[xe,w,B,R,e,r,$,D]),(0,j.useEffect)(()=>{Z.current===0&&(Z.current=Date.now());let e,t=()=>{let n=Date.now()-Z.current,r=_e[Y.current],i=z(X.current,r,n);Q.current=i,q(i),r-i>1e-6&&(e=requestAnimationFrame(t))};return e=requestAnimationFrame(t),()=>cancelAnimationFrame(e)},[we]),W?(0,N.jsx)(O,{children:(0,N.jsxs)(`div`,{role:`alert`,className:`mx-auto flex w-full max-w-xl flex-col items-center ${E?`min-h-full px-8 pt-21 pb-28 electron-prechat-type`:`min-h-screen justify-center px-6 pb-40`} text-center text-[var(--content-default)]`,children:[(0,N.jsx)(`h1`,{className:E?`text-title-large`:`text-3xl font-semibold tracking-tight`,children:`Something went wrong`}),(0,N.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--content-tertiary)] ${E?`mt-3.5`:`mt-4`}`,children:W}),be&&(0,N.jsxs)(`div`,{className:`mt-6 flex w-full max-w-sm flex-col items-center gap-3`,children:[(0,N.jsx)(`p`,{className:`text-body-medium-default text-[var(--content-default)]`,children:`Get started today with a local assistant`}),(0,N.jsx)(i,{asChild:!0,variant:`primary`,size:`regular`,fullWidth:!0,className:E?void 0:`h-11 text-base`,children:(0,N.jsx)(`a`,{href:`${window.location.origin}/download`,children:`Download the macOS app`})})]}),(0,N.jsx)(`img`,{src:V,alt:``,width:160,height:160,className:`${E?`my-auto py-8`:`my-16`} onboarding-avatar-failed`}),(0,N.jsxs)(`div`,{className:`flex w-full flex-col ${E?`gap-2.5 max-w-[280px]`:`gap-2 max-w-sm`}`,children:[(0,N.jsx)(i,{variant:`primary`,size:`regular`,fullWidth:!0,className:E?void 0:`h-11 text-base`,onClick:()=>{X.current=0,Z.current=Date.now(),Y.current=`initializing`,Q.current=0,U(`initializing`),q(0),J(e=>e+1),G(null),K(!1),Se(e=>e+1)},children:`Try again`}),(0,N.jsx)(i,{variant:`outlined`,size:`regular`,fullWidth:!0,className:E?void 0:`h-11 text-base`,onClick:()=>void e(D?S.onboarding.hosting:S.onboarding.privacy,{replace:!0}),children:`Back`})]})]})}):(0,N.jsx)(O,{children:(0,N.jsxs)(`div`,{className:`mx-auto flex w-full max-w-xl flex-col items-center ${E?`min-h-full px-8 pt-21 pb-28 electron-prechat-type`:`min-h-screen justify-center px-6 pb-40`} text-center text-[var(--content-default)]`,children:[(0,N.jsx)(`h1`,{className:E?`text-title-large`:`text-3xl font-semibold tracking-tight`,children:H===`ready`?`Your assistant is ready!`:`Waking up…`}),H!==`ready`&&(0,N.jsx)(`p`,{className:`text-body-medium-lighter text-[var(--content-tertiary)] ${E?`mt-3.5`:`mt-4`}`,children:`Hang tight — your assistant will have a few questions for you once it's up.`}),(0,N.jsx)(`img`,{src:V,alt:``,width:160,height:160,className:`${E?`my-auto py-8`:`my-16`} ${H===`ready`?`onboarding-avatar-awake`:`onboarding-avatar-pulse`}`}),(0,N.jsx)(l,{value:Ce,height:6,className:`w-full ${E?`max-w-[200px]`:`max-w-sm`}`,"aria-label":`Assistant startup progress`}),(0,N.jsx)(`p`,{className:`text-[var(--content-tertiary)] ${E?`mt-4 text-label-small-default`:`mt-3 text-body-small-default`}`,children:ve[H]})]})})}export{B as HatchingScreen};