decocms 4.319.5 → 4.319.6
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-BjdquHf-.js → AlertCircle-DPUOoh5j.js} +1 -1
- package/dist/client/assets/{AreaChart-DISWAeCj.js → AreaChart-CR1kK7Z6.js} +1 -1
- package/dist/client/assets/{ArrowLeft-da6Q-UyL.js → ArrowLeft-BUTpr7Zk.js} +1 -1
- package/dist/client/assets/{ArrowUp-DA_CbLFn.js → ArrowUp-CORHojmg.js} +1 -1
- package/dist/client/assets/{Check-Cnsro5cT.js → Check-CZ_g5EHO.js} +1 -1
- package/dist/client/assets/{CheckCircle-D2QIjzKK.js → CheckCircle-B_Jj98KC.js} +1 -1
- package/dist/client/assets/{ChevronDown-B-Abg1e0.js → ChevronDown-Bt6RPgee.js} +1 -1
- package/dist/client/assets/{ChevronRight-Brk-D2sZ.js → ChevronRight-CNbZXCEK.js} +1 -1
- package/dist/client/assets/{ChevronSelectorVertical-B62qDywG.js → ChevronSelectorVertical-8rrSZwTz.js} +1 -1
- package/dist/client/assets/{ChevronUp-DV8kBI8Y.js → ChevronUp-DkUmlK9q.js} +1 -1
- package/dist/client/assets/{Copy01-CWUFCWPy.js → Copy01-HfyvilSG.js} +1 -1
- package/dist/client/assets/{CreditCard01-CHEBrxoD.js → CreditCard01-BpsRcf0P.js} +1 -1
- package/dist/client/assets/{DotsVertical-ClsiP4Ty.js → DotsVertical-Cvjwtvf0.js} +1 -1
- package/dist/client/assets/{Download01-zimKnpts.js → Download01-BDdx-x6g.js} +1 -1
- package/dist/client/assets/{ErrorBarContext-5JTW_Mba.js → ErrorBarContext-Bqlq569z.js} +1 -1
- package/dist/client/assets/{Eye-S3in9ejU.js → Eye-DsnJ6Hdj.js} +1 -1
- package/dist/client/assets/{FilterLines-Chfs1mfk.js → FilterLines-BUA3zaBV.js} +1 -1
- package/dist/client/assets/{GitBranch01-WegQ50s8.js → GitBranch01-B2HQZMnv.js} +1 -1
- package/dist/client/assets/{Globe01-ChRqAF_1.js → Globe01-Bi3FrG4r.js} +1 -1
- package/dist/client/assets/{Globe04-BSSpPEkT.js → Globe04-R1k9PcJw.js} +1 -1
- package/dist/client/assets/{HardDrive-B8Cy2PQx.js → HardDrive-Ckf8POt4.js} +1 -1
- package/dist/client/assets/{Image01-DFw0y6lF.js → Image01-CdSDKzEr.js} +1 -1
- package/dist/client/assets/{Key01-CraG_uBV.js → Key01-vZqkEk7C.js} +1 -1
- package/dist/client/assets/{LinkExternal01-C0UQ1ExC.js → LinkExternal01-CvJ65RHZ.js} +1 -1
- package/dist/client/assets/{LockUnlocked01-Ci0otu-M.js → LockUnlocked01-6p9kTpAw.js} +1 -1
- package/dist/client/assets/{LogOut01-Nj6MhWEg.js → LogOut01-BKqqcMKc.js} +1 -1
- package/dist/client/assets/{Monitor01-CeeOI5sb.js → Monitor01-CB7YoX25.js} +1 -1
- package/dist/client/assets/{Package-DaOVHCwU.js → Package-Bnouug7j.js} +1 -1
- package/dist/client/assets/{Palette-CzJHZUOm.js → Palette-CCm7KdHj.js} +1 -1
- package/dist/client/assets/{Play-CwdZq2EZ.js → Play-D7lbeUou.js} +1 -1
- package/dist/client/assets/{Plus-D8sAtN4u.js → Plus-N25KFjkP.js} +1 -1
- package/dist/client/assets/{SearchLg-C9b34PXG.js → SearchLg-CHXkkIcP.js} +1 -1
- package/dist/client/assets/{SearchMd-BaB_Q14X.js → SearchMd-BVz5rgMO.js} +1 -1
- package/dist/client/assets/{Sector-C8IIm76y.js → Sector-D9JRVcKv.js} +1 -1
- package/dist/client/assets/{Settings02-CUszvuT2.js → Settings02-JGeGuLpa.js} +1 -1
- package/dist/client/assets/{Share07-D1gdA92o.js → Share07-BaE_VewM.js} +1 -1
- package/dist/client/assets/{Shield01-G7QoiCov.js → Shield01-D_0zBkw-.js} +1 -1
- package/dist/client/assets/{Stars01-C3jSf9hQ.js → Stars01-Bm9KpsQB.js} +1 -1
- package/dist/client/assets/{Stars02-0AGhIbsh.js → Stars02-BSN_fShX.js} +1 -1
- package/dist/client/assets/{Sun-DUlOfQe9.js → Sun-CTLZrmxP.js} +1 -1
- package/dist/client/assets/{SwitchHorizontal01-BSuHHv8C.js → SwitchHorizontal01-CU4u2Mx3.js} +1 -1
- package/dist/client/assets/{Tool01-CNzVBj_W.js → Tool01-6i_1iF0I.js} +1 -1
- package/dist/client/assets/{Tool02-Dpn9yDp0.js → Tool02-CdWdC_dA.js} +1 -1
- package/dist/client/assets/{Trash01-ClFAZqXM.js → Trash01-DeEhE87T.js} +1 -1
- package/dist/client/assets/{TrendUp01-DhMg0ifd.js → TrendUp01-HQV90qh_.js} +1 -1
- package/dist/client/assets/{Upload01-DNvn3Jpk.js → Upload01-a-uHONMh.js} +1 -1
- package/dist/client/assets/{User01-OPq_dP0r.js → User01-BzW7liSD.js} +1 -1
- package/dist/client/assets/{UserSquare-y_18laAE.js → UserSquare-BIJUhRq9.js} +1 -1
- package/dist/client/assets/{Users01-DbbW5Be2.js → Users01-DHt_zj2k.js} +1 -1
- package/dist/client/assets/{Users03-DzeNH_9p.js → Users03-B7JMwHdE.js} +1 -1
- package/dist/client/assets/{XCircle-B4UOTih1.js → XCircle-DGpjgsOa.js} +1 -1
- package/dist/client/assets/{XClose-CANrkFbB.js → XClose-CcgBecn5.js} +1 -1
- package/dist/client/assets/{YAxis-C--iUe-e.js → YAxis-DHEFEMNz.js} +1 -1
- package/dist/client/assets/{Zap-BWej80kj.js → Zap-phia53Nn.js} +1 -1
- package/dist/client/assets/{ZapSquare-BXqrP_tc.js → ZapSquare-C-dg-H1S.js} +1 -1
- package/dist/client/assets/{ZoomOut-CxIB2Yte.js → ZoomOut-B0fwcMBQ.js} +1 -1
- package/dist/client/assets/{access-gate-Bbfkxifm.js → access-gate-C2CuQeuA.js} +1 -1
- package/dist/client/assets/agent-capabilities-BxGDQyCw.js +1 -0
- package/dist/client/assets/{agent-icon-Cg1MVuqt.js → agent-icon-DBchm6Nb.js} +1 -1
- package/dist/client/assets/agents-list-CpKsJdN9.js +1 -0
- package/dist/client/assets/{ai-providers-vkass1lT.js → ai-providers-CwzG1Suk.js} +1 -1
- package/dist/client/assets/{alert-dialog-DY-KNl6H.js → alert-dialog-sgAetjem.js} +1 -1
- package/dist/client/assets/{alert-CqCiQFG2.js → alert-q_9y674t.js} +1 -1
- package/dist/client/assets/{analytics-tab-AFOqdLVu.js → analytics-tab-B3DNh-qY.js} +1 -1
- package/dist/client/assets/{api-keys-BindejEx.js → api-keys-B89ICCUP.js} +1 -1
- package/dist/client/assets/app-editor-fuCtyplA.js +1 -0
- package/dist/client/assets/{auth-4ENUk0th.js → auth-C0jQaNGd.js} +1 -1
- package/dist/client/assets/{auth-catchall-vt2PFKoA.js → auth-catchall-BuJcfhXs.js} +1 -1
- package/dist/client/assets/{auth-entry-CQRMQMpy.js → auth-entry-O5b5_3Z2.js} +1 -1
- package/dist/client/assets/{auth-split-layout-D-LNBWkg.js → auth-split-layout-CivnsjUE.js} +1 -1
- package/dist/client/assets/{authenticate-and-persist-oauth-8TKE_-8N.js → authenticate-and-persist-oauth-B_ddEMoN.js} +1 -1
- package/dist/client/assets/{automation-list-row-CfAr-sYB.js → automation-list-row-CGDHAky9.js} +1 -1
- package/dist/client/assets/{automation-runs-ZqzOzZQ9.js → automation-runs-D6YBL96p.js} +1 -1
- package/dist/client/assets/automations-CPRNSbP-.js +1 -0
- package/dist/client/assets/{avatar-BMtJ5YwV.js → avatar-DLQUtbSd.js} +1 -1
- package/dist/client/assets/{badge-B0pYz4_b.js → badge-CeB87lwb.js} +1 -1
- package/dist/client/assets/{block-document-B0f0QnRm.js → block-document-Dpihi8bF.js} +1 -1
- package/dist/client/assets/{breadcrumb-DG1Z7Nud.js → breadcrumb-KvM6LUMN.js} +1 -1
- package/dist/client/assets/{buckets-B9t66mcv.js → buckets-CtAQxsvY.js} +1 -1
- package/dist/client/assets/{bulk-category-panel-xzXWhqS9.js → bulk-category-panel-Dxxw6gof.js} +1 -1
- package/dist/client/assets/{capability-load-error-Jq9gmxBc.js → capability-load-error-BEFZl7BI.js} +1 -1
- package/dist/client/assets/{cards-SKD62d5P.js → cards-DcMbn2wM.js} +1 -1
- package/dist/client/assets/category-editor-BqyKSX-k.js +1 -0
- package/dist/client/assets/{cdn-tab-4ap_H62i.js → cdn-tab-CS6BQAKM.js} +1 -1
- package/dist/client/assets/{chart-B7o-grMK.js → chart-DikfTaxQ.js} +1 -1
- package/dist/client/assets/{chat-context-D4UYOsqd.js → chat-context-D7bBWEjV.js} +1 -1
- package/dist/client/assets/{checkbox-CjC7D1uk.js → checkbox-Bnn2cV2o.js} +1 -1
- package/dist/client/assets/{choose-editor-DtVWHWuc.js → choose-editor-CQKvK2nQ.js} +1 -1
- package/dist/client/assets/{cli-auth-success-Df5XXOa1.js → cli-auth-success-C8fdvbK0.js} +1 -1
- package/dist/client/assets/collection-detail-BdZYqX07.js +1 -0
- package/dist/client/assets/{collection-display-button-CsfR8ud_.js → collection-display-button-BGPacmRH.js} +1 -1
- package/dist/client/assets/{collection-search-Be0YtMRt.js → collection-search-Bx0fHGdP.js} +1 -1
- package/dist/client/assets/{collection-table-wrapper-B_S7cVDB.js → collection-table-wrapper-Bq9o79bg.js} +1 -1
- package/dist/client/assets/{collection-tabs-4dFJYq71.js → collection-tabs-wE5AjIxo.js} +1 -1
- package/dist/client/assets/{command-DWrtW5Dd.js → command-B-8IVgOi.js} +1 -1
- package/dist/client/assets/{commerce-onboarding-FngCnA8R.js → commerce-onboarding-DvfkGGaG.js} +1 -1
- package/dist/client/assets/{config-5kP3riQw.js → config-BWjWcdbt.js} +1 -1
- package/dist/client/assets/{connect-Di0tK7D1.js → connect-BQldyEIH.js} +1 -1
- package/dist/client/assets/{connection-DhSojBB7.js → connection-Bu6CKKHo.js} +1 -1
- package/dist/client/assets/{connection-card-B46OuNED.js → connection-card-BgP76mdh.js} +1 -1
- package/dist/client/assets/connection-detail-HtDHEVye.js +1 -0
- package/dist/client/assets/{connection-form-helpers-RFHcTUdU.js → connection-form-helpers-D3UyncMx.js} +1 -1
- package/dist/client/assets/{connections-Bz2YpeCL.js → connections-BFDSHlg7.js} +1 -1
- package/dist/client/assets/{decopilot-sse-pool-CYrcMfCK.js → decopilot-sse-pool-BDmk3gDD.js} +1 -1
- package/dist/client/assets/{dialog-DNGy-1NN.js → dialog-Dxe79goo.js} +1 -1
- package/dist/client/assets/{domain-settings-P66G0BKs.js → domain-settings-CVK0PWLe.js} +1 -1
- package/dist/client/assets/{drawer-Dy3_lJI_.js → drawer-DkejdWwz.js} +1 -1
- package/dist/client/assets/{dropdown-menu-5m2qr892.js → dropdown-menu-PmWQu__b.js} +1 -1
- package/dist/client/assets/e2e-tab-DK2VRmcC.js +1 -0
- package/dist/client/assets/{editor-CqDBLwA4.js → editor-CDDmFeb8.js} +1 -1
- package/dist/client/assets/{empty-state-C_35zZjp.js → empty-state-C8ZR6dk7.js} +1 -1
- package/dist/client/assets/{empty-state-BPBMEtIw.js → empty-state-DR2MeWCG.js} +1 -1
- package/dist/client/assets/{extract-connection-data-B7VY0pzb.js → extract-connection-data-BRKwNJ15.js} +1 -1
- package/dist/client/assets/file-explorer-BHOrF9oj.js +2 -0
- package/dist/client/assets/{file-type-icon-BDW-g-n3.js → file-type-icon-B8SUHUXO.js} +1 -1
- package/dist/client/assets/{folder-icon-uMXxo7Cy.js → folder-icon-C9fCzh0e.js} +1 -1
- package/dist/client/assets/{form-C99hTZji.js → form-BzA23Elj.js} +1 -1
- package/dist/client/assets/general-CBxcqCBJ.js +1 -0
- package/dist/client/assets/github-repo-BpKUwJal.js +1 -0
- package/dist/client/assets/{github-repo-picker-Cw-9KtDM.js → github-repo-picker-EtIcW9an.js} +1 -1
- package/dist/client/assets/{hooks-Bws7gD0u.js → hooks-X3Ivo2M-.js} +1 -1
- package/dist/client/assets/{hosting-tab-CWK3SQWH.js → hosting-tab-BHDCkQun.js} +1 -1
- package/dist/client/assets/{index-C75JHNjQ.js → index-BrERmW69.js} +55 -55
- package/dist/client/assets/index-CKLDhHOO.js +1 -0
- package/dist/client/assets/{index-DMOYeaOu.js → index-CtC5YrQv.js} +1 -1
- package/dist/client/assets/{index-CNFW7QBf.js → index-D0d43HMh.js} +1 -1
- package/dist/client/assets/{index-DyeJmUaK.js → index-a8Dvpxdi.js} +1 -1
- package/dist/client/assets/{index-CLQho_ND.js → index-h1j6ujxS.js} +1 -1
- package/dist/client/assets/{index-CX6s6aHQ.js → index-lveCx5PF.js} +1 -1
- package/dist/client/assets/{index-BVrvrbq0.js → index-qCYv4MSE.js} +3 -3
- package/dist/client/assets/{index-redirect-B3YGW1ma.js → index-redirect-L0iJfhY6.js} +1 -1
- package/dist/client/assets/{index-CsFM6pcY.js → index-zpp84knt.js} +2 -2
- package/dist/client/assets/{infra-billing-CuSMuKwL.js → infra-billing-CPf4fFDu.js} +1 -1
- package/dist/client/assets/{input-BrIYd6rX.js → input-CRGKfmn6.js} +1 -1
- package/dist/client/assets/{integration-icon-DxfcS7Xs.js → integration-icon-DBnJJnhq.js} +1 -1
- package/dist/client/assets/{invite-member-dialog-BjO0wj1s.js → invite-member-dialog-BkIQ0dOi.js} +1 -1
- package/dist/client/assets/{label-DsbZOjXe.js → label-CfDXMhl5.js} +1 -1
- package/dist/client/assets/{layout-BcrHxhta.js → layout-D40hZqBj.js} +1 -1
- package/dist/client/assets/{login--Z5yEWJ3.js → login-DdLYUzng.js} +1 -1
- package/dist/client/assets/{markdown-BYfQbGnL.js → markdown-B7Ud7SgT.js} +1 -1
- package/dist/client/assets/{mcp-oauth-CuqNzP3Q.js → mcp-oauth-CGEvYC-J.js} +1 -1
- package/dist/client/assets/{members-DCJr2JZe.js → members-CDTLn-5g.js} +1 -1
- package/dist/client/assets/{monaco-editor-CWSEDaK_.js → monaco-editor-DjnM7g3H.js} +1 -1
- package/dist/client/assets/{monitoring-stats-row-DAZmEtUp.js → monitoring-stats-row-BtKlGcG4.js} +1 -1
- package/dist/client/assets/{multi-select-Dh6LtMHU.js → multi-select-B338vBF_.js} +1 -1
- package/dist/client/assets/{oauth-callback-3B3YCgeQ.js → oauth-callback-ByOfijBR.js} +1 -1
- package/dist/client/assets/{oauth-callback-ai-provider-DMzjvpCR.js → oauth-callback-ai-provider-z49HmhKn.js} +1 -1
- package/dist/client/assets/{onboarding-Xkx6vWRZ.js → onboarding-D50GvWIA.js} +1 -1
- package/dist/client/assets/{org-layout-BA5AxI0J.js → org-layout-Bx5e_xav.js} +1 -1
- package/dist/client/assets/{organization-choice-CmHhVz3y.js → organization-choice-5Z25dFY6.js} +1 -1
- package/dist/client/assets/{orgs-TJ7kad2V.js → orgs-CQPbK1d5.js} +1 -1
- package/dist/client/assets/{page-seo-form-CDF2Ko-x.js → page-seo-form-CFn8hcfO.js} +1 -1
- package/dist/client/assets/{popover-DcAxlsrD.js → popover-BzE481wQ.js} +1 -1
- package/dist/client/assets/post-calendar-CJX3Ko38.js +1 -0
- package/dist/client/assets/post-editor-BdbDvb-c.js +1 -0
- package/dist/client/assets/{primitives-C2Mp-ZLz.js → primitives-DEmITI2J.js} +1 -1
- package/dist/client/assets/{profile-2XlBmYXY.js → profile-BwXGqXR4.js} +1 -1
- package/dist/client/assets/project-app-view-CeNx1fBu.js +1 -0
- package/dist/client/assets/{prompts-F_KMox9n.js → prompts-uqhpOUAX.js} +1 -1
- package/dist/client/assets/record-editor-DwspN490.js +1 -0
- package/dist/client/assets/redirect-editor-7e7Upnyf.js +1 -0
- package/dist/client/assets/registry-DZdIIHBt.js +2 -0
- package/dist/client/assets/{registry-layout-DnrTait8.js → registry-layout-DbvX20ly.js} +1 -1
- package/dist/client/assets/{reports-D6LO2KWZ.js → reports-CrQDejVs.js} +1 -1
- package/dist/client/assets/{require-capability-CsF5i3rq.js → require-capability-BoL6jDgL.js} +1 -1
- package/dist/client/assets/{required-auth-layout-C6_OVZML.js → required-auth-layout-5tFVnd1H.js} +1 -1
- package/dist/client/assets/{reset-password-y8UaZt4j.js → reset-password-CS2Clij0.js} +1 -1
- package/dist/client/assets/{review-settings-BDghijj5.js → review-settings-DBmL8p2f.js} +1 -1
- package/dist/client/assets/{roles-DdlycxBh.js → roles-D-X3mh9v.js} +1 -1
- package/dist/client/assets/{schema-CzxlgXcl.js → schema-CYc80BIA.js} +1 -1
- package/dist/client/assets/{scroll-area-CYvS2rbr.js → scroll-area-r1EYMKyQ.js} +1 -1
- package/dist/client/assets/{search-input-PZ2Wi6Dz.js → search-input-DXwr2899.js} +1 -1
- package/dist/client/assets/{secrets-To08wXej.js → secrets-BTH_8gqg.js} +1 -1
- package/dist/client/assets/{sections-editor-BXXSsnqX.js → sections-editor-90Gsfmg3.js} +2 -2
- package/dist/client/assets/{select-DWZHVE7Z.js → select-Bz_3bOJv.js} +1 -1
- package/dist/client/assets/{select-model-CDSL0Ptb.js → select-model-DH9jNXmH.js} +1 -1
- package/dist/client/assets/{self-tool-result-DmSUT1RY.js → self-tool-result-Do1470Ib.js} +1 -1
- package/dist/client/assets/seo-editor-BkneoKKW.js +1 -0
- package/dist/client/assets/{settings-layout-C34pgJG1.js → settings-layout-B7WDpOx1.js} +1 -1
- package/dist/client/assets/{shell-controls-BOPfw-f-.js → shell-controls-DCdB5eeb.js} +1 -1
- package/dist/client/assets/{shell-layout-BQ1ldV9H.js → shell-layout-CYtE1aPw.js} +1 -1
- package/dist/client/assets/{skill-preview-D9LhMKji.js → skill-preview-DzcAaN-A.js} +1 -1
- package/dist/client/assets/{skills-BPcYrEBu.js → skills-DbUTk6nR.js} +1 -1
- package/dist/client/assets/{spinner-DV6GUIjA.js → spinner-Bgc6NWQ-.js} +1 -1
- package/dist/client/assets/{sso-DlDtc8zv.js → sso-C1XWFvNa.js} +1 -1
- package/dist/client/assets/{store-CbvWrMMu.js → store-C3zBFUp-.js} +1 -1
- package/dist/client/assets/store-registry-5KlYurHE.js +2 -0
- package/dist/client/assets/super-agent-icon-CRICd5zg.js +1 -0
- package/dist/client/assets/{switch-CkIgMDq_.js → switch-Cz4K9iDZ.js} +1 -1
- package/dist/client/assets/synced-repos-C8bY52Sw.js +1 -0
- package/dist/client/assets/{table-l7d0L4HA.js → table-BrzSAp6e.js} +1 -1
- package/dist/client/assets/{tabs-ddeF4LXG.js → tabs-CQbWfZhJ.js} +1 -1
- package/dist/client/assets/{task-board-CDfxS8qo.js → task-board-DCFA9I7S.js} +1 -1
- package/dist/client/assets/{tasks-N1NlU5mX.js → tasks-siQjbDLL.js} +1 -1
- package/dist/client/assets/{textarea-D0l1wrxS.js → textarea-p2bYTUAA.js} +1 -1
- package/dist/client/assets/{thread-route-CYkAuakU.js → thread-route-oU2v4HPI.js} +1 -1
- package/dist/client/assets/{toggle-group-C9fEgPcg.js → toggle-group-C3G6c63e.js} +1 -1
- package/dist/client/assets/{toolbar-Di3Hs5Jo.js → toolbar-BcAFop8I.js} +1 -1
- package/dist/client/assets/{track-B2ASSGQ7.js → track-CC514-8k.js} +1 -1
- package/dist/client/assets/{types-8phPNsJi.js → types-BHR6d6Y2.js} +1 -1
- package/dist/client/assets/{use-ai-providers-Pn7kyqm7.js → use-ai-providers-DPQuwb-3.js} +1 -1
- package/dist/client/assets/{use-api-keys-B1_MH0N8.js → use-api-keys-Cf-PDuMg.js} +1 -1
- package/dist/client/assets/{use-automations-DvucsFJj.js → use-automations-CopIAiD9.js} +1 -1
- package/dist/client/assets/{use-autosave-DdKId9wj.js → use-autosave-Df4gSSDP.js} +1 -1
- package/dist/client/assets/{use-connection-aJLLgoye.js → use-connection-BQeSoolZ.js} +1 -1
- package/dist/client/assets/{use-copy-fzne1gRK.js → use-copy-DrncLLue.js} +1 -1
- package/dist/client/assets/{use-create-virtual-mcp-CUFXXwu6.js → use-create-virtual-mcp-DMgncd5a.js} +1 -1
- package/dist/client/assets/{use-debounced-autosave-DbilpG-x.js → use-debounced-autosave-B-XG1FGZ.js} +1 -1
- package/dist/client/assets/{use-debounced-value-oRaU09z6.js → use-debounced-value-CKaVv7Ac.js} +1 -1
- package/dist/client/assets/{use-decopilot-events-DyGhXOIt.js → use-decopilot-events-B6E_Hlcz.js} +1 -1
- package/dist/client/assets/{use-delete-connection-3IV5iw4V.js → use-delete-connection-CJhsy60O.js} +1 -1
- package/dist/client/assets/{use-deployment-admin-D7QdVcQo.js → use-deployment-admin-DK88CLg4.js} +1 -1
- package/dist/client/assets/{use-destination-route-DQ-Be9BI.js → use-destination-route-DAn4XmeU.js} +1 -1
- package/dist/client/assets/{use-file-configs-CR_5RVUF.js → use-file-configs-D7AMfTRS.js} +1 -1
- package/dist/client/assets/{use-infinite-scroll-BrB7Lt9H.js → use-infinite-scroll-wJNeU_LL.js} +1 -1
- package/dist/client/assets/{use-join-requests-DD20FgTt.js → use-join-requests-Dh08Nva7.js} +1 -1
- package/dist/client/assets/{use-mcp-auth-status-CBeyelo6.js → use-mcp-auth-status-BejOvzkI.js} +1 -1
- package/dist/client/assets/{use-mcp-client-5ujPvma8.js → use-mcp-client-BJ8Gl7bN.js} +1 -1
- package/dist/client/assets/{use-mcp-tools-DWCt19eK.js → use-mcp-tools-aQw0C0zY.js} +1 -1
- package/dist/client/assets/{use-members-MYtJ0ZQo.js → use-members-DZ8N99iL.js} +1 -1
- package/dist/client/assets/use-navigate-to-agent-ctVWYeGN.js +1 -0
- package/dist/client/assets/{use-org-auth-client-C0hhHvh6.js → use-org-auth-client-BD5pSTKO.js} +1 -1
- package/dist/client/assets/{use-org-repo-syncs-ge0m_cRw.js → use-org-repo-syncs-BQHddGlx.js} +1 -1
- package/dist/client/assets/{use-org-sso-Cu9b3co_.js → use-org-sso-B37D2h-E.js} +1 -1
- package/dist/client/assets/{use-organization-roles-BcIg5CMF.js → use-organization-roles-C4CfyaNV.js} +1 -1
- package/dist/client/assets/{use-organization-settings-R_ptPhVG.js → use-organization-settings-DFlCOddU.js} +1 -1
- package/dist/client/assets/{use-panel-navigate-BNhFZdkJ.js → use-panel-navigate-DUpzUMxR.js} +1 -1
- package/dist/client/assets/{use-registry-connections-DRWn31Xx.js → use-registry-connections-pPrzjL2h.js} +1 -1
- package/dist/client/assets/{use-secrets-C1YpR5Po.js → use-secrets-ByjQEBQi.js} +1 -1
- package/dist/client/assets/{use-section-preview-base-CTgZPJVn.js → use-section-preview-base-CgD6NC5X.js} +1 -1
- package/dist/client/assets/{use-status-sounds-zKo5Escv.js → use-status-sounds-DMS0qCWX.js} +1 -1
- package/dist/client/assets/{use-tags-CgzcYzNS.js → use-tags-CkxCFmu3.js} +1 -1
- package/dist/client/assets/{use-view-mode-BWeacecH.js → use-view-mode-DVYPz9HN.js} +1 -1
- package/dist/client/assets/{use-virtual-mcp-BdUU54wm.js → use-virtual-mcp-B7PM027K.js} +1 -1
- package/dist/client/assets/useInfiniteQuery-DsTrslqR.js +1 -0
- package/dist/client/assets/useSuspenseInfiniteQuery-m-DwhjRi.js +1 -0
- package/dist/client/assets/{users-CJU73FxC.js → users-n6tGhrCq.js} +1 -1
- package/dist/client/assets/variant-calendar-BOfhcURI.js +1 -0
- package/dist/client/assets/{view-mode-toggle-DkcqYmXk.js → view-mode-toggle-CVCfOvmN.js} +1 -1
- package/dist/client/index.html +1 -1
- package/dist/server/cli.js +1 -1
- package/dist/server/server.js +1 -1
- package/package.json +1 -1
- package/dist/client/assets/agent-capabilities-B52k7xCe.js +0 -1
- package/dist/client/assets/agents-list-DDDs_272.js +0 -1
- package/dist/client/assets/app-editor-FLYfHJVR.js +0 -1
- package/dist/client/assets/automations-BWiAscw3.js +0 -1
- package/dist/client/assets/category-editor-Dx-vjtTr.js +0 -1
- package/dist/client/assets/collection-detail-C9q6iZ0_.js +0 -1
- package/dist/client/assets/connection-detail-CxYv_HRv.js +0 -1
- package/dist/client/assets/e2e-tab-BuPG2Fh0.js +0 -1
- package/dist/client/assets/file-explorer-D5D47OKf.js +0 -2
- package/dist/client/assets/general-DwOuveWj.js +0 -1
- package/dist/client/assets/index-C41AUxAr.js +0 -1
- package/dist/client/assets/post-calendar-VrqCwGSb.js +0 -1
- package/dist/client/assets/post-editor-7YwpckIK.js +0 -1
- package/dist/client/assets/project-app-view-mvCzsIGJ.js +0 -1
- package/dist/client/assets/record-editor-Dr4skbDC.js +0 -1
- package/dist/client/assets/redirect-editor-DGxrUiXy.js +0 -1
- package/dist/client/assets/registry-DUZw0nlM.js +0 -2
- package/dist/client/assets/seo-editor-tOcU9OSU.js +0 -1
- package/dist/client/assets/store-registry-DyvkpUU8.js +0 -2
- package/dist/client/assets/super-agent-icon-B4UCN6Nm.js +0 -1
- package/dist/client/assets/synced-repos-ItyFXcNL.js +0 -1
- package/dist/client/assets/use-navigate-to-agent-BGjuoQ2e.js +0 -1
- package/dist/client/assets/useInfiniteQuery-CTUYsDi7.js +0 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-DE6FuMxx.js +0 -1
- package/dist/client/assets/variant-calendar-Bptuxrxp.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{c as O,H as oe,o as ke,K as Ae,b as F,j as t,C as Gt,av as Xt,B as te,r as R,bO as Qt,d as ot,w as Wt,n as H,a as re,t as K,y as Yt,k as Ie,a5 as gt,M as ht,q as B,_ as pt,Z as xt,Y as Zt,a8 as Ce,a9 as ye,ab as Ne,L as Jt,G as en,ax as tn,ay as nn,R as sn,I as on,p as an,ac as ln}from"./index-BVrvrbq0.js";import{m as ct,u as cn}from"./use-mcp-client-5ujPvma8.js";import{C as jt,g as rn,W as dn,S as vt,a as bt,i as un,d as mn,f as fn}from"./constants-dLUUoWH7.js";import{D as gn}from"./use-destination-route-DQ-Be9BI.js";import{d as rt,C as hn}from"./self-tool-result-DmSUT1RY.js";import{i as pn}from"./ChevronRight-Brk-D2sZ.js";import{aH as xn,N as jn,A as Ct,I as vn,s as Je}from"./agent-icon-Cg1MVuqt.js";import{b as yt,d as bn,e as Nt}from"./thread-route-CYkAuakU.js";import{t as wt}from"./ChevronDown-B-Abg1e0.js";import{u as _t,a as Cn}from"./use-virtual-mcp-BdUU54wm.js";import{a as Re,b as St,P as Dt}from"./popover-DcAxlsrD.js";import{i as Ve}from"./Check-Cnsro5cT.js";import{s as we}from"./Plus-D8sAtN4u.js";import{i as kt}from"./SearchMd-BaB_Q14X.js";import{s as It}from"./XClose-CANrkFbB.js";import{T as At}from"./toolbar-Di3Hs5Jo.js";import{D as Tt,a as Pt,b as Ot,c as yn,g as Nn,e as wn,f as _n}from"./drawer-Dy3_lJI_.js";import{a as Sn,G as Dn}from"./github-repo-picker-Cw-9KtDM.js";import{g as kn,a as In,b as zt}from"./hooks-Bws7gD0u.js";import{u as An,g as Tn,a as Pn,b as On,f as zn}from"./use-navigate-to-agent-BGjuoQ2e.js";import{g as Mn,a as Mt}from"./agent-capabilities-B52k7xCe.js";import{u as $t}from"./shell-layout-BQ1ldV9H.js";import{d as $n}from"./session-runtime-C-KTDVeQ.js";import{C as Fn}from"./collection-search-Be0YtMRt.js";import{g as Ln,a as En,b as Bn,e as Rn}from"./extract-connection-data-B7VY0pzb.js";import{u as Ft,a as Lt,g as Vn,C as et}from"./connection-card-B46OuNED.js";import{D as Et,b as Bt,c as Rt,d as Vt,h as Kn,e as Hn}from"./dialog-DNGy-1NN.js";import{d as W,a as Y,e as Z,b as J,c as ee,F as dt}from"./form-C99hTZji.js";import{I as ce}from"./input-BrIYd6rX.js";import{S as Un,a as qn,b as Gn,c as Xn,d as De}from"./select-DWZHVE7Z.js";import{T as Qn}from"./textarea-D0l1wrxS.js";import{b as Kt}from"./use-connection-aJLLgoye.js";import{n as Be,i as tt}from"./Tool02-Dpn9yDp0.js";import{e as Wn}from"./UserSquare-y_18laAE.js";import{c as Yn,i as Le,a as ut,E as Zn,p as Jn,b as es,d as ts}from"./connection-form-helpers-RFHcTUdU.js";import{a as nt}from"./authenticate-and-persist-oauth-8TKE_-8N.js";import{g as ns}from"./connection-slug-CITJ0kGN.js";import{C as ss}from"./collection-tabs-4dFJYq71.js";import{u as mt}from"./use-infinite-scroll-BrB7Lt9H.js";import{B as Ee}from"./badge-B0pYz4_b.js";import{u as os}from"./useSuspenseInfiniteQuery-DE6FuMxx.js";import{g as Ke}from"./metadata-dUsYcpuu.js";import{u as is}from"./use-ai-providers-Pn7kyqm7.js";function as(n){return n?n.run_in_progress?"generating":n.scanned_at?"ready":"none":"none"}const ls=2e4;function cs(n){if(typeof n!="string"||!n)return null;try{return new URL(n).hostname||null}catch{return null}}function Go(){const n=O.c(19),{org:e}=oe(),s=dn.COMMERCE_DISCOVERY(e.id);let o;n[0]!==e.id||n[1]!==e.slug?(o=ct({connectionId:vt,orgId:e.id,orgSlug:e.slug}),n[0]=e.id,n[1]=e.slug,n[2]=o):o=n[2];const{data:a}=ke(o),i=ke({queryKey:Ae.commerceDiscoveryConnection(e.id,s),enabled:!!a,retry:!1,staleTime:6e4,queryFn:async()=>{if(!a)throw new Error("selfClient not ready");const S=await a.callTool({name:"COLLECTION_CONNECTIONS_GET",arguments:{id:s}});return rt(S)}}),l=i.data?.item??null,{data:c}=ke({...ct({connectionId:s,orgId:e.id,orgSlug:e.slug}),enabled:!!l}),r=Ae.commerceDiscoveryDiagnostic(e.id,s),u=!!c;let m;n[3]!==c?(m=async()=>{if(!c)throw new Error("cdClient not ready");const S=await c.callTool({name:jt,arguments:{}});return rt(S).diagnostic??null},n[3]=c,n[4]=m):m=n[4];let f;n[5]!==r||n[6]!==u||n[7]!==m?(f={queryKey:r,enabled:u,retry:1,refetchInterval:rs,queryFn:m},n[5]=r,n[6]=u,n[7]=m,n[8]=f):f=n[8];const d=ke(f),g=l?.metadata?.siteUrl,b=d.data??null,h=d.isSuccess,p=i.isPending||!!l&&d.isPending,j=typeof g=="string"&&g?g:null;let v;n[9]!==g?(v=cs(g),n[9]=g,n[10]=v):v=n[10];const C=c??null;let _;return n[11]!==s||n[12]!==d.isSuccess||n[13]!==C||n[14]!==b||n[15]!==p||n[16]!==j||n[17]!==v?(_={diagnostic:b,isSuccess:h,isLoading:p,siteUrl:j,host:v,connectionId:s,cdClient:C},n[11]=s,n[12]=d.isSuccess,n[13]=C,n[14]=b,n[15]=p,n[16]=j,n[17]=v,n[18]=_):_=n[18],_}function rs(n){return n.state.status!=="error"&&as(n.state.data)==="generating"?ls:!1}function Xo(n,e){return{to:gn.agents,params:{org:n.slug,project:rn(n.id),panel:"app"},search:{connection:e,tool:jt}}}const ds="https://decoims.com/image?src=decocms%2F06b54678-5335-4671-b63a-e13d9e541155%2Fagataesteves.png&quality=original&fit=cover&width=160&height=160";function us(){const n=O.c(13),e=F();let s;n[0]===Symbol.for("react.memo_cache_sentinel")?(s=t.jsx("img",{src:"/logos/summit/monte-carlo.svg",alt:"Monte Carlo",className:"h-14 w-[112px] shrink-0 self-start object-contain object-left brightness-0 invert"}),n[0]=s):s=n[0];let o;n[1]!==e?(o=e("routes.commerceOnboarding.connectModal.quote"),n[1]=e,n[2]=o):o=n[2];let a;n[3]!==o?(a=t.jsxs("blockquote",{className:"text-lg font-medium leading-[1.45] lg:text-xl",children:["“",o,"”"]}),n[3]=o,n[4]=a):a=n[4];let i;n[5]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx("img",{src:ds,alt:"",className:"size-10 shrink-0 rounded-full object-cover",loading:"lazy"}),n[5]=i):i=n[5];let l;n[6]!==e?(l=e("routes.commerceOnboarding.connectModal.quoteAuthor"),n[6]=e,n[7]=l):l=n[7];let c;n[8]!==l?(c=t.jsxs("figcaption",{className:"flex items-center gap-2.5",children:[i,t.jsx("span",{className:"text-base font-medium",children:l})]}),n[8]=l,n[9]=c):c=n[9];let r;return n[10]!==a||n[11]!==c?(r=t.jsxs("div",{className:"relative flex flex-col gap-8 text-white",children:[s,a,c]}),n[10]=a,n[11]=c,n[12]=r):r=n[12],r}function ms(){const n=O.c(19),e=F();let s;n[0]!==e?(s=e("routes.commerceOnboarding.connectModal.trustRevoke"),n[0]=e,n[1]=s):s=n[1];let o;n[2]!==s?(o={Icon:xn,label:s},n[2]=s,n[3]=o):o=n[3];let a;n[4]!==e?(a=e("routes.commerceOnboarding.connectModal.trustEncrypted"),n[4]=e,n[5]=a):a=n[5];let i;n[6]!==a?(i={Icon:Gt,label:a},n[6]=a,n[7]=i):i=n[7];let l;n[8]!==e?(l=e("routes.commerceOnboarding.connectModal.trustNeverSold"),n[8]=e,n[9]=l):l=n[9];let c;n[10]!==l?(c={Icon:jn,label:l},n[10]=l,n[11]=c):c=n[11];let r;n[12]!==o||n[13]!==i||n[14]!==c?(r=[o,i,c],n[12]=o,n[13]=i,n[14]=c,n[15]=r):r=n[15];const u=r;let m;n[16]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx("div",{className:"h-px w-full bg-white/15"}),n[16]=m):m=n[16];let f;return n[17]!==u?(f=t.jsxs("div",{className:"relative flex flex-col gap-2.5 text-white",children:[m,t.jsx("ul",{className:"mt-1 flex flex-col gap-2.5",children:u.map(fs)})]}),n[17]=u,n[18]=f):f=n[18],f}function fs(n){const{Icon:e,label:s}=n;return t.jsxs("li",{className:"flex items-center gap-2.5 text-[13px] leading-tight text-white/70",children:[t.jsx(e,{className:"size-4 shrink-0 opacity-85"}),s]},s)}function Qo(n){const e=O.c(22),{siteHost:s,footer:o,onClose:a,children:i}=n,l=F(),c=s?`https://www.google.com/s2/favicons?domain=${s}&sz=128`:null;let r;e[0]!==a||e[1]!==l?(r=a&&t.jsx("button",{type:"button",onClick:a,"aria-label":l("routes.commerceOnboarding.connectModal.close"),className:"absolute right-3 top-3 z-10 flex size-9 items-center justify-center rounded-lg text-muted-foreground transition-colors hover:bg-black/10 hover:text-foreground lg:text-white/80 lg:hover:bg-white/15 lg:hover:text-white",children:t.jsx(Xt,{size:18})}),e[0]=a,e[1]=l,e[2]=r):r=e[2];let u,m;e[3]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx("img",{src:"/logos/deco logo.svg",alt:"Deco",className:"size-7 shrink-0 dark:hidden"}),m=t.jsx("img",{src:"/logos/deco logo negative.svg",alt:"Deco",className:"hidden size-7 shrink-0 dark:block"}),e[3]=u,e[4]=m):(u=e[3],m=e[4]);let f;e[5]!==c||e[6]!==s?(f=s&&t.jsxs(t.Fragment,{children:[t.jsx(pn,{size:16,className:"shrink-0 text-foreground/25"}),c&&t.jsx("span",{className:"flex size-4 shrink-0 items-center justify-center overflow-hidden rounded bg-white",children:t.jsx("img",{src:c,alt:"",className:"size-full"})}),t.jsx("span",{className:"truncate text-[15px] leading-tight text-muted-foreground",children:s})]}),e[5]=c,e[6]=s,e[7]=f):f=e[7];let d;e[8]!==f?(d=t.jsxs("div",{className:"flex items-center gap-2",children:[u,m,f]}),e[8]=f,e[9]=d):d=e[9];let g;e[10]!==o?(g=t.jsx("div",{className:"flex shrink-0 flex-col gap-3",children:o}),e[10]=o,e[11]=g):g=e[11];let b;e[12]!==i||e[13]!==d||e[14]!==g?(b=t.jsxs("div",{className:"flex min-h-0 flex-1 flex-col gap-8 bg-background p-6 lg:p-8",children:[d,i,g]}),e[12]=i,e[13]=d,e[14]=g,e[15]=b):b=e[15];let h,p;e[16]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx("img",{src:"https://decoims.com/image?src=decocms%2F8191643a-1947-4c30-afb4-36b8073c90fb%2Fbg-quote.png&quality=original&fit=cover&width=880",alt:"",className:"absolute inset-0 size-full object-cover"}),p=t.jsx("div",{className:"absolute inset-0 bg-black/20"}),e[16]=h,e[17]=p):(h=e[16],p=e[17]);let j;e[18]===Symbol.for("react.memo_cache_sentinel")?(j=t.jsxs("aside",{className:"relative hidden shrink-0 overflow-hidden lg:flex lg:w-[440px] lg:flex-col lg:p-14",children:[h,p,t.jsxs("div",{className:"relative z-10 flex h-full flex-col",children:[t.jsx("div",{className:"flex-1"}),t.jsx(us,{}),t.jsx("div",{className:"flex-1"}),t.jsx(ms,{})]})]}),e[18]=j):j=e[18];let v;return e[19]!==r||e[20]!==b?(v=t.jsxs("div",{className:"relative flex min-h-0 flex-1 flex-col lg:flex-row",children:[r,b,j]}),e[19]=r,e[20]=b,e[21]=v):v=e[21],v}function Wo(n){const e=O.c(5),{ready:s,pending:o,label:a,onClick:i,children:l}=n,c=o||!s,r=s&&!o?l:null;let u;return e[0]!==a||e[1]!==i||e[2]!==c||e[3]!==r?(u=t.jsxs(te,{type:"button",size:"lg",className:"h-auto min-h-12 w-full whitespace-normal rounded-lg py-3 text-center text-base font-medium leading-tight",onClick:i,disabled:c,children:[a,r]}),e[0]=a,e[1]=i,e[2]=c,e[3]=r,e[4]=u):u=e[4],u}function Ht(){const n=R.useContext(Qt),{data:e,refetch:s}=n.hooks.useListUserInvitations();return{invitations:(e??[]).filter(a=>a.status==="pending"&&new Date(a.expiresAt)>new Date),refetch:()=>s?.()}}function gs(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 it(n){const e=O.c(13),{org:s,size:o}=n,a=o===void 0?"sm":o,i=a==="xs"?"size-5":"size-6",l=a==="xs"?"text-[9px]":"text-xs";let c;e[0]!==i?(c=H(i,"shrink-0 rounded-md flex items-center justify-center border border-border/50 overflow-hidden"),e[0]=i,e[1]=c):c=e[1];let r;e[2]!==s.logo||e[3]!==s.name?(r=s.logo?void 0:gs(s.name),e[2]=s.logo,e[3]=s.name,e[4]=r):r=e[4];let u;e[5]!==s.logo||e[6]!==s.name||e[7]!==l?(u=s.logo?t.jsx("img",{src:s.logo,alt:"",className:"size-full object-cover"}):t.jsx("span",{className:H("font-semibold leading-none",l),children:s.name.slice(0,2).toUpperCase()}),e[5]=s.logo,e[6]=s.name,e[7]=l,e[8]=u):u=e[8];let m;return e[9]!==c||e[10]!==r||e[11]!==u?(m=t.jsx("div",{className:c,style:r,children:u}),e[9]=c,e[10]=r,e[11]=u,e[12]=m):m=e[12],m}function hs({invitation:n,onChanged:e}){const s=F(),[o,a]=R.useState(!1),i=n.organizationName??s("header.orgSwitcher.unknownOrganization"),l=async()=>{a(!0);try{const u=await re.organization.acceptInvitation({invitationId:n.id});if(u.error){K.error(u.error.message),a(!1);return}}catch{K.error(s("header.orgSwitcher.failedToAcceptInvitation")),a(!1);return}K.success(s("header.orgSwitcher.joined",{name:i})),Yt();let r;try{r=(await re.organization.getFullOrganization({query:{organizationId:n.organizationId}}))?.data?.slug}catch{}window.location.href=r?`/${r}`:"/"},c=async()=>{a(!0);try{const r=await re.organization.rejectInvitation({invitationId:n.id});if(r.error){K.error(r.error.message),a(!1);return}K.success(s("header.orgSwitcher.invitationDeclined")),a(!1),e()}catch{K.error(s("header.orgSwitcher.failedToDeclineInvitation")),a(!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(it,{org:{name:i},size:"sm"}),t.jsxs("div",{className:"min-w-0 flex-1",children:[t.jsx("p",{className:"truncate text-sm font-medium",children:i}),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(te,{size:"sm",variant:"default",className:"h-7 text-xs",onClick:l,disabled:o,children:s("header.orgSwitcher.accept")}),t.jsx(te,{size:"icon",variant:"ghost",className:"size-7 text-muted-foreground",onClick:c,disabled:o,"aria-label":s("header.orgSwitcher.declineInvitationTo",{name:i}),children:t.jsx(It,{size:14})})]})]})}function ps(n){const e=O.c(32),{orgParam:s,onSelectOrg:o,onCreateOrg:a}=n,i=F(),{data:l}=Wt(),{invitations:c,refetch:r}=Ht();let u;e[0]!==s?(u=(k,A)=>k.slug===s?-1:A.slug===s?1:k.name.localeCompare(A.name),e[0]=s,e[1]=u):u=e[1];const m=[...l??[]].sort(u),[f,d]=R.useState(""),g=f.toLowerCase(),b=g?m.filter(k=>k.name.toLowerCase().includes(g)||k.slug.toLowerCase().includes(g)):m;let h;e[2]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx(kt,{size:16,className:"shrink-0 text-muted-foreground/60"}),e[2]=h):h=e[2];let p;e[3]===Symbol.for("react.memo_cache_sentinel")?(p=k=>d(k.target.value),e[3]=p):p=e[3];let j;e[4]!==f?(j=k=>k.key==="Escape"&&f&&d(""),e[4]=f,e[5]=j):j=e[5];let v;e[6]!==i?(v=i("header.orgSwitcher.searchOrganizations"),e[6]=i,e[7]=v):v=e[7];let C;e[8]!==f||e[9]!==j||e[10]!==v?(C=t.jsx("input",{"data-org-switcher-search":!0,autoFocus:!0,type:"text",value:f,onChange:p,onKeyDown:j,placeholder:v,className:"flex-1 min-w-0 bg-transparent text-sm outline-none placeholder:text-muted-foreground/60"}),e[8]=f,e[9]=j,e[10]=v,e[11]=C):C=e[11];let _;e[12]===Symbol.for("react.memo_cache_sentinel")?(_=t.jsx(we,{size:16}),e[12]=_):_=e[12];let S;e[13]!==a?(S=t.jsx("button",{type:"button",onClick:a,className:"flex items-center justify-center size-7 rounded-md text-muted-foreground hover:bg-accent/50 hover:text-foreground transition-colors",children:_}),e[13]=a,e[14]=S):S=e[14];let I;e[15]!==C||e[16]!==S?(I=t.jsxs("div",{className:"flex items-center gap-2 px-3 py-2.5 border-b border-border/50",children:[h,C,S]}),e[15]=C,e[16]=S,e[17]=I):I=e[17];const L="flex-1 min-h-0 overflow-y-auto p-1.5 flex flex-col gap-1";let x;e[18]!==c||e[19]!==f||e[20]!==r?(x=!f&&c.map(k=>t.jsx(hs,{invitation:k,onChanged:r},k.id)),e[18]=c,e[19]=f,e[20]=r,e[21]=x):x=e[21];const D=b.length===0&&t.jsx("p",{className:"px-3 py-4 text-sm text-muted-foreground/60 text-center",children:f?i("header.orgSwitcher.noOrganizationsMatch",{query:f}):i("header.orgSwitcher.noOrganizationsAvailable")});let P;e[22]!==o||e[23]!==s?(P=k=>t.jsxs("button",{type:"button",onClick:()=>o(k.slug),className:H("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(it,{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(Ve,{size:14,className:"ml-auto text-muted-foreground shrink-0"})]},k.id),e[22]=o,e[23]=s,e[24]=P):P=e[24];const N=b.map(P);let y;e[25]!==x||e[26]!==D||e[27]!==N?(y=t.jsxs("div",{className:L,children:[x,D,N]}),e[25]=x,e[26]=D,e[27]=N,e[28]=y):y=e[28];let T;return e[29]!==y||e[30]!==I?(T=t.jsxs(t.Fragment,{children:[I,y]}),e[29]=y,e[30]=I,e[31]=T):T=e[31],T}function xs(n){const e=O.c(22),{trigger:s,orgParam:o,align:a,side:i}=n,l=a===void 0?"start":a,c=i===void 0?"bottom":i,r=ot(),[u,m]=R.useState(!1),[f,d]=R.useState(!1);let g;e[0]!==s?(g=t.jsx(Re,{asChild:!0,children:s}),e[0]=s,e[1]=g):g=e[1];const b=String(u);let h;e[2]!==r?(h=I=>{m(!1),r({to:"/$org",params:{org:I}})},e[2]=r,e[3]=h):h=e[3];let p;e[4]===Symbol.for("react.memo_cache_sentinel")?(p=()=>{m(!1),d(!0)},e[4]=p):p=e[4];let j;e[5]!==o||e[6]!==b||e[7]!==h?(j=t.jsx(ps,{orgParam:o,onSelectOrg:h,onCreateOrg:p},b),e[5]=o,e[6]=b,e[7]=h,e[8]=j):j=e[8];let v;e[9]!==l||e[10]!==c||e[11]!==j?(v=t.jsx(St,{side:c,align:l,sideOffset:8,collisionPadding:16,className:"w-[300px] p-0 flex flex-col max-h-[440px]",onOpenAutoFocus:vs,onCloseAutoFocus:js,children:j}),e[9]=l,e[10]=c,e[11]=j,e[12]=v):v=e[12];let C;e[13]!==u||e[14]!==g||e[15]!==v?(C=t.jsxs(Dt,{open:u,onOpenChange:m,children:[g,v]}),e[13]=u,e[14]=g,e[15]=v,e[16]=C):C=e[16];let _;e[17]!==f?(_=t.jsx(hn,{open:f,onOpenChange:d}),e[17]=f,e[18]=_):_=e[18];let S;return e[19]!==_||e[20]!==C?(S=t.jsxs(t.Fragment,{children:[C,_]}),e[19]=_,e[20]=C,e[21]=S):S=e[21],S}function js(n){return n.preventDefault()}function vs(n){n.preventDefault(),n.currentTarget?.querySelector("[data-org-switcher-search]")?.focus()}function bs(n){const e=O.c(21),{value:s,onChange:o,placeholder:a,onKeyDown:i,className:l,isSearching:c,disabled:r}=n,u=a===void 0?"Search...":a;let m;e[0]!==l?(m=H("shrink-0 w-full border-b border-border h-12",l),e[0]=l,e[1]=m):m=e[1];const f=r?"cursor-not-allowed opacity-50":"cursor-text";let d;e[2]!==f?(d=H("flex items-center gap-2.5 h-12 px-4",f),e[2]=f,e[3]=d):d=e[3];let g;e[4]!==c?(g=c?t.jsx(Ie,{size:16,className:"animate-spin text-muted-foreground shrink-0"}):t.jsx(kt,{size:16,className:"text-muted-foreground shrink-0"}),e[4]=c,e[5]=g):g=e[5];let b;e[6]!==o?(b=v=>o(v.target.value),e[6]=o,e[7]=b):b=e[7];let h;e[8]!==r||e[9]!==i||e[10]!==u||e[11]!==b||e[12]!==s?(h=t.jsx("input",{type:"text",value:s,onChange:b,onKeyDown:i,placeholder:u,disabled:r,className:"flex-1 min-w-0 bg-transparent text-sm text-foreground placeholder:text-muted-foreground/50 outline-none"}),e[8]=r,e[9]=i,e[10]=u,e[11]=b,e[12]=s,e[13]=h):h=e[13];let p;e[14]!==d||e[15]!==g||e[16]!==h?(p=t.jsxs("label",{className:d,children:[g,h]}),e[14]=d,e[15]=g,e[16]=h,e[17]=p):p=e[17];let j;return e[18]!==m||e[19]!==p?(j=t.jsx("div",{className:m,children:p}),e[18]=m,e[19]=p,e[20]=j):j=e[20],j}function Cs(n,e,s){if(!s)return null;const o=kn(n,e);return o?o.threads.get().find(i=>i.id===s)?.branch??null:null}function ys(n){const e=O.c(6),{value:s,onChange:o}=n,a=F();let i;e[0]!==a?(i=a("sidebar.agentsSection.searchAgents"),e[0]=a,e[1]=i):i=e[1];let l;return e[2]!==o||e[3]!==i||e[4]!==s?(l=t.jsx(bs,{value:s,onChange:o,placeholder:i}),e[2]=o,e[3]=i,e[4]=s,e[5]=l):l=e[5],l}function Ns(){const n=O.c(4),e=F();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 ws(n){const e=O.c(10),{org:s,onClose:o}=n,a=F();let i;e[0]!==s.slug?(i={org:s.slug},e[0]=s.slug,e[1]=i):i=e[1];let l;e[2]!==o?(l=()=>o(),e[2]=o,e[3]=l):l=e[3];let c;e[4]!==a?(c=a("sidebar.agentsSection.seeAllAgents"),e[4]=a,e[5]=c):c=e[5];let r;return e[6]!==i||e[7]!==l||e[8]!==c?(r=t.jsx("div",{className:"border-t border-border px-3 py-2.5",children:t.jsx(Jt,{to:"/$org/settings/agents",params:i,onClick:l,className:"text-xs text-muted-foreground hover:text-foreground transition-colors flex items-center justify-center",children:c})}),e[6]=i,e[7]=l,e[8]=c,e[9]=r):r=e[9],r}function _s(){const n=O.c(4),e=F();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(Ut,{children:s}),n[2]=s,n[3]=o):o=n[3],o}function Ss(n){const e=O.c(11),{onImportFromGithub:s}=n,o=F();let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(Dn,{className:"size-3.5"}),e[0]=a):a=e[0];let i;e[1]!==o?(i=o("sidebar.agentsSection.import"),e[1]=o,e[2]=i):i=e[2];let l;e[3]!==s||e[4]!==i?(l=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:[a,i]}),e[3]=s,e[4]=i,e[5]=l):l=e[5];let c;e[6]!==o?(c=o("sidebar.agentsSection.codeAgents"),e[6]=o,e[7]=c):c=e[7];let r;return e[8]!==l||e[9]!==c?(r=t.jsx(Ut,{action:l,children:c}),e[8]=l,e[9]=c,e[10]=r):r=e[10],r}function Ds(n){const e=O.c(11),{setOpen:s,emptyCtaClass:o}=n,a=F();let i;e[0]!==a?(i=a("sidebar.agentsSection.browseAgents"),e[0]=a,e[1]=i):i=e[1];let l;e[2]!==o?(l=H(o),e[2]=o,e[3]=l):l=e[3];let c;e[4]!==s?(c=()=>{B("agent_browser_opened",{surface:"mobile_drawer"}),s(!0)},e[4]=s,e[5]=c):c=e[5];let r;e[6]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(we,{className:"size-4"}),e[6]=r):r=e[6];let u;return e[7]!==i||e[8]!==l||e[9]!==c?(u=t.jsx(At,{"aria-label":i,className:l,onClick:c,children:r}),e[7]=i,e[8]=l,e[9]=c,e[10]=u):u=e[10],u}function ks(n){const e=O.c(17),{setOpen:s,highlightEmpty:o,emptyCtaClass:a}=n,i=F();let l;e[0]!==o||e[1]!==i?(l=o?void 0:i("sidebar.agentsSection.browseAgents"),e[0]=o,e[1]=i,e[2]=l):l=e[2];let c;e[3]!==a?(c=H(a),e[3]=a,e[4]=c):c=e[4];let r;e[5]!==s?(r=()=>{B("agent_browser_opened",{surface:"mobile_drawer"}),s(!0)},e[5]=s,e[6]=r):r=e[6];let u;e[7]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(we,{}),e[7]=u):u=e[7];let m;e[8]!==i?(m=i("sidebar.agentsSection.newAgent"),e[8]=i,e[9]=m):m=e[9];let f;e[10]!==m?(f=t.jsx("span",{children:m}),e[10]=m,e[11]=f):f=e[11];let d;return e[12]!==l||e[13]!==c||e[14]!==r||e[15]!==f?(d=t.jsx(pt,{children:t.jsxs(xt,{tooltip:l,className:c,onClick:r,children:[u,f]})}),e[12]=l,e[13]=c,e[14]=r,e[15]=f,e[16]=d):d=e[16],d}function Is(){const n=O.c(4),e=F();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(Ot,{className:"sr-only",children:s}),n[2]=s,n[3]=o):o=n[3],o}function As(n){const e=O.c(8),{emptyCtaClass:s}=n,o=F();let a;e[0]!==o?(a=o("sidebar.agentsSection.browseAgents"),e[0]=o,e[1]=a):a=e[1];let i;e[2]!==s?(i=H(s),e[2]=s,e[3]=i):i=e[3];let l;e[4]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx(we,{className:"size-4"}),e[4]=l):l=e[4];let c;return e[5]!==a||e[6]!==i?(c=t.jsx(At,{"aria-label":a,className:i,children:l}),e[5]=a,e[6]=i,e[7]=c):c=e[7],c}function Ts(n){const e=O.c(19),{wrapEmptyHint:s,highlightEmpty:o,emptyCtaClass:a}=n,i=F();let l;e[0]!==o||e[1]!==i?(l=o?void 0:i("sidebar.agentsSection.browseAgents"),e[0]=o,e[1]=i,e[2]=l):l=e[2];let c;e[3]!==a?(c=H(a),e[3]=a,e[4]=c):c=e[4];let r;e[5]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(we,{}),e[5]=r):r=e[5];let u;e[6]!==i?(u=i("sidebar.agentsSection.newAgent"),e[6]=i,e[7]=u):u=e[7];let m;e[8]!==u?(m=t.jsx("span",{children:u}),e[8]=u,e[9]=m):m=e[9];let f;e[10]!==l||e[11]!==c||e[12]!==m?(f=t.jsx(Re,{asChild:!0,children:t.jsxs(xt,{tooltip:l,className:c,children:[r,m]})}),e[10]=l,e[11]=c,e[12]=m,e[13]=f):f=e[13];let d;e[14]!==f||e[15]!==s?(d=s(f),e[14]=f,e[15]=s,e[16]=d):d=e[16];let g;return e[17]!==d?(g=t.jsx(pt,{children:d}),e[17]=d,e[18]=g):g=e[18],g}function Ps(n){const e=O.c(9),{children:s}=n,o=F();let a;e[0]!==s?(a=t.jsx(Ce,{asChild:!0,children:s}),e[0]=s,e[1]=a):a=e[1];let i;e[2]!==o?(i=o("sidebar.agentsSection.selectAnExistingAgent"),e[2]=o,e[3]=i):i=e[3];let l;e[4]!==i?(l=t.jsx(ye,{side:"right",sideOffset:8,children:i}),e[4]=i,e[5]=l):l=e[5];let c;return e[6]!==a||e[7]!==l?(c=t.jsxs(Ne,{defaultOpen:!0,delayDuration:0,children:[a,l]}),e[6]=a,e[7]=l,e[8]=c):c=e[8],c}function Os(n){const e=ot(),{create:s}=In(),{locator:o}=oe(),a=yt(),i=bn();return async l=>{const c=crypto.randomUUID(),r=l===i?Cs(n,o,a??""):null;try{await s({id:c,virtual_mcp_id:l,...r?{branch:r}:{}})}catch{}e({to:"/$org/$taskId",params:{org:n,taskId:c},search:{virtualmcpid:l}})}}function st(n){const e=O.c(20),{agent:s,selected:o,onClick:a}=n,i=o?"bg-accent text-accent-foreground":"text-foreground hover:bg-accent/50";let l;e[0]!==i?(l=H("flex items-center gap-3 px-3 py-2.5 rounded-md text-sm text-left w-full transition-colors",i),e[0]=i,e[1]=l):l=e[1];let c;e[2]!==s.icon||e[3]!==s.title?(c=t.jsx(Ct,{icon:s.icon,name:s.title,size:"xs",className:"shrink-0"}),e[2]=s.icon,e[3]=s.title,e[4]=c):c=e[4];let r;e[5]!==s.title?(r=t.jsx("p",{className:"text-sm font-medium truncate",children:s.title}),e[5]=s.title,e[6]=r):r=e[6];let u;e[7]!==s.description?(u=s.description&&t.jsx("p",{className:"text-xs text-muted-foreground truncate",children:s.description}),e[7]=s.description,e[8]=u):u=e[8];let m;e[9]!==r||e[10]!==u?(m=t.jsxs("div",{className:"flex-1 min-w-0",children:[r,u]}),e[9]=r,e[10]=u,e[11]=m):m=e[11];let f;e[12]!==o?(f=o&&t.jsx(Ve,{size:14,className:"ml-auto text-muted-foreground shrink-0"}),e[12]=o,e[13]=f):f=e[13];let d;return e[14]!==a||e[15]!==l||e[16]!==c||e[17]!==m||e[18]!==f?(d=t.jsxs("button",{type:"button",onClick:a,className:l,children:[c,m,f]}),e[14]=a,e[15]=l,e[16]=c,e[17]=m,e[18]=f,e[19]=d):d=e[19],d}function Ut(n){const e=O.c(5),{children:s,action:o}=n;let a;e[0]!==s?(a=t.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:s}),e[0]=s,e[1]=a):a=e[1];let i;return e[2]!==o||e[3]!==a?(i=t.jsxs("div",{className:"flex items-center justify-between px-3 pb-1 pt-2",children:[a,o]}),e[2]=o,e[3]=a,e[4]=i):i=e[4],i}function zs(n){const e=O.c(23),{onClose:s,onSelectAgent:o,selectedAgentId:a,onImportFromGithub:i}=n,[l,c]=R.useState(""),r=_t(),u=r??[],{org:m}=oe(),{data:f}=re.useSession(),d=f?.user?.id??"anon",g=Tn(r),b=Pn(),h=Os(m.slug),p=Mn(r),j=l.toLowerCase(),v=u.filter(Ls).filter($=>!p.has($.id)).filter(Fs).filter($=>!l||$.title.toLowerCase().includes(j)),C=v.filter($s),_=v.filter(Ms),S=bt(m.id),I=!l||S.title.toLowerCase().includes(j),L=!!(o&&I);let x;e[0]!==s||e[1]!==o?(x=()=>{o?.(null),s(),c("")},e[0]=s,e[1]=o,e[2]=x):x=e[2];const D=x,P=$=>{if(o){o($.id),s(),c("");return}On({orgId:m.id,userId:d},$.id,g),b(),s(),c(""),h($.id)},N="flex flex-col max-h-[min(640px,80dvh)]";let y;e[3]!==l?(y=t.jsx(ys,{value:l,onChange:c}),e[3]=l,e[4]=y):y=e[4];const T="overflow-y-auto flex-1 min-h-0 p-1.5 flex flex-col gap-0.5",k=o&&I&&S&&t.jsx(st,{agent:S,selected:!a||a===S.id,onClick:D}),A=(C.length>0||!l)&&t.jsx(Ss,{onImportFromGithub:i}),z=C.map($=>t.jsx(st,{agent:$,selected:o?a===$.id:void 0,onClick:()=>P($)},$.id)),V=_.length>0&&t.jsx(_s,{}),X=_.map($=>t.jsx(st,{agent:$,selected:o?a===$.id:void 0,onClick:()=>P($)},$.id));let E;e[5]!==L||e[6]!==l||e[7]!==v.length?(E=v.length===0&&!L&&l&&t.jsx(Ns,{}),e[5]=L,e[6]=l,e[7]=v.length,e[8]=E):E=e[8];let ne;e[9]!==E||e[10]!==k||e[11]!==A||e[12]!==z||e[13]!==V||e[14]!==X?(ne=t.jsxs("div",{className:T,children:[k,A,z,V,X,E]}),e[9]=E,e[10]=k,e[11]=A,e[12]=z,e[13]=V,e[14]=X,e[15]=ne):ne=e[15];let q;e[16]!==s||e[17]!==m?(q=t.jsx(ws,{org:m,onClose:s}),e[16]=s,e[17]=m,e[18]=q):q=e[18];let de;return e[19]!==ne||e[20]!==q||e[21]!==y?(de=t.jsxs("div",{className:N,children:[y,ne,q]}),e[19]=ne,e[20]=q,e[21]=y,e[22]=de):de=e[22],de}function Ms(n){return!Mt(n.metadata)}function $s(n){return Mt(n.metadata)}function Fs(n){return!mn(n.id)}function Ls(n){return!un(n.id)}function Es(n){const e=O.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:a,onSelectAgent:i,selectedAgentId:l,side:c,align:r}=s,u=o===void 0?!1:o,m=c===void 0?"right":c,f=r===void 0?"start":r,[d,g]=R.useState(!1),[b,h]=R.useState(!1),p=gt(),{setOpenMobile:j}=ht(),v=An(),C=v?"border border-border":void 0;let _;e[2]!==v?(_=A=>v?t.jsx(Ps,{children:A}):A,e[2]=v,e[3]=_):_=e[3];const S=_;let I;e[4]!==p||e[5]!==j?(I=()=>{g(!1),p&&j(!1)},e[4]=p,e[5]=j,e[6]=I):I=e[6];const L=I;let x;e[7]!==L?(x=()=>{L(),h(!0)},e[7]=L,e[8]=x):x=e[8];const D=x;let P;e[9]!==L||e[10]!==D||e[11]!==i||e[12]!==d||e[13]!==l?(P=d&&t.jsx(R.Suspense,{fallback:t.jsx("div",{className:"flex items-center justify-center py-8",children:t.jsx(Zt,{className:"h-4 w-24"})}),children:t.jsx(zs,{onClose:L,onSelectAgent:i,selectedAgentId:l,onImportFromGithub:D})}),e[9]=L,e[10]=D,e[11]=i,e[12]=d,e[13]=l,e[14]=P):P=e[14];const N=P;let y;e[15]!==f||e[16]!==u||e[17]!==C||e[18]!==v||e[19]!==p||e[20]!==d||e[21]!==N||e[22]!==m||e[23]!==a||e[24]!==S?(y=p?t.jsxs(t.Fragment,{children:[a?t.jsx("button",{type:"button",onClick:()=>g(!0),className:"contents",children:a}):u?S(t.jsx(Ds,{setOpen:g,emptyCtaClass:C})):t.jsx(ks,{setOpen:g,highlightEmpty:v,emptyCtaClass:C}),t.jsx(Tt,{open:d,onOpenChange:g,direction:"bottom",children:t.jsxs(Pt,{className:"max-h-[85dvh] p-0",children:[t.jsx(Is,{}),N]})})]}):t.jsxs(Dt,{open:d,onOpenChange:A=>{A&&!d&&B("agent_browser_opened",{surface:"desktop_popover"}),g(A)},children:[a?t.jsx(Re,{asChild:!0,children:a}):u?S(t.jsx(Re,{asChild:!0,children:t.jsx(As,{emptyCtaClass:C})})):t.jsx(Ts,{wrapEmptyHint:S,highlightEmpty:v,emptyCtaClass:C}),t.jsx(St,{className:"w-[380px] p-0 overflow-hidden",side:m,align:f,children:N})]}),e[15]=f,e[16]=u,e[17]=C,e[18]=v,e[19]=p,e[20]=d,e[21]=N,e[22]=m,e[23]=a,e[24]=S,e[25]=y):y=e[25];let T;e[26]!==b?(T=t.jsx(Sn,{open:b,onOpenChange:h,mode:"agent"}),e[26]=b,e[27]=T):T=e[27];let k;return e[28]!==T||e[29]!==y?(k=t.jsxs(t.Fragment,{children:[y,T]}),e[28]=T,e[29]=y,e[30]=k):k=e[30],k}function Bs(){const n=O.c(2),e=_t()??[];let s;return n[0]!==e?(s=o=>{if(!o)return;const a=e.find(i=>i.id===o);return a?$n(a.metadata):void 0},n[0]=e,n[1]=s):s=n[1],s}const Rs="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 Vs(n){const e=O.c(29),{agentId:s,fallback:o,onOpenHome:a,onPick:i}=n,l=F(),c=Cn(s)??o??null;let r,u,m,f,d;e[0]!==c?.title||e[1]!==a||e[2]!==l?(d=c?.title??l("header.shellBreadcrumb.superAgentDefaultName"),f="flex min-w-0 items-center gap-0",r="button",u=a,m=l("header.shellBreadcrumb.openAgentHome",{name:d}),e[0]=c?.title,e[1]=a,e[2]=l,e[3]=r,e[4]=u,e[5]=m,e[6]=f,e[7]=d):(r=e[3],u=e[4],m=e[5],f=e[6],d=e[7]);const g=c?.icon??null;let b;e[8]!==g||e[9]!==d?(b=t.jsx(Ct,{icon:g,name:d,size:"xs"}),e[8]=g,e[9]=d,e[10]=b):b=e[10];let h;e[11]!==r||e[12]!==u||e[13]!==m||e[14]!==b?(h=t.jsx("button",{type:r,onClick:u,"aria-label":m,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:b}),e[11]=r,e[12]=u,e[13]=m,e[14]=b,e[15]=h):h=e[15];let p;e[16]!==d?(p=t.jsx("span",{className:"truncate font-medium max-w-[8rem]",children:d}),e[16]=d,e[17]=p):p=e[17];let j;e[18]===Symbol.for("react.memo_cache_sentinel")?(j=t.jsx(wt,{size:14,className:"shrink-0 text-muted-foreground opacity-70"}),e[18]=j):j=e[18];let v;e[19]!==p?(v=t.jsxs("button",{type:"button",className:Rs,children:[p,j]}),e[19]=p,e[20]=v):v=e[20];let C;e[21]!==s||e[22]!==i||e[23]!==v?(C=t.jsx(Es,{side:"bottom",align:"start",selectedAgentId:s,onSelectAgent:i,trigger:v}),e[21]=s,e[22]=i,e[23]=v,e[24]=C):C=e[24];let _;return e[25]!==C||e[26]!==f||e[27]!==h?(_=t.jsxs("div",{className:f,children:[h,C]}),e[25]=C,e[26]=f,e[27]=h,e[28]=_):_=e[28],_}function Yo(n){const e=O.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,a=F(),{org:i}=oe(),{state:l,isMobile:c}=ht(),r=Ht().invitations.length>0,u=l==="collapsed"||c;let m;e[2]!==r||e[3]!==i.name||e[4]!==a?(m=r?a("header.shellBreadcrumb.switchOrganizationPendingInvitation",{name:i.name}):a("header.shellBreadcrumb.switchOrganization",{name:i.name}),e[2]=r,e[3]=i.name,e[4]=a,e[5]=m):m=e[5];let f;e[6]!==i?(f=t.jsx(it,{org:i,size:"sm"}),e[6]=i,e[7]=f):f=e[7];let d;e[8]!==r||e[9]!==u?(d=r&&t.jsx("span",{className:H("absolute -right-1 size-2.5 rounded-full bg-destructive ring-2 ring-background",u?"-top-1":"top-1/2 -translate-y-1/2")}),e[8]=r,e[9]=u,e[10]=d):d=e[10];let g;e[11]!==f||e[12]!==d?(g=t.jsxs("span",{className:"relative inline-flex",children:[f,d]}),e[11]=f,e[12]=d,e[13]=g):g=e[13];let b;e[14]!==i.name||e[15]!==o?(b=o&&t.jsx("span",{className:"truncate text-sm font-medium text-foreground max-w-[10rem]",children:i.name}),e[14]=i.name,e[15]=o,e[16]=b):b=e[16];let h;e[17]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx(wt,{size:14,className:"shrink-0 text-muted-foreground opacity-70"}),e[17]=h):h=e[17];let p;e[18]!==m||e[19]!==g||e[20]!==b?(p=t.jsx(Ce,{asChild:!0,children:t.jsxs("button",{type:"button","aria-label":m,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:[g,b,h]})}),e[18]=m,e[19]=g,e[20]=b,e[21]=p):p=e[21];let j;e[22]!==i.slug||e[23]!==p?(j=t.jsx(xs,{orgParam:i.slug,trigger:p}),e[22]=i.slug,e[23]=p,e[24]=j):j=e[24];let v;e[25]!==i.name?(v=t.jsx(ye,{side:"bottom",children:i.name}),e[25]=i.name,e[26]=v):v=e[26];let C;return e[27]!==v||e[28]!==j?(C=t.jsxs(Ne,{children:[j,v]}),e[27]=v,e[28]=j,e[29]=C):C=e[29],C}function Zo(n){const e=O.c(21);let s;e[0]!==n?(s=n===void 0?{}:n,e[0]=n,e[1]=s):s=e[1];const{onNavigate:o}=s,{org:a}=oe(),{threads:i}=zt(),{data:l}=re.useSession(),{setTaskId:c,createNewTask:r}=$t(),u=Bs();let m;e[2]!==a.id?(m=bt(a.id),e[2]=a.id,e[3]=m):m=e[3];const f=m,d=f.id,g=Nt();let b;e[4]!==r||e[5]!==d||e[6]!==o||e[7]!==u||e[8]!==l?.user?.id||e[9]!==c||e[10]!==i?(b=_=>{const S=_??d,I=zn(i,S,l?.user?.id,u(S));I?c(I.id,S):r(S),o?.()},e[4]=r,e[5]=d,e[6]=o,e[7]=u,e[8]=l?.user?.id,e[9]=c,e[10]=i,e[11]=b):b=e[11];const h=b;let p;e[12]===Symbol.for("react.memo_cache_sentinel")?(p=t.jsx("span",{className:"h-5 w-24 rounded bg-muted animate-pulse"}),e[12]=p):p=e[12];const j=g===d?f:void 0;let v;e[13]!==g||e[14]!==h?(v=()=>h(g),e[13]=g,e[14]=h,e[15]=v):v=e[15];let C;return e[16]!==g||e[17]!==h||e[18]!==j||e[19]!==v?(C=t.jsx(R.Suspense,{fallback:p,children:t.jsx(Vs,{agentId:g,fallback:j,onOpenHome:v,onPick:h})}),e[16]=g,e[17]=h,e[18]=j,e[19]=v,e[20]=C):C=e[20],C}function Jo(){const n=O.c(20),e=F(),{threads:s}=zt(),{createNewTask:o}=$t(),a=Nt(),i=yt();let l;n[0]!==i||n[1]!==s?(l=s.find(p=>p.id===i)?.branch??null,n[0]=i,n[1]=s,n[2]=l):l=n[2];const c=l;let r;n[3]!==a||n[4]!==o||n[5]!==c?(r=()=>{o(a,c)},n[3]=a,n[4]=o,n[5]=c,n[6]=r):r=n[6];const u=r;let m;n[7]!==e?(m=e("sidebar.taskGroupsList.newChat"),n[7]=e,n[8]=m):m=n[8];let f;n[9]===Symbol.for("react.memo_cache_sentinel")?(f=t.jsx(vn,{size:16}),n[9]=f):f=n[9];let d;n[10]!==u||n[11]!==m?(d=t.jsx(Ce,{asChild:!0,children:t.jsx("button",{type:"button",onClick:u,"aria-label":m,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:f})}),n[10]=u,n[11]=m,n[12]=d):d=n[12];let g;n[13]!==e?(g=e("sidebar.taskGroupsList.newChat"),n[13]=e,n[14]=g):g=n[14];let b;n[15]!==g?(b=t.jsx(ye,{side:"bottom",children:g}),n[15]=g,n[16]=b):b=n[16];let h;return n[17]!==d||n[18]!==b?(h=t.jsxs(Ne,{children:[d,b]}),n[17]=d,n[18]=b,n[19]=h):h=n[19],h}function Ks({open:n,onOpenChange:e,onCreated:s}){const o=F(),{org:a}=oe(),{data:i}=re.useSession(),{stdioEnabled:l}=en(),c=gt(),r=Kt(),u=Ft(),f=Lt(u,"").items,d=tn({resolver:nn(Yn),defaultValues:{title:"",description:null,icon:null,ui_type:"HTTP",connection_url:"",connection_token:null,npx_package:"",stdio_command:"",stdio_args:"",stdio_cwd:"",env_vars:[]}}),g=d.watch("ui_type"),b=d.watch("connection_url"),h=d.watch("npx_package"),p=Le({uiType:g,connectionUrl:b??"",npxPackage:h??""})??ut({uiType:g,connectionUrl:b??"",registryItems:f}),j=x=>{const D=x.trim();if(!D)return;const P=!!d.formState.dirtyFields.title,N=!!d.formState.dirtyFields.description,y=!!d.formState.dirtyFields.env_vars,T=A=>{if(A&&(!P&&!d.getValues("title").trim()&&A.title&&d.setValue("title",A.title,{shouldDirty:!1}),!N&&!(d.getValues("description")??"").trim()&&A.description&&d.setValue("description",A.description,{shouldDirty:!1}),!y&&A.envVarKeys?.length)){const z=d.getValues("env_vars")??[],V=new Set(z.map(E=>E.key)),X=A.envVarKeys.filter(E=>!V.has(E));X.length>0&&d.setValue("env_vars",[...z,...X.map(E=>({key:E,value:""}))],{shouldDirty:!0})}},k=Jn(D);if(k&&l){d.setValue("ui_type","NPX",{shouldDirty:!0}),d.setValue("npx_package",k.packageName,{shouldDirty:!0}),d.setValue("connection_url","",{shouldDirty:!0}),d.setValue("connection_token",null,{shouldDirty:!0}),T(Le({uiType:"NPX",npxPackage:k.packageName}));return}if(D.startsWith("http://")||D.startsWith("https://")){const A=g==="HTTP"||g==="SSE"||g==="Websocket"?g:"HTTP";d.setValue("ui_type",A,{shouldDirty:!0}),d.setValue("connection_url",D,{shouldDirty:!0}),T(Le({uiType:A,connectionUrl:D})??ut({uiType:A,connectionUrl:D,registryItems:f}));return}g==="NPX"&&T(Le({uiType:"NPX",npxPackage:D}))},v=x=>{x||d.reset(),e(x)},C=async x=>{let D,P=null,N=null,y=null;x.ui_type==="NPX"?(D="STDIO",P="",y=es(x.npx_package||"",x.env_vars||[])):x.ui_type==="STDIO"?(D="STDIO",P="",y=ts(x.stdio_command||"",x.stdio_args||"",x.stdio_cwd,x.env_vars||[])):(D=x.ui_type,P=x.connection_url||"",N=x.connection_token||null);const T=Ln("conn");try{await r.create.mutateAsync({id:T,title:x.title,description:x.description||null,connection_type:D,connection_url:P,connection_token:N,created_at:new Date().toISOString(),updated_at:new Date().toISOString(),created_by:i?.user?.id||"system",organization_id:a.id,icon:x.icon??null,app_name:null,app_id:null,connection_headers:y,oauth_config:null,configuration_state:null,metadata:null,tools:null,bindings:null,status:"inactive"}),d.reset(),e(!1),s?.(T)}catch{K.error(o("connections.createConnectionDialog.failedToCreateConnection"))}},_=o("connections.createConnectionDialog.title"),S=o("connections.createConnectionDialog.description"),I=d.formState.isSubmitting?o("connections.createConnectionDialog.saving"):o("connections.createConnectionDialog.createButton"),L=t.jsxs("div",{className:"grid gap-4",children:[t.jsx(W,{control:d.control,name:"ui_type",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.typeLabel")}),t.jsxs(Un,{value:x.value,onValueChange:x.onChange,children:[t.jsx(J,{children:t.jsx(qn,{children:t.jsx(Gn,{})})}),t.jsxs(Xn,{children:[t.jsx(De,{value:"HTTP",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(Je,{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(Je,{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(Je,{className:"w-4 h-4"}),o("connections.createConnectionDialog.websocketType")]})}),l&&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(Wn,{className:"w-4 h-4"}),o("connections.createConnectionDialog.customCommandType")]})})]})]})]}),t.jsx(ee,{})]})}),g==="NPX"&&t.jsx(W,{control:d.control,name:"npx_package",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.npmPackageLabel")}),t.jsx(J,{children:t.jsx(ce,{placeholder:o("connections.createConnectionDialog.npmPackagePlaceholder"),...x,value:x.value??"",onPaste:D=>{const P=D.clipboardData.getData("text");P&&(D.preventDefault(),d.setValue("npx_package",P.trim(),{shouldDirty:!0}),j(P))},onBlur:D=>{j(D.target.value),x.onBlur()}})}),t.jsx(ee,{})]})}),g==="STDIO"&&t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"grid grid-cols-2 gap-4 items-start",children:[t.jsx(W,{control:d.control,name:"stdio_command",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.commandLabel")}),t.jsx(J,{children:t.jsx(ce,{placeholder:o("connections.createConnectionDialog.commandPlaceholder"),...x,value:x.value??""})}),t.jsx(ee,{})]})}),t.jsx(W,{control:d.control,name:"stdio_args",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.argumentsLabel")}),t.jsx(J,{children:t.jsx(ce,{placeholder:o("connections.createConnectionDialog.argumentsPlaceholder"),...x,value:x.value??""})}),t.jsx(ee,{})]})})]}),t.jsx(W,{control:d.control,name:"stdio_cwd",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.workingDirectoryLabel")}),t.jsx(J,{children:t.jsx(ce,{placeholder:o("connections.createConnectionDialog.workingDirectoryPlaceholder"),...x,value:x.value??""})}),t.jsx("p",{className:"text-xs text-muted-foreground",children:o("connections.createConnectionDialog.workingDirectoryDescription")}),t.jsx(ee,{})]})})]}),(g==="NPX"||g==="STDIO")&&t.jsx(W,{control:d.control,name:"env_vars",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.environmentVariablesLabel")}),t.jsx(J,{children:t.jsx(Zn,{value:x.value??[],onChange:x.onChange})}),t.jsx(ee,{})]})}),g!=="NPX"&&g!=="STDIO"&&t.jsxs(t.Fragment,{children:[t.jsx(W,{control:d.control,name:"connection_url",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.urlLabel")}),t.jsx(J,{children:t.jsx(ce,{placeholder:o("connections.createConnectionDialog.urlPlaceholder"),...x,value:x.value??"",onPaste:D=>{const P=D.clipboardData.getData("text");P&&(D.preventDefault(),d.setValue("connection_url",P.trim(),{shouldDirty:!0}),j(P))},onBlur:D=>{j(D.target.value),x.onBlur()}})}),t.jsx(ee,{})]})}),t.jsx(W,{control:d.control,name:"connection_token",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:p?.token?.label??o("connections.createConnectionDialog.tokenLabelDefault")}),t.jsx(J,{children:t.jsx(ce,{type:"password",placeholder:p?.token?.placeholder??o("connections.createConnectionDialog.tokenPlaceholderDefault"),className:"ph-no-capture",...x,value:x.value??""})}),p?.token?.helperText&&t.jsxs("p",{className:"text-xs text-muted-foreground",children:[p.token.helperText,p.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(W,{control:d.control,name:"title",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.nameLabel")}),t.jsx(J,{children:t.jsx(ce,{placeholder:o("connections.createConnectionDialog.namePlaceholder"),...x})}),t.jsx(ee,{})]})}),t.jsx(W,{control:d.control,name:"description",render:({field:x})=>t.jsxs(Y,{children:[t.jsx(Z,{children:o("connections.createConnectionDialog.descriptionLabel")}),t.jsx(J,{children:t.jsx(Qn,{placeholder:o("connections.createConnectionDialog.descriptionPlaceholder"),rows:3,...x,value:x.value??""})}),t.jsx(ee,{})]})})]});return c?t.jsx(Tt,{open:n,onOpenChange:v,children:t.jsxs(Pt,{className:"max-h-[90vh]",children:[t.jsx(yn,{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(Ot,{children:_}),t.jsx(Nn,{className:"mt-1",children:S})]}),t.jsx(wn,{asChild:!0,children:t.jsx(te,{variant:"ghost",size:"icon",className:"shrink-0 -mt-1",children:t.jsx(It,{size:16})})})]})}),t.jsx(dt,{...d,children:t.jsxs("form",{onSubmit:d.handleSubmit(C),children:[t.jsx("div",{className:"overflow-y-auto px-4 pb-4",children:L}),t.jsx(_n,{children:t.jsx(te,{type:"submit",disabled:d.formState.isSubmitting,className:"w-full",children:I})})]})})]})}):t.jsx(Et,{open:n,onOpenChange:v,children:t.jsxs(Bt,{className:"sm:max-w-[525px]",children:[t.jsxs(Rt,{children:[t.jsx(Vt,{children:_}),t.jsx(Kn,{children:S})]}),t.jsx(dt,{...d,children:t.jsxs("form",{onSubmit:d.handleSubmit(C),children:[t.jsx("div",{className:"py-4",children:L}),t.jsxs(Hn,{children:[t.jsx(te,{type:"button",variant:"outline",onClick:()=>v(!1),children:o("connections.createConnectionDialog.cancelButton")}),t.jsx(te,{type:"submit",disabled:d.formState.isSubmitting,className:"min-w-40",children:I})]})]})})]})})}function Hs(n){const e=O.c(72),{mode:s,agentId:o,addedConnectionIds:a,onAdd:i,onCloneAndAdd:l,onConnectAndAdd:c,connectingItemId:r,search:u,onCreateConnection:m,onBrowseNavigate:f,defaultTab:d}=n,g=s===void 0?"add":s,b=d===void 0?"connected":d,h=F(),{org:p}=oe(),j=R.useDeferredValue(u),v=u!==j;let C;e[0]!==j?(C=j.trim().toLowerCase(),e[0]=j,e[1]=C):C=e[1];const _=C;let S;e[2]!==b?(S=w=>w??b,e[2]=b,e[3]=S):S=e[3];const[I,L]=sn(on.connectionsTab(p.slug)+(b==="all"?":home-modal":":agent-modal"),S);let x;e[4]!==I||e[5]!==L?(x=w=>{w!==I&&B("connections_dialog_tab_changed",{to_tab:w}),L(w)},e[4]=I,e[5]=L,e[6]=x):x=e[6];const D=x;let P;e[7]!==p.id||e[8]!==p.slug?(P={connectionId:vt,orgId:p.id,orgSlug:p.slug},e[7]=p.id,e[8]=p.slug,e[9]=P):P=e[9];const N=cn(P),y=j?.trim().split(/\s+/).filter(Boolean)??[],T=y.length>0?{operator:"or",conditions:y.flatMap(Zs)}:void 0,k={...T&&{where:T},orderBy:[{field:["updated_at"],direction:"asc"}],limit:100,offset:0},A=JSON.stringify(k),{data:z,fetchNextPage:V,hasNextPage:X,isFetchingNextPage:E}=os({queryKey:Ae.collectionListInfinite(N,p.id,"","CONNECTIONS",A),queryFn:async w=>{const{pageParam:M}=w,se=M===void 0?0:M;return(await N.callTool({name:"COLLECTION_CONNECTIONS_LIST",arguments:{...T&&{where:T},orderBy:[{field:["updated_at"],direction:"asc"}],limit:100,offset:se}})).structuredContent},initialPageParam:0,getNextPageParam:Ws,staleTime:3e4}),ne=z?.pages.flatMap(Qs)??[],q=Vn(ne),de=new Set(ne.filter(Xs).map(Gs)),$=Ft(),ie=Lt($,j),He=mt(ie.loadMore,ie.hasMore,ie.isLoadingMore),Ue=mt(V,X??!1,E),G=I==="all"||!!_,at=G?ie.items.filter(w=>{const M=En(w);if(M&&de.has(M))return!1;if(!_)return!0;const se=Ke(w._meta),ae=[w.title,w.description,w.name,w.server?.title,w.server?.description,w.server?.name,se?.friendly_name,se?.friendlyName].filter(Boolean).join(" ").toLowerCase();return y.some(Q=>ae.includes(Q.toLowerCase()))}):[],_e=at.filter(qs),Se=at.filter(Us);let Te;e[10]!==a?(Te=w=>w.some(M=>a.has(M.id)),e[10]=a,e[11]=Te):Te=e[11];const qe=Te;let Pe;e[12]!==a||e[13]!==o||e[14]!==r||e[15]!==qe||e[16]!==g||e[17]!==i||e[18]!==f||e[19]!==l||e[20]!==h?(Pe=(w,M,se,ae,Q)=>{const Fe=qe(Q),be=Q.find(le=>!a.has(le.id)),U=Q[0];if(g==="browse"){const le=ns(U);return t.jsx(et,{connection:{title:M,icon:se,description:Q.length>1?`${Q.length} instances`:ae??void 0},fallbackIcon:t.jsx(Be,{}),headerActionsAlwaysVisible:!0,headerActions:t.jsxs(Ee,{variant:"secondary",className:"text-xs gap-1 font-normal",children:[t.jsx(Ve,{size:11})," ",h("virtualMcp.connectionDialogContent.connected")]}),onClick:()=>{B("connection_browse_clicked",{app_name:U.app_name??null,connection_id:U.id,instances_count:Q.length}),f?.(le)}},w)}return t.jsx(et,{connection:{title:M,icon:se,description:ae},fallbackIcon:t.jsx(Be,{}),headerActionsAlwaysVisible:!0,headerActions:t.jsxs("div",{className:"flex items-center gap-1.5",children:[Fe&&t.jsxs(Ee,{variant:"secondary",className:"text-xs gap-1 font-normal",children:[t.jsx(Ve,{size:11})," ",h("virtualMcp.connectionDialogContent.added")]}),t.jsx(te,{variant:"outline",size:"sm",className:"h-7 px-3 text-xs font-medium",disabled:r!==null,onClick:le=>{le.stopPropagation(),be?(B("connection_add_clicked",{action:"use_existing",app_name:U.app_name??null,connection_id:be.id}),o&&B("agent_connection_attached",{agent_id:o,connection_id:be.id,app_name:U.app_name??null,mode:"existing"}),i(be.id)):(B("connection_add_clicked",{action:"clone",app_name:U.app_name??null,base_connection_id:U.id}),l(U))},children:h("virtualMcp.connectionDialogContent.add")})]})},w)},e[12]=a,e[13]=o,e[14]=r,e[15]=qe,e[16]=g,e[17]=i,e[18]=f,e[19]=l,e[20]=h,e[21]=Pe):Pe=e[21];const Oe=Pe;let ze;e[22]!==r||e[23]!==g||e[24]!==c||e[25]!==h?(ze=w=>{const M=Ke(w._meta),se=M?.friendlyName||M?.friendly_name||w.server?.title||w.title||w.server?.name||w.name||w.id||"",ae=w.server?.description||w.description||null,Q=w.server?.icons?.[0]?.src||Bn(w.server?.repository)||null,Fe=M?.official===!0,be=M?.verified===!0,U=M?.owner==="deco";return t.jsx(et,{connection:{title:se,description:ae,icon:Q},fallbackIcon:t.jsx(Be,{}),headerActionsAlwaysVisible:!0,headerActions:t.jsxs("div",{className:"flex items-center gap-1.5",children:[U&&t.jsxs(Ne,{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")})]}),!U&&Fe&&t.jsxs(Ne,{children:[t.jsx(Ce,{asChild:!0,children:t.jsx(Ee,{variant:"outline",size:"icon",children:t.jsx(tt,{})})}),t.jsx(ye,{children:h("virtualMcp.connectionDialogContent.builtByOfficial")})]}),!U&&!Fe&&be&&t.jsxs(Ne,{children:[t.jsx(Ce,{asChild:!0,children:t.jsx(Ee,{variant:"outline",size:"icon",children:t.jsx(tt,{})})}),t.jsx(ye,{children:h("virtualMcp.connectionDialogContent.verifiedByDeco")})]}),t.jsx(te,{variant:"outline",size:"sm",className:"h-7 px-3 text-xs font-medium",disabled:r!==null,onClick:le=>{le.stopPropagation(),B("connection_add_clicked",{action:"connect_new",registry_item_id:w.id,app_name:M?.friendlyName||w.server?.name||w.name||null}),c(w)},children:r===w.id?t.jsx(Ie,{size:14,className:"animate-spin"}):h(g==="browse"?"virtualMcp.connectionDialogContent.connect":"virtualMcp.connectionDialogContent.add")})]})},`catalog-${w.id}`)},e[22]=r,e[23]=g,e[24]=c,e[25]=h,e[26]=ze):ze=e[26];const lt=ze;let ue;e[27]!==I||e[28]!==D||e[29]!==m||e[30]!==_||e[31]!==h?(ue=!_&&t.jsxs("div",{className:"flex items-center justify-between px-5 py-3 border-b border-border shrink-0",children:[t.jsx(ss,{tabs:[{id:"all",label:h("virtualMcp.connectionDialogContent.tabAll")},{id:"connected",label:h("virtualMcp.connectionDialogContent.tabConnected")}],activeTab:I,onTabChange:w=>D(w)}),t.jsxs(te,{variant:"outline",size:"sm",className:"h-7 px-2 text-sm",onClick:()=>{B("connections_dialog_custom_clicked"),m()},children:[t.jsx(we,{size:12}),h("virtualMcp.connectionDialogContent.customConnection")]})]}),e[27]=I,e[28]=D,e[29]=m,e[30]=_,e[31]=h,e[32]=ue):ue=e[32];const Ge=v&&"opacity-50 pointer-events-none";let me;e[33]!==Ge?(me=H("flex-1 overflow-auto p-5 transition-opacity duration-150",Ge),e[33]=Ge,e[34]=me):me=e[34];const qt="grid grid-cols-[repeat(auto-fill,minmax(260px,1fr))] gap-4";let Me;e[35]!==Oe?(Me=w=>{if(w.type==="group")return Oe(w.key,w.title,w.icon,null,w.connections);const M=w.connection;return Oe(M.id,M.title,M.icon,M.description??null,[M])},e[35]=Oe,e[36]=Me):Me=e[36];const Xe=q.map(Me);let fe;e[37]!==Ue?(fe=t.jsx("div",{ref:Ue,className:"col-span-full h-1"}),e[37]=Ue,e[38]=fe):fe=e[38];let ge;e[39]!==E?(ge=E&&t.jsx("div",{className:"col-span-full flex justify-center py-6",children:t.jsx(Ie,{size:24,className:"animate-spin text-muted-foreground"})}),e[39]=E,e[40]=ge):ge=e[40];const Qe=G&&_e.length>0&&t.jsxs("div",{className:"col-span-full flex items-center gap-2 mt-2",children:[t.jsx(tt,{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"})]}),We=G&&_e.map(lt),Ye=G&&Se.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"})]}),Ze=G&&Se.map(lt);let he;e[41]!==He||e[42]!==$||e[43]!==G?(he=G&&$.length>0&&t.jsx("div",{ref:He,className:"col-span-full h-1"}),e[41]=He,e[42]=$,e[43]=G,e[44]=he):he=e[44];let pe;e[45]!==ie.isLoadingMore||e[46]!==G?(pe=G&&ie.isLoadingMore&&t.jsx("div",{className:"col-span-full flex justify-center py-6",children:t.jsx(Ie,{size:24,className:"animate-spin text-muted-foreground"})}),e[45]=ie.isLoadingMore,e[46]=G,e[47]=pe):pe=e[47];let xe;e[48]!==Xe||e[49]!==fe||e[50]!==ge||e[51]!==Qe||e[52]!==We||e[53]!==Ye||e[54]!==Ze||e[55]!==he||e[56]!==pe?(xe=t.jsxs("div",{className:qt,children:[Xe,fe,ge,Qe,We,Ye,Ze,he,pe]}),e[48]=Xe,e[49]=fe,e[50]=ge,e[51]=Qe,e[52]=We,e[53]=Ye,e[54]=Ze,e[55]=he,e[56]=pe,e[57]=xe):xe=e[57];let je;e[58]!==I||e[59]!==q.length||e[60]!==Se||e[61]!==u||e[62]!==h||e[63]!==_e?(je=q.length===0&&_e.length===0&&Se.length===0&&t.jsx("div",{className:"flex items-center justify-center h-48 text-sm text-muted-foreground",children:u?h("virtualMcp.connectionDialogContent.emptyStateSearchNoMatch",{search:u}):h(I==="connected"?"virtualMcp.connectionDialogContent.emptyStateNoConnectionsYet":"virtualMcp.connectionDialogContent.emptyStateNoConnectionsAvailable")}),e[58]=I,e[59]=q.length,e[60]=Se,e[61]=u,e[62]=h,e[63]=_e,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 $e;return e[69]!==ue||e[70]!==ve?($e=t.jsxs(t.Fragment,{children:[ue,ve]}),e[69]=ue,e[70]=ve,e[71]=$e):$e=e[71],$e}function Us(n){return!n.verified&&!Ke(n._meta)?.verified&&!n.meta?.verified}function qs(n){return n.verified||Ke(n._meta)?.verified||n.meta?.verified}function Gs(n){return n.app_name}function Xs(n){return n.app_name}function Qs(n){return n?.items??[]}function Ws(n,e){if(n?.hasMore)return e.reduce(Ys,0)}function Ys(n,e){return n+(e?.items?.length??0)}function Zs(n){return[{field:["title"],operator:"contains",value:n},{field:["description"],operator:"contains",value:n}]}function ei({open:n,onOpenChange:e,defaultTab:s,initialSearch:o="",...a}){const i=F(),l=a.mode??"add",c="agentId"in a?a.agentId:void 0,r="addedConnectionIds"in a?a.addedConnectionIds??new Set:new Set,u="onAdd"in a&&a.onAdd?a.onAdd:N=>{},m=(N,y,T)=>{c&&B("agent_connection_attached",{agent_id:c,connection_id:N,app_name:y,mode:T})},[f,d]=R.useState(null),[g,b]=R.useState(o),[h,p]=R.useState(!1),{org:j}=oe(),{data:v}=re.useSession(),C=Kt(),_=an(),S=ot(),I=N=>{e(!1),S({to:"/$org/settings/connections/$appSlug",params:{org:j.slug,appSlug:N}})},L=()=>{_.invalidateQueries({predicate:N=>{const y=N.queryKey;return y[1]===j.id&&y[3]==="collection"&&y[4]==="CONNECTIONS"}})},x=async(N,y)=>{B("connection_oauth_succeeded",{connection_id:N,flow:y});const T=new URL(`/api/${j.slug}/mcp/${N}`,window.location.origin);await _.invalidateQueries({queryKey:Ae.isMCPAuthenticated(T.href,null)}),L()},D=async N=>{d(N.app_name??N.id);try{const T=`${N.title.replace(/\s*\(\d+\)\s*$/,"")} (${Date.now().toString(36).slice(-4)})`,A=(await C.create.mutateAsync({title:T,description:N.description??null,connection_type:N.connection_type,connection_url:N.connection_url??null,connection_token:null,icon:N.icon??null,app_name:N.app_name??null,app_id:N.app_id??null,connection_headers:N.connection_headers??null})).id,z=await nt({connectionId:A,orgId:j.id,orgSlug:j.slug,persistFallback:V=>C.update.mutateAsync({id:A,data:{connection_token:V}}).then(()=>{})});if(z.ran&&!z.ok){B("connection_oauth_failed",{connection_id:A,flow:"clone",error:z.error??"no_token"}),K.error(i("virtualMcp.addConnectionDialog.authenticationFailedError",{error:z.error??"no token received"})),await C.delete.mutateAsync(A);return}z.ran&&await x(A,"clone"),m(A,N.app_name??null,"clone"),u(A)}catch(y){console.error("Failed to add connection:",y),K.error(i("virtualMcp.addConnectionDialog.failedToAddConnection"))}finally{d(null)}},P=async N=>{if(!(!j||!v?.user?.id)){d(N.id);try{const y=Rn(N,j.id,v.user.id,{remoteIndex:0}),T=y.connection_type==="STDIO",k=!!y.connection_url,A=T&&y.connection_headers&&typeof y.connection_headers=="object"&&"command"in y.connection_headers;if(!k&&!A){K.error(i("virtualMcp.addConnectionDialog.mcpServerConnectionError")),d(null);return}const{id:z}=await C.create.mutateAsync(y),V=await nt({connectionId:z,orgId:j.id,orgSlug:j.slug,persistFallback:X=>C.update.mutateAsync({id:z,data:{connection_token:X}}).then(()=>{})});if(V.ran&&!V.ok){B("connection_oauth_failed",{connection_id:z,flow:"connect_new",error:V.error??"no_token"}),K.warning(i("virtualMcp.addConnectionDialog.signInFailedTitle"),{description:i("virtualMcp.addConnectionDialog.signInFailedDescription",{error:V.error??"no token received"})}),m(z,y.app_name??null,"new"),u(z);return}V.ran?(await x(z,"connect_new"),K.success(i("virtualMcp.addConnectionDialog.connectedAuthenticated"))):K.success(i("virtualMcp.addConnectionDialog.connected")),m(z,y.app_name??null,"new"),u(z)}catch(y){console.error("Failed to connect:",y),K.error(i("virtualMcp.addConnectionDialog.failedToConnect"))}finally{d(null)}}};return t.jsxs(Et,{open:n,onOpenChange:e,children:[t.jsxs(Bt,{className:"sm:max-w-5xl h-[85vh] max-h-[85vh] flex flex-col p-0 gap-0 overflow-hidden w-[95vw]",children:[t.jsx(Rt,{className:"px-6 pt-5 pb-0 shrink-0",children:t.jsx(Vt,{className:"text-base font-semibold",children:i(l==="browse"?"virtualMcp.addConnectionDialog.connectionsTitle":"virtualMcp.addConnectionDialog.addConnectionTitle")})}),t.jsx("div",{className:"pt-3 shrink-0",children:t.jsx(Fn,{value:g,onChange:b,placeholder:i("virtualMcp.addConnectionDialog.searchConnectionsPlaceholder")})}),t.jsx(R.Suspense,{fallback:t.jsx("div",{className:"flex-1 flex items-center justify-center",children:t.jsx(Ie,{size:24,className:"animate-spin text-muted-foreground"})}),children:t.jsx(Hs,{mode:l,agentId:c,addedConnectionIds:r,onAdd:u,onCloneAndAdd:D,onConnectAndAdd:P,connectingItemId:f,search:g,onCreateConnection:()=>p(!0),onBrowseNavigate:I,defaultTab:s})})]}),t.jsx(Ks,{open:h,onOpenChange:p,onCreated:async N=>{p(!1);const y=await nt({connectionId:N,orgId:j.id,orgSlug:j.slug,persistFallback:T=>C.update.mutateAsync({id:N,data:{connection_token:T}}).then(()=>{})});if(y.ran&&!y.ok){B("connection_oauth_failed",{connection_id:N,flow:"custom_create",error:y.error??"no_token"}),K.warning(i("virtualMcp.addConnectionDialog.signInFailedTitle"),{description:i("virtualMcp.addConnectionDialog.signInFailedDescription",{error:y.error??"no token received"})}),m(N,null,"custom"),u(N),e(!1);return}y.ran&&await x(N,"custom_create"),m(N,null,"custom"),u(N),e(!1)}})]})}const ft=new Map;function ti(){const{org:n}=oe(),e=ln(),s=is(),o=s.find(p=>p.providerId==="deco"),{data:a,isLoading:i,refetch:l,isFetching:c}=ke({queryKey:Ae.aiProviderCredits(n.id,"deco"),enabled:!!o,staleTime:6e4,queryFn:async()=>{try{return await e.call("AI_PROVIDER_CREDITS",{providerId:"deco"})}catch{return null}}}),r=a?.balanceCents??null,u=r!=null?r/100:null,m=R.useRef(new Map);if(r!=null){const p=ft.get(n.id);m.current.get(n.id)&&p!=null&&r>p&&B("credits_topped_up_detected",{organization_id:n.id,delta_cents:r-p,previous_balance_cents:p,new_balance_cents:r}),ft.set(n.id,r),m.current.set(n.id,!0)}const f=!!o,d=r!=null&&r>0,g=r!=null&&r===0,b=r!=null&&r===200,h=s.length>0&&s.every(p=>p.providerId==="deco");return{hasDecoKey:f,decoKeyId:o?.id??null,balanceCents:r,balanceDollars:u,hasCredits:d,isZeroBalance:g,isInitialFreeCredit:b,hasOnlyDecoProvider:h,isLoading:i,isFetching:c,refetch:l}}const Js=4,eo="TASK";function to(n){return n.replace(/[^a-zA-Z]/g,"").toUpperCase().slice(0,Js)||eo}function ni(n,e,s){const o=s?.trim();return o||(e==null?null:`${to(n)}-${String(e).padStart(2,"0")}`)}const no=/^(?:[a-z]{1,8}-)?0*(\d+)$/i;function si(n){const e=no.exec(n.trim())?.[1];return e===void 0?null:Number(e)}function oi(n){const e=O.c(8),{size:s,className:o}=n,a=s===void 0?16:s;let i;e[0]!==a?(i={width:a,height:a},e[0]=a,e[1]=i):i=e[1];let l;e[2]!==o?(l=H("shrink-0 rounded-full object-cover",o),e[2]=o,e[3]=l):l=e[3];let c;return e[4]!==a||e[5]!==i||e[6]!==l?(c=t.jsx("img",{src:fn,alt:"Super Agent",width:a,height:a,style:i,className:l}),e[4]=a,e[5]=i,e[6]=l,e[7]=c):c=e[7],c}export{Zo as A,Qo as C,Jo as N,Yo as O,oi as S,Wo as a,ei as b,Xo as c,xs as d,it as e,Go as f,as as g,Bs as h,si as p,ni as t,ti as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{c as te,j as s,dy as ye,b as ue,r as ce,B as ee,n as je,t as ae,Y as be}from"./index-BVrvrbq0.js";import{s as ge}from"./Plus-D8sAtN4u.js";import{c as Re,d as ve,b as Se,f as De,g as Ne,e as _e,a as Ce,A as Pe}from"./alert-dialog-DY-KNl6H.js";import{d as Ae,h as ke,c as we,e as Oe,b as ze,D as Ee}from"./dialog-DNGy-1NN.js";import{I as Ie}from"./input-BrIYd6rX.js";import{G as xe,a as $e}from"./github-repo-picker-Cw-9KtDM.js";import{u as Fe,b as Te,c as Ge}from"./use-org-repo-syncs-ge0m_cRw.js";import{t as He}from"./cards-SKD62d5P.js";import{R as Be}from"./require-capability-CsF5i3rq.js";import"./collection-search-Be0YtMRt.js";import"./SearchMd-BaB_Q14X.js";import"./use-debounced-value-oRaU09z6.js";import"./use-connection-aJLLgoye.js";import"./use-mcp-client-5ujPvma8.js";import"./constants-dLUUoWH7.js";import"./auth-4ENUk0th.js";import"./authenticate-and-persist-oauth-8TKE_-8N.js";import"./mcp-oauth-CuqNzP3Q.js";import"./ArrowLeft-da6Q-UyL.js";import"./LinkExternal01-C0UQ1ExC.js";import"./LockUnlocked01-Ci0otu-M.js";import"./use-mcp-tools-DWCt19eK.js";import"./extract-connection-data-B7VY0pzb.js";import"./metadata-dUsYcpuu.js";import"./use-navigate-to-agent-BGjuoQ2e.js";import"./use-destination-route-DQ-Be9BI.js";import"./use-virtual-mcp-BdUU54wm.js";import"./hooks-Bws7gD0u.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./decopilot-sse-pool-CYrcMfCK.js";import"./task-board-CDfxS8qo.js";import"./schema-CzxlgXcl.js";import"./session-runtime-C-KTDVeQ.js";import"./slugify-CEUa2lfQ.js";import"./provision-repo-scoped-github-connection-CMPWtdMv.js";import"./folder-icon-uMXxo7Cy.js";import"./Eye-S3in9ejU.js";import"./DotsVertical-ClsiP4Ty.js";import"./Download01-zimKnpts.js";import"./Share07-D1gdA92o.js";import"./Globe01-ChRqAF_1.js";import"./Key01-CraG_uBV.js";import"./Palette-CzJHZUOm.js";import"./Trash01-ClFAZqXM.js";import"./Zap-BWej80kj.js";import"./dropdown-menu-5m2qr892.js";import"./Check-Cnsro5cT.js";import"./ChevronRight-Brk-D2sZ.js";import"./file-type-icon-BDW-g-n3.js";import"./access-gate-Bbfkxifm.js";import"./capability-load-error-Jq9gmxBc.js";function qe(e){return e.toLowerCase().replace(/[^a-z0-9_.-]+/g,"-").replace(/^[.-]+|[.-]+$/g,"").slice(0,128)}function Le(e,t){return e.lastSyncError?{label:e.lastSyncError,error:!0}:e.lastSyncedAt?{label:t("library.syncedRepos.syncedAgo",{ago:He(e.lastSyncedAt)}),error:!1}:{label:t("library.syncedRepos.waitingFirstSync"),error:!1}}function Ve(e){const t=te.c(32),{config:l,onRemove:i}=e,c=ue();let u;t[0]!==l||t[1]!==c?(u=Le(l,c),t[0]=l,t[1]=c,t[2]=u):u=t[2];const p=u;let o;t[3]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx("div",{className:"size-9 rounded-md bg-muted flex items-center justify-center shrink-0",children:s.jsx(xe,{size:16,className:"text-muted-foreground"})}),t[3]=o):o=t[3];let a;t[4]!==l.repoName||t[5]!==l.repoOwner?(a=s.jsxs("span",{className:"font-medium text-sm truncate",children:[l.repoOwner,"/",l.repoName]}),t[4]=l.repoName,t[5]=l.repoOwner,t[6]=a):a=t[6];let n;t[7]!==l.ref?(n=s.jsxs("span",{className:"text-xs text-muted-foreground shrink-0",children:["@",l.ref]}),t[7]=l.ref,t[8]=n):n=t[8];let g;t[9]!==a||t[10]!==n?(g=s.jsxs("div",{className:"flex items-center gap-2",children:[a,n]}),t[9]=a,t[10]=n,t[11]=g):g=t[11];const m=p.error?"text-destructive":"text-muted-foreground";let d;t[12]!==m?(d=je("text-xs mt-0.5 truncate",m),t[12]=m,t[13]=d):d=t[13];let f;t[14]!==l.volume||t[15]!==c?(f=c("settings.syncedRepos.rowSubtitle",{volume:l.volume}),t[14]=l.volume,t[15]=c,t[16]=f):f=t[16];let y;t[17]!==p.label||t[18]!==d||t[19]!==f?(y=s.jsxs("p",{className:d,children:[f," ·"," ",p.label]}),t[17]=p.label,t[18]=d,t[19]=f,t[20]=y):y=t[20];let x;t[21]!==g||t[22]!==y?(x=s.jsxs("div",{className:"flex items-start gap-3 min-w-0",children:[o,s.jsxs("div",{className:"min-w-0",children:[g,y]})]}),t[21]=g,t[22]=y,t[23]=x):x=t[23];let j;t[24]!==c?(j=c("settings.syncedRepos.remove"),t[24]=c,t[25]=j):j=t[25];let h;t[26]!==i||t[27]!==j?(h=s.jsx(ee,{variant:"outline",size:"sm",onClick:i,children:j}),t[26]=i,t[27]=j,t[28]=h):h=t[28];let b;return t[29]!==x||t[30]!==h?(b=s.jsxs("div",{className:"flex items-center justify-between gap-4 py-3 border-b border-border/60 last:border-b-0",children:[x,h]}),t[29]=x,t[30]=h,t[31]=b):b=t[31],b}function Ye(e){const t=te.c(21),{onAdd:l}=e,i=ue();let c;t[0]===Symbol.for("react.memo_cache_sentinel")?(c=s.jsx("div",{className:"size-12 rounded-full bg-muted flex items-center justify-center",children:s.jsx(xe,{size:20,className:"text-muted-foreground"})}),t[0]=c):c=t[0];let u;t[1]!==i?(u=i("settings.syncedRepos.emptyTitle"),t[1]=i,t[2]=u):u=t[2];let p;t[3]!==u?(p=s.jsx("p",{className:"font-medium text-sm",children:u}),t[3]=u,t[4]=p):p=t[4];let o;t[5]!==i?(o=i("settings.syncedRepos.emptyDescription"),t[5]=i,t[6]=o):o=t[6];let a;t[7]!==o?(a=s.jsx("p",{className:"text-xs text-muted-foreground mt-1 max-w-sm",children:o}),t[7]=o,t[8]=a):a=t[8];let n;t[9]!==p||t[10]!==a?(n=s.jsxs("div",{children:[p,a]}),t[9]=p,t[10]=a,t[11]=n):n=t[11];let g;t[12]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx(ge,{size:14}),t[12]=g):g=t[12];let m;t[13]!==i?(m=i("settings.syncedRepos.addRepo"),t[13]=i,t[14]=m):m=t[14];let d;t[15]!==l||t[16]!==m?(d=s.jsxs(ee,{onClick:l,size:"sm",className:"mt-2",children:[g,m]}),t[15]=l,t[16]=m,t[17]=d):d=t[17];let f;return t[18]!==n||t[19]!==d?(f=s.jsxs("div",{className:"rounded-2xl border border-dashed border-border/60 p-10 flex flex-col items-center justify-center text-center gap-3",children:[c,n,d]}),t[18]=n,t[19]=d,t[20]=f):f=t[20],f}function Je(){const e=te.c(107),t=ue(),l=Fe(),i=Te(),c=Ge(),[u,p]=ce.useState(!1),[o,a]=ce.useState(null),[n,g]=ce.useState(""),[m,d]=ce.useState(null);let f;e[0]!==i||e[1]!==o||e[2]!==t||e[3]!==n?(f=function(){!o||!n.trim()||i.mutate({connectionId:o.connectionId,volume:n.trim()},{onSuccess:R=>{a(null),ae.success(t("settings.syncedRepos.created",{volume:R.volume}))},onError:R=>{ae.error(R instanceof Error?R.message:t("settings.syncedRepos.failed"))}})},e[0]=i,e[1]=o,e[2]=t,e[3]=n,e[4]=f):f=e[4];const y=f;let x;e[5]!==m||e[6]!==c||e[7]!==t?(x=function(){m&&c.mutate(m.id,{onSuccess:()=>ae.success(t("settings.syncedRepos.removed")),onError:R=>ae.error(R instanceof Error?R.message:t("settings.syncedRepos.failed")),onSettled:()=>d(null)})},e[5]=m,e[6]=c,e[7]=t,e[8]=x):x=e[8];const j=x;if(l.isPending){let r;return e[9]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx(be,{className:"h-32 w-full"}),e[9]=r):r=e[9],r}let h;e[10]!==l.data?(h=l.data??[],e[10]=l.data,e[11]=h):h=e[11];const b=h;let v;e[12]!==t?(v=t("settings.syncedRepos.pageDescription"),e[12]=t,e[13]=v):v=e[13];let S;e[14]!==v?(S=s.jsx("p",{className:"text-sm text-muted-foreground",children:v}),e[14]=v,e[15]=S):S=e[15];let D;e[16]!==b||e[17]!==t?(D=b.length===0?s.jsx(Ye,{onAdd:()=>p(!0)}):s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"flex items-center justify-end",children:s.jsxs(ee,{onClick:()=>p(!0),size:"sm",children:[s.jsx(ge,{size:14}),t("settings.syncedRepos.addRepo")]})}),s.jsx("section",{className:"rounded-2xl border border-border/60 bg-background px-5 py-2",children:b.map(r=>s.jsx(Ve,{config:r,onRemove:()=>d(r)},r.id))})]}),e[16]=b,e[17]=t,e[18]=D):D=e[18];let N;e[19]!==t?(N=t("settings.syncedRepos.pickerTitle"),e[19]=t,e[20]=N):N=e[20];let se;e[21]===Symbol.for("react.memo_cache_sentinel")?(se=r=>{p(!1),a(r),g(qe(r.repo.name))},e[21]=se):se=e[21];let _;e[22]!==u||e[23]!==N?(_=s.jsx($e,{mode:"connection",open:u,onOpenChange:p,title:N,onImportComplete:se}),e[22]=u,e[23]=N,e[24]=_):_=e[24];const me=o!==null;let ie;e[25]===Symbol.for("react.memo_cache_sentinel")?(ie=r=>{r||a(null)},e[25]=ie):ie=e[25];let C;e[26]!==t?(C=t("settings.syncedRepos.nameDialogTitle"),e[26]=t,e[27]=C):C=e[27];let P;e[28]!==C?(P=s.jsx(Ae,{children:C}),e[28]=C,e[29]=P):P=e[29];const de=o?`${o.repo.owner}/${o.repo.name}`:"";let A;e[30]!==t||e[31]!==de?(A=t("settings.syncedRepos.nameDialogDescription",{repo:de}),e[30]=t,e[31]=de,e[32]=A):A=e[32];let k;e[33]!==A?(k=s.jsx(ke,{children:A}),e[33]=A,e[34]=k):k=e[34];let w;e[35]!==P||e[36]!==k?(w=s.jsxs(we,{children:[P,k]}),e[35]=P,e[36]=k,e[37]=w):w=e[37];let le;e[38]===Symbol.for("react.memo_cache_sentinel")?(le=r=>g(r.target.value),e[38]=le):le=e[38];let O;e[39]!==t?(O=t("settings.syncedRepos.namePlaceholder"),e[39]=t,e[40]=O):O=e[40];let z;e[41]!==O||e[42]!==n?(z=s.jsx(Ie,{value:n,onChange:le,placeholder:O,autoFocus:!0}),e[41]=O,e[42]=n,e[43]=z):z=e[43];let ne;e[44]===Symbol.for("react.memo_cache_sentinel")?(ne=()=>a(null),e[44]=ne):ne=e[44];const he=i.isPending;let E;e[45]!==t?(E=t("settings.syncedRepos.cancel"),e[45]=t,e[46]=E):E=e[46];let I;e[47]!==i.isPending||e[48]!==E?(I=s.jsx(ee,{variant:"outline",onClick:ne,disabled:he,children:E}),e[47]=i.isPending,e[48]=E,e[49]=I):I=e[49];let $;e[50]!==i.isPending||e[51]!==n?($=!n.trim()||i.isPending,e[50]=i.isPending,e[51]=n,e[52]=$):$=e[52];let F;e[53]!==i.isPending||e[54]!==t?(F=i.isPending?t("settings.syncedRepos.creating"):t("settings.syncedRepos.create"),e[53]=i.isPending,e[54]=t,e[55]=F):F=e[55];let T;e[56]!==y||e[57]!==$||e[58]!==F?(T=s.jsx(ee,{disabled:$,onClick:y,children:F}),e[56]=y,e[57]=$,e[58]=F,e[59]=T):T=e[59];let G;e[60]!==I||e[61]!==T?(G=s.jsxs(Oe,{children:[I,T]}),e[60]=I,e[61]=T,e[62]=G):G=e[62];let H;e[63]!==w||e[64]!==z||e[65]!==G?(H=s.jsxs(ze,{className:"sm:max-w-sm",children:[w,z,G]}),e[63]=w,e[64]=z,e[65]=G,e[66]=H):H=e[66];let B;e[67]!==H||e[68]!==me?(B=s.jsx(Ee,{open:me,onOpenChange:ie,children:H}),e[67]=H,e[68]=me,e[69]=B):B=e[69];const pe=m!==null;let oe;e[70]===Symbol.for("react.memo_cache_sentinel")?(oe=r=>{r||d(null)},e[70]=oe):oe=e[70];const fe=m?.volume??"";let q;e[71]!==t||e[72]!==fe?(q=t("settings.syncedRepos.removeTitle",{volume:fe}),e[71]=t,e[72]=fe,e[73]=q):q=e[73];let L;e[74]!==q?(L=s.jsx(Re,{children:q}),e[74]=q,e[75]=L):L=e[75];let V;e[76]!==t?(V=t("settings.syncedRepos.removeDescription"),e[76]=t,e[77]=V):V=e[77];let Y;e[78]!==V?(Y=s.jsx(ve,{children:V}),e[78]=V,e[79]=Y):Y=e[79];let J;e[80]!==L||e[81]!==Y?(J=s.jsxs(Se,{children:[L,Y]}),e[80]=L,e[81]=Y,e[82]=J):J=e[82];let K;e[83]!==t?(K=t("settings.syncedRepos.cancel"),e[83]=t,e[84]=K):K=e[84];let M;e[85]!==K?(M=s.jsx(De,{children:K}),e[85]=K,e[86]=M):M=e[86];let Q;e[87]!==t?(Q=t("settings.syncedRepos.remove"),e[87]=t,e[88]=Q):Q=e[88];let U;e[89]!==j||e[90]!==Q?(U=s.jsx(Ne,{onClick:j,children:Q}),e[89]=j,e[90]=Q,e[91]=U):U=e[91];let W;e[92]!==M||e[93]!==U?(W=s.jsxs(_e,{children:[M,U]}),e[92]=M,e[93]=U,e[94]=W):W=e[94];let X;e[95]!==J||e[96]!==W?(X=s.jsxs(Ce,{children:[J,W]}),e[95]=J,e[96]=W,e[97]=X):X=e[97];let Z;e[98]!==pe||e[99]!==X?(Z=s.jsx(Pe,{open:pe,onOpenChange:oe,children:X}),e[98]=pe,e[99]=X,e[100]=Z):Z=e[100];let re;return e[101]!==B||e[102]!==S||e[103]!==Z||e[104]!==D||e[105]!==_?(re=s.jsxs(s.Fragment,{children:[S,D,_,B,Z]}),e[101]=B,e[102]=S,e[103]=Z,e[104]=D,e[105]=_,e[106]=re):re=e[106],re}function Ke(){const e=te.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx(ye,{group:"storage",children:s.jsx(Je,{})}),e[0]=t):t=e[0],t}function Jt(){const e=te.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx(Be,{capability:"file-configs:manage",area:"files",children:s.jsx(Ke,{})}),e[0]=t):t=e[0],t}export{Jt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D as R}from"./use-destination-route-DQ-Be9BI.js";import{I as O,r as c,c as v,j as A,d as x,H as C,a as E,dD as T}from"./index-BVrvrbq0.js";import{u as _}from"./use-virtual-mcp-BdUU54wm.js";import{u as N}from"./hooks-Bws7gD0u.js";import{p as w,d as P}from"./session-runtime-C-KTDVeQ.js";const f=new Map;function y(r){return`${r.orgId}:${r.userId}`}function U(r){return`sidebar.group-order.${r}`}function h(r){try{const e=localStorage.getItem(r),t=e?JSON.parse(e):[];return Array.isArray(t)?t.filter(n=>typeof n=="string"):[]}catch{return[]}}function G(r,e){try{localStorage.setItem(r,JSON.stringify(e))}catch{}}function j(r){const e=y(r),t=f.get(e);if(t)return t;const n=O.sidebarGroupOrder(r.orgId,r.userId);let s=!1;try{s=localStorage.getItem(n)!==null}catch{}let o=h(n);if(!s&&o.length===0&&r.userId!=="anon"){const d=h(U(r.orgId));d.length>0&&(o=d)}return f.set(e,o),o}function D(r,e){const t=new Set(e);return j(r).filter(n=>!t.has(n))}function K(r,e){f.set(y(r),e),G(O.sidebarGroupOrder(r.orgId,r.userId),e)}function $(r,e,t=[]){if(t.includes(e))return;const n=D(r,t);n.includes(e)||K(r,[e,...n])}const m=c.createContext(null);function X(r){const e=v.c(7),{children:t}=r,[n,s]=c.useState(!1),[o,d]=c.useState(0);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=()=>d(L),e[0]=i):i=e[0];const l=i;let a;e[1]!==n||e[2]!==o?(a={empty:n,setEmpty:s,orderRevision:o,bumpOrderRevision:l},e[1]=n,e[2]=o,e[3]=a):a=e[3];let u;return e[4]!==t||e[5]!==a?(u=A.jsx(m.Provider,{value:a,children:t}),e[4]=t,e[5]=a,e[6]=u):u=e[6],u}function L(r){return r+1}function Z(){return c.useContext(m)?.empty??!1}function k(){return c.useContext(m)?.bumpOrderRevision??H}function H(){}function J(r,e,t,n){return r.find(s=>!s.hidden&&s.virtual_mcp_id===e&&s.created_by===t&&s.title==="New chat"&&!s.harness_id&&B(s,n))}function B(r,e){if(!e)return!0;if(r.partial)return!1;const t=w(r.metadata?.runtime);return t===null||t===e}const S=[],F=()=>()=>{};function V(r){return(r??[]).filter(e=>!!e.pinned).map(e=>e.id)}function M(){const r=x(),{org:e}=C(),t=_(),{data:n}=E.useSession(),s=n?.user?.id??"anon",o=V(t),d=k(),i=N(),l=c.useSyncExternalStore(i?.threads.subscribe??F,i?.threads.get??(()=>S),i?.threads.get??(()=>S));return(a,u)=>{$({orgId:e.id,userId:s},a,o),d();const g=(t??[]).find(I=>I.id===a),b=J(l,a,n?.user?.id,g?P(g.metadata):void 0)?.id??crypto.randomUUID(),p=u?.panel?T(u.panel):null;r({to:R.agents,params:{org:e.slug,project:a,panel:p?.panel},search:{...p?.payload??{},thread:b}})}}export{X as S,k as a,$ as b,M as c,J as f,V as g,Z as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{I as u}from"./use-infinite-scroll-BrB7Lt9H.js";import{fg as i}from"./index-BVrvrbq0.js";function t(e,r){return i(e,u,r)}export{t as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{I as s}from"./use-infinite-scroll-BrB7Lt9H.js";import{fg as u,b$ as n}from"./index-BVrvrbq0.js";function a(r,e){return u({...r,enabled:!0,suspense:!0,throwOnError:n},s,e)}export{a as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{c as K,b as X,r as Z,j as n,n as rt,a8 as ut,ab as ht,B as tt,a9 as xt}from"./index-BVrvrbq0.js";import{r as gt,U as at,aC as bt}from"./agent-icon-Cg1MVuqt.js";import{i as vt}from"./ChevronRight-Brk-D2sZ.js";import{L as yt}from"./label-DsbZOjXe.js";import{S as lt}from"./scroll-area-CYvS2rbr.js";import{S as jt}from"./switch-CkIgMDq_.js";import{V as Tt}from"./view-mode-toggle-DkcqYmXk.js";import{bu as ct,bv as mt,bw as Nt,bx as _t,by as kt,bz as U,bA as wt}from"./index-C75JHNjQ.js";import"./AlertCircle-BjdquHf-.js";import"./UserSquare-y_18laAE.js";import"./Tool01-CNzVBj_W.js";import"./ArrowUp-DA_CbLFn.js";import"./ArrowLeft-da6Q-UyL.js";import"./Tool02-Dpn9yDp0.js";import"./XCircle-B4UOTih1.js";import"./TrendUp01-DhMg0ifd.js";import"./ZapSquare-BXqrP_tc.js";import"./ZoomOut-CxIB2Yte.js";import"./Users03-DzeNH_9p.js";import"./CheckCircle-D2QIjzKK.js";import"./Check-Cnsro5cT.js";import"./ChevronDown-B-Abg1e0.js";import"./ChevronSelectorVertical-B62qDywG.js";import"./ChevronUp-DV8kBI8Y.js";import"./DotsVertical-ClsiP4Ty.js";import"./Stars02-0AGhIbsh.js";import"./Copy01-CWUFCWPy.js";import"./CreditCard01-CHEBrxoD.js";import"./Download01-zimKnpts.js";import"./Settings02-CUszvuT2.js";import"./Eye-S3in9ejU.js";import"./FilterLines-Chfs1mfk.js";import"./Share07-D1gdA92o.js";import"./GitBranch01-WegQ50s8.js";import"./Globe01-ChRqAF_1.js";import"./Globe04-BSSpPEkT.js";import"./SwitchHorizontal01-BSuHHv8C.js";import"./HardDrive-B8Cy2PQx.js";import"./Image01-DFw0y6lF.js";import"./Key01-CraG_uBV.js";import"./LinkExternal01-C0UQ1ExC.js";import"./LockUnlocked01-Ci0otu-M.js";import"./LogOut01-Nj6MhWEg.js";import"./Monitor01-CeeOI5sb.js";import"./Sun-DUlOfQe9.js";import"./Package-DaOVHCwU.js";import"./Palette-CzJHZUOm.js";import"./Play-CwdZq2EZ.js";import"./Plus-D8sAtN4u.js";import"./SearchLg-C9b34PXG.js";import"./SearchMd-BaB_Q14X.js";import"./Shield01-G7QoiCov.js";import"./Stars01-C3jSf9hQ.js";import"./Trash01-ClFAZqXM.js";import"./Upload01-DNvn3Jpk.js";import"./User01-OPq_dP0r.js";import"./Users01-DbbW5Be2.js";import"./XClose-CANrkFbB.js";import"./Zap-BWej80kj.js";import"./select-DWZHVE7Z.js";import"./chat-context-D4UYOsqd.js";import"./use-panel-navigate-BNhFZdkJ.js";import"./use-destination-route-DQ-Be9BI.js";import"./thread-route-CYkAuakU.js";import"./dialog-DNGy-1NN.js";import"./constants-dLUUoWH7.js";import"./session-runtime-C-KTDVeQ.js";import"./slugify-CEUa2lfQ.js";import"./hooks-Bws7gD0u.js";import"./use-mcp-client-5ujPvma8.js";import"./auth-4ENUk0th.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./decopilot-sse-pool-CYrcMfCK.js";import"./task-board-CDfxS8qo.js";import"./schema-CzxlgXcl.js";import"./use-is-desktop-app-BNujXJc_.js";import"./use-virtual-mcp-BdUU54wm.js";import"./use-ai-providers-Pn7kyqm7.js";import"./location-oTTXFrSF.js";import"./use-decopilot-events-DyGhXOIt.js";import"./use-organization-settings-R_ptPhVG.js";import"./automation-runs-ZqzOzZQ9.js";import"./useInfiniteQuery-CTUYsDi7.js";import"./use-infinite-scroll-BrB7Lt9H.js";import"./use-connection-aJLLgoye.js";import"./table-l7d0L4HA.js";import"./empty-state-C_35zZjp.js";import"./use-members-MYtJ0ZQo.js";import"./use-org-auth-client-C0hhHvh6.js";import"./use-automations-DvucsFJj.js";import"./useSuspenseInfiniteQuery-DE6FuMxx.js";import"./avatar-BMtJ5YwV.js";import"./format-time-BnbuEtat.js";import"./differenceInSeconds-NQ4PDo0z.js";import"./use-copy-fzne1gRK.js";import"./markdown-BYfQbGnL.js";import"./monaco-editor-CWSEDaK_.js";import"./spinner-DV6GUIjA.js";import"./editor-CqDBLwA4.js";import"./types-8phPNsJi.js";import"./shell-layout-BQ1ldV9H.js";import"./required-auth-layout-C6_OVZML.js";import"./use-org-sso-Cu9b3co_.js";import"./integration-icon-DxfcS7Xs.js";import"./use-navigate-to-agent-BGjuoQ2e.js";import"./chart-B7o-grMK.js";import"./index-CLQho_ND.js";import"./AreaChart-DISWAeCj.js";import"./form-C99hTZji.js";import"./input-BrIYd6rX.js";import"./file-type-icon-BDW-g-n3.js";import"./drawer-Dy3_lJI_.js";import"./collection-search-Be0YtMRt.js";import"./agent-capabilities-B52k7xCe.js";import"./use-mcp-tools-DWCt19eK.js";import"./tabs-ddeF4LXG.js";import"./toggle-group-C9fEgPcg.js";import"./super-agent-icon-B4UCN6Nm.js";import"./self-tool-result-DmSUT1RY.js";import"./alert-dialog-DY-KNl6H.js";import"./extract-connection-data-B7VY0pzb.js";import"./metadata-dUsYcpuu.js";import"./provision-repo-scoped-github-connection-CMPWtdMv.js";import"./use-debounced-value-oRaU09z6.js";import"./authenticate-and-persist-oauth-8TKE_-8N.js";import"./mcp-oauth-CuqNzP3Q.js";import"./track-B2ASSGQ7.js";import"./popover-DcAxlsrD.js";import"./toolbar-Di3Hs5Jo.js";import"./github-repo-picker-Cw-9KtDM.js";import"./connection-card-B46OuNED.js";import"./use-registry-connections-DRWn31Xx.js";import"./retry-CErkP7V6.js";import"./connection-slug-CITJ0kGN.js";import"./textarea-D0l1wrxS.js";import"./connection-form-helpers-RFHcTUdU.js";import"./collection-tabs-4dFJYq71.js";import"./badge-B0pYz4_b.js";import"./select-model-CDSL0Ptb.js";import"./checkbox-CjC7D1uk.js";import"./ai-providers-logos-DD3qZ33J.js";import"./folder-icon-uMXxo7Cy.js";import"./dropdown-menu-5m2qr892.js";import"./question-004-sINsf4GQ.js";import"./use-status-sounds-zKo5Escv.js";import"./skill-preview-D9LhMKji.js";import"./use-file-configs-CR_5RVUF.js";import"./site-slug-uya6Wp4-.js";import"./pt-BR-CLy76QW2.js";import"./use-debounced-autosave-DbilpG-x.js";import"./search-input-PZ2Wi6Dz.js";import"./use-mcp-auth-status-CBeyelo6.js";import"./use-secrets-C1YpR5Po.js";import"./config-5kP3riQw.js";import"./command-DWrtW5Dd.js";import"./index-CNFW7QBf.js";import"./get-initials-D-f_fDFw.js";import"./breadcrumb-DG1Z7Nud.js";import"./use-tags-CgzcYzNS.js";import"./automation-list-row-CfAr-sYB.js";import"./site-error--i37Vnuw.js";import"./use-org-repo-syncs-ge0m_cRw.js";import"./cards-SKD62d5P.js";const Et=new Set(["website/matchers/date.ts","$live/matchers/MatchDate.ts"]),St=new Set(["website/matchers/multi.ts","$live/matchers/MatchMulti.ts"]),Ct=new Date(-864e13),Mt=new Date(864e13),At=/\/flags\/multivariate(?:\/[^/]+)?\.ts$/,$t=/\/flags\/multivariate\.ts$/;function Lt(e){let t=e;t.startsWith("pages-")&&(t=t.slice(6).replace(/-\d+$/,""));try{t=decodeURIComponent(t)}catch{}return t}function Rt(e){if(!e||typeof e!="object")return null;const{start:t,end:r}=e,o=typeof t=="string",s=typeof r=="string";if(!o&&!s)return null;const i=o?new Date(t):Ct,a=s?new Date(r):Mt;return Number.isNaN(i.getTime())||Number.isNaN(a.getTime())||o&&s&&a.getTime()<=i.getTime()?null:{start:i,end:a,openStart:!o,openEnd:!s}}function pt(e,t){if(!e||typeof e!="object")return;const r=e.__resolveType;if(typeof r=="string"){if(Et.has(r)){const o=Rt(e);o&&t.push(o);return}if(St.has(r)){const o=e.matchers;if(Array.isArray(o))for(const s of o)pt(s,t)}}}function Dt(e){if(!e||typeof e!="object")return!1;const t=e.__resolveType;if(typeof t!="string"||!At.test(t))return!1;const r=e.variants;return Array.isArray(r)}function Ot(e){if(typeof e=="string"){const c=e.trim();if(c.length===0)return null;try{const m=new URL(c).pathname.split("/").filter(Boolean),p=m[m.length-1];if(p)return decodeURIComponent(p)}catch{}return c.length>80?`${c.slice(0,77)}…`:c}if(!e||typeof e!="object")return null;const t=e,r=t.config,s=t.desktop?.media,i=[t.title,t.name,t.label,t.alt,r?.title,r?.name,r?.typeAlert?.message,s?.alt,Array.isArray(t.matcher)?t.matcher[0]:void 0];for(const c of i)if(typeof c=="string"&&c.trim().length>0)return c.trim();const a=t.__resolveType;if(typeof a=="string"){const l=(a.split("/").pop()??a).replace(/\.(tsx?|jsx?)$/i,"");if(l.length>0)return l}return null}function Pt(e){const t=[];for(let r=0;r<e.length;r++){const o=e[r];typeof o=="number"?t.length>0?t[t.length-1]+=`[${o}]`:t.push(`[${o}]`):t.push(o)}return t.join(" · ")}function Q(e,t,r,o,s){if(Dt(e)){const i=e.variants,a=e.__resolveType,c=$t.test(a)?"":Pt(o);i.forEach((l,m)=>{if(!l||typeof l!="object")return;const p=l,h=[];if(pt(p.rule,h),h.length===0)return;const g=Ot(p.value)??(c||r);for(const u of h)s.push({blockKey:t,blockLabel:r,innerPath:c,variantIndex:m,start:u.start,end:u.end,openStart:u.openStart,openEnd:u.openEnd,label:g,flagResolveType:a})});for(let l=0;l<i.length;l++){const m=i[l];m&&typeof m=="object"&&Q(m.value,t,r,[...o,"variants",l,"value"],s)}return}if(Array.isArray(e)){for(let i=0;i<e.length;i++)Q(e[i],t,r,[...o,i],s);return}if(e&&typeof e=="object")for(const[i,a]of Object.entries(e))i!=="__resolveType"&&Q(a,t,r,[...o,i],s)}function It(e){if(!e)return[];const t=[];for(const[r,o]of Object.entries(e))Q(o,r,Lt(r),[],t);return t.sort((r,o)=>r.start.getTime()-o.start.getTime())}function Vt(e){const t=[...new Set(e)].sort(),r=new Map;return t.forEach((o,s)=>{const i=s*137.508%360;r.set(o,{bg:`oklch(0.62 0.14 ${i})`,text:"white",border:`oklch(0.50 0.14 ${i})`})}),r}const Ht={bg:"oklch(0.62 0.14 0)",text:"white",border:"oklch(0.50 0.14 0)"};function dt(e,t){return e.get(t)??Ht}const ot=new Intl.DateTimeFormat("en",{dateStyle:"medium",timeStyle:"short"});function Bt(e,t){const r=e.openStart?t("sandbox.variantCalendar.always"):ot.format(e.start),o=e.openEnd?t("sandbox.variantCalendar.ongoing"):ot.format(e.end);return`${r} → ${o}`}function Ft(e){const t=K.c(18),{variant:r}=e,o=X();let s;t[0]!==r.blockLabel?(s=n.jsx("div",{className:"font-semibold",children:r.blockLabel}),t[0]=r.blockLabel,t[1]=s):s=t[1];let i;t[2]!==r.innerPath?(i=r.innerPath&&n.jsx("div",{className:"text-muted-foreground",children:r.innerPath}),t[2]=r.innerPath,t[3]=i):i=t[3];let a;t[4]!==r.blockLabel||t[5]!==r.innerPath||t[6]!==r.label?(a=r.label!==r.blockLabel&&r.label!==r.innerPath&&n.jsx("div",{className:"text-muted-foreground",children:r.label}),t[4]=r.blockLabel,t[5]=r.innerPath,t[6]=r.label,t[7]=a):a=t[7];let c;t[8]!==o||t[9]!==r?(c=Bt(r,o),t[8]=o,t[9]=r,t[10]=c):c=t[10];let l;t[11]!==c?(l=n.jsx("div",{className:"mt-1",children:c}),t[11]=c,t[12]=l):l=t[12];let m;return t[13]!==s||t[14]!==i||t[15]!==a||t[16]!==l?(m=n.jsx(xt,{children:n.jsxs("div",{className:"text-xs",children:[s,i,a,l]})}),t[13]=s,t[14]=i,t[15]=a,t[16]=l,t[17]=m):m=t[17],m}const nt=16;function zt(e,t){const r=e?"transparent":"#000 0",o=t?"transparent":"#000 100%";if(!(!e&&!t))return`linear-gradient(to right, ${r}, #000 ${nt}px, #000 calc(100% - ${nt}px), ${o})`}function ft(e){const t=K.c(26),{variant:r,color:o,style:s,children:i,fadeStart:a,fadeEnd:c}=e,l=a===void 0?!1:a,m=c===void 0?!1:c;let p;t[0]!==m||t[1]!==l?(p=zt(l,m),t[0]=m,t[1]=l,t[2]=p):p=t[2];const h=p;let f;t[3]!==l?(f=l&&{borderTopLeftRadius:0,borderBottomLeftRadius:0},t[3]=l,t[4]=f):f=t[4];let g;t[5]!==m?(g=m&&{borderTopRightRadius:0,borderBottomRightRadius:0},t[5]=m,t[6]=g):g=t[6];let u;t[7]!==h?(u=h&&{maskImage:h,WebkitMaskImage:h},t[7]=h,t[8]=u):u=t[8];let x;t[9]!==o.bg||t[10]!==o.text||t[11]!==s||t[12]!==f||t[13]!==g||t[14]!==u?(x={background:o.bg,color:o.text,borderRadius:4,...f,...g,...u,...s},t[9]=o.bg,t[10]=o.text,t[11]=s,t[12]=f,t[13]=g,t[14]=u,t[15]=x):x=t[15];let b;t[16]!==i?(b=n.jsx("span",{className:"truncate",children:i}),t[16]=i,t[17]=b):b=t[17];let E;t[18]!==x||t[19]!==b?(E=n.jsx(ut,{asChild:!0,children:n.jsx("div",{className:"absolute flex items-center px-2 text-[11px] font-medium truncate cursor-default",style:x,children:b})}),t[18]=x,t[19]=b,t[20]=E):E=t[20];let T;t[21]!==r?(T=n.jsx(Ft,{variant:r}),t[21]=r,t[22]=T):T=t[22];let d;return t[23]!==T||t[24]!==E?(d=n.jsxs(ht,{children:[E,T]}),t[23]=T,t[24]=E,t[25]=d):d=t[25],d}function ln(e){const t=K.c(72),{decofile:r}=e,o=X(),[s,i]=Z.useState("calendar"),[a,c]=Z.useState(Kt),[l,m]=Z.useState(!1);let p,h,f;if(t[0]!==r||t[1]!==l){const I=It(r);p=I.filter(Ut).length,f=l?I:I.filter(Gt),h=Vt(f.map(Wt)),t[0]=r,t[1]=l,t[2]=p,t[3]=h,t[4]=f}else p=t[2],h=t[3],f=t[4];const g=h;let u;t[5]===Symbol.for("react.memo_cache_sentinel")?(u=()=>c(mt(new Date)),t[5]=u):u=t[5];const x=u;let b;t[6]!==s?(b=()=>c(I=>s==="calendar"?U(I,-1):U(I,-3)),t[6]=s,t[7]=b):b=t[7];const E=b;let T;t[8]!==s?(T=()=>c(I=>s==="calendar"?U(I,1):U(I,3)),t[8]=s,t[9]=T):T=t[9];const d=T;let v;t[10]!==o?(v=o("sandbox.variantCalendar.today"),t[10]=o,t[11]=v):v=t[11];let y;t[12]!==v?(y=n.jsx(tt,{variant:"outline",size:"sm",onClick:x,children:v}),t[12]=v,t[13]=y):y=t[13];let N;t[14]!==o?(N=o("sandbox.variantCalendar.previous"),t[14]=o,t[15]=N):N=t[15];let A;t[16]===Symbol.for("react.memo_cache_sentinel")?(A=n.jsx(gt,{size:16}),t[16]=A):A=t[16];let _;t[17]!==E||t[18]!==N?(_=n.jsx(tt,{variant:"ghost",size:"icon",className:"size-8",onClick:E,"aria-label":N,children:A}),t[17]=E,t[18]=N,t[19]=_):_=t[19];let k;t[20]!==o?(k=o("sandbox.variantCalendar.next"),t[20]=o,t[21]=k):k=t[21];let C;t[22]===Symbol.for("react.memo_cache_sentinel")?(C=n.jsx(vt,{size:16}),t[22]=C):C=t[22];let $;t[23]!==d||t[24]!==k?($=n.jsx(tt,{variant:"ghost",size:"icon",className:"size-8",onClick:d,"aria-label":k,children:C}),t[23]=d,t[24]=k,t[25]=$):$=t[25];const L=ct[a.getMonth()];let M;t[26]!==a?(M=a.getFullYear(),t[26]=a,t[27]=M):M=t[27];let w;t[28]!==L||t[29]!==M?(w=n.jsxs("h2",{className:"ml-2 text-base font-semibold",children:[L," ",M]}),t[28]=L,t[29]=M,t[30]=w):w=t[30];let j;t[31]!==$||t[32]!==w||t[33]!==y||t[34]!==_?(j=n.jsxs("div",{className:"flex items-center gap-2",children:[y,_,$,w]}),t[31]=$,t[32]=w,t[33]=y,t[34]=_,t[35]=j):j=t[35];let R;t[36]!==p||t[37]!==l||t[38]!==o?(R=p>0&&n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx(jt,{id:"show-ongoing",checked:l,onCheckedChange:m}),n.jsx(yt,{htmlFor:"show-ongoing",className:"text-xs text-muted-foreground cursor-pointer",children:o("sandbox.variantCalendar.showOngoing",{count:p})})]}),t[36]=p,t[37]=l,t[38]=o,t[39]=R):R=t[39];let B;t[40]===Symbol.for("react.memo_cache_sentinel")?(B=n.jsx(at,{}),t[40]=B):B=t[40];let V;t[41]!==o?(V=o("sandbox.variantCalendar.calendarMode"),t[41]=o,t[42]=V):V=t[42];let S;t[43]!==V?(S={value:"calendar",icon:B,label:V},t[43]=V,t[44]=S):S=t[44];let F;t[45]===Symbol.for("react.memo_cache_sentinel")?(F=n.jsx(bt,{}),t[45]=F):F=t[45];let D;t[46]!==o?(D=o("sandbox.variantCalendar.timelineMode"),t[46]=o,t[47]=D):D=t[47];let O;t[48]!==D?(O={value:"timeline",icon:F,label:D},t[48]=D,t[49]=O):O=t[49];let P;t[50]!==S||t[51]!==O?(P=[S,O],t[50]=S,t[51]=O,t[52]=P):P=t[52];let H;t[53]!==P||t[54]!==s?(H=n.jsx(Tt,{value:s,onValueChange:i,options:P}),t[53]=P,t[54]=s,t[55]=H):H=t[55];let z;t[56]!==R||t[57]!==H?(z=n.jsxs("div",{className:"flex items-center gap-4",children:[R,H]}),t[56]=R,t[57]=H,t[58]=z):z=t[58];let W;t[59]!==j||t[60]!==z?(W=n.jsxs("div",{className:"flex items-center justify-between px-4 h-12 border-b shrink-0",children:[j,z]}),t[59]=j,t[60]=z,t[61]=W):W=t[61];let G;t[62]!==g||t[63]!==a||t[64]!==p||t[65]!==l||t[66]!==f||t[67]!==s?(G=f.length===0?n.jsx(Yt,{hiddenOngoing:l?0:p}):s==="calendar"?n.jsx(Jt,{monthStart:a,variants:f,colorMap:g}):n.jsx(te,{monthStart:a,variants:f,colorMap:g}),t[62]=g,t[63]=a,t[64]=p,t[65]=l,t[66]=f,t[67]=s,t[68]=G):G=t[68];let q;return t[69]!==W||t[70]!==G?(q=n.jsxs("div",{className:"flex h-full w-full flex-col",children:[W,G]}),t[69]=W,t[70]=G,t[71]=q):q=t[71],q}function Wt(e){return e.blockKey}function Gt(e){return!e.openEnd}function Ut(e){return e.openEnd}function Kt(){return mt(new Date)}function Yt(e){const t=K.c(4),{hiddenOngoing:r}=e,o=r===void 0?0:r,s=X();let i;t[0]===Symbol.for("react.memo_cache_sentinel")?(i=n.jsx(at,{size:24,className:"text-muted-foreground/60"}),t[0]=i):i=t[0];let a;return t[1]!==o||t[2]!==s?(a=n.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center gap-2 text-center text-sm text-muted-foreground p-6",children:[i,o>0?n.jsxs(n.Fragment,{children:[n.jsx("div",{children:s("sandbox.variantCalendar.noDatedVariants")}),n.jsx("div",{className:"text-xs text-muted-foreground/80",children:s("sandbox.variantCalendar.hiddenOngoingVariants",{count:o})})]}):n.jsxs(n.Fragment,{children:[n.jsx("div",{children:s("sandbox.variantCalendar.noScheduledVariants")}),n.jsx("div",{className:"text-xs text-muted-foreground/80",children:s("sandbox.variantCalendar.dateMatcherInfo")})]})]}),t[1]=o,t[2]=s,t[3]=a):a=t[3],a}const et=20,it=2,st=28,qt=6;function Jt(e){const t=K.c(17),{monthStart:r,variants:o,colorMap:s}=e;let i,a,c,l,m;if(t[0]!==s||t[1]!==r||t[2]!==o){const f=Nt(r),g=_t(new Date);i=lt,m="flex-1 min-h-0",a="min-w-[840px]",t[8]===Symbol.for("react.memo_cache_sentinel")?(c=n.jsx("div",{className:"grid grid-cols-7 border-b text-xs text-muted-foreground sticky top-0 bg-background z-10",children:wt.map(Xt)}),t[8]=c):c=t[8],l=f.map((u,x)=>{const b=kt(u,o),E=b.reduce(Qt,0),T=st+E*(et+it)+8;return n.jsxs("div",{className:"grid grid-cols-7 relative border-b",style:{height:T},children:[u.map((d,v)=>{const y=d.getMonth()===r.getMonth(),N=d.getTime()===g.getTime();return n.jsx("div",{className:rt("border-r last:border-r-0 px-2 pt-1.5 text-xs",y?"bg-background":"bg-muted/30 text-muted-foreground"),children:n.jsx("span",{className:rt("inline-flex h-5 min-w-5 items-center justify-center rounded-full px-1",N&&"bg-primary text-primary-foreground font-semibold"),children:d.getDate()})},v)}),b.map((d,v)=>{const y=dt(s,d.variant.blockKey),N=st+d.lane*(et+it),A=d.leftUnits/7*100,_=d.widthUnits/7*100,k=d.variant.openStart&&x===0,C=d.variant.openEnd&&x===f.length-1;return n.jsxs(ft,{variant:d.variant,color:y,fadeStart:k,fadeEnd:C,style:{top:N,left:`calc(${A}% + 2px)`,width:`calc(${_}% - 4px)`,minWidth:qt,height:et},children:[d.variant.blockLabel,d.variant.label!==d.variant.blockLabel&&n.jsxs("span",{className:"opacity-70",children:[" · ",d.variant.label]})]},`${x}-${v}`)})]},x)}),t[0]=s,t[1]=r,t[2]=o,t[3]=i,t[4]=a,t[5]=c,t[6]=l,t[7]=m}else i=t[3],a=t[4],c=t[5],l=t[6],m=t[7];let p;t[9]!==a||t[10]!==c||t[11]!==l?(p=n.jsxs("div",{className:a,children:[c,l]}),t[9]=a,t[10]=c,t[11]=l,t[12]=p):p=t[12];let h;return t[13]!==i||t[14]!==m||t[15]!==p?(h=n.jsx(i,{className:m,children:p}),t[13]=i,t[14]=m,t[15]=p,t[16]=h):h=t[16],h}function Qt(e,t){return Math.max(e,t.lane+1)}function Xt(e){return n.jsx("div",{className:"px-2 py-2 text-center uppercase tracking-wide",children:e},e)}const J=4,Zt=32,Y=240;function te(e){const t=K.c(23),{monthStart:r,variants:o,colorMap:s}=e,i=r,a=U(r,J),c=new Date,l=new Map;for(const w of o){const j=l.get(w.blockKey)??[];j.push(w),l.set(w.blockKey,j)}const m=Array.from(l.entries()).sort(oe),p=a.getTime()-i.getTime(),h=w=>(Math.max(i.getTime(),Math.min(a.getTime(),w.getTime()))-i.getTime())/p*100;let f;t[0]!==i?(f=(w,j)=>U(i,j),t[0]=i,t[1]=f):f=t[1];const g=Array.from({length:J},f),u=c.getTime()>=i.getTime()&&c.getTime()<=a.getTime()?h(c):null,x=X(),b=lt,E="flex-1 min-h-0",T="min-w-[900px] relative";let d;t[2]===Symbol.for("react.memo_cache_sentinel")?(d={width:Y},t[2]=d):d=t[2];let v;t[3]!==x?(v=x("sandbox.variantCalendar.variantBlock"),t[3]=x,t[4]=v):v=t[4];let y;t[5]!==v?(y=n.jsx("div",{className:"shrink-0 px-3 py-2 text-xs font-semibold uppercase tracking-wide text-muted-foreground border-r",style:d,children:v}),t[5]=v,t[6]=y):y=t[6];let N;t[7]===Symbol.for("react.memo_cache_sentinel")?(N={gridTemplateColumns:`repeat(${J}, minmax(0, 1fr))`},t[7]=N):N=t[7];const A=g.map(re);let _;t[8]!==A?(_=n.jsx("div",{className:"flex-1 grid",style:N,children:A}),t[8]=A,t[9]=_):_=t[9];let k;t[10]!==y||t[11]!==_?(k=n.jsxs("div",{className:"flex border-b sticky top-0 bg-background z-10",children:[y,_]}),t[10]=y,t[11]=_,t[12]=k):k=t[12];let C;t[13]!==x||t[14]!==u?(C=u!==null&&n.jsx("div",{className:"pointer-events-none absolute top-0 bottom-0 w-px bg-primary/70 z-[5]",style:{left:`calc(${Y}px + (100% - ${Y}px) * ${u} / 100)`},children:n.jsx("span",{className:"absolute -top-0.5 -translate-x-1/2 rounded-sm bg-primary px-1.5 py-px text-[10px] font-medium text-primary-foreground",children:x("sandbox.variantCalendar.todayLabel")})}),t[13]=x,t[14]=u,t[15]=C):C=t[15];const $=m.map(w=>{const[j,R]=w,B=dt(s,j),V=R[0]?.blockLabel??j;return n.jsxs("div",{children:[n.jsx("div",{className:"flex items-center bg-muted/40 border-b text-xs font-semibold uppercase tracking-wide text-muted-foreground",style:{height:28},children:n.jsx("div",{className:"px-3 truncate",style:{width:Y},children:V})}),R.map((S,F)=>n.jsxs("div",{className:"flex border-b items-center",style:{height:Zt},children:[n.jsxs("div",{className:"flex items-center gap-2 px-3 text-sm border-r shrink-0",style:{width:Y},children:[n.jsx("span",{className:"inline-block h-2 w-2 rounded-full shrink-0",style:{background:B.bg}}),n.jsx("span",{className:"truncate text-foreground/80",children:S.label})]}),n.jsxs("div",{className:"relative flex-1 h-full",children:[n.jsx("div",{className:"absolute inset-0 grid",style:{gridTemplateColumns:`repeat(${J}, minmax(0, 1fr))`},children:g.map(ee)}),(()=>{const D=Math.max(S.start.getTime(),i.getTime()),O=Math.min(S.end.getTime(),a.getTime());if(O<=D)return null;const P=h(new Date(D)),H=h(new Date(O))-P;return n.jsx(ft,{variant:S,color:B,fadeStart:S.openStart,fadeEnd:S.openEnd,style:{top:"50%",transform:"translateY(-50%)",left:`${P}%`,width:`calc(${H}% - 2px)`,height:22},children:S.label})})()]})]},F))]},j)});let L;t[16]!==k||t[17]!==C||t[18]!==$?(L=n.jsxs("div",{className:T,children:[k,C,$]}),t[16]=k,t[17]=C,t[18]=$,t[19]=L):L=t[19];let M;return t[20]!==b||t[21]!==L?(M=n.jsx(b,{className:E,children:L}),t[20]=b,t[21]=L,t[22]=M):M=t[22],M}function ee(e,t){return n.jsx("div",{className:"border-r last:border-r-0 border-border/40"},t)}function re(e,t){return n.jsxs("div",{className:"px-2 py-2 text-xs uppercase tracking-wide text-muted-foreground border-r last:border-r-0",children:[ct[e.getMonth()]?.slice(0,3)," ",e.getFullYear()]},t)}function oe(e,t){return e[0].localeCompare(t[0])}export{ln as VariantCalendar};
|