decocms 4.182.2 → 4.182.4
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/dist/client/assets/{AlertCircle-BGrbeDYT.js → AlertCircle-aHUodbMz.js} +1 -1
- package/dist/client/assets/{AreaChart-ChjS34cq.js → AreaChart-B5lioxQz.js} +1 -1
- package/dist/client/assets/{ArrowUp-B7rh6W_b.js → ArrowUp-B1slVOB0.js} +1 -1
- package/dist/client/assets/{ArrowUpRight-An4hbib7.js → ArrowUpRight--mFpZoD0.js} +1 -1
- package/dist/client/assets/{Check-DpoXXYhc.js → Check-Bqqh9z-D.js} +1 -1
- package/dist/client/assets/{CheckCircle-DI16N69_.js → CheckCircle-2-UJ4CMp.js} +1 -1
- package/dist/client/assets/{ChevronDown-BbcA24KM.js → ChevronDown-DP1ievFt.js} +1 -1
- package/dist/client/assets/{ChevronRight-BamDO5gK.js → ChevronRight-D_oGoarw.js} +1 -1
- package/dist/client/assets/{ChevronUp-HIfNhOKS.js → ChevronUp-VBLtmSfp.js} +1 -1
- package/dist/client/assets/{Copy01-Bnz3Wx80.js → Copy01-C2PSDvbV.js} +1 -1
- package/dist/client/assets/{CpuChip01-BShcbCHO.js → CpuChip01-BKuPfNBn.js} +1 -1
- package/dist/client/assets/{CreditCard01-DNJmFfow.js → CreditCard01-C-gNn36M.js} +1 -1
- package/dist/client/assets/{DotsVertical-B_iya6B7.js → DotsVertical-CKKotJph.js} +1 -1
- package/dist/client/assets/{Eye-BjhopnZD.js → Eye-C4_fUR7p.js} +1 -1
- package/dist/client/assets/{FilterLines-H3se16dF.js → FilterLines-1LemGTNy.js} +1 -1
- package/dist/client/assets/{HardDrive-Cc0iy42M.js → HardDrive-B3cDKzGK.js} +1 -1
- package/dist/client/assets/{Key01-C21diL-t.js → Key01-DW19snbx.js} +1 -1
- package/dist/client/assets/{LayoutLeft-NGYALHZo.js → LayoutLeft-DT75DZge.js} +1 -1
- package/dist/client/assets/{LinkExternal01-BIYwVSjD.js → LinkExternal01-Cr_D6AUh.js} +1 -1
- package/dist/client/assets/{LogOut01-BYbHv1g4.js → LogOut01-CpinuBoH.js} +1 -1
- package/dist/client/assets/{Monitor01-PnI4BWSm.js → Monitor01-DE267NI6.js} +1 -1
- package/dist/client/assets/{Palette-DqKGGY7c.js → Palette-CFdqAyvh.js} +1 -1
- package/dist/client/assets/{Play-C6pKirQG.js → Play-DQaYqXyr.js} +1 -1
- package/dist/client/assets/{Plus-3NJoZ-Rn.js → Plus-CEsq76GY.js} +1 -1
- package/dist/client/assets/{SearchLg-DUoOTY_-.js → SearchLg-Ccn7y6_h.js} +1 -1
- package/dist/client/assets/{SearchMd-DZC0VFyz.js → SearchMd-Cp5X4j-4.js} +1 -1
- package/dist/client/assets/{Settings02-K87UDDa_.js → Settings02-B88nTmbo.js} +1 -1
- package/dist/client/assets/{Shield01-Dif9NKxP.js → Shield01-7HxK-TBP.js} +1 -1
- package/dist/client/assets/{Star01-BWcFSKod.js → Star01-CmKUJriU.js} +1 -1
- package/dist/client/assets/{Stars01-DNjCGctC.js → Stars01-dsVxW0Iw.js} +1 -1
- package/dist/client/assets/{Stars02-CF9PavPD.js → Stars02-CbWcKkha.js} +1 -1
- package/dist/client/assets/{Sun-D_TMYzXg.js → Sun-Iy-StK2g.js} +1 -1
- package/dist/client/assets/{SwitchHorizontal01-Boo6w6_t.js → SwitchHorizontal01-BJitQzy2.js} +1 -1
- package/dist/client/assets/{Tool01-BjfDVrJb.js → Tool01-2Qll6vRQ.js} +1 -1
- package/dist/client/assets/{Tool02-df-j-2i7.js → Tool02-CO5Ts7uk.js} +1 -1
- package/dist/client/assets/{Trash01-BfrFYc0O.js → Trash01-CxQJ-T3T.js} +1 -1
- package/dist/client/assets/{TrendUp01-Bj5u2ghc.js → TrendUp01-0XOYCeVZ.js} +1 -1
- package/dist/client/assets/{Upload01-DGoH2Bw8.js → Upload01-B8X2BCi1.js} +1 -1
- package/dist/client/assets/{User01-PHqRfaY2.js → User01-C8SW2dlc.js} +1 -1
- package/dist/client/assets/{Users01-CeRMXGJo.js → Users01-Dkku08eU.js} +1 -1
- package/dist/client/assets/{Users03-Cwqfteu1.js → Users03-CNHHA2CB.js} +1 -1
- package/dist/client/assets/{X-D0lgdZFx.js → X-2mQugttC.js} +1 -1
- package/dist/client/assets/{XCircle-BEfRA2Fy.js → XCircle-DcPzz_7R.js} +1 -1
- package/dist/client/assets/{XClose-Ca9PFBA7.js → XClose-DFzRbFQt.js} +1 -1
- package/dist/client/assets/{Zap-Cd4akcPN.js → Zap-BhuYnrjn.js} +1 -1
- package/dist/client/assets/{ZapSquare-2syNvY2F.js → ZapSquare-D8-2DhvZ.js} +1 -1
- package/dist/client/assets/{access-gate-BXHarpej.js → access-gate-BsORq1ML.js} +1 -1
- package/dist/client/assets/{add-section-modal-BtHF1Suz.js → add-section-modal-BDFcNPjF.js} +1 -1
- package/dist/client/assets/{agent-icon-CQRHN6rX.js → agent-icon-CXHCeTMr.js} +1 -1
- package/dist/client/assets/{agents-list-CwubhMUP.js → agents-list-B4JOoj6P.js} +1 -1
- package/dist/client/assets/ai-providers-DG3Wwjk6.js +1 -0
- package/dist/client/assets/{alert-Ig9SrjcF.js → alert-BrapZZ1e.js} +1 -1
- package/dist/client/assets/{alert-dialog-CWFjoJjX.js → alert-dialog-Dp0TwMS2.js} +3 -3
- package/dist/client/assets/app-editor-C5bR2kuD.js +1 -0
- package/dist/client/assets/{auth-av09Sk0f.js → auth-CVRtqdR-.js} +1 -1
- package/dist/client/assets/{auth-catchall-DWcWxlY6.js → auth-catchall-C5-vo66l.js} +1 -1
- package/dist/client/assets/{auth-entry-DOdCfRAO.js → auth-entry-DevPOjDG.js} +1 -1
- package/dist/client/assets/{auth-split-layout-CIY4l9vm.js → auth-split-layout-BWhd9bfi.js} +1 -1
- package/dist/client/assets/{authenticate-and-persist-oauth-CCHy3FzA.js → authenticate-and-persist-oauth-E6sLdro6.js} +1 -1
- package/dist/client/assets/{automation-list-row-CYmqpjOL.js → automation-list-row-adG4CPhS.js} +1 -1
- package/dist/client/assets/{automation-runs-D9S7Bj8t.js → automation-runs-dow6kHOy.js} +1 -1
- package/dist/client/assets/{automations-g7LGm5hd.js → automations-1TSzUOmA.js} +1 -1
- package/dist/client/assets/{avatar-I17szs3Q.js → avatar-CgzSFqk_.js} +1 -1
- package/dist/client/assets/{badge-1BKF0WjP.js → badge-lMx4Em_d.js} +1 -1
- package/dist/client/assets/{billing-EZuyPlZX.js → billing-cg1pMUCL.js} +1 -1
- package/dist/client/assets/{block-document-CrI42xhd.js → block-document-DACwj6cq.js} +1 -1
- package/dist/client/assets/brand-context-_YEJiMtE.js +1 -0
- package/dist/client/assets/{buckets-BjM-OEVV.js → buckets-DDs_bOU6.js} +1 -1
- package/dist/client/assets/bulk-category-panel-CZ1xK5ra.js +1 -0
- package/dist/client/assets/{calendar-ihm97ng4.js → calendar-CYMp7iB8.js} +1 -1
- package/dist/client/assets/{capability-load-error-CdiziQNa.js → capability-load-error-BdQ0RY6o.js} +1 -1
- package/dist/client/assets/{card-ZgfbVCh9.js → card-CmIeTTKx.js} +1 -1
- package/dist/client/assets/category-editor-tpL-X4Ls.js +1 -0
- package/dist/client/assets/chat-context-BLOQKHWz.js +35 -0
- package/dist/client/assets/{checkbox-CQ_C4vJL.js → checkbox-CQzjZNLI.js} +1 -1
- package/dist/client/assets/{cli-auth-success-SOuYeldg.js → cli-auth-success-B_bJdAXe.js} +1 -1
- package/dist/client/assets/collection-detail-BrNskSUP.js +1 -0
- package/dist/client/assets/{collection-display-button-sALJ24Pj.js → collection-display-button-DDQfc_4E.js} +1 -1
- package/dist/client/assets/{collection-search-Bxz23u0F.js → collection-search-Ck8xQbQY.js} +1 -1
- package/dist/client/assets/{collection-table-wrapper-Dl8DuNBG.js → collection-table-wrapper-CPjrFIXF.js} +1 -1
- package/dist/client/assets/{collection-tabs-DJww20x9.js → collection-tabs-ChTTyKBp.js} +1 -1
- package/dist/client/assets/{command-bMsQFALP.js → command-DVjoIL5Z.js} +1 -1
- package/dist/client/assets/commerce-onboarding-XS_jc2I-.js +1 -0
- package/dist/client/assets/{companions-core-DYxPDPJ-.js → companions-core-ByyoADu_.js} +1 -1
- package/dist/client/assets/{connect-BS6fJ7Zh.js → connect-DcehsLQD.js} +1 -1
- package/dist/client/assets/connection-Bkj-nefY.js +1 -0
- package/dist/client/assets/{connection-card-Di6_Srf0.js → connection-card-C70gWuc_.js} +1 -1
- package/dist/client/assets/connection-detail-Cnm4EZ40.js +1 -0
- package/dist/client/assets/connection-form-helpers-BRiQ_rsM.js +1 -0
- package/dist/client/assets/connections-CL7Q9BT1.js +1 -0
- package/dist/client/assets/{decopilot-sse-pool-CsSaGM07.js → decopilot-sse-pool-BHpOwOnT.js} +1 -1
- package/dist/client/assets/{dialog-DFfWjXhn.js → dialog-C4tS6-AJ.js} +1 -1
- package/dist/client/assets/{domain-settings-I5C-7sNQ.js → domain-settings-DhQBJJ9v.js} +1 -1
- package/dist/client/assets/{drawer-CjxVq45y.js → drawer-DCnsLLwJ.js} +1 -1
- package/dist/client/assets/{dropdown-menu-DNVNevD7.js → dropdown-menu-qrFjdFOd.js} +1 -1
- package/dist/client/assets/{empty-state-BkAQUfnz.js → empty-state-BcHx1F5j.js} +1 -1
- package/dist/client/assets/{extract-connection-data-D8g8Vhah.js → extract-connection-data-Btyggj3c.js} +1 -1
- package/dist/client/assets/file-explorer-DGWuJh1T.js +2 -0
- package/dist/client/assets/{form-Cy7Rd3TL.js → form-HuoBuCsb.js} +1 -1
- package/dist/client/assets/general-YiXWqla_.js +1 -0
- package/dist/client/assets/{github-repo-picker-CKQYOUVF.js → github-repo-picker-DXw_3pye.js} +1 -1
- package/dist/client/assets/{hooks-BYQbPRxe.js → hooks-BG8LlYqb.js} +5 -5
- package/dist/client/assets/{index-4j84p8Zm.js → index-BC86WZCo.js} +1 -1
- package/dist/client/assets/{index-C6AlWcn2.js → index-BPHqkwHC.js} +1 -1
- package/dist/client/assets/{index-Dyyz80fH.js → index-BVf7C7ZF.js} +3 -3
- package/dist/client/assets/{index-gWiN9Hkl.js → index-B_Bz9U5o.js} +1 -1
- package/dist/client/assets/{index-DW2rv6fU.js → index-BmYps6j2.js} +1 -1
- package/dist/client/assets/{index-DnUHHdy9.js → index-BsoA0TDj.js} +1 -1
- package/dist/client/assets/{index-B1Swgh1Q.js → index-BwZDbDIY.js} +1 -1
- package/dist/client/assets/index-CiPtrYhG.js +1 -0
- package/dist/client/assets/{index-SVAVudgF.js → index-Cj6tjEF7.js} +1 -1
- package/dist/client/assets/{index-y45nRZhN.js → index-CmIo9JPs.js} +36 -36
- package/dist/client/assets/{index-geMXTkeP.js → index-D-1YQKmA.js} +6 -6
- package/dist/client/assets/{index-BZsTAPza.js → index-D0be3KU_.js} +1 -1
- package/dist/client/assets/{index-redirect-tLRs_ohU.js → index-redirect-kUAcNkcZ.js} +1 -1
- package/dist/client/assets/{input-i4x2nRXJ.js → input-BJ0a7El5.js} +1 -1
- package/dist/client/assets/{integration-icon-G3CkJMl-.js → integration-icon-BolJxA3P.js} +1 -1
- package/dist/client/assets/invite-member-dialog-Cwz44-id.js +1 -0
- package/dist/client/assets/{label-cSCv6rYO.js → label-B51Cfjcb.js} +1 -1
- package/dist/client/assets/{layout-Dc_sBLyQ.js → layout-DNcRGo2s.js} +1 -1
- package/dist/client/assets/{login-BiKFzoUX.js → login-z85wGBst.js} +1 -1
- package/dist/client/assets/{mcp-oauth-Dv6Uhpr5.js → mcp-oauth-ls-QVFRg.js} +1 -1
- package/dist/client/assets/{members-50SkOm91.js → members-DphiZz1R.js} +1 -1
- package/dist/client/assets/{monaco-editor-DNmyyJIn.js → monaco-editor-x5D7h3Zd.js} +4 -4
- package/dist/client/assets/{monitoring-stats-row-C66zfOZ2.js → monitoring-stats-row-A2TkqHkL.js} +1 -1
- package/dist/client/assets/{multi-select-JtlKk2T8.js → multi-select-D-smOS6l.js} +1 -1
- package/dist/client/assets/{oauth-callback-BOmgYt-J.js → oauth-callback-F721pquo.js} +1 -1
- package/dist/client/assets/{oauth-callback-ai-provider-D-bUKmX5.js → oauth-callback-ai-provider-BwKYVloT.js} +1 -1
- package/dist/client/assets/{onboarding-Dd0xJ_jB.js → onboarding-CLbPa2Iw.js} +1 -1
- package/dist/client/assets/{org-layout-Cyx2dswG.js → org-layout-efrG08YS.js} +1 -1
- package/dist/client/assets/{organization-choice-Dmy0N3Ho.js → organization-choice-DddHH9KP.js} +1 -1
- package/dist/client/assets/{orgs-c3mClxSP.js → orgs-DdMwkwNa.js} +1 -1
- package/dist/client/assets/{page-seo-form-CT7Q9nSJ.js → page-seo-form-CwTJM4dv.js} +1 -1
- package/dist/client/assets/{popover-i4jezHIh.js → popover-D9cBxWQc.js} +1 -1
- package/dist/client/assets/post-editor-DnSlIXef.js +1 -0
- package/dist/client/assets/{primitives-DONjjQ2v.js → primitives-H5jElIgn.js} +1 -1
- package/dist/client/assets/profile-Aobp6psg.js +1 -0
- package/dist/client/assets/project-app-view-DjrSQfca.js +1 -0
- package/dist/client/assets/record-editor-3OTLDvRE.js +1 -0
- package/dist/client/assets/redirect-editor-DpMy0uAy.js +1 -0
- package/dist/client/assets/registry-Bso8TzZ7.js +2 -0
- package/dist/client/assets/{registry-layout-f4c_WFt1.js → registry-layout-opgZJiz9.js} +1 -1
- package/dist/client/assets/{reports-CVDl7DQS.js → reports-D2yxA8fw.js} +1 -1
- package/dist/client/assets/{require-capability-6g_AHVvS.js → require-capability-CMySxwCj.js} +1 -1
- package/dist/client/assets/{required-auth-layout-S0YtLBA5.js → required-auth-layout-Bvo_3wIM.js} +1 -1
- package/dist/client/assets/{reset-password-mvh2Bp76.js → reset-password-nv8NwNZo.js} +1 -1
- package/dist/client/assets/roles-CYWyfOcz.js +1 -0
- package/dist/client/assets/{search-input-B-QuRigZ.js → search-input-CXdhLilB.js} +1 -1
- package/dist/client/assets/{secrets-DJdQx2SE.js → secrets-B9PJQSCH.js} +1 -1
- package/dist/client/assets/sections-editor-C939paEw.js +2 -0
- package/dist/client/assets/{select-D6zOoh5E.js → select-SeQy1Hg5.js} +1 -1
- package/dist/client/assets/{select-model-BNaO-ex3.js → select-model-CBQ7sKC3.js} +1 -1
- package/dist/client/assets/self-tool-result-BH4oZBIX.js +1 -0
- package/dist/client/assets/seo-editor-PXOzj3WZ.js +1 -0
- package/dist/client/assets/{settings-layout-DhZgaTMP.js → settings-layout-CHRiIOe2.js} +1 -1
- package/dist/client/assets/{settings-section-jz9Avb_j.js → settings-section-CQIkd9Eq.js} +1 -1
- package/dist/client/assets/{shell-controls-Cp2LM0mr.js → shell-controls-D3D-t70c.js} +1 -1
- package/dist/client/assets/{shell-layout-D82GP0rP.js → shell-layout-DfAyNJEZ.js} +1 -1
- package/dist/client/assets/{sidebar-cviY2JKt.js → sidebar-By4K9wDK.js} +1 -1
- package/dist/client/assets/{skeleton-BnFORNZa.js → skeleton-D5IMmpmB.js} +1 -1
- package/dist/client/assets/{spinner-CkuCAiR1.js → spinner-Cz5qI88w.js} +1 -1
- package/dist/client/assets/{sso-De3-zYaW.js → sso-C3F2Mig7.js} +1 -1
- package/dist/client/assets/{store-4sYEV7M-.js → store-BP1goh1R.js} +1 -1
- package/dist/client/assets/store-registry-0mAT-_6s.js +2 -0
- package/dist/client/assets/{studio-tools-DH0-34Hv.js → studio-tools-CBB5NcXK.js} +1 -1
- package/dist/client/assets/{switch-D2uF_EAp.js → switch-DoHyUDLY.js} +1 -1
- package/dist/client/assets/{tab-id-VDxePu-8.js → tab-id-DbJCnUPm.js} +1 -1
- package/dist/client/assets/{table-D5WR7hLa.js → table-CDPtw8xa.js} +1 -1
- package/dist/client/assets/{tabs-CqBl7afq.js → tabs-C1G6by-P.js} +1 -1
- package/dist/client/assets/{textarea-Bn6hQ_Qz.js → textarea-BwRj3BWK.js} +1 -1
- package/dist/client/assets/{toggle-group-D7y3Qsoq.js → toggle-group-GBeHqGC2.js} +1 -1
- package/dist/client/assets/{toolbar-CpuC8NsW.js → toolbar-AgUwum7S.js} +1 -1
- package/dist/client/assets/{tooltip-BrF3GD_a.js → tooltip-DD5bQH23.js} +1 -1
- package/dist/client/assets/{use-ai-providers-CaSDpPjb.js → use-ai-providers-BzQGXce-.js} +1 -1
- package/dist/client/assets/{use-automations-mCzD08OY.js → use-automations-09Ukg4ai.js} +1 -1
- package/dist/client/assets/{use-autosave-Dys6xriZ.js → use-autosave-Dqz98v7e.js} +1 -1
- package/dist/client/assets/{use-capability-Cpe_qvZ_.js → use-capability-B_lZAM70.js} +1 -1
- package/dist/client/assets/{use-clock-tick-CAblMTwd.js → use-clock-tick-DAnBYTL7.js} +1 -1
- package/dist/client/assets/{use-connection-B7cDwiOJ.js → use-connection-BHwQgQE1.js} +1 -1
- package/dist/client/assets/{use-copy-r5QxG4Uf.js → use-copy-CaVFAZIo.js} +1 -1
- package/dist/client/assets/{use-create-virtual-mcp-DcGH_7kD.js → use-create-virtual-mcp-6AEcQ_wM.js} +1 -1
- package/dist/client/assets/{use-debounced-autosave-9sjmxrz4.js → use-debounced-autosave-B2uo_U0Q.js} +1 -1
- package/dist/client/assets/{use-debounced-value-LrUb7eiJ.js → use-debounced-value-74quYOmV.js} +1 -1
- package/dist/client/assets/use-deco-credits-CBEWHfVh.js +1 -0
- package/dist/client/assets/{use-decopilot-events-up5oIRDt.js → use-decopilot-events-BgusMKRg.js} +1 -1
- package/dist/client/assets/{use-delete-connection-B8yeqLKN.js → use-delete-connection-BiPqYCjC.js} +1 -1
- package/dist/client/assets/{use-deployment-admin-nCX9A08B.js → use-deployment-admin-C59XkfKO.js} +1 -1
- package/dist/client/assets/{use-file-configs-1vs3YVUZ.js → use-file-configs-DVZ67f8T.js} +1 -1
- package/dist/client/assets/{use-infinite-scroll-CNsERN2g.js → use-infinite-scroll-DXBuOc2K.js} +1 -1
- package/dist/client/assets/{use-join-requests-6lnToRtO.js → use-join-requests-CBhkIuEv.js} +1 -1
- package/dist/client/assets/{use-mcp-client-BBl5zme6.js → use-mcp-client-D2tnZwXX.js} +1 -1
- package/dist/client/assets/{use-mcp-tools-BKtLcTYP.js → use-mcp-tools-BSCBM72A.js} +1 -1
- package/dist/client/assets/{use-members-stYO4DxP.js → use-members-CbYX7gT8.js} +1 -1
- package/dist/client/assets/{use-mobile-DMoYecwn.js → use-mobile-DhY0tiih.js} +1 -1
- package/dist/client/assets/{use-navigate-to-agent-ABFR-14c.js → use-navigate-to-agent-3K4zONOl.js} +1 -1
- package/dist/client/assets/{use-open-billing-url-DU9jxy0C.js → use-open-billing-url-BYrh3DXJ.js} +1 -1
- package/dist/client/assets/{use-org-auth-client-DoX1JG5g.js → use-org-auth-client-DnAPExjB.js} +1 -1
- package/dist/client/assets/{use-org-sso-BVhPMS3K.js → use-org-sso-CxMNrp--.js} +1 -1
- package/dist/client/assets/{use-organization-roles-A2d2BvKK.js → use-organization-roles-D_3ZeAWB.js} +1 -1
- package/dist/client/assets/{use-organization-settings-DhcL4nY9.js → use-organization-settings-BqeF7AUq.js} +1 -1
- package/dist/client/assets/{use-registry-connections-BoF5es5w.js → use-registry-connections-9U302Lpg.js} +1 -1
- package/dist/client/assets/{use-secrets-BmzIH3vm.js → use-secrets-B1ccTxVT.js} +1 -1
- package/dist/client/assets/{use-status-sounds-DCcIH0HO.js → use-status-sounds-DDz5PHrU.js} +1 -1
- package/dist/client/assets/{use-tags-B8ASGI2M.js → use-tags-CFQKPVS-.js} +1 -1
- package/dist/client/assets/{use-view-mode-xB_4AhUq.js → use-view-mode-DnH7I6ms.js} +1 -1
- package/dist/client/assets/{use-virtual-mcp-CEV_ngrf.js → use-virtual-mcp-DsypThsI.js} +1 -1
- package/dist/client/assets/useInfiniteQuery-lNJCiHAb.js +1 -0
- package/dist/client/assets/{useRouterState-CZMj98pk.js → useRouterState-57-5hG_a.js} +1 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-PjgDS9n5.js +1 -0
- package/dist/client/assets/{users-CONOx6T6.js → users-C806VJZs.js} +1 -1
- package/dist/client/assets/{variant-calendar-E6f23yio.js → variant-calendar-RlCZewyQ.js} +1 -1
- package/dist/client/assets/{view-mode-toggle-DM6n_Ydg.js → view-mode-toggle-CCjGdqzA.js} +1 -1
- package/dist/client/index.html +1 -1
- package/dist/server/cli.js +2 -2
- package/dist/server/server.js +2 -2
- package/package.json +1 -1
- package/dist/client/assets/ai-providers-BpVENL06.js +0 -1
- package/dist/client/assets/app-editor-B5H5-F8S.js +0 -1
- package/dist/client/assets/brand-context-DVPmwhF3.js +0 -1
- package/dist/client/assets/bulk-category-panel-USUYO_mP.js +0 -1
- package/dist/client/assets/category-editor-DQSbFl5w.js +0 -1
- package/dist/client/assets/chat-context-Duovvv_d.js +0 -35
- package/dist/client/assets/collection-detail-Fz2npTpx.js +0 -1
- package/dist/client/assets/commerce-onboarding-orMZD5VK.js +0 -1
- package/dist/client/assets/connection-CSUNWBHY.js +0 -1
- package/dist/client/assets/connection-detail-XkeoVAsF.js +0 -1
- package/dist/client/assets/connection-form-helpers-Dl1KTkNE.js +0 -1
- package/dist/client/assets/connections-3_b1sdLg.js +0 -1
- package/dist/client/assets/file-explorer-DjVkaNg4.js +0 -2
- package/dist/client/assets/general-CWjnB8Qn.js +0 -1
- package/dist/client/assets/index-a5f43C0l.js +0 -1
- package/dist/client/assets/invite-member-dialog-Bp5nMnrA.js +0 -1
- package/dist/client/assets/post-editor-ITfNNH8c.js +0 -1
- package/dist/client/assets/profile-CJ18mI2I.js +0 -1
- package/dist/client/assets/project-app-view-BEATiNjk.js +0 -1
- package/dist/client/assets/record-editor-CxzRU1Mb.js +0 -1
- package/dist/client/assets/redirect-editor-DmlZU7UI.js +0 -1
- package/dist/client/assets/registry-DHRSWQvL.js +0 -2
- package/dist/client/assets/roles-BDap8m-X.js +0 -1
- package/dist/client/assets/sections-editor-W06wfa9f.js +0 -2
- package/dist/client/assets/self-tool-result-Bjd_Fo-p.js +0 -1
- package/dist/client/assets/seo-editor-DKX2y5cI.js +0 -1
- package/dist/client/assets/store-registry-BKTzIEg1.js +0 -2
- package/dist/client/assets/use-deco-credits-Dp43HFr7.js +0 -1
- package/dist/client/assets/useInfiniteQuery-BI-Ge-Y8.js +0 -1
- package/dist/client/assets/useQueries-d_0_L-iH.js +0 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-9ztDghoj.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Y as Kt,Z as Ut,c as $,b as V,_ as pt,$ as ht,e as Gt,j as t,a as ae,B as ne,r as R,aJ as qt,d as st,s as Xt,m as X,t as K,w as Wt,k as ke,p as H,F as oe,f as ot,u as it,L as Qt,D as Yt,I as Jt,G as Zt,K as at,o as en,n as tn}from"./index-geMXTkeP.js";import{t as xt}from"./ChevronDown-BbcA24KM.js";import{A as jt,j as nn,a4 as sn}from"./agent-icon-CQRHN6rX.js";import{T as Ce,a as ye,c as Se}from"./tooltip-BrF3GD_a.js";import{u as vt,d as bt,c as Ct}from"./sidebar-cviY2JKt.js";import{a as rt,i as on,f as an,S as rn,u as ln}from"./use-mcp-client-BBl5zme6.js";import{a as cn,u as dn}from"./use-virtual-mcp-CEV_ngrf.js";import{a as Le,b as yt,P as St}from"./popover-i4jezHIh.js";import{i as Ee}from"./Check-DpoXXYhc.js";import{s as we}from"./Plus-3NJoZ-Rn.js";import{i as wt}from"./SearchMd-DZC0VFyz.js";import{s as Nt}from"./XClose-Ca9PFBA7.js";import{A as un,a as mn,b as fn,c as gn,e as pn,f as hn,g as xn}from"./alert-dialog-CWFjoJjX.js";import{F as Q,a as nt,b as Y,c as J,d as Z,f as jn,e as ee}from"./form-Cy7Rd3TL.js";import{I as ie}from"./input-i4x2nRXJ.js";import{S as vn}from"./spinner-CkuCAiR1.js";import{T as _t}from"./toolbar-CpuC8NsW.js";import{S as bn}from"./skeleton-BnFORNZa.js";import{D as Dt,a as kt,b as At,c as Cn,e as yn,f as Sn,g as wn}from"./drawer-CjxVq45y.js";import{u as It}from"./use-mobile-DMoYecwn.js";import{a as Nn,G as _n}from"./github-repo-picker-CKQYOUVF.js";import{g as Dn,b as kn,a as Pt}from"./hooks-BYQbPRxe.js";import{u as An,g as In,a as Pn,b as Tn}from"./use-navigate-to-agent-ABFR-14c.js";import{a as On,c as Tt}from"./agent-capabilities-cXfbMfjV.js";import{u as Ot}from"./shell-layout-D82GP0rP.js";import{f as zn}from"./reusable-new-chat-CouMjkYR.js";import{C as Mn}from"./collection-search-Bxz23u0F.js";import{g as $n,a as Fn,b as Bn,e as Ln}from"./extract-connection-data-D8g8Vhah.js";import{u as zt,a as Mt,g as En,C as Ye}from"./connection-card-Di6_Srf0.js";import{e as $t,d as Ft,a as Bt,b as Lt,h as Vn,c as Hn}from"./dialog-DFfWjXhn.js";import{S as Rn,a as Kn,b as Un,c as Gn,d as De}from"./select-D6zOoh5E.js";import{T as qn}from"./textarea-Bn6hQ_Qz.js";import{b as Et}from"./use-connection-B7cDwiOJ.js";import{a as Be,b as Je}from"./Tool02-df-j-2i7.js";import{s as Ze}from"./Star01-BWcFSKod.js";import{c as Xn,i as $e,a as ut,E as Wn,p as Qn,b as Yn,d as Jn}from"./connection-form-helpers-Dl1KTkNE.js";import{a as et}from"./authenticate-and-persist-oauth-CCHy3FzA.js";import{g as Zn}from"./connection-slug-eyAPH6o3.js";import{C as es}from"./collection-tabs-DJww20x9.js";import{u as mt}from"./use-infinite-scroll-CNsERN2g.js";import{B as Fe}from"./badge-1BKF0WjP.js";import{u as ts}from"./useSuspenseInfiniteQuery-9ztDghoj.js";import{g as Ve}from"./metadata-dUsYcpuu.js";import{u as ns}from"./studio-tools-DH0-34Hv.js";import{u as ss}from"./use-ai-providers-CaSDpPjb.js";function ft(n){return n.toLowerCase().trim().replace(/[^a-z0-9\s_-]+/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const os=Kt({name:Ut().min(2,"Organization name is required")});function is(n){const e=$.c(66),{open:s,onOpenChange:o}=n,i=V();let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a={resolver:pt(os),defaultValues:{name:""}},e[0]=a):a=e[0];const r=ht(a);let d;e[1]!==i?(d=async E=>{const M=ft(E.name);if(!M)throw new Error(i("common.createOrganizationDialog.invalidSlug"));const G=await ae.organization.create({name:E.name,slug:M});if(G?.error)throw new Error(G.error.message||i("common.createOrganizationDialog.failedToCreate"));const U=G?.data?.slug??M;if(!U)throw new Error(i("common.createOrganizationDialog.failedToCreate"));return{orgSlug:U}},e[1]=i,e[2]=d):d=e[2];let c;e[3]===Symbol.for("react.memo_cache_sentinel")?(c=as,e[3]=c):c=e[3];let m;e[4]!==d?(m={mutationFn:d,onSuccess:c},e[4]=d,e[5]=m):m=e[5];const u=Gt(m);let p;e[6]!==u.error||e[7]!==i?(p=u.error instanceof Error?u.error.message:u.error?i("common.createOrganizationDialog.failedToCreateGeneric"):null,e[6]=u.error,e[7]=i,e[8]=p):p=e[8];const l=p;let x;e[9]!==i?(x=i("common.createOrganizationDialog.title"),e[9]=i,e[10]=x):x=e[10];let y;e[11]!==x?(y=t.jsx(un,{children:x}),e[11]=x,e[12]=y):y=e[12];let h;e[13]!==i?(h=i("common.createOrganizationDialog.description"),e[13]=i,e[14]=h):h=e[14];let f;e[15]!==h?(f=t.jsx(mn,{children:h}),e[15]=h,e[16]=f):f=e[16];let j;e[17]!==y||e[18]!==f?(j=t.jsxs(fn,{children:[y,f]}),e[17]=y,e[18]=f,e[19]=j):j=e[19];let v;if(e[20]!==u||e[21]!==r){let E;e[23]!==u?(E=M=>u.mutateAsync(M),e[23]=u,e[24]=E):E=e[24],v=r.handleSubmit(E),e[20]=u,e[21]=r,e[22]=v}else v=e[22];let b;e[25]!==r.formState.isSubmitting||e[26]!==i?(b=E=>{const{field:M}=E;return t.jsxs(Y,{children:[t.jsx(J,{children:i("common.createOrganizationDialog.nameLabel")}),t.jsx(Z,{children:t.jsx(ie,{...M,placeholder:i("common.createOrganizationDialog.namePlaceholder"),disabled:r.formState.isSubmitting})}),t.jsx(jn,{children:i("common.createOrganizationDialog.nameDescription")}),M.value&&t.jsxs("div",{className:"text-xs text-muted-foreground mt-1",children:[i("common.createOrganizationDialog.urlLabel")," ",t.jsxs("span",{className:"font-mono",children:[typeof window<"u"?globalThis.location.origin:"","/",ft(M.value)]})]}),t.jsx(ee,{})]})},e[25]=r.formState.isSubmitting,e[26]=i,e[27]=b):b=e[27];let w;e[28]!==r.control||e[29]!==b?(w=t.jsx(Q,{control:r.control,name:"name",render:b}),e[28]=r.control,e[29]=b,e[30]=w):w=e[30];let N;e[31]!==l?(N=l&&t.jsx("div",{className:"text-destructive text-sm mt-2",children:l}),e[31]=l,e[32]=N):N=e[32];const P=r.formState.isSubmitting;let O;e[33]!==u||e[34]!==r?(O=()=>{u.reset(),r.reset()},e[33]=u,e[34]=r,e[35]=O):O=e[35];let g;e[36]!==i?(g=i("common.createOrganizationDialog.cancel"),e[36]=i,e[37]=g):g=e[37];let _;e[38]!==r.formState.isSubmitting||e[39]!==O||e[40]!==g?(_=t.jsx(gn,{disabled:P,onClick:O,children:g}),e[38]=r.formState.isSubmitting,e[39]=O,e[40]=g,e[41]=_):_=e[41];const T=!r.formState.isValid||r.formState.isSubmitting;let S;e[42]!==r.formState.isSubmitting||e[43]!==i?(S=r.formState.isSubmitting?t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(vn,{size:"xs"})," ",i("common.createOrganizationDialog.creating")]}):i("common.createOrganizationDialog.createButton"),e[42]=r.formState.isSubmitting,e[43]=i,e[44]=S):S=e[44];let C;e[45]!==T||e[46]!==S?(C=t.jsx(ne,{type:"submit",variant:"default",disabled:T,children:S}),e[45]=T,e[46]=S,e[47]=C):C=e[47];let I;e[48]!==_||e[49]!==C?(I=t.jsxs(pn,{children:[_,C]}),e[48]=_,e[49]=C,e[50]=I):I=e[50];let k;e[51]!==v||e[52]!==w||e[53]!==N||e[54]!==I?(k=t.jsxs("form",{className:"space-y-6",onSubmit:v,autoComplete:"off",children:[w,N,I]}),e[51]=v,e[52]=w,e[53]=N,e[54]=I,e[55]=k):k=e[55];let A;e[56]!==r||e[57]!==k?(A=t.jsx(nt,{...r,children:k}),e[56]=r,e[57]=k,e[58]=A):A=e[58];let z;e[59]!==j||e[60]!==A?(z=t.jsxs(hn,{children:[j,A]}),e[59]=j,e[60]=A,e[61]=z):z=e[61];let L;return e[62]!==o||e[63]!==s||e[64]!==z?(L=t.jsx(xn,{open:s,onOpenChange:o,children:z}),e[62]=o,e[63]=s,e[64]=z,e[65]=L):L=e[65],L}function as(n){const{orgSlug:e}=n;window.location.href=`/${e}`}function Vt(){const n=R.useContext(qt),{data:e,refetch:s}=n.hooks.useListUserInvitations();return{invitations:(e??[]).filter(i=>i.status==="pending"&&new Date(i.expiresAt)>new Date),refetch:()=>s?.()}}function rs(n){let e=0;for(let o=0;o<n.length;o++)e=n.charCodeAt(o)+((e<<5)-e);const s=Math.abs(e)%360;return{backgroundColor:`hsl(${s} 55% 70%)`,color:`hsl(${s} 55% 20%)`}}function lt(n){const e=$.c(13),{org:s,size:o}=n,i=o===void 0?"sm":o,a=i==="xs"?"size-5":"size-6",r=i==="xs"?"text-[9px]":"text-xs";let d;e[0]!==a?(d=X(a,"shrink-0 rounded-md flex items-center justify-center border border-border/50 overflow-hidden"),e[0]=a,e[1]=d):d=e[1];let c;e[2]!==s.logo||e[3]!==s.name?(c=s.logo?void 0:rs(s.name),e[2]=s.logo,e[3]=s.name,e[4]=c):c=e[4];let m;e[5]!==s.logo||e[6]!==s.name||e[7]!==r?(m=s.logo?t.jsx("img",{src:s.logo,alt:"",className:"size-full object-cover"}):t.jsx("span",{className:X("font-semibold leading-none",r),children:s.name.slice(0,2).toUpperCase()}),e[5]=s.logo,e[6]=s.name,e[7]=r,e[8]=m):m=e[8];let u;return e[9]!==d||e[10]!==c||e[11]!==m?(u=t.jsx("div",{className:d,style:c,children:m}),e[9]=d,e[10]=c,e[11]=m,e[12]=u):u=e[12],u}function ls({invitation:n,onChanged:e}){const s=V(),[o,i]=R.useState(!1),a=n.organizationName??s("header.orgSwitcher.unknownOrganization"),r=async()=>{i(!0);try{const m=await ae.organization.acceptInvitation({invitationId:n.id});if(m.error){K.error(m.error.message),i(!1);return}}catch{K.error(s("header.orgSwitcher.failedToAcceptInvitation")),i(!1);return}K.success(s("header.orgSwitcher.joined",{name:a})),Wt();let c;try{c=(await ae.organization.getFullOrganization({query:{organizationId:n.organizationId}}))?.data?.slug}catch{}window.location.href=c?`/${c}`:"/"},d=async()=>{i(!0);try{const c=await ae.organization.rejectInvitation({invitationId:n.id});if(c.error){K.error(c.error.message),i(!1);return}K.success(s("header.orgSwitcher.invitationDeclined")),i(!1),e()}catch{K.error(s("header.orgSwitcher.failedToDeclineInvitation")),i(!1)}};return t.jsxs("div",{className:"flex items-center gap-3 rounded-md border border-dashed border-border px-3 py-2.5",children:[t.jsx(lt,{org:{name:a},size:"sm"}),t.jsxs("div",{className:"min-w-0 flex-1",children:[t.jsx("p",{className:"truncate text-sm font-medium",children:a}),t.jsx("p",{className:"truncate text-xs text-muted-foreground",children:s("header.orgSwitcher.invitedToJoin")})]}),t.jsxs("div",{className:"flex shrink-0 items-center gap-1",children:[t.jsx(ne,{size:"sm",variant:"default",className:"h-7 text-xs",onClick:r,disabled:o,children:s("header.orgSwitcher.accept")}),t.jsx(ne,{size:"icon",variant:"ghost",className:"size-7 text-muted-foreground",onClick:d,disabled:o,"aria-label":s("header.orgSwitcher.declineInvitationTo",{name:a}),children:t.jsx(Nt,{size:14})})]})]})}function cs(n){const e=$.c(32),{orgParam:s,onSelectOrg:o,onCreateOrg:i}=n,a=V(),{data:r}=Xt(),{invitations:d,refetch:c}=Vt();let m;e[0]!==s?(m=(k,A)=>k.slug===s?-1:A.slug===s?1:k.name.localeCompare(A.name),e[0]=s,e[1]=m):m=e[1];const u=[...r??[]].sort(m),[p,l]=R.useState(""),x=p.toLowerCase(),y=x?u.filter(k=>k.name.toLowerCase().includes(x)||k.slug.toLowerCase().includes(x)):u;let h;e[2]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx(wt,{size:16,className:"shrink-0 text-muted-foreground/60"}),e[2]=h):h=e[2];let f;e[3]===Symbol.for("react.memo_cache_sentinel")?(f=k=>l(k.target.value),e[3]=f):f=e[3];let j;e[4]!==p?(j=k=>k.key==="Escape"&&p&&l(""),e[4]=p,e[5]=j):j=e[5];let v;e[6]!==a?(v=a("header.orgSwitcher.searchOrganizations"),e[6]=a,e[7]=v):v=e[7];let b;e[8]!==p||e[9]!==j||e[10]!==v?(b=t.jsx("input",{"data-org-switcher-search":!0,autoFocus:!0,type:"text",value:p,onChange:f,onKeyDown:j,placeholder:v,className:"flex-1 min-w-0 bg-transparent text-sm outline-none placeholder:text-muted-foreground/60"}),e[8]=p,e[9]=j,e[10]=v,e[11]=b):b=e[11];let w;e[12]===Symbol.for("react.memo_cache_sentinel")?(w=t.jsx(we,{size:16}),e[12]=w):w=e[12];let N;e[13]!==i?(N=t.jsx("button",{type:"button",onClick:i,className:"flex items-center justify-center size-7 rounded-md text-muted-foreground hover:bg-accent/50 hover:text-foreground transition-colors",children:w}),e[13]=i,e[14]=N):N=e[14];let P;e[15]!==b||e[16]!==N?(P=t.jsxs("div",{className:"flex items-center gap-2 px-3 py-2.5 border-b border-border/50",children:[h,b,N]}),e[15]=b,e[16]=N,e[17]=P):P=e[17];const O="flex-1 min-h-0 overflow-y-auto p-1.5 flex flex-col gap-1";let g;e[18]!==d||e[19]!==p||e[20]!==c?(g=!p&&d.map(k=>t.jsx(ls,{invitation:k,onChanged:c},k.id)),e[18]=d,e[19]=p,e[20]=c,e[21]=g):g=e[21];const _=y.length===0&&t.jsx("p",{className:"px-3 py-4 text-sm text-muted-foreground/60 text-center",children:p?a("header.orgSwitcher.noOrganizationsMatch",{query:p}):a("header.orgSwitcher.noOrganizationsAvailable")});let T;e[22]!==o||e[23]!==s?(T=k=>t.jsxs("button",{type:"button",onClick:()=>o(k.slug),className:X("flex items-center gap-3 px-3 py-2.5 rounded-md text-sm text-left w-full transition-colors",k.slug===s?"bg-accent text-accent-foreground":"text-foreground hover:bg-accent/50"),children:[t.jsx(lt,{org:k,size:"sm"}),t.jsxs("div",{className:"flex-1 min-w-0",children:[t.jsx("p",{className:"text-sm font-medium truncate",children:k.name}),t.jsx("p",{className:"text-xs text-muted-foreground truncate",children:k.slug})]}),k.slug===s&&t.jsx(Ee,{size:14,className:"ml-auto text-muted-foreground shrink-0"})]},k.id),e[22]=o,e[23]=s,e[24]=T):T=e[24];const S=y.map(T);let C;e[25]!==g||e[26]!==_||e[27]!==S?(C=t.jsxs("div",{className:O,children:[g,_,S]}),e[25]=g,e[26]=_,e[27]=S,e[28]=C):C=e[28];let I;return e[29]!==C||e[30]!==P?(I=t.jsxs(t.Fragment,{children:[P,C]}),e[29]=C,e[30]=P,e[31]=I):I=e[31],I}function ds(n){const e=$.c(22),{trigger:s,orgParam:o,align:i,side:a}=n,r=i===void 0?"start":i,d=a===void 0?"bottom":a,c=st(),[m,u]=R.useState(!1),[p,l]=R.useState(!1);let x;e[0]!==s?(x=t.jsx(Le,{asChild:!0,children:s}),e[0]=s,e[1]=x):x=e[1];const y=String(m);let h;e[2]!==c?(h=P=>{u(!1),c({to:"/$org",params:{org:P}})},e[2]=c,e[3]=h):h=e[3];let f;e[4]===Symbol.for("react.memo_cache_sentinel")?(f=()=>{u(!1),l(!0)},e[4]=f):f=e[4];let j;e[5]!==o||e[6]!==y||e[7]!==h?(j=t.jsx(cs,{orgParam:o,onSelectOrg:h,onCreateOrg:f},y),e[5]=o,e[6]=y,e[7]=h,e[8]=j):j=e[8];let v;e[9]!==r||e[10]!==d||e[11]!==j?(v=t.jsx(yt,{side:d,align:r,sideOffset:8,collisionPadding:16,className:"w-[300px] p-0 flex flex-col max-h-[440px]",onOpenAutoFocus:ms,onCloseAutoFocus:us,children:j}),e[9]=r,e[10]=d,e[11]=j,e[12]=v):v=e[12];let b;e[13]!==m||e[14]!==x||e[15]!==v?(b=t.jsxs(St,{open:m,onOpenChange:u,children:[x,v]}),e[13]=m,e[14]=x,e[15]=v,e[16]=b):b=e[16];let w;e[17]!==p?(w=t.jsx(is,{open:p,onOpenChange:l}),e[17]=p,e[18]=w):w=e[18];let N;return e[19]!==w||e[20]!==b?(N=t.jsxs(t.Fragment,{children:[b,w]}),e[19]=w,e[20]=b,e[21]=N):N=e[21],N}function us(n){return n.preventDefault()}function ms(n){n.preventDefault(),n.currentTarget?.querySelector("[data-org-switcher-search]")?.focus()}function fs(n){const e=$.c(21),{value:s,onChange:o,placeholder:i,onKeyDown:a,className:r,isSearching:d,disabled:c}=n,m=i===void 0?"Search...":i;let u;e[0]!==r?(u=X("shrink-0 w-full border-b border-border h-12",r),e[0]=r,e[1]=u):u=e[1];const p=c?"cursor-not-allowed opacity-50":"cursor-text";let l;e[2]!==p?(l=X("flex items-center gap-2.5 h-12 px-4",p),e[2]=p,e[3]=l):l=e[3];let x;e[4]!==d?(x=d?t.jsx(ke,{size:16,className:"animate-spin text-muted-foreground shrink-0"}):t.jsx(wt,{size:16,className:"text-muted-foreground shrink-0"}),e[4]=d,e[5]=x):x=e[5];let y;e[6]!==o?(y=v=>o(v.target.value),e[6]=o,e[7]=y):y=e[7];let h;e[8]!==c||e[9]!==a||e[10]!==m||e[11]!==y||e[12]!==s?(h=t.jsx("input",{type:"text",value:s,onChange:y,onKeyDown:a,placeholder:m,disabled:c,className:"flex-1 min-w-0 bg-transparent text-sm text-foreground placeholder:text-muted-foreground/50 outline-none"}),e[8]=c,e[9]=a,e[10]=m,e[11]=y,e[12]=s,e[13]=h):h=e[13];let f;e[14]!==l||e[15]!==x||e[16]!==h?(f=t.jsxs("label",{className:l,children:[x,h]}),e[14]=l,e[15]=x,e[16]=h,e[17]=f):f=e[17];let j;return e[18]!==u||e[19]!==f?(j=t.jsx("div",{className:u,children:f}),e[18]=u,e[19]=f,e[20]=j):j=e[20],j}function gs(n,e,s){if(!s)return null;const o=Dn(n,e);return o?o.threads.get().find(a=>a.id===s)?.branch??null:null}function ps(n){const e=$.c(6),{value:s,onChange:o}=n,i=V();let a;e[0]!==i?(a=i("sidebar.agentsSection.searchAgents"),e[0]=i,e[1]=a):a=e[1];let r;return e[2]!==o||e[3]!==a||e[4]!==s?(r=t.jsx(fs,{value:s,onChange:o,placeholder:a}),e[2]=o,e[3]=a,e[4]=s,e[5]=r):r=e[5],r}function hs(){const n=$.c(4),e=V();let s;n[0]!==e?(s=e("sidebar.agentsSection.noAgentsFound"),n[0]=e,n[1]=s):s=n[1];let o;return n[2]!==s?(o=t.jsx("div",{className:"flex items-center justify-center py-6 text-xs text-muted-foreground",children:s}),n[2]=s,n[3]=o):o=n[3],o}function xs(n){const e=$.c(10),{org:s,onClose:o}=n,i=V();let a;e[0]!==s.slug?(a={org:s.slug},e[0]=s.slug,e[1]=a):a=e[1];let r;e[2]!==o?(r=()=>o(),e[2]=o,e[3]=r):r=e[3];let d;e[4]!==i?(d=i("sidebar.agentsSection.seeAllAgents"),e[4]=i,e[5]=d):d=e[5];let c;return e[6]!==a||e[7]!==r||e[8]!==d?(c=t.jsx("div",{className:"border-t border-border px-3 py-2.5",children:t.jsx(Qt,{to:"/$org/settings/agents",params:a,onClick:r,className:"text-xs text-muted-foreground hover:text-foreground transition-colors flex items-center justify-center",children:d})}),e[6]=a,e[7]=r,e[8]=d,e[9]=c):c=e[9],c}function js(){const n=$.c(4),e=V();let s;n[0]!==e?(s=e("sidebar.agentsSection.agents"),n[0]=e,n[1]=s):s=n[1];let o;return n[2]!==s?(o=t.jsx(Ht,{children:s}),n[2]=s,n[3]=o):o=n[3],o}function vs(n){const e=$.c(11),{onImportFromGithub:s}=n,o=V();let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx(_n,{className:"size-3.5"}),e[0]=i):i=e[0];let a;e[1]!==o?(a=o("sidebar.agentsSection.import"),e[1]=o,e[2]=a):a=e[2];let r;e[3]!==s||e[4]!==a?(r=t.jsxs("button",{type:"button",onClick:s,className:"flex items-center gap-1.5 rounded-md px-2 py-1 text-xs font-medium text-muted-foreground transition-colors hover:bg-accent/50 hover:text-foreground",children:[i,a]}),e[3]=s,e[4]=a,e[5]=r):r=e[5];let d;e[6]!==o?(d=o("sidebar.agentsSection.codeAgents"),e[6]=o,e[7]=d):d=e[7];let c;return e[8]!==r||e[9]!==d?(c=t.jsx(Ht,{action:r,children:d}),e[8]=r,e[9]=d,e[10]=c):c=e[10],c}function bs(n){const e=$.c(11),{setOpen:s,emptyCtaClass:o}=n,i=V();let a;e[0]!==i?(a=i("sidebar.agentsSection.browseAgents"),e[0]=i,e[1]=a):a=e[1];let r;e[2]!==o?(r=X(o),e[2]=o,e[3]=r):r=e[3];let d;e[4]!==s?(d=()=>{H("agent_browser_opened",{surface:"mobile_drawer"}),s(!0)},e[4]=s,e[5]=d):d=e[5];let c;e[6]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx(we,{className:"size-4"}),e[6]=c):c=e[6];let m;return e[7]!==a||e[8]!==r||e[9]!==d?(m=t.jsx(_t,{"aria-label":a,className:r,onClick:d,children:c}),e[7]=a,e[8]=r,e[9]=d,e[10]=m):m=e[10],m}function Cs(n){const e=$.c(17),{setOpen:s,highlightEmpty:o,emptyCtaClass:i}=n,a=V();let r;e[0]!==o||e[1]!==a?(r=o?void 0:a("sidebar.agentsSection.browseAgents"),e[0]=o,e[1]=a,e[2]=r):r=e[2];let d;e[3]!==i?(d=X(i),e[3]=i,e[4]=d):d=e[4];let c;e[5]!==s?(c=()=>{H("agent_browser_opened",{surface:"mobile_drawer"}),s(!0)},e[5]=s,e[6]=c):c=e[6];let m;e[7]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx(we,{}),e[7]=m):m=e[7];let u;e[8]!==a?(u=a("sidebar.agentsSection.newAgent"),e[8]=a,e[9]=u):u=e[9];let p;e[10]!==u?(p=t.jsx("span",{children:u}),e[10]=u,e[11]=p):p=e[11];let l;return e[12]!==r||e[13]!==d||e[14]!==c||e[15]!==p?(l=t.jsx(bt,{children:t.jsxs(Ct,{tooltip:r,className:d,onClick:c,children:[m,p]})}),e[12]=r,e[13]=d,e[14]=c,e[15]=p,e[16]=l):l=e[16],l}function ys(){const n=$.c(4),e=V();let s;n[0]!==e?(s=e("sidebar.agentsSection.browseAgents"),n[0]=e,n[1]=s):s=n[1];let o;return n[2]!==s?(o=t.jsx(At,{className:"sr-only",children:s}),n[2]=s,n[3]=o):o=n[3],o}function Ss(n){const e=$.c(8),{emptyCtaClass:s}=n,o=V();let i;e[0]!==o?(i=o("sidebar.agentsSection.browseAgents"),e[0]=o,e[1]=i):i=e[1];let a;e[2]!==s?(a=X(s),e[2]=s,e[3]=a):a=e[3];let r;e[4]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(we,{className:"size-4"}),e[4]=r):r=e[4];let d;return e[5]!==i||e[6]!==a?(d=t.jsx(_t,{"aria-label":i,className:a,children:r}),e[5]=i,e[6]=a,e[7]=d):d=e[7],d}function ws(n){const e=$.c(19),{wrapEmptyHint:s,highlightEmpty:o,emptyCtaClass:i}=n,a=V();let r;e[0]!==o||e[1]!==a?(r=o?void 0:a("sidebar.agentsSection.browseAgents"),e[0]=o,e[1]=a,e[2]=r):r=e[2];let d;e[3]!==i?(d=X(i),e[3]=i,e[4]=d):d=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx(we,{}),e[5]=c):c=e[5];let m;e[6]!==a?(m=a("sidebar.agentsSection.newAgent"),e[6]=a,e[7]=m):m=e[7];let u;e[8]!==m?(u=t.jsx("span",{children:m}),e[8]=m,e[9]=u):u=e[9];let p;e[10]!==r||e[11]!==d||e[12]!==u?(p=t.jsx(Le,{asChild:!0,children:t.jsxs(Ct,{tooltip:r,className:d,children:[c,u]})}),e[10]=r,e[11]=d,e[12]=u,e[13]=p):p=e[13];let l;e[14]!==p||e[15]!==s?(l=s(p),e[14]=p,e[15]=s,e[16]=l):l=e[16];let x;return e[17]!==l?(x=t.jsx(bt,{children:l}),e[17]=l,e[18]=x):x=e[18],x}function Ns(n){const e=$.c(9),{children:s}=n,o=V();let i;e[0]!==s?(i=t.jsx(Ce,{asChild:!0,children:s}),e[0]=s,e[1]=i):i=e[1];let a;e[2]!==o?(a=o("sidebar.agentsSection.selectAnExistingAgent"),e[2]=o,e[3]=a):a=e[3];let r;e[4]!==a?(r=t.jsx(ye,{side:"right",sideOffset:8,children:a}),e[4]=a,e[5]=r):r=e[5];let d;return e[6]!==i||e[7]!==r?(d=t.jsxs(Se,{defaultOpen:!0,delayDuration:0,children:[i,r]}),e[6]=i,e[7]=r,e[8]=d):d=e[8],d}function _s(n){const e=st(),{create:s}=kn(),{locator:o}=oe(),i=ot({strict:!1}),a=it({strict:!1});return async r=>{const d=crypto.randomUUID(),c=r===a.virtualmcpid?gs(n,o,i.taskId??""):null;try{await s({id:d,virtual_mcp_id:r,...c?{branch:c}:{}})}catch{}e({to:"/$org/$taskId",params:{org:n,taskId:d},search:{virtualmcpid:r}})}}function tt(n){const e=$.c(20),{agent:s,selected:o,onClick:i}=n,a=o?"bg-accent text-accent-foreground":"text-foreground hover:bg-accent/50";let r;e[0]!==a?(r=X("flex items-center gap-3 px-3 py-2.5 rounded-md text-sm text-left w-full transition-colors",a),e[0]=a,e[1]=r):r=e[1];let d;e[2]!==s.icon||e[3]!==s.title?(d=t.jsx(jt,{icon:s.icon,name:s.title,size:"xs",className:"shrink-0"}),e[2]=s.icon,e[3]=s.title,e[4]=d):d=e[4];let c;e[5]!==s.title?(c=t.jsx("p",{className:"text-sm font-medium truncate",children:s.title}),e[5]=s.title,e[6]=c):c=e[6];let m;e[7]!==s.description?(m=s.description&&t.jsx("p",{className:"text-xs text-muted-foreground truncate",children:s.description}),e[7]=s.description,e[8]=m):m=e[8];let u;e[9]!==c||e[10]!==m?(u=t.jsxs("div",{className:"flex-1 min-w-0",children:[c,m]}),e[9]=c,e[10]=m,e[11]=u):u=e[11];let p;e[12]!==o?(p=o&&t.jsx(Ee,{size:14,className:"ml-auto text-muted-foreground shrink-0"}),e[12]=o,e[13]=p):p=e[13];let l;return e[14]!==i||e[15]!==r||e[16]!==d||e[17]!==u||e[18]!==p?(l=t.jsxs("button",{type:"button",onClick:i,className:r,children:[d,u,p]}),e[14]=i,e[15]=r,e[16]=d,e[17]=u,e[18]=p,e[19]=l):l=e[19],l}function Ht(n){const e=$.c(5),{children:s,action:o}=n;let i;e[0]!==s?(i=t.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:s}),e[0]=s,e[1]=i):i=e[1];let a;return e[2]!==o||e[3]!==i?(a=t.jsxs("div",{className:"flex items-center justify-between px-3 pb-1 pt-2",children:[i,o]}),e[2]=o,e[3]=i,e[4]=a):a=e[4],a}function Ds(n){const e=$.c(23),{onClose:s,onSelectAgent:o,selectedAgentId:i,onImportFromGithub:a}=n,[r,d]=R.useState(""),c=cn(),m=c??[],{org:u}=oe(),{data:p}=ae.useSession(),l=p?.user?.id??"anon",x=In(c),y=Pn(),h=_s(u.slug),f=On(c),j=r.toLowerCase(),v=m.filter(Ps).filter(B=>!f.has(B.id)).filter(Is).filter(B=>!r||B.title.toLowerCase().includes(j)),b=v.filter(As),w=v.filter(ks),N=rt(u.id),P=!r||N.title.toLowerCase().includes(j),O=!!(o&&P);let g;e[0]!==s||e[1]!==o?(g=()=>{o?.(null),s(),d("")},e[0]=s,e[1]=o,e[2]=g):g=e[2];const _=g,T=B=>{if(o){o(B.id),s(),d("");return}Tn({orgId:u.id,userId:l},B.id,x),y(),s(),d(""),h(B.id)},S="flex flex-col max-h-[min(640px,80dvh)]";let C;e[3]!==r?(C=t.jsx(ps,{value:r,onChange:d}),e[3]=r,e[4]=C):C=e[4];const I="overflow-y-auto flex-1 min-h-0 p-1.5 flex flex-col gap-0.5",k=o&&P&&N&&t.jsx(tt,{agent:N,selected:!i||i===N.id,onClick:_}),A=(b.length>0||!r)&&t.jsx(vs,{onImportFromGithub:a}),z=b.map(B=>t.jsx(tt,{agent:B,selected:o?i===B.id:void 0,onClick:()=>T(B)},B.id)),L=w.length>0&&t.jsx(js,{}),E=w.map(B=>t.jsx(tt,{agent:B,selected:o?i===B.id:void 0,onClick:()=>T(B)},B.id));let M;e[5]!==O||e[6]!==r||e[7]!==v.length?(M=v.length===0&&!O&&r&&t.jsx(hs,{}),e[5]=O,e[6]=r,e[7]=v.length,e[8]=M):M=e[8];let G;e[9]!==M||e[10]!==k||e[11]!==A||e[12]!==z||e[13]!==L||e[14]!==E?(G=t.jsxs("div",{className:I,children:[k,A,z,L,E,M]}),e[9]=M,e[10]=k,e[11]=A,e[12]=z,e[13]=L,e[14]=E,e[15]=G):G=e[15];let U;e[16]!==s||e[17]!==u?(U=t.jsx(xs,{org:u,onClose:s}),e[16]=s,e[17]=u,e[18]=U):U=e[18];let de;return e[19]!==G||e[20]!==U||e[21]!==C?(de=t.jsxs("div",{className:S,children:[C,G,U]}),e[19]=G,e[20]=U,e[21]=C,e[22]=de):de=e[22],de}function ks(n){return!Tt(n.metadata)}function As(n){return Tt(n.metadata)}function Is(n){return!an(n.id)}function Ps(n){return!on(n.id)}function Ts(n){const e=$.c(31);let s;e[0]!==n?(s=n===void 0?{}:n,e[0]=n,e[1]=s):s=e[1];const{compact:o,trigger:i,onSelectAgent:a,selectedAgentId:r,side:d,align:c}=s,m=o===void 0?!1:o,u=d===void 0?"right":d,p=c===void 0?"start":c,[l,x]=R.useState(!1),[y,h]=R.useState(!1),f=It(),{setOpenMobile:j}=vt(),v=An(),b=v?"border border-border":void 0;let w;e[2]!==v?(w=A=>v?t.jsx(Ns,{children:A}):A,e[2]=v,e[3]=w):w=e[3];const N=w;let P;e[4]!==f||e[5]!==j?(P=()=>{x(!1),f&&j(!1)},e[4]=f,e[5]=j,e[6]=P):P=e[6];const O=P;let g;e[7]!==O?(g=()=>{O(),h(!0)},e[7]=O,e[8]=g):g=e[8];const _=g;let T;e[9]!==O||e[10]!==_||e[11]!==a||e[12]!==l||e[13]!==r?(T=l&&t.jsx(R.Suspense,{fallback:t.jsx("div",{className:"flex items-center justify-center py-8",children:t.jsx(bn,{className:"h-4 w-24"})}),children:t.jsx(Ds,{onClose:O,onSelectAgent:a,selectedAgentId:r,onImportFromGithub:_})}),e[9]=O,e[10]=_,e[11]=a,e[12]=l,e[13]=r,e[14]=T):T=e[14];const S=T;let C;e[15]!==p||e[16]!==m||e[17]!==b||e[18]!==v||e[19]!==f||e[20]!==l||e[21]!==S||e[22]!==u||e[23]!==i||e[24]!==N?(C=f?t.jsxs(t.Fragment,{children:[i?t.jsx("button",{type:"button",onClick:()=>x(!0),className:"contents",children:i}):m?N(t.jsx(bs,{setOpen:x,emptyCtaClass:b})):t.jsx(Cs,{setOpen:x,highlightEmpty:v,emptyCtaClass:b}),t.jsx(Dt,{open:l,onOpenChange:x,direction:"bottom",children:t.jsxs(kt,{className:"max-h-[85dvh] p-0",children:[t.jsx(ys,{}),S]})})]}):t.jsxs(St,{open:l,onOpenChange:A=>{A&&!l&&H("agent_browser_opened",{surface:"desktop_popover"}),x(A)},children:[i?t.jsx(Le,{asChild:!0,children:i}):m?N(t.jsx(Le,{asChild:!0,children:t.jsx(Ss,{emptyCtaClass:b})})):t.jsx(ws,{wrapEmptyHint:N,highlightEmpty:v,emptyCtaClass:b}),t.jsx(yt,{className:"w-[380px] p-0 overflow-hidden",side:u,align:p,children:S})]}),e[15]=p,e[16]=m,e[17]=b,e[18]=v,e[19]=f,e[20]=l,e[21]=S,e[22]=u,e[23]=i,e[24]=N,e[25]=C):C=e[25];let I;e[26]!==y?(I=t.jsx(Nn,{open:y,onOpenChange:h,mode:"agent"}),e[26]=y,e[27]=I):I=e[27];let k;return e[28]!==I||e[29]!==C?(k=t.jsxs(t.Fragment,{children:[C,I]}),e[28]=I,e[29]=C,e[30]=k):k=e[30],k}const Os="inline-flex items-center gap-1.5 min-w-0 rounded-md pl-1 pr-2 py-1.5 text-sm text-foreground hover:bg-accent/60 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/50";function zs(n){const e=$.c(29),{agentId:s,fallback:o,onOpenHome:i,onPick:a}=n,r=V(),d=dn(s)??o??null;let c,m,u,p,l;e[0]!==d?.title||e[1]!==i||e[2]!==r?(l=d?.title??r("header.shellBreadcrumb.superAgentDefaultName"),p="flex min-w-0 items-center gap-0",c="button",m=i,u=r("header.shellBreadcrumb.openAgentHome",{name:l}),e[0]=d?.title,e[1]=i,e[2]=r,e[3]=c,e[4]=m,e[5]=u,e[6]=p,e[7]=l):(c=e[3],m=e[4],u=e[5],p=e[6],l=e[7]);const x=d?.icon??null;let y;e[8]!==x||e[9]!==l?(y=t.jsx(jt,{icon:x,name:l,size:"xs"}),e[8]=x,e[9]=l,e[10]=y):y=e[10];let h;e[11]!==c||e[12]!==m||e[13]!==u||e[14]!==y?(h=t.jsx("button",{type:c,onClick:m,"aria-label":u,className:"flex items-center shrink-0 rounded-md p-1 hover:bg-accent/60 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/50",children:y}),e[11]=c,e[12]=m,e[13]=u,e[14]=y,e[15]=h):h=e[15];let f;e[16]!==l?(f=t.jsx("span",{className:"truncate font-medium max-w-[8rem]",children:l}),e[16]=l,e[17]=f):f=e[17];let j;e[18]===Symbol.for("react.memo_cache_sentinel")?(j=t.jsx(xt,{size:14,className:"shrink-0 text-muted-foreground opacity-70"}),e[18]=j):j=e[18];let v;e[19]!==f?(v=t.jsxs("button",{type:"button",className:Os,children:[f,j]}),e[19]=f,e[20]=v):v=e[20];let b;e[21]!==s||e[22]!==a||e[23]!==v?(b=t.jsx(Ts,{side:"bottom",align:"start",selectedAgentId:s,onSelectAgent:a,trigger:v}),e[21]=s,e[22]=a,e[23]=v,e[24]=b):b=e[24];let w;return e[25]!==b||e[26]!==p||e[27]!==h?(w=t.jsxs("div",{className:p,children:[h,b]}),e[25]=b,e[26]=p,e[27]=h,e[28]=w):w=e[28],w}function Fo(n){const e=$.c(30);let s;e[0]!==n?(s=n===void 0?{}:n,e[0]=n,e[1]=s):s=e[1];const{showName:o}=s,i=V(),{org:a}=oe(),{state:r,isMobile:d}=vt(),c=Vt().invitations.length>0,m=r==="collapsed"||d;let u;e[2]!==c||e[3]!==a.name||e[4]!==i?(u=c?i("header.shellBreadcrumb.switchOrganizationPendingInvitation",{name:a.name}):i("header.shellBreadcrumb.switchOrganization",{name:a.name}),e[2]=c,e[3]=a.name,e[4]=i,e[5]=u):u=e[5];let p;e[6]!==a?(p=t.jsx(lt,{org:a,size:"sm"}),e[6]=a,e[7]=p):p=e[7];let l;e[8]!==c||e[9]!==m?(l=c&&t.jsx("span",{className:X("absolute -right-1 size-2.5 rounded-full bg-destructive ring-2 ring-background",m?"-top-1":"top-1/2 -translate-y-1/2")}),e[8]=c,e[9]=m,e[10]=l):l=e[10];let x;e[11]!==p||e[12]!==l?(x=t.jsxs("span",{className:"relative inline-flex",children:[p,l]}),e[11]=p,e[12]=l,e[13]=x):x=e[13];let y;e[14]!==a.name||e[15]!==o?(y=o&&t.jsx("span",{className:"truncate text-sm font-medium text-foreground max-w-[10rem]",children:a.name}),e[14]=a.name,e[15]=o,e[16]=y):y=e[16];let h;e[17]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx(xt,{size:14,className:"shrink-0 text-muted-foreground opacity-70"}),e[17]=h):h=e[17];let f;e[18]!==u||e[19]!==x||e[20]!==y?(f=t.jsx(Ce,{asChild:!0,children:t.jsxs("button",{type:"button","aria-label":u,className:"flex items-center gap-1.5 shrink-0 rounded-lg pl-[5px] pr-1.5 py-1.5 hover:bg-accent/60 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/50",children:[x,y,h]})}),e[18]=u,e[19]=x,e[20]=y,e[21]=f):f=e[21];let j;e[22]!==a.slug||e[23]!==f?(j=t.jsx(ds,{orgParam:a.slug,trigger:f}),e[22]=a.slug,e[23]=f,e[24]=j):j=e[24];let v;e[25]!==a.name?(v=t.jsx(ye,{side:"bottom",children:a.name}),e[25]=a.name,e[26]=v):v=e[26];let b;return e[27]!==v||e[28]!==j?(b=t.jsxs(Se,{children:[j,v]}),e[27]=v,e[28]=j,e[29]=b):b=e[29],b}function Bo(n){const e=$.c(22);let s;e[0]!==n?(s=n===void 0?{}:n,e[0]=n,e[1]=s):s=e[1];const{onNavigate:o}=s,{org:i}=oe();let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a={strict:!1},e[2]=a):a=e[2];const r=ot(a);let d;e[3]===Symbol.for("react.memo_cache_sentinel")?(d={strict:!1},e[3]=d):d=e[3];const c=it(d),{threads:m}=Pt(),{data:u}=ae.useSession(),{setTaskId:p,createNewTask:l}=Ot();let x;e[4]!==i.id?(x=rt(i.id),e[4]=i.id,e[5]=x):x=e[5];const y=x,h=y.id,f=r.taskId?c.virtualmcpid??h:h;let j;e[6]!==l||e[7]!==h||e[8]!==o||e[9]!==u?.user?.id||e[10]!==p||e[11]!==m?(j=O=>{const g=O??h,_=zn(m,g,u?.user?.id);_?p(_.id,g):l(g),o?.()},e[6]=l,e[7]=h,e[8]=o,e[9]=u?.user?.id,e[10]=p,e[11]=m,e[12]=j):j=e[12];const v=j;let b;e[13]===Symbol.for("react.memo_cache_sentinel")?(b=t.jsx("span",{className:"h-5 w-24 rounded bg-muted animate-pulse"}),e[13]=b):b=e[13];const w=f===h?y:void 0;let N;e[14]!==f||e[15]!==v?(N=()=>v(f),e[14]=f,e[15]=v,e[16]=N):N=e[16];let P;return e[17]!==f||e[18]!==v||e[19]!==w||e[20]!==N?(P=t.jsx(R.Suspense,{fallback:b,children:t.jsx(zs,{agentId:f,fallback:w,onOpenHome:N,onPick:v})}),e[17]=f,e[18]=v,e[19]=w,e[20]=N,e[21]=P):P=e[21],P}function Lo(){const n=$.c(24),e=V(),{org:s}=oe();let o;n[0]===Symbol.for("react.memo_cache_sentinel")?(o={strict:!1},n[0]=o):o=n[0];const i=ot(o);let a;n[1]===Symbol.for("react.memo_cache_sentinel")?(a={strict:!1},n[1]=a):a=n[1];const r=it(a),{threads:d}=Pt(),{createNewTask:c}=Ot();let m;n[2]!==s.id?(m=rt(s.id),n[2]=s.id,n[3]=m):m=n[3];const u=m.id,p=i.taskId?r.virtualmcpid??u:u;let l;n[4]!==i.taskId||n[5]!==d?(l=(i.taskId?d.find(P=>P.id===i.taskId)?.branch:null)??null,n[4]=i.taskId,n[5]=d,n[6]=l):l=n[6];const x=l;let y;n[7]!==p||n[8]!==c||n[9]!==x?(y=()=>{c(p,x)},n[7]=p,n[8]=c,n[9]=x,n[10]=y):y=n[10];const h=y;let f;n[11]!==e?(f=e("sidebar.taskGroupsList.newChat"),n[11]=e,n[12]=f):f=n[12];let j;n[13]===Symbol.for("react.memo_cache_sentinel")?(j=t.jsx(nn,{size:16}),n[13]=j):j=n[13];let v;n[14]!==h||n[15]!==f?(v=t.jsx(Ce,{asChild:!0,children:t.jsx("button",{type:"button",onClick:h,"aria-label":f,className:"flex shrink-0 items-center rounded-md p-1.5 text-muted-foreground transition-colors hover:bg-accent/60 hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring/50",children:j})}),n[14]=h,n[15]=f,n[16]=v):v=n[16];let b;n[17]!==e?(b=e("sidebar.taskGroupsList.newChat"),n[17]=e,n[18]=b):b=n[18];let w;n[19]!==b?(w=t.jsx(ye,{side:"bottom",children:b}),n[19]=b,n[20]=w):w=n[20];let N;return n[21]!==v||n[22]!==w?(N=t.jsxs(Se,{children:[v,w]}),n[21]=v,n[22]=w,n[23]=N):N=n[23],N}function Ms({open:n,onOpenChange:e,onCreated:s}){const o=V(),{org:i}=oe(),{data:a}=ae.useSession(),{stdioEnabled:r}=Yt(),d=It(),c=Et(),m=zt(),p=Mt(m,"").items,l=ht({resolver:pt(Xn),defaultValues:{title:"",description:null,icon:null,ui_type:"HTTP",connection_url:"",connection_token:null,npx_package:"",stdio_command:"",stdio_args:"",stdio_cwd:"",env_vars:[]}}),x=l.watch("ui_type"),y=l.watch("connection_url"),h=l.watch("npx_package"),f=$e({uiType:x,connectionUrl:y??"",npxPackage:h??""})??ut({uiType:x,connectionUrl:y??"",registryItems:p}),j=g=>{const _=g.trim();if(!_)return;const T=!!l.formState.dirtyFields.title,S=!!l.formState.dirtyFields.description,C=!!l.formState.dirtyFields.env_vars,I=A=>{if(A&&(!T&&!l.getValues("title").trim()&&A.title&&l.setValue("title",A.title,{shouldDirty:!1}),!S&&!(l.getValues("description")??"").trim()&&A.description&&l.setValue("description",A.description,{shouldDirty:!1}),!C&&A.envVarKeys?.length)){const z=l.getValues("env_vars")??[],L=new Set(z.map(M=>M.key)),E=A.envVarKeys.filter(M=>!L.has(M));E.length>0&&l.setValue("env_vars",[...z,...E.map(M=>({key:M,value:""}))],{shouldDirty:!0})}},k=Qn(_);if(k&&r){l.setValue("ui_type","NPX",{shouldDirty:!0}),l.setValue("npx_package",k.packageName,{shouldDirty:!0}),l.setValue("connection_url","",{shouldDirty:!0}),l.setValue("connection_token",null,{shouldDirty:!0}),I($e({uiType:"NPX",npxPackage:k.packageName}));return}if(_.startsWith("http://")||_.startsWith("https://")){const A=x==="HTTP"||x==="SSE"||x==="Websocket"?x:"HTTP";l.setValue("ui_type",A,{shouldDirty:!0}),l.setValue("connection_url",_,{shouldDirty:!0}),I($e({uiType:A,connectionUrl:_})??ut({uiType:A,connectionUrl:_,registryItems:p}));return}x==="NPX"&&I($e({uiType:"NPX",npxPackage:_}))},v=g=>{g||l.reset(),e(g)},b=async g=>{let _,T=null,S=null,C=null;g.ui_type==="NPX"?(_="STDIO",T="",C=Yn(g.npx_package||"",g.env_vars||[])):g.ui_type==="STDIO"?(_="STDIO",T="",C=Jn(g.stdio_command||"",g.stdio_args||"",g.stdio_cwd,g.env_vars||[])):(_=g.ui_type,T=g.connection_url||"",S=g.connection_token||null);const I=$n("conn");try{await c.create.mutateAsync({id:I,title:g.title,description:g.description||null,connection_type:_,connection_url:T,connection_token:S,created_at:new Date().toISOString(),updated_at:new Date().toISOString(),created_by:a?.user?.id||"system",organization_id:i.id,icon:g.icon??null,app_name:null,app_id:null,connection_headers:C,oauth_config:null,configuration_state:null,metadata:null,tools:null,bindings:null,status:"inactive"}),l.reset(),e(!1),s?.(I)}catch{K.error(o("connections.createConnectionDialog.failedToCreateConnection"))}},w=o("connections.createConnectionDialog.title"),N=o("connections.createConnectionDialog.description"),P=l.formState.isSubmitting?o("connections.createConnectionDialog.saving"):o("connections.createConnectionDialog.createButton"),O=t.jsxs("div",{className:"grid gap-4",children:[t.jsx(Q,{control:l.control,name:"ui_type",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.typeLabel")}),t.jsxs(Rn,{value:g.value,onValueChange:g.onChange,children:[t.jsx(Z,{children:t.jsx(Kn,{children:t.jsx(Un,{})})}),t.jsxs(Gn,{children:[t.jsx(De,{value:"HTTP",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(Ze,{className:"w-4 h-4"}),o("connections.createConnectionDialog.httpType")]})}),t.jsx(De,{value:"SSE",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(Ze,{className:"w-4 h-4"}),o("connections.createConnectionDialog.sseType")]})}),t.jsx(De,{value:"Websocket",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(Ze,{className:"w-4 h-4"}),o("connections.createConnectionDialog.websocketType")]})}),r&&t.jsxs(t.Fragment,{children:[t.jsx(De,{value:"NPX",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(Be,{className:"w-4 h-4"}),o("connections.createConnectionDialog.npxPackageType")]})}),t.jsx(De,{value:"STDIO",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(sn,{className:"w-4 h-4"}),o("connections.createConnectionDialog.customCommandType")]})})]})]})]}),t.jsx(ee,{})]})}),x==="NPX"&&t.jsx(Q,{control:l.control,name:"npx_package",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.npmPackageLabel")}),t.jsx(Z,{children:t.jsx(ie,{placeholder:o("connections.createConnectionDialog.npmPackagePlaceholder"),...g,value:g.value??"",onPaste:_=>{const T=_.clipboardData.getData("text");T&&(_.preventDefault(),l.setValue("npx_package",T.trim(),{shouldDirty:!0}),j(T))},onBlur:_=>{j(_.target.value),g.onBlur()}})}),t.jsx(ee,{})]})}),x==="STDIO"&&t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"grid grid-cols-2 gap-4 items-start",children:[t.jsx(Q,{control:l.control,name:"stdio_command",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.commandLabel")}),t.jsx(Z,{children:t.jsx(ie,{placeholder:o("connections.createConnectionDialog.commandPlaceholder"),...g,value:g.value??""})}),t.jsx(ee,{})]})}),t.jsx(Q,{control:l.control,name:"stdio_args",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.argumentsLabel")}),t.jsx(Z,{children:t.jsx(ie,{placeholder:o("connections.createConnectionDialog.argumentsPlaceholder"),...g,value:g.value??""})}),t.jsx(ee,{})]})})]}),t.jsx(Q,{control:l.control,name:"stdio_cwd",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.workingDirectoryLabel")}),t.jsx(Z,{children:t.jsx(ie,{placeholder:o("connections.createConnectionDialog.workingDirectoryPlaceholder"),...g,value:g.value??""})}),t.jsx("p",{className:"text-xs text-muted-foreground",children:o("connections.createConnectionDialog.workingDirectoryDescription")}),t.jsx(ee,{})]})})]}),(x==="NPX"||x==="STDIO")&&t.jsx(Q,{control:l.control,name:"env_vars",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.environmentVariablesLabel")}),t.jsx(Z,{children:t.jsx(Wn,{value:g.value??[],onChange:g.onChange})}),t.jsx(ee,{})]})}),x!=="NPX"&&x!=="STDIO"&&t.jsxs(t.Fragment,{children:[t.jsx(Q,{control:l.control,name:"connection_url",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.urlLabel")}),t.jsx(Z,{children:t.jsx(ie,{placeholder:o("connections.createConnectionDialog.urlPlaceholder"),...g,value:g.value??"",onPaste:_=>{const T=_.clipboardData.getData("text");T&&(_.preventDefault(),l.setValue("connection_url",T.trim(),{shouldDirty:!0}),j(T))},onBlur:_=>{j(_.target.value),g.onBlur()}})}),t.jsx(ee,{})]})}),t.jsx(Q,{control:l.control,name:"connection_token",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:f?.token?.label??o("connections.createConnectionDialog.tokenLabelDefault")}),t.jsx(Z,{children:t.jsx(ie,{type:"password",placeholder:f?.token?.placeholder??o("connections.createConnectionDialog.tokenPlaceholderDefault"),className:"ph-no-capture",...g,value:g.value??""})}),f?.token?.helperText&&t.jsxs("p",{className:"text-xs text-muted-foreground",children:[f.token.helperText,f.id==="github"&&t.jsxs(t.Fragment,{children:[" ","·"," ",t.jsx("a",{className:"text-foreground underline underline-offset-4 hover:text-foreground/80",href:"https://github.com/settings/personal-access-tokens",target:"_blank",rel:"noreferrer",children:o("connections.createConnectionDialog.openGitHubPatSettings")})]})]}),t.jsx(ee,{})]})})]}),t.jsx(Q,{control:l.control,name:"title",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.nameLabel")}),t.jsx(Z,{children:t.jsx(ie,{placeholder:o("connections.createConnectionDialog.namePlaceholder"),...g})}),t.jsx(ee,{})]})}),t.jsx(Q,{control:l.control,name:"description",render:({field:g})=>t.jsxs(Y,{children:[t.jsx(J,{children:o("connections.createConnectionDialog.descriptionLabel")}),t.jsx(Z,{children:t.jsx(qn,{placeholder:o("connections.createConnectionDialog.descriptionPlaceholder"),rows:3,...g,value:g.value??""})}),t.jsx(ee,{})]})})]});return d?t.jsx(Dt,{open:n,onOpenChange:v,children:t.jsxs(kt,{className:"max-h-[90vh]",children:[t.jsx(Cn,{className:"pb-2",children:t.jsxs("div",{className:"flex items-start justify-between gap-4",children:[t.jsxs("div",{className:"flex-1 text-left",children:[t.jsx(At,{children:w}),t.jsx(yn,{className:"mt-1",children:N})]}),t.jsx(Sn,{asChild:!0,children:t.jsx(ne,{variant:"ghost",size:"icon",className:"shrink-0 -mt-1",children:t.jsx(Nt,{size:16})})})]})}),t.jsx(nt,{...l,children:t.jsxs("form",{onSubmit:l.handleSubmit(b),children:[t.jsx("div",{className:"overflow-y-auto px-4 pb-4",children:O}),t.jsx(wn,{children:t.jsx(ne,{type:"submit",disabled:l.formState.isSubmitting,className:"w-full",children:P})})]})})]})}):t.jsx($t,{open:n,onOpenChange:v,children:t.jsxs(Ft,{className:"sm:max-w-[525px]",children:[t.jsxs(Bt,{children:[t.jsx(Lt,{children:w}),t.jsx(Vn,{children:N})]}),t.jsx(nt,{...l,children:t.jsxs("form",{onSubmit:l.handleSubmit(b),children:[t.jsx("div",{className:"py-4",children:O}),t.jsxs(Hn,{children:[t.jsx(ne,{type:"button",variant:"outline",onClick:()=>v(!1),children:o("connections.createConnectionDialog.cancelButton")}),t.jsx(ne,{type:"submit",disabled:l.formState.isSubmitting,className:"min-w-40",children:P})]})]})})]})})}function $s(n){const e=$.c(72),{mode:s,agentId:o,addedConnectionIds:i,onAdd:a,onCloneAndAdd:r,onConnectAndAdd:d,connectingItemId:c,search:m,onCreateConnection:u,onBrowseNavigate:p,defaultTab:l}=n,x=s===void 0?"add":s,y=l===void 0?"connected":l,h=V(),{org:f}=oe(),j=R.useDeferredValue(m),v=m!==j;let b;e[0]!==j?(b=j.trim().toLowerCase(),e[0]=j,e[1]=b):b=e[1];const w=b;let N;e[2]!==y?(N=D=>D??y,e[2]=y,e[3]=N):N=e[3];const[P,O]=Jt(Zt.connectionsTab(f.slug)+(y==="all"?":home-modal":":agent-modal"),N);let g;e[4]!==P||e[5]!==O?(g=D=>{D!==P&&H("connections_dialog_tab_changed",{to_tab:D}),O(D)},e[4]=P,e[5]=O,e[6]=g):g=e[6];const _=g;let T;e[7]!==f.id||e[8]!==f.slug?(T={connectionId:rn,orgId:f.id,orgSlug:f.slug},e[7]=f.id,e[8]=f.slug,e[9]=T):T=e[9];const S=ln(T),C=j?.trim().split(/\s+/).filter(Boolean)??[],I=C.length>0?{operator:"or",conditions:C.flatMap(Ks)}:void 0,k={...I&&{where:I},orderBy:[{field:["updated_at"],direction:"asc"}],limit:100,offset:0},A=JSON.stringify(k),{data:z,fetchNextPage:L,hasNextPage:E,isFetchingNextPage:M}=ts({queryKey:at.collectionListInfinite(S,f.id,"","CONNECTIONS",A),queryFn:async D=>{const{pageParam:F}=D,se=F===void 0?0:F;return(await S.callTool({name:"COLLECTION_CONNECTIONS_LIST",arguments:{...I&&{where:I},orderBy:[{field:["updated_at"],direction:"asc"}],limit:100,offset:se}})).structuredContent},initialPageParam:0,getNextPageParam:Hs,staleTime:3e4}),G=z?.pages.flatMap(Vs)??[],U=En(G),de=new Set(G.filter(Es).map(Ls)),B=zt(),re=Mt(B,j),He=mt(re.loadMore,re.hasMore,re.isLoadingMore),Re=mt(L,E??!1,M),W=P==="all"||!!w,ct=W?re.items.filter(D=>{const F=Fn(D);if(F&&de.has(F))return!1;if(!w)return!0;const se=Ve(D._meta),le=[D.title,D.description,D.name,D.server?.title,D.server?.description,D.server?.name,se?.friendly_name,se?.friendlyName].filter(Boolean).join(" ").toLowerCase();return C.some(te=>le.includes(te.toLowerCase()))}):[],Ne=ct.filter(Bs),_e=ct.filter(Fs);let Ae;e[10]!==i?(Ae=D=>D.some(F=>i.has(F.id)),e[10]=i,e[11]=Ae):Ae=e[11];const Ke=Ae;let Ie;e[12]!==i||e[13]!==o||e[14]!==c||e[15]!==Ke||e[16]!==x||e[17]!==a||e[18]!==p||e[19]!==r||e[20]!==h?(Ie=(D,F,se,le,te)=>{const Me=Ke(te),be=te.find(ce=>!i.has(ce.id)),q=te[0];if(x==="browse"){const ce=Zn(q);return t.jsx(Ye,{connection:{title:F,icon:se,description:te.length>1?`${te.length} instances`:le??void 0},fallbackIcon:t.jsx(Be,{}),headerActionsAlwaysVisible:!0,headerActions:t.jsxs(Fe,{variant:"secondary",className:"text-xs gap-1 font-normal",children:[t.jsx(Ee,{size:11})," ",h("virtualMcp.connectionDialogContent.connected")]}),onClick:()=>{H("connection_browse_clicked",{app_name:q.app_name??null,connection_id:q.id,instances_count:te.length}),p?.(ce)}},D)}return t.jsx(Ye,{connection:{title:F,icon:se,description:le},fallbackIcon:t.jsx(Be,{}),headerActionsAlwaysVisible:!0,headerActions:t.jsxs("div",{className:"flex items-center gap-1.5",children:[Me&&t.jsxs(Fe,{variant:"secondary",className:"text-xs gap-1 font-normal",children:[t.jsx(Ee,{size:11})," ",h("virtualMcp.connectionDialogContent.added")]}),t.jsx(ne,{variant:"outline",size:"sm",className:"h-7 px-3 text-xs font-medium",disabled:c!==null,onClick:ce=>{ce.stopPropagation(),be?(H("connection_add_clicked",{action:"use_existing",app_name:q.app_name??null,connection_id:be.id}),o&&H("agent_connection_attached",{agent_id:o,connection_id:be.id,app_name:q.app_name??null,mode:"existing"}),a(be.id)):(H("connection_add_clicked",{action:"clone",app_name:q.app_name??null,base_connection_id:q.id}),r(q))},children:h("virtualMcp.connectionDialogContent.add")})]})},D)},e[12]=i,e[13]=o,e[14]=c,e[15]=Ke,e[16]=x,e[17]=a,e[18]=p,e[19]=r,e[20]=h,e[21]=Ie):Ie=e[21];const Pe=Ie;let Te;e[22]!==c||e[23]!==x||e[24]!==d||e[25]!==h?(Te=D=>{const F=Ve(D._meta),se=F?.friendlyName||F?.friendly_name||D.server?.title||D.title||D.server?.name||D.name||D.id||"",le=D.server?.description||D.description||null,te=D.server?.icons?.[0]?.src||Bn(D.server?.repository)||null,Me=F?.official===!0,be=F?.verified===!0,q=F?.owner==="deco";return t.jsx(Ye,{connection:{title:se,description:le,icon:te},fallbackIcon:t.jsx(Be,{}),headerActionsAlwaysVisible:!0,headerActions:t.jsxs("div",{className:"flex items-center gap-1.5",children:[q&&t.jsxs(Se,{children:[t.jsx(Ce,{asChild:!0,children:t.jsx("span",{className:"inline-flex items-center justify-center size-5 rounded-md bg-muted shrink-0",children:t.jsx("img",{src:"/logos/deco logo.svg",alt:h("virtualMcp.connectionDialogContent.madeByDeco"),className:"size-3"})})}),t.jsx(ye,{children:h("virtualMcp.connectionDialogContent.builtByDeco")})]}),!q&&Me&&t.jsxs(Se,{children:[t.jsx(Ce,{asChild:!0,children:t.jsx(Fe,{variant:"outline",size:"icon",children:t.jsx(Je,{})})}),t.jsx(ye,{children:h("virtualMcp.connectionDialogContent.builtByOfficial")})]}),!q&&!Me&&be&&t.jsxs(Se,{children:[t.jsx(Ce,{asChild:!0,children:t.jsx(Fe,{variant:"outline",size:"icon",children:t.jsx(Je,{})})}),t.jsx(ye,{children:h("virtualMcp.connectionDialogContent.verifiedByDeco")})]}),t.jsx(ne,{variant:"outline",size:"sm",className:"h-7 px-3 text-xs font-medium",disabled:c!==null,onClick:ce=>{ce.stopPropagation(),H("connection_add_clicked",{action:"connect_new",registry_item_id:D.id,app_name:F?.friendlyName||D.server?.name||D.name||null}),d(D)},children:c===D.id?t.jsx(ke,{size:14,className:"animate-spin"}):h(x==="browse"?"virtualMcp.connectionDialogContent.connect":"virtualMcp.connectionDialogContent.add")})]})},`catalog-${D.id}`)},e[22]=c,e[23]=x,e[24]=d,e[25]=h,e[26]=Te):Te=e[26];const dt=Te;let ue;e[27]!==P||e[28]!==_||e[29]!==u||e[30]!==w||e[31]!==h?(ue=!w&&t.jsxs("div",{className:"flex items-center justify-between px-5 py-3 border-b border-border shrink-0",children:[t.jsx(es,{tabs:[{id:"all",label:h("virtualMcp.connectionDialogContent.tabAll")},{id:"connected",label:h("virtualMcp.connectionDialogContent.tabConnected")}],activeTab:P,onTabChange:D=>_(D)}),t.jsxs(ne,{variant:"outline",size:"sm",className:"h-7 px-2 text-sm",onClick:()=>{H("connections_dialog_custom_clicked"),u()},children:[t.jsx(we,{size:12}),h("virtualMcp.connectionDialogContent.customConnection")]})]}),e[27]=P,e[28]=_,e[29]=u,e[30]=w,e[31]=h,e[32]=ue):ue=e[32];const Ue=v&&"opacity-50 pointer-events-none";let me;e[33]!==Ue?(me=X("flex-1 overflow-auto p-5 transition-opacity duration-150",Ue),e[33]=Ue,e[34]=me):me=e[34];const Rt="grid grid-cols-[repeat(auto-fill,minmax(260px,1fr))] gap-4";let Oe;e[35]!==Pe?(Oe=D=>{if(D.type==="group")return Pe(D.key,D.title,D.icon,null,D.connections);const F=D.connection;return Pe(F.id,F.title,F.icon,F.description??null,[F])},e[35]=Pe,e[36]=Oe):Oe=e[36];const Ge=U.map(Oe);let fe;e[37]!==Re?(fe=t.jsx("div",{ref:Re,className:"col-span-full h-1"}),e[37]=Re,e[38]=fe):fe=e[38];let ge;e[39]!==M?(ge=M&&t.jsx("div",{className:"col-span-full flex justify-center py-6",children:t.jsx(ke,{size:24,className:"animate-spin text-muted-foreground"})}),e[39]=M,e[40]=ge):ge=e[40];const qe=W&&Ne.length>0&&t.jsxs("div",{className:"col-span-full flex items-center gap-2 mt-2",children:[t.jsx(Je,{size:13,className:"text-muted-foreground shrink-0"}),t.jsx("span",{className:"text-sm font-medium text-muted-foreground whitespace-nowrap",children:h("virtualMcp.connectionDialogContent.sectionVerified")}),t.jsx("div",{className:"flex-1 h-px bg-border"})]}),Xe=W&&Ne.map(dt),We=W&&_e.length>0&&t.jsxs("div",{className:"col-span-full flex items-center gap-2 mt-2",children:[t.jsx("span",{className:"text-sm font-medium text-muted-foreground whitespace-nowrap",children:h("virtualMcp.connectionDialogContent.sectionAllConnections")}),t.jsx("div",{className:"flex-1 h-px bg-border"})]}),Qe=W&&_e.map(dt);let pe;e[41]!==He||e[42]!==B||e[43]!==W?(pe=W&&B.length>0&&t.jsx("div",{ref:He,className:"col-span-full h-1"}),e[41]=He,e[42]=B,e[43]=W,e[44]=pe):pe=e[44];let he;e[45]!==re.isLoadingMore||e[46]!==W?(he=W&&re.isLoadingMore&&t.jsx("div",{className:"col-span-full flex justify-center py-6",children:t.jsx(ke,{size:24,className:"animate-spin text-muted-foreground"})}),e[45]=re.isLoadingMore,e[46]=W,e[47]=he):he=e[47];let xe;e[48]!==Ge||e[49]!==fe||e[50]!==ge||e[51]!==qe||e[52]!==Xe||e[53]!==We||e[54]!==Qe||e[55]!==pe||e[56]!==he?(xe=t.jsxs("div",{className:Rt,children:[Ge,fe,ge,qe,Xe,We,Qe,pe,he]}),e[48]=Ge,e[49]=fe,e[50]=ge,e[51]=qe,e[52]=Xe,e[53]=We,e[54]=Qe,e[55]=pe,e[56]=he,e[57]=xe):xe=e[57];let je;e[58]!==P||e[59]!==U.length||e[60]!==_e||e[61]!==m||e[62]!==h||e[63]!==Ne?(je=U.length===0&&Ne.length===0&&_e.length===0&&t.jsx("div",{className:"flex items-center justify-center h-48 text-sm text-muted-foreground",children:m?h("virtualMcp.connectionDialogContent.emptyStateSearchNoMatch",{search:m}):h(P==="connected"?"virtualMcp.connectionDialogContent.emptyStateNoConnectionsYet":"virtualMcp.connectionDialogContent.emptyStateNoConnectionsAvailable")}),e[58]=P,e[59]=U.length,e[60]=_e,e[61]=m,e[62]=h,e[63]=Ne,e[64]=je):je=e[64];let ve;e[65]!==me||e[66]!==xe||e[67]!==je?(ve=t.jsxs("div",{className:me,children:[xe,je]}),e[65]=me,e[66]=xe,e[67]=je,e[68]=ve):ve=e[68];let ze;return e[69]!==ue||e[70]!==ve?(ze=t.jsxs(t.Fragment,{children:[ue,ve]}),e[69]=ue,e[70]=ve,e[71]=ze):ze=e[71],ze}function Fs(n){return!n.verified&&!Ve(n._meta)?.verified&&!n.meta?.verified}function Bs(n){return n.verified||Ve(n._meta)?.verified||n.meta?.verified}function Ls(n){return n.app_name}function Es(n){return n.app_name}function Vs(n){return n?.items??[]}function Hs(n,e){if(n?.hasMore)return e.reduce(Rs,0)}function Rs(n,e){return n+(e?.items?.length??0)}function Ks(n){return[{field:["title"],operator:"contains",value:n},{field:["description"],operator:"contains",value:n}]}function Eo({open:n,onOpenChange:e,defaultTab:s,initialSearch:o="",...i}){const a=V(),r=i.mode??"add",d="agentId"in i?i.agentId:void 0,c="addedConnectionIds"in i?i.addedConnectionIds??new Set:new Set,m="onAdd"in i&&i.onAdd?i.onAdd:S=>{},u=(S,C,I)=>{d&&H("agent_connection_attached",{agent_id:d,connection_id:S,app_name:C,mode:I})},[p,l]=R.useState(null),[x,y]=R.useState(o),[h,f]=R.useState(!1),{org:j}=oe(),{data:v}=ae.useSession(),b=Et(),w=en(),N=st(),P=S=>{e(!1),N({to:"/$org/settings/connections/$appSlug",params:{org:j.slug,appSlug:S}})},O=()=>{w.invalidateQueries({predicate:S=>{const C=S.queryKey;return C[1]===j.id&&C[3]==="collection"&&C[4]==="CONNECTIONS"}})},g=async(S,C)=>{H("connection_oauth_succeeded",{connection_id:S,flow:C});const I=new URL(`/api/${j.slug}/mcp/${S}`,window.location.origin);await w.invalidateQueries({queryKey:at.isMCPAuthenticated(I.href,null)}),O()},_=async S=>{l(S.app_name??S.id);try{const I=`${S.title.replace(/\s*\(\d+\)\s*$/,"")} (${Date.now().toString(36).slice(-4)})`,A=(await b.create.mutateAsync({title:I,description:S.description??null,connection_type:S.connection_type,connection_url:S.connection_url??null,connection_token:null,icon:S.icon??null,app_name:S.app_name??null,app_id:S.app_id??null,connection_headers:S.connection_headers??null})).id,z=await et({connectionId:A,orgId:j.id,orgSlug:j.slug,persistFallback:L=>b.update.mutateAsync({id:A,data:{connection_token:L}}).then(()=>{})});if(z.ran&&!z.ok){H("connection_oauth_failed",{connection_id:A,flow:"clone",error:z.error??"no_token"}),K.error(a("virtualMcp.addConnectionDialog.authenticationFailedError",{error:z.error??"no token received"})),await b.delete.mutateAsync(A);return}z.ran&&await g(A,"clone"),u(A,S.app_name??null,"clone"),m(A)}catch(C){console.error("Failed to add connection:",C),K.error(a("virtualMcp.addConnectionDialog.failedToAddConnection"))}finally{l(null)}},T=async S=>{if(!(!j||!v?.user?.id)){l(S.id);try{const C=Ln(S,j.id,v.user.id,{remoteIndex:0}),I=C.connection_type==="STDIO",k=!!C.connection_url,A=I&&C.connection_headers&&typeof C.connection_headers=="object"&&"command"in C.connection_headers;if(!k&&!A){K.error(a("virtualMcp.addConnectionDialog.mcpServerConnectionError")),l(null);return}const{id:z}=await b.create.mutateAsync(C),L=await et({connectionId:z,orgId:j.id,orgSlug:j.slug,persistFallback:E=>b.update.mutateAsync({id:z,data:{connection_token:E}}).then(()=>{})});if(L.ran&&!L.ok){H("connection_oauth_failed",{connection_id:z,flow:"connect_new",error:L.error??"no_token"}),K.warning(a("virtualMcp.addConnectionDialog.signInFailedTitle"),{description:a("virtualMcp.addConnectionDialog.signInFailedDescription",{error:L.error??"no token received"})}),u(z,C.app_name??null,"new"),m(z);return}L.ran?(await g(z,"connect_new"),K.success(a("virtualMcp.addConnectionDialog.connectedAuthenticated"))):K.success(a("virtualMcp.addConnectionDialog.connected")),u(z,C.app_name??null,"new"),m(z)}catch(C){console.error("Failed to connect:",C),K.error(a("virtualMcp.addConnectionDialog.failedToConnect"))}finally{l(null)}}};return t.jsxs($t,{open:n,onOpenChange:e,children:[t.jsxs(Ft,{className:"sm:max-w-5xl h-[85vh] max-h-[85vh] flex flex-col p-0 gap-0 overflow-hidden w-[95vw]",children:[t.jsx(Bt,{className:"px-6 pt-5 pb-0 shrink-0",children:t.jsx(Lt,{className:"text-base font-semibold",children:a(r==="browse"?"virtualMcp.addConnectionDialog.connectionsTitle":"virtualMcp.addConnectionDialog.addConnectionTitle")})}),t.jsx("div",{className:"pt-3 shrink-0",children:t.jsx(Mn,{value:x,onChange:y,placeholder:a("virtualMcp.addConnectionDialog.searchConnectionsPlaceholder")})}),t.jsx(R.Suspense,{fallback:t.jsx("div",{className:"flex-1 flex items-center justify-center",children:t.jsx(ke,{size:24,className:"animate-spin text-muted-foreground"})}),children:t.jsx($s,{mode:r,agentId:d,addedConnectionIds:c,onAdd:m,onCloneAndAdd:_,onConnectAndAdd:T,connectingItemId:p,search:x,onCreateConnection:()=>f(!0),onBrowseNavigate:P,defaultTab:s})})]}),t.jsx(Ms,{open:h,onOpenChange:f,onCreated:async S=>{f(!1);const C=await et({connectionId:S,orgId:j.id,orgSlug:j.slug,persistFallback:I=>b.update.mutateAsync({id:S,data:{connection_token:I}}).then(()=>{})});if(C.ran&&!C.ok){H("connection_oauth_failed",{connection_id:S,flow:"custom_create",error:C.error??"no_token"}),K.warning(a("virtualMcp.addConnectionDialog.signInFailedTitle"),{description:a("virtualMcp.addConnectionDialog.signInFailedDescription",{error:C.error??"no token received"})}),u(S,null,"custom"),m(S),e(!1);return}C.ran&&await g(S,"custom_create"),u(S,null,"custom"),m(S),e(!1)}})]})}const gt=new Map;function Vo(){const{org:n}=oe(),e=ns(),s=ss(),o=s.find(f=>f.providerId==="deco"),{data:i,isLoading:a,refetch:r,isFetching:d}=tn({queryKey:at.aiProviderCredits(n.id,"deco"),enabled:!!o,staleTime:6e4,queryFn:async()=>{try{return await e.call("AI_PROVIDER_CREDITS",{providerId:"deco"})}catch{return null}}}),c=i?.balanceCents??null,m=c!=null?c/100:null,u=R.useRef(new Map);if(c!=null){const f=gt.get(n.id);u.current.get(n.id)&&f!=null&&c>f&&H("credits_topped_up_detected",{organization_id:n.id,delta_cents:c-f,previous_balance_cents:f,new_balance_cents:c}),gt.set(n.id,c),u.current.set(n.id,!0)}const p=!!o,l=c!=null&&c>0,x=c!=null&&c===0,y=c!=null&&c===200,h=s.length>0&&s.every(f=>f.providerId==="deco");return{hasDecoKey:p,decoKeyId:o?.id??null,balanceCents:c,balanceDollars:m,hasCredits:l,isZeroBalance:x,isInitialFreeCredit:y,hasOnlyDecoProvider:h,isLoading:a,isFetching:d,refetch:r}}export{Bo as A,Lo as N,Fo as O,Eo as a,ds as b,lt as c,Vo as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{I as u}from"./use-infinite-scroll-CNsERN2g.js";import{e4 as i}from"./index-geMXTkeP.js";function t(e,r){return i(e,u,r)}export{t as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{aK as E,a2 as y,aL as S,a1 as w,aM as Q,o as k,aN as M,aO as x,r as p,aP as q,aQ as H,aR as L,aS as P,aT as R,aU as B,aV as T}from"./index-geMXTkeP.js";function v(r,s){const e=new Set(s);return r.filter(t=>!e.has(t))}function A(r,s,e){const t=r.slice(0);return t[s]=e,t}var U=class extends E{#i;#s;#n;#r;#e;#t;#o;#u;#a;#h=[];constructor(r,s,e){super(),this.#i=r,this.#r=e,this.#n=[],this.#e=[],this.#s=[],this.setQueries(s)}onSubscribe(){this.listeners.size===1&&this.#e.forEach(r=>{r.subscribe(s=>{this.#d(r,s)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,this.#e.forEach(r=>{r.destroy()})}setQueries(r,s){this.#n=r,this.#r=s,y.batch(()=>{const e=this.#e,t=this.#f(this.#n);t.forEach(o=>o.observer.setOptions(o.defaultedQueryOptions));const i=t.map(o=>o.observer),n=i.map(o=>o.getCurrentResult()),u=e.length!==i.length,c=i.some((o,d)=>o!==e[d]),f=u||c,b=f?!0:n.some((o,d)=>{const g=this.#s[d];return!g||!S(o,g)});!f&&!b||(f&&(this.#h=t,this.#e=i),this.#s=n,this.hasListeners()&&(f&&(v(e,i).forEach(o=>{o.destroy()}),v(i,e).forEach(o=>{o.subscribe(d=>{this.#d(o,d)})})),this.#p()))})}getCurrentResult(){return this.#s}getQueries(){return this.#e.map(r=>r.getCurrentQuery())}getObservers(){return this.#e}getOptimisticResult(r,s){const e=this.#f(r),t=e.map(n=>n.observer.getOptimisticResult(n.defaultedQueryOptions)),i=e.map(n=>n.defaultedQueryOptions.queryHash);return[t,n=>this.#l(n??t,s,i),()=>this.#c(t,e)]}#c(r,s){return s.map((e,t)=>{const i=r[t];return e.defaultedQueryOptions.notifyOnChangeProps?i:e.observer.trackResult(i,n=>{s.forEach(u=>{u.observer.trackProp(n)})})})}#l(r,s,e){if(s){const t=this.#a,i=e!==void 0&&t!==void 0&&(t.length!==e.length||e.some((n,u)=>n!==t[u]));return(!this.#t||this.#s!==this.#u||i||s!==this.#o)&&(this.#o=s,this.#u=this.#s,e!==void 0&&(this.#a=e),this.#t=w(this.#t,s(r))),this.#t}return r}#b(){return this.#r?.combine!==void 0&&this.#e.some((r,s)=>r.options.suspense&&this.#s[s]?.data===void 0)}#f(r){const s=new Map;this.#e.forEach(t=>{const i=t.options.queryHash;if(!i)return;const n=s.get(i);n?n.push(t):s.set(i,[t])});const e=[];return r.forEach(t=>{const i=this.#i.defaultQueryOptions(t),u=s.get(i.queryHash)?.shift()??new Q(this.#i,i);e.push({defaultedQueryOptions:i,observer:u})}),e}#d(r,s){const e=this.#e.indexOf(r);e!==-1&&(this.#s=A(this.#s,e,s),this.#p())}#p(){if(this.hasListeners()){const r=this.#c(this.#s,this.#h),s=this.#b(),e=this.#t,t=s?e:this.#l(r,this.#r?.combine);(s||e!==t)&&y.batch(()=>{this.listeners.forEach(i=>{i(this.#s)})})}}};function I({queries:r,...s},e){const t=k(e),i=M(),n=x(),u=p.useMemo(()=>r.map(a=>{const h=t.defaultQueryOptions(a);return h._optimisticResults=i?"isRestoring":"optimistic",h}),[r,t,i]);u.forEach(a=>{q(a);const h=t.getQueryCache().get(a.queryHash);H(a,n,h)}),L(n);const[c]=p.useState(()=>new U(t,u,s)),[f,b,o]=c.getOptimisticResult(u,s.combine),d=!i&&s.subscribed!==!1;p.useSyncExternalStore(p.useCallback(a=>d?c.subscribe(y.batchCalls(a)):P,[c,d]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),p.useEffect(()=>{c.setQueries(u,s)},[u,s,c]);const m=f.some((a,h)=>R(u[h],a))?f.flatMap((a,h)=>{const l=u[h];if(l&&R(l,a)){const C=new Q(t,l);return B(l,C,n)}return[]}):[];if(m.length>0)throw Promise.all(m);const O=f.find((a,h)=>{const l=u[h];return l&&T({result:a,errorResetBoundary:n,throwOnError:l.throwOnError,query:t.getQueryCache().get(l.queryHash),suspense:l.suspense})});if(O?.error)throw O.error;return b(o())}export{I as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{I as s}from"./use-infinite-scroll-CNsERN2g.js";import{e4 as u,X as n}from"./index-geMXTkeP.js";function a(e,r){return u({...e,enabled:!0,suspense:!0,throwOnError:n},s,r)}export{a as u};
|