@openhands/agent-canvas 1.15.0 → 1.17.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 +15 -1
- package/README.windows.md +2 -2
- package/build/assets/{acp-providers-BKvmTf82.js → acp-providers-DrjNsPOH.js} +1 -1
- package/build/assets/active-backend-context-rZiLJRUc.js +2 -0
- package/build/assets/{agent-context-settings-D3PjSTU1.js → agent-context-settings-CJUrcBut.js} +1 -1
- package/build/assets/agent-profiles-service.api-Biieml2L.js +1 -0
- package/build/assets/agent-profiles-settings-x6RvPsq7.js +1 -0
- package/build/assets/agent-server-client-options-BikiNwTa.js +1 -0
- package/build/assets/agent-server-conversation-service.api-DYFsNHKf.js +88 -0
- package/build/assets/agent-settings-BJyovpJ_.js +1 -0
- package/build/assets/agent-settings-CpY3zObk.js +2 -0
- package/build/assets/alert-banner-vARz1idS.js +1 -0
- package/build/assets/{api-error-message-BJyfWp6p.js → api-error-message-Ve79qDcN.js} +1 -1
- package/build/assets/api-key-entry-screen-CsMuBhoP.js +1 -0
- package/build/assets/{app-settings-CbHqzQus.js → app-settings-BaJ7nfHt.js} +1 -1
- package/build/assets/automation-detail-CVoGDrKq.js +3 -0
- package/build/assets/{automation-export-BRopEHMu.js → automation-export-DxY47m3T.js} +1 -1
- package/build/assets/automation-git-sync-CRMP9Bbm.js +1 -0
- package/build/assets/automation-setup-route-072beLz1.js +3 -0
- package/build/assets/{automation-templates-C_0FZgLG.js → automation-templates-4C4PM8K7.js} +1 -1
- package/build/assets/automations-list-xuqTSQL4.js +1 -0
- package/build/assets/{back-nav-button-Dm9tIjVf.js → back-nav-button-B8tH0BEp.js} +1 -1
- package/build/assets/backend-form-modal-0aJmWdsa.js +1 -0
- package/build/assets/{backend-synced-settings-badge-3fOwg6Bd.js → backend-synced-settings-badge-B7rKWBir.js} +1 -1
- package/build/assets/{badge-D4SqUCsR.js → badge-CcGx2TaV.js} +1 -1
- package/build/assets/{base-modal-C7_BDl_U.js → base-modal-DTULovNc.js} +1 -1
- package/build/assets/bot-CLMxGFaq.js +1 -0
- package/build/assets/{brand-button-Dxv6PDeN.js → brand-button-DxPO4Lf8.js} +1 -1
- package/build/assets/browser-C-_qBasq.js +46 -0
- package/build/assets/{browser-tab-BAl4ckJE.js → browser-tab-DZanIw5m.js} +1 -1
- package/build/assets/canvas-extension-page-o_cWgE9B.js +1 -0
- package/build/assets/canvas-extensions-DSgNlCha.js +1 -0
- package/build/assets/canvas-extensions-runtime-DdnkgJXV.js +1 -0
- package/build/assets/{chat-send-button-DWwR2cgI.js → chat-send-button-B3SFSIg5.js} +1 -1
- package/build/assets/check-fDEfgSzj.js +1 -0
- package/build/assets/chevron-down-CFrWHqu8.js +1 -0
- package/build/assets/chevron-right-C5roOrJu.js +1 -0
- package/build/assets/circle-check-ClTzJTdb.js +1 -0
- package/build/assets/{circle-plus-check-toggle-CBh_qomE.js → circle-plus-check-toggle-Fr-h-mbL.js} +1 -1
- package/build/assets/{cloud-funnel-analytics-287iIERo.js → cloud-funnel-analytics-BQanUEEC.js} +1 -1
- package/build/assets/{cog-C4rrw-ZK.js → cog-VBlRo6iw.js} +1 -1
- package/build/assets/command-menu-BT3Ia5Ru.js +1 -0
- package/build/assets/commits-tab-2jhtaohl.js +1 -0
- package/build/assets/{condenser-settings-BcNmYR4s.js → condenser-settings-eVKFMvap.js} +1 -1
- package/build/assets/confirmation-modal-gIFHeZt6.js +1 -0
- package/build/assets/{context-menu-list-item-lVYETtY5.js → context-menu-list-item-DDROe12Z.js} +1 -1
- package/build/assets/conversation-BnjJSFf5.js +93 -0
- package/build/assets/conversation-DZ578rOX.js +1 -0
- package/build/assets/conversation-panel-DZ578rOX.js +1 -0
- package/build/assets/conversation-state-store-D1_G_9I-.js +1 -0
- package/build/assets/{conversation-store-Ca3ghXap.js → conversation-store-DVVfkCsk.js} +1 -1
- package/build/assets/{conversation-tab-empty-state-HJtkmHZj.js → conversation-tab-empty-state-DKlzAz5c.js} +1 -1
- package/build/assets/{copy-to-clipboard-button-Cjkswvnj.js → copy-to-clipboard-button-B3w0X7WH.js} +1 -1
- package/build/assets/{device-verify-EZhHhBT7.js → device-verify-BfkCzyFB.js} +1 -1
- package/build/assets/{dropdown-classes-DJe-E6MC.js → dropdown-classes-B9kJVDIk.js} +1 -1
- package/build/assets/edit-automation-modal-BwhJ39JT.js +1 -0
- package/build/assets/empty-state-RZz0OfnY.js +1 -0
- package/build/assets/{entry.client-C7Bi2tkU.js → entry.client-Ds8LVp-E.js} +2 -2
- package/build/assets/enum-filter-dropdown-C4pW0ORd.js +1 -0
- package/build/assets/{environment-switch-overlay-CEKrFiMw.js → environment-switch-overlay-P2ZAuzov.js} +1 -1
- package/build/assets/{error-state-BALXiBNy.js → error-state-B_5cgNPJ.js} +1 -1
- package/build/assets/extensions-hub-DsaUr4ca.js +1 -0
- package/build/assets/extensions-navigation-CRMZd-FE.js +1 -0
- package/build/assets/external-link-DQtv7eTh.js +1 -0
- package/build/assets/files-tab-CCgAcVdc.js +1 -0
- package/build/assets/{form-control-classes-CGw40z5h.js → form-control-classes-B-z85REi.js} +1 -1
- package/build/assets/format-model-name-CasAP3nd.js +1 -0
- package/build/assets/get-git-path-EHrSDxTM.js +1 -0
- package/build/assets/git-repo-dropdown-D2WEQ97X.js +1 -0
- package/build/assets/{git-repo-dropdown-ai8qaNkD.js → git-repo-dropdown-DVeCUUXG.js} +1 -1
- package/build/assets/{highlighted-source-view-C3sxykQi.js → highlighted-source-view-DjHO3SdW.js} +1 -1
- package/build/assets/home-BorS_vdS.js +1 -0
- package/build/assets/home-aIMbHw5M.js +1 -0
- package/build/assets/home-automation-run-tooltip-CpHNFiFl.js +1 -0
- package/build/assets/home-store-DyXz0w6d.js +1 -0
- package/build/assets/hooks-service-C6dpRtZM.js +1 -0
- package/build/assets/index-home-zKFuKK2B.js +1 -0
- package/build/assets/info-CTIdjttz.js +1 -0
- package/build/assets/install-server-modal-DUiZMc8u.js +1 -0
- package/build/assets/kebab-menu-item-content-mm04SBD3.js +1 -0
- package/build/assets/{key-Cn5za3rg.js → key-CfXbJa8w.js} +1 -1
- package/build/assets/{launch-C1ieiOGe.js → launch-BSIf9KEg.js} +1 -1
- package/build/assets/list-filter-CNpqTWVY.js +1 -0
- package/build/assets/{list-todo-Cuu-STFc.js → list-todo-ByXMdY4W.js} +1 -1
- package/build/assets/llm-not-configured-banner-z_QRSeV0.js +27 -0
- package/build/assets/llm-settings-B-5AHMiX.js +1 -0
- package/build/assets/llm-settings-B3SjHDmA.js +1 -0
- package/build/assets/llm-subscription-service-aDNBQ7Gq.js +1 -0
- package/build/assets/loader-circle-Dex47vVW.js +1 -0
- package/build/assets/{loading-spinner-0L3ZTToZ.js → loading-spinner-DfHI77BA.js} +1 -1
- package/build/assets/manage-backends-modal-q1NdFisr.js +1 -0
- package/build/assets/manifest-8920b615.js +1 -0
- package/build/assets/{manifest-subpage-layout-BGhiUQbA.js → manifest-subpage-layout-BQQy5ipR.js} +1 -1
- package/build/assets/{map-provider-B9LTm23I.js → map-provider-DXvssjw9.js} +1 -1
- package/build/assets/markdown-renderer-rivLvYh-.js +8 -0
- package/build/assets/{mcp-CKbR4Vft.js → mcp-CEXDhQWn.js} +1 -1
- package/build/assets/{mcp-marketplace-utils-C13fFccR.js → mcp-marketplace-utils-Cn_NIMWM.js} +1 -1
- package/build/assets/mcp-page-LGYIICMG.js +9 -0
- package/build/assets/messages-DUSeANAh.js +41 -0
- package/build/assets/{modal-body-CMOc2tLl.js → modal-body-DJw4xBki.js} +1 -1
- package/build/assets/{modal-classes-BAb4Y_BG.js → modal-classes-Dg0ngBPO.js} +1 -1
- package/build/assets/{modal-close-button-CkJ0Ktjj.js → modal-close-button-B9j4nasm.js} +1 -1
- package/build/assets/{mouse-pointer-click-CsgRs_-r.js → mouse-pointer-click-DEhsSUpu.js} +1 -1
- package/build/assets/onboarding-BjFebfs5.js +1 -0
- package/build/assets/onboarding-modal-DDTjOpyd.js +1 -0
- package/build/assets/organization-service.api-Cyg1Tn03.js +1 -0
- package/build/assets/pencil-D5c47kyN.js +1 -0
- package/build/assets/pin-C7vMagvf.js +1 -0
- package/build/assets/planner-tab-D8f2Y3rn.js +1 -0
- package/build/assets/plug-CeaqeF6u.js +1 -0
- package/build/assets/plugins-management-service-Bh_pBuf-.js +1 -0
- package/build/assets/plus-B3wvU06-.js +1 -0
- package/build/assets/profiles-service.api-BbOK0EkF.js +1 -0
- package/build/assets/providers-2gIIkz2N.js +1 -0
- package/build/assets/proxy-CBgMd2zf.js +1 -0
- package/build/assets/{puzzle-A9pGxxai.js → puzzle-DdAqbUrb.js} +1 -1
- package/build/assets/recommended-automations-launcher-YLAQTp4s.js +1 -0
- package/build/assets/refresh-cw-DEQdPCpH.js +1 -0
- package/build/assets/root-Bye_XmEL.js +2 -0
- package/build/assets/root-Cnwwzgo0.css +1 -0
- package/build/assets/root-layout-CSAwxBGM.js +2 -0
- package/build/assets/schema-field-CK0xYNbO.js +1 -0
- package/build/assets/scroll-fade-state-Dt_fx2kf.js +1 -0
- package/build/assets/sdk-section-page-Da73Rs_o.js +1 -0
- package/build/assets/secret-form-CB2VwYYg.js +1 -0
- package/build/assets/secrets-service-Cr8g8xuv.js +1 -0
- package/build/assets/{secrets-settings-BizaTEr1.js → secrets-settings-Bh0udeKv.js} +1 -1
- package/build/assets/settings-CKqk8ZnH.js +1 -0
- package/build/assets/settings-DmyIgRxO.js +1 -0
- package/build/assets/{settings-dropdown-input-tM0A0ipy.js → settings-dropdown-input-DVpyD87C.js} +1 -1
- package/build/assets/settings-index-BSJUFmjE.js +1 -0
- package/build/assets/{settings-input-C03KUoSC.js → settings-input-C0dd8Utu.js} +1 -1
- package/build/assets/{settings-list-classes-BJ0g8rWj.js → settings-list-classes-Ds4jPBHK.js} +1 -1
- package/build/assets/{settings-modal-AzEF1QPP.js → settings-modal-yStgEh2o.js} +1 -1
- package/build/assets/settings-service.api-9_xdv_mh.js +1 -0
- package/build/assets/{settings-switch-CQE0EGC-.js → settings-switch-B78Khmyz.js} +1 -1
- package/build/assets/{settings-utils-ClYOkbbI.js → settings-utils-8GIIgOQL.js} +1 -1
- package/build/assets/shared-conversation-DM96X4KV.js +1 -0
- package/build/assets/shield-check-DO7wa_eu.js +1 -0
- package/build/assets/{sidebar-layout-D3hE08wK.js → sidebar-layout-EPfWxk11.js} +1 -1
- package/build/assets/sidebar-mobile-menu-toggle-D5GR5xT9.js +1 -0
- package/build/assets/sidebar-nav-link-_t4_Ef-9.js +1 -0
- package/build/assets/{sidebar-onboarding-checklist-storage-3qYflszY.js → sidebar-onboarding-checklist-storage-DbDX-Wvj.js} +1 -1
- package/build/assets/sidebar-store-CSDFK0W5.js +1 -0
- package/build/assets/{skill-card-pill-row-CFxjoqxn.js → skill-card-pill-row-989y15jV.js} +1 -1
- package/build/assets/skill-enablement-DXeaImBz.js +1 -0
- package/build/assets/skill-filter-BBeZ4JEP.js +2 -0
- package/build/assets/{skill-icon-badge-CPQJ6A-I.js → skill-icon-badge-BDhQ-tQ0.js} +1 -1
- package/build/assets/skill-scope-Dz3kPH3P.js +1 -0
- package/build/assets/skills-plugins-e3CYGdUJ.js +1 -0
- package/build/assets/skills-settings-3e-FuHw_.js +1 -0
- package/build/assets/styled-tooltip-Pd22BIvr.js +1 -0
- package/build/assets/{task-list-tab-04GNQuii.js → task-list-tab-3Jg8ywch.js} +1 -1
- package/build/assets/{terminal-Cj0iHIW7.js → terminal-onXx0_Qz.js} +1 -1
- package/build/assets/toggle-switch-lwQtxDcm.js +1 -0
- package/build/assets/trash-2-ZhKuTLiz.js +1 -0
- package/build/assets/trash-B6OIe4yX.js +1 -0
- package/build/assets/triangle-alert-BajLPpQg.js +1 -0
- package/build/assets/{typography-SgFy466J.js → typography-HLLg_FAn.js} +1 -1
- package/build/assets/usage-tab-Cm-9j3UK.js +1 -0
- package/build/assets/use-acp-credential-form-BARcvjYE.js +1 -0
- package/build/assets/use-activate-agent-profile-BLKML6vQ.js +1 -0
- package/build/assets/use-agent-profiles-1P91KSXz.js +1 -0
- package/build/assets/{use-automation-health-BxXdzZMP.js → use-automation-health-BZkQNEA8.js} +1 -1
- package/build/assets/use-automation-permissions-B_RpvL-s.js +1 -0
- package/build/assets/{use-automations-zYb0dUny.js → use-automations-Cg0PDIZr.js} +1 -1
- package/build/assets/{use-can-manage-org-profiles-BWMahtUh.js → use-can-manage-org-profiles-BbN6KfDr.js} +1 -1
- package/build/assets/use-canvas-extensions-CFUpHat6.js +1 -0
- package/build/assets/{use-cloud-current-user-id-CPHMDG-C.js → use-cloud-current-user-id-Dk0rjr63.js} +1 -1
- package/build/assets/use-config-DpafU_QP.js +1 -0
- package/build/assets/use-create-conversation-1YgmAHt-.js +1 -0
- package/build/assets/use-create-secret-D8p9ybQj.js +1 -0
- package/build/assets/{use-get-secrets-BT4ihRwj.js → use-get-secrets-CQ4b0qK8.js} +1 -1
- package/build/assets/use-is-authed-BRPjCRKM.js +1 -0
- package/build/assets/{use-launch-skill-in-chat-BYjYihBP.js → use-launch-skill-in-chat-DeYa1tFM.js} +1 -1
- package/build/assets/use-llm-configured-DGm8FiRR.js +1 -0
- package/build/assets/use-llm-profiles-BTTtpW4z.js +1 -0
- package/build/assets/use-manifest-capabilities-AOWGcu0j.js +1 -0
- package/build/assets/use-onboarding-completion-CoINurkm.js +1 -0
- package/build/assets/use-pinned-home-route-D6krwXjy.js +1 -0
- package/build/assets/use-plugins-marketplace-mLsIDhBv.js +1 -0
- package/build/assets/use-save-agent-profile-CxyO9YG-.js +1 -0
- package/build/assets/{use-save-settings-CUZW6yXP.js → use-save-settings-3U5K9-8x.js} +1 -1
- package/build/assets/use-settings-Dn00UISA.js +1 -0
- package/build/assets/use-settings-nav-items-vrjxTqcu.js +16 -0
- package/build/assets/use-tracking-B9prBsrq.js +3 -0
- package/build/assets/{use-user-conversation-DT0_QCnL.js → use-user-conversation-ZWlXtbZb.js} +1 -1
- package/build/assets/{useInfiniteQuery-CgeUQPfs.js → useInfiniteQuery-BzrRqjLg.js} +1 -1
- package/build/assets/{useMutation-DFnzkf6f.js → useMutation-CJuK90oc.js} +1 -1
- package/build/assets/{useQueries-BhbrGEf1.js → useQueries-CykmpT-a.js} +1 -1
- package/build/assets/{useQuery-BXWbZBZl.js → useQuery-S6j94er1.js} +1 -1
- package/build/assets/utils-BOco8mxR.js +1 -0
- package/build/assets/{vendor~conversation-panel~conversation-CTvDDiXg.js → vendor~conversation-panel~conversation-4eJ0tml3.js} +1 -1
- package/build/assets/{vendor~entry.client-BFE7Llz9.js → vendor~entry.client-CoCfUXUF.js} +1 -1
- package/build/assets/{vendor~entry.client-BaKt_PIp.js → vendor~entry.client-DA2izTjq.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-BfkNGovw.js +185 -0
- package/build/assets/{vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew3u153i-rfV8mQ9m.js → vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-DnDoaYNi.js} +1 -1
- package/build/assets/{vendor~index-home~home~conversation-panel~conversation-BTyukeM-.js → vendor~index-home~home~conversation-panel~conversation-CSFLzmTN.js} +1 -1
- package/build/assets/vendor~root-layout-n8XCEXG8.js +1 -0
- package/build/assets/{vendor~root-layout~conversation-panel~conversation-BYAWJwQX.js → vendor~root-layout~conversation-panel~conversation-3Idg1_U3.js} +1 -1
- package/build/assets/{vendor~root-layout~conversation-panel~conversation~skills-settings~automations-list~shared-~bovqqk8e-CHaLEBVR.js → vendor~root-layout~conversation-panel~conversation~skills-settings~automations-list~shared-~bovqqk8e-DkPlXWl9.js} +1 -1
- package/build/assets/vendor~root-layout~index-home~home~conversation-panel~conversation-DgQ564nC.js +1 -0
- 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~hjcjabwg-Dtu7BpYk.js → vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~inibp4qe-CnsDDzeE.js} +2 -2
- package/build/assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js +1 -0
- package/build/assets/{vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-DonTKfQD.js → vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-BPjI-atc.js} +125 -15
- package/build/assets/{vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~jz4f6vo2-BgxDvUcf.js → vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~jz4f6vo2-C7HiY4Ae.js} +42 -3
- package/build/assets/{verification-settings-Bj6bo097.js → verification-settings-u2POabjH.js} +1 -1
- package/build/assets/{wrench-hi7Q13dF.js → wrench-CkgI4rxA.js} +1 -1
- package/build/assets/x-By6qCmtY.js +1 -0
- package/build/index.html +4 -4
- package/build/locales/ar/openhands.json +94 -25
- package/build/locales/ca/openhands.json +94 -25
- package/build/locales/de/openhands.json +94 -25
- package/build/locales/en/openhands.json +94 -25
- package/build/locales/es/openhands.json +94 -25
- package/build/locales/fr/openhands.json +94 -25
- package/build/locales/it/openhands.json +94 -25
- package/build/locales/ja/openhands.json +94 -25
- package/build/locales/ko-KR/openhands.json +94 -25
- package/build/locales/no/openhands.json +94 -25
- package/build/locales/pt/openhands.json +94 -25
- package/build/locales/tr/openhands.json +94 -25
- package/build/locales/uk/openhands.json +94 -25
- package/build/locales/zh-CN/openhands.json +94 -25
- package/build/locales/zh-TW/openhands.json +94 -25
- package/config/defaults.json +9 -5
- package/dist/api/agent-profiles-service/profile-field-support.d.ts +26 -0
- 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 +249 -145
- package/dist/api/agent-server-adapter.js.map +1 -1
- package/dist/api/agent-server-compatibility.cjs +1 -1
- package/dist/api/agent-server-compatibility.cjs.map +1 -1
- package/dist/api/agent-server-compatibility.d.ts +21 -0
- package/dist/api/agent-server-compatibility.js +52 -38
- package/dist/api/agent-server-compatibility.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 +32 -0
- package/dist/api/agent-server-config.js +21 -5
- 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/canvas-extensions-service.cjs +1 -0
- package/dist/api/canvas-extensions-service.d.ts +22 -0
- package/dist/api/canvas-extensions-service.js +4 -0
- package/dist/api/cloud/conversation-service.api.cjs +1 -1
- package/dist/api/cloud/conversation-service.api.cjs.map +1 -1
- package/dist/api/cloud/conversation-service.api.d.ts +6 -0
- package/dist/api/cloud/conversation-service.api.js +14 -6
- package/dist/api/cloud/conversation-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/conversation-file-upload.api.cjs +1 -1
- package/dist/api/conversation-file-upload.api.js +10 -10
- 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 +31 -0
- package/dist/api/conversation-service/agent-server-conversation-service.api.js +188 -128
- package/dist/api/conversation-service/agent-server-conversation-service.api.js.map +1 -1
- package/dist/api/event-service/event-service.api.cjs +1 -1
- package/dist/api/event-service/event-service.api.js +12 -12
- package/dist/api/git-service/agent-server-git-service.api.cjs +1 -1
- package/dist/api/git-service/agent-server-git-service.api.js +8 -8
- 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/runtime-service/agent-server-runtime-service.cjs +1 -1
- package/dist/api/runtime-service/agent-server-runtime-service.js +8 -8
- 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 +5 -2
- package/dist/api/settings-service/settings-service.api.js +20 -11
- 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/event-group.cjs +1 -1
- package/dist/components/conversation-events/chat/event-message-components/event-group.cjs.map +1 -1
- package/dist/components/conversation-events/chat/event-message-components/event-group.js +40 -36
- package/dist/components/conversation-events/chat/event-message-components/event-group.js.map +1 -1
- 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 +118 -102
- 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 +88 -77
- package/dist/components/features/automations/automation-list-row.js.map +1 -1
- package/dist/components/features/automations/detail/detail-header.d.ts +3 -1
- package/dist/components/features/automations/detail/run-phase.cjs +2 -0
- package/dist/components/features/automations/detail/run-phase.cjs.map +1 -0
- package/dist/components/features/automations/detail/run-phase.d.ts +89 -0
- package/dist/components/features/automations/detail/run-phase.js +72 -0
- package/dist/components/features/automations/detail/run-phase.js.map +1 -0
- 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-form-modal.cjs +1 -1
- package/dist/components/features/backends/backend-form-modal.cjs.map +1 -1
- package/dist/components/features/backends/backend-form-modal.js +5 -11
- package/dist/components/features/backends/backend-form-modal.js.map +1 -1
- 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 +133 -122
- 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/canvas-extensions/add-canvas-extension-modal.d.ts +6 -0
- package/dist/components/features/canvas-extensions/canvas-extension-card.d.ts +9 -0
- package/dist/components/features/canvas-extensions/canvas-extensions-runtime.cjs +2 -0
- package/dist/components/features/canvas-extensions/canvas-extensions-runtime.cjs.map +1 -0
- package/dist/components/features/canvas-extensions/canvas-extensions-runtime.d.ts +23 -0
- package/dist/components/features/canvas-extensions/canvas-extensions-runtime.js +19 -0
- package/dist/components/features/canvas-extensions/canvas-extensions-runtime.js.map +1 -0
- 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 +107 -104
- package/dist/components/features/chat/chat-interface.js.map +1 -1
- package/dist/components/features/chat/chat-markdown-path-code.cjs +3 -0
- package/dist/components/features/chat/chat-markdown-path-code.cjs.map +1 -0
- package/dist/components/features/chat/chat-markdown-path-code.d.ts +27 -0
- package/dist/components/features/chat/chat-markdown-path-code.js +72 -0
- package/dist/components/features/chat/chat-markdown-path-code.js.map +1 -0
- 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/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/path-component.cjs +1 -1
- package/dist/components/features/chat/path-component.cjs.map +1 -1
- package/dist/components/features/chat/path-component.d.ts +8 -2
- package/dist/components/features/chat/path-component.js +33 -21
- package/dist/components/features/chat/path-component.js.map +1 -1
- package/dist/components/features/chat/tool-visualizers/file-editor/file-editor.cjs +1 -1
- package/dist/components/features/chat/tool-visualizers/file-editor/file-editor.cjs.map +1 -1
- package/dist/components/features/chat/tool-visualizers/file-editor/file-editor.js +38 -43
- package/dist/components/features/chat/tool-visualizers/file-editor/file-editor.js.map +1 -1
- package/dist/components/features/chat/tool-visualizers/primitives/file-path-chip.cjs +1 -1
- package/dist/components/features/chat/tool-visualizers/primitives/file-path-chip.cjs.map +1 -1
- package/dist/components/features/chat/tool-visualizers/primitives/file-path-chip.d.ts +8 -5
- package/dist/components/features/chat/tool-visualizers/primitives/file-path-chip.js +22 -16
- package/dist/components/features/chat/tool-visualizers/primitives/file-path-chip.js.map +1 -1
- package/dist/components/features/chat/user-message-body.cjs +1 -1
- package/dist/components/features/chat/user-message-body.cjs.map +1 -1
- package/dist/components/features/chat/user-message-body.d.ts +4 -0
- package/dist/components/features/chat/user-message-body.js +30 -24
- package/dist/components/features/chat/user-message-body.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.cjs.map +1 -1
- package/dist/components/features/conversation/conversation-overview-skills-panel.js +63 -81
- package/dist/components/features/conversation/conversation-overview-skills-panel.js.map +1 -1
- 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 +96 -96
- package/dist/components/features/conversation/conversation-tabs/conversation-tabs.js.map +1 -1
- package/dist/components/features/conversation/conversation-tabs/drawer-vscode-link.cjs +1 -1
- package/dist/components/features/conversation/conversation-tabs/drawer-vscode-link.cjs.map +1 -1
- package/dist/components/features/conversation/conversation-tabs/drawer-vscode-link.d.ts +1 -1
- package/dist/components/features/conversation/conversation-tabs/drawer-vscode-link.js +3 -3
- package/dist/components/features/conversation/conversation-tabs/drawer-vscode-link.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/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-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/conversation-panel/skills-modal.cjs +1 -1
- package/dist/components/features/conversation-panel/skills-modal.cjs.map +1 -1
- package/dist/components/features/conversation-panel/skills-modal.js +29 -28
- package/dist/components/features/conversation-panel/skills-modal.js.map +1 -1
- package/dist/components/features/files-tab/file-content-viewer.cjs +1 -1
- package/dist/components/features/files-tab/file-content-viewer.js +5 -5
- 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/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 +59 -37
- package/dist/components/features/home/featured-automations/home-automation-run-tooltip.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/onboarding-host.d.ts +3 -4
- package/dist/components/features/onboarding/steps/setup-llm-step.d.ts +5 -9
- package/dist/components/features/settings/acp-auth-status-banner.d.ts +23 -6
- 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.js +5 -3
- 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 +2 -1
- package/dist/components/features/settings/llm-profiles/profiles-body.d.ts +2 -2
- package/dist/components/features/settings/llm-profiles/provider-connection-modal.cjs +1 -1
- package/dist/components/features/settings/llm-profiles/provider-connection-modal.js +3 -0
- package/dist/components/features/settings/sdk-settings/field-help.cjs +1 -1
- package/dist/components/features/settings/sdk-settings/field-help.cjs.map +1 -1
- package/dist/components/features/settings/sdk-settings/field-help.d.ts +1 -1
- package/dist/components/features/settings/sdk-settings/field-help.js +1 -1
- package/dist/components/features/settings/sdk-settings/field-help.js.map +1 -1
- 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-nav-link.cjs +1 -1
- package/dist/components/features/sidebar/sidebar-nav-link.cjs.map +1 -1
- package/dist/components/features/sidebar/sidebar-nav-link.d.ts +10 -1
- package/dist/components/features/sidebar/sidebar-nav-link.js +54 -36
- package/dist/components/features/sidebar/sidebar-nav-link.js.map +1 -1
- 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 +3 -1
- package/dist/components/features/sidebar/sidebar-rail-body.js +98 -58
- 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 +44 -43
- 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/build-skill-pills.cjs +1 -1
- package/dist/components/features/skills/build-skill-pills.cjs.map +1 -1
- package/dist/components/features/skills/build-skill-pills.js +60 -52
- package/dist/components/features/skills/build-skill-pills.js.map +1 -1
- 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 +54 -43
- package/dist/components/features/skills/extensions-navigation.js.map +1 -1
- package/dist/components/features/skills/skill-filter.cjs +1 -1
- package/dist/components/features/skills/skill-filter.cjs.map +1 -1
- package/dist/components/features/skills/skill-filter.d.ts +8 -3
- package/dist/components/features/skills/skill-filter.js +69 -52
- package/dist/components/features/skills/skill-filter.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/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.js +27 -27
- package/dist/components/shared/modals/settings/settings-form.cjs +1 -1
- package/dist/components/shared/modals/settings/settings-form.js +8 -8
- package/dist/config/defaults.cjs +1 -1
- package/dist/config/defaults.cjs.map +1 -1
- package/dist/config/defaults.js +9 -5
- package/dist/config/defaults.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/extensions/canvas-extension-module-loader.d.ts +11 -0
- 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/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-manage-canvas-extensions.d.ts +12 -0
- 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/concurrency-limiter.cjs +2 -0
- package/dist/hooks/query/concurrency-limiter.cjs.map +1 -0
- package/dist/hooks/query/concurrency-limiter.d.ts +22 -0
- package/dist/hooks/query/concurrency-limiter.js +29 -0
- package/dist/hooks/query/concurrency-limiter.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 +10 -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-active-conversation.cjs +1 -1
- package/dist/hooks/query/use-active-conversation.js +4 -4
- 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-automations.cjs.map +1 -1
- package/dist/hooks/query/use-automations.js.map +1 -1
- package/dist/hooks/query/use-backends-health.cjs +1 -1
- package/dist/hooks/query/use-backends-health.cjs.map +1 -1
- package/dist/hooks/query/use-backends-health.d.ts +1 -1
- package/dist/hooks/query/use-backends-health.js +50 -64
- package/dist/hooks/query/use-backends-health.js.map +1 -1
- package/dist/hooks/query/use-canvas-extensions.cjs +1 -0
- package/dist/hooks/query/use-canvas-extensions.d.ts +5 -0
- package/dist/hooks/query/use-canvas-extensions.js +3 -0
- package/dist/hooks/query/use-commit-changes.cjs +1 -1
- package/dist/hooks/query/use-commit-changes.js +4 -4
- 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-latest-automation-runs.cjs +1 -1
- package/dist/hooks/query/use-latest-automation-runs.js +1 -0
- package/dist/hooks/query/use-paginated-conversations.cjs +1 -1
- package/dist/hooks/query/use-paginated-conversations.cjs.map +1 -1
- package/dist/hooks/query/use-paginated-conversations.js +19 -16
- package/dist/hooks/query/use-paginated-conversations.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-search-providers.cjs +1 -1
- package/dist/hooks/query/use-search-providers.cjs.map +1 -1
- package/dist/hooks/query/use-search-providers.js +17 -10
- 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/query/use-unified-get-git-changes.cjs +1 -1
- package/dist/hooks/query/use-unified-get-git-changes.js +4 -4
- package/dist/hooks/query/use-unified-git-commits.cjs +1 -1
- package/dist/hooks/query/use-unified-git-commits.js +4 -4
- package/dist/hooks/query/use-unified-git-diff.cjs +1 -1
- package/dist/hooks/query/use-unified-git-diff.js +4 -4
- package/dist/hooks/query/use-unified-vscode-url.cjs +1 -1
- package/dist/hooks/query/use-unified-vscode-url.cjs.map +1 -1
- package/dist/hooks/query/use-unified-vscode-url.d.ts +1 -0
- package/dist/hooks/query/use-unified-vscode-url.js +40 -26
- package/dist/hooks/query/use-unified-vscode-url.js.map +1 -1
- package/dist/hooks/query/use-workspace-file-content.cjs +1 -1
- package/dist/hooks/query/use-workspace-file-content.js +5 -5
- package/dist/hooks/query/use-workspace-files.cjs +1 -1
- package/dist/hooks/query/use-workspace-files.js +6 -6
- package/dist/hooks/use-acp-credential-form.d.ts +6 -0
- 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-conversation-overview-git-diff-stats.cjs +1 -1
- package/dist/hooks/use-conversation-overview-git-diff-stats.js +4 -4
- 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.js +1 -0
- 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-pinned-home-route.cjs +2 -0
- package/dist/hooks/use-pinned-home-route.cjs.map +1 -0
- package/dist/hooks/use-pinned-home-route.d.ts +33 -0
- package/dist/hooks/use-pinned-home-route.js +34 -0
- package/dist/hooks/use-pinned-home-route.js.map +1 -0
- package/dist/hooks/use-skill-enablement.cjs +2 -0
- package/dist/hooks/use-skill-enablement.cjs.map +1 -0
- package/dist/hooks/use-skill-enablement.d.ts +14 -0
- package/dist/hooks/use-skill-enablement.js +80 -0
- package/dist/hooks/use-skill-enablement.js.map +1 -0
- 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 +83 -14
- package/dist/i18n/declaration.js +1 -1
- package/dist/i18n/declaration.js.map +1 -1
- package/dist/i18n/translation.cjs +3 -3
- package/dist/i18n/translation.cjs.map +1 -1
- package/dist/i18n/translation.js +1575 -402
- package/dist/i18n/translation.js.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +15 -14
- package/dist/lib/index.cjs +1 -1
- package/dist/lib/index.d.ts +1 -0
- package/dist/lib/index.js +1 -0
- package/dist/locales/ar/openhands.json +94 -25
- package/dist/locales/ca/openhands.json +94 -25
- package/dist/locales/de/openhands.json +94 -25
- package/dist/locales/en/openhands.json +94 -25
- package/dist/locales/es/openhands.json +94 -25
- package/dist/locales/fr/openhands.json +94 -25
- package/dist/locales/it/openhands.json +94 -25
- package/dist/locales/ja/openhands.json +94 -25
- package/dist/locales/ko-KR/openhands.json +94 -25
- package/dist/locales/no/openhands.json +94 -25
- package/dist/locales/pt/openhands.json +94 -25
- package/dist/locales/tr/openhands.json +94 -25
- package/dist/locales/uk/openhands.json +94 -25
- package/dist/locales/zh-CN/openhands.json +94 -25
- package/dist/locales/zh-TW/openhands.json +94 -25
- 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-interface.cjs +1 -1
- package/dist/manifests/automation-interface.cjs.map +1 -1
- package/dist/manifests/automation-interface.d.ts +6 -0
- package/dist/manifests/automation-interface.js +11 -8
- package/dist/manifests/automation-interface.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/bundle-index.cjs +45 -4
- package/dist/node_modules/@openhands/extensions/automations/bundle-index.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/bundle-index.js +1 -1
- package/dist/node_modules/@openhands/extensions/automations/bundle-index.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-agents-md-maintainer/manifest.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-agents-md-maintainer/manifest.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-agents-md-maintainer/manifest.js +5 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-agents-md-maintainer/manifest.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-issue-to-pr/manifest.cjs +2 -2
- 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 +6 -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 +2 -2
- 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 +6 -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/github-repo-monitor/manifest.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-repo-monitor/manifest.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-repo-monitor/manifest.js +5 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/github-repo-monitor/manifest.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-bitbucket-pr/manifest.cjs +9 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-bitbucket-pr/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-bitbucket-pr/manifest.js +21 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-bitbucket-pr/manifest.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-gitlab-mr/manifest.cjs +9 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-gitlab-mr/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-gitlab-mr/manifest.js +21 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/jira-issue-to-gitlab-mr/manifest.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-bitbucket-pr/manifest.cjs +9 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-bitbucket-pr/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-bitbucket-pr/manifest.js +21 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-bitbucket-pr/manifest.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-github-pr/manifest.cjs +9 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-github-pr/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-github-pr/manifest.js +21 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-github-pr/manifest.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-gitlab-mr/manifest.cjs +9 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-gitlab-mr/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-gitlab-mr/manifest.js +21 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/linear-issue-to-gitlab-mr/manifest.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/news-digest/manifest.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/news-digest/manifest.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/news-digest/manifest.js +5 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/news-digest/manifest.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.cjs +30 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.js +65 -0
- package/dist/node_modules/@openhands/extensions/automations/catalog/qa-changes/manifest.js.map +1 -0
- 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 +28 -14
- 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/datadog.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/datadog.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/datadog.js +2 -2
- package/dist/node_modules/@openhands/extensions/integrations/catalog/datadog.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.cjs +2 -0
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.cjs.map +1 -0
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.js +59 -0
- package/dist/node_modules/@openhands/extensions/integrations/catalog/gitlab.js.map +1 -0
- package/dist/node_modules/@openhands/extensions/integrations/catalog/notion.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/notion.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/notion.js +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog/notion.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog-index.cjs +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog-index.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/integrations/catalog-index.js +74 -72
- package/dist/node_modules/@openhands/extensions/integrations/catalog-index.js.map +1 -1
- package/dist/node_modules/@openhands/extensions/skills/index.cjs +42 -3
- package/dist/node_modules/@openhands/extensions/skills/index.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/skills/index.js +22 -3
- package/dist/node_modules/@openhands/extensions/skills/index.js.map +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/conversation/remote-conversation.cjs +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/conversation/remote-conversation.js +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/conversation/remote-state.cjs +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/conversation/remote-state.cjs.map +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/conversation/remote-state.js +8 -7
- package/dist/node_modules/@openhands/typescript-client/dist/conversation/remote-state.js.map +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/index.cjs +1 -1
- package/dist/node_modules/@openhands/typescript-client/dist/index.js +2 -2
- 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/blocks.cjs +2 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/blocks.cjs.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/blocks.js +16 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/blocks.js.map +1 -0
- 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/panels-top-left.cjs +2 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/panels-top-left.cjs.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/panels-top-left.js +23 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/panels-top-left.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 +5 -5
- package/dist/package.js.map +1 -1
- package/dist/routes/agent-settings.d.ts +12 -0
- package/dist/routes/app-settings.cjs +1 -1
- package/dist/routes/app-settings.cjs.map +1 -1
- package/dist/routes/app-settings.js +11 -11
- package/dist/routes/files-tab.cjs +1 -1
- package/dist/routes/files-tab.cjs.map +1 -1
- package/dist/routes/files-tab.js +14 -14
- package/dist/routes/files-tab.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 +100 -91
- 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/canvas-ui.cjs +1 -1
- package/dist/services/canvas-ui.cjs.map +1 -1
- package/dist/services/canvas-ui.d.ts +5 -0
- package/dist/services/canvas-ui.js +24 -10
- package/dist/services/canvas-ui.js.map +1 -1
- package/dist/services/settings.cjs +1 -1
- package/dist/services/settings.cjs.map +1 -1
- package/dist/services/settings.js +3 -2
- package/dist/services/settings.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/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 +66 -1
- package/dist/types/automation.js.map +1 -1
- package/dist/types/canvas-extension.cjs +2 -0
- package/dist/types/canvas-extension.cjs.map +1 -0
- package/dist/types/canvas-extension.d.ts +77 -0
- package/dist/types/canvas-extension.js +6 -0
- package/dist/types/canvas-extension.js.map +1 -0
- package/dist/types/settings.d.ts +7 -0
- package/dist/ui/context-menu.d.ts +1 -1
- package/dist/ui/help-link.cjs +1 -1
- package/dist/ui/help-link.cjs.map +1 -1
- package/dist/ui/help-link.d.ts +6 -1
- package/dist/ui/help-link.js +32 -18
- package/dist/ui/help-link.js.map +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/acp-auth-display.d.ts +35 -0
- 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/cache-utils.cjs +1 -1
- package/dist/utils/cache-utils.js +5 -5
- 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 +7 -3
- package/dist/utils/format-model-name.js +6 -11
- package/dist/utils/format-model-name.js.map +1 -1
- package/dist/utils/format-relative-time.cjs +1 -1
- package/dist/utils/format-relative-time.cjs.map +1 -1
- package/dist/utils/format-relative-time.d.ts +7 -0
- package/dist/utils/format-relative-time.js +7 -2
- package/dist/utils/format-relative-time.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/path-utils.cjs +1 -1
- package/dist/utils/path-utils.cjs.map +1 -1
- package/dist/utils/path-utils.d.ts +15 -3
- package/dist/utils/path-utils.js +29 -3
- package/dist/utils/path-utils.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/skill-enablement.cjs +2 -0
- package/dist/utils/skill-enablement.cjs.map +1 -0
- package/dist/utils/skill-enablement.d.ts +51 -0
- package/dist/utils/skill-enablement.js +31 -0
- package/dist/utils/skill-enablement.js.map +1 -0
- 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/dist/utils/vscode-origin.cjs +2 -0
- package/dist/utils/vscode-origin.cjs.map +1 -0
- package/dist/utils/vscode-origin.d.ts +55 -0
- package/dist/utils/vscode-origin.js +27 -0
- package/dist/utils/vscode-origin.js.map +1 -0
- package/dist/utils/workspace-mode.d.ts +4 -0
- package/package.json +5 -5
- package/scripts/check-sdk-version-sync.mjs +6 -6
- package/scripts/check-translation-completeness.cjs +1 -0
- package/scripts/dev-extra-backend.mjs +28 -9
- package/scripts/dev-safe.mjs +81 -8
- package/scripts/dev-static.mjs +35 -37
- package/scripts/dev-with-automation.mjs +83 -2
- package/scripts/ingress.mjs +27 -1
- package/scripts/static-server.mjs +107 -2
- package/tools/canvas_ui_tool.py +19 -0
- package/build/assets/active-backend-context-DKFSMbn3.js +0 -2
- package/build/assets/agent-profiles-settings-D4cY5U2T.js +0 -1
- package/build/assets/agent-server-conversation-service.api-DozDKIW_.js +0 -86
- package/build/assets/agent-settings-351vXWc9.js +0 -2
- package/build/assets/agent-settings-Ce7BDZ6I.js +0 -1
- package/build/assets/alert-banner-Kyy1YWZU.js +0 -1
- package/build/assets/api-key-entry-screen-INIxqAMs.js +0 -1
- package/build/assets/automation-detail-DXDhUwPq.js +0 -3
- package/build/assets/automation-git-sync-CzyS4cn1.js +0 -1
- package/build/assets/automation-setup-route-FRr05f_g.js +0 -1
- package/build/assets/automations-list-CERuQWE6.js +0 -1
- package/build/assets/backend-form-modal-DK78-jn1.js +0 -1
- package/build/assets/bot-C-0Wu7vQ.js +0 -1
- package/build/assets/browser-11etCQ04.js +0 -7
- package/build/assets/check-Cf2YoT90.js +0 -1
- package/build/assets/chevron-down-C3OQ-ehx.js +0 -1
- package/build/assets/chevron-right-CN1uUiJ1.js +0 -1
- package/build/assets/circle-check-g5yeGMd-.js +0 -1
- package/build/assets/command-menu-BZQ8S3Ke.js +0 -1
- package/build/assets/commits-tab-DZtJgaDM.js +0 -1
- package/build/assets/confirmation-modal-Bk4JRcCM.js +0 -1
- package/build/assets/conversation-CchMzpGl.js +0 -1
- package/build/assets/conversation-Dpzftz57.js +0 -93
- package/build/assets/conversation-panel-CchMzpGl.js +0 -1
- package/build/assets/conversation-state-store-a9d2fxRc.js +0 -1
- package/build/assets/edit-automation-modal-D-urtv8n.js +0 -1
- package/build/assets/empty-state-CvaVahVr.js +0 -1
- package/build/assets/enum-filter-dropdown-DliX_Lo0.js +0 -1
- package/build/assets/extensions-hub-CFduxBnk.js +0 -1
- package/build/assets/extensions-navigation-BeC224yX.js +0 -1
- package/build/assets/external-link-DFpYunfj.js +0 -1
- package/build/assets/files-tab-CL3J9b3p.js +0 -1
- package/build/assets/format-model-name-BNPKVsIq.js +0 -1
- package/build/assets/get-git-path-DlAJa_i6.js +0 -1
- package/build/assets/git-repo-dropdown-DGMEhz7d.js +0 -1
- package/build/assets/home-BCGlNJCA.js +0 -1
- package/build/assets/home-DB1pRqTC.js +0 -1
- package/build/assets/home-automation-run-tooltip-CooFQRIG.js +0 -1
- package/build/assets/home-store-Dl1dPE58.js +0 -1
- package/build/assets/index-home-DB1pRqTC.js +0 -1
- package/build/assets/info-uYSVzX86.js +0 -1
- package/build/assets/install-server-modal-BbJdhzet.js +0 -1
- package/build/assets/kebab-menu-item-content-BYokkRHi.js +0 -1
- package/build/assets/list-filter-OFkpRrmi.js +0 -1
- package/build/assets/llm-not-configured-banner-BqqYnJ1t.js +0 -27
- package/build/assets/llm-settings-CnDbbmVW.js +0 -1
- package/build/assets/llm-settings-S8Yjg__1.js +0 -1
- package/build/assets/llm-subscription-service-BpPfzW4x.js +0 -1
- package/build/assets/loader-circle-nvrwthvj.js +0 -1
- package/build/assets/manage-backends-modal-BCUPswyl.js +0 -1
- package/build/assets/manifest-58597dde.js +0 -1
- package/build/assets/markdown-renderer-Cb2sBWtV.js +0 -8
- package/build/assets/mcp-page-Bm4K2NQq.js +0 -9
- package/build/assets/messages-BTN5thLe.js +0 -40
- package/build/assets/onboarding-Cx_kaiD1.js +0 -1
- package/build/assets/onboarding-modal-vMwn7ihv.js +0 -1
- package/build/assets/organization-service.api-C8XpQ0pM.js +0 -1
- package/build/assets/pencil-Clh1Wjvh.js +0 -1
- package/build/assets/planner-tab-DQvDU3ap.js +0 -1
- package/build/assets/plug-BuQhHSSG.js +0 -1
- package/build/assets/plugins-management-service-BjYeF0b0.js +0 -1
- package/build/assets/plus-CEKne-Yp.js +0 -1
- package/build/assets/profiles-service.api-QB-T_u-g.js +0 -1
- package/build/assets/providers-FfSZ5TXP.js +0 -1
- package/build/assets/proxy-tcFL2yTQ.js +0 -1
- package/build/assets/recommended-automations-launcher-Bw8uC4V6.js +0 -1
- package/build/assets/refresh-cw-Bh69DyYO.js +0 -1
- package/build/assets/root-BLeQfBEq.css +0 -1
- package/build/assets/root-ZKKYPR1Z.js +0 -2
- package/build/assets/root-layout-luJoE9IG.js +0 -2
- package/build/assets/schema-field-Csw5fhtN.js +0 -1
- package/build/assets/scroll-fade-state-Dw-i4SGq.js +0 -1
- package/build/assets/sdk-section-page-HTffvm7Q.js +0 -1
- package/build/assets/secret-form-HTUbYw5o.js +0 -1
- package/build/assets/secrets-service-BTor9uAU.js +0 -1
- package/build/assets/settings-BlmrkwRi.js +0 -1
- package/build/assets/settings-DcNPxz0v.js +0 -1
- package/build/assets/settings-index-CKq0b0Vg.js +0 -1
- package/build/assets/settings-service.api-B2agVfjL.js +0 -1
- package/build/assets/shared-conversation-B55pCyBG.js +0 -1
- package/build/assets/shield-check-CFDViW82.js +0 -1
- package/build/assets/sidebar-mobile-menu-toggle-BOtyJHwE.js +0 -1
- package/build/assets/sidebar-nav-link-CPzhyHQg.js +0 -1
- package/build/assets/sidebar-store-DtpU7zaI.js +0 -1
- package/build/assets/skill-filter-CWZ5kjcg.js +0 -2
- package/build/assets/skill-scope-CV1dkAbW.js +0 -1
- package/build/assets/skills-plugins-DGHULTq6.js +0 -1
- package/build/assets/skills-settings-CM1lFv3e.js +0 -1
- package/build/assets/styled-tooltip-Dl06rkpY.js +0 -1
- package/build/assets/toggle-switch-Fd_QGz0r.js +0 -1
- package/build/assets/trash-2-Dl8_RGz0.js +0 -1
- package/build/assets/trash-_RMt7Ayc.js +0 -1
- package/build/assets/triangle-alert-SM-q4NU_.js +0 -1
- package/build/assets/usage-tab-BcfWV6db.js +0 -1
- package/build/assets/use-acp-credential-form-BsSW5NHG.js +0 -1
- package/build/assets/use-activate-agent-profile-B2NS8nA5.js +0 -1
- package/build/assets/use-agent-profiles-DWBPC0Si.js +0 -1
- package/build/assets/use-config-Bft35DOK.js +0 -1
- package/build/assets/use-create-conversation-DwN5vv2f.js +0 -1
- package/build/assets/use-create-secret-BSxJMxHp.js +0 -1
- package/build/assets/use-has-permission-B3C8rQmR.js +0 -1
- package/build/assets/use-is-authed-CFGkY3-Z.js +0 -1
- package/build/assets/use-llm-configured-BI6obxsc.js +0 -1
- package/build/assets/use-llm-profiles-djGAhTWL.js +0 -1
- package/build/assets/use-manifest-capabilities-3z0-1G59.js +0 -1
- package/build/assets/use-onboarding-completion-BXpyUSsJ.js +0 -1
- package/build/assets/use-plugins-marketplace-DI4_pK56.js +0 -1
- package/build/assets/use-save-agent-profile-DdBSTdpN.js +0 -1
- package/build/assets/use-settings-C5VhGpqd.js +0 -1
- package/build/assets/use-settings-nav-items-DHaUu1Dg.js +0 -16
- package/build/assets/use-tracking-D5t9otIF.js +0 -3
- package/build/assets/utils-DaCIEEQP.js +0 -1
- package/build/assets/vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~kepq2zme-ZixYGy6E.js +0 -186
- package/build/assets/vendor~index-home~home~conversation-panel~conversation~alert-banner-B3qC_oj8.js +0 -1
- package/build/assets/vendor~root-layout-BlUaZ18v.js +0 -1
- package/build/assets/vendor~root-layout~index-home~home~conversation-panel~conversation~mcp~automations-list~aut~ibfbmr9f-B2OLKL7N.js +0 -1
- package/build/assets/vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iw7io29p-Dz-MAyNb.js +0 -1
- package/build/assets/x-DkgltWa0.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/components/features/tips/random-tip.d.ts +0 -2
- 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
- package/dist/utils/tips.d.ts +0 -7
- package/dist/utils/workspace-relative-path.cjs +0 -2
- package/dist/utils/workspace-relative-path.cjs.map +0 -1
- package/dist/utils/workspace-relative-path.d.ts +0 -10
- package/dist/utils/workspace-relative-path.js +0 -22
- package/dist/utils/workspace-relative-path.js.map +0 -1
- /package/build/assets/{vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ox0jfsa0-cHFhpUBq.js → vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{yt as e}from"./vendor-styling-Ck5D_A2Q.js";import{t}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~
|
|
1
|
+
import{yt as e}from"./vendor-styling-Ck5D_A2Q.js";import{t}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{K as n}from"./utils-BOco8mxR.js";import{k as r}from"./use-tracking-B9prBsrq.js";import{r as i}from"./modal-classes-Dg0ngBPO.js";import{t as a}from"./x-mark-BopmFoBq.js";var o=e();function s({automationName:e,isOpen:r,onConfirm:s,onCancel:c}){let{t:l}=t(`openhands`);return r?(0,o.jsxs)(`div`,{className:`fixed inset-0 z-50 flex items-center justify-center`,children:[(0,o.jsx)(`div`,{className:`absolute inset-0 bg-black/60`,onClick:c,onKeyDown:e=>{e.key===`Escape`&&c()},role:`presentation`}),(0,o.jsxs)(`div`,{className:`relative w-full max-w-sm rounded-xl border border-[var(--oh-border)] bg-[var(--oh-surface)] p-6`,children:[(0,o.jsx)(`button`,{type:`button`,onClick:c,className:`absolute right-4 top-4 text-muted hover:text-foreground`,"aria-label":l(n.BUTTON$CLOSE),children:(0,o.jsx)(a,{className:`size-5`})}),(0,o.jsx)(`h2`,{className:i,children:l(n.AUTOMATIONS$DELETE_CONFIRM_TITLE)}),(0,o.jsx)(`p`,{className:`mt-2 text-sm text-muted`,children:l(n.AUTOMATIONS$DELETE_CONFIRM_MESSAGE,{name:e})}),(0,o.jsxs)(`div`,{className:`mt-6 flex justify-end gap-3`,children:[(0,o.jsx)(`button`,{type:`button`,onClick:c,className:`rounded-lg border border-[var(--oh-border)] px-4 py-2 text-sm text-white hover:bg-surface-raised`,children:l(n.AUTOMATIONS$CANCEL)}),(0,o.jsx)(`button`,{type:`button`,onClick:s,className:`rounded-lg bg-danger px-4 py-2 text-sm text-white hover:bg-danger/80`,children:l(n.AUTOMATIONS$DELETE)})]})]})]}):null}var c=new Set([`cron`,`schedule`,`event`]),l=class extends Error{issues;constructor(e){super(e.join(`
|
|
2
2
|
`)),this.name=`AutomationFileValidationError`,this.issues=e}};function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(e,t,n,r){let i=e[t];if(typeof i!=`string`||i.trim().length===0){r.push(`${n}: expected a non-empty string`);return}return i}function f(e,t,n,r){let i=e[t];if(i!==void 0){if(typeof i!=`string`){r.push(`${n}: expected a string`);return}return i}}function p(e,t){if(!u(e)){t.push(`spec.trigger: expected an object`);return}let n=d(e,`type`,`spec.trigger.type`,t);n&&!c.has(n)&&t.push(`spec.trigger.type: expected one of "cron", "schedule", or "event"`);let r=f(e,`schedule`,`spec.trigger.schedule`,t),i=f(e,`schedule_human`,`spec.trigger.schedule_human`,t),a=f(e,`timezone`,`spec.trigger.timezone`,t),o=f(e,`source`,`spec.trigger.source`,t),s=f(e,`filter`,`spec.trigger.filter`,t),l;if(e.on!==void 0&&(typeof e.on==`string`||Array.isArray(e.on)&&e.on.length>0&&e.on.every(e=>typeof e==`string`&&e.trim().length>0)?l=e.on:t.push(`spec.trigger.on: expected a string or a non-empty array of strings`)),(n===`cron`||n===`schedule`)&&!r?.trim()&&t.push(`spec.trigger.schedule: required for a scheduled trigger`),n===`event`&&(o?.trim()||t.push(`spec.trigger.source: required for an event trigger`),(l===void 0||typeof l==`string`&&l.trim().length===0)&&t.push(`spec.trigger.on: required for an event trigger`)),!(!n||!c.has(n)))return{type:n,...r!==void 0&&{schedule:r},...i!==void 0&&{schedule_human:i},...a!==void 0&&{timezone:a},...o!==void 0&&{source:o},...l!==void 0&&{on:l},...s!==void 0&&{filter:s}}}function m(e){let t=e.timezone??e.trigger.timezone,n={name:e.name,trigger:{...e.trigger},enabled:e.enabled,prompt:e.prompt,...e.repository!==void 0&&{repository:e.repository},...e.model!==void 0&&{model:e.model},...e.timeout!=null&&{timeout:e.timeout},...e.branch!==void 0&&{branch:e.branch},...e.plugins!==void 0&&{plugins:[...e.plugins]},...e.notification!==void 0&&{notification:e.notification},...t!==void 0&&{timezone:t}},i=r();return{version:i.fileVersion,kind:i.fileKind,spec:n}}function h(e){return`${e.name.trim().toLowerCase().replace(/[^a-z0-9]+/g,`-`).replace(/^-+|-+$/g,``)||e.id}${r().filenameSuffix}`}function g(e){let t=[];if(!u(e))throw new l([`file: expected a JSON object`]);let n=r();if(e.version!==n.fileVersion&&t.push(`version: expected ${n.fileVersion}`),e.kind!==n.fileKind&&t.push(`kind: expected "${n.fileKind}"`),!u(e.spec))throw t.push(`spec: expected an object`),new l(t);let i=d(e.spec,`name`,`spec.name`,t),a=d(e.spec,`prompt`,`spec.prompt`,t),o=p(e.spec.trigger,t),s=e.spec.enabled;typeof s!=`boolean`&&t.push(`spec.enabled: expected a boolean`);let c=f(e.spec,`repository`,`spec.repository`,t),m=f(e.spec,`branch`,`spec.branch`,t),h=f(e.spec,`notification`,`spec.notification`,t),g=f(e.spec,`timezone`,`spec.timezone`,t),_;e.spec.model===null||e.spec.model===void 0||typeof e.spec.model==`string`&&e.spec.model.trim().length>0?_=e.spec.model:t.push(`spec.model: expected a non-empty string or null`);let v;e.spec.timeout===null||e.spec.timeout===void 0||typeof e.spec.timeout==`number`&&Number.isInteger(e.spec.timeout)&&e.spec.timeout>0?v=e.spec.timeout:t.push(`spec.timeout: expected a positive integer`);let y;if(e.spec.plugins!==void 0&&(Array.isArray(e.spec.plugins)&&e.spec.plugins.every(e=>typeof e==`string`&&e.trim().length>0)?y=[...e.spec.plugins]:t.push(`spec.plugins: expected an array of non-empty strings`)),t.length>0||!i||!a||!o)throw new l(t);return{name:i,prompt:a,trigger:o,enabled:s,...c!==void 0&&{repository:c},..._!==void 0&&{model:_},...v!==void 0&&{timeout:v},...m!==void 0&&{branch:m},...y!==void 0&&{plugins:y},...h!==void 0&&{notification:h},...g!==void 0&&{timezone:g}}}export{s as i,g as n,m as r,h as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{U as r}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{r as i}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-DnDoaYNi.js";import{t as a}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{t as o}from"./useMutation-CJuK90oc.js";import{t as s}from"./useQuery-S6j94er1.js";import{ct as c,n as l,st as u}from"./active-backend-context-rZiLJRUc.js";import{K as d,t as f}from"./utils-BOco8mxR.js";import{t as p}from"./check-fDEfgSzj.js";import{t as m}from"./refresh-cw-DEQdPCpH.js";import{t as h}from"./triangle-alert-BajLPpQg.js";import{n as g,t as _}from"./use-tracking-B9prBsrq.js";import{t as v}from"./use-settings-Dn00UISA.js";import{t as y}from"./brand-button-DxPO4Lf8.js";import{t as b}from"./settings-input-C0dd8Utu.js";import{t as x}from"./format-time-delta-BIR5Os7T.js";import{t as S}from"./folder-C1ou4_DT.js";import{n as C,t as w}from"./use-automation-health-BZkQNEA8.js";import{t as T}from"./settings-switch-B78Khmyz.js";import{n as E}from"./api-error-message-Ve79qDcN.js";import{t as D}from"./use-automation-permissions-B_RpvL-s.js";import{t as O}from"./parse-git-remote-url-DpDM9bK6.js";import{n as k,r as A,t as j}from"./error-state-B_5cgNPJ.js";import{a as M,i as N,n as P,r as F,t as ee}from"./cog-VBlRo6iw.js";var I=e(t()),L=[`git-sync-status`];function R(e={}){let{enabled:t=!0,refetchInterval:n=!1}=e,r=l();return s({queryKey:[...L,r.backend.id,r.orgId],queryFn:()=>g.getGitSyncStatus(),staleTime:10*1e3,enabled:t,refetchInterval:n,retry:(e,t)=>v(t)===void 0&&e<2,meta:{disableToast:!0}})}function te(){let e=i(),t=l(),{trackGitSyncConfigUpdated:n}=_();return o({mutationFn:e=>g.updateGitSyncConfig(e),onSuccess:async r=>{let i=[...L,t.backend.id,t.orgId];await e.cancelQueries({queryKey:i}),e.setQueryData(i,r),n({backendKind:t.backend.kind})},meta:{disableToast:!0}})}function ne(){return o({mutationFn:e=>g.checkGitSyncConfig(e),retry:!1,meta:{disableToast:!0}})}function z(){let e=i(),t=l(),{trackGitSyncTriggered:n}=_();return o({mutationFn:()=>g.triggerGitSync(),onSuccess:()=>{e.invalidateQueries({queryKey:L}),n({backendKind:t.backend.kind})},meta:{disableToast:!0}})}var B=n();function V({className:e}){return(0,B.jsx)(`div`,{className:f(`animate-pulse rounded bg-surface-raised`,e)})}function H(){return(0,B.jsxs)(`div`,{className:`flex flex-col gap-4`,"data-testid":`git-sync-skeleton`,children:[(0,B.jsx)(V,{className:`h-5 w-40`}),(0,B.jsx)(V,{className:`h-6 w-48`}),(0,B.jsx)(V,{className:`h-5 w-96`}),(0,B.jsx)(V,{className:`h-48 w-full rounded-2xl`}),(0,B.jsx)(V,{className:`h-96 w-full rounded-2xl`})]})}function U(){let{t:e}=a(`openhands`);return(0,B.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-20`,children:[(0,B.jsx)(A,{className:`size-12 text-muted`}),(0,B.jsx)(`p`,{className:`mt-4 text-sm font-medium text-content`,children:e(d.AUTOMATIONS$GIT_SYNC$NOT_LOCAL_TITLE)}),(0,B.jsx)(`p`,{className:`mt-2 text-sm text-muted`,children:e(d.AUTOMATIONS$GIT_SYNC$NOT_LOCAL_MESSAGE)}),(0,B.jsx)(`div`,{className:`mt-6`,children:(0,B.jsx)(M,{})})]})}function W(){let{t:e}=a(`openhands`);return(0,B.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-20`,children:[(0,B.jsx)(A,{className:`size-12 text-muted`}),(0,B.jsx)(`p`,{className:`mt-4 text-sm font-medium text-content`,children:e(d.AUTOMATIONS$GIT_SYNC$UNSUPPORTED_TITLE)}),(0,B.jsx)(`p`,{className:`mt-2 text-sm text-muted`,children:e(d.AUTOMATIONS$GIT_SYNC$UNSUPPORTED_MESSAGE)}),(0,B.jsx)(`div`,{className:`mt-6`,children:(0,B.jsx)(M,{})})]})}function G({error:e,errorAt:t}){let{t:n}=a(`openhands`);return(0,B.jsxs)(`div`,{role:`alert`,"data-testid":`git-sync-error-banner`,className:`rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm text-red-300 whitespace-pre-wrap break-words`,children:[(0,B.jsx)(`p`,{className:`font-medium`,children:n(d.AUTOMATIONS$GIT_SYNC$LAST_ERROR_TITLE)}),(0,B.jsx)(`p`,{className:`mt-1`,children:e}),t&&(0,B.jsx)(`p`,{className:`mt-1 text-xs text-red-300/70`,children:`${x(t)} ${n(d.CONVERSATION$AGO)}`})]})}var K=e=>(0,B.jsx)(`svg`,{viewBox:`0 0 18 18`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,B.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M2.4375 9C2.4375 5.37563 5.37563 2.4375 9 2.4375C12.6244 2.4375 15.5625 5.37563 15.5625 9C15.5625 12.6244 12.6244 15.5625 9 15.5625C5.37563 15.5625 2.4375 12.6244 2.4375 9ZM4.13812 6.5625C4.81317 5.21867 6.02897 4.19333 7.49996 3.77204C7.15155 4.17641 6.85182 4.65395 6.60713 5.17892C6.40828 5.60556 6.24263 6.06975 6.11494 6.5625H4.13812ZM3.72196 7.6875C3.61778 8.10783 3.5625 8.54746 3.5625 9C3.5625 9.45254 3.61778 9.89217 3.72196 10.3125H5.89738C5.84161 9.88758 5.8125 9.44852 5.8125 8.99998C5.8125 8.55142 5.84161 8.11239 5.89737 7.6875H3.72196ZM7.0333 7.6875C6.97087 8.10689 6.9375 8.54634 6.9375 8.99998C6.9375 9.45367 6.97087 9.89313 7.0333 10.3125H10.9667C11.0291 9.89311 11.0625 9.45367 11.0625 9.00002C11.0625 8.54637 11.0291 8.1069 10.9667 7.6875H7.0333ZM12.1026 7.6875C12.1584 8.1124 12.1875 8.55145 12.1875 9.00002C12.1875 9.44858 12.1584 9.88762 12.1026 10.3125H14.278C14.3822 9.89217 14.4375 9.45254 14.4375 9C14.4375 8.54746 14.3822 8.10783 14.278 7.6875H12.1026ZM13.8619 6.5625H11.885C11.7574 6.06976 11.5917 5.6056 11.3929 5.17897C11.1482 4.65397 10.8484 4.1764 10.5 3.77203C11.971 4.19331 13.1868 5.21866 13.8619 6.5625ZM10.7171 6.5625H7.28293C7.38007 6.23971 7.49559 5.93571 7.62681 5.65419C7.99835 4.85708 8.48101 4.26914 8.99997 3.92442C9.51895 4.26913 10.0016 4.8571 10.3732 5.65424C10.5044 5.93575 10.6199 6.23973 10.7171 6.5625ZM4.13812 11.4375H6.11496C6.24963 11.9572 6.42655 12.4452 6.64015 12.8909C6.87835 13.3879 7.16685 13.8413 7.50006 14.228C6.02902 13.8067 4.81318 12.7814 4.13812 11.4375ZM10.7171 11.4375H7.28295C7.3869 11.7829 7.51191 12.1068 7.65465 12.4047C8.02305 13.1733 8.49456 13.7398 9.00007 14.0756C9.51902 13.7308 10.0017 13.1429 10.3732 12.3458C10.5044 12.0643 10.6199 11.7603 10.7171 11.4375ZM11.3929 12.8211C11.5917 12.3944 11.7574 11.9303 11.8851 11.4375H13.8619C13.1868 12.7813 11.971 13.8067 10.5 14.228C10.8485 13.8236 11.1482 13.346 11.3929 12.8211Z`,fill:`currentColor`})});function q({tone:e,label:t,testId:n}){return(0,B.jsx)(`span`,{"data-testid":n,className:f(`inline-flex items-center rounded-full px-3 py-1 text-xs font-medium`,e===`success`&&`bg-[var(--oh-success)]/15 text-[var(--oh-success)]`,e===`warning`&&`bg-[var(--oh-warning)]/15 text-[var(--oh-warning)]`,e===`neutral`&&`bg-surface-raised text-muted`),children:t})}function J(e){let[,t]=(0,I.useState)(0);(0,I.useEffect)(()=>{if(!e)return;let n=setInterval(()=>t(e=>e+1),1e3);return()=>clearInterval(n)},[e])}function Y({state:e,startedAt:t,pendingCount:n}){let{t:r}=a(`openhands`),i=e===`running`;if(J(i&&t!==null),e===`idle`)return null;let o=e===`failed`;return(0,B.jsxs)(`div`,{"data-testid":`git-sync-activity-row`,"data-state":e,className:f(`mt-4 flex flex-wrap items-center gap-x-2 gap-y-1 rounded-md px-3 py-2 text-sm`,i&&`bg-tertiary text-content`,e===`succeeded`&&`bg-green-500/10 text-green-300`,o&&`bg-red-500/10 text-red-300`),children:[i&&(0,B.jsx)(m,{className:`size-4 animate-spin`,"aria-hidden":!0}),e===`succeeded`&&(0,B.jsx)(p,{className:`size-4`,"aria-hidden":!0}),o&&(0,B.jsx)(h,{className:`size-4`,"aria-hidden":!0}),(0,B.jsxs)(`span`,{className:`font-medium`,children:[i&&r(d.AUTOMATIONS$GIT_SYNC$SYNCING),e===`succeeded`&&r(d.AUTOMATIONS$GIT_SYNC$SYNC_COMPLETED),o&&r(d.AUTOMATIONS$GIT_SYNC$SYNC_FAILED)]}),i&&t&&(0,B.jsx)(`span`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$SYNC_STARTED_AGO,{time:x(t)})}),i&&n>0&&(0,B.jsx)(`span`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$SYNC_PENDING_COUNT,{count:n})})]})}function X(e){let t=O(e);if(!t?.host||!t.repository)return null;if(/^https?:\/\//i.test(t.url)){let e=new URL(t.url);return e.username=``,e.password=``,e.pathname=e.pathname.replace(/\.git$/,``),e.toString()}return`https://${t.host}/${t.repository}`}function Z({status:e,onSyncNow:t,isSyncing:n,syncActivity:r,syncStartedAt:i,canManage:o}){let{t:s}=a(`openhands`),c=X(e.repo_url);return(0,B.jsxs)(F,{icon:(0,B.jsx)(N,{className:`size-4`}),title:s(d.AUTOMATIONS$GIT_SYNC$STATUS_TITLE),children:[(0,B.jsxs)(`div`,{className:`flex flex-wrap items-center justify-between gap-3`,children:[(0,B.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,B.jsx)(q,{testId:`git-sync-enabled-pill`,tone:e.enabled?`success`:`neutral`,label:s(e.enabled?d.AUTOMATIONS$GIT_SYNC$ENABLED:d.AUTOMATIONS$GIT_SYNC$DISABLED)}),(0,B.jsx)(q,{testId:`git-sync-encryption-pill`,tone:e.encryption_enabled?`success`:`neutral`,label:s(e.encryption_enabled?d.AUTOMATIONS$GIT_SYNC$ENCRYPTED:d.AUTOMATIONS$GIT_SYNC$NOT_ENCRYPTED)})]}),(0,B.jsx)(y,{testId:`git-sync-now-button`,type:`button`,variant:`secondary`,isDisabled:!o||!e.enabled||n,onClick:t,startContent:(0,B.jsx)(m,{className:f(`size-4`,n&&`animate-spin`),"aria-hidden":!0}),children:s(n?d.AUTOMATIONS$GIT_SYNC$SYNCING:d.AUTOMATIONS$GIT_SYNC$SYNC_NOW)})]}),(0,B.jsx)(Y,{state:r,startedAt:i,pendingCount:e.dirty_count}),(0,B.jsxs)(`div`,{className:`mt-5 grid grid-cols-2 gap-x-4 gap-y-5`,children:[(0,B.jsx)(P,{icon:(0,B.jsx)(K,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$REPOSITORY),children:c?(0,B.jsx)(`a`,{"data-testid":`git-sync-repo-link`,href:c,target:`_blank`,rel:`noopener noreferrer`,className:`break-all underline transition-colors hover:text-foreground`,children:e.repo_url}):(0,B.jsx)(`span`,{className:`break-all`,children:e.repo_url||s(d.AUTOMATIONS$GIT_SYNC$NOT_CONFIGURED)})}),(0,B.jsx)(P,{icon:(0,B.jsx)(N,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$FIELD_BRANCH),children:e.branch}),(0,B.jsx)(P,{icon:(0,B.jsx)(S,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$FIELD_PATH),children:e.path}),(0,B.jsx)(P,{icon:(0,B.jsx)(N,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$LAST_SYNCED_COMMIT),children:e.last_synced_commit?(0,B.jsx)(`span`,{className:`font-mono`,children:e.last_synced_commit.slice(0,7)}):s(d.AUTOMATIONS$GIT_SYNC$NEVER_SYNCED)}),(0,B.jsx)(P,{icon:(0,B.jsx)(C,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$LAST_SYNCED_AT),children:e.last_synced_at?`${x(e.last_synced_at)} ${s(d.CONVERSATION$AGO)}`:s(d.AUTOMATIONS$GIT_SYNC$NEVER_SYNCED)}),(0,B.jsx)(P,{icon:(0,B.jsx)(C,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$FIELD_INTERVAL),children:e.interval_seconds>0?s(d.AUTOMATIONS$GIT_SYNC$EVERY_N_SECONDS,{count:e.interval_seconds}):s(d.AUTOMATIONS$GIT_SYNC$MANUAL_ONLY)}),(0,B.jsx)(P,{icon:(0,B.jsx)(C,{className:`size-3.5`}),label:s(d.AUTOMATIONS$GIT_SYNC$PENDING_CHANGES),children:(0,B.jsx)(`span`,{className:f(e.dirty_count>0&&`text-[var(--oh-warning)]`),children:e.dirty_count})})]})]})}var Q=`git-sync-save-and-sync`;function $({status:e,canManage:t,onSyncNow:n}){let{t:r}=a(`openhands`),{mutate:i,isPending:o}=te(),{mutateAsync:s,isPending:l}=ne(),[f,p]=(0,I.useState)(null),[m,h]=(0,I.useState)(!1),[g,_]=(0,I.useState)(!1),[x,S]=(0,I.useState)(!1),[C,w]=(0,I.useState)(!1),[D,O]=(0,I.useState)(!1),[k,A]=(0,I.useState)(!1),[j,M]=(0,I.useState)(null),N=j??e.enabled,P=j!==null&&N!==e.enabled,[L,R]=(0,I.useState)(``),[z,V]=(0,I.useState)(!1),[H,U]=(0,I.useState)(``),[W,G]=(0,I.useState)(!1),K=L.trim().length>0||z,q=H.trim().length>0||W,J=!P&&!m&&!g&&!x&&!C&&!D&&!k&&!K&&!q,Y=()=>{M(null),h(!1),_(!1),S(!1),w(!1),O(!1),A(!1),R(``),V(!1),U(``),G(!1),p(null)},X=e=>{V(e),R(``)},Z=e=>{G(e),U(``)},$=(e,t)=>e.get(t)?.toString().trim()||null,re=(e,t)=>{i(e,{onSuccess:()=>{c(r(d.AUTOMATIONS$GIT_SYNC$CONFIG_SAVED)),Y(),t&&n()},onError:e=>{u(v(e)===409?r(d.AUTOMATIONS$GIT_SYNC$ENABLE_BLOCKED_ERROR):E(e,r(d.ERROR$GENERIC)))}})},ie=e=>[`repo_url`,`branch`,`token`].filter(t=>t in e).map(t=>`${t}=${e[t]}`).join(`&`),ae=async e=>{try{let t=await s(e);return t.ok?null:t.detail??r(d.AUTOMATIONS$GIT_SYNC$CHECK_FAILED_TITLE)}catch{return null}};return(0,B.jsx)(F,{icon:(0,B.jsx)(ee,{className:`size-4`}),title:r(d.AUTOMATIONS$GIT_SYNC$CONFIG_TITLE),children:(0,B.jsxs)(`form`,{onSubmit:async e=>{e.preventDefault();let t=e.nativeEvent.submitter?.getAttribute(`name`)===Q,n=new FormData(e.currentTarget),r={};if(P&&(r.enabled=N),m){let e=n.get(`git-sync-interval-input`)?.toString().trim(),t=Number(e);r.interval_seconds=e&&Number.isFinite(t)?Math.max(0,Math.trunc(t)):0}g&&(r.repo_url=$(n,`git-sync-repo-url-input`)),x&&(r.branch=$(n,`git-sync-branch-input`)),C&&(r.path=$(n,`git-sync-path-input`)),D&&(r.author_name=$(n,`git-sync-author-name-input`)),k&&(r.author_email=$(n,`git-sync-author-email-input`));let i=L.trim(),a=H.trim();z?r.token=null:i&&(r.token=i),W?r.encryption_key=null:a&&(r.encryption_key=a);let o=ie(r);if(o&&f?.key!==o){let e=await ae(r);if(e){p({key:o,detail:e});return}}p(null),re(r,t)},className:`flex flex-col gap-6`,children:[(0,B.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,B.jsx)(T,{testId:`git-sync-enabled-switch`,isToggled:N,isDisabled:!t,onToggle:M,children:r(d.AUTOMATIONS$GIT_SYNC$FIELD_ENABLED)}),(0,B.jsx)(`p`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$ENABLED_HELP)})]}),(0,B.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,B.jsx)(b,{testId:`git-sync-interval-input`,name:`git-sync-interval-input`,type:`number`,min:0,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_INTERVAL),defaultValue:String(e.interval_seconds),isDisabled:!t,onChange:t=>h(t.trim()!==String(e.interval_seconds))}),(0,B.jsx)(`p`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$INTERVAL_HELP)})]}),(0,B.jsx)(b,{testId:`git-sync-repo-url-input`,name:`git-sync-repo-url-input`,type:`text`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_REPO_URL),defaultValue:e.repo_url,placeholder:r(d.AUTOMATIONS$GIT_SYNC$REPO_URL_PLACEHOLDER),isDisabled:!t,onChange:t=>_(t.trim()!==e.repo_url)}),(0,B.jsx)(b,{testId:`git-sync-branch-input`,name:`git-sync-branch-input`,type:`text`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_BRANCH),defaultValue:e.branch,placeholder:r(d.AUTOMATIONS$GIT_SYNC$BRANCH_PLACEHOLDER),isDisabled:!t,onChange:t=>S(t.trim()!==e.branch)}),(0,B.jsx)(b,{testId:`git-sync-path-input`,name:`git-sync-path-input`,type:`text`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_PATH),defaultValue:e.path,placeholder:r(d.AUTOMATIONS$GIT_SYNC$PATH_PLACEHOLDER),isDisabled:!t,onChange:t=>w(t.trim()!==e.path)}),(0,B.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,B.jsx)(b,{testId:`git-sync-author-name-input`,name:`git-sync-author-name-input`,type:`text`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_AUTHOR_NAME),showOptionalTag:!0,defaultValue:``,isDisabled:!t,onChange:()=>O(!0)}),(0,B.jsx)(b,{testId:`git-sync-author-email-input`,name:`git-sync-author-email-input`,type:`email`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_AUTHOR_EMAIL),showOptionalTag:!0,defaultValue:``,isDisabled:!t,onChange:()=>A(!0)}),(0,B.jsx)(`p`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$AUTHOR_HELP)})]}),(0,B.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,B.jsx)(b,{testId:`git-sync-token-input`,name:`git-sync-token-input`,type:`password`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_TOKEN),placeholder:r(d.AUTOMATIONS$GIT_SYNC$TOKEN_PLACEHOLDER),isDisabled:!t||z,onChange:R},z?`token-cleared`:`token-editable`),(0,B.jsx)(`p`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$TOKEN_HELP)}),(0,B.jsx)(T,{testId:`git-sync-clear-token-switch`,isToggled:z,isDisabled:!t,onToggle:X,children:r(d.AUTOMATIONS$GIT_SYNC$CLEAR_TOKEN)})]}),(0,B.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,B.jsx)(b,{testId:`git-sync-encryption-key-input`,name:`git-sync-encryption-key-input`,type:`password`,label:r(d.AUTOMATIONS$GIT_SYNC$FIELD_ENCRYPTION_KEY),placeholder:r(e.encryption_enabled?d.AUTOMATIONS$GIT_SYNC$KEY_SET_PLACEHOLDER:d.AUTOMATIONS$GIT_SYNC$KEY_UNSET_PLACEHOLDER),isDisabled:!t||W,onChange:U},W?`key-cleared`:`key-editable`),(0,B.jsx)(`p`,{className:`text-xs text-muted`,children:r(d.AUTOMATIONS$GIT_SYNC$ENCRYPTION_KEY_HELP)}),(0,B.jsx)(T,{testId:`git-sync-clear-encryption-key-switch`,isToggled:W,isDisabled:!t,onToggle:Z,children:r(d.AUTOMATIONS$GIT_SYNC$CLEAR_ENCRYPTION_KEY)})]}),f&&(0,B.jsxs)(`div`,{role:`alert`,"data-testid":`git-sync-check-failure`,className:`rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm text-red-300 whitespace-pre-wrap break-words`,children:[(0,B.jsx)(`p`,{className:`font-medium`,children:r(d.AUTOMATIONS$GIT_SYNC$CHECK_FAILED_TITLE)}),(0,B.jsx)(`p`,{className:`mt-1`,children:f.detail}),(0,B.jsx)(`p`,{className:`mt-1 text-xs text-red-300/70`,children:r(d.AUTOMATIONS$GIT_SYNC$CHECK_FAILED_HINT)})]}),(0,B.jsxs)(`div`,{className:`flex justify-start gap-3`,children:[(0,B.jsxs)(y,{testId:`git-sync-save-button`,variant:`primary`,type:`submit`,isDisabled:!t||o||l||J,children:[!o&&!l&&r(d.SETTINGS$SAVE_CHANGES),l&&r(d.AUTOMATIONS$GIT_SYNC$CHECKING),o&&r(d.SETTINGS$SAVING)]}),(0,B.jsx)(y,{testId:`git-sync-save-and-sync-button`,name:Q,variant:`secondary`,type:`submit`,isDisabled:!t||o||l||J||!N,children:r(d.AUTOMATIONS$GIT_SYNC$SAVE_AND_SYNC)})]})]})})}var re=3e3,ie=15e3,ae=3e4,oe=e=>({state:`running`,startedAt:e.sync_started_at??new Date().toISOString(),lastSyncedAt:e.last_synced_at,lastErrorAt:e.last_error_at}),se=r(function(){let{t:e}=a(`openhands`),t=l(),{canManage:n}=D(),[r,i]=(0,I.useState)({state:`idle`}),o=r.state===`running`,{data:s,isLoading:c,refetch:f}=w(),p=s?.status===`ok`,m=t.backend.kind===`local`,{data:h,isLoading:g,error:_,refetch:y}=R({enabled:p&&m,refetchInterval:o?re:ie});(0,I.useEffect)(()=>{h?.sync_in_progress&&i(e=>e.state===`running`?e:oe(h))},[h]),(0,I.useEffect)(()=>{r.state!==`running`||!h||(h.last_error_at&&h.last_error_at!==r.lastErrorAt?i({state:`failed`}):h.last_synced_at&&h.last_synced_at!==r.lastSyncedAt&&i({state:`succeeded`}))},[h,r]),(0,I.useEffect)(()=>{if(!o)return;let e=setTimeout(()=>i({state:`idle`}),ae);return()=>clearTimeout(e)},[o,r]);let b=z();if(!m)return(0,B.jsx)(`div`,{className:`min-h-full`,children:(0,B.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:(0,B.jsx)(U,{})})});if(c)return(0,B.jsx)(`div`,{className:`min-h-full`,children:(0,B.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:(0,B.jsx)(H,{})})});if(!p)return(0,B.jsx)(`div`,{className:`min-h-full`,children:(0,B.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:(0,B.jsx)(k,{onRetry:f})})});if(g)return(0,B.jsx)(`div`,{className:`min-h-full`,children:(0,B.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:(0,B.jsx)(H,{})})});if(!h)return(0,B.jsx)(`div`,{className:`min-h-full`,children:(0,B.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:v(_)===404?(0,B.jsx)(W,{}):(0,B.jsx)(j,{onRetry:()=>y()})})});let x=()=>{b.mutate(void 0,{onSuccess:()=>i(oe(h)),onError:t=>{u(v(t)===503?e(d.AUTOMATIONS$GIT_SYNC$SYNC_DISABLED_ERROR):E(t,e(d.ERROR$GENERIC)))}})};return(0,B.jsx)(`div`,{className:`min-h-full`,children:(0,B.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:(0,B.jsxs)(`div`,{className:`flex flex-col gap-4`,children:[(0,B.jsx)(M,{}),(0,B.jsxs)(`div`,{children:[(0,B.jsx)(`h1`,{className:`text-xl font-semibold text-content`,children:e(d.AUTOMATIONS$GIT_SYNC$TITLE)}),(0,B.jsx)(`p`,{className:`mt-1 text-sm text-muted`,children:e(d.AUTOMATIONS$GIT_SYNC$SUBTITLE)})]}),h.last_error&&(0,B.jsx)(G,{error:h.last_error,errorAt:h.last_error_at}),(0,B.jsx)(Z,{status:h,onSyncNow:x,isSyncing:b.isPending||o,syncActivity:r.state,syncStartedAt:o?r.startedAt:null,canManage:n}),(0,B.jsx)($,{status:h,canManage:n,onSyncNow:x})]})})})});export{se as default};
|
|
@@ -0,0 +1,3 @@
|
|
|
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,P as i,R as a,U as o}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{t as s}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{l as c}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-BfkNGovw.js";import{$ as l,n as u}from"./active-backend-context-rZiLJRUc.js";import{K as d,t as f}from"./utils-BOco8mxR.js";import{r as p}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~skills-setti~eo2nf80n-BPjI-atc.js";import{t as m}from"./loading-spinner-DfHI77BA.js";import{C as h,I as g,L as _,P as v,R as ee,S as y,_ as te,a as b,b as ne,c as x,d as re,f as S,g as ie,h as C,i as ae,l as oe,m as se,n as w,o as ce,p as T,r as le,s as E,t as ue,u as de,v as fe,y as pe}from"./use-tracking-B9prBsrq.js";import{l as D}from"./settings-service.api-9_xdv_mh.js";import{n as me}from"./use-settings-Dn00UISA.js";import{t as he}from"./modal-backdrop-BSzNhM4r.js";import{n as ge}from"./modal-classes-Dg0ngBPO.js";import{f as _e,l as ve}from"./form-control-classes-B-z85REi.js";import{t as O}from"./brand-button-DxPO4Lf8.js";import{t as k}from"./navigation-link-Bxo3-4vo.js";import{t as A}from"./settings-dropdown-input-DVpyD87C.js";import{o as ye,s as j,t as M}from"./conversation-store-DVVfkCsk.js";import{t as be}from"./modal-close-button-B9j4nasm.js";import{t as N}from"./settings-input-C0dd8Utu.js";import{t as xe}from"./use-llm-profiles-BTTtpW4z.js";import{n as P}from"./use-create-conversation-1YgmAHt-.js";import{t as Se}from"./api-error-message-Ve79qDcN.js";import{f as F,n as I,o as L,s as R}from"./mcp-marketplace-utils-Cn_NIMWM.js";import{t as z}from"./vendor~root-layout~index-home~home~conversation-panel~conversation~mcp~automations-list~aut~ibfbmr9f-CxhwKuAd.js";import{i as Ce,n as we,r as Te}from"./use-manifest-capabilities-AOWGcu0j.js";import{t as B}from"./git-repo-dropdown-DVeCUUXG.js";import"./git-repo-dropdown-D2WEQ97X.js";var V=e(t(),1);function Ee(e){let t=e.requires.integrations,{data:n,isLoading:r}=me(),i=(0,V.useMemo)(()=>F(D(n?.agent_settings?.mcp_config)),[n?.agent_settings?.mcp_config]),a=(0,V.useMemo)(()=>{let e=R(z);return Object.entries(t).map(([t,n])=>({id:t,requirement:n,entry:L(t,e)??null})).filter(({entry:e})=>!e||!I(e,i))},[t,i]),o=a.filter(({requirement:e})=>e.required!==!1);return{blockingIntegrations:o,warningIntegrations:a.filter(({requirement:e})=>e.required===!1),isBlocked:o.length>0,isLoading:r}}var De={fieldErrors:{},formErrors:[]};function H(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function Oe(e,t){let n=e[0]===`body`?e.slice(1):e,r=[],i=t;return n.forEach(e=>{if(typeof e==`number`){Array.isArray(i)&&r.length>0&&(r[r.length-1]+=`[${e}]`,i=i[e]);return}H(i)&&e in i&&(r.push(e),i=i[e])}),r.join(`.`)}function ke(e,t){if(!H(e))return[];if(Array.isArray(e.errors))return e.errors.flatMap(e=>!H(e)||typeof e.message!=`string`?[]:[{path:typeof e.field==`string`?e.field:``,message:e.message}]);let{detail:n}=e;return typeof n==`string`?[{path:``,message:n}]:Array.isArray(n)?n.flatMap(e=>!H(e)||typeof e.msg!=`string`?[]:[{path:Oe(Array.isArray(e.loc)?e.loc:[],t),message:e.msg}]):[]}function Ae(e,t){return t[e]??t[e.replace(/\[\d+\]/g,`[0]`)]}function je(e,t){if(e.length===0)return De;let n={},r=[];return e.forEach(({path:e,message:i})=>{let a=e?Ae(e,t):void 0;if(!a?.length){r.push(i);return}a.forEach(e=>{e in n||(n[e]=i)})}),{fieldErrors:n,formErrors:r}}var Me={fieldErrors:{},formErrors:[]},Ne=[404,501];function U(e){return Ne.some(t=>l(e,t)||c.isAxiosError(e)&&e.response?.status===t)}function Pe(e){let t=(0,V.useRef)(0);return(0,V.useCallback)(async(n,r,i)=>{try{let a=b(e,n,r,i);if(!a)return null;t.current+=1;let o=t.current,s=await w.validateDraft(a);return o===t.current?s?.valid?Me:je(ke(s,a.draft),ce(e,r,i)):null}catch(e){return U(e)||console.warn(`Automation setup preflight failed:`,e),null}},[e])}var W=new TextEncoder,G=512,K=100,q=148;function Fe(e,t,n){let r=new Uint8Array(G),i=(e,t)=>{for(let n=0;n<t.length;n+=1)r[e+n]=t.charCodeAt(n)&127},a=(e,t,n)=>i(e,n.toString(8).padStart(t-1,`0`));return r.set(t,0),a(100,8,e.mode??420),a(108,8,0),a(116,8,0),a(124,12,n),a(136,12,0),r[156]=48,i(257,`ustar`),i(263,`00`),r.fill(32,q,156),i(q,r.reduce((e,t)=>e+t,0).toString(8).padStart(6,`0`)),r[154]=0,r[155]=32,r}function Ie(e){let t=[];for(let n of e){let e=W.encode(n.name);if(e.length>K)throw Error(`tar: name too long for a ustar header: ${n.name}`);let r=W.encode(n.content);t.push(Fe(n,e,r.length));let i=new Uint8Array(Math.ceil(r.length/G)*G);i.set(r),t.push(i)}t.push(new Uint8Array(G*2));let n=t.reduce((e,t)=>e+t.length,0),r=new Uint8Array(new ArrayBuffer(n)),i=0;for(let e of t)r.set(e,i),i+=e.length;return r}async function Le(e){let t=Ie(e),n=new ReadableStream({start(e){e.enqueue(t),e.close()}}),r=new Response(n.pipeThrough(new CompressionStream(`gzip`)));return new Uint8Array(await r.arrayBuffer())}function Re(e){let t=p?.(e);if(!t||Object.keys(t).length===0)throw Error(`The published extensions package ships no bundle files for '${e}'.`);return t}function ze(e){let t=(e.entrypoint.trim().split(` `)[0]??``).replace(/^\.\//,``);return new Set([e.setupScript,t in e.files?t:void 0].filter(e=>e!==void 0))}async function Be(e,t){let n=e.setup.bundle;if(!n)throw Error(`'${e.id}' declares no bundle.`);let r=Re(e.id),i=Object.keys(n.files).filter(e=>typeof r[e]!=`string`);if(i.length>0)throw Error(`The published extensions package is missing bundle files for '${e.id}': ${i.join(`, `)}.`);let a=ae(e,t)?.template,o=ze(n),s=Object.keys(n.files).sort().map(e=>({name:e,content:r[e],mode:o.has(e)?493:420}));return s.push({name:_,content:`${JSON.stringify(a?.config??{},null,2)}\n`}),Le(s)}function Ve(e){return typeof File<`u`&&e instanceof File}function He(e,t,n){let r=t.tarball,i=Ve(r)?{name:r.name,size:r.size,lastModified:r.lastModified}:r;return`${e.id}
|
|
2
|
+
${n??``}
|
|
3
|
+
${JSON.stringify({...t,tarball:i})}`}async function Ue(e){let t=e.tarball;if(!Ve(t))throw Error(`Choose a tarball before creating this automation.`);return new Uint8Array(await t.arrayBuffer())}function We(){let e=P(),t=M(e=>e.setMessageToSend),n=(0,V.useRef)(null),r=(0,V.useCallback)(async n=>{let r=await e.mutateAsync({});return r.conversation_id.startsWith(`task-`)&&r.task_id?j(r.task_id,n):ye(r.conversation_id,{draftMessage:n}),window.setTimeout(()=>t(n),0),{response:{...r}}},[e,t]);return(0,V.useCallback)(async(e,t,i,a,o)=>{if(!i)return r(le(e,t));if(E(e)||x(e,o)){let r=He(e,t,o),i=n.current?.path??null;if(n.current?.key!==r||i===null){let a=E(e)?await Be(e,t):await Ue(t);i=await w.uploadAutomationTarball(e.id,a),n.current={key:r,path:i}}let s=ae(e,t,i,a,o);if(!s)throw Error(`'${e.id}' produced no create request.`);return{response:await w.createAutomationDraft(s,e,o)}}return{response:await w.createAutomationDraft(i,e,o)}},[r])}var J=n();function Y({name:e,field:t,values:n,canListRepositories:r,placeholder:i,disabled:a,onChange:o,onBlur:c}){let{t:l}=s(`openhands`),[u,f]=(0,V.useState)(``),p=e=>{let t=e.trim();!t||n.includes(t)||(o([...n,t]),f(``),c())},m=e=>{o(n.filter(t=>t!==e)),c()};return(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2`,"data-testid":`setup-list-${e}`,children:[n.length>0&&(0,J.jsx)(`ul`,{className:`flex flex-col gap-1.5`,children:n.map(t=>(0,J.jsxs)(`li`,{className:`flex items-center justify-between gap-2 rounded-md border border-[var(--oh-border)] px-3 py-1.5`,children:[(0,J.jsx)(`span`,{className:`truncate text-sm`,children:t}),(0,J.jsx)(O,{testId:`setup-list-${e}-remove-${t}`,type:`button`,variant:`ghost-danger`,isDisabled:a,ariaLabel:l(d.COMMON$REMOVE),onClick:()=>m(t),children:l(d.COMMON$REMOVE)})]},t))}),r?(0,J.jsx)(B,{provider:t.provider??`github`,value:null,repositoryName:null,placeholder:i,disabled:a,onChange:e=>{e?.full_name&&p(e.full_name)}}):(0,J.jsxs)(`div`,{className:`flex items-end gap-2`,children:[(0,J.jsx)(`div`,{className:`grow`,children:(0,J.jsx)(N,{testId:`setup-field-${e}`,name:e,label:``,ariaLabel:t.label,type:`text`,value:u,placeholder:i,isDisabled:a,onChange:f,onKeyDown:e=>{e.key===`Enter`&&(e.preventDefault(),p(u))},onBlur:()=>p(u)})}),(0,J.jsx)(O,{testId:`setup-list-${e}-add`,type:`button`,variant:`secondary`,isDisabled:a||u.trim()===``,onClick:()=>p(u),children:l(d.BUTTON$ADD)})]})]})}function Ge({name:e,field:t,value:n,error:r,options:i,isOptionsLoading:a=!1,repository:o,disabled:c,onChange:l,onRepositoryChange:p,onBlur:m}){let{t:h}=s(`openhands`),{backend:g}=u(),_=`setup-field-${e}`,v=(0,J.jsx)(`p`,{className:`text-xs text-[var(--oh-muted)]`,children:t.help}),ee=g.kind===`cloud`,y=t.placeholder??h(d.SETUP$REPOSITORY_PLACEHOLDER);if(t.type===`repo-picker`&&t.multiple)return(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(Z,{field:t}),(0,J.jsx)(Y,{name:e,field:t,values:T(n),canListRepositories:ee,placeholder:y,disabled:c,onChange:l,onBlur:m}),(0,J.jsx)(Q,{testId:_,error:r}),v]});if(t.type===`repo-picker`&&ee)return(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(Z,{field:t}),(0,J.jsx)(B,{provider:t.provider??`github`,value:o?.id??null,repositoryName:o?.full_name??S(n)??null,placeholder:t.placeholder,disabled:c,onChange:e=>{p(e??null),l(e?.full_name??``),m()}}),(0,J.jsx)(Q,{testId:_,error:r}),v]});if(t.type===`select`||t.type===`llm-profile`||[`timezone`,`event-source`,`event-type`].includes(t.type)&&i.length>0){let o=i.length>0,s=t.type===`llm-profile`&&!a&&!o;return(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(A,{testId:_,name:e,label:(0,J.jsx)(X,{field:t}),items:i.map(e=>({key:e.value,label:e.label})),selectedKey:S(n)||void 0,placeholder:s?h(d.MODEL$NO_SAVED_PROFILES):t.placeholder,isDisabled:c||s,isLoading:a,required:t.required,onSelectionChange:e=>{l(e===null?``:String(e)),m()}}),(0,J.jsx)(Q,{testId:_,error:r}),v]})}if(t.type===`plugin-sources`)return(0,J.jsxs)(`label`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(X,{field:t}),(0,J.jsx)(`textarea`,{"data-testid":_,name:e,rows:4,value:S(n),placeholder:t.placeholder,disabled:c,"aria-invalid":!!r,onChange:e=>l(e.target.value),onBlur:m,className:f(ve,r&&`border-red-500`)}),(0,J.jsx)(Q,{testId:_,error:r}),v]});if(t.type===`tarball-upload`)return(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(Z,{field:t}),(0,J.jsx)(`input`,{"data-testid":_,name:e,type:`file`,accept:`.tar,.tar.gz,.tgz,application/gzip,application/x-tar`,disabled:c,"aria-invalid":!!r,onChange:e=>{l(e.target.files?.[0]??``),m()},className:f(_e,`file:mr-3 file:rounded-md file:border-0 file:bg-neutral-700 file:px-3 file:py-1.5 file:text-sm file:text-white`,r&&`border-red-500`)}),S(n)&&(0,J.jsx)(`p`,{className:`text-xs text-[var(--oh-muted)]`,children:S(n)}),(0,J.jsx)(Q,{testId:_,error:r}),v]});if(t.type===`textarea`)return(0,J.jsxs)(`label`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(X,{field:t}),(0,J.jsx)(`textarea`,{"data-testid":_,name:e,rows:4,value:S(n),placeholder:t.placeholder,disabled:c,"aria-invalid":!!r,onChange:e=>l(e.target.value),onBlur:m,className:f(ve,r&&`border-red-500`)}),(0,J.jsx)(Q,{testId:_,error:r}),v]});let te=t.type===`repo-picker`?y:t.placeholder;return(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(N,{testId:_,name:e,type:t.type===`number`?`number`:`text`,label:t.label,value:S(n),placeholder:te,isDisabled:c,min:t.constraints?.min,max:t.constraints?.max,showRequiredTag:t.required,error:r,onChange:l,onBlur:m}),v]})}function X({field:e}){return(0,J.jsxs)(`span`,{className:`flex items-center gap-2 text-sm`,children:[e.label,e.required&&(0,J.jsx)(`span`,{className:`text-sm leading-none text-red-400`,"aria-hidden":!0,children:`*`})]})}function Z({field:e}){return(0,J.jsx)(`div`,{className:`flex items-center gap-2`,children:(0,J.jsx)(X,{field:e})})}function Q({testId:e,error:t}){return t?(0,J.jsx)(`p`,{role:`alert`,"data-testid":`${e}-error`,className:`-mt-1 text-xs text-red-400`,children:t}):null}var Ke=`/mcp`;function qe({prerequisites:e}){let{t}=s(`openhands`),{blockingIntegrations:n,warningIntegrations:r}=e;return(0,J.jsxs)(`div`,{className:`flex flex-col gap-4`,"data-testid":`setup-prerequisites`,children:[[...n,...r].map(({id:e,requirement:t,entry:n})=>(0,J.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,J.jsx)(`span`,{className:`text-sm`,children:n?.name??e}),(0,J.jsx)(`span`,{className:`text-xs text-[var(--oh-muted)]`,children:t.message})]},e)),(0,J.jsx)(k,{to:Ke,className:`text-sm underline`,children:t(d.SETUP$MANAGE_INTEGRATIONS)})]})}function Je({setup:e,values:t,selectedTrigger:n,selectedAction:r}){let{t:i}=s(`openhands`);return(0,J.jsx)(`div`,{className:`flex flex-col gap-4`,"data-testid":`setup-review`,children:(0,J.jsxs)(`dl`,{className:`flex flex-col gap-3`,children:[r&&e.actions?.[r]&&(0,J.jsxs)(`div`,{className:`flex flex-col gap-0.5`,children:[(0,J.jsx)(`dt`,{className:`text-xs text-[var(--oh-muted)]`,children:i(d.SETUP$ACTION_LABEL)}),(0,J.jsx)(`dd`,{className:`text-sm break-words`,children:e.actions[r]?.label})]}),Object.entries(re(e,n,r)).map(([e,n])=>(0,J.jsxs)(`div`,{className:`flex flex-col gap-0.5`,children:[(0,J.jsx)(`dt`,{className:`text-xs text-[var(--oh-muted)]`,children:n.label}),(0,J.jsx)(`dd`,{className:`text-sm break-words`,children:T(t[e]).join(`, `)||i(d.SETUP$EMPTY_VALUE)})]},e))]})})}var Ye=400,$={fieldErrors:{},formErrors:[]};function Xe(e){return e.formErrors.length>0||Object.keys(e.fieldErrors).length>0}function Ze(e){return typeof e.conversation_id==`string`?`/conversations/${e.conversation_id}`:typeof e.id==`string`?y(e.id):null}function Qe({entry:e,onClose:t}){let{t:n}=s(`openhands`),r=a(),i=we(e),o=Ee(e),c=Pe(e),l=We(),{trackAutomationSetupOpened:u,trackAutomationSetupValidated:p,trackAutomationSetupCreated:h,trackAutomationSetupFailed:g}=ue(),[_,v]=(0,V.useState)(`prerequisites`),y=(0,V.useMemo)(()=>pe(e.setup),[e]),b=(0,V.useMemo)(()=>y.length===0?[]:i.capabilities?Ce(e,i.capabilities):y,[y,i.capabilities,e]),x=(0,V.useMemo)(()=>de(e.setup),[e]),[S,w]=(0,V.useState)(()=>te(e.setup)),[T,le]=(0,V.useState)(()=>ie(e.setup)),[E,D]=(0,V.useState)(()=>C(e.setup,te(e.setup),ie(e.setup))),[me,_e]=(0,V.useState)({}),[ve,k]=(0,V.useState)({}),[ye,j]=(0,V.useState)($),[M,N]=(0,V.useState)(!1),P=(0,V.useRef)(E),F=(0,V.useRef)(null);(0,V.useEffect)(()=>()=>{F.current&&window.clearTimeout(F.current)},[]);let I=(0,V.useMemo)(()=>x.length===0?[]:(i.capabilities?Te(e,i.capabilities):x).filter(t=>oe(e,t).length===0),[x,i.capabilities,e]),L=(0,V.useMemo)(()=>re(e.setup,S,T),[e,S,T]),R=(0,V.useMemo)(()=>Object.values(L).some(e=>e.type===`llm-profile`),[L]),{data:z,isLoading:B}=xe({enabled:R}),De=(0,V.useMemo)(()=>(z?.profiles??[]).map(e=>({value:e.name,label:e.name})),[z?.profiles]),H=(0,V.useMemo)(()=>{let t=fe(e.setup,i.capabilities,S,T);return!R||B?t:Object.entries(L).reduce((e,[t,n])=>n.type===`llm-profile`?{...e,[t]:{options:De}}:e,t)},[e.setup,i.capabilities,S,T,R,B,L,De]),Oe=(0,V.useMemo)(()=>ae(e,E,void 0,S,T),[e,E,S,T]),Ae=(0,V.useMemo)(()=>ce(e,S,T),[e,S,T]),Me=(0,V.useRef)(!1);(0,V.useEffect)(()=>{Me.current||(Me.current=!0,u({automationId:e.id}))},[e.id,u]);let Ne=(0,V.useMemo)(()=>oe(e,T),[e,T]),U=i.supported===!1||Ne.length>0,W=[...i.unmet,...Ne],G=o.blockingIntegrations.length>0||o.warningIntegrations.length>0,K=_===`prerequisites`&&!G?`form`:_,q=t=>{w(t),P.current={...C(e.setup,t,T),...P.current},D(P.current),k({}),j($)},Fe=t=>{le(t),P.current={...C(e.setup,S,t),...P.current},D(P.current),k({}),j($)};(0,V.useEffect)(()=>{y.length===0||i.isLoading||S&&b.includes(S)||b.length>0&&q(b[0])},[b,y.length,i.isLoading,S]),(0,V.useEffect)(()=>{x.length===0||i.isLoading||T&&I.includes(T)||I.length>0&&Fe(I[0])},[I,x.length,i.isLoading,T]);let Ie=(e,t)=>{P.current={...P.current,[e]:t},D(P.current),k(({[e]:t,...n})=>n),j(t=>{if(!(e in t.fieldErrors))return t;let{[e]:n,...r}=t.fieldErrors;return{...t,fieldErrors:r}})},Le=()=>{F.current&&window.clearTimeout(F.current),F.current=window.setTimeout(()=>{c(P.current,S,T).then(e=>{e&&j(e)})},Ye)},Re=async()=>{if(K===`prerequisites`){v(`form`);return}let t=ne(e.setup,E,H,S,T);if(Object.keys(t).length>0){k(t);return}k({});let n=await c(E,S,T);if(n&&Xe(n)){j(n);return}j($),p({automationId:e.id}),v(`review`)},ze=async(i,a)=>{N(!0);try{let{response:n}=await l(e,E,i,S,T);h({automationId:e.id,setupMode:a});let o=Ze(n);o?r(o,{replace:!0}):t()}catch(t){g({automationId:e.id,setupMode:a});let r=je(ke(Se(t),i),Ae);j(Xe(r)?r:{fieldErrors:{},formErrors:[n(d.SETUP$SUBMIT_FAILED)]}),v(`form`)}finally{N(!1)}},Be=()=>ze(Oe,e.setup.mode),Ve=()=>ze(null,`assisted`),He=e.setup.mode===`direct`&&(ee(e)!==null||e.setup.message!==void 0),Ue=e=>{let t=ve[e];return t?$e(t,n):ye.fieldErrors[e]},Y=i.isLoading||o.isLoading,X=R&&B,Z=U?n(d.SETUP$UNAVAILABLE_TITLE):K===`prerequisites`?n(d.SETUP$PREREQUISITES_TITLE):K===`review`?n(d.SETUP$REVIEW_TITLE):e.name;return(0,J.jsx)(he,{onClose:t,"aria-label":e.name,children:(0,J.jsxs)(`div`,{"data-testid":`setup-dialog`,className:`relative flex max-h-[85vh] w-[92vw] max-w-lg flex-col rounded-xl border border-[var(--oh-border)] bg-base-secondary`,children:[(0,J.jsx)(be,{onClose:t,testId:`setup-dialog-close`,disabled:M}),(0,J.jsx)(`header`,{className:`flex-shrink-0 px-6 pb-4 pt-6`,children:(0,J.jsx)(`h2`,{className:f(`pr-6`,ge),children:Z})}),(0,J.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto px-6`,children:[Y&&(0,J.jsx)(`div`,{className:`flex justify-center py-6`,children:(0,J.jsx)(m,{size:`small`})}),!Y&&U&&(0,J.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,J.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:n(d.SETUP$UNSUPPORTED_MESSAGE)}),W.length>0&&(0,J.jsx)(`p`,{"data-testid":`setup-unmet-requirements`,className:`text-sm text-[var(--oh-muted)]`,children:W.join(`, `)})]}),!Y&&!U&&K===`prerequisites`&&(0,J.jsx)(qe,{prerequisites:o}),!Y&&!U&&K===`form`&&(0,J.jsxs)(`div`,{className:`flex flex-col gap-5`,children:[(0,J.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:e.description}),e.setup.form.note&&(0,J.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:e.setup.form.note}),x.length>1&&I.length>1&&(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(A,{testId:`setup-action-kind`,name:`actionKind`,label:n(d.SETUP$ACTION_LABEL),items:I.map(t=>({key:t,label:e.setup.actions?.[t]?.label??t})),selectedKey:T??void 0,isDisabled:M,required:!0,onSelectionChange:e=>{e!==null&&Fe(String(e))}}),T&&e.setup.actions?.[T]&&(0,J.jsx)(`p`,{className:`text-xs text-[var(--oh-muted)]`,children:e.setup.actions[T]?.help})]}),b.length>1&&(0,J.jsxs)(`div`,{className:`flex w-full flex-col gap-2.5`,children:[(0,J.jsx)(A,{testId:`setup-trigger-kind`,name:`triggerKind`,label:n(d.SETUP$TRIGGER_LABEL),items:b.map(e=>({key:e,label:e===`cron`?`Scheduled`:`Event`})),selectedKey:S??void 0,isDisabled:M,required:!0,onSelectionChange:e=>{e!==null&&q(String(e))}}),(0,J.jsx)(`p`,{className:`text-xs text-[var(--oh-muted)]`,children:n(d.SETUP$TRIGGER_HELP)})]}),Object.entries(L).map(([e,t])=>(0,J.jsx)(Ge,{name:e,field:t,value:E[e]??``,error:Ue(e),options:se(e,t,H),repository:me[e]??null,disabled:M,isOptionsLoading:t.type===`llm-profile`&&X,onChange:t=>Ie(e,t),onRepositoryChange:t=>_e(n=>({...n,[e]:t})),onBlur:Le},e))]}),!Y&&!U&&K===`review`&&(0,J.jsx)(Je,{setup:e.setup,values:E,selectedTrigger:S,selectedAction:T}),ye.formErrors.map(e=>(0,J.jsx)(`p`,{role:`alert`,"data-testid":`setup-form-error`,className:`pt-4 text-sm text-red-400`,children:e},e))]}),(0,J.jsxs)(`footer`,{className:`flex flex-shrink-0 justify-end gap-2 px-6 pb-6 pt-4`,children:[K===`review`&&(0,J.jsx)(O,{testId:`setup-back-button`,type:`button`,variant:`secondary`,isDisabled:M,onClick:()=>v(`form`),children:n(d.BUTTON$BACK)}),U?(0,J.jsxs)(J.Fragment,{children:[(0,J.jsx)(O,{type:`button`,variant:`secondary`,isDisabled:M,onClick:t,children:n(d.BUTTON$CLOSE)}),He&&(0,J.jsx)(O,{testId:`setup-fallback-conversation`,type:`button`,variant:`primary`,isDisabled:M,onClick:Ve,children:n(d.SETUP$FALLBACK_CONVERSATION)})]}):(0,J.jsx)(O,{testId:`setup-continue-button`,type:`button`,variant:`primary`,isDisabled:Y||X||M||K===`prerequisites`&&o.isBlocked,onClick:K===`review`?Be:Re,children:n(K===`review`?d.SETUP$CONFIRM:d.BUTTON$CONTINUE)})]})]})})}function $e(e,t){switch(e.code){case`required`:return t(d.SETUP$VALIDATION_REQUIRED);case`minLength`:return t(d.SETUP$VALIDATION_MIN_LENGTH,{length:e.length});case`maxLength`:return t(d.SETUP$VALIDATION_MAX_LENGTH,{length:e.length});case`min`:return`Must be at least ${e.value}.`;case`max`:return`Must be at most ${e.value}.`;case`invalidOption`:return t(d.SETUP$VALIDATION_INVALID_OPTION);case`unsafeExpressionLiteral`:return t(d.SETUP$VALIDATION_UNSAFE_VALUE);default:return e}}var et=({params:e})=>{let t=g.findById(e.automationId??``);if(!t||!v())throw new Response(null,{status:404,statusText:`Not Found`});return{automationId:t.id}},tt=o(function(){let{automationId:e}=i(),t=r(),n=a(),o=g.findById(e);return o?(0,J.jsx)(Qe,{entry:o,onClose:()=>{t.key==="default"?n(h(),{replace:!0}):n(-1)}}):null});export{et as clientLoader,tt as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{U as r}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~
|
|
1
|
+
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{U as r}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{t as i}from"./recommended-automations-launcher-YLAQTp4s.js";import{N as a}from"./use-tracking-B9prBsrq.js";import{n as o,r as s,t as c}from"./manifest-subpage-layout-BQQy5ipR.js";var l=e(t(),1),u=n(),d=()=>{if(!a())throw new Response(null,{status:404,statusText:`Not Found`});return null},f=r(function(){let[e,t]=(0,l.useState)(``),n=a(),r=o();return!n||!r?null:(0,u.jsxs)(c,{heading:r.heading,navTestIdBase:`automations-navbar`,items:r.items,children:[(0,u.jsxs)(`div`,{className:`min-w-0`,children:[(0,u.jsx)(`h1`,{className:`text-xl font-semibold text-content`,children:n.title}),(0,u.jsx)(`p`,{className:`mt-1 text-sm text-muted`,children:n.description})]}),(0,u.jsx)(`div`,{className:`w-full`,children:(0,u.jsx)(s,{value:e,onChange:t})}),(0,u.jsx)(i,{query:e})]})});export{d as clientLoader,f as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,bt as n,yt as r}from"./vendor-styling-Ck5D_A2Q.js";import{U as i}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{t as a}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{i as o}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-BfkNGovw.js";import{t as s}from"./useQueries-CykmpT-a.js";import{t as c}from"./recommended-automations-launcher-YLAQTp4s.js";import{ct as l,lt as u,n as d,st as f}from"./active-backend-context-rZiLJRUc.js";import{K as p,a as m,t as h}from"./utils-BOco8mxR.js";import{t as g}from"./check-fDEfgSzj.js";import{t as _}from"./chevron-down-CFrWHqu8.js";import{m as v,t as y}from"./kebab-menu-item-content-mm04SBD3.js";import{i as b,n as ee,r as te,t as ne}from"./empty-state-RZz0OfnY.js";import{P as x,_ as re,c as ie,g as ae,h as oe,l as se,m as ce}from"./home-automation-run-tooltip-CpHNFiFl.js";import{t as S}from"./list-filter-CNpqTWVY.js";import{t as le}from"./plus-B3wvU06-.js";import{t as ue}from"./refresh-cw-DEQdPCpH.js";import{n as C,t as w}from"./context-menu-list-item-DDROe12Z.js";import{A as de,D as fe,G as pe,P as T,S as me,W as he,n as E,t as ge,x as D}from"./use-tracking-B9prBsrq.js";import{t as O}from"./modal-backdrop-BSzNhM4r.js";import{n as _e}from"./modal-classes-Dg0ngBPO.js";import{t as k}from"./brand-button-DxPO4Lf8.js";import{n as ve}from"./navigation-context-CQZwH_tC.js";import{t as A,u as j}from"./dropdown-classes-B9kJVDIk.js";import{t as M}from"./modal-close-button-B9j4nasm.js";import{t as N}from"./use-click-outside-element-W6Os4Nlb.js";import{t as P}from"./enum-filter-dropdown-C4pW0ORd.js";import{t as ye}from"./use-automation-health-BZkQNEA8.js";import{t as F}from"./automation-C_eCrGyP.js";import{a as be,c as I,i as xe,o as Se,r as Ce,t as we}from"./use-automations-Cg0PDIZr.js";import{a as L}from"./extension-module-card-classes-DpeaYhYo.js";import{n as R}from"./api-error-message-Ve79qDcN.js";import{t as Te}from"./edit-automation-modal-BwhJ39JT.js";import{t as Ee}from"./use-automation-permissions-B_RpvL-s.js";import{n as De,t as Oe}from"./error-state-B_5cgNPJ.js";import{n as ke,r as Ae,t as je}from"./manifest-subpage-layout-BQQy5ipR.js";import{i as Me,n as Ne,r as Pe,t as Fe}from"./automation-export-DxY47m3T.js";var z=o(`file-up`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M12 12v6`,key:`3ahymv`}],[`path`,{d:`m15 15-3-3-3 3`,key:`15xj92`}]]),Ie=o(`grid-2x2`,[[`path`,{d:`M12 3v18`,key:`108xh3`}],[`path`,{d:`M3 12h18`,key:`1i2n21`}],[`rect`,{x:`3`,y:`3`,width:`18`,height:`18`,rx:`2`,key:`h1oib`}]]),Le=o(`rows-3`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M21 9H3`,key:`1338ky`}],[`path`,{d:`M21 15H3`,key:`9uk58r`}]]),B=e(t(),1),V=e(n(),1),H=r();function U({icon:e,label:t,isSelected:n}){return(0,H.jsxs)(`span`,{className:`flex min-w-0 w-full items-center gap-2`,children:[(0,H.jsx)(`span`,{className:j,"aria-hidden":!0,children:(0,H.jsx)(e,{})}),(0,H.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:t}),n?(0,H.jsx)(g,{className:`size-4 shrink-0`,"aria-hidden":!0}):null]})}var W=[{value:`grid`,icon:Ie,labelKey:p.AUTOMATIONS$VIEW_GRID,testId:`automations-view-toggle-grid`},{value:`list`,icon:Le,labelKey:p.AUTOMATIONS$VIEW_LIST,testId:`automations-view-toggle-list`}];function Re({view:e,onChange:t,disabled:n=!1}){let{t:r}=a(`openhands`),[i,o]=(0,B.useState)(!1),[s,c]=(0,B.useState)(),l=(0,B.useRef)(null),u=(0,B.useRef)(null),d=(W.find(t=>t.value===e)??W[0]).icon;(0,B.useLayoutEffect)(()=>{if(!i||!l.current)return;let e=()=>{let e=l.current?.getBoundingClientRect();e&&c({position:`fixed`,zIndex:9999,top:e.bottom+4,right:window.innerWidth-e.right})};return e(),window.addEventListener(`resize`,e),window.addEventListener(`scroll`,e,!0),()=>{window.removeEventListener(`resize`,e),window.removeEventListener(`scroll`,e,!0)}},[i]),(0,B.useEffect)(()=>{if(!i)return;let e=e=>{let t=e.target;l.current?.contains(t)||u.current?.contains(t)||o(!1)},t=e=>{e.key===`Escape`&&o(!1)};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[i]);let f=i&&s?(0,H.jsx)(C,{ref:u,theme:`popover`,className:`min-w-[10rem]`,children:W.map(n=>(0,H.jsx)(`li`,{children:(0,H.jsx)(w,{testId:n.testId,onClick:()=>{t(n.value),o(!1)},className:`group`,children:(0,H.jsx)(U,{icon:n.icon,label:r(n.labelKey),isSelected:e===n.value})})},n.value))}):null;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`button`,{ref:l,type:`button`,"data-testid":`automations-view-toggle`,"aria-label":r(p.AUTOMATIONS$VIEW_MODE),"aria-haspopup":`menu`,"aria-expanded":i,"aria-disabled":n,disabled:n,onClick:()=>{n||o(e=>!e)},className:h(`inline-flex size-9 shrink-0 cursor-pointer items-center justify-center rounded-lg border border-[var(--oh-border)] bg-base-secondary text-white transition-colors hover:bg-[var(--oh-interactive-hover)] focus-visible:border-white/40 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-white/20`,`disabled:cursor-not-allowed disabled:opacity-50 disabled:hover:bg-base-secondary`),children:(0,H.jsx)(d,{className:`size-4`,"aria-hidden":!0})}),i&&s&&typeof document<`u`?V.createPortal((0,H.jsx)(`div`,{style:s,children:f}),document.body):null]})}function ze({onAdd:e,onImport:t,isAddDisabled:n=!1}){let{t:r}=a(`openhands`),[i,o]=(0,B.useState)(!1),[s,c]=(0,B.useState)(),l=(0,B.useRef)(null),u=(0,B.useRef)(null);(0,B.useLayoutEffect)(()=>{if(!i||!l.current)return;let e=()=>{let e=l.current?.getBoundingClientRect();e&&c({position:`fixed`,zIndex:9999,top:e.bottom+2,right:window.innerWidth-e.right})};return e(),window.addEventListener(`resize`,e),window.addEventListener(`scroll`,e,!0),()=>{window.removeEventListener(`resize`,e),window.removeEventListener(`scroll`,e,!0)}},[i]),(0,B.useEffect)(()=>{if(!i)return;let e=e=>{let t=e.target;l.current?.contains(t)||u.current?.contains(t)||o(!1)},t=e=>{e.key===`Escape`&&o(!1)};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[i]);let d=e=>{e(),o(!1)},f=i&&s?(0,H.jsxs)(C,{ref:u,testId:`automations-add-automation-menu`,theme:`popover`,position:`none`,alignment:`none`,spacing:`none`,className:`min-w-[10rem]`,children:[(0,H.jsx)(`li`,{children:(0,H.jsx)(w,{testId:`automations-add-automation-create`,isDisabled:n,className:`group`,onClick:()=>{n||d(e)},children:(0,H.jsx)(y,{icon:(0,H.jsx)(le,{className:`size-4`,"aria-hidden":!0}),label:r(p.AUTOMATIONS$CREATE_AUTOMATION_BUTTON)})})}),(0,H.jsx)(`li`,{children:(0,H.jsx)(w,{testId:`automations-import-automation`,className:`group`,onClick:()=>d(t),children:(0,H.jsx)(y,{icon:(0,H.jsx)(z,{className:`size-4`,"aria-hidden":!0}),label:r(p.AUTOMATIONS$IMPORT)})})})]}):null;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(k,{ref:l,type:`button`,variant:`secondary`,testId:`automations-add-automation`,className:`whitespace-nowrap`,"aria-haspopup":`menu`,"aria-expanded":i,onClick:()=>o(e=>!e),children:[r(p.AUTOMATIONS$ADD_AUTOMATION),(0,H.jsx)(_,{className:`size-4 shrink-0`,"aria-hidden":!0})]}),i&&s&&typeof document<`u`?V.createPortal((0,H.jsx)(`div`,{style:s,children:f}),document.body):null]})}function G({label:e,value:t}){return(0,H.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,H.jsx)(`dt`,{className:`text-xs font-medium uppercase tracking-wide text-muted`,children:e}),(0,H.jsx)(`dd`,{className:`whitespace-pre-wrap break-words text-sm text-content`,children:t})]})}function K(e){let t=e.dataTransfer?.files;return t&&t.length>0?t[0]:null}function Be({onFile:e}){let{t}=a(`openhands`),n=(0,B.useRef)(null),[r,i]=(0,B.useState)(!1),o=()=>n.current?.click();return(0,H.jsxs)(`div`,{className:`flex flex-col gap-5 px-6 pb-6`,children:[(0,H.jsxs)(`p`,{className:`text-sm leading-relaxed text-tertiary-light`,children:[t(p.AUTOMATIONS$IMPORT_EXPLAIN),` `,(0,H.jsx)(`a`,{href:D,target:`_blank`,rel:`noopener noreferrer`,"data-testid":`import-automation-format-docs`,className:`text-white no-underline transition-colors hover:text-white`,children:t(p.AUTOMATIONS$IMPORT_FORMAT_DOCS)})]}),(0,H.jsx)(`p`,{className:`text-sm text-tertiary-light`,children:t(p.AUTOMATIONS$IMPORT_DISABLED_NOTICE)}),(0,H.jsx)(`input`,{ref:n,type:`file`,accept:`application/json,.json`,className:`hidden`,"data-testid":`automations-import-file`,onChange:()=>{let t=n.current,r=t?.files?.[0];t&&(t.value=``),r&&e(r)}}),(0,H.jsxs)(`div`,{"data-testid":`import-automation-dropzone`,"data-active":r?`true`:`false`,onClick:o,onDragEnter:e=>{e.preventDefault(),i(!0)},onDragOver:e=>{e.preventDefault(),i(!0)},onDragLeave:e=>{e.currentTarget.contains(e.relatedTarget)||i(!1)},onDrop:t=>{t.preventDefault(),i(!1);let n=K(t);n&&e(n)},className:h(`flex cursor-pointer flex-col items-center justify-center gap-3 rounded-xl border border-dashed px-6 py-10 text-center`,r?`border-[var(--oh-focus)] bg-[var(--oh-interactive-hover)]`:`border-[var(--oh-border)] bg-[var(--oh-surface)]`),children:[(0,H.jsx)(z,{className:`size-8 text-[var(--oh-muted)]`,"aria-hidden":!0}),(0,H.jsx)(`p`,{className:`text-sm font-medium text-content`,children:t(p.AUTOMATIONS$IMPORT_DROPZONE)}),(0,H.jsx)(`p`,{className:`text-xs text-tertiary-light`,children:t(p.AUTOMATIONS$IMPORT_OR)}),(0,H.jsx)(k,{testId:`import-automation-choose-file`,type:`button`,variant:`secondary`,onClick:e=>{e?.stopPropagation(),o()},children:t(p.AUTOMATIONS$IMPORT_CHOOSE_FILE)})]})]})}function Ve({isOpen:e,spec:t,isImporting:n,onClose:r,onImport:i,onFile:o}){let{t:s}=a(`openhands`);if(!e)return null;let c=t?t.trigger.type===`event`?[t.trigger.source,v(t.trigger.on)].filter(Boolean).join(`: `):[t.trigger.schedule_human??t.trigger.schedule,t.timezone??t.trigger.timezone].filter(Boolean).join(` · `):``;return(0,H.jsx)(O,{onClose:n?void 0:r,closeOnEscape:!n,closeOnBackdropClick:!n,"aria-label":s(p.AUTOMATIONS$IMPORT),children:(0,H.jsxs)(`div`,{"data-testid":`import-automation-modal`,"data-view":t?`preview`:`picker`,className:`relative flex max-h-[85vh] w-[min(36rem,calc(100vw-2rem))] flex-col rounded-xl border border-[var(--oh-border)] bg-base-secondary`,children:[(0,H.jsx)(M,{onClose:r,testId:`import-automation-modal-close`,disabled:n}),(0,H.jsxs)(`header`,{className:`px-6 pb-4 pt-6`,children:[(0,H.jsx)(`h2`,{className:h(`pr-6`,_e),children:s(p.AUTOMATIONS$IMPORT)}),t?(0,H.jsx)(`p`,{className:`mt-2 text-sm text-tertiary-light`,children:s(p.AUTOMATIONS$IMPORT_PREVIEW_DESCRIPTION)}):null]}),t?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`dl`,{className:`mx-6 flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto rounded-xl border border-[var(--oh-border)] bg-[var(--oh-surface)] px-4 py-4`,children:[(0,H.jsx)(G,{label:s(p.AUTOMATIONS$NAME),value:t.name}),(0,H.jsx)(G,{label:s(p.AUTOMATIONS$DETAIL$TRIGGER),value:c}),(0,H.jsx)(G,{label:s(p.AUTOMATIONS$PROMPT),value:t.prompt??``}),t.plugins&&t.plugins.length>0?(0,H.jsx)(G,{label:s(p.AUTOMATIONS$DETAIL$PLUGINS),value:t.plugins.join(`, `)}):null]}),(0,H.jsxs)(`footer`,{className:`px-6 py-5`,children:[(0,H.jsx)(`p`,{className:`mb-4 text-sm text-tertiary-light`,children:s(p.AUTOMATIONS$IMPORT_DISABLED_NOTICE)}),(0,H.jsxs)(`div`,{className:`flex justify-end gap-3`,children:[(0,H.jsx)(k,{testId:`import-automation-cancel`,type:`button`,variant:`secondary`,onClick:r,isDisabled:n,children:s(p.AUTOMATIONS$CANCEL)}),(0,H.jsx)(k,{testId:`import-automation-confirm`,type:`button`,variant:`primary`,onClick:i,isDisabled:n,"aria-busy":n,children:s(n?p.AUTOMATIONS$IMPORTING:p.AUTOMATIONS$IMPORT)})]})]})]}):(0,H.jsx)(Be,{onFile:o})]})})}var q=20,He=15e3,Ue=e=>e.status===F.PENDING||e.status===F.RUNNING;function We(e,t={}){let{enabled:n=!0}=t,r=d();return s({queries:e.map(e=>({queryKey:[...I,e.id,{limit:q,offset:0},r.backend.id,r.orgId],queryFn:({signal:t})=>x.run(()=>E.getAutomationRuns(e.id,q,0),t),staleTime:60*1e3,retry:!1,refetchOnWindowFocus:!1,meta:{disableToast:!0},enabled:n&&!!e.id,refetchInterval:e=>{let t=e.state.data?.runs?.[0];return t&&Ue(t)?He:!1}})),combine:t=>{let n=new Map;return e.forEach((e,r)=>{let i=t[r];n.set(e.id,{summary:i.data?re(i.data):null,isLoading:i.isLoading,isError:i.isError})}),n}})}function J({label:e,children:t}){return(0,H.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,H.jsx)(`span`,{className:`text-xs font-medium text-muted`,children:e}),t]})}function Y(e){return Object.fromEntries(e.map(e=>[e.value,e.label]))}function Ge({spec:e,status:t,trigger:n,sort:r,onStatusChange:i,onTriggerChange:o,onSortChange:s}){let{t:c}=a(`openhands`),[l,u]=(0,B.useState)(!1),d=N(()=>u(!1)),f=e.filters.find(e=>e.id===`status`),m=e.filters.find(e=>e.id===`trigger`),g=[f&&t!==f.options[0]?.value,m&&n!==m.options[0]?.value,r!==e.sort.default].filter(Boolean).length,v=c(p.AUTOMATIONS$FILTERS),y=f?.options[0]?.value,b=m?.options[0]?.value;return(0,H.jsxs)(`div`,{ref:d,className:`relative shrink-0 w-auto`,"data-testid":`automations-filters`,children:[(0,H.jsxs)(`button`,{type:`button`,"data-testid":`dropdown-trigger`,"aria-haspopup":`true`,"aria-expanded":l,"aria-label":v,onClick:()=>u(e=>!e),className:h(A,`h-9 py-0`,g>0&&`border-white/60 bg-white/10`),children:[(0,H.jsx)(S,{className:`h-4 w-4 shrink-0`,"aria-hidden":!0}),(0,H.jsx)(`span`,{className:`whitespace-nowrap`,children:v}),g>0?(0,H.jsx)(`span`,{className:`rounded-full bg-white px-1.5 text-[11px] font-medium text-black`,children:g}):null,(0,H.jsx)(_,{className:h(`h-4 w-4 shrink-0 text-tertiary-alt transition-transform`,l&&`rotate-180`),"aria-hidden":!0})]}),l?(0,H.jsxs)(`div`,{role:`group`,"data-testid":`automations-filters-menu`,"aria-label":v,className:`absolute right-0 top-full z-50 mt-1 flex min-w-[16rem] w-max flex-col gap-3 overflow-visible rounded-[6px] bg-tertiary p-3 context-menu-box-shadow`,children:[f?(0,H.jsx)(J,{label:f.label,children:(0,H.jsx)(P,{testId:`automations-filter-status`,value:t,onChange:i,options:f.options.map(e=>e.value),labelByValue:Y(f.options),ariaLabel:f.label,fullWidth:!0})}):null,m?(0,H.jsx)(J,{label:m.label,children:(0,H.jsx)(P,{testId:`automations-filter-trigger`,value:n,onChange:o,options:m.options.map(e=>e.value),labelByValue:Y(m.options),ariaLabel:m.label,fullWidth:!0})}):null,(0,H.jsx)(J,{label:e.sort.label,children:(0,H.jsx)(P,{testId:`automations-sort`,value:r,onChange:s,options:e.sort.options.map(e=>e.value),labelByValue:Y(e.sort.options),ariaLabel:e.sort.label,fullWidth:!0})}),g>0?(0,H.jsx)(`button`,{type:`button`,"data-testid":`automations-filters-reset`,onClick:()=>{y&&i(y),b&&o(b),s(e.sort.default)},className:`self-start text-sm text-muted hover:text-foreground`,children:c(p.AUTOMATIONS$RESET_ALL)}):null]}):null]})}function Ke({onClear:e}){let{t}=a(`openhands`);return(0,H.jsxs)(`div`,{"data-testid":`automations-filtered-empty`,className:`rounded-xl border border-dashed border-[var(--oh-border)] p-8 text-center`,children:[(0,H.jsx)(`p`,{className:`text-sm text-muted`,children:t(p.AUTOMATIONS$NO_FILTER_MATCHES)}),(0,H.jsx)(`button`,{type:`button`,"data-testid":`automations-clear-filters`,onClick:e,className:`mt-2 text-sm text-white underline-offset-2 hover:underline`,children:t(p.AUTOMATIONS$CLEAR_FILTERS)})]})}function qe({label:e,tiles:t}){return(0,H.jsx)(`section`,{"aria-label":e,className:`grid grid-cols-2 gap-3 xl:grid-cols-4`,children:t.map(e=>(0,H.jsxs)(`div`,{"data-testid":`overview-tile-${e.key}`,className:h(L,`p-4`),children:[(0,H.jsxs)(`div`,{className:`flex items-center justify-between gap-2`,children:[(0,H.jsx)(`span`,{className:`truncate text-xs text-muted`,children:e.label}),(0,H.jsx)(e.Icon,{className:`size-4 shrink-0 text-[var(--oh-muted)]`,"aria-hidden":!0})]}),(0,H.jsx)(`div`,{className:`mt-2 text-xl font-semibold text-content`,children:e.value}),(0,H.jsx)(`div`,{className:`mt-1 truncate text-xs text-muted`,children:e.detail})]},e.key))})}var Je=50,X=()=>{if(!T())throw new Response(null,{status:404,statusText:`Not Found`});return null},Z=i(function(){let{t:e}=a(`openhands`),t=de(),n=(0,B.useMemo)(()=>fe(),[]),r=ke(),i=n&&r?{spec:n,nav:r}:null,[o,s]=(0,B.useState)(``),[g,_]=(0,B.useState)(`all`),[v,y]=(0,B.useState)(`all`),[x,re]=(0,B.useState)(n?.sort.default??`last-run`),[S,le]=(0,B.useState)(()=>ie()),[C,w]=(0,B.useState)(Je),[T,E]=(0,B.useState)(null),[D,O]=(0,B.useState)(null),[_e,A]=(0,B.useState)(!1),[j,M]=(0,B.useState)(null),[N,P]=(0,B.useState)(!1),F=d(),{navigate:I}=ve(),L=F.backend.kind===`local`,{canManage:z}=Ee(),{data:Ie,isLoading:Le,refetch:V}=ye(),U=Ie?.status===`ok`,{data:W,isLoading:G,isError:K,refetch:Be}=we({limit:C,offset:0,enabled:U}),q=We(W?.automations??[],{enabled:U&&i!==null}),{trackPrebuiltAutomationEnabled:He,trackAutomationExported:Ue}=ge(),J=Se(),Y=Ce(),X=xe(),Z=be(),Q=(0,B.useMemo)(()=>W?.automations?n?ce(W.automations,{search:o,status:g,trigger:v,sort:x},q):W.automations.filter(e=>ae(e,o)):[],[W?.automations,n,o,g,v,x,q]),$=(0,B.useMemo)(()=>Q.filter(e=>e.enabled),[Q]),Ye=(0,B.useMemo)(()=>Q.filter(e=>!e.enabled),[Q]),Xe=(e,t)=>{let n=!t;if(J.mutate({id:e,enabled:n}),n){let t=W?.automations.find(t=>t.id===e);He({automationId:e,automationName:t?.name??e})}},Ze=t=>{X.mutate(t,{onSuccess:()=>{l(e(p.AUTOMATIONS$RUN_NOW_SUCCESS))},onError:t=>{f(R(t,e(p.AUTOMATIONS$RUN_NOW_ERROR)))}})},Qe=e=>{let t=W?.automations.find(t=>t.id===e);t&&E({id:e,name:t.name})},$e=e=>{let t=W?.automations.find(t=>t.id===e);t&&O(t)},et=e=>{let t=`${JSON.stringify(Pe(e),null,2)}\n`;m(new Blob([t],{type:`application/json`}),Fe(e)),Ue({backendKind:F.backend.kind})},tt=async t=>{try{let n;try{n=JSON.parse(await t.text())}catch{f(e(p.AUTOMATIONS$IMPORT_INVALID_JSON));return}M(Ne(n))}catch(t){f(t instanceof Error?t.message:e(p.ERROR$GENERIC))}},nt=()=>{j&&Z.mutate({...j,enabled:!1},{onSuccess:t=>{P(!1),M(null),u(e(p.AUTOMATIONS$IMPORT_SUCCESS,{name:t.name}),e(p.AUTOMATIONS$IMPORT_VIEW),me(t.id))},onError:t=>{f(R(t,e(p.ERROR$GENERIC)))}})},rt=()=>{T&&(Y.mutate(T.id),E(null))},it=(0,B.useCallback)(e=>{le(e),se(e)},[]),at=()=>{s(``),_(`all`),y(`all`)},ot=(0,B.useMemo)(()=>{if(!n)return[];let e=W?.automations??[];return n.overview.tiles.map(t=>{let n=oe(t.metric,e,q),r=n.isZero&&t.zeroDetail?t.zeroDetail:t.detail;return{key:t.metric,label:t.label,value:n.display,detail:he(r,n.placeholderValues),Icon:pe[t.icon]}})},[n,W?.automations,q]),st=i?{spec:i.spec.insights,byId:q}:void 0,ct=e=>i?(0,H.jsx)(je,{heading:i.nav.heading,navTestIdBase:`automations-navbar`,items:i.nav.items,children:e}):(0,H.jsx)(`div`,{className:`min-h-full`,children:(0,H.jsx)(`div`,{className:`p-6 max-w-4xl mx-auto`,children:e})}),lt=W?W.total>W.automations.length:!1,ut=!G&&!K&&W?.automations.length===0;return ct(Le?(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h1`,{className:`text-xl font-medium text-content`,children:t.listTitle}),(0,H.jsx)(`p`,{className:`mt-1 text-sm text-muted`,children:t.listSubtitle}),(0,H.jsx)(`div`,{className:`mt-6 flex flex-col gap-3`,children:Array.from({length:3}).map((e,t)=>(0,H.jsx)(b,{},`skeleton-${String(t)}`))})]}):U?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`flex items-start justify-between gap-4`,children:[(0,H.jsxs)(`div`,{className:`min-w-0`,children:[(0,H.jsx)(`h1`,{className:`text-xl font-semibold text-content`,children:t.listTitle}),(0,H.jsx)(`p`,{className:`mt-1 text-sm text-muted`,children:t.listSubtitle})]}),(0,H.jsxs)(`div`,{className:`flex shrink-0 flex-wrap justify-end gap-2`,children:[L&&(0,H.jsx)(k,{type:`button`,variant:`secondary`,testId:`automations-git-sync`,className:`whitespace-nowrap`,onClick:()=>I?.(`/automations/git-sync`),startContent:(0,H.jsx)(ue,{className:`size-4`,"aria-hidden":!0}),children:e(p.AUTOMATIONS$GIT_SYNC$NAV_BUTTON)}),z?(0,H.jsx)(ze,{onAdd:()=>A(!0),onImport:()=>P(!0)}):null]})]}),i&&(0,H.jsx)(qe,{label:i.spec.overview.label,tiles:ot}),(0,H.jsxs)(`div`,{className:h(`flex items-stretch gap-2`,i?`flex-wrap`:`mt-6`),children:[(0,H.jsx)(Ae,{value:o,onChange:s}),i&&(0,H.jsx)(Ge,{spec:i.spec,status:g,trigger:v,sort:x,onStatusChange:_,onTriggerChange:y,onSortChange:re}),(0,H.jsx)(Re,{view:S,onChange:it,disabled:ut})]}),(0,H.jsxs)(`div`,{className:h(`flex flex-col gap-6`,!i&&`mt-6`),children:[G&&(0,H.jsx)(`div`,{className:`flex flex-col gap-3`,children:Array.from({length:3}).map((e,t)=>(0,H.jsx)(b,{},`skeleton-${String(t)}`))}),K&&!G&&(0,H.jsx)(Oe,{onRetry:Be}),ut&&(0,H.jsx)(ne,{}),!G&&!K&&W&&W.automations.length>0&&(i&&Q.length===0?(0,H.jsx)(Ke,{onClear:at}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(te,{title:e(p.AUTOMATIONS$ACTIVE),count:$.length,automations:$,view:S,onToggle:Xe,onRunNow:Ze,runPendingId:X.isPending?X.variables??null:null,onDelete:Qe,onExport:et,onEdit:L?$e:void 0,insights:st}),(0,H.jsx)(te,{title:e(p.AUTOMATIONS$INACTIVE),count:Ye.length,automations:Ye,view:S,onToggle:Xe,onRunNow:Ze,runPendingId:X.isPending?X.variables??null:null,onDelete:Qe,onExport:et,onEdit:L?$e:void 0,insights:st}),lt&&(0,H.jsx)(`button`,{type:`button`,onClick:()=>w(e=>e+Je),className:`self-center rounded-lg border border-[var(--oh-border)] px-6 py-2 text-sm text-white hover:bg-surface-raised`,children:e(p.AUTOMATIONS$LOAD_MORE)})]}))]}),!i&&(0,H.jsx)(`div`,{className:`mt-6`,children:(0,H.jsx)(c,{query:o})}),(0,H.jsx)(Me,{automationName:T?.name??``,isOpen:T!==null,onConfirm:rt,onCancel:()=>E(null)}),D&&(0,H.jsx)(Te,{automation:D,isOpen:D!==null,onClose:()=>O(null)}),(0,H.jsx)(ee,{isOpen:_e,onClose:()=>A(!1)}),(0,H.jsx)(Ve,{isOpen:N,spec:j,isImporting:Z.isPending,onClose:()=>{P(!1),M(null)},onImport:nt,onFile:tt})]}):(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h1`,{className:`text-xl font-medium text-content`,children:t.listTitle}),(0,H.jsx)(`p`,{className:`mt-1 text-sm text-muted`,children:t.listSubtitle}),(0,H.jsx)(De,{onRetry:V})]}))});export{X as clientLoader,Z as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-Cyuzqnbw.js";import{St as e,yt as t}from"./vendor-styling-Ck5D_A2Q.js";import{
|
|
1
|
+
import"./rolldown-runtime-Cyuzqnbw.js";import{St as e,yt as t}from"./vendor-styling-Ck5D_A2Q.js";import{i as n}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-BfkNGovw.js";import{t as r}from"./utils-BOco8mxR.js";import{r as i}from"./form-control-classes-B-z85REi.js";import{t as a}from"./navigation-link-Bxo3-4vo.js";var o=n(`arrow-left`,[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]);e();var s=t();function c({children:e}){return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o,{size:20,"aria-hidden":!0}),e]})}function l(e){let{children:t,testId:n,className:o}=e,l=r(i,o);return`to`in e?(0,s.jsx)(a,{to:e.to,onClick:e.onClick,"data-testid":n,className:l,children:(0,s.jsx)(c,{children:t})}):(0,s.jsx)(`button`,{type:`button`,onClick:e.onClick,"data-testid":n,className:l,children:(0,s.jsx)(c,{children:t})})}export{l as t};
|
|
@@ -0,0 +1 @@
|
|
|
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-CV850oio.js";import{i as a}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-BfkNGovw.js";import{t as o}from"./useQuery-S6j94er1.js";import{J as s,r as c,tt as l,w as u}from"./active-backend-context-rZiLJRUc.js";import{K as d,t as f}from"./utils-BOco8mxR.js";import{B as p,H as m,O as h,n as g,z as _}from"./agent-server-client-options-BikiNwTa.js";import{t as v}from"./chevron-down-CFrWHqu8.js";import{a as y,i as b,n as x,r as S}from"./cloud-funnel-analytics-BQanUEEC.js";import{t as C}from"./info-CTIdjttz.js";import{a as w,i as T,n as E,r as D,x as ee}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~b0x1wrp2-Z0lly3FE.js";import{a as O,i as k,n as A,o as j,r as M}from"./use-onboarding-completion-CoINurkm.js";import{t as N}from"./use-tracking-B9prBsrq.js";import{t as P}from"./modal-backdrop-BSzNhM4r.js";import{n as te,r as ne,t as re}from"./modal-body-DJw4xBki.js";import{n as ie,r as ae}from"./modal-classes-Dg0ngBPO.js";import{t as F}from"./brand-button-DxPO4Lf8.js";import{n as oe}from"./navigation-context-CQZwH_tC.js";import{t as I}from"./modal-close-button-B9j4nasm.js";import{t as L}from"./settings-input-C0dd8Utu.js";var se=a(`monitor`,[[`rect`,{width:`20`,height:`14`,x:`2`,y:`3`,rx:`2`,key:`48i651`}],[`line`,{x1:`8`,x2:`16`,y1:`21`,y2:`21`,key:`1svkeh`}],[`line`,{x1:`12`,x2:`12`,y1:`17`,y2:`21`,key:`vw1qmm`}]]),R=e(n()),z=r(),B=e=>(0,z.jsxs)(`svg`,{width:1365,height:1365,viewBox:`0 -24 148 148`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,z.jsx)(`path`,{d:`M71.7542 16.863V2.97414C71.7542 1.82355 72.6872 0.890503 73.8378 0.890503C74.9884 0.890503 75.9214 1.82355 75.9214 2.97414V16.863C75.9214 18.0136 74.9884 18.9466 73.8378 18.9466C72.6872 18.9466 71.7542 18.0136 71.7542 16.863Z`,fill:`white`}),(0,z.jsx)(`path`,{d:`M82.5272 18.9329L89.4716 6.90477C90.0469 5.90832 91.3215 5.5668 92.3179 6.1421C93.3144 6.7174 93.6559 7.99197 93.0806 8.98841L86.1362 21.0165C85.5609 22.0129 84.2863 22.3545 83.2899 21.7792C82.2934 21.2039 81.9519 19.9293 82.5272 18.9329Z`,fill:`white`}),(0,z.jsx)(`path`,{d:`M65.1481 18.9329L58.2037 6.90477C57.6284 5.90832 56.3538 5.5668 55.3574 6.1421C54.3609 6.7174 54.0194 7.99197 54.5947 8.98841L61.5391 21.0165C62.1144 22.0129 63.389 22.3545 64.3854 21.7792C65.3819 21.2039 65.7234 19.9293 65.1481 18.9329Z`,fill:`white`}),(0,z.jsx)(`path`,{d:`M140.606 62.0292C140.606 58.409 141.583 47.6748 141.89 44.1323C142.097 41.7374 141.809 40.4247 141.424 39.7542C141.141 39.2626 140.699 38.915 139.634 38.8436C138.865 38.7921 138.027 39.0114 137.401 39.5761C136.814 40.1052 136.159 41.1682 136.159 43.3176L136.155 43.4388L135.198 59.758C135.164 60.3451 134.883 60.8911 134.424 61.2599C133.966 61.6284 133.374 61.7859 132.793 61.6941L122.764 60.1068L111.948 58.6703C110.949 58.5376 110.188 57.7084 110.142 56.7016L109.561 44.1323C109.535 43.621 109.51 43.1141 109.484 42.6146C109.241 37.9294 109.022 33.7805 109.022 32.4282C109.022 28.3859 108.338 26.6806 107.74 25.9634C107.263 25.3915 106.577 25.1402 105.11 25.1402C104.583 25.1402 104.212 25.2481 103.933 25.4111C103.659 25.5714 103.346 25.8587 103.049 26.4208C102.41 27.6257 101.945 29.891 102.118 33.8479C102.342 38.9804 102.692 42.8146 103.035 46.2718C103.377 49.7231 103.718 52.8561 103.908 56.4971C104.204 62.1966 104.178 66.1256 103.945 68.7924C103.828 70.124 103.656 71.1996 103.423 72.0501C103.202 72.8558 102.871 73.6757 102.296 74.2887C101.6 75.0303 100.608 75.3844 99.577 75.136C98.7592 74.9389 98.1847 74.4215 97.8706 74.0916C97.2141 73.4017 96.7501 72.5106 96.568 72.0512C95.5097 69.3812 92.2352 63.1808 87.8023 59.6811C86.5089 58.6599 85.5666 58.3652 84.9736 58.3204C84.4148 58.2783 84.0094 58.4436 83.6909 58.6967C83.34 58.9756 83.0781 59.3811 82.9479 59.7643C82.9019 59.8999 82.8823 59.9968 82.8741 60.0584C84.0759 62.0865 88.8421 69.5222 91.0896 77.069C92.7648 82.6941 96.8038 88.4259 99.8194 90.8809C102.74 93.258 107.988 94.7313 113.9 95.0218C119.756 95.3095 125.788 94.4121 130.033 92.5092C138.233 88.8334 139.903 80.7382 140.651 77.2292C141.232 74.5057 141.243 71.5987 141.087 68.9009C141.01 67.5551 140.894 66.2969 140.793 65.1373C140.695 64.0105 140.606 62.9215 140.606 62.0292ZM120.986 27.0953C120.986 25.8314 120.648 24.7049 120.089 23.9514C119.583 23.27 118.84 22.7987 117.646 22.7984C116.668 22.7982 116.011 22.9187 115.546 23.1167C115.13 23.2943 114.781 23.5699 114.463 24.0831C113.73 25.2671 113.192 27.6455 113.189 32.384L113.721 43.9088C113.91 47.5661 114.106 51.4922 114.235 54.7707L120.986 55.6666V27.0953ZM125.153 56.2652L131.172 57.218L131.992 43.267V32.5083C131.992 31.031 131.39 30.1275 130.678 29.5489C129.884 28.9039 128.957 28.6731 128.519 28.6731C127.722 28.6731 126.899 28.797 126.306 29.2179C125.849 29.5421 125.153 30.3087 125.153 32.5083V56.2652ZM136.159 35.4278C137.406 34.8069 138.74 34.6083 139.912 34.6868C142.037 34.8292 143.91 35.718 145.037 37.6779C146.06 39.4592 146.273 41.8136 146.041 44.4927C145.72 48.1949 144.772 58.6457 144.772 62.0292C144.772 62.708 144.843 63.6116 144.944 64.7758C145.042 65.907 145.165 67.2389 145.247 68.6606C145.411 71.4987 145.422 74.8383 144.727 78.0987C144.002 81.4953 142.041 91.6918 131.738 96.3108C126.731 98.5551 120.002 99.4936 113.696 99.1838C107.445 98.8767 101.128 97.3189 97.1887 94.1122C93.4809 91.0937 88.9938 84.6307 87.0962 78.2589C84.9529 71.0619 80.3109 63.9646 79.1527 61.9533C78.4706 60.7689 78.684 59.3628 79.0019 58.4258C79.3607 57.3688 80.0554 56.2631 81.0993 55.4337C82.1758 54.5784 83.6043 54.0377 85.2876 54.1647C86.9369 54.2893 88.6462 55.0393 90.3834 56.4107C94.8541 59.9401 98.1342 65.5082 99.7424 68.9231C99.759 68.7664 99.779 68.6024 99.7941 68.4298C100.003 66.0435 100.039 62.3344 99.7467 56.7132C99.5635 53.1942 99.2356 50.1809 98.8888 46.6828C98.5425 43.1904 98.184 39.2713 97.955 34.0302C97.7722 29.8481 98.2012 26.6722 99.3672 24.471C99.9716 23.3302 100.79 22.4223 101.83 21.814C102.866 21.2087 103.995 20.974 105.11 20.974C106.759 20.974 108.813 21.2062 110.448 22.7678C110.593 22.4576 110.75 22.1652 110.921 21.8899C111.676 20.6698 112.681 19.8084 113.912 19.2835C115.095 18.7791 116.378 18.6309 117.646 18.6311C120.195 18.6315 122.164 19.7567 123.434 21.4683C124.256 22.576 124.75 23.8775 124.985 25.1982C126.338 24.5876 127.691 24.5068 128.519 24.5068C129.933 24.5068 131.784 25.0791 133.305 26.3154C134.908 27.6179 136.159 29.6733 136.159 32.5083V35.4278Z`,fill:`white`}),(0,z.jsx)(`path`,{d:`M7.15661 62.0292C7.15661 58.409 6.17994 47.6748 5.87291 44.1323C5.6654 41.7374 5.95357 40.4247 6.33875 39.7542C6.62116 39.2626 7.06336 38.915 8.12834 38.8436C8.89759 38.7921 9.73544 39.0114 10.3616 39.5761C10.9484 40.1052 11.6032 41.1682 11.6032 43.3176L11.6074 43.4388L12.5644 59.758C12.5988 60.3451 12.8798 60.8911 13.338 61.2599C13.7961 61.6284 14.3887 61.7859 14.9695 61.6941L24.9988 60.1068L35.8143 58.6703C36.8135 58.5376 37.5741 57.7084 37.6208 56.7016L38.2015 44.1323C38.2279 43.621 38.2525 43.1141 38.2784 42.6146C38.5218 37.9294 38.7401 33.7805 38.7401 32.4282C38.7401 28.3859 39.4246 26.6806 40.0227 25.9634C40.4996 25.3915 41.185 25.1402 42.6523 25.1402C43.1794 25.1402 43.5505 25.2481 43.8295 25.4111C44.1038 25.5714 44.416 25.8587 44.7138 26.4208C45.3521 27.6257 45.8173 29.891 45.6444 33.8479C45.4201 38.9804 45.0703 42.8146 44.7275 46.2718C44.3853 49.7231 44.0443 52.8561 43.8548 56.4971C43.5582 62.1966 43.5847 66.1256 43.8179 68.7924C43.9344 70.124 44.1069 71.1996 44.3396 72.0501C44.5601 72.8558 44.891 73.6757 45.4663 74.2887C46.1625 75.0303 47.1546 75.3844 48.1855 75.136C49.0033 74.9389 49.5778 74.4215 49.8918 74.0916C50.5484 73.4017 51.0123 72.5106 51.1945 72.0512C52.2527 69.3812 55.5272 63.1808 59.9601 59.6811C61.2536 58.6599 62.1958 58.3652 62.7889 58.3204C63.3476 58.2783 63.753 58.4436 64.0715 58.6967C64.4225 58.9756 64.6844 59.3811 64.8146 59.7643C64.8606 59.8999 64.8801 59.9968 64.8883 60.0584C63.6866 62.0865 58.9204 69.5222 56.6729 77.069C54.9977 82.6941 50.9586 88.4259 47.9431 90.8809C45.0229 93.258 39.7747 94.7313 33.8624 95.0218C28.0068 95.3095 21.9748 94.4121 17.7297 92.5092C9.52988 88.8334 7.85961 80.7382 7.11129 77.2292C6.53054 74.5057 6.5195 71.5987 6.67496 68.9009C6.75251 67.5551 6.86809 66.2969 6.96901 65.1373C7.06707 64.0105 7.1566 62.9215 7.15661 62.0292ZM26.7768 27.0953C26.7768 25.8314 27.1147 24.7049 27.6737 23.9514C28.1792 23.27 28.9221 22.7987 30.1167 22.7984C31.0942 22.7982 31.7518 22.9187 32.2162 23.1167C32.6326 23.2943 32.9817 23.5699 33.2996 24.0831C34.0328 25.2671 34.5705 27.6455 34.5738 32.384L34.0416 43.9088C33.8524 47.5661 33.6565 51.4922 33.5273 54.7707L26.7768 55.6666V27.0953ZM22.6095 56.2652L16.5904 57.218L15.7705 43.267V32.5083C15.7705 31.031 16.3726 30.1275 17.0847 29.5489C17.8785 28.9039 18.8058 28.6731 19.2432 28.6731C20.0404 28.6731 20.8634 28.797 21.4565 29.2179C21.9131 29.5421 22.6095 30.3087 22.6095 32.5083V56.2652ZM11.6032 35.4278C10.3568 34.8069 9.02265 34.6083 7.8501 34.6868C5.72541 34.8292 3.85197 35.718 2.72584 37.6779C1.70247 39.4592 1.48924 41.8136 1.72143 44.4927C2.0423 48.1949 2.99038 58.6457 2.99038 62.0292C2.99037 62.708 2.91991 63.6116 2.81859 64.7758C2.72014 65.907 2.59699 67.2389 2.51505 68.6606C2.3515 71.4987 2.34041 74.8383 3.0357 78.0987C3.76005 81.4953 5.72154 91.6918 16.0245 96.3108C21.0311 98.5551 27.7601 99.4936 34.0669 99.1838C40.3172 98.8767 46.6346 97.3189 50.5737 94.1122C54.2816 91.0937 58.7686 84.6307 60.6662 78.2589C62.8095 71.0619 67.4515 63.9646 68.6098 61.9533C69.2919 60.7689 69.0785 59.3628 68.7605 58.4258C68.4018 57.3688 67.707 56.2631 66.6632 55.4337C65.5867 54.5784 64.1582 54.0377 62.4748 54.1647C60.8256 54.2893 59.1162 55.0393 57.379 56.4107C52.9083 59.9401 49.6283 65.5082 48.02 68.9231C48.0034 68.7664 47.9835 68.6024 47.9684 68.4298C47.7597 66.0435 47.7232 62.3344 48.0158 56.7132C48.1989 53.1942 48.5269 50.1809 48.8737 46.6828C49.22 43.1904 49.5784 39.2713 49.8075 34.0302C49.9903 29.8481 49.5612 26.6722 48.3952 24.471C47.7909 23.3302 46.9729 22.4223 45.9321 21.814C44.8964 21.2087 43.7676 20.974 42.6523 20.974C41.0038 20.974 38.9497 21.2062 37.3141 22.7678C37.1698 22.4576 37.0124 22.1652 36.8419 21.8899C36.0863 20.6698 35.0817 19.8084 33.8508 19.2835C32.6679 18.7791 31.3849 18.6309 30.1167 18.6311C27.5677 18.6315 25.5986 19.7567 24.3285 21.4683C23.5066 22.576 23.0121 23.8775 22.7771 25.1982C21.4247 24.5876 20.0718 24.5068 19.2432 24.5068C17.8298 24.5068 15.9788 25.0791 14.4573 26.3154C12.8542 27.6179 11.6032 29.6733 11.6032 32.5083V35.4278Z`,fill:`white`})]});function ce(e){return w(e,{headers:u})}function le(e,t,n){return T(e,t,{...n,headers:u})}var V=e=>(0,z.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:(0,z.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M15.3235 10.9352L11.5016 14.2111L7.67969 10.9352L8.6152 9.84375L11.5016 12.3178L14.388 9.84375L15.3235 10.9352Z`,fill:`currentColor`})}),H=e=>(0,z.jsxs)(`svg`,{width:16,height:16,viewBox:`0 0 16 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,z.jsx)(`path`,{d:`M13 3H8.33337V4H11.2929L7.31315 7.97978L8.02026 8.68689L12 4.70711V7.66667H13V3Z`,fill:`currentColor`}),(0,z.jsx)(`path`,{d:`M4.33333 3.66667C3.59695 3.66667 3 4.26362 3 5V11.6667C3 12.403 3.59695 13 4.33333 13H11C11.7364 13 12.3333 12.403 12.3333 11.6667V9.66667H11.3333V11.6667C11.3333 11.8508 11.1841 12 11 12H4.33333C4.14924 12 4 11.8508 4 11.6667V5C4 4.81591 4.14924 4.66667 4.33333 4.66667H6.33333V3.66667H4.33333Z`,fill:`currentColor`})]}),ue=e=>(0,z.jsx)(`svg`,{viewBox:`0 0 18 18`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,z.jsx)(`path`,{d:`M8.25 9.75C8.10166 9.75 7.95666 9.79399 7.83332 9.8764C7.70999 9.95881 7.61386 10.0759 7.55709 10.213C7.50032 10.35 7.48547 10.5008 7.51441 10.6463C7.54335 10.7918 7.61478 10.9254 7.71967 11.0303C7.82456 11.1352 7.9582 11.2066 8.10368 11.2356C8.24917 11.2645 8.39997 11.2497 8.53701 11.1929C8.67406 11.1361 8.79119 11.04 8.8736 10.9167C8.95601 10.7933 9 10.6483 9 10.5C9 10.3011 8.92098 10.1103 8.78033 9.96967C8.63968 9.82902 8.44891 9.75 8.25 9.75ZM5.25 9.75C5.10166 9.75 4.95666 9.79399 4.83332 9.8764C4.70999 9.95881 4.61386 10.0759 4.55709 10.213C4.50032 10.35 4.48547 10.5008 4.51441 10.6463C4.54335 10.7918 4.61478 10.9254 4.71967 11.0303C4.82456 11.1352 4.9582 11.2066 5.10368 11.2356C5.24917 11.2645 5.39997 11.2497 5.53701 11.1929C5.67406 11.1361 5.79119 11.04 5.8736 10.9167C5.95601 10.7933 6 10.6483 6 10.5C6 10.3011 5.92098 10.1103 5.78033 9.96967C5.63968 9.82902 5.44891 9.75 5.25 9.75ZM16.5 3C16.5 2.40326 16.2629 1.83097 15.841 1.40901C15.419 0.987053 14.8467 0.75 14.25 0.75H3.75C3.15326 0.75 2.58097 0.987053 2.15901 1.40901C1.73705 1.83097 1.5 2.40326 1.5 3V6C1.50331 6.55504 1.71166 7.08927 2.085 7.5C1.71166 7.91073 1.50331 8.44496 1.5 9V12C1.5 12.5967 1.73705 13.169 2.15901 13.591C2.58097 14.0129 3.15326 14.25 3.75 14.25H8.25V15.75H2.25C2.05109 15.75 1.86032 15.829 1.71967 15.9697C1.57902 16.1103 1.5 16.3011 1.5 16.5C1.5 16.6989 1.57902 16.8897 1.71967 17.0303C1.86032 17.171 2.05109 17.25 2.25 17.25H15.75C15.9489 17.25 16.1397 17.171 16.2803 17.0303C16.421 16.8897 16.5 16.6989 16.5 16.5C16.5 16.3011 16.421 16.1103 16.2803 15.9697C16.1397 15.829 15.9489 15.75 15.75 15.75H9.75V14.25H14.25C14.8467 14.25 15.419 14.0129 15.841 13.591C16.2629 13.169 16.5 12.5967 16.5 12V9C16.4967 8.44496 16.2883 7.91073 15.915 7.5C16.2883 7.08927 16.4967 6.55504 16.5 6V3ZM15 12C15 12.1989 14.921 12.3897 14.7803 12.5303C14.6397 12.671 14.4489 12.75 14.25 12.75H3.75C3.55109 12.75 3.36032 12.671 3.21967 12.5303C3.07902 12.3897 3 12.1989 3 12V9C3 8.80109 3.07902 8.61032 3.21967 8.46967C3.36032 8.32902 3.55109 8.25 3.75 8.25H14.25C14.4489 8.25 14.6397 8.32902 14.7803 8.46967C14.921 8.61032 15 8.80109 15 9V12ZM15 6C15 6.19891 14.921 6.38968 14.7803 6.53033C14.6397 6.67098 14.4489 6.75 14.25 6.75H3.75C3.55109 6.75 3.36032 6.67098 3.21967 6.53033C3.07902 6.38968 3 6.19891 3 6V3C3 2.80109 3.07902 2.61032 3.21967 2.46967C3.36032 2.32902 3.55109 2.25 3.75 2.25H14.25C14.4489 2.25 14.6397 2.32902 14.7803 2.46967C14.921 2.61032 15 2.80109 15 3V6ZM8.25 3.75C8.10166 3.75 7.95666 3.79399 7.83332 3.8764C7.70999 3.95881 7.61386 4.07594 7.55709 4.21299C7.50032 4.35003 7.48547 4.50083 7.51441 4.64632C7.54335 4.7918 7.61478 4.92544 7.71967 5.03033C7.82456 5.13522 7.9582 5.20665 8.10368 5.23559C8.24917 5.26453 8.39997 5.24968 8.53701 5.19291C8.67406 5.13614 8.79119 5.04001 8.8736 4.91668C8.95601 4.79334 9 4.64834 9 4.5C9 4.30109 8.92098 4.11032 8.78033 3.96967C8.63968 3.82902 8.44891 3.75 8.25 3.75ZM5.25 3.75C5.10166 3.75 4.95666 3.79399 4.83332 3.8764C4.70999 3.95881 4.61386 4.07594 4.55709 4.21299C4.50032 4.35003 4.48547 4.50083 4.51441 4.64632C4.54335 4.7918 4.61478 4.92544 4.71967 5.03033C4.82456 5.13522 4.9582 5.20665 5.10368 5.23559C5.24917 5.26453 5.39997 5.24968 5.53701 5.19291C5.67406 5.13614 5.79119 5.04001 5.8736 4.91668C5.95601 4.79334 6 4.64834 6 4.5C6 4.30109 5.92098 4.11032 5.78033 3.96967C5.63968 3.82902 5.44891 3.75 5.25 3.75Z`,fill:`currentColor`})});function U(e,t,n){let r=n?.lastError??null,i=t?.kind===`cloud`;return i&&!t?.apiKey?.trim()||O(r)?e(d.BACKEND$STATUS_DISCONNECTED_ADD_API_KEY):k(r)?e(d.BACKEND$STATUS_DISCONNECTED_CHECK_API_KEY):M(r)?e(d.BACKEND$LOGGED_OUT):n?.isConnected===!0?e(d.ONBOARDING$BACKEND_STATUS_CONNECTED):i&&n?.isConnected===!1&&(A(r)||m(r))?e(d.BACKEND$STATUS_DISCONNECTED_CHECK_CLOUD_ACCESS):n?.isConnected===!1&&p(r)?e(d.BACKEND$STATUS_DISCONNECTED_CHECK_TUNNEL):n?.isConnected===!1&&m(r)?e(d.BACKEND$STATUS_DISCONNECTED_CHECK_URL_OR_NETWORK):n?.isConnected===!1?e(d.ONBOARDING$BACKEND_STATUS_DISCONNECTED):e(d.ONBOARDING$BACKEND_STATUS_CHECKING)}function W({isConnected:e,className:t}){let n,r,i;return e===`unavailable`?(n=`bg-[var(--oh-text-tertiary)]`,r=`No Backend Available`,i=`unavailable`):e===!0?(n=`bg-[var(--oh-status-success)]`,r=`Connected`,i=`connected`):e===!1?(n=`bg-red-500`,r=`Disconnected`,i=`disconnected`):(n=`bg-[var(--oh-interactive-selected)]`,r=`Checking connection`,i=`checking`),(0,z.jsx)(`span`,{"data-testid":`backend-status-dot`,"data-status":i,"aria-label":r,title:r,role:`status`,className:f(`inline-block w-2 h-2 rounded-full shrink-0`,n,t)})}var G={status:`idle`,verificationUrl:null,userCode:null,apiKey:null,error:null,errorCode:null};function de(){let[e,t]=R.useState(G),n=R.useRef(null),r=R.useCallback((e,r)=>{n.current?.abort();let i=new AbortController;n.current=i,t({...G,status:`starting`}),(async()=>{let n;try{n=await ce(e)}catch(e){if(i.signal.aborted)return;let n=e instanceof Error?e.message:`Failed to start device flow`,r=e instanceof E?e.code:void 0;t({...G,status:`error`,error:n,errorCode:r??null});return}if(!i.signal.aborted){x(e,r),t({...G,status:`awaiting_authorization`,verificationUrl:n.verification_uri_complete,userCode:n.user_code});try{let a=await le(e,n.device_code,{interval:n.interval,signal:i.signal});if(i.signal.aborted)return;S(e,r),t({...G,status:`success`,apiKey:a.access_token})}catch(e){if(i.signal.aborted)return;if(e instanceof E&&e.code===`cancelled`){t(G);return}let n=e instanceof Error?e.message:`Authorization failed`,r=e instanceof E?e.code:void 0;t({...G,status:`error`,error:n,errorCode:r??null})}}})()},[]),i=R.useCallback(()=>{n.current?.abort(),n.current=null,t(G)},[]),a=R.useCallback(()=>{n.current?.abort(),n.current=null,t(G)},[]);return R.useEffect(()=>()=>{n.current?.abort()},[]),{...e,start:r,cancel:i,reset:a}}function K(e){try{return new URL(e).protocol===`https:`}catch{return!1}}function q({host:e,onSuccess:t,testIdRoot:n,isDisabled:r=!1,idleButtonLabel:a,idleButtonContent:o,idleDescription:s,idleFooter:c,className:l,buttonClassName:u,buttonVariant:p=`primary`,statusDisplay:m=`inline`,analyticsSource:h}){let{t:g}=i(`openhands`),_=de(),v=R.useRef(null);R.useEffect(()=>()=>{v.current?.close()},[]),R.useEffect(()=>{if(_.status===`awaiting_authorization`&&_.verificationUrl&&v.current&&!v.current.closed){if(!K(_.verificationUrl)){console.error(`Invalid verification URL protocol`);return}try{v.current.location.href=_.verificationUrl}catch{v.current=window.open(_.verificationUrl,`_blank`,`noopener,noreferrer`)}}},[_.status,_.verificationUrl]),R.useEffect(()=>{if(_.status===`success`&&_.apiKey)try{t(_.apiKey)}finally{_.reset(),v.current?.close()}},[_.status,_.apiKey,_.reset,t]);let y=()=>{let t=e.trim().replace(/\/+$/,``),n=/^https?:\/\//i.test(t)?t:`https://${t}`;try{let e=new URL(n);if(e.username||e.password)throw Error(`Invalid URL format`)}catch{return}v.current=window.open(`about:blank`,`_blank`),v.current||console.warn(`Popup blocked - user will need to use manual link`),_.start(n,h)},b=()=>{_.cancel(),v.current?.close()},x=(0,z.jsx)(fe,{status:_.status,error:_.error,verificationUrl:_.verificationUrl,testIdRoot:n,onCancel:b,onRetry:y}),S=m===`modal`&&_.status!==`idle`,C=a??g(d.BACKEND$LOGIN_WITH_OPENHANDS);return(0,z.jsxs)(`div`,{"data-testid":`${n}-device-flow`,className:f(`flex flex-col gap-3`,l),children:[_.status===`idle`?s:null,_.status===`idle`&&p===`unstyled`&&(0,z.jsx)(`button`,{type:`button`,onClick:y,"data-testid":`${n}-login-button`,className:u,disabled:r,"aria-label":o?C:void 0,children:o??C}),_.status===`idle`&&p!==`unstyled`&&(0,z.jsx)(F,{type:`button`,variant:p,onClick:y,testId:`${n}-login-button`,className:u,isDisabled:r,ariaLabel:o?C:void 0,children:o??C}),_.status===`idle`?c:null,m===`inline`?x:null,S?(0,z.jsx)(P,{onClose:b,"aria-label":g(d.BACKEND$LOGIN_WITH_OPENHANDS),closeOnBackdropClick:!1,children:(0,z.jsx)(te,{testID:`${n}-auth-modal`,width:`sm`,className:`items-stretch border border-[var(--oh-border)]`,children:x})}):null]})}function fe({status:e,error:t,verificationUrl:n,testIdRoot:r,onCancel:a,onRetry:o}){let{t:s}=i(`openhands`);if(e===`idle`||e===`success`)return null;if(e===`starting`)return(0,z.jsxs)(`div`,{className:`flex items-center justify-center gap-2`,"data-testid":`${r}-auth-starting`,role:`status`,"aria-live":`polite`,children:[(0,z.jsx)(pe,{}),(0,z.jsx)(`span`,{className:`text-sm text-[var(--oh-text-tertiary)]`,children:s(d.BACKEND$AUTH_STARTING)})]});if(e===`awaiting_authorization`){let e=n&&K(n)?n:null;return(0,z.jsxs)(`div`,{className:`flex flex-col gap-4`,"data-testid":`${r}-auth-awaiting`,role:`status`,"aria-live":`polite`,children:[(0,z.jsxs)(`div`,{className:`flex items-center justify-center gap-2`,children:[(0,z.jsx)(pe,{}),(0,z.jsx)(`span`,{className:`text-sm font-medium text-white`,children:s(d.BACKEND$AUTH_AWAITING)})]}),(0,z.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,z.jsx)(`p`,{className:`text-center text-sm leading-5 text-[var(--oh-text-tertiary)]`,children:e?`${s(d.BACKEND$AUTH_BROWSER_OPENED)} ${s(d.BACKEND$AUTH_OPEN_MANUALLY)}`:s(d.BACKEND$AUTH_BROWSER_OPENED)}),e?(0,z.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,className:`max-h-16 overflow-auto break-all text-center text-xs text-blue-400 hover:underline`,children:e}):null]}),(0,z.jsx)(F,{type:`button`,variant:`secondary`,onClick:a,testId:`${r}-auth-cancel`,className:`w-full`,children:s(d.BACKEND$AUTH_CANCEL)})]})}return(0,z.jsxs)(`div`,{className:`flex flex-col gap-3 rounded-lg border border-red-700 bg-red-900/20 p-4`,"data-testid":`${r}-auth-error`,role:`alert`,children:[(0,z.jsx)(`p`,{className:`text-sm text-red-400`,children:t}),(0,z.jsx)(F,{type:`button`,variant:`secondary`,onClick:o,testId:`${r}-auth-retry`,className:`w-full`,children:s(d.BACKEND$AUTH_RETRY)})]})}function pe(){return(0,z.jsx)(`svg`,{className:`animate-spin h-4 w-4 text-white`,xmlns:`http://www.w3.org/2000/svg`,fill:`none`,viewBox:`0 0 24 24`,"aria-hidden":`true`,children:(0,z.jsx)(`path`,{className:`opacity-75`,fill:`currentColor`,d:`M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z`})})}var me=t({BackendConnectionOptions:()=>De,BackendForm:()=>Q,BackendFormModal:()=>Pe});function he(e){return D(e)?`cloud`:`local`}function ge(e){let t=e.toLowerCase().replace(/^\[|\]$/g,``);return!!(t===`localhost`||t===`::1`||t===`::`||t===`0.0.0.0`||/^127\./.test(t)||/^::ffff:127\./i.test(t)||/^10\./.test(t)||/^192\.168\./.test(t)||/^172\.(1[6-9]|2\d|3[01])\./.test(t)||/^fe[89ab][0-9a-f]:/i.test(t)||/^f[cd][0-9a-f]{2}:/i.test(t)||t.endsWith(`.local`)||!t.includes(`.`)&&!t.includes(`:`))}function J(e){let t=e.trim().replace(/\/+$/,``);if(!t)return``;if(/^https?:\/\//i.test(t))return t;let n=t.match(/^\[([^\]]+)\]/);return`${ge(n?n[1]:(t.match(/:/g)??[]).length>1?t:t.split(`:`)[0])?`http`:`https`}://${t}`}function Y(e){let t=e.trim();if(!t||/\s/.test(t))return!1;let n=J(t);if(!n)return!1;try{let e=new URL(n);return(e.protocol===`http:`||e.protocol===`https:`)&&e.hostname.length>0}catch{return!1}}var X=`https://app.all-hands.dev`,_e=`agent-canvas --backend-only --port 8001`,ve=`https://github.com/OpenHands/OpenHands/blob/main/docs/DEVELOPMENT.md#alternative-development-workflows`,ye=`https://github.com/OpenHands/OpenHands/blob/main/docs/SELF_HOSTING.md`,be=`https://docs.openhands.dev/overview/introduction`;function xe(e,t){return e(d.BACKEND$CONNECTION_TEST_FAILED,{host:t,interpolation:{escapeValue:!1}})}function Se(e){return _(e)}function Ce(e,t){let n=Se(t);return n?`${e}\n${n}`:e}async function we(e){return e.kind===`local`?{agentServerVersion:await l(e,5e3)}:{agentServerVersion:null}}function Te({backend:e,testIdRoot:t}){let{t:n}=i(`openhands`),r=j([e])[e.id],a=r?.isConnected??null,c=r?.disabled===!0,l=r?.consecutiveFailures??0,u=r?.lastError??null,{data:f}=o({queryKey:[`backend-version`,e.host,e.apiKey],queryFn:async()=>s(await new ee(g({host:e.host,sessionApiKey:e.apiKey||null,timeout:5e3})).getServerInfo()),retry:!1,staleTime:6e4,enabled:e.kind===`local`&&!c}),p=U(n,e,r),m=e.kind===`cloud`?n(d.BACKEND$KIND_CLOUD):n(d.BACKEND$KIND_LOCAL);return(0,z.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,z.jsxs)(`div`,{"data-testid":`${t}-status`,className:`flex items-center gap-3 text-sm`,children:[(0,z.jsx)(W,{isConnected:a}),(0,z.jsx)(`span`,{className:`text-white`,"data-testid":`${t}-status-label`,children:p}),(0,z.jsx)(`span`,{className:`text-tertiary-alt`,children:`·`}),(0,z.jsx)(`span`,{className:`text-[var(--oh-text-tertiary)]`,children:m}),f?(0,z.jsx)(`span`,{className:`text-xs text-[var(--oh-muted)]`,"data-testid":`${t}-version`,children:n(d.BACKEND$VERSION_LABEL,{version:f})}):null]}),c?(0,z.jsxs)(`div`,{"data-testid":`${t}-status-error`,className:`flex flex-col gap-1 rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm`,children:[(0,z.jsx)(`span`,{className:`font-semibold text-red-300`,children:n(d.BACKEND$HEALTH_FAILED_TITLE)}),(0,z.jsx)(`span`,{className:`text-xs text-[var(--oh-text-tertiary)]`,children:n(d.BACKEND$HEALTH_FAILED_DETAIL,{count:l})}),u?(0,z.jsx)(`span`,{"data-testid":`${t}-status-error-message`,className:`text-xs text-red-300 whitespace-pre-wrap break-words`,children:u}):null]}):null]})}function Z({initialName:e=``,initialHost:t=``,initialApiKey:n=``,onTestConnection:r,onSuccess:a,requireApiKey:o=!1,onSubmitOverride:s,fixedKind:c}){let{t:l}=i(`openhands`),[u,d]=R.useState(e),[f,p]=R.useState(t),[m,h]=R.useState(n),[g,_]=R.useState(null),[v,y]=R.useState(!1),[b,x]=R.useState(null),S=c??b??he(f),C=o||S!==`local`,w=u.trim().length>0&&Y(f)&&(!C||m.trim().length>0);return{name:u,setName:d,host:f,setHost:p,apiKey:m,setApiKey:h,connectionError:g,setConnectionError:_,isSubmitting:v,kind:S,setKind:x,canSubmit:w,handleSubmit:R.useCallback(async e=>{if(e.preventDefault(),!w||v)return;let t={name:u.trim(),host:J(f),apiKey:m.trim(),kind:S};_(null),y(!0);try{s?await s(t):a(await r(t))}catch(e){_(Ce(xe(l,t.host),e))}finally{y(!1)}},[w,v,u,f,m,S,r,a,o,s,c,l])}}function Q({mode:e,backend:t,onSubmitted:n,renderActions:r,testIdRoot:a,hostReadOnly:o,requireApiKey:s,hideConfigurationFields:l=!1,onSubmitOverride:u}){let{t:p}=i(`openhands`),{addBackend:m,updateBackend:h}=c(),g=e===`edit`&&t?t.kind:null,{name:_,setName:v,host:y,setHost:b,apiKey:x,setApiKey:S,connectionError:C,setConnectionError:w,isSubmitting:T,kind:E,handleSubmit:D}=Z({initialName:t?.name??``,initialHost:t?.host??``,initialApiKey:t?.apiKey??``,onTestConnection:we,onSuccess:async()=>{let r={name:_.trim(),host:J(y),apiKey:x.trim(),kind:g??E};e===`edit`&&t?h(t.id,r):m(r),n()},requireApiKey:s,onSubmitOverride:u}),[ee,O]=R.useState(!1),[k,A]=R.useState(!1),j=g??E,M=a??(e===`edit`?`edit-backend`:`add-backend`),N=s||j!==`local`,P=_.trim().length>0&&Y(y)&&(!N||x.trim().length>0),te=ee&&!_.trim()?p(d.BACKEND$NAME_REQUIRED):void 0,ne=k?y.trim()?Y(y)?void 0:p(d.BACKEND$HOST_INVALID):p(d.BACKEND$HOST_REQUIRED):void 0;return(0,z.jsxs)(`form`,{"data-testid":`${M}-form`,onSubmit:async e=>{if(!P){O(!0),A(!0);return}await D(e)},className:`flex flex-col gap-4`,children:[(0,z.jsxs)(`div`,{"data-testid":`${M}-configuration-fields`,className:f(`flex flex-col gap-4`,l&&`hidden`),children:[(0,z.jsx)(L,{testId:`${M}-name`,name:`${M}-name`,type:`text`,label:p(d.BACKEND$NAME_LABEL),value:_,onChange:e=>{v(e),w(null)},onBlur:()=>O(!0),placeholder:`Production`,className:`w-full`,showRequiredTag:!0,error:te}),(0,z.jsx)(L,{testId:`${M}-host`,name:`${M}-host`,type:`text`,label:p(d.BACKEND$HOST_LABEL),value:y,onChange:o?void 0:e=>{b(e),w(null)},onBlur:()=>A(!0),placeholder:X,className:`w-full`,showRequiredTag:!0,error:ne,isDisabled:o}),(0,z.jsx)(L,{testId:`${M}-api-key`,name:`${M}-api-key`,type:`password`,label:p(d.BACKEND$KEY_LABEL),value:x,onChange:e=>{S(e),w(null)},placeholder:``,className:`w-full`}),C?(0,z.jsx)(`div`,{role:`alert`,"data-testid":`${M}-error`,className:`rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm text-red-300 whitespace-pre-wrap break-words`,children:C}):null,e===`edit`&&t&&(0,z.jsx)(Te,{backend:t,testIdRoot:M})]}),r?r({canSubmit:P&&!T,isSubmitting:T,testIdRoot:M}):(0,z.jsxs)(`div`,{className:`flex justify-end gap-2 mt-2 w-full`,children:[(0,z.jsx)(F,{type:`button`,variant:`secondary`,onClick:n,testId:`${M}-cancel`,children:p(d.BUTTON$CANCEL)}),(0,z.jsx)(F,{type:`submit`,variant:`primary`,isDisabled:!P||T,testId:`${M}-submit`,children:p(d.BACKEND$SAVE)})]})]})}function Ee(){let{currentPath:e,navigate:t}=oe();return R.useCallback(()=>{/^\/automations\/[^/]+/.test(e)?t(`/automations`):/^\/conversations\/[^/]+/.test(e)&&t(`/conversations`)},[e,t])}function De({onConnected:e,testIdRoot:t=`add-backend`,initialManualBackend:n,requireManualApiKey:r=!1,manualSubmitLabel:a,manualSubmittingLabel:o,manualSubmitTestId:s,analyticsSource:c}){let{t:l}=i(`openhands`),u=h();return u?(0,z.jsx)(`div`,{"data-testid":`${t}-connection-options`,className:`flex justify-center`,children:(0,z.jsx)(`div`,{className:`w-full`,children:(0,z.jsx)($,{onConnected:e,testIdRoot:t,lockedHost:u,analyticsSource:c})})}):(0,z.jsxs)(`div`,{"data-testid":`${t}-connection-options`,className:`flex flex-col gap-6 md:flex-row`,children:[(0,z.jsx)(`div`,{className:`flex-1 min-w-0`,children:(0,z.jsx)(Oe,{onConnected:e,testIdRoot:t,initialBackend:n,requireApiKey:r,submitLabel:a??l(d.BACKEND$CONNECT),submittingLabel:o??l(d.ONBOARDING$BACKEND_STATUS_CHECKING),submitTestId:s})}),(0,z.jsx)(`div`,{className:`flex-1 min-w-0`,children:(0,z.jsx)($,{onConnected:e,testIdRoot:t,analyticsSource:c})})]})}function Oe({onConnected:e,testIdRoot:t,initialBackend:n,requireApiKey:r,submitLabel:a,submittingLabel:o,submitTestId:s,fixedKind:c,showKindSelector:l=!0}){let{t:u}=i(`openhands`),{name:f,setName:p,host:m,setHost:h,apiKey:g,setApiKey:_,connectionError:v,setConnectionError:y,isSubmitting:x,kind:S,setKind:C,canSubmit:w,handleSubmit:T}=Z({initialName:n?.name??``,initialHost:n?.host??``,initialApiKey:n?.apiKey??``,onTestConnection:we,onSuccess:t=>{e({name:f.trim(),host:J(m),apiKey:g.trim(),kind:S},`manual`,t)},requireApiKey:r,fixedKind:c});return(0,z.jsxs)(`form`,{"data-testid":`${t}-form`,onSubmit:T,className:`flex flex-col gap-4 flex-1 min-w-0`,children:[(0,z.jsx)(L,{testId:`${t}-name`,name:`${t}-name`,type:`text`,label:u(d.BACKEND$NAME_LABEL),hint:u(d.BACKEND$NAME_HELPER),value:f,onChange:e=>{p(e),y(null)},placeholder:`e.g. My Server`,className:`w-full`}),(0,z.jsx)(L,{testId:`${t}-host`,name:`${t}-host`,type:`text`,label:u(d.BACKEND$HOST_LABEL),hint:u(d.BACKEND$HOST_HELPER),value:m,onChange:e=>{h(e),y(null)},placeholder:`http://localhost:8000`,className:`w-full`}),l?(0,z.jsxs)(`div`,{className:`flex flex-col items-start gap-2.5`,children:[(0,z.jsx)(`span`,{className:`text-sm`,children:u(d.BACKEND$KIND_LABEL)}),(0,z.jsx)(b,{value:S,options:[{value:`local`,label:u(d.BACKEND$KIND_LOCAL)},{value:`cloud`,label:u(d.BACKEND$KIND_CLOUD)}],onChange:e=>C(e),ariaLabel:u(d.BACKEND$KIND_LABEL),testId:`${t}-kind`})]}):null,(0,z.jsx)(L,{testId:`${t}-api-key`,name:`${t}-api-key`,type:`password`,label:u(d.BACKEND$KEY_LABEL),value:g,onChange:e=>{_(e),y(null)},placeholder:`sk-••••••••••`,className:`w-full`}),v?(0,z.jsx)(`div`,{role:`alert`,"data-testid":`${t}-error`,className:`rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm text-red-300 whitespace-pre-wrap break-words`,children:v}):null,(0,z.jsx)(F,{type:`submit`,variant:`secondary`,isDisabled:!w||x,testId:s??`${t}-submit`,className:`w-full text-center`,children:x?o:a})]})}function $({onConnected:e,testIdRoot:t,lockedHost:n,analyticsSource:r,showBranding:a=!0}){let{t:o}=i(`openhands`),[s,c]=R.useState(!1),[l,u]=R.useState(``),p=`${t}-advanced-panel`,m=n??(l.trim()||X);return(0,z.jsxs)(`div`,{className:`flex w-full min-w-0 flex-col items-center gap-3`,children:[a?(0,z.jsxs)(`div`,{className:`flex flex-col items-center gap-1`,children:[(0,z.jsx)(B,{width:56,height:56,"aria-hidden":!0}),(0,z.jsx)(`h4`,{className:ae,"data-testid":`${t}-cloud-title`,children:o(d.BACKEND$CLOUD_TITLE)})]}):null,(0,z.jsx)(q,{host:m,onSuccess:t=>{e({name:`OpenHands Cloud`,host:J(m),apiKey:t,kind:`cloud`},`cloud_login`)},testIdRoot:t,analyticsSource:r,className:`w-full items-center`,idleDescription:(0,z.jsx)(`p`,{className:`text-center text-sm leading-relaxed text-[var(--oh-muted)]`,"data-testid":`${t}-cloud-description`,children:o(d.BACKEND$CLOUD_DESCRIPTION)}),idleFooter:n?null:(0,z.jsxs)(`div`,{className:`mx-auto w-full max-w-md`,children:[(0,z.jsxs)(`button`,{type:`button`,onClick:()=>c(e=>!e),"aria-expanded":s,"aria-controls":p,"data-testid":`${t}-advanced-toggle`,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,z.jsx)(`span`,{children:o(d.BACKEND$ADVANCED)}),(0,z.jsx)(V,{className:f(`h-4 w-4 shrink-0 text-muted transition-transform duration-200 ease-out`,s&&`rotate-180`),"aria-hidden":!0})]}),(0,z.jsx)(`div`,{className:f(`grid transition-[grid-template-rows] duration-200 ease-out motion-reduce:transition-none`,s?`grid-rows-[1fr]`:`grid-rows-[0fr]`),children:(0,z.jsx)(`div`,{className:`overflow-hidden`,children:(0,z.jsxs)(`div`,{id:p,"data-testid":`${t}-advanced-panel`,"aria-hidden":!s,inert:s?void 0:!0,className:f(`pt-3 transition-opacity duration-200 ease-out motion-reduce:transition-none`,s?`opacity-100`:`opacity-0`),children:[(0,z.jsx)(L,{testId:`${t}-cloud-host`,name:`${t}-cloud-host`,type:`text`,label:o(d.BACKEND$HOST_LABEL),value:l,onChange:u,placeholder:X,className:`w-full`}),(0,z.jsx)(`p`,{className:`mt-1 text-xs text-[var(--oh-muted)]`,children:o(d.BACKEND$LOGIN_CLOUD_HINT)})]})})})]})})]})}function ke({value:e,selectedValue:t,title:n,description:r,icon:i,onSelect:a,panelId:o,testId:s}){let c=e===t;return(0,z.jsxs)(`button`,{id:`${s}-tab`,type:`button`,role:`tab`,"aria-selected":c,"aria-controls":o,"data-testid":s,onClick:()=>a(e),className:f(`relative flex min-h-16 w-full cursor-pointer items-center gap-3 px-3 py-3 text-left transition-colors`,`first:border-r first:border-r-[var(--oh-border)]`,`focus-visible:z-10 focus-visible:outline-2 focus-visible:-outline-offset-2 focus-visible:outline-blue-300`,c?`bg-[var(--oh-surface-raised)] text-white after:absolute after:inset-x-0 after:bottom-0 after:h-0.5 after:bg-primary`:`text-[var(--oh-muted)] hover:bg-[var(--oh-surface-raised)] hover:text-white`),children:[(0,z.jsx)(`span`,{className:`flex size-8 shrink-0 items-center justify-center`,"aria-hidden":!0,children:i}),(0,z.jsxs)(`span`,{className:`min-w-0 flex-1`,children:[(0,z.jsx)(`span`,{className:`block truncate text-sm font-medium`,children:n}),(0,z.jsx)(`span`,{className:`mt-0.5 block text-xs leading-tight text-[var(--oh-muted)]`,children:r})]})]})}function Ae({children:e}){let t=R.useRef(null),[n,r]=R.useState();return R.useLayoutEffect(()=>{let e=t.current;if(!e)return;let n=()=>{let t=e.getBoundingClientRect().height;r(t>0?t:void 0)};if(n(),typeof ResizeObserver>`u`)return;let i=new ResizeObserver(n);return i.observe(e),()=>i.disconnect()},[]),(0,z.jsx)(`div`,{"data-testid":`add-backend-panel-height`,style:n===void 0?void 0:{height:n},className:`overflow-hidden transition-[height] duration-300 ease-in-out motion-reduce:transition-none`,children:(0,z.jsx)(`div`,{ref:t,children:e})})}function je({location:e}){let{t}=i(`openhands`),[n,r]=R.useState(!1),a=e===`remote`,o=t(a?d.BACKEND$REMOTE_SETUP_TITLE:d.BACKEND$BEFORE_CONNECT_TITLE),s=t(a?d.BACKEND$REMOTE_SETUP_DESCRIPTION:d.BACKEND$LOCAL_SETUP_DESCRIPTION),c=a?ye:ve,l=t(a?d.BACKEND$REMOTE_SETUP_DOCS:d.BACKEND$LOCAL_SETUP_DOCS),u=a?`add-backend-remote`:`add-backend-local`,p=`${u}-guidance-toggle`,m=`${u}-guidance-body`;return(0,z.jsxs)(`aside`,{"data-testid":`${u}-guidance`,className:`rounded-lg bg-[var(--oh-surface-raised)] text-sm text-[var(--oh-muted)]`,children:[(0,z.jsx)(`h4`,{className:`text-white`,children:(0,z.jsxs)(`button`,{id:p,type:`button`,onClick:()=>r(e=>!e),"aria-expanded":n,"aria-controls":m,"data-testid":p,className:f(`flex w-full cursor-pointer items-center justify-between gap-2 rounded-lg px-3 py-2 text-left font-medium`,`transition-colors hover:bg-[var(--oh-interactive-hover)]`,`focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-blue-300`),children:[(0,z.jsxs)(`span`,{className:`flex min-w-0 items-center gap-2`,children:[(0,z.jsx)(C,{className:`size-4 shrink-0 text-[var(--oh-muted)]`,"aria-hidden":!0}),(0,z.jsx)(`span`,{className:`truncate`,children:o})]}),(0,z.jsx)(v,{className:f(`size-5 shrink-0 text-[var(--oh-muted)] transition-transform duration-200 ease-out`,n&&`rotate-180`),"aria-hidden":!0})]})}),(0,z.jsx)(`div`,{className:f(`grid transition-[grid-template-rows] duration-200 ease-out motion-reduce:transition-none`,n?`grid-rows-[1fr]`:`grid-rows-[0fr]`),children:(0,z.jsx)(`div`,{className:`overflow-hidden`,children:(0,z.jsxs)(`div`,{id:m,"data-testid":m,role:`region`,"aria-labelledby":p,"aria-hidden":!n,inert:n?void 0:!0,className:f(`flex flex-col gap-2 px-3 pb-3 transition-opacity duration-200 ease-out motion-reduce:transition-none`,n?`opacity-100`:`opacity-0`),children:[(0,z.jsx)(`p`,{className:`leading-5`,children:s}),a?(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h5`,{className:`font-medium text-white`,children:t(d.BACKEND$REMOTE_CONNECTION_TITLE)}),(0,z.jsx)(`p`,{className:`mt-1 leading-5`,children:t(d.BACKEND$REMOTE_CONNECTION_DESCRIPTION)})]}):(0,z.jsx)(`code`,{className:`block break-words font-mono text-xs text-white`,children:_e}),(0,z.jsxs)(`a`,{href:c,target:`_blank`,rel:`noopener noreferrer`,"data-testid":`${u}-docs-link`,tabIndex:n?void 0:-1,className:`inline-flex w-fit items-center gap-1.5 text-primary hover:underline`,children:[(0,z.jsx)(`span`,{children:l}),(0,z.jsx)(H,{className:`size-4 shrink-0`,"aria-hidden":!0})]})]})})})]})}function Me({onConnected:e,source:t}){let{t:n}=i(`openhands`),[r,a]=R.useState(`cloud`),[o,s]=R.useState(`local`),c=`add-backend-selected-panel`,l=`add-backend-option-${r}-tab`,u=r===`cloud`;return(0,z.jsxs)(`div`,{"data-testid":`add-backend-chooser`,className:`flex flex-col`,children:[(0,z.jsxs)(`div`,{role:`tablist`,"aria-label":n(d.BACKEND$CHOOSER_TITLE),className:`grid grid-cols-2 overflow-hidden rounded-lg border border-[var(--oh-border)]`,children:[(0,z.jsx)(ke,{value:`cloud`,selectedValue:r,title:n(d.BACKEND$CLOUD_TITLE),description:n(d.BACKEND$CLOUD_OPTION_DESCRIPTION),icon:(0,z.jsx)(B,{width:32,height:32,"data-testid":`add-backend-option-cloud-logo`}),onSelect:a,panelId:c,testId:`add-backend-option-cloud`}),(0,z.jsx)(ke,{value:`agent-server`,selectedValue:r,title:n(d.BACKEND$AGENT_SERVER_TITLE),description:n(d.BACKEND$AGENT_SERVER_OPTION_DESCRIPTION),icon:(0,z.jsx)(ue,{className:`size-6`}),onSelect:a,panelId:c,testId:`add-backend-option-agent-server`})]}),(0,z.jsx)(`div`,{className:`mt-6`,children:(0,z.jsx)(Ae,{children:(0,z.jsx)(`section`,{id:c,role:`tabpanel`,"aria-labelledby":l,className:`min-w-0`,children:u?(0,z.jsx)(`div`,{"data-testid":`add-backend-cloud-panel`,className:f(`relative isolate flex min-h-[13.5rem] w-full items-center justify-center rounded-xl border border-[var(--oh-border)] px-5 py-6`,`before:pointer-events-none before:absolute before:inset-0 before:-z-10 before:rounded-xl`,`before:bg-[radial-gradient(75%_75%_at_50%_50%,rgba(255,255,255,0.1)_0%,rgba(255,255,255,0)_70%)]`),children:(0,z.jsx)($,{onConnected:e,testIdRoot:`add-backend`,analyticsSource:t,showBranding:!1})}):(0,z.jsxs)(`div`,{"data-testid":`add-backend-agent-server-panel`,className:`mx-auto w-full max-w-xl`,children:[(0,z.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,z.jsx)(`span`,{className:`h-px flex-1 bg-[var(--oh-border)]`,"aria-hidden":!0}),(0,z.jsx)(b,{value:o,options:[{value:`local`,label:n(d.BACKEND$KIND_LOCAL),icon:(0,z.jsx)(se,{"aria-hidden":!0})},{value:`remote`,label:n(d.BACKEND$KIND_REMOTE),icon:(0,z.jsx)(y,{"aria-hidden":!0})}],onChange:s,ariaLabel:n(d.BACKEND$AGENT_SERVER_LOCATION),testId:`add-backend-location`}),(0,z.jsx)(`span`,{className:`h-px flex-1 bg-[var(--oh-border)]`,"aria-hidden":!0})]}),(0,z.jsxs)(`div`,{className:`mt-4 flex flex-col gap-4`,children:[(0,z.jsx)(je,{location:o},o),(0,z.jsx)(Oe,{onConnected:e,testIdRoot:`add-backend`,requireApiKey:o===`remote`,submitLabel:n(d.BACKEND$CONNECT),submittingLabel:n(d.ONBOARDING$BACKEND_STATUS_CHECKING),fixedKind:`local`,showKindSelector:!1})]})]})})})})]})}function Ne({onClose:e,source:t}){let{addBackend:n}=c(),r=Ee(),{trackBackendAdded:i}=N(),a=h(),o=R.useCallback((a,o,s)=>{n(a),i({backendKind:a.kind,connectionMethod:o,hasApiKey:!!a.apiKey,source:t,agentServerVersion:s?.agentServerVersion}),r(),e()},[n,r,e,i,t]);return a?(0,z.jsx)($,{onConnected:o,testIdRoot:`add-backend`,lockedHost:a,analyticsSource:t}):(0,z.jsx)(Me,{onConnected:o,source:t})}function Pe({mode:e,backend:t,onClose:n,source:r=`add_backend_modal`,hideCloseButton:a=!1}){let{t:o}=i(`openhands`);if(e===`add`)return(0,z.jsx)(P,{onClose:a?void 0:n,closeOnEscape:!1,closeOnBackdropClick:!a,"aria-label":o(d.BACKEND$ADD_TITLE),children:(0,z.jsxs)(`div`,{"data-testid":a?`onboarding-modal`:`add-backend-modal`,className:f(`relative max-h-[92vh] w-[720px] overflow-y-auto rounded-xl border border-[var(--oh-border)] bg-base-secondary p-6`,re),children:[a?null:(0,z.jsx)(I,{onClose:n,testId:`add-backend-close`}),a?null:(0,z.jsxs)(`div`,{className:`pr-8`,children:[(0,z.jsx)(`h2`,{className:ie,children:o(d.BACKEND$CHOOSER_TITLE)}),(0,z.jsxs)(`p`,{className:`mt-2 text-sm leading-6 text-[var(--oh-muted)]`,"data-testid":`add-backend-description`,children:[o(d.BACKEND$CHOOSER_DESCRIPTION),` `,(0,z.jsxs)(`a`,{href:be,target:`_blank`,rel:`noopener noreferrer`,"aria-label":o(d.BACKEND$DEPLOYMENT_OPTIONS),"data-testid":`add-backend-deployment-options-link`,className:`text-primary hover:underline`,children:[o(d.CTA$LEARN_MORE),(0,z.jsx)(H,{className:`ml-1 inline size-3.5 align-[-0.125em]`,"aria-hidden":!0})]})]})]}),(0,z.jsx)(`div`,{className:a?void 0:`mt-5`,children:(0,z.jsx)(Ne,{onClose:n,source:r})})]})});let s=`edit-backend`;return(0,z.jsx)(P,{onClose:n,closeOnEscape:!1,"aria-label":o(d.BACKEND$EDIT_TITLE),children:(0,z.jsxs)(`div`,{"data-testid":`${s}-modal`,className:f(`relative bg-base-secondary p-6 rounded-xl flex flex-col gap-4 border border-[var(--oh-border)]`,ne(`md`)),children:[(0,z.jsx)(I,{onClose:n,testId:`${s}-close`}),(0,z.jsx)(`h2`,{className:f(`pr-6`,ie),children:o(d.BACKEND$EDIT_TITLE)}),(0,z.jsx)(Q,{mode:`edit`,backend:t,onSubmitted:n,testIdRoot:s})]})})}export{q as a,V as c,me as i,Q as n,W as o,Pe as r,U as s,De as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{yt as e}from"./vendor-styling-Ck5D_A2Q.js";import{t}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~
|
|
1
|
+
import{yt as e}from"./vendor-styling-Ck5D_A2Q.js";import{t}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{n}from"./active-backend-context-rZiLJRUc.js";import{K as r}from"./utils-BOco8mxR.js";import{n as i,t as a}from"./use-cloud-current-user-id-Dk0rjr63.js";import{r as o}from"./typography-HLLg_FAn.js";var s=e();function c(){let{t:e}=t(),o=n(),s=i(),c=a();if(o.backend.kind!==`cloud`||!o.orgId)return o.backend.name;let l=s[o.backend.id]?.orgs.find(e=>e.id===o.orgId);if(!l)return o.backend.name;let u=c[o.backend.id]?.userId??null,d=u&&l.id===u?e(r.BACKEND$PERSONAL_WORKSPACE):l.name;return`${o.backend.name} – ${d}`}function l(){let{t:e}=t(),i=n(),a=c();return(0,s.jsx)(`div`,{"data-testid":`backend-synced-settings-badge`,className:`flex items-center`,children:(0,s.jsx)(o.Text,{className:`text-[11px] font-medium text-[var(--oh-text-dim)] leading-5`,children:e(r.SETTINGS$BACKEND_SYNCED_BADGE,{name:a,host:i.backend.host,interpolation:{escapeValue:!1}})})})}export{l as t};
|
|
@@ -1 +1 @@
|
|
|
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~
|
|
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-CV850oio.js";import{K as i,t as a}from"./utils-BOco8mxR.js";import{t as o}from"./modal-backdrop-BSzNhM4r.js";import{r as s,t as c}from"./modal-body-DJw4xBki.js";import{r as l}from"./base-modal-DTULovNc.js";import{t as u}from"./settings-input-C0dd8Utu.js";import{a as d}from"./use-can-manage-org-profiles-BbN6KfDr.js";var f=e(t(),1),p=/^[A-Za-z0-9][A-Za-z0-9._-]{0,63}$/;function m(e,{isRequired:t=!1}={}){return e===``?!t:p.test(e)}function h(e){let t=e.split(`/`),n=(t[t.length-1]||e).replace(/[^A-Za-z0-9._-]/g,`-`).replace(/-+/g,`-`).replace(/^-+|-+$/g,``);return n&&!/^[A-Za-z0-9]/.test(n)&&(n=`profile-${n}`),n.length>64&&(n=n.substring(0,64).replace(/-+$/,``)),n||`default-profile`}var g=n(),_=(0,f.forwardRef)(function({testId:e,ruleTestId:t,value:n,onChange:o,onKeyDown:s,placeholder:c,isDisabled:l,isOptional:d,isRequired:p=!1},h){let{t:_}=r(`openhands`),v=m(n,{isRequired:p}),y=d?`${_(i.SETTINGS$PROFILE_NAME_LABEL)} (${_(i.COMMON$OPTIONAL)})`:_(i.SETTINGS$PROFILE_NAME_LABEL),b=f.useId(),x=t??`${b}-rule`;return(0,g.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,g.jsx)(u,{ref:h,testId:e,label:y,type:`text`,className:`w-full`,value:n,placeholder:c??_(i.SETTINGS$PROFILE_NAME_PLACEHOLDER),onChange:o,onKeyDown:s,isDisabled:l,ariaDescribedBy:x,ariaInvalid:!v}),(0,g.jsx)(`p`,{id:x,"data-testid":t,className:a(`text-xs`,v?`text-[var(--oh-muted)]`:`text-red-400`),children:_(i.SETTINGS$PROFILE_NAME_RULE)})]})});function v({isOpen:e,title:t,width:n=`md`,children:r,footer:i,onClose:u,initialFocusRef:d}){let p=(0,f.useRef)(null);return(0,f.useEffect)(()=>{if(!e)return;let t=d?.current??p.current;if(t){let e=setTimeout(()=>{t.focus()},0);return()=>clearTimeout(e)}},[e,d]),(0,f.useEffect)(()=>{if(!e||!p.current)return;let t=p.current,n=e=>{if(e.key!==`Tab`)return;let n=t.querySelectorAll(`button:not([disabled]), [href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])`),r=n[0],i=n[n.length-1];e.shiftKey&&document.activeElement===r?(e.preventDefault(),i?.focus()):!e.shiftKey&&document.activeElement===i&&(e.preventDefault(),r?.focus())};return document.addEventListener(`keydown`,n),()=>document.removeEventListener(`keydown`,n)},[e]),e?(0,g.jsx)(o,{onClose:u,children:(0,g.jsxs)(`div`,{ref:p,tabIndex:-1,role:`dialog`,"aria-modal":`true`,"aria-labelledby":`modal-title`,className:a(`bg-base-secondary p-6 rounded-xl flex flex-col gap-4 border border-[var(--oh-border)]`,s(n),c),children:[(0,g.jsx)(l,{id:`modal-title`,title:t}),r,(0,g.jsx)(`div`,{className:`w-full flex justify-end gap-2 mt-2`,children:i})]})}):null}function y({index:e,icon:t,label:n,onClick:r,onKeyDown:i,menuItemsRef:o,disabled:s,testId:c}){return(0,g.jsx)(`button`,{ref:t=>{o.current[e]=t},type:`button`,onClick:r,onKeyDown:t=>i(t,e),disabled:s,className:a(`group w-full cursor-pointer rounded px-2 py-2 text-start text-nowrap text-sm font-normal`,`text-[var(--oh-foreground)] hover:bg-[var(--oh-interactive-hover)]`,`disabled:cursor-not-allowed disabled:opacity-50 disabled:hover:bg-transparent`),role:`menuitem`,"data-testid":c,children:(0,g.jsx)(d,{icon:t,text:n})})}function b({children:e,className:t,...n}){return(0,g.jsx)(`span`,{className:a(`text-sm leading-4 text-black font-semibold tracking-tighter bg-primary p-1 rounded-full`,t),...n,children:e})}export{h as a,_ as i,y as n,m as o,v as r,b as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-Cyuzqnbw.js";import{St as e,vt as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{t as r}from"./utils-
|
|
1
|
+
import"./rolldown-runtime-Cyuzqnbw.js";import{St as e,vt as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{t as r}from"./utils-BOco8mxR.js";import{n as i}from"./modal-body-DJw4xBki.js";import{t as a}from"./modal-classes-Dg0ngBPO.js";e();var o=n();function s({testId:e,variant:n=`default`,onClick:r,text:i,className:a,icon:s,type:c=`button`,disabled:l,intent:u}){return(0,o.jsxs)(`button`,{"data-testid":e,type:c===`submit`?`submit`:`button`,disabled:l,onClick:r,className:t(n==="default"&&`text-sm font-normal py-[10px] rounded-sm`,n===`text-like`&&`text-xs leading-4 font-normal`,s&&`flex items-center justify-center gap-2`,l&&`opacity-50 cursor-not-allowed`,a),name:u&&`intent`,value:u,children:[s,i]})}function c({title:e,id:t,className:n}){return(0,o.jsx)(`span`,{id:t,className:r(a,n),children:e})}function l({description:e,children:t}){return(0,o.jsx)(`span`,{className:`text-sm text-modal-muted`,children:t||e})}function u({testId:e,title:t,description:n,buttons:r}){return(0,o.jsxs)(i,{testID:e,children:[(0,o.jsxs)(`div`,{className:`flex flex-col gap-2 self-start`,children:[(0,o.jsx)(c,{title:t}),(0,o.jsx)(l,{description:n})]}),(0,o.jsx)(`div`,{className:`flex flex-col gap-2 w-full`,children:r.map((e,t)=>(0,o.jsx)(s,{onClick:e.onClick,text:e.text,className:e.className},t))})]})}export{s as i,l as n,c as r,u as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~czjee3a3-BfkNGovw.js";var t=e(`bot`,[[`path`,{d:`M12 8V4H8`,key:`hb8ula`}],[`rect`,{width:`16`,height:`12`,x:`4`,y:`8`,rx:`2`,key:`enze0r`}],[`path`,{d:`M2 14h2`,key:`vft8re`}],[`path`,{d:`M20 14h2`,key:`4cs60a`}],[`path`,{d:`M15 13v2`,key:`1xurst`}],[`path`,{d:`M9 13v2`,key:`rq6x2g`}]]);export{t};
|
|
@@ -1 +1 @@
|
|
|
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"./utils-
|
|
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"./utils-BOco8mxR.js";import{a as i}from"./form-control-classes-B-z85REi.js";var a=e(t(),1),o=n(),s=(0,a.forwardRef)(function({testId:e,name:t,children:n,variant:a,type:s,isDisabled:c,className:l,onClick:u,startContent:d,ariaLabel:f,"aria-busy":p,"aria-haspopup":m,"aria-expanded":h},g){return(0,o.jsxs)(`button`,{ref:g,name:t,"data-testid":e,disabled:c,type:s,onClick:u,"aria-label":f,"aria-busy":p,"aria-haspopup":m,"aria-expanded":h,className:r(i,a===`primary`&&`bg-primary text-[var(--oh-color-base)] hover:opacity-80 disabled:bg-[var(--oh-interactive-hover)] disabled:text-[var(--oh-muted)] disabled:opacity-100`,a===`secondary`&&`border border-[var(--oh-border)] bg-base-secondary text-white hover:bg-surface-raised`,a===`tertiary`&&`bg-[var(--oh-interactive-hover)] text-white hover:opacity-80`,a===`danger`&&`bg-red-600 text-white hover:bg-red-700`,a===`ghost-danger`&&`h-auto min-h-0 bg-transparent px-0 text-red-600 underline hover:text-red-700 hover:no-underline font-normal`,d&&`flex items-center justify-center gap-2`,l),children:[d,n]})});export{s as t};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import{D as e,O as t}from"./utils-BOco8mxR.js";import{t as n}from"./settings-CKqk8ZnH.js";import{c as r,d as i,l as a,o,s,u as c}from"./llm-subscription-DTqtBCWz.js";import{t as l}from"./automation-C_eCrGyP.js";import{a as ee,i as u,n as d,o as f,r as p,t as te}from"./vendor~browser-hbU4u2Ag.js";var m=[`file1.txt`,`file2.txt`,`file3.txt`],h=[`reboot_skynet.exe`,`target_list.txt`,`terminator_blueprint.txt`],ne={home:`/home/openhands`,favorites:[{label:`Downloads`,path:`/home/openhands/Downloads`}],locations:[]},re={"/projects":[{name:`demo-app`,path:`/projects/demo-app`},{name:`sample-tools`,path:`/projects/sample-tools`},{name:`notes-service`,path:`/projects/notes-service`}],"/projects/demo-app":[{name:`web-client`,path:`/projects/demo-app/web-client`},{name:`api-service`,path:`/projects/demo-app/api-service`}],"/projects/demo-app/web-client":[]},ie=[u.all(`*/api/bash/execute_bash_command`,async()=>f.json({command:``,exit_code:0,output:``})),u.get(`*/api/file/home`,async()=>f.json(ne)),u.get(`*/api/file/search_subdirs`,async({request:e})=>{let t=new URL(e.url).searchParams.get(`path`)??``,n=re[t]??[];return f.json({path:t,items:n,subdirs:n,next_page_id:null})}),u.get(`*/api/file/:path`,async({params:e})=>f.json({path:`/${e.path?.toString()??`home`}`,subdirs:[]})),u.get(`/api/conversations/:conversationId/list-files`,async({params:e})=>{await p();let t=e.conversationId?.toString();return t?t===`test-conversation-id-2`?f.json(h):f.json(m):f.json(null,{status:400})}),u.get(`/api/conversations/:conversationId/select-file`,async({request:e})=>{await p();let t=new URL(e.url).searchParams.get(`file`)?.toString();return t?f.json({code:`Content of ${t}`}):f.json(null,{status:404})})],g=new Map([[`OpenAI_API_Key`,{value:`test-123`,description:`OpenAI API Key`}],[`Google_Maps_API_Key`,{value:`test-123`,description:`Google Maps API Key`}]]),ae=[u.get(`*/api/settings/secrets`,async({request:e})=>{if(new URL(e.url).pathname.split(`/`).filter(Boolean).length>3)return;let t=Array.from(g.entries()).map(([e,{description:t}])=>({name:e,description:t}));return f.json({secrets:t})}),u.get(`*/api/settings/secrets/:name`,async({params:e})=>{let{name:t}=e;if(typeof t!=`string`)return f.json({detail:`Invalid name`},{status:400});let n=g.get(t);return n?new f(n.value,{headers:{"Content-Type":`text/plain`}}):f.json({detail:`Secret not found`},{status:404})}),u.put(`*/api/settings/secrets`,async({request:e})=>{let t=await e.json();return!t?.name||!t?.value?f.json({detail:`name and value are required`},{status:400}):(g.set(t.name,{value:t.value,description:t.description}),f.json({name:t.name,description:t.description}))}),u.delete(`*/api/settings/secrets/:name`,async({params:e})=>{let{name:t}=e;return typeof t==`string`?g.delete(t)?f.json({deleted:!0}):f.json({detail:`Secret not found`},{status:404}):f.json({detail:`Invalid name`},{status:400})})],_=new Map,v=null,oe={critic_enabled:!1,critic_mode:`off`,enable_iterative_refinement:!1,critic_threshold:.5,max_refinement_iterations:3,critic_server_url:null,critic_model_name:null};function se(e){return{schema_version:1,revision:1,mcp_server_refs:null,agent_kind:`openhands`,llm_profile_ref:`default`,agent:`CodeActAgent`,skills:[],system_message_suffix:null,condenser:null,verification:oe,enable_sub_agents:!1,tool_concurrency_limit:1,...e}}var ce=`3f1c1b7e-0000-4000-8000-000000000001`,y=[se({id:ce,name:`default`}),se({id:`3f1c1b7e-0000-4000-8000-000000000002`,name:`research`,enable_sub_agents:!0,tool_concurrency_limit:4})],b=y.length+1;function le(){let e=String(b).padStart(12,`0`);return b+=1,`3f1c1b7e-0000-4000-8000-${e}`}function ue(){_.clear(),v=null,b=y.length+1}function de(){ue();for(let e of y)_.set(e.name,{...e});v=ce}de();function fe(e,t){return{id:t.id,name:e,agent_kind:t.agent_kind,revision:t.revision,llm_profile_ref:t.agent_kind===`openhands`?t.llm_profile_ref:null,mcp_server_refs:t.mcp_server_refs}}function pe(e){return f.json({detail:`Agent profile '${e}' not found`},{status:404})}var me=[u.get(`*/api/agent-profiles`,async()=>{let e=Array.from(_.entries()).map(([e,t])=>fe(e,t));return f.json({profiles:e,active_agent_profile_id:v})}),u.get(`*/api/agent-profiles/:name`,async({params:e})=>{let{name:t}=e;if(typeof t!=`string`)return f.json({detail:`Invalid name`},{status:400});let n=_.get(t);return n?f.json({name:t,profile:n}):pe(t)}),u.post(`*/api/agent-profiles/:name/rename`,async({params:e,request:t})=>{let{name:n}=e;if(typeof n!=`string`)return f.json({detail:`Invalid name`},{status:400});let r=(await t.json())?.new_name;if(!r)return f.json({detail:`new_name is required`},{status:422});let i=_.get(n);return i?r!==n&&_.has(r)?f.json({detail:`Agent profile '${r}' already exists`},{status:409}):(_.delete(n),_.set(r,{...i,name:r}),f.json({name:r,message:`Agent profile renamed.`})):pe(n)}),u.post(`*/api/agent-profiles/:id/activate`,async({params:e})=>{let{id:t}=e;return typeof t==`string`?Array.from(_.values()).find(e=>e.id===t)?(v=t,f.json({id:t,message:`Agent profile activated.`,agent_settings_applied:!1})):pe(t):f.json({detail:`Invalid id`},{status:400})}),u.post(`*/api/agent-profiles/:name`,async({params:e,request:t})=>{let{name:n}=e;if(typeof n!=`string`)return f.json({detail:`Invalid name`},{status:400});let r=await t.json(),i=_.get(n);return _.set(n,{...r,name:n,id:i?.id??r.id??le(),revision:(i?.revision??0)+1}),f.json({name:n,message:`Agent profile saved.`})}),u.delete(`*/api/agent-profiles/:name`,async({params:e})=>{let{name:t}=e;return typeof t==`string`?(v===_.get(t)?.id&&(v=null),_.delete(t),f.json({name:t,message:`Agent profile deleted.`})):f.json({detail:`Invalid name`},{status:400})})],x=(e,t)=>Array.from({length:e},(e,n)=>({id:`${n+1}`,full_name:`user/repo-${n+1}`,git_provider:t,is_public:Math.random()>.3,stargazers_count:Math.floor(Math.random()*1e3),pushed_at:new Date(Date.now()-Math.random()*90*24*60*60*1e3).toISOString()})),he=e=>Array.from({length:e},(e,t)=>({name:t===0?`main`:t===1?`develop`:`feature/branch-${t}`,commit_sha:`abc123${t.toString().padStart(3,`0`)}`,protected:t===0,last_push_date:new Date(Date.now()-Math.random()*7*24*60*60*1e3).toISOString()})),ge={github:x(120,`github`),gitlab:x(120,`gitlab`),bitbucket:x(120,`bitbucket`)},S=he(25),_e=[{path:`src/components/hello.tsx`,status:`UPDATED`},{path:`src/utils/new-helper.ts`,status:`ADDED`},{path:`src/old-module.py`,status:`DELETED`}],ve=[u.get(`*/api/user/repositories`,async({request:e})=>{await p(500);let t=new URL(e.url),n=t.searchParams.get(`selected_provider`),r=parseInt(t.searchParams.get(`page`)||`1`,10),i=parseInt(t.searchParams.get(`per_page`)||`30`,10),a=t.searchParams.get(`sort`)||`pushed`,o=t.searchParams.get(`installation_id`);if(!n)return f.json(`Git provider token required. (such as GitHub).`,{status:401});let s=[...ge[n]||[]];if(a===`pushed`?s.sort((e,t)=>new Date(t.pushed_at).getTime()-new Date(e.pushed_at).getTime()):a===`stars`&&s.sort((e,t)=>(t.stargazers_count||0)-(e.stargazers_count||0)),o&&n===`github`){let e=(parseInt(o,10)||0)*20;s=s.slice(e,e+20)}let c=(r-1)*i,l=c+i,ee=s.slice(c,l),u=l<s.length,d=r>1,te=Math.ceil(s.length/i),m=``;if(u||d){let e=[];d&&e.push(`</api/user/repositories?page=${r-1}&per_page=${i}>; rel="prev"`),u&&e.push(`</api/user/repositories?page=${r+1}&per_page=${i}>; rel="next"`),e.push(`</api/user/repositories?page=${te}&per_page=${i}>; rel="last"`),e.push(`</api/user/repositories?page=1&per_page=${i}>; rel="first"`),m=e.join(`, `)}let h=[...ee];return h.length>0&&m&&(h[0]={...h[0],link_header:m}),f.json(h)}),u.get(`*/api/user/search/repositories`,async({request:e})=>{await p(300);let t=new URL(e.url),n=t.searchParams.get(`query`)||``,r=t.searchParams.get(`selected_provider`),i=parseInt(t.searchParams.get(`per_page`)||`5`,10),a=t.searchParams.get(`sort`)||`stars`,o=t.searchParams.get(`order`)||`desc`;if(!r)return f.json(`Git provider token required.`,{status:401});let s=[...(ge[r]||[]).filter(e=>e.full_name.toLowerCase().includes(n.toLowerCase()))];a===`stars`&&s.sort((e,t)=>{let n=e.stargazers_count||0,r=t.stargazers_count||0;return o===`desc`?r-n:n-r});let c=s.slice(0,i);return f.json(c)}),u.get(`*/api/user/repository/branches`,async({request:e})=>{await p(300);let t=new URL(e.url),n=t.searchParams.get(`repository`),r=parseInt(t.searchParams.get(`page`)||`1`,10),i=parseInt(t.searchParams.get(`per_page`)||`30`,10);if(!n)return f.json(`Repository parameter is required`,{status:400});let a=(r-1)*i,o=a+i,s={branches:S.slice(a,o),has_next_page:o<S.length,current_page:r,per_page:i,total_count:S.length};return f.json(s)}),u.get(`*/api/user/search/branches`,async({request:e})=>{await p(200);let t=new URL(e.url),n=t.searchParams.get(`repository`),r=t.searchParams.get(`query`)||``,i=parseInt(t.searchParams.get(`per_page`)||`30`,10);if(!n)return f.json(`Repository parameter is required`,{status:400});let a=S.filter(e=>e.name.toLowerCase().includes(r.toLowerCase())).slice(0,i);return f.json(a)}),u.get(`*/api/git/changes`,async()=>f.json(_e)),u.get(`*/api/git/diff`,async()=>f.json({original:`def greet(name):
|
|
2
|
+
return f"Hello, {name}!"
|
|
3
|
+
`,modified:`def greet(name: str) -> str:
|
|
4
|
+
return f"Hello, {name}! Welcome."
|
|
5
|
+
`}))];function C(e,t){let n={...e};for(let[e,r]of Object.entries(t))typeof r==`object`&&r&&!Array.isArray(r)&&typeof n[e]==`object`&&n[e]!=null&&!Array.isArray(n[e])?n[e]=C(n[e],r):n[e]=r;return n}var ye=n.agent_settings??{},w=ye.llm,be=typeof w?.model==`string`?w.model:`openhands/claude-opus-4-5-20251101`,xe={model_name:`AgentSettings`,sections:[{key:`general`,label:`General`,fields:[{key:`enable_sub_agents`,label:`Enable sub-agents`,description:`Allow the agent to delegate work to specialized built-in sub-agents.`,section:`general`,section_label:`General`,value_type:`boolean`,default:!1,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!1},{key:`enable_switch_llm_tool`,label:`Enable LLM switching tool`,description:`Allow the agent to move the conversation to another saved LLM profile on its own.`,section:`general`,section_label:`General`,value_type:`boolean`,default:!0,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!1},{key:`tool_concurrency_limit`,label:`Parallel tool calls`,description:`Maximum number of tool calls to execute concurrently per agent step. 1 = sequential (default).`,section:`general`,section_label:`General`,value_type:`integer`,default:1,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!1}]},{key:`llm`,label:`LLM`,fields:[{key:`llm.model`,label:`Model`,description:`Select the model to use for this conversation.`,section:`llm`,section_label:`LLM`,value_type:`string`,default:be,choices:[],depends_on:[],prominence:`critical`,secret:!1,required:!0},{key:`llm.api_key`,label:`API Key`,description:`Provide the API key used to authenticate requests for the selected model.`,section:`llm`,section_label:`LLM`,value_type:`string`,default:null,choices:[],depends_on:[],prominence:`critical`,secret:!0,required:!1},{key:`llm.base_url`,description:`Override the model provider's default API base URL when needed.`,label:`Base URL`,section:`llm`,section_label:`LLM`,value_type:`string`,default:null,choices:[],depends_on:[],prominence:`critical`,secret:!1,required:!1},{key:`llm.temperature`,label:`Temperature`,description:`Adjust randomness for non-deterministic model outputs.`,section:`llm`,section_label:`LLM`,value_type:`number`,default:null,choices:[],depends_on:[],prominence:`minor`,secret:!1,required:!1}]},{key:`verification`,label:`Verification`,fields:[{key:`verification.critic_enabled`,label:`Enable Critic`,description:`Enable an additional critic pass to review the agent's work.`,section:`verification`,section_label:`Verification`,value_type:`boolean`,default:!1,choices:[],depends_on:[],prominence:`critical`,secret:!1,required:!1},{key:`verification.critic_mode`,label:`Critic Mode`,description:`Choose when the critic should review and intervene.`,section:`verification`,section_label:`Verification`,value_type:`string`,default:`finish_and_message`,choices:[{label:`finish_and_message`,value:`finish_and_message`},{label:`all_actions`,value:`all_actions`}],depends_on:[`verification.critic_enabled`],prominence:`major`,secret:!1,required:!1},{key:`verification.enable_iterative_refinement`,label:`Enable Iterative Refinement`,description:`Let the critic send the agent back to refine its work when issues are found.`,section:`verification`,section_label:`Verification`,value_type:`boolean`,default:!1,choices:[],depends_on:[`verification.critic_enabled`],prominence:`critical`,secret:!1,required:!1},{key:`verification.critic_api_key`,label:`Critic API Key`,description:`If OpenHands is selected as your active LLM provider, leave this empty; the critic reuses the OpenHands Provider LLM Key.`,section:`verification`,section_label:`Verification`,value_type:`string`,default:null,choices:[],depends_on:[`verification.critic_enabled`],prominence:`critical`,secret:!0,required:!1},{key:`verification.critic_threshold`,label:`Critic Threshold`,description:`Critic success threshold used for iterative refinement.`,section:`verification`,section_label:`Verification`,value_type:`number`,default:.6,choices:[],depends_on:[`verification.critic_enabled`,`verification.enable_iterative_refinement`],prominence:`minor`,secret:!1,required:!1},{key:`verification.max_refinement_iterations`,label:`Max Refinement Iterations`,description:`Maximum number of refinement attempts after critic feedback.`,section:`verification`,section_label:`Verification`,value_type:`integer`,default:3,choices:[],depends_on:[`verification.critic_enabled`,`verification.enable_iterative_refinement`],prominence:`minor`,secret:!1,required:!1},{key:`verification.critic_server_url`,label:`Critic Server URL`,description:`Override the critic service URL.`,section:`verification`,section_label:`Verification`,value_type:`string`,default:null,choices:[],depends_on:[`verification.critic_enabled`],prominence:`minor`,secret:!1,required:!1},{key:`verification.critic_model_name`,label:`Critic Model Name`,description:`Override the critic model name.`,section:`verification`,section_label:`Verification`,value_type:`string`,default:null,choices:[],depends_on:[`verification.critic_enabled`],prominence:`minor`,secret:!1,required:!1}]},{key:`condenser`,label:`Condenser`,fields:[{description:`Enable the default LLM-based condenser to summarize long conversation histories.`,key:`condenser.enable_default_condenser`,label:`Enable default condenser`,section:`condenser`,section_label:`Condenser`,value_type:`boolean`,default:!0,choices:[],depends_on:[],prominence:`critical`,secret:!1,required:!0},{description:`Maximum number of tokens the condenser keeps after summarization. Leave blank for unlimited.`,key:`condenser.condenser_max_size`,label:`Condenser max size`,section:`condenser`,section_label:`Condenser`,value_type:`integer`,default:null,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!1}]},{key:`agent_context`,label:`Memory`,fields:[{description:`The agent keeps notes under .openhands/memory/ and loads them at the start of each new conversation, learning your codebase and preferences over time.`,key:`agent_context.load_memory`,label:`Persistent memory`,section:`agent_context`,section_label:`Memory`,value_type:`boolean`,default:!1,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!1}]}]},T={model_name:`ConversationSettings`,sections:[{key:`general`,label:`General`,fields:[{key:`max_iterations`,label:`Max iterations`,section:`general`,description:`Maximum number of agent steps allowed before the conversation stops.`,section_label:`General`,value_type:`integer`,default:500,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!0}]},{key:`verification`,label:`Verification`,fields:[{key:`confirmation_mode`,label:`Confirmation mode`,description:`Pause for confirmation before the agent performs high-risk actions.`,section:`verification`,section_label:`Verification`,value_type:`boolean`,default:!1,choices:[],depends_on:[],prominence:`major`,secret:!1,required:!0},{key:`security_analyzer`,label:`Security analyzer`,description:`Choose how OpenHands should analyze actions before asking for confirmation.`,section:`verification`,section_label:`Verification`,value_type:`string`,default:`llm`,choices:[{label:`llm`,value:`llm`},{label:`none`,value:`none`}],depends_on:[`confirmation_mode`],prominence:`major`,secret:!1,required:!1}]}]},E={...n,provider_tokens_set:{},agent_settings_schema:xe,agent_settings:{...ye,verification:{critic_enabled:!1,enable_iterative_refinement:!1},llm:{...w??{},api_key:null,model:be},condenser:{enable_default_condenser:!0,condenser_max_size:null},enable_sub_agents:!1,tool_concurrency_limit:1},conversation_settings_schema:T,conversation_settings:{...n.conversation_settings??{}}},D={settings:structuredClone(E)},O={profiles:new Map,activeProfile:null},k=!1,A=e=>decodeURIComponent(String(Array.isArray(e)?e[0]??``:e??``)),Se=e=>({name:e.name,model:typeof e.config.model==`string`?e.config.model:null,base_url:typeof e.config.base_url==`string`?e.config.base_url:null,api_key_set:e.api_key_set}),j=e=>{let t=D.settings||structuredClone(E);D.settings={...t,agent_settings:{...t.agent_settings??{},llm:structuredClone(e.config)},llm_api_key_set:e.api_key_set}},Ce=(e,t)=>{let n=structuredClone(e.config);return e.api_key_set&&`api_key`in n&&(t===`encrypted`?n.api_key=`gAAAAA_mock_encrypted_${e.name}`:t===`plaintext`||(n.api_key=null)),{name:e.name,config:n,api_key_set:e.api_key_set}},we=(e,t)=>{let n=structuredClone(t.llm??{});if(typeof n.model!=`string`||n.model.trim().length===0)return null;let r={name:e,config:n,api_key_set:typeof n.api_key==`string`&&n.api_key.trim().length>0};return O.profiles.set(e,r),O.activeProfile===e&&j(r),r},M=[`anthropic/claude-3.5`,`anthropic/claude-sonnet-4-20250514`,`anthropic/claude-sonnet-4-5-20250929`,`anthropic/claude-haiku-4-5-20251001`,`anthropic/claude-opus-4-5-20251101`,`anthropic/claude-opus-4-8`,`openai/gpt-3.5-turbo`,`openai/gpt-5.5`,`openai/gpt-4o`,`openai/gpt-4o-mini`,`openhands/claude-sonnet-4-20250514`,`openhands/claude-sonnet-4-5-20250929`,`openhands/claude-haiku-4-5-20251001`,`openhands/claude-opus-4-5-20251101`,`openai/gpt-5.6-sol`,`openhands/deepseek-v4-flash`,`openhands/glm-5.2`,`sambanova/Meta-Llama-3.1-8B-Instruct`],Te=[`gpt-5.2`,`gpt-5.3-codex`],Ee=new Set([`anthropic/claude-opus-4-5-20251101`,`anthropic/claude-opus-4-8`,`anthropic/claude-sonnet-4-5-20250929`,`openai/gpt-5.5`,`openhands/claude-opus-4-5-20251101`,`openhands/claude-sonnet-4-5-20250929`,`openai/gpt-5.6-sol`,`openhands/deepseek-v4-flash`,`openhands/glm-5.2`]),De=[`openhands`,`anthropic`,`openai`,`mistral`,`gemini`,`deepseek`,`moonshot`,`minimax`],Oe=Array.from(new Set(M.map(e=>e.split(`/`)[0]).filter(e=>!!e))),ke=M.reduce((e,t)=>{if(!Ee.has(t))return e;let[n,...r]=t.split(`/`);return!n||r.length===0?e:(e[n]??=[],e[n].push(r.join(`/`)),e)},{}),Ae=`1.36.1`,je=[u.get(`*/server_info`,async()=>f.json({uptime:0,idle_time:0,version:Ae,usable_tools:[`terminal`,`file_editor`,`task_tracker`,`browser_tool_set`],agents:[`CodeActAgent`],default_agent:`CodeActAgent`,models:M,security_analyzers:[`llm`,`none`]})),u.get(`*/api/llm/models`,async()=>f.json({models:M})),u.get(`*/api/llm/models/verified`,async()=>f.json({models:ke})),u.get(`*/api/llm/providers`,async()=>f.json({providers:Oe})),u.get(`*${a}`,async()=>f.json({vendor:i,models:Te})),u.get(`*${c}`,async()=>f.json({connected:k,account_email:k?`mock-chatgpt@example.com`:null,expires_at:null})),u.post(`*${s}`,async()=>f.json({device_code:`mock-device-code`,user_code:`MOCK-CODE`,verification_uri:`https://auth.openai.com/activate`,verification_uri_complete:`https://auth.openai.com/activate?user_code=MOCK-CODE`,interval:1,expires_in:900})),u.post(`*${o}`,async()=>(k=!0,f.json({connected:!0,account_email:`mock-chatgpt@example.com`,expires_at:null}))),u.post(`*${r}`,async()=>(k=!1,f.json({connected:!1}))),u.get(`*/api/options/models`,async()=>f.json({models:M,verified_models:[`claude-opus-4-5-20251101`,`claude-sonnet-4-5-20250929`],verified_providers:De,default_model:`openai/gpt-5.6-sol`})),u.get(`*/api/v1/config/providers/search`,async({request:e})=>{let t=new URL(e.url),n=t.searchParams.get(`query`)?.toLowerCase(),r=t.searchParams.get(`verified__eq`),i=new Set,a=[];for(let e of M){let[t]=e.split(`/`);t&&!i.has(t)&&(i.add(t),a.push({name:t,verified:De.includes(t)}))}if(n&&(a=a.filter(e=>e.name.toLowerCase().includes(n))),r!=null){let e=r===`true`;a=a.filter(t=>t.verified===e)}return f.json({items:a,next_page_id:null})}),u.get(`*/api/v1/config/models/search`,async({request:e})=>{let t=new URL(e.url),n=t.searchParams.get(`query`)?.toLowerCase(),r=t.searchParams.get(`verified__eq`),i=t.searchParams.get(`provider__eq`),a=M.map(e=>{let[t,...n]=e.split(`/`),r=n.join(`/`);return{provider:t||null,name:r,verified:Ee.has(e)}});if(i&&(a=a.filter(e=>e.provider===i)),n&&(a=a.filter(e=>e.name.toLowerCase().includes(n))),r!=null){let e=r===`true`;a=a.filter(t=>t.verified===e)}return f.json({items:a,next_page_id:null})}),u.get(`*/api/options/security-analyzers`,async()=>f.json([`llm`,`none`])),u.get(`*/api/profiles`,async()=>f.json({profiles:Array.from(O.profiles.values()).map(Se),active_profile:O.activeProfile})),u.get(`*/api/profiles/:name`,async({params:e,request:t})=>{let n=A(e.name),r=O.profiles.get(n);return r?f.json(Ce(r,t.headers.get(`X-Expose-Secrets`))):f.json({detail:`Profile '${n}' not found`},{status:404})}),u.post(`*/api/profiles/:name`,async({params:e,request:t})=>{let n=A(e.name),r=await t.json();if(!r)return f.json({detail:`Empty body`},{status:400});let i=we(n,r);return i?f.json({name:i.name,message:`Profile '${i.name}' saved`},{status:201}):f.json({detail:`Profile requires llm.model`},{status:400})}),u.delete(`*/api/profiles/:name`,async({params:e})=>{let t=A(e.name);return O.profiles.delete(t),O.activeProfile===t&&(O.activeProfile=null),f.json({name:t,message:`Profile '${t}' deleted`})}),u.post(`*/api/profiles/:name/rename`,async({params:e,request:t})=>{let n=A(e.name),r=(await t.json())?.new_name?.trim()??``,i=O.profiles.get(n);if(!i)return f.json({detail:`Profile '${n}' not found`},{status:404});if(!r)return f.json({detail:`new_name is required`},{status:400});if(r!==n&&O.profiles.has(r))return f.json({detail:`Profile '${r}' already exists`},{status:409});O.profiles.delete(n);let a={...i,name:r};return O.profiles.set(r,a),O.activeProfile===n&&(O.activeProfile=r,j(a)),f.json({name:r,message:`Profile '${n}' renamed to '${r}'`})}),u.post(`*/api/profiles/:name/activate`,async({params:e})=>{let t=A(e.name),n=O.profiles.get(t);return n?(O.activeProfile=t,j(n),f.json({name:t,message:`Profile '${t}' activated and applied to current settings`,llm_applied:!0})):f.json({detail:`Profile '${t}' not found`},{status:404})}),u.get(`*/api/v1/web-client/config`,()=>{let e={feature_flags:{hide_llm_settings:!1,hide_users_page:!1},providers_configured:[],maintenance_start_time:null,recaptcha_site_key:null,faulty_models:[],error_message:null,updated_at:new Date().toISOString()};return f.json(e)}),u.get(`*/api/settings/conversation-schema`,async()=>(await p(),f.json(T))),u.get(`*/api/v1/settings/conversation-schema`,async()=>(await p(),f.json(T))),u.get(`*/api/v1/settings`,async()=>{await p();let{settings:e}=D;return e?f.json(e):f.json(null,{status:404})}),u.get(`*/api/settings`,async({request:e})=>{if(new URL(e.url).pathname.split(`/`).filter(Boolean).length>2)return;await p();let{settings:t}=D,n={language:null,user_consents_to_analytics:null,enable_sound_notifications:null,git_user_name:null,git_user_email:null,title_llm_profile:null,disabled_skills:[]};if(!t)return f.json({agent_settings:{},conversation_settings:{},llm_api_key_is_set:!1,misc_settings:{app_preferences:n}});let r=e.headers.get(`X-Expose-Secrets`),i=structuredClone(t.agent_settings??{}),a=i.llm;a?.api_key&&(r===`encrypted`?a.api_key=`gAAAAA_mock_encrypted_${String(a.api_key).slice(0,8)}`:r===`plaintext`||(a.api_key=`**********`));let o=!!t.llm_api_key_set||!!t.agent_settings?.llm&&!!t.agent_settings.llm?.api_key,s=t.misc_settings,c={...n,...s?.app_preferences??{}};return f.json({agent_settings:i,conversation_settings:t.conversation_settings??{},llm_api_key_is_set:o,misc_settings:{app_preferences:c}})}),u.patch(`*/api/settings`,async({request:e})=>{await p();let t=await e.json();if(!t)return f.json({error:`Empty body`},{status:400});if(!t.agent_settings_diff&&!t.conversation_settings_diff&&!t.misc_settings_diff)return f.json({error:`At least one of agent_settings_diff, conversation_settings_diff, or misc_settings_diff must be provided`},{status:400});let n=D.settings||structuredClone(E),r={...n};if(t.agent_settings_diff){let e=C(n.agent_settings??{},t.agent_settings_diff);r.agent_settings=e;let i=e.llm;i?.api_key&&typeof i.api_key==`string`&&i.api_key.trim().length>0&&(r.llm_api_key_set=!0)}if(t.conversation_settings_diff&&(r.conversation_settings={...n.conversation_settings??{},...t.conversation_settings_diff}),t.misc_settings_diff){let e=n.misc_settings,i={...e??{}};t.misc_settings_diff.app_preferences&&(i.app_preferences={...e?.app_preferences??{},...t.misc_settings_diff.app_preferences}),r.misc_settings=i}return D.settings=r,f.json({agent_settings:r.agent_settings??{},conversation_settings:r.conversation_settings??{},llm_api_key_is_set:r.llm_api_key_set??!1,misc_settings:r.misc_settings??{app_preferences:{}}})}),u.post(`*/api/mcp/test`,async()=>(await p(),f.json({ok:!0,tools:[`mock_tool`]}))),u.get(`*/api/settings/agent-schema`,async()=>(await p(),f.json(xe))),u.get(`*/api/v1/settings/agent-schema`,async()=>(await p(),f.json(xe))),u.post(`*/api/v1/settings`,async({request:e})=>{await p();let t=await e.json();if(t){let e=D.settings||structuredClone(E);if(`agent_settings`in t||`conversation_settings`in t)return f.json({error:`Use *_diff nested settings payloads`,keys:[`agent_settings`,`conversation_settings`].filter(e=>e in t)},{status:422});let n={...e},r=t.agent_settings_diff;r&&(n.agent_settings=C(e.agent_settings??{},r));let i=t.conversation_settings_diff;i&&(n.conversation_settings={...e.conversation_settings??{},...i});for(let[e,r]of Object.entries(t))e!==`agent_settings_diff`&&e!==`conversation_settings_diff`&&e!==`agent_settings_schema`&&e!==`conversation_settings_schema`&&(n[e]=r);return D.settings=n,f.json(null,{status:200})}return f.json(null,{status:400})}),u.post(`*/api/mcp/test`,async()=>(await p(),f.json({ok:!0,tools:[]})))],Me=`table-demo`,Ne=`Can you compare several coding agents in a wide table?`,Pe=[`Here is a wide comparison table. Scroll horizontally to read every column:`,``,`| Feature | OpenHands | Claude Code | Codex | Gemini CLI | Cursor | Windsurf | Cline | Aider | Devin | Continue |`,`| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |`,`| CLI | Yes | Yes | Yes | Yes | IDE | IDE | IDE | Terminal | Cloud | IDE |`,`| MCP support | Yes | Yes | Partial | Partial | Yes | Yes | Yes | No | Yes | Yes |`,`| Local models | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | Yes |`,`| Browser tools | Yes | Yes | Yes | Limited | Yes | Yes | Yes | No | Yes | Yes |`,`| Git integration | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |`,`| Best for | General coding | Anthropic stack | OpenAI stack | Google stack | IDE users | IDE users | VS Code | Terminal | Autonomous | IDE users |`].join(`
|
|
6
|
+
`),Fe=Date.UTC(2026,5,23,12,0,0);function Ie(e,t,n,r){return{id:e,timestamp:new Date(Fe+r*6e4).toISOString(),source:t===`user`?`user`:`agent`,llm_message:{role:t,content:[{type:`text`,text:n}]},activated_skills:[],extended_content:[]}}var Le=[Ie(`table-demo-user-1`,`user`,Ne,0),Ie(`table-demo-agent-1`,`assistant`,Pe,1)],Re=`canvas-demo`,N=`canvas.md`,P=[`# Agent Canvas Demo`,``,`This report was generated by the agent and opened from the file chip in chat.`,``,`## Release snapshot`,``,`| Area | Status | Next step |`,`| --- | --- | --- |`,`| Conversation UX | Ready | Validate the drawer flow |`,`| Markdown preview | Ready | Review rich rendering |`,`| Accessibility | Ready | Confirm keyboard navigation |`,``,`## Highlights`,``,`- The artifact stays in the conversation workspace.`,`- The chat chip is the compact entry point.`,`- The Files drawer provides the full rich Markdown view.`].join(`
|
|
7
|
+
`),ze=Date.UTC(2026,6,29,12,0,0),F=e=>new Date(ze+e*1e3).toISOString();function Be(e,t,n,r){return{id:e,timestamp:F(r),source:t===`user`?`user`:`agent`,llm_message:{role:t,content:[{type:`text`,text:n}]},activated_skills:[],extended_content:[]}}var Ve={id:`canvas-demo-action`,timestamp:F(1),source:`agent`,thought:[],thinking_blocks:[],action:{kind:`FileEditorAction`,command:`create`,path:N,file_text:P,old_str:null,new_str:null,insert_line:null,view_range:null},tool_name:`file_editor`,tool_call_id:`canvas-demo-tool-call`,tool_call:{id:`canvas-demo-tool-call`,type:`function`,function:{name:`file_editor`,arguments:JSON.stringify({command:`create`,path:N})}},llm_response_id:`canvas-demo-response`,security_risk:t.LOW},He={id:`canvas-demo-observation`,timestamp:F(2),source:`environment`,tool_name:`file_editor`,tool_call_id:`canvas-demo-tool-call`,action_id:Ve.id,observation:{kind:`FileEditorObservation`,command:`create`,output:`Created ${N}`,path:N,prev_exist:!1,old_content:null,new_content:P,error:null}},Ue=[Be(`canvas-demo-user`,`user`,`Create a concise project canvas as a Markdown report.`,0),Ve,He,Be(`canvas-demo-agent`,`assistant`,`I generated the project canvas. Open it from the file chip above.`,3)],We={[Me]:Le,[Re]:Ue},I=Date.now(),Ge=`pagination-local`,L=`pagination-cloud`,Ke=100,qe=500,Je=Date.UTC(2026,4,13,0,0,0),Ye=[{id:`1`,title:`My New Project`,created_at:new Date(I).toISOString(),updated_at:new Date(I).toISOString(),execution_status:`waiting_for_confirmation`,tags:{project:`vault`,work:``}},{id:`2`,title:`Repo Testing`,created_at:new Date(I-2880*60*1e3).toISOString(),updated_at:new Date(I-2880*60*1e3).toISOString(),execution_status:`idle`,selected_repository:`octocat/hello-world`,git_provider:`github`},{id:`3`,title:`Another Project`,created_at:new Date(I-7200*60*1e3).toISOString(),updated_at:new Date(I-7200*60*1e3).toISOString(),execution_status:`idle`,selected_repository:`octocat/earth`,selected_branch:`main`},{id:`4`,title:`Archived Project`,created_at:new Date(I-14400*60*1e3).toISOString(),updated_at:new Date(I-14400*60*1e3).toISOString(),execution_status:`idle`,sandbox_status:`MISSING`},{id:`5`,title:`Errored Project`,created_at:new Date(I-10080*60*1e3).toISOString(),updated_at:new Date(I-10080*60*1e3).toISOString(),execution_status:`idle`,sandbox_status:`ERROR`},{id:Ge,title:`Local pagination fixture`,created_at:new Date(I-8640*60*1e3).toISOString(),updated_at:new Date(I-8640*60*1e3).toISOString(),execution_status:`idle`,workspace:{working_dir:`/workspace/project`}},{id:Me,title:`Wide table demo`,created_at:new Date(I-1440*60*1e3).toISOString(),updated_at:new Date(I-1440*60*1e3).toISOString(),execution_status:`idle`,workspace:{working_dir:`/workspace/project`}},{id:Re,title:`Generated canvas demo`,created_at:new Date(I-720*60*1e3).toISOString(),updated_at:new Date(I-720*60*1e3).toISOString(),execution_status:`idle`,workspace:{working_dir:`/workspace/project`}}],R=new Map(Ye.map(e=>[e.id,e])),Xe=new Map([[Ge,Qe(`Local pagination message`)],[L,Qe(`Cloud pagination message`)]]);function Ze(e,t){return{id:`${t.toLowerCase().replaceAll(` `,`-`)}-${e}`,timestamp:new Date(Je+e*6e4).toISOString(),source:`agent`,llm_message:{role:`assistant`,content:[{type:`text`,text:`${t} ${e}`}]},activated_skills:[],extended_content:[]}}function Qe(e){return Array.from({length:Ke},(t,n)=>Ze(n+1,e))}function $e(e,t){let n=Number(t.get(`limit`)??`100`),r=t.get(`timestamp__lt`),i=t.get(`sort_order`),a=[...r?e.filter(e=>(e.timestamp??``)<r):e].sort((e,t)=>i===`TIMESTAMP_DESC`?(t.timestamp??``).localeCompare(e.timestamp??``):(e.timestamp??``).localeCompare(t.timestamp??``));return{items:a.slice(0,n),next_page_id:a.length>n?`next-page`:null}}async function et(e,t){let n=Xe.get(e);return n?(t.has(`timestamp__lt`)&&await p(qe),$e(n,t)):null}function tt(){let t=new Date(I-8640*60*1e3).toISOString();return{id:L,created_by_user_id:null,selected_repository:null,selected_branch:null,git_provider:null,title:`Cloud pagination fixture`,trigger:null,pr_number:[],llm_model:`openhands/claude-haiku-4-5-20251001`,metrics:null,created_at:t,updated_at:t,execution_status:e.IDLE,conversation_url:null,session_api_key:null,sandbox_id:null,workspace:{working_dir:`/workspace/project`},public:!1,sub_conversation_ids:[]}}var nt=tt();function z(e){return{id:e.id,title:e.title??null,created_at:e.created_at,updated_at:e.updated_at,execution_status:e.execution_status??`idle`,sandbox_status:e.sandbox_status??null,metrics:e.metrics??null,agent:e.agent??null,workspace:e.workspace??null,tags:e.tags??null}}function rt(e){return!e||e.length===0?Array.from(R.values()).map(z):e.map(e=>{let t=R.get(e);return t?z(t):null})}var it=[u.get(`*/api/conversations/search`,async({request:e})=>{let t=new URL(e.url),n=Number(t.searchParams.get(`limit`)??`20`),r=Array.from(R.values()).sort((e,t)=>t.updated_at.localeCompare(e.updated_at)).slice(0,n).map(z);return f.json({items:r,next_page_id:null})}),u.get(`*/api/conversations`,async({request:e})=>{let t=new URL(e.url),n=t.searchParams.getAll(`ids[]`).length>0?t.searchParams.getAll(`ids[]`):t.searchParams.getAll(`ids`);return f.json(rt(n))}),u.get(`*/api/conversations/:conversationId`,async({params:e})=>{let t=e.conversationId,n=R.get(t);return n?f.json(z(n)):f.json(null,{status:404})}),u.post(`*/api/conversations`,async()=>{await p();let e={id:`${Math.floor(Math.random()*1e5)}`,title:`New Conversation`,created_at:new Date().toISOString(),updated_at:new Date().toISOString(),execution_status:`idle`};return R.set(e.id,e),f.json(z(e),{status:201})}),u.patch(`/api/conversations/:conversationId`,async({params:e,request:t})=>{let n=e.conversationId,r=R.get(n);if(r){let e=await t.json();if(e?.title||e?.tags)return R.set(n,{...r,...e.title?{title:e.title}:{},...e.tags?{tags:e.tags}:{},updated_at:new Date().toISOString()}),f.json(null,{status:200})}return f.json(null,{status:404})}),u.delete(`*/api/conversations/:conversationId`,async({params:e})=>{let t=e.conversationId;return R.has(t)?(R.delete(t),f.json(null,{status:200})):f.json(null,{status:404})}),u.get(`*/api/conversations/:conversationId/events/count`,async()=>f.json(0)),u.get(`*/api/conversations/:conversationId/events/search`,async({params:e,request:t})=>{let n=e.conversationId,r=new URL(t.url).searchParams,i=await et(n,r);if(i)return f.json(i);let a=We[n];return a?f.json($e(a,r)):f.json({items:[],next_page_id:null})}),u.post(`*/api/conversations/:conversationId/events`,async()=>f.json({ok:!0})),u.get(`*/api/conversations/:conversationId/workspace/*`,({params:e,request:t})=>{let n=e.conversationId?.toString(),r=new URL(t.url);return n===`canvas-demo`&&r.pathname.endsWith(`/canvas.md`)?f.text(P,{headers:{"Content-Type":`text/markdown; charset=utf-8`}}):d()}),u.post(`*/api/conversations/:conversationId/pause`,async()=>f.json({success:!0})),u.post(`*/api/conversations/:conversationId/interrupt`,async()=>f.json({success:!0})),u.post(`*/api/conversations/:conversationId/run`,async()=>f.json({success:!0})),u.post(`*/api/cloud-proxy`,async({request:e})=>{let t=(await e.json()).path??`/`,n=new URL(t,`https://mock-cloud.test`);if(n.pathname===`/api/v1/app-conversations`){let e=n.searchParams.getAll(`ids`);if(e.length>0)return f.json(e.map(e=>e===L?nt:null))}if(n.pathname===`/api/v1/app-conversations/search`)return f.json({items:[nt],next_page_id:null});if(n.pathname===`/api/v1/conversation/${L}/events/search`){let e=await et(L,n.searchParams);return f.json(e)}return n.pathname===`/api/v1/settings`?f.json({llm_model:`openhands/claude-haiku-4-5-20251001`,llm_base_url:``,llm_api_key:null,llm_api_key_set:!1,search_api_key_set:!1,agent:`CodeActAgent`,language:`en`,user_consents_to_analytics:!1,provider_tokens_set:{github:``}}):n.pathname===`/api/keys/current`?f.json({id:`mock-key`,name:`Mock key`,org_id:`org-1`,user_id:`user-1`,auth_type:`api_key`}):n.pathname===`/api/organizations`?f.json({items:[{id:`org-1`,name:`Mock Org`,is_personal:!0}],current_org_id:`org-1`}):n.pathname===`/api/organizations/org-1/me`?f.json({org_id:`org-1`,user_id:`org-1`}):n.pathname===`/api/authenticate`?f.json({ok:!0}):f.json({})}),u.post(`*/api/conversations/:conversationId/ask_agent`,async()=>f.json({response:`Mock agent response`})),u.get(`*/api/vscode/url`,async()=>f.json({url:null})),u.post(`*/api/skills`,async()=>f.json({skills:[]})),u.post(`/api/v1/conversations/:conversationId/pending-messages`,async()=>f.json({id:`mock-pending-id`,position:0}))],at=[u.post(`*/api/cloud-proxy`,()=>f.json({error:`cloud proxy not available in mock mode`},{status:503})),u.get(`*/api/user/info`,()=>f.json({id:`1`,login:`octocat`,avatar_url:`https://avatars.githubusercontent.com/u/583231?v=4`,company:`GitHub`,email:`placeholder@placeholder.placeholder`,name:`monalisa octocat`})),u.post(`*/api/authenticate`,async()=>f.json({message:`Authenticated`})),u.post(`*/api/logout`,()=>f.json(null,{status:200}))],ot=[u.post(`*/api/submit-feedback`,async()=>(await p(1200),f.json({statusCode:200,body:{message:`Success`,link:`fake-url.com`,password:`abc123`}}))),u.post(`*/api/submit-feedback`,async()=>f.json({statusCode:200},{status:200}))],st=[u.post(`https://us.i.posthog.com/e`,async()=>f.json(null,{status:200})),u.post(`https://z.openhands.dev/*`,async()=>f.json(null,{status:200}))],B=new Date().toISOString(),V=e=>new Date(Date.now()-e*864e5).toISOString(),ct={automations:[{id:`a1000000-0000-0000-0000-000000000001`,name:`PR Triage Digest`,trigger:{type:`cron`,schedule:`0 9 * * 1-5`,schedule_human:`Weekdays at 09:00`},enabled:!0,repository:`acme/frontend-app`,model:`triage-fast`,timeout:600,created_at:V(90),updated_at:B,prompt:`Review newly opened pull requests in acme/frontend-app, identify risky changes, summarize likely impact, and prepare a concise digest with priority ordering for the engineering review channel.`,branch:`main`,plugins:[`GitHub`,`Slack`,`Linear`],notification:`Slack digest to #eng-reviews`,timezone:`America/Los_Angeles`,last_triggered_at:V(0)},{id:`a1000000-0000-0000-0000-000000000002`,name:`Nightly Security Pass`,trigger:{type:`cron`,schedule:`30 1 * * *`,schedule_human:`Daily at 01:30`},enabled:!0,repository:`acme/backend-api`,model:`security-careful`,timeout:900,created_at:V(60),updated_at:B,prompt:`Scan the acme/backend-api repository for known security vulnerabilities, outdated dependencies, and insecure code patterns. Produce a prioritized remediation summary.`,branch:`main`,plugins:[`GitHub`],notification:`Email to security-team@acme.com`,timezone:`UTC`,last_triggered_at:V(0)},{id:`a1000000-0000-0000-0000-000000000003`,name:`Docs Sync on Push`,trigger:{type:`cron`,schedule:`*/5 * * * *`,schedule_human:`Runs on every push`},enabled:!0,repository:`acme/docs`,model:`docs-fast`,created_at:V(45),updated_at:B,prompt:`Monitor acme/docs for new pushes. For each push, generate a changelog-ready summary of what changed and why.`,branch:`main`,plugins:[`GitHub`,`Slack`],notification:`Slack to #docs-updates`,timezone:`America/New_York`,last_triggered_at:V(1)},{id:`a1000000-0000-0000-0000-000000000004`,name:`Release Readiness Review`,trigger:{type:`cron`,schedule:`0 11 * * 5`,schedule_human:`Fridays at 11:00`},enabled:!1,repository:`acme/realtime-service`,model:`release-review`,created_at:V(80),updated_at:B,prompt:`Compile a release readiness report: list open blockers, active incidents, and pending approvals for acme/realtime-service.`,branch:`release`,plugins:[`GitHub`,`Linear`],notification:`Slack to #releases`,timezone:`America/Chicago`,last_triggered_at:V(14)},{id:`a1000000-0000-0000-0000-000000000005`,name:`Incident Webhook Summary`,trigger:{type:`cron`,schedule:`0 */2 * * *`,schedule_human:`On incident webhook`},enabled:!1,repository:`acme/incident-service`,model:`incident-summary`,created_at:V(30),updated_at:B,prompt:`Summarize incoming incident webhooks, categorize by severity, and post a digest to the on-call Slack channel.`,branch:`main`,plugins:[`Slack`],notification:`Slack to #oncall`,timezone:`UTC`,last_triggered_at:null},{id:`a1000000-0000-0000-0000-000000000006`,name:`PR Review on Open`,trigger:{type:`event`,source:`github`,on:`pull_request.opened`,filter:`repository.full_name == 'acme/frontend-app'`},enabled:!0,repository:`acme/frontend-app`,model:`review-fast`,timeout:1800,created_at:V(15),updated_at:B,prompt:`When a new PR is opened, perform a thorough code review focusing on correctness, security, and performance. Post findings as inline comments.`,branch:`main`,plugins:[`GitHub`],notification:`GitHub PR comment`,last_triggered_at:V(0),preset_metadata:{template:{id:`github-pr-reviewer`,version:`1.0.0`,config:{}}}},{id:`a1000000-0000-0000-0000-000000000007`,name:`Release Notes Generator`,trigger:{type:`event`,source:`github`,on:`release.published`,filter:`glob(release.tag_name, 'v*') && !release.prerelease`},enabled:!0,repository:`acme/backend-api`,model:`docs-fast`,created_at:V(10),updated_at:B,prompt:`Generate comprehensive release notes from the commits since the last release. Include breaking changes, new features, and bug fixes.`,branch:`main`,plugins:[`GitHub`],notification:`GitHub release body update`,last_triggered_at:V(3)}],total:7},lt=(e,t=9)=>{let n=new Date(Date.now()-e*864e5);return n.setHours(t,0,0,0),n.toISOString()},ut=e=>new Date(Date.now()-e*6e4).toISOString();function dt(e,t){return e?{phase_code:e.code,phase_label:e.label,phase_updated_at:e.ageMinutes===void 0?t:ut(e.ageMinutes)}:{}}function H(e,t,n,r=9,i=!0,a){let o=lt(n,r);return{id:e,status:t,conversation_id:i?`conv-${e}`:null,bash_command_id:i?`cmd-${e}`:null,error_detail:t===l.FAILED?`Process exited with code 1`:null,...dt(a,o),started_at:o,completed_at:new Date(new Date(o).getTime()+12e4).toISOString()}}function U(e,t,n,r=!0,i){let a=ut(n);return{id:e,status:t,conversation_id:r?`conv-${e}`:null,bash_command_id:r?`cmd-${e}`:null,error_detail:null,...dt(i,a),started_at:a,completed_at:null}}var ft={"a1000000-0000-0000-0000-000000000001":[H(`r1-01`,l.COMPLETED,0),H(`r1-02`,l.COMPLETED,1),H(`r1-03`,l.FAILED,2,9,!0,{code:`sandbox_provisioning`,label:null}),H(`r1-04`,l.COMPLETED,3,9,!0,{code:`running_agent`,label:null}),H(`r1-05`,l.COMPLETED,4),H(`r1-06`,l.COMPLETED,7),H(`r1-07`,l.FAILED,8),H(`r1-08`,l.COMPLETED,9),H(`r1-09`,l.COMPLETED,10),H(`r1-10`,l.COMPLETED,11)],"a1000000-0000-0000-0000-000000000002":[U(`r2-00`,l.PENDING,2,!1,{code:`queued`,label:null}),H(`r2-01`,l.COMPLETED,0,1),H(`r2-02`,l.COMPLETED,1,1),H(`r2-03`,l.COMPLETED,2,1),H(`r2-04`,l.FAILED,3,1),H(`r2-05`,l.COMPLETED,4,1)],"a1000000-0000-0000-0000-000000000003":[U(`r3-00`,l.RUNNING,52,!0,{code:`diffing_docs_tree`,label:`Diffing 340 changed files against main`,ageMinutes:41}),H(`r3-01`,l.COMPLETED,1),H(`r3-02`,l.CANCELLED,2),H(`r3-03`,l.SKIPPED,3,9,!1)],"a1000000-0000-0000-0000-000000000004":[H(`r4-01`,l.FAILED,14,11,!1),H(`r4-02`,l.COMPLETED,21,11)],"a1000000-0000-0000-0000-000000000005":[],"a1000000-0000-0000-0000-000000000006":[U(`r6-00`,l.RUNNING,13,!0,{code:null,label:`Running QA checks on PR #4821`,ageMinutes:4}),U(`r6-06`,l.RUNNING,6,!0,{code:`checking_out`,label:null,ageMinutes:2}),U(`r6-07`,l.RUNNING,21),H(`r6-01`,l.COMPLETED,0,14),H(`r6-02`,l.COMPLETED,0,11),H(`r6-03`,l.FAILED,1,16),H(`r6-04`,l.COMPLETED,2,10),H(`r6-05`,l.COMPLETED,3,9)],"a1000000-0000-0000-0000-000000000007":[H(`r7-01`,l.COMPLETED,3,15),H(`r7-02`,l.COMPLETED,10,12)]},W=te.responses.supported.body,pt=/^(?:\*|\*\/(\d+)) \* \* \* \*$/;function mt(e){let t=pt.exec(e.trim());return t?(t[1]?Number(t[1]):1)*60:null}var ht=W.eventTypes.filter(e=>e!==`pull_request_review_comment.created`);function gt(e){if(!e)return[];let t=W.triggers.cron;if(e.type===`cron`&&e.schedule&&t){let n=mt(e.schedule);if(n!==null&&n<t.minIntervalSeconds)return[{field:`trigger.schedule`,code:`interval_too_short`,message:`Minimum interval for this deployment is ${t.minIntervalSeconds/60} minutes.`}]}return e.type===`event`&&e.on&&!ht.includes(e.on)?[{field:`trigger.on`,code:`event_type_not_delivered`,message:`No ${e.source===`github`?`GitHub`:e.source} webhook delivering ${e.on} is registered for this organization.`}]:[]}var G=new Map(ct.automations.map(e=>[e.id,{...e}])),_t=[u.get(`*/api/automation/health`,async()=>(await p(100),f.json({status:`ok`}))),u.get(`*/api/automation/v1`,async({request:e})=>{await p(300);let t=new URL(e.url),n=Number(t.searchParams.get(`limit`)??`50`),r=Number(t.searchParams.get(`offset`)??`0`),i=Array.from(G.values()),a={automations:i.slice(r,r+n),total:i.length};return f.json(a)}),u.get(`*/api/automation/v1/capabilities`,async()=>(await p(200),f.json(W))),u.post(`*/api/automation/v1/validate`,async({request:e})=>{await p(200);let t=gt((await e.clone().json()).draft?.trigger),n={valid:t.length===0,errors:t};return f.json(n)}),u.post(`*/api/automation/v1/uploads`,async({request:e})=>{await p(200);let t=new URL(e.url).searchParams.get(`name`)||`automation`;return f.json({tarball_path:`oh-internal://uploads/${encodeURIComponent(t)}-${crypto.randomUUID()}.tar.gz`})}),u.post(`*/api/automation/v1`,async({request:e})=>{await p(200);let t=await e.clone().json(),n=new Date().toISOString(),r={id:crypto.randomUUID(),name:t.name,prompt:null,model:t.model??null,trigger:t.trigger,enabled:!0,created_at:n,updated_at:n,last_triggered_at:null,...typeof t.timeout==`number`&&{timeout:t.timeout},...typeof t.trigger.timezone==`string`&&{timezone:t.trigger.timezone}};return G.set(r.id,r),f.json(r,{status:201})}),u.post(`*/api/automation/v1/preset/:kind`,async({params:e,request:t})=>{await p(200);let n=await t.clone().json(),r=new Date().toISOString(),i={id:crypto.randomUUID(),name:n.name,prompt:n.prompt,model:n.model??null,trigger:n.trigger,enabled:!0,created_at:r,updated_at:r,last_triggered_at:null,...n.repos?.[0]&&{repository:n.repos[0].url,branch:n.repos[0].ref},...n.plugins&&{plugins:n.plugins.map(e=>e.source)},...typeof n.timeout==`number`&&{timeout:n.timeout},...typeof n.trigger.timezone==`string`&&{timezone:n.trigger.timezone}};return e.kind!==`prompt`&&e.kind!==`plugin`?f.json({detail:`Unknown preset kind`},{status:404}):(G.set(i.id,i),f.json(i,{status:201}))}),u.get(`*/api/automation/v1/:id/runs`,async({params:e,request:t})=>{await p(200);let n=e.id;if(!G.has(n))return f.json({detail:`Automation not found`},{status:404});let r=new URL(t.url),i=Number(r.searchParams.get(`limit`)??`50`),a=Number(r.searchParams.get(`offset`)??`0`),o=ft[n]??[],s=o.slice(a,a+i),c={};for(let e of o)c[e.status]=(c[e.status]??0)+1;let l={runs:s,total:o.length,status_counts:c};return f.json(l)}),u.get(`*/api/automation/v1/:id`,async({params:e})=>{await p(200);let t=G.get(e.id);return t?f.json(t):f.json({detail:`Automation not found`},{status:404})}),u.patch(`*/api/automation/v1/:id`,async({params:e,request:t})=>{await p(200);let n=e.id,r=await t.clone().json(),i=G.get(n);if(!i)return f.json({detail:`Automation not found`},{status:404});let a={...i,...r,updated_at:new Date().toISOString()};return G.set(n,a),f.json(a)}),u.post(`*/api/automation/v1/:id/dispatch`,async({params:e})=>{await p(200);let t=e.id;if(!G.get(t))return f.json({detail:`Automation not found`},{status:404});let n={id:crypto.randomUUID(),status:l.PENDING,conversation_id:null,bash_command_id:null,error_detail:null,phase_code:null,phase_label:null,phase_updated_at:null,started_at:new Date().toISOString(),completed_at:null};return f.json(n,{status:201})}),u.delete(`*/api/automation/v1/:id`,async({params:e})=>{await p(200);let t=e.id;return G.has(t)?(G.delete(t),new f(null,{status:204})):f.json({detail:`Automation not found`},{status:404})})],vt={ok:!0,tools:[]},yt=[u.post(`*/api/mcp/test`,async()=>f.json(vt))],K=[],q=[];function J(){return{workspaces:K.map(e=>({...e})),workspaceParents:q.map(e=>({...e}))}}var bt=[u.get(`*/api/workspaces`,async()=>f.json(J())),u.post(`*/api/workspaces`,async({request:e})=>{let t=await e.json();for(let e of t.workspaces??[]){let t=K.findIndex(t=>t.path===e.path);t>=0?K[t]={...e}:K.push({...e})}return f.json(J())}),u.delete(`*/api/workspaces`,async({request:e})=>{let t=new URL(e.url).searchParams.get(`path`),n=K.length;return K=K.filter(e=>e.path!==t),f.json({deleted:K.length!==n})}),u.post(`*/api/workspaces/parents`,async({request:e})=>{let t=await e.json();for(let e of t.parents??[]){let t=q.findIndex(t=>t.path===e.path);t>=0?q[t]={...e}:q.push({...e})}return f.json(J())}),u.delete(`*/api/workspaces/parents`,async({request:e})=>{let t=new URL(e.url).searchParams.get(`path`),n=q.length;return q=q.filter(e=>e.path!==t),f.json({deleted:q.length!==n})}),u.post(`*/api/auth/workspace-session`,async()=>f.json({ok:!0})),u.delete(`*/api/auth/workspace-session`,async()=>new f(null,{status:204}))],xt=`{
|
|
8
|
+
"schema_version": 1,
|
|
9
|
+
"name": "demo-page",
|
|
10
|
+
"display_name": "Demo page",
|
|
11
|
+
"version": "0.1.0",
|
|
12
|
+
"description": "A dependency-free fixture for the Canvas Extension page ABI.",
|
|
13
|
+
"entrypoint": "extension.js",
|
|
14
|
+
"contributes": {
|
|
15
|
+
"pages": [
|
|
16
|
+
{
|
|
17
|
+
"id": "hello",
|
|
18
|
+
"title": "Hello from an extension",
|
|
19
|
+
"path": "/hello",
|
|
20
|
+
"nav_label": "Extension demo"
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
`,St=`export function activate(host) {
|
|
26
|
+
return host.registerPage("hello", ({ container, path }) => {
|
|
27
|
+
const wrapper = document.createElement("section");
|
|
28
|
+
wrapper.style.cssText =
|
|
29
|
+
"min-height:100%;padding:2rem;color:var(--oh-text-primary,#fff);background:var(--oh-color-base,#111);";
|
|
30
|
+
|
|
31
|
+
const title = document.createElement("h1");
|
|
32
|
+
title.textContent = "Hello from a Canvas Extension";
|
|
33
|
+
title.style.cssText = "font-size:1.5rem;font-weight:600;";
|
|
34
|
+
|
|
35
|
+
const detail = document.createElement("p");
|
|
36
|
+
detail.textContent = path
|
|
37
|
+
? \`Nested extension path: \${path}\`
|
|
38
|
+
: \`Host API \${host.apiVersion} on backend \${host.backend.id}\`;
|
|
39
|
+
detail.style.cssText = "margin-top:0.75rem;opacity:0.75;";
|
|
40
|
+
|
|
41
|
+
wrapper.append(title, detail);
|
|
42
|
+
container.append(wrapper);
|
|
43
|
+
return () => wrapper.remove();
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
`,Ct=`src/fixtures/canvas-extensions/demo-page`,Y=JSON.parse(xt),wt=`openhands-canvas-extension-dev-installation`;function Tt(){try{let e=globalThis.sessionStorage?.getItem(wt);return e?JSON.parse(e):null}catch{return null}}var X=Tt();function Et(e){X=e;try{e?globalThis.sessionStorage?.setItem(wt,JSON.stringify(e)):globalThis.sessionStorage?.removeItem(wt)}catch{}}function Dt(e){return e.replaceAll(`\\`,`/`).endsWith(Ct)}function Z(e){return e?decodeURIComponent(Array.isArray(e)?e[0]:e):``}function Q(e){return f.json({detail:`Canvas extension '${e}' is not installed.`},{status:404})}function $(e){return X?.name===e?X:null}var Ot=[u.get(`*/api/canvas-extensions/installed`,()=>f.json({canvas_extensions:X?[X]:[]})),u.post(`*/api/canvas-extensions/install`,async({request:e})=>{let t=await e.json();return!t.source||!Dt(t.source)?f.json({detail:`Mock mode only installs '${Ct}'.`},{status:400}):X&&!t.force?f.json({detail:`Canvas extension '${Y.name}' is already installed.`},{status:409}):(Et({name:Y.name,version:Y.version,description:Y.description,enabled:!1,source:t.source,resolved_ref:t.ref||`mock-working-tree`,repo_path:t.repo_path||null,installed_at:new Date().toISOString(),install_path:`/mock/canvas-extensions/${Y.name}`,manifest:Y}),f.json(X))}),u.get(`*/api/canvas-extensions/installed/:name/bundle`,({params:e})=>{let t=Z(e.name);return $(t)?new f(St,{headers:{"Content-Type":`application/javascript; charset=utf-8`,"Cache-Control":`no-cache`}}):Q(t)}),u.get(`*/api/canvas-extensions/installed/:name`,({params:e})=>{let t=Z(e.name),n=$(t);return n?f.json(n):Q(t)}),u.patch(`*/api/canvas-extensions/installed/:name`,async({params:e,request:t})=>{let n=Z(e.name),r=$(n);if(!r)return Q(n);let i=await t.json();return typeof i.enabled==`boolean`?(Et({...r,enabled:i.enabled}),f.json({name:n,enabled:i.enabled})):f.json({detail:`'enabled' must be a boolean.`},{status:422})}),u.delete(`*/api/canvas-extensions/installed/:name`,({params:e})=>{let t=Z(e.name);return $(t)?(Et(null),f.json({message:`Canvas extension uninstalled.`})):Q(t)})],kt=ee(...ie,...ae,...me,...ve,...je,...it,...at,...ot,...st,..._t,...yt,...bt,...Ot);export{kt as worker};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{yt as e}from"./vendor-styling-Ck5D_A2Q.js";import{t}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~
|
|
1
|
+
import{yt as e}from"./vendor-styling-Ck5D_A2Q.js";import{t}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{K as n,t as r}from"./utils-BOco8mxR.js";import{t as i}from"./external-link-DQtv7eTh.js";import{C as a}from"./markdown-renderer-rivLvYh-.js";import{t as o}from"./conversation-tab-empty-state-DKlzAz5c.js";import{t as s}from"./vendor~browser-tab-C5uuAxZX.js";var c=e();function l({src:e}){let{t:r}=t(`openhands`);return(0,c.jsx)(`img`,{src:e,className:`block w-full h-auto`,alt:r(n.BROWSER$SCREENSHOT_ALT)})}function u({url:e,hasPage:a}){let{t:o}=t(`openhands`),s=r(`shrink-0 inline-flex items-center justify-center w-6 h-6 rounded-md`,`text-[var(--oh-text-tertiary)] opacity-40 cursor-not-allowed`),l=`w-3.5 h-3.5`;return(0,c.jsxs)(`div`,{className:`flex w-full min-h-[34px] shrink-0 items-center gap-1 border-b border-[var(--oh-border)] px-2 py-1.5`,"data-testid":`browser-chrome-bar`,children:[(0,c.jsx)(`div`,{className:r(`flex min-h-7 min-w-0 flex-1 items-center rounded-md border border-[var(--oh-border)]`,`bg-[var(--oh-surface-raised)] px-2 text-xs leading-5`,e?`text-[var(--oh-text-tertiary)]`:`text-[var(--oh-text-dim)]`),"data-testid":`browser-chrome-url`,title:e||void 0,children:(0,c.jsx)(`span`,{className:`truncate`,children:e||o(n.BROWSER$URL_PLACEHOLDER)})}),a&&e?(0,c.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,"aria-label":o(n.BUTTON$OPEN_IN_NEW_TAB),title:o(n.BUTTON$OPEN_IN_NEW_TAB),"data-testid":`browser-chrome-open-external`,className:r(`shrink-0 inline-flex items-center justify-center w-6 h-6 rounded-md`,`text-[var(--oh-text-tertiary)] hover:bg-tertiary cursor-pointer`),children:(0,c.jsx)(i,{className:l,"aria-hidden":!0,strokeWidth:2})}):(0,c.jsx)(`button`,{type:`button`,disabled:!0,"aria-label":o(n.BUTTON$OPEN_IN_NEW_TAB),title:o(n.BUTTON$OPEN_IN_NEW_TAB),className:s,children:(0,c.jsx)(i,{className:l,"aria-hidden":!0,strokeWidth:2})})]})}function d(){let{t:e}=t(`openhands`);return(0,c.jsx)(o,{icon:(0,c.jsx)(s,{}),children:e(n.BROWSER$NO_PAGE_LOADED)})}function f(){let{url:e,screenshotSrc:t}=a(),n=!!t,r=t?.startsWith(`data:image/png;base64,`)?t:`data:image/png;base64,${t??``}`;return(0,c.jsxs)(`div`,{className:`flex h-full min-h-0 w-full flex-col text-[var(--oh-muted)]`,children:[(0,c.jsx)(u,{url:e,hasPage:n}),(0,c.jsx)(`div`,{className:`flex min-h-0 flex-1 flex-col overflow-y-auto scrollbar-hide bg-[var(--oh-surface)]`,children:t?(0,c.jsx)(l,{src:r}):(0,c.jsx)(d,{})})]})}function p(){return(0,c.jsx)(f,{})}export{p as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{B as r,R as i,U as a}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{t as o}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{K as s}from"./utils-BOco8mxR.js";import{t as c}from"./loading-spinner-DfHI77BA.js";import{n as l}from"./canvas-extensions-runtime-DdnkgJXV.js";var u=e(t(),1),d=n(),f=a(function(){let{t:e}=o(`openhands`),t=r(),n=i(),a=t.extensionName??``,f=t[`*`]??``,{pages:p,activating:m,errors:h}=l(),g=u.useRef(null),[_,v]=u.useState(null),y=u.useMemo(()=>p.filter(e=>e.extension.name===a).sort((e,t)=>t.contribution.path.length-e.contribution.path.length).find(e=>f===e.contribution.path||f.startsWith(`${e.contribution.path}/`)),[a,p,f]);if(u.useEffect(()=>{let e=g.current;if(!e||!y)return;let t=!1,r;v(null),e.replaceChildren();let i=f.slice(y.contribution.path.length).replace(/^\/+/,``);return Promise.resolve().then(()=>y.mount({container:e,path:i,navigate:e=>n(e)})).then(e=>{typeof e==`function`&&(t?e():r=e)}).catch(e=>{t||v(e instanceof Error?e.message:`Extension page failed.`)}),()=>{t=!0;try{r?.()}catch(e){console.error(`Canvas Extension page cleanup failed`,e)}e.replaceChildren()}},[n,y,f]),m&&!y)return(0,d.jsx)(`div`,{className:`flex h-full items-center justify-center`,children:(0,d.jsx)(c,{size:`large`})});let b=_??h.get(a);return b||!y?(0,d.jsx)(`main`,{className:`flex h-full items-center justify-center p-8`,children:(0,d.jsxs)(`div`,{className:`max-w-lg rounded-xl border border-[var(--oh-border)] bg-base-secondary p-6 text-center`,children:[(0,d.jsx)(`h1`,{className:`text-lg font-semibold text-white`,children:e(s.SETUP$UNAVAILABLE_TITLE)}),(0,d.jsx)(`p`,{className:`mt-2 text-sm text-tertiary-light`,children:b||e(s.SETTINGS$APPS_PAGE_UNAVAILABLE)})]})}):(0,d.jsx)(`main`,{"aria-label":y.contribution.title,className:`h-full min-h-0 overflow-auto`,children:(0,d.jsx)(`div`,{ref:g,className:`min-h-full`})})});export{f as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e}from"./rolldown-runtime-Cyuzqnbw.js";import{St as t,yt as n}from"./vendor-styling-Ck5D_A2Q.js";import{U as r}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~i58xkef6-cHFhpUBq.js";import{r as i}from"./vendor~entry.client~root~root-layout~index-home~home~conversation-panel~conversation~launch~ew9ih1s8-DnDoaYNi.js";import{t as a}from"./vendor~root~root-layout~index-home~home~conversation-panel~conversation~launch~extensions-h~iyia17eu-CV850oio.js";import{t as o}from"./useMutation-CJuK90oc.js";import{ct as s,dt as c,j as l,n as u,st as d}from"./active-backend-context-rZiLJRUc.js";import{K as f,t as p}from"./utils-BOco8mxR.js";import{p as m}from"./agent-server-client-options-BikiNwTa.js";import{n as h}from"./extensions-navigation-CRMZd-FE.js";import{t as g}from"./external-link-DQtv7eTh.js";import{t as _}from"./modal-backdrop-BSzNhM4r.js";import{n as v}from"./modal-classes-Dg0ngBPO.js";import{t as y}from"./brand-button-DxPO4Lf8.js";import{t as b}from"./modal-close-button-B9j4nasm.js";import{t as x}from"./settings-input-C0dd8Utu.js";import{t as S}from"./confirmation-modal-gIFHeZt6.js";import{t as C}from"./toggle-switch-lwQtxDcm.js";import{i as w,n as T,r as E,t as D}from"./use-canvas-extensions-CFUpHat6.js";import{a as O,i as k,n as A,o as j,t as M}from"./extension-module-card-classes-DpeaYhYo.js";import{n as N,t as P}from"./api-error-message-Ve79qDcN.js";import{n as F}from"./settings-like-page-layout-classes-Cw4Yzv_P.js";var I=e(t(),1);function L(){let e=i();return()=>e.invalidateQueries({queryKey:l.all})}function R(){let e=L(),{t}=a(`openhands`);return o({meta:{disableToast:!0},mutationFn:e=>T.install(e),onSuccess:()=>{e(),s(t(f.SETTINGS$APPS_INSTALL_SUCCESS))},onError:e=>{d(P(e)?N(e,t(f.ERROR$GENERIC)):c(e)||t(f.ERROR$GENERIC))}})}function z(){let e=L();return o({mutationFn:({name:e,enabled:t})=>T.setEnabled(e,t),onSuccess:()=>void e()})}function B(){let e=L(),{t}=a(`openhands`);return o({mutationFn:e=>T.uninstall(e),onSuccess:()=>{e(),s(t(f.SETTINGS$APPS_UNINSTALL_SUCCESS))}})}var V=n();function H({onClose:e}){let{t}=a(`openhands`),n=R(),[r,i]=I.useState(``),[o,s]=I.useState(``),[c,l]=I.useState(``),u=r.trim(),d=u.length>0&&!n.isPending;return(0,V.jsx)(_,{onClose:e,"aria-label":t(f.SETTINGS$APPS_ADD_BUTTON),children:(0,V.jsxs)(`form`,{onSubmit:t=>{t.preventDefault(),d&&n.mutate({source:u,ref:o.trim()||null,repo_path:c.trim()||null},{onSuccess:e})},"data-testid":`add-canvas-extension-modal`,className:`relative flex w-[520px] max-w-[90vw] max-h-[85vh] flex-col rounded-xl border border-[var(--oh-border)] bg-base-secondary`,children:[(0,V.jsx)(b,{onClose:e,testId:`add-canvas-extension-modal-close`}),(0,V.jsxs)(`header`,{className:`flex-shrink-0 px-6 pb-4 pt-6`,children:[(0,V.jsx)(`h2`,{className:p(`pr-6`,v),children:t(f.SETTINGS$APPS_ADD_BUTTON)}),(0,V.jsx)(`p`,{className:`mt-4 text-sm text-tertiary-light`,children:t(f.SETTINGS$APPS_ADD_MODAL_INTRO)})]}),(0,V.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto px-6 custom-scrollbar`,children:[(0,V.jsx)(x,{testId:`add-canvas-extension-source-input`,label:t(f.SETTINGS$APPS_SOURCE_LABEL),type:`text`,value:r,onChange:i,placeholder:t(f.SETTINGS$PLUGINS_SOURCE_PLACEHOLDER),showRequiredTag:!0}),(0,V.jsx)(x,{testId:`add-canvas-extension-ref-input`,label:t(f.SETTINGS$PLUGINS_REF_LABEL),type:`text`,value:o,onChange:s,showOptionalTag:!0}),(0,V.jsx)(x,{testId:`add-canvas-extension-repo-path-input`,label:t(f.SETTINGS$PLUGINS_REPO_PATH_LABEL),type:`text`,value:c,onChange:l,showOptionalTag:!0})]}),(0,V.jsxs)(`footer`,{className:`flex flex-shrink-0 justify-end gap-2 px-6 pb-6 pt-4`,children:[(0,V.jsx)(y,{type:`button`,variant:`secondary`,onClick:e,testId:`add-canvas-extension-dismiss`,children:t(f.BUTTON$CLOSE)}),(0,V.jsx)(y,{type:`submit`,variant:`primary`,testId:`add-canvas-extension-submit`,isDisabled:!d,children:t(n.isPending?f.SETTINGS$PLUGINS_INSTALLING:f.SETTINGS$PLUGINS_INSTALL)})]})]})})}function U({extension:e,isBusy:t,onToggle:n,onUninstall:r}){let{t:i}=a(`openhands`),o=e.manifest?.contributes?.pages??[],s=e.manifest?.display_name||e.name;return(0,V.jsxs)(`article`,{"data-testid":`canvas-extension-card-${e.name}`,className:`flex min-w-0 flex-col gap-4 p-4 ${O}`,children:[(0,V.jsxs)(`header`,{className:`flex items-start justify-between gap-4`,children:[(0,V.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,V.jsx)(`h3`,{className:`truncate text-sm font-semibold text-white`,children:s}),(0,V.jsx)(`p`,{className:`mt-0.5 truncate text-xs text-tertiary-alt`,children:e.source})]}),(0,V.jsx)(C,{enabled:e.enabled,label:i(e.enabled?f.COMMON$DISABLE:f.COMMON$ENABLE),onToggle:n,className:t?`pointer-events-none opacity-50`:void 0})]}),e.description||e.manifest?.description?(0,V.jsx)(`p`,{className:`text-xs leading-relaxed text-tertiary-light`,children:e.description||e.manifest?.description}):null,(0,V.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,V.jsx)(`span`,{className:k,children:e.enabled?i(f.SETTINGS$SKILLS_ENABLED):i(f.SETTINGS$SKILLS_DISABLED)}),(0,V.jsx)(`span`,{className:k,children:i(f.SETTINGS$SKILLS_VERSION,{version:e.version})}),o.length?(0,V.jsxs)(`span`,{className:k,children:[i(f.SETTINGS$APPS_PAGES),`: `,o.length]}):null]}),(0,V.jsxs)(`dl`,{className:`grid min-w-0 grid-cols-[auto_1fr] gap-x-3 gap-y-1 text-xs`,children:[e.resolved_ref?(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(`dt`,{className:`text-tertiary-alt`,children:i(f.SETTINGS$PLUGINS_REF_LABEL)}),(0,V.jsx)(`dd`,{className:`min-w-0 truncate font-mono text-tertiary-light`,children:e.resolved_ref})]}):null,e.repo_path?(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(`dt`,{className:`text-tertiary-alt`,children:i(f.SETTINGS$PLUGINS_REPO_PATH_LABEL)}),(0,V.jsx)(`dd`,{className:`min-w-0 truncate text-tertiary-light`,children:e.repo_path})]}):null]}),o.length?(0,V.jsx)(`section`,{className:`flex min-w-0 flex-col gap-2`,children:(0,V.jsx)(`ul`,{className:`flex flex-wrap gap-2`,children:o.map(e=>(0,V.jsx)(`li`,{className:k,children:e.title},e.id))})}):null,(0,V.jsx)(`footer`,{className:`flex justify-end gap-2 border-t border-[var(--oh-border)] pt-3`,children:(0,V.jsx)(y,{type:`button`,variant:`ghost-danger`,testId:`canvas-extension-uninstall-${e.name}`,isDisabled:t,onClick:r,children:i(f.SETTINGS$PLUGINS_UNINSTALL)})})]})}var W=`https://docs.openhands.dev/openhands/usage/agent-canvas/canvas-extensions`,G=r(function(){let{t:e}=a(`openhands`),{backend:t}=u(),[n,r]=I.useState(!1),[i,o]=I.useState(null),s=D(),c=z(),l=B(),d=!m(t)&&t.kind===`local`,_=!d||w(s.error),v=c.isPending||l.isPending,b=()=>{i&&(i.type===`enable`?c.mutate({name:i.extension.name,enabled:!0},{onSuccess:()=>o(null)}):l.mutate(i.extension.name,{onSuccess:()=>o(null)}))},x=i?i.extension.manifest?.display_name||i.extension.name:``,C=i?.type===`enable`?e(f.SETTINGS$APPS_ENABLE_CONFIRM):i?.type===`uninstall`?e(f.SETTINGS$APPS_UNINSTALL_CONFIRM,{name:x}):``;return(0,V.jsxs)(`div`,{"data-testid":`canvas-extensions-screen`,className:`flex h-full gap-4 md:gap-6 md:pl-8 lg:gap-10 lg:pl-10`,children:[(0,V.jsx)(h,{}),(0,V.jsx)(`main`,{className:p(F,`h-full`),children:(0,V.jsxs)(`div`,{className:`mx-auto flex w-full min-w-0 max-w-[800px] flex-col gap-6`,children:[(0,V.jsxs)(`div`,{className:`flex min-w-0 items-start justify-between gap-4`,children:[(0,V.jsxs)(`div`,{className:`min-w-0 space-y-1`,children:[(0,V.jsx)(`h2`,{className:`text-xl font-semibold leading-6 text-foreground`,children:e(f.SETTINGS$APPS_PAGE_TITLE)}),(0,V.jsx)(`p`,{className:`max-w-2xl text-sm text-tertiary-light`,children:e(f.SETTINGS$APPS_PAGE_DESCRIPTION)}),(0,V.jsxs)(`a`,{href:W,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1 text-sm text-primary hover:underline`,children:[e(f.SETTINGS$APPS_BUILD_LINK),(0,V.jsx)(g,{className:`size-3.5`,"aria-hidden":!0})]})]}),(0,V.jsx)(y,{type:`button`,variant:`secondary`,testId:`canvas-extensions-add-button`,isDisabled:!d||_||s.isLoading,className:`flex-shrink-0 whitespace-nowrap`,onClick:()=>r(!0),children:e(f.SETTINGS$APPS_ADD_BUTTON)})]}),(0,V.jsx)(`div`,{className:`rounded-xl border border-amber-400/30 bg-amber-400/5 px-4 py-3 text-sm text-amber-100`,children:e(f.SETTINGS$APPS_TRUST_NOTICE)}),(0,V.jsx)(`h3`,{className:`text-base font-semibold text-foreground`,children:e(f.SETTINGS$APPS_INSTALLED)}),_?(0,V.jsxs)(`div`,{className:j,children:[(0,V.jsx)(`h3`,{className:`text-sm font-semibold text-white`,children:e(f.SETUP$UNAVAILABLE_TITLE)}),(0,V.jsx)(`p`,{className:`mt-2 text-sm text-tertiary-light`,children:w(s.error)?s.error.message:t.kind===`cloud`?new E(`cloud-backend`).message:new E(`no-backend`).message})]}):s.isLoading?(0,V.jsx)(`div`,{className:`flex flex-col gap-4`,children:[1,2].map(e=>(0,V.jsx)(`div`,{className:`h-40 animate-pulse rounded-xl bg-base-secondary`},e))}):s.isError?(0,V.jsxs)(`div`,{className:j,children:[(0,V.jsx)(`p`,{className:`text-sm text-tertiary-light`,children:s.error instanceof Error?s.error.message:e(f.ERROR$GENERIC)}),(0,V.jsx)(y,{type:`button`,variant:`secondary`,className:`mt-4`,onClick:()=>void s.refetch(),children:e(f.AUTOMATIONS$ERROR_RETRY)})]}):s.data?.length?(0,V.jsx)(`div`,{className:A,children:(0,V.jsx)(`div`,{className:M,children:s.data.map(e=>(0,V.jsx)(U,{extension:e,isBusy:v,onToggle:()=>{e.enabled?c.mutate({name:e.name,enabled:!1}):o({type:`enable`,extension:e})},onUninstall:()=>o({type:`uninstall`,extension:e})},e.name))})}):(0,V.jsx)(`div`,{className:j,children:(0,V.jsx)(`p`,{className:`text-sm text-tertiary-light`,children:e(f.SETTINGS$APPS_EMPTY)})})]})}),n?(0,V.jsx)(H,{onClose:()=>r(!1)}):null,i?(0,V.jsx)(S,{text:C,onCancel:()=>o(null),onConfirm:b,confirmText:i.type===`enable`?e(f.SETTINGS$APPS_ENABLE_ACTION):void 0,isConfirming:v}):null]})});export{G as default};
|