@openhands/agent-canvas 1.16.0 → 1.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/README.windows.md +2 -2
- package/build/assets/{acp-providers-CX3Lh9gj.js → acp-providers-DcY_mKYa.js} +1 -1
- package/build/assets/active-backend-context-BnH4-L8h.js +2 -0
- package/build/assets/{agent-context-settings-DSZlXrLj.js → agent-context-settings-D3peZkjX.js} +1 -1
- package/build/assets/agent-profiles-service.api-DkeZaqIl.js +1 -0
- package/build/assets/agent-profiles-settings-7yMWYjGF.js +1 -0
- package/build/assets/agent-server-client-options-EHB23gyx.js +1 -0
- package/build/assets/agent-server-config-C_x8Otd9.js +1 -0
- package/build/assets/agent-server-conversation-service.api-jiCopc2E.js +88 -0
- package/build/assets/agent-settings-BF8hM6wb.js +2 -0
- package/build/assets/agent-settings-YPutBAeR.js +1 -0
- package/build/assets/alert-banner-eYyqvHL3.js +1 -0
- package/build/assets/{api-error-message-B-XdSk3b.js → api-error-message-BXo0lCI5.js} +1 -1
- package/build/assets/api-key-entry-screen-CCBvBD8u.js +1 -0
- package/build/assets/app-settings-BtYDs-Be.js +1 -0
- package/build/assets/automation-detail-BxXhb_m2.js +3 -0
- package/build/assets/{automation-export-D3a3of4G.js → automation-export-BJsfi7n2.js} +1 -1
- package/build/assets/automation-git-sync-B7o_Nbl-.js +1 -0
- package/build/assets/automation-setup-route-qaJ6lLCf.js +3 -0
- package/build/assets/{automation-templates-BRppNh99.js → automation-templates-Bb98r-kx.js} +1 -1
- package/build/assets/automations-list-DEPVNud3.js +1 -0
- package/build/assets/{back-nav-button-Cjl_hoxq.js → back-nav-button-B2yBiVMB.js} +1 -1
- package/build/assets/backend-form-modal-DxisQV_6.js +1 -0
- package/build/assets/backend-synced-settings-badge-DLEp6cq7.js +1 -0
- package/build/assets/badge-ehL-kgeO.js +1 -0
- package/build/assets/{base-modal-D_L0oEbG.js → base-modal-C1a0TsSx.js} +1 -1
- package/build/assets/bot-ByolqPEr.js +1 -0
- package/build/assets/{brand-button-BAfk4wGP.js → brand-button-CUMfjb99.js} +1 -1
- package/build/assets/browser-SE24Tk8g.js +46 -0
- package/build/assets/browser-tab-HjJxHA0V.js +1 -0
- package/build/assets/canvas-extension-page-BsUGBb1T.js +1 -0
- package/build/assets/canvas-extensions-C9Tm6s_E.js +1 -0
- package/build/assets/{canvas-extensions-runtime-2_x5Ezmi.js → canvas-extensions-runtime-B8kxM4rO.js} +1 -1
- package/build/assets/{chat-send-button-MUQqCZCS.js → chat-send-button-CGvc2wpE.js} +1 -1
- package/build/assets/check-Bo8s5Ylg.js +1 -0
- package/build/assets/chevron-down-Cr6Fn_wS.js +1 -0
- package/build/assets/chevron-right-CfdfRn-8.js +1 -0
- package/build/assets/circle-check-5pH3qCji.js +1 -0
- package/build/assets/circle-plus-check-toggle-BDX_ctNs.js +1 -0
- package/build/assets/{cloud-funnel-analytics-CztBCCPp.js → cloud-funnel-analytics-D5uJ_4JE.js} +1 -1
- package/build/assets/{cog-D-MPQW6G.js → cog-CAEugqtV.js} +1 -1
- package/build/assets/command-menu-CQxs4mtX.js +1 -0
- package/build/assets/commits-tab-D0xgjipP.js +1 -0
- package/build/assets/{condenser-settings-DmEOje-7.js → condenser-settings-D63NJRBT.js} +1 -1
- package/build/assets/confirmation-modal-78sd9Vny.js +1 -0
- package/build/assets/{context-menu-list-item-I86vKcmM.js → context-menu-list-item-Cm7-7Y-7.js} +1 -1
- package/build/assets/conversation-B_nweu5p.js +93 -0
- package/build/assets/conversation-edjzrv5w.js +1 -0
- package/build/assets/conversation-panel-edjzrv5w.js +1 -0
- package/build/assets/conversation-state-store-9D_3P7q4.js +1 -0
- package/build/assets/conversation-store-DC-JlJuq.js +6 -0
- package/build/assets/{conversation-tab-empty-state-FIbh_lc8.js → conversation-tab-empty-state-B3dpJXX0.js} +1 -1
- package/build/assets/copy-to-clipboard-button-B1ljgNxO.js +1 -0
- package/build/assets/device-verify-D5QRIS_x.js +1 -0
- package/build/assets/{dropdown-classes-Bc1djN0-.js → dropdown-classes-BGvOvW2_.js} +1 -1
- package/build/assets/edit-automation-modal-D_JWSmxT.js +1 -0
- package/build/assets/empty-state-FK_s1B60.js +1 -0
- package/build/assets/{entry.client-CqyPPjOq.js → entry.client-BMafTpjO.js} +2 -2
- package/build/assets/enum-filter-dropdown-UNaom12H.js +1 -0
- package/build/assets/environment-switch-overlay-COibRUA-.js +1 -0
- package/build/assets/error-state-Cf8LRuuY.js +1 -0
- package/build/assets/extensions-hub-C_6ahIua.js +1 -0
- package/build/assets/extensions-navigation-C5GfpzFe.js +1 -0
- package/build/assets/external-link-Bd7Tga-1.js +1 -0
- package/build/assets/files-tab-D5PPIWI1.js +1 -0
- package/build/assets/{form-control-classes-Bkh5FGrD.js → form-control-classes-Dbq-7YP_.js} +1 -1
- package/build/assets/format-model-name-Dfh9Udrx.js +1 -0
- package/build/assets/get-git-path-jU2zjqIB.js +1 -0
- package/build/assets/git-repo-dropdown-BoDDWXfX.js +1 -0
- package/build/assets/git-repo-dropdown-uxlFw2gn.js +1 -0
- package/build/assets/highlighted-source-view-C7pAXrT0.js +1 -0
- package/build/assets/home-BM5_Wz_R.js +1 -0
- package/build/assets/home-Ivfm7KC4.js +1 -0
- package/build/assets/home-automation-run-tooltip-B1N2uO9p.js +1 -0
- package/build/assets/home-store-DCbei3DX.js +1 -0
- package/build/assets/hooks-service-Dnmhqc0Z.js +1 -0
- package/build/assets/index-home-td9BN2T3.js +1 -0
- package/build/assets/info-BcajzHn1.js +1 -0
- package/build/assets/install-server-modal-B81I-5OE.js +1 -0
- package/build/assets/kebab-menu-item-content-SCJBwZnp.js +1 -0
- package/build/assets/{key-BmVyxs-2.js → key-O84CMFHb.js} +1 -1
- package/build/assets/launch-ZLxI4opd.js +1 -0
- package/build/assets/list-filter-B8PQk3RA.js +1 -0
- package/build/assets/{list-todo-apgLVjMw.js → list-todo-Caa8E1X_.js} +1 -1
- package/build/assets/llm-not-configured-banner-Dh_ajcM8.js +27 -0
- package/build/assets/llm-settings-CODhjQzy.js +1 -0
- package/build/assets/llm-settings-CZaXYgtw.js +1 -0
- package/build/assets/llm-subscription-service-CgIDc38n.js +1 -0
- package/build/assets/loader-circle-BxJgk73D.js +1 -0
- package/build/assets/{loading-spinner-BY9N3pOe.js → loading-spinner-BeLV0IXf.js} +1 -1
- package/build/assets/manage-backends-modal-cMXqCb-B.js +1 -0
- package/build/assets/manifest-bfeccb98.js +1 -0
- package/build/assets/manifest-subpage-layout-CVZgVKoY.js +1 -0
- package/build/assets/{map-provider-Cu3Zgumb.js → map-provider-iRs80q_6.js} +1 -1
- package/build/assets/markdown-renderer-DyFl9-mL.js +8 -0
- package/build/assets/mcp-CraxoXQv.js +1 -0
- package/build/assets/{mcp-marketplace-utils-AIBzzHTO.js → mcp-marketplace-utils-C7PYr293.js} +1 -1
- package/build/assets/mcp-page-CteH_K0N.js +9 -0
- package/build/assets/messages-Bk1xhbU2.js +41 -0
- package/build/assets/{modal-body-BxZjsju9.js → modal-body-C24WsdFb.js} +1 -1
- package/build/assets/{modal-classes-C8eycCwG.js → modal-classes-B0b9eiL8.js} +1 -1
- package/build/assets/modal-close-button-DfqfB2Nj.js +1 -0
- package/build/assets/{mouse-pointer-click-Co2uyaPA.js → mouse-pointer-click-BXlRN92t.js} +1 -1
- package/build/assets/onboarding-DXFBRqEy.js +1 -0
- package/build/assets/onboarding-modal-BT3Gx_sZ.js +1 -0
- package/build/assets/organization-service.api-B5CvmnYQ.js +1 -0
- package/build/assets/pencil-q-ihqDYv.js +1 -0
- package/build/assets/pin-BdroVQdN.js +1 -0
- package/build/assets/planner-tab-CstoOlAB.js +1 -0
- package/build/assets/plug-7ACOEbMs.js +1 -0
- package/build/assets/plugins-management-service-5rqVPEGN.js +1 -0
- package/build/assets/plus-C2e21TFC.js +1 -0
- package/build/assets/profiles-service.api-D1XKMgr0.js +1 -0
- package/build/assets/providers-XmZ9HM4Q.js +1 -0
- package/build/assets/proxy-XP6U1Dhv.js +1 -0
- package/build/assets/{puzzle-JM_QaRm0.js → puzzle-LJYnuxKe.js} +1 -1
- package/build/assets/react-BX7IV650.js +1 -0
- package/build/assets/recommended-automations-launcher-DEHRKIAg.js +1 -0
- package/build/assets/refresh-cw-BtdC3T8P.js +1 -0
- package/build/assets/root-CM6IZHlg.css +1 -0
- package/build/assets/root-DdFkodKW.js +2 -0
- package/build/assets/root-layout-DUquNZTU.js +2 -0
- package/build/assets/schema-field-Y3F8JvXd.js +1 -0
- package/build/assets/scroll-fade-state-Dt_fx2kf.js +1 -0
- package/build/assets/sdk-section-page-CNZTLwH9.js +1 -0
- package/build/assets/secret-form-9-BoGA40.js +1 -0
- package/build/assets/secrets-service-BOIsfD9j.js +1 -0
- package/build/assets/secrets-settings-CBJgFr42.js +1 -0
- package/build/assets/settings-D4hdToD4.js +1 -0
- package/build/assets/settings-dropdown-input-DBvsZ7-Q.js +1 -0
- package/build/assets/settings-index-DeQphyBK.js +1 -0
- package/build/assets/settings-input-dVuzapBA.js +1 -0
- package/build/assets/{settings-list-classes-BzeSZbF2.js → settings-list-classes-DhAPuXm6.js} +1 -1
- package/build/assets/settings-modal-tHiJ8iYV.js +1 -0
- package/build/assets/settings-nav-GAQjW1a-.js +16 -0
- package/build/assets/settings-service.api-C1vZH9Vh.js +1 -0
- package/build/assets/settings-switch-DDd1cQ8t.js +1 -0
- package/build/assets/{settings-utils-UYpEdPuD.js → settings-utils-BTaaRhLZ.js} +1 -1
- package/build/assets/shared-conversation-Cyg7m7ns.js +1 -0
- package/build/assets/shield-check-C3Rl0NF8.js +1 -0
- package/build/assets/{sidebar-layout-D6fS8-Gl.js → sidebar-layout-DH0E-5KW.js} +1 -1
- package/build/assets/sidebar-mobile-menu-toggle-CQ4iky__.js +1 -0
- package/build/assets/{sidebar-nav-link-DQQcMf1A.js → sidebar-nav-link-oLQiKUBu.js} +1 -1
- package/build/assets/{sidebar-onboarding-checklist-storage-BBkeI6Bp.js → sidebar-onboarding-checklist-storage-TfvNNnnr.js} +1 -1
- package/build/assets/sidebar-store-DAZVH-DR.js +1 -0
- package/build/assets/skill-card-pill-row-DfjIfj0K.js +1 -0
- package/build/assets/{skill-filter-w__3UCEE.js → skill-filter-DsNLmn76.js} +2 -2
- package/build/assets/{skill-icon-badge-RQkq8wvl.js → skill-icon-badge-0MK_68Nc.js} +1 -1
- package/build/assets/skill-scope-BE-H9TSZ.js +1 -0
- package/build/assets/skills-plugins-vzSdxSk_.js +1 -0
- package/build/assets/skills-settings-BiPOH9H9.js +1 -0
- package/build/assets/styled-tooltip-CejG0rqv.js +1 -0
- package/build/assets/task-list-tab-OkZSqnTp.js +1 -0
- package/build/assets/{terminal-CNElN42a.js → terminal-Dph60VFZ.js} +2 -2
- package/build/assets/toggle-switch-B2uXaAUS.js +1 -0
- package/build/assets/trash-2-Bb40zQzs.js +1 -0
- package/build/assets/trash-Ckh7yCaB.js +1 -0
- package/build/assets/triangle-alert-DEdu-b_L.js +1 -0
- package/build/assets/{typography-v1KN0tzi.js → typography-DgcLGdHk.js} +1 -1
- package/build/assets/usage-tab-MCmNRAnR.js +1 -0
- package/build/assets/use-acp-credential-form-ychoGqjC.js +1 -0
- package/build/assets/use-activate-agent-profile-8L8Xdghy.js +1 -0
- package/build/assets/use-agent-profiles-Bi8hSkze.js +1 -0
- package/build/assets/{use-automation-health-E6NZi9rb.js → use-automation-health-U99vvHxx.js} +1 -1
- package/build/assets/use-automation-permissions-Buus0R6h.js +1 -0
- package/build/assets/{use-automations-xijQKIl9.js → use-automations-Bq5hVuv0.js} +1 -1
- package/build/assets/{use-can-manage-org-profiles-CrJP5262.js → use-can-manage-org-profiles-MzIeEV8F.js} +1 -1
- package/build/assets/use-canvas-extensions-Ca9KoVEm.js +1 -0
- package/build/assets/{use-cloud-current-user-id-CDfAHpPX.js → use-cloud-current-user-id-B4ZLUZSa.js} +1 -1
- package/build/assets/use-config-l5tkDHyD.js +1 -0
- package/build/assets/use-create-conversation-i_PdFdIs.js +1 -0
- package/build/assets/use-create-secret-CjWq0J4O.js +1 -0
- package/build/assets/use-free-models-gCsJ5BV0.js +1 -0
- package/build/assets/{use-get-secrets-K3jmk-LH.js → use-get-secrets-CMTuWEp_.js} +1 -1
- package/build/assets/use-is-authed-A2Yinlt0.js +1 -0
- package/build/assets/{use-launch-skill-in-chat-BYjYihBP.js → use-launch-skill-in-chat-QbXDhiHr.js} +1 -1
- package/build/assets/use-llm-configured-Dl4zg8ht.js +1 -0
- package/build/assets/use-llm-profiles-SWsuFmFu.js +1 -0
- package/build/assets/use-manifest-capabilities-CdqYfUAC.js +1 -0
- package/build/assets/use-onboarding-completion-Xl63ZvzQ.js +1 -0
- package/build/assets/use-pinned-home-route-BXDIUaxQ.js +1 -0
- package/build/assets/use-plugins-marketplace-BIIaPiaB.js +1 -0
- package/build/assets/use-save-agent-profile-D-ZHHE94.js +1 -0
- package/build/assets/{use-save-settings-DYqkKv7T.js → use-save-settings-Dapkf4cC.js} +1 -1
- package/build/assets/use-settings-C2KKQKVC.js +1 -0
- package/build/assets/use-settings-nav-items-TOc0Rsfd.js +1 -0
- package/build/assets/use-tracking-j4uo9VEW.js +3 -0
- package/build/assets/{use-user-conversation-B9Gebw_g.js → use-user-conversation-5UFqMoO4.js} +1 -1
- package/build/assets/{useInfiniteQuery-C926xzY4.js → useInfiniteQuery-CtSRG7uW.js} +1 -1
- package/build/assets/{useMutation-B-qc391N.js → useMutation-Cszf8mKy.js} +1 -1
- package/build/assets/useQueries-pUohFMSP.js +1 -0
- package/build/assets/useQuery-DAAacS7O.js +1 -0
- package/build/assets/useTranslation-CCgUjPJF.js +1 -0
- package/build/assets/utils-BgLSZdyy.js +1 -0
- package/build/assets/{vendor~conversation-panel~conversation-C8Fn4XOf.js → vendor~conversation-panel~conversation-C22sJuWZ.js} +1 -1
- package/build/assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~b0x1wrp2-Z0lly3FE.js +2 -0
- package/build/assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-BXXGJNDU.js +185 -0
- package/build/assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-40UR63Gt.js +1 -0
- package/build/assets/{vendor~index-home~home~conversation-panel~conversation-hWywRBaR.js → vendor~index-home~home~conversation-panel~conversation-UTl7gUo9.js} +1 -1
- package/build/assets/vendor~root-layout-CcdIqs-C.js +1 -0
- package/build/assets/{vendor~root-layout~conversation-panel~conversation-BMbMgaGu.js → vendor~root-layout~conversation-panel~conversation-C3EBV3kp.js} +1 -1
- package/build/assets/vendor~root-layout~conversation-panel~conversation~skills-settings~automations-list~shared-~bovqqk8e-BCe0JJVy.js +1 -0
- package/build/assets/{vendor~root-layout~index-home~home~conversation-panel~conversation-j5MFqfSy.js → vendor~root-layout~index-home~home~conversation-panel~conversation-BGGbPcYh.js} +1 -1
- package/build/assets/vendor~root-layout~index-home~home~conversation-panel~conversation~mcp~automations-list~aut~ibfbmr9f-CxhwKuAd.js +1 -0
- package/build/assets/{vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~nj1hli3r-DP9wmsjo.js → vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~inibp4qe-CnsDDzeE.js} +1 -1
- package/build/assets/{vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-CUmIwQCN.js → vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-3eJ4ExtV.js} +12 -6
- package/build/assets/{verification-settings-gw_q6vkL.js → verification-settings-DdBpaVPz.js} +1 -1
- package/build/assets/{wrench-CUEI1krB.js → wrench-B8Wg_nbp.js} +1 -1
- package/build/assets/x-CX8lVGwm.js +1 -0
- package/build/index.html +4 -4
- package/build/locales/ar/openhands.json +79 -22
- package/build/locales/ca/openhands.json +79 -22
- package/build/locales/de/openhands.json +79 -22
- package/build/locales/en/openhands.json +79 -22
- package/build/locales/es/openhands.json +79 -22
- package/build/locales/fr/openhands.json +79 -22
- package/build/locales/it/openhands.json +79 -22
- package/build/locales/ja/openhands.json +79 -22
- package/build/locales/ko-KR/openhands.json +79 -22
- package/build/locales/no/openhands.json +79 -22
- package/build/locales/pt/openhands.json +79 -22
- package/build/locales/tr/openhands.json +79 -22
- package/build/locales/uk/openhands.json +79 -22
- package/build/locales/zh-CN/openhands.json +79 -22
- package/build/locales/zh-TW/openhands.json +79 -22
- package/config/defaults.json +3 -3
- package/dist/api/agent-server-adapter.cjs +3 -3
- package/dist/api/agent-server-adapter.cjs.map +1 -1
- package/dist/api/agent-server-adapter.d.ts +72 -12
- package/dist/api/agent-server-adapter.js +234 -132
- package/dist/api/agent-server-adapter.js.map +1 -1
- package/dist/api/agent-server-config.cjs +1 -1
- package/dist/api/agent-server-config.cjs.map +1 -1
- package/dist/api/agent-server-config.d.ts +6 -0
- package/dist/api/agent-server-config.js +6 -3
- package/dist/api/agent-server-config.js.map +1 -1
- package/dist/api/automation-service/automation-service.api.cjs +1 -1
- package/dist/api/automation-service/automation-service.api.cjs.map +1 -1
- package/dist/api/automation-service/automation-service.api.d.ts +2 -2
- package/dist/api/automation-service/automation-service.api.js +7 -7
- package/dist/api/automation-service/automation-service.api.js.map +1 -1
- package/dist/api/cloud/organization-service.api.cjs.map +1 -1
- package/dist/api/cloud/organization-service.api.d.ts +9 -1
- package/dist/api/cloud/organization-service.api.js.map +1 -1
- package/dist/api/cloud/provider-connections-service.api.cjs +2 -0
- package/dist/api/cloud/provider-connections-service.api.cjs.map +1 -0
- package/dist/api/cloud/provider-connections-service.api.d.ts +5 -0
- package/dist/api/cloud/provider-connections-service.api.js +50 -0
- package/dist/api/cloud/provider-connections-service.api.js.map +1 -0
- package/dist/api/cloud/skills-service.api.cjs +1 -1
- package/dist/api/cloud/skills-service.api.cjs.map +1 -1
- package/dist/api/cloud/skills-service.api.d.ts +10 -0
- package/dist/api/cloud/skills-service.api.js +11 -1
- package/dist/api/cloud/skills-service.api.js.map +1 -1
- package/dist/api/config-service/config-service.api.cjs +1 -1
- package/dist/api/config-service/config-service.api.cjs.map +1 -1
- package/dist/api/config-service/config-service.api.js +6 -2
- package/dist/api/config-service/config-service.api.js.map +1 -1
- package/dist/api/config-service/config-service.types.d.ts +13 -0
- package/dist/api/conversation-metadata-store.cjs +1 -1
- package/dist/api/conversation-metadata-store.cjs.map +1 -1
- package/dist/api/conversation-metadata-store.d.ts +24 -0
- package/dist/api/conversation-metadata-store.js +10 -2
- package/dist/api/conversation-metadata-store.js.map +1 -1
- package/dist/api/conversation-service/agent-server-conversation-service.api.cjs +1 -1
- package/dist/api/conversation-service/agent-server-conversation-service.api.cjs.map +1 -1
- package/dist/api/conversation-service/agent-server-conversation-service.api.d.ts +20 -0
- package/dist/api/conversation-service/agent-server-conversation-service.api.js +126 -77
- package/dist/api/conversation-service/agent-server-conversation-service.api.js.map +1 -1
- package/dist/api/hooks-service.cjs +2 -0
- package/dist/api/hooks-service.cjs.map +1 -0
- package/dist/api/hooks-service.d.ts +13 -0
- package/dist/api/hooks-service.js +20 -0
- package/dist/api/hooks-service.js.map +1 -0
- package/dist/api/provider-connections-service/provider-connections-service.api.cjs +1 -1
- package/dist/api/provider-connections-service/provider-connections-service.api.cjs.map +1 -1
- package/dist/api/provider-connections-service/provider-connections-service.api.js +25 -16
- package/dist/api/provider-connections-service/provider-connections-service.api.js.map +1 -1
- package/dist/api/settings-service/settings-service.api.cjs +1 -1
- package/dist/api/settings-service/settings-service.api.cjs.map +1 -1
- package/dist/api/settings-service/settings-service.api.d.ts +2 -0
- package/dist/api/settings-service/settings-service.api.js +18 -10
- package/dist/api/settings-service/settings-service.api.js.map +1 -1
- package/dist/api/skills-service.cjs +1 -1
- package/dist/api/skills-service.cjs.map +1 -1
- package/dist/api/skills-service.d.ts +7 -0
- package/dist/api/skills-service.js +11 -8
- package/dist/api/skills-service.js.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/critic-result-display.cjs +1 -1
- package/dist/components/conversation-events/chat/event-message-components/critic-result-display.js +5 -5
- package/dist/components/conversation-events/chat/event-message-components/finish-event-message.cjs +1 -1
- package/dist/components/conversation-events/chat/event-message-components/finish-event-message.cjs.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/finish-event-message.js +2 -1
- package/dist/components/conversation-events/chat/event-message-components/finish-event-message.js.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/generic-event-message-wrapper.cjs +1 -1
- package/dist/components/conversation-events/chat/event-message-components/generic-event-message-wrapper.cjs.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/generic-event-message-wrapper.d.ts +1 -1
- package/dist/components/conversation-events/chat/event-message-components/generic-event-message-wrapper.js +28 -28
- package/dist/components/conversation-events/chat/event-message-components/generic-event-message-wrapper.js.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/thought-event-message.cjs +1 -1
- package/dist/components/conversation-events/chat/event-message-components/thought-event-message.cjs.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/thought-event-message.js +2 -1
- package/dist/components/conversation-events/chat/event-message-components/thought-event-message.js.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/user-assistant-event-message.cjs +1 -1
- package/dist/components/conversation-events/chat/event-message-components/user-assistant-event-message.cjs.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/user-assistant-event-message.d.ts +1 -1
- package/dist/components/conversation-events/chat/event-message-components/user-assistant-event-message.js +37 -37
- package/dist/components/conversation-events/chat/event-message-components/user-assistant-event-message.js.map +1 -1
- package/dist/components/conversation-events/chat/event-message.cjs +2 -2
- package/dist/components/conversation-events/chat/event-message.cjs.map +1 -1
- package/dist/components/conversation-events/chat/event-message.js +79 -70
- package/dist/components/conversation-events/chat/event-message.js.map +1 -1
- package/dist/components/conversation-events/chat/messages.cjs +1 -1
- package/dist/components/conversation-events/chat/messages.cjs.map +1 -1
- package/dist/components/conversation-events/chat/messages.js +28 -27
- package/dist/components/conversation-events/chat/messages.js.map +1 -1
- package/dist/components/features/automations/automation-card.cjs +1 -1
- package/dist/components/features/automations/automation-card.cjs.map +1 -1
- package/dist/components/features/automations/automation-card.js +104 -97
- package/dist/components/features/automations/automation-card.js.map +1 -1
- package/dist/components/features/automations/automation-list-row.cjs +1 -1
- package/dist/components/features/automations/automation-list-row.cjs.map +1 -1
- package/dist/components/features/automations/automation-list-row.js +89 -77
- package/dist/components/features/automations/automation-list-row.js.map +1 -1
- package/dist/components/features/automations/build-automation-menu-items.cjs +1 -1
- package/dist/components/features/automations/build-automation-menu-items.cjs.map +1 -1
- package/dist/components/features/automations/build-automation-menu-items.d.ts +3 -1
- package/dist/components/features/automations/build-automation-menu-items.js +12 -11
- package/dist/components/features/automations/build-automation-menu-items.js.map +1 -1
- package/dist/components/features/automations/detail/configuration-section.d.ts +7 -1
- package/dist/components/features/automations/detail/detail-header.d.ts +10 -5
- package/dist/components/features/automations/detail/run-status-badge.cjs +1 -1
- package/dist/components/features/automations/detail/run-status-badge.cjs.map +1 -1
- package/dist/components/features/automations/detail/run-status-badge.d.ts +2 -2
- package/dist/components/features/automations/detail/run-status-badge.js +82 -53
- package/dist/components/features/automations/detail/run-status-badge.js.map +1 -1
- package/dist/components/features/automations/kebab-menu.cjs +1 -1
- package/dist/components/features/automations/kebab-menu.cjs.map +1 -1
- package/dist/components/features/automations/kebab-menu.js +9 -5
- package/dist/components/features/automations/kebab-menu.js.map +1 -1
- package/dist/components/features/automations/recommended-automations-launcher.cjs +1 -1
- package/dist/components/features/automations/recommended-automations-launcher.cjs.map +1 -1
- package/dist/components/features/automations/recommended-automations-launcher.js +12 -12
- package/dist/components/features/automations/recommended-automations-launcher.js.map +1 -1
- package/dist/components/features/automations/recommended-automations-section.cjs +1 -1
- package/dist/components/features/automations/recommended-automations-section.js +9 -9
- package/dist/components/features/backends/backend-selector.cjs +1 -1
- package/dist/components/features/backends/backend-selector.cjs.map +1 -1
- package/dist/components/features/backends/backend-selector.js +123 -112
- package/dist/components/features/backends/backend-selector.js.map +1 -1
- package/dist/components/features/backends/manage-backends-modal.cjs +1 -1
- package/dist/components/features/backends/manage-backends-modal.cjs.map +1 -1
- package/dist/components/features/backends/manage-backends-modal.js +29 -29
- package/dist/components/features/backends/manage-backends-modal.js.map +1 -1
- package/dist/components/features/chat/change-agent-button.cjs +1 -1
- package/dist/components/features/chat/change-agent-button.js +4 -4
- package/dist/components/features/chat/chat-interface.cjs +2 -2
- package/dist/components/features/chat/chat-interface.cjs.map +1 -1
- package/dist/components/features/chat/chat-interface.js +137 -137
- package/dist/components/features/chat/chat-interface.js.map +1 -1
- package/dist/components/features/chat/chat-message.cjs +1 -1
- package/dist/components/features/chat/chat-message.cjs.map +1 -1
- package/dist/components/features/chat/chat-message.d.ts +2 -1
- package/dist/components/features/chat/chat-message.js +88 -79
- package/dist/components/features/chat/chat-message.js.map +1 -1
- package/dist/components/features/chat/components/chat-input-llm-profile-picker.cjs +1 -1
- package/dist/components/features/chat/components/chat-input-llm-profile-picker.cjs.map +1 -1
- package/dist/components/features/chat/components/chat-input-llm-profile-picker.js +62 -61
- package/dist/components/features/chat/components/chat-input-llm-profile-picker.js.map +1 -1
- package/dist/components/features/chat/components/context-window-meter.cjs +1 -1
- package/dist/components/features/chat/components/context-window-meter.js +4 -4
- package/dist/components/features/chat/confirmation-mode-enabled.cjs +1 -1
- package/dist/components/features/chat/confirmation-mode-enabled.js +4 -4
- package/dist/components/features/chat/generic-event-message.cjs +1 -1
- package/dist/components/features/chat/generic-event-message.cjs.map +1 -1
- package/dist/components/features/chat/generic-event-message.d.ts +2 -1
- package/dist/components/features/chat/generic-event-message.js +41 -22
- package/dist/components/features/chat/generic-event-message.js.map +1 -1
- package/dist/components/features/chat/interactive-chat-box.cjs +1 -1
- package/dist/components/features/chat/interactive-chat-box.cjs.map +1 -1
- package/dist/components/features/chat/interactive-chat-box.js +20 -19
- package/dist/components/features/chat/interactive-chat-box.js.map +1 -1
- package/dist/components/features/chat/model-messages.cjs +1 -1
- package/dist/components/features/chat/model-messages.cjs.map +1 -1
- package/dist/components/features/chat/model-messages.js +27 -26
- package/dist/components/features/chat/model-messages.js.map +1 -1
- package/dist/components/features/conversation/conversation-overview-git-section.cjs +1 -1
- package/dist/components/features/conversation/conversation-overview-git-section.js +4 -4
- package/dist/components/features/conversation/conversation-overview-skills-panel.cjs +1 -1
- package/dist/components/features/conversation/conversation-overview-skills-panel.js +4 -4
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs-context-menu.cjs +1 -1
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs-context-menu.cjs.map +1 -1
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs-context-menu.js +77 -78
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs-context-menu.js.map +1 -1
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs.cjs +1 -1
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs.cjs.map +1 -1
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs.js +88 -88
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs.js.map +1 -1
- package/dist/components/features/conversation-panel/advanced-conversation-options-modal.cjs +2 -0
- package/dist/components/features/conversation-panel/advanced-conversation-options-modal.cjs.map +1 -0
- package/dist/components/features/conversation-panel/advanced-conversation-options-modal.d.ts +21 -0
- package/dist/components/features/conversation-panel/advanced-conversation-options-modal.js +239 -0
- package/dist/components/features/conversation-panel/advanced-conversation-options-modal.js.map +1 -0
- package/dist/components/features/conversation-panel/budget-display.cjs +1 -1
- package/dist/components/features/conversation-panel/budget-display.cjs.map +1 -1
- package/dist/components/features/conversation-panel/budget-display.d.ts +1 -2
- package/dist/components/features/conversation-panel/budget-display.js +12 -19
- package/dist/components/features/conversation-panel/budget-display.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-active-tag-filters.cjs +2 -0
- package/dist/components/features/conversation-panel/conversation-active-tag-filters.cjs.map +1 -0
- package/dist/components/features/conversation-panel/conversation-active-tag-filters.d.ts +28 -0
- package/dist/components/features/conversation-panel/conversation-active-tag-filters.js +69 -0
- package/dist/components/features/conversation-panel/conversation-active-tag-filters.js.map +1 -0
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-actions.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-actions.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-actions.d.ts +2 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-actions.js +19 -18
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-actions.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-context-menu.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-context-menu.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-context-menu.d.ts +2 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-context-menu.js +91 -80
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-context-menu.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-footer.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-footer.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-footer.js +45 -44
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-footer.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-preview.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-preview.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-preview.js +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card-preview.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card.d.ts +7 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-card.js +87 -81
- package/dist/components/features/conversation-panel/conversation-card/conversation-card.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-chips.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-chips.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-chips.d.ts +2 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-chips.js +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-chips.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-display.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-display.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-display.d.ts +2 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-display.js +2 -1
- package/dist/components/features/conversation-panel/conversation-card/conversation-tag-display.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-layouts-menu.cjs +2 -0
- package/dist/components/features/conversation-panel/conversation-layouts-menu.cjs.map +1 -0
- package/dist/components/features/conversation-panel/conversation-layouts-menu.d.ts +29 -0
- package/dist/components/features/conversation-panel/conversation-layouts-menu.js +177 -0
- package/dist/components/features/conversation-panel/conversation-layouts-menu.js.map +1 -0
- package/dist/components/features/conversation-panel/conversation-panel-list-helpers.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-panel-list-helpers.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-panel-list-helpers.d.ts +37 -0
- package/dist/components/features/conversation-panel/conversation-panel-list-helpers.js +85 -45
- package/dist/components/features/conversation-panel/conversation-panel-list-helpers.js.map +1 -1
- package/dist/components/features/conversation-panel/conversation-panel.cjs +1 -1
- package/dist/components/features/conversation-panel/conversation-panel.cjs.map +1 -1
- package/dist/components/features/conversation-panel/conversation-panel.js +296 -290
- package/dist/components/features/conversation-panel/conversation-panel.js.map +1 -1
- package/dist/components/features/conversation-panel/edit-conversation-tags-modal.cjs +2 -0
- package/dist/components/features/conversation-panel/edit-conversation-tags-modal.cjs.map +1 -0
- package/dist/components/features/conversation-panel/edit-conversation-tags-modal.d.ts +22 -0
- package/dist/components/features/conversation-panel/edit-conversation-tags-modal.js +153 -0
- package/dist/components/features/conversation-panel/edit-conversation-tags-modal.js.map +1 -0
- package/dist/components/features/conversation-panel/hide-older-conversations-row.cjs +2 -0
- package/dist/components/features/conversation-panel/hide-older-conversations-row.cjs.map +1 -0
- package/dist/components/features/conversation-panel/hide-older-conversations-row.d.ts +6 -0
- package/dist/components/features/conversation-panel/hide-older-conversations-row.js +65 -0
- package/dist/components/features/conversation-panel/hide-older-conversations-row.js.map +1 -0
- package/dist/components/features/conversation-panel/menu-row.cjs +1 -1
- package/dist/components/features/conversation-panel/menu-row.cjs.map +1 -1
- package/dist/components/features/conversation-panel/menu-row.d.ts +11 -1
- package/dist/components/features/conversation-panel/menu-row.js +27 -16
- package/dist/components/features/conversation-panel/menu-row.js.map +1 -1
- package/dist/components/features/home/featured-automations/automation-health-indicator.cjs +1 -1
- package/dist/components/features/home/featured-automations/automation-health-indicator.cjs.map +1 -1
- package/dist/components/features/home/featured-automations/automation-health-indicator.js +1 -1
- package/dist/components/features/home/featured-automations/automation-health-indicator.js.map +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-metrics.cjs +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-metrics.cjs.map +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-metrics.d.ts +4 -3
- package/dist/components/features/home/featured-automations/automation-run-activity-metrics.js +22 -25
- package/dist/components/features/home/featured-automations/automation-run-activity-metrics.js.map +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-sparkline.cjs +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-sparkline.cjs.map +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-sparkline.d.ts +1 -1
- package/dist/components/features/home/featured-automations/automation-run-activity-sparkline.js +15 -15
- package/dist/components/features/home/featured-automations/automation-run-activity-sparkline.js.map +1 -1
- package/dist/components/features/home/featured-automations/automation-run-health.cjs +1 -1
- package/dist/components/features/home/featured-automations/automation-run-health.cjs.map +1 -1
- package/dist/components/features/home/featured-automations/automation-run-health.d.ts +5 -3
- package/dist/components/features/home/featured-automations/automation-run-health.js +30 -23
- package/dist/components/features/home/featured-automations/automation-run-health.js.map +1 -1
- package/dist/components/features/home/featured-automations/build-home-automation-menu-items.d.ts +1 -2
- package/dist/components/features/home/featured-automations/build-pinned-automation-menu-items.d.ts +0 -1
- package/dist/components/features/home/featured-automations/home-automation-activity.d.ts +3 -2
- package/dist/components/features/home/featured-automations/home-automation-run-tooltip.cjs +1 -1
- package/dist/components/features/home/featured-automations/home-automation-run-tooltip.cjs.map +1 -1
- package/dist/components/features/home/featured-automations/home-automation-run-tooltip.d.ts +1 -1
- package/dist/components/features/home/featured-automations/home-automation-run-tooltip.js +42 -42
- package/dist/components/features/home/featured-automations/home-automation-run-tooltip.js.map +1 -1
- package/dist/components/features/images/image-lightbox.cjs +2 -0
- package/dist/components/features/images/image-lightbox.cjs.map +1 -0
- package/dist/components/features/images/image-lightbox.d.ts +11 -0
- package/dist/components/features/images/image-lightbox.js +37 -0
- package/dist/components/features/images/image-lightbox.js.map +1 -0
- package/dist/components/features/images/image-preview.cjs +1 -1
- package/dist/components/features/images/image-preview.cjs.map +1 -1
- package/dist/components/features/images/image-preview.d.ts +2 -1
- package/dist/components/features/images/image-preview.js +33 -13
- package/dist/components/features/images/image-preview.js.map +1 -1
- package/dist/components/features/manifest/manifest-form-field.d.ts +3 -1
- package/dist/components/features/manifest/manifest-review-step.d.ts +3 -1
- package/dist/components/features/onboarding/steps/setup-llm-step.d.ts +3 -4
- package/dist/components/features/settings/cloud-settings-link.cjs +1 -1
- package/dist/components/features/settings/cloud-settings-link.cjs.map +1 -1
- package/dist/components/features/settings/cloud-settings-link.d.ts +3 -1
- package/dist/components/features/settings/cloud-settings-link.js +22 -19
- package/dist/components/features/settings/cloud-settings-link.js.map +1 -1
- package/dist/components/features/settings/integrations-settings-link.cjs +1 -1
- package/dist/components/features/settings/integrations-settings-link.cjs.map +1 -1
- package/dist/components/features/settings/integrations-settings-link.d.ts +3 -1
- package/dist/components/features/settings/integrations-settings-link.js +20 -17
- package/dist/components/features/settings/integrations-settings-link.js.map +1 -1
- package/dist/components/features/settings/llm-profiles/llm-settings-local-view.cjs +1 -1
- package/dist/components/features/settings/llm-profiles/llm-settings-local-view.js +3 -2
- package/dist/components/features/settings/llm-profiles/profile-row.cjs +1 -1
- package/dist/components/features/settings/llm-profiles/profile-row.js +1 -1
- package/dist/components/features/settings/llm-profiles/profiles-body.d.ts +2 -2
- package/dist/components/features/settings/sdk-settings/sdk-section-page.cjs +1 -1
- package/dist/components/features/settings/sdk-settings/sdk-section-page.cjs.map +1 -1
- package/dist/components/features/settings/sdk-settings/sdk-section-page.d.ts +8 -7
- package/dist/components/features/settings/sdk-settings/sdk-section-page.js +172 -142
- package/dist/components/features/settings/sdk-settings/sdk-section-page.js.map +1 -1
- package/dist/components/features/settings/secrets-settings/secret-form.cjs +1 -1
- package/dist/components/features/settings/secrets-settings/secret-form.cjs.map +1 -1
- package/dist/components/features/settings/secrets-settings/secret-form.js +38 -25
- package/dist/components/features/settings/secrets-settings/secret-form.js.map +1 -1
- package/dist/components/features/settings/settings-dropdown-input.cjs +1 -1
- package/dist/components/features/settings/settings-dropdown-input.js +6 -6
- package/dist/components/features/sidebar/sidebar-rail-body.cjs +1 -1
- package/dist/components/features/sidebar/sidebar-rail-body.cjs.map +1 -1
- package/dist/components/features/sidebar/sidebar-rail-body.d.ts +4 -1
- package/dist/components/features/sidebar/sidebar-rail-body.js +157 -139
- package/dist/components/features/sidebar/sidebar-rail-body.js.map +1 -1
- package/dist/components/features/sidebar/sidebar.cjs +1 -1
- package/dist/components/features/sidebar/sidebar.cjs.map +1 -1
- package/dist/components/features/sidebar/sidebar.js +28 -26
- package/dist/components/features/sidebar/sidebar.js.map +1 -1
- package/dist/components/features/sidebar/use-sidebar-onboarding-checklist.cjs +1 -1
- package/dist/components/features/sidebar/use-sidebar-onboarding-checklist.js +3 -3
- package/dist/components/features/skills/extensions-navigation.cjs +1 -1
- package/dist/components/features/skills/extensions-navigation.cjs.map +1 -1
- package/dist/components/features/skills/extensions-navigation.js +3 -3
- package/dist/components/features/skills/extensions-navigation.js.map +1 -1
- package/dist/components/providers/agent-server-ui-providers.cjs +1 -1
- package/dist/components/providers/agent-server-ui-providers.cjs.map +1 -1
- package/dist/components/providers/agent-server-ui-providers.js +33 -29
- package/dist/components/providers/agent-server-ui-providers.js.map +1 -1
- package/dist/components/shared/buttons/remove-button.cjs +1 -1
- package/dist/components/shared/buttons/remove-button.cjs.map +1 -1
- package/dist/components/shared/buttons/remove-button.d.ts +2 -1
- package/dist/components/shared/buttons/remove-button.js +2 -1
- package/dist/components/shared/buttons/remove-button.js.map +1 -1
- package/dist/components/shared/buttons/styled-tooltip.cjs +1 -1
- package/dist/components/shared/buttons/styled-tooltip.cjs.map +1 -1
- package/dist/components/shared/buttons/styled-tooltip.d.ts +2 -1
- package/dist/components/shared/buttons/styled-tooltip.js +2 -1
- package/dist/components/shared/buttons/styled-tooltip.js.map +1 -1
- package/dist/components/shared/filters/enum-filter-dropdown.cjs +1 -1
- package/dist/components/shared/filters/enum-filter-dropdown.cjs.map +1 -1
- package/dist/components/shared/filters/enum-filter-dropdown.d.ts +5 -1
- package/dist/components/shared/filters/enum-filter-dropdown.js +14 -14
- package/dist/components/shared/filters/enum-filter-dropdown.js.map +1 -1
- package/dist/components/shared/free-models-note.cjs +2 -0
- package/dist/components/shared/free-models-note.cjs.map +1 -0
- package/dist/components/shared/free-models-note.d.ts +3 -0
- package/dist/components/shared/free-models-note.js +20 -0
- package/dist/components/shared/free-models-note.js.map +1 -0
- package/dist/components/shared/modals/confirmation-modal.cjs +1 -1
- package/dist/components/shared/modals/confirmation-modal.cjs.map +1 -1
- package/dist/components/shared/modals/confirmation-modal.d.ts +2 -1
- package/dist/components/shared/modals/confirmation-modal.js +8 -8
- package/dist/components/shared/modals/confirmation-modal.js.map +1 -1
- package/dist/components/shared/modals/settings/model-selector.cjs +1 -1
- package/dist/components/shared/modals/settings/model-selector.cjs.map +1 -1
- package/dist/components/shared/modals/settings/model-selector.js +102 -112
- package/dist/components/shared/modals/settings/model-selector.js.map +1 -1
- package/dist/config/defaults.cjs +1 -1
- package/dist/config/defaults.cjs.map +1 -1
- package/dist/config/defaults.js +3 -3
- package/dist/config/defaults.js.map +1 -1
- package/dist/constants/acp-providers.cjs.map +1 -1
- package/dist/constants/acp-providers.d.ts +12 -0
- package/dist/constants/acp-providers.js.map +1 -1
- package/dist/constants/settings-nav.d.ts +8 -0
- package/dist/contexts/conversation-websocket-context.cjs +3 -3
- package/dist/contexts/conversation-websocket-context.cjs.map +1 -1
- package/dist/contexts/conversation-websocket-context.d.ts +5 -0
- package/dist/contexts/conversation-websocket-context.js +194 -198
- package/dist/contexts/conversation-websocket-context.js.map +1 -1
- package/dist/contexts/websocket-provider-wrapper.cjs +1 -1
- package/dist/contexts/websocket-provider-wrapper.cjs.map +1 -1
- package/dist/contexts/websocket-provider-wrapper.js +31 -15
- package/dist/contexts/websocket-provider-wrapper.js.map +1 -1
- package/dist/hooks/chat/record-model-switch-message.cjs +1 -1
- package/dist/hooks/chat/record-model-switch-message.cjs.map +1 -1
- package/dist/hooks/chat/record-model-switch-message.d.ts +31 -0
- package/dist/hooks/chat/record-model-switch-message.js +25 -12
- package/dist/hooks/chat/record-model-switch-message.js.map +1 -1
- package/dist/hooks/chat/use-plan-mode-interceptor.cjs +2 -0
- package/dist/hooks/chat/use-plan-mode-interceptor.cjs.map +1 -0
- package/dist/hooks/chat/use-plan-mode-interceptor.d.ts +16 -0
- package/dist/hooks/chat/use-plan-mode-interceptor.js +43 -0
- package/dist/hooks/chat/use-plan-mode-interceptor.js.map +1 -0
- package/dist/hooks/chat/use-slash-command.cjs +1 -1
- package/dist/hooks/chat/use-slash-command.cjs.map +1 -1
- package/dist/hooks/chat/use-slash-command.js +63 -62
- package/dist/hooks/chat/use-slash-command.js.map +1 -1
- package/dist/hooks/mutation/use-create-conversation.cjs +1 -1
- package/dist/hooks/mutation/use-create-conversation.cjs.map +1 -1
- package/dist/hooks/mutation/use-create-conversation.js +5 -1
- package/dist/hooks/mutation/use-create-conversation.js.map +1 -1
- package/dist/hooks/mutation/use-read-conversation-file.cjs +1 -1
- package/dist/hooks/mutation/use-read-conversation-file.cjs.map +1 -1
- package/dist/hooks/mutation/use-read-conversation-file.js +11 -4
- package/dist/hooks/mutation/use-read-conversation-file.js.map +1 -1
- package/dist/hooks/mutation/use-save-settings.cjs +1 -1
- package/dist/hooks/mutation/use-save-settings.js +3 -3
- package/dist/hooks/mutation/use-switch-llm-profile.cjs +1 -1
- package/dist/hooks/mutation/use-switch-llm-profile.cjs.map +1 -1
- package/dist/hooks/mutation/use-switch-llm-profile.js +13 -25
- package/dist/hooks/mutation/use-switch-llm-profile.js.map +1 -1
- package/dist/hooks/mutation/use-update-conversation-tags.cjs +2 -0
- package/dist/hooks/mutation/use-update-conversation-tags.cjs.map +1 -0
- package/dist/hooks/mutation/use-update-conversation-tags.d.ts +8 -0
- package/dist/hooks/mutation/use-update-conversation-tags.js +45 -0
- package/dist/hooks/mutation/use-update-conversation-tags.js.map +1 -0
- package/dist/hooks/query/query-keys.cjs +1 -1
- package/dist/hooks/query/query-keys.cjs.map +1 -1
- package/dist/hooks/query/query-keys.d.ts +6 -0
- package/dist/hooks/query/query-keys.js +2 -2
- package/dist/hooks/query/query-keys.js.map +1 -1
- package/dist/hooks/query/use-automation-sdk-version.cjs +1 -1
- package/dist/hooks/query/use-automation-sdk-version.cjs.map +1 -1
- package/dist/hooks/query/use-automation-sdk-version.d.ts +0 -1
- package/dist/hooks/query/use-automation-sdk-version.js +30 -55
- package/dist/hooks/query/use-automation-sdk-version.js.map +1 -1
- package/dist/hooks/query/use-conversation-skills.cjs +1 -1
- package/dist/hooks/query/use-conversation-skills.cjs.map +1 -1
- package/dist/hooks/query/use-conversation-skills.d.ts +14 -5
- package/dist/hooks/query/use-conversation-skills.js +20 -4
- package/dist/hooks/query/use-conversation-skills.js.map +1 -1
- package/dist/hooks/query/use-free-models.cjs +2 -0
- package/dist/hooks/query/use-free-models.cjs.map +1 -0
- package/dist/hooks/query/use-free-models.d.ts +23 -0
- package/dist/hooks/query/use-free-models.js +67 -0
- package/dist/hooks/query/use-free-models.js.map +1 -0
- package/dist/hooks/query/use-local-git-info.cjs.map +1 -1
- package/dist/hooks/query/use-local-git-info.js.map +1 -1
- package/dist/hooks/query/use-provider-connections.cjs +1 -1
- package/dist/hooks/query/use-provider-connections.cjs.map +1 -1
- package/dist/hooks/query/use-provider-connections.d.ts +6 -3
- package/dist/hooks/query/use-provider-connections.js +7 -3
- package/dist/hooks/query/use-provider-connections.js.map +1 -1
- package/dist/hooks/query/use-provider-models.cjs +1 -1
- package/dist/hooks/query/use-provider-models.cjs.map +1 -1
- package/dist/hooks/query/use-provider-models.js +34 -25
- package/dist/hooks/query/use-provider-models.js.map +1 -1
- package/dist/hooks/query/use-search-providers.cjs +1 -1
- package/dist/hooks/query/use-search-providers.cjs.map +1 -1
- package/dist/hooks/query/use-search-providers.js +31 -19
- package/dist/hooks/query/use-search-providers.js.map +1 -1
- package/dist/hooks/query/use-sub-conversations.cjs +1 -1
- package/dist/hooks/query/use-sub-conversations.cjs.map +1 -1
- package/dist/hooks/query/use-sub-conversations.js +16 -16
- package/dist/hooks/query/use-sub-conversations.js.map +1 -1
- package/dist/hooks/use-acp-model-context.cjs +1 -1
- package/dist/hooks/use-acp-model-context.js +3 -3
- package/dist/hooks/use-agent-state.cjs +1 -1
- package/dist/hooks/use-agent-state.cjs.map +1 -1
- package/dist/hooks/use-agent-state.d.ts +17 -1
- package/dist/hooks/use-agent-state.js +19 -9
- package/dist/hooks/use-agent-state.js.map +1 -1
- package/dist/hooks/use-automation-permissions.cjs +2 -0
- package/dist/hooks/use-automation-permissions.cjs.map +1 -0
- package/dist/hooks/use-automation-permissions.d.ts +43 -0
- package/dist/hooks/use-automation-permissions.js +52 -0
- package/dist/hooks/use-automation-permissions.js.map +1 -0
- package/dist/hooks/use-chat-input-model-state.cjs +1 -1
- package/dist/hooks/use-chat-input-model-state.js +3 -3
- package/dist/hooks/use-handle-plan-click.cjs +1 -1
- package/dist/hooks/use-handle-plan-click.cjs.map +1 -1
- package/dist/hooks/use-handle-plan-click.d.ts +3 -1
- package/dist/hooks/use-handle-plan-click.js +85 -26
- package/dist/hooks/use-handle-plan-click.js.map +1 -1
- package/dist/hooks/use-home-automation-actions.cjs +1 -1
- package/dist/hooks/use-home-automation-actions.cjs.map +1 -1
- package/dist/hooks/use-home-automation-actions.d.ts +1 -2
- package/dist/hooks/use-home-automation-actions.js +1 -1
- package/dist/hooks/use-home-automation-actions.js.map +1 -1
- package/dist/hooks/use-llm-configured.cjs +1 -1
- package/dist/hooks/use-llm-configured.js +3 -3
- package/dist/hooks/use-manifest-preflight.d.ts +1 -1
- package/dist/hooks/use-unified-websocket-status.cjs +1 -1
- package/dist/hooks/use-unified-websocket-status.cjs.map +1 -1
- package/dist/hooks/use-unified-websocket-status.d.ts +7 -0
- package/dist/hooks/use-unified-websocket-status.js +5 -1
- package/dist/hooks/use-unified-websocket-status.js.map +1 -1
- package/dist/i18n/declaration.cjs +1 -1
- package/dist/i18n/declaration.cjs.map +1 -1
- package/dist/i18n/declaration.d.ts +71 -14
- package/dist/i18n/declaration.js +1 -1
- package/dist/i18n/declaration.js.map +1 -1
- package/dist/i18n/translation.cjs +2 -2
- package/dist/i18n/translation.cjs.map +1 -1
- package/dist/i18n/translation.js +1281 -312
- package/dist/i18n/translation.js.map +1 -1
- package/dist/locales/ar/openhands.json +79 -22
- package/dist/locales/ca/openhands.json +79 -22
- package/dist/locales/de/openhands.json +79 -22
- package/dist/locales/en/openhands.json +79 -22
- package/dist/locales/es/openhands.json +79 -22
- package/dist/locales/fr/openhands.json +79 -22
- package/dist/locales/it/openhands.json +79 -22
- package/dist/locales/ja/openhands.json +79 -22
- package/dist/locales/ko-KR/openhands.json +79 -22
- package/dist/locales/no/openhands.json +79 -22
- package/dist/locales/pt/openhands.json +79 -22
- package/dist/locales/tr/openhands.json +79 -22
- package/dist/locales/uk/openhands.json +79 -22
- package/dist/locales/zh-CN/openhands.json +79 -22
- package/dist/locales/zh-TW/openhands.json +79 -22
- package/dist/manifests/automation-insights.cjs.map +1 -1
- package/dist/manifests/automation-insights.d.ts +10 -2
- package/dist/manifests/automation-insights.js.map +1 -1
- package/dist/manifests/automation-setup.cjs +1 -1
- package/dist/manifests/automation-setup.cjs.map +1 -1
- package/dist/manifests/automation-setup.d.ts +9 -16
- package/dist/manifests/automation-setup.js +17 -7
- package/dist/manifests/automation-setup.js.map +1 -1
- package/dist/manifests/manifest-actions.d.ts +1 -1
- package/dist/manifests/manifest-capabilities.d.ts +3 -1
- package/dist/manifests/manifest-local-validation.cjs +2 -0
- package/dist/manifests/manifest-local-validation.cjs.map +1 -0
- package/dist/manifests/manifest-local-validation.d.ts +15 -11
- package/dist/manifests/manifest-local-validation.js +8 -0
- package/dist/manifests/manifest-local-validation.js.map +1 -0
- package/dist/manifests/manifest-template.cjs +2 -0
- package/dist/manifests/manifest-template.cjs.map +1 -0
- package/dist/manifests/manifest-template.d.ts +4 -4
- package/dist/manifests/manifest-template.js +12 -0
- package/dist/manifests/manifest-template.js.map +1 -0
- package/dist/manifests/manifest-validation.cjs +1 -1
- package/dist/manifests/manifest-validation.cjs.map +1 -1
- package/dist/manifests/manifest-validation.js +106 -28
- package/dist/manifests/manifest-validation.js.map +1 -1
- package/dist/manifests/types.cjs.map +1 -1
- package/dist/manifests/types.d.ts +39 -4
- package/dist/manifests/types.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/custom-automation/manifest.cjs +8 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/custom-automation/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/custom-automation/manifest.js +221 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/custom-automation/manifest.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-issue-to-pr/manifest.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-issue-to-pr/manifest.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-issue-to-pr/manifest.js +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-issue-to-pr/manifest.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-pr-reviewer/manifest.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-pr-reviewer/manifest.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-pr-reviewer/manifest.js +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-pr-reviewer/manifest.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.js +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog-index.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog-index.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog-index.js +22 -20
- package/dist/node_modules/@openhands/extensions/automations/catalog-index.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/interface.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/interface.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/interface.js +2 -1
- package/dist/node_modules/@openhands/extensions/automations/interface.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.js +24 -5
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.js.map +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/QueryClientProvider.cjs +1 -1
- package/dist/node_modules/@tanstack/react-query/build/modern/QueryClientProvider.js +1 -1
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-question-mark.cjs +2 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-question-mark.cjs.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-question-mark.js +21 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-question-mark.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/shrink.cjs +2 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/shrink.cjs.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/shrink.js +23 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/shrink.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/sliders-horizontal.cjs +2 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/sliders-horizontal.cjs.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/sliders-horizontal.js +43 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/sliders-horizontal.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/tags.cjs +2 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/tags.cjs.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/tags.js +22 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/tags.js.map +1 -0
- package/dist/package.cjs +1 -1
- package/dist/package.cjs.map +1 -1
- package/dist/package.js +4 -4
- package/dist/package.js.map +1 -1
- package/dist/routes/agent-settings.d.ts +2 -0
- package/dist/routes/app-settings.cjs +1 -1
- package/dist/routes/app-settings.cjs.map +1 -1
- package/dist/routes/app-settings.js +53 -48
- package/dist/routes/app-settings.js.map +1 -1
- package/dist/routes/llm-settings.cjs +1 -1
- package/dist/routes/llm-settings.cjs.map +1 -1
- package/dist/routes/llm-settings.d.ts +3 -1
- package/dist/routes/llm-settings.js +120 -127
- package/dist/routes/llm-settings.js.map +1 -1
- package/dist/routes/planner-tab.cjs +1 -1
- package/dist/routes/planner-tab.cjs.map +1 -1
- package/dist/routes/planner-tab.js +44 -28
- package/dist/routes/planner-tab.js.map +1 -1
- package/dist/services/telemetry.cjs +1 -1
- package/dist/services/telemetry.cjs.map +1 -1
- package/dist/services/telemetry.d.ts +5 -0
- package/dist/services/telemetry.js +122 -115
- package/dist/services/telemetry.js.map +1 -1
- package/dist/stores/conversation-panel-preferences-store.cjs +1 -1
- package/dist/stores/conversation-panel-preferences-store.cjs.map +1 -1
- package/dist/stores/conversation-panel-preferences-store.d.ts +32 -5
- package/dist/stores/conversation-panel-preferences-store.js +29 -12
- package/dist/stores/conversation-panel-preferences-store.js.map +1 -1
- package/dist/stores/conversation-state-store.cjs +1 -1
- package/dist/stores/conversation-state-store.cjs.map +1 -1
- package/dist/stores/conversation-state-store.d.ts +9 -3
- package/dist/stores/conversation-state-store.js +6 -3
- package/dist/stores/conversation-state-store.js.map +1 -1
- package/dist/stores/conversation-store.cjs +1 -1
- package/dist/stores/conversation-store.cjs.map +1 -1
- package/dist/stores/conversation-store.d.ts +2 -0
- package/dist/stores/conversation-store.js +3 -0
- package/dist/stores/conversation-store.js.map +1 -1
- package/dist/stores/free-models-store.cjs +2 -0
- package/dist/stores/free-models-store.cjs.map +1 -0
- package/dist/stores/free-models-store.d.ts +30 -0
- package/dist/stores/free-models-store.js +22 -0
- package/dist/stores/free-models-store.js.map +1 -0
- package/dist/stores/model-store.cjs +1 -1
- package/dist/stores/model-store.cjs.map +1 -1
- package/dist/stores/model-store.d.ts +7 -0
- package/dist/stores/model-store.js +4 -0
- package/dist/stores/model-store.js.map +1 -1
- package/dist/types/automation.cjs.map +1 -1
- package/dist/types/automation.d.ts +46 -1
- package/dist/types/automation.js.map +1 -1
- package/dist/ui/context-menu.d.ts +1 -1
- package/dist/ui/toggle-switch.cjs +1 -1
- package/dist/ui/toggle-switch.cjs.map +1 -1
- package/dist/ui/toggle-switch.d.ts +4 -1
- package/dist/ui/toggle-switch.js +4 -3
- package/dist/ui/toggle-switch.js.map +1 -1
- package/dist/utils/automation-catalog.cjs +1 -1
- package/dist/utils/automation-catalog.cjs.map +1 -1
- package/dist/utils/automation-catalog.d.ts +12 -1
- package/dist/utils/automation-catalog.js +42 -12
- package/dist/utils/automation-catalog.js.map +1 -1
- package/dist/utils/automation-run-display.cjs +2 -0
- package/dist/utils/automation-run-display.cjs.map +1 -0
- package/dist/utils/automation-run-display.d.ts +20 -0
- package/dist/utils/automation-run-display.js +85 -0
- package/dist/utils/automation-run-display.js.map +1 -0
- package/dist/utils/automation-schedule.cjs +1 -1
- package/dist/utils/automation-schedule.cjs.map +1 -1
- package/dist/utils/automation-schedule.d.ts +16 -0
- package/dist/utils/automation-schedule.js +2 -0
- package/dist/utils/automation-schedule.js.map +1 -1
- package/dist/utils/constants.cjs +1 -1
- package/dist/utils/constants.cjs.map +1 -1
- package/dist/utils/constants.d.ts +4 -0
- package/dist/utils/constants.js +23 -3
- package/dist/utils/constants.js.map +1 -1
- package/dist/utils/format-event-timestamp.cjs +2 -0
- package/dist/utils/format-event-timestamp.cjs.map +1 -0
- package/dist/utils/format-event-timestamp.d.ts +1 -0
- package/dist/utils/format-event-timestamp.js +13 -0
- package/dist/utils/format-event-timestamp.js.map +1 -0
- package/dist/utils/format-model-name.cjs +1 -1
- package/dist/utils/format-model-name.cjs.map +1 -1
- package/dist/utils/format-model-name.d.ts +27 -6
- package/dist/utils/format-model-name.js +14 -6
- package/dist/utils/format-model-name.js.map +1 -1
- package/dist/utils/git-diff-stats.cjs +2 -2
- package/dist/utils/git-diff-stats.cjs.map +1 -1
- package/dist/utils/git-diff-stats.d.ts +4 -0
- package/dist/utils/git-diff-stats.js +12 -2
- package/dist/utils/git-diff-stats.js.map +1 -1
- package/dist/utils/plan-file.cjs +4 -0
- package/dist/utils/plan-file.cjs.map +1 -0
- package/dist/utils/plan-file.d.ts +18 -0
- package/dist/utils/plan-file.js +58 -0
- package/dist/utils/plan-file.js.map +1 -0
- package/dist/utils/recommended-automation-rail.cjs +1 -1
- package/dist/utils/recommended-automation-rail.cjs.map +1 -1
- package/dist/utils/recommended-automation-rail.js +1 -0
- package/dist/utils/recommended-automation-rail.js.map +1 -1
- package/dist/utils/scroll-fade-state.cjs +1 -1
- package/dist/utils/scroll-fade-state.cjs.map +1 -1
- package/dist/utils/scroll-fade-state.d.ts +6 -0
- package/dist/utils/scroll-fade-state.js +8 -1
- package/dist/utils/scroll-fade-state.js.map +1 -1
- package/dist/utils/sdk-settings-schema.cjs +1 -1
- package/dist/utils/sdk-settings-schema.cjs.map +1 -1
- package/dist/utils/sdk-settings-schema.d.ts +1 -0
- package/dist/utils/sdk-settings-schema.js +25 -22
- package/dist/utils/sdk-settings-schema.js.map +1 -1
- package/dist/utils/utils.cjs +1 -1
- package/dist/utils/utils.cjs.map +1 -1
- package/dist/utils/utils.js +11 -11
- package/dist/utils/utils.js.map +1 -1
- package/package.json +4 -4
- package/scripts/check-sdk-version-sync.mjs +6 -6
- package/scripts/dev-safe.mjs +1 -1
- package/scripts/dev-with-automation.mjs +1 -1
- package/scripts/static-server.mjs +33 -1
- package/build/assets/active-backend-context-CrHTlgvN.js +0 -2
- package/build/assets/agent-profiles-settings-Dzgb7G9z.js +0 -1
- package/build/assets/agent-server-conversation-service.api-tnqNjbpE.js +0 -86
- package/build/assets/agent-settings-DLtsqaOs.js +0 -2
- package/build/assets/agent-settings-fFvR-XC2.js +0 -1
- package/build/assets/alert-banner-HP6mX-Vr.js +0 -1
- package/build/assets/api-key-entry-screen-qTzrmJcr.js +0 -1
- package/build/assets/app-settings-dbnneVaV.js +0 -1
- package/build/assets/automation-detail-BmwlCUAB.js +0 -3
- package/build/assets/automation-git-sync-CprN5DcU.js +0 -1
- package/build/assets/automation-setup-route-C40kXjMY.js +0 -1
- package/build/assets/automations-list-DuNcRawl.js +0 -1
- package/build/assets/backend-form-modal-lhGwzXFI.js +0 -1
- package/build/assets/backend-synced-settings-badge-DPkz30BE.js +0 -1
- package/build/assets/badge-BU3S0VtE.js +0 -1
- package/build/assets/bot-dMYHVfYM.js +0 -1
- package/build/assets/browser-DSAo0tz1.js +0 -46
- package/build/assets/browser-tab-C9vy56R5.js +0 -1
- package/build/assets/canvas-extension-page-dx1gFrfW.js +0 -1
- package/build/assets/canvas-extensions-8A-XhpgP.js +0 -1
- package/build/assets/check-CS0vmpQQ.js +0 -1
- package/build/assets/chevron-down-e1QBpjVy.js +0 -1
- package/build/assets/chevron-right-ZG4R5G4Q.js +0 -1
- package/build/assets/circle-check-DzWLNsbE.js +0 -1
- package/build/assets/circle-plus-check-toggle-BO_kFZt3.js +0 -1
- package/build/assets/command-menu--UIlGL72.js +0 -1
- package/build/assets/commits-tab-AnZwLvh-.js +0 -1
- package/build/assets/confirmation-modal-Dv1ktp8K.js +0 -1
- package/build/assets/conversation-BbGrAO4Z.js +0 -93
- package/build/assets/conversation-mYT6NAoj.js +0 -1
- package/build/assets/conversation-panel-mYT6NAoj.js +0 -1
- package/build/assets/conversation-state-store-B0ImPLHO.js +0 -1
- package/build/assets/conversation-store-Ca3ghXap.js +0 -6
- package/build/assets/copy-to-clipboard-button-Ca8iSkkA.js +0 -1
- package/build/assets/device-verify-Bhn2e_Ye.js +0 -1
- package/build/assets/edit-automation-modal-DadGbJ2u.js +0 -1
- package/build/assets/empty-state-BoGVDecT.js +0 -1
- package/build/assets/enum-filter-dropdown-Bgca129f.js +0 -1
- package/build/assets/environment-switch-overlay-BmBRT7gv.js +0 -1
- package/build/assets/error-state-Body8Ngd.js +0 -1
- package/build/assets/extensions-hub-CcDqq_vR.js +0 -1
- package/build/assets/extensions-navigation-Cr4yzYk4.js +0 -1
- package/build/assets/external-link-DKUlnCQV.js +0 -1
- package/build/assets/files-tab-D4o2VyE_.js +0 -1
- package/build/assets/format-model-name-CasAP3nd.js +0 -1
- package/build/assets/get-git-path-ChKDVHZp.js +0 -1
- package/build/assets/git-repo-dropdown-4ROKl2cB.js +0 -1
- package/build/assets/git-repo-dropdown-BkqzkMmM.js +0 -1
- package/build/assets/highlighted-source-view-BFRxGT_Q.js +0 -1
- package/build/assets/home-ChpSuepX.js +0 -1
- package/build/assets/home-DIsB440S.js +0 -1
- package/build/assets/home-automation-run-tooltip-BVNDWjAH.js +0 -1
- package/build/assets/home-store-CY9Ej0ux.js +0 -1
- package/build/assets/index-home-BdlrFIif.js +0 -1
- package/build/assets/info-B6RQawoW.js +0 -1
- package/build/assets/install-server-modal-Dpy89p4g.js +0 -1
- package/build/assets/kebab-menu-item-content-D8hSNGmm.js +0 -1
- package/build/assets/launch-IrTDEFCs.js +0 -1
- package/build/assets/list-filter-DsEK7NFC.js +0 -1
- package/build/assets/llm-not-configured-banner-CIFABh3K.js +0 -27
- package/build/assets/llm-settings-B9juXhIa.js +0 -1
- package/build/assets/llm-settings-De1d5dfr.js +0 -1
- package/build/assets/llm-subscription-service-BpJ0ouQo.js +0 -1
- package/build/assets/loader-circle-CC1au6hc.js +0 -1
- package/build/assets/manage-backends-modal-BrPV3oB-.js +0 -1
- package/build/assets/manifest-80fb1c29.js +0 -1
- package/build/assets/manifest-subpage-layout-CAOYzrYp.js +0 -1
- package/build/assets/markdown-renderer-BzTlxI8x.js +0 -8
- package/build/assets/mcp-BTs_SXfZ.js +0 -1
- package/build/assets/mcp-page-BEBYqH_K.js +0 -9
- package/build/assets/messages-DKV9cRc2.js +0 -41
- package/build/assets/modal-close-button-DDzdRvCs.js +0 -1
- package/build/assets/onboarding-DV_OXoeP.js +0 -1
- package/build/assets/onboarding-modal-rkyBYkeQ.js +0 -1
- package/build/assets/organization-service.api-DrYNkEN_.js +0 -1
- package/build/assets/pencil-47jAZH_V.js +0 -1
- package/build/assets/pin-By41Vl5J.js +0 -1
- package/build/assets/planner-tab-C9uZmhme.js +0 -1
- package/build/assets/plug-CG5HFcNG.js +0 -1
- package/build/assets/plugins-management-service-BMJgC3Ga.js +0 -1
- package/build/assets/plus-C7Slq-0I.js +0 -1
- package/build/assets/profiles-service.api-ChoKrL0l.js +0 -1
- package/build/assets/providers-BhMcY5nv.js +0 -1
- package/build/assets/proxy-9Fe1v5na.js +0 -1
- package/build/assets/recommended-automations-launcher-6ABrI9Cy.js +0 -1
- package/build/assets/refresh-cw-3q3Frrii.js +0 -1
- package/build/assets/root-Dc8YmC9F.js +0 -2
- package/build/assets/root-VDaypvK4.css +0 -1
- package/build/assets/root-layout-CXkhSPYh.js +0 -2
- package/build/assets/schema-field-D-y9-LDb.js +0 -1
- package/build/assets/scroll-fade-state-Dw-i4SGq.js +0 -1
- package/build/assets/sdk-section-page-BlFiizlG.js +0 -1
- package/build/assets/secret-form-BB7the8W.js +0 -1
- package/build/assets/secrets-service-ByZVENbp.js +0 -1
- package/build/assets/secrets-settings-B_GpxKW2.js +0 -1
- package/build/assets/settings-C0EWuBtA.js +0 -1
- package/build/assets/settings-dropdown-input-BcwylHs2.js +0 -1
- package/build/assets/settings-index-5w5UW2K3.js +0 -1
- package/build/assets/settings-input-Db-1g8Ql.js +0 -1
- package/build/assets/settings-modal-DfJ3tcJQ.js +0 -1
- package/build/assets/settings-service.api-DJ1r62Zr.js +0 -1
- package/build/assets/settings-switch-CS-dJDmA.js +0 -1
- package/build/assets/shared-conversation-CA5ISEDy.js +0 -1
- package/build/assets/shield-check-D2aCRd16.js +0 -1
- package/build/assets/sidebar-mobile-menu-toggle-C_fb0Jki.js +0 -1
- package/build/assets/sidebar-store-DGqHkVLw.js +0 -1
- package/build/assets/skill-card-pill-row-B27-xyig.js +0 -1
- package/build/assets/skill-scope-B42H-XOc.js +0 -1
- package/build/assets/skills-plugins-tgF8EiXC.js +0 -1
- package/build/assets/skills-settings-BgJ9PaOe.js +0 -1
- package/build/assets/styled-tooltip-C4jf5Fv9.js +0 -1
- package/build/assets/task-list-tab-C5zcaktH.js +0 -1
- package/build/assets/toggle-switch-ChOLXv2n.js +0 -1
- package/build/assets/trash-2-D7K26eDO.js +0 -1
- package/build/assets/trash-D-HYiVYM.js +0 -1
- package/build/assets/triangle-alert-CtdXWHUI.js +0 -1
- package/build/assets/usage-tab-CVDffLPt.js +0 -1
- package/build/assets/use-acp-credential-form-XIQmpX6M.js +0 -1
- package/build/assets/use-activate-agent-profile-BLfmvDiG.js +0 -1
- package/build/assets/use-agent-profiles-Bd9Bvvp1.js +0 -1
- package/build/assets/use-canvas-extensions-Bi693ujJ.js +0 -1
- package/build/assets/use-config-A9QovgXO.js +0 -1
- package/build/assets/use-create-conversation-Dx3l7mFZ.js +0 -1
- package/build/assets/use-create-secret-B9cUFWRG.js +0 -1
- package/build/assets/use-has-permission-B3C8rQmR.js +0 -1
- package/build/assets/use-is-authed-nTBcM7dE.js +0 -1
- package/build/assets/use-llm-configured-BV9nZ1_j.js +0 -1
- package/build/assets/use-llm-profiles-BO-P4Oyo.js +0 -1
- package/build/assets/use-manifest-capabilities-Cw_flwEz.js +0 -1
- package/build/assets/use-onboarding-completion-D8U7k4Qb.js +0 -1
- package/build/assets/use-pinned-home-route-CckOZrmb.js +0 -1
- package/build/assets/use-plugins-marketplace-7i94Zu3Z.js +0 -1
- package/build/assets/use-save-agent-profile-BUjSsDXK.js +0 -1
- package/build/assets/use-settings-DSXLbvBl.js +0 -1
- package/build/assets/use-settings-nav-items-CwRw-CmX.js +0 -16
- package/build/assets/use-tracking-D53y3TH9.js +0 -3
- package/build/assets/useQueries-DlbhlH9I.js +0 -1
- package/build/assets/useQuery-BSTgq1rl.js +0 -1
- package/build/assets/utils-CN5ZfZy1.js +0 -1
- package/build/assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js +0 -186
- package/build/assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js +0 -1
- package/build/assets/vendor~root-layout-C9Ju9DQg.js +0 -1
- package/build/assets/vendor~root-layout~conversation-panel~conversation~skills-settings~automations-list~shared-~bovqqk8e-BWir3rJs.js +0 -1
- package/build/assets/vendor~root-layout~index-home~home~conversation-panel~conversation~mcp~automations-list~aut~ibfbmr9f-cDuKr-WD.js +0 -1
- package/build/assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js +0 -1
- package/build/assets/x-DJdhbdmt.js +0 -1
- package/dist/components/features/conversation-panel/conversation-panel-filter-menu.cjs +0 -2
- package/dist/components/features/conversation-panel/conversation-panel-filter-menu.cjs.map +0 -1
- package/dist/components/features/conversation-panel/conversation-panel-filter-menu.d.ts +0 -35
- package/dist/components/features/conversation-panel/conversation-panel-filter-menu.js +0 -247
- package/dist/components/features/conversation-panel/conversation-panel-filter-menu.js.map +0 -1
- package/dist/hooks/query/use-skills.cjs +0 -2
- package/dist/hooks/query/use-skills.cjs.map +0 -1
- package/dist/hooks/query/use-skills.d.ts +0 -7
- package/dist/hooks/query/use-skills.js +0 -13
- package/dist/hooks/query/use-skills.js.map +0 -1
- package/dist/hooks/use-has-permission.cjs +0 -2
- package/dist/hooks/use-has-permission.cjs.map +0 -1
- package/dist/hooks/use-has-permission.d.ts +0 -1
- package/dist/hooks/use-has-permission.js +0 -8
- package/dist/hooks/use-has-permission.js.map +0 -1
- package/dist/node_modules/lucide-react/dist/esm/icons/eye.cjs +0 -2
- package/dist/node_modules/lucide-react/dist/esm/icons/eye.cjs.map +0 -1
- package/dist/node_modules/lucide-react/dist/esm/icons/eye.js +0 -14
- package/dist/node_modules/lucide-react/dist/esm/icons/eye.js.map +0 -1
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{M as t,N as n,St as r,j as i,yt as a}from"./vendor-styling-Ck5D_A2Q.js";import{n as o}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js";import{t as s}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{D as c,_ as l}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{t as u}from"./useMutation-B-qc391N.js";import{t as d}from"./useQuery-BSTgq1rl.js";import{t as f}from"./vendor~root-layout~conversation-panel~conversation~skills-settings~automations-list~shared-~bovqqk8e-BWir3rJs.js";import{Ft as p,Jt as m,ht as h,it as g,n as _,pt as v,tt as ee,ut as te}from"./active-backend-context-CrHTlgvN.js";import{O as y,R as b,W as x,k as S,t as C}from"./utils-CN5ZfZy1.js";import{t as w}from"./chevron-down-e1QBpjVy.js";import{t as T}from"./chevron-right-ZG4R5G4Q.js";import{t as E}from"./loader-circle-CC1au6hc.js";import{i as ne}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~nj1hli3r-DP9wmsjo.js";import{t as re}from"./proxy-9Fe1v5na.js";import{t as ie}from"./use-config-A9QovgXO.js";import{n as D}from"./use-settings-DSXLbvBl.js";import{n as ae,o as oe}from"./form-control-classes-Bkh5FGrD.js";import{n as se}from"./navigation-context-CQZwH_tC.js";import{ot as ce,st as le}from"./vendor-markdown-j0kYzV48.js";import{t as ue}from"./styled-tooltip-C4jf5Fv9.js";import{_ as de,t as fe}from"./conversation-store-Ca3ghXap.js";import{c as pe,d as me,t as he,v as ge}from"./agent-server-conversation-service.api-tnqNjbpE.js";import{_ as _e,a as ve,h as ye,o as be,p as xe,r as Se,s as Ce}from"./conversation-state-store-B0ImPLHO.js";import{n as we}from"./vendor~root-layout~conversation-panel~conversation~shared-conversation-DOuig0C0.js";import{t as Te}from"./skills-B0IliMxw.js";import{r as Ee}from"./format-model-name-CasAP3nd.js";import{t as De}from"./close-ScPlnwyq.js";import{t as Oe}from"./copy-to-clipboard-button-Ca8iSkkA.js";import{r as O}from"./typography-v1KN0tzi.js";import{t as ke}from"./u-check-circle-BKn1spCL.js";import{A as Ae,B as je,C as Me,F as Ne,H as k,L as Pe,M as A,N as Fe,O as Ie,Q as Le,T as Re,U as ze,W as Be,Z as Ve,_ as He,a as Ue,b as We,c as Ge,et as j,g as Ke,i as qe,j as Je,k as Ye,n as Xe,o as Ze,q as Qe,r as $e,t as M,v as N,z as et}from"./markdown-renderer-BzTlxI8x.js";import{t as tt}from"./syntax-highlighter-BGDg_7w9.js";import{n as nt,t as rt}from"./get-git-path-ChKDVHZp.js";var it=c(`arrow-up-right`,[[`path`,{d:`M7 7h10v10`,key:`1tivn9`}],[`path`,{d:`M7 17 17 7`,key:`1vkiza`}]]),P=e(r(),1);function at(){!t.current&&i();let[e]=(0,P.useState)(n.current);return e}var F=a(),ot=function(e){return e.INIT=`initialize`,e.MESSAGE=`message`,e.SYSTEM=`system`,e.READ=`read`,e.WRITE=`write`,e.RUN=`run`,e.RUN_IPYTHON=`run_ipython`,e.BROWSE=`browse`,e.BROWSE_INTERACTIVE=`browse_interactive`,e.DELEGATE=`delegate`,e.THINK=`think`,e.FINISH=`finish`,e.REJECT=`reject`,e.CHANGE_AGENT_STATE=`change_agent_state`,e.MCP=`call_tool_mcp`,e.TASK_TRACKING=`task_tracking`,e}(ot||{});function st(){let{conversationId:e}=j(),t=Ge();return{send:(0,P.useCallback)(async e=>{if(t){let{action:n,args:r}=e;if(n===`message`&&r?.content){let e=[{type:`text`,text:r.content}];return r.image_urls&&r.image_urls.length>0&&e.push({type:`image`,image_urls:r.image_urls}),await t.sendMessage({role:`user`,content:e})}return{queued:!1}}return{queued:!1}},[t,e])}}function ct(e,t,n,r){return{action:ot.MESSAGE,args:{content:e,image_urls:t,file_urls:n,timestamp:r}}}var I=e=>(0,F.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 448 512`,...e,children:(0,F.jsx)(`path`,{d:`M201.4 374.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 306.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z`})}),L=e=>(0,F.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 448 512`,...e,children:(0,F.jsx)(`path`,{d:`M201.4 137.4c12.5-12.5 32.8-12.5 45.3 0l160 160c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L224 205.3 86.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l160-160z`})});function lt({status:e}){return(0,F.jsx)(`span`,{className:`flex-shrink-0`,children:e===`timeout`&&(0,F.jsx)(we,{"data-testid":`status-icon`,className:`h-4 w-4 ml-2 inline fill-yellow-500`})})}function R({title:e,details:t,success:n,initiallyExpanded:r=!1,chevronPosition:i=`after`,titleTrailing:a,titleIcon:o}){let{t:c}=s(`openhands`),[l,u]=P.useState(r),d=t?(0,F.jsx)(`button`,{type:`button`,onClick:()=>u(e=>!e),className:`cursor-pointer text-left`,"aria-label":c(l?x.BUTTON$COLLAPSE:x.BUTTON$EXPAND),children:l?(0,F.jsx)(L,{className:C(`h-4 w-4 inline fill-[var(--oh-muted)]`,i===`after`?`ml-2`:`mr-2`)}):(0,F.jsx)(I,{className:C(`h-4 w-4 inline fill-[var(--oh-muted)]`,i===`after`?`ml-2`:`mr-2`)})}):null;return(0,F.jsxs)(`div`,{className:`flex flex-col gap-1.5 my-1 py-1 text-sm w-full`,children:[(0,F.jsxs)(`div`,{className:`flex items-center justify-between font-normal text-[var(--oh-muted)]`,children:[(0,F.jsxs)(`div`,{className:`flex items-center`,children:[i===`before`&&d,o,(0,F.jsx)(`span`,{children:e}),i===`after`&&d]}),(0,F.jsxs)(`div`,{className:`flex items-center`,children:[a,n&&(0,F.jsx)(lt,{status:n})]})]}),l&&(typeof t==`string`?(0,F.jsx)(M,{children:t}):t)]})}var ut=e=>(0,F.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 512 512`,...e,children:(0,F.jsx)(`path`,{d:`M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM369 209L241 337c-9.4 9.4-24.6 9.4-33.9 0l-64-64c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0l47 47L335 175c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9z`})}),dt=e=>(0,F.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 512 512`,...e,children:(0,F.jsx)(`path`,{d:`M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM175 175c9.4-9.4 24.6-9.4 33.9 0l47 47 47-47c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9l-47 47 47 47c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0l-47-47-47 47c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l47-47-47-47c-9.4-9.4-9.4-24.6 0-33.9z`})}),ft={running:x.GOAL$STATUS_RUNNING,complete:x.GOAL$STATUS_COMPLETE,capped:x.GOAL$STATUS_CAPPED,interrupted:x.GOAL$STATUS_INTERRUPTED};function pt({status:e}){let{t}=s(`openhands`),{conversationId:n}=j(),r=We(e=>n?!!e.statusByConversation[n]?.active:!1),[i,a]=(0,P.useState)(!1),{active:o,objective:c,iteration:l,max_iterations:u,verdict:d}=e,f=d?Math.round(d.score*100):null,m=d?.missing?t(x.GOAL$MISSING,{missing:d.missing}):``,h=async(e,r)=>{if(!(!n||i)){a(!0);try{await e(n)}catch(e){p(e instanceof Error&&e.message?e.message:t(r))}finally{a(!1)}}},g=()=>h(async e=>{await _e(e),await xe(e)},x.GOAL$STOP_FAILED),_=()=>h(ye,x.GOAL$RESUME_FAILED),v=null;return n&&o?v=(0,F.jsx)(`button`,{type:`button`,"data-testid":`goal-stop`,disabled:i,onClick:g,className:C(ae,oe),children:t(x.GOAL$STOP)}):n&&e.status===`interrupted`&&!r&&(v=(0,F.jsx)(`button`,{type:`button`,"data-testid":`goal-resume`,disabled:i,onClick:_,className:C(ae,oe),children:t(x.GOAL$RESUME)})),(0,F.jsx)(`div`,{"data-testid":`goal-status`,className:`flex flex-col w-full`,children:(0,F.jsx)(R,{title:(0,F.jsxs)(`span`,{className:`flex items-center gap-2 flex-wrap`,children:[(0,F.jsx)(`span`,{className:`opacity-60`,children:t(x.GOAL$PREFIX)}),(0,F.jsx)(`span`,{children:c}),(0,F.jsx)(`span`,{className:`opacity-60`,children:t(x.GOAL$ROUND,{iteration:l,max:u})}),(0,F.jsx)(`span`,{children:t(ft[e.status])}),f!==null&&(0,F.jsx)(`span`,{className:`opacity-60`,children:t(x.GOAL$SCORE,{score:f})}),o?(0,F.jsx)(`span`,{"data-testid":`goal-spinner`,className:`inline-block w-3.5 h-3.5 ml-1 rounded-full border-2 border-transparent border-t-[var(--oh-border-input)] animate-spin`}):e.status===`complete`?(0,F.jsx)(`span`,{"data-testid":`goal-done`,className:`inline-flex ml-1`,children:(0,F.jsx)(ut,{className:`w-3.5 h-3.5 fill-success`})}):(0,F.jsx)(`span`,{"data-testid":`goal-ended`,className:`inline-flex ml-1`,children:(0,F.jsx)(dt,{className:`w-3.5 h-3.5 fill-[var(--oh-muted)]`})})]}),titleTrailing:v,details:m,initiallyExpanded:!o,chevronPosition:`before`})})}var mt=e=>(0,F.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:12,height:12,viewBox:`0 0 12 12`,fill:`none`,...e,children:[(0,F.jsxs)(`g`,{clipPath:`url(#clip0_17463_15006)`,children:[(0,F.jsx)(`path`,{d:`M6 11C8.76142 11 11 8.76142 11 6C11 3.23858 8.76142 1 6 1C3.23858 1 1 3.23858 1 6C1 8.76142 3.23858 11 6 11Z`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`}),(0,F.jsx)(`path`,{d:`M6 8V6`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`}),(0,F.jsx)(`path`,{d:`M6 4H6.00667`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`})]}),(0,F.jsx)(`defs`,{children:(0,F.jsx)(`clipPath`,{id:`clip0_17463_15006`,children:(0,F.jsx)(`rect`,{width:12,height:12,fill:`white`})})})]});function ht({profile:e}){let[t,n]=P.useState(!1),r=Ee(e.model);return(0,F.jsxs)(`div`,{className:`border border-neutral-700 rounded-md overflow-hidden`,children:[(0,F.jsxs)(`button`,{type:`button`,onClick:()=>n(e=>!e),"aria-expanded":t,"aria-label":`Toggle details for ${e.name}`,className:`w-full py-1.5 px-2 text-left flex items-center gap-2 hover:bg-neutral-700 transition-colors cursor-pointer`,children:[(0,F.jsx)(`span`,{className:`text-neutral-300`,children:t?(0,F.jsx)(w,{size:14}):(0,F.jsx)(T,{size:14})}),(0,F.jsx)(`span`,{className:`font-normal text-neutral-200 text-sm`,children:e.name})]}),t&&(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`hr`,{className:`border-neutral-700`}),(0,F.jsx)(`div`,{className:`px-3 py-2 text-xs text-neutral-300 font-mono whitespace-pre-wrap`,children:`model: ${r??`—`}\nbase_url: ${e.base_url??`—`}\napi_key: ${e.api_key_set?`set`:`not set`}`})]})]})}function gt({conversationId:e,anchorEventId:t}){let n=He(e=>e.entriesByConversation),r=(e?n[e]??[]:[]).filter(e=>e.anchorEventId===t);return!e||r.length===0?null:(0,F.jsx)(`div`,{"data-testid":`model-messages`,className:`flex flex-col w-full`,children:r.map(e=>{if(e.switchedTo)return(0,F.jsx)(R,{title:(0,F.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,F.jsx)(mt,{width:14,height:14,className:`shrink-0 text-neutral-400`,"aria-hidden":!0}),(0,F.jsx)(f,{i18nKey:x.MODEL$SWITCHED_TO_PROFILE,values:{name:e.switchedTo},components:{cmd:(0,F.jsx)(`span`,{className:`font-mono text-neutral-200 bg-neutral-800 px-1 rounded`})}})]}),details:``},e.id);let t=e.profiles.length===0;return(0,F.jsx)(R,{title:(0,F.jsx)(`span`,{children:t?(0,F.jsx)(f,{i18nKey:x.MODEL$NO_SAVED_PROFILES}):(0,F.jsx)(f,{i18nKey:x.MODEL$AVAILABLE_PROFILES,values:{count:e.profiles.length}})}),details:t?(0,F.jsx)(`span`,{className:`text-neutral-300 text-sm px-2 py-1 block`,children:(0,F.jsx)(f,{i18nKey:x.MODEL$NO_PROFILES_HINT})}):(0,F.jsx)(`div`,{className:`flex flex-col gap-1 mt-1`,children:e.profiles.map(e=>(0,F.jsx)(ht,{profile:e},e.name))}),initiallyExpanded:t},e.id)})})}function _t(e){let[t,n]=(0,P.useState)(!0),[r,i]=(0,P.useState)(!0),a=(0,P.useRef)(0),o=(0,P.useCallback)(e=>e.scrollTop+e.clientHeight>=e.scrollHeight-20,[]),s=(0,P.useCallback)(e=>{let t=o(e);i(t);let r=e.scrollTop,s=r<a.current;a.current=r,s&&n(!1),t&&n(!0)},[o]);return{scrollRef:e,autoScroll:t,setAutoScroll:n,scrollDomToBottom:(0,P.useCallback)(()=>{let t=e.current;t&&requestAnimationFrame(()=>{n(!0),i(!0),t.scrollTop=t.scrollHeight})},[e]),hitBottom:r,setHitBottom:i,onChatBodyScroll:s}}var vt=(0,P.createContext)(void 0);function yt({children:e,value:t}){let n=_t(P.useRef(null)),r=t||n;return(0,F.jsx)(vt.Provider,{value:r,children:e})}function bt(){let e=(0,P.useContext)(vt);if(e===void 0)throw Error(`useScrollContext must be used within a ScrollProvider`);return e}function xt(){return(0,P.useContext)(vt)}var St=class{static async executeCommand(e,t,n,r,i=30){let a=te().backend;if(a.kind===`cloud`&&e){let o=await re({backend:a,method:`POST`,hostOverride:g(e),path:`/api/bash/execute_bash_command`,body:{command:n,...r?{cwd:r}:{},timeout:Math.floor(i)},authMode:`session-api-key`,sessionApiKey:t,timeoutSeconds:i+10});return{exit_code:o.exit_code??-1,stdout:o.stdout??``,stderr:o.stderr??``}}let o=await new ne(ee({conversationUrl:e,sessionApiKey:t})).executeCommand(n,r,i);return{exit_code:o.exit_code,stdout:o.stdout,stderr:o.stderr}}static async downloadFile(e,t,n){let r=te().backend;return r.kind===`cloud`&&e?(await re({backend:r,method:`GET`,hostOverride:g(e),path:`/api/file/download?path=${encodeURIComponent(n)}`,authMode:`session-api-key`,sessionApiKey:t,responseType:`blob`})).arrayBuffer():new l(ee({conversationUrl:e,sessionApiKey:t})).downloadFile(n)}},Ct=2e3,wt=[`.git`,`node_modules`,`.venv`,`venv`,`__pycache__`,`dist`,`build`,`.next`,`.cache`,`.pytest_cache`,`.mypy_cache`,`.turbo`,`.parcel-cache`,`target`];function Tt(){return`find . \\( ${wt.map(e=>`-name '${e}' -prune`).join(` -o `)} \\) -o -type f -print 2>/dev/null | sort | head -n ${Ct}`}function Et(e){return e.startsWith(`./`)?e.slice(2):e}function Dt(e){let{data:t}=Le(),n=nt(),r=t?.id,i=t?.conversation_url,a=t?.session_api_key,o=t?.workspace?.working_dir?.trim(),s=d({queryKey:[`workspace-files`,r,i,a,o],queryFn:async()=>{let e=await St.executeCommand(i,a,Tt(),o,30);if(e.exit_code!==0)throw Error(e.stderr?.trim()||`Failed to list workspace files`);let t=e.stdout.split(/\r?\n/).map(e=>e.trim()).filter(Boolean).map(Et);return Array.from(new Set(t)).slice(0,Ct)},enabled:e&&n&&!!r&&!!o,retry:!1,staleTime:1e3*30,gcTime:1e3*60*5,meta:{disableToast:!0}});return{data:s.data,isLoading:s.isLoading}}function Ot(e){let{conversationId:t}=j(),{data:n}=Le(),r=nt(),i=n?.selected_repository,a=n?.workspace?.working_dir?.trim(),o=rt(i,a),s=o.startsWith(`/`)?o:`/${o}`,c=d({queryKey:[`workspace-files-cloud`,t,s],queryFn:async()=>{let e=(await ge(t,s)).map(Et).filter(Boolean);return Array.from(new Set(e)).slice(0,Ct)},enabled:e&&r&&!!t,retry:!1,staleTime:1e3*30,gcTime:1e3*60*5,meta:{disableToast:!0}});return{data:c.data,isLoading:c.isLoading}}function kt(){let e=(0,P.useSyncExternalStore)(h,v,v).active.backend.kind===`cloud`,t=Dt(!e),n=Ot(e);return e?n:t}var At=(0,P.createContext)(!1),jt=(0,P.createContext)(void 0);function Mt({children:e}){let{data:t}=kt();return(0,F.jsx)(jt.Provider,{value:t,children:e})}function Nt(e){if(e==null||typeof e==`boolean`)return``;if(typeof e==`string`||typeof e==`number`)return String(e);if(Array.isArray(e)){let t=e.map(Nt);return t.some(e=>e===null)?null:t.join(``)}return null}function Pt(e){let t=(0,P.useContext)(jt);if(!t?.length||!Se(e))return null;let n=Ce.getCurrentConversation()?.workspace?.working_dir,r=ve(e,n);return r&&t.includes(r)?r:null}function Ft({path:e,className:t,children:n}){let{conversationId:r}=j();return(0,F.jsx)(`button`,{type:`button`,"data-testid":`markdown-file-path-link`,title:e,className:C(t,`cursor-pointer rounded border border-surface-raised bg-surface-raised px-[0.4em] py-[0.2em] font-mono text-foreground hover:underline`),onClick:t=>{t.stopPropagation(),N(e,r)},children:n})}function It(e){let{children:t,className:n}=e,r=(0,P.useContext)(At),i=/language-(\w+)/.exec(n||``),a=String(t).replace(/\n$/,``),o=String(t).includes(`
|
|
2
|
-
`),s=Pt(!i&&!o&&!r?a:``);return s?(0,F.jsx)(Ft,{path:s,className:n,children:t}):$e(e)}function Lt(e){let{children:t}=e,n=(0,P.useContext)(At),r=Nt(t)?.trim()??``,i=Pt(n?``:r);return i?(0,F.jsx)(Ft,{path:i,children:t}):(0,F.jsx)(`strong`,{children:t})}function Rt(e){return(0,F.jsx)(At.Provider,{value:!0,children:Xe(e)})}var z=1e3,zt=e=>`\`\`\`json\n${JSON.stringify(e,null,2)}\n\`\`\``,Bt=e=>{switch(e.tool_kind){case`execute`:return`ACTION_MESSAGE$ACP_RUN`;case`edit`:return`ACTION_MESSAGE$ACP_EDIT`;case`read`:return`ACTION_MESSAGE$ACP_READ`;case`fetch`:return`ACTION_MESSAGE$ACP_FETCH`;default:return`ACTION_MESSAGE$ACP_TOOL`}},Vt={read:[`Read`],edit:[`Edit`,`Write`],execute:[`Bash`,`Run`],fetch:[`Fetch`,`WebFetch`]},Ht=e=>{let t=e.title,n=e.tool_kind;if(!t||!n)return t;let r=Vt[n];if(!r)return t;for(let e of r)if(t.length>e.length&&t.startsWith(e)&&/\s/.test(t.charAt(e.length)))return t.slice(e.length).trimStart();return t},Ut=e=>{if(e==null)return``;if(typeof e==`string`)return e;try{return JSON.stringify(e,null,2)}catch{return String(e)}},Wt=e=>e.length>1e3?`${e.slice(0,z)}...`:e,Gt=e=>{let t=e.tool_kind,n=e.raw_input,r=e.raw_output,i=e.is_error,a=``;if(t===`execute`&&n&&typeof n==`object`&&`command`in n&&typeof n.command==`string`){let{command:e}=n;a+=`Command: \`${e}\`\n\n`}else if(n!=null&&n!==``){let e=Ut(n);e.trim()&&(a+=`Input:\n\`\`\`json\n${e}\n\`\`\`\n\n`)}let o=Wt(Ut(r).trim()),s=i?`**Error:**`:`Output:`,c=o||m.t(x.OBSERVATION$COMMAND_NO_OUTPUT);return a+=`${s}\n\`\`\`\n${c}\n\`\`\``,a},B=(e,t)=>e?e.length>t?`${e.substring(0,t)}...`:e:``,Kt=e=>/^[a-z][a-z0-9_]*\s*:\s*[[{]/i.test(e),qt=e=>{let t=e.summary?.trim().replace(/\s+/g,` `)||``;return!t||Kt(t)?null:t},Jt=e=>{let t=qt(e);if(t)return{kind:`text`,text:t};let n=e.action.kind;switch(n){case`ExecuteBashAction`:case`TerminalAction`:return{kind:`translation`,key:`ACTION_MESSAGE$RUN`,values:{command:B(e.action.command,80)}};case`FileEditorAction`:case`StrReplaceEditorAction`:return{kind:`translation`,key:e.action.command===`view`?`ACTION_MESSAGE$READ`:e.action.command===`create`?`ACTION_MESSAGE$WRITE`:`ACTION_MESSAGE$EDIT`,values:{path:e.action.path}};case`MCPToolAction`:return{kind:`translation`,key:`ACTION_MESSAGE$CALL_TOOL_MCP`,values:{mcp_tool_name:e.tool_name}};case`InvokeSkillAction`:return{kind:`translation`,key:`ACTION_MESSAGE$INVOKE_SKILL`,values:{name:e.action.name}};case`TaskAction`:return{kind:`translation`,key:`ACTION_MESSAGE$TASK`,values:{name:e.action.subagent_type}};case`ThinkAction`:return{kind:`translation`,key:`ACTION_MESSAGE$THINK`,values:{}};case`FinishAction`:return{kind:`translation`,key:`ACTION_MESSAGE$FINISH`,values:{}};case`TaskTrackerAction`:return{kind:`translation`,key:`ACTION_MESSAGE$TASK_TRACKING`,values:{}};case`GrepAction`:return{kind:`translation`,key:`ACTION_MESSAGE$GREP`,values:{pattern:e.action.pattern?B(e.action.pattern,50):``}};case`GlobAction`:return{kind:`translation`,key:`ACTION_MESSAGE$GLOB`,values:{pattern:e.action.pattern?B(e.action.pattern,50):``}};case`BrowserNavigateAction`:case`BrowserClickAction`:case`BrowserTypeAction`:case`BrowserGetStateAction`:case`BrowserGetContentAction`:case`BrowserScrollAction`:case`BrowserGoBackAction`:case`BrowserListTabsAction`:case`BrowserSwitchTabAction`:case`BrowserCloseTabAction`:return{kind:`translation`,key:`ACTION_MESSAGE$BROWSE`,values:{}};case`CanvasUIAction`:case me:return{kind:`text`,text:`CANVASUI`};case pe:return{kind:`translation`,key:`ACTION_MESSAGE$LAUNCH_CHILD_CONVERSATION`,values:{}};default:return{kind:`text`,text:String(n).replace(`Action`,``).toUpperCase()}}},Yt=class{static isDevMode=!1;static message(e){this.isDevMode&&console.warn(JSON.stringify(JSON.parse(e.data.toString()),null,2))}static event(e,t){this.isDevMode&&console.warn(t||`EVENT`,e)}static warning(e){this.isDevMode&&console.warn(e)}static error(e){this.isDevMode&&console.error(e)}},Xt=e=>{let t=document.createElement(`textarea`);return t.innerHTML=e,t.value};function Zt(e){let{children:t}=e,n=e=>{try{return Xt(e)}catch(t){return Yt.error(String(t)),e}};return Array.isArray(t)?(0,F.jsx)(`strong`,{className:`font-mono`,children:t.map(e=>typeof e==`string`?n(e):e)}):typeof t==`string`?(0,F.jsx)(`strong`,{className:`font-mono`,children:n(t)}):(0,F.jsx)(`strong`,{className:`font-mono`,children:t})}var Qt=(0,P.createContext)(!0),$t=e=>{let t=document.createElement(`textarea`);return t.innerHTML=e,t.value},en=e=>e?e.endsWith(`/`)||e.endsWith(`\\`)?!0:!(e.split(/[/\\]/).pop()||``).includes(`.`):!1,tn=e=>{if(!e)return``;let t=e.split(/[/\\]/),n=t[t.length-1];return en(e)&&!n.endsWith(`/`)?`${n}/`:n};function nn(e){let{children:t}=e,{conversationId:n}=j(),r=(0,P.useContext)(Qt),i=e=>{try{let t=$t(e),i=tn(t);return r?(0,F.jsx)(`button`,{type:`button`,"data-testid":`path-component-link`,className:`cursor-pointer font-mono font-normal tracking-tight hover:underline`,title:t,onClick:e=>{e.stopPropagation(),N(t,n)},children:i}):(0,F.jsx)(`span`,{className:`font-mono font-normal tracking-tight`,title:t,children:i})}catch(t){return Yt.error(String(t)),(0,F.jsx)(`span`,{className:`font-mono font-normal tracking-tight`,children:e})}};return Array.isArray(t)?(0,F.jsx)(`span`,{className:`font-normal tracking-tight`,children:t.map((e,t)=>typeof e==`string`?(0,F.jsx)(`span`,{children:i(e)},`${e}-${t}`):e)}):typeof t==`string`?(0,F.jsx)(`span`,{className:`font-normal tracking-tight`,children:i(t)}):(0,F.jsx)(`span`,{className:`font-mono font-normal tracking-tight`,children:t})}var rn=()=>{let{setConversationMode:e}=fe(),{send:t}=st(),{conversationId:n}=j(),r=Me(e=>e.enqueuePendingMessage),i=Me(e=>e.markPendingMessageError);return{handleBuildPlanClick:(0,P.useCallback)(a=>{a?.preventDefault(),a?.stopPropagation(),e(`code`);let o=`Execute the plan based on the .agents_tmp/PLAN.md file.`,s=new Date().toISOString(),c=n?r({conversationId:n,text:o,timestamp:s}):null;t(ct(o,[],[],s)).catch(e=>{c&&i(c,e instanceof Error?e.message:`Failed to send message`)})},[e,t,n,r,i])}},an=`200%`,V=8,on=V*2;function sn({children:e,as:t=`p`,className:n,duration:r=2,spread:i=2,style:a,...o}){let s=at(),c=`oh-text-shimmer-${(0,P.useId)().replace(/:/g,``)}`,l=(0,P.useMemo)(()=>Math.min(V/2-1,1+i/2),[i]),u=(0,P.useMemo)(()=>{let e=V/2;return{...a,backgroundImage:`repeating-linear-gradient(90deg, var(--oh-muted) 0%, var(--oh-muted) ${e-l}%, var(--oh-foreground) ${e}%, var(--oh-muted) ${e+l}%, var(--oh-muted) ${V}%)`,backgroundSize:`${an} 100%`,backgroundRepeat:`no-repeat`,WebkitBackgroundClip:`text`,backgroundClip:`text`,color:`transparent`,WebkitTextFillColor:`transparent`,animation:`${c} ${r}s linear infinite`}},[c,l,r,a]);return s?(0,F.jsx)(t,{className:C(`text-[var(--oh-muted)]`,n),style:a,...o,children:e}):(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`style`,{dangerouslySetInnerHTML:{__html:`@keyframes ${c}{from{background-position:${on}% center}to{background-position:0% center}}`}}),(0,F.jsx)(t,{className:C(`relative inline-block`,n),style:u,...o,children:e})]})}var cn=P.memo(sn);function ln({className:e}){return(0,F.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":!0,className:e,children:[(0,F.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,className:`fill-[var(--oh-foreground)] transition-colors duration-150 group-hover:fill-[var(--oh-text-secondary)]`}),(0,F.jsx)(`rect`,{x:`9`,y:`9`,width:`6`,height:`6`,rx:`1`,className:`fill-[var(--oh-color-tertiary)]`})]})}var un=5,dn=360,fn={p:({children:e})=>(0,F.jsx)(`p`,{className:`m-0 leading-6`,children:e}),code:It,a:Rt,strong:Lt};function pn({message:e,isHovering:t,isExpanded:n,onTruncatableChange:r}){let{t:i}=s(`openhands`),a=P.useRef(null),[o,c]=P.useState(!1);P.useEffect(()=>{r(o)},[o,r]),P.useLayoutEffect(()=>{let t=a.current;if(!t||n){c(!1);return}let r=()=>{let n=Number.parseFloat(getComputedStyle(t).lineHeight),r=un*(Number.isFinite(n)&&n>0?n:24),i=(e.match(/\n/g)??[]).length;c(t.scrollHeight>r+1||i>=un||e.trim().length>dn)};r();let i=new ResizeObserver(r);return i.observe(t),()=>i.disconnect()},[e,n]);let l=o&&!n;return(0,F.jsxs)(`div`,{className:`relative min-w-0`,children:[(0,F.jsx)(`div`,{ref:a,className:C(`text-sm leading-6 whitespace-normal [word-break:break-word]`,l&&`line-clamp-5`),children:(0,F.jsx)(M,{includeStandard:!0,includeHeadings:!0,allowHtml:!1,components:fn,children:e})}),l?(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`div`,{"aria-hidden":!0,"data-testid":`chat-message-truncation-gradient`,className:`pointer-events-none absolute inset-x-0 bottom-0 h-10 bg-gradient-to-t from-tertiary to-transparent`}),(0,F.jsx)(`span`,{"data-testid":`chat-message-view-more`,className:C(`pointer-events-none absolute bottom-1 left-1/2 z-10 inline-flex -translate-x-1/2 items-center rounded-full border border-[var(--oh-border-subtle)] bg-[var(--oh-surface-raised)] px-2.5 py-0.5 text-xs font-normal text-[var(--oh-foreground)] transition-opacity duration-150`,t?`opacity-100`:`opacity-0`),children:i(x.COMMON$VIEW_MORE)})]}):null]})}function H({type:e,message:t,children:n,actions:r,isFromPlanningAgent:i=!1,pendingStatus:a,onRetry:o,onDismiss:c,onStop:l}){let{t:u}=s(`openhands`),[d,f]=P.useState(!1),[p,m]=P.useState(!1),[h,g]=P.useState(!1),[_,v]=P.useState(!1),[ee,te]=P.useState(!0),y=P.useRef(null);P.useEffect(()=>{g(!1)},[t]);let b=async()=>{await navigator.clipboard.writeText(t),m(!0)};P.useEffect(()=>{let e;return p&&(e=setTimeout(()=>{m(!1)},2e3)),()=>{clearTimeout(e)}},[p]);let S=e===`user`&&(a===`error`||a===`sending`),w=a===`sending`&&l!=null,T=w&&d,E=e===`user`&&a==null,ne=E&&_&&!h,re=P.Children.count(n)>0;P.useLayoutEffect(()=>{if(!w||E)return;let e=y.current;if(!e)return;let t=()=>{let t=Number.parseFloat(getComputedStyle(e).lineHeight),n=Number.isFinite(t)&&t>0?t:24;te(e.scrollHeight<=n+1)};t();let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[t,w,E]);let ie=E?(0,F.jsx)(pn,{message:t,isHovering:d,isExpanded:h,onTruncatableChange:v}):(0,F.jsx)(`div`,{ref:y,className:`min-w-0 text-sm leading-6 whitespace-normal [word-break:break-word]`,children:(0,F.jsx)(M,{includeStandard:!0,includeHeadings:!0,allowHtml:e!==`user`,components:fn,children:t})}),D=(0,F.jsxs)(`article`,{"data-testid":`${e}-message`,"data-pending-status":a,onMouseEnter:()=>f(!0),onMouseLeave:()=>f(!1),className:C(`rounded-xl relative w-fit max-w-full flex flex-col`,re&&`gap-2`,e===`user`&&`mt-6 bg-tertiary self-end px-4 py-2.5`,e===`agent`&&`mt-6 w-full max-w-full bg-transparent`,i&&e===`agent`&&`border border-[#597ff4] bg-tertiary p-4 mt-2`,a===`error`&&`border border-[var(--oh-status-error)]/40`,!S&&`last:mb-4`),children:[(0,F.jsxs)(`div`,{className:C(`absolute -top-2.5 -right-2.5 z-10`,!d||a===`sending`?`hidden`:`flex`,`items-center gap-1`),onClick:e=>e.stopPropagation(),children:[r?.map((e,t)=>e.tooltip?(0,F.jsx)(ue,{content:e.tooltip,placement:`top`,children:(0,F.jsx)(`button`,{type:`button`,onClick:e.onClick,className:`button-base p-1 cursor-pointer`,"aria-label":e.tooltip,children:e.icon})},t):(0,F.jsx)(`button`,{type:`button`,onClick:e.onClick,className:`button-base p-1 cursor-pointer`,"aria-label":`Action ${t+1}`,children:e.icon},t)),(0,F.jsx)(Oe,{isHidden:!d,isDisabled:p,onClick:b,mode:p?`copied`:`copy`})]}),ie,w?(0,F.jsx)(`button`,{type:`button`,onClick:e=>{e.stopPropagation(),l?.()},"data-testid":`chat-message-stop`,"aria-label":u(x.BUTTON$STOP),"aria-hidden":!T,tabIndex:T?0:-1,className:C(`group absolute z-10 inline-flex h-7 w-7 cursor-pointer items-center justify-center rounded-full bg-[var(--oh-color-tertiary)] text-[var(--oh-foreground)] transition-opacity duration-150`,ee?`right-3 top-1/2 -translate-y-1/2`:`right-3 bottom-2.5`,T?`opacity-100`:`pointer-events-none opacity-0`),children:(0,F.jsx)(ln,{className:`block h-7 w-7 max-w-none`})}):null,ne?(0,F.jsx)(`button`,{type:`button`,"data-testid":`chat-message-expand`,"aria-expanded":!1,"aria-label":u(x.COMMON$VIEW_MORE),className:`absolute inset-0 z-[1] cursor-pointer rounded-xl border-0 bg-transparent p-0`,onClick:()=>g(!0)}):null,n]});return e===`user`&&a===`error`?(0,F.jsxs)(`div`,{className:`flex w-fit max-w-full flex-col items-end gap-1.5 self-end last:mb-4`,children:[D,(0,F.jsxs)(`div`,{role:`alert`,"data-testid":`chat-message-error`,className:`flex items-center gap-2 text-xs text-[var(--oh-status-error)]`,children:[(0,F.jsx)(`span`,{children:u(x.CHAT_INTERFACE$MESSAGE_SEND_FAILED)}),o?(0,F.jsx)(`button`,{type:`button`,onClick:o,className:`cursor-pointer rounded-md border border-[var(--oh-border)] px-2 py-1 text-xs font-normal text-[var(--oh-foreground)] hover:bg-[var(--oh-interactive-hover)]`,"data-testid":`chat-message-retry`,children:u(x.CHAT_INTERFACE$MESSAGE_RETRY)}):null,c?(0,F.jsx)(`button`,{type:`button`,onClick:c,className:`cursor-pointer rounded-md border border-[var(--oh-border)] px-2 py-1 text-xs font-normal text-[var(--oh-foreground)] hover:bg-[var(--oh-interactive-hover)]`,"data-testid":`chat-message-dismiss`,children:u(x.CHAT_INTERFACE$MESSAGE_DISMISS)}):null]})]}):e===`user`&&a===`sending`?(0,F.jsxs)(`div`,{className:`flex w-full max-w-full flex-col last:mb-4`,children:[D,(0,F.jsx)(`div`,{className:`my-1 w-full py-1 text-sm`,children:(0,F.jsx)(cn,{as:`p`,role:`status`,"aria-live":`polite`,"data-testid":`chat-message-sending`,className:`block w-full text-sm font-normal`,duration:1,spread:2,children:u(x.CHAT_INTERFACE$MESSAGE_SENDING)})})]}):D}function mn(e){return{h1:({children:t,className:n})=>(0,F.jsx)(`h1`,{className:C(`text-lg text-white font-bold leading-6 mb-1.5 mt-3 first:mt-0`,n,e),children:t}),h2:({children:t,className:n})=>(0,F.jsx)(`h2`,{className:C(`text-base font-semibold leading-5 text-white mb-1 mt-2.5 first:mt-0`,n,e),children:t}),h3:({children:t,className:n})=>(0,F.jsx)(`h3`,{className:C(`text-sm font-semibold text-white mb-1 mt-2 first:mt-0`,n,e),children:t}),h4:({children:t,className:n})=>(0,F.jsx)(`h4`,{className:C(`text-sm font-semibold text-white mb-1 mt-2 first:mt-0`,n,e),children:t}),h5:({children:t,className:n})=>(0,F.jsx)(`h5`,{className:C(`text-xs font-semibold text-white mb-0.5 mt-1.5 first:mt-0`,n,e),children:t}),h6:({children:t,className:n})=>(0,F.jsx)(`h6`,{className:C(`text-xs font-medium text-[var(--oh-text-tertiary)] mb-0.5 mt-1.5 first:mt-0`,n,e),children:t}),p:({children:t,className:n})=>(0,F.jsx)(`p`,{className:C(`py-2.5 first:pt-0 last:pb-0`,n,e),children:t}),ul:({children:t,className:n})=>(0,F.jsx)(`ul`,{className:C(`list-disc ml-5 pl-2 whitespace-normal`,n,e),children:t}),ol:({children:t,className:n,start:r})=>(0,F.jsx)(`ol`,{className:C(`list-decimal ml-5 pl-2 whitespace-normal`,n,e),start:r,children:t}),li:({children:t,className:n})=>(0,F.jsx)(`li`,{className:C(n,e),children:t}),a:({children:t,className:n,href:r})=>(0,F.jsx)(`a`,{className:C(`text-blue-500 hover:underline`,n,e),href:r,target:`_blank`,rel:`noopener noreferrer`,children:t}),code:({children:t,className:n})=>(0,F.jsx)(`code`,{className:C(`bg-[var(--oh-surface-raised)] px-1.5 py-0.5 rounded text-[var(--oh-foreground)] border border-[var(--oh-border-subtle)]`,n,e),children:t})}}var hn=mn(),gn=300,_n=mn(`shine-text`);function vn({planContent:e,isStreaming:t,isBuildDisabled:n}){let{t:r}=s(`openhands`),{navigateToTab:i}=Ue(),{handleBuildPlanClick:a}=rn(),{scrollDomToBottom:o}=bt(),c=()=>{i(`planner`)},l=(0,P.useCallback)(e=>{a(e),o()},[a,o]),u=(0,P.useMemo)(()=>e?e.length<=gn?e:`${e.slice(0,gn)}...`:``,[e]);return e?(0,F.jsxs)(`div`,{className:`bg-[var(--oh-surface)] border border-[#597FF4] rounded-[12px] w-full mt-2`,children:[(0,F.jsxs)(`div`,{className:`border-b border-[var(--oh-border)] flex h-[41px] items-center px-2 gap-1`,children:[(0,F.jsx)(Ze,{width:18,height:18,color:`var(--oh-muted)`}),(0,F.jsx)(O.Text,{className:`font-normal text-[11px] text-white tracking-[0.11px] leading-4`,children:r(x.COMMON$PLAN_MD)}),(0,F.jsx)(`div`,{className:`flex-1`}),(0,F.jsxs)(`button`,{type:`button`,onClick:c,className:`flex items-center gap-1 hover:opacity-80 transition-opacity cursor-pointer`,"data-testid":`plan-preview-view-button`,children:[(0,F.jsx)(O.Text,{className:`font-normal text-[11px] text-white tracking-[0.11px] leading-4`,children:r(x.COMMON$VIEW)}),(0,F.jsx)(it,{className:`text-white`,size:18})]})]}),(0,F.jsx)(`div`,{"data-testid":`plan-preview-content`,className:`flex flex-col gap-[10px] p-4 text-[15px] text-white leading-[29px]`,children:u&&(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(M,{includeStandard:!0,components:t?_n:hn,children:u}),e&&e.length>gn&&(0,F.jsx)(`button`,{type:`button`,onClick:c,className:`text-[#4a67bd] cursor-pointer hover:underline text-left`,"data-testid":`plan-preview-read-more-button`,children:r(x.COMMON$READ_MORE)})]})}),(0,F.jsx)(`div`,{className:`border-t border-[var(--oh-border)] flex h-[54px] items-center justify-start px-4`,children:(0,F.jsx)(`button`,{type:`button`,onClick:l,disabled:n,className:C(`bg-white flex items-center justify-center h-[26px] px-2 rounded-[4px] w-[93px] transition-opacity`,n?`opacity-50 cursor-not-allowed`:`hover:opacity-90 cursor-pointer`),"data-testid":`plan-preview-build-button`,children:(0,F.jsxs)(O.Text,{className:`font-normal text-[14px] text-black leading-5`,children:[r(x.COMMON$BUILD),` `,(0,F.jsx)(O.Text,{className:`font-normal text-black`,children:`⌘↩`})]})})})]}):null}function yn({errorId:e,defaultMessage:t}){let{t:n}=s(`openhands`),[r,i]=P.useState(!1);return(0,F.jsxs)(`div`,{className:`flex flex-col gap-2 my-2 py-2 text-sm w-full`,children:[(0,F.jsxs)(`div`,{className:`font-bold text-danger`,children:[n(e&&m.exists(e)?e:`CHAT_INTERFACE$AGENT_ERROR_MESSAGE`),(0,F.jsx)(`button`,{type:`button`,onClick:()=>i(e=>!e),className:`cursor-pointer text-left`,children:r?(0,F.jsx)(L,{className:`h-4 w-4 ml-2 inline fill-danger`}):(0,F.jsx)(I,{className:`h-4 w-4 ml-2 inline fill-danger`})})]}),r&&(0,F.jsx)(M,{children:t})]})}function bn({event:e}){return Fe(e)?(0,F.jsx)(yn,{errorId:e.id,defaultMessage:e.error}):null}function xn({width:e=20,height:t=20,active:n}){return(0,F.jsx)(`svg`,{width:e,height:t,viewBox:`0 0 ${e} ${t}`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,children:(0,F.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M11.204 15.0037L6.65511 9.99993L11.204 4.99617L12.1289 5.83701L8.34444 9.99993L12.1289 14.1628L11.204 15.0037Z`,fill:n?`var(--oh-text-tertiary)`:`var(--oh-border)`})})}function Sn({width:e=20,height:t=20,active:n}){return(0,F.jsx)(`svg`,{width:e,height:t,viewBox:`0 0 ${e} ${t}`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,children:(0,F.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M8.79602 4.99634L13.3449 10.0001L8.79602 15.0038L7.87109 14.163L11.6556 10.0001L7.87109 5.83718L8.79602 4.99634Z`,fill:n?`var(--oh-text-tertiary)`:`var(--oh-border)`})})}function Cn({onClick:e,className:t}){return(0,F.jsx)(`button`,{type:`button`,onClick:e,className:C(`bg-[var(--oh-muted)] rounded-full w-5 h-5 flex items-center justify-center cursor-pointer`,t),children:(0,F.jsx)(De,{width:18,height:18})})}function wn({src:e,size:t=`small`}){return(0,F.jsx)(`img`,{role:`img`,alt:``,src:e,className:C(`rounded-sm object-cover`,t===`small`&&`w-[62px] h-[62px]`,t===`large`&&`w-[100px] h-[100px]`)})}function Tn({src:e,onRemove:t,size:n=`small`}){return(0,F.jsxs)(`div`,{"data-testid":`image-preview`,className:`relative w-fit shrink-0 py-1`,children:[(0,F.jsx)(wn,{src:e,size:n}),t&&(0,F.jsx)(Cn,{onClick:t,className:`absolute right-[3px] top-[3px] cursor-pointer`})]})}function En({size:e=`small`,images:t,onRemove:n}){let r=P.useRef(null),[i,a]=P.useState(!1),[o,s]=P.useState(!0),[c,l]=P.useState(!1);return P.useEffect(()=>{let e=r.current;e&&a(e.scrollWidth>e.clientWidth)},[t]),(0,F.jsxs)(`div`,{"data-testid":`image-carousel`,className:`relative`,children:[i&&(0,F.jsx)(`div`,{className:`absolute right-full transform top-1/2 -translate-y-1/2`,children:(0,F.jsx)(xn,{active:!o})}),(0,F.jsx)(`div`,{ref:r,onScroll:e=>{let t=e.currentTarget;s(t.scrollLeft===0),l(t.scrollLeft+t.clientWidth===t.scrollWidth)},className:C(`flex overflow-x-auto`,e===`small`&&`gap-2`,e===`large`&&`gap-4`),children:t.map((t,r)=>(0,F.jsx)(Tn,{size:e,src:t,onRemove:n?()=>n?.(r):void 0},r))}),i&&(0,F.jsx)(`div`,{className:`absolute left-full transform top-1/2 -translate-y-1/2`,children:(0,F.jsx)(Sn,{active:!c})})]})}function Dn({type:e,onClick:t}){let{t:n}=s(`openhands`),r=e===`confirm`,i=n(r?x.ACTION$CONFIRM:x.ACTION$REJECT),a=n(r?x.CHAT_INTERFACE$USER_CONFIRMED:x.CHAT_INTERFACE$USER_REJECTED),o=r?`${n(x.CHAT_INTERFACE$INPUT_CONTINUE_MESSAGE)} ⌘↩`:`${n(x.BUTTON$CANCEL)} ⇧⌘⌫`;return(0,F.jsx)(ue,{closeDelay:100,content:a,children:(0,F.jsx)(`button`,{"data-testid":`action-${e}-button`,type:`button`,"aria-label":i,className:C(`rounded px-2 h-6.5 text-sm font-normal leading-5 cursor-pointer hover:opacity-80`,e===`confirm`?`bg-tertiary text-white`:`bg-white text-base`),onClick:t,children:o})})}function On({className:e,content:t,icon:n,severity:r,title:i}){return r===`high`?(0,F.jsxs)(`div`,{className:C(`flex items-center gap-3.5 bg-[#4A0709] border border-[#FF0006] text-red-400 rounded-xl px-3.5 h-13 text-sm text-white`,e),children:[n&&(0,F.jsx)(`span`,{className:``,children:n}),(0,F.jsx)(`span`,{className:`font-bold`,children:i}),(0,F.jsx)(`span`,{className:`font-normal`,children:t})]}):null}var kn=e=>(0,F.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:[(0,F.jsx)(`path`,{d:`M12 14C11.4477 14 11 13.5523 11 13V10C11 9.44772 11.4477 9 12 9C12.5523 9 13 9.44772 13 10V13C13 13.5523 12.5523 14 12 14Z`,fill:`currentColor`}),(0,F.jsx)(`path`,{d:`M10.5 16.5C10.5 15.6716 11.1716 15 12 15C12.8284 15 13.5 15.6716 13.5 16.5C13.5 17.3284 12.8284 18 12 18C11.1716 18 10.5 17.3284 10.5 16.5Z`,fill:`currentColor`}),(0,F.jsx)(`path`,{d:`M10.2301 3.2156C10.98 1.79093 13.02 1.79092 13.7698 3.2156L22.1135 19.0685C22.8144 20.4003 21.8486 22 20.3436 22H3.65635C2.15133 22 1.18556 20.4003 1.88651 19.0685L10.2301 3.2156ZM20.3436 20L12 4.1471L3.65635 20L20.3436 20Z`,fill:`currentColor`})]}),An=de(e=>({submittedEventIds:[],addSubmittedEventId:t=>e(e=>({submittedEventIds:[...e.submittedEventIds,t]})),removeSubmittedEventId:t=>e(e=>({submittedEventIds:e.submittedEventIds.filter(e=>e!==t)}))})),jn=()=>u({mutationKey:[`respond-to-confirmation`],mutationFn:async({conversationId:e,conversationUrl:t,sessionApiKey:n,accept:r})=>{let i={accept:r};return Ke.respondToConfirmation(e,t,i,n)}});function Mn(){let e=An(e=>e.submittedEventIds),t=An(e=>e.addSubmittedEventId),{t:n}=s(`openhands`),{data:r}=Le(),{curAgentState:i}=Ve(),{mutate:a}=jn(),o=Re(e=>e.events).slice().reverse().find(e=>e.source===`agent`?i===S.AWAITING_USER_CONFIRMATION:!1),c=(0,P.useCallback)(e=>{!o||!r||(o.id&&t(o.id),a({conversationId:r.id,conversationUrl:r.conversation_url||``,sessionApiKey:r.session_api_key,accept:e}))},[o,r,t,a]);return(0,P.useEffect)(()=>{if(!o)return;let e=e=>{e.shiftKey&&e.metaKey&&e.key===`Backspace`&&(e.preventDefault(),c(!1))},t=e=>{e.metaKey&&e.key===`Enter`&&(e.preventDefault(),c(!0))},n=n=>{e(n),t(n)};return document.addEventListener(`keydown`,n),()=>document.removeEventListener(`keydown`,n)},[o,c]),i!==S.AWAITING_USER_CONFIRMATION||!o||o.id!==void 0&&e.includes(o.id)?null:(0,F.jsxs)(`div`,{className:`flex flex-col gap-2 pt-4`,children:[(A(o)?o.security_risk:y.UNKNOWN)===y.HIGH&&(0,F.jsx)(On,{content:n(x.CHAT_INTERFACE$HIGH_RISK_WARNING),icon:(0,F.jsx)(kn,{width:16,height:16,color:`#fff`}),severity:`high`,title:n(x.COMMON$HIGH_RISK)}),(0,F.jsxs)(`div`,{className:`flex justify-between items-center`,children:[(0,F.jsx)(`p`,{className:`text-sm font-normal text-white`,children:n(x.CHAT_INTERFACE$USER_ASK_CONFIRMATION)}),(0,F.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,F.jsx)(Dn,{type:`reject`,onClick:()=>c(!1)}),(0,F.jsx)(Dn,{type:`confirm`,onClick:()=>c(!0)})]})]})]})}var Nn=e=>{let t=e.llm_message;if(!t?.content)return``;let n=``;if(t.content&&(Array.isArray(t.content)?n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
3
|
-
`):typeof t.content==`string`&&(n=t.content)),!(Array.isArray(t.content)&&t.content.some(e=>e.type===`image`)))return n;let r=m.t(x.CHAT_INTERFACE$AUGMENTED_PROMPT_FILES_TITLE);return n.split(r)[0]};function Pn(e){return Number.isFinite(e)?Math.min(1,Math.max(0,e)):0}function Fn(e){let t=Math.round(e*5);return{filled:t,empty:5-t}}function In(e){return e>=.6?`text-green-400`:e>=.4?`text-yellow-400`:`text-red-400`}function Ln(e){return e>=.7?`text-red-400 font-semibold`:e>=.5?`text-yellow-400`:`text-neutral-400`}function Rn(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function zn(e){let t=e?.verification;if(!Rn(t))return null;let n=t.enable_iterative_refinement;return typeof n==`boolean`?n:null}function Bn({feature:e}){let t=Math.round(e.probability*100),n=Ln(e.probability);return(0,F.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,F.jsx)(`span`,{className:`text-neutral-200`,children:e.display_name}),(0,F.jsxs)(`span`,{className:n,children:[`(`,t,`%)`]})]})}function U({label:e,features:t}){return!t||t.length===0?null:(0,F.jsxs)(`div`,{className:`flex flex-wrap items-center gap-x-1 text-xs`,children:[(0,F.jsx)(`span`,{className:`font-semibold text-neutral-300`,children:e}),t.map((e,t)=>(0,F.jsxs)(P.Fragment,{children:[t>0&&(0,F.jsx)(`span`,{className:`text-neutral-500`,children:`·`}),(0,F.jsx)(Bn,{feature:e})]},e.name))]})}function Vn({categorized:e}){let{t}=s(),n=e.agent_behavioral_issues&&e.agent_behavioral_issues.length>0,r=e.user_followup_patterns&&e.user_followup_patterns.length>0,i=e.infrastructure_issues&&e.infrastructure_issues.length>0,a=e.other&&e.other.length>0;return!n&&!r&&!i&&!a?null:(0,F.jsxs)(`div`,{className:`flex flex-col gap-1 mt-1.5`,children:[n&&(0,F.jsx)(U,{label:t(x.CRITIC$POTENTIAL_ISSUES),features:e.agent_behavioral_issues}),i&&(0,F.jsx)(U,{label:t(x.CRITIC$INFRASTRUCTURE),features:e.infrastructure_issues}),r&&(0,F.jsx)(U,{label:t(x.CRITIC$LIKELY_FOLLOWUP),features:e.user_followup_patterns}),a&&(0,F.jsx)(U,{label:t(x.CRITIC$OTHER),features:e.other})]})}function Hn({criticResult:e}){let{t}=s(),{data:n}=D(),[r,i]=P.useState(!1),a=Pn(e.score),{filled:o,empty:c}=Fn(a),l=In(a),u=(a*100).toFixed(1),d=zn(n?.agent_settings)===!1,f=e.metadata?.categorized_features,p=f!=null&&((f.agent_behavioral_issues??[]).length>0||(f.user_followup_patterns??[]).length>0||(f.infrastructure_issues??[]).length>0||(f.other??[]).length>0);return(0,F.jsxs)(`div`,{className:`border-l-2 border-neutral-600 pl-2 my-2 py-1.5 text-sm`,children:[(0,F.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,F.jsx)(`span`,{className:`font-semibold text-neutral-300 text-xs`,children:t(x.CRITIC$SUCCESS_LIKELIHOOD_LABEL)}),(0,F.jsxs)(`span`,{className:`${l} text-xs tracking-wide`,"aria-label":`Score: ${u}%`,children:[`★`.repeat(o),`☆`.repeat(c)]}),(0,F.jsxs)(`span`,{className:`text-neutral-500 text-xs`,children:[`(`,u,`%)`]}),p&&(0,F.jsx)(`button`,{type:`button`,onClick:()=>i(e=>!e),className:`cursor-pointer ml-1`,"aria-label":t(r?x.BUTTON$COLLAPSE_DETAILS:x.BUTTON$EXPAND_DETAILS),children:r?(0,F.jsx)(L,{className:`h-3 w-3 inline fill-neutral-400`}):(0,F.jsx)(I,{className:`h-3 w-3 inline fill-neutral-400`})})]}),r&&p&&(0,F.jsx)(Vn,{categorized:f}),d&&(0,F.jsx)(`p`,{className:`mt-1.5 text-xs leading-5 text-neutral-500`,"data-testid":`critic-iterative-refinement-hint`,children:t(x.CRITIC$ITERATIVE_REFINEMENT_HINT)})]})}var Un=e=>(0,F.jsx)(`svg`,{width:16,height:16,viewBox:`0 0 16 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,F.jsx)(`path`,{d:`M11.3931 1.88021C10.78 1.37593 10.062 1.01489 9.29157 0.823438C8.52113 0.631981 7.71767 0.614934 6.9398 0.773542C5.90405 0.982756 4.95379 1.49492 4.20959 2.24506C3.46538 2.9952 2.96078 3.9495 2.7598 4.98688C2.61303 5.76469 2.6397 6.56531 2.83791 7.33163C3.03611 8.09795 3.40097 8.8111 3.90647 9.42021C4.37559 9.94959 4.64449 10.6266 4.66647 11.3335V13.3335C4.66647 13.864 4.87718 14.3727 5.25225 14.7478C5.62732 15.1228 6.13603 15.3335 6.66647 15.3335H9.33313C9.86356 15.3335 10.3723 15.1228 10.7473 14.7478C11.1224 14.3727 11.3331 13.864 11.3331 13.3335V11.4602C11.3555 10.6797 11.6423 9.92983 12.1465 9.33354C13.0299 8.24073 13.4463 6.84342 13.3052 5.44529C13.1642 4.04716 12.477 2.7612 11.3931 1.86687V1.88021ZM9.9998 13.3335C9.9998 13.5104 9.92956 13.6799 9.80454 13.8049C9.67951 13.93 9.50994 14.0002 9.33313 14.0002H6.66647C6.48965 14.0002 6.32009 13.93 6.19506 13.8049C6.07004 13.6799 5.9998 13.5104 5.9998 13.3335V12.6669H9.9998V13.3335ZM11.1131 8.50688C10.4428 9.30194 10.0517 10.2949 9.9998 11.3335H8.66647V9.33354C8.66647 9.15673 8.59623 8.98716 8.4712 8.86214C8.34618 8.73711 8.17661 8.66688 7.9998 8.66688C7.82299 8.66688 7.65342 8.73711 7.52839 8.86214C7.40337 8.98716 7.33313 9.15673 7.33313 9.33354V11.3335H5.9998C5.98221 10.3123 5.60443 9.33005 4.93313 8.56021C4.49023 8.02954 4.19239 7.39316 4.06867 6.71311C3.94495 6.03306 3.99957 5.33255 4.22719 4.6799C4.45481 4.02724 4.84768 3.4447 5.36748 2.98909C5.88728 2.53348 6.51627 2.22034 7.19313 2.08021C7.77483 1.96044 8.37591 1.9717 8.95271 2.11319C9.52952 2.25467 10.0676 2.52282 10.5278 2.89818C10.9881 3.27353 11.359 3.74666 11.6136 4.28322C11.8682 4.81978 12.0001 5.4063 11.9998 6.00021C12.0047 6.91345 11.6912 7.79985 11.1131 8.50688Z`,fill:`currentColor`})});function W({content:e}){let{t}=s(`openhands`),[n,r]=P.useState(!1);if(!e.trim())return null;let i=n?L:I;return(0,F.jsxs)(`div`,{className:`my-1 w-full py-1 text-sm`,"data-testid":`collapsible-thinking`,children:[(0,F.jsxs)(`button`,{type:`button`,onClick:()=>r(e=>!e),"aria-expanded":n,"aria-label":t(n?x.THINKING$COLLAPSE:x.THINKING$EXPAND),"data-testid":`collapsible-thinking-toggle`,className:`w-full flex items-center gap-2 text-left cursor-pointer`,children:[(0,F.jsx)(i,{className:`h-4 w-4 fill-[var(--oh-muted)] flex-shrink-0`}),(0,F.jsx)(Un,{className:`h-4 w-4 fill-[var(--oh-muted)] flex-shrink-0`}),(0,F.jsx)(`span`,{className:`font-normal text-[var(--oh-muted)]`,children:t(x.THINKING$TITLE)})]}),n&&(0,F.jsx)(`div`,{className:`mt-1.5 pl-6`,"data-testid":`collapsible-thinking-content`,children:(0,F.jsx)(M,{children:e})})]})}var Wn=()=>{let e=o();return u({mutationKey:[`fork-conversation`],mutationFn:async({sourceConversationId:e,eventId:t,editText:n,title:r})=>{let i=t,a=!1;if(n!=null){let n=await he.getEventParentId(e,t);n&&(i=n,a=!0)}let o=await he.forkConversation(e,i,r);return a&&o.leaf_event_id!==i&&(a=!1),{info:o,excluded:a}},onSuccess:()=>{e.invalidateQueries({queryKey:[`user`,`conversations`]})}})};function Gn({event:e,isLastMessage:t,isFromPlanningAgent:n}){let{t:r}=s(`openhands`),{navigate:i}=se(),{conversationId:a}=j(),o=_().backend.kind===`cloud`,{mutate:c,isPending:l}=Wn(),u=fe(e=>e.setMessageToSend),d=P.useRef(!1),f=Nn(e),{reasoning:m,message:h}=e.source===`agent`?Ae(f):{reasoning:``,message:f},g=[];Array.isArray(e.llm_message.content)&&e.llm_message.content.forEach(e=>{e.type===`image`&&g.push(...e.image_urls)});let v=!o&&a?[{icon:(0,F.jsx)(be,{width:15,height:15,"aria-hidden":!0}),onClick:()=>{if(!a||l||d.current)return;d.current=!0;let t=Ce.getCurrentConversation(),n=t?.id===a?t.title:void 0,r=n?`${n} (branch)`:void 0,o=e.source===`user`&&h.length>0;c({sourceConversationId:a,eventId:e.id,...o?{editText:h}:{},...r?{title:r}:{}},{onSuccess:({info:e,excluded:t})=>{i(`/conversations/${e.id}`),t&&window.setTimeout(()=>u(h),0)},onError:e=>p(e instanceof Error?e.message:null),onSettled:()=>{d.current=!1}})},tooltip:r(x.CHAT_INTERFACE$BRANCH_FROM_HERE)}]:void 0;return(0,F.jsxs)(F.Fragment,{children:[m&&(0,F.jsx)(W,{content:m}),(0,F.jsxs)(H,{type:e.source,message:h,isFromPlanningAgent:n,actions:v,children:[g.length>0&&(0,F.jsx)(En,{size:`small`,images:g}),t&&(0,F.jsx)(Mn,{})]}),e.source===`agent`&&e.critic_result!=null&&(0,F.jsx)(Hn,{criticResult:e.critic_result})]})}var Kn=e=>{switch(e){case y.LOW:return m.t(x.SECURITY$LOW_RISK);case y.MEDIUM:return m.t(x.SECURITY$MEDIUM_RISK);case y.HIGH:return m.t(x.SECURITY$HIGH_RISK);case y.UNKNOWN:default:return m.t(x.SECURITY$UNKNOWN_RISK)}},G=()=>``,qn=e=>e.name?`**Skill:** \`${e.name}\``:G(),Jn=e=>{let{action:t}=e,n=[];return t.pattern&&n.push(`**Pattern:** \`${t.pattern}\``),t.path&&n.push(`**Path:** \`${t.path}\``),`include`in t&&t.include&&n.push(`**Include:** \`${t.include}\``),n.length>0?n.join(`
|
|
4
|
-
`):G()},Yn=e=>{if(e.command!==`create`||!e.file_text)return G();let t=e.file_text;return t.length>1e3&&(t=`${t.slice(0,z)}...`),`${e.path}\n${t}`},Xn=e=>{let t=`Command:\n\`${e.action.command}\``;return(e.security_risk===y.HIGH||e.security_risk===y.MEDIUM)&&(t+=`\n\n${Kn(e.security_risk)}`),t},Zn=e=>{let t=`**MCP Tool Call**
|
|
5
|
-
|
|
6
|
-
`;return t+=`**Arguments:**\n\`\`\`json\n${JSON.stringify(e.data,null,2)}\n\`\`\``,t},Qn=e=>e.thought,$n=e=>e.message.trim(),er=e=>{let t=`**Command:** \`${e.command}\``;return e.command===`plan`&&(e.task_list&&e.task_list.length>0?(t+=`\n\n**Task List (${e.task_list.length} ${e.task_list.length===1?`item`:`items`}):**\n`,e.task_list.forEach((e,n)=>{let r={todo:`⏳`,in_progress:`🔄`,done:`✅`}[e.status]||`❓`;t+=`\n${n+1}. ${r} **[${e.status.toUpperCase().replace(`_`,` `)}]** ${e.title}`,e.notes&&(t+=`\n *Notes: ${e.notes}*`)})):t+=`
|
|
7
|
-
|
|
8
|
-
**Task List:** Empty`),t},tr=e=>{switch(e.kind){case`BrowserNavigateAction`:{let t=`Browsing ${e.url}`;return e.new_tab&&(t+=`
|
|
9
|
-
**New Tab:** Yes`),t}case`BrowserClickAction`:{let t=`**Element Index:** ${e.index}`;return e.new_tab&&(t+=`
|
|
10
|
-
**New Tab:** Yes`),t}case`BrowserTypeAction`:{let t=e.text.length>50?`${e.text.slice(0,50)}...`:e.text;return`**Element Index:** ${e.index}\n**Text:** ${t}`}case`BrowserGetStateAction`:return e.include_screenshot?`**Include Screenshot:** Yes`:G();case`BrowserGetContentAction`:{let t=[];return e.extract_links&&t.push(`**Extract Links:** Yes`),e.start_from_char>0&&t.push(`**Start From Character:** ${e.start_from_char}`),t.length>0?t.join(`
|
|
11
|
-
`):G()}case`BrowserScrollAction`:return`**Direction:** ${e.direction}`;case`BrowserGoBackAction`:return G();case`BrowserListTabsAction`:return G();case`BrowserSwitchTabAction`:return`**Tab ID:** ${e.tab_id}`;case`BrowserCloseTabAction`:return`**Tab ID:** ${e.tab_id}`;default:return G()}},nr=e=>{let{action:t}=e;switch(t.kind){case`FileEditorAction`:case`StrReplaceEditorAction`:return Yn(t);case`ExecuteBashAction`:case`TerminalAction`:return Xn(e);case`MCPToolAction`:return Zn(t);case`ThinkAction`:return Qn(t);case`FinishAction`:return $n(t);case`TaskTrackerAction`:return er(t);case`BrowserNavigateAction`:case`BrowserClickAction`:case`BrowserTypeAction`:case`BrowserGetStateAction`:case`BrowserGetContentAction`:case`BrowserScrollAction`:case`BrowserGoBackAction`:case`BrowserListTabsAction`:case`BrowserSwitchTabAction`:case`BrowserCloseTabAction`:return tr(t);case`GrepAction`:case`GlobAction`:return Jn(e);case`InvokeSkillAction`:return qn(t);default:return zt(e)}},rr=e=>{if(e.is_error||e.status===`failed`)return`error`;if(e.status===`completed`)return`success`},ir=e=>{let{observation:t}=e;switch(t.kind){case`ExecuteBashObservation`:{let e=t.exit_code,{metadata:n}=t;return e===-1||n.exit_code===-1?`timeout`:e===0||n.exit_code===0?`success`:`error`}case`TerminalObservation`:{let e=t.exit_code??t.metadata.exit_code??null;return t.timeout||e===-1?`timeout`:e===0?`success`:t.is_error?`error`:`success`}case`FileEditorObservation`:case`StrReplaceEditorObservation`:return t.error?`error`:`success`;case`MCPToolObservation`:return t.is_error?`error`:`success`;case`SwitchLLMObservation`:return t.is_error?`error`:`success`;case`InvokeSkillObservation`:return t.is_error?`error`:`success`;case`TaskObservation`:return t.is_error||t.status===`failed`?`error`:`success`;case`CanvasUIObservation`:return t.is_error?`error`:`success`;default:return`success`}},ar=e=>{let{observation:t}=e;if(t.error)return`**Error:**\n${t.error}`;let n=`content`in t&&Array.isArray(t.content)?t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
12
|
-
`):null;return ir(e)===`success`&&`old_content`in t&&`new_content`in t&&t.old_content&&t.new_content||t.command===`view`?`\`\`\`\n${n||t.output}\n\`\`\``:n||t.output},or=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
13
|
-
`)||``;n.length>1e3&&(n=`${n.slice(0,z)}...`);let r=``;return t.command&&(r+=`Command: \`${t.command}\`\n\n`),r+=`Output:\n\`\`\`sh\n${n.trim()||m.t(x.OBSERVATION$COMMAND_NO_OUTPUT)}\n\`\`\``,r},sr=e=>{let{observation:t}=e,n=`content`in t&&Array.isArray(t.content)?t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
14
|
-
`):t.output||``,r=``;return t.error?r+=`**Error:**\n${t.error}`:n?r+=`**Output:**\n${n}`:r+=`Browser action completed successfully.`,r.length>1e3&&(r=`${r.slice(0,z)}...(truncated)`),r},cr=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
15
|
-
`),r=`**Tool:** ${t.tool_name}\n\n`;return t.is_error?r+=`**Error:**\n${n}`:r+=`**Result:**\n${n}`,r.length>1e3&&(r=`${r.slice(0,z)}...`),r},lr=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
16
|
-
`),r=`${t.skill_name?`**Skill:** \`${t.skill_name}\`\n\n`:``}${t.is_error?`**Error:**\n${n}`:n}`;return r.length>1e3&&(r=`${r.slice(0,z)}...(truncated)`),r},ur=e=>e.observation.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
17
|
-
`),dr=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
18
|
-
`);if(t.is_error)return n?`**Error:**\n${n}`:`**Error:**\nFailed to switch LLM profile \`${t.profile_name}\`.`;let r=[`**Profile:** \`${t.profile_name}\``];return t.active_model&&r.push(`**Active model:** \`${t.active_model}\``),t.reason&&r.push(`**Reason:** ${t.reason}`),r.join(`
|
|
19
|
-
`)},fr=e=>{let{observation:t}=e,{command:n,task_list:r}=t,i=`**Command:** \`${n}\``;return n===`plan`&&r.length>0?(i+=`\n\n**Task List (${r.length} ${r.length===1?`item`:`items`}):**\n`,r.forEach((e,t)=>{let n={todo:`⏳`,in_progress:`🔄`,done:`✅`}[e.status]||`❓`;i+=`\n${t+1}. ${n} **[${e.status.toUpperCase().replace(`_`,` `)}]** ${e.title}`,e.notes&&(i+=`\n *Notes: ${e.notes}*`)})):n===`plan`&&(i+=`
|
|
20
|
-
|
|
21
|
-
**Task List:** Empty`),`content`in t&&t.content&&typeof t.content==`string`&&t.content.trim()&&(i+=`\n\n**Result:** ${t.content.trim()}`),i},pr=e=>{let{observation:t}=e;return t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
22
|
-
`)||``},mr=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
23
|
-
`),r=``;return t.is_error?r+=`**Error:**\n${n}`:r+=n,r},hr=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
24
|
-
`),r=`**Pattern:** \`${t.pattern}\`\n`;return r+=`**Search Path:** \`${t.search_path}\`\n\n`,t.is_error?r+=`**Error:**\n${n}`:t.files.length===0?r+=`**Result:** No files found.`:(r+=`**Files Found (${t.files.length}${t.truncated?`+, truncated`:``}):**\n`,r+=t.files.map(e=>`- \`${e}\``).join(`
|
|
25
|
-
`)),r.length>1e3&&(r=`${r.slice(0,z)}...(truncated)`),r},gr=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
26
|
-
`),r=`**Pattern:** \`${t.pattern}\`\n`;return r+=`**Search Path:** \`${t.search_path}\`\n`,t.include_pattern&&(r+=`**Include:** \`${t.include_pattern}\`\n`),r+=`
|
|
27
|
-
`,t.is_error?r+=`**Error:**\n${n}`:t.matches.length===0?r+=`**Result:** No matches found.`:(r+=`**Matches (${t.matches.length}${t.truncated?`+, truncated`:``}):**\n`,r+=t.matches.map(e=>`- \`${e}\``).join(`
|
|
28
|
-
`)),r.length>1e3&&(r=`${r.slice(0,z)}...(truncated)`),r},_r=e=>{switch(e.observation.kind){case`FileEditorObservation`:case`StrReplaceEditorObservation`:return ar(e);case`ExecuteBashObservation`:case`TerminalObservation`:return or(e);case`BrowserObservation`:return sr(e);case`MCPToolObservation`:return cr(e);case`TaskTrackerObservation`:return fr(e);case`ThinkObservation`:return pr(e);case`FinishObservation`:return mr(e);case`GlobObservation`:return hr(e);case`GrepObservation`:return gr(e);case`InvokeSkillObservation`:return lr(e);case`CanvasUIObservation`:return ur(e);case`ClientToolObservation`:return e.tool_name===`canvas_ui_control`?ur(e):zt(e);case`SwitchLLMObservation`:return dr(e);default:return zt(e)}},vr=e=>(0,F.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:(0,F.jsx)(`path`,{d:`M12 2C10.0222 2 8.08879 2.58649 6.4443 3.6853C4.79981 4.78412 3.51809 6.3459 2.76121 8.17317C2.00433 10.0004 1.8063 12.0111 2.19215 13.9509C2.578 15.8907 3.53041 17.6725 4.92894 19.0711C6.32746 20.4696 8.10929 21.422 10.0491 21.8079C11.9889 22.1937 13.9996 21.9957 15.8268 21.2388C17.6541 20.4819 19.2159 19.2002 20.3147 17.5557C21.4135 15.9112 22 13.9778 22 12C22 10.6868 21.7413 9.38642 21.2388 8.17317C20.7363 6.95991 19.9997 5.85752 19.0711 4.92893C18.1425 4.00035 17.0401 3.26375 15.8268 2.7612C14.6136 2.25866 13.3132 2 12 2ZM12 20C10.4178 20 8.87104 19.5308 7.55544 18.6518C6.23985 17.7727 5.21447 16.5233 4.60897 15.0615C4.00347 13.5997 3.84504 11.9911 4.15372 10.4393C4.4624 8.88743 5.22433 7.46197 6.34315 6.34315C7.46197 5.22433 8.88743 4.4624 10.4393 4.15372C11.9911 3.84504 13.5997 4.00346 15.0615 4.60896C16.5233 5.21447 17.7727 6.23984 18.6518 7.55544C19.5308 8.87103 20 10.4177 20 12C20 14.1217 19.1572 16.1566 17.6569 17.6569C16.1566 19.1571 14.1217 20 12 20Z`,fill:`currentColor`})}),yr=e=>(0,F.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:16,height:16,viewBox:`0 0 16 16`,fill:`none`,...e,children:[(0,F.jsx)(`path`,{d:`M5.79029 12.9507C5.69629 12.9042 5.59557 12.8843 5.50157 12.8843C5.25314 12.8843 5.01142 13.0238 4.89728 13.2562C4.72942 13.5883 4.87042 13.9868 5.20614 14.1462C5.30014 14.1927 5.40086 14.2127 5.50157 14.2127C5.75 14.2127 5.985 14.0732 6.10586 13.8407C6.15286 13.7477 6.17301 13.6481 6.17301 13.5551C6.17301 13.3027 6.03201 13.0636 5.79029 12.9507ZM13.3641 12.3463C13.3641 12.3463 13.3909 12.333 13.3977 12.3198C13.4178 12.2998 13.4312 12.2733 13.4447 12.2533C13.4245 12.2865 13.3977 12.3198 13.3641 12.3463ZM3.91698 11.463C3.7827 11.2969 3.58798 11.2106 3.39326 11.2106C3.24555 11.2106 3.09783 11.2637 2.97697 11.3567C2.68154 11.5892 2.63454 12.0076 2.86283 12.2932C2.99712 12.4592 3.19183 12.5456 3.39326 12.5456C3.54098 12.5456 3.68869 12.4924 3.80955 12.3995C3.97741 12.2666 4.0647 12.074 4.0647 11.8814C4.0647 11.7353 4.0177 11.5892 3.91698 11.463ZM2.88297 9.32433C2.80911 9.01881 2.53382 8.80627 2.23168 8.80627C2.18468 8.80627 2.13096 8.81291 2.07725 8.8262C1.71467 8.9059 1.48638 9.26455 1.56696 9.61657C1.64081 9.92873 1.9161 10.1346 2.22496 10.1346C2.27196 10.1346 2.32568 10.1346 2.37268 10.1213C2.68825 10.0549 2.8964 9.77597 2.8964 9.47045C2.8964 9.42395 2.8964 9.37082 2.88297 9.32433ZM2.37939 6.15621C2.33239 6.14293 2.27868 6.14293 2.23168 6.14293C1.92282 6.14293 1.64753 6.34218 1.57367 6.65434C1.4931 7.013 1.71467 7.36501 2.07725 7.45135C2.13096 7.46464 2.17796 7.47128 2.22496 7.47128C2.53382 7.47128 2.80911 7.25874 2.88297 6.95322C2.8964 6.90673 2.8964 6.8536 2.8964 6.8071C2.8964 6.50158 2.69497 6.22263 2.37939 6.15621ZM3.82298 3.87809C3.70212 3.78511 3.55441 3.73197 3.40669 3.73197C3.20526 3.73197 3.01054 3.81831 2.87626 3.98436C2.64797 4.26995 2.69497 4.68838 2.98369 4.92085C3.10454 5.01383 3.25226 5.06696 3.39998 5.06696C3.59469 5.06696 3.79612 4.98062 3.9237 4.81458C4.02441 4.69503 4.07141 4.54227 4.07141 4.39615C4.07141 4.20354 3.99084 4.01093 3.82298 3.87809ZM6.11929 2.45011C6.00515 2.21101 5.76343 2.07153 5.50829 2.07153C5.41428 2.07153 5.31357 2.09146 5.21957 2.13795C4.88385 2.29735 4.74956 2.69586 4.90399 3.0213C5.02485 3.26041 5.25985 3.39988 5.50829 3.39988C5.609 3.39988 5.70972 3.37996 5.80372 3.33347C6.04543 3.22056 6.17972 2.98145 6.17972 2.73571C6.17972 2.63608 6.15958 2.5431 6.11929 2.45011Z`,fill:`currentColor`}),(0,F.jsx)(`path`,{d:`M14.8809 8.14215C14.8809 8.65356 14.8205 9.15834 14.7063 9.64983C14.5251 10.4269 14.2028 11.1708 13.7462 11.8482C13.6589 11.9811 13.5649 12.1073 13.4642 12.2268C13.4642 12.2401 13.4575 12.2468 13.444 12.2534C13.4239 12.2866 13.397 12.3198 13.3635 12.3464C12.7457 13.1102 11.9602 13.7212 11.0604 14.1529C11.047 14.1596 11.0269 14.1662 11.0134 14.1729C10.9194 14.2194 10.8187 14.2658 10.718 14.3057C9.90558 14.6378 9.01928 14.8105 8.1397 14.8105H8.11955C7.74355 14.8038 7.45483 14.5116 7.45483 14.1463C7.45483 13.781 7.75698 13.4821 8.12627 13.4821H8.14641C8.85142 13.4821 9.55643 13.3426 10.2077 13.077C11.047 12.7316 11.7789 12.187 12.3496 11.4896C12.4436 11.37 12.5443 11.2438 12.6316 11.111C12.9942 10.5664 13.256 9.97527 13.397 9.35095C13.397 9.33766 13.397 9.32438 13.397 9.31774C13.4843 8.93252 13.5313 8.54065 13.5313 8.14215C13.5313 7.43812 13.3903 6.75402 13.1218 6.10313C12.927 5.64485 12.6786 5.21978 12.3697 4.83455C12.2422 4.67515 12.1012 4.51575 11.9535 4.36963C11.4499 3.8715 10.859 3.47964 10.201 3.21397C9.55643 2.9483 8.86485 2.81546 8.16655 2.80882H8.13298C7.76369 2.80882 7.46155 2.50994 7.46155 2.14464C7.46155 1.77935 7.76369 1.48047 8.13298 1.48047H8.17327C9.05285 1.48711 9.90557 1.65315 10.7113 1.98524C10.8322 2.03838 10.953 2.08487 11.0672 2.14464C11.0806 2.15129 11.094 2.15793 11.1007 2.15793C11.7722 2.48337 12.3697 2.90845 12.9002 3.43314C13.0815 3.61247 13.256 3.80508 13.4172 4.00434C13.4239 4.01098 13.4239 4.01762 13.4306 4.02426C13.8133 4.49583 14.1222 5.02717 14.3639 5.59171C14.4982 5.91052 14.6056 6.24261 14.6795 6.57469C14.6929 6.62119 14.7063 6.66768 14.7131 6.71417C14.8205 7.17909 14.8742 7.6573 14.8742 8.14215H14.8809Z`,fill:`currentColor`})]});function br({task:e}){let{t}=s(`openhands`),n=(0,P.useMemo)(()=>{switch(e.status){case`todo`:return(0,F.jsx)(vr,{className:`w-4 h-4 text-[#ffffff]`});case`in_progress`:return(0,F.jsx)(yr,{className:`w-4 h-4 text-[#ffffff]`});case`done`:return(0,F.jsx)(ke,{className:`w-4 h-4 text-[var(--oh-muted)]`});default:return(0,F.jsx)(vr,{className:`w-4 h-4 text-[#ffffff]`})}},[e.status]),r=e.status===`done`;return(0,F.jsxs)(`div`,{className:`flex gap-[14px] items-center px-4 py-2 w-full`,"data-name":`item`,children:[(0,F.jsx)(`div`,{className:`shrink-0`,children:n}),(0,F.jsxs)(`div`,{className:`flex flex-col items-start justify-center leading-[20px] text-nowrap whitespace-pre font-normal`,children:[(0,F.jsx)(O.Text,{className:C(`text-[12px] text-white`,r&&`text-[var(--oh-muted)]`),children:e.title}),e.notes&&(0,F.jsxs)(O.Text,{className:`text-[10px] text-[var(--oh-muted)]`,children:[t(x.TASK_TRACKING_OBSERVATION$TASK_NOTES),`: `,e.notes]})]})]})}function xr({taskList:e}){let{t}=s(`openhands`);return(0,F.jsxs)(`div`,{className:`flex flex-col overflow-clip bg-[var(--oh-surface)] border border-[var(--oh-border)] rounded-[12px] w-full`,children:[(0,F.jsxs)(`div`,{className:`flex gap-1 items-center border-b border-[var(--oh-border)] h-[41px] px-2 shrink-0`,children:[(0,F.jsx)(Ze,{className:`shrink-0 w-4.5 h-4.5 text-[var(--oh-muted)]`}),(0,F.jsx)(O.Text,{className:`text-[11px] text-nowrap text-white tracking-[0.11px] font-medium leading-[16px] whitespace-pre`,children:t(x.COMMON$TASKS)})]}),(0,F.jsx)(`div`,{children:e.map((e,t)=>(0,F.jsx)(br,{task:e},`task-${t}`))})]})}function Sr({event:e}){let{observation:t}=e,{command:n,task_list:r}=t;return(0,F.jsx)(`div`,{className:`flex flex-col gap-4`,children:n===`plan`&&r.length>0&&(0,F.jsx)(xr,{taskList:r})})}var Cr=e=>e.filter(e=>e.type===`text`).map(e=>e.text).join(``),wr=e=>{let t=[],n=/<EXTRA_INFO>([\s\S]*?)<\/EXTRA_INFO>/gi,r=n.exec(e);for(;r!==null;){let i=r[1].trim();i.length>0&&t.push(i),r=n.exec(e)}return t},Tr=(e,t)=>{let n=`\n\n- **${e}**`;return t&&t.trim().length>0&&(n+=`\n\n${t}`),n},Er=(e,t)=>{let n=`
|
|
29
|
-
|
|
30
|
-
**Triggered Skill Knowledge:**`;return e.forEach((e,r)=>{let i=r<t.length?t[r]:void 0;n+=Tr(e,i)}),n},Dr=e=>{let t=`
|
|
31
|
-
|
|
32
|
-
**Extended Content:**`;return e.forEach(e=>{e.trim().length>0&&(t+=`\n\n${e}`)}),t},Or=e=>!e||e.length===0?[]:wr(Cr(e)),kr=(e,t)=>{let n=Or(t);return e&&e.length>0?Er(e,n):n.length>0?Dr(n):``},Ar=(e,t)=>{let n=Or(t);return e&&e.length>0?e.map((e,t)=>({name:e,content:t<n.length?n[t].trim():``})):n.length>0?n.filter(e=>e.trim().length>0).map((e,t)=>({name:`Extended Content ${t+1}`,content:e.trim()})):[]},K=e=>typeof e==`object`&&!!e&&`_isSkillReadyEvent`in e&&e._isSkillReadyEvent===!0,jr=e=>{let t=e.activated_skills||[],n=e.extended_content||[];if(t.length===0&&n.length===0)throw Error(`Cannot create skill ready event without activated skills or extended content`);let r=kr(t,n),i=Ar(t,n);return{id:`${e.id}-skill-ready`,timestamp:e.timestamp,source:`agent`,_isSkillReadyEvent:!0,_skillReadyContent:r,_skillReadyItems:i}},q=e=>e,J=e=>e.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
33
|
-
`);function Mr({code:e,language:t,copy:n=!0,placeholder:r,expandable:i=!1,wrapLongLines:a=!1}){let{t:o}=s(`openhands`),[c,l]=P.useState(!1),u=e.length>z,d=(u&&!(i&&c)?`${e.slice(0,1e3)}…`:e).trim()||r||``,f=n&&e.trim().length>0,p=o(c?x.BUTTON$COLLAPSE:x.BUTTON$EXPAND),m=(0,F.jsx)(ce,{className:`rounded-lg text-xs`,style:le,language:t,PreTag:`div`,wrapLongLines:a,customStyle:a?{whiteSpace:`pre-wrap`}:void 0,codeTagProps:a?{style:{whiteSpace:`pre-wrap`}}:void 0,children:d});return(0,F.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[f?(0,F.jsx)(qe,{text:e,children:m}):m,i&&u&&(0,F.jsx)(`button`,{type:`button`,onClick:()=>l(e=>!e),className:`self-start text-xs text-muted transition-colors hover:text-white hover:underline`,children:p})]})}function Nr({output:e,exitCode:t,copy:n=!0}){let{t:r}=s(`openhands`);return(0,F.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[t!=null&&t!==0&&t!==-1&&(0,F.jsx)(`span`,{className:`self-start rounded bg-status-fail-bg px-1.5 py-0.5 font-mono text-xs text-status-fail-text`,children:r(x.OBSERVATION$EXIT_CODE,{code:t})}),(0,F.jsx)(Mr,{code:e,language:`bash`,copy:n,placeholder:r(x.OBSERVATION$COMMAND_NO_OUTPUT),expandable:!0,wrapLongLines:!0})]})}var Pr=q({actionKinds:[`ExecuteBashAction`,`TerminalAction`],observationKinds:[`ExecuteBashObservation`,`TerminalObservation`],Body:function({action:e,observation:t}){let{t:n}=s(`openhands`),r=t?.observation.command??e?.action.command??``,i=e?.security_risk;return(0,F.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[r&&(0,F.jsx)(Mr,{code:r,language:`bash`}),(i===y.HIGH||i===y.MEDIUM)&&(0,F.jsx)(`span`,{className:`text-xs text-status-fail-text`,children:n(i===y.HIGH?x.SECURITY$HIGH_RISK:x.SECURITY$MEDIUM_RISK)}),t&&(0,F.jsx)(Nr,{output:J(t.observation.content),exitCode:t.observation.exit_code})]})}}),Fr=e=>{switch(e.split(`.`).pop()?.toLowerCase()){case`js`:case`jsx`:return`javascript`;case`ts`:case`tsx`:return`typescript`;case`py`:return`python`;case`html`:return`html`;case`css`:return`css`;case`json`:return`json`;case`md`:return`markdown`;case`yml`:case`yaml`:return`yaml`;case`sh`:case`bash`:return`bash`;case`dockerfile`:return`dockerfile`;case`rs`:return`rust`;case`go`:return`go`;case`java`:return`java`;case`cpp`:case`cc`:case`cxx`:return`cpp`;case`c`:return`c`;case`rb`:return`ruby`;case`php`:return`php`;case`sql`:return`sql`;default:return`text`}},Ir=3,Lr=300,Rr=25e4,zr=(e,t)=>{if(e.length*t.length>Rr)return[...e.map(e=>({type:`del`,text:e})),...t.map(e=>({type:`add`,text:e}))];let n=e.length,r=t.length,i=Array.from({length:n+1},()=>Array(r+1).fill(0));for(let a=n-1;a>=0;--a)for(let n=r-1;n>=0;--n)i[a][n]=e[a]===t[n]?i[a+1][n+1]+1:Math.max(i[a+1][n],i[a][n+1]);let a=[],o=0,s=0;for(;o<n&&s<r;)e[o]===t[s]?(a.push({type:`ctx`,text:e[o]}),o+=1,s+=1):i[o+1][s]>=i[o][s+1]?(a.push({type:`del`,text:e[o]}),o+=1):(a.push({type:`add`,text:t[s]}),s+=1);for(;o<n;)a.push({type:`del`,text:e[o]}),o+=1;for(;s<r;)a.push({type:`add`,text:t[s]}),s+=1;return a},Br=(e,t)=>{let n=e.split(`
|
|
34
|
-
`),r=t.split(`
|
|
35
|
-
`),i=0;for(;i<n.length&&i<r.length&&n[i]===r[i];)i+=1;let a=n.length,o=r.length;for(;a>i&&o>i&&n[a-1]===r[o-1];)--a,--o;let s=n.slice(Math.max(0,i-Ir),i),c=n.slice(a,Math.min(n.length,a+Ir));return[...s.map(e=>({type:`ctx`,text:e})),...zr(n.slice(i,a),r.slice(i,o)),...c.map(e=>({type:`ctx`,text:e}))]},Vr={add:`bg-status-success-bg text-status-success-text`,del:`bg-status-fail-bg text-status-fail-text`,ctx:`text-muted`},Hr={add:`+ `,del:`- `,ctx:` `};function Ur({oldText:e,newText:t}){let{t:n}=s(`openhands`),r=Br(e,t),i=r.length>Lr;return(0,F.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,F.jsx)(`div`,{className:`overflow-auto rounded-lg border border-surface-raised font-mono text-xs`,children:(i?r.slice(0,Lr):r).map((e,t)=>(0,F.jsx)(`div`,{className:C(`whitespace-pre-wrap px-2`,Vr[e.type]),children:`${Hr[e.type]}${e.text}`},`${t}-${e.type}`))}),i&&(0,F.jsx)(`span`,{className:`text-xs text-muted`,children:n(x.COMMON$TRUNCATED)})]})}function Wr({path:e,range:t,onClick:n}){let{conversationId:r}=j();return(0,F.jsx)(`button`,{type:`button`,"data-testid":`file-path-chip`,title:e,className:`inline-flex max-w-full cursor-pointer items-center gap-1.5 self-start rounded bg-surface-raised px-2 py-0.5 text-left font-mono text-xs text-foreground hover:bg-[var(--oh-interactive-hover)]`,onClick:t=>{if(t.stopPropagation(),n){n();return}N(e,r)},children:(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(tt,{className:`h-3.5 w-3.5 flex-shrink-0 text-muted`}),(0,F.jsx)(`span`,{className:`break-all`,children:t?`${e}:${t}`:e})]})})}var Gr=new Set([`md`,`markdown`,`mdx`]);function Kr(e){let t=e.lastIndexOf(`.`);return t===-1?!1:Gr.has(e.slice(t+1).toLowerCase())}var Y=new Set([`FileEditorAction`,`StrReplaceEditorAction`]),qr=new Set([`FileEditorObservation`,`StrReplaceEditorObservation`]);function Jr(e,t){if(A(e)&&Y.has(e.action.kind))return e.action.path||null;if(k(e)&&qr.has(e.observation.kind)){let n=e.observation.path;if(n)return n;if(t&&Y.has(t.action.kind))return t.action.path||null}return null}function Yr(e,t){if(A(e)&&Y.has(e.action.kind))return e.action.command||null;if(k(e)&&qr.has(e.observation.kind)){let n=e.observation.command;if(n)return n;if(t&&Y.has(t.action.kind))return t.action.command||null}return null}function Xr(e,t){let n=Jr(e,t),r=Yr(e,t);return!!(n&&r===`create`&&Kr(n))}function Zr({content:e,path:t,onView:n}){let{t:r}=s(`openhands`),i=t.split(`/`).pop()||t;return(0,F.jsxs)(`div`,{className:`w-full overflow-hidden rounded-[12px] border border-[var(--oh-border)] bg-[var(--oh-surface)]`,"data-testid":`markdown-file-preview`,children:[(0,F.jsx)(`div`,{"data-testid":`markdown-file-preview-content`,className:`max-h-40 overflow-y-auto px-4 py-3 text-white custom-scrollbar-always [--oh-scroll-fade-from:var(--oh-surface)]`,children:(0,F.jsx)(M,{content:e,includeStandard:!0,includeHeadings:!0,components:hn})}),(0,F.jsxs)(`div`,{className:`flex h-10 items-center justify-between gap-2 border-t border-[var(--oh-border)] px-3`,children:[(0,F.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1.5`,children:[(0,F.jsx)(tt,{className:`h-3.5 w-3.5 flex-shrink-0 text-[var(--oh-muted)]`}),(0,F.jsx)(O.Text,{className:`truncate font-mono text-[11px] leading-4 tracking-[0.11px] text-[var(--oh-muted)]`,children:i})]}),n?(0,F.jsxs)(`button`,{type:`button`,onClick:n,className:`flex shrink-0 cursor-pointer items-center gap-1 transition-opacity hover:opacity-80`,"data-testid":`markdown-file-preview-view`,children:[(0,F.jsx)(O.Text,{className:`text-[11px] leading-4 tracking-[0.11px] text-white`,children:r(x.COMMON$VIEW)}),(0,F.jsx)(it,{className:`text-white`,size:16})]}):null]})]})}var Qr=({action:e,observation:t})=>t?.observation.path??e?.action.path??``;function $r({action:e,observation:t,onOpenFile:n}){let r=Qr({action:e,observation:t}),i=t?.observation.command??e?.action.command,a=Fr(r),o=e?.action.view_range,s=i===`view`&&o?`${o[0]}-${o[1]}`:void 0,c=r?(0,F.jsx)(Wr,{path:r,range:s,onClick:n}):null,l=e=>r&&i===`create`&&Kr(r)?{chip:null,body:(0,F.jsx)(Zr,{content:e,path:r,onView:n})}:{chip:c,body:(0,F.jsx)(Mr,{code:e,language:a})};if(t){let e=t.observation,n=null,r=c;if(e.error)n=(0,F.jsx)(`span`,{className:`whitespace-pre-wrap text-xs text-danger`,children:e.error});else if(e.old_content!=null&&e.new_content!=null)n=(0,F.jsx)(Ur,{oldText:e.old_content,newText:e.new_content});else{let t=e.new_content||e.output||(e.content?J(e.content):``);if(t){let e=l(t);r=e.chip,n=e.body}}return(0,F.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[r,n]})}if(e){let t=e.action,n=null,r=c;if(t.command===`create`&&t.file_text){let e=l(t.file_text);r=e.chip,n=e.body}else (t.command===`str_replace`||t.command===`insert`)&&t.new_str!=null&&(n=(0,F.jsx)(Ur,{oldText:t.old_str??``,newText:t.new_str}));return(0,F.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[r,n]})}return null}function ei({conversationId:e,...t}){let n=Qr(t),r=n&&t.observation?()=>N(n,e):void 0;return(0,F.jsx)($r,{...t,onOpenFile:r})}var ti=q({actionKinds:[`FileEditorAction`,`StrReplaceEditorAction`],observationKinds:[`FileEditorObservation`,`StrReplaceEditorObservation`],Body:function(e){let{conversationId:t}=j();return t?(0,F.jsx)(ei,{...e,conversationId:t}):(0,F.jsx)($r,{...e})}});function ni({rows:e}){return(0,F.jsx)(`div`,{className:`grid grid-cols-[auto_1fr] gap-x-3 gap-y-1 text-xs`,children:e.map(({label:e,value:t})=>(0,F.jsxs)(P.Fragment,{children:[(0,F.jsx)(`span`,{className:`text-muted`,children:e}),(0,F.jsx)(`span`,{className:`break-all font-mono text-foreground`,children:t})]},e))})}var ri=q({actionKinds:[`GrepAction`,`GlobAction`],observationKinds:[`GrepObservation`,`GlobObservation`],Body:function({action:e,observation:t}){let{t:n}=s(`openhands`),r=t?.observation,i=e?.action,a=r?.pattern??i?.pattern??``,o=r?.search_path??i?.path??``,c=r?`include_pattern`in r?r.include_pattern:null:i&&`include`in i?i.include:null,l=r?`matches`in r?r.matches:r.files:[];return(0,F.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,F.jsx)(ni,{rows:[{label:n(x.COMMON$PATTERN),value:a},...o?[{label:n(x.COMMON$PATH),value:o}]:[],...c?[{label:n(x.COMMON$INCLUDE),value:c}]:[]]}),r&&(r.is_error?(0,F.jsx)(`span`,{className:`whitespace-pre-wrap text-xs text-danger`,children:J(r.content)}):l.length===0?(0,F.jsx)(`span`,{className:`text-xs text-muted`,children:n(x.COMMON$NO_RESULTS)}):(0,F.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,F.jsx)(`span`,{className:`text-xs text-muted`,children:n(x.COMMON$RESULTS,{count:l.length})}),(0,F.jsx)(`div`,{className:`flex flex-col gap-0.5 font-mono text-xs text-foreground`,children:l.map(e=>(0,F.jsx)(`span`,{className:`break-all`,children:e},e))}),r.truncated&&(0,F.jsx)(`span`,{className:`text-xs text-muted`,children:n(x.COMMON$TRUNCATED)})]}))]})}});function ii({label:e,text:t,isError:n=!1}){return(0,F.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,F.jsx)(`span`,{className:`text-xs text-muted`,children:e}),(0,F.jsx)(qe,{text:t,children:(0,F.jsx)(`div`,{className:`overflow-auto rounded border border-surface-raised bg-surface-raised p-2 text-xs ${n?`text-danger`:`text-foreground`}`,children:(0,F.jsx)(M,{includeStandard:!0,includeHeadings:!0,children:t})})})]})}var ai=[Pr,ti,ri,q({actionKinds:[`TaskAction`],observationKinds:[`TaskObservation`],Body:function({action:e,observation:t}){let{t:n}=s(`openhands`),r=e?.action,i=t?.observation,a=i?.subagent??r?.subagent_type??``,o=i?.task_id,c=r?.prompt?.trim()??``,l=i?J(i.content).trim():``,u=[...a?[{label:n(x.TASK$SUBAGENT),value:a}]:[],...o?[{label:n(x.TASK$TASK_ID),value:o}]:[]];return(0,F.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[u.length>0&&(0,F.jsx)(ni,{rows:u}),c&&(0,F.jsx)(ii,{label:n(x.TASK$QUERY),text:c}),l&&(0,F.jsx)(ii,{label:n(x.TASK$RESULT),text:l,isError:i?.is_error})]})}})],oi=e=>new Map(ai.flatMap(t=>(e(t)??[]).map(e=>[e,t]))),si=oi(e=>e.actionKinds),ci=oi(e=>e.observationKinds);function li(e,t){if(A(e)){let t=si.get(e.action.kind);if(t)return(0,F.jsx)(t.Body,{action:e})}else if(k(e)){let n=ci.get(e.observation.kind);if(n)return(0,F.jsx)(n.Body,{action:t,observation:e})}return null}var X=(e,t)=>m.exists(e)?(0,F.jsx)(f,{ns:`openhands`,i18nKey:e,values:t,components:{path:(0,F.jsx)(nn,{}),cmd:(0,F.jsx)(Zt,{})}}):e,ui=e=>e.kind===`text`?e.text:X(e.key,e.values),Z=(e,t)=>{if(typeof e!=`string`)return null;let n=e.trim();return n?t?B(n,t):n:null},di=e=>{if(e.tool_name!==`inspect_image_with_vision`)return null;let t=e.action,n=Z(t.profile_name);return n?`Describing image with ${n}`:`Describing image with auxiliary vision LLM`},fi=(e,t)=>{let n=t?.tool_name,r=e.observation,i=Z(r.tool_name);if(n!==`inspect_image_with_vision`&&i!==`inspect_image_with_vision`&&String(e.observation.kind)!==`VisionInspectObservation`)return null;let a=Z((t?.action??{}).profile_name)??Z(r.profile_name)??Z(r.base_url,80)??Z(r.endpoint,80)??Z(r.model,80);return a?`Describing image with ${a}`:`Describing image with auxiliary vision LLM`},pi=e=>A(e)?di(e)||ui(Jt(e)):``,mi=(e,t)=>{if(!k(e))return``;let n=fi(e,t);if(n)return n;if(t){let e=di(t);if(e)return e;let n=qt(t);if(n)return n}let r=e.observation.kind,i=``,a={};switch(r){case`ExecuteBashObservation`:case`TerminalObservation`:i=`OBSERVATION_MESSAGE$RUN`,a={command:e.observation.command?B(e.observation.command,80):``};break;case`FileEditorObservation`:case`StrReplaceEditorObservation`:i=e.observation.command===`view`?`OBSERVATION_MESSAGE$READ`:e.observation.command===`create`?`OBSERVATION_MESSAGE$WRITE`:`OBSERVATION_MESSAGE$EDIT`,a={path:e.observation.path||``};break;case`MCPToolObservation`:i=`OBSERVATION_MESSAGE$MCP`,a={mcp_tool_name:e.observation.tool_name};break;case`InvokeSkillObservation`:i=`OBSERVATION_MESSAGE$INVOKE_SKILL`,a={name:e.observation.skill_name};break;case`TaskObservation`:i=`OBSERVATION_MESSAGE$TASK`,a={name:e.observation.subagent};break;case`CanvasUIObservation`:i=`OBSERVATION_MESSAGE$CANVAS_UI`;break;case`ClientToolObservation`:if(e.tool_name===`canvas_ui_control`){i=`OBSERVATION_MESSAGE$CANVAS_UI`;break}if(e.tool_name===`launch_child_conversation`){i=`OBSERVATION_MESSAGE$LAUNCH_CHILD_CONVERSATION`;break}return r.replace(`Observation`,``).toUpperCase();case`SwitchLLMObservation`:i=e.observation.is_error?`MODEL$SWITCH_FAILED`:`MODEL$SWITCHED_TO_PROFILE`,a={name:e.observation.profile_name};break;case`BrowserObservation`:i=`OBSERVATION_MESSAGE$BROWSE`;break;case`TaskTrackerObservation`:{let{command:t}=e.observation;i=t===`plan`?`OBSERVATION_MESSAGE$TASK_TRACKING_PLAN`:`OBSERVATION_MESSAGE$TASK_TRACKING_VIEW`;break}case`ThinkObservation`:i=`OBSERVATION_MESSAGE$THINK`;break;case`GlobObservation`:i=`OBSERVATION_MESSAGE$GLOB`,a={pattern:e.observation.pattern?B(e.observation.pattern,50):``};break;case`GrepObservation`:i=`OBSERVATION_MESSAGE$GREP`,a={pattern:e.observation.pattern?B(e.observation.pattern,50):``};break;default:return r.replace(`Observation`,``).toUpperCase()}return i?X(i,a):r},hi=(e,t)=>e.observation.kind!==`ClientToolObservation`||e.tool_name!==`canvas_ui_control`||!t||!Ne(t)?null:`UI command '${t.action.command}' dispatched to the Agent Canvas frontend.`,Q=(e,t)=>{let n=``,r=``;if(K(e)){let t=`OBSERVATION_MESSAGE$SKILL_READY`;n=m.exists(t)?X(t,{}):`Skill Ready`,r=e._skillReadyContent}else A(e)?(n=pi(e),r=li(e)??nr(e)):k(e)?(n=mi(e,t),r=e.observation.kind===`TaskTrackerObservation`?(0,F.jsx)(Sr,{event:e}):hi(e,t)??li(e,t)??_r(e)):Je(e)?(n=X(Bt(e),{title:Ht(e)}),r=Gt(e)):e.source===`agent`&&`action`in e&&e.action!==null&&typeof e.action==`object`&&`kind`in e.action&&typeof e.action.kind==`string`&&(n=String(e.action.kind).replace(`Action`,``).toUpperCase());return{title:n||m.t(x.EVENT$UNKNOWN_EVENT),details:r}};function gi({event:e,isFromPlanningAgent:t=!1}){let n=Q(e);return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(H,{type:`agent`,message:typeof n.details==`string`?n.details:String(n.details),isFromPlanningAgent:t}),e.critic_result!=null&&(0,F.jsx)(Hn,{criticResult:e.critic_result})]})}var _i=e=>{let{observation:t}=e,n=t.content.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
36
|
-
`).trim();return!t.skill_name&&!n?[]:[{name:t.skill_name,content:n}]};function vi(e){let t=e.split(`
|
|
37
|
-
`),n=null,r=null,i=0;for(let e=0;e<t.length;e+=1){let a=t[e];if(a.startsWith(b[0]))n=a.trim(),i=e+1;else if(a.startsWith(b[2]))r=a.replace(b[2],``).trim(),i=e+1;else if(a.startsWith(b[1])||a.startsWith(b[3]))i=e+1;else if(a.trim()===``&&e<=i)i=e+1;else break}return{matchInfo:n,filePath:r,body:t.slice(i).join(`
|
|
38
|
-
`).trim()}}function yi(e){return e.replace(/<important>([\s\S]*?)<\/important>/gi,(e,t)=>`**${t.trim()}**`)}function bi({content:e}){let{t}=s(`openhands`),{matchInfo:n,filePath:r,body:i}=vi(e),a=n||r;return(0,F.jsxs)(`div`,{className:`pl-6 pr-2 pt-2 pb-2`,children:[a&&(0,F.jsxs)(`div`,{className:`mb-3 text-sm text-[var(--oh-muted)] space-y-1`,children:[n&&(0,F.jsx)(`p`,{children:n}),r&&(0,F.jsxs)(`p`,{children:[(0,F.jsxs)(O.Text,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.COMMON$PATH),` `]}),(0,F.jsx)(`code`,{className:`bg-[var(--oh-surface)] px-1.5 py-0.5 rounded text-[var(--oh-text-tertiary)]`,children:r})]})]}),a&&i&&(0,F.jsx)(`hr`,{className:`border-[var(--oh-border-subtle)] mb-3`}),i&&(0,F.jsx)(M,{children:yi(i)})]})}function xi({items:e,titleKey:t=x.SKILLS$TRIGGERED_SKILL_KNOWLEDGE}){let{t:n}=s(`openhands`),[r,i]=P.useState({}),a=e=>{i(t=>({...t,[e]:!t[e]}))};return(0,F.jsxs)(`div`,{className:`flex flex-col gap-1 mt-1`,children:[(0,F.jsx)(O.Text,{className:`font-bold text-[var(--oh-foreground)] text-sm px-2 py-1`,children:n(t)}),e.map(e=>{let t=r[e.name]||!1;return(0,F.jsxs)(`div`,{className:`border border-[var(--oh-border-subtle)] rounded-md overflow-hidden`,children:[(0,F.jsxs)(`button`,{type:`button`,onClick:()=>a(e.name),className:`w-full py-1.5 px-2 text-left flex items-center gap-2 hover:bg-tertiary transition-colors cursor-pointer`,children:[(0,F.jsx)(O.Text,{className:`text-[var(--oh-text-tertiary)]`,children:t?(0,F.jsx)(w,{size:14}):(0,F.jsx)(T,{size:14})}),(0,F.jsx)(O.Text,{className:`font-normal text-[var(--oh-foreground)] text-sm`,children:e.name})]}),t&&e.content&&(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`hr`,{className:`border-[var(--oh-border-subtle)]`}),(0,F.jsx)(bi,{content:e.content})]})]},e.name)})]})}function Si(e){if(K(e))return e._skillReadyItems.length>0?{items:e._skillReadyItems,titleKey:x.SKILLS$TRIGGERED_SKILL_KNOWLEDGE}:null;if(k(e)&&e.observation.kind===`InvokeSkillObservation`){let t=_i(e);return t.length>0?{items:t,titleKey:x.SKILLS$INVOKED_SKILL_KNOWLEDGE}:null}return null}function $({event:e,isLastMessage:t,correspondingAction:n}){let{title:r,details:i}=Q(e,n);if(!K(e)&&k(e)&&e.observation.kind===`TaskTrackerObservation`)return(0,F.jsx)(`div`,{children:i});let a;K(e)?a=`success`:k(e)?a=ir(e):Je(e)&&(a=rr(e));let o=Si(e),s=o?(0,F.jsx)(xi,{items:o.items,titleKey:o.titleKey}):i,c=!K(e)&&Xr(e,n);return(0,F.jsxs)(`div`,{children:[(0,F.jsx)(R,{title:r,details:s,success:a,initiallyExpanded:c,titleIcon:o?(0,F.jsx)(Te,{className:`h-4 w-4 stroke-[var(--oh-muted)] flex-shrink-0 mr-2`}):void 0}),t&&(0,F.jsx)(Mn,{})]})}function Ci({event:e,actions:t,isFromPlanningAgent:n=!1}){let r=e.thought.filter(e=>e.type===`text`).map(e=>e.text).join(`
|
|
39
|
-
`);return r?(0,F.jsx)(H,{type:`agent`,message:r,actions:t,isFromPlanningAgent:n}):null}function wi(e,t){if(t)return`🚫`;switch(e){case`PreToolUse`:return`⏳`;case`PostToolUse`:return`✅`;case`UserPromptSubmit`:return`📝`;case`SessionStart`:return`🚀`;case`SessionEnd`:return`🏁`;case`Stop`:return`⏹️`;default:return`🔗`}}function Ti(e){return e.length>80?`${e.slice(0,77)}...`:e}function Ei(e,t){return e?`blocked`:t?`ok`:`failed`}function Di(e,t){return e?`bg-amber-900/50 text-amber-300`:t?`bg-green-900/50 text-green-300`:`bg-red-900/50 text-red-300`}function Oi({event:e}){let{t}=s(`openhands`);if(!je(e))return null;let n=wi(e.hook_event_type,e.blocked),r=Ei(e.blocked,e.success),i=Di(e.blocked,e.success),a=(()=>{if(!e.blocked)return e.success?`success`:`error`})();return(0,F.jsx)(R,{title:(0,F.jsxs)(`span`,{children:[n,` `,t(x.HOOK$HOOK_LABEL),`: `,e.hook_event_type,e.tool_name&&(0,F.jsxs)(`span`,{className:`text-[var(--oh-muted)] ml-2`,children:[`(`,e.tool_name,`)`]}),(0,F.jsx)(`span`,{className:C(`ml-2 px-1 py-0.5 rounded text-xs`,i),children:r})]}),details:(0,F.jsxs)(`div`,{className:`flex flex-col gap-2 text-[var(--oh-muted)]`,children:[(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$COMMAND),`:`]}),` `,(0,F.jsx)(`code`,{className:`text-xs bg-[var(--oh-surface)] px-1 py-0.5 rounded`,children:Ti(e.hook_command)})]}),e.exit_code!==null&&(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$EXIT_CODE),`:`]}),` `,e.exit_code]}),e.blocked&&e.reason&&(0,F.jsxs)(`div`,{className:`text-amber-400`,children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$BLOCKED_REASON),`:`]}),` `,e.reason]}),e.additional_context&&(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$CONTEXT),`:`]}),` `,e.additional_context]}),e.error&&(0,F.jsxs)(`div`,{className:`text-red-400`,children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$ERROR),`:`]}),` `,e.error]}),e.stdout&&(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$OUTPUT),`:`]}),(0,F.jsx)(`pre`,{className:`text-xs bg-[var(--oh-surface)] p-2 rounded mt-1 overflow-x-auto max-h-40 overflow-y-auto`,children:e.stdout})]}),e.stderr&&(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`span`,{className:`text-[var(--oh-text-subtle)]`,children:[t(x.HOOK$STDERR),`:`]}),(0,F.jsx)(`pre`,{className:`text-xs bg-[var(--oh-surface)] p-2 rounded mt-1 overflow-x-auto max-h-40 overflow-y-auto text-amber-300`,children:e.stderr})]})]}),success:a})}function ki(e){let t=[],n=[];for(let r of e)Qe(r)?(n.length>0&&t.push(n),n=[r]):n.push(r);return n.length>0&&t.push(n),t}var Ai=e=>e?.toUpperCase().endsWith(`PLAN.MD`)??!1;function ji(e){for(let t=e.length-1;t>=0;--t){let n=e[t];if(ze(n)&&Ai(n.observation.path))return n.id}return null}function Mi(e){return(0,P.useMemo)(()=>{let t=new Set;return ki(e).forEach(e=>{let n=ji(e);n&&t.add(n)}),t},[e])}function Ni(e,t){return t.has(e)}var Pi=e=>e.activated_skills||[],Fi=e=>!e||e.length===0?!1:e.some(e=>e.type===`text`&&e.text.trim().length>0),Ii=e=>{let t=Pi(e).length>0,n=Fi(e.extended_content);return t&&n},Li=(e,t,n)=>{try{let r=jr(e);return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(Gn,{event:e,isLastMessage:!1,isFromPlanningAgent:t.isFromPlanningAgent}),(0,F.jsx)($,{event:r,isLastMessage:n})]})}catch{return(0,F.jsx)(Gn,{event:e,isLastMessage:n,isFromPlanningAgent:t.isFromPlanningAgent})}};function Ri({event:e,messages:t,isLastMessage:n,isInLast10Actions:r,planPreviewEventIds:i,suppressThought:a=!1}){let{data:o}=ie(),{planContent:s}=fe(),{curAgentState:c}=Ve(),l=c===S.RUNNING||c===S.LOADING,u=e.isFromPlanningAgent||!1,d={isLastMessage:n,isInLast10Actions:r,config:o,isFromPlanningAgent:u};if(Pe(e)&&et(e))return(0,F.jsx)(pt,{status:e.value});if(Fe(e))return(0,F.jsx)(bn,{event:e,...d});if(je(e))return(0,F.jsx)(Oi,{event:e});if(Je(e))return(0,F.jsx)($,{event:e,isLastMessage:n});if(Be(e)){let{reasoning:t,message:n}=Ae(e.content??``,{streaming:!0}),r=[e.reasoning_content??``,t].filter(Boolean).join(`
|
|
40
|
-
|
|
41
|
-
`);return(0,F.jsxs)(F.Fragment,{children:[r&&(0,F.jsx)(W,{content:r}),n&&(0,F.jsx)(H,{type:`agent`,message:n,isFromPlanningAgent:u})]})}if(A(e)&&e.action.kind===`FinishAction`)return(0,F.jsx)(gi,{event:e,...d});if(A(e)&&e.action.kind===`ThinkAction`)return(0,F.jsx)(W,{content:e.action.thought});if(A(e)){let t=Ie(e);return(0,F.jsxs)(F.Fragment,{children:[t&&(0,F.jsx)(W,{content:t}),!a&&(0,F.jsx)(Ci,{event:e,isFromPlanningAgent:u}),(0,F.jsx)($,{event:e,isLastMessage:n})]})}if(k(e)){if(ze(e))return i&&Ni(e.id,i)?(0,F.jsx)(vn,{planContent:s,isStreaming:n&&c===S.RUNNING,isBuildDisabled:l}):null;let r=t.find(t=>A(t)&&t.id===e.action_id),o=!a&&r&&A(r)&&r.action.kind!==`ThinkAction`,d=r&&A(r)?Ie(r):``;return(0,F.jsxs)(F.Fragment,{children:[d&&(0,F.jsx)(W,{content:d}),o&&(0,F.jsx)(Ci,{event:r,isFromPlanningAgent:u}),(0,F.jsx)($,{event:e,isLastMessage:n,correspondingAction:r&&A(r)?r:void 0})]})}if(!A(e)&&!k(e)){let t=e;return Qe(e)&&Ii(t)?Li(t,d,n):(0,F.jsx)(Gn,{event:t,...d,isLastMessage:n})}return(0,F.jsx)($,{event:e,isLastMessage:n})}var zi=(e,t)=>{if(A(e)){let{kind:n}=e.action;return!(n===`FinishAction`||n===`ThinkAction`||Xr(e,t))}return k(e)?!(ze(e)||Xr(e,t)||e.observation.kind===`TaskTrackerObservation`):!1},Bi=(e,t=2,n=e)=>{if(t<1)throw Error(`minSize must be at least 1`);let r=[],i=new Set,a=null,o=()=>{a&&=(a.events.length>=t?r.push({kind:`group`,events:a.events,startIndex:a.startIndex}):a.events.forEach((e,t)=>{r.push({kind:`single`,event:e,index:a.startIndex+t})}),null)};return e.forEach((e,t)=>{if(zi(e,k(e)?n.find(t=>A(t)&&t.id===e.action_id):void 0)){let s=Ye(e,n);s&&!i.has(s.id)&&(o(),i.add(s.id),r.push({kind:`thought`,action:s,index:t})),a||={events:[],startIndex:t},a.events.push(e)}else o(),r.push({kind:`single`,event:e,index:t})}),o(),r},Vi=(0,P.createContext)(!1);function Hi({events:e,allEvents:t,isFinalized:n=!1,children:r}){let{t:i}=s(`openhands`),[a,o]=P.useState(!1),c=P.useId(),l=`${c}-toggle`;if(e.length===0)return null;let u=e.find(e=>A(e)),d=e.filter(k).length,f=e.length,p=!!u,m=e[e.length-1],h=null;m&&(A(m)?h=Q(m).title:k(m)&&(h=Q(m,(t??e).find(e=>A(e)&&e.id===m.action_id)).title));let g=p?i(x.EVENT_GROUP$ACTIONS_PROGRESS,{completed:d,total:f}):i(x.EVENT_GROUP$ACTIONS_COMPLETED,{count:f}),_=a?L:I;return(0,F.jsxs)(`div`,{className:`my-1 w-full py-1 text-sm`,"data-testid":`event-group`,children:[(0,F.jsx)(`button`,{id:l,type:`button`,onClick:()=>o(e=>!e),"aria-controls":c,"aria-expanded":a,"aria-label":i(a?x.EVENT_GROUP$COLLAPSE:x.EVENT_GROUP$EXPAND),"data-testid":`event-group-toggle`,className:`w-full flex items-center justify-between gap-2 text-left cursor-pointer`,children:n?(0,F.jsxs)(`span`,{className:`flex items-center gap-2 min-w-0 font-normal text-[var(--oh-muted)]`,children:[(0,F.jsx)(_,{className:`h-4 w-4 fill-[var(--oh-muted)] flex-shrink-0`}),(0,F.jsx)(`span`,{className:`truncate`,children:g})]}):(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)(`span`,{className:`flex items-center gap-2 min-w-0 font-normal text-[var(--oh-muted)]`,children:[(0,F.jsx)(_,{className:`h-4 w-4 fill-[var(--oh-muted)] flex-shrink-0`}),(0,F.jsx)(`span`,{className:`truncate`,children:(0,F.jsx)(Qt.Provider,{value:!1,children:h??g})})]}),(0,F.jsxs)(`span`,{className:`flex items-center flex-shrink-0 font-normal text-[var(--oh-muted)]`,children:[(0,F.jsx)(`span`,{className:`truncate`,children:g}),p?(0,F.jsx)(E,{"data-testid":`spinner-icon`,className:`h-4 w-4 ml-2 inline animate-spin text-[var(--oh-muted)]`}):null]})]})}),a&&(0,F.jsx)(`div`,{id:c,role:`region`,"aria-labelledby":l,className:`mt-1.5 flex flex-col`,"data-testid":`event-group-content`,children:(0,F.jsx)(Vi.Provider,{value:!0,children:r})})]})}var Ui=e=>e.at(-1)?.id,Wi=e=>e.at(-1),Gi=P.memo(({messages:e,allEvents:t})=>{let{conversationId:n}=j(),r=Mi(t),i=He(e=>n?e.entriesByConversation[n]:void 0),a=P.useMemo(()=>{if(!i||i.length===0)return null;let e=new Set;for(let t of i)t.anchorEventId!==null&&e.add(t.anchorEventId);return e.size>0?e:null},[i]),o=e=>{if(!a||e===void 0)return null;let t=String(e);return a.has(t)?(0,F.jsx)(gt,{conversationId:n,anchorEventId:t}):null},s=P.useMemo(()=>Bi(e,void 0,t),[e,t]),c=(n,i,a)=>(0,F.jsx)(Ri,{event:n,messages:t,isLastMessage:e.length-1===i,isInLast10Actions:e.length-1-i<10,planPreviewEventIds:r,suppressThought:a},n.id);return(0,F.jsx)(F.Fragment,{children:s.map((e,n)=>{if(e.kind===`single`)return(0,F.jsxs)(P.Fragment,{children:[c(e.event,e.index,!0),o(e.event.id)]},`single-${e.event.id}`);if(e.kind===`thought`)return(0,F.jsxs)(P.Fragment,{children:[(0,F.jsx)(Ci,{event:e.action}),o(e.action.id)]},`thought-${e.action.id}`);let r=n<s.length-1,i=e.events[0]?.id??`group-${e.startIndex}`;return(0,F.jsxs)(P.Fragment,{children:[(0,F.jsx)(Hi,{events:e.events,allEvents:t,isFinalized:r,children:e.events.map((t,n)=>c(t,e.startIndex+n,!0))}),e.events.map(e=>(0,F.jsx)(P.Fragment,{children:o(e.id)},`model-${e.id}`))]},`group-${i}`)})})},(e,t)=>e.messages.length===t.messages.length&&e.allEvents.length===t.allEvents.length&&Ui(e.messages)===Ui(t.messages)&&Ui(e.allEvents)===Ui(t.allEvents)&&Wi(e.messages)===Wi(t.messages)&&Wi(e.allEvents)===Wi(t.allEvents));Gi.displayName=`Messages`;export{R as A,kt as C,gt as D,_t as E,st as M,ot as N,pt as O,at as P,Mt as S,xt as T,Jt as _,yr as a,Bt as b,nr as c,hn as d,H as f,Zt as g,nn as h,Fr as i,ct as j,ut as k,Nn as l,rn as m,Bi as n,vr as o,cn as p,Kr as r,_r as s,Gi as t,En as u,qt as v,yt as w,Ht as x,Gt as y};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./rolldown-runtime-Cyuzqnbw.js";import{St as e,yt as t}from"./vendor-styling-Ck5D_A2Q.js";import{t as n}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{W as r,t as i}from"./utils-CN5ZfZy1.js";e();var a=t(),o=e=>(0,a.jsx)(`svg`,{width:16,height:16,viewBox:`0 0 16 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,a.jsx)(`path`,{d:`M12 4L4 12M4 4L12 12`,stroke:`currentColor`,strokeWidth:1.5,strokeLinecap:`round`,strokeLinejoin:`round`})});function s({onClose:e,testId:t,className:s,disabled:c=!1}){let{t:l}=n(`openhands`);return(0,a.jsx)(`button`,{type:`button`,"data-testid":t,onClick:e,disabled:c,"aria-label":l(r.BUTTON$CLOSE),className:i(`absolute right-4 top-4 z-10 flex cursor-pointer items-center justify-center rounded-sm border-0 bg-transparent p-1 text-tertiary-alt transition-colors hover:bg-surface-raised hover:text-white disabled:cursor-not-allowed disabled:opacity-50`,s),children:(0,a.jsx)(o,{"aria-hidden":!0,className:`size-4`})})}export{s as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{F as r}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{n as i}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js";import{t as a}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{D as o,_ as s,g as c,s as l}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{t as u}from"./useMutation-B-qc391N.js";import{t as d}from"./useQueries-DlbhlH9I.js";import{t as f}from"./useQuery-BSTgq1rl.js";import{F as p,n as m,tt as h}from"./active-backend-context-CrHTlgvN.js";import{W as g,t as _}from"./utils-CN5ZfZy1.js";import{t as v}from"./use-onboarding-completion-D8U7k4Qb.js";import{n as y}from"./use-settings-DSXLbvBl.js";import{t as b}from"./modal-backdrop-BSzNhM4r.js";import{r as x,t as S}from"./modal-body-BxZjsju9.js";import{r as C}from"./base-modal-D_L0oEbG.js";import{i as w}from"./modal-classes-C8eycCwG.js";import{t as T}from"./brand-button-BAfk4wGP.js";import{m as E}from"./use-llm-configured-BV9nZ1_j.js";import{t as D}from"./confirmation-modal-Dv1ktp8K.js";import{f as O}from"./llm-subscription-DTqtBCWz.js";import{t as ee}from"./onboarding-modal-rkyBYkeQ.js";import{t as k}from"./folder-C1ou4_DT.js";import{t as A}from"./close-ScPlnwyq.js";var j=o(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),M=e(t(),1);function N(){return new l(h())}function P(e){return{workspaces:e.workspaces.map(({parentPath:e,...t})=>({...t,...e?{parentPath:e}:{}})),workspaceParents:e.workspaceParents}}var F=class{static async listWorkspaces(){return P(await N().listWorkspaces())}static async addWorkspaces(e){return P(await N().addWorkspaces(e))}static async removeWorkspace(e){await N().deleteWorkspace(e)}static async addWorkspaceParents(e){return P(await N().addWorkspaceParents(e))}static async removeWorkspaceParent(e){await N().deleteWorkspaceParent(e)}};function I({enabled:e=!0}={}){return f({queryKey:p.all,queryFn:()=>F.listWorkspaces(),enabled:e,retry:(e,t)=>!c(t)&&e<3,meta:{disableToast:!0},staleTime:6e4})}function L(){return new s(h())}async function R(e,t=L()){let n=[],r=new Set,i;for(;;){let a=await t.searchSubdirectories(e,i?{pageId:i}:void 0);if(n.push(...a.items),i=a.next_page_id,!i)return{items:n,next_page_id:null};if(r.has(i))throw Error(`File search returned a repeated page id`);r.add(i)}}var z=e=>{let t=m();return f({queryKey:[`file`,`search_subdirs`,e,t.backend.id,t.orgId],queryFn:()=>R(e),enabled:!!e,retry:!1,meta:{disableToast:!0}})},B=()=>{let e=m();return f({queryKey:[`file`,`home`,e.backend.id,e.orgId],queryFn:async()=>L().getHome(),retry:!1,meta:{disableToast:!0},staleTime:1/0})};function te(){let{data:e,isLoading:t,isError:n,error:r}=I(),i=c(r),a=e?.workspaces??[],o=e?.workspaceParents??[],s=(0,M.useMemo)(()=>{let e=new Set(o.map(e=>e.path)),t=[].filter(t=>!e.has(t.path));return t.length===0?o:[...o,...t]},[o,i]),l=d({queries:i?[]:s.map(e=>({queryKey:[`file`,`search_subdirs`,e.path],queryFn:()=>R(e.path),retry:!1,meta:{disableToast:!0}}))}),u=t||l.some(e=>e.isLoading),f=n||l.some(e=>e.isError);return{workspaces:(0,M.useMemo)(()=>{let e=new Map,t=new Map(s.map((e,t)=>[e.path,l[t]]));return s.forEach(n=>{(t.get(n.path)?.data?.items??[]).forEach(t=>{e.has(t.path)||e.set(t.path,{id:t.path,name:t.name,path:t.path,parentPath:n.path})})}),a.forEach(t=>{e.set(t.path,t)}),Array.from(e.values())},[a,s,l.map(e=>`${e.dataUpdatedAt??0}:${e.status}`).join(`|`)]),parents:s,isLoading:u,isError:f,error:r}}var V=n();function ne(){return(0,V.jsx)(E,{inset:`menu`})}function re(){let e=i();return u({mutationFn:e=>F.addWorkspaces(e),onSuccess:()=>e.invalidateQueries({queryKey:p.all})})}function ie(){let e=i();return u({mutationFn:e=>F.removeWorkspace(e),onSuccess:()=>e.invalidateQueries({queryKey:p.all})})}function H(){let e=i();return u({mutationFn:e=>F.addWorkspaceParents(e),onSuccess:()=>e.invalidateQueries({queryKey:p.all})})}function U(){let e=i();return u({mutationFn:e=>F.removeWorkspaceParent(e),onSuccess:()=>e.invalidateQueries({queryKey:p.all})})}function W(e,t){return c(e)?t(g.HOME$WORKSPACES_UNSUPPORTED_AGENT_SERVER,{actualVersion:e.actualVersion,requiredVersion:e.requiredVersion}):null}var G=e=>(0,V.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:(0,V.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M13.8227 16.6549L10.4043 12.6668L13.8227 8.67871L14.9615 9.6549L12.3799 12.6668L14.9615 15.6787L13.8227 16.6549Z`,fill:`currentColor`})}),K=`/projects`;function q({label:e,entries:t,currentPath:n,onPick:r}){return t.length===0?null:(0,V.jsxs)(`div`,{className:`px-2 pb-3`,children:[(0,V.jsx)(`div`,{className:`px-2 pb-1 text-[11px] uppercase tracking-wide text-[var(--oh-muted)] font-semibold`,children:e}),(0,V.jsx)(`ul`,{children:t.map(e=>{let t=n===e.path;return(0,V.jsx)(`li`,{children:(0,V.jsxs)(`button`,{type:`button`,onClick:()=>r(e.path),"data-testid":`folder-browser-sidebar-${e.label.toLowerCase()}`,className:_(`flex items-center gap-2 w-full px-2 py-1 rounded text-sm cursor-pointer`,t?`bg-tertiary text-white`:`text-[var(--oh-text-tertiary)] hover:bg-[var(--oh-surface-raised)]`),children:[(0,V.jsx)(k,{width:14,height:14,className:`shrink-0`}),(0,V.jsx)(`span`,{className:`truncate`,children:e.label})]})},e.path)})})]})}function J(e){let t=X(e);if(!t||t===`/`||Y(t))return null;let n=Math.max(t.lastIndexOf(`/`),t.lastIndexOf(`\\`));if(n<0)return null;if(n===0)return`/`;let r=t.slice(0,n);return/^[A-Za-z]:$/.test(r)?`${r}${t[n]}`:r}function Y(e){return/^[A-Za-z]:[\\/]?$/.test(e)}function X(e){let t=e.replace(/[\\/]+$/,``);return/^[A-Za-z]:$/.test(t)?`${t}${e.includes(`/`)&&!e.includes(`\\`)?`/`:`\\`}`:t}function Z(e){return e?.home===`/home/openhands`}function ae({isOpen:e,onClose:t,onAdd:n,onAddParent:r}){let{t:i}=a(`openhands`),[o,s]=(0,M.useState)(null),c=m(),{data:l}=B();(0,M.useEffect)(()=>{e&&l?.home&&o===null&&s(Z(l)?K:l.home),e||s(null)},[e,l?.home,o]),(0,M.useEffect)(()=>{s(null)},[c.backend.id,c.orgId]);let{data:u,isLoading:d,isError:f,error:p}=z(e?o:null),h=(0,M.useMemo)(()=>{if(!l?.home)return[];let e=[{label:`Home`,path:X(l.home)||l.home},...l.favorites??[]];return Z(l)&&!e.some(e=>e.path===K)&&e.push({label:K,path:K}),e},[l]),v=l?.locations??[];if(!e)return null;let y=u?.items??[],E=o?J(o):null,D=l?.home===`/home/openhands`&&(l?.favorites?.length??0)===0&&o===l?.home&&!d&&!f&&y.length===0,O=e=>{let t=X(e);if(!t)return`/`;if(t===`/`||Y(t))return t;let n=Math.max(t.lastIndexOf(`/`),t.lastIndexOf(`\\`));return n>=0&&t.slice(n+1)||t};return(0,V.jsx)(b,{onClose:t,"aria-label":i(g.HOME$ADD_WORKSPACES_TITLE),children:(0,V.jsxs)(`div`,{"data-testid":`folder-browser-modal`,className:_(`flex flex-col bg-[var(--oh-surface)] border border-[var(--oh-border-input)] rounded-xl`,x(`xl`),S,`h-[480px]`),children:[(0,V.jsx)(`div`,{className:`flex items-center justify-between px-5 py-3 border-b border-[var(--oh-border-input)]`,children:(0,V.jsx)(C,{className:w,title:i(g.HOME$ADD_WORKSPACES_TITLE)})}),(0,V.jsxs)(`div`,{className:`flex flex-1 min-h-0`,children:[(0,V.jsxs)(`aside`,{"data-testid":`folder-browser-sidebar`,className:`w-[180px] shrink-0 border-r border-[var(--oh-border-input)] bg-[var(--oh-surface)] py-3 overflow-y-auto`,children:[(0,V.jsx)(q,{label:i(g.HOME$FAVORITES),entries:h,currentPath:o,onPick:s}),(0,V.jsx)(q,{label:i(g.HOME$LOCATIONS),entries:v,currentPath:o,onPick:s})]}),(0,V.jsxs)(`div`,{className:`flex-1 flex flex-col min-w-0`,children:[(0,V.jsxs)(`div`,{className:`flex items-center gap-2 px-4 py-2 border-b border-[var(--oh-border-input)]`,children:[(0,V.jsx)(`button`,{type:`button`,"data-testid":`folder-browser-up`,onClick:()=>E&&s(E),disabled:!E,"aria-label":i(g.COMMON$UP),className:`p-1 rounded hover:bg-[var(--oh-interactive-hover)] text-white disabled:opacity-40 disabled:cursor-not-allowed cursor-pointer`,children:(0,V.jsx)(G,{width:16,height:16})}),(0,V.jsx)(`span`,{className:`text-xs text-[var(--oh-muted)] truncate`,"data-testid":`folder-browser-current-path`,children:o??``})]}),(0,V.jsxs)(`div`,{className:`grid grid-cols-[1fr_120px] px-4 py-1 border-b border-[var(--oh-border-input)] text-xs text-[var(--oh-text-secondary)] font-semibold`,children:[(0,V.jsx)(`span`,{children:i(g.HOME$NAME)}),(0,V.jsx)(`span`,{children:i(g.HOME$KIND)})]}),(0,V.jsxs)(`ul`,{className:`flex-1 overflow-auto custom-scrollbar-always`,"data-testid":`folder-browser-list`,children:[d&&(0,V.jsx)(`li`,{className:`px-4 py-2 text-sm text-[var(--oh-text-secondary)]`,children:i(g.HOME$LOADING)}),f&&(0,V.jsx)(`li`,{className:`px-4 py-2 text-sm text-red-400`,"data-testid":`folder-browser-error`,children:p?.message??i(g.COMMON$FAILED_TO_LOAD)}),!d&&!f&&y.length===0&&(0,V.jsx)(`li`,{className:`px-4 py-2 text-sm text-[var(--oh-text-secondary)]`,"data-testid":D?`folder-browser-host-home-hint`:`folder-browser-empty`,children:i(D?g.HOME$HOST_HOME_NOT_MOUNTED_HINT:g.HOME$NO_WORKSPACES)}),y.map(e=>(0,V.jsx)(`li`,{children:(0,V.jsxs)(`button`,{type:`button`,onClick:()=>s(e.path),className:`grid grid-cols-[1fr_120px] items-center w-full text-left px-4 py-1.5 text-sm text-white hover:bg-[var(--oh-interactive-hover)] cursor-pointer`,"data-testid":`folder-browser-entry-${e.name}`,children:[(0,V.jsxs)(`span`,{className:`flex items-center gap-2 min-w-0`,children:[(0,V.jsx)(k,{width:16,height:16,className:`shrink-0`}),(0,V.jsx)(`span`,{className:`truncate`,children:e.name})]}),(0,V.jsx)(`span`,{className:`text-[var(--oh-text-secondary)] text-xs`,children:i(g.HOME$FOLDER)})]})},e.path))]})]})]}),(0,V.jsxs)(`div`,{className:`flex items-center justify-end gap-2 px-5 py-3 border-t border-[var(--oh-border-input)]`,children:[(0,V.jsx)(T,{type:`button`,variant:`secondary`,onClick:t,testId:`folder-browser-cancel`,children:i(g.HOME$CANCEL)}),r&&(0,V.jsx)(T,{type:`button`,variant:`secondary`,onClick:()=>{!o||!r||(r([{id:o,name:O(o),path:o}]),t())},isDisabled:!o||d,testId:`folder-browser-add-all-subdirs`,children:i(g.HOME$ADD_ALL_SUBDIRECTORIES)}),(0,V.jsx)(T,{type:`button`,variant:`primary`,onClick:()=>{o&&(n([{id:o,name:O(o),path:o}]),t())},isDisabled:!o||d,testId:`folder-browser-use`,children:i(g.HOME$ADD_THIS_DIRECTORY)})]})]})})}function oe({isOpen:e,workspaces:t,workspaceParents:n=[],onClose:r,onRemove:i,onRemoveParent:o}){let{t:s}=a(`openhands`),[c,l]=M.useState(null);if(!e)return null;let u=t.filter(e=>!e.parentPath),d=new Map;t.forEach(e=>{if(!e.parentPath)return;let t=d.get(e.parentPath)??[];t.push(e),d.set(e.parentPath,t)});let f=u.length>0||n.length>0;return(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(b,{onClose:r,"aria-label":s(g.HOME$MANAGE_WORKSPACES),children:(0,V.jsxs)(`div`,{"data-testid":`manage-workspaces-modal`,className:_(`flex flex-col bg-[var(--oh-surface)] border border-[var(--oh-border-input)] rounded-xl`,x(`lg`),S,`max-h-[70vh]`),children:[(0,V.jsx)(`div`,{className:`flex items-center justify-between px-5 py-3 border-b border-[var(--oh-border-input)]`,children:(0,V.jsx)(C,{className:w,title:s(g.HOME$MANAGE_WORKSPACES)})}),(0,V.jsxs)(`div`,{className:`flex-1 overflow-auto custom-scrollbar-always`,"data-testid":`manage-workspaces-list`,children:[!f&&(0,V.jsx)(`p`,{className:`px-5 py-6 text-sm text-[var(--oh-text-secondary)] text-center`,children:s(g.HOME$MANAGE_WORKSPACES_EMPTY)}),u.length>0&&(0,V.jsx)(`ul`,{children:u.map(e=>(0,V.jsxs)(`li`,{className:`flex items-center gap-3 px-5 py-2 border-b border-[var(--oh-border-subtle)] last:border-b-0`,"data-testid":`manage-workspaces-row-${e.name}`,children:[(0,V.jsx)(k,{width:16,height:16,className:`shrink-0`}),(0,V.jsxs)(`div`,{className:`flex flex-col min-w-0 flex-1`,children:[(0,V.jsx)(`span`,{className:`text-sm text-white truncate`,children:e.name}),(0,V.jsx)(`span`,{className:`text-xs text-[var(--oh-muted)] truncate`,children:e.path})]}),(0,V.jsxs)(`button`,{type:`button`,onClick:()=>l({type:`workspace`,path:e.path,text:s(g.HOME$REMOVE_WORKSPACE_CONFIRMATION,{name:e.name})}),"aria-label":s(g.HOME$REMOVE_WORKSPACE),"data-testid":`manage-workspaces-remove-${e.name}`,className:`flex items-center gap-1 px-2 py-1 rounded text-xs text-[var(--oh-text-tertiary)] hover:bg-[var(--oh-interactive-hover)] hover:text-white cursor-pointer`,children:[(0,V.jsx)(A,{width:12,height:12}),(0,V.jsx)(`span`,{children:s(g.HOME$REMOVE_WORKSPACE)})]})]},e.id))}),n.length>0&&(0,V.jsxs)(`div`,{"data-testid":`manage-workspaces-parents-section`,children:[(0,V.jsx)(`div`,{className:`px-5 pt-3 pb-1 text-[11px] uppercase tracking-wide text-[var(--oh-muted)] font-semibold`,children:s(g.HOME$WORKSPACE_PARENTS)}),(0,V.jsx)(`ul`,{children:n.map(e=>{let t=d.get(e.path)??[];return(0,V.jsxs)(`li`,{className:`border-b border-[var(--oh-border-subtle)] last:border-b-0`,"data-testid":`manage-workspaces-parent-row-${e.name}`,children:[(0,V.jsxs)(`div`,{className:`flex items-center gap-3 px-5 py-2`,children:[(0,V.jsx)(k,{width:16,height:16,className:`shrink-0`}),(0,V.jsxs)(`div`,{className:`flex flex-col min-w-0 flex-1`,children:[(0,V.jsx)(`span`,{className:`text-sm text-white truncate`,children:e.name}),(0,V.jsx)(`span`,{className:`text-xs text-[var(--oh-muted)] truncate`,children:e.path})]}),o&&(0,V.jsxs)(`button`,{type:`button`,onClick:()=>l({type:`parent`,path:e.path,text:s(g.HOME$REMOVE_WORKSPACE_PARENT_CONFIRMATION,{name:e.name,count:t.length})}),"aria-label":s(g.HOME$REMOVE_WORKSPACE_PARENT),"data-testid":`manage-workspaces-remove-parent-${e.name}`,className:`flex items-center gap-1 px-2 py-1 rounded text-xs text-[var(--oh-text-tertiary)] hover:bg-[var(--oh-interactive-hover)] hover:text-white cursor-pointer`,children:[(0,V.jsx)(A,{width:12,height:12}),(0,V.jsx)(`span`,{children:s(g.HOME$REMOVE_WORKSPACE_PARENT)})]})]}),t.length>0&&(0,V.jsx)(`ul`,{className:`pb-2`,children:t.map(e=>(0,V.jsxs)(`li`,{className:`flex items-center gap-3 px-5 pl-10 py-1 text-xs text-[var(--oh-text-secondary)]`,"data-testid":`manage-workspaces-child-${e.name}`,children:[(0,V.jsx)(k,{width:12,height:12,className:`shrink-0 opacity-70`}),(0,V.jsx)(`span`,{className:`truncate`,children:e.name})]},e.id))})]},e.id)})})]})]}),(0,V.jsx)(`div`,{className:`flex justify-end gap-2 px-5 py-3 border-t border-[var(--oh-border-input)]`,children:(0,V.jsx)(T,{type:`button`,variant:`primary`,onClick:r,testId:`manage-workspaces-done`,children:s(g.HOME$DONE)})})]})}),c&&(0,V.jsx)(D,{text:c.text,onConfirm:()=>{c&&(c.type===`workspace`?i(c.path):o?.(c.path),l(null))},onCancel:()=>l(null)})]})}var se=`previewOnboardingStep`,ce=3;function Q(e=typeof window<`u`?window.location.search:``){let t=new URLSearchParams(e).get(se);if(t==null)return null;let n=Number.parseInt(t,10);return!Number.isFinite(n)||n<0||n>ce?null:n}function $(e=typeof window<`u`?window.location.search:``){return Q(e)!=null}function le(e){let t=e?.agent_settings?.llm,n=typeof t?.model==`string`&&t.model.trim().length>0,r=e?.llm_api_key_set===!0||O(t);return n&&r}function ue(){let e=r(),t=Q(e.search),n=$(e.search),{isCompleted:i,markCompleted:a}=v(),{backend:o}=m(),s=y(),c=o.kind===`cloud`||o.id!==`default-local`;return!n&&(i||c&&s.isLoading||c&&le(s.data))?null:(0,V.jsx)(ee,{onClose:()=>{n||a()},initialStep:t??0,isPreview:n})}export{W as a,ie as c,te as d,I as f,ae as i,U as l,$ as n,H as o,j as p,oe as r,re as s,ue as t,ne as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e,r as t}from"./rolldown-runtime-Cyuzqnbw.js";import{St as n,yt as r}from"./vendor-styling-Ck5D_A2Q.js";import{t as i}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{i as a,t as o}from"./recommended-automations-launcher-6ABrI9Cy.js";import{Dt as s,Et as c,Ft as l,It as u,St as d,_t as f,kt as p,mt as m,n as h,r as g,zt as _}from"./active-backend-context-CrHTlgvN.js";import{W as v,t as y}from"./utils-CN5ZfZy1.js";import{c as b}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-CUmIwQCN.js";import{t as x}from"./chat-send-button-MUQqCZCS.js";import{t as S}from"./check-CS0vmpQQ.js";import{t as C}from"./circle-check-DzWLNsbE.js";import{a as w,i as T,n as E,r as D,t as O}from"./use-acp-credential-form-XIQmpX6M.js";import{t as k}from"./loader-circle-CC1au6hc.js";import{c as A,s as j,t as M}from"./backend-form-modal-lhGwzXFI.js";import{a as N,r as P,t as F}from"./llm-settings-De1d5dfr.js";import{o as I}from"./use-onboarding-completion-D8U7k4Qb.js";import{t as L}from"./use-tracking-D53y3TH9.js";import{n as ee}from"./use-settings-DSXLbvBl.js";import{t as R}from"./use-save-settings-DYqkKv7T.js";import{t as te}from"./modal-backdrop-BSzNhM4r.js";import{r as ne,t as re}from"./modal-body-BxZjsju9.js";import{t as z}from"./brand-button-BAfk4wGP.js";import{n as B}from"./navigation-context-CQZwH_tC.js";import{t as V}from"./openhands-logo-BS-Epajy.js";import{c as H,i as U,n as W,o as G}from"./acp-providers-CX3Lh9gj.js";import{n as ie,r as ae}from"./use-agent-profiles-Bd9Bvvp1.js";import{n as oe}from"./use-create-conversation-Dx3l7mFZ.js";import{t as se}from"./terminal-BUpID2wS.js";import{c as ce,r as le}from"./sidebar-onboarding-checklist-storage-BBkeI6Bp.js";import{a as ue}from"./badge-BU3S0VtE.js";import{t as de}from"./use-save-agent-profile-BUjSsDXK.js";import{n as fe}from"./use-activate-agent-profile-BLfmvDiG.js";var K=e(n(),1),q=r(),pe=`m19.6 66.5 19.7-11 .3-1-.3-.5h-1l-3.3-.2-11.2-.3L14 53l-9.5-.5-2.4-.5L0 49l.2-1.5 2-1.3 2.9.2 6.3.5 9.5.6 6.9.4L38 49.1h1.6l.2-.7-.5-.4-.4-.4L29 41l-10.6-7-5.6-4.1-3-2-1.5-2-.6-4.2 2.7-3 3.7.3.9.2 3.7 2.9 8 6.1L37 36l1.5 1.2.6-.4.1-.3-.7-1.1L33 25l-6-10.4-2.7-4.3-.7-2.6c-.3-1-.4-2-.4-3l3-4.2L28 0l4.2.6L33.8 2l2.6 6 4.1 9.3L47 29.9l2 3.8 1 3.4.3 1h.7v-.5l.5-7.2 1-8.7 1-11.2.3-3.2 1.6-3.8 3-2L61 2.6l2 2.9-.3 1.8-1.1 7.7L59 27.1l-1.5 8.2h.9l1-1.1 4.1-5.4 6.9-8.6 3-3.5L77 13l2.3-1.8h4.3l3.1 4.7-1.4 4.9-4.4 5.6-3.7 4.7-5.3 7.1-3.2 5.7.3.4h.7l12-2.6 6.4-1.1 7.6-1.3 3.5 1.6.4 1.6-1.4 3.4-8.2 2-9.6 2-14.3 3.3-.2.1.2.3 6.4.6 2.8.2h6.8l12.6 1 3.3 2 1.9 2.7-.3 2-5.1 2.6-6.8-1.6-16-3.8-5.4-1.3h-.8v.4l4.6 4.5 8.3 7.5L89 80.1l.5 2.4-1.3 2-1.4-.2-9.2-7-3.6-3-8-6.8h-.5v.7l1.8 2.7 9.8 14.7.5 4.5-.7 1.4-2.6 1-2.7-.6-5.8-8-6-9-4.7-8.2-.5.4-2.9 30.2-1.3 1.5-3 1.2-2.5-2-1.4-3 1.4-6.2 1.6-8 1.3-6.4 1.2-7.9.7-2.6v-.2H49L43 72l-9 12.3-7.2 7.6-1.7.7-3-1.5.3-2.8L24 86l10-12.8 6-7.9 4-4.6-.1-.5h-.3L17.2 77.4l-4.7.6-2-2 .2-3 1-1 8-5.5Z`,me=`0 0 100 100`,he=`M4.04286 0.228393C4.52451 0.0304495 5.0488 -0.0409817 5.56586 0.0208928C6.23236 0.0973928 6.82636 0.380893 7.34786 0.870893C7.35488 0.877545 7.36344 0.882351 7.37278 0.884881C7.38212 0.887412 7.39194 0.887588 7.40136 0.885393C8.10536 0.712393 8.78236 0.773393 9.43186 1.06839L9.46336 1.08339L9.54036 1.12139C10.2189 1.47289 10.7054 2.00639 10.9994 2.72039C11.1384 3.05989 11.2084 3.41439 11.2099 3.78339C11.2197 4.05816 11.1893 4.33288 11.1199 4.59889C11.1164 4.61245 11.1165 4.62665 11.12 4.6402C11.1235 4.65374 11.1303 4.66618 11.1399 4.67639C11.5329 5.0749 11.8063 5.57572 11.9289 6.12189C12.1214 7.07239 11.9239 7.92939 11.3374 8.69189L11.2464 8.80189C10.8579 9.24669 10.3481 9.56836 9.77936 9.72739C9.76694 9.73097 9.75556 9.73747 9.74617 9.74634C9.73677 9.75521 9.72964 9.7662 9.72536 9.77839C9.59786 10.1464 9.46986 10.4604 9.23186 10.7744C8.63236 11.5654 7.75086 12.0054 6.75786 11.9999C5.96636 11.9959 5.26486 11.7064 4.65286 11.1319C4.64358 11.1234 4.63225 11.1174 4.61998 11.1146C4.6077 11.1118 4.59491 11.1123 4.58286 11.1159C4.32386 11.1994 4.06286 11.2114 3.78086 11.2084C3.33033 11.2048 2.88658 11.0984 2.48336 10.8974C2.0613 10.688 1.6939 10.3831 1.41036 10.0069C1.30886 9.87239 1.20836 9.74589 1.13486 9.59639C1.03349 9.39033 0.95066 9.17565 0.887357 8.95489C0.754446 8.45324 0.751521 7.92599 0.878857 7.42289C0.882974 7.41102 0.884341 7.39837 0.882857 7.38589C0.88038 7.37348 0.873877 7.36223 0.864357 7.35389C0.556147 7.04213 0.320543 6.66619 0.174357 6.25289C0.0775698 5.99842 0.0213841 5.73031 0.00785682 5.45839C-0.0163229 5.10033 0.0153902 4.74069 0.101857 4.39239C0.326857 3.65039 0.756357 3.06839 1.39036 2.64589C1.53136 2.55189 1.66536 2.47889 1.79136 2.42689C1.93436 2.36689 2.07786 2.31689 2.22186 2.27489C2.23216 2.27184 2.24153 2.26626 2.24913 2.25866C2.25672 2.25107 2.2623 2.24169 2.26536 2.23139C2.37455 1.83888 2.56235 1.47264 2.81736 1.15489C3.15736 0.731893 3.56586 0.422893 4.04286 0.228393ZM3.64086 4.15339C3.58503 4.05573 3.49269 3.98424 3.38415 3.95465C3.27562 3.92507 3.15977 3.93981 3.06211 3.99564C2.96444 4.05147 2.89295 4.14381 2.86337 4.25235C2.83378 4.36088 2.84853 4.47673 2.90436 4.57439L3.75136 6.05689L2.90736 7.48089C2.85561 7.57738 2.84315 7.69014 2.87257 7.7956C2.902 7.90106 2.97104 7.99108 3.06526 8.04684C3.15949 8.1026 3.27162 8.1198 3.37823 8.09484C3.48484 8.06988 3.57768 8.00469 3.63736 7.91289L4.60736 6.27689C4.64561 6.21237 4.66609 6.13887 4.66671 6.06386C4.66732 5.98886 4.64805 5.91503 4.61086 5.84989L3.64086 4.15339ZM6.36386 7.27339C6.25583 7.27982 6.15434 7.32727 6.08012 7.40603C6.00591 7.48479 5.96458 7.58892 5.96458 7.69714C5.96458 7.80536 6.00591 7.90949 6.08012 7.98826C6.15434 8.06702 6.25583 8.11446 6.36386 8.12089H8.78786C8.89675 8.1156 8.99943 8.06862 9.07462 7.98969C9.14982 7.91075 9.19176 7.80591 9.19176 7.69689C9.19176 7.58787 9.14982 7.48303 9.07462 7.4041C8.99943 7.32516 8.89675 7.27818 8.78786 7.27289H6.36386V7.27339Z`,ge=`0 0 12 12`,_e=`M12 0C12.904 6.056 17.944 11.096 24 12C17.944 12.904 12.904 17.944 12 24C11.096 17.944 6.056 12.904 0 12C6.056 11.096 11.096 6.056 12 0Z`,ve=`0 0 24 24`,ye=3/2;function J({kind:e,size:t=12,className:n,"data-testid":r}){return e===`openhands`?(0,q.jsx)(V,{width:Math.round(t*ye),height:t,className:y(`shrink-0 [&_path:not([fill=transparent])]:fill-current`,n),"data-testid":r??`agent-brand-icon-openhands`,"aria-hidden":!0}):e===`claude-code`?(0,q.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:me,width:t,height:t,className:y(`shrink-0`,n),"data-testid":r??`agent-brand-icon-claude-code`,"aria-hidden":!0,children:(0,q.jsx)(`path`,{fill:`currentColor`,d:pe})}):e===`codex`?(0,q.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:ge,width:t,height:t,className:y(`shrink-0`,n),"data-testid":r??`agent-brand-icon-codex`,"aria-hidden":!0,children:(0,q.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:he,fill:`currentColor`})}):e===`gemini`?(0,q.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:ve,width:t,height:t,className:y(`shrink-0`,n),"data-testid":r??`agent-brand-icon-gemini`,"aria-hidden":!0,children:(0,q.jsx)(`path`,{fill:`currentColor`,d:_e})}):(0,q.jsx)(se,{width:t,height:t,className:y(`shrink-0`,n),"data-testid":r??`agent-brand-icon-generic`,"aria-hidden":!0})}function be({currentStep:e,totalSteps:t,className:n}){return(0,q.jsx)(`div`,{role:`progressbar`,"aria-valuemin":1,"aria-valuemax":t,"aria-valuenow":e+1,"data-testid":`onboarding-progress-bar`,className:y(`flex w-full items-center gap-2`,n),children:Array.from({length:t},(t,n)=>{let r=n<e,i=n===e;return(0,q.jsx)(`div`,{"data-testid":`onboarding-progress-step-${n}`,"data-state":r?`completed`:i?`current`:`upcoming`,className:y(`h-1.5 flex-1 rounded-full transition-colors duration-300`,r||i?`bg-white`:`bg-white/15`)},n)})})}function xe(e){return e===`openhands`?`openhands`:W.find(({key:t})=>t===e)?.icon??`cli-generic`}function Se({id:e,muted:t}){let n=xe(e);return n===`openhands`?(0,q.jsx)(J,{kind:`openhands`,size:16,className:y(`text-white`,t&&`opacity-55`),"data-testid":`onboarding-agent-icon-openhands`}):(0,q.jsx)(J,{kind:n,size:18,className:t?`text-[var(--oh-muted)]`:`text-white`,"data-testid":`onboarding-agent-icon-${n}`})}function Ce(){return[{id:`openhands`,label:`OpenHands`,descriptionKey:v.ONBOARDING$AGENT_OPENHANDS_DESCRIPTION},...W.map(e=>({id:e.key,label:e.display_name,descriptionKey:e.description_key}))]}function we({selectedAgentId:e,onSelect:t,onBack:n,onNext:r}){let{t:a}=i(`openhands`),{mutate:o,isPending:s}=R();return(0,q.jsxs)(`div`,{"data-testid":`onboarding-step-choose-agent`,className:`flex flex-col gap-6`,children:[(0,q.jsxs)(`header`,{className:`flex flex-col gap-2`,children:[(0,q.jsx)(`h2`,{className:`text-2xl font-medium text-white`,children:a(v.ONBOARDING$AGENT_TITLE)}),(0,q.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:a(v.ONBOARDING$AGENT_SUBTITLE)})]}),(0,q.jsx)(`div`,{role:`radiogroup`,"aria-label":a(v.ONBOARDING$AGENT_TITLE),className:`flex flex-col gap-3`,children:Ce().map(n=>{let r=n.id===e;return(0,q.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":r,"data-testid":`onboarding-agent-option-${n.id}`,"data-selected":r,onClick:()=>t(n.id),className:y(`flex items-start justify-between gap-4 rounded-xl border px-4 py-3 text-left transition-colors cursor-pointer`,r?`border-white/45 bg-white/[0.09] shadow-none hover:border-white/45 hover:bg-white/[0.09]`:`border-white/30 bg-white/5 hover:border-white/40 hover:bg-white/[0.08]`),children:[(0,q.jsxs)(`div`,{className:`flex min-w-0 flex-1 flex-col gap-1`,children:[(0,q.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[(0,q.jsx)(Se,{id:n.id,muted:!1}),(0,q.jsx)(`span`,{className:`truncate text-base font-normal text-white`,children:n.label})]}),(0,q.jsx)(`span`,{className:`text-xs text-[var(--oh-muted)]`,children:a(n.descriptionKey)})]}),(0,q.jsx)(`div`,{className:`flex shrink-0 flex-col items-end gap-1`,children:r?(0,q.jsx)(S,{width:18,height:18,className:`mt-1 shrink-0 text-white`,"aria-hidden":!0}):null})]},n.id)})}),(0,q.jsxs)(`div`,{className:y(`sticky bottom-0 flex items-center gap-2 bg-base-secondary pt-4 pb-7`,n?`justify-between`:`justify-end`),children:[n?(0,q.jsx)(z,{testId:`onboarding-agent-back`,type:`button`,variant:`secondary`,onClick:n,isDisabled:s,children:a(v.ONBOARDING$BACK)}):null,(0,q.jsx)(z,{testId:`onboarding-agent-next`,type:`button`,variant:`primary`,isDisabled:s,onClick:()=>{let t=U(e);if(!t){r();return}o({agent_settings_diff:t},{onError:e=>{l(_(e)||a(v.ERROR$GENERIC))},onSuccess:()=>{u(a(v.SETTINGS$SAVED)),r()}})},children:a(s?v.SETTINGS$SAVING:v.ONBOARDING$NEXT)})]})]})}function Te({backend:e,isConnected:t,lastError:n}){let{t:r}=i(`openhands`);if(t===!0)return(0,q.jsxs)(`div`,{role:`status`,"data-testid":`onboarding-backend-connected`,className:y(`flex items-start gap-3 rounded-xl border border-green-500/40 bg-green-500/10 px-4 py-3`),children:[(0,q.jsx)(C,{className:`mt-0.5 size-5 shrink-0 text-green-400`}),(0,q.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,q.jsx)(`span`,{className:`text-sm font-medium text-green-200`,children:r(v.ONBOARDING$BACKEND_CONNECTED_TITLE)}),(0,q.jsx)(`span`,{className:`text-xs text-green-200/80`,children:r(v.ONBOARDING$BACKEND_CONNECTED_BODY)})]})]});if(t===!1){let i=j(r,e,{isConnected:t,lastError:n});return(0,q.jsxs)(`div`,{role:`alert`,"data-testid":`onboarding-backend-disconnected`,className:`flex items-start gap-3 rounded-xl border border-red-500/40 bg-red-500/10 px-4 py-3`,children:[(0,q.jsx)(b,{className:`mt-0.5 size-5 shrink-0 text-red-400`}),(0,q.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,q.jsx)(`span`,{className:`text-sm font-medium text-red-200`,children:i}),(0,q.jsx)(`span`,{className:`text-xs text-red-200/80`,children:r(v.ONBOARDING$BACKEND_DISCONNECTED_BODY)})]})]})}return(0,q.jsxs)(`div`,{role:`status`,"data-testid":`onboarding-backend-checking`,className:`flex items-start gap-3 rounded-xl border border-white/10 bg-white/5 px-4 py-3`,children:[(0,q.jsx)(k,{className:`mt-0.5 size-5 shrink-0 animate-spin text-[var(--oh-text-tertiary)]`}),(0,q.jsx)(`span`,{className:`text-sm text-[var(--oh-text-tertiary)]`,children:r(v.ONBOARDING$BACKEND_CHECKING)})]})}function Ee({onBack:e,onNext:t,onClose:n}){let{t:r}=i(`openhands`),{active:a,addBackend:o,setActive:l,updateBackend:u}=g(),{trackBackendAdded:h}=L(),{backend:_}=a,b=m(_),x=c(),S=x!==null&&!b&&!(_.kind===`cloud`&&p(_.host,x)),C=b||S,w=K.useMemo(()=>d(),[]),T=C?{id:`onboarding-local-backend-draft`,name:f,host:w.baseUrl,apiKey:w.sessionApiKey,kind:`local`}:_,E=I(b?[]:[_]),D=C?null:E[_.id]?.isConnected??null,O=C?null:E[_.id]?.lastError??null,[k,j]=K.useState(!1);K.useEffect(()=>{D===!0&&j(!1)},[D]);let N=D===!0&&!k,P=K.useCallback((e,r)=>{if(b)o(e);else{let t=e.host!==_.host;u(_.id,e),t&&a.orgId!==null&&l(_.id,null)}h({backendKind:e.kind,connectionMethod:r,hasApiKey:!!e.apiKey,source:`onboarding`}),x!==null&&e.kind===`cloud`&&n?n():t()},[a.orgId,o,_.host,_.id,x,b,n,t,l,h,u]),F=y(`sticky bottom-0 mt-2 flex items-center gap-2 bg-base-secondary pt-4 pb-7`,e?`justify-between`:`justify-end`);return(0,q.jsxs)(`div`,{"data-testid":`onboarding-step-check-backend`,className:`flex flex-col gap-6`,children:[(0,q.jsxs)(`header`,{className:`flex flex-col gap-2`,children:[(0,q.jsx)(`h2`,{className:`text-2xl font-medium text-white`,children:r(C?x?v.ONBOARDING$LOGIN_TO_CLOUD_TITLE:v.BACKEND$ADD_TITLE:v.ONBOARDING$BACKEND_TITLE)}),C?null:(0,q.jsx)(`p`,{"data-testid":`onboarding-backend-subtitle`,className:`text-sm text-[var(--oh-muted)]`,children:r(v.ONBOARDING$BACKEND_SUBTITLE)})]}),C?null:(0,q.jsx)(Te,{backend:T,isConnected:D,lastError:O}),D===!0?(0,q.jsxs)(`button`,{type:`button`,onClick:()=>j(e=>!e),"aria-expanded":k,"data-testid":`onboarding-backend-show-configuration`,className:`flex w-full cursor-pointer items-center justify-center gap-1 text-center text-xs text-[var(--oh-muted)] transition-colors hover:text-content-2`,children:[(0,q.jsx)(`span`,{children:r(k?v.ONBOARDING$BACKEND_HIDE_CONFIGURATION:v.ONBOARDING$BACKEND_SHOW_CONFIGURATION)}),(0,q.jsx)(A,{className:y(`h-4 w-4 shrink-0 text-muted transition-transform`,k&&`rotate-180`),"aria-hidden":!0})]}):null,(0,q.jsx)(`div`,{"data-testid":`onboarding-backend-configuration-fields`,children:N?null:(0,q.jsx)(M,{onConnected:P,testIdRoot:`onboarding-backend`,initialManualBackend:T,requireManualApiKey:s(),manualSubmitLabel:r(v.ONBOARDING$NEXT),manualSubmittingLabel:r(v.SETTINGS$SAVING),manualSubmitTestId:`onboarding-backend-next`,analyticsSource:`onboarding`})}),N?(0,q.jsxs)(`div`,{className:F,children:[e?(0,q.jsx)(z,{testId:`onboarding-backend-back`,type:`button`,variant:`secondary`,onClick:e,children:r(v.ONBOARDING$BACK)}):null,(0,q.jsx)(z,{testId:`onboarding-backend-next`,type:`button`,variant:`primary`,onClick:t,children:r(v.ONBOARDING$NEXT)})]}):null]})}var Y=ae;function X(){let e=de(),t=fe();return(0,K.useCallback)(async n=>{try{await e.mutateAsync({name:Y,profile:n});let r=(await ie.getProfile(Y)).profile.id;r&&await t.mutateAsync(r)}catch(e){console.error(`Failed to configure onboarding agent profile:`,e)}},[e,t])}var De=`openai/gpt-5.6-sol`;function Oe({onBack:e,onNext:t}){let{t:n}=i(`openhands`),{backend:r}=h(),a=r.kind===`local`,o=P(),s=N(),c=X(),[l,u]=K.useState(null),[d,f]=K.useState(!1),p=K.useCallback(async()=>{if(!a||!l)return null;let e=l.values,t=typeof e[`llm.model`]==`string`?e[`llm.model`]:``;if(!t)return null;let n=typeof e[`llm.api_key`]==`string`?e[`llm.api_key`]:``,r=typeof e[`llm.base_url`]==`string`?e[`llm.base_url`]:``,i=ue(t),c={model:t};n&&(c.api_key=n),r&&(c.base_url=r);try{return await o.mutateAsync({name:i,request:{llm:c,include_secrets:!0}}),await s.mutateAsync(i),i}catch(e){return console.error(`Failed to persist onboarding LLM as profile:`,e),null}},[a,l,o,s]),m=K.useCallback(async()=>{f(!0);try{let e=await p();e&&await c({agent_kind:`openhands`,llm_profile_ref:e})}finally{f(!1),t()}},[p,c,t]);return(0,q.jsxs)(`div`,{"data-testid":`onboarding-step-setup-llm`,className:`flex flex-col gap-6 max-h-[calc(90vh-7rem)]`,children:[(0,q.jsxs)(`header`,{className:`flex flex-col gap-2`,children:[(0,q.jsx)(`h2`,{className:`text-2xl font-medium text-white`,children:n(v.ONBOARDING$LLM_TITLE)}),(0,q.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:n(v.ONBOARDING$LLM_SUBTITLE)})]}),(0,q.jsx)(`div`,{"data-testid":`onboarding-llm-settings`,className:`flex min-h-0 flex-1 flex-col overflow-y-auto custom-scrollbar-always`,children:(0,q.jsx)(F,{embedded:!0,hideSaveButton:!0,suppressSuccessToast:!0,initialValueOverrides:{"llm.model":De},onSaveSuccess:m,onSaveControlChange:u})}),(0,q.jsxs)(`div`,{className:`sticky bottom-0 flex items-center justify-between gap-2 bg-base-secondary pt-4 pb-7`,children:[(0,q.jsx)(z,{testId:`onboarding-llm-back`,type:`button`,variant:`secondary`,onClick:e,children:n(v.ONBOARDING$BACK)}),(0,q.jsx)(z,{testId:`onboarding-llm-next`,type:`button`,variant:`primary`,isDisabled:(l?.isSaving??!1)||d,onClick:()=>{if(l?.isDirty){l.save();return}t()},children:n(v.ONBOARDING$NEXT)})]})]})}function ke({providerKey:e,isActive:t,onBack:n,onNext:r}){let{t:a}=i(`openhands`),o=h(),{status:s,isChecking:c}=E(e,{enabled:t}),{fields:l,values:u,setValue:d,secretExists:f,hasValueFor:p,conflicts:m,credentialsConfigured:g,consumesFileCredentials:_,save:y,isSaving:b}=O(e),x=X(),S=H(e)??e,C=s===`authenticated`,k=Ae(o.backend.kind,s),A=C||l.some(e=>e.secret&&(!e.multiline||_)&&p(e.name)),j=k&&!A,M=b||j||c&&!A;return(0,q.jsxs)(`div`,{"data-testid":`onboarding-step-setup-acp-secrets`,className:`flex flex-col gap-6`,children:[(0,q.jsxs)(`header`,{className:`flex flex-col gap-2`,children:[(0,q.jsx)(`h2`,{className:`text-2xl font-medium text-white`,children:a(v.ONBOARDING$ACP_SECRETS_TITLE)}),(0,q.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:a(v.ONBOARDING$ACP_SECRETS_SUBTITLE,{provider:S})}),k&&!C?(0,q.jsx)(`p`,{"data-testid":`onboarding-acp-secrets-required-note`,className:`text-sm text-[var(--oh-muted)]`,children:a(v.ONBOARDING$ACP_SECRETS_REQUIRED_NOTE,{provider:S})}):s!==`authenticated`&&(0,q.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:a(v.ONBOARDING$ACP_SECRETS_SUBSCRIPTION_NOTE)})]}),(0,q.jsx)(T,{status:s,isChecking:c,credentialsConfigured:g,providerName:S,testIdPrefix:`onboarding-acp-auth`}),(0,q.jsx)(`div`,{className:`flex flex-col gap-5`,children:l.map(e=>(0,q.jsx)(D,{field:e,value:u[e.name]??``,onChange:t=>d(e.name,t),alreadySet:f(e.name),testId:`onboarding-acp-secret-${e.name}`,showOptionalTag:!0},e.name))}),(0,q.jsx)(w,{conflicts:m}),j?(0,q.jsx)(`p`,{"data-testid":`onboarding-acp-secrets-blocked`,className:`text-sm text-amber-300`,children:a(v.ONBOARDING$ACP_SECRETS_REQUIRED_BLOCKED)}):null,(0,q.jsxs)(`div`,{className:`sticky bottom-0 flex items-center justify-between gap-2 bg-base-secondary pt-4 pb-7`,children:[(0,q.jsx)(z,{testId:`onboarding-acp-secrets-back`,type:`button`,variant:`secondary`,onClick:n,isDisabled:b,children:a(v.ONBOARDING$BACK)}),(0,q.jsx)(z,{testId:`onboarding-acp-secrets-next`,type:`button`,variant:`primary`,isDisabled:M,onClick:async()=>{await y()&&(e!==`openhands`&&await x({agent_kind:`acp`,acp_server:e,acp_model:G(e)??void 0}),r())},children:a(b?v.SETTINGS$SAVING:v.ONBOARDING$NEXT)})]})]})}function Ae(e,t){return t===`authenticated`?!1:e===`cloud`?!0:t===`unauthenticated`}function je({onBack:e,onClose:t,onLaunched:n}){let{t:r}=i(`openhands`),{navigate:s}=B(),{backend:c}=h(),l=c.kind!==`cloud`,u=r(v.ONBOARDING$HELLO_DEFAULT_MESSAGE),[d,f]=K.useState(u),{mutate:p,isPending:m,isSuccess:g}=oe(),_=a(),y=m||g||_,b=K.useRef(!1),S=d.trim().length>0&&!y&&!b.current,C=()=>{!S||b.current||(b.current=!0,p({query:d.trim(),entryPoint:`onboarding_say_hello`},{onSuccess:e=>{s(`/conversations/${e.conversation_id}`),n()},onError:()=>{b.current=!1}}))};return(0,q.jsxs)(`div`,{"data-testid":`onboarding-step-say-hello`,className:`flex max-h-[calc(90vh-7rem)] flex-col`,children:[(0,q.jsxs)(`header`,{className:`flex shrink-0 flex-col gap-2`,children:[(0,q.jsx)(`h2`,{className:`text-2xl font-medium text-white`,children:r(v.ONBOARDING$HELLO_TITLE)}),(0,q.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:r(v.ONBOARDING$HELLO_SUBTITLE)})]}),(0,q.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),C()},"data-testid":`onboarding-hello-input-form`,className:`mt-6 box-border flex w-full shrink-0 flex-col items-start justify-center rounded-[15px] border border-[var(--oh-border)] bg-surface-raised p-4`,children:[(0,q.jsx)(`div`,{className:`relative w-full`,children:(0,q.jsx)(`div`,{className:`box-border flex w-full shrink-0 flex-row items-end justify-between gap-2 p-0 pb-[18px]`,children:(0,q.jsx)(`input`,{"data-testid":`onboarding-hello-input`,"aria-label":r(v.ONBOARDING$HELLO_TITLE),type:`text`,value:d,onChange:e=>f(e.target.value),onKeyDown:e=>{e.key===`Enter`&&!e.shiftKey&&(e.preventDefault(),C())},placeholder:u,disabled:y,className:`min-h-[20px] w-full flex-1 bg-transparent text-[16px] font-normal leading-[20px] text-white outline-none placeholder:text-[var(--oh-text-tertiary)] disabled:cursor-not-allowed disabled:opacity-50`})})}),(0,q.jsx)(`div`,{className:`flex w-full min-w-0 items-center justify-end gap-2`,children:(0,q.jsx)(x,{buttonClassName:``,handleSubmit:C,disabled:!S})})]}),l?(0,q.jsxs)(q.Fragment,{children:[(0,q.jsxs)(`div`,{"data-testid":`onboarding-hello-or-separator`,className:`mt-6 flex w-full items-center gap-3`,children:[(0,q.jsx)(`div`,{className:`h-px flex-1 bg-[var(--oh-border)]`}),(0,q.jsx)(`span`,{className:`text-xs uppercase text-[var(--oh-muted)]`,children:r(v.LANDING$OR)}),(0,q.jsx)(`div`,{className:`h-px flex-1 bg-[var(--oh-border)]`})]}),(0,q.jsx)(`div`,{"data-testid":`onboarding-recommended-automations`,className:`flex min-h-0 flex-1 flex-col`,children:(0,q.jsx)(o,{onLaunched:n,scrollableGrid:!0})})]}):null,(0,q.jsxs)(`div`,{className:`flex shrink-0 items-center justify-between gap-2 bg-base-secondary pt-7 pb-7`,children:[(0,q.jsx)(z,{testId:`onboarding-hello-back`,type:`button`,variant:`secondary`,onClick:e,isDisabled:y,children:r(v.ONBOARDING$BACK)}),(0,q.jsx)(z,{testId:`onboarding-hello-close`,type:`button`,variant:`secondary`,onClick:t,isDisabled:y,children:r(v.BUTTON$CLOSE)})]})]})}var Me=t({OnboardingModal:()=>$}),Z=[`backend`,`agent`,`setup`,`hello`],Ne=[`agent`,`setup`,`hello`],Pe=`openhands-onboarding-started`;function Q({index:e,currentStep:t,children:n}){let r=e===t,i=(e-t)*100;return(0,q.jsx)(`div`,{"data-testid":`onboarding-slide-${e}`,"data-active":r,"aria-hidden":!r,style:{transform:`translateX(${i}%)`},className:y(`w-full transition-transform duration-300 ease-out`,!r&&`pointer-events-none absolute inset-0`),children:n})}function $({onClose:e,initialStep:t=0,isPreview:n=!1}){let{t:r}=i(`openhands`),{data:a}=ee(),o=a?.user_consents_to_analytics===!0,{trackOnboardingStarted:s,trackOnboardingStepViewed:l,trackOnboardingCompleted:u,trackOnboardingSkipped:d}=L(),{active:f}=g(),{backend:h}=f,_=m(h),b=I(_?[]:[h]),x=c(),S=x!==null&&h.kind===`cloud`&&p(h.host,x),C=!_&&b[h.id]?.isConnected===!0&&(x===null||S),w=C?Ne:Z,[T,E]=K.useState(()=>Z[Math.min(Math.max(t,0),Z.length-1)]),[D,O]=K.useState(`openhands`),[k,A]=K.useState(()=>le());K.useEffect(()=>{w.includes(T)||E(w[0])},[T,w]);let j=w.length,M=w.includes(T)?T:w[0],N=w.indexOf(M),P=e=>{let t=e.target.checked;A(t),ce(t)},F=_||b[h.id]?.isConnected!==void 0,R=D===`openhands`,z=N===0&&c()!==null,B=K.useCallback(()=>{E(e=>{let t=w,n=t.indexOf(e);return t[Math.min((n===-1?0:n)+1,t.length-1)]})},[w]),V=K.useCallback(()=>{E(e=>{let t=w,n=t.indexOf(e);return t[Math.max((n===-1?0:n)-1,0)]})},[w]),H=K.useRef(!1);K.useEffect(()=>{n||!o||H.current||window.sessionStorage.getItem(Pe)||(H.current=!0,window.sessionStorage.setItem(Pe,`1`),s())},[n,o]);let U=K.useRef(null);K.useEffect(()=>{n||!o||!F||U.current!==M&&(U.current=M,l({step:M,stepIndex:N,totalSteps:j,agent:D}))},[n,o,F,M,N,j,D]);let W=()=>{u({agent:D}),e()},G=()=>{d({step:M,stepIndex:N,totalSteps:j,agent:D}),e()};return(0,q.jsx)(te,{"aria-label":r(v.ONBOARDING$TITLE),children:(0,q.jsxs)(`div`,{className:`relative flex flex-col items-center gap-4`,children:[(0,q.jsxs)(`section`,{"data-testid":`onboarding-modal`,"data-current-step":N,"data-preview":n?`true`:void 0,className:y(`flex flex-col gap-6 overflow-hidden rounded-2xl border border-white/10 bg-base-secondary shadow-2xl`,ne(`lg`),re,`max-h-[90vh]`),children:[(0,q.jsx)(`header`,{className:`flex flex-col gap-3 px-7 pt-7 shrink-0`,children:(0,q.jsx)(be,{currentStep:N,totalSteps:j})}),(0,q.jsx)(`div`,{"data-testid":`onboarding-scroll-area`,className:`min-h-0 overflow-y-auto custom-scrollbar-always px-7 pb-7`,children:(0,q.jsxs)(`div`,{"data-testid":`onboarding-slide-rail`,"data-current-step":N,className:`relative overflow-clip`,children:[C?null:(0,q.jsx)(Q,{index:w.indexOf(`backend`),currentStep:N,children:(0,q.jsx)(Ee,{onNext:B,onClose:e})}),(0,q.jsx)(Q,{index:w.indexOf(`agent`),currentStep:N,children:(0,q.jsx)(we,{selectedAgentId:D,onSelect:O,onBack:C?void 0:V,onNext:B})}),(0,q.jsx)(Q,{index:w.indexOf(`setup`),currentStep:N,children:R?(0,q.jsx)(Oe,{onBack:V,onNext:B}):(0,q.jsx)(ke,{providerKey:D,isActive:M===`setup`,onBack:V,onNext:B})}),(0,q.jsx)(Q,{index:w.indexOf(`hello`),currentStep:N,children:(0,q.jsx)(je,{onBack:V,onClose:G,onLaunched:W})})]})})]}),N<j-1&&!z?(0,q.jsx)(`button`,{type:`button`,"data-testid":`onboarding-skip`,onClick:G,className:`rounded-md px-3 py-2 text-sm text-[var(--oh-muted)] transition-colors hover:bg-white/5 hover:text-white cursor-pointer`,children:r(v.ONBOARDING$SKIP)}):null,M===`hello`?(0,q.jsxs)(`label`,{className:`flex cursor-pointer items-center justify-center gap-2 text-sm text-[var(--oh-muted)]`,children:[(0,q.jsx)(`input`,{"data-testid":`onboarding-skip-getting-started-checklist`,type:`checkbox`,checked:k,onChange:P,className:`size-4 cursor-pointer`}),r(v.ONBOARDING$SKIP_GETTING_STARTED_CHECKLIST)]}):null]})})}export{Me as n,J as r,$ as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{C as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{ut as t}from"./active-backend-context-CrHTlgvN.js";import"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~nj1hli3r-DP9wmsjo.js";import{t as n}from"./proxy-9Fe1v5na.js";function r(e){return{items:e?.items??[],currentOrgId:e?.current_org_id??null}}function i(e){if(e)return e;let n=t().backend;if(n.kind!==`cloud`)throw Error(`Cloud organization calls require a cloud backend. Active backend is local.`);return n}async function a(e){return r(await n({backend:i(e),method:`GET`,path:`/api/organizations`}))}async function o(t){let r=i(t);try{return{orgId:(await n({backend:r,method:`GET`,path:`/api/keys/current`}))?.org_id??null,isLegacyKey:!1}}catch(t){if(t instanceof e&&t.status===400)return{orgId:null,isLegacyKey:!0};throw t}}async function s(e,t){let r=await n({backend:i(t),method:`GET`,path:`/api/organizations/${encodeURIComponent(e)}/me`});return{orgId:r?.org_id??e,userId:r?.user_id??``,role:r?.role??null,permissions:Array.isArray(r?.permissions)?r.permissions:null}}export{a as n,o as r,s as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";var t=e(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]);export{t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";var t=e(`pin`,[[`path`,{d:`M12 17v5`,key:`bb1du9`}],[`path`,{d:`M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z`,key:`1nkz8b`}]]);export{t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{t as r}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{W as i}from"./utils-CN5ZfZy1.js";import{E as a,d as o}from"./messages-DKV9cRc2.js";import{t as s}from"./list-todo-apgLVjMw.js";import{t as c}from"./brand-button-BAfk4wGP.js";import{t as l}from"./conversation-store-Ca3ghXap.js";import{N as u}from"./llm-not-configured-banner-CIFABh3K.js";import{t as d}from"./markdown-renderer-BzTlxI8x.js";import{t as f}from"./conversation-tab-empty-state-FIbh_lc8.js";var p=e(t(),1),m=n();function h(){let{t:e}=r(`openhands`),{scrollRef:t,onChatBodyScroll:n,autoScroll:h,scrollDomToBottom:g}=a(p.useRef(null)),{planContent:_,conversationMode:v}=l();p.useEffect(()=>{h&&g()},[_,h,g]);let y=v===`plan`,{handlePlanClick:b}=u();return _==null?(0,m.jsx)(f,{icon:(0,m.jsx)(s,{"aria-hidden":!0,strokeWidth:2,className:`size-full`}),action:(0,m.jsx)(c,{type:`button`,variant:`secondary`,onClick:b,isDisabled:y,className:`min-w-40 justify-center px-6`,children:e(i.COMMON$CREATE_A_PLAN)}),children:e(i.PLANNER$EMPTY_MESSAGE)}):(0,m.jsx)(`div`,{ref:t,onScroll:e=>n(e.currentTarget),className:`flex flex-col w-full h-full p-4 overflow-auto`,children:(0,m.jsx)(d,{includeStandard:!0,components:o,children:_})})}export{h as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";var t=e(`plug`,[[`path`,{d:`M12 22v-5`,key:`1ega77`}],[`path`,{d:`M15 8V2`,key:`18g5xt`}],[`path`,{d:`M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z`,key:`1xoxul`}],[`path`,{d:`M9 8V2`,key:`14iosj`}]]);export{t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{u as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{tt as t,ut as n}from"./active-backend-context-CrHTlgvN.js";function r(){return n().backend.kind===`cloud`}function i(){return new e(t())}var a=class{static async listInstalledPlugins(){if(r())return[];try{return(await i().listInstalledPlugins()).plugins??[]}catch{return[]}}static async installPlugin(e){if(r())throw Error(`Installing plugins is only available on a local backend.`);return i().installPlugin(e)}static async setPluginEnabled(e,t){if(r())throw Error(`Enabling and disabling plugins is only available on a local backend.`);return i().setPluginEnabled(e,t)}static async uninstallPlugin(e){if(r())throw Error(`Uninstalling plugins is only available on a local backend.`);return i().uninstallPlugin(e)}static async refreshPlugin(e){if(r())throw Error(`Refreshing plugins is only available on a local backend.`);return i().refreshPlugin(e)}};export{a as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";var t=e(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]);export{t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{p as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{tt as t,ut as n}from"./active-backend-context-CrHTlgvN.js";import{t as r}from"./proxy-9Fe1v5na.js";var i=`/api/v1/settings/profiles`;function a(){let{backend:e,orgId:t}=n();if(e.kind!==`cloud`)throw Error(`Cloud profiles call requires a cloud backend.`);return{backend:e,base:t?`/api/organizations/${encodeURIComponent(t)}/profiles`:i}}async function o(){let{backend:e,base:t}=a();return r({backend:e,method:`GET`,path:t})}async function s(e){let{backend:t,base:n}=a(),i=await r({backend:t,method:`GET`,path:`${n}/${encodeURIComponent(e)}`});return{name:i.name,config:i.config??i.llm??{},api_key_set:i.api_key_set??!1}}async function c(e,t){let{backend:n,base:i}=a();return r({backend:n,method:`POST`,path:`${i}/${encodeURIComponent(e)}`,body:t})}async function l(e){let{backend:t,base:n}=a();return r({backend:t,method:`DELETE`,path:`${n}/${encodeURIComponent(e)}`})}async function u(e,t){let{backend:n,base:i}=a();return r({backend:n,method:`POST`,path:`${i}/${encodeURIComponent(e)}/rename`,body:{new_name:t}})}async function d(e){let{backend:t,base:n}=a(),i=await r({backend:t,method:`POST`,path:`${n}/${encodeURIComponent(e)}/activate`,body:{}});return{name:i.name,message:i.message,llm_applied:i.model!=null||i.llm!=null}}function f(){return n().backend.kind===`cloud`}function p(e){if(!e||typeof e!=`object`)return!1;let t=`name`in e?e.name:void 0;if(t===`AbortError`||t===`TimeoutError`)return!0;let n=`cause`in e?e.cause:void 0;return!!n&&typeof n==`object`&&`name`in n&&(n.name===`AbortError`||n.name===`TimeoutError`)}var m=class{static async listProfiles(){return f()?o():new e(t()).listProfiles()}static async getProfile(n,r){if(f())return s(n);let i=r?{exposeSecrets:r}:{};return new e(t()).getProfile(n,i)}static async saveProfile(n,r){return f()?c(n,r):new e(t()).saveProfile(n,r)}static async deleteProfile(n){return f()?l(n):new e(t()).deleteProfile(n)}static async renameProfile(n,r){return f()?u(n,r):new e(t()).renameProfile(n,r)}static async activateProfile(n){return f()?d(n):new e(t()).activateProfile(n)}static async validateProfile(n,r){if(f())return null;let i=new e({...t(),timeout:3e4});try{return await i.validateProfile(n,r)}catch(e){let t=e&&typeof e==`object`&&`status`in e?e.status:void 0;if(t===404||t===429||typeof t==`number`&&t>=500||p(e))return null;throw e}finally{i.close()}}};export{m as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{t as r}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{t as i}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js";import{Gt as a,Kt as o,S as s,Yt as c,_ as l,b as u,c as d,d as f,lt as p,m,o as h,ot as g,qt as _,s as v,st as y,t as b,x,y as S}from"./active-backend-context-CrHTlgvN.js";import{t as C}from"./utils-CN5ZfZy1.js";import{n as w,t as T}from"./agent-server-ui-style-scope-DdG0ZAHu.js";var E=e(t());function D({i18n:e,defaultNS:t,children:n}){let i=(0,E.useMemo)(()=>({i18n:e,defaultNS:t}),[e,t]);return(0,E.createElement)(r.Provider,{value:i},n)}function O(){let e=(0,E.useSyncExternalStore)(S,f,()=>`pending`),t=(0,E.useRef)(!1);(0,E.useEffect)(()=>{t.current||(t.current=!0,x())},[]),(0,E.useEffect)(()=>{e===`granted`&&s()},[e]);let n=(0,E.useCallback)(()=>l(`granted`),[]),r=(0,E.useCallback)(()=>l(`denied`),[]),i=(0,E.useCallback)((e,t)=>{u(e,t)},[]),a=(0,E.useCallback)(()=>h(),[]);return{consent:e,isEnabled:e===`granted`,showConsentPrompt:e===`pending`,grantConsent:n,denyConsent:r,track:i,clearData:a}}var k=n(),A=`posthog_bootstrap`;function j(e){if(typeof e!=`object`||!e)return!1;let t=e;return typeof t.distinctID==`string`&&typeof t.sessionID==`string`}function M(){if(typeof window>`u`||typeof sessionStorage>`u`)return;let e=new URLSearchParams(window.location.hash.slice(1)),t=e.get(`distinct_id`),n=e.get(`session_id`);if(t&&n){let e={distinctID:t,sessionID:n};try{sessionStorage.setItem(A,JSON.stringify(e))}catch{}try{window.history.replaceState(null,``,window.location.pathname+window.location.search)}catch{}return e}try{let e=sessionStorage.getItem(A);if(!e)return;sessionStorage.removeItem(A);let t=JSON.parse(e);return j(t)?t:void 0}catch{try{sessionStorage.removeItem(A)}catch{}return}}function N(){return O(),null}function P({children:e,config:t={}}){let n=E.useRef(!1),r=t!==!1,i=t===!1?void 0:t.apiKey,a=t===!1?void 0:t.apiHost,o=t===!1?void 0:t.uiHost;return E.useLayoutEffect(()=>{d(r?{apiKey:i,apiHost:a,uiHost:o}:!1),n.current||=(v(M()),!0)},[r,a,i,o]),E.useEffect(()=>{r&&m().catch(()=>{})},[r,a,i,o]),(0,k.jsxs)(k.Fragment,{children:[r?(0,k.jsx)(N,{}):null,e]})}function F({children:e,theme:t=w,className:n,style:r,styleOverrides:i,contentClassName:a,...o}){let s=E.useMemo(()=>({...T,...i,...r}),[r,i]);return(0,k.jsx)(`div`,{"data-agent-server-ui":``,...o,className:n,style:s,children:(0,k.jsx)(`div`,{className:C(t,a,`text-foreground`),"data-theme":t,children:e})})}var I={provider:`posthog`};function L({children:e,queryClient:t,analytics:n,i18n:r,className:s,contentClassName:l,style:u,styleOverrides:d,theme:f,withStyleRoot:m=!0}){let h=E.useMemo(()=>t??g(),[t]),v=E.useMemo(()=>r??o(),[r]),x=E.useRef(null);x.current||={queryClient:y(),i18n:_()},p(h),c(v),E.useEffect(()=>()=>{x.current&&(p(x.current.queryClient),c(x.current.i18n))},[]);let S=(0,k.jsx)(P,{config:n&&n.provider===`posthog`?{apiKey:n.apiKey,apiHost:n.apiHost,uiHost:n.uiHost}:!1,children:e});return(0,k.jsx)(D,{i18n:v,defaultNS:a,children:(0,k.jsx)(i,{client:h,children:(0,k.jsx)(b,{children:m?(0,k.jsx)(F,{className:s,contentClassName:l,style:u,styleOverrides:d,theme:f,children:S}):S})})})}export{I as n,F as r,L as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{Ct as t,et as n,ut as r,xt as i}from"./active-backend-context-CrHTlgvN.js";function a(e){if(e)return e;let t=r().backend;if(t.kind!==`cloud`)throw Error(`Cloud calls require a cloud backend.`);return t}function o(e){let t=r();return t.backend.id===e.id?t.orgId:null}function s(n){let r=a(n),s=i(),c=s?t():{};return new e({host:r.host,apiKey:r.apiKey,orgId:o(r),timeout:3e4,...s?{proxy:{host:s,headers:c}}:{}})}function c(e){let t=s(e);if(!t.proxy)throw new n;return t}async function l(e){return(e.hostOverride?c(e.backend):s(e.backend)).request({method:e.method,path:e.path,body:e.body,headers:e.headers,timeoutSeconds:e.timeoutSeconds,hostOverride:e.hostOverride,authMode:e.authMode===void 0||e.authMode===`bearer`?`bearer`:e.authMode,sessionApiKey:e.sessionApiKey,responseType:e.responseType})}export{l as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{S as r,n as i,u as a}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js";import{t as o}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{Ft as s,Jt as c,n as l,zt as u}from"./active-backend-context-CrHTlgvN.js";import{B as d,W as f,t as p}from"./utils-CN5ZfZy1.js";import{t as m}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-CUmIwQCN.js";import{A as ee,D as h,F as g,I as _,L as v,M as te,R as y,b as ne,t as re,w as b}from"./use-tracking-D53y3TH9.js";import{l as ie}from"./settings-service.api-DJ1r62Zr.js";import{n as ae}from"./use-settings-DSXLbvBl.js";import{t as x}from"./modal-backdrop-BSzNhM4r.js";import{n as S}from"./modal-classes-C8eycCwG.js";import{t as C}from"./brand-button-BAfk4wGP.js";import{n as w}from"./navigation-context-CQZwH_tC.js";import{o as oe,s as se,t as ce}from"./conversation-store-Ca3ghXap.js";import{t as T}from"./modal-close-button-DDzdRvCs.js";import{n as le}from"./use-create-conversation-Dx3l7mFZ.js";import{p as E,t as ue}from"./install-server-modal-Dpy89p4g.js";import{t as de}from"./use-automations-xijQKIl9.js";import{a as D,i as O,n as k,r as A,t as j}from"./extension-module-card-classes-DpeaYhYo.js";import{t as M}from"./secrets-service-ByZVENbp.js";import{t as N}from"./use-create-secret-B9cUFWRG.js";import{f as fe,n as P,o as F,u as I}from"./mcp-marketplace-utils-AIBzzHTO.js";import{t as L}from"./vendor~root-layout~index-home~home~conversation-panel~conversation~mcp~automations-list~aut~ibfbmr9f-cDuKr-WD.js";import{t as R}from"./scroll-fade-state-Dw-i4SGq.js";import{n as z}from"./skill-card-pill-row-B27-xyig.js";import{t as B}from"./circle-plus-check-toggle-BO_kFZt3.js";var V=e(t(),1);function H(e,t){let n=i(t);return pe({filters:{...e,status:`pending`}},n).length}function U(e,t){return e.findAll(t.filters).map(e=>t.select?t.select(e):e.state)}function pe(e={},t){let n=i(t).getMutationCache(),o=V.useRef(e),s=V.useRef(null);return s.current===null&&(s.current=U(n,e)),V.useEffect(()=>{o.current=e}),V.useSyncExternalStore(V.useCallback(e=>n.subscribe(()=>{let t=r(s.current,U(n,o.current));s.current!==t&&(s.current=t,a.schedule(e))}),[n]),()=>s.current,()=>s.current)}var W=()=>{let e=w(),t=H({mutationKey:[`create-conversation`]}),{isNavigating:n}=e;return t>0||n},G=`OPENHANDS_URL`;function me(){let e=l(),t=i(),{mutateAsync:n}=N();return(0,V.useCallback)(async()=>{let r;try{r=await t.fetchQuery({queryKey:[`secrets`,e.backend.id,e.orgId],queryFn:M.getSecretsOrThrow,staleTime:0,retry:!1,meta:{disableToast:!0}})}catch(e){return s(u(e)||c.t(f.ERROR$GENERIC)),!1}if(r.some(e=>e.name===G))return!0;try{await n({name:G,value:window.location.origin})}catch{return!1}return await t.invalidateQueries({queryKey:[`secrets`]}),!0},[e.backend.id,e.orgId,n,t])}var he=`${d.PRODUCTION}/settings/integrations`;function ge(e){let t=h(),n=y(e);return n.length>0&&n.every(e=>t.includes(e))}function _e(e){switch(e){case`local`:return{target:e,testId:`responder-deployment-option-local`,titleKey:f.RESPONDER_DEPLOYMENT$LOCAL_TITLE,descriptionKey:f.RESPONDER_DEPLOYMENT$LOCAL_DESCRIPTION,primaryActionKey:f.RESPONDER_DEPLOYMENT$LOCAL_ACTION,primaryActionTestId:`responder-deployment-continue-local`,action:{kind:`launch-local`}};case`openhands-cloud`:return{target:e,testId:`responder-deployment-option-openhands-cloud`,titleKey:f.RESPONDER_DEPLOYMENT$OPENHANDS_CLOUD_TITLE,descriptionKey:f.RESPONDER_DEPLOYMENT$OPENHANDS_CLOUD_DESCRIPTION,primaryActionKey:f.RESPONDER_DEPLOYMENT$OPENHANDS_CLOUD_ACTION,primaryActionTestId:`responder-deployment-open-openhands-cloud`,action:{kind:`open-url`,url:he}};case`user-cloud`:throw Error(`User Cloud responder deployment is not yet supported`);default:return e}}var ve=[`local`,`openhands-cloud`];function K(e){return e.map((e,t)=>({automation:e,index:t})).sort((e,t)=>(t.automation.popularityRank??0)-(e.automation.popularityRank??0)||e.index-t.index).map(({automation:e})=>e)}function q(e){return e.trim().toLowerCase().replace(/&/g,`and`).replace(/[^a-z0-9]+/g,`-`).replace(/^-+|-+$/g,``)}function ye(e){return[e.id,e.name,e.skill].filter(e=>!!e).map(q)}function be(e,t){let n=new Set(t.map(e=>q(e.name)));return ye(e).some(e=>n.has(e))}function J(e){return b().includes(e.id)}function xe(e){return te.findById(e.id)==null}function Se(e){let t=K(m).filter(t=>!be(t,e));return{proven:t.filter(J),conversation:t.filter(e=>!J(e)&&xe(e))}}function Ce(e){return[...e.proven,...e.conversation]}var we=2;function Te(e){let[t,n]=(0,V.useState)(!1),r=(0,V.useRef)(0),i=(0,V.useRef)(0),a=(0,V.useRef)(!1),o=(0,V.useCallback)(t=>{let o=e.current;t.button!==0||!o||(a.current=!1,r.current=t.clientX,i.current=o.scrollLeft,n(!0))},[e]),s=(0,V.useCallback)(e=>{a.current&&(a.current=!1,e.preventDefault(),e.stopPropagation())},[]),c=(0,V.useCallback)(e=>{e.preventDefault()},[]);return(0,V.useEffect)(()=>{if(!t)return;let o=t=>{let o=e.current;if(o){if(!(t.buttons&1)){n(!1);return}if(!a.current){if(Math.abs(t.clientX-r.current)<we)return;a.current=!0}t.preventDefault(),o.scrollLeft=i.current-(t.clientX-r.current)}},s=()=>n(!1);return document.addEventListener(`mousemove`,o),document.addEventListener(`mouseup`,s),()=>{document.removeEventListener(`mousemove`,o),document.removeEventListener(`mouseup`,s)}},[t,e]),{handleMouseDown:o,handleClickCapture:s,handleDragStart:c}}var Y=`pb-12`,X=n(),Ee=`flex h-10 items-start`;function De(e){return v(e).flatMap(e=>{let t=F(e,L);return t?[t]:[]})}function Oe({automation:e,entries:t,testId:n}){let r=t.slice(0,4),i=r.length>1,a=g(e);return(0,X.jsx)(`span`,{"aria-hidden":`true`,"data-testid":n,"data-layout":i&&!a?`overlap`:void 0,className:p(Ee,i&&!a&&`-space-x-2`),children:a?(0,X.jsx)(E,{entry:null,size:`base`,fallback:(0,V.createElement)(a,{className:`h-5 w-5`,strokeWidth:2.25})}):r.length===0?(0,X.jsx)(E,{entry:null,size:`base`}):r.map(e=>(0,X.jsx)(E,{entry:e,size:`base`,className:i?`ring-2 ring-[var(--oh-color-base-secondary)]`:void 0},e.id))})}function ke({installedAutomations:e,onSelect:t,className:n}){let{t:r}=o(`openhands`),i=Ce(Se(e)),a=(0,V.useRef)(null),{handleMouseDown:s,handleClickCapture:c,handleDragStart:l}=Te(a),[u,d]=(0,V.useState)({left:!1,right:!1}),m=(0,V.useCallback)(()=>{let e=a.current;if(!e)return;let t=R(e);d(e=>e.left===t.left&&e.right===t.right?e:t)},[]);return(0,V.useLayoutEffect)(()=>{m();let e=a.current;if(!e)return;let t=new ResizeObserver(m);return t.observe(e),Array.from(e.children).forEach(e=>{t.observe(e)}),()=>t.disconnect()},[m,i.map(e=>e.id).join(`,`)]),i.length===0?null:(0,X.jsxs)(`section`,{"data-testid":`recommended-automations-rail`,"aria-label":r(f.RECOMMENDED_AUTOMATIONS$SECTION_LABEL),className:p(`w-full`,Y,n),children:[(0,X.jsx)(`h2`,{className:`mb-2 text-sm font-medium text-[var(--oh-foreground)]`,children:r(f.RECOMMENDED_AUTOMATIONS$SECTION_LABEL)}),(0,X.jsxs)(`div`,{className:`relative`,children:[(0,X.jsx)(`div`,{ref:a,role:`list`,"data-testid":`recommended-automations-rail-scroll`,onScroll:m,onMouseDown:s,onClickCapture:c,onDragStart:l,className:`flex flex-nowrap gap-3 overflow-x-auto scrollbar-hide select-none`,children:i.map(e=>(0,X.jsx)(`div`,{role:`listitem`,children:(0,X.jsxs)(`button`,{type:`button`,"data-testid":`recommended-automation-rail-card-${e.id}`,onClick:()=>t(e),className:p(`flex w-[220px] shrink-0 flex-col gap-3 p-3 text-left`,D,A),children:[(0,X.jsx)(Oe,{automation:e,entries:De(e),testId:`recommended-automation-rail-icon-${e.id}`}),(0,X.jsxs)(`div`,{className:`min-w-0`,children:[(0,X.jsx)(`h3`,{className:`truncate text-sm font-semibold text-white`,children:e.name}),(0,X.jsx)(`p`,{className:`mt-0.5 line-clamp-2 text-xs leading-relaxed text-tertiary-light`,children:e.description})]})]})},e.id))}),(0,X.jsx)(`div`,{"aria-hidden":!0,"data-testid":`recommended-automations-rail-fade-left`,"data-visible":u.left?`true`:`false`,className:p(`pointer-events-none absolute inset-y-0 left-0 z-10 w-10`,`bg-gradient-to-r from-[var(--oh-scroll-fade-from,var(--oh-color-base))] to-transparent`,`transition-opacity duration-300 ease-out motion-reduce:transition-none`,u.left?`opacity-100`:`opacity-0`)}),(0,X.jsx)(`div`,{"aria-hidden":!0,"data-testid":`recommended-automations-rail-fade-right`,"data-visible":u.right?`true`:`false`,className:p(`pointer-events-none absolute inset-y-0 right-0 z-10 w-10`,`bg-gradient-to-l from-[var(--oh-scroll-fade-from,var(--oh-color-base))] to-transparent`,`transition-opacity duration-300 ease-out motion-reduce:transition-none`,u.right?`opacity-100`:`opacity-0`)})]})]})}var Z=`inline-flex h-10 w-10 shrink-0 overflow-hidden rounded-lg border border-white/10 bg-surface-raised shadow-[inset_0_1px_0_rgba(255,255,255,0.18)]`;function Ae(e){return e.slice(0,4)}function je({entries:e,className:t,testId:n}){let r=Ae(e);if(r.length===0)return(0,X.jsx)(E,{entry:null,size:`md`,className:t,testId:n});if(r.length===1)return(0,X.jsx)(E,{entry:r[0],size:`md`,className:t,testId:n});if(r.length===2)return(0,X.jsx)(`span`,{"aria-hidden":`true`,"data-testid":n,"data-layout":`overlap`,className:p(Z,`items-center justify-center`,t),children:(0,X.jsx)(`span`,{className:`flex items-center justify-center -space-x-2`,children:r.map(e=>(0,X.jsx)(E,{entry:e,size:`sm`,className:`ring-2 ring-surface-raised`},e.id))})});let i=[r[0]??null,r[1]??null,r[2]??null,r[3]??null];return(0,X.jsx)(`span`,{"aria-hidden":`true`,"data-testid":n,"data-layout":`quadrants`,className:p(Z,`grid grid-cols-2 grid-rows-2 gap-0.5 p-1`,t),children:i.map((e,t)=>e?(0,X.jsx)(`span`,{className:`flex items-center justify-center`,children:(0,X.jsx)(E,{entry:e,size:`xs`})},e.id):(0,X.jsx)(`span`,{"aria-hidden":`true`},`empty-${t}`))})}function Q({count:e}){return(0,X.jsx)(`span`,{className:`ml-2 inline-flex items-center justify-center rounded-full bg-surface-raised px-2 py-0.5 text-xs text-foreground`,children:e})}var Me=K(m);function $(e){return b().includes(e.id)}function Ne(e){return v(e).map(e=>{let t=F(e,L);return{id:e,entry:t,mcpInstallable:!!t&&I(t)}})}function Pe(e,t,n){let r=n.trim().toLowerCase();return r?[e.name,e.category,e.description,_(e),...t.flatMap(({entry:e,id:t})=>e?[e.name,t,...e.keywords??[]]:[t])].join(` `).toLowerCase().includes(r):!0}function Fe(e,t,n,r){let i=e.map(({id:e,entry:n,mcpInstallable:i})=>{let a=!!n&&P(n,t),o=n?.name??e;return{id:`integration-${e}`,node:(0,X.jsxs)(`span`,{className:p(O,`gap-1`),children:[(0,X.jsx)(E,{entry:n,size:`xs`}),o,a?(0,X.jsx)(`span`,{className:`text-white`,children:r(f.RECOMMENDED_AUTOMATIONS$CONNECTED)}):n?i?null:(0,X.jsx)(`span`,{className:`text-tertiary-alt`,"data-testid":`automation-integration-external-${e}`,children:r(f.RECOMMENDED_AUTOMATIONS$EXTERNAL_SETUP)}):(0,X.jsx)(`span`,{className:`text-tertiary-alt`,"data-testid":`recommended-automation-integration-${e}`,children:r(f.RECOMMENDED_AUTOMATIONS$UNKNOWN_SETUP)})]})}});return n>0&&i.push({id:`missing-connect`,node:(0,X.jsx)(`span`,{className:O,children:r(f.RECOMMENDED_AUTOMATIONS$MISSING_CONNECT,{count:n})})}),i}function Ie({automation:e,integrations:t,size:n,testId:r}){let i=g(e);return i?(0,X.jsx)(E,{entry:null,size:n,testId:r,fallback:(0,V.createElement)(i,{className:`h-5 w-5`,strokeWidth:2.25})}):(0,X.jsx)(je,{entries:t.flatMap(({entry:e})=>e?[e]:[]),testId:r})}function Le({automations:e,installedServers:t,onSelect:n,translate:r}){return(0,X.jsx)(`div`,{className:p(`mt-3`,j),children:e.map(e=>{let i=Ne(e),a=i.filter(({entry:e,mcpInstallable:n})=>!!e&&n&&!P(e,t)).length;return(0,X.jsx)(`button`,{type:`button`,"data-testid":`recommended-automation-card-${e.id}`,onClick:()=>n(e),className:p(`flex min-w-0 overflow-hidden p-4 text-left`,D,A),children:(0,X.jsxs)(`div`,{className:`flex min-w-0 flex-1 items-start gap-3`,children:[(0,X.jsx)(Ie,{automation:e,integrations:i,size:`md`,testId:`recommended-automation-icon-${e.id}`}),(0,X.jsxs)(`div`,{className:`flex min-w-0 flex-1 flex-col gap-3`,children:[(0,X.jsxs)(`header`,{className:`flex items-start justify-between gap-3`,children:[(0,X.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,X.jsx)(`h3`,{className:`truncate text-sm font-semibold text-white`,children:e.name}),(0,X.jsx)(`p`,{className:`mt-0.5 truncate text-xs text-tertiary-alt`,children:e.category})]}),(0,X.jsx)(B,{testId:`recommended-automation-plus-${e.id}`})]}),(0,X.jsx)(`p`,{className:`line-clamp-2 text-xs leading-relaxed text-tertiary-light`,children:e.description}),(0,X.jsx)(z,{pills:Fe(i,t,a,r),testId:`recommended-automation-pills-${e.id}`})]})]})},e.id)})})}function Re({backendKind:e,installedServers:t,query:n=``,onSelect:r,scrollableGrid:i=!1}){let{t:a}=o(`openhands`),s=Me.filter(e=>Pe(e,Ne(e),n));if(s.length===0)return null;let c=s.filter($),l=s.filter(e=>!$(e));return(0,X.jsx)(`section`,{"data-testid":`recommended-automations-section`,className:p(i&&`flex min-h-0 flex-1 flex-col`),children:(0,X.jsxs)(`div`,{"data-testid":i?`recommended-automations-scroll-area`:void 0,className:p(`mt-3`,k,i&&`min-h-0 flex-1 overflow-y-auto custom-scrollbar-always`),children:[c.length>0&&(0,X.jsxs)(X.Fragment,{children:[(0,X.jsxs)(`div`,{className:`flex items-center`,children:[(0,X.jsx)(`h2`,{className:`text-base font-semibold text-foreground`,children:a(f.RECOMMENDED_AUTOMATIONS$SECTION_TITLE)}),(0,X.jsx)(Q,{count:c.length})]}),(0,X.jsx)(`p`,{className:`mt-1 text-sm text-muted`,children:a(f.RECOMMENDED_AUTOMATIONS$SECTION_DESCRIPTION)}),(0,X.jsx)(Le,{automations:c,installedServers:t,onSelect:r,translate:a})]}),l.length>0&&(0,X.jsxs)(`section`,{"data-testid":`recommended-automations-beta-section`,className:p(c.length>0&&`mt-8`),children:[(0,X.jsxs)(`div`,{"data-testid":`recommended-automations-beta-heading`,className:`flex items-center`,children:[(0,X.jsx)(`h2`,{className:`text-base font-semibold text-foreground`,children:a(f.RECOMMENDED_AUTOMATIONS$BETA_LABEL)}),(0,X.jsx)(Q,{count:l.length})]}),(0,X.jsx)(Le,{automations:l,installedServers:t,onSelect:r,translate:a})]})]})})}function ze({isOpen:e,isPending:t,onClose:n,onContinueLocal:r,onOpenUrl:i}){let{t:a}=o(`openhands`);return e?(0,X.jsx)(x,{onClose:n,closeOnEscape:!t,closeOnBackdropClick:!t,"aria-label":a(f.RESPONDER_DEPLOYMENT$TITLE),children:(0,X.jsxs)(`div`,{"data-testid":`responder-deployment-modal`,className:`relative flex w-full max-w-3xl flex-col rounded-xl border border-[var(--oh-border)] bg-base-secondary`,children:[(0,X.jsx)(T,{onClose:n,testId:`responder-deployment-modal-close`,disabled:t}),(0,X.jsxs)(`header`,{className:`flex-shrink-0 px-6 pb-4 pt-6`,children:[(0,X.jsx)(`h2`,{className:p(`pr-6`,S),children:a(f.RESPONDER_DEPLOYMENT$TITLE)}),(0,X.jsx)(`p`,{className:`mt-2 text-sm text-muted`,children:a(f.RESPONDER_DEPLOYMENT$DESCRIPTION)})]}),(0,X.jsx)(`div`,{className:`flex flex-col gap-3 px-6 pb-6 sm:flex-row`,children:ve.map(e=>{let n=_e(e),{action:o}=n;return(0,X.jsxs)(`div`,{"data-testid":n.testId,className:`flex flex-1 flex-col gap-3 rounded-xl border border-[var(--oh-border)] bg-surface-raised p-4`,children:[(0,X.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,X.jsx)(`h3`,{className:`text-sm font-semibold text-white`,children:a(n.titleKey)}),(0,X.jsx)(`p`,{className:`text-xs leading-relaxed text-tertiary-light`,children:a(n.descriptionKey)})]}),(0,X.jsx)(C,{type:`button`,variant:`primary`,className:`mt-auto`,testId:n.primaryActionTestId,isDisabled:t,"aria-busy":t&&o.kind===`launch-local`?!0:void 0,onClick:()=>{o.kind===`launch-local`?r():i(o.url)},children:a(n.primaryActionKey)})]},n.target)})})]})}):null}function Be(e){return y(e).map(e=>F(e,L)).filter(e=>!!e).filter(I)}function Ve({query:e,onLaunched:t,scrollableGrid:n=!1,variant:r=`catalog`,className:i}){let a=l(),{navigate:o}=w(),{data:s}=ae(),{trackPrebuiltAutomationEnabled:c}=re(),u=le(),d=me(),f=W(),p=ce(e=>e.setMessageToSend),[m,h]=(0,V.useState)(null),[g,v]=(0,V.useState)(null),[y,b]=(0,V.useState)([]),x=(0,V.useRef)(!1),S=(0,V.useRef)(!1),C=(0,V.useRef)(!1),[T,E]=(0,V.useState)(!1),D=r===`rail`,{data:O,isLoading:k}=de({enabled:D&&a.backend.kind===`local`}),A=(0,V.useMemo)(()=>fe(s?.mcp_config??ie(s?.agent_settings?.mcp_config)).filter(e=>e.enabled!==!1),[s?.agent_settings?.mcp_config,s?.mcp_config]),j=(0,V.useCallback)(e=>{if(S.current||u.isPending||f)return;if(S.current=!0,te.findById(e.id)){o?.(ne(e.id)),t?.();return}let n=_(e);u.mutate({},{onSuccess:r=>{c({automationName:e.name,automationCategory:e.category}),r.conversation_id.startsWith(`task-`)&&r.task_id?se(r.task_id,n):oe(r.conversation_id,{draftMessage:n}),o?.(`/conversations/${r.conversation_id}`),t?.(),window.setTimeout(()=>p(n),0)},onError:()=>{S.current=!1}})},[a.backend.kind,u,f,o,t,p,c]),M=(0,V.useCallback)(e=>Be(e).filter(e=>!P(e,A)),[A]),N=e=>{let t=M(e);if(t.length===0){j(e);return}h(e),b(t)},F=e=>{if(!(S.current||u.isPending||f||y.length>0||g!==null)){if(ge(e)){v(e);return}N(e)}},I=async()=>{let e=g;if(!(!e||C.current)){C.current=!0,E(!0);try{if(!await d())return;v(null),N(e)}finally{C.current=!1,E(!1)}}},L=e=>{v(null),window.open(e,`_blank`,`noopener,noreferrer`)},R=()=>{v(null)},z=()=>{if(x.current){x.current=!1;return}h(null),b([])},B=()=>{x.current=!0,b(e=>{let t=e.slice(1);if(t.length===0){let e=m;window.setTimeout(()=>{h(null),e&&j(e)},0)}return t})},H=y[0]??null;return!ee()||a.backend.kind===`cloud`||D&&k?null:(0,X.jsxs)(X.Fragment,{children:[D?(0,X.jsx)(ke,{className:i,installedAutomations:O?.automations??[],onSelect:F}):(0,X.jsx)(Re,{backendKind:a.backend.kind,installedServers:A,query:e,onSelect:F,scrollableGrid:n}),H&&(0,X.jsx)(ue,{entry:H,existingServers:A,onClose:z,onSuccess:B},H.id),(0,X.jsx)(ze,{isOpen:g!==null,isPending:T,onClose:R,onContinueLocal:I,onOpenUrl:L})]})}export{H as a,W as i,Q as n,Y as r,Ve as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";var t=e(`refresh-cw`,[[`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,key:`v9h5vc`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}],[`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,key:`3uifl3`}],[`path`,{d:`M8 16H3v5`,key:`1cv678`}]]);export{t};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/manage-backends-modal-BrPV3oB-.js","assets/rolldown-runtime-Cyuzqnbw.js","assets/vendor-styling-Ck5D_A2Q.js","assets/active-backend-context-CrHTlgvN.js","assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js","assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js","assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js","assets/utils-CN5ZfZy1.js","assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js","assets/useQuery-BSTgq1rl.js","assets/backend-form-modal-lhGwzXFI.js","assets/chevron-down-e1QBpjVy.js","assets/cloud-funnel-analytics-CztBCCPp.js","assets/info-B6RQawoW.js","assets/use-tracking-D53y3TH9.js","assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-CUmIwQCN.js","assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~jz4f6vo2-C7HiY4Ae.js","assets/bot-dMYHVfYM.js","assets/proxy-9Fe1v5na.js","assets/use-onboarding-completion-D8U7k4Qb.js","assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~nj1hli3r-DP9wmsjo.js","assets/useQueries-DlbhlH9I.js","assets/organization-service.api-DrYNkEN_.js","assets/brand-button-BAfk4wGP.js","assets/form-control-classes-Bkh5FGrD.js","assets/settings-input-Db-1g8Ql.js","assets/modal-backdrop-BSzNhM4r.js","assets/modal-body-BxZjsju9.js","assets/modal-close-button-DDzdRvCs.js","assets/navigation-context-CQZwH_tC.js","assets/modal-classes-C8eycCwG.js","assets/pencil-47jAZH_V.js","assets/plus-C7Slq-0I.js","assets/refresh-cw-3q3Frrii.js","assets/trash-2-D7K26eDO.js","assets/confirmation-modal-Dv1ktp8K.js","assets/use-cloud-current-user-id-CDfAHpPX.js","assets/api-key-entry-screen-qTzrmJcr.js","assets/onboarding-modal-rkyBYkeQ.js","assets/recommended-automations-launcher-6ABrI9Cy.js","assets/vendor~root-layout~index-home~home~conversation-panel~conversation~mcp~automations-list~aut~ibfbmr9f-cDuKr-WD.js","assets/conversation-store-Ca3ghXap.js","assets/secrets-service-ByZVENbp.js","assets/settings-service.api-DJ1r62Zr.js","assets/settings-CKqk8ZnH.js","assets/install-server-modal-Dpy89p4g.js","assets/useMutation-B-qc391N.js","assets/styled-tooltip-C4jf5Fv9.js","assets/use-settings-DSXLbvBl.js","assets/mcp-marketplace-utils-AIBzzHTO.js","assets/skill-card-pill-row-B27-xyig.js","assets/extension-module-card-classes-DpeaYhYo.js","assets/circle-plus-check-toggle-BO_kFZt3.js","assets/checkmark-XZyokq_Y.js","assets/x-mark-BopmFoBq.js","assets/use-create-conversation-Dx3l7mFZ.js","assets/agent-server-conversation-service.api-tnqNjbpE.js","assets/profiles-service.api-ChoKrL0l.js","assets/llm-subscription-service-BpJ0ouQo.js","assets/llm-subscription-DTqtBCWz.js","assets/acp-providers-CX3Lh9gj.js","assets/skill-enablement-DXeaImBz.js","assets/use-agent-profiles-Bd9Bvvp1.js","assets/plugins-management-service-BMJgC3Ga.js","assets/use-llm-profiles-BO-P4Oyo.js","assets/use-create-secret-B9cUFWRG.js","assets/use-automations-xijQKIl9.js","assets/automation-C_eCrGyP.js","assets/scroll-fade-state-Dw-i4SGq.js","assets/chat-send-button-MUQqCZCS.js","assets/check-CS0vmpQQ.js","assets/circle-check-DzWLNsbE.js","assets/use-acp-credential-form-XIQmpX6M.js","assets/loader-circle-CC1au6hc.js","assets/use-get-secrets-K3jmk-LH.js","assets/llm-settings-De1d5dfr.js","assets/back-nav-button-Cjl_hoxq.js","assets/navigation-link-Bxo3-4vo.js","assets/map-provider-Cu3Zgumb.js","assets/external-link-DKUlnCQV.js","assets/triangle-alert-CtdXWHUI.js","assets/use-can-manage-org-profiles-CrJP5262.js","assets/dropdown-classes-Bc1djN0-.js","assets/badge-BU3S0VtE.js","assets/base-modal-D_L0oEbG.js","assets/sdk-section-page-BlFiizlG.js","assets/switch-skeleton-DwOoCqaL.js","assets/schema-field-D-y9-LDb.js","assets/dist-Bl64nBZL.js","assets/settings-dropdown-input-BcwylHs2.js","assets/settings-switch-CS-dJDmA.js","assets/toggle-switch-ChOLXv2n.js","assets/use-is-authed-nTBcM7dE.js","assets/typography-v1KN0tzi.js","assets/use-save-settings-DYqkKv7T.js","assets/copy-to-clipboard-button-Ca8iSkkA.js","assets/copy-Drmhc2jD.js","assets/loading-spinner-BY9N3pOe.js","assets/settings-section-header-context-BOJ_Fbak.js","assets/u-check-circle-BKn1spCL.js","assets/u-edit-DAkcF52u.js","assets/api-error-message-B-XdSk3b.js","assets/format-model-name-CasAP3nd.js","assets/settings-list-classes-BzeSZbF2.js","assets/openhands-logo-BS-Epajy.js","assets/sidebar-onboarding-checklist-storage-BBkeI6Bp.js","assets/use-activate-agent-profile-BLfmvDiG.js","assets/use-save-agent-profile-BUjSsDXK.js","assets/terminal-BUpID2wS.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,xt as n,yt as r}from"./vendor-styling-Ck5D_A2Q.js";import{F as i,R as a,U as o,_ as s,g as c,l,p as u,u as d,z as f}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{n as p}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-rfV8mQ9m.js";import{t as m}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-Chf7vmKB.js";import{M as h,w as g}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-DqZDXfg2.js";import{t as _}from"./useQuery-BSTgq1rl.js";import{r as v}from"./providers-BhMcY5nv.js";import{Et as y,Gt as b,H as x,Ot as ee,Pt as S,R as C,Tt as w,Y as T,Zt as E,_ as te,dt as D,kt as ne,n as re,q as O,r as k}from"./active-backend-context-CrHTlgvN.js";import{W as A}from"./utils-CN5ZfZy1.js";import{n as j,o as M,r as N,t as P}from"./use-onboarding-completion-D8U7k4Qb.js";import{t as F}from"./loading-spinner-BY9N3pOe.js";import{t as I}from"./use-config-A9QovgXO.js";import{n as L}from"./use-settings-DSXLbvBl.js";import{t as R}from"./use-save-settings-DYqkKv7T.js";import{t as z}from"./modal-backdrop-BSzNhM4r.js";import{n as B}from"./modal-body-BxZjsju9.js";import{n as V,r as H}from"./base-modal-D_L0oEbG.js";import{t as U}from"./brand-button-BAfk4wGP.js";import{t as W}from"./navigation-context-CQZwH_tC.js";import{i as G,n as K}from"./color-themes-DTj5Ylbr.js";var q=e(t(),1),ie=`/api/authenticate`,J=`/login`,Y=`returnTo`,ae=new Set([`localhost`,`127.0.0.1`,`::1`]);function oe(){return typeof window>`u`?`/`:`${window.location.pathname}${window.location.search}${window.location.hash}`}function se(){return typeof window>`u`?!1:ae.has(window.location.hostname)}function ce(){return w()===`cookie`&&!se()}async function le(){try{return await h.post(ie,null,{withCredentials:!0}),!0}catch(e){if(h.isAxiosError(e)&&e.response?.status===401)return!1;throw e}}function ue(e=oe()){return`${J}?${new URLSearchParams({[Y]:e}).toString()}`}function de(){typeof window>`u`||window.location.assign(ue())}var X=r();function fe({backend:e,onChoice:t}){let{t:n,ready:r}=m(b),i=M([e])[e.id]?.isConnected===!0,{data:a,isSuccess:o}=L(),{mutateAsync:s,isPending:c}=R(),[l,u]=q.useState(!1),[d,f]=q.useState(!1);q.useEffect(()=>{f(!1)},[e.id]);let p=i&&o&&a?.user_consents_to_analytics===null&&!d;return q.useEffect(()=>{if(r&&p){let e=setTimeout(()=>u(!0),50);return()=>clearTimeout(e)}u(!1)},[r,p]),!p||!l?null:(0,X.jsx)(z,{elevated:!0,"aria-label":n(A.TELEMETRY$CONSENT_TITLE),children:(0,X.jsx)(`form`,{"data-testid":`telemetry-consent-form`,onSubmit:async e=>{e.preventDefault();let n=new FormData(e.currentTarget).get(`analytics`)===`on`;try{await s({user_consents_to_analytics:n})}catch{return}f(!0),await te(n?`granted`:`denied`),t?.(n)},className:`flex flex-col gap-2`,children:(0,X.jsxs)(B,{className:`border border-[var(--oh-border)]`,children:[(0,X.jsx)(H,{title:n(A.TELEMETRY$CONSENT_TITLE)}),(0,X.jsx)(V,{children:n(A.TELEMETRY$CONSENT_DESCRIPTION)}),(0,X.jsx)(`p`,{className:`text-xs text-neutral-400`,children:n(A.TELEMETRY$BACKEND_SCOPE,{name:e.name,host:e.host})}),(0,X.jsxs)(`label`,{className:`flex gap-2 items-center self-start text-sm cursor-pointer`,children:[(0,X.jsx)(`input`,{name:`analytics`,type:`checkbox`,defaultChecked:!0,className:`w-4 h-4 cursor-pointer`}),n(A.TELEMETRY$SEND_ANONYMOUS_DATA)]}),(0,X.jsx)(U,{testId:`confirm-telemetry-preferences`,type:`submit`,variant:`primary`,className:`w-full`,isDisabled:c,children:n(A.TELEMETRY$CONFIRM_PREFERENCES)})]})})})}function Z({onChoice:e}){let{backend:t}=re();return y()!==null||t.kind!==`local`?null:(0,X.jsx)(fe,{backend:t,onChoice:e})}function pe(){return q.useEffect(()=>{K(G())},[]),null}var me=q.lazy(()=>n(()=>import(`./manage-backends-modal-BrPV3oB-.js`).then(e=>e.n).then(e=>({default:e.ManageBackendsModal})),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36]))),Q=q.lazy(()=>n(()=>import(`./api-key-entry-screen-qTzrmJcr.js`),__vite__mapDeps([37,1,2,3,4,5,6,7,8,10,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30]))),he=q.lazy(()=>n(()=>import(`./onboarding-modal-rkyBYkeQ.js`).then(e=>e.n).then(e=>({default:e.OnboardingModal})),__vite__mapDeps([38,1,2,3,4,5,6,7,15,8,39,40,41,14,16,17,18,42,43,44,45,46,23,24,25,47,26,28,48,9,49,30,50,51,52,53,54,29,55,56,20,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,10,11,12,13,19,21,22,27,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108]))),ge=q.lazy(()=>n(()=>import(`./backend-form-modal-lhGwzXFI.js`).then(e=>e.i).then(e=>({default:e.BackendFormModal})),__vite__mapDeps([10,1,2,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30])));function _e({children:e}){return(0,X.jsxs)(`html`,{lang:`en`,children:[(0,X.jsxs)(`head`,{children:[(0,X.jsx)(`meta`,{charSet:`utf-8`}),(0,X.jsx)(`meta`,{name:`viewport`,content:`width=device-width, initial-scale=1`}),(0,X.jsx)(d,{}),(0,X.jsx)(l,{})]}),(0,X.jsxs)(`body`,{"data-agent-server-ui":``,className:`m-0`,children:[(0,X.jsxs)(v,{contentClassName:`min-h-screen`,children:[(0,X.jsx)(pe,{}),e,(0,X.jsx)(g,{toastOptions:S}),(0,X.jsx)(`div`,{id:`modal-portal-exit`})]}),(0,X.jsx)(s,{}),(0,X.jsx)(c,{})]})]})}function $(){return(0,X.jsx)(`main`,{className:`min-h-screen bg-base px-6 py-10 text-white`,children:(0,X.jsx)(`div`,{className:`mx-auto flex min-h-screen max-w-6xl items-center justify-center`,children:(0,X.jsx)(`div`,{className:`rounded-3xl border border-white/10 bg-base/80 px-8 py-10 shadow-2xl`,children:(0,X.jsx)(F,{size:`large`})})})})}function ve(){let e=p(),t=q.useCallback(()=>{D()&&(x(),e.invalidateQueries({queryKey:C.WEB_CLIENT_CONFIG}))},[e]);return(0,X.jsx)(`main`,{"data-testid":`agent-server-onboarding-screen`,className:`min-h-screen bg-base`,children:(0,X.jsx)(q.Suspense,{fallback:null,children:(0,X.jsx)(me,{onClose:t,recoveryMode:!0})})})}function ye({onClose:e}){let t=i(),n=a(),r=f(),o=t.pathname.match(/^\/conversations\/([^/]+)/)?.[1]??null,s=q.useMemo(()=>({currentPath:t.pathname,conversationId:o,isNavigating:!!r.location,navigate:(e,t)=>n(e,t)}),[o,t.pathname,n,r.location]);return y()===null?(0,X.jsx)(`main`,{"data-testid":`first-run-onboarding-screen`,className:`min-h-screen bg-base`,children:(0,X.jsx)(W,{value:s,children:(0,X.jsx)(q.Suspense,{fallback:(0,X.jsx)($,{}),children:(0,X.jsx)(he,{onClose:e})})})}):(0,X.jsx)(`main`,{"data-testid":`first-run-onboarding-screen`,className:`min-h-screen bg-base`,children:(0,X.jsx)(q.Suspense,{fallback:(0,X.jsx)($,{}),children:(0,X.jsx)(ge,{mode:`add`,onClose:e,source:`manage_backends_modal`,hideCloseButton:!0})})})}var be=()=>[{rel:`icon`,type:`image/svg+xml`,href:E(`/favicon.svg`)}],xe=()=>[{title:`OpenHands`},{name:`description`,content:`Let's Start Building!`}],Se=o(function(){let e=ee(),t=!!D()?.apiKey,n=e&&!t,{active:r}=k(),i=y(),a=w(),o=i!==null,s=o&&r.backend.kind===`cloud`&&ne(r.backend.host,i),{isCompleted:c,markCompleted:l}=P(),d=ce(),f=o?!d&&(!s||a!==`cookie`&&!c):!c,p=_({queryKey:C.MAIN_APP_COOKIE_AUTH,queryFn:le,enabled:d&&!f,retry:!1,staleTime:1e3*60*5,meta:{disableToast:!0}}),m=d&&!f&&p.isPending&&!p.isError,h=d&&p.data===!1,g=!d||p.data===!0||p.isError;q.useEffect(()=>{h&&de()},[h]);let v=I({enabled:!n&&!f&&g}),b=M(r.backend.kind===`cloud`&&g?[r.backend]:[])[r.backend.id],x=r.backend.kind===`cloud`&&b?.isConnected===!1&&N(b.lastError),S=r.backend.kind===`cloud`&&b?.disabled===!0&&j(b.lastError);return f?(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)(ye,{onClose:l}),(0,X.jsx)(Z,{})]}):m||h?(0,X.jsx)($,{}):n||O(v.error)?(0,X.jsx)(q.Suspense,{fallback:(0,X.jsx)($,{}),children:(0,X.jsx)(Q,{})}):v.isPending||v.isLoading?(0,X.jsx)($,{}):x||S||T(v.error)?(0,X.jsx)(ve,{}):(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)(u,{}),(0,X.jsx)(Z,{})]})});export{_e as Layout,Se as default,be as links,xe as meta};
|