@openhands/agent-canvas 1.0.0-rc.6 → 1.0.0-rc.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -3
- package/README.windows.md +2 -2
- package/build/assets/{QueryClientProvider-2bFjjuvv.js → QueryClientProvider-XcSjsfpb.js} +1 -1
- package/build/assets/{Trans-D1xHkKyr.js → Trans-sy4l4TyQ.js} +1 -1
- package/build/assets/{acp-providers-Djbp2WMV.js → acp-providers-BqUvf67Q.js} +1 -1
- package/build/assets/{active-backend-context-BiVlte2V.js → active-backend-context-CNF2lPkA.js} +1 -1
- package/build/assets/add-backend-modal-BywVr6uq.js +1 -0
- package/build/assets/{agent-server-adapter-BD6kvwWb.js → agent-server-adapter-k8veH-1O.js} +1 -1
- package/build/assets/{agent-server-conversation-service.api-8AC86rC5.js → agent-server-conversation-service.api-CGbkhsLj.js} +1 -1
- package/build/assets/{agent-settings-DycVwGfd.js → agent-settings-DoHXHcoA.js} +1 -1
- package/build/assets/{alert-banner-BUqPui_3.js → alert-banner-Bsvys-hT.js} +1 -1
- package/build/assets/{analytics-consent-form-modal-CdP5JRph.js → analytics-consent-form-modal-CVhsAREx.js} +1 -1
- package/build/assets/{api-key-entry-screen-BnvQM0v5.js → api-key-entry-screen-Dnr5TcV0.js} +1 -1
- package/build/assets/{app-settings-FRYUtG-Z.js → app-settings-Bgm2-yOM.js} +1 -1
- package/build/assets/{automation-detail-DiIq3Vsh.js → automation-detail-86M_yMqz.js} +1 -1
- package/build/assets/{automations-list-DQn7k1Ix.js → automations-list-BWUILrqY.js} +1 -1
- package/build/assets/{back-nav-button-B8eULM4t.js → back-nav-button-D20Avel_.js} +1 -1
- package/build/assets/{backend-form-modal-DY3My0us.js → backend-form-modal-Dl29wkF5.js} +1 -1
- package/build/assets/{backend-synced-settings-badge-BW2WPX-c.js → backend-synced-settings-badge-Dcd4712m.js} +1 -1
- package/build/assets/{base-modal-B_MCb3rx.js → base-modal-DvuGYyu1.js} +1 -1
- package/build/assets/{brand-button-B6g_UvEG.js → brand-button-9SOzmqPP.js} +1 -1
- package/build/assets/{browser-tab-DVHx54yn.js → browser-tab-bveyJhG9.js} +1 -1
- package/build/assets/{chat-send-button-Ce9rK8Vd.js → chat-send-button-BhoO7T0s.js} +1 -1
- package/build/assets/{checkmark-BQIxLn5W.js → checkmark--JWAesua.js} +1 -1
- package/build/assets/{circle-plus-check-toggle-DRwQ4Z7K.js → circle-plus-check-toggle-AO9DWyDX.js} +1 -1
- package/build/assets/{close-HybccyBS.js → close--W-tHn1h.js} +1 -1
- package/build/assets/{code-tag-DZCEX2zo.js → code-tag-chmctf4w.js} +1 -1
- package/build/assets/{combobox-caret-kEa3kTvf.js → combobox-caret-C9BNHfSu.js} +1 -1
- package/build/assets/{condenser-settings-BlbT8YRd.js → condenser-settings-DgQ0rsAf.js} +1 -1
- package/build/assets/{confirmation-modal-CG_Fgrny.js → confirmation-modal-Cq3eqvqH.js} +1 -1
- package/build/assets/{context-menu-list-item-CvJv3-kq.js → context-menu-list-item-BQU0jZPq.js} +1 -1
- package/build/assets/conversation-CayU5Lrr.js +19 -0
- package/build/assets/conversation-erinyBqT.js +1 -0
- package/build/assets/conversation-panel-DiI4q-8-.js +1 -0
- package/build/assets/{conversation-service.api-CngSQhPh.js → conversation-service.api-shHWtFwu.js} +1 -1
- package/build/assets/{conversation-tab-empty-state-B5eOSEGv.js → conversation-tab-empty-state-C8tztloo.js} +1 -1
- package/build/assets/{copy-D6CyDz2n.js → copy-CdKN5rtJ.js} +1 -1
- package/build/assets/{declaration-BDfM67Kl.js → declaration-D9ucT0fq.js} +1 -1
- package/build/assets/{device-verify-CAevP6_3.js → device-verify-YuGXnpRk.js} +1 -1
- package/build/assets/{dropdown-classes-CL8egwz_.js → dropdown-classes-CVp0kVdt.js} +1 -1
- package/build/assets/{edit-automation-modal-CwLfhSMN.js → edit-automation-modal-8y9Uctxo.js} +1 -1
- package/build/assets/{ellipsis-button-Db-AwbLv.js → ellipsis-button-k7HLwYth.js} +1 -1
- package/build/assets/{entry.client-BKDpKmdB.js → entry.client-D_wtryHT.js} +2 -2
- package/build/assets/{enum-filter-dropdown-DnYXhc1E.js → enum-filter-dropdown-COqUq3mB.js} +1 -1
- package/build/assets/{environment-switch-overlay-BgYKFdf6.js → environment-switch-overlay-wB5LxfYZ.js} +1 -1
- package/build/assets/{extensions-hub-CgisT2wb.js → extensions-hub-CoWO3SzQ.js} +1 -1
- package/build/assets/{extensions-navigation-nurGkQe5.js → extensions-navigation-D5w2sFQe.js} +1 -1
- package/build/assets/{files-tab-DIyAYvp0.js → files-tab-CxdtgkIe.js} +1 -1
- package/build/assets/{files-tab-store-RScGdwu8.js → files-tab-store-DSKUhziI.js} +1 -1
- package/build/assets/{folder-IChmji2Y.js → folder-DPTBlxWb.js} +1 -1
- package/build/assets/home-3joHMYSR.js +1 -0
- package/build/assets/{install-server-modal-C8fylTet.js → install-server-modal-_7l1gcjd.js} +1 -1
- package/build/assets/{launch-BNiqgTvz.js → launch-fU77utLO.js} +1 -1
- package/build/assets/{lesson-plan-BdmMvboE.js → lesson-plan-CHGc-B8Y.js} +1 -1
- package/build/assets/{lightbulb-DzViGAuw.js → lightbulb-S616sGEL.js} +1 -1
- package/build/assets/{link-external-Dwv3oQAx.js → link-external-ooNztGLp.js} +1 -1
- package/build/assets/llm-not-configured-banner-BMGzpBPV.js +27 -0
- package/build/assets/llm-settings-BRotm_g6.js +1 -0
- package/build/assets/{llm-settings-B92l1Z2N.js → llm-settings-yDgbXP6Q.js} +1 -1
- package/build/assets/{loading-spinner-Dtm7y-w5.js → loading-spinner-D7bOU6I7.js} +1 -1
- package/build/assets/{manage-backends-modal-qpq2M_oN.js → manage-backends-modal-tfdzTXWU.js} +1 -1
- package/build/assets/{manifest-05156141.js → manifest-bbc1374e.js} +1 -1
- package/build/assets/{markdown-renderer-Dt0RXhUJ.js → markdown-renderer-z446oW0Z.js} +1 -1
- package/build/assets/{mcp-BKdD21xY.js → mcp-Dopstf0t.js} +1 -1
- package/build/assets/{messages-Ch8Rd1cx.js → messages-CsFUrAen.js} +1 -1
- package/build/assets/{modal-backdrop-DmDLoot0.js → modal-backdrop-_VbcKk5K.js} +1 -1
- package/build/assets/{modal-body-BWjhfiSa.js → modal-body-Cd-PtMHr.js} +1 -1
- package/build/assets/{modal-classes-DbJbhQCW.js → modal-classes-CNm4ovfm.js} +1 -1
- package/build/assets/{modal-close-button-DXN6uYvt.js → modal-close-button-Dbo0NAMt.js} +1 -1
- package/build/assets/{model-selector-BMn4D5v6.js → model-selector-sioC8xP4.js} +1 -1
- package/build/assets/{navigation-context-BrRCrWhm.js → navigation-context-BpAOh_t5.js} +1 -1
- package/build/assets/{navigation-link-qUrH_I5_.js → navigation-link-Dci7Nuyf.js} +1 -1
- package/build/assets/{onboarding-B50IeNyy.js → onboarding-CQh50i2z.js} +1 -1
- package/build/assets/{openhands-logo-DnfHAq7Y.js → openhands-logo-Dzm-d_V_.js} +1 -1
- package/build/assets/{option-service.api-lzN_3s9w.js → option-service.api-DjPvPAtd.js} +1 -1
- package/build/assets/{organization-service.api-CNmSPGj4.js → organization-service.api-BNc9Kn6n.js} +1 -1
- package/build/assets/{path-utils-CKgIQZAY.js → path-utils-YlkpoImJ.js} +1 -1
- package/build/assets/{plan-components-D9fU4FFh.js → plan-components-CutRBi0G.js} +1 -1
- package/build/assets/{planner-tab-B7kpsTT8.js → planner-tab-DjIFIQDk.js} +1 -1
- package/build/assets/{providers-189W9TJO.js → providers-BiWSYwRT.js} +1 -1
- package/build/assets/{query-client-config-B9ZI-1_w.js → query-client-config-Ca3tW1AH.js} +1 -1
- package/build/assets/{recommended-automations-launcher-C_RcP2yb.js → recommended-automations-launcher-DCi0RXIj.js} +1 -1
- package/build/assets/{root-CFnl2e43.js → root-DrHpnAqU.js} +2 -2
- package/build/assets/{root-layout-BQGwrist.js → root-layout-Cf7FC9DC.js} +2 -2
- package/build/assets/{runtime-waiting-state-DPjfE32a.js → runtime-waiting-state-8i0Z3A_i.js} +1 -1
- package/build/assets/{sdk-section-page-ozvrzW4r.js → sdk-section-page-COlGKv4E.js} +1 -1
- package/build/assets/{sdk-settings-schema-Ck6f2ON9.js → sdk-settings-schema-Big50zDH.js} +1 -1
- package/build/assets/{search-aDWSdSb7.js → search-C_l_XW4e.js} +1 -1
- package/build/assets/{secrets-settings-Bga0bwB1.js → secrets-settings-DYfTc5c8.js} +1 -1
- package/build/assets/{settings-DHAhcPm2.js → settings-DRmVFdOc.js} +1 -1
- package/build/assets/{settings-dropdown-input-N0FtDFkk.js → settings-dropdown-input-BP-arqjU.js} +1 -1
- package/build/assets/{settings-gear-D8ao16bi.js → settings-gear-f-zWpxfI.js} +1 -1
- package/build/assets/{settings-index-CJvQH5ls.js → settings-index-B035V2pu.js} +1 -1
- package/build/assets/{settings-input-CyWJBrqC.js → settings-input-BM8ANxDb.js} +1 -1
- package/build/assets/{settings-list-classes-CYRnRf8r.js → settings-list-classes-B9uo5WES.js} +1 -1
- package/build/assets/{settings-modal-BeAlR7Be.js → settings-modal-CeRvS5Bc.js} +1 -1
- package/build/assets/{settings-section-header-context-1fN7Xkb3.js → settings-section-header-context-Cid25HM2.js} +1 -1
- package/build/assets/{settings-switch-D3aEIphL.js → settings-switch-xa6q4M6j.js} +1 -1
- package/build/assets/{shared-conversation-CtRf6CQN.js → shared-conversation-CBbpyPaD.js} +1 -1
- package/build/assets/{sidebar-mobile-menu-toggle-DkYaKR6Q.js → sidebar-mobile-menu-toggle-SKcwsEtD.js} +1 -1
- package/build/assets/{sidebar-nav-link-CzeuB4So.js → sidebar-nav-link-CPWuQ_c6.js} +1 -1
- package/build/assets/{skill-card-pill-row-CvLCLqqD.js → skill-card-pill-row-DeodrwPG.js} +1 -1
- package/build/assets/{skills-jKeJCunm.js → skills-BE5HJuGM.js} +1 -1
- package/build/assets/{skills-plugins-juwPhlEE.js → skills-plugins-Dc4ec3CW.js} +1 -1
- package/build/assets/{skills-settings-BW09n_Px.js → skills-settings-B6HwvA0S.js} +1 -1
- package/build/assets/{styled-tooltip-B3wz8m5E.js → styled-tooltip-X61SEwqk.js} +1 -1
- package/build/assets/{suspense-BpkWt-39.js → suspense-Bqb0V0q1.js} +1 -1
- package/build/assets/{switch-skeleton-Cl_Nh2kt.js → switch-skeleton-BbIWemkK.js} +1 -1
- package/build/assets/{task-list-tab-DKnHShLG.js → task-list-tab-BFnyHGsn.js} +1 -1
- package/build/assets/{telemetry-Ca_YAGcO.js → telemetry-DCFAqpIA.js} +1 -1
- package/build/assets/{terminal-BFi5FOMc.js → terminal-B92mACR5.js} +1 -1
- package/build/assets/{terminal-CZH2h1J3.js → terminal-CltMeLv4.js} +1 -1
- package/build/assets/{toggle-switch-BzaEofjj.js → toggle-switch-CL_wRiGs.js} +1 -1
- package/build/assets/{typography-BFj4IzMj.js → typography-BLSEGjph.js} +1 -1
- package/build/assets/{u-check-circle-Cs2GOrZ7.js → u-check-circle-dG_VJqx5.js} +1 -1
- package/build/assets/{u-check-circle-half-DGgLKVV1.js → u-check-circle-half-D-5ZPRnd.js} +1 -1
- package/build/assets/{u-circuit-DniZPNAV.js → u-circuit-BXoisXOA.js} +1 -1
- package/build/assets/{u-edit-BvTiDr33.js → u-edit-DIgADxLH.js} +1 -1
- package/build/assets/{use-acp-credential-form-8yHKY_py.js → use-acp-credential-form-LjCIhMSK.js} +1 -1
- package/build/assets/{use-active-conversation-CLzls6XV.js → use-active-conversation-B0_rXnqa.js} +1 -1
- package/build/assets/{use-agent-settings-schema-BCXxH2N-.js → use-agent-settings-schema-D8x5LJVS.js} +1 -1
- package/build/assets/{use-agent-state-BocVPR5S.js → use-agent-state-BuOzLeFN.js} +1 -1
- package/build/assets/{use-cloud-current-user-id-BjDwnldw.js → use-cloud-current-user-id-DVZXa_WH.js} +1 -1
- package/build/assets/use-config-5zEjywCL.js +1 -0
- package/build/assets/{use-create-conversation-CIkPp9u9.js → use-create-conversation-pV2eA-e9.js} +1 -1
- package/build/assets/{use-create-secret-Bwy6457V.js → use-create-secret-ClPpLBgD.js} +1 -1
- package/build/assets/{use-handle-plan-click-CjNwpDeO.js → use-handle-plan-click-CwN_nNib.js} +1 -1
- package/build/assets/use-is-authed-B8eLO-Xq.js +1 -0
- package/build/assets/{use-launch-skill-in-chat-QmcJQxUY.js → use-launch-skill-in-chat-BTgXIu3N.js} +1 -1
- package/build/assets/{use-llm-profiles-CZD1ALup.js → use-llm-profiles-CWLfWjav.js} +1 -1
- package/build/assets/use-runtime-is-ready-Bbory9-s.js +1 -0
- package/build/assets/{use-save-settings-BjYPOrtF.js → use-save-settings-Xp8DD-jf.js} +1 -1
- package/build/assets/{use-settings-YTDcMvj1.js → use-settings-0SeqaDeW.js} +1 -1
- package/build/assets/{use-settings-nav-items-DMit9adK.js → use-settings-nav-items-DVrMNk0I.js} +1 -1
- package/build/assets/{use-skills-fh_U4ZGe.js → use-skills-Bv8LXrys.js} +1 -1
- package/build/assets/{use-tracking-DJ3Z7ha1.js → use-tracking-BhyV5A9i.js} +1 -1
- package/build/assets/{use-user-conversation-Ct93yaXj.js → use-user-conversation-6yFVEXiG.js} +1 -1
- package/build/assets/{useMutation-B1gQr_yr.js → useMutation-Dm84WAKR.js} +1 -1
- package/build/assets/{useQuery-CbqdITLM.js → useQuery-DGRSm7IT.js} +1 -1
- package/build/assets/{useTranslation-C-T8J2U-.js → useTranslation-CL6FTf1b.js} +1 -1
- package/build/assets/{utils-CXRkUr73.js → utils-eXk6yerZ.js} +1 -1
- package/build/assets/{vendor~conversation-panel~conversation-CkFCLbQW.js → vendor~conversation-panel~conversation-D98u43rl.js} +1 -1
- package/build/assets/{vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-C1BmvJX4.js → vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-Dqpi2xyZ.js} +1 -1
- package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~bok0tgtf-RuHTcYaf.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~bok0tgtf-7eqKdLSQ.js} +1 -1
- package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~bok0tgtf-B04AZhMW.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~bok0tgtf-BP3MGAAY.js} +1 -1
- package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~ceijy54y-D7ZsdcLa.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~ceijy54y-Dkd2wxJA.js} +1 -1
- package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~launch~skills-settings~mcp~automati~dou5smdo-DH07jaIY.js → vendor~root-layout~home~conversation-panel~conversation~launch~skills-settings~mcp~automati~dou5smdo-DavKsAvB.js} +186 -40
- package/build/assets/{vendor~root-layout~home~mcp~automations-list-COlx7Is6.js → vendor~root-layout~home~mcp~automations-list-D40jgugf.js} +1 -1
- package/build/assets/{vendor~root-layout~home~mcp~llm-settings~agent-settings~condenser-settings~verification-set~o7tv66sg-DuiHR4ce.js → vendor~root-layout~home~mcp~llm-settings~agent-settings~condenser-settings~verification-set~o7tv66sg-BIm99UaF.js} +1 -1
- package/build/assets/{vendor~root-layout~home~mcp~llm-settings~agent-settings~condenser-settings~verification-set~o7tv66sg-4yr76Evz.js → vendor~root-layout~home~mcp~llm-settings~agent-settings~condenser-settings~verification-set~o7tv66sg-xCM3k6Rd.js} +1 -1
- package/build/assets/{verification-settings-CeIuPtF2.js → verification-settings-Be6NxjuT.js} +1 -1
- package/build/assets/{x-mark-BMhi11Sg.js → x-mark-C42svtnu.js} +1 -1
- package/build/index.html +4 -4
- package/build/locales/ar/openhands.json +45 -40
- package/build/locales/ca/openhands.json +41 -36
- package/build/locales/de/openhands.json +42 -37
- package/build/locales/en/openhands.json +6 -1
- package/build/locales/es/openhands.json +44 -39
- package/build/locales/fr/openhands.json +44 -39
- package/build/locales/it/openhands.json +44 -39
- package/build/locales/ja/openhands.json +44 -39
- package/build/locales/ko-KR/openhands.json +44 -39
- package/build/locales/no/openhands.json +44 -39
- package/build/locales/pt/openhands.json +44 -39
- package/build/locales/tr/openhands.json +43 -38
- package/build/locales/uk/openhands.json +44 -39
- package/build/locales/zh-CN/openhands.json +44 -39
- package/build/locales/zh-TW/openhands.json +44 -39
- package/config/defaults.json +9 -4
- 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 +1 -1
- package/dist/components/features/backends/backend-form-modal.js.map +1 -1
- package/dist/components/features/chat/chat-interface.cjs +1 -1
- package/dist/components/features/chat/chat-interface.cjs.map +1 -1
- package/dist/components/features/chat/chat-interface.js +1 -1
- package/dist/components/features/chat/chat-interface.js.map +1 -1
- package/dist/components/features/chat/git-control-bar.cjs +1 -1
- package/dist/components/features/chat/git-control-bar.cjs.map +1 -1
- package/dist/components/features/chat/git-control-bar.js +1 -1
- package/dist/components/features/chat/git-control-bar.js.map +1 -1
- package/dist/components/features/chat/open-repository-modal.cjs +1 -1
- package/dist/components/features/chat/open-repository-modal.cjs.map +1 -1
- package/dist/components/features/chat/open-repository-modal.js +0 -3
- package/dist/components/features/chat/open-repository-modal.js.map +1 -1
- package/dist/components/features/chat/pending-user-messages.cjs +1 -1
- package/dist/components/features/chat/pending-user-messages.cjs.map +1 -1
- package/dist/components/features/chat/pending-user-messages.js +31 -28
- package/dist/components/features/chat/pending-user-messages.js.map +1 -1
- package/dist/components/features/home/git-branch-dropdown/git-branch-dropdown.cjs +1 -1
- package/dist/components/features/home/git-branch-dropdown/git-branch-dropdown.cjs.map +1 -1
- package/dist/components/features/home/git-branch-dropdown/git-branch-dropdown.js +79 -77
- package/dist/components/features/home/git-branch-dropdown/git-branch-dropdown.js.map +1 -1
- package/dist/components/features/home/git-provider-dropdown/git-provider-dropdown.cjs +1 -1
- package/dist/components/features/home/git-provider-dropdown/git-provider-dropdown.cjs.map +1 -1
- package/dist/components/features/home/git-provider-dropdown/git-provider-dropdown.js +67 -65
- package/dist/components/features/home/git-provider-dropdown/git-provider-dropdown.js.map +1 -1
- package/dist/components/features/home/git-repo-dropdown/git-repo-dropdown.cjs +1 -1
- package/dist/components/features/home/git-repo-dropdown/git-repo-dropdown.cjs.map +1 -1
- package/dist/components/features/home/git-repo-dropdown/git-repo-dropdown.js +2 -2
- package/dist/components/features/home/git-repo-dropdown/git-repo-dropdown.js.map +1 -1
- package/dist/components/features/settings/settings-navigation.cjs +1 -1
- package/dist/components/features/settings/settings-navigation.cjs.map +1 -1
- package/dist/components/features/settings/settings-navigation.js +1 -1
- package/dist/components/features/settings/settings-navigation.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 +3 -2
- package/dist/components/features/sidebar/sidebar.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 +6 -1
- 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 +612 -527
- package/dist/i18n/translation.js.map +1 -1
- package/dist/locales/ar/openhands.json +45 -40
- package/dist/locales/ca/openhands.json +41 -36
- package/dist/locales/de/openhands.json +42 -37
- package/dist/locales/en/openhands.json +6 -1
- package/dist/locales/es/openhands.json +44 -39
- package/dist/locales/fr/openhands.json +44 -39
- package/dist/locales/it/openhands.json +44 -39
- package/dist/locales/ja/openhands.json +44 -39
- package/dist/locales/ko-KR/openhands.json +44 -39
- package/dist/locales/no/openhands.json +44 -39
- package/dist/locales/pt/openhands.json +44 -39
- package/dist/locales/tr/openhands.json +43 -38
- package/dist/locales/uk/openhands.json +44 -39
- package/dist/locales/zh-CN/openhands.json +44 -39
- package/dist/locales/zh-TW/openhands.json +44 -39
- package/dist/node_modules/@openhands/extensions/skills/index.cjs +186 -40
- package/dist/node_modules/@openhands/extensions/skills/index.cjs.map +1 -1
- package/dist/node_modules/@openhands/extensions/skills/index.js +2 -2
- package/dist/node_modules/@openhands/extensions/skills/index.js.map +1 -1
- package/dist/package.cjs +1 -1
- package/dist/package.cjs.map +1 -1
- package/dist/package.js +2 -2
- package/dist/package.js.map +1 -1
- package/package.json +2 -2
- package/scripts/check-sdk-version-sync.mjs +6 -6
- package/scripts/check-translation-completeness.cjs +149 -59
- package/scripts/dev-safe.mjs +1 -1
- package/build/assets/add-backend-modal-CSfOPrnr.js +0 -1
- package/build/assets/conversation-B7ztPdyS.js +0 -1
- package/build/assets/conversation-DZYd8QiZ.js +0 -19
- package/build/assets/conversation-panel-CklMXcs6.js +0 -1
- package/build/assets/home-iVOrSOWL.js +0 -1
- package/build/assets/llm-not-configured-banner-BQgVTo0O.js +0 -27
- package/build/assets/llm-settings-ICWFhhjM.js +0 -1
- package/build/assets/use-config-C4DX1-nF.js +0 -1
- package/build/assets/use-is-authed-7P3xSsit.js +0 -1
- package/build/assets/use-runtime-is-ready-B7sbw-q5.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-BDfM67Kl.js";import{t as i}from"./useTranslation-C-T8J2U-.js";import{g as a,m as o,p as s}from"./query-client-config-B9ZI-1_w.js";import{t as c}from"./utils-CXRkUr73.js";import{c as l,g as u,m as d,t as ee}from"./brand-button-B6g_UvEG.js";import{t as f}from"./vendor~root-layout~home~conversation-panel~conversation~launch~extensions-hub~skills-settin~bxn4ldi1-_LydBB1e.js";import{n as p,t as m}from"./settings-input-CyWJBrqC.js";import{r as te}from"./use-settings-YTDcMvj1.js";import{t as ne}from"./use-save-settings-BjYPOrtF.js";import{a as re,c as ie,d as h,l as ae,n as oe,o as se,r as ce,s as le,t as ue}from"./sdk-settings-schema-Ck6f2ON9.js";import{n as de,t as fe}from"./use-agent-settings-schema-BCXxH2N-.js";import{n as g,t as _}from"./switch-skeleton-Cl_Nh2kt.js";import{o as pe}from"./extension-module-card-classes-DP5J6ngE.js";import{i as v,n as y,r as b,t as x}from"./sdk-settings-field-metadata-p2GVlft7.js";import{t as S}from"./settings-dropdown-input-N0FtDFkk.js";import{t as C}from"./settings-switch-D3aEIphL.js";import{r as w}from"./typography-BFj4IzMj.js";var T=e(t(),1),E=n();function D(){return(0,E.jsx)(`div`,{className:`w-[250px] h-[20px] skeleton`})}function O(){return(0,E.jsxs)(`div`,{"data-testid":`app-settings-skeleton`,className:`px-11 py-9 flex flex-col gap-6`,children:[(0,E.jsx)(_,{}),(0,E.jsx)(g,{}),(0,E.jsx)(g,{}),(0,E.jsx)(g,{}),(0,E.jsx)(D,{}),(0,E.jsx)(_,{}),(0,E.jsx)(_,{}),(0,E.jsx)(g,{})]})}var k={"llm.api_key":{textKey:`SCHEMA$LLM$API_KEY$HELP_TEXT`,linkTextKey:`SCHEMA$LLM$API_KEY$HELP_LINK_TEXT`,href:`https://docs.openhands.dev/usage/local-setup#getting-an-api-key`},"verification.critic_api_key":{textKey:`SCHEMA$VERIFICATION$CRITIC_API_KEY$HELP_TEXT`,linkTextKey:`SETTINGS$NAV_API_KEYS`,suffixKey:`SCHEMA$VERIFICATION$CRITIC_API_KEY$HELP_SUFFIX`,href:`https://app.all-hands.dev/settings/api-keys`,hideDescription:!0}},me=new Set([`verification.critic_api_key`]);function A({field:e}){let{t}=i(`openhands`),n=k[e.key],r=b(t,e.key,e.description);return(0,E.jsxs)(E.Fragment,{children:[r&&!n?.hideDescription?(0,E.jsx)(w.Paragraph,{className:`text-tertiary-alt text-xs leading-5`,children:r}):null,n?(0,E.jsx)(h,{testId:`help-link-${e.key}`,text:t(n.textKey),linkText:t(n.linkTextKey),href:n.href,suffix:n.suffixKey?` ${t(n.suffixKey)}`:void 0,size:`settings`,linkColor:`white`}):null]})}function j(e){return e.choices.length>0}function M(e){return e.value_type===`boolean`&&!j(e)}function N(e){return e.value_type===`array`||e.value_type===`object`}function P(e){return e.key.endsWith(`url`)||e.key.endsWith(`_url`)}function F(e){return e.secret?`password`:e.value_type===`integer`||e.value_type===`number`?`number`:e.value_type===`string`&&P(e)?`url`:`text`}function he({field:e,value:t,isDisabled:n,onChange:r}){let{t:a}=i(`openhands`),o=v(a,e.key,e.label),s=x(e.key);return M(e)?(0,E.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,E.jsx)(C,{testId:`sdk-settings-${e.key}`,isToggled:!!t,isDisabled:n,onToggle:r,children:o}),(0,E.jsx)(`div`,{className:d,children:(0,E.jsx)(A,{field:e})})]}):j(e)?(0,E.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,E.jsx)(S,{testId:`sdk-settings-${e.key}`,name:e.key,label:o,items:e.choices.map(t=>({key:String(t.value),label:y(a,e.key,t.value,t.label)})),selectedKey:t===``?void 0:String(t),isClearable:!e.required,required:e.required,showOptionalTag:!e.required,isDisabled:n,onSelectionChange:e=>r(String(e??``))}),(0,E.jsx)(A,{field:e})]}):N(e)?(0,E.jsxs)(`label`,{className:`flex flex-col gap-2.5 w-full`,children:[(0,E.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,E.jsx)(`span`,{className:`text-sm`,children:o}),e.required?null:(0,E.jsx)(p,{})]}),(0,E.jsx)(`textarea`,{"data-testid":`sdk-settings-${e.key}`,name:e.key,value:String(t??``),required:e.required,disabled:n,onChange:e=>r(e.target.value),className:c(l,`min-h-32 font-mono placeholder:italic`,`disabled:bg-[var(--oh-surface-raised)] disabled:border-[var(--oh-border-subtle)]`)}),(0,E.jsx)(A,{field:e})]}):(0,E.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,E.jsx)(m,{testId:`sdk-settings-${e.key}`,name:e.key,label:o,type:F(e),value:String(t??``),required:e.required,showOptionalTag:!e.required,isDisabled:n,onChange:r,className:`w-full`,min:s?.min,max:s?.max,step:s?.step}),(0,E.jsx)(A,{field:e})]})}var I=(e,t)=>c(`w-fit px-2 py-2 text-sm cursor-pointer rounded-none bg-transparent`,u,`border-b-2 pb-2`,e?`text-white border-white`:`text-[var(--oh-muted)] border-transparent hover:text-white`,t&&`pointer-events-none opacity-30 cursor-not-allowed`);function ge({view:e,setView:t,showAdvanced:n,showAll:a,isDisabled:o=!1}){let{t:s}=i(`openhands`);return!n&&!a?null:(0,E.jsxs)(`div`,{role:`tablist`,"aria-orientation":`horizontal`,className:`mb-6 flex items-center gap-2`,children:[(0,E.jsx)(`button`,{"data-testid":`sdk-section-basic-toggle`,type:`button`,role:`tab`,"aria-selected":e===`basic`,disabled:o,className:I(e===`basic`,o),onClick:()=>t(`basic`),children:s(r.SETTINGS$BASIC)}),n?(0,E.jsx)(`button`,{"data-testid":`sdk-section-advanced-toggle`,type:`button`,role:`tab`,"aria-selected":e===`advanced`,disabled:o,className:I(e===`advanced`,o),onClick:()=>t(`advanced`),children:s(r.SETTINGS$ADVANCED)}):null,a?(0,E.jsx)(`button`,{"data-testid":`sdk-section-all-toggle`,type:`button`,role:`tab`,"aria-selected":e===`all`,disabled:o,className:I(e===`all`,o),onClick:()=>t(`all`),children:s(r.SETTINGS$ALL)}):null]})}var _e=new Set,L={basic:0,advanced:1,all:2},ve=(e,t)=>L[t]<L[e]?t:e,ye=(e,t)=>L[t]>L[e]?t:e,be=(e,{showAdvanced:t,showAll:n})=>e===`all`?n?`all`:t?`advanced`:`basic`:e===`advanced`?t?`advanced`:n?`all`:`basic`:`basic`,xe={agent_settings:`agent_settings_diff`,conversation_settings:`conversation_settings_diff`},Se=(e,t)=>e instanceof f?e.response?.status===401?`${t} This agent server requires X-Session-API-Key. Set VITE_SESSION_API_KEY in the frontend to the same value used by the backend SESSION_API_KEY or OH_SESSION_API_KEYS_0.`:e.response?.status===404?`${t} This backend does not expose /api/settings/* schema endpoints. Upgrade to a recent openhands-agent-server release.`:t:t;function R({settingsSources:e,scope:t=`personal`,header:n,extraDirty:c=!1,buildPayload:l,onSaveSuccess:u,getInitialView:d,forceShowAdvancedView:f=!1,allowAllView:p=!0,initialValueOverrides:m,embedded:h=!1,hideSaveButton:g=!1,suppressSuccessToast:_=!1,onSaveControlChange:v,testId:y=`sdk-section-settings-screen`}){let{t:b}=i(`openhands`),{mutate:x,isPending:S}=ne(t),{data:C,isLoading:w,isFetching:D}=te(t),k=fe(C?.agent_settings_schema),A=de(C?.conversation_settings_schema),j=T.useMemo(()=>JSON.stringify(e.map(e=>({source:e.settingsSource,sectionKeys:e.sectionKeys,excludeKeys:e.excludeKeys?Array.from(e.excludeKeys).sort():null}))),[e]),M=T.useMemo(()=>JSON.parse(j).map(e=>({settingsSource:e.source,sectionKeys:e.sectionKeys,excludeKeys:e.excludeKeys?new Set(e.excludeKeys):void 0})),[j]),N=T.useCallback(e=>e===`conversation_settings`?A.data:k.data,[k.data,A.data]),P=M.some(e=>e.settingsSource===`conversation_settings`?A.isLoading:k.isLoading),F=T.useMemo(()=>M.map(e=>{let t=N(e.settingsSource);if(!ae(t))return{...e,filteredSchema:null};let n=new Set(e.sectionKeys),r={...t,sections:t.sections.filter(e=>n.has(e.key))};return{...e,filteredSchema:r}}),[M,N]),I=f||F.some(e=>se(e.filteredSchema)),L=p&&F.some(e=>le(e.filteredSchema)),R=T.useMemo(()=>Se(M.reduce((e,t)=>e??(t.settingsSource===`conversation_settings`?A.error:k.error),null),b(r.SETTINGS$SDK_SCHEMA_UNAVAILABLE)),[M,k.error,A.error,b]),Ce=T.useMemo(()=>m?JSON.stringify(m):``,[m]),[z,B]=T.useState(`basic`),[V,H]=T.useState({}),[U,W]=T.useState({}),G=T.useRef(!1),K=T.useMemo(()=>{if(!C)return null;let e={};for(let t of F){if(!t.filteredSchema)return null;e[t.settingsSource]={...e[t.settingsSource]??{},...ue(C,t.filteredSchema,t.settingsSource)}}if(m){let t=F[0]?.settingsSource;t&&e[t]&&(e[t]={...e[t],...m})}return e},[C,F,Ce]),q=T.useMemo(()=>{if(!C)return null;let e=null;for(let t of F){if(!t.filteredSchema)return null;let n=d?d(C,t.filteredSchema):ie(C,t.filteredSchema,t.settingsSource);e=e?ye(e,n):n}return e?be(e,{showAdvanced:I,showAll:L}):null},[C,F,d,I,L]);T.useEffect(()=>{G.current=!1,B(`basic`),H({}),W({})},[t,j]),T.useEffect(()=>{if(!(!K||!q)){if(H(K),m){let e=F[0]?.settingsSource;if(e){let t=Object.fromEntries(Object.keys(m).map(e=>[e,!0]));W({[e]:t})}else W({})}else W({});B(e=>G.current?ve(e,q):(G.current=!0,q))}},[K,q]);let J=T.useMemo(()=>{let e=new Map;for(let t of F)if(t.filteredSchema)for(let n of t.filteredSchema.sections)for(let r of n.fields)e.has(r.key)||e.set(r.key,t.settingsSource);return e},[F]),Y=T.useMemo(()=>{let e={};for(let t of F)Object.assign(e,V[t.settingsSource]??{});return e},[F,V]),X=T.useMemo(()=>{let e={};for(let t of F)Object.assign(e,U[t.settingsSource]??{});return e},[F,U]),Z=T.useCallback((e,t)=>{let n=J.get(e);n&&(H(r=>({...r,[n]:{...r[n]??{},[e]:t}})),W(t=>({...t,[n]:{...t[n]??{},[e]:!0}})))},[J]),we=T.useCallback(e=>{s(a(e)||b(r.ERROR$GENERIC))},[b]),Q=T.useRef(()=>{}),Te=T.useCallback(()=>{Q.current()},[]),$=T.useRef(()=>({})),Ee=T.useCallback(()=>$.current(),[]),De=()=>{if(F.some(e=>!e.filteredSchema))return;let e;try{let t={};for(let e of F){let n=e.filteredSchema,r=ce(n,V[e.settingsSource]??{},U[e.settingsSource]??{},z);if(Object.keys(r).length>0){let n=xe[e.settingsSource];t[n]={...t[n]??{},...r}}}e=l?l(t,{values:Y,dirty:X,view:z}):t}catch(e){s(e instanceof Error?e.message:b(r.ERROR$GENERIC));return}Object.keys(e).length!==0&&x(e,{onError:we,onSuccess:()=>{_||o(b(r.SETTINGS$SAVED_WARNING)),W({}),u?.()}})};Q.current=De,$.current=()=>{let e={};for(let t of F){if(!t.filteredSchema)continue;let n=V[t.settingsSource]??{},r=U[t.settingsSource]??{};Object.assign(e,oe(t.filteredSchema,n,r))}return e};let Oe=Object.keys(X).length>0,ke=Oe||c;return T.useEffect(()=>{v&&v({save:Te,isSaving:S,isDirty:ke,values:Y,view:z,getDirtyPayload:Ee})},[S,ke,Y,z]),(w||D)&&!C||P?(0,E.jsx)(O,{}):F.some(e=>e.filteredSchema&&e.filteredSchema.sections.length>0)?Object.keys(Y).length===0?(0,E.jsx)(O,{}):(0,E.jsxs)(`div`,{"data-testid":y,className:h?`relative flex min-h-0 w-full flex-1 flex-col`:`relative w-full min-h-0`,children:[(0,E.jsx)(ge,{view:z,setView:B,showAdvanced:I,showAll:L,isDisabled:!1}),(0,E.jsxs)(`div`,{className:`flex flex-col gap-8`,children:[n?.({values:Y,isDisabled:!1,view:z,onChange:Z}),F.map(e=>{if(!e.filteredSchema)return null;let t=V[e.settingsSource]??{};return re(e.filteredSchema,{...Y,...t},z,e.excludeKeys??_e).map(n=>(0,E.jsx)(`section`,{className:`flex flex-col gap-4`,children:(0,E.jsx)(`div`,{className:`grid gap-4 xl:grid-cols-2`,children:n.fields.map(e=>(0,E.jsx)(`div`,{className:me.has(e.key)?`xl:col-span-2`:void 0,children:(0,E.jsx)(he,{field:e,value:t[e.key],isDisabled:!1,onChange:t=>Z(e.key,t)})},e.key))})},`${e.settingsSource}:${n.key}`))}),g?null:(0,E.jsx)(`div`,{className:`flex justify-start pt-2`,children:(0,E.jsx)(ee,{testId:`save-button`,type:`button`,variant:`primary`,isDisabled:S||!Oe&&!c,onClick:De,children:b(S?r.SETTINGS$SAVING:r.SETTINGS$SAVE_CHANGES)})})]})]}):(0,E.jsx)(`div`,{"data-testid":`sdk-schema-unavailable`,className:pe,children:(0,E.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:R})})}export{R as t};
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{g as a,m as o,p as s}from"./query-client-config-Ca3tW1AH.js";import{t as c}from"./utils-eXk6yerZ.js";import{c as l,g as u,m as d,t as ee}from"./brand-button-9SOzmqPP.js";import{t as f}from"./vendor~root-layout~home~conversation-panel~conversation~launch~extensions-hub~skills-settin~bxn4ldi1-_LydBB1e.js";import{n as p,t as m}from"./settings-input-BM8ANxDb.js";import{r as te}from"./use-settings-0SeqaDeW.js";import{t as ne}from"./use-save-settings-Xp8DD-jf.js";import{a as re,c as ie,d as h,l as ae,n as oe,o as se,r as ce,s as le,t as ue}from"./sdk-settings-schema-Big50zDH.js";import{n as de,t as fe}from"./use-agent-settings-schema-D8x5LJVS.js";import{n as g,t as _}from"./switch-skeleton-BbIWemkK.js";import{o as pe}from"./extension-module-card-classes-DP5J6ngE.js";import{i as v,n as y,r as b,t as x}from"./sdk-settings-field-metadata-p2GVlft7.js";import{t as S}from"./settings-dropdown-input-BP-arqjU.js";import{t as C}from"./settings-switch-xa6q4M6j.js";import{r as w}from"./typography-BLSEGjph.js";var T=e(t(),1),E=n();function D(){return(0,E.jsx)(`div`,{className:`w-[250px] h-[20px] skeleton`})}function O(){return(0,E.jsxs)(`div`,{"data-testid":`app-settings-skeleton`,className:`px-11 py-9 flex flex-col gap-6`,children:[(0,E.jsx)(_,{}),(0,E.jsx)(g,{}),(0,E.jsx)(g,{}),(0,E.jsx)(g,{}),(0,E.jsx)(D,{}),(0,E.jsx)(_,{}),(0,E.jsx)(_,{}),(0,E.jsx)(g,{})]})}var k={"llm.api_key":{textKey:`SCHEMA$LLM$API_KEY$HELP_TEXT`,linkTextKey:`SCHEMA$LLM$API_KEY$HELP_LINK_TEXT`,href:`https://docs.openhands.dev/usage/local-setup#getting-an-api-key`},"verification.critic_api_key":{textKey:`SCHEMA$VERIFICATION$CRITIC_API_KEY$HELP_TEXT`,linkTextKey:`SETTINGS$NAV_API_KEYS`,suffixKey:`SCHEMA$VERIFICATION$CRITIC_API_KEY$HELP_SUFFIX`,href:`https://app.all-hands.dev/settings/api-keys`,hideDescription:!0}},me=new Set([`verification.critic_api_key`]);function A({field:e}){let{t}=i(`openhands`),n=k[e.key],r=b(t,e.key,e.description);return(0,E.jsxs)(E.Fragment,{children:[r&&!n?.hideDescription?(0,E.jsx)(w.Paragraph,{className:`text-tertiary-alt text-xs leading-5`,children:r}):null,n?(0,E.jsx)(h,{testId:`help-link-${e.key}`,text:t(n.textKey),linkText:t(n.linkTextKey),href:n.href,suffix:n.suffixKey?` ${t(n.suffixKey)}`:void 0,size:`settings`,linkColor:`white`}):null]})}function j(e){return e.choices.length>0}function M(e){return e.value_type===`boolean`&&!j(e)}function N(e){return e.value_type===`array`||e.value_type===`object`}function P(e){return e.key.endsWith(`url`)||e.key.endsWith(`_url`)}function F(e){return e.secret?`password`:e.value_type===`integer`||e.value_type===`number`?`number`:e.value_type===`string`&&P(e)?`url`:`text`}function he({field:e,value:t,isDisabled:n,onChange:r}){let{t:a}=i(`openhands`),o=v(a,e.key,e.label),s=x(e.key);return M(e)?(0,E.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,E.jsx)(C,{testId:`sdk-settings-${e.key}`,isToggled:!!t,isDisabled:n,onToggle:r,children:o}),(0,E.jsx)(`div`,{className:d,children:(0,E.jsx)(A,{field:e})})]}):j(e)?(0,E.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,E.jsx)(S,{testId:`sdk-settings-${e.key}`,name:e.key,label:o,items:e.choices.map(t=>({key:String(t.value),label:y(a,e.key,t.value,t.label)})),selectedKey:t===``?void 0:String(t),isClearable:!e.required,required:e.required,showOptionalTag:!e.required,isDisabled:n,onSelectionChange:e=>r(String(e??``))}),(0,E.jsx)(A,{field:e})]}):N(e)?(0,E.jsxs)(`label`,{className:`flex flex-col gap-2.5 w-full`,children:[(0,E.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,E.jsx)(`span`,{className:`text-sm`,children:o}),e.required?null:(0,E.jsx)(p,{})]}),(0,E.jsx)(`textarea`,{"data-testid":`sdk-settings-${e.key}`,name:e.key,value:String(t??``),required:e.required,disabled:n,onChange:e=>r(e.target.value),className:c(l,`min-h-32 font-mono placeholder:italic`,`disabled:bg-[var(--oh-surface-raised)] disabled:border-[var(--oh-border-subtle)]`)}),(0,E.jsx)(A,{field:e})]}):(0,E.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,E.jsx)(m,{testId:`sdk-settings-${e.key}`,name:e.key,label:o,type:F(e),value:String(t??``),required:e.required,showOptionalTag:!e.required,isDisabled:n,onChange:r,className:`w-full`,min:s?.min,max:s?.max,step:s?.step}),(0,E.jsx)(A,{field:e})]})}var I=(e,t)=>c(`w-fit px-2 py-2 text-sm cursor-pointer rounded-none bg-transparent`,u,`border-b-2 pb-2`,e?`text-white border-white`:`text-[var(--oh-muted)] border-transparent hover:text-white`,t&&`pointer-events-none opacity-30 cursor-not-allowed`);function ge({view:e,setView:t,showAdvanced:n,showAll:a,isDisabled:o=!1}){let{t:s}=i(`openhands`);return!n&&!a?null:(0,E.jsxs)(`div`,{role:`tablist`,"aria-orientation":`horizontal`,className:`mb-6 flex items-center gap-2`,children:[(0,E.jsx)(`button`,{"data-testid":`sdk-section-basic-toggle`,type:`button`,role:`tab`,"aria-selected":e===`basic`,disabled:o,className:I(e===`basic`,o),onClick:()=>t(`basic`),children:s(r.SETTINGS$BASIC)}),n?(0,E.jsx)(`button`,{"data-testid":`sdk-section-advanced-toggle`,type:`button`,role:`tab`,"aria-selected":e===`advanced`,disabled:o,className:I(e===`advanced`,o),onClick:()=>t(`advanced`),children:s(r.SETTINGS$ADVANCED)}):null,a?(0,E.jsx)(`button`,{"data-testid":`sdk-section-all-toggle`,type:`button`,role:`tab`,"aria-selected":e===`all`,disabled:o,className:I(e===`all`,o),onClick:()=>t(`all`),children:s(r.SETTINGS$ALL)}):null]})}var _e=new Set,L={basic:0,advanced:1,all:2},ve=(e,t)=>L[t]<L[e]?t:e,ye=(e,t)=>L[t]>L[e]?t:e,be=(e,{showAdvanced:t,showAll:n})=>e===`all`?n?`all`:t?`advanced`:`basic`:e===`advanced`?t?`advanced`:n?`all`:`basic`:`basic`,xe={agent_settings:`agent_settings_diff`,conversation_settings:`conversation_settings_diff`},Se=(e,t)=>e instanceof f?e.response?.status===401?`${t} This agent server requires X-Session-API-Key. Set VITE_SESSION_API_KEY in the frontend to the same value used by the backend SESSION_API_KEY or OH_SESSION_API_KEYS_0.`:e.response?.status===404?`${t} This backend does not expose /api/settings/* schema endpoints. Upgrade to a recent openhands-agent-server release.`:t:t;function R({settingsSources:e,scope:t=`personal`,header:n,extraDirty:c=!1,buildPayload:l,onSaveSuccess:u,getInitialView:d,forceShowAdvancedView:f=!1,allowAllView:p=!0,initialValueOverrides:m,embedded:h=!1,hideSaveButton:g=!1,suppressSuccessToast:_=!1,onSaveControlChange:v,testId:y=`sdk-section-settings-screen`}){let{t:b}=i(`openhands`),{mutate:x,isPending:S}=ne(t),{data:C,isLoading:w,isFetching:D}=te(t),k=fe(C?.agent_settings_schema),A=de(C?.conversation_settings_schema),j=T.useMemo(()=>JSON.stringify(e.map(e=>({source:e.settingsSource,sectionKeys:e.sectionKeys,excludeKeys:e.excludeKeys?Array.from(e.excludeKeys).sort():null}))),[e]),M=T.useMemo(()=>JSON.parse(j).map(e=>({settingsSource:e.source,sectionKeys:e.sectionKeys,excludeKeys:e.excludeKeys?new Set(e.excludeKeys):void 0})),[j]),N=T.useCallback(e=>e===`conversation_settings`?A.data:k.data,[k.data,A.data]),P=M.some(e=>e.settingsSource===`conversation_settings`?A.isLoading:k.isLoading),F=T.useMemo(()=>M.map(e=>{let t=N(e.settingsSource);if(!ae(t))return{...e,filteredSchema:null};let n=new Set(e.sectionKeys),r={...t,sections:t.sections.filter(e=>n.has(e.key))};return{...e,filteredSchema:r}}),[M,N]),I=f||F.some(e=>se(e.filteredSchema)),L=p&&F.some(e=>le(e.filteredSchema)),R=T.useMemo(()=>Se(M.reduce((e,t)=>e??(t.settingsSource===`conversation_settings`?A.error:k.error),null),b(r.SETTINGS$SDK_SCHEMA_UNAVAILABLE)),[M,k.error,A.error,b]),Ce=T.useMemo(()=>m?JSON.stringify(m):``,[m]),[z,B]=T.useState(`basic`),[V,H]=T.useState({}),[U,W]=T.useState({}),G=T.useRef(!1),K=T.useMemo(()=>{if(!C)return null;let e={};for(let t of F){if(!t.filteredSchema)return null;e[t.settingsSource]={...e[t.settingsSource]??{},...ue(C,t.filteredSchema,t.settingsSource)}}if(m){let t=F[0]?.settingsSource;t&&e[t]&&(e[t]={...e[t],...m})}return e},[C,F,Ce]),q=T.useMemo(()=>{if(!C)return null;let e=null;for(let t of F){if(!t.filteredSchema)return null;let n=d?d(C,t.filteredSchema):ie(C,t.filteredSchema,t.settingsSource);e=e?ye(e,n):n}return e?be(e,{showAdvanced:I,showAll:L}):null},[C,F,d,I,L]);T.useEffect(()=>{G.current=!1,B(`basic`),H({}),W({})},[t,j]),T.useEffect(()=>{if(!(!K||!q)){if(H(K),m){let e=F[0]?.settingsSource;if(e){let t=Object.fromEntries(Object.keys(m).map(e=>[e,!0]));W({[e]:t})}else W({})}else W({});B(e=>G.current?ve(e,q):(G.current=!0,q))}},[K,q]);let J=T.useMemo(()=>{let e=new Map;for(let t of F)if(t.filteredSchema)for(let n of t.filteredSchema.sections)for(let r of n.fields)e.has(r.key)||e.set(r.key,t.settingsSource);return e},[F]),Y=T.useMemo(()=>{let e={};for(let t of F)Object.assign(e,V[t.settingsSource]??{});return e},[F,V]),X=T.useMemo(()=>{let e={};for(let t of F)Object.assign(e,U[t.settingsSource]??{});return e},[F,U]),Z=T.useCallback((e,t)=>{let n=J.get(e);n&&(H(r=>({...r,[n]:{...r[n]??{},[e]:t}})),W(t=>({...t,[n]:{...t[n]??{},[e]:!0}})))},[J]),we=T.useCallback(e=>{s(a(e)||b(r.ERROR$GENERIC))},[b]),Q=T.useRef(()=>{}),Te=T.useCallback(()=>{Q.current()},[]),$=T.useRef(()=>({})),Ee=T.useCallback(()=>$.current(),[]),De=()=>{if(F.some(e=>!e.filteredSchema))return;let e;try{let t={};for(let e of F){let n=e.filteredSchema,r=ce(n,V[e.settingsSource]??{},U[e.settingsSource]??{},z);if(Object.keys(r).length>0){let n=xe[e.settingsSource];t[n]={...t[n]??{},...r}}}e=l?l(t,{values:Y,dirty:X,view:z}):t}catch(e){s(e instanceof Error?e.message:b(r.ERROR$GENERIC));return}Object.keys(e).length!==0&&x(e,{onError:we,onSuccess:()=>{_||o(b(r.SETTINGS$SAVED_WARNING)),W({}),u?.()}})};Q.current=De,$.current=()=>{let e={};for(let t of F){if(!t.filteredSchema)continue;let n=V[t.settingsSource]??{},r=U[t.settingsSource]??{};Object.assign(e,oe(t.filteredSchema,n,r))}return e};let Oe=Object.keys(X).length>0,ke=Oe||c;return T.useEffect(()=>{v&&v({save:Te,isSaving:S,isDirty:ke,values:Y,view:z,getDirtyPayload:Ee})},[S,ke,Y,z]),(w||D)&&!C||P?(0,E.jsx)(O,{}):F.some(e=>e.filteredSchema&&e.filteredSchema.sections.length>0)?Object.keys(Y).length===0?(0,E.jsx)(O,{}):(0,E.jsxs)(`div`,{"data-testid":y,className:h?`relative flex min-h-0 w-full flex-1 flex-col`:`relative w-full min-h-0`,children:[(0,E.jsx)(ge,{view:z,setView:B,showAdvanced:I,showAll:L,isDisabled:!1}),(0,E.jsxs)(`div`,{className:`flex flex-col gap-8`,children:[n?.({values:Y,isDisabled:!1,view:z,onChange:Z}),F.map(e=>{if(!e.filteredSchema)return null;let t=V[e.settingsSource]??{};return re(e.filteredSchema,{...Y,...t},z,e.excludeKeys??_e).map(n=>(0,E.jsx)(`section`,{className:`flex flex-col gap-4`,children:(0,E.jsx)(`div`,{className:`grid gap-4 xl:grid-cols-2`,children:n.fields.map(e=>(0,E.jsx)(`div`,{className:me.has(e.key)?`xl:col-span-2`:void 0,children:(0,E.jsx)(he,{field:e,value:t[e.key],isDisabled:!1,onChange:t=>Z(e.key,t)})},e.key))})},`${e.settingsSource}:${n.key}`))}),g?null:(0,E.jsx)(`div`,{className:`flex justify-start pt-2`,children:(0,E.jsx)(ee,{testId:`save-button`,type:`button`,variant:`primary`,isDisabled:S||!Oe&&!c,onClick:De,children:b(S?r.SETTINGS$SAVING:r.SETTINGS$SAVE_CHANGES)})})]})]}):(0,E.jsx)(`div`,{"data-testid":`sdk-schema-unavailable`,className:pe,children:(0,E.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:R})})}export{R as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./declaration-
|
|
1
|
+
import{o as e}from"./declaration-D9ucT0fq.js";import{t}from"./utils-eXk6yerZ.js";import{t as n}from"./dist-5dObF4p4.js";import{t as r}from"./sdk-settings-field-metadata-p2GVlft7.js";var i=e(),a=n(``,{variants:{size:{default:`text-xs`,settings:`text-sm text-[var(--oh-muted)] font-normal leading-5.5`},linkColor:{default:``,white:`text-white`}},defaultVariants:{size:`default`,linkColor:`default`}});function o({testId:e,text:n,linkText:r,href:o,suffix:s,size:c,linkColor:l,className:u,linkTextClassName:d,suffixClassName:f}){return(0,i.jsxs)(`p`,{"data-testid":e,className:t(a({size:c}),u),children:[n,` `,(0,i.jsx)(`a`,{href:o,rel:`noreferrer noopener`,target:`_blank`,className:t(`underline underline-offset-2`,a({size:c,linkColor:l}),d),children:r}),s&&(0,i.jsx)(`span`,{className:f,children:s})]})}var s=new Set([`llm.model`,`llm.api_key`,`llm.base_url`]),c={basic:new Set([`critical`]),advanced:new Set([`critical`,`major`]),all:new Set([`critical`,`major`,`minor`])};function l(e){return!!e&&Array.isArray(e.sections)}function u(e){return l(e)?e.sections.flatMap(e=>e.fields):[]}function d(e,t){if(!e)return;let n=t.split(`.`),r=e;for(let e of n){if(typeof r!=`object`||!r)return;r=r[e]}return r}function f(e,t,n){let r=t.split(`.`),i=e;for(let e=0;e<r.length-1;e+=1){let t=r[e];(i[t]==null||typeof i[t]!=`object`||Array.isArray(i[t]))&&(i[t]={}),i=i[t]}i[r[r.length-1]]=n}function p(e,t,n=`agent_settings`){return d(e[n],t)??null}function m(e,t){return p(e,t,`agent_settings`)}function h(e){return e.choices.length>0}function g(e){return e.prominence===`critical`}function _(e){return e.prominence===`minor`}function v(e,t){let n=t??e.default;return h(e)?n==null?``:String(n):e.value_type===`boolean`?!!(n??!1):n==null?``:e.value_type===`array`||e.value_type===`object`?JSON.stringify(n,null,2):String(n)}function y(e,t){if(t===void 0)return null;if(e.value_type===`boolean`){if(typeof t==`string`){if(t===`true`)return!0;if(t===`false`)return!1}return t===null?null:!!t}if(e.value_type===`integer`||e.value_type===`number`){if(t===``||t===null)return null;let e=typeof t==`number`?t:Number(String(t));return Number.isNaN(e)?null:e}if(e.value_type===`array`||e.value_type===`object`){if(t===null||e.value_type===`object`&&typeof t==`object`&&!Array.isArray(t)&&Object.keys(t).length===0)return null;if(typeof t==`string`){let n=t.trim();if(!n)return null;try{let t=JSON.parse(n);return e.value_type===`object`&&typeof t==`object`&&t&&!Array.isArray(t)&&Object.keys(t).length===0?null:JSON.stringify(t)}catch{return n}}return JSON.stringify(t)}return t===null?null:String(t)}function b(e,t,n=`agent_settings`){let r=t??(n===`conversation_settings`?e.conversation_settings_schema:e.agent_settings_schema);return r?Object.fromEntries(u(r).map(t=>[t.key,v(t,p(e,t.key,n))])):{}}function x(e,t,n=`agent_settings`){let r=t??(n===`conversation_settings`?e.conversation_settings_schema:e.agent_settings_schema);if(!r)return`basic`;let i=!1,a=!1;for(let t of u(r))g(t)||y(t,p(e,t.key,n)??t.default??null)!==y(t,t.default??null)&&(_(t)?i=!0:a=!0);return i?`all`:a?`advanced`:`basic`}function S(e,t){return e.depends_on.every(e=>t[e]===!0)}function C(e){if(typeof e==`boolean`)return e;let t=e.trim().toLowerCase();if(!t)return null;if(t===`true`)return!0;if(t===`false`)return!1;throw Error(`Expected a boolean value, received: ${e}`)}function w(e,t){if(e.value_type===`boolean`)return C(t);if(e.value_type===`integer`||e.value_type===`number`){let n=String(t).trim();if(!n)return null;let i=Number(n);if(Number.isNaN(i))throw Error(`Expected a numeric value, received: ${n}`);if(e.value_type===`integer`&&!Number.isInteger(i))throw Error(`Expected an integer value, received: ${n}`);let a=r(e.key);if(a?.min!=null&&i<a.min)throw Error(`${e.label} must be at least ${a.min}`);if(a?.max!=null&&i>a.max)throw Error(`${e.label} must be at most ${a.max}`);return i}if(e.value_type===`array`||e.value_type===`object`){let n=String(t).trim();if(!n)return null;let r;try{r=JSON.parse(n)}catch{throw Error(`Invalid JSON for ${e.label}`)}if(e.value_type===`array`){if(!Array.isArray(r))throw Error(`${e.label} must be a JSON array`);return r}if(r===null||Array.isArray(r)||typeof r!=`object`)throw Error(`${e.label} must be a JSON object`);return r}let n=String(t);return n===``&&!e.secret?null:n}function T(e,t,n){let r={};for(let i of u(e))n[i.key]&&f(r,i.key,w(i,t[i.key]));return r}function E(e,t){return c[t].has(e.prominence)}function D(e,t,n,r){let i=T(e,t,n);for(let t of u(e))E(t,r)||f(i,t.key,t.default??null);return i}function O(e,t,n,r=s){return l(e)?e.sections.map(e=>({...e,fields:e.fields.filter(e=>!r.has(e.key)&&E(e,n)&&S(e,t))})).filter(e=>e.fields.length>0):[]}function k(e){return e?u(e).some(e=>e.prominence===`major`):!1}function A(e){return e?u(e).some(e=>e.prominence===`minor`):!1}export{O as a,x as c,o as d,m as i,l,T as n,k as o,D as r,A as s,b as t,v as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-
|
|
1
|
+
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-D9ucT0fq.js";e();var n=t(),r=e=>(0,n.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,strokeWidth:2,...e,children:(0,n.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,d:`M21 21l-4.35-4.35M11 19a8 8 0 100-16 8 8 0 000 16z`})});export{r as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{L as n}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{t as r}from"./useMutation-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{L as n}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{t as r}from"./useMutation-Dm84WAKR.js";import{o as i,t as a}from"./declaration-D9ucT0fq.js";import{n as o}from"./QueryClientProvider-XcSjsfpb.js";import{t as s}from"./useTranslation-CL6FTf1b.js";import{t as c}from"./back-nav-button-D20Avel_.js";import{t as l}from"./pencil-DPEtl5QD.js";import{t as u}from"./trash-2-C-RvV8WA.js";import{t as d}from"./utils-eXk6yerZ.js";import{c as f,d as p,t as m}from"./brand-button-9SOzmqPP.js";import{t as h}from"./loading-spinner-D7bOU6I7.js";import{n as g,t as _}from"./settings-input-BM8ANxDb.js";import{t as v}from"./confirmation-modal-Cq3eqvqH.js";import"./extension-module-card-classes-DP5J6ngE.js";import{r as y}from"./typography-BLSEGjph.js";import{a as b,c as x,i as S,l as C,o as w,r as T,s as E}from"./settings-list-classes-B9uo5WES.js";import{t as D}from"./secrets-service-D6Gcymcs.js";import{n as O,t as k}from"./use-create-secret-ClPpLBgD.js";var A=e(t(),1),j=()=>r({mutationFn:e=>D.deleteSecret(e)}),M=()=>r({mutationFn:({secretToEdit:e,name:t,description:n})=>D.updateSecret(e,t,n)}),N=i();function P({mode:e,selectedSecret:t,onCancel:n}){let r=o(),{t:i}=s(`openhands`),{data:c}=O(),{mutate:l}=k(),{mutate:u}=M(),[h,v]=A.useState(null),y=e===`edit`&&t&&c?.find(e=>e.name===t)?.description?.trim()||``,b=()=>{r.invalidateQueries({queryKey:[`secrets-search`]}),r.invalidateQueries({queryKey:[`secrets`]})},x=(e,t,r)=>{l({name:e,value:t,description:r},{onSettled:n,onSuccess:b})},S=(e,t,r)=>{u({secretToEdit:e,name:t,description:r},{onSettled:n,onSuccess:b})};return(0,N.jsxs)(`form`,{"data-testid":e===`add`?`add-secret-form`:`edit-secret-form`,onSubmit:n=>{n.preventDefault();let r=new FormData(n.currentTarget),o=r.get(`secret-name`)?.toString(),s=r.get(`secret-value`)?.toString().trim(),l=r.get(`secret-description`)?.toString();if(o){if(v(null),c?.some(e=>e.name===o&&e.name!==t)){v(i(a.SECRETS$SECRET_ALREADY_EXISTS));return}if(e===`add`){if(!s){v(i(a.SECRETS$SECRET_VALUE_REQUIRED));return}x(o,s,l||void 0)}else e===`edit`&&t&&S(t,o,l||void 0)}},className:`flex flex-col items-start gap-6`,children:[(0,N.jsx)(_,{testId:`name-input`,name:`secret-name`,type:`text`,label:`Name`,className:`w-full min-w-0`,required:!0,defaultValue:e===`edit`&&t?t:``,placeholder:i(a.SECRETS$API_KEY_EXAMPLE),pattern:`^[a-zA-Z][a-zA-Z0-9_]{0,63}$`,title:`Must start with a letter, contain only letters/numbers/underscores, and be 1-64 characters`}),h&&(0,N.jsx)(`p`,{className:`text-red-500 text-sm`,children:h}),e===`add`&&(0,N.jsxs)(`label`,{className:`flex flex-col gap-2.5 w-full min-w-0`,children:[(0,N.jsx)(`span`,{className:`text-sm`,children:i(a.FORM$VALUE)}),(0,N.jsx)(`textarea`,{"data-testid":`value-input`,name:`secret-value`,required:!0,className:d(`resize-none`,f,`placeholder:italic`,`disabled:bg-[var(--oh-surface-raised)] disabled:border-[var(--oh-border-subtle)] disabled:cursor-not-allowed`),rows:8})]}),(0,N.jsxs)(`label`,{className:`flex flex-col gap-2.5 w-full min-w-0`,children:[(0,N.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,N.jsx)(`span`,{className:`text-sm`,children:i(a.FORM$DESCRIPTION)}),(0,N.jsx)(g,{})]}),(0,N.jsx)(`input`,{"data-testid":`description-input`,name:`secret-description`,defaultValue:y,className:d(p,`disabled:bg-[var(--oh-surface-raised)] disabled:border-[var(--oh-border-subtle)]`)})]}),(0,N.jsxs)(`div`,{className:`flex items-center gap-4`,children:[(0,N.jsx)(m,{testId:`cancel-button`,type:`button`,variant:`secondary`,onClick:n,children:i(a.BUTTON$CANCEL)}),(0,N.jsxs)(m,{testId:`submit-button`,type:`submit`,variant:`primary`,children:[e===`add`&&i(a.SECRETS$ADD_SECRET),e===`edit`&&i(a.SECRETS$EDIT_SECRET)]})]})]})}function F(){return(0,N.jsxs)(`div`,{className:d(S,`justify-between border-t border-[var(--oh-border)] first:border-t-0`),children:[(0,N.jsxs)(`div`,{className:`flex min-w-0 flex-1 items-center gap-4`,children:[(0,N.jsx)(`span`,{className:`skeleton h-4 w-1/4`}),(0,N.jsx)(`span`,{className:`skeleton h-4 w-1/2`})]}),(0,N.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,N.jsx)(`span`,{className:`skeleton h-4 w-4`}),(0,N.jsx)(`span`,{className:`skeleton h-4 w-4`})]})]})}function I({title:e,description:t,onEdit:n,onDelete:r}){return(0,N.jsxs)(`tr`,{"data-testid":`secret-item`,className:C,children:[(0,N.jsx)(`td`,{className:d(w,`text-content-2 truncate`),title:e,children:e}),(0,N.jsx)(`td`,{className:d(w,`truncate text-content-2 opacity-80`),title:t||``,children:t||``}),(0,N.jsx)(`td`,{className:w,children:(0,N.jsxs)(`div`,{className:`flex items-center justify-end gap-0.5`,children:[(0,N.jsx)(`button`,{"data-testid":`edit-secret-button`,type:`button`,onClick:n,"aria-label":`Edit ${e}`,className:T,children:(0,N.jsx)(l,{"aria-hidden":!0,className:`size-4`,strokeWidth:2})}),(0,N.jsx)(`button`,{"data-testid":`delete-secret-button`,type:`button`,onClick:r,"aria-label":`Delete ${e}`,className:T,children:(0,N.jsx)(u,{"aria-hidden":!0,className:`size-4`,strokeWidth:2})})]})})]})}var L={hideTitle:!0};function R(){let e=o(),{t}=s(`openhands`),n=(0,A.useRef)(null),{data:r,isLoading:i,hasNextPage:l,isFetchingNextPage:u,onLoadMore:f}=O(),{mutate:p}=j(),[g,_]=A.useState(`list`),[S,C]=A.useState(null),[w,T]=A.useState(!1),D=(0,A.useCallback)(e=>{let t=e.currentTarget;t.scrollHeight-t.scrollTop<=t.clientHeight+100&&l&&!u&&f()},[l,u,f]),k=()=>{e.invalidateQueries({queryKey:[`secrets-search`]}),e.invalidateQueries({queryKey:[`secrets`]})},M=e=>{p(e,{onSettled:()=>{T(!1)},onSuccess:k,onError:k})},L=()=>{S&&M(S)},R=()=>{T(!1)},z=()=>{_(`list`),C(null)},B=g===`add-secret-form`||g===`edit-secret-form`,V=t(g===`add-secret-form`?a.SECRETS$ADD_A_SECRET:a.SECRETS$EDIT_A_SECRET);return(0,N.jsxs)(`div`,{"data-testid":`secrets-settings-screen`,className:`flex flex-col gap-6`,children:[g===`list`?(0,N.jsxs)(`div`,{className:`flex items-start justify-between gap-4`,children:[(0,N.jsxs)(`div`,{className:`min-w-0 space-y-1`,children:[(0,N.jsx)(y.H2,{children:t(a.SETTINGS$NAV_SECRETS)}),(0,N.jsx)(`p`,{"data-testid":`settings-page-subtitle`,className:`text-sm leading-5 text-tertiary-light`,children:t(a.SETTINGS$PAGE_SECRETS_SUBLINE)})]}),(0,N.jsx)(m,{testId:`add-secret-button`,type:`button`,variant:`primary`,className:`shrink-0 whitespace-nowrap`,onClick:()=>_(`add-secret-form`),isDisabled:i,children:t(a.SECRETS$ADD_NEW_SECRET)})]}):null,B?(0,N.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,N.jsx)(c,{testId:`back-to-secrets`,onClick:z,children:t(a.BUTTON$BACK)}),(0,N.jsx)(y.H2,{testId:`secret-editor-title`,children:V})]}):null,i&&g===`list`&&(0,N.jsxs)(`ul`,{children:[(0,N.jsx)(F,{}),(0,N.jsx)(F,{}),(0,N.jsx)(F,{})]}),g===`list`&&!i&&r?.length===0&&(0,N.jsx)(`div`,{"data-testid":`secrets-empty`,className:`rounded-xl border border-[var(--oh-border)] p-8 text-center`,children:(0,N.jsx)(`p`,{className:`text-sm text-[var(--oh-muted)]`,children:t(a.SECRETS$EMPTY)})}),g===`list`&&!i&&(r?.length??0)>0&&(0,N.jsxs)(`div`,{ref:n,className:b,onScroll:D,children:[(0,N.jsxs)(`table`,{className:`w-full min-w-full table-fixed`,children:[(0,N.jsx)(`thead`,{className:E,children:(0,N.jsxs)(`tr`,{children:[(0,N.jsx)(`th`,{className:d(x,`w-1/4`),children:t(a.SETTINGS$NAME)}),(0,N.jsx)(`th`,{className:d(x,`w-1/2`),children:t(a.SECRETS$DESCRIPTION)}),(0,N.jsx)(`th`,{className:d(x,`w-1/4 text-right`),children:t(a.SETTINGS$ACTIONS)})]})}),(0,N.jsx)(`tbody`,{children:r?.map(e=>(0,N.jsx)(I,{title:e.name,description:e.description,onEdit:()=>{_(`edit-secret-form`),C(e.name)},onDelete:()=>{T(!0),C(e.name)}},e.name))})]}),u&&(0,N.jsx)(`div`,{className:`flex justify-center p-4`,children:(0,N.jsx)(h,{size:`small`})})]}),(g===`add-secret-form`||g===`edit-secret-form`)&&(0,N.jsx)(P,{mode:g===`add-secret-form`?`add`:`edit`,selectedSecret:S,onCancel:z}),w&&(0,N.jsx)(v,{text:t(a.SECRETS$CONFIRM_DELETE_KEY),onConfirm:L,onCancel:R})]})}var z=n(R);export{z as default,L as handle};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{E as n,L as r,c as i,j as a,k as o}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as s,t as c}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{E as n,L as r,c as i,j as a,k as o}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as s,t as c}from"./declaration-D9ucT0fq.js";import{t as l}from"./useTranslation-CL6FTf1b.js";import{r as u}from"./query-client-config-Ca3tW1AH.js";import{n as d,t as f}from"./use-settings-nav-items-DVrMNk0I.js";import{t as p}from"./utils-eXk6yerZ.js";import{a as m}from"./agent-server-client-options-B-C8JaTb.js";import{c as h,i as g,s as _}from"./active-backend-context-CNF2lPkA.js";import{t as v}from"./option-service.api-DjPvPAtd.js";import"./navigation-link-Dci7Nuyf.js";import"./use-cloud-current-user-id-DVZXa_WH.js";import{t as y}from"./sidebar-nav-link-CPWuQ_c6.js";import{n as b}from"./use-settings-0SeqaDeW.js";import"./close--W-tHn1h.js";import{r as x}from"./typography-BLSEGjph.js";import{t as S}from"./settings-section-header-context-Cid25HM2.js";import"./settings-gear-f-zWpxfI.js";import{n as C,r as w}from"./settings-utils--H_EvFjx.js";import{t as T}from"./use-breakpoint-DpxHDmuH.js";import{t as E}from"./backend-synced-settings-badge-Dcd4712m.js";import{t as D}from"./settings-like-page-layout-classes-C335ikW2.js";var O=e(t(),1),k=s();function A({navigationItems:e}){let{t}=l(`openhands`),n=e.filter(e=>e.type===`item`);return(0,k.jsxs)(`aside`,{"data-testid":`settings-navbar-desktop`,className:p(`hidden md:flex md:w-[260px] md:shrink-0 md:flex-col md:gap-2`,`md:sticky md:top-8 md:self-start md:pl-8`),children:[(0,k.jsx)(x.Text,{className:`px-2 text-sm font-normal text-white`,children:t(c.SETTINGS$TITLE)}),(0,k.jsx)(`div`,{className:`flex flex-col gap-0.5 pt-0.5`,children:n.map(e=>(0,k.jsx)(y,{to:e.item.to,label:t(e.item.text),end:!0,testId:`sidebar-settings-${e.item.to}`,icon:e.item.icon,disabled:e.disabled,disabledReason:e.disabled&&e.disabledAgentName?t(c.SETTINGS$AGENT_DISABLED_TOOLTIP,{agentName:e.disabledAgentName}):void 0},e.item.to))}),(0,k.jsx)(`div`,{className:`px-2 pt-3`,children:(0,k.jsx)(E,{})})]})}function j({children:e,navigationItems:t}){return(0,k.jsx)(`div`,{className:`flex h-full flex-col md:pt-8`,children:(0,k.jsxs)(`div`,{className:`flex min-h-0 flex-1 gap-10 md:items-start`,children:[(0,k.jsx)(A,{navigationItems:t}),(0,k.jsx)(`main`,{className:D,children:(0,k.jsx)(`div`,{className:`mx-auto w-full min-w-0 max-w-[800px]`,children:e})})]})})}async function M(){try{let e=m();if((await u.fetchQuery({queryKey:[...h.byScope(`personal`),e.backend.id,e.orgId],queryFn:()=>b(`personal`),staleTime:0}))?.agent_settings?.agent_kind===`acp`)return n(`/settings/agent`)}catch{}return null}var N=async({request:e})=>{let{pathname:t}=new URL(e.url),r=(await u.fetchQuery({queryKey:_.WEB_CLIENT_CONFIG,queryFn:v.getConfig,...g}))?.feature_flags;if(w(t,r)){let e=C(r);if(e&&e!==t)return n(e)}if(d.find(e=>e.to===t)?.disabledByAcp){let e=await M();if(e)return e}return null};function P(){let{t:e}=l(`openhands`),t=o(),n=a(),r=f(),s=T(768),[c,u]=(0,O.useState)(!1),{currentSectionTitle:d,currentSectionSubtitle:p}=(0,O.useMemo)(()=>{let e=r.find(e=>e.type===`item`&&e.item.to===t.pathname);if(e?.type===`item`)return{currentSectionTitle:e.item.text,currentSectionSubtitle:e.item.subtitle};let n=r.find(e=>e.type===`item`);return n?.type===`item`?{currentSectionTitle:n.item.text,currentSectionSubtitle:n.item.subtitle}:{currentSectionTitle:`SETTINGS$TITLE`,currentSectionSubtitle:null}},[r,t.pathname]),m=n.find(e=>e.pathname===t.pathname)?.handle,h=s&&t.pathname===`/settings`;return(0,k.jsx)(`main`,{"data-testid":`settings-screen`,className:`min-h-0`,children:(0,k.jsx)(S,{setHideSectionHeader:u,children:(0,k.jsx)(j,{navigationItems:r,children:(0,k.jsxs)(`div`,{className:`flex flex-col gap-6 pb-8`,children:[!(m?.hideTitle===!0||h||c)&&(0,k.jsxs)(`header`,{className:`space-y-1`,children:[(0,k.jsx)(x.H2,{children:e(d)}),p?(0,k.jsx)(`p`,{"data-testid":`settings-page-subtitle`,className:`text-sm leading-5 text-tertiary-light`,children:e(p)}):null]}),(0,k.jsx)(i,{})]})})})})}var F=r(P);export{N as clientLoader,F as default};
|
package/build/assets/{settings-dropdown-input-N0FtDFkk.js → settings-dropdown-input-BP-arqjU.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t,t as n}from"./declaration-
|
|
1
|
+
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t,t as n}from"./declaration-D9ucT0fq.js";import{t as r}from"./useTranslation-CL6FTf1b.js";import{t as i}from"./utils-eXk6yerZ.js";import{d as a}from"./brand-button-9SOzmqPP.js";import{n as o,t as s}from"./vendor~root-layout~home~mcp~llm-settings~agent-settings~condenser-settings~verification-set~o7tv66sg-BIm99UaF.js";import{i as c}from"./combobox-caret-C9BNHfSu.js";import{n as l}from"./settings-input-BM8ANxDb.js";e();var u=t();function d({testId:e,label:t,wrapperClassName:d,name:f,items:p,placeholder:m,showOptionalTag:h,isDisabled:g,isLoading:_,defaultSelectedKey:v,selectedKey:y,isClearable:b,allowsCustomValue:x,required:S,onSelectionChange:C,onInputChange:w,defaultFilter:T,startContent:E,inputWrapperClassName:D,inputClassName:O}){let{t:k}=r(`openhands`);return(0,u.jsxs)(`label`,{className:i(`flex flex-col gap-2.5 w-full min-w-0`,d),children:[t&&(0,u.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,u.jsx)(`span`,{className:`text-sm`,children:t}),h&&(0,u.jsx)(l,{})]}),(0,u.jsx)(s,{"aria-label":typeof t==`string`?t:f,"data-testid":e,name:f,defaultItems:p,defaultSelectedKey:v,selectedKey:y,onSelectionChange:C,onInputChange:w,isClearable:b,isDisabled:g||_,isLoading:_,placeholder:_?k(n.HOME$LOADING):m,allowsCustomValue:x,isRequired:S,className:`w-full`,classNames:{popoverContent:`bg-content1 rounded-xl`,selectorButton:c},selectorButtonProps:{disableRipple:!0},inputProps:{classNames:{inputWrapper:i(a,D),input:O}},defaultFilter:T,startContent:E||null,children:e=>(0,u.jsx)(o,{children:e.label},e.key)})]})}export{d as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-
|
|
1
|
+
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-D9ucT0fq.js";e();var n=t(),r=e=>(0,n.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:[(0,n.jsx)(`g`,{clipPath:`url(#clip0_7985_8061)`,children:(0,n.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M19.85 8.75L24 9.58V14.42L19.85 15.25L22.2 18.77L18.77 22.2L15.25 19.85L14.42 24H9.58L8.75 19.85L5.23 22.2L1.8 18.77L4.15 15.25L0 14.42V9.58L4.15 8.75L1.8 5.23L5.23 1.8L8.75 4.15L9.58 0H14.42L15.25 4.15L18.77 1.8L22.2 5.23L19.85 8.75ZM18.28 13.82L22.28 13.01V11.01L18.28 10.2L17.74 8.9L20.03 5.47L18.6 4.04L15.17 6.33L13.87 5.79L13.06 1.79H11.06L10.25 5.79L8.95 6.33L5.52 4.04L4.09 5.47L6.38 8.9L5.84 10.2L1.84 11.01V13.01L5.84 13.82L6.38 15.12L4.09 18.55L5.52 19.98L8.95 17.69L10.25 18.23L11.06 22.23H13.06L13.87 18.23L15.17 17.69L18.6 19.98L20.03 18.55L17.74 15.12L18.28 13.82ZM10.094 9.148C10.6582 8.77105 11.3215 8.5699 12 8.57C12.9089 8.57264 13.7798 8.93486 14.4225 9.57754C15.0651 10.2202 15.4274 11.0911 15.43 12C15.4299 12.5925 15.2764 13.175 14.9843 13.6905C14.6922 14.2061 14.2715 14.6371 13.7633 14.9417C13.255 15.2464 12.6765 15.4141 12.0842 15.4286C11.4918 15.4432 10.9058 15.304 10.3832 15.0247C9.86059 14.7454 9.41928 14.3355 9.10225 13.8349C8.78521 13.3343 8.60327 12.7601 8.57415 12.1683C8.54502 11.5764 8.66972 10.9871 8.93607 10.4578C9.20243 9.92854 9.60136 9.47727 10.094 9.148ZM11.05 13.422C11.331 13.61 11.662 13.71 12 13.71C12.2249 13.7113 12.4479 13.668 12.656 13.5825C12.864 13.4971 13.0531 13.3712 13.2121 13.2121C13.3712 13.0531 13.4971 12.864 13.5825 12.656C13.668 12.4479 13.7113 12.2249 13.71 12C13.71 11.7046 13.6334 11.4142 13.4878 11.1572C13.3421 10.9002 13.1324 10.6852 12.879 10.5334C12.6256 10.3815 12.3372 10.2979 12.0418 10.2907C11.7465 10.2835 11.4544 10.3529 11.1938 10.4921C10.9333 10.6314 10.7133 10.8358 10.5553 11.0854C10.3972 11.335 10.3065 11.6213 10.2921 11.9163C10.2776 12.2114 10.3398 12.5052 10.4726 12.769C10.6054 13.0329 10.8044 13.2579 11.05 13.422Z`,fill:`currentColor`})}),(0,n.jsx)(`defs`,{children:(0,n.jsx)(`clipPath`,{id:`clip0_7985_8061`,children:(0,n.jsx)(`rect`,{width:24,height:24,fill:`currentColor`})})})]});export{r as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{L as e,s as t}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as n,t as r}from"./declaration-
|
|
1
|
+
import{L as e,s as t}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{t as a}from"./use-settings-nav-items-DVrMNk0I.js";import{t as o}from"./use-config-5zEjywCL.js";import{t as s}from"./sidebar-nav-link-CPWuQ_c6.js";import{r as c}from"./typography-BLSEGjph.js";import{n as l}from"./settings-utils--H_EvFjx.js";import{t as u}from"./use-breakpoint-DpxHDmuH.js";import{t as d}from"./backend-synced-settings-badge-Dcd4712m.js";var f=n();function p({navigationItems:e}){let{t}=i(`openhands`),n=e.filter(e=>e.type===`item`);return(0,f.jsxs)(`div`,{"data-testid":`settings-mobile-hub`,className:`flex flex-col gap-4 px-4 py-2 md:hidden`,children:[(0,f.jsx)(c.H2,{children:t(r.SETTINGS$TITLE)}),(0,f.jsx)(`nav`,{className:`flex flex-col gap-0.5`,children:n.map(e=>(0,f.jsx)(s,{to:e.item.to,label:t(e.item.text),end:!0,testId:`sidebar-settings-${e.item.to}`,icon:e.item.icon},e.item.to))}),(0,f.jsx)(`div`,{className:`pt-1`,children:(0,f.jsx)(d,{})})]})}var m=e(function(){let e=u(768),n=a(),{data:r}=o();return e?(0,f.jsx)(p,{navigationItems:n}):(0,f.jsx)(t,{to:l(r?.feature_flags)??`/settings/app`,replace:!0})});export{m as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{t as a}from"./utils-eXk6yerZ.js";import{d as o}from"./brand-button-9SOzmqPP.js";var s=e(t(),1),c=n();function l(){let{t:e}=i(`openhands`);return(0,c.jsx)(`span`,{className:`text-xs text-tertiary-alt`,children:e(r.COMMON$OPTIONAL)})}var u=(0,s.forwardRef)(function({testId:e,name:t,label:n,type:r,defaultValue:i,value:s,placeholder:u,showOptionalTag:d,isDisabled:f,startContent:p,className:m,onChange:h,onKeyDown:g,required:_,min:v,max:y,step:b,pattern:x,title:S,labelClassName:C,ariaDescribedBy:w,ariaInvalid:T,error:E,showRequiredTag:D,onBlur:O,inputClassName:k},A){let j=E&&e?`${e}-error`:void 0;return(0,c.jsxs)(`label`,{className:a(`flex flex-col gap-2.5 w-full min-w-0`,m),children:[(0,c.jsxs)(`div`,{className:`flex items-center gap-2`,children:[p,(0,c.jsx)(`span`,{className:a(`text-sm`,C),children:n}),D&&(0,c.jsx)(`span`,{className:`text-red-400 text-sm leading-none`,"aria-hidden":!0,children:`*`}),d&&(0,c.jsx)(l,{})]}),(0,c.jsx)(`input`,{ref:A,"data-testid":e,onChange:e=>h?.(e.target.value),onKeyDown:g,onBlur:O,name:t,disabled:f,type:r,defaultValue:i,value:s,placeholder:u,min:v,max:y,step:b,required:_,pattern:x,title:S,"aria-describedby":j??w,"aria-invalid":!!E||T,className:a(o,`disabled:bg-[var(--oh-surface-raised)] disabled:border-[var(--oh-border-subtle)]`,E&&`border-red-500`,k)}),E&&(0,c.jsx)(`p`,{id:j,role:`alert`,"data-testid":e?`${e}-error`:void 0,className:`text-xs text-red-400 -mt-1`,children:E})]})});export{l as n,u as t};
|
package/build/assets/{settings-list-classes-CYRnRf8r.js → settings-list-classes-B9uo5WES.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./utils-
|
|
1
|
+
import{t as e}from"./utils-eXk6yerZ.js";import{a as t,g as n,p as r,u as i}from"./brand-button-9SOzmqPP.js";var a=`h-12 min-h-12`,o=e(t,i,r,`overflow-hidden`),s=e(o,`overflow-auto max-h-[min(40vh,22rem)]`),c=`divide-y divide-[var(--oh-border)]`,l=`hover:bg-[var(--oh-interactive-hover-low)]`,u=e(a,`flex items-center px-3`,n,l),d=e(l,n,`border-t border-[var(--oh-border)] first:border-t-0`),f=e(r,`sticky top-0 z-10 border-b border-[var(--oh-border)]`),p=e(a,`px-3 text-left text-sm font-medium align-middle`),m=e(a,`px-3 text-sm align-middle min-w-0`),h=e(`inline-flex cursor-pointer items-center justify-center rounded-md p-1 text-muted`,n,`hover:bg-[var(--oh-interactive-hover-low)] hover:text-white`);export{s as a,p as c,u as i,d as l,c as n,m as o,h as r,f as s,o as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{N as a,t as o}from"./utils-eXk6yerZ.js";import{t as s}from"./modal-backdrop-_VbcKk5K.js";import{r as c,t as l}from"./modal-body-Cd-PtMHr.js";import{t as u}from"./base-modal-DvuGYyu1.js";import{t as d}from"./modal-classes-CNm4ovfm.js";import{t as f}from"./brand-button-9SOzmqPP.js";import{n as p}from"./navigation-context-BpAOh_t5.js";import{t as m}from"./model-selector-sioC8xP4.js";import{t as h}from"./settings-input-BM8ANxDb.js";import{t as g}from"./settings-wh2sLLJM.js";import{t as _}from"./use-tracking-BhyV5A9i.js";import{t as v}from"./use-save-settings-Xp8DD-jf.js";import{d as y,i as b}from"./sdk-settings-schema-Big50zDH.js";import{t as x}from"./settings-utils--H_EvFjx.js";var S=e(t(),1),C=n();function w({testId:e,title:t,description:n,buttons:r}){return(0,C.jsx)(u,{testId:e,title:t,description:n,buttons:[{text:r.danger.text,onClick:r.danger.onClick,className:`bg-danger`},{text:r.cancel.text,onClick:r.cancel.onClick,className:`bg-[var(--oh-interactive-selected)]`}]})}function T({settings:e,onClose:t}){let{trackSettingsSaved:n}=_(),{mutate:o}=v(),{currentPath:c}=p(),{t:l}=i(`openhands`),u=S.useRef(null),[d,g]=S.useState(!1),T=async e=>{let r=x(e);await o(r,{onSuccess:()=>{t();let e=r.agent_settings_diff?.llm??{};n({llmModel:e.model,llmApiKeySet:e.api_key?`SET`:`UNSET`,searchApiKeySet:r.search_api_key?`SET`:`UNSET`,remoteRuntimeResourceFactor:r.remote_runtime_resource_factor})}})},E=()=>{T(new FormData(u.current??void 0))},D=e=>{e.preventDefault();let t=new FormData(e.currentTarget);c.startsWith(`/conversations/`)?g(!0):T(t)},O=e.llm_api_key_set,k=b(e,`llm.model`),A=b(e,`llm.base_url`);return(0,C.jsxs)(`div`,{children:[(0,C.jsxs)(`form`,{ref:u,"data-testid":`settings-form`,className:`flex flex-col gap-6`,onSubmit:D,children:[(0,C.jsxs)(`div`,{className:`flex flex-col gap-[17px]`,children:[(0,C.jsx)(m,{currentModel:typeof k==`string`?k:void 0,currentBaseUrl:typeof A==`string`?A:void 0,wrapperClassName:`!flex-col !gap-[17px]`,labelClassName:a.LABEL_CLASSNAME}),(0,C.jsx)(h,{testId:`llm-api-key-input`,name:`llm-api-key-input`,label:l(r.SETTINGS_FORM$API_KEY),type:`password`,className:`w-full`,placeholder:O?`<hidden>`:``,labelClassName:a.LABEL_CLASSNAME}),(0,C.jsx)(y,{testId:`llm-api-key-help-anchor`,text:l(r.SETTINGS$DONT_KNOW_API_KEY),linkText:l(r.SETTINGS$CLICK_FOR_INSTRUCTIONS),href:`https://docs.openhands.dev/usage/local-setup#getting-an-api-key`,size:`settings`,linkColor:`white`})]}),(0,C.jsx)(`div`,{className:`flex flex-col gap-2`,children:(0,C.jsx)(f,{testId:`save-settings-button`,type:`submit`,variant:`primary`,className:`w-full`,children:l(r.BUTTON$SAVE)})})]}),d&&(0,C.jsx)(s,{children:(0,C.jsx)(w,{title:l(r.MODAL$END_SESSION_TITLE),description:l(r.MODAL$END_SESSION_MESSAGE),buttons:{danger:{text:l(r.BUTTON$END_SESSION),onClick:E},cancel:{text:l(r.BUTTON$CANCEL),onClick:()=>g(!1)}}})})]})}function E({onClose:e,settings:t}){let{t:n}=i(`openhands`);return(0,C.jsx)(s,{children:(0,C.jsxs)(`div`,{"data-testid":`ai-config-modal`,className:o(`bg-[var(--oh-surface)] m-4 p-6 rounded-xl flex flex-col gap-[17px] border border-[var(--oh-border)] api-configuration-modal`,c(`md`),l),children:[(0,C.jsx)(`span`,{className:d,children:n(r.AI_SETTINGS$TITLE)}),(0,C.jsx)(y,{testId:`advanced-settings-link`,text:`${n(r.SETTINGS$DESCRIPTION)}. ${n(r.SETTINGS$FOR_OTHER_OPTIONS)} ${n(r.COMMON$SEE)}`,linkText:n(r.COMMON$ADVANCED_SETTINGS),href:`/settings`,suffix:`.`,size:`settings`,linkColor:`white`,suffixClassName:`text-white`}),(0,C.jsx)(T,{settings:t||g,onClose:e})]})})}export{E as SettingsModal};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n}from"./declaration-D9ucT0fq.js";var r=e(t(),1),i=n(),a=r.createContext(null);function o({setHideSectionHeader:e,children:t}){let n=r.useMemo(()=>({setHideSectionHeader:e}),[e]);return(0,i.jsx)(a.Provider,{value:n,children:t})}function s(){return r.useContext(a)??{setHideSectionHeader:()=>{}}}export{s as n,o as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{t as a}from"./utils-eXk6yerZ.js";import{n as o}from"./toggle-switch-CL_wRiGs.js";var s=e(t(),1),c=n();function l({children:e,testId:t,name:n,onToggle:l,defaultIsToggled:u,isToggled:d,isBeta:f,isDisabled:p,togglePosition:m=`left`}){let{t:h}=i(`openhands`),[g,_]=s.useState(u??!1),v=e=>{p||(_(e),l?.(e))},y=(0,c.jsx)(`input`,{hidden:!0,"data-testid":t,name:n,type:`checkbox`,onChange:e=>v(e.target.checked),checked:d??g,disabled:p}),b=(0,c.jsx)(o,{enabled:d??g}),x=e||f?(0,c.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,c.jsx)(`span`,{className:`text-sm`,children:e}),f&&(0,c.jsx)(`span`,{className:`text-[11px] leading-4 text-base font-[500] tracking-tighter bg-primary px-1 rounded-full`,children:h(r.BADGE$BETA)})]}):null;return(0,c.jsxs)(`label`,{className:a(`flex items-center gap-2`,m===`right`?`w-full justify-between`:`w-fit`,p?`cursor-not-allowed opacity-50`:`cursor-pointer`),children:[y,m===`right`?(0,c.jsxs)(c.Fragment,{children:[x,b]}):(0,c.jsxs)(c.Fragment,{children:[b,x]})]})}export{l as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{L as n,P as r,r as i}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{d as a}from"./path-utils-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{L as n,P as r,r as i}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{d as a}from"./path-utils-YlkpoImJ.js";import{o,t as s}from"./declaration-D9ucT0fq.js";import{t as c}from"./useQuery-DGRSm7IT.js";import{t as l}from"./useTranslation-CL6FTf1b.js";import{t as u}from"./messages-CsFUrAen.js";import{n as d}from"./agent-server-client-options-B-C8JaTb.js";import{s as f}from"./vendor~root-layout~home~conversation-panel~conversation~launch~mcp~settings~settings-index~~m3acswdn-CGm-Jxp5.js";import{t as p}from"./loading-spinner-D7bOU6I7.js";import{t as m}from"./openhands-logo-Dzm-d_V_.js";import{c as h}from"./lesson-plan-CHGc-B8Y.js";import{n as g}from"./use-event-store-DNSmyzUh.js";var _=e(t(),1),v=e=>c({queryKey:[`shared-conversation`,e],queryFn:()=>{if(!e)throw Error(`Conversation ID is required`);return new f(d()).getSharedConversation(e)},enabled:!!e,retry:!1}),y=e=>a({queryKey:[`shared-conversation-events`,e],queryFn:({pageParam:t})=>{if(!e)throw Error(`Conversation ID is required`);return new f(d()).searchSharedEvents({conversationId:e,limit:100,pageId:t})},initialPageParam:void 0,getNextPageParam:e=>e.next_page_id??void 0,enabled:!!e,retry:!1}),b=({hasNextPage:e,isFetchingNextPage:t,fetchNextPage:n,threshold:r=100})=>{let i=(0,_.useRef)(null),a=(0,_.useCallback)(()=>{if(!i.current||t||!e)return;let{scrollTop:a,scrollHeight:o,clientHeight:s}=i.current;a+s>=o-r&&n()},[e,t,n,r]);return(0,_.useEffect)(()=>{let e=i.current;if(e)return e.addEventListener(`scroll`,a),()=>{e.removeEventListener(`scroll`,a)}},[a]),i},x=o(),S=n(function(){let{t:e}=l(`openhands`),{conversationId:t}=r(),{data:n,isLoading:a,error:o}=v(t),{data:c,isLoading:d,error:f,hasNextPage:S,fetchNextPage:C,isFetchingNextPage:w}=y(t),T=a||d,E=o||f,D=_.useMemo(()=>c?.pages?c.pages.flatMap(e=>e.items):[],[c?.pages]),O=_.useMemo(()=>D.reduce((e,t)=>g(t,e),[]).filter(h),[D]),k=b({hasNextPage:!!S,isFetchingNextPage:w,fetchNextPage:C});return T?(0,x.jsx)(`div`,{className:`flex items-center justify-center h-screen bg-base`,children:(0,x.jsx)(p,{size:`large`})}):E||!n?(0,x.jsx)(`div`,{className:`flex items-center justify-center h-screen bg-base`,children:(0,x.jsx)(`div`,{className:`text-white`,children:e(s.CONVERSATION$NOT_FOUND)})}):(0,x.jsxs)(`div`,{className:`h-screen bg-base text-white flex flex-col`,children:[(0,x.jsx)(`div`,{className:`border-b border-[var(--oh-border-subtle)] p-4 flex-shrink-0`,children:(0,x.jsxs)(`div`,{className:`max-w-4xl mx-auto flex items-start gap-4`,children:[(0,x.jsx)(i,{to:`/conversations`,className:`flex-shrink-0`,"aria-label":e(s.BRANDING$OPENHANDS_LOGO),children:(0,x.jsx)(m,{width:46,height:30})}),(0,x.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,x.jsx)(`h1`,{className:`text-xl font-medium mb-2`,children:n?.title||e(s.CONVERSATION$SHARED_CONVERSATION)}),n?.selected_branch&&(0,x.jsxs)(`div`,{className:`text-sm text-[var(--oh-muted)]`,children:[e(s.CONVERSATION$BRANCH),`: `,n.selected_branch]}),n?.selected_repository&&(0,x.jsxs)(`div`,{className:`text-sm text-[var(--oh-muted)]`,children:[e(s.CONVERSATION$REPOSITORY),`:`,` `,n.selected_repository]}),n?.llm_model&&(0,x.jsxs)(`div`,{className:`text-sm text-[var(--oh-muted)]`,children:[e(s.LLM$MODEL),`: `,n.llm_model]})]})]})}),(0,x.jsx)(`div`,{ref:k,className:`flex-1 overflow-y-auto custom-scrollbar-always px-4 pt-4 gap-2`,children:(0,x.jsxs)(`div`,{className:`max-w-4xl mx-auto p-4 border border-[var(--oh-border-subtle)] rounded`,children:[O.length>0?(0,x.jsx)(u,{messages:O,allEvents:D}):(0,x.jsx)(`div`,{className:`flex items-center justify-center h-full`,children:(0,x.jsx)(`div`,{className:`text-center text-[var(--oh-muted)] py-8`,children:e(s.CONVERSATION$NO_HISTORY_AVAILABLE)})}),w&&(0,x.jsx)(`div`,{className:`flex justify-center py-4`,children:(0,x.jsx)(p,{size:`small`})})]})})]})});export{S as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{t as n}from"./useMutation-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{t as n}from"./useMutation-Dm84WAKR.js";import{o as r,t as i}from"./declaration-D9ucT0fq.js";import{n as a}from"./QueryClientProvider-XcSjsfpb.js";import{t as o}from"./Trans-sy4l4TyQ.js";import{t as s}from"./useTranslation-CL6FTf1b.js";import{t as c}from"./createLucideIcon-CkGTf9Qj.js";import{t as l}from"./utils-eXk6yerZ.js";import{t as u}from"./agent-server-conversation-service.api-CGbkhsLj.js";import{t as d}from"./modal-backdrop-_VbcKk5K.js";import{n as f}from"./modal-body-Cd-PtMHr.js";import{n as p,r as m}from"./base-modal-DvuGYyu1.js";import{g as h,l as g,t as _}from"./brand-button-9SOzmqPP.js";var v=c(`chevron-left`,[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]),y=e(t(),1),b=r();function x({onConfirm:e,onCancel:t,conversationTitle:n,title:r,description:a}){let{t:c}=s(`openhands`),l;return l=a??(n?(0,b.jsx)(o,{ns:`openhands`,i18nKey:i.CONVERSATION$DELETE_WARNING_WITH_TITLE,values:{title:n},components:{title:(0,b.jsx)(`span`,{className:`text-white`})}}):c(i.CONVERSATION$DELETE_WARNING)),(0,b.jsx)(d,{onClose:t,children:(0,b.jsxs)(f,{className:`items-start border border-[var(--oh-border)]`,children:[(0,b.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,b.jsx)(m,{title:r??c(i.CONVERSATION$CONFIRM_DELETE)}),(0,b.jsx)(p,{children:l})]}),(0,b.jsxs)(`div`,{className:`flex justify-end gap-2 w-full`,onClick:e=>e.stopPropagation(),children:[(0,b.jsx)(_,{type:`button`,variant:`secondary`,onClick:t,"data-testid":`cancel-button`,children:c(i.BUTTON$CANCEL)}),(0,b.jsx)(_,{type:`button`,variant:`primary`,onClick:e,"data-testid":`confirm-button`,children:c(i.ACTION$CONFIRM_DELETE)})]})]})})}function S({onConfirm:e,onCancel:t}){let{t:n}=s(`openhands`);return(0,b.jsx)(d,{onClose:t,children:(0,b.jsxs)(f,{className:`items-start border border-[var(--oh-border)]`,children:[(0,b.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,b.jsx)(m,{title:n(i.CONVERSATION$CONFIRM_CLOSE_CONVERSATION)}),(0,b.jsx)(p,{description:n(i.CONVERSATION$CLOSE_CONVERSATION_WARNING)})]}),(0,b.jsxs)(`div`,{className:`flex justify-end gap-2 w-full`,onClick:e=>e.stopPropagation(),children:[(0,b.jsx)(_,{type:`button`,variant:`secondary`,onClick:t,"data-testid":`cancel-button`,children:n(i.BUTTON$CANCEL)}),(0,b.jsx)(_,{type:`button`,variant:`primary`,onClick:e,"data-testid":`confirm-button`,children:n(i.ACTION$CONFIRM_CLOSE)})]})]})})}var C=()=>{let e=a();return n({mutationFn:e=>u.updateConversationTitle(e.conversationId,e.newTitle),onMutate:async t=>{await e.cancelQueries({queryKey:[`user`,`conversations`]});let n=e.getQueryData([`user`,`conversations`]);return e.setQueryData([`user`,`conversations`],e=>e?.map(e=>e.id===t.conversationId?{...e,title:t.newTitle}:e)),e.setQueryData([`user`,`conversation`,t.conversationId],e=>e&&{...e,title:t.newTitle}),{previousConversations:n}},onError:(t,n,r)=>{r?.previousConversations&&e.setQueryData([`user`,`conversations`],r.previousConversations)},onSettled:(t,n,r)=>{e.invalidateQueries({queryKey:[`user`,`conversations`]}),e.invalidateQueries({queryKey:[`user`,`conversation`,r.conversationId]})}})};function w(e){if(!e)return null;try{let t=new URL(e);return t.hostname===`localhost`&&window.location.hostname!==`localhost`?(t.hostname=window.location.hostname,t.toString()):e}catch{return e}}var T=e=>(0,b.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:(0,b.jsx)(`path`,{d:`M12 2C12.5523 2 13 2.44772 13 3V13.5858L15.2929 11.2929C15.6834 10.9024 16.3166 10.9024 16.7071 11.2929C17.0976 11.6834 17.0976 12.3166 16.7071 12.7071L12.7071 16.7071C12.3166 17.0976 11.6834 17.0976 11.2929 16.7071L7.29289 12.7071C6.90237 12.3166 6.90237 11.6834 7.29289 11.2929C7.68342 10.9024 8.31658 10.9024 8.70711 11.2929L11 13.5858V3C11 2.44772 11.4477 2 12 2ZM5 17C5.55228 17 6 17.4477 6 18V20H18V18C18 17.4477 18.4477 17 19 17C19.5523 17 20 17.4477 20 18V20C20 21.1046 19.1046 22 18 22H6C4.89543 22 4 21.1046 4 20V18C4 17.4477 4.44772 17 5 17Z`,fill:`currentColor`})}),E=e=>(0,b.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:(0,b.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M21 7.5V9H3V7.5H21ZM3 10.5H21V18H3V10.5ZM21 6H3C2.60218 6 2.22064 6.15804 1.93934 6.43934C1.65804 6.72064 1.5 7.10218 1.5 7.5V18C1.5 18.3978 1.65804 18.7794 1.93934 19.0607C2.22064 19.342 2.60218 19.5 3 19.5H21C21.3978 19.5 21.7794 19.342 22.0607 19.0607C22.342 18.7794 22.5 18.3978 22.5 18V7.5C22.5 7.10218 22.342 6.72064 22.0607 6.43934C21.7794 6.15804 21.3978 6 21 6ZM16.5 15H19.5V16.5H16.5V15Z`,fill:`currentColor`})}),D=y.createContext(null);function O({children:e}){let[t,n]=y.useState(!1),r=y.useCallback(()=>n(!0),[]),i=y.useCallback(()=>n(!1),[]),a=y.useCallback(()=>n(e=>!e),[]),o=y.useMemo(()=>({isOpen:t,open:r,close:i,toggle:a}),[t,r,i,a]);return(0,b.jsx)(D.Provider,{value:o,children:e})}function k(){let e=y.useContext(D);if(!e)throw Error(`useSidebarMobileNav must be used within SidebarMobileNavProvider`);return e}var A=l(`inline-flex shrink-0 cursor-pointer items-center justify-center rounded-md p-1`,`text-[var(--oh-muted)]`,h,g),j=`size-5 shrink-0`,M=e=>(0,b.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,...e,children:(0,b.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M10 5.5H18C18.2761 5.5 18.5 5.72386 18.5 6V18C18.5 18.2761 18.2761 18.5 18 18.5H10L10 5.5ZM8.5 5.5H6C5.72386 5.5 5.5 5.72386 5.5 6V18C5.5 18.2761 5.72386 18.5 6 18.5H8.5L8.5 5.5ZM18 4H6C4.89543 4 4 4.89543 4 6V18C4 19.1046 4.89543 20 6 20H18C19.1046 20 20 19.1046 20 18V6C20 4.89543 19.1046 4 18 4Z`,fill:`currentColor`})});function N(){let{t:e}=s(`openhands`),{isOpen:t,toggle:n}=k();return(0,b.jsx)(`button`,{type:`button`,"data-testid":`sidebar-mobile-menu-toggle`,onClick:n,"aria-expanded":t,"aria-label":e(t?i.SIDEBAR$CLOSE_MENU:i.SIDEBAR$OPEN_MENU),className:A,children:(0,b.jsx)(M,{className:j,"aria-hidden":!0})})}export{O as a,T as c,S as d,x as f,j as i,w as l,M as n,k as o,v as p,A as r,E as s,N as t,C as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-
|
|
1
|
+
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-D9ucT0fq.js";import{t as n}from"./utils-eXk6yerZ.js";import{n as r}from"./navigation-context-BpAOh_t5.js";import{t as i}from"./navigation-link-Dci7Nuyf.js";import{c as a,f as o,l as s,m as c,r as l,s as u,u as d}from"./use-cloud-current-user-id-DVZXa_WH.js";import{t as f}from"./styled-tooltip-X61SEwqk.js";e();var p=t();function m({active:e,className:t,children:r}){return(0,p.jsxs)(`span`,{className:n(l,t),children:[(0,p.jsx)(`span`,{"aria-hidden":!0,className:s(e)}),(0,p.jsx)(`span`,{className:d(e),children:r})]})}function h(e,t,n){return t===`/`||n?e===t:e===t||e.startsWith(`${t}/`)}function g({to:e,label:t,end:s=!1,indent:l=!1,testId:d,disabled:g=!1,icon:_,collapsed:v=!1,hoverContent:y,disabledReason:b,forceActive:x=!1}){let{currentPath:S}=r(),C=x||h(S,e,s),w=(0,p.jsxs)(i,{to:e,end:s,"data-testid":d,tabIndex:g?-1:0,"aria-label":v?t:void 0,"aria-disabled":g||void 0,onClick:e=>{g&&e.preventDefault()},className:n(c({indent:l,collapsed:v}),!v&&(C?a.active:a.idle),g&&`pointer-events-none opacity-50`),children:[_?v?(0,p.jsx)(m,{active:C,children:_}):(0,p.jsx)(`span`,{className:u,children:_}):null,(0,p.jsx)(`span`,{className:o(v),children:t})]});return g&&b?(0,p.jsx)(f,{content:b,placement:`right`,children:w}):v?(0,p.jsx)(f,{content:y??t,placement:`right`,tooltipClassName:y?`p-0 bg-tertiary text-white`:void 0,children:w}):w}export{m as n,g as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{t as a}from"./utils-eXk6yerZ.js";import{i as o}from"./extension-module-card-classes-DP5J6ngE.js";var s=e(t(),1),c=n(),l=o,u=6,d=40;function f(e,t){if(e.length===0||t<=0)return 0;let n=0;for(let r=0;r<e.length;r+=1){let i=e[r],a=r>0?u:0,o=e.length-r-1>0?d+u:0;if(n+a+i+o>t)return Math.max(1,r);n+=a+i}return e.length}function p({pills:e,testId:t}){let{t:n}=i(`openhands`),l=s.useRef(null),u=s.useRef(null),[d,p]=s.useState(e.length),m=s.useCallback(()=>{let e=l.current,t=u.current;!e||!t||p(f(Array.from(t.children).map(e=>e.offsetWidth),e.clientWidth))},[]);if(s.useLayoutEffect(()=>{m()},[e,m]),s.useEffect(()=>{let e=l.current;if(!e||typeof ResizeObserver>`u`)return;let t=new ResizeObserver(()=>m());return t.observe(e),()=>t.disconnect()},[m]),e.length===0)return null;let h=Math.max(0,e.length-d);return(0,c.jsxs)(`div`,{className:`min-w-0 overflow-hidden`,children:[(0,c.jsx)(`div`,{ref:u,"aria-hidden":!0,className:`pointer-events-none fixed top-0 -left-[10000px] z-[-1] flex flex-nowrap items-center gap-1.5 opacity-0`,children:e.map(e=>(0,c.jsx)(`span`,{className:`inline-flex shrink-0`,children:e.node},e.id))}),(0,c.jsxs)(`div`,{ref:l,"data-testid":t,className:`flex w-full min-w-0 max-w-full flex-nowrap items-center gap-1.5 overflow-hidden`,children:[e.slice(0,d).map(e=>(0,c.jsx)(`span`,{className:`inline-flex shrink-0`,children:e.node},e.id)),h>0?(0,c.jsx)(`span`,{"data-testid":`${t}-overflow`,className:a(o,`font-medium text-tertiary-alt`),title:e.slice(d).map(e=>e.id).join(`, `),children:n(r.SETTINGS$SKILLS_PILLS_MORE,{count:h})}):null]})]})}export{p as n,l as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-
|
|
1
|
+
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-D9ucT0fq.js";e();var n=t(),r=e=>(0,n.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 19.13 24.62`,fill:`none`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,...e,children:[(0,n.jsx)(`path`,{d:`M.86,7.26l5.74,3.3,11.68-6.6`}),(0,n.jsx)(`path`,{d:`M6.6,17.15v-6.6`}),(0,n.jsx)(`path`,{d:`M1.32,14.34l4.62,2.64c.41.24.91.24,1.32,0l10.56-5.94`}),(0,n.jsx)(`path`,{d:`M.66,20c0,.47.25.91.66,1.14l4.62,2.64c.41.24.91.24,1.32,0l10.56-5.94c.41-.24.66-.67.66-1.14V4.62c0-.47-.25-.91-.66-1.14L13.2.84c-.41-.24-.91-.24-1.32,0L1.32,6.78c-.41.24-.66.67-.66,1.14v12.08Z`}),(0,n.jsx)(`path`,{d:`M.86,14.06l5.74,3.3,11.68-6.6`}),(0,n.jsx)(`path`,{d:`M6.6,23.96v-6.6`})]});export{r as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{L as e}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as t,t as n}from"./declaration-
|
|
1
|
+
import{L as e}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as t,t as n}from"./declaration-D9ucT0fq.js";import{t as r}from"./useTranslation-CL6FTf1b.js";import{n as i}from"./extensions-navigation-D5w2sFQe.js";import{n as a}from"./settings-like-page-layout-classes-C335ikW2.js";var o=t(),s=e(function(){let{t:e}=r(`openhands`);return(0,o.jsxs)(`div`,{"data-testid":`skills-plugins-screen`,className:`flex h-full gap-4 md:gap-6 md:pl-8 lg:gap-10 lg:pl-10`,children:[(0,o.jsx)(i,{}),(0,o.jsx)(`main`,{className:a,children:(0,o.jsx)(`div`,{className:`mx-auto w-full min-w-0 max-w-[800px]`,children:(0,o.jsxs)(`div`,{className:`mb-4 min-w-0 space-y-1`,children:[(0,o.jsx)(`h2`,{className:`text-xl font-medium leading-6 text-foreground`,children:e(n.SETTINGS$PLUGINS_TITLE)}),(0,o.jsx)(`div`,{className:`max-w-2xl text-sm text-tertiary-light`,children:e(n.SETTINGS$PLUGINS_DESCRIPTION)})]})})})]})});export{s as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{L as n}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as r,t as i}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{L as n}from"./vendor~entry.client~root~root-layout~index-redirect~home~conversation-panel~conversation~la~cnj3raoq-BjMt2JeR.js";import{o as r,t as i}from"./declaration-D9ucT0fq.js";import{t as a}from"./Trans-sy4l4TyQ.js";import{t as o}from"./useTranslation-CL6FTf1b.js";import{g as s,p as c}from"./query-client-config-Ca3tW1AH.js";import{n as l,r as u}from"./circle-plus-check-toggle-AO9DWyDX.js";import{t as d}from"./x-CCfDppg5.js";import{t as f}from"./utils-eXk6yerZ.js";import{t as p}from"./modal-backdrop-_VbcKk5K.js";import{n as m}from"./modal-classes-CNm4ovfm.js";import{t as h}from"./brand-button-9SOzmqPP.js";import{t as g}from"./modal-close-button-Dbo0NAMt.js";import{r as _}from"./use-settings-0SeqaDeW.js";import{t as v}from"./skills-BE5HJuGM.js";import{t as y}from"./use-save-settings-Xp8DD-jf.js";import{a as b,r as x}from"./extension-module-card-classes-DP5J6ngE.js";import{t as S}from"./settings-switch-xa6q4M6j.js";import{n as C,t as w}from"./skill-card-pill-row-DeodrwPG.js";import{t as T}from"./checkmark--JWAesua.js";import{t as E}from"./use-skills-Bv8LXrys.js";import{t as D}from"./copy-CdKN5rtJ.js";import{n as O}from"./extensions-navigation-D5w2sFQe.js";import{n as k,t as A}from"./use-launch-skill-in-chat-BTgXIu3N.js";import{t as j}from"./enum-filter-dropdown-COqUq3mB.js";import{n as ee}from"./settings-like-page-layout-classes-C335ikW2.js";var M=e(t(),1),N=r();function P({skillName:e,className:t}){return(0,N.jsx)(`span`,{"aria-hidden":`true`,title:e,"data-testid":`skill-icon-${e}`,className:f(`inline-flex h-10 w-10 shrink-0 items-center justify-center overflow-hidden`,`rounded-lg border border-white/10 bg-surface-raised text-white`,`shadow-[inset_0_1px_0_rgba(255,255,255,0.18)]`,`[&>svg]:h-5 [&>svg]:w-5`,t),children:(0,N.jsx)(v,{})})}var F=/^---\r?\n([\s\S]*?)\r?\n---\r?\n?/;function te(e){let t=e.match(/^description:\s*\|\s*\r?\n((?:[ \t].*(?:\r?\n|$))+)/m);if(t)return t[1].replace(/^[ \t]+/gm,``).trim();let n=e.match(/^description:\s*['"](.+?)['"]\s*$/m);if(n)return n[1].trim();let r=e.match(/^description:\s*(.+)\s*$/m);return r?r[1].trim():null}function ne(e){let t=e.match(F);return t?e.slice(t[0].length).trim():e.trim()}function re(e){let t=e.replace(/^#+\s+[^\n]+\n+/,``).trim();return t.split(/\n\s*\n/).map(e=>e.replace(/\s+/g,` `).trim()).find(e=>e.length>0)??t.replace(/\s+/g,` `).trim()}function I(e){let t=e.description?.trim();if(t)return t;let n=e.content?.trim();if(!n)return``;let r=n.match(F);if(r){let e=te(r[1]);if(e)return e}return re(ne(n))}var L=`inline-flex shrink-0 items-center whitespace-nowrap rounded-full border border-text-secondary/35 bg-text-secondary/12 px-2 py-0.5 text-[11px] font-medium leading-4 text-tertiary-light`,R={agentskills:{labelKey:i.SETTINGS$SKILLS_TYPE_AGENTSKILLS},knowledge:{labelKey:i.SETTINGS$SKILLS_TYPE_KNOWLEDGE},repo:{labelKey:i.SETTINGS$SKILLS_TYPE_REPO}};function z({type:e}){let{t}=o(`openhands`),n=R[e];return(0,N.jsx)(`span`,{"data-testid":`skill-type-badge-${e}`,className:L,children:t(n.labelKey)})}function B(e,t,n){if(e)return`${e}-${t}-${n}`}function V(e,t,n={}){let{variant:r=`card`,testIdPrefix:a}=n,o=[{id:`type-${e.type}`,node:(0,N.jsx)(z,{type:e.type})}];if(e.version&&o.push({id:`version-${e.version}`,node:(0,N.jsx)(`span`,{"data-testid":B(a,e.name,`version`)??`skill-version-${e.name}`,className:w,children:t(i.SETTINGS$SKILLS_VERSION,{version:e.version})})}),r===`detail`&&e.license&&o.push({id:`license-${e.license}`,node:(0,N.jsx)(`span`,{"data-testid":B(a,e.name,`license`),className:w,children:e.license})}),r===`detail`&&e.compatibility&&o.push({id:`compatibility-${e.compatibility}`,node:(0,N.jsx)(`span`,{"data-testid":B(a,e.name,`compatibility`),className:w,children:e.compatibility})}),e.disable_model_invocation&&o.push({id:`disable-model-invocation`,node:(0,N.jsxs)(`span`,{"data-testid":B(a,e.name,`disable-model-invocation`)??`skill-disable-model-invocation-${e.name}`,className:`inline-flex shrink-0 items-center gap-1 whitespace-nowrap rounded-full border border-[rgba(248,113,113,0.35)] bg-[rgba(248,113,113,0.12)] px-2 py-0.5 text-[11px] font-medium leading-4 text-[#fca5a5]`,children:[(0,N.jsx)(`span`,{className:`size-1.5 rounded-full bg-[#fca5a5]`}),t(i.SETTINGS$SKILLS_DISABLE_MODEL_INVOCATION)]})}),r===`detail`&&e.allowed_tools)for(let t of e.allowed_tools)o.push({id:`allowed-tool-${t}`,node:(0,N.jsx)(`span`,{"data-testid":B(a,e.name,`tool-${t}`),className:f(w,`font-mono`),children:t})});if(r===`detail`&&e.metadata)for(let[t,n]of Object.entries(e.metadata))o.push({id:`metadata-${t}`,node:(0,N.jsxs)(`span`,{"data-testid":B(a,e.name,`metadata-${t}`),className:w,children:[(0,N.jsxs)(`span`,{className:`font-mono text-[10px] text-tertiary-light`,children:[t,`:`]}),` `,n]})});for(let t of e.triggers??[])o.push({id:`trigger-${t}`,node:(0,N.jsx)(`span`,{"data-testid":B(a,e.name,`trigger-${t}`),className:w,children:t})});return o}function H(e){let t=e?.trim();return t?!!(/^https?:\/\//i.test(t)||t.startsWith(`/`)||t.startsWith(`./`)||t.startsWith(`../`)||t.startsWith(`~`)||/^[A-Za-z]:[\\/]/.test(t)||t.includes(`/`)||t.includes(`\\`)):!1}function U({skill:e,enabled:t,onOpen:n,onToggle:r}){let{t:a}=o(`openhands`),[s,c]=M.useState(!1),u=I(e),d=M.useMemo(()=>V(e,a),[e,a]),p=H(e.source);return M.useEffect(()=>{if(!s)return;let e=setTimeout(()=>c(!1),2e3);return()=>clearTimeout(e)},[s]),(0,N.jsx)(`div`,{"data-testid":`skill-card-${e.name}`,role:`button`,tabIndex:0,onClick:n,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),n())},className:f(`flex min-w-0 flex-col gap-3 overflow-hidden p-4`,b,x),children:(0,N.jsxs)(`div`,{className:`flex items-start gap-3`,children:[(0,N.jsx)(P,{skillName:e.name}),(0,N.jsxs)(`div`,{className:`flex min-w-0 flex-1 flex-col gap-3`,children:[(0,N.jsxs)(`header`,{className:`flex items-start justify-between gap-3`,children:[(0,N.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,N.jsx)(`h3`,{"data-testid":`skill-name-${e.name}`,className:`truncate text-sm font-semibold text-white`,children:e.name}),e.source?(0,N.jsxs)(`div`,{className:`mt-0.5 flex min-w-0 items-center gap-1`,children:[(0,N.jsx)(`p`,{"data-testid":`skill-source-${e.name}`,className:`min-w-0 flex-1 truncate text-xs text-tertiary-alt`,title:e.source,children:e.source}),p?(0,N.jsx)(`button`,{type:`button`,"data-testid":`skill-copy-source-${e.name}`,"aria-label":a(s?i.BUTTON$COPIED:i.SETTINGS$SKILLS_COPY_PATH),disabled:s,onClick:async t=>{t.stopPropagation(),e.source&&(await navigator.clipboard.writeText(e.source),c(!0))},className:`shrink-0 cursor-pointer border-0 bg-transparent p-0.5 text-tertiary-alt hover:text-white disabled:cursor-default [&_path]:fill-current`,children:s?(0,N.jsx)(T,{width:12,height:12}):(0,N.jsx)(D,{width:12,height:12})}):null]}):null]}),(0,N.jsx)(l,{testId:`skill-toggle-${e.name}`,isSelected:t,onToggle:r,disableTooltipKey:i.COMMON$DISABLE})]}),u?(0,N.jsx)(`div`,{"data-testid":`skill-description-${e.name}`,className:`min-w-0`,children:(0,N.jsx)(`p`,{className:`line-clamp-2 break-words text-xs leading-relaxed text-tertiary-light`,children:u})}):null,d.length>0?(0,N.jsx)(C,{pills:d,testId:`skill-triggers-${e.name}`}):null]})]})})}var W=`https://docs.openhands.dev/overview/skills/adding#adding-new-skills`,G=`/add-skill https://github.com/OpenHands/extensions/tree/main/skills/codereview`;function K(e){return e.name===`add-skill`?G:`/${e.name} `}function q({testId:e,label:t,value:n}){return(0,N.jsxs)(`label`,{className:`flex min-w-0 w-full flex-col gap-2.5`,children:[(0,N.jsx)(`span`,{className:`text-sm`,children:t}),(0,N.jsx)(`textarea`,{"data-testid":e,readOnly:!0,value:n,rows:Math.min(12,Math.max(4,n.split(`
|
|
2
2
|
`).length)),className:f(`bg-[var(--oh-surface-raised)] border border-[var(--oh-border-subtle)] w-full min-w-0 rounded-sm p-2 text-sm`,`cursor-not-allowed resize-none custom-scrollbar`)})]})}function J({skill:e,enabled:t,onToggle:n,onClose:r}){let{t:a}=o(`openhands`),s=A(),[c,l]=M.useState(!1),u=M.useMemo(()=>K(e),[e]),d=I(e),f=M.useMemo(()=>V(e,a,{variant:`detail`,testIdPrefix:`skill-modal-pill`}),[e,a]),_=H(e.source);return M.useEffect(()=>{if(!c)return;let e=setTimeout(()=>l(!1),2e3);return()=>clearTimeout(e)},[c]),(0,N.jsx)(p,{onClose:r,"aria-label":e.name,children:(0,N.jsxs)(`div`,{"data-testid":`skill-detail-modal`,"data-skill-name":e.name,className:`relative bg-base-secondary p-6 rounded-xl flex flex-col gap-4 border border-[var(--oh-border)] w-[520px] max-w-[90vw] max-h-[85vh] overflow-y-auto custom-scrollbar`,children:[(0,N.jsx)(g,{onClose:r,testId:`skill-detail-modal-close`}),(0,N.jsxs)(`div`,{className:`flex items-start gap-3 pr-6`,children:[(0,N.jsx)(P,{skillName:e.name}),(0,N.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,N.jsx)(`h2`,{"data-testid":`skill-modal-name-${e.name}`,className:m,children:e.name}),e.source?(0,N.jsxs)(`div`,{className:`mt-0.5 flex min-w-0 items-center gap-1`,children:[(0,N.jsx)(`p`,{"data-testid":`skill-modal-source-${e.name}`,className:`min-w-0 flex-1 truncate text-xs text-tertiary-alt`,title:e.source,children:e.source}),_?(0,N.jsx)(`button`,{type:`button`,"data-testid":`skill-modal-copy-source-${e.name}`,"aria-label":a(c?i.BUTTON$COPIED:i.SETTINGS$SKILLS_COPY_PATH),disabled:c,onClick:async()=>{e.source&&(await navigator.clipboard.writeText(e.source),l(!0))},className:`shrink-0 cursor-pointer border-0 bg-transparent p-0.5 text-tertiary-alt hover:text-white disabled:cursor-default [&_path]:fill-current`,children:c?(0,N.jsx)(T,{width:12,height:12}):(0,N.jsx)(D,{width:12,height:12})}):null]}):null]})]}),(0,N.jsx)(`div`,{"data-testid":`skill-modal-enable-row-${e.name}`,className:`flex w-full items-center rounded-lg border border-[var(--oh-border)] bg-[rgba(255,255,255,0.04)] px-3 py-2.5`,children:(0,N.jsx)(S,{testId:`skill-modal-toggle-${e.name}`,isToggled:t,onToggle:n,togglePosition:`right`,children:a(t?i.SETTINGS$SKILLS_ENABLED:i.SETTINGS$SKILLS_DISABLED)})}),d?(0,N.jsx)(`p`,{"data-testid":`skill-modal-description-${e.name}`,className:`text-xs text-tertiary-light`,children:d}):null,f.length>0?(0,N.jsx)(C,{pills:f,testId:`skill-modal-pills-${e.name}`}):null,e.content?(0,N.jsx)(q,{testId:`skill-modal-field-content-${e.name}`,label:a(i.SETTINGS$SKILLS_CONTENT),value:e.content}):null,(0,N.jsxs)(`div`,{className:`mt-2 flex justify-end gap-2`,children:[(0,N.jsx)(h,{type:`button`,variant:`secondary`,onClick:r,testId:`skill-detail-close`,children:a(i.BUTTON$CLOSE)}),(0,N.jsx)(h,{type:`button`,variant:`primary`,isDisabled:!t,onClick:()=>s(u,r),testId:`skill-detail-use-skill-${e.name}`,startContent:(0,N.jsx)(k,{className:`size-4`,"aria-hidden":!0}),children:a(i.SETTINGS$SKILLS_USE_SKILL_BUTTON)})]})]})})}var Y=[i.SETTINGS$SKILLS_ADD_MODAL_STEP_1,i.SETTINGS$SKILLS_ADD_MODAL_STEP_2,i.SETTINGS$SKILLS_ADD_MODAL_STEP_3,i.SETTINGS$SKILLS_ADD_MODAL_STEP_4,i.SETTINGS$SKILLS_ADD_MODAL_STEP_5],X={cmd:(0,N.jsx)(Z,{}),path:(0,N.jsx)(Z,{}),env:(0,N.jsx)(Z,{})};function Z({children:e}){return(0,N.jsx)(`code`,{className:f(`mx-0.5 inline-block rounded-sm border border-[var(--oh-border-subtle)]`,`bg-[var(--oh-surface-raised)] px-1.5 py-0.5 align-baseline font-mono text-[11px] text-white`),children:e})}function ie(){let{t:e}=o(`openhands`),[t,n]=M.useState(!1);return M.useEffect(()=>{if(!t)return;let e=setTimeout(()=>n(!1),2e3);return()=>clearTimeout(e)},[t]),(0,N.jsxs)(`div`,{className:`relative`,children:[(0,N.jsx)(`pre`,{"data-testid":`add-skill-modal-example`,className:f(`overflow-x-auto rounded-sm border border-[var(--oh-border-subtle)]`,`bg-[var(--oh-surface-raised)] p-2 pr-10 text-xs text-white`),children:G}),(0,N.jsx)(`button`,{type:`button`,"data-testid":`add-skill-modal-example-copy`,"aria-label":e(t?i.BUTTON$COPIED:i.BUTTON$COPY),disabled:t,onClick:async()=>{await navigator.clipboard.writeText(G),n(!0)},className:f(`absolute right-2 top-2 cursor-pointer rounded-sm border border-[var(--oh-border-subtle)]`,`bg-base-secondary p-1 text-tertiary-alt transition-colors`,`hover:bg-[var(--oh-surface)] hover:text-white disabled:cursor-default [&_path]:fill-current`),children:t?(0,N.jsx)(T,{width:14,height:14}):(0,N.jsx)(D,{width:14,height:14})})]})}function Q({i18nKey:e}){return(0,N.jsx)(`p`,{className:`text-xs leading-relaxed text-tertiary-light`,children:(0,N.jsx)(a,{ns:`openhands`,i18nKey:e,components:X})})}function ae({onClose:e}){let{t}=o(`openhands`);return(0,N.jsx)(p,{onClose:e,"aria-label":t(i.SETTINGS$SKILLS_ADD_MODAL_TITLE),children:(0,N.jsxs)(`div`,{"data-testid":`add-skill-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,N.jsx)(g,{onClose:e,testId:`add-skill-modal-close`}),(0,N.jsxs)(`header`,{className:`flex-shrink-0 px-6 pb-4 pt-6`,children:[(0,N.jsx)(`h2`,{className:f(`pr-6`,m),children:t(i.SETTINGS$SKILLS_ADD_MODAL_TITLE)}),(0,N.jsx)(`p`,{className:`mt-4 text-sm text-tertiary-light`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_INTRO)})]}),(0,N.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto px-6 custom-scrollbar`,children:[(0,N.jsxs)(`section`,{className:`flex flex-col gap-2`,children:[(0,N.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_CHAT_TITLE)}),(0,N.jsx)(Q,{i18nKey:i.SETTINGS$SKILLS_ADD_MODAL_CHAT_BODY}),(0,N.jsx)(`p`,{className:`text-xs text-tertiary-light`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_EXAMPLE_LABEL)}),(0,N.jsx)(ie,{}),(0,N.jsx)(`ol`,{className:`list-decimal space-y-1 pl-4 text-xs leading-relaxed text-tertiary-light`,children:Y.map(e=>(0,N.jsx)(`li`,{children:e===i.SETTINGS$SKILLS_ADD_MODAL_STEP_3?(0,N.jsx)(a,{ns:`openhands`,i18nKey:e,components:X}):t(e)},e))})]}),(0,N.jsxs)(`section`,{className:`flex flex-col gap-1`,children:[(0,N.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_URL_FORMATS_TITLE)}),(0,N.jsx)(`p`,{className:`text-xs leading-relaxed text-tertiary-light`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_URL_FORMATS)})]}),(0,N.jsxs)(`section`,{className:`flex flex-col gap-1`,children:[(0,N.jsx)(`h3`,{className:`text-sm font-semibold text-foreground`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_STORAGE_TITLE)}),(0,N.jsx)(Q,{i18nKey:i.SETTINGS$SKILLS_ADD_MODAL_STORAGE_BODY})]}),(0,N.jsx)(Q,{i18nKey:i.SETTINGS$SKILLS_ADD_MODAL_PRIVATE_REPOS}),(0,N.jsx)(`a`,{href:W,target:`_blank`,rel:`noreferrer`,"data-testid":`add-skill-modal-docs-link`,className:`self-start text-xs text-[var(--oh-muted)] transition-colors hover:text-white hover:underline`,children:t(i.SETTINGS$SKILLS_ADD_MODAL_VIEW_DOCS)})]}),(0,N.jsx)(`footer`,{className:`flex flex-shrink-0 justify-end gap-2 px-6 pb-6 pt-4`,children:(0,N.jsx)(h,{type:`button`,variant:`secondary`,onClick:e,testId:`add-skill-modal-dismiss`,children:t(i.BUTTON$CLOSE)})})]})})}var oe=[`all`,`agentskills`,`knowledge`,`repo`],$={all:i.SETTINGS$SKILLS_TYPE_ALL,agentskills:i.SETTINGS$SKILLS_TYPE_AGENTSKILLS,knowledge:i.SETTINGS$SKILLS_TYPE_KNOWLEDGE,repo:i.SETTINGS$SKILLS_TYPE_REPO};function se({value:e,onChange:t}){return(0,N.jsx)(j,{testId:`skills-type-filter`,value:e,onChange:t,options:oe,labelKeyByValue:$})}function ce({search:e,onSearchChange:t,typeFilter:n,onTypeFilterChange:r}){let{t:a}=o(`openhands`);return(0,N.jsxs)(`div`,{"data-testid":`skills-toolbar`,className:`flex items-stretch gap-2`,children:[(0,N.jsxs)(`div`,{className:f(`relative flex flex-1 min-w-0 items-center`,`rounded-lg border border-[var(--oh-border)] bg-base-secondary`,`focus-within:border-white/40 focus-within:ring-1 focus-within:ring-white/20`,`transition-colors`),children:[(0,N.jsx)(u,{className:`ml-3 h-4 w-4 shrink-0 text-tertiary-alt`,"aria-hidden":!0}),(0,N.jsx)(`input`,{"data-testid":`skills-search-input`,type:`search`,value:e,onChange:e=>t(e.target.value),placeholder:a(i.SETTINGS$SKILLS_SEARCH_PLACEHOLDER),"aria-label":a(i.SETTINGS$SKILLS_SEARCH_PLACEHOLDER),className:f(`flex-1 min-w-0 bg-transparent border-0 outline-none`,`px-3 py-2 text-sm placeholder:text-tertiary-alt`,`[&::-webkit-search-cancel-button]:hidden`)}),e?(0,N.jsx)(`button`,{type:`button`,onClick:()=>t(``),"aria-label":`Clear search`,className:`mr-2 p-1 rounded text-tertiary-alt hover:text-white cursor-pointer`,children:(0,N.jsx)(d,{className:`h-4 w-4`,"aria-hidden":!0})}):null]}),(0,N.jsx)(se,{value:n,onChange:r})]})}function le(e,t){if(!t)return!0;let n=[e.name,I(e),e.description??``,e.content??``,e.license??``,e.compatibility??``,...e.triggers??[],...e.allowed_tools??[]],r=t.toLowerCase();return n.some(e=>e.toLowerCase().includes(r))}function ue(){let{t:e}=o(`openhands`),{mutate:t}=y(),{data:n,isLoading:r}=_(),{data:a,isLoading:l}=E(),[u,d]=M.useState(new Set),[p,m]=M.useState(!1),[g,v]=M.useState(``),[b,x]=M.useState(`all`),[S,C]=M.useState(null),[w,T]=M.useState(!1);M.useEffect(()=>{r||!n||(d(new Set(n.disabled_skills??[])),m(!0))},[r,n?.disabled_skills]);let D=(e,t)=>{d(n=>{let r=new Set(n);return t?r.delete(e):r.add(e),r})};M.useEffect(()=>{p&&t({disabled_skills:Array.from(u)},{onError:t=>{c(s(t)||e(i.ERROR$GENERIC))}})},[u,p,t,e]);let k=r||l||!n,A=M.useMemo(()=>a?a.filter(e=>(b===`all`||e.type===b)&&le(e,g)):[],[a,b,g]);return(0,N.jsxs)(`div`,{"data-testid":`skills-settings-screen`,className:`flex h-full gap-4 md:gap-6 md:pl-8 lg:gap-10 lg:pl-10`,children:[(0,N.jsx)(O,{}),(0,N.jsx)(`main`,{className:f(ee,`h-full`),children:(0,N.jsxs)(`div`,{className:`mx-auto flex w-full min-w-0 max-w-[800px] flex-col gap-6`,children:[(0,N.jsxs)(`div`,{className:`flex min-w-0 items-start justify-between gap-4`,children:[(0,N.jsxs)(`div`,{className:`min-w-0 space-y-1`,children:[(0,N.jsx)(`h2`,{className:`text-xl font-semibold leading-6 text-foreground`,children:e(i.SETTINGS$SKILLS_TITLE)}),(0,N.jsx)(`div`,{"data-testid":`skills-settings-description`,className:`max-w-2xl text-sm text-tertiary-light`,children:e(i.SETTINGS$SKILLS_PAGE_DESCRIPTION)})]}),(0,N.jsx)(h,{type:`button`,variant:`secondary`,testId:`skills-add-skill-button`,className:`flex-shrink-0 whitespace-nowrap`,onClick:()=>T(!0),children:e(i.SETTINGS$SKILLS_ADD_BUTTON)})]}),k&&(0,N.jsx)(`div`,{className:`flex flex-col gap-4`,children:[1,2,3].map(e=>(0,N.jsx)(`div`,{className:`h-24 rounded-2xl bg-tertiary animate-pulse`},e))}),!k&&(!a||a.length===0)&&(0,N.jsx)(`div`,{"data-testid":`skills-empty`,className:`rounded-xl border border-[var(--oh-border)] p-8 text-center`,children:(0,N.jsx)(`p`,{className:`text-sm text-tertiary-light`,children:e(i.SETTINGS$SKILLS_NO_SKILLS)})}),!k&&a&&a.length>0&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(ce,{search:g,onSearchChange:v,typeFilter:b,onTypeFilterChange:x}),A.length===0?(0,N.jsx)(`div`,{"data-testid":`skills-no-match`,className:`rounded-xl border border-[var(--oh-border)] p-8 text-center`,children:(0,N.jsx)(`p`,{className:`text-sm text-tertiary-light`,children:e(i.SETTINGS$SKILLS_NO_MATCH)})}):(0,N.jsx)(`section`,{className:f(`flex min-w-0 flex-col gap-3`,`@container min-w-0 w-full`),children:(0,N.jsx)(`div`,{className:`grid min-w-0 grid-cols-1 gap-3 @min-[600px]:grid-cols-2`,children:A.map(e=>(0,N.jsx)(U,{skill:e,enabled:!u.has(e.name),onOpen:()=>C(e),onToggle:t=>D(e.name,t)},e.name))})})]}),S&&(0,N.jsx)(J,{skill:S,enabled:!u.has(S.name),onToggle:e=>D(S.name,e),onClose:()=>C(null)}),w&&(0,N.jsx)(ae,{onClose:()=>T(!1)})]})})]})}var de=n(ue);export{de as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n}from"./declaration-D9ucT0fq.js";import{t as r}from"./utils-eXk6yerZ.js";import{t as i}from"./vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~mcp~~ceijy54y-Dkd2wxJA.js";var a=e(t(),1),o=n();function s(e){return a.Children.count(e)===1&&a.isValidElement(e)?e:(0,o.jsx)(`span`,{className:`inline-flex`,children:e})}function c({children:e,content:t,tooltipClassName:n,placement:a=`right`,showArrow:c=!1,closeDelay:l=100,shouldFlip:u,offset:d=7}){return(0,o.jsx)(i,{content:t,closeDelay:l,placement:a,offset:d,shouldFlip:u,className:r(`bg-white text-black`,n),showArrow:c,disableAnimation:!1,classNames:{content:r(`z-[9999] rounded-md px-2 py-1 text-xs font-medium shadow-md`,`!bg-white !text-black`,n)},children:s(e)})}export{c as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{C as n,D as r,E as i,O as a,S as o,_ as s,c,k as l,l as u,m as d,n as f,u as p,w as m,x as h,y as g}from"./vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~extensions~dqseey1n-D_BSEDk4.js";import{o as _}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{C as n,D as r,E as i,O as a,S as o,_ as s,c,k as l,l as u,m as d,n as f,u as p,w as m,x as h,y as g}from"./vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~extensions~dqseey1n-D_BSEDk4.js";import{o as _}from"./declaration-D9ucT0fq.js";var v=class extends l{constructor(e,t){super(),this.options=t,this.#e=e,this.#s=null,this.#o=u(),this.bindMethods(),this.setOptions(t)}#e;#t=void 0;#n=void 0;#r=void 0;#i;#a;#o;#s;#c;#l;#u;#d;#f;#p;#m=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),b(this.#t,this.options)?this.#h():this.updateResult(),this.#y())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return x(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return x(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#b(),this.#x(),this.#t.removeObserver(this)}setOptions(e){let t=this.options,r=this.#t;if(this.options=this.#e.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!=`boolean`&&typeof this.options.enabled!=`function`&&typeof h(this.options.enabled,this.#t)!=`boolean`)throw Error(`Expected enabled to be a boolean or a callback that returns a boolean`);this.#S(),this.#t.setOptions(this.options),t._defaulted&&!n(this.options,t)&&this.#e.getQueryCache().notify({type:`observerOptionsUpdated`,query:this.#t,observer:this});let i=this.hasListeners();i&&S(this.#t,r,this.options,t)&&this.#h(),this.updateResult(),i&&(this.#t!==r||h(this.options.enabled,this.#t)!==h(t.enabled,this.#t)||o(this.options.staleTime,this.#t)!==o(t.staleTime,this.#t))&&this.#g();let a=this.#_();i&&(this.#t!==r||h(this.options.enabled,this.#t)!==h(t.enabled,this.#t)||a!==this.#p)&&this.#v(a)}getOptimisticResult(e){let t=this.#e.getQueryCache().build(this.#e,e),n=this.createResult(t,e);return w(this,n)&&(this.#r=n,this.#a=this.options,this.#i=this.#t.state),n}getCurrentResult(){return this.#r}trackResult(e,t){return new Proxy(e,{get:(e,n)=>(this.trackProp(n),t?.(n),n===`promise`&&(this.trackProp(`data`),!this.options.experimental_prefetchInRender&&this.#o.status===`pending`&&this.#o.reject(Error(`experimental_prefetchInRender feature flag is not enabled`))),Reflect.get(e,n))})}trackProp(e){this.#m.add(e)}getCurrentQuery(){return this.#t}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){let t=this.#e.defaultQueryOptions(e),n=this.#e.getQueryCache().build(this.#e,t);return n.fetch().then(()=>this.createResult(n,t))}fetch(e){return this.#h({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#r))}#h(e){this.#S();let t=this.#t.fetch(this.options,e);return e?.throwOnError||(t=t.catch(s)),t}#g(){this.#b();let e=o(this.options.staleTime,this.#t);if(p.isServer()||this.#r.isStale||!d(e))return;let t=i(this.#r.dataUpdatedAt,e)+1;this.#d=r.setTimeout(()=>{this.#r.isStale||this.updateResult()},t)}#_(){return(typeof this.options.refetchInterval==`function`?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(e){this.#x(),this.#p=e,!(p.isServer()||h(this.options.enabled,this.#t)===!1||!d(this.#p)||this.#p===0)&&(this.#f=r.setInterval(()=>{(this.options.refetchIntervalInBackground||a.isFocused())&&this.#h()},this.#p))}#y(){this.#g(),this.#v(this.#_())}#b(){this.#d!==void 0&&(r.clearTimeout(this.#d),this.#d=void 0)}#x(){this.#f!==void 0&&(r.clearInterval(this.#f),this.#f=void 0)}createResult(e,t){let n=this.#t,r=this.options,i=this.#r,a=this.#i,o=this.#a,s=e===n?this.#n:e.state,{state:c}=e,l={...c},d=!1,p;if(t._optimisticResults){let i=this.hasListeners(),a=!i&&b(e,t),o=i&&S(e,n,t,r);(a||o)&&(l={...l,...f(c.data,e.options)}),t._optimisticResults===`isRestoring`&&(l.fetchStatus=`idle`)}let{error:m,errorUpdatedAt:_,status:v}=l;p=l.data;let y=!1;if(t.placeholderData!==void 0&&p===void 0&&v===`pending`){let e;i?.isPlaceholderData&&t.placeholderData===o?.placeholderData?(e=i.data,y=!0):e=typeof t.placeholderData==`function`?t.placeholderData(this.#u?.state.data,this.#u):t.placeholderData,e!==void 0&&(v=`success`,p=g(i?.data,e,t),d=!0)}if(t.select&&p!==void 0&&!y)if(i&&p===a?.data&&t.select===this.#c)p=this.#l;else try{this.#c=t.select,p=t.select(p),p=g(i?.data,p,t),this.#l=p,this.#s=null}catch(e){this.#s=e}this.#s&&(m=this.#s,p=this.#l,_=Date.now(),v=`error`);let x=l.fetchStatus===`fetching`,w=v===`pending`,T=v===`error`,E=w&&x,D=p!==void 0,O={status:v,fetchStatus:l.fetchStatus,isPending:w,isSuccess:v===`success`,isError:T,isInitialLoading:E,isLoading:E,data:p,dataUpdatedAt:l.dataUpdatedAt,error:m,errorUpdatedAt:_,failureCount:l.fetchFailureCount,failureReason:l.fetchFailureReason,errorUpdateCount:l.errorUpdateCount,isFetched:e.isFetched(),isFetchedAfterMount:l.dataUpdateCount>s.dataUpdateCount||l.errorUpdateCount>s.errorUpdateCount,isFetching:x,isRefetching:x&&!w,isLoadingError:T&&!D,isPaused:l.fetchStatus===`paused`,isPlaceholderData:d,isRefetchError:T&&D,isStale:C(e,t),refetch:this.refetch,promise:this.#o,isEnabled:h(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){let t=O.data!==void 0,r=O.status===`error`&&!t,i=e=>{r?e.reject(O.error):t&&e.resolve(O.data)},a=()=>{i(this.#o=O.promise=u())},o=this.#o;switch(o.status){case`pending`:e.queryHash===n.queryHash&&i(o);break;case`fulfilled`:(r||O.data!==o.value)&&a();break;case`rejected`:(!r||O.error!==o.reason)&&a();break}}return O}updateResult(){let e=this.#r,t=this.createResult(this.#t,this.options);this.#i=this.#t.state,this.#a=this.options,this.#i.data!==void 0&&(this.#u=this.#t),!n(t,e)&&(this.#r=t,this.#C({listeners:(()=>{if(!e)return!0;let{notifyOnChangeProps:t}=this.options,n=typeof t==`function`?t():t;if(n===`all`||!n&&!this.#m.size)return!0;let r=new Set(n??this.#m);return this.options.throwOnError&&r.add(`error`),Object.keys(this.#r).some(t=>{let n=t;return this.#r[n]!==e[n]&&r.has(n)})})()}))}#S(){let e=this.#e.getQueryCache().build(this.#e,this.options);if(e===this.#t)return;let t=this.#t;this.#t=e,this.#n=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#y()}#C(e){c.batch(()=>{e.listeners&&this.listeners.forEach(e=>{e(this.#r)}),this.#e.getQueryCache().notify({query:this.#t,type:`observerResultsUpdated`})})}};function y(e,t){return h(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status===`error`&&h(t.retryOnMount,e)===!1)}function b(e,t){return y(e,t)||e.state.data!==void 0&&x(e,t,t.refetchOnMount)}function x(e,t,n){if(h(t.enabled,e)!==!1&&o(t.staleTime,e)!==`static`){let r=typeof n==`function`?n(e):n;return r===`always`||r!==!1&&C(e,t)}return!1}function S(e,t,n,r){return(e!==t||h(r.enabled,e)===!1)&&(!n.suspense||e.state.status!==`error`)&&C(e,n)}function C(e,t){return h(t.enabled,e)!==!1&&e.isStaleByTime(o(t.staleTime,e))}function w(e,t){return!n(e.getCurrentResult(),t)}var T=e(t(),1),E=T.createContext(!1),D=()=>T.useContext(E);E.Provider,_();function O(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var k=T.createContext(O()),A=()=>T.useContext(k),j=(e,t,n)=>{let r=n?.state.error&&typeof e.throwOnError==`function`?m(e.throwOnError,[n.state.error,n]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||r)&&(t.isReset()||(e.retryOnMount=!1))},M=e=>{T.useEffect(()=>{e.clearReset()},[e])},N=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(i&&e.data===void 0||m(n,[e.error,r])),P=e=>{if(e.suspense){let t=1e3,n=e=>e===`static`?e:Math.max(e??t,t),r=e.staleTime;e.staleTime=typeof r==`function`?(...e)=>n(r(...e)):n(r),typeof e.gcTime==`number`&&(e.gcTime=Math.max(e.gcTime,t))}},F=(e,t)=>e.isLoading&&e.isFetching&&!t,I=(e,t)=>e?.suspense&&t.isPending,L=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});export{j as a,A as c,F as i,D as l,L as n,N as o,I as r,M as s,P as t,v as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./declaration-
|
|
1
|
+
import{o as e}from"./declaration-D9ucT0fq.js";var t=e();function n(){return(0,t.jsxs)(`div`,{className:`flex flex-col gap-2.5`,children:[(0,t.jsx)(`div`,{className:`w-[70px] h-[20px] skeleton`}),(0,t.jsx)(`div`,{className:`w-full min-w-0 h-[40px] skeleton`})]})}function r(){return(0,t.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,t.jsx)(`div`,{className:`w-[48px] h-[24px] skeleton-round`}),(0,t.jsx)(`div`,{className:`w-[100px] h-[20px] skeleton`})]})}export{n,r as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BFRubm34.js";import{t}from"./react-CM_dJw1Z.js";import{o as n,t as r}from"./declaration-D9ucT0fq.js";import{t as i}from"./useTranslation-CL6FTf1b.js";import{t as a}from"./utils-eXk6yerZ.js";import{r as o}from"./typography-BLSEGjph.js";import{t as s}from"./u-check-circle-dG_VJqx5.js";import{n as c,t as l}from"./u-check-circle-half-D-5ZPRnd.js";import{t as u}from"./use-task-list-E5t-jtgs.js";import{t as d}from"./conversation-tab-empty-state-C8tztloo.js";var f=e(t(),1),p=n();function m({task:e}){let{t}=i(`openhands`),n=(0,f.useMemo)(()=>{switch(e.status){case`todo`:return(0,p.jsx)(c,{className:`w-4 h-4 text-[#ffffff]`});case`in_progress`:return(0,p.jsx)(l,{className:`w-4 h-4 text-[#ffffff]`});case`done`:return(0,p.jsx)(s,{className:`w-4 h-4 text-[var(--oh-muted)]`});default:return(0,p.jsx)(c,{className:`w-4 h-4 text-[#ffffff]`})}},[e.status]),u=e.status===`done`;return(0,p.jsxs)(`div`,{className:`flex gap-2 items-center w-full`,"data-name":`item`,children:[(0,p.jsx)(`div`,{className:`shrink-0`,children:n}),(0,p.jsxs)(`div`,{className:`flex flex-col items-start justify-center leading-[16px] text-nowrap whitespace-pre font-normal`,children:[(0,p.jsx)(o.Text,{className:a(`text-[12px]`,u?`text-[var(--oh-muted)]`:`text-white`),children:e.title}),e.notes&&(0,p.jsxs)(o.Text,{className:`text-[10px] text-[var(--oh-muted)]`,children:[t(r.TASK_TRACKING_OBSERVATION$TASK_NOTES),`: `,e.notes]})]})]})}function h(){let{t:e}=i(`openhands`),{taskList:t}=u();return t.length===0?(0,p.jsx)(d,{icon:(0,p.jsx)(s,{}),children:e(r.COMMON$NO_TASKS)}):(0,p.jsx)(`main`,{className:`h-full overflow-y-auto flex flex-col custom-scrollbar-always`,children:t.map(e=>(0,p.jsx)(`div`,{"data-active":e.status===`in_progress`?`true`:`false`,className:a(`px-4 py-2`,e.status===`in_progress`&&`bg-[var(--oh-surface-raised)]`),children:(0,p.jsx)(m,{task:e})},e.id))})}export{h as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~skills-set~lpdshwee-Cl4h-NSi.js","assets/rolldown-runtime-BFRubm34.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{t as e}from"./preload-helper-CT1Z6Pdu.js";var t={name:`@openhands/agent-canvas`,version:`1.0.0-rc.
|
|
2
|
+
import{t as e}from"./preload-helper-CT1Z6Pdu.js";var t={name:`@openhands/agent-canvas`,version:`1.0.0-rc.8`,description:`Agent Canvas UI for OpenHands - run AI coding agents with a visual interface`,license:`MIT`,private:!1,type:`module`,repository:{type:`git`,url:`https://github.com/OpenHands/agent-canvas`},homepage:`https://github.com/OpenHands/agent-canvas#readme`,bugs:{url:`https://github.com/OpenHands/agent-canvas/issues`},bin:{"agent-canvas":`bin/agent-canvas.mjs`},engines:{node:`>=22.12.0`},dependencies:{"@heroui/react":`2.8.10`,"@microlink/react-json-view":`1.31.20`,"@monaco-editor/react":`4.7.0`,"@openhands/extensions":`0.4.1`,"@openhands/typescript-client":`1.24.3`,"@react-router/node":`7.17.0`,"@react-router/serve":`7.17.0`,"@tailwindcss/vite":`4.2.4`,"@tanstack/react-query":`5.100.9`,"@types/shell-quote":`^1.7.5`,"@uidotdev/usehooks":`2.4.1`,"@xterm/addon-fit":`0.11.0`,"@xterm/xterm":`6.0.0`,axios:`1.16.0`,"class-variance-authority":`0.7.1`,clsx:`2.1.1`,downshift:`9.3.2`,"framer-motion":`12.38.0`,i18next:`26.0.8`,"i18next-browser-languagedetector":`8.2.1`,"i18next-http-backend":`4.0.0`,isbot:`5.1.39`,"lucide-react":`1.14.0`,"monaco-editor":`0.55.1`,"posthog-js":`1.372.6`,react:`19.2.5`,"react-dom":`19.2.5`,"react-hot-toast":`2.6.0`,"react-i18next":`17.0.6`,"react-icons":`5.6.0`,"react-markdown":`10.1.0`,"react-router":`7.17.0`,"react-syntax-highlighter":`16.1.1`,"rehype-raw":`7.0.0`,"rehype-sanitize":`6.0.0`,"remark-breaks":`4.0.0`,"remark-gfm":`4.0.1`,"shell-quote":`^1.8.3`,"sirv-cli":`3.0.1`,"socket.io-client":`4.8.3`,"tailwind-merge":`3.5.0`,"tailwind-scrollbar":`4.0.2`,"unist-util-visit":`5.1.0`,uuid:`14.0.0`,vite:`8.0.10`,winston:`^3.19.0`,"winston-daily-rotate-file":`^5.0.0`,zustand:`5.0.12`},scripts:{dev:`node --env-file-if-exists=.env scripts/dev-with-automation.mjs`,"dev:static":`node --env-file-if-exists=.env scripts/dev-static.mjs`,"dev:extra-backend":`node --env-file-if-exists=.env scripts/dev-extra-backend.mjs`,"dev:minimal":`node --env-file-if-exists=.env scripts/dev-safe.mjs`,"dev:frontend":`npm run make-i18n && cross-env VITE_MOCK_API=false react-router dev`,"dev:mock":`npm run make-i18n && cross-env VITE_MOCK_API=true react-router dev`,build:`npm run build:app`,"build:mock":`npm run make-i18n && cross-env VITE_MOCK_API=true react-router build`,start:`npx sirv-cli build/ --single`,test:`npm run make-i18n && vitest run`,"test:e2e":`playwright test --pass-with-no-tests`,"test:e2e:live":`node --env-file-if-exists=.env tests/e2e/live/scripts/run-live-e2e.mjs`,"test:e2e:mock-llm":`playwright test --config=playwright.mock-llm.config.ts`,"test:e2e:mock-llm:docker":`playwright test --config=playwright.mock-llm-docker.config.ts`,"test:e2e:snapshots":`playwright test tests/e2e/snapshots --project=chromium --retries=0`,"test:e2e:snapshots:update":`playwright test tests/e2e/snapshots --project=chromium --update-snapshots`,"test:coverage":`npm run make-i18n && vitest run --coverage`,dev_wsl:`VITE_WATCH_USE_POLLING=true vite`,preview:`vite preview`,"make-i18n":`node scripts/make-i18n-translations.cjs`,prelint:`npm run make-i18n`,lint:`npm run typecheck && eslint src && prettier --check src/**/*.{ts,tsx}`,"lint:fix":`eslint src --fix && prettier --write src/**/*.{ts,tsx}`,prepare:`husky`,typecheck:`react-router typegen && tsc`,"typecheck:staged":`react-router typegen && npx tsc --noEmit --skipLibCheck`,"check-translation-completeness":`node scripts/check-translation-completeness.cjs`,"build:app":`npm run make-i18n && react-router build`,"build:lib":`npm run make-i18n && react-router typegen && cross-env BUILD_LIB=true VITE_APP_ENV=production vite build && tsc -p tsconfig.lib.json`,"build:docker":`node scripts/docker-build.mjs`},"lint-staged":{"src/**/*.{ts,tsx,js}":[`eslint --fix`,`prettier --write`],"src/**/*.{ts,tsx}":[`bash -c 'npm run typecheck:staged'`],"src/**/*":[`npm run check-translation-completeness`]},devDependencies:{"@eslint/eslintrc":`3.3.1`,"@eslint/js":`9.39.4`,"@mswjs/socket.io-binding":`0.2.0`,"@playwright/test":`1.59.1`,"@react-router/dev":`7.17.0`,"@tailwindcss/typography":`0.5.19`,"@tanstack/eslint-plugin-query":`5.100.9`,"@testing-library/dom":`10.4.1`,"@testing-library/jest-dom":`6.9.1`,"@testing-library/react":`16.3.2`,"@testing-library/user-event":`14.6.1`,"@types/mdast":`4.0.4`,"@types/node":`25.6.0`,"@types/react":`19.2.14`,"@types/react-dom":`19.2.3`,"@types/react-syntax-highlighter":`15.5.13`,"@typescript-eslint/eslint-plugin":`8.59.2`,"@typescript-eslint/parser":`8.59.2`,"@vercel/react-router":`1.3.0`,"@vitest/coverage-v8":`4.1.5`,"cross-env":`10.1.0`,eslint:`9.39.4`,"eslint-config-prettier":`10.1.8`,"eslint-import-resolver-typescript":`4.4.4`,"eslint-plugin-i18next":`6.1.4`,"eslint-plugin-import-x":`4.16.2`,"eslint-plugin-jsx-a11y":`6.10.2`,"eslint-plugin-prettier":`5.5.5`,"eslint-plugin-react":`7.37.5`,"eslint-plugin-react-hooks":`7.1.1`,"eslint-plugin-unused-imports":`4.4.1`,globals:`16.5.0`,husky:`9.1.7`,jsdom:`29.1.1`,"lint-staged":`16.4.0`,msw:`2.14.2`,"postcss-prefix-selector":`2.1.1`,prettier:`3.8.3`,tailwindcss:`4.2.4`,typescript:`6.0.3`,"vite-plugin-svgr":`5.2.0`,vitest:`4.1.5`},packageManager:`npm@10.5.0`,volta:{node:`22.12.0`},msw:{workerDirectory:[`public`]},overrides:{"@vercel/static-config":{ajv:`8.20.0`},dompurify:`3.4.7`},main:`./dist/index.cjs`,module:`./dist/index.js`,types:`./dist/index.d.ts`,files:[`dist`,`bin`,`build`,`config`,`scripts`,`tools`],exports:{".":{types:`./dist/index.d.ts`,import:`./dist/index.js`,require:`./dist/index.cjs`},"./browser":{types:`./dist/components/browser/index.d.ts`,import:`./dist/components/browser/index.js`,require:`./dist/components/browser/index.cjs`},"./conversation":{types:`./dist/components/conversation/index.d.ts`,import:`./dist/components/conversation/index.js`,require:`./dist/components/conversation/index.cjs`},"./files":{types:`./dist/components/files/index.d.ts`,import:`./dist/components/files/index.js`,require:`./dist/components/files/index.cjs`},"./settings":{types:`./dist/components/settings/index.d.ts`,import:`./dist/components/settings/index.js`,require:`./dist/components/settings/index.cjs`},"./sidebar":{types:`./dist/components/sidebar/index.d.ts`,import:`./dist/components/sidebar/index.js`,require:`./dist/components/sidebar/index.cjs`},"./terminal":{types:`./dist/components/terminal/index.d.ts`,import:`./dist/components/terminal/index.js`,require:`./dist/components/terminal/index.cjs`},"./i18n":{types:`./dist/i18n/index.d.ts`,import:`./dist/i18n/index.js`,require:`./dist/i18n/index.cjs`},"./package.json":`./package.json`},peerDependencies:{react:`19.2.5`,"react-dom":`19.2.5`,"react-router":`7.17.0`}},n=`openhands-telemetry-consent`,r=`openhands-telemetry-first-use`,i=`openhands-telemetry-session`,a=`phc_kBtz5nKmxVRRQ7HtPwr2QX9eMC5j65zE86QKocVNwb4U`,o=`https://z.openhands.dev`,s=`https://us.posthog.com`,c=!1,l=null;function u(){return typeof window<`u`&&typeof localStorage<`u`}async function d(){if(!u())return null;if(l)return l;try{let{default:t}=await e(async()=>{let{default:e}=await import(`./vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~skills-set~lpdshwee-Cl4h-NSi.js`).then(e=>e.n);return{default:e}},__vite__mapDeps([0,1]));return l=t,t}catch{return null}}function f(){return typeof process<`u`&&{}?.DO_NOT_TRACK===`1`||typeof navigator<`u`&&(navigator.doNotTrack===`1`||typeof window<`u`&&window.doNotTrack===`1`)}async function p(e=!1){if(c)return l;let n=await d();return n?(n.init(a,{api_host:o,ui_host:s,opt_out_capturing_by_default:!e,capture_pageview:!1,autocapture:!1,persistence:`localStorage`,disable_session_recording:!0,loaded:e=>{e.register({package_name:t.name,package_version:t.version})}}),c=!0,n):null}function m(){if(!u())return`pending`;if(f())return`denied`;try{let e=localStorage.getItem(n);if(e===`granted`||e===`denied`)return e}catch{}return`pending`}async function h(e){if(u())try{localStorage.setItem(n,e);let t=await p();if(!t)return;e===`granted`?t.opt_in_capturing():t.opt_out_capturing()}catch{}}function g(){return m()===`granted`}function _(){if(!u())return!1;try{return localStorage.getItem(r)===`true`}catch{return!1}}function v(){if(u())try{localStorage.setItem(r,`true`)}catch{}}async function y(){if(f()||_())return;let e=await p(!0);e&&((e.has_opted_out_capturing?.()??!1)&&e.opt_in_capturing(),e.capture(`canvas_install`,{platform:typeof navigator<`u`?navigator.platform:`unknown`,user_agent:typeof navigator<`u`?navigator.userAgent:`unknown`,referrer:typeof document<`u`?document.referrer:``,url_origin:typeof window<`u`?window.location.origin:``,embedded:typeof window<`u`&&window.self!==window.top}),v(),m()!==`granted`&&e.opt_out_capturing())}function b(){if(!u())return!1;try{return sessionStorage.getItem(i)===`true`}catch{return!1}}function x(){if(u())try{sessionStorage.setItem(i,`true`)}catch{}}async function S(){if(!g()||b())return;let e=await p();e&&(e.capture(`canvas_new_session`,{is_first_use:!_()}),x())}async function C(e,t={}){if(!g())return;let n=await p();n&&n.capture(e,t)}async function w(){if(u())try{localStorage.removeItem(n),localStorage.removeItem(r),sessionStorage.removeItem(i),c&&l&&l.reset()}catch{}}export{y as a,C as i,m as n,S as o,h as r,w as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-
|
|
1
|
+
import"./rolldown-runtime-BFRubm34.js";import{t as e}from"./react-CM_dJw1Z.js";import{o as t}from"./declaration-D9ucT0fq.js";e();var n=t(),r=e=>(0,n.jsx)(`svg`,{viewBox:`0 0 18 18`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,n.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M2.25 1.125L1.125 2.25V15.75L2.25 16.875H15.75L16.875 15.75V2.25L15.75 1.125H2.25ZM2.25 15.75V2.25H15.75V15.75H2.25ZM6.492 12.7425L7.2705 13.5382L11.2155 9.606V8.922L7.2705 4.977L6.49425 5.772L9.93675 9.2985L6.492 12.7425Z`,fill:`currentColor`})});export{r as t};
|