decocms 4.449.0 → 4.450.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/assets/{AlertCircle-Bx6Xy-Kw.js → AlertCircle-CfHvNlgZ.js} +1 -1
- package/dist/client/assets/{AreaChart-DQ7VB4Rk.js → AreaChart-DgRgPjRl.js} +1 -1
- package/dist/client/assets/{ArrowLeft-BBlLaPEb.js → ArrowLeft-Bj2Vh3jF.js} +1 -1
- package/dist/client/assets/{ArrowUp-Dr4dZUTV.js → ArrowUp-BDwJ6lSJ.js} +1 -1
- package/dist/client/assets/{Building02-qqUg_lk7.js → Building02-Bqa8ze-O.js} +1 -1
- package/dist/client/assets/{CartesianChart-2IJlIK54.js → CartesianChart-C-1Ljn_q.js} +1 -1
- package/dist/client/assets/{Check-BhHmW1CL.js → Check-COzQ04E7.js} +1 -1
- package/dist/client/assets/{CheckCircle-DQ_Iwx7G.js → CheckCircle-Vb-xyxhE.js} +1 -1
- package/dist/client/assets/{ChevronUp-C6nGgzcV.js → ChevronUp-RdnkaZaK.js} +1 -1
- package/dist/client/assets/{Copy01-1J_cPh43.js → Copy01-DJrDIAgF.js} +1 -1
- package/dist/client/assets/{CreditCard01-CZJLSW5h.js → CreditCard01-N4OPgVDg.js} +1 -1
- package/dist/client/assets/{DotsVertical-DMzCTdNT.js → DotsVertical-D5rr2YQm.js} +1 -1
- package/dist/client/assets/{ErrorBarContext-BsMO1nqd.js → ErrorBarContext-BzHJmc6J.js} +1 -1
- package/dist/client/assets/{Image01-VqGHD62D.js → Image01-Ccx9C_Rg.js} +1 -1
- package/dist/client/assets/{Key01-3kquwPFB.js → Key01-B1Y8yy7Z.js} +1 -1
- package/dist/client/assets/{Line-C3wcRFDr.js → Line-CDHGyXU2.js} +1 -1
- package/dist/client/assets/{Link01-ZJZ8YMCs.js → Link01-Bh_PC3dO.js} +1 -1
- package/dist/client/assets/{LinkBroken01-DLTNdGdq.js → LinkBroken01-xKKRxXlY.js} +1 -1
- package/dist/client/assets/{LinkExternal01-ByTglQMD.js → LinkExternal01-mH0kFM32.js} +1 -1
- package/dist/client/assets/{Monitor01-CjCwBipo.js → Monitor01-PBPlMgWr.js} +1 -1
- package/dist/client/assets/{Palette-DItfN1RT.js → Palette-KCM9-De7.js} +1 -1
- package/dist/client/assets/{Plus-jU4D0ULX.js → Plus-HBSdQYLn.js} +1 -1
- package/dist/client/assets/{SearchMd-yUpDH67q.js → SearchMd-BBjcQIvr.js} +1 -1
- package/dist/client/assets/{Sector-DADH10bp.js → Sector-BGpLXB4C.js} +1 -1
- package/dist/client/assets/{ShoppingBag01-BnqPHk8-.js → ShoppingBag01-CdLvneJ1.js} +1 -1
- package/dist/client/assets/{Sun-G5YUTpKk.js → Sun-BpeW1MoX.js} +1 -1
- package/dist/client/assets/{Tool01-DQZj0rVc.js → Tool01-Dz-lp6mO.js} +1 -1
- package/dist/client/assets/{Trash01-CfWaytgc.js → Trash01-C7BGYPNB.js} +1 -1
- package/dist/client/assets/{Upload01-ca0GgR0P.js → Upload01-Crj-EmOO.js} +1 -1
- package/dist/client/assets/{User01-BJgSr0na.js → User01-COdLotsN.js} +1 -1
- package/dist/client/assets/{UserSquare-DubBIV3t.js → UserSquare-BZc1G4LK.js} +1 -1
- package/dist/client/assets/{Users01-BI4qzwEi.js → Users01-6Yj_4D_n.js} +1 -1
- package/dist/client/assets/{X-4SjHAUB6.js → X-BpUF7FNJ.js} +1 -1
- package/dist/client/assets/{XAxis-6QdhlFSd.js → XAxis-DHX42RQV.js} +1 -1
- package/dist/client/assets/{XClose-B5gtMDn3.js → XClose-CYHY5GcG.js} +1 -1
- package/dist/client/assets/{ZoomOut-o5Bj_0k0.js → ZoomOut-BvLQLuGR.js} +1 -1
- package/dist/client/assets/{access-gate-CVOkVcAR.js → access-gate-m2qtNNPd.js} +1 -1
- package/dist/client/assets/{add-connection-dialog-C9teNzj3.js → add-connection-dialog-BKu4JrTL.js} +1 -1
- package/dist/client/assets/{agent-analytics-pnZ5kkw4.js → agent-analytics-vEDyxY7n.js} +1 -1
- package/dist/client/assets/agent-app-DnEVoEjI.js +1 -0
- package/dist/client/assets/{agent-assets-CkTPoTPt.js → agent-assets-DPX4xJR-.js} +1 -1
- package/dist/client/assets/{agent-automation-IkGTi12K.js → agent-automation-q5wiAOx3.js} +1 -1
- package/dist/client/assets/{agent-automations-CeOlf6kC.js → agent-automations-CLGqAcAP.js} +1 -1
- package/dist/client/assets/{agent-connect-sources-CE8WWO21.js → agent-connect-sources-D9DCAQIR.js} +1 -1
- package/dist/client/assets/agent-deck-BczWleOc.js +1 -0
- package/dist/client/assets/{agent-e2e-CqzK8bNw.js → agent-e2e-DGk0x04T.js} +1 -1
- package/dist/client/assets/{agent-experiments-y5AB7gNs.js → agent-experiments-D65zJ4jN.js} +1 -1
- package/dist/client/assets/{agent-file-CaQOAUU8.js → agent-file-B9SJnbYJ.js} +1 -1
- package/dist/client/assets/{agent-git-B3hEpRLE.js → agent-git-CJxYwcoX.js} +1 -1
- package/dist/client/assets/{agent-hosting-k179Ejew.js → agent-hosting-UMq8FCPI.js} +1 -1
- package/dist/client/assets/{agent-icon-Plx0vVQZ.js → agent-icon-Cs5o_QD_.js} +1 -1
- package/dist/client/assets/agent-library-D54-cgPN.js +1 -0
- package/dist/client/assets/agent-library-file-DeLY3SxR.js +1 -0
- package/dist/client/assets/{agent-monitor-_UheQa-B.js → agent-monitor-Dy_K0ub4.js} +1 -1
- package/dist/client/assets/{agent-overview-bLRGU593.js → agent-overview-DgMmZowY.js} +1 -1
- package/dist/client/assets/agent-settings-BrnBZqdX.js +1 -0
- package/dist/client/assets/{agent-site-editor-DVenLdmy.js → agent-site-editor-C76UAYYm.js} +1 -1
- package/dist/client/assets/agent-site-editor-code-ClZXgoqS.js +2 -0
- package/dist/client/assets/{agent-site-editor-content-GMuyS7LS.js → agent-site-editor-content-CPY5DcAt.js} +3 -3
- package/dist/client/assets/{agent-site-editor-preview-fQwmql9B.js → agent-site-editor-preview-uCP-Axlu.js} +3 -3
- package/dist/client/assets/agent-view-CB7GVVHY.js +1 -0
- package/dist/client/assets/{agent-view-guard-BwrmGLlw.js → agent-view-guard-Dz25zh4B.js} +1 -1
- package/dist/client/assets/{agents-list-C3sXvejj.js → agents-list-C7koOCD-.js} +1 -1
- package/dist/client/assets/{ai-providers-CedLyqka.js → ai-providers-mt2APKAD.js} +1 -1
- package/dist/client/assets/{alert-FpVcsSTC.js → alert-DTtquKm0.js} +1 -1
- package/dist/client/assets/{alert-dialog-CRVM-23V.js → alert-dialog-BZP1AD0I.js} +1 -1
- package/dist/client/assets/{analytics-sections-rbnTnuvD.js → analytics-sections-BCXDounI.js} +1 -1
- package/dist/client/assets/api-keys-B0lfuxgV.js +1 -0
- package/dist/client/assets/{api-keys-COeksGyn.js → api-keys-gXBnRr4Q.js} +1 -1
- package/dist/client/assets/app-editor-BeOyqqqi.js +1 -0
- package/dist/client/assets/{asset-utils-BZ8WEgo_.js → asset-utils-BciMW5G_.js} +1 -1
- package/dist/client/assets/{auth-BhL4Ae7M.js → auth-C1mOz7Cp.js} +1 -1
- package/dist/client/assets/{auth-catchall-CwYBELfP.js → auth-catchall-D1QDLQSo.js} +1 -1
- package/dist/client/assets/{auth-entry-AWWhawM-.js → auth-entry-CD9pgR2t.js} +1 -1
- package/dist/client/assets/{auth-split-layout-DKZlsvJh.js → auth-split-layout-DTpd8fsO.js} +1 -1
- package/dist/client/assets/{authenticate-and-persist-oauth-CM_sd9mo.js → authenticate-and-persist-oauth-jKlCQsjO.js} +1 -1
- package/dist/client/assets/{automation-list-row-BaZJos7Z.js → automation-list-row-CbqCS8l-.js} +1 -1
- package/dist/client/assets/{automation-runs-D8nbfNRi.js → automation-runs-Dl3yx598.js} +1 -1
- package/dist/client/assets/{automations-CSz4StRo.js → automations-BZBJG0Qn.js} +1 -1
- package/dist/client/assets/{autosend-CtvAncuN.js → autosend-BiJfUQUT.js} +1 -1
- package/dist/client/assets/{avatar-ZtrZA-xC.js → avatar-BIv_2mLm.js} +1 -1
- package/dist/client/assets/{badge-B0eiYJhc.js → badge-lEq6LpEb.js} +1 -1
- package/dist/client/assets/{block-document-BceCRczU.js → block-document-9tqq3gtP.js} +1 -1
- package/dist/client/assets/{blocks-preview-workspace-context-CHwgOgkC.js → blocks-preview-workspace-context-DANrcxW4.js} +1 -1
- package/dist/client/assets/{blog-schema-CswZLK88.js → blog-schema-CyOQeZHl.js} +1 -1
- package/dist/client/assets/{buckets-Gs1fVclo.js → buckets-BqkRKuz-.js} +1 -1
- package/dist/client/assets/{build-improve-prompt-doc-Cb05TlMk.js → build-improve-prompt-doc-CbZ5gHs3.js} +1 -1
- package/dist/client/assets/{calendar-Cwshzk8E.js → calendar-DV2ELhqc.js} +1 -1
- package/dist/client/assets/{capability-load-error-CV82KOmw.js → capability-load-error-khp8kp3N.js} +1 -1
- package/dist/client/assets/{category-editor-BVh5TSwx.js → category-editor-BXpyvMT8.js} +1 -1
- package/dist/client/assets/{chart-DQHWQ1kS.js → chart-DZlYelqd.js} +1 -1
- package/dist/client/assets/{chat-context-CW-2SJ9g.js → chat-context-CuWiXF8M.js} +1 -1
- package/dist/client/assets/{chat-draft-CwKaZkWY.js → chat-draft-MjQajd4b.js} +1 -1
- package/dist/client/assets/{checkbox-Cs5VXlL7.js → checkbox-69BFI5HM.js} +1 -1
- package/dist/client/assets/{choose-editor-DYyB77HH.js → choose-editor-DOkI-i_1.js} +1 -1
- package/dist/client/assets/claim-phase-copy-DW6T-00N.js +1 -0
- package/dist/client/assets/{cli-auth-success-QlGAkecU.js → cli-auth-success-Oels3F-J.js} +1 -1
- package/dist/client/assets/{client-icons-B_Vdp-aH.js → client-icons-BhwVxJqX.js} +1 -1
- package/dist/client/assets/{collapsible-taXF9Vin.js → collapsible-BMQj5Dup.js} +1 -1
- package/dist/client/assets/{collection-detail-Dj6LHA84.js → collection-detail--UMVDw_e.js} +1 -1
- package/dist/client/assets/{collection-display-button-oMAXeg11.js → collection-display-button-A4mEJyub.js} +1 -1
- package/dist/client/assets/{collection-search-De8chpSh.js → collection-search-DUZsfox8.js} +1 -1
- package/dist/client/assets/{collection-table-wrapper-yQxCbZDl.js → collection-table-wrapper-CJyPG0PT.js} +1 -1
- package/dist/client/assets/{collection-tabs-2Nn5b0UJ.js → collection-tabs-BYPXCgXS.js} +1 -1
- package/dist/client/assets/{column-rules-NVsxdRkm.js → column-rules-Cmy6j5D_.js} +1 -1
- package/dist/client/assets/{combobox-uWP-A1cr.js → combobox-BfrybbG7.js} +1 -1
- package/dist/client/assets/{command-Dj5wxXJe.js → command-BzdiaYU5.js} +1 -1
- package/dist/client/assets/{companion-mcps-section-DGa0mzqM.js → companion-mcps-section-BaryY-2L.js} +1 -1
- package/dist/client/assets/{config-CNoTk6kM.js → config-U1gvv_50.js} +1 -1
- package/dist/client/assets/{connect-CnaN_058.js → connect-CheBVLEk.js} +1 -1
- package/dist/client/assets/{connect-layout-1nOF0djv.js → connect-layout-CGfoXglM.js} +1 -1
- package/dist/client/assets/{connection-DCZz5J1M.js → connection-Byk90CG2.js} +1 -1
- package/dist/client/assets/{connection-card-DaZTNpcS.js → connection-card-CdUGcyiA.js} +1 -1
- package/dist/client/assets/{connection-detail-BZEZF1y2.js → connection-detail-DVhGbJ_P.js} +1 -1
- package/dist/client/assets/{connection-form-helpers-Dyc97_iQ.js → connection-form-helpers-CIUjUhAv.js} +1 -1
- package/dist/client/assets/{connections-DwyQu0E5.js → connections-D7nPZ_WD.js} +1 -1
- package/dist/client/assets/{context-Hy9lD2FY.js → context-CrR6BY7f.js} +1 -1
- package/dist/client/assets/{context-menu-D4sB9rRV.js → context-menu-n5XAPSQR.js} +1 -1
- package/dist/client/assets/{create-organization-dialog-BPk6MpO6.js → create-organization-dialog-Bt3iiYSK.js} +1 -1
- package/dist/client/assets/{daily-pulse-jC7QtChD.js → daily-pulse-DRfCbhaG.js} +1 -1
- package/dist/client/assets/{decopilot-CcCmg-UE.js → decopilot-Djx80CTZ.js} +1 -1
- package/dist/client/assets/{device-hint-DFIHePB4.js → device-hint-DIcIjg5e.js} +1 -1
- package/dist/client/assets/{dialog-DUkVOZIE.js → dialog-BK1Ueu93.js} +1 -1
- package/dist/client/assets/{discover-PHqRmlAb.js → discover-CjiCng93.js} +1 -1
- package/dist/client/assets/{domain-settings-DC07Bwzh.js → domain-settings-BqejR8AT.js} +1 -1
- package/dist/client/assets/{download-app-dialog-VBK5SfsW.js → download-app-dialog-wOlBcsxc.js} +1 -1
- package/dist/client/assets/{drawer-BE8-rjnv.js → drawer-u-W4g_nO.js} +1 -1
- package/dist/client/assets/{editor-Bicb4Bqw.js → editor-DOIu8213.js} +1 -1
- package/dist/client/assets/{empty-state-CGgBiEoz.js → empty-state-B5HnsrMX.js} +1 -1
- package/dist/client/assets/{empty-state-Lw6BWO66.js → empty-state-CwuzKy1b.js} +1 -1
- package/dist/client/assets/{extract-connection-data-BqvnWkg5.js → extract-connection-data-lBq634kY.js} +1 -1
- package/dist/client/assets/{feature-gate-BIe5gsHR.js → feature-gate-C451yaSo.js} +1 -1
- package/dist/client/assets/{feature-paywall-DGxl3PI8.js → feature-paywall-Ly3_RQ_p.js} +1 -1
- package/dist/client/assets/{file-explorer-DuE7CaLg.js → file-explorer-BGyklvkh.js} +1 -1
- package/dist/client/assets/{file-preview-DwqtznxG.js → file-preview-B2Gly7zq.js} +1 -1
- package/dist/client/assets/{file-share-button-CGad6pvg.js → file-share-button-CUSzS93g.js} +1 -1
- package/dist/client/assets/{file-type-icon-CideAigq.js → file-type-icon-Ib_JQuvQ.js} +1 -1
- package/dist/client/assets/flat-project-ehtY7lK6.js +1 -0
- package/dist/client/assets/{folder-icon-C5v3kOW1.js → folder-icon-tWiqYLYb.js} +1 -1
- package/dist/client/assets/{form-esFIz8cn.js → form-nYJgRjCD.js} +1 -1
- package/dist/client/assets/{gateway-client-DdEB-W_0.js → gateway-client-BpCG924q.js} +1 -1
- package/dist/client/assets/{general-C9QQwa7q.js → general-CEwHM3rV.js} +1 -1
- package/dist/client/assets/{home-DHdEzmGE.js → home-CmbO8MKm.js} +1 -1
- package/dist/client/assets/{icon-button-BpPbhU8u.js → icon-button-D4H5x94G.js} +1 -1
- package/dist/client/assets/{index-pCZVwBrG.js → index-BAnyMtCQ.js} +1 -1
- package/dist/client/assets/{index-CFflVJHI.js → index-BEAvsXWJ.js} +1 -1
- package/dist/client/assets/{index-CfCqm3c8.js → index-BWmIYoGl.js} +1 -1
- package/dist/client/assets/{index-BP-g_hO2.js → index-C2J0aGyP.js} +1 -1
- package/dist/client/assets/{index-De_dnJRN.js → index-CGgVIw_7.js} +1 -1
- package/dist/client/assets/{index-BtEM8a9F.js → index-CYQqV4oD.js} +1 -1
- package/dist/client/assets/{index-B1zctMWM.js → index-Creb5Fal.js} +2 -2
- package/dist/client/assets/{index-km7ID5lM.js → index-CzSdBX-p.js} +1 -1
- package/dist/client/assets/{index-DD7q2zTd.js → index-D3Sn56HF.js} +1 -1
- package/dist/client/assets/{index-wBJ7lMpR.js → index-Do0LZXCE.js} +3 -3
- package/dist/client/assets/{index-DCuYoDHT.js → index-DpRTJH-I.js} +1 -1
- package/dist/client/assets/{index-CKkIU_55.js → index-DrzDi7N3.js} +1 -1
- package/dist/client/assets/{index-Cbn4vfz_.js → index-DxddTk14.js} +1 -1
- package/dist/client/assets/{index-_Pfw1M40.js → index-YPpUZW2G.js} +1 -1
- package/dist/client/assets/{index-CazcJ_7a.js → index-hVDNPnIj.js} +1 -1
- package/dist/client/assets/{index-redirect-DJCpFh35.js → index-redirect-BhVNihb9.js} +1 -1
- package/dist/client/assets/{infiniteQueryObserver-BBgKyTli.js → infiniteQueryObserver-D3SNQDlh.js} +1 -1
- package/dist/client/assets/{infra-billing-CT-SKwYV.js → infra-billing-DwoAbG-N.js} +1 -1
- package/dist/client/assets/{input-D1BEXHTl.js → input-B4_sU5tp.js} +1 -1
- package/dist/client/assets/{input-B3HVl7By.js → input-BKlAoViI.js} +1 -1
- package/dist/client/assets/{input-DsxQztmQ.js → input-Bv8cV8cl.js} +3 -3
- package/dist/client/assets/{integration-icon-B97YfXXZ.js → integration-icon-DhFk0v8h.js} +1 -1
- package/dist/client/assets/{label-Be_7Vms5.js → label-ycBnzzff.js} +1 -1
- package/dist/client/assets/{layout-HR14oaFC.js → layout-DmY5YpEN.js} +1 -1
- package/dist/client/assets/{legacy-agents-deep-Cg0ho0FK.js → legacy-agents-deep-CIaqC-AF.js} +1 -1
- package/dist/client/assets/{legacy-main-redirect-B_6vW12N.js → legacy-main-redirect-Bgp7nu2i.js} +1 -1
- package/dist/client/assets/library-CN3vmNYC.js +1 -0
- package/dist/client/assets/{library-tab-tJXLlybm.js → library-tab-CBapuFEX.js} +1 -1
- package/dist/client/assets/{login-DaVQiw7H.js → login-BKGtEguK.js} +1 -1
- package/dist/client/assets/{markdown-BSYuVrvS.js → markdown-C0crjplB.js} +1 -1
- package/dist/client/assets/mcp-app-renderer-weTyRI6G.js +11 -0
- package/dist/client/assets/{mcp-oauth-Dt9pIBq5.js → mcp-oauth-DvzBEl8t.js} +1 -1
- package/dist/client/assets/{members-CHSwnC7s.js → members-D6M8al4X.js} +1 -1
- package/dist/client/assets/{memory-y99QmzFe.js → memory-DUEsb2C1.js} +1 -1
- package/dist/client/assets/{message-templates-xF6Z-DZJ.js → message-templates-80H103Z6.js} +1 -1
- package/dist/client/assets/{mini-report-page-CFRqMuFT.js → mini-report-page-BmNfvJlO.js} +1 -1
- package/dist/client/assets/{mock-board-BD3qTGYo.js → mock-board-CZK2Cvo3.js} +1 -1
- package/dist/client/assets/{monaco-editor-BXK3f-Og.js → monaco-editor-C-S-8OC6.js} +1 -1
- package/dist/client/assets/{monitoring-stats-row-IHl-mX1g.js → monitoring-stats-row-IwAbB8u9.js} +1 -1
- package/dist/client/assets/{multi-select-DGgRKpc4.js → multi-select-y9FwQ-dm.js} +1 -1
- package/dist/client/assets/{mustache-Cgurdydm.js → mustache-Ag809o1A.js} +1 -1
- package/dist/client/assets/{new-project-dialog-BMehfxLv.js → new-project-dialog-DrxiqG-Y.js} +1 -1
- package/dist/client/assets/{oauth-callback-pqa-Hyt-.js → oauth-callback-DWtAAf7G.js} +1 -1
- package/dist/client/assets/{oauth-callback-ai-provider-k4dNzBd0.js → oauth-callback-ai-provider-NQ8LdX-a.js} +1 -1
- package/dist/client/assets/{onboarding-Dp8GO7az.js → onboarding-BRFoKzMG.js} +1 -1
- package/dist/client/assets/{openai-conversation-oneJt9QR.js → openai-conversation-BHudNimx.js} +1 -1
- package/dist/client/assets/{optimistic-project-sidebar-views-DDETX0mx.js → optimistic-project-sidebar-views-DS6iax6c.js} +1 -1
- package/dist/client/assets/{org-file-open-context-2kSVNzGe.js → org-file-open-context-BWYWVr6j.js} +1 -1
- package/dist/client/assets/{organization-choice-Di3lf1DM.js → organization-choice-ColOG4Qs.js} +1 -1
- package/dist/client/assets/{orgs-BXBqBecG.js → orgs-DN46iPbm.js} +1 -1
- package/dist/client/assets/{page-seo-form-B-vBxb4j.js → page-seo-form-bx7wNVcF.js} +1 -1
- package/dist/client/assets/{pair-bDKRTMqu.js → pair-BbS6p0iS.js} +1 -1
- package/dist/client/assets/{plan-ladder-CfA0FpAL.js → plan-ladder-RwyJdG4c.js} +1 -1
- package/dist/client/assets/{popover-DwQza7Ap.js → popover-Dvqj57GQ.js} +1 -1
- package/dist/client/assets/{post-calendar-CM-j2TVF.js → post-calendar-BLOA3EdX.js} +1 -1
- package/dist/client/assets/{post-editor-DzeGxIPl.js → post-editor-0k2icWwR.js} +1 -1
- package/dist/client/assets/{preview-content-b2Kfd0ih.js → preview-content-CT0ZeYI2.js} +1 -1
- package/dist/client/assets/{preview-dialog-7_zN433M.js → preview-dialog-C06uRVP1.js} +1 -1
- package/dist/client/assets/{profile-DH3xvW4M.js → profile-C1YrKzza.js} +1 -1
- package/dist/client/assets/{project-app-view-8XHhP-21.js → project-app-view-CvhGuyEm.js} +1 -1
- package/dist/client/assets/{project-feed-C4R5QRpx.js → project-feed-Lrn2Vx6v.js} +1 -1
- package/dist/client/assets/{project-icon-0knrxIOw.js → project-icon-DYsLOXub.js} +1 -1
- package/dist/client/assets/project-reports-Cxp5cndN.js +1 -0
- package/dist/client/assets/project-tasks-mGerfQed.js +1 -0
- package/dist/client/assets/{projects-ZExDUw0W.js → projects-9bg9EGUj.js} +1 -1
- package/dist/client/assets/{projects-empty-state-BSpE0Riy.js → projects-empty-state-lPWjupMn.js} +1 -1
- package/dist/client/assets/{prompts-BLBkOl8v.js → prompts-Ci7eVBQ_.js} +1 -1
- package/dist/client/assets/record-editor-1_isDy55.js +1 -0
- package/dist/client/assets/{redirect-editor-BVFm9u4z.js → redirect-editor-dVA7hSbo.js} +1 -1
- package/dist/client/assets/reports-BhvXDkS0.js +1 -0
- package/dist/client/assets/{reports-DSK9pInf.js → reports-DMyC7KyA.js} +1 -1
- package/dist/client/assets/{reports-onboarding-BGpMVdJb.js → reports-onboarding-DPM59fnB.js} +1 -1
- package/dist/client/assets/{reports-tab-DOaYQIgv.js → reports-tab-8zKvNIEo.js} +2 -2
- package/dist/client/assets/{repositories-9mNfLfC6.js → repositories-DU6E4aSI.js} +1 -1
- package/dist/client/assets/{repository-binding-DB3Rsfan.js → repository-binding-BDRDBDUT.js} +1 -1
- package/dist/client/assets/{repository-import-picker-DyQqkMVo.js → repository-import-picker-COhtx-GU.js} +1 -1
- package/dist/client/assets/{repository-picker-BhN42NYE.js → repository-picker-CsXpKrPD.js} +1 -1
- package/dist/client/assets/{require-capability-T865QzND.js → require-capability-r3Xn3m_O.js} +1 -1
- package/dist/client/assets/{required-auth-layout-BhtMSUK8.js → required-auth-layout-CPsT8IBO.js} +1 -1
- package/dist/client/assets/{reset-password-DknJZEoY.js → reset-password-BCbbqzqA.js} +1 -1
- package/dist/client/assets/{resizable-Cl5uhslg.js → resizable-xF5MDTwK.js} +1 -1
- package/dist/client/assets/{resolve-tab-icon-BJxTAEQQ.js → resolve-tab-icon-BpT7YYoz.js} +1 -1
- package/dist/client/assets/{review-settings-CMvo0pRC.js → review-settings-bSzJA51j.js} +1 -1
- package/dist/client/assets/{rich-text-link-control-CzOQrdNt.js → rich-text-link-control-CY5lmcbW.js} +1 -1
- package/dist/client/assets/{roles-Bvw2DL9o.js → roles-COXgTHD9.js} +1 -1
- package/dist/client/assets/route-CXaJOXis.js +1 -0
- package/dist/client/assets/{route-BqhdkgCD.js → route-DgJH5qOb.js} +1 -1
- package/dist/client/assets/{route-Dq4tC8Qc.js → route-DsmAMRjH.js} +1 -1
- package/dist/client/assets/{runnable-block-editor-CU4DL_Np.js → runnable-block-editor-Bq48XkmP.js} +4 -4
- package/dist/client/assets/{sandbox-lifecycle-context-CCWi8UrE.js → sandbox-lifecycle-context-BDzjYF6X.js} +1 -1
- package/dist/client/assets/{schema-CtVpxfN8.js → schema-DsftfWql.js} +1 -1
- package/dist/client/assets/{scroll-area-DTVFcTe4.js → scroll-area-CuhYBrVG.js} +1 -1
- package/dist/client/assets/{search-input-B7esxZLr.js → search-input-DO4RsgDo.js} +1 -1
- package/dist/client/assets/{search-toggle-BmdAS9S4.js → search-toggle-BJ6mBMxB.js} +1 -1
- package/dist/client/assets/{secret-picker-BV1iDD76.js → secret-picker-B9q4BUYJ.js} +1 -1
- package/dist/client/assets/{secrets-D9_ygYCx.js → secrets-CePkYXXO.js} +1 -1
- package/dist/client/assets/{sections-editor-BOruSM_E.js → sections-editor-Df3gUxs6.js} +1 -1
- package/dist/client/assets/{select-CCPnfgQ9.js → select-DUxatCDi.js} +1 -1
- package/dist/client/assets/{select-model-8KGpYG78.js → select-model-hxt2hW5D.js} +1 -1
- package/dist/client/assets/{seo-editor-C0NKkdi0.js → seo-editor-Du7ojpzS.js} +1 -1
- package/dist/client/assets/{separator-CWugGQbc.js → separator-BzaLX8fd.js} +1 -1
- package/dist/client/assets/{settings-tab-DRo0WDQp.js → settings-tab-DqEufUIw.js} +1 -1
- package/dist/client/assets/{sheet-BHMUXURV.js → sheet-Dsh1DGgw.js} +1 -1
- package/dist/client/assets/{shell-layout-XTP1Kn60.js → shell-layout-DrF9YflL.js} +1 -1
- package/dist/client/assets/{skills-E3OyU2oM.js → skills-oZ0qPKOl.js} +1 -1
- package/dist/client/assets/{sso-BZQj7YFV.js → sso-D9V8xm1h.js} +1 -1
- package/dist/client/assets/{suggestion-089nWMGT.js → suggestion-C-WgKXgU.js} +1 -1
- package/dist/client/assets/{switch-Bj8bJ2hL.js → switch-Dm6uUVFL.js} +1 -1
- package/dist/client/assets/{synced-repos-CVHbttMo.js → synced-repos-CYW9TGNF.js} +1 -1
- package/dist/client/assets/{tab-icon-glyph-6vvl9RhU.js → tab-icon-glyph-BqlyD9jL.js} +1 -1
- package/dist/client/assets/{table-vIpu14O-.js → table-BbevayqW.js} +1 -1
- package/dist/client/assets/{tabs-Cz37pyV6.js → tabs-8CMAf1uG.js} +1 -1
- package/dist/client/assets/{task-board-BMQrxTue.js → task-board-DXD3aKXi.js} +1 -1
- package/dist/client/assets/{task-route-BKWswtA1.js → task-route-doPf8uSw.js} +1 -1
- package/dist/client/assets/{task-status-C1D3al28.js → task-status-B0dcE5iY.js} +1 -1
- package/dist/client/assets/{taskboard-analytics-D2gsuZp2.js → taskboard-analytics-CE1JeLhH.js} +1 -1
- package/dist/client/assets/{tasks-CuCPnKFB.js → tasks-BvFkBNHM.js} +1 -1
- package/dist/client/assets/tasks-xR3ybzsh.js +1 -0
- package/dist/client/assets/{textarea-C-PwJiry.js → textarea-Cnw96_Vw.js} +1 -1
- package/dist/client/assets/{thread-analytics-6Vi5UYyl.js → thread-analytics-BnQ-KERJ.js} +1 -1
- package/dist/client/assets/{thread-button-CBArUpXO.js → thread-button-BRy_z3r1.js} +1 -1
- package/dist/client/assets/{thread-intent-swCQbScV.js → thread-intent-BOEFGlMm.js} +1 -1
- package/dist/client/assets/{thread-route-CMTlmdB2.js → thread-route-BtUAL8zM.js} +1 -1
- package/dist/client/assets/{thread-route-DTbwFwzB.js → thread-route-D6_2qU5y.js} +1 -1
- package/dist/client/assets/{thread-sheet-body-BNWfu5MD.js → thread-sheet-body-C_UWi3rA.js} +1 -1
- package/dist/client/assets/{toggle-group-CozxhBpA.js → toggle-group-DMrc-VEn.js} +1 -1
- package/dist/client/assets/{toolbar-icon-button-BR_iVDC5.js → toolbar-icon-button-B_si7l6J.js} +1 -1
- package/dist/client/assets/{tooltip-CmsIn1_T.js → tooltip-D_rDETL5.js} +1 -1
- package/dist/client/assets/{track-ISGFXwLG.js → track-CmsoJ4xI.js} +1 -1
- package/dist/client/assets/{types-Dnj2Xk6p.js → types-DNrbJSW6.js} +1 -1
- package/dist/client/assets/{usage-stats-CQr6G5Ur.js → usage-stats-DtxeZ0P6.js} +1 -1
- package/dist/client/assets/{use-ai-providers-DKY0H66j.js → use-ai-providers-BY6SYGnL.js} +1 -1
- package/dist/client/assets/{use-automations-CSJ606-d.js → use-automations-BTGg3lrV.js} +1 -1
- package/dist/client/assets/{use-autosave-CnIoAHDs.js → use-autosave-C09SWhxz.js} +1 -1
- package/dist/client/assets/{use-chat-layout-state-B1ZVGaLS.js → use-chat-layout-state-DtSzju1r.js} +1 -1
- package/dist/client/assets/{use-clock-tick-BsJNcY-e.js → use-clock-tick-B6RjlwGP.js} +1 -1
- package/dist/client/assets/{use-connect-companion-vcvy2-_E.js → use-connect-companion-Md7gJVdj.js} +1 -1
- package/dist/client/assets/{use-connection-o6IaHrCa.js → use-connection-BdXCXco4.js} +1 -1
- package/dist/client/assets/{use-copy-CbVFfAiy.js → use-copy-CGFZVF1O.js} +1 -1
- package/dist/client/assets/{use-create-virtual-mcp-B90oa05V.js → use-create-virtual-mcp-BDx5KjcP.js} +1 -1
- package/dist/client/assets/{use-date-fns-locale-DtLNXwQQ.js → use-date-fns-locale-xsNp9_jV.js} +1 -1
- package/dist/client/assets/{use-debounced-autosave-C94tXEES.js → use-debounced-autosave-Bm10g-8R.js} +1 -1
- package/dist/client/assets/{use-debounced-value-BJOL8Gwj.js → use-debounced-value-BXmvwHes.js} +1 -1
- package/dist/client/assets/{use-deco-credits-BTMj7mOL.js → use-deco-credits-BLsA0-D1.js} +1 -1
- package/dist/client/assets/{use-decopilot-events-B7N8IjI0.js → use-decopilot-events-xg-lzK_6.js} +1 -1
- package/dist/client/assets/{use-delete-connection-CWCsmyea.js → use-delete-connection-BE4Nj7DL.js} +1 -1
- package/dist/client/assets/{use-deployment-admin-C7HpswZD.js → use-deployment-admin-CdfYikgx.js} +1 -1
- package/dist/client/assets/{use-fast-preview-draft-url-X9ccfQ1G.js → use-fast-preview-draft-url-D5snqAgF.js} +1 -1
- package/dist/client/assets/{use-file-configs-BJx6-ZW4.js → use-file-configs-CeiMSMu5.js} +1 -1
- package/dist/client/assets/{use-infinite-scroll-D564AByM.js → use-infinite-scroll-CnGnDOhg.js} +1 -1
- package/dist/client/assets/{use-join-requests-DadESn-r.js → use-join-requests-BldvGxVz.js} +1 -1
- package/dist/client/assets/{use-main-panel-tabs-CvkNpk_m.js → use-main-panel-tabs-C83ZnyG5.js} +1 -1
- package/dist/client/assets/{use-mcp-auth-status-BPJMjKJu.js → use-mcp-auth-status-Du_TKL-p.js} +1 -1
- package/dist/client/assets/{use-mcp-client-BCOmh6mH.js → use-mcp-client-DrDmZDA7.js} +1 -1
- package/dist/client/assets/{use-mcp-prompts-DsQz4qyp.js → use-mcp-prompts-ORmr-8fB.js} +1 -1
- package/dist/client/assets/{use-mcp-tools-isgPo0N2.js → use-mcp-tools-YCPND0WQ.js} +1 -1
- package/dist/client/assets/{use-members-B_fEZqvW.js → use-members-DEXWsj1d.js} +1 -1
- package/dist/client/assets/{use-mobile-CUG36tjm.js → use-mobile-CfSbfoft.js} +1 -1
- package/dist/client/assets/{use-navigate-to-agent-Cv939dl9.js → use-navigate-to-agent-CPmL7r2a.js} +1 -1
- package/dist/client/assets/use-new-blocks-editor-Cc8wtKHo.js +1 -0
- package/dist/client/assets/{use-open-billing-url-DBj1DYvR.js → use-open-billing-url-kzMhA6w7.js} +1 -1
- package/dist/client/assets/{use-org-auth-client-Cro1UGGf.js → use-org-auth-client-CkktJ4ju.js} +1 -1
- package/dist/client/assets/{use-org-fs-CfcB8IFl.js → use-org-fs-aJhRDDIA.js} +1 -1
- package/dist/client/assets/{use-org-repo-syncs-DVJH08hK.js → use-org-repo-syncs-hamxf4uc.js} +1 -1
- package/dist/client/assets/{use-org-sso-554XjjGQ.js → use-org-sso-D5wnNfkO.js} +1 -1
- package/dist/client/assets/{use-organization-roles-BTmd-L2w.js → use-organization-roles-OHxv6X-a.js} +1 -1
- package/dist/client/assets/{use-organization-settings-B-_PpufY.js → use-organization-settings-B56H80YG.js} +1 -1
- package/dist/client/assets/{use-panel-navigate-CuKDZSXf.js → use-panel-navigate-C7k_IWwP.js} +1 -1
- package/dist/client/assets/{use-project-scope-B1N6dPlK.js → use-project-scope-D3SRaEYd.js} +1 -1
- package/dist/client/assets/{use-releases-BK-Rfz0E.js → use-releases-CpYl3ey_.js} +1 -1
- package/dist/client/assets/{use-reports-diagnostic-kNe2-1FK.js → use-reports-diagnostic-CkrVtdqs.js} +1 -1
- package/dist/client/assets/{use-secrets-Bpfmfnyi.js → use-secrets-Dcc9pXbR.js} +1 -1
- package/dist/client/assets/{use-section-preview-base-DDylhaW1.js → use-section-preview-base-Z24TKN0B.js} +1 -1
- package/dist/client/assets/{use-session-runtime-CTR5dqXO.js → use-session-runtime-DStZ5XGd.js} +1 -1
- package/dist/client/assets/{use-tags-CToQ_9AW.js → use-tags-BaTcNvTV.js} +1 -1
- package/dist/client/assets/{use-task-board-analytics-BhmIKHN_.js → use-task-board-analytics-B1pwJZX7.js} +1 -1
- package/dist/client/assets/{use-task-board-events-B6plWEJr.js → use-task-board-events-oQbUK5D4.js} +1 -1
- package/dist/client/assets/{use-task-metadata-_V-lBt2X.js → use-task-metadata-Dq3w9o1-.js} +1 -1
- package/dist/client/assets/{use-thread-analytics-DJ0Oh091.js → use-thread-analytics-Bit06zCt.js} +1 -1
- package/dist/client/assets/{use-thread-outputs-BH6QTvpP.js → use-thread-outputs-DMYaNXtN.js} +1 -1
- package/dist/client/assets/useInfiniteQuery-S6GnLytU.js +1 -0
- package/dist/client/assets/{useQueries-DHRnWhYf.js → useQueries-Bm3vQaFd.js} +1 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-CrkH2XOR.js +1 -0
- package/dist/client/assets/{users-UP11Y2d_.js → users-BHYuTTwT.js} +1 -1
- package/dist/client/assets/{utils-CSf7trYW.js → utils-Fw1u9QDx.js} +1 -1
- package/dist/client/assets/{variant-calendar-k_RwHcjk.js → variant-calendar-DRKQ2B6v.js} +1 -1
- package/dist/client/assets/{variant-matcher-override-DEvkqGTd.js → variant-matcher-override-wHTtLSfq.js} +1 -1
- package/dist/client/assets/{view-mode-toggle-C7tIx4kb.js → view-mode-toggle-BQZodl_Y.js} +1 -1
- package/dist/client/assets/{virtual-mcp-BkcbnGY4.js → virtual-mcp-C2bpy2G-.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-app-Bmq8mE4b.js +0 -1
- package/dist/client/assets/agent-deck-ChJEzNvh.js +0 -1
- package/dist/client/assets/agent-library-DCzTnvza.js +0 -1
- package/dist/client/assets/agent-library-file-DtqKvoz2.js +0 -1
- package/dist/client/assets/agent-settings-BFm3cinJ.js +0 -1
- package/dist/client/assets/agent-site-editor-code-Bux6lvrY.js +0 -2
- package/dist/client/assets/agent-view-CLwrYt4k.js +0 -1
- package/dist/client/assets/api-keys-41OcNRfF.js +0 -1
- package/dist/client/assets/app-editor-C0HEp9TR.js +0 -1
- package/dist/client/assets/claim-phase-copy-CLVpoo-M.js +0 -1
- package/dist/client/assets/flat-project-BXD7xaS4.js +0 -1
- package/dist/client/assets/library-BbAPgXkD.js +0 -1
- package/dist/client/assets/mcp-app-renderer-BuJCA9WL.js +0 -11
- package/dist/client/assets/project-reports-BrIp72jF.js +0 -1
- package/dist/client/assets/project-tasks-DV-ii699.js +0 -1
- package/dist/client/assets/record-editor-ziqyGjSB.js +0 -1
- package/dist/client/assets/reports-3EyuS8J8.js +0 -1
- package/dist/client/assets/route-BRK2g0Ok.js +0 -1
- package/dist/client/assets/tasks-sv7N_jrP.js +0 -1
- package/dist/client/assets/use-new-blocks-editor-CUI80h3P.js +0 -1
- package/dist/client/assets/useInfiniteQuery-DRaKStQa.js +0 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-WHFkobEh.js +0 -1
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{c as k,m as Te,b as L,j as s,h as Ie,X as Y,r as de,ak as me,l as X,B as ue,ep as P,bo as fe,bw as Pe,bF as Re,br as pe,bm as Ee,bq as Me,bp as $e,bn as De,ao as Fe}from"./index-B1zctMWM.js";import{C as Le}from"./index-_Pfw1M40.js";import{A as Oe}from"./agent-view-guard-BwrmGLlw.js";import{a as Ge,d as Be,h as Ve}from"./repository-binding-DB3Rsfan.js";import{n as W}from"./LinkExternal01-ByTglQMD.js";import{f as Ue,M as se}from"./markdown-BSYuVrvS.js";import"./index-DD7q2zTd.js";import{G as He,e as Ke,d as K}from"./message-templates-xF6Z-DZJ.js";import{T as te,a as Qe,c as re,b as ze}from"./tabs-Cz37pyV6.js";import{u as qe}from"./use-mcp-client-BCOmh6mH.js";import{a as Je}from"./sandbox-git-api-B1R0585s.js";import{a as Ye,u as Xe,b as We}from"./chat-context-CW-2SJ9g.js";import{g as Ze,h as et,i as tt,d as rt}from"./use-navigate-to-agent-Cv939dl9.js";import{T as ot,c as he,R as st,d as nt}from"./collapsible-taXF9Vin.js";import{b as it}from"./thread-route-CMTlmdB2.js";import"./use-mobile-CUG36tjm.js";import"./thread-button-CBArUpXO.js";import"./agent-icon-Plx0vVQZ.js";import"./AlertCircle-Bx6Xy-Kw.js";import"./Tool01-DQZj0rVc.js";import"./ArrowUp-Dr4dZUTV.js";import"./ArrowLeft-BBlLaPEb.js";import"./LinkBroken01-DLTNdGdq.js";import"./ShoppingBag01-BnqPHk8-.js";import"./ZoomOut-o5Bj_0k0.js";import"./Building02-qqUg_lk7.js";import"./CheckCircle-DQ_Iwx7G.js";import"./Check-BhHmW1CL.js";import"./ChevronUp-C6nGgzcV.js";import"./UserSquare-DubBIV3t.js";import"./Copy01-1J_cPh43.js";import"./CreditCard01-CZJLSW5h.js";import"./DotsVertical-DMzCTdNT.js";import"./Image01-VqGHD62D.js";import"./Palette-DItfN1RT.js";import"./XClose-B5gtMDn3.js";import"./Key01-3kquwPFB.js";import"./Link01-ZJZ8YMCs.js";import"./Monitor01-CjCwBipo.js";import"./Sun-G5YUTpKk.js";import"./Plus-jU4D0ULX.js";import"./SearchMd-yUpDH67q.js";import"./Trash01-CfWaytgc.js";import"./Upload01-ca0GgR0P.js";import"./User01-BJgSr0na.js";import"./Users01-BI4qzwEi.js";import"./X-4SjHAUB6.js";import"./use-chat-layout-state-B1ZVGaLS.js";import"./use-file-configs-BJx6-ZW4.js";import"./use-organization-settings-B-_PpufY.js";import"./schema-CtVpxfN8.js";import"./task-board-BMQrxTue.js";import"./site-slug-DebpOoQq.js";import"./use-panel-navigate-CuKDZSXf.js";import"./use-project-scope-B1N6dPlK.js";import"./thread-intent-swCQbScV.js";import"./backoff-8mStPHYB.js";import"./slugify-CEUa2lfQ.js";import"./sheet-BHMUXURV.js";import"./tooltip-CmsIn1_T.js";import"./index-CazcJ_7a.js";import"./toolbar-icon-button-BR_iVDC5.js";import"./shell-layout-XTP1Kn60.js";import"./avatar-ZtrZA-xC.js";import"./download-app-dialog-VBK5SfsW.js";import"./dialog-DUkVOZIE.js";import"./use-clock-tick-BsJNcY-e.js";import"./command-Dj5wxXJe.js";import"./index-CKkIU_55.js";import"./integration-icon-B97YfXXZ.js";import"./project-icon-0knrxIOw.js";import"./new-project-dialog-BMehfxLv.js";import"./input-B3HVl7By.js";import"./label-Be_7Vms5.js";import"./repository-import-picker-DyQqkMVo.js";import"./repository-picker-BhN42NYE.js";import"./useInfiniteQuery-DRaKStQa.js";import"./infiniteQueryObserver-BBgKyTli.js";import"./collection-search-De8chpSh.js";import"./use-debounced-value-BJOL8Gwj.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-BhtMSUK8.js";import"./autosend-CtvAncuN.js";import"./use-org-sso-554XjjGQ.js";import"./resizable-Cl5uhslg.js";import"./icon-button-BpPbhU8u.js";import"./use-main-panel-tabs-CvkNpk_m.js";import"./use-connection-o6IaHrCa.js";import"./use-mcp-tools-isgPo0N2.js";import"./types-Dnj2Xk6p.js";import"./utils-CVEq3hMx.js";import"./sandbox-lifecycle-context-CCWi8UrE.js";import"./use-session-runtime-CTR5dqXO.js";import"./sandbox-url-D3mC8qhT.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./file-type-icon-CideAigq.js";import"./resolve-tab-icon-BJxTAEQQ.js";import"./use-task-metadata-_V-lBt2X.js";import"./virtual-mcp-BkcbnGY4.js";import"./location-DPIrGNp7.js";import"./org-file-open-context-2kSVNzGe.js";import"./gateway-client-DdEB-W_0.js";import"./drawer-BE8-rjnv.js";import"./use-mcp-prompts-DsQz4qyp.js";import"./index-De_dnJRN.js";import"./form-esFIz8cn.js";import"./input-DsxQztmQ.js";import"./chat-draft-CwKaZkWY.js";import"./select-CCPnfgQ9.js";import"./usage-stats-CQr6G5Ur.js";import"./use-copy-CbVFfAiy.js";import"./format-time-CjIPQhCN.js";import"./differenceInSeconds-C3x8sHUj.js";import"./use-decopilot-events-B7N8IjI0.js";import"./use-deco-credits-BTMj7mOL.js";import"./use-ai-providers-DKY0H66j.js";import"./toggle-group-CozxhBpA.js";import"./tool-namespace-DmnQIdtF.js";import"./use-open-billing-url-DBj1DYvR.js";import"./decopilot-CcCmg-UE.js";import"./checkbox-Cs5VXlL7.js";import"./ai-providers-logos-DD3qZ33J.js";import"./popover-DwQza7Ap.js";import"./index-CFflVJHI.js";import"./input-D1BEXHTl.js";import"./suggestion-089nWMGT.js";import"./use-org-fs-CfcB8IFl.js";import"./question-004-sINsf4GQ.js";import"./use-members-B_fEZqvW.js";import"./use-org-auth-client-Cro1UGGf.js";import"./feature-paywall-DGxl3PI8.js";import"./plan-ladder-CfA0FpAL.js";import"./add-connection-dialog-C9teNzj3.js";import"./extract-connection-data-BqvnWkg5.js";import"./metadata-D72DunRR.js";import"./connection-DCZz5J1M.js";import"./connection-card-DaZTNpcS.js";import"./connection-slug-CITJ0kGN.js";import"./textarea-C-PwJiry.js";import"./connection-form-helpers-Dyc97_iQ.js";import"./authenticate-and-persist-oauth-CM_sd9mo.js";import"./mcp-oauth-Dt9pIBq5.js";import"./auth-BhL4Ae7M.js";import"./collection-tabs-2Nn5b0UJ.js";import"./badge-B0eiYJhc.js";import"./use-infinite-scroll-D564AByM.js";import"./useSuspenseInfiniteQuery-WHFkobEh.js";import"./use-task-board-events-B6plWEJr.js";import"./pair-bDKRTMqu.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-BuJCA9WL.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./use-thread-outputs-BH6QTvpP.js";import"./editor-Bicb4Bqw.js";import"./utils-CSf7trYW.js";function lt(i){if(!i||typeof i!="object")return null;const e=i;return e.isError?e.content?.find(r=>r.type==="text")?.text?.trim()||"GitHub MCP tool returned an error":null}function at(i){const e=lt(i);if(e)throw new Error(e)}function ct(i){try{return JSON.parse(i)}catch{return null}}function dt(i){if(!i||typeof i!="object")return null;const e=i,t=e.content?.find(a=>a.type==="text")?.text,r=t?ct(t):null,l=e.structuredContent;return l==null?r:typeof l=="object"&&!Array.isArray(l)&&Object.keys(l).length===0?r??l:l}function mt(i){const e=dt(i);return e===null?null:e}const ut=10,ae=100,ft=30;function pt(i){const e=i;if(e.isError)return null;const t=e.content?.find(l=>l.type==="resource"),r=t?.resource?.text??t?.text;if(!r)return null;try{const l=JSON.parse(r);return typeof l=="string"?l:l&&typeof l=="object"&&"content"in l&&typeof l.content=="string"?l.content:JSON.stringify(l,null,2)}catch{return r}}async function q(i,e,t){try{const r=await i.callTool({name:"get_file_contents",arguments:{owner:e.owner,repo:e.repo,path:e.path,...t}});return pt(r)}catch{return null}}function ht(i){at(i);const e=mt(i);return Array.isArray(e)?e.map(t=>{const r=Number(t.additions??0),l=Number(t.changes??r),a=Number(t.deletions??Math.max(0,l-r));return{filename:String(t.filename??""),status:t.status??"modified",additions:r,deletions:a,blobUrl:typeof t.blob_url=="string"?t.blob_url:null,previousFilename:typeof t.previous_filename=="string"?t.previous_filename:null}}):[]}async function xt(i,e,t){if(i.length===0)return;let r=0;async function l(){for(;r<i.length;){const a=r++;await t(i[a])}}await Promise.all(Array.from({length:Math.min(e,i.length)},()=>l()))}async function gt(i,e){const t=[];for(let r=1;r<=ft;r++){const l=await i.callTool({name:"pull_request_read",arguments:{method:"get_files",owner:e.owner,repo:e.repo,pullNumber:e.pullNumber,page:r,perPage:ae}}),a=ht(l);if(t.push(...a),a.length<ae)break}return t}async function ce(i,e){const r=(await gt(i,e)).filter(o=>o.filename.length>0),l={},a=e.mergeBaseSha?{sha:e.mergeBaseSha}:{ref:e.base};return await xt(r,ut,async o=>{const n=o.filename;if(o.status==="added"){l[n]={from:null,to:await q(i,{owner:e.owner,repo:e.repo,path:n},{sha:e.headSha})};return}if(o.status==="removed"){l[n]={from:await q(i,{owner:e.owner,repo:e.repo,path:n},a),to:null};return}const c=o.previousFilename??n,[m,f]=await Promise.all([q(i,{owner:e.owner,repo:e.repo,path:c},a),q(i,{owner:e.owner,repo:e.repo,path:n},{sha:e.headSha})]);l[n]={from:m,to:f}}),{diffs:l}}function xe(i){return i?Object.keys(i.diffs).length:0}function bt(i,e,t,r,l,a,o){return["pr-diff",i,e,t,r,l,a,o]}function jt(i){const e=k.c(27),{orgSlug:t,orgId:r,virtualMcpId:l,branch:a,threadId:o,base:n,headSha:c,pullNumber:m,connectionId:f,owner:d,repo:x,enabled:p}=i,b=p===void 0?!0:p;let g;e[0]!==f||e[1]!==r||e[2]!==t?(g={connectionId:f,orgId:r,orgSlug:t},e[0]=f,e[1]=r,e[2]=t,e[3]=g):g=e[3];const v=qe(g);let A;e[4]!==n||e[5]!==a||e[6]!==f||e[7]!==c||e[8]!==t||e[9]!==m||e[10]!==l?(A=bt(t,l,a,n,c,m,f),e[4]=n,e[5]=a,e[6]=f,e[7]=c,e[8]=t,e[9]=m,e[10]=l,e[11]=A):A=e[11];let y;e[12]!==n||e[13]!==a||e[14]!==v||e[15]!==c||e[16]!==t||e[17]!==d||e[18]!==m||e[19]!==x||e[20]!==o||e[21]!==l?(y=async()=>{try{const w=await Je({orgSlug:t,virtualMcpId:l,branch:a,threadId:o},{base:n,headSha:c});return xe(w)>0?w:ce(v,{owner:d,repo:x,pullNumber:m,base:n,headSha:c,mergeBaseSha:w.mergeBaseSha})}catch{return ce(v,{owner:d,repo:x,pullNumber:m,base:n,headSha:c})}},e[12]=n,e[13]=a,e[14]=v,e[15]=c,e[16]=t,e[17]=d,e[18]=m,e[19]=x,e[20]=o,e[21]=l,e[22]=y):y=e[22];const C=b&&!!a&&!!c&&!!f;let N;return e[23]!==A||e[24]!==y||e[25]!==C?(N={queryKey:A,queryFn:y,enabled:C,staleTime:1/0},e[23]=A,e[24]=y,e[25]=C,e[26]=N):N=e[26],Te(N)}function vt(i){const e=k.c(14),{diffQuery:t}=i,r=L();if(t.isLoading){let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsx(Ie,{className:"h-4 w-4"}),e[0]=n):n=e[0];let c;e[1]!==r?(c=r("thread.changesTab.loadingChanges"),e[1]=r,e[2]=c):c=e[2];let m;return e[3]!==c?(m=s.jsxs("div",{className:"flex items-center justify-center gap-2 py-16 text-muted-foreground",children:[n,s.jsx("span",{className:"text-sm",children:c})]}),e[3]=c,e[4]=m):m=e[4],m}if(t.isError){let n;e[5]!==r?(n=r("thread.changesTab.couldntLoadPrChanges"),e[5]=r,e[6]=n):n=e[6];let c;return e[7]!==n?(c=s.jsx("div",{className:"py-10 text-sm text-destructive",children:n}),e[7]=n,e[8]=c):c=e[8],c}const l=t.data;let a;e[9]!==r?(a=r("thread.changesTab.noCommittedChanges"),e[9]=r,e[10]=a):a=e[10];let o;return e[11]!==t.data||e[12]!==a?(o=s.jsx(He,{diff:l,rowClassName:"px-0",emptyMessage:a}),e[11]=t.data,e[12]=a,e[13]=o):o=e[13],o}function yt(i){return[i?.summary?.trim(),i?.text?.trim()].filter(Boolean).join(`
|
|
1
|
+
import{c as k,m as Te,b as L,j as s,h as Ie,X as Y,r as de,ak as me,l as X,B as ue,ep as P,bo as fe,bw as Pe,bF as Re,br as pe,bm as Ee,bq as Me,bp as $e,bn as De,ao as Fe}from"./index-Creb5Fal.js";import{C as Le}from"./index-YPpUZW2G.js";import{A as Oe}from"./agent-view-guard-Dz25zh4B.js";import{a as Ge,d as Be,h as Ve}from"./repository-binding-BDRDBDUT.js";import{n as W}from"./LinkExternal01-mH0kFM32.js";import{f as Ue,M as se}from"./markdown-C0crjplB.js";import"./index-D3Sn56HF.js";import{G as He,e as Ke,d as K}from"./message-templates-80H103Z6.js";import{T as te,a as Qe,c as re,b as ze}from"./tabs-8CMAf1uG.js";import{u as qe}from"./use-mcp-client-DrDmZDA7.js";import{a as Je}from"./sandbox-git-api-B1R0585s.js";import{a as Ye,u as Xe,b as We}from"./chat-context-CuWiXF8M.js";import{g as Ze,h as et,i as tt,d as rt}from"./use-navigate-to-agent-CPmL7r2a.js";import{T as ot,c as he,R as st,d as nt}from"./collapsible-BMQj5Dup.js";import{b as it}from"./thread-route-BtUAL8zM.js";import"./use-mobile-CfSbfoft.js";import"./thread-button-BRy_z3r1.js";import"./agent-icon-Cs5o_QD_.js";import"./AlertCircle-CfHvNlgZ.js";import"./Tool01-Dz-lp6mO.js";import"./ArrowUp-BDwJ6lSJ.js";import"./ArrowLeft-Bj2Vh3jF.js";import"./LinkBroken01-xKKRxXlY.js";import"./ShoppingBag01-CdLvneJ1.js";import"./ZoomOut-BvLQLuGR.js";import"./Building02-Bqa8ze-O.js";import"./CheckCircle-Vb-xyxhE.js";import"./Check-COzQ04E7.js";import"./ChevronUp-RdnkaZaK.js";import"./UserSquare-BZc1G4LK.js";import"./Copy01-DJrDIAgF.js";import"./CreditCard01-N4OPgVDg.js";import"./DotsVertical-D5rr2YQm.js";import"./Image01-Ccx9C_Rg.js";import"./Palette-KCM9-De7.js";import"./XClose-CYHY5GcG.js";import"./Key01-B1Y8yy7Z.js";import"./Link01-Bh_PC3dO.js";import"./Monitor01-PBPlMgWr.js";import"./Sun-BpeW1MoX.js";import"./Plus-HBSdQYLn.js";import"./SearchMd-BBjcQIvr.js";import"./Trash01-C7BGYPNB.js";import"./Upload01-Crj-EmOO.js";import"./User01-COdLotsN.js";import"./Users01-6Yj_4D_n.js";import"./X-BpUF7FNJ.js";import"./use-chat-layout-state-DtSzju1r.js";import"./use-file-configs-CeiMSMu5.js";import"./use-organization-settings-B56H80YG.js";import"./schema-DsftfWql.js";import"./task-board-DXD3aKXi.js";import"./site-slug-DebpOoQq.js";import"./use-panel-navigate-C7k_IWwP.js";import"./use-project-scope-D3SRaEYd.js";import"./thread-intent-BOEFGlMm.js";import"./backoff-8mStPHYB.js";import"./slugify-CEUa2lfQ.js";import"./sheet-Dsh1DGgw.js";import"./tooltip-D_rDETL5.js";import"./index-hVDNPnIj.js";import"./toolbar-icon-button-B_si7l6J.js";import"./shell-layout-DrF9YflL.js";import"./avatar-BIv_2mLm.js";import"./download-app-dialog-wOlBcsxc.js";import"./dialog-BK1Ueu93.js";import"./use-clock-tick-B6RjlwGP.js";import"./command-BzdiaYU5.js";import"./index-DrzDi7N3.js";import"./integration-icon-DhFk0v8h.js";import"./project-icon-DYsLOXub.js";import"./new-project-dialog-DrxiqG-Y.js";import"./input-BKlAoViI.js";import"./label-ycBnzzff.js";import"./repository-import-picker-COhtx-GU.js";import"./repository-picker-CsXpKrPD.js";import"./useInfiniteQuery-S6GnLytU.js";import"./infiniteQueryObserver-D3SNQDlh.js";import"./collection-search-DUZsfox8.js";import"./use-debounced-value-BXmvwHes.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-CPsT8IBO.js";import"./autosend-BiJfUQUT.js";import"./use-org-sso-D5wnNfkO.js";import"./resizable-xF5MDTwK.js";import"./icon-button-D4H5x94G.js";import"./use-main-panel-tabs-C83ZnyG5.js";import"./use-connection-BdXCXco4.js";import"./use-mcp-tools-YCPND0WQ.js";import"./types-DNrbJSW6.js";import"./utils-CVEq3hMx.js";import"./sandbox-lifecycle-context-BDzjYF6X.js";import"./use-session-runtime-DStZ5XGd.js";import"./sandbox-url-D3mC8qhT.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./file-type-icon-Ib_JQuvQ.js";import"./resolve-tab-icon-BpT7YYoz.js";import"./use-task-metadata-Dq3w9o1-.js";import"./virtual-mcp-C2bpy2G-.js";import"./location-DPIrGNp7.js";import"./org-file-open-context-BWYWVr6j.js";import"./gateway-client-BpCG924q.js";import"./drawer-u-W4g_nO.js";import"./use-mcp-prompts-ORmr-8fB.js";import"./index-CGgVIw_7.js";import"./form-nYJgRjCD.js";import"./input-Bv8cV8cl.js";import"./chat-draft-MjQajd4b.js";import"./select-DUxatCDi.js";import"./usage-stats-DtxeZ0P6.js";import"./use-copy-CGFZVF1O.js";import"./format-time-CjIPQhCN.js";import"./differenceInSeconds-C3x8sHUj.js";import"./use-decopilot-events-xg-lzK_6.js";import"./use-deco-credits-BLsA0-D1.js";import"./use-ai-providers-BY6SYGnL.js";import"./toggle-group-DMrc-VEn.js";import"./tool-namespace-DmnQIdtF.js";import"./use-open-billing-url-kzMhA6w7.js";import"./decopilot-Djx80CTZ.js";import"./checkbox-69BFI5HM.js";import"./ai-providers-logos-DD3qZ33J.js";import"./popover-Dvqj57GQ.js";import"./index-BEAvsXWJ.js";import"./input-B4_sU5tp.js";import"./suggestion-C-WgKXgU.js";import"./use-org-fs-aJhRDDIA.js";import"./question-004-sINsf4GQ.js";import"./use-members-DEXWsj1d.js";import"./use-org-auth-client-CkktJ4ju.js";import"./feature-paywall-Ly3_RQ_p.js";import"./plan-ladder-RwyJdG4c.js";import"./add-connection-dialog-BKu4JrTL.js";import"./extract-connection-data-lBq634kY.js";import"./metadata-D72DunRR.js";import"./connection-Byk90CG2.js";import"./connection-card-CdUGcyiA.js";import"./connection-slug-CITJ0kGN.js";import"./textarea-Cnw96_Vw.js";import"./connection-form-helpers-CIUjUhAv.js";import"./authenticate-and-persist-oauth-jKlCQsjO.js";import"./mcp-oauth-DvzBEl8t.js";import"./auth-C1mOz7Cp.js";import"./collection-tabs-BYPXCgXS.js";import"./badge-lEq6LpEb.js";import"./use-infinite-scroll-CnGnDOhg.js";import"./useSuspenseInfiniteQuery-CrkH2XOR.js";import"./use-task-board-events-oQbUK5D4.js";import"./pair-BbS6p0iS.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-weTyRI6G.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./use-thread-outputs-DMYaNXtN.js";import"./editor-DOIu8213.js";import"./utils-Fw1u9QDx.js";function lt(i){if(!i||typeof i!="object")return null;const e=i;return e.isError?e.content?.find(r=>r.type==="text")?.text?.trim()||"GitHub MCP tool returned an error":null}function at(i){const e=lt(i);if(e)throw new Error(e)}function ct(i){try{return JSON.parse(i)}catch{return null}}function dt(i){if(!i||typeof i!="object")return null;const e=i,t=e.content?.find(a=>a.type==="text")?.text,r=t?ct(t):null,l=e.structuredContent;return l==null?r:typeof l=="object"&&!Array.isArray(l)&&Object.keys(l).length===0?r??l:l}function mt(i){const e=dt(i);return e===null?null:e}const ut=10,ae=100,ft=30;function pt(i){const e=i;if(e.isError)return null;const t=e.content?.find(l=>l.type==="resource"),r=t?.resource?.text??t?.text;if(!r)return null;try{const l=JSON.parse(r);return typeof l=="string"?l:l&&typeof l=="object"&&"content"in l&&typeof l.content=="string"?l.content:JSON.stringify(l,null,2)}catch{return r}}async function q(i,e,t){try{const r=await i.callTool({name:"get_file_contents",arguments:{owner:e.owner,repo:e.repo,path:e.path,...t}});return pt(r)}catch{return null}}function ht(i){at(i);const e=mt(i);return Array.isArray(e)?e.map(t=>{const r=Number(t.additions??0),l=Number(t.changes??r),a=Number(t.deletions??Math.max(0,l-r));return{filename:String(t.filename??""),status:t.status??"modified",additions:r,deletions:a,blobUrl:typeof t.blob_url=="string"?t.blob_url:null,previousFilename:typeof t.previous_filename=="string"?t.previous_filename:null}}):[]}async function xt(i,e,t){if(i.length===0)return;let r=0;async function l(){for(;r<i.length;){const a=r++;await t(i[a])}}await Promise.all(Array.from({length:Math.min(e,i.length)},()=>l()))}async function gt(i,e){const t=[];for(let r=1;r<=ft;r++){const l=await i.callTool({name:"pull_request_read",arguments:{method:"get_files",owner:e.owner,repo:e.repo,pullNumber:e.pullNumber,page:r,perPage:ae}}),a=ht(l);if(t.push(...a),a.length<ae)break}return t}async function ce(i,e){const r=(await gt(i,e)).filter(o=>o.filename.length>0),l={},a=e.mergeBaseSha?{sha:e.mergeBaseSha}:{ref:e.base};return await xt(r,ut,async o=>{const n=o.filename;if(o.status==="added"){l[n]={from:null,to:await q(i,{owner:e.owner,repo:e.repo,path:n},{sha:e.headSha})};return}if(o.status==="removed"){l[n]={from:await q(i,{owner:e.owner,repo:e.repo,path:n},a),to:null};return}const c=o.previousFilename??n,[m,f]=await Promise.all([q(i,{owner:e.owner,repo:e.repo,path:c},a),q(i,{owner:e.owner,repo:e.repo,path:n},{sha:e.headSha})]);l[n]={from:m,to:f}}),{diffs:l}}function xe(i){return i?Object.keys(i.diffs).length:0}function bt(i,e,t,r,l,a,o){return["pr-diff",i,e,t,r,l,a,o]}function jt(i){const e=k.c(27),{orgSlug:t,orgId:r,virtualMcpId:l,branch:a,threadId:o,base:n,headSha:c,pullNumber:m,connectionId:f,owner:d,repo:x,enabled:p}=i,b=p===void 0?!0:p;let g;e[0]!==f||e[1]!==r||e[2]!==t?(g={connectionId:f,orgId:r,orgSlug:t},e[0]=f,e[1]=r,e[2]=t,e[3]=g):g=e[3];const v=qe(g);let A;e[4]!==n||e[5]!==a||e[6]!==f||e[7]!==c||e[8]!==t||e[9]!==m||e[10]!==l?(A=bt(t,l,a,n,c,m,f),e[4]=n,e[5]=a,e[6]=f,e[7]=c,e[8]=t,e[9]=m,e[10]=l,e[11]=A):A=e[11];let y;e[12]!==n||e[13]!==a||e[14]!==v||e[15]!==c||e[16]!==t||e[17]!==d||e[18]!==m||e[19]!==x||e[20]!==o||e[21]!==l?(y=async()=>{try{const w=await Je({orgSlug:t,virtualMcpId:l,branch:a,threadId:o},{base:n,headSha:c});return xe(w)>0?w:ce(v,{owner:d,repo:x,pullNumber:m,base:n,headSha:c,mergeBaseSha:w.mergeBaseSha})}catch{return ce(v,{owner:d,repo:x,pullNumber:m,base:n,headSha:c})}},e[12]=n,e[13]=a,e[14]=v,e[15]=c,e[16]=t,e[17]=d,e[18]=m,e[19]=x,e[20]=o,e[21]=l,e[22]=y):y=e[22];const C=b&&!!a&&!!c&&!!f;let N;return e[23]!==A||e[24]!==y||e[25]!==C?(N={queryKey:A,queryFn:y,enabled:C,staleTime:1/0},e[23]=A,e[24]=y,e[25]=C,e[26]=N):N=e[26],Te(N)}function vt(i){const e=k.c(14),{diffQuery:t}=i,r=L();if(t.isLoading){let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsx(Ie,{className:"h-4 w-4"}),e[0]=n):n=e[0];let c;e[1]!==r?(c=r("thread.changesTab.loadingChanges"),e[1]=r,e[2]=c):c=e[2];let m;return e[3]!==c?(m=s.jsxs("div",{className:"flex items-center justify-center gap-2 py-16 text-muted-foreground",children:[n,s.jsx("span",{className:"text-sm",children:c})]}),e[3]=c,e[4]=m):m=e[4],m}if(t.isError){let n;e[5]!==r?(n=r("thread.changesTab.couldntLoadPrChanges"),e[5]=r,e[6]=n):n=e[6];let c;return e[7]!==n?(c=s.jsx("div",{className:"py-10 text-sm text-destructive",children:n}),e[7]=n,e[8]=c):c=e[8],c}const l=t.data;let a;e[9]!==r?(a=r("thread.changesTab.noCommittedChanges"),e[9]=r,e[10]=a):a=e[10];let o;return e[11]!==t.data||e[12]!==a?(o=s.jsx(He,{diff:l,rowClassName:"px-0",emptyMessage:a}),e[11]=t.data,e[12]=a,e[13]=o):o=e[13],o}function yt(i){return[i?.summary?.trim(),i?.text?.trim()].filter(Boolean).join(`
|
|
2
2
|
|
|
3
3
|
`)}function Nt(i){const e=k.c(54),{pr:t,target:r,owner:l,repo:a}=i,{org:o}=Y(),n=Ye(),c=L();let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m=new Set,e[0]=m):m=e[0];const[f,d]=de.useState(m);let x;e[1]!==o.id||e[2]!==o.slug||e[3]!==l||e[4]!==t.head||e[5]!==a||e[6]!==r?(x={orgId:o.id,orgSlug:o.slug,target:r,owner:l,repo:a,branch:t.head},e[1]=o.id,e[2]=o.slug,e[3]=l,e[4]=t.head,e[5]=a,e[6]=r,e[7]=x):x=e[7];const p=Ze(x);let b;e[8]!==n||e[9]!==t.number?(b=h=>n.sendMessage({parts:[{type:"text",text:Ke({prNumber:t.number,checkName:h})}]}),e[8]=n,e[9]=t.number,e[10]=b):b=e[10];const g=b;let v;e[11]===Symbol.for("react.memo_cache_sentinel")?(v=h=>d(u=>{const j=new Set(u);return j.has(h)?j.delete(h):j.add(h),j}),e[11]=v):v=e[11];const A=v;if(p.isLoading){let h;e[12]!==c?(h=c("thread.checksTab.loadingChecks"),e[12]=c,e[13]=h):h=e[13];let u;return e[14]!==h?(u=s.jsx("div",{className:"text-sm text-muted-foreground",children:h}),e[14]=h,e[15]=u):u=e[15],u}if(p.isError){let h;e[16]!==c?(h=c("thread.checksTab.couldntLoadCheckRuns"),e[16]=c,e[17]=h):h=e[17];let u;e[18]!==h?(u=s.jsx("span",{children:h}),e[18]=h,e[19]=u):u=e[19];let j;e[20]!==p.error?(j=p.error?.message&&s.jsx("span",{className:"text-xs text-muted-foreground",children:p.error.message}),e[20]=p.error,e[21]=j):j=e[21];let _;return e[22]!==u||e[23]!==j?(_=s.jsxs("div",{className:"flex flex-col gap-1 text-sm text-destructive",children:[u,j]}),e[22]=u,e[23]=j,e[24]=_):_=e[24],_}let y;e[25]!==p.data?(y=p.data??[],e[25]=p.data,e[26]=y):y=e[26];const C=y;if(C.length===0){let h;e[27]!==c?(h=c("thread.checksTab.noCheckRunsOnPrHeadCommit"),e[27]=c,e[28]=h):h=e[28];let u;return e[29]!==h?(u=s.jsx("div",{className:"text-sm text-muted-foreground",children:h}),e[29]=h,e[30]=u):u=e[30],u}let N;if(e[31]!==n||e[32]!==C||e[33]!==f||e[34]!==o.id||e[35]!==o.slug||e[36]!==l||e[37]!==a||e[38]!==g||e[39]!==c||e[40]!==r){let h;e[42]!==n||e[43]!==f||e[44]!==o.id||e[45]!==o.slug||e[46]!==l||e[47]!==a||e[48]!==g||e[49]!==c||e[50]!==r?(h=u=>{const j=u.id??u.name,_=u.id!==null&&f.has(u.id);return s.jsxs("li",{className:"flex flex-col",children:[s.jsxs("div",{className:"flex items-center justify-between gap-2 rounded px-2 py-1.5 text-sm hover:bg-muted",children:[s.jsxs("button",{type:"button",disabled:u.id===null,onClick:()=>u.id!==null&&A(u.id),"aria-expanded":_,className:"flex min-w-0 flex-1 items-center gap-2 text-left",children:[s.jsx(me,{className:X("h-3.5 w-3.5 shrink-0 text-muted-foreground transition-transform",_&&"rotate-90")}),s.jsx(wt,{check:u}),s.jsx("span",{className:"truncate",children:u.name}),u.durationMs!=null&&s.jsx("span",{className:"text-xs text-muted-foreground",children:_t(u.durationMs)})]}),s.jsxs("span",{className:"flex shrink-0 items-center gap-1",children:[u.htmlUrl&&s.jsx("a",{href:u.htmlUrl,target:"_blank",rel:"noreferrer",className:"inline-flex h-7 items-center justify-center rounded px-2 text-xs text-muted-foreground hover:bg-background",title:c("thread.checksTab.viewRun"),children:s.jsx(W,{className:"h-3.5 w-3.5"})}),u.conclusion==="failure"&&s.jsx(ue,{size:"sm",variant:"ghost",disabled:n.isStreaming,onClick:()=>g(u.name),children:c("thread.checksTab.rerun")})]})]}),_&&s.jsx(Ct,{orgId:o.id,orgSlug:o.slug,target:r,owner:l,repo:a,checkRunId:u.id})]},j)},e[42]=n,e[43]=f,e[44]=o.id,e[45]=o.slug,e[46]=l,e[47]=a,e[48]=g,e[49]=c,e[50]=r,e[51]=h):h=e[51],N=C.map(h),e[31]=n,e[32]=C,e[33]=f,e[34]=o.id,e[35]=o.slug,e[36]=l,e[37]=a,e[38]=g,e[39]=c,e[40]=r,e[41]=N}else N=e[41];let w;return e[52]!==N?(w=s.jsx("ul",{className:"flex flex-col gap-0.5",children:N}),e[52]=N,e[53]=w):w=e[53],w}function Ct(i){const e=k.c(32);let t,r;e[0]!==i?({checkRunId:t,...r}=i,e[0]=i,e[1]=t,e[2]=r):(t=e[1],r=e[2]);const l=L();let a;e[3]!==t||e[4]!==r?(a={...r,checkRunId:t,enabled:!0},e[3]=t,e[4]=r,e[5]=a):a=e[5];const o=et(a);if(o.isLoading){let p;e[6]!==l?(p=l("thread.checksTab.loadingCheckDetail"),e[6]=l,e[7]=p):p=e[7];let b;return e[8]!==p?(b=s.jsx("div",{className:"px-7 py-2 text-xs text-muted-foreground",children:p}),e[8]=p,e[9]=b):b=e[9],b}if(o.isError){let p;e[10]!==l?(p=l("thread.checksTab.couldntLoadCheckDetail"),e[10]=l,e[11]=p):p=e[11];let b;e[12]!==p?(b=s.jsx("span",{children:p}),e[12]=p,e[13]=b):b=e[13];let g;e[14]!==o.error?(g=o.error?.message&&s.jsx("span",{className:"text-muted-foreground",children:o.error.message}),e[14]=o.error,e[15]=g):g=e[15];let v;return e[16]!==b||e[17]!==g?(v=s.jsxs("div",{className:"flex flex-col gap-1 px-7 py-2 text-xs text-destructive",children:[b,g]}),e[16]=b,e[17]=g,e[18]=v):v=e[18],v}const n=o.data;let c;e[19]!==n?(c=yt(n),e[19]=n,e[20]=c):c=e[20];const m=c;if(!m&&!n?.title){let p;e[21]!==l?(p=l("thread.checksTab.noCheckDetail"),e[21]=l,e[22]=p):p=e[22];let b;return e[23]!==p?(b=s.jsx("div",{className:"px-7 py-2 text-xs text-muted-foreground",children:p}),e[23]=p,e[24]=b):b=e[24],b}let f;e[25]!==n?(f=n?.title&&s.jsx("div",{className:"mb-1 text-xs font-medium text-muted-foreground",children:n.title}),e[25]=n,e[26]=f):f=e[26];let d;e[27]!==m?(d=m&&s.jsx(Ue,{className:"max-w-none text-sm",children:m}),e[27]=m,e[28]=d):d=e[28];let x;return e[29]!==f||e[30]!==d?(x=s.jsxs("div",{className:"px-7 pb-3 pt-1 text-sm",children:[f,d]}),e[29]=f,e[30]=d,e[31]=x):x=e[31],x}function wt(i){const e=k.c(14),{check:t}=i,r=L();if(t.status!=="completed"){let o;e[0]!==r?(o=r("thread.checksTab.inProgress"),e[0]=r,e[1]=o):o=e[1];let n;return e[2]!==o?(n=s.jsx("span",{className:"text-muted-foreground","aria-label":o,children:"○"}),e[2]=o,e[3]=n):n=e[3],n}if(t.conclusion==="success"){let o;e[4]!==r?(o=r("thread.checksTab.success"),e[4]=r,e[5]=o):o=e[5];let n;return e[6]!==o?(n=s.jsx("span",{className:"text-success","aria-label":o,children:"✓"}),e[6]=o,e[7]=n):n=e[7],n}if(t.conclusion==="failure"){let o;e[8]!==r?(o=r("thread.checksTab.failure"),e[8]=r,e[9]=o):o=e[9];let n;return e[10]!==o?(n=s.jsx("span",{className:"text-destructive","aria-label":o,children:"✗"}),e[10]=o,e[11]=n):n=e[11],n}const l=t.conclusion??"—";let a;return e[12]!==l?(a=s.jsx("span",{className:"text-muted-foreground","aria-label":l,children:"—"}),e[12]=l,e[13]=a):a=e[13],a}function _t(i){const e=Math.round(i/1e3);return e<60?`${e}s`:`${Math.round(e/60)}m`}var D="Accordion",At=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[ne,kt,St]=Pe(D),[Z]=Re(D,[St,he]),ie=he(),ge=P.forwardRef((i,e)=>{const{type:t,...r}=i,l=r,a=r;return s.jsx(ne.Provider,{scope:i.__scopeAccordion,children:t==="multiple"?s.jsx(Rt,{...a,ref:e}):s.jsx(Pt,{...l,ref:e})})});ge.displayName=D;var[be,Tt]=Z(D),[je,It]=Z(D,{collapsible:!1}),Pt=P.forwardRef((i,e)=>{const{value:t,defaultValue:r,onValueChange:l=()=>{},collapsible:a=!1,...o}=i,[n,c]=pe({prop:t,defaultProp:r??"",onChange:l,caller:D});return s.jsx(be,{scope:i.__scopeAccordion,value:P.useMemo(()=>n?[n]:[],[n]),onItemOpen:c,onItemClose:P.useCallback(()=>a&&c(""),[a,c]),children:s.jsx(je,{scope:i.__scopeAccordion,collapsible:a,children:s.jsx(ve,{...o,ref:e})})})}),Rt=P.forwardRef((i,e)=>{const{value:t,defaultValue:r,onValueChange:l=()=>{},...a}=i,[o,n]=pe({prop:t,defaultProp:r??[],onChange:l,caller:D}),c=P.useCallback(f=>n((d=[])=>[...d,f]),[n]),m=P.useCallback(f=>n((d=[])=>d.filter(x=>x!==f)),[n]);return s.jsx(be,{scope:i.__scopeAccordion,value:o,onItemOpen:c,onItemClose:m,children:s.jsx(je,{scope:i.__scopeAccordion,collapsible:!0,children:s.jsx(ve,{...a,ref:e})})})}),[Et,ee]=Z(D),ve=P.forwardRef((i,e)=>{const{__scopeAccordion:t,disabled:r,dir:l,orientation:a="vertical",...o}=i,n=P.useRef(null),c=Ee(n,e),m=kt(t),d=Me(l)==="ltr",x=$e(i.onKeyDown,p=>{if(!At.includes(p.key))return;const b=p.target,g=m().filter(j=>!j.ref.current?.disabled),v=g.findIndex(j=>j.ref.current===b),A=g.length;if(v===-1)return;p.preventDefault();let y=v;const C=0,N=A-1,w=()=>{y=v+1,y>N&&(y=C)},h=()=>{y=v-1,y<C&&(y=N)};switch(p.key){case"Home":y=C;break;case"End":y=N;break;case"ArrowRight":a==="horizontal"&&(d?w():h());break;case"ArrowDown":a==="vertical"&&w();break;case"ArrowLeft":a==="horizontal"&&(d?h():w());break;case"ArrowUp":a==="vertical"&&h();break}const u=y%A;g[u].ref.current?.focus()});return s.jsx(Et,{scope:t,disabled:r,direction:l,orientation:a,children:s.jsx(ne.Slot,{scope:t,children:s.jsx(fe.div,{...o,"data-orientation":a,ref:c,onKeyDown:r?void 0:x})})})}),J="AccordionItem",[Mt,le]=Z(J),ye=P.forwardRef((i,e)=>{const{__scopeAccordion:t,value:r,...l}=i,a=ee(J,t),o=Tt(J,t),n=ie(t),c=De(),m=r&&o.value.includes(r)||!1,f=a.disabled||i.disabled;return s.jsx(Mt,{scope:t,open:m,disabled:f,triggerId:c,children:s.jsx(st,{"data-orientation":a.orientation,"data-state":ke(m),...n,...l,ref:e,disabled:f,open:m,onOpenChange:d=>{d?o.onItemOpen(r):o.onItemClose(r)}})})});ye.displayName=J;var Ne="AccordionHeader",Ce=P.forwardRef((i,e)=>{const{__scopeAccordion:t,...r}=i,l=ee(D,t),a=le(Ne,t);return s.jsx(fe.h3,{"data-orientation":l.orientation,"data-state":ke(a.open),"data-disabled":a.disabled?"":void 0,...r,ref:e})});Ce.displayName=Ne;var oe="AccordionTrigger",we=P.forwardRef((i,e)=>{const{__scopeAccordion:t,...r}=i,l=ee(D,t),a=le(oe,t),o=It(oe,t),n=ie(t);return s.jsx(ne.ItemSlot,{scope:t,children:s.jsx(ot,{"aria-disabled":a.open&&!o.collapsible||void 0,"data-orientation":l.orientation,id:a.triggerId,...n,...r,ref:e})})});we.displayName=oe;var _e="AccordionContent",Ae=P.forwardRef((i,e)=>{const{__scopeAccordion:t,...r}=i,l=ee(D,t),a=le(_e,t),o=ie(t);return s.jsx(nt,{role:"region","aria-labelledby":a.triggerId,"data-orientation":l.orientation,...o,...r,ref:e,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...i.style}})});Ae.displayName=_e;function ke(i){return i?"open":"closed"}var $t=ge,Dt=ye,Ft=Ce,Lt=we,Ot=Ae;function Gt(i){const e=k.c(4);let t;e[0]!==i?({...t}=i,e[0]=i,e[1]=t):t=e[1];let r;return e[2]!==t?(r=s.jsx($t,{"data-slot":"accordion",...t}),e[2]=t,e[3]=r):r=e[3],r}function Bt(i){const e=k.c(8);let t,r;e[0]!==i?({className:t,...r}=i,e[0]=i,e[1]=t,e[2]=r):(t=e[1],r=e[2]);let l;e[3]!==t?(l=X("border-b last:border-b-0",t),e[3]=t,e[4]=l):l=e[4];let a;return e[5]!==r||e[6]!==l?(a=s.jsx(Dt,{"data-slot":"accordion-item",className:l,...r}),e[5]=r,e[6]=l,e[7]=a):a=e[7],a}function Vt(i){const e=k.c(11);let t,r,l;e[0]!==i?({className:r,children:t,...l}=i,e[0]=i,e[1]=t,e[2]=r,e[3]=l):(t=e[1],r=e[2],l=e[3]);let a;e[4]!==r?(a=X("focus-visible:border-ring focus-visible:ring-ring/20 flex flex-1 items-center justify-between gap-4 py-4 text-left text-sm font-medium transition-all outline-none hover:bg-accent/50 focus-visible:ring-[2px] disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>svg]:rotate-90",r),e[4]=r,e[5]=a):a=e[5];let o;e[6]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx(me,{className:"text-muted-foreground pointer-events-none size-4 shrink-0 transition-transform duration-200"}),e[6]=o):o=e[6];let n;return e[7]!==t||e[8]!==l||e[9]!==a?(n=s.jsx(Ft,{className:"flex",children:s.jsxs(Lt,{"data-slot":"accordion-trigger",className:a,...l,children:[t,o]})}),e[7]=t,e[8]=l,e[9]=a,e[10]=n):n=e[10],n}function Ut(i){const e=k.c(12);let t,r,l;e[0]!==i?({className:r,children:t,...l}=i,e[0]=i,e[1]=t,e[2]=r,e[3]=l):(t=e[1],r=e[2],l=e[3]);let a;e[4]!==r?(a=X("pt-0 pb-4",r),e[4]=r,e[5]=a):a=e[5];let o;e[6]!==t||e[7]!==a?(o=s.jsx("div",{className:a,children:t}),e[6]=t,e[7]=a,e[8]=o):o=e[8];let n;return e[9]!==l||e[10]!==o?(n=s.jsx(Ot,{"data-slot":"accordion-content",className:"data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm",...l,children:o}),e[9]=l,e[10]=o,e[11]=n):n=e[11],n}function Ht(i){const e=k.c(10),{comments:t,isLoading:r,isError:l}=i;if(r||l||!t||t.length===0)return null;const a=t.length===1?"":"s";let o;e[0]!==t.length||e[1]!==a?(o=s.jsxs(Vt,{className:"py-3 text-sm font-medium",children:[t.length," comment",a]}),e[0]=t.length,e[1]=a,e[2]=o):o=e[2];let n;e[3]!==t?(n=t.map(Kt),e[3]=t,e[4]=n):n=e[4];let c;e[5]!==n?(c=s.jsx(Ut,{className:"space-y-3 pb-3",children:n}),e[5]=n,e[6]=c):c=e[6];let m;return e[7]!==o||e[8]!==c?(m=s.jsx(Gt,{type:"single",collapsible:!0,className:"border-t border-border",children:s.jsxs(Bt,{value:"comments",className:"border-b-0",children:[o,c]})}),e[7]=o,e[8]=c,e[9]=m):m=e[9],m}function Kt(i){return s.jsxs("div",{className:"rounded-md border border-border p-3",children:[s.jsxs("div",{className:"mb-1 text-xs text-muted-foreground",children:["@",i.author," · ",Qt(i.createdAt)]}),s.jsx(se,{id:`pr-comment-${i.id}`,text:K(i.body)})]},i.id)}function Qt(i){if(!i)return"";const e=new Date(i).getTime();if(!Number.isFinite(e))return"";const t=Date.now()-e;if(t<0)return"just now";const r=Math.floor(t/864e5);if(r>0)return`${r}d ago`;const l=Math.floor(t/36e5);if(l>0)return`${l}h ago`;const a=Math.floor(t/6e4);return`${Math.max(1,a)}m ago`}function zt(i){const e=k.c(19),{pr:t,target:r,owner:l,repo:a}=i,{org:o}=Y();let n;e[0]!==o.id||e[1]!==o.slug||e[2]!==l||e[3]!==t.head||e[4]!==a||e[5]!==r?(n={orgId:o.id,orgSlug:o.slug,target:r,owner:l,repo:a,branch:t.head},e[0]=o.id,e[1]=o.slug,e[2]=l,e[3]=t.head,e[4]=a,e[5]=r,e[6]=n):n=e[6];const c=tt(n);let m;e[7]!==t.body||e[8]!==t.number?(m=t.body&&s.jsx("div",{className:"text-sm",children:s.jsx(se,{id:`pr-body-${t.number}`,text:K(t.body)})}),e[7]=t.body,e[8]=t.number,e[9]=m):m=e[9];let f;e[10]!==c.data?(f=c.data??[],e[10]=c.data,e[11]=f):f=e[11];let d;e[12]!==c.isError||e[13]!==c.isLoading||e[14]!==f?(d=s.jsx(Ht,{comments:f,isLoading:c.isLoading,isError:c.isError}),e[12]=c.isError,e[13]=c.isLoading,e[14]=f,e[15]=d):d=e[15];let x;return e[16]!==m||e[17]!==d?(x=s.jsxs("div",{className:"space-y-8",children:[m,d]}),e[16]=m,e[17]=d,e[18]=x):x=e[18],x}function qt(i){const e=k.c(71),{pr:t,virtualMcpId:r,branch:l,target:a,owner:o,repo:n}=i,{org:c}=Y(),[m,f]=de.useState("changes"),d=Xe()?.taskId??null,x=a.connectionId??"",p=m==="changes";let b;e[0]!==l||e[1]!==c.id||e[2]!==c.slug||e[3]!==o||e[4]!==t.base||e[5]!==t.headSha||e[6]!==t.number||e[7]!==n||e[8]!==d||e[9]!==x||e[10]!==p||e[11]!==r?(b={orgSlug:c.slug,orgId:c.id,virtualMcpId:r,branch:l,threadId:d,base:t.base,headSha:t.headSha,pullNumber:t.number,connectionId:x,owner:o,repo:n,enabled:p},e[0]=l,e[1]=c.id,e[2]=c.slug,e[3]=o,e[4]=t.base,e[5]=t.headSha,e[6]=t.number,e[7]=n,e[8]=d,e[9]=x,e[10]=p,e[11]=r,e[12]=b):b=e[12];const g=jt(b);let v;e[13]!==g||e[14]!==t.changedFiles?(v=t.changedFiles??(g.data?xe(g.data):void 0),e[13]=g,e[14]=t.changedFiles,e[15]=v):v=e[15];const A=v;let y;e[16]!==t.title?(y=K(t.title),e[16]=t.title,e[17]=y):y=e[17];let C;e[18]!==y?(C=s.jsx("h1",{className:"text-lg font-semibold leading-tight",children:y}),e[18]=y,e[19]=C):C=e[19];const N=`Open change request #${t.number}`;let w;e[20]===Symbol.for("react.memo_cache_sentinel")?(w=s.jsx(W,{className:"h-3.5 w-3.5"}),e[20]=w):w=e[20];let h;e[21]!==t.htmlUrl||e[22]!==t.number||e[23]!==N?(h=s.jsxs("a",{href:t.htmlUrl,target:"_blank",rel:"noreferrer","aria-label":N,className:"inline-flex items-center gap-1 hover:text-foreground",children:["PR #",t.number,w]}),e[21]=t.htmlUrl,e[22]=t.number,e[23]=N,e[24]=h):h=e[24];let u;e[25]!==t.author?(u=t.author?s.jsxs(s.Fragment,{children:[s.jsx("span",{children:"·"}),s.jsxs("span",{children:["@",t.author]})]}):null,e[25]=t.author,e[26]=u):u=e[26];let j;e[27]===Symbol.for("react.memo_cache_sentinel")?(j=s.jsx("span",{children:"·"}),e[27]=j):j=e[27];let _;e[28]!==t.base?(_=s.jsx("span",{className:"font-mono text-xs",children:t.base}),e[28]=t.base,e[29]=_):_=e[29];let R;e[30]===Symbol.for("react.memo_cache_sentinel")?(R=s.jsx("span",{children:"←"}),e[30]=R):R=e[30];let S;e[31]!==t.head?(S=s.jsx("span",{className:"font-mono text-xs",children:t.head}),e[31]=t.head,e[32]=S):S=e[32];let T;e[33]!==h||e[34]!==u||e[35]!==_||e[36]!==S?(T=s.jsxs("div",{className:"flex flex-wrap items-center gap-x-1.5 text-sm text-muted-foreground",children:[h,u,j,_,R,S]}),e[33]=h,e[34]=u,e[35]=_,e[36]=S,e[37]=T):T=e[37];let I;e[38]!==T||e[39]!==C?(I=s.jsx("div",{className:"shrink-0 space-y-3 pb-4",children:s.jsxs("div",{className:"space-y-1",children:[C,T]})}),e[38]=T,e[39]=C,e[40]=I):I=e[40];let E;e[41]===Symbol.for("react.memo_cache_sentinel")?(E=Se=>f(Se),e[41]=E):E=e[41];let M;e[42]===Symbol.for("react.memo_cache_sentinel")?(M=s.jsx(te,{value:"description",className:"px-3 text-xs",children:"Description"}),e[42]=M):M=e[42];const F=A!==void 0?` ${A}`:"";let $;e[43]!==F?($=s.jsxs(te,{value:"changes",className:"px-3 text-xs",children:["Changes",F]}),e[43]=F,e[44]=$):$=e[44];let Q;e[45]===Symbol.for("react.memo_cache_sentinel")?(Q=s.jsx(te,{value:"checks",className:"px-3 text-xs",children:"Checks"}),e[45]=Q):Q=e[45];let O;e[46]!==$?(O=s.jsxs(Qe,{className:"h-8 w-fit max-w-[600px] shrink-0",variant:"pill",children:[M,$,Q]}),e[46]=$,e[47]=O):O=e[47];let G;e[48]!==o||e[49]!==t||e[50]!==n||e[51]!==a?(G=s.jsx(re,{value:"description",className:"mt-0",children:s.jsx(zt,{pr:t,target:a,owner:o,repo:n})}),e[48]=o,e[49]=t,e[50]=n,e[51]=a,e[52]=G):G=e[52];let B;e[53]!==g?(B=s.jsx(re,{value:"changes",className:"mt-0",children:s.jsx(vt,{diffQuery:g})}),e[53]=g,e[54]=B):B=e[54];let V;e[55]!==o||e[56]!==t||e[57]!==n||e[58]!==a?(V=s.jsx(re,{value:"checks",className:"mt-0",children:s.jsx(Nt,{pr:t,target:a,owner:o,repo:n})}),e[55]=o,e[56]=t,e[57]=n,e[58]=a,e[59]=V):V=e[59];let U;e[60]!==G||e[61]!==B||e[62]!==V?(U=s.jsxs("div",{className:"min-h-0 flex-1 overflow-y-auto pt-5",children:[G,B,V]}),e[60]=G,e[61]=B,e[62]=V,e[63]=U):U=e[63];let H;e[64]!==m||e[65]!==O||e[66]!==U?(H=s.jsxs(ze,{value:m,onValueChange:E,className:"flex min-h-0 flex-1 flex-col",children:[O,U]}),e[64]=m,e[65]=O,e[66]=U,e[67]=H):H=e[67];let z;return e[68]!==I||e[69]!==H?(z=s.jsxs("div",{className:"flex min-h-0 flex-1 flex-col",children:[I,H]}),e[68]=I,e[69]=H,e[70]=z):z=e[70],z}function Jt(i){const e=k.c(11),{pr:t}=i,r=L(),l=t.htmlUrl,a=String(t.number);let o;e[0]!==r||e[1]!==a?(o=r("thread.gitTab.openPrAriaLabel",{number:a}),e[0]=r,e[1]=a,e[2]=o):o=e[2];const n=String(t.number);let c;e[3]!==r||e[4]!==n?(c=r("thread.gitTab.prNumber",{number:n}),e[3]=r,e[4]=n,e[5]=c):c=e[5];let m;e[6]===Symbol.for("react.memo_cache_sentinel")?(m=s.jsx(W,{className:"h-4 w-4 text-muted-foreground"}),e[6]=m):m=e[6];let f;return e[7]!==t.htmlUrl||e[8]!==o||e[9]!==c?(f=s.jsx("div",{className:"flex h-12 items-center border-b border-border px-4 shrink-0",children:s.jsxs("a",{href:l,target:"_blank",rel:"noreferrer","aria-label":o,className:"inline-flex items-center gap-1.5 text-base font-medium text-foreground hover:underline",children:[c,m]})}),e[7]=t.htmlUrl,e[8]=o,e[9]=c,e[10]=f):f=e[10],f}function Yt(i){const e=k.c(27),{virtualMcpId:t}=i,r=L(),{org:l}=Y(),a=Ge(t),{currentBranch:o}=We(),n=a?.metadata?.repository??null;let c,m;if(e[0]!==n?(m=Be(n),c=!n||!Ve(m),e[0]=n,e[1]=c,e[2]=m):(c=e[1],m=e[2]),c){let d;e[3]!==r?(d=r("thread.gitTab.notLinkedToGithub"),e[3]=r,e[4]=d):d=e[4];let x;return e[5]!==d?(x=s.jsx("div",{className:"flex h-full items-center justify-center p-8 text-sm text-muted-foreground",children:d}),e[5]=d,e[6]=x):x=e[6],x}if(!o){let d;e[7]===Symbol.for("react.memo_cache_sentinel")?(d=s.jsx(Fe,{className:"h-6 w-6 text-muted-foreground"}),e[7]=d):d=e[7];let x;e[8]!==r?(x=r("thread.gitTab.noBranchSelected"),e[8]=r,e[9]=x):x=e[9];let p;e[10]!==x?(p=s.jsx("div",{className:"text-muted-foreground",children:x}),e[10]=x,e[11]=p):p=e[11];let b;e[12]!==r?(b=r("thread.gitTab.pickBranchForPrStatus"),e[12]=r,e[13]=b):b=e[13];let g;e[14]!==b?(g=s.jsx("div",{className:"text-xs text-muted-foreground",children:b}),e[14]=b,e[15]=g):g=e[15];let v;return e[16]!==p||e[17]!==g?(v=s.jsxs("div",{className:"flex h-full flex-col items-center justify-center gap-3 p-8 text-sm",children:[d,p,g]}),e[16]=p,e[17]=g,e[18]=v):v=e[18],v}let f;return e[19]!==o||e[20]!==l.id||e[21]!==l.slug||e[22]!==n.name||e[23]!==n.owner||e[24]!==m||e[25]!==t?(f=s.jsx(Xt,{orgId:l.id,orgSlug:l.slug,virtualMcpId:t,target:m,owner:n.owner,repo:n.name,branch:o}),e[19]=o,e[20]=l.id,e[21]=l.slug,e[22]=n.name,e[23]=n.owner,e[24]=m,e[25]=t,e[26]=f):f=e[26],f}function Xt(i){const e=k.c(69),t=L(),{orgId:r,orgSlug:l,virtualMcpId:a,target:o,owner:n,repo:c,branch:m}=i;let f;e[0]!==m||e[1]!==r||e[2]!==l||e[3]!==n||e[4]!==c||e[5]!==o?(f={orgId:r,orgSlug:l,target:o,owner:n,repo:c,branch:m},e[0]=m,e[1]=r,e[2]=l,e[3]=n,e[4]=c,e[5]=o,e[6]=f):f=e[6];const{data:d,isLoading:x,isError:p}=rt(f),b=Wt;if(x){let u;e[7]!==t?(u=t("thread.gitTab.loadingPrState"),e[7]=t,e[8]=u):u=e[8];let j;return e[9]!==u?(j=s.jsx("div",{className:"p-4 text-sm text-muted-foreground",children:u}),e[9]=u,e[10]=j):j=e[10],j}if(p){let u;e[11]!==t?(u=t("thread.gitTab.couldNotLoadPrState"),e[11]=t,e[12]=u):u=e[12];let j;return e[13]!==u?(j=s.jsx("div",{className:"p-4 text-sm text-destructive",children:u}),e[13]=u,e[14]=j):j=e[14],j}const g=`https://github.com/${n}/${c}/tree/${m}`;if(d&&d.state==="closed"){let u;e[15]!==d?(u=s.jsx(Jt,{pr:d}),e[15]=d,e[16]=u):u=e[16];let j;e[17]!==d.merged||e[18]!==t?(j=d.merged?t("thread.gitTab.merged"):t("thread.gitTab.closed"),e[17]=d.merged,e[18]=t,e[19]=j):j=e[19];let _;e[20]!==d.base||e[21]!==t?(_=t("thread.gitTab.into",{base:d.base}),e[20]=d.base,e[21]=t,e[22]=_):_=e[22];let R;e[23]!==d.mergedAt?(R=d.mergedAt&&s.jsxs(s.Fragment,{children:[" · ",new Date(d.mergedAt).toLocaleDateString()]}),e[23]=d.mergedAt,e[24]=R):R=e[24];let S;e[25]!==d.author||e[26]!==t?(S=d.author&&s.jsxs(s.Fragment,{children:[" · ",t("thread.gitTab.by",{author:d.author})]}),e[25]=d.author,e[26]=t,e[27]=S):S=e[27];let T;e[28]!==j||e[29]!==_||e[30]!==R||e[31]!==S?(T=s.jsxs("div",{className:"text-sm text-success",children:[j," ",_,R,S]}),e[28]=j,e[29]=_,e[30]=R,e[31]=S,e[32]=T):T=e[32];let I;e[33]!==d.title?(I=K(d.title),e[33]=d.title,e[34]=I):I=e[34];let E;e[35]!==I?(E=s.jsx("h1",{className:"text-lg font-semibold",children:I}),e[35]=I,e[36]=E):E=e[36];let M;e[37]!==d.body||e[38]!==d.number?(M=d.body&&s.jsx("div",{className:"rounded-md border border-border bg-muted/30 p-3 text-sm",children:s.jsx(se,{id:`pr-body-${d.number}`,text:K(d.body)})}),e[37]=d.body,e[38]=d.number,e[39]=M):M=e[39];let F;e[40]!==T||e[41]!==E||e[42]!==M?(F=s.jsxs("div",{className:"flex flex-col gap-4 p-4 overflow-auto",children:[T,E,M]}),e[40]=T,e[41]=E,e[42]=M,e[43]=F):F=e[43];let $;return e[44]!==u||e[45]!==F?($=s.jsxs("div",{className:"flex min-h-0 flex-1 flex-col",children:[u,F]}),e[44]=u,e[45]=F,e[46]=$):$=e[46],$}if(d&&d.state==="open"){let u;return e[47]!==m||e[48]!==n||e[49]!==d||e[50]!==c||e[51]!==o||e[52]!==a?(u=s.jsx("div",{className:"flex min-h-0 flex-1 flex-col overflow-hidden",children:s.jsx("div",{className:"flex min-h-0 w-full flex-1 flex-col px-6 py-5",children:s.jsx(qt,{pr:d,virtualMcpId:a,branch:m,target:o,owner:n,repo:c})})}),e[47]=m,e[48]=n,e[49]=d,e[50]=c,e[51]=o,e[52]=a,e[53]=u):u=e[53],u}let v;e[54]!==t?(v=t("thread.gitTab.noPrYet"),e[54]=t,e[55]=v):v=e[55];let A;e[56]!==v?(A=s.jsx("div",{className:"rounded-md border border-border bg-muted/30 p-4 text-sm",children:v}),e[56]=v,e[57]=A):A=e[57];let y;e[58]!==g?(y=()=>b(g),e[58]=g,e[59]=y):y=e[59];let C;e[60]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx(W,{className:"mr-1.5 h-4 w-4"}),e[60]=C):C=e[60];let N;e[61]!==t?(N=t("thread.gitTab.openBranchOnGithub"),e[61]=t,e[62]=N):N=e[62];let w;e[63]!==y||e[64]!==N?(w=s.jsx("div",{className:"flex items-center gap-2",children:s.jsxs(ue,{size:"sm",variant:"outline",onClick:y,children:[C,N]})}),e[63]=y,e[64]=N,e[65]=w):w=e[65];let h;return e[66]!==A||e[67]!==w?(h=s.jsxs("div",{className:"flex flex-col gap-4 p-4",children:[A,w]}),e[66]=A,e[67]=w,e[68]=h):h=e[68],h}function Wt(i){window.open(i,"_blank","noopener,noreferrer")}function Zt(){const i=k.c(2),e=it();let t;return i[0]!==e?(t=s.jsx(Oe,{tabId:"git",children:s.jsx(Yt,{virtualMcpId:e})}),i[0]=e,i[1]=t):t=i[1],t}function qs(){const i=k.c(1);let e;return i[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(Le.Content,{children:s.jsx(Zt,{})}),i[0]=e):e=i[0],e}export{qs as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as Z,j as t,l as xt,b as Ae,aS as dt,e_ as ps,ak as ns,ec as Ts,t as ce,o as bt,r as ee,e as lt,B as Qe,m as ct,K as Xe,ab as _t,a7 as Wt,X as js,n as Jt,fn as Ps}from"./index-B1zctMWM.js";import{C as vs}from"./index-_Pfw1M40.js";import{n as kt}from"./LinkExternal01-ByTglQMD.js";import{B as Re}from"./badge-B0eiYJhc.js";import{E as Ze}from"./empty-state-Lw6BWO66.js";import{a as ys}from"./repository-binding-DB3Rsfan.js";import{r as Ss}from"./site-slug-DebpOoQq.js";import{i as Ns}from"./AlertCircle-Bx6Xy-Kw.js";import{bn as Cs,bo as is,K as Ds,aA as ws,bp as $s,b as Et,aB as Xt,W as Yt,b7 as Ls}from"./agent-icon-Plx0vVQZ.js";import{h as gt}from"./UserSquare-DubBIV3t.js";import{i as _s}from"./ZoomOut-o5Bj_0k0.js";import{A as ls,a as as,b as os,c as rs,g as cs,d as ms,e as ds,f as fs}from"./alert-dialog-CRVM-23V.js";import{I as et}from"./icon-button-BpPbhU8u.js";import{S as ks,c as Es,a as Rs,b as Fs}from"./sheet-BHMUXURV.js";import{T as As,b as nt,c as Fe,e as Rt,a as Ft,d as At}from"./table-vIpu14O-.js";import{a as zs}from"./Copy01-1J_cPh43.js";import{a as Vt,b as Ht,C as Vs}from"./collapsible-taXF9Vin.js";import{s as Pt}from"./Plus-jU4D0ULX.js";import{s as vt}from"./Trash01-CfWaytgc.js";import{c as yt,d as St,e as Nt,b as Ct,D as Dt}from"./dialog-DUkVOZIE.js";import{I as it}from"./input-B3HVl7By.js";import{L as Ge}from"./label-Be_7Vms5.js";import{T as Hs,a as Bs,b as Os}from"./tooltip-CmsIn1_T.js";import{b as qs}from"./Tool01-DQZj0rVc.js";import{s as Ms}from"./Image01-VqGHD62D.js";import{a as Bt,b as Ot,c as ft,d as qt,S as Mt}from"./select-CCPnfgQ9.js";import{i as Is}from"./LinkBroken01-DLTNdGdq.js";import{S as Ks}from"./settings-tab-DRo0WDQp.js";import{b as Qs}from"./use-organization-settings-B-_PpufY.js";import{b as Us}from"./thread-route-CMTlmdB2.js";import"./use-mobile-CUG36tjm.js";import"./thread-button-CBArUpXO.js";import"./use-chat-layout-state-B1ZVGaLS.js";import"./use-file-configs-BJx6-ZW4.js";import"./use-panel-navigate-CuKDZSXf.js";import"./use-project-scope-B1N6dPlK.js";import"./thread-intent-swCQbScV.js";import"./use-mcp-client-BCOmh6mH.js";import"./auth-BhL4Ae7M.js";import"./backoff-8mStPHYB.js";import"./task-board-BMQrxTue.js";import"./schema-CtVpxfN8.js";import"./slugify-CEUa2lfQ.js";import"./toolbar-icon-button-BR_iVDC5.js";import"./shell-layout-XTP1Kn60.js";import"./avatar-ZtrZA-xC.js";import"./User01-BJgSr0na.js";import"./Building02-qqUg_lk7.js";import"./XClose-B5gtMDn3.js";import"./download-app-dialog-VBK5SfsW.js";import"./Check-BhHmW1CL.js";import"./CheckCircle-DQ_Iwx7G.js";import"./Monitor01-CjCwBipo.js";import"./use-clock-tick-BsJNcY-e.js";import"./command-Dj5wxXJe.js";import"./index-CKkIU_55.js";import"./SearchMd-yUpDH67q.js";import"./integration-icon-B97YfXXZ.js";import"./project-icon-0knrxIOw.js";import"./new-project-dialog-BMehfxLv.js";import"./ArrowLeft-BBlLaPEb.js";import"./repository-import-picker-DyQqkMVo.js";import"./use-navigate-to-agent-Cv939dl9.js";import"./repository-picker-BhN42NYE.js";import"./useInfiniteQuery-DRaKStQa.js";import"./infiniteQueryObserver-BBgKyTli.js";import"./collection-search-De8chpSh.js";import"./ShoppingBag01-BnqPHk8-.js";import"./use-debounced-value-BJOL8Gwj.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-BhtMSUK8.js";import"./autosend-CtvAncuN.js";import"./use-org-sso-554XjjGQ.js";import"./resizable-Cl5uhslg.js";import"./ArrowUp-Dr4dZUTV.js";import"./ChevronUp-C6nGgzcV.js";import"./CreditCard01-CZJLSW5h.js";import"./DotsVertical-DMzCTdNT.js";import"./Palette-DItfN1RT.js";import"./Key01-3kquwPFB.js";import"./Link01-ZJZ8YMCs.js";import"./Sun-G5YUTpKk.js";import"./Upload01-ca0GgR0P.js";import"./Users01-BI4qzwEi.js";import"./X-4SjHAUB6.js";import"./index-CazcJ_7a.js";import"./extract-connection-data-BqvnWkg5.js";import"./metadata-D72DunRR.js";import"./connection-DCZz5J1M.js";import"./chat-context-CW-2SJ9g.js";import"./use-decopilot-events-B7N8IjI0.js";import"./use-ai-providers-DKY0H66j.js";import"./location-DPIrGNp7.js";import"./build-improve-prompt-doc-Cb05TlMk.js";import"./empty-state-CGgBiEoz.js";import"./use-date-fns-locale-DtLNXwQQ.js";import"./differenceInSeconds-C3x8sHUj.js";import"./use-connection-o6IaHrCa.js";import"./mcp-oauth-Dt9pIBq5.js";import"./textarea-C-PwJiry.js";import"./use-debounced-autosave-C94tXEES.js";import"./add-connection-dialog-C9teNzj3.js";import"./connection-card-DaZTNpcS.js";import"./connection-slug-CITJ0kGN.js";import"./drawer-BE8-rjnv.js";import"./form-esFIz8cn.js";import"./connection-form-helpers-Dyc97_iQ.js";import"./authenticate-and-persist-oauth-CM_sd9mo.js";import"./collection-tabs-2Nn5b0UJ.js";import"./use-infinite-scroll-D564AByM.js";import"./useSuspenseInfiniteQuery-WHFkobEh.js";import"./file-type-icon-CideAigq.js";import"./use-org-fs-CfcB8IFl.js";import"./checkbox-Cs5VXlL7.js";import"./search-input-B7esxZLr.js";import"./use-mcp-auth-status-BPJMjKJu.js";import"./types-Dnj2Xk6p.js";import"./use-mcp-tools-isgPo0N2.js";import"./use-mcp-prompts-DsQz4qyp.js";import"./utils-CVEq3hMx.js";import"./switch-Bj8bJ2hL.js";import"./popover-DwQza7Ap.js";import"./scroll-area-DTVFcTe4.js";import"./optimistic-project-sidebar-views-DDETX0mx.js";import"./virtual-mcp-BkcbnGY4.js";import"./sandbox-url-D3mC8qhT.js";import"./secret-picker-BV1iDD76.js";import"./use-secrets-Bpfmfnyi.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./serial-task-queue-CGOeQgpr.js";function Lt(r,e){return r.name===e.name&&(r.scope??"runtime")===e.scope}function mt(r,e){if(Array.isArray(r))return r;if(r&&typeof r=="object"){const o=r[e];if(Array.isArray(o))return o}return[]}function zt(r){return r==="deco-deno"?"Deco Deno":r==="deco-tanstack"?"Deco TanStack":r??null}function Ws(r){const e=(r??"").toLowerCase();return e.includes("ready")||e.includes("success")||e.includes("active")?"success":e.includes("fail")||e.includes("error")?"destructive":e.includes("build")||e.includes("pend")||e.includes("progress")?"warning":"secondary"}function Gt(r){if(!r)return"—";const e=new Date(r).getTime();if(Number.isNaN(e))return"—";const o=Math.round((Date.now()-e)/1e3),l=new Intl.RelativeTimeFormat(void 0,{numeric:"auto"}),a=[["year",31536e3],["month",2592e3],["day",86400],["hour",3600],["minute",60]];for(const[i,c]of a)if(Math.abs(o)>=c)return l.format(-Math.round(o/c),i);return l.format(-o,"second")}function Js(r){if(r==null||!Number.isFinite(r))return"—";if(r<1e3)return`${Math.round(r)}ms`;const e=r/1e3;if(e<60)return`${e.toFixed(e>=10?0:1)}s`;const o=Math.round(e);return`${Math.floor(o/60)}m ${o%60}s`}class It extends Error{constructor(e,o){super(e),this.status=o}status}function jt(r){return r instanceof It&&r.status===401}function rt(r){return r instanceof Error?r.message:String(r)}function Xs(r){const e=r.trim();if(!e)return null;const l=(e.endsWith(".")?e.slice(0,-1):e).split(".");if(l.length<2)return"Domain must include a TLD (e.g., example.com)";if(e.length>253)return"Domain name is too long (max 253 characters)";for(const i of l){if(i.length>63)return`Label "${i}" is too long (max 63 characters)`;if(!/^[a-z0-9]([a-z0-9-]*[a-z0-9])?$/i.test(i))return`Label "${i}" has invalid characters or format`}const a=l[l.length-1]??"";return/^[0-9]+$/.test(a)?"Domain must include a valid TLD, not a number":null}function us(r,e){return r&&typeof r=="object"&&"error"in r?String(r.error):`request failed (${e})`}async function Kt(r){const e=await fetch(r),o=await e.json().catch(()=>({}));if(!e.ok)throw new It(us(o,e.status),e.status);return o}async function at(r,e,o){const l=await fetch(r,{method:e,headers:o!==void 0?{"Content-Type":"application/json"}:{},body:o!==void 0?JSON.stringify(o):void 0}),a=await l.json().catch(()=>({}));if(!l.ok)throw new It(us(a,l.status),l.status);return a}function ut(r){const e=Z.c(4),{title:o,actions:l,children:a}=r;let i;return e[0]!==l||e[1]!==a||e[2]!==o?(i=t.jsx(Ts,{title:o,actions:l,children:a}),e[0]=l,e[1]=a,e[2]=o,e[3]=i):i=e[3],i}function Ie(r){const e=Z.c(5),{className:o,children:l}=r;let a;e[0]!==o?(a=xt("gap-0 overflow-hidden p-0 divide-y divide-border",o),e[0]=o,e[1]=a):a=e[1];let i;return e[2]!==l||e[3]!==a?(i=t.jsx(ps,{className:a,children:l}),e[2]=l,e[3]=a,e[4]=i):i=e[4],i}function pt(r){const e=Z.c(5),{className:o,children:l}=r;let a;e[0]!==o?(a=xt("flex min-h-12 items-center gap-3 px-4 py-2",o),e[0]=o,e[1]=a):a=e[1];let i;return e[2]!==l||e[3]!==a?(i=t.jsx("div",{className:a,children:l}),e[2]=l,e[3]=a,e[4]=i):i=e[4],i}function ot(r){const e=Z.c(2),{children:o}=r;let l;return e[0]!==o?(l=t.jsx("p",{className:"px-4 py-6 text-sm text-muted-foreground",children:o}),e[0]=o,e[1]=l):l=e[1],l}function ht(r){const e=Z.c(2),{rows:o}=r,l=o===void 0?3:o;let a;return e[0]!==l?(a=t.jsx(Ie,{children:Array.from({length:l},Ys)}),e[0]=l,e[1]=a):a=e[1],a}function Ys(r,e){return t.jsxs(pt,{children:[t.jsx(dt,{className:"h-4 w-40"}),t.jsx(dt,{className:"h-4 flex-1"}),t.jsx(dt,{className:"size-7 rounded-lg"})]},e)}function Me(r){const e=Z.c(5),{className:o,children:l}=r;let a;e[0]!==o?(a=xt("text-xs font-medium text-muted-foreground",o),e[0]=o,e[1]=a):a=e[1];let i;return e[2]!==l||e[3]!==a?(i=t.jsx(As,{className:a,children:l}),e[2]=l,e[3]=a,e[4]=i):i=e[4],i}function Qt(r){const e=Z.c(12),{open:o,onClick:l}=r,a=Ae();let i;e[0]!==o||e[1]!==a?(i=a(o?"mainPanelTabs.hostingTab.hideDetails":"mainPanelTabs.hostingTab.showDetails"),e[0]=o,e[1]=a,e[2]=i):i=e[2];const c=o&&"rotate-90";let m;e[3]!==c?(m=xt("transition-transform duration-200 motion-reduce:transition-none",c),e[3]=c,e[4]=m):m=e[4];let s;e[5]!==m?(s=t.jsx(ns,{className:m}),e[5]=m,e[6]=s):s=e[6];let n;return e[7]!==l||e[8]!==o||e[9]!==i||e[10]!==s?(n=t.jsx(et,{label:i,size:"icon-sm",className:"-ml-1.5 text-muted-foreground","aria-expanded":o,onClick:l,children:s}),e[7]=l,e[8]=o,e[9]=i,e[10]=s,e[11]=n):n=e[11],n}function Gs(r){const e=Z.c(8),{open:o,colSpan:l,children:a}=r;let i;e[0]!==a?(i=t.jsx(Vt,{children:t.jsx("div",{className:"border-b border-border bg-muted/30 px-4 py-3",children:a})}),e[0]=a,e[1]=i):i=e[1];let c;e[2]!==o||e[3]!==i?(c=t.jsx(Ht,{open:o,children:i}),e[2]=o,e[3]=i,e[4]=c):c=e[4];let m;return e[5]!==l||e[6]!==c?(m=t.jsx(nt,{className:"border-0 hover:bg-transparent",children:t.jsx(Fe,{colSpan:l,className:"p-0 whitespace-normal",children:c})}),e[5]=l,e[6]=c,e[7]=m):m=e[7],m}function hs(r){const e=Z.c(5),{open:o,children:l}=r;let a;e[0]!==l?(a=t.jsx(Vt,{children:t.jsx("div",{className:"border-t border-border bg-muted/30 px-4 py-3",children:l})}),e[0]=l,e[1]=a):a=e[1];let i;return e[2]!==o||e[3]!==a?(i=t.jsx(Ht,{open:o,children:a}),e[2]=o,e[3]=a,e[4]=i):i=e[4],i}function xs(r){const e=Z.c(6),{scope:o}=r,l=Ae(),a=o==="build"?"outline":"secondary";let i;e[0]!==o||e[1]!==l?(i=l(o==="build"?"mainPanelTabs.hostingTab.secretScopeBuild":"mainPanelTabs.hostingTab.secretScopeRuntime"),e[0]=o,e[1]=l,e[2]=i):i=e[2];let c;return e[3]!==a||e[4]!==i?(c=t.jsx(Re,{variant:a,children:i}),e[3]=a,e[4]=i,e[5]=c):c=e[5],c}function Zs(r){const e=Z.c(9),{value:o}=r,l=Ae();let a;e[0]!==l?(a=l("mainPanelTabs.hostingTab.dnsCopy"),e[0]=l,e[1]=a):a=e[1];let i;e[2]!==l||e[3]!==o?(i=()=>{if(!navigator.clipboard){ce.error(l("mainPanelTabs.hostingTab.dnsCopyError"));return}navigator.clipboard.writeText(o).then(()=>ce.success(l("mainPanelTabs.hostingTab.dnsCopied")),()=>ce.error(l("mainPanelTabs.hostingTab.dnsCopyError")))},e[2]=l,e[3]=o,e[4]=i):i=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx(zs,{className:"size-3.5"}),e[5]=c):c=e[5];let m;return e[6]!==a||e[7]!==i?(m=t.jsx(et,{label:a,onClick:i,children:c}),e[6]=a,e[7]=i,e[8]=m):m=e[8],m}function wt(r){const e=Z.c(28),{open:o,onOpenChange:l,title:a,description:i,confirmLabel:c,pending:m,onConfirm:s}=r,n=Ae();let x;e[0]!==a?(x=t.jsx(ls,{children:a}),e[0]=a,e[1]=x):x=e[1];let b;e[2]!==i?(b=t.jsx(as,{children:i}),e[2]=i,e[3]=b):b=e[3];let d;e[4]!==x||e[5]!==b?(d=t.jsxs(os,{children:[x,b]}),e[4]=x,e[5]=b,e[6]=d):d=e[6];let f;e[7]!==n?(f=n("mainPanelTabs.hostingTab.cancel"),e[7]=n,e[8]=f):f=e[8];let u;e[9]!==m||e[10]!==f?(u=t.jsx(rs,{disabled:m,children:f}),e[9]=m,e[10]=f,e[11]=u):u=e[11];let g;e[12]!==s?(g=S=>{S.preventDefault(),s()},e[12]=s,e[13]=g):g=e[13];let h;e[14]!==c||e[15]!==m||e[16]!==g?(h=t.jsx(cs,{className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",onClick:g,disabled:m,children:c}),e[14]=c,e[15]=m,e[16]=g,e[17]=h):h=e[17];let N;e[18]!==u||e[19]!==h?(N=t.jsxs(ms,{children:[u,h]}),e[18]=u,e[19]=h,e[20]=N):N=e[20];let C;e[21]!==d||e[22]!==N?(C=t.jsxs(ds,{children:[d,N]}),e[21]=d,e[22]=N,e[23]=C):C=e[23];let P;return e[24]!==l||e[25]!==o||e[26]!==C?(P=t.jsx(fs,{open:o,onOpenChange:l,children:C}),e[24]=l,e[25]=o,e[26]=C,e[27]=P):P=e[27],P}const en=8;function tn(r){const e=Z.c(54),{base:o,orgSlug:l,site:a}=r,i=Ae(),c=bt(),[m,s]=ee.useState(!1);let n;e[0]!==o?(n=()=>at(`${o}/deploy`,"POST",{mode:"current"}),e[0]=o,e[1]=n):n=e[1];let x;e[2]!==l||e[3]!==c||e[4]!==a||e[5]!==i?(x=()=>{c.invalidateQueries({queryKey:Xe.hostingDeployments(l,a)}),c.invalidateQueries({queryKey:Xe.hostingDeploymentHistory(l,a)}),ce.success(i("mainPanelTabs.hostingTab.toastDeployQueued")),s(!1)},e[2]=l,e[3]=c,e[4]=a,e[5]=i,e[6]=x):x=e[6];let b;e[7]!==n||e[8]!==x?(b={mutationFn:n,onSuccess:x,onError:sn},e[7]=n,e[8]=x,e[9]=b):b=e[9];const d=lt(b);let f;e[10]===Symbol.for("react.memo_cache_sentinel")?(f=()=>s(!0),e[10]=f):f=e[10];let u;e[11]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(gt,{}),e[11]=u):u=e[11];let g;e[12]!==d.isPending||e[13]!==i?(g=d.isPending?i("mainPanelTabs.hostingTab.deploying"):i("mainPanelTabs.hostingTab.deploy"),e[12]=d.isPending,e[13]=i,e[14]=g):g=e[14];let h;e[15]!==d.isPending||e[16]!==g?(h=t.jsxs(Qe,{size:"sm",onClick:f,disabled:d.isPending,children:[u,g]}),e[15]=d.isPending,e[16]=g,e[17]=h):h=e[17];let N;e[18]!==i?(N=i("mainPanelTabs.hostingTab.deployConfirmTitle"),e[18]=i,e[19]=N):N=e[19];let C;e[20]!==N?(C=t.jsx(ls,{children:N}),e[20]=N,e[21]=C):C=e[21];let P;e[22]!==i?(P=i("mainPanelTabs.hostingTab.deployConfirmDescription"),e[22]=i,e[23]=P):P=e[23];let S;e[24]!==P?(S=t.jsx(as,{children:P}),e[24]=P,e[25]=S):S=e[25];let y;e[26]!==S||e[27]!==C?(y=t.jsxs(os,{children:[C,S]}),e[26]=S,e[27]=C,e[28]=y):y=e[28];const R=d.isPending;let w;e[29]!==i?(w=i("mainPanelTabs.hostingTab.cancel"),e[29]=i,e[30]=w):w=e[30];let j;e[31]!==d.isPending||e[32]!==w?(j=t.jsx(rs,{disabled:R,children:w}),e[31]=d.isPending,e[32]=w,e[33]=j):j=e[33];let T;e[34]!==d?(T=_=>{_.preventDefault(),d.mutate()},e[34]=d,e[35]=T):T=e[35];const V=d.isPending;let q;e[36]!==i?(q=i("mainPanelTabs.hostingTab.deploy"),e[36]=i,e[37]=q):q=e[37];let F;e[38]!==d.isPending||e[39]!==T||e[40]!==q?(F=t.jsx(cs,{onClick:T,disabled:V,children:q}),e[38]=d.isPending,e[39]=T,e[40]=q,e[41]=F):F=e[41];let v;e[42]!==j||e[43]!==F?(v=t.jsxs(ms,{children:[j,F]}),e[42]=j,e[43]=F,e[44]=v):v=e[44];let H;e[45]!==y||e[46]!==v?(H=t.jsxs(ds,{children:[y,v]}),e[45]=y,e[46]=v,e[47]=H):H=e[47];let A;e[48]!==m||e[49]!==H?(A=t.jsx(fs,{open:m,onOpenChange:s,children:H}),e[48]=m,e[49]=H,e[50]=A):A=e[50];let K;return e[51]!==A||e[52]!==h?(K=t.jsxs(t.Fragment,{children:[h,A]}),e[51]=A,e[52]=h,e[53]=K):K=e[53],K}function sn(r){return ce.error(rt(r))}function nn(r,e){const o=(r??"").toLowerCase();return o.includes("rollback")?t.jsxs(Re,{variant:"warning",children:[t.jsx(ws,{}),e("mainPanelTabs.hostingTab.actionRollback")]}):o.includes("redeploy")?t.jsxs(Re,{variant:"secondary",children:[t.jsx($s,{}),e("mainPanelTabs.hostingTab.actionRedeploy")]}):t.jsxs(Re,{variant:"secondary",children:[t.jsx(gt,{}),e("mainPanelTabs.hostingTab.actionDeploy")]})}function ln(r,e,o){const l=(r??"").toLowerCase();return l==="build"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(is,{}),o("mainPanelTabs.hostingTab.typeBuild")]}):l==="fast-deploy"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(_s,{}),o("mainPanelTabs.hostingTab.typeFastDeploy")]}):l==="deploy"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(gt,{}),o("mainPanelTabs.hostingTab.typeDeploy")]}):nn(e,o)}function an(r,e){const o=(r??"").toLowerCase();return o==="success"?t.jsx(Re,{variant:"success",children:e("mainPanelTabs.hostingTab.outcomeSuccess")}):o==="failure"?t.jsx(Re,{variant:"destructive",children:e("mainPanelTabs.hostingTab.outcomeFailure")}):o==="pending"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(Ds,{}),e("mainPanelTabs.hostingTab.outcomePending")]}):null}function Zt(r){const e=Z.c(7),{commit:o,onClick:l}=r,a=Ae();let i;e[0]!==a?(i=a("mainPanelTabs.hostingTab.buildLogs"),e[0]=a,e[1]=i):i=e[1];const c=!o;let m;e[2]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx(is,{}),e[2]=m):m=e[2];let s;return e[3]!==l||e[4]!==i||e[5]!==c?(s=t.jsx(et,{label:i,onClick:l,disabled:c,children:m}),e[3]=l,e[4]=i,e[5]=c,e[6]=s):s=e[6],s}function on(r){const e=Z.c(37),{base:o,orgSlug:l,site:a,target:i,onOpenChange:c}=r,m=Ae(),s=i!=null,n=i?.commit??"",x=i?.env??"";let b;e[0]!==n||e[1]!==x||e[2]!==l||e[3]!==a?(b=Xe.hostingBuildLogs(l,a,n,x),e[0]=n,e[1]=x,e[2]=l,e[3]=a,e[4]=b):b=e[4];let d;e[5]!==o||e[6]!==n||e[7]!==x?(d=()=>Kt(`${o}/deployments/logs?commit=${encodeURIComponent(n)}&env=${encodeURIComponent(x)}`),e[5]=o,e[6]=n,e[7]=x,e[8]=d):d=e[8];const f=s&&!!n;let u;e[9]!==b||e[10]!==d||e[11]!==f?(u={queryKey:b,queryFn:d,enabled:f,retry:!1,staleTime:0,gcTime:0,refetchOnMount:"always"},e[9]=b,e[10]=d,e[11]=f,e[12]=u):u=e[12];const g=ct(u),h=g.data;let N;e[13]!==m?(N=m("mainPanelTabs.hostingTab.buildLogsTitle"),e[13]=m,e[14]=N):N=e[14];let C;e[15]!==N?(C=t.jsx(ks,{children:N}),e[15]=N,e[16]=C):C=e[16];let P;e[17]!==n||e[18]!==m?(P=m("mainPanelTabs.hostingTab.buildLogsCommit",{commit:n.slice(0,7)}),e[17]=n,e[18]=m,e[19]=P):P=e[19];let S;e[20]!==P?(S=t.jsx("p",{className:"font-mono text-xs text-muted-foreground",children:P}),e[20]=P,e[21]=S):S=e[21];let y;e[22]!==C||e[23]!==S?(y=t.jsxs(Es,{className:"shrink-0 border-b border-border px-5 py-5 md:px-6",children:[C,S]}),e[22]=C,e[23]=S,e[24]=y):y=e[24];let R;e[25]!==h||e[26]!==g.error||e[27]!==g.isLoading||e[28]!==m?(R=t.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto px-5 py-5 md:px-6",children:jt(g.error)?t.jsx(Ze,{icon:t.jsx(_t,{className:"size-5"}),title:m("mainPanelTabs.hostingTab.notConnectedTitle"),description:m("mainPanelTabs.hostingTab.notConnectedDescription")}):g.isLoading?t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsx(dt,{className:"h-4 w-full"}),t.jsx(dt,{className:"h-4 w-full"}),t.jsx(dt,{className:"h-4 w-2/3"})]}):g.error?t.jsx(ot,{children:m("mainPanelTabs.hostingTab.buildLogsError")}):h&&h.configured===!1?t.jsxs("div",{className:"flex flex-col items-center gap-2 rounded-lg border border-border bg-muted/30 px-4 py-8 text-center",children:[t.jsx(Ns,{className:"size-5 text-muted-foreground"}),t.jsx("p",{className:"text-sm font-medium text-foreground",children:m("mainPanelTabs.hostingTab.buildLogsNotWiredTitle")}),t.jsx("p",{className:"text-xs text-muted-foreground",children:h.reason??m("mainPanelTabs.hostingTab.buildLogsNotWiredDescription")})]}):h?.text?t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsx("pre",{className:"overflow-auto font-mono text-[11px] leading-relaxed text-foreground/80 whitespace-pre-wrap break-words",children:h.text}),h.truncated&&t.jsx("p",{className:"text-xs text-warning",children:m("mainPanelTabs.hostingTab.buildLogsTruncated")}),h.url&&t.jsxs("a",{href:h.url,target:"_blank",rel:"noreferrer",className:"inline-flex w-fit items-center gap-1.5 text-xs text-primary hover:underline",children:[t.jsx(kt,{className:"size-3.5"}),m("mainPanelTabs.hostingTab.buildLogsOpenFull")]})]}):h?.url?t.jsxs("a",{href:h.url,target:"_blank",rel:"noreferrer",className:"inline-flex w-fit items-center gap-1.5 text-sm text-primary hover:underline",children:[t.jsx(kt,{className:"size-4"}),m("mainPanelTabs.hostingTab.buildLogsOpenFull")]}):t.jsx(ot,{children:m("mainPanelTabs.hostingTab.buildLogsEmpty")})}),e[25]=h,e[26]=g.error,e[27]=g.isLoading,e[28]=m,e[29]=R):R=e[29];let w;e[30]!==R||e[31]!==y?(w=t.jsxs(Rs,{className:"flex flex-col gap-0 p-0 sm:max-w-2xl",children:[y,R]}),e[30]=R,e[31]=y,e[32]=w):w=e[32];let j;return e[33]!==c||e[34]!==s||e[35]!==w?(j=t.jsx(Fs,{open:s,onOpenChange:c,children:w}),e[33]=c,e[34]=s,e[35]=w,e[36]=j):j=e[36],j}function rn(r){const e=Z.c(52),{base:o,orgSlug:l,site:a,enabled:i,deployments:c,isLoading:m,error:s}=r,n=Ae(),[x,b]=ee.useState(null),[d,f]=ee.useState(en),[u,g]=ee.useState(null);let h;e[0]!==l||e[1]!==a?(h=Xe.hostingDeploymentHistory(l,a),e[0]=l,e[1]=a,e[2]=h):h=e[2];let N;e[3]!==o?(N=()=>Kt(`${o}/deployments/history?limit=50`),e[3]=o,e[4]=N):N=e[4];let C;e[5]!==i||e[6]!==h||e[7]!==N?(C={queryKey:h,queryFn:N,enabled:i,retry:!1,staleTime:3e4},e[5]=i,e[6]=h,e[7]=N,e[8]=C):C=e[8];const P=ct(C);let S,y,R,w;if(e[9]!==c||e[10]!==s||e[11]!==x||e[12]!==d||e[13]!==P.data||e[14]!==P.error||e[15]!==P.isLoading||e[16]!==m||e[17]!==n){const F=mt(P.data,"items"),v=F.slice(0,d),H=F.length-v.length;let A;e[22]!==c?(A=c.find(dn)?.commitSha??c.find(mn)?.commitSha??null,e[22]=c,e[23]=A):A=e[23];const K=A;let _;e[24]===Symbol.for("react.memo_cache_sentinel")?(_=(p,I)=>{p&&g({commit:p,env:I??"production"})},e[24]=_):_=e[24];const W=_;let J;e[25]!==n?(J=n("mainPanelTabs.hostingTab.deployments"),e[25]=n,e[26]=J):J=e[26];let Q;e[27]!==c||e[28]!==s||e[29]!==x||e[30]!==m||e[31]!==n?(Q=m?t.jsx(ht,{}):s?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.deploymentsError")})}):c.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(gt,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noDeployments"),className:"py-10"})}):t.jsxs(Rt,{children:[t.jsx(Ft,{children:t.jsxs(nt,{children:[t.jsx(Me,{className:"pl-4",children:n("mainPanelTabs.hostingTab.colCommit")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colStatus")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colFramework")}),t.jsx(Me,{className:"text-right",children:n("mainPanelTabs.hostingTab.colDuration")}),t.jsx(Me,{className:"text-right",children:n("mainPanelTabs.hostingTab.colUpdated")}),t.jsx(Me,{className:"w-[1%]"})]})}),t.jsx(At,{children:c.map(p=>{const I=!!p.buildMessage,X=x===p.id;return t.jsxs(ee.Fragment,{children:[t.jsxs(nt,{className:xt(I&&"cursor-pointer hover:bg-muted/40"),onClick:I?()=>b(X?null:p.id):void 0,children:[t.jsx(Fe,{className:"px-4",children:t.jsxs("div",{className:"flex items-center gap-1.5",children:[I?t.jsx(Qt,{open:X,onClick:()=>b(X?null:p.id)}):t.jsx(Cs,{className:"size-4 text-muted-foreground/60"}),t.jsx("span",{className:"font-mono text-xs",children:p.shortCommit??p.commitSha?.slice(0,7)??"—"}),p.production===!0&&t.jsx(Re,{variant:"outline",children:n("mainPanelTabs.hostingTab.production")})]})}),t.jsx(Fe,{children:t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(Re,{variant:Ws(p.phase),children:p.phase??"—"}),p.up===!0&&t.jsx(Re,{variant:"success",children:n("mainPanelTabs.hostingTab.live")})]})}),t.jsx(Fe,{className:"text-xs text-muted-foreground",children:zt(p.framework)??"—"}),t.jsx(Fe,{className:"text-right font-mono text-xs text-muted-foreground tabular-nums",children:Js(p.durationMs)}),t.jsx(Fe,{className:"text-right text-xs text-muted-foreground",children:Gt(p.finishedAt??p.startedAt??p.createdAt)}),t.jsx(Fe,{className:"pr-3 text-right",onClick:cn,children:t.jsx(Zt,{commit:p.commitSha,onClick:()=>W(p.commitSha,p.env)})})]}),I&&t.jsx(Gs,{open:X,colSpan:6,children:t.jsx("p",{className:"whitespace-pre-wrap break-words font-mono text-xs text-muted-foreground",children:p.buildMessage})})]},p.id)})})]}),e[27]=c,e[28]=s,e[29]=x,e[30]=m,e[31]=n,e[32]=Q):Q=e[32],e[33]!==Q||e[34]!==J?(w=t.jsx(ut,{title:J,children:Q}),e[33]=Q,e[34]=J,e[35]=w):w=e[35],S=ut,e[36]!==n?(y=n("mainPanelTabs.hostingTab.deployHistory"),e[36]=n,e[37]=y):y=e[37],R=P.isLoading?t.jsx(ht,{}):P.error?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.deployHistoryError")})}):F.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(gt,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noDeployHistory"),className:"py-10"})}):t.jsxs(Rt,{children:[t.jsx(Ft,{children:t.jsxs(nt,{children:[t.jsx(Me,{className:"pl-4",children:n("mainPanelTabs.hostingTab.colAction")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colStatus")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colCommit")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colFramework")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colActor")}),t.jsx(Me,{className:"text-right",children:n("mainPanelTabs.hostingTab.colDate")}),t.jsx(Me,{className:"w-[1%]"})]})}),t.jsxs(At,{children:[v.map(p=>{const I=!!K&&p.commitSha===K;return t.jsxs(nt,{children:[t.jsx(Fe,{className:"pl-4",children:ln(p.type,p.action,n)}),t.jsx(Fe,{children:an(p.outcome,n)}),t.jsx(Fe,{children:t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx("span",{className:"font-mono text-xs",children:p.commitSha?.slice(0,7)??"—"}),I&&t.jsx(Re,{variant:"success",children:n("mainPanelTabs.hostingTab.live")})]})}),t.jsx(Fe,{className:"text-xs text-muted-foreground",children:zt(p.framework)??"—"}),t.jsx(Fe,{className:"text-xs text-muted-foreground",children:p.actor??"—"}),t.jsx(Fe,{className:"text-right text-xs text-muted-foreground",children:Gt(p.createdAt)}),t.jsx(Fe,{className:"pr-3 text-right",children:t.jsx(Zt,{commit:p.commitSha,onClick:()=>W(p.commitSha,p.env)})})]},p.id)}),H>0&&t.jsx(nt,{className:"hover:bg-transparent",children:t.jsx(Fe,{colSpan:7,className:"p-2 text-center",children:t.jsx(Qe,{variant:"ghost",size:"sm",onClick:()=>f(F.length),children:n("mainPanelTabs.hostingTab.showMoreHistory",{count:String(H)})})})})]})]}),e[9]=c,e[10]=s,e[11]=x,e[12]=d,e[13]=P.data,e[14]=P.error,e[15]=P.isLoading,e[16]=m,e[17]=n,e[18]=S,e[19]=y,e[20]=R,e[21]=w}else S=e[18],y=e[19],R=e[20],w=e[21];let j;e[38]!==S||e[39]!==y||e[40]!==R?(j=t.jsx(S,{title:y,children:R}),e[38]=S,e[39]=y,e[40]=R,e[41]=j):j=e[41];let T;e[42]===Symbol.for("react.memo_cache_sentinel")?(T=F=>{F||g(null)},e[42]=T):T=e[42];let V;e[43]!==o||e[44]!==u||e[45]!==l||e[46]!==a?(V=t.jsx(on,{base:o,orgSlug:l,site:a,target:u,onOpenChange:T}),e[43]=o,e[44]=u,e[45]=l,e[46]=a,e[47]=V):V=e[47];let q;return e[48]!==w||e[49]!==j||e[50]!==V?(q=t.jsxs(t.Fragment,{children:[w,j,V]}),e[48]=w,e[49]=j,e[50]=V,e[51]=q):q=e[51],q}function cn(r){return r.stopPropagation()}function mn(r){return r.production===!0&&r.up}function dn(r){return r.up===!0}const fn=["16.148.147.194","52.32.122.94","52.35.156.199"];function un(r){return r.replace(/\.$/,"").split(".").filter(Boolean).length===2}function es(r){const e=r.trim();return e.length>0&&!e.startsWith("/")&&e.includes(".")}function gs(r){const e=Z.c(24),{records:o}=r,l=Ae();let a;e[0]!==l?(a=l("mainPanelTabs.hostingTab.dnsColType"),e[0]=l,e[1]=a):a=e[1];let i;e[2]!==a?(i=t.jsx(Me,{className:"w-16",children:a}),e[2]=a,e[3]=i):i=e[3];let c;e[4]!==l?(c=l("mainPanelTabs.hostingTab.dnsColName"),e[4]=l,e[5]=c):c=e[5];let m;e[6]!==c?(m=t.jsx(Me,{children:c}),e[6]=c,e[7]=m):m=e[7];let s;e[8]!==l?(s=l("mainPanelTabs.hostingTab.dnsColValue"),e[8]=l,e[9]=s):s=e[9];let n;e[10]!==s?(n=t.jsx(Me,{children:s}),e[10]=s,e[11]=n):n=e[11];let x;e[12]===Symbol.for("react.memo_cache_sentinel")?(x=t.jsx(Me,{className:"w-10"}),e[12]=x):x=e[12];let b;e[13]!==i||e[14]!==m||e[15]!==n?(b=t.jsx(Ft,{children:t.jsxs(nt,{children:[i,m,n,x]})}),e[13]=i,e[14]=m,e[15]=n,e[16]=b):b=e[16];let d;e[17]!==o?(d=o.map(hn),e[17]=o,e[18]=d):d=e[18];let f;e[19]!==d?(f=t.jsx(At,{children:d}),e[19]=d,e[20]=f):f=e[20];let u;return e[21]!==f||e[22]!==b?(u=t.jsxs(Rt,{className:"table-fixed",children:[b,f]}),e[21]=f,e[22]=b,e[23]=u):u=e[23],u}function hn(r){return t.jsxs(nt,{children:[t.jsx(Fe,{className:"font-mono text-xs",children:r.type}),t.jsx(Fe,{className:"break-all whitespace-normal font-mono text-xs",children:r.name}),t.jsx(Fe,{className:"break-all whitespace-normal font-mono text-xs text-muted-foreground",children:r.value}),t.jsx(Fe,{className:"text-right",children:t.jsx(Zs,{value:r.value})})]},`${r.type}-${r.name}-${r.value}`)}function bs(r){const e=Z.c(14),{status:o,children:l}=r,a=Ae();let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx(Et,{className:"size-4 text-muted-foreground"}),e[0]=i):i=e[0];let c;e[1]!==a?(c=a("mainPanelTabs.hostingTab.dnsSetupTitle"),e[1]=a,e[2]=c):c=e[2];let m;e[3]!==c?(m=t.jsx("span",{className:"text-sm font-medium",children:c}),e[3]=c,e[4]=m):m=e[4];let s;e[5]!==o||e[6]!==a?(s=o&&t.jsx(Re,{variant:o.active?"success":"outline",className:"ml-auto",children:o.active?a("mainPanelTabs.hostingTab.dnsActive"):a("mainPanelTabs.hostingTab.dnsAwaiting")}),e[5]=o,e[6]=a,e[7]=s):s=e[7];let n;e[8]!==m||e[9]!==s?(n=t.jsxs("div",{className:"flex items-center gap-2",children:[i,m,s]}),e[8]=m,e[9]=s,e[10]=n):n=e[10];let x;return e[11]!==l||e[12]!==n?(x=t.jsxs("div",{className:"flex min-w-0 flex-col gap-3",children:[n,l]}),e[11]=l,e[12]=n,e[13]=x):x=e[13],x}function ts(r){const e=Z.c(21),{from:o,source:l}=r,a=Ae();let i,c,m,s,n;if(e[0]!==o||e[1]!==l||e[2]!==a){const d=o.trim().replace(/\.$/,""),f=d?un(d)?"@":d:"@",u=l==="both";c=bs,e[8]!==u?(s={active:u},e[8]=u,e[9]=s):s=e[9];let g;e[10]!==u||e[11]!==a?(g=a(u?"mainPanelTabs.hostingTab.dnsActiveHint":"mainPanelTabs.hostingTab.dnsAwaitingHint"),e[10]=u,e[11]=a,e[12]=g):g=e[12],n=t.jsxs("p",{className:"text-xs text-muted-foreground",children:[a("mainPanelTabs.hostingTab.dnsRedirectIntent",{from:d||"—"})," ",g]}),i=gs,m=fn.map(h=>({type:"A",name:f,value:h})),e[0]=o,e[1]=l,e[2]=a,e[3]=i,e[4]=c,e[5]=m,e[6]=s,e[7]=n}else i=e[3],c=e[4],m=e[5],s=e[6],n=e[7];let x;e[13]!==i||e[14]!==m?(x=t.jsx(i,{records:m}),e[13]=i,e[14]=m,e[15]=x):x=e[15];let b;return e[16]!==c||e[17]!==s||e[18]!==n||e[19]!==x?(b=t.jsxs(c,{status:s,children:[n,x]}),e[16]=c,e[17]=s,e[18]=n,e[19]=x,e[20]=b):b=e[20],b}function ss(r){const e=Z.c(2),{records:o}=r;if(o.length===0)return null;let l;return e[0]!==o?(l=t.jsx(bs,{children:t.jsx(gs,{records:o})}),e[0]=o,e[1]=l):l=e[1],l}function xn(r){const e=Z.c(16),{domain:o}=r,l=Ae(),a=o.status??"pending";let i;e[0]!==a||e[1]!==l?(i=l(a==="active"?"mainPanelTabs.hostingTab.statusActive":a==="action-required"?"mainPanelTabs.hostingTab.statusActionRequired":"mainPanelTabs.hostingTab.statusPending"),e[0]=a,e[1]=l,e[2]=i):i=e[2];const c=i;let m;e[3]!==o.detail||e[4]!==l?(m=o.detail==="zone-not-onboarded"?l("mainPanelTabs.hostingTab.detailZoneNotOnboarded"):void 0,e[3]=o.detail,e[4]=l,e[5]=m):m=e[5];const s=m,n=a==="active"?"success":a==="action-required"?"warning":"outline";let x;e[6]!==c||e[7]!==n?(x=t.jsx(Re,{variant:n,children:c}),e[6]=c,e[7]=n,e[8]=x):x=e[8];const b=x;if(!s)return b;let d;e[9]!==b?(d=t.jsx(Hs,{asChild:!0,children:b}),e[9]=b,e[10]=d):d=e[10];let f;e[11]!==s?(f=t.jsx(Bs,{className:"max-w-xs",children:s}),e[11]=s,e[12]=f):f=e[12];let u;return e[13]!==d||e[14]!==f?(u=t.jsxs(Os,{children:[d,f]}),e[13]=d,e[14]=f,e[15]=u):u=e[15],u}function gn(r){const e=Z.c(121),{base:o,orgSlug:l,site:a,domains:i,dnsTemplate:c,isLoading:m,error:s}=r,n=Ae(),x=bt(),[b,d]=ee.useState(!1),[f,u]=ee.useState(""),[g,h]=ee.useState(null),[N,C]=ee.useState(null);let P;e[0]!==l||e[1]!==x||e[2]!==a?(P=()=>x.invalidateQueries({queryKey:Xe.hostingDomains(l,a)}),e[0]=l,e[1]=x,e[2]=a,e[3]=P):P=e[3];const S=P;let y;e[4]!==o?(y=$=>at(`${o}/domains`,"PUT",$),e[4]=o,e[5]=y):y=e[5];let R;e[6]!==S||e[7]!==n?(R=()=>{S(),ce.success(n("mainPanelTabs.hostingTab.toastDomainSaved")),d(!1)},e[6]=S,e[7]=n,e[8]=R):R=e[8];let w;e[9]!==y||e[10]!==R?(w={mutationFn:y,onSuccess:R,onError:pn},e[9]=y,e[10]=R,e[11]=w):w=e[11];const j=lt(w);let T;e[12]!==o?(T=$=>at(`${o}/domains/${encodeURIComponent($)}`,"DELETE"),e[12]=o,e[13]=T):T=e[13];let V;e[14]!==S||e[15]!==n?(V=()=>{S(),ce.success(n("mainPanelTabs.hostingTab.toastDomainDeleted")),h(null)},e[14]=S,e[15]=n,e[16]=V):V=e[16];let q;e[17]!==T||e[18]!==V?(q={mutationFn:T,onSuccess:V,onError:bn},e[17]=T,e[18]=V,e[19]=q):q=e[19];const F=lt(q);let v;e[20]!==f||e[21]!==j||e[22]!==n?(v=()=>{const $=f.trim().toLowerCase();if(!$){ce.error(n("mainPanelTabs.hostingTab.errorDomainHostRequired"));return}const se=Xs($);if(se){ce.error(se);return}j.mutate({host:$})},e[20]=f,e[21]=j,e[22]=n,e[23]=v):v=e[23];const H=v;let A;if(e[24]!==c||e[25]!==f){let $;e[27]!==f?($=se=>({...se,name:f.trim().toLowerCase()||se.name}),e[27]=f,e[28]=$):$=e[28],A=c.map($),e[24]=c,e[25]=f,e[26]=A}else A=e[26];const K=A;let _,W;e[29]===Symbol.for("react.memo_cache_sentinel")?(_=()=>{u(""),d(!0)},W=t.jsx(Pt,{}),e[29]=_,e[30]=W):(_=e[29],W=e[30]);let J;e[31]!==n?(J=n("mainPanelTabs.hostingTab.addDomain"),e[31]=n,e[32]=J):J=e[32];let Q;e[33]!==J?(Q=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:_,children:[W,J]}),e[33]=J,e[34]=Q):Q=e[34];const p=Q;let I;e[35]!==n?(I=n("mainPanelTabs.hostingTab.domains"),e[35]=n,e[36]=I):I=e[36];const X=i.length>0?p:void 0;let D;e[37]!==p||e[38]!==F.isPending||e[39]!==N||e[40]!==i||e[41]!==s||e[42]!==m||e[43]!==n?(D=m?t.jsx(ht,{}):s?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.domainsError")})}):i.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Et,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noDomains"),className:"py-10",buttonComponent:p})}):t.jsx(Ie,{children:i.map(($,se)=>{const Se=!$.canonical&&($.dns?.length??0)>0,je=N===$.host;return t.jsxs("div",{children:[t.jsxs(pt,{children:[Se?t.jsx(Qt,{open:je,onClick:()=>C(je?null:$.host)}):t.jsx(Et,{className:"size-4 shrink-0 text-muted-foreground/60"}),t.jsxs("div",{className:"flex min-w-0 flex-1 items-center gap-2",children:[t.jsx("span",{className:"truncate font-mono text-xs",children:$.host}),$.canonical&&t.jsx(Re,{variant:"outline",children:n("mainPanelTabs.hostingTab.canonical")})]}),t.jsx(xn,{domain:$}),!$.canonical&&t.jsx(et,{label:n("mainPanelTabs.hostingTab.deleteDomain"),onClick:()=>h($.host),disabled:F.isPending,className:"text-muted-foreground",children:t.jsx(vt,{})})]}),Se&&t.jsx(hs,{open:je,children:t.jsx(ss,{records:$.dns??[]})})]},`${$.host}-${se}`)})}),e[37]=p,e[38]=F.isPending,e[39]=N,e[40]=i,e[41]=s,e[42]=m,e[43]=n,e[44]=D):D=e[44];let Y;e[45]!==n?(Y=n("mainPanelTabs.hostingTab.addDomainTitle"),e[45]=n,e[46]=Y):Y=e[46];let O;e[47]!==Y?(O=t.jsx(yt,{children:t.jsx(St,{children:Y})}),e[47]=Y,e[48]=O):O=e[48];let k;e[49]!==H?(k=$=>{$.preventDefault(),H()},e[49]=H,e[50]=k):k=e[50];let E;e[51]!==n?(E=n("mainPanelTabs.hostingTab.colHost"),e[51]=n,e[52]=E):E=e[52];let B;e[53]!==E?(B=t.jsx(Ge,{htmlFor:"domain-host",children:E}),e[53]=E,e[54]=B):B=e[54];let G;e[55]!==n?(G=n("mainPanelTabs.hostingTab.domainHostPlaceholder"),e[55]=n,e[56]=G):G=e[56];let te;e[57]===Symbol.for("react.memo_cache_sentinel")?(te=$=>u($.target.value),e[57]=te):te=e[57];let U;e[58]!==f||e[59]!==j.isPending||e[60]!==G?(U=t.jsx(it,{id:"domain-host",placeholder:G,value:f,onChange:te,className:"font-mono text-xs",autoComplete:"off",disabled:j.isPending}),e[58]=f,e[59]=j.isPending,e[60]=G,e[61]=U):U=e[61];let ne;e[62]!==B||e[63]!==U?(ne=t.jsxs("div",{className:"flex flex-col gap-2",children:[B,U]}),e[62]=B,e[63]=U,e[64]=ne):ne=e[64];let ie;e[65]!==f||e[66]!==K?(ie=f.trim()&&t.jsx("div",{className:"rounded-lg border border-border bg-muted/30 p-3",children:t.jsx(ss,{records:K})}),e[65]=f,e[66]=K,e[67]=ie):ie=e[67];let Pe;e[68]===Symbol.for("react.memo_cache_sentinel")?(Pe=()=>d(!1),e[68]=Pe):Pe=e[68];const Ce=j.isPending;let me;e[69]!==n?(me=n("mainPanelTabs.hostingTab.cancel"),e[69]=n,e[70]=me):me=e[70];let pe;e[71]!==j.isPending||e[72]!==me?(pe=t.jsx(Qe,{variant:"outline",type:"button",onClick:Pe,disabled:Ce,children:me}),e[71]=j.isPending,e[72]=me,e[73]=pe):pe=e[73];let le;e[74]!==f||e[75]!==j.isPending?(le=j.isPending||!f.trim(),e[74]=f,e[75]=j.isPending,e[76]=le):le=e[76];let ae;e[77]!==j.isPending||e[78]!==n?(ae=j.isPending?n("mainPanelTabs.hostingTab.saving"):n("mainPanelTabs.hostingTab.save"),e[77]=j.isPending,e[78]=n,e[79]=ae):ae=e[79];let de;e[80]!==le||e[81]!==ae?(de=t.jsx(Qe,{type:"submit",disabled:le,children:ae}),e[80]=le,e[81]=ae,e[82]=de):de=e[82];let De;e[83]!==pe||e[84]!==de?(De=t.jsxs(Nt,{children:[pe,de]}),e[83]=pe,e[84]=de,e[85]=De):De=e[85];let fe;e[86]!==k||e[87]!==ne||e[88]!==ie||e[89]!==De?(fe=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:k,children:[ne,ie,De]}),e[86]=k,e[87]=ne,e[88]=ie,e[89]=De,e[90]=fe):fe=e[90];let ue;e[91]!==O||e[92]!==fe?(ue=t.jsxs(Ct,{className:"sm:max-w-md",children:[O,fe]}),e[91]=O,e[92]=fe,e[93]=ue):ue=e[93];let oe;e[94]!==b||e[95]!==ue?(oe=t.jsx(Dt,{open:b,onOpenChange:d,children:ue}),e[94]=b,e[95]=ue,e[96]=oe):oe=e[96];const Te=g!=null;let he;e[97]===Symbol.for("react.memo_cache_sentinel")?(he=$=>{$||h(null)},e[97]=he):he=e[97];let xe;e[98]!==n?(xe=n("mainPanelTabs.hostingTab.confirmDeleteDomainTitle"),e[98]=n,e[99]=xe):xe=e[99];const ve=g??"";let ye;e[100]!==n||e[101]!==ve?(ye=n("mainPanelTabs.hostingTab.confirmDeleteDomainDescription",{host:ve}),e[100]=n,e[101]=ve,e[102]=ye):ye=e[102];let ge;e[103]!==n?(ge=n("mainPanelTabs.hostingTab.deleteDomain"),e[103]=n,e[104]=ge):ge=e[104];let re;e[105]!==F||e[106]!==g?(re=()=>{g&&F.mutate(g)},e[105]=F,e[106]=g,e[107]=re):re=e[107];let be;e[108]!==F.isPending||e[109]!==Te||e[110]!==xe||e[111]!==ye||e[112]!==ge||e[113]!==re?(be=t.jsx(wt,{open:Te,onOpenChange:he,title:xe,description:ye,confirmLabel:ge,pending:F.isPending,onConfirm:re}),e[108]=F.isPending,e[109]=Te,e[110]=xe,e[111]=ye,e[112]=ge,e[113]=re,e[114]=be):be=e[114];let we;return e[115]!==I||e[116]!==X||e[117]!==D||e[118]!==oe||e[119]!==be?(we=t.jsxs(ut,{title:I,actions:X,children:[D,oe,be]}),e[115]=I,e[116]=X,e[117]=D,e[118]=oe,e[119]=be,e[120]=we):we=e[120],we}function bn(r){return ce.error(rt(r))}function pn(r){return ce.error(rt(r))}function Tn(r){const e=Z.c(24),{value:o,onChange:l,disabled:a,className:i}=r,c=Ae();let m;e[0]!==l?(m=N=>l(N==="build"?"build":"runtime"),e[0]=l,e[1]=m):m=e[1];let s;e[2]!==i?(s=xt("h-8",i),e[2]=i,e[3]=s):s=e[3];let n;e[4]===Symbol.for("react.memo_cache_sentinel")?(n=t.jsx(Bt,{}),e[4]=n):n=e[4];let x;e[5]!==s?(x=t.jsx(Ot,{className:s,children:n}),e[5]=s,e[6]=x):x=e[6];let b;e[7]!==c?(b=c("mainPanelTabs.hostingTab.secretScopeRuntime"),e[7]=c,e[8]=b):b=e[8];let d;e[9]!==b?(d=t.jsx(ft,{value:"runtime",children:b}),e[9]=b,e[10]=d):d=e[10];let f;e[11]!==c?(f=c("mainPanelTabs.hostingTab.secretScopeBuild"),e[11]=c,e[12]=f):f=e[12];let u;e[13]!==f?(u=t.jsx(ft,{value:"build",children:f}),e[13]=f,e[14]=u):u=e[14];let g;e[15]!==d||e[16]!==u?(g=t.jsxs(qt,{children:[d,u]}),e[15]=d,e[16]=u,e[17]=g):g=e[17];let h;return e[18]!==a||e[19]!==m||e[20]!==x||e[21]!==g||e[22]!==o?(h=t.jsxs(Mt,{value:o,onValueChange:m,disabled:a,children:[x,g]}),e[18]=a,e[19]=m,e[20]=x,e[21]=g,e[22]=o,e[23]=h):h=e[23],h}function jn(r){const e=Z.c(151),{base:o,orgSlug:l,site:a,envVars:i,codeVars:c,isLoading:m,error:s}=r,n=Ae(),x=bt(),[b,d]=ee.useState(!1),[f,u]=ee.useState(""),[g,h]=ee.useState(""),[N,C]=ee.useState("runtime"),[P,S]=ee.useState(null),[y,R]=ee.useState(""),[w,j]=ee.useState(null);let T;e[0]===Symbol.for("react.memo_cache_sentinel")?(T=new Set,e[0]=T):T=e[0];const[V,q]=ee.useState(T);let F;e[1]===Symbol.for("react.memo_cache_sentinel")?(F=L=>{q(Ne=>{const We=new Set(Ne);return We.has(L)?We.delete(L):We.add(L),We})},e[1]=F):F=e[1];const v=F;let H;e[2]!==o?(H=L=>at(`${o}/env`,"PUT",{vars:L}),e[2]=o,e[3]=H):H=e[3];let A;e[4]!==l||e[5]!==x||e[6]!==a||e[7]!==n?(A=()=>{x.invalidateQueries({queryKey:Xe.hostingEnv(l,a)}),ce.success(n("mainPanelTabs.hostingTab.toastEnvSaved"))},e[4]=l,e[5]=x,e[6]=a,e[7]=n,e[8]=A):A=e[8];let K;e[9]!==H||e[10]!==A?(K={mutationFn:H,onSuccess:A,onError:vn},e[9]=H,e[10]=A,e[11]=K):K=e[11];const _=lt(K);let W;e[12]!==f||e[13]!==N||e[14]!==g||e[15]!==_||e[16]!==i||e[17]!==n?(W=()=>{const L=f.trim();if(!L){ce.error(n("mainPanelTabs.hostingTab.errorEnvNameRequired"));return}if(i.some(Ne=>Lt(Ne,{name:L,scope:N}))){ce.error(n("mainPanelTabs.hostingTab.errorEnvNameDuplicate"));return}_.mutate([...i,{name:L,value:g,scope:N}],{onSuccess:()=>{d(!1),u(""),h(""),C("runtime")}})},e[12]=f,e[13]=N,e[14]=g,e[15]=_,e[16]=i,e[17]=n,e[18]=W):W=e[18];const J=W;let Q;e[19]!==y||e[20]!==_||e[21]!==i?(Q=L=>{_.mutate(i.map(Ne=>Lt(Ne,L)?{name:L.name,value:y,scope:L.scope}:Ne),{onSuccess:()=>S(null)})},e[19]=y,e[20]=_,e[21]=i,e[22]=Q):Q=e[22];const p=Q;let I;e[23]!==w||e[24]!==_||e[25]!==i?(I=()=>{w&&_.mutate(i.filter(L=>!Lt(L,w)),{onSuccess:()=>j(null)})},e[23]=w,e[24]=_,e[25]=i,e[26]=I):I=e[26];const X=I,D=_.isPending;let Y;e[27]===Symbol.for("react.memo_cache_sentinel")?(Y=()=>{u(""),h(""),C("runtime")},e[27]=Y):Y=e[27];const O=Y;let k,E;e[28]===Symbol.for("react.memo_cache_sentinel")?(k=()=>d(!0),E=t.jsx(Pt,{}),e[28]=k,e[29]=E):(k=e[28],E=e[29]);let B;e[30]!==n?(B=n("mainPanelTabs.hostingTab.addVariable"),e[30]=n,e[31]=B):B=e[31];let G;e[32]!==B?(G=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:k,children:[E,B]}),e[32]=B,e[33]=G):G=e[33];const te=G;let U;e[34]!==n?(U=n("mainPanelTabs.hostingTab.env"),e[34]=n,e[35]=U):U=e[35];const ne=i.length>0||c.length>0?te:void 0;let ie;e[36]!==te||e[37]!==c||e[38]!==y||e[39]!==P?.name||e[40]!==P?.scope||e[41]!==i||e[42]!==s||e[43]!==p||e[44]!==m||e[45]!==D||e[46]!==V||e[47]!==n?(ie=m?t.jsx(ht,{}):s?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.envError")})}):i.length===0&&c.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Xt,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noEnv"),className:"py-10",buttonComponent:te})}):t.jsxs(Ie,{children:[i.map(L=>{const Ne=L.scope==="build"?"build":"runtime",We=`${L.name}:${Ne}`,tt=P?.name===L.name&&P?.scope===Ne,st=V.has(We);return t.jsxs(pt,{children:[t.jsxs("div",{className:"flex min-w-0 flex-1 basis-0 items-center gap-2",children:[t.jsx("div",{className:"w-20 shrink-0",children:t.jsx(xs,{scope:Ne})}),t.jsx("span",{className:"truncate font-mono text-xs",children:L.name})]}),t.jsx("div",{className:"flex min-w-0 flex-1 basis-0 items-center justify-end gap-2",children:tt?t.jsxs(t.Fragment,{children:[t.jsx(it,{value:y,onChange:z=>R(z.target.value),onKeyDown:z=>{z.key==="Enter"&&p({name:L.name,scope:Ne}),z.key==="Escape"&&S(null)},autoFocus:!0,className:"h-8 font-mono text-xs"}),t.jsx(Qe,{size:"sm",onClick:()=>p({name:L.name,scope:Ne}),disabled:D,children:n("mainPanelTabs.hostingTab.save")}),t.jsx(Qe,{size:"sm",variant:"ghost",onClick:()=>S(null),disabled:D,children:n("mainPanelTabs.hostingTab.cancel")})]}):t.jsxs(t.Fragment,{children:[t.jsx(et,{label:n(st?"mainPanelTabs.hostingTab.hideValue":"mainPanelTabs.hostingTab.showValue"),onClick:()=>v(We),className:"text-muted-foreground",children:st?t.jsx(qs,{}):t.jsx(Ms,{})}),st?t.jsx("button",{type:"button",onClick:()=>{S({name:L.name,scope:Ne}),R(L.value)},title:n("mainPanelTabs.hostingTab.editValue"),className:"min-w-0 truncate px-1.5 py-0.5 text-right font-mono text-xs text-muted-foreground hover:bg-muted hover:text-foreground rounded-lg",children:L.value||"—"}):t.jsx("span",{className:"min-w-0 truncate px-1.5 py-0.5 text-right font-mono text-xs text-muted-foreground/60",children:L.value?"••••••••••":"—"})]})}),t.jsx(et,{label:n("mainPanelTabs.hostingTab.deleteVariable"),onClick:()=>j({name:L.name,scope:Ne}),disabled:D,className:"text-muted-foreground",children:t.jsx(vt,{})})]},We)}),c.length>0&&t.jsxs(Ht,{children:[t.jsx(Vs,{asChild:!0,children:t.jsxs("button",{type:"button",className:"group flex w-full items-center gap-2 px-4 py-2.5 text-left text-xs text-muted-foreground hover:bg-muted/40",children:[t.jsx(ns,{className:"size-4 transition-transform duration-200 group-data-[state=open]:rotate-90 motion-reduce:transition-none"}),t.jsx(Xt,{className:"size-4"}),n("mainPanelTabs.hostingTab.codeVarsToggle",{count:String(c.length)})]})}),t.jsx(Vt,{children:t.jsx("div",{className:"divide-y divide-border/60 border-t border-border bg-muted/30",children:c.map(Pn)})})]})]}),e[36]=te,e[37]=c,e[38]=y,e[39]=P?.name,e[40]=P?.scope,e[41]=i,e[42]=s,e[43]=p,e[44]=m,e[45]=D,e[46]=V,e[47]=n,e[48]=ie):ie=e[48];let Pe;e[49]===Symbol.for("react.memo_cache_sentinel")?(Pe=L=>{d(L),L||O()},e[49]=Pe):Pe=e[49];let Ce;e[50]!==n?(Ce=n("mainPanelTabs.hostingTab.addVariable"),e[50]=n,e[51]=Ce):Ce=e[51];let me;e[52]!==Ce?(me=t.jsx(yt,{children:t.jsx(St,{children:Ce})}),e[52]=Ce,e[53]=me):me=e[53];let pe;e[54]!==J?(pe=L=>{L.preventDefault(),J()},e[54]=J,e[55]=pe):pe=e[55];let le;e[56]!==n?(le=n("mainPanelTabs.hostingTab.colName"),e[56]=n,e[57]=le):le=e[57];let ae;e[58]!==le?(ae=t.jsx(Ge,{htmlFor:"env-name",children:le}),e[58]=le,e[59]=ae):ae=e[59];let de;e[60]!==n?(de=n("mainPanelTabs.hostingTab.envNamePlaceholder"),e[60]=n,e[61]=de):de=e[61];let De;e[62]===Symbol.for("react.memo_cache_sentinel")?(De=L=>u(L.target.value),e[62]=De):De=e[62];let fe;e[63]!==f||e[64]!==D||e[65]!==de?(fe=t.jsx(it,{id:"env-name",placeholder:de,value:f,onChange:De,className:"font-mono text-xs",autoComplete:"off",disabled:D}),e[63]=f,e[64]=D,e[65]=de,e[66]=fe):fe=e[66];let ue;e[67]!==ae||e[68]!==fe?(ue=t.jsxs("div",{className:"flex flex-col gap-2",children:[ae,fe]}),e[67]=ae,e[68]=fe,e[69]=ue):ue=e[69];let oe;e[70]!==n?(oe=n("mainPanelTabs.hostingTab.colValue"),e[70]=n,e[71]=oe):oe=e[71];let Te;e[72]!==oe?(Te=t.jsx(Ge,{htmlFor:"env-value",children:oe}),e[72]=oe,e[73]=Te):Te=e[73];let he;e[74]!==n?(he=n("mainPanelTabs.hostingTab.envValuePlaceholder"),e[74]=n,e[75]=he):he=e[75];let xe;e[76]===Symbol.for("react.memo_cache_sentinel")?(xe=L=>h(L.target.value),e[76]=xe):xe=e[76];let ve;e[77]!==g||e[78]!==D||e[79]!==he?(ve=t.jsx(it,{id:"env-value",placeholder:he,value:g,onChange:xe,className:"font-mono text-xs",autoComplete:"off",disabled:D}),e[77]=g,e[78]=D,e[79]=he,e[80]=ve):ve=e[80];let ye;e[81]!==Te||e[82]!==ve?(ye=t.jsxs("div",{className:"flex flex-col gap-2",children:[Te,ve]}),e[81]=Te,e[82]=ve,e[83]=ye):ye=e[83];let ge;e[84]!==n?(ge=n("mainPanelTabs.hostingTab.secretScope"),e[84]=n,e[85]=ge):ge=e[85];let re;e[86]!==ge?(re=t.jsx(Ge,{children:ge}),e[86]=ge,e[87]=re):re=e[87];let be;e[88]!==N||e[89]!==D?(be=t.jsx(Tn,{value:N,onChange:C,disabled:D,className:"w-full"}),e[88]=N,e[89]=D,e[90]=be):be=e[90];let we;e[91]!==N||e[92]!==n?(we=n(N==="build"?"mainPanelTabs.hostingTab.secretScopeBuildHint":"mainPanelTabs.hostingTab.secretScopeRuntimeHint"),e[91]=N,e[92]=n,e[93]=we):we=e[93];let $;e[94]!==we?($=t.jsx("p",{className:"text-xs text-muted-foreground",children:we}),e[94]=we,e[95]=$):$=e[95];let se;e[96]!==re||e[97]!==be||e[98]!==$?(se=t.jsxs("div",{className:"flex flex-col gap-2",children:[re,be,$]}),e[96]=re,e[97]=be,e[98]=$,e[99]=se):se=e[99];let Se;e[100]===Symbol.for("react.memo_cache_sentinel")?(Se=()=>{d(!1),O()},e[100]=Se):Se=e[100];let je;e[101]!==n?(je=n("mainPanelTabs.hostingTab.cancel"),e[101]=n,e[102]=je):je=e[102];let $e;e[103]!==D||e[104]!==je?($e=t.jsx(Qe,{variant:"outline",type:"button",onClick:Se,disabled:D,children:je}),e[103]=D,e[104]=je,e[105]=$e):$e=e[105];let ze;e[106]!==f||e[107]!==D?(ze=D||!f.trim(),e[106]=f,e[107]=D,e[108]=ze):ze=e[108];let Ue;e[109]!==D||e[110]!==n?(Ue=n(D?"mainPanelTabs.hostingTab.saving":"mainPanelTabs.hostingTab.add"),e[109]=D,e[110]=n,e[111]=Ue):Ue=e[111];let Le;e[112]!==ze||e[113]!==Ue?(Le=t.jsx(Qe,{type:"submit",disabled:ze,children:Ue}),e[112]=ze,e[113]=Ue,e[114]=Le):Le=e[114];let _e;e[115]!==$e||e[116]!==Le?(_e=t.jsxs(Nt,{children:[$e,Le]}),e[115]=$e,e[116]=Le,e[117]=_e):_e=e[117];let Be;e[118]!==pe||e[119]!==ue||e[120]!==ye||e[121]!==se||e[122]!==_e?(Be=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:pe,children:[ue,ye,se,_e]}),e[118]=pe,e[119]=ue,e[120]=ye,e[121]=se,e[122]=_e,e[123]=Be):Be=e[123];let Ve;e[124]!==me||e[125]!==Be?(Ve=t.jsxs(Ct,{className:"sm:max-w-md",children:[me,Be]}),e[124]=me,e[125]=Be,e[126]=Ve):Ve=e[126];let ke;e[127]!==b||e[128]!==Ve?(ke=t.jsx(Dt,{open:b,onOpenChange:Pe,children:Ve}),e[127]=b,e[128]=Ve,e[129]=ke):ke=e[129];const Je=w!=null;let He;e[130]===Symbol.for("react.memo_cache_sentinel")?(He=L=>{L||j(null)},e[130]=He):He=e[130];let Ee;e[131]!==n?(Ee=n("mainPanelTabs.hostingTab.confirmDeleteVariableTitle"),e[131]=n,e[132]=Ee):Ee=e[132];const Oe=w?.name??"";let qe;e[133]!==n||e[134]!==Oe?(qe=n("mainPanelTabs.hostingTab.confirmDeleteVariableDescription",{name:Oe}),e[133]=n,e[134]=Oe,e[135]=qe):qe=e[135];let Ke;e[136]!==n?(Ke=n("mainPanelTabs.hostingTab.deleteVariable"),e[136]=n,e[137]=Ke):Ke=e[137];let M;e[138]!==X||e[139]!==D||e[140]!==Je||e[141]!==Ee||e[142]!==qe||e[143]!==Ke?(M=t.jsx(wt,{open:Je,onOpenChange:He,title:Ee,description:qe,confirmLabel:Ke,pending:D,onConfirm:X}),e[138]=X,e[139]=D,e[140]=Je,e[141]=Ee,e[142]=qe,e[143]=Ke,e[144]=M):M=e[144];let Ye;return e[145]!==U||e[146]!==ne||e[147]!==ie||e[148]!==ke||e[149]!==M?(Ye=t.jsxs(ut,{title:U,actions:ne,children:[ie,ke,M]}),e[145]=U,e[146]=ne,e[147]=ie,e[148]=ke,e[149]=M,e[150]=Ye):Ye=e[150],Ye}function Pn(r){return t.jsxs("div",{className:"flex items-center gap-3 px-4 py-2 font-mono text-xs",children:[t.jsx("span",{className:"flex-1 basis-0 truncate",children:r.name}),t.jsx("span",{className:"flex-1 basis-0 truncate text-right text-muted-foreground",children:r.value})]},r.name)}function vn(r){return ce.error(rt(r))}function yn(r){const e=Z.c(6),{type:o}=r,l=Ae(),a=o==="permanent"?"secondary":"outline";let i;e[0]!==l||e[1]!==o?(i=l(o==="permanent"?"mainPanelTabs.hostingTab.permanent":"mainPanelTabs.hostingTab.temporary"),e[0]=l,e[1]=o,e[2]=i):i=e[2];let c;return e[3]!==a||e[4]!==i?(c=t.jsx(Re,{variant:a,children:i}),e[3]=a,e[4]=i,e[5]=c):c=e[5],c}function Sn(r){const e=Z.c(163),{base:o,orgSlug:l,site:a,redirects:i,isLoading:c,error:m}=r,s=Ae(),n=bt(),[x,b]=ee.useState(!1),[d,f]=ee.useState(null),[u,g]=ee.useState(""),[h,N]=ee.useState(""),[C,P]=ee.useState("permanent"),[S,y]=ee.useState(null),[R,w]=ee.useState(null);let j;e[0]!==l||e[1]!==n||e[2]!==a?(j=()=>n.invalidateQueries({queryKey:Xe.hostingRedirects(l,a)}),e[0]=l,e[1]=n,e[2]=a,e[3]=j):j=e[3];const T=j;let V;e[4]!==o?(V=z=>at(`${o}/redirects`,"PUT",z),e[4]=o,e[5]=V):V=e[5];let q;e[6]!==T||e[7]!==s?(q=()=>{T(),ce.success(s("mainPanelTabs.hostingTab.toastRedirectSaved")),b(!1)},e[6]=T,e[7]=s,e[8]=q):q=e[8];let F;e[9]!==V||e[10]!==q?(F={mutationFn:V,onSuccess:q,onError:Cn},e[9]=V,e[10]=q,e[11]=F):F=e[11];const v=lt(F);let H;e[12]!==o?(H=z=>at(`${o}/redirects/${encodeURIComponent(z)}`,"DELETE"),e[12]=o,e[13]=H):H=e[13];let A;e[14]!==T||e[15]!==s?(A=()=>{T(),ce.success(s("mainPanelTabs.hostingTab.toastRedirectDeleted")),y(null)},e[14]=T,e[15]=s,e[16]=A):A=e[16];let K;e[17]!==H||e[18]!==A?(K={mutationFn:H,onSuccess:A,onError:Nn},e[17]=H,e[18]=A,e[19]=K):K=e[19];const _=lt(K);let W;e[20]===Symbol.for("react.memo_cache_sentinel")?(W=()=>{f(null),g(""),N(""),P("permanent"),b(!0)},e[20]=W):W=e[20];const J=W;let Q;e[21]===Symbol.for("react.memo_cache_sentinel")?(Q=z=>{f(z.from),g(z.from),N(z.to),P(z.type==="temporary"?"temporary":"permanent"),b(!0)},e[21]=Q):Q=e[21];const p=Q;let I;e[22]!==u||e[23]!==h||e[24]!==C||e[25]!==v||e[26]!==s?(I=()=>{const z=u.trim(),Tt=h.trim();if(!z||!Tt){ce.error(s("mainPanelTabs.hostingTab.errorRedirectFieldsRequired"));return}v.mutate({from:z,to:Tt,type:C})},e[22]=u,e[23]=h,e[24]=C,e[25]=v,e[26]=s,e[27]=I):I=e[27];const X=I;let D;e[28]===Symbol.for("react.memo_cache_sentinel")?(D=t.jsx(Pt,{}),e[28]=D):D=e[28];let Y;e[29]!==s?(Y=s("mainPanelTabs.hostingTab.addRedirect"),e[29]=s,e[30]=Y):Y=e[30];let O;e[31]!==Y?(O=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:J,children:[D,Y]}),e[31]=Y,e[32]=O):O=e[32];const k=O;let E;e[33]!==s?(E=s("mainPanelTabs.hostingTab.redirects"),e[33]=s,e[34]=E):E=e[34];const B=i.length>0?k:void 0;let G;e[35]!==k||e[36]!==_.isPending||e[37]!==R||e[38]!==m||e[39]!==c||e[40]!==v.isPending||e[41]!==i||e[42]!==s?(G=c?t.jsx(ht,{}):m?t.jsx(Ie,{children:t.jsx(ot,{children:s("mainPanelTabs.hostingTab.redirectsError")})}):i.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Yt,{className:"size-5"}),title:s("mainPanelTabs.hostingTab.noRedirects"),className:"py-10",buttonComponent:k})}):t.jsx(Ie,{children:i.map((z,Tt)=>{const Ut=es(z.from),$t=R===z.from;return t.jsxs("div",{children:[t.jsxs(pt,{children:[Ut?t.jsx(Qt,{open:$t,onClick:()=>w($t?null:z.from)}):t.jsx(Yt,{className:"size-4 shrink-0 text-muted-foreground/60"}),t.jsxs("div",{className:"flex min-w-0 flex-1 items-center gap-2 font-mono text-xs",children:[t.jsx("span",{className:"truncate",children:z.from}),t.jsx(Is,{className:"size-3.5 shrink-0 text-muted-foreground/60"}),t.jsx("span",{className:"truncate text-muted-foreground",children:z.to})]}),t.jsx(yn,{type:z.type}),t.jsx(et,{label:s("mainPanelTabs.hostingTab.editRedirect"),onClick:()=>p(z),disabled:v.isPending,className:"text-muted-foreground",children:t.jsx(Ls,{})}),t.jsx(et,{label:s("mainPanelTabs.hostingTab.deleteRedirect"),onClick:()=>y(z.from),disabled:_.isPending,className:"-ml-1 text-muted-foreground",children:t.jsx(vt,{})})]}),Ut&&t.jsx(hs,{open:$t,children:t.jsx(ts,{from:z.from,source:z.source})})]},z.id??`${z.from}-${Tt}`)})}),e[35]=k,e[36]=_.isPending,e[37]=R,e[38]=m,e[39]=c,e[40]=v.isPending,e[41]=i,e[42]=s,e[43]=G):G=e[43];let te;e[44]!==d||e[45]!==s?(te=d!=null?s("mainPanelTabs.hostingTab.editRedirectTitle"):s("mainPanelTabs.hostingTab.addRedirectTitle"),e[44]=d,e[45]=s,e[46]=te):te=e[46];let U;e[47]!==te?(U=t.jsx(yt,{children:t.jsx(St,{children:te})}),e[47]=te,e[48]=U):U=e[48];let ne;e[49]!==X?(ne=z=>{z.preventDefault(),X()},e[49]=X,e[50]=ne):ne=e[50];let ie;e[51]!==s?(ie=s("mainPanelTabs.hostingTab.colFrom"),e[51]=s,e[52]=ie):ie=e[52];let Pe;e[53]!==ie?(Pe=t.jsx(Ge,{htmlFor:"redirect-from",children:ie}),e[53]=ie,e[54]=Pe):Pe=e[54];let Ce;e[55]!==s?(Ce=s("mainPanelTabs.hostingTab.redirectFromPlaceholder"),e[55]=s,e[56]=Ce):Ce=e[56];let me;e[57]===Symbol.for("react.memo_cache_sentinel")?(me=z=>g(z.target.value),e[57]=me):me=e[57];const pe=d!=null||v.isPending;let le;e[58]!==u||e[59]!==Ce||e[60]!==pe?(le=t.jsx(it,{id:"redirect-from",placeholder:Ce,value:u,onChange:me,className:"font-mono text-xs",disabled:pe}),e[58]=u,e[59]=Ce,e[60]=pe,e[61]=le):le=e[61];let ae;e[62]!==Pe||e[63]!==le?(ae=t.jsxs("div",{className:"flex flex-col gap-2",children:[Pe,le]}),e[62]=Pe,e[63]=le,e[64]=ae):ae=e[64];let de;e[65]!==s?(de=s("mainPanelTabs.hostingTab.colTo"),e[65]=s,e[66]=de):de=e[66];let De;e[67]!==de?(De=t.jsx(Ge,{htmlFor:"redirect-to",children:de}),e[67]=de,e[68]=De):De=e[68];let fe;e[69]!==s?(fe=s("mainPanelTabs.hostingTab.redirectToPlaceholder"),e[69]=s,e[70]=fe):fe=e[70];let ue;e[71]===Symbol.for("react.memo_cache_sentinel")?(ue=z=>N(z.target.value),e[71]=ue):ue=e[71];let oe;e[72]!==h||e[73]!==v.isPending||e[74]!==fe?(oe=t.jsx(it,{id:"redirect-to",placeholder:fe,value:h,onChange:ue,className:"font-mono text-xs",disabled:v.isPending}),e[72]=h,e[73]=v.isPending,e[74]=fe,e[75]=oe):oe=e[75];let Te;e[76]!==De||e[77]!==oe?(Te=t.jsxs("div",{className:"flex flex-col gap-2",children:[De,oe]}),e[76]=De,e[77]=oe,e[78]=Te):Te=e[78];let he;e[79]!==s?(he=s("mainPanelTabs.hostingTab.colType"),e[79]=s,e[80]=he):he=e[80];let xe;e[81]!==he?(xe=t.jsx(Ge,{children:he}),e[81]=he,e[82]=xe):xe=e[82];let ve;e[83]===Symbol.for("react.memo_cache_sentinel")?(ve=z=>P(z==="temporary"?"temporary":"permanent"),e[83]=ve):ve=e[83];const ye=v.isPending;let ge;e[84]===Symbol.for("react.memo_cache_sentinel")?(ge=t.jsx(Ot,{className:"w-full",children:t.jsx(Bt,{})}),e[84]=ge):ge=e[84];let re;e[85]!==s?(re=s("mainPanelTabs.hostingTab.permanent"),e[85]=s,e[86]=re):re=e[86];let be;e[87]!==re?(be=t.jsx(ft,{value:"permanent",children:re}),e[87]=re,e[88]=be):be=e[88];let we;e[89]!==s?(we=s("mainPanelTabs.hostingTab.temporary"),e[89]=s,e[90]=we):we=e[90];let $;e[91]!==we?($=t.jsx(ft,{value:"temporary",children:we}),e[91]=we,e[92]=$):$=e[92];let se;e[93]!==be||e[94]!==$?(se=t.jsxs(qt,{children:[be,$]}),e[93]=be,e[94]=$,e[95]=se):se=e[95];let Se;e[96]!==C||e[97]!==v.isPending||e[98]!==se?(Se=t.jsxs(Mt,{value:C,onValueChange:ve,disabled:ye,children:[ge,se]}),e[96]=C,e[97]=v.isPending,e[98]=se,e[99]=Se):Se=e[99];let je;e[100]!==xe||e[101]!==Se?(je=t.jsxs("div",{className:"flex flex-col gap-2",children:[xe,Se]}),e[100]=xe,e[101]=Se,e[102]=je):je=e[102];let $e;e[103]!==d||e[104]!==u||e[105]!==i?($e=es(u)&&t.jsx("div",{className:"rounded-lg border border-border bg-muted/30 p-3",children:t.jsx(ts,{from:u,source:i.find(z=>z.from===d)?.source})}),e[103]=d,e[104]=u,e[105]=i,e[106]=$e):$e=e[106];let ze;e[107]===Symbol.for("react.memo_cache_sentinel")?(ze=()=>b(!1),e[107]=ze):ze=e[107];const Ue=v.isPending;let Le;e[108]!==s?(Le=s("mainPanelTabs.hostingTab.cancel"),e[108]=s,e[109]=Le):Le=e[109];let _e;e[110]!==v.isPending||e[111]!==Le?(_e=t.jsx(Qe,{variant:"outline",type:"button",onClick:ze,disabled:Ue,children:Le}),e[110]=v.isPending,e[111]=Le,e[112]=_e):_e=e[112];let Be;e[113]!==u||e[114]!==h||e[115]!==v.isPending?(Be=v.isPending||!u.trim()||!h.trim(),e[113]=u,e[114]=h,e[115]=v.isPending,e[116]=Be):Be=e[116];let Ve;e[117]!==v.isPending||e[118]!==s?(Ve=v.isPending?s("mainPanelTabs.hostingTab.saving"):s("mainPanelTabs.hostingTab.save"),e[117]=v.isPending,e[118]=s,e[119]=Ve):Ve=e[119];let ke;e[120]!==Be||e[121]!==Ve?(ke=t.jsx(Qe,{type:"submit",disabled:Be,children:Ve}),e[120]=Be,e[121]=Ve,e[122]=ke):ke=e[122];let Je;e[123]!==_e||e[124]!==ke?(Je=t.jsxs(Nt,{children:[_e,ke]}),e[123]=_e,e[124]=ke,e[125]=Je):Je=e[125];let He;e[126]!==ne||e[127]!==ae||e[128]!==Te||e[129]!==je||e[130]!==$e||e[131]!==Je?(He=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:ne,children:[ae,Te,je,$e,Je]}),e[126]=ne,e[127]=ae,e[128]=Te,e[129]=je,e[130]=$e,e[131]=Je,e[132]=He):He=e[132];let Ee;e[133]!==U||e[134]!==He?(Ee=t.jsxs(Ct,{className:"sm:max-w-md",children:[U,He]}),e[133]=U,e[134]=He,e[135]=Ee):Ee=e[135];let Oe;e[136]!==x||e[137]!==Ee?(Oe=t.jsx(Dt,{open:x,onOpenChange:b,children:Ee}),e[136]=x,e[137]=Ee,e[138]=Oe):Oe=e[138];const qe=S!=null;let Ke;e[139]===Symbol.for("react.memo_cache_sentinel")?(Ke=z=>{z||y(null)},e[139]=Ke):Ke=e[139];let M;e[140]!==s?(M=s("mainPanelTabs.hostingTab.confirmDeleteRedirectTitle"),e[140]=s,e[141]=M):M=e[141];const Ye=S??"";let L;e[142]!==s||e[143]!==Ye?(L=s("mainPanelTabs.hostingTab.confirmDeleteRedirectDescription",{from:Ye}),e[142]=s,e[143]=Ye,e[144]=L):L=e[144];let Ne;e[145]!==s?(Ne=s("mainPanelTabs.hostingTab.deleteRedirect"),e[145]=s,e[146]=Ne):Ne=e[146];let We;e[147]!==_||e[148]!==S?(We=()=>{S&&_.mutate(S)},e[147]=_,e[148]=S,e[149]=We):We=e[149];let tt;e[150]!==_.isPending||e[151]!==qe||e[152]!==M||e[153]!==L||e[154]!==Ne||e[155]!==We?(tt=t.jsx(wt,{open:qe,onOpenChange:Ke,title:M,description:L,confirmLabel:Ne,pending:_.isPending,onConfirm:We}),e[150]=_.isPending,e[151]=qe,e[152]=M,e[153]=L,e[154]=Ne,e[155]=We,e[156]=tt):tt=e[156];let st;return e[157]!==E||e[158]!==B||e[159]!==G||e[160]!==Oe||e[161]!==tt?(st=t.jsxs(ut,{title:E,actions:B,children:[G,Oe,tt]}),e[157]=E,e[158]=B,e[159]=G,e[160]=Oe,e[161]=tt,e[162]=st):st=e[162],st}function Nn(r){return ce.error(rt(r))}function Cn(r){return ce.error(rt(r))}function Dn(r){const e=Z.c(160),{base:o,orgSlug:l,site:a,secrets:i,isLoading:c,error:m}=r,s=Ae(),n=bt(),[x,b]=ee.useState(!1),[d,f]=ee.useState(""),[u,g]=ee.useState(""),[h,N]=ee.useState("runtime"),[C,P]=ee.useState(null);let S;e[0]!==l||e[1]!==n||e[2]!==a?(S=()=>n.invalidateQueries({queryKey:Xe.hostingSecrets(l,a)}),e[0]=l,e[1]=n,e[2]=a,e[3]=S):S=e[3];const y=S;let R;e[4]!==o?(R=M=>at(`${o}/secrets`,"PUT",M),e[4]=o,e[5]=R):R=e[5];let w;e[6]!==y||e[7]!==s?(w=()=>{y(),ce.success(s("mainPanelTabs.hostingTab.toastSecretSaved")),b(!1),f(""),g(""),N("runtime")},e[6]=y,e[7]=s,e[8]=w):w=e[8];let j;e[9]!==R||e[10]!==w?(j={mutationFn:R,onSuccess:w,onError:$n},e[9]=R,e[10]=w,e[11]=j):j=e[11];const T=lt(j);let V;e[12]!==o?(V=M=>at(`${o}/secrets/${encodeURIComponent(M.name)}?scope=${M.scope}`,"DELETE"),e[12]=o,e[13]=V):V=e[13];let q;e[14]!==y||e[15]!==s?(q=()=>{y(),ce.success(s("mainPanelTabs.hostingTab.toastSecretDeleted")),P(null)},e[14]=y,e[15]=s,e[16]=q):q=e[16];let F;e[17]!==V||e[18]!==q?(F={mutationFn:V,onSuccess:q,onError:wn},e[17]=V,e[18]=q,e[19]=F):F=e[19];const v=lt(F);let H;e[20]!==d||e[21]!==h||e[22]!==u||e[23]!==T||e[24]!==s?(H=()=>{const M=d.trim();if(!M){ce.error(s("mainPanelTabs.hostingTab.errorSecretNameRequired"));return}if(!u){ce.error(s("mainPanelTabs.hostingTab.errorSecretValueRequired"));return}T.mutate({name:M,value:u,scope:h})},e[20]=d,e[21]=h,e[22]=u,e[23]=T,e[24]=s,e[25]=H):H=e[25];const A=H;let K,_;e[26]===Symbol.for("react.memo_cache_sentinel")?(_=()=>b(!0),K=t.jsx(Pt,{}),e[26]=K,e[27]=_):(K=e[26],_=e[27]);let W;e[28]!==s?(W=s("mainPanelTabs.hostingTab.addSecret"),e[28]=s,e[29]=W):W=e[29];let J;e[30]!==W?(J=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:_,children:[K,W]}),e[30]=W,e[31]=J):J=e[31];const Q=J;let p;e[32]!==s?(p=s("mainPanelTabs.hostingTab.secrets"),e[32]=s,e[33]=p):p=e[33];const I=i.length>0?Q:void 0;let X;e[34]!==Q||e[35]!==v.isPending||e[36]!==m||e[37]!==c||e[38]!==i||e[39]!==s?(X=c?t.jsx(ht,{}):m?t.jsx(Ie,{children:t.jsx(ot,{children:s("mainPanelTabs.hostingTab.secretsError")})}):i.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Wt,{className:"size-5"}),title:s("mainPanelTabs.hostingTab.noSecrets"),className:"py-10",buttonComponent:Q})}):t.jsx(Ie,{children:i.map(M=>{const Ye=M.scope==="build"?"build":"runtime";return t.jsxs(pt,{children:[t.jsx(Wt,{className:"size-4 shrink-0 text-muted-foreground/60"}),t.jsxs("div",{className:"flex min-w-0 flex-1 items-center gap-2",children:[t.jsx("div",{className:"w-20 shrink-0",children:t.jsx(xs,{scope:Ye})}),t.jsx("span",{className:"truncate font-mono text-xs",children:M.name}),M.origin==="worker"&&t.jsx(Re,{variant:"secondary",children:s("mainPanelTabs.hostingTab.secretOnWorker")})]}),t.jsx("span",{className:"font-mono text-xs text-muted-foreground/60",children:s("mainPanelTabs.hostingTab.secretValueHidden")}),t.jsx(et,{label:s("mainPanelTabs.hostingTab.deleteSecret"),onClick:()=>P({name:M.name,scope:Ye}),disabled:v.isPending,className:"text-muted-foreground",children:t.jsx(vt,{})})]},`${M.name}:${Ye}`)})}),e[34]=Q,e[35]=v.isPending,e[36]=m,e[37]=c,e[38]=i,e[39]=s,e[40]=X):X=e[40];let D;e[41]!==s?(D=s("mainPanelTabs.hostingTab.addSecretTitle"),e[41]=s,e[42]=D):D=e[42];let Y;e[43]!==D?(Y=t.jsx(yt,{children:t.jsx(St,{children:D})}),e[43]=D,e[44]=Y):Y=e[44];let O;e[45]!==A?(O=M=>{M.preventDefault(),A()},e[45]=A,e[46]=O):O=e[46];let k;e[47]!==s?(k=s("mainPanelTabs.hostingTab.colName"),e[47]=s,e[48]=k):k=e[48];let E;e[49]!==k?(E=t.jsx(Ge,{htmlFor:"secret-name",children:k}),e[49]=k,e[50]=E):E=e[50];let B;e[51]!==s?(B=s("mainPanelTabs.hostingTab.secretNamePlaceholder"),e[51]=s,e[52]=B):B=e[52];let G;e[53]===Symbol.for("react.memo_cache_sentinel")?(G=M=>f(M.target.value),e[53]=G):G=e[53];let te;e[54]!==d||e[55]!==T.isPending||e[56]!==B?(te=t.jsx(it,{id:"secret-name",placeholder:B,value:d,onChange:G,className:"font-mono text-xs",autoComplete:"off",disabled:T.isPending}),e[54]=d,e[55]=T.isPending,e[56]=B,e[57]=te):te=e[57];let U;e[58]!==E||e[59]!==te?(U=t.jsxs("div",{className:"flex flex-col gap-2",children:[E,te]}),e[58]=E,e[59]=te,e[60]=U):U=e[60];let ne;e[61]!==s?(ne=s("mainPanelTabs.hostingTab.colValue"),e[61]=s,e[62]=ne):ne=e[62];let ie;e[63]!==ne?(ie=t.jsx(Ge,{htmlFor:"secret-value",children:ne}),e[63]=ne,e[64]=ie):ie=e[64];let Pe;e[65]!==s?(Pe=s("mainPanelTabs.hostingTab.secretValuePlaceholder"),e[65]=s,e[66]=Pe):Pe=e[66];let Ce;e[67]===Symbol.for("react.memo_cache_sentinel")?(Ce=M=>g(M.target.value),e[67]=Ce):Ce=e[67];let me;e[68]!==u||e[69]!==T.isPending||e[70]!==Pe?(me=t.jsx(it,{id:"secret-value",type:"password",placeholder:Pe,value:u,onChange:Ce,className:"font-mono text-xs",autoComplete:"new-password",disabled:T.isPending}),e[68]=u,e[69]=T.isPending,e[70]=Pe,e[71]=me):me=e[71];let pe;e[72]!==ie||e[73]!==me?(pe=t.jsxs("div",{className:"flex flex-col gap-2",children:[ie,me]}),e[72]=ie,e[73]=me,e[74]=pe):pe=e[74];let le;e[75]!==s?(le=s("mainPanelTabs.hostingTab.secretScope"),e[75]=s,e[76]=le):le=e[76];let ae;e[77]!==le?(ae=t.jsx(Ge,{children:le}),e[77]=le,e[78]=ae):ae=e[78];let de;e[79]===Symbol.for("react.memo_cache_sentinel")?(de=M=>N(M==="build"?"build":"runtime"),e[79]=de):de=e[79];const De=T.isPending;let fe;e[80]===Symbol.for("react.memo_cache_sentinel")?(fe=t.jsx(Ot,{className:"w-full",children:t.jsx(Bt,{})}),e[80]=fe):fe=e[80];let ue;e[81]!==s?(ue=s("mainPanelTabs.hostingTab.secretScopeRuntime"),e[81]=s,e[82]=ue):ue=e[82];let oe;e[83]!==ue?(oe=t.jsx(ft,{value:"runtime",children:ue}),e[83]=ue,e[84]=oe):oe=e[84];let Te;e[85]!==s?(Te=s("mainPanelTabs.hostingTab.secretScopeBuild"),e[85]=s,e[86]=Te):Te=e[86];let he;e[87]!==Te?(he=t.jsx(ft,{value:"build",children:Te}),e[87]=Te,e[88]=he):he=e[88];let xe;e[89]!==oe||e[90]!==he?(xe=t.jsxs(qt,{children:[oe,he]}),e[89]=oe,e[90]=he,e[91]=xe):xe=e[91];let ve;e[92]!==h||e[93]!==T.isPending||e[94]!==xe?(ve=t.jsxs(Mt,{value:h,onValueChange:de,disabled:De,children:[fe,xe]}),e[92]=h,e[93]=T.isPending,e[94]=xe,e[95]=ve):ve=e[95];let ye;e[96]!==h||e[97]!==s?(ye=s(h==="build"?"mainPanelTabs.hostingTab.secretScopeBuildHint":"mainPanelTabs.hostingTab.secretScopeRuntimeHint"),e[96]=h,e[97]=s,e[98]=ye):ye=e[98];let ge;e[99]!==ye?(ge=t.jsx("p",{className:"text-xs text-muted-foreground",children:ye}),e[99]=ye,e[100]=ge):ge=e[100];let re;e[101]!==ae||e[102]!==ve||e[103]!==ge?(re=t.jsxs("div",{className:"flex flex-col gap-2",children:[ae,ve,ge]}),e[101]=ae,e[102]=ve,e[103]=ge,e[104]=re):re=e[104];let be;e[105]===Symbol.for("react.memo_cache_sentinel")?(be=()=>b(!1),e[105]=be):be=e[105];const we=T.isPending;let $;e[106]!==s?($=s("mainPanelTabs.hostingTab.cancel"),e[106]=s,e[107]=$):$=e[107];let se;e[108]!==T.isPending||e[109]!==$?(se=t.jsx(Qe,{variant:"outline",type:"button",onClick:be,disabled:we,children:$}),e[108]=T.isPending,e[109]=$,e[110]=se):se=e[110];let Se;e[111]!==d||e[112]!==u||e[113]!==T.isPending?(Se=T.isPending||!d.trim()||!u,e[111]=d,e[112]=u,e[113]=T.isPending,e[114]=Se):Se=e[114];let je;e[115]!==T.isPending||e[116]!==s?(je=T.isPending?s("mainPanelTabs.hostingTab.saving"):s("mainPanelTabs.hostingTab.add"),e[115]=T.isPending,e[116]=s,e[117]=je):je=e[117];let $e;e[118]!==Se||e[119]!==je?($e=t.jsx(Qe,{type:"submit",disabled:Se,children:je}),e[118]=Se,e[119]=je,e[120]=$e):$e=e[120];let ze;e[121]!==se||e[122]!==$e?(ze=t.jsxs(Nt,{children:[se,$e]}),e[121]=se,e[122]=$e,e[123]=ze):ze=e[123];let Ue;e[124]!==O||e[125]!==U||e[126]!==pe||e[127]!==re||e[128]!==ze?(Ue=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:O,children:[U,pe,re,ze]}),e[124]=O,e[125]=U,e[126]=pe,e[127]=re,e[128]=ze,e[129]=Ue):Ue=e[129];let Le;e[130]!==Y||e[131]!==Ue?(Le=t.jsxs(Ct,{className:"sm:max-w-md",children:[Y,Ue]}),e[130]=Y,e[131]=Ue,e[132]=Le):Le=e[132];let _e;e[133]!==x||e[134]!==Le?(_e=t.jsx(Dt,{open:x,onOpenChange:b,children:Le}),e[133]=x,e[134]=Le,e[135]=_e):_e=e[135];const Be=C!=null;let Ve;e[136]===Symbol.for("react.memo_cache_sentinel")?(Ve=M=>{M||P(null)},e[136]=Ve):Ve=e[136];let ke;e[137]!==s?(ke=s("mainPanelTabs.hostingTab.confirmDeleteSecretTitle"),e[137]=s,e[138]=ke):ke=e[138];const Je=C?.name??"";let He;e[139]!==s||e[140]!==Je?(He=s("mainPanelTabs.hostingTab.confirmDeleteSecretDescription",{name:Je}),e[139]=s,e[140]=Je,e[141]=He):He=e[141];let Ee;e[142]!==s?(Ee=s("mainPanelTabs.hostingTab.deleteSecret"),e[142]=s,e[143]=Ee):Ee=e[143];let Oe;e[144]!==v||e[145]!==C?(Oe=()=>{C&&v.mutate(C)},e[144]=v,e[145]=C,e[146]=Oe):Oe=e[146];let qe;e[147]!==v.isPending||e[148]!==Be||e[149]!==ke||e[150]!==He||e[151]!==Ee||e[152]!==Oe?(qe=t.jsx(wt,{open:Be,onOpenChange:Ve,title:ke,description:He,confirmLabel:Ee,pending:v.isPending,onConfirm:Oe}),e[147]=v.isPending,e[148]=Be,e[149]=ke,e[150]=He,e[151]=Ee,e[152]=Oe,e[153]=qe):qe=e[153];let Ke;return e[154]!==p||e[155]!==I||e[156]!==X||e[157]!==_e||e[158]!==qe?(Ke=t.jsxs(ut,{title:p,actions:I,children:[X,_e,qe]}),e[154]=p,e[155]=I,e[156]=X,e[157]=_e,e[158]=qe,e[159]=Ke):Ke=e[159],Ke}function wn(r){return ce.error(rt(r))}function $n(r){return ce.error(rt(r))}const Ln=3e4;function _n(r){const e=Z.c(111),{virtualMcpId:o}=r,l=Ae(),{org:a}=js(),i=ys(o),c=Ss(i),m=!!c,s=c?`/api/${a.slug}/hosting/${encodeURIComponent(c)}`:"";let n;e[0]!==s||e[1]!==m?(n=(O,k)=>({queryKey:O,queryFn:()=>Kt(`${s}${k}`),enabled:m,retry:!1,staleTime:Ln}),e[0]=s,e[1]=m,e[2]=n):n=e[2];const x=n,b=c??"",d=ct(x(Xe.hostingDeployments(a.slug,b),"/deployments")),f=ct(x(Xe.hostingEnv(a.slug,b),"/env")),u=ct(x(Xe.hostingSecrets(a.slug,b),"/secrets")),g=ct(x(Xe.hostingRedirects(a.slug,b),"/redirects")),h=ct(x(Xe.hostingDomains(a.slug,b),"/domains"));if(!c){let O;e[3]===Symbol.for("react.memo_cache_sentinel")?(O=t.jsx(_t,{className:"size-5"}),e[3]=O):O=e[3];let k;e[4]!==l?(k=l("mainPanelTabs.hostingTab.noSiteTitle"),e[4]=l,e[5]=k):k=e[5];let E;e[6]!==l?(E=l("mainPanelTabs.hostingTab.noSiteDescription"),e[6]=l,e[7]=E):E=e[7];let B;return e[8]!==k||e[9]!==E?(B=t.jsx("div",{className:"flex flex-1 items-center justify-center p-6",children:t.jsx(Ze,{icon:O,title:k,description:E})}),e[8]=k,e[9]=E,e[10]=B):B=e[10],B}if(jt(d.error)&&jt(f.error)&&jt(g.error)){let O;e[11]===Symbol.for("react.memo_cache_sentinel")?(O=t.jsx(_t,{className:"size-5"}),e[11]=O):O=e[11];let k;e[12]!==l?(k=l("mainPanelTabs.hostingTab.notConnectedTitle"),e[12]=l,e[13]=k):k=e[13];let E;e[14]!==l?(E=l("mainPanelTabs.hostingTab.notConnectedDescription"),e[14]=l,e[15]=E):E=e[15];let B;return e[16]!==k||e[17]!==E?(B=t.jsx("div",{className:"flex flex-1 items-center justify-center p-6",children:t.jsx(Ze,{icon:O,title:k,description:E})}),e[16]=k,e[17]=E,e[18]=B):B=e[18],B}let C,P,S,y,R,w,j,T,V,q;if(e[19]!==d.data||e[20]!==h.data||e[21]!==f.data||e[22]!==g.data||e[23]!==u.data){P=mt(d.data,"items");let O;e[34]!==f.data?(O=mt(f.data,"vars"),e[34]=f.data,e[35]=O):O=e[35],R=O;let k;e[36]!==f.data?(k=mt(f.data,"codeVars"),e[36]=f.data,e[37]=k):k=e[37],C=k;let E;e[38]!==u.data?(E=mt(u.data,"secrets"),e[38]=u.data,e[39]=E):E=e[39],V=E;let B;e[40]!==g.data?(B=mt(g.data,"items"),e[40]=g.data,e[41]=B):B=e[41],T=B;const G=h.data;let te;e[42]!==G?.items?(te=G?.items??[],e[42]=G?.items,e[43]=te):te=e[43],y=te;let U;e[44]!==G?.dnsTemplate?(U=G?.dnsTemplate??[],e[44]=G?.dnsTemplate,e[45]=U):U=e[45],S=U;const ne=P.find(En);w=zt((ne??P.find(kn))?.framework),j=ne?.servingUrl??null,q=j?j.replace(/^https?:\/\//,"").replace(/\/$/,""):null,e[19]=d.data,e[20]=h.data,e[21]=f.data,e[22]=g.data,e[23]=u.data,e[24]=C,e[25]=P,e[26]=S,e[27]=y,e[28]=R,e[29]=w,e[30]=j,e[31]=T,e[32]=V,e[33]=q}else C=e[24],P=e[25],S=e[26],y=e[27],R=e[28],w=e[29],j=e[30],T=e[31],V=e[32],q=e[33];const F=q;let v;e[46]!==s||e[47]!==a.slug||e[48]!==c?(v=t.jsx(tn,{base:s,orgSlug:a.slug,site:c}),e[46]=s,e[47]=a.slug,e[48]=c,e[49]=v):v=e[49];let H;e[50]!==l?(H=l("mainPanelTabs.hostingTab.title"),e[50]=l,e[51]=H):H=e[51];let A;e[52]!==w?(A=w&&t.jsx(Re,{variant:"secondary",children:w}),e[52]=w,e[53]=A):A=e[53];let K;e[54]!==H||e[55]!==A?(K=t.jsxs("span",{className:"inline-flex items-center gap-2.5",children:[H,A]}),e[54]=H,e[55]=A,e[56]=K):K=e[56];let _;e[57]!==v||e[58]!==K?(_=t.jsx(Jt.Title,{actions:v,children:K}),e[57]=v,e[58]=K,e[59]=_):_=e[59];let W;e[60]!==F||e[61]!==j?(W=j&&F&&t.jsx("p",{className:"flex flex-wrap items-center gap-x-1.5 text-sm text-muted-foreground",children:t.jsxs("a",{href:j,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-1 font-mono text-xs text-foreground hover:underline",children:[F,t.jsx(kt,{className:"size-3"})]})}),e[60]=F,e[61]=j,e[62]=W):W=e[62];let J;e[63]!==_||e[64]!==W?(J=t.jsxs("div",{className:"flex flex-col gap-2",children:[_,W]}),e[63]=_,e[64]=W,e[65]=J):J=e[65];let Q;e[66]!==s||e[67]!==P||e[68]!==d.error||e[69]!==d.isLoading||e[70]!==m||e[71]!==a.slug||e[72]!==c?(Q=t.jsx(rn,{base:s,orgSlug:a.slug,site:c,enabled:m,deployments:P,isLoading:d.isLoading,error:d.error}),e[66]=s,e[67]=P,e[68]=d.error,e[69]=d.isLoading,e[70]=m,e[71]=a.slug,e[72]=c,e[73]=Q):Q=e[73];let p;e[74]!==s||e[75]!==C||e[76]!==f.error||e[77]!==f.isLoading||e[78]!==R||e[79]!==a.slug||e[80]!==c?(p=t.jsx(jn,{base:s,orgSlug:a.slug,site:c,envVars:R,codeVars:C,isLoading:f.isLoading,error:f.error}),e[74]=s,e[75]=C,e[76]=f.error,e[77]=f.isLoading,e[78]=R,e[79]=a.slug,e[80]=c,e[81]=p):p=e[81];let I;e[82]!==s||e[83]!==a.slug||e[84]!==V||e[85]!==u.error||e[86]!==u.isLoading||e[87]!==c?(I=t.jsx(Dn,{base:s,orgSlug:a.slug,site:c,secrets:V,isLoading:u.isLoading,error:u.error}),e[82]=s,e[83]=a.slug,e[84]=V,e[85]=u.error,e[86]=u.isLoading,e[87]=c,e[88]=I):I=e[88];let X;e[89]!==s||e[90]!==S||e[91]!==y||e[92]!==h.error||e[93]!==h.isLoading||e[94]!==a.slug||e[95]!==c?(X=t.jsx(gn,{base:s,orgSlug:a.slug,site:c,domains:y,dnsTemplate:S,isLoading:h.isLoading,error:h.error}),e[89]=s,e[90]=S,e[91]=y,e[92]=h.error,e[93]=h.isLoading,e[94]=a.slug,e[95]=c,e[96]=X):X=e[96];let D;e[97]!==s||e[98]!==a.slug||e[99]!==T||e[100]!==g.error||e[101]!==g.isLoading||e[102]!==c?(D=t.jsx(Sn,{base:s,orgSlug:a.slug,site:c,redirects:T,isLoading:g.isLoading,error:g.error}),e[97]=s,e[98]=a.slug,e[99]=T,e[100]=g.error,e[101]=g.isLoading,e[102]=c,e[103]=D):D=e[103];let Y;return e[104]!==Q||e[105]!==p||e[106]!==I||e[107]!==X||e[108]!==D||e[109]!==J?(Y=t.jsx("div",{className:"h-full min-h-0 overflow-y-auto",children:t.jsx(Jt.Container,{width:"standard",children:t.jsxs(Ps,{children:[J,Q,p,I,X,D]})})}),e[104]=Q,e[105]=p,e[106]=I,e[107]=X,e[108]=D,e[109]=J,e[110]=Y):Y=e[110],Y}function kn(r){return r.framework}function En(r){return r.up===!0}function Rn(){const r=Z.c(3),e=Us(),o=Qs();let l;return r[0]!==o.hosting||r[1]!==e?(l=o.hosting?t.jsx(_n,{virtualMcpId:e}):t.jsx(Ks,{virtualMcpId:e}),r[0]=o.hosting,r[1]=e,r[2]=l):l=r[2],l}function na(){const r=Z.c(1);let e;return r[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(vs.Content,{children:t.jsx(Rn,{})}),r[0]=e):e=r[0],e}export{na as default};
|
|
1
|
+
import{c as Z,j as t,l as xt,b as Ae,aS as dt,e_ as ps,ak as ns,ec as Ts,t as ce,o as bt,r as ee,e as lt,B as Qe,m as ct,K as Xe,ab as _t,a7 as Wt,X as js,n as Jt,fn as Ps}from"./index-Creb5Fal.js";import{C as vs}from"./index-YPpUZW2G.js";import{n as kt}from"./LinkExternal01-mH0kFM32.js";import{B as Re}from"./badge-lEq6LpEb.js";import{E as Ze}from"./empty-state-CwuzKy1b.js";import{a as ys}from"./repository-binding-BDRDBDUT.js";import{r as Ss}from"./site-slug-DebpOoQq.js";import{i as Ns}from"./AlertCircle-CfHvNlgZ.js";import{bn as Cs,bo as is,K as Ds,aA as ws,bp as $s,b as Et,aB as Xt,W as Yt,b7 as Ls}from"./agent-icon-Cs5o_QD_.js";import{h as gt}from"./UserSquare-BZc1G4LK.js";import{i as _s}from"./ZoomOut-BvLQLuGR.js";import{A as ls,a as as,b as os,c as rs,g as cs,d as ms,e as ds,f as fs}from"./alert-dialog-BZP1AD0I.js";import{I as et}from"./icon-button-D4H5x94G.js";import{S as ks,c as Es,a as Rs,b as Fs}from"./sheet-Dsh1DGgw.js";import{T as As,b as nt,c as Fe,e as Rt,a as Ft,d as At}from"./table-BbevayqW.js";import{a as zs}from"./Copy01-DJrDIAgF.js";import{a as Vt,b as Ht,C as Vs}from"./collapsible-BMQj5Dup.js";import{s as Pt}from"./Plus-HBSdQYLn.js";import{s as vt}from"./Trash01-C7BGYPNB.js";import{c as yt,d as St,e as Nt,b as Ct,D as Dt}from"./dialog-BK1Ueu93.js";import{I as it}from"./input-BKlAoViI.js";import{L as Ge}from"./label-ycBnzzff.js";import{T as Hs,a as Bs,b as Os}from"./tooltip-D_rDETL5.js";import{b as qs}from"./Tool01-Dz-lp6mO.js";import{s as Ms}from"./Image01-Ccx9C_Rg.js";import{a as Bt,b as Ot,c as ft,d as qt,S as Mt}from"./select-DUxatCDi.js";import{i as Is}from"./LinkBroken01-xKKRxXlY.js";import{S as Ks}from"./settings-tab-DqEufUIw.js";import{b as Qs}from"./use-organization-settings-B56H80YG.js";import{b as Us}from"./thread-route-BtUAL8zM.js";import"./use-mobile-CfSbfoft.js";import"./thread-button-BRy_z3r1.js";import"./use-chat-layout-state-DtSzju1r.js";import"./use-file-configs-CeiMSMu5.js";import"./use-panel-navigate-C7k_IWwP.js";import"./use-project-scope-D3SRaEYd.js";import"./thread-intent-BOEFGlMm.js";import"./use-mcp-client-DrDmZDA7.js";import"./auth-C1mOz7Cp.js";import"./backoff-8mStPHYB.js";import"./task-board-DXD3aKXi.js";import"./schema-DsftfWql.js";import"./slugify-CEUa2lfQ.js";import"./toolbar-icon-button-B_si7l6J.js";import"./shell-layout-DrF9YflL.js";import"./avatar-BIv_2mLm.js";import"./User01-COdLotsN.js";import"./Building02-Bqa8ze-O.js";import"./XClose-CYHY5GcG.js";import"./download-app-dialog-wOlBcsxc.js";import"./Check-COzQ04E7.js";import"./CheckCircle-Vb-xyxhE.js";import"./Monitor01-PBPlMgWr.js";import"./use-clock-tick-B6RjlwGP.js";import"./command-BzdiaYU5.js";import"./index-DrzDi7N3.js";import"./SearchMd-BBjcQIvr.js";import"./integration-icon-DhFk0v8h.js";import"./project-icon-DYsLOXub.js";import"./new-project-dialog-DrxiqG-Y.js";import"./ArrowLeft-Bj2Vh3jF.js";import"./repository-import-picker-COhtx-GU.js";import"./use-navigate-to-agent-CPmL7r2a.js";import"./repository-picker-CsXpKrPD.js";import"./useInfiniteQuery-S6GnLytU.js";import"./infiniteQueryObserver-D3SNQDlh.js";import"./collection-search-DUZsfox8.js";import"./ShoppingBag01-CdLvneJ1.js";import"./use-debounced-value-BXmvwHes.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-CPsT8IBO.js";import"./autosend-BiJfUQUT.js";import"./use-org-sso-D5wnNfkO.js";import"./resizable-xF5MDTwK.js";import"./ArrowUp-BDwJ6lSJ.js";import"./ChevronUp-RdnkaZaK.js";import"./CreditCard01-N4OPgVDg.js";import"./DotsVertical-D5rr2YQm.js";import"./Palette-KCM9-De7.js";import"./Key01-B1Y8yy7Z.js";import"./Link01-Bh_PC3dO.js";import"./Sun-BpeW1MoX.js";import"./Upload01-Crj-EmOO.js";import"./Users01-6Yj_4D_n.js";import"./X-BpUF7FNJ.js";import"./index-hVDNPnIj.js";import"./extract-connection-data-lBq634kY.js";import"./metadata-D72DunRR.js";import"./connection-Byk90CG2.js";import"./chat-context-CuWiXF8M.js";import"./use-decopilot-events-xg-lzK_6.js";import"./use-ai-providers-BY6SYGnL.js";import"./location-DPIrGNp7.js";import"./build-improve-prompt-doc-CbZ5gHs3.js";import"./empty-state-B5HnsrMX.js";import"./use-date-fns-locale-xsNp9_jV.js";import"./differenceInSeconds-C3x8sHUj.js";import"./use-connection-BdXCXco4.js";import"./mcp-oauth-DvzBEl8t.js";import"./textarea-Cnw96_Vw.js";import"./use-debounced-autosave-Bm10g-8R.js";import"./add-connection-dialog-BKu4JrTL.js";import"./connection-card-CdUGcyiA.js";import"./connection-slug-CITJ0kGN.js";import"./drawer-u-W4g_nO.js";import"./form-nYJgRjCD.js";import"./connection-form-helpers-CIUjUhAv.js";import"./authenticate-and-persist-oauth-jKlCQsjO.js";import"./collection-tabs-BYPXCgXS.js";import"./use-infinite-scroll-CnGnDOhg.js";import"./useSuspenseInfiniteQuery-CrkH2XOR.js";import"./file-type-icon-Ib_JQuvQ.js";import"./use-org-fs-aJhRDDIA.js";import"./checkbox-69BFI5HM.js";import"./search-input-DO4RsgDo.js";import"./use-mcp-auth-status-Du_TKL-p.js";import"./types-DNrbJSW6.js";import"./use-mcp-tools-YCPND0WQ.js";import"./use-mcp-prompts-ORmr-8fB.js";import"./utils-CVEq3hMx.js";import"./switch-Dm6uUVFL.js";import"./popover-Dvqj57GQ.js";import"./scroll-area-CuhYBrVG.js";import"./optimistic-project-sidebar-views-DS6iax6c.js";import"./virtual-mcp-C2bpy2G-.js";import"./sandbox-url-D3mC8qhT.js";import"./secret-picker-B9q4BUYJ.js";import"./use-secrets-Dcc9pXbR.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./serial-task-queue-CGOeQgpr.js";function Lt(r,e){return r.name===e.name&&(r.scope??"runtime")===e.scope}function mt(r,e){if(Array.isArray(r))return r;if(r&&typeof r=="object"){const o=r[e];if(Array.isArray(o))return o}return[]}function zt(r){return r==="deco-deno"?"Deco Deno":r==="deco-tanstack"?"Deco TanStack":r??null}function Ws(r){const e=(r??"").toLowerCase();return e.includes("ready")||e.includes("success")||e.includes("active")?"success":e.includes("fail")||e.includes("error")?"destructive":e.includes("build")||e.includes("pend")||e.includes("progress")?"warning":"secondary"}function Gt(r){if(!r)return"—";const e=new Date(r).getTime();if(Number.isNaN(e))return"—";const o=Math.round((Date.now()-e)/1e3),l=new Intl.RelativeTimeFormat(void 0,{numeric:"auto"}),a=[["year",31536e3],["month",2592e3],["day",86400],["hour",3600],["minute",60]];for(const[i,c]of a)if(Math.abs(o)>=c)return l.format(-Math.round(o/c),i);return l.format(-o,"second")}function Js(r){if(r==null||!Number.isFinite(r))return"—";if(r<1e3)return`${Math.round(r)}ms`;const e=r/1e3;if(e<60)return`${e.toFixed(e>=10?0:1)}s`;const o=Math.round(e);return`${Math.floor(o/60)}m ${o%60}s`}class It extends Error{constructor(e,o){super(e),this.status=o}status}function jt(r){return r instanceof It&&r.status===401}function rt(r){return r instanceof Error?r.message:String(r)}function Xs(r){const e=r.trim();if(!e)return null;const l=(e.endsWith(".")?e.slice(0,-1):e).split(".");if(l.length<2)return"Domain must include a TLD (e.g., example.com)";if(e.length>253)return"Domain name is too long (max 253 characters)";for(const i of l){if(i.length>63)return`Label "${i}" is too long (max 63 characters)`;if(!/^[a-z0-9]([a-z0-9-]*[a-z0-9])?$/i.test(i))return`Label "${i}" has invalid characters or format`}const a=l[l.length-1]??"";return/^[0-9]+$/.test(a)?"Domain must include a valid TLD, not a number":null}function us(r,e){return r&&typeof r=="object"&&"error"in r?String(r.error):`request failed (${e})`}async function Kt(r){const e=await fetch(r),o=await e.json().catch(()=>({}));if(!e.ok)throw new It(us(o,e.status),e.status);return o}async function at(r,e,o){const l=await fetch(r,{method:e,headers:o!==void 0?{"Content-Type":"application/json"}:{},body:o!==void 0?JSON.stringify(o):void 0}),a=await l.json().catch(()=>({}));if(!l.ok)throw new It(us(a,l.status),l.status);return a}function ut(r){const e=Z.c(4),{title:o,actions:l,children:a}=r;let i;return e[0]!==l||e[1]!==a||e[2]!==o?(i=t.jsx(Ts,{title:o,actions:l,children:a}),e[0]=l,e[1]=a,e[2]=o,e[3]=i):i=e[3],i}function Ie(r){const e=Z.c(5),{className:o,children:l}=r;let a;e[0]!==o?(a=xt("gap-0 overflow-hidden p-0 divide-y divide-border",o),e[0]=o,e[1]=a):a=e[1];let i;return e[2]!==l||e[3]!==a?(i=t.jsx(ps,{className:a,children:l}),e[2]=l,e[3]=a,e[4]=i):i=e[4],i}function pt(r){const e=Z.c(5),{className:o,children:l}=r;let a;e[0]!==o?(a=xt("flex min-h-12 items-center gap-3 px-4 py-2",o),e[0]=o,e[1]=a):a=e[1];let i;return e[2]!==l||e[3]!==a?(i=t.jsx("div",{className:a,children:l}),e[2]=l,e[3]=a,e[4]=i):i=e[4],i}function ot(r){const e=Z.c(2),{children:o}=r;let l;return e[0]!==o?(l=t.jsx("p",{className:"px-4 py-6 text-sm text-muted-foreground",children:o}),e[0]=o,e[1]=l):l=e[1],l}function ht(r){const e=Z.c(2),{rows:o}=r,l=o===void 0?3:o;let a;return e[0]!==l?(a=t.jsx(Ie,{children:Array.from({length:l},Ys)}),e[0]=l,e[1]=a):a=e[1],a}function Ys(r,e){return t.jsxs(pt,{children:[t.jsx(dt,{className:"h-4 w-40"}),t.jsx(dt,{className:"h-4 flex-1"}),t.jsx(dt,{className:"size-7 rounded-lg"})]},e)}function Me(r){const e=Z.c(5),{className:o,children:l}=r;let a;e[0]!==o?(a=xt("text-xs font-medium text-muted-foreground",o),e[0]=o,e[1]=a):a=e[1];let i;return e[2]!==l||e[3]!==a?(i=t.jsx(As,{className:a,children:l}),e[2]=l,e[3]=a,e[4]=i):i=e[4],i}function Qt(r){const e=Z.c(12),{open:o,onClick:l}=r,a=Ae();let i;e[0]!==o||e[1]!==a?(i=a(o?"mainPanelTabs.hostingTab.hideDetails":"mainPanelTabs.hostingTab.showDetails"),e[0]=o,e[1]=a,e[2]=i):i=e[2];const c=o&&"rotate-90";let m;e[3]!==c?(m=xt("transition-transform duration-200 motion-reduce:transition-none",c),e[3]=c,e[4]=m):m=e[4];let s;e[5]!==m?(s=t.jsx(ns,{className:m}),e[5]=m,e[6]=s):s=e[6];let n;return e[7]!==l||e[8]!==o||e[9]!==i||e[10]!==s?(n=t.jsx(et,{label:i,size:"icon-sm",className:"-ml-1.5 text-muted-foreground","aria-expanded":o,onClick:l,children:s}),e[7]=l,e[8]=o,e[9]=i,e[10]=s,e[11]=n):n=e[11],n}function Gs(r){const e=Z.c(8),{open:o,colSpan:l,children:a}=r;let i;e[0]!==a?(i=t.jsx(Vt,{children:t.jsx("div",{className:"border-b border-border bg-muted/30 px-4 py-3",children:a})}),e[0]=a,e[1]=i):i=e[1];let c;e[2]!==o||e[3]!==i?(c=t.jsx(Ht,{open:o,children:i}),e[2]=o,e[3]=i,e[4]=c):c=e[4];let m;return e[5]!==l||e[6]!==c?(m=t.jsx(nt,{className:"border-0 hover:bg-transparent",children:t.jsx(Fe,{colSpan:l,className:"p-0 whitespace-normal",children:c})}),e[5]=l,e[6]=c,e[7]=m):m=e[7],m}function hs(r){const e=Z.c(5),{open:o,children:l}=r;let a;e[0]!==l?(a=t.jsx(Vt,{children:t.jsx("div",{className:"border-t border-border bg-muted/30 px-4 py-3",children:l})}),e[0]=l,e[1]=a):a=e[1];let i;return e[2]!==o||e[3]!==a?(i=t.jsx(Ht,{open:o,children:a}),e[2]=o,e[3]=a,e[4]=i):i=e[4],i}function xs(r){const e=Z.c(6),{scope:o}=r,l=Ae(),a=o==="build"?"outline":"secondary";let i;e[0]!==o||e[1]!==l?(i=l(o==="build"?"mainPanelTabs.hostingTab.secretScopeBuild":"mainPanelTabs.hostingTab.secretScopeRuntime"),e[0]=o,e[1]=l,e[2]=i):i=e[2];let c;return e[3]!==a||e[4]!==i?(c=t.jsx(Re,{variant:a,children:i}),e[3]=a,e[4]=i,e[5]=c):c=e[5],c}function Zs(r){const e=Z.c(9),{value:o}=r,l=Ae();let a;e[0]!==l?(a=l("mainPanelTabs.hostingTab.dnsCopy"),e[0]=l,e[1]=a):a=e[1];let i;e[2]!==l||e[3]!==o?(i=()=>{if(!navigator.clipboard){ce.error(l("mainPanelTabs.hostingTab.dnsCopyError"));return}navigator.clipboard.writeText(o).then(()=>ce.success(l("mainPanelTabs.hostingTab.dnsCopied")),()=>ce.error(l("mainPanelTabs.hostingTab.dnsCopyError")))},e[2]=l,e[3]=o,e[4]=i):i=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx(zs,{className:"size-3.5"}),e[5]=c):c=e[5];let m;return e[6]!==a||e[7]!==i?(m=t.jsx(et,{label:a,onClick:i,children:c}),e[6]=a,e[7]=i,e[8]=m):m=e[8],m}function wt(r){const e=Z.c(28),{open:o,onOpenChange:l,title:a,description:i,confirmLabel:c,pending:m,onConfirm:s}=r,n=Ae();let x;e[0]!==a?(x=t.jsx(ls,{children:a}),e[0]=a,e[1]=x):x=e[1];let b;e[2]!==i?(b=t.jsx(as,{children:i}),e[2]=i,e[3]=b):b=e[3];let d;e[4]!==x||e[5]!==b?(d=t.jsxs(os,{children:[x,b]}),e[4]=x,e[5]=b,e[6]=d):d=e[6];let f;e[7]!==n?(f=n("mainPanelTabs.hostingTab.cancel"),e[7]=n,e[8]=f):f=e[8];let u;e[9]!==m||e[10]!==f?(u=t.jsx(rs,{disabled:m,children:f}),e[9]=m,e[10]=f,e[11]=u):u=e[11];let g;e[12]!==s?(g=S=>{S.preventDefault(),s()},e[12]=s,e[13]=g):g=e[13];let h;e[14]!==c||e[15]!==m||e[16]!==g?(h=t.jsx(cs,{className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",onClick:g,disabled:m,children:c}),e[14]=c,e[15]=m,e[16]=g,e[17]=h):h=e[17];let N;e[18]!==u||e[19]!==h?(N=t.jsxs(ms,{children:[u,h]}),e[18]=u,e[19]=h,e[20]=N):N=e[20];let C;e[21]!==d||e[22]!==N?(C=t.jsxs(ds,{children:[d,N]}),e[21]=d,e[22]=N,e[23]=C):C=e[23];let P;return e[24]!==l||e[25]!==o||e[26]!==C?(P=t.jsx(fs,{open:o,onOpenChange:l,children:C}),e[24]=l,e[25]=o,e[26]=C,e[27]=P):P=e[27],P}const en=8;function tn(r){const e=Z.c(54),{base:o,orgSlug:l,site:a}=r,i=Ae(),c=bt(),[m,s]=ee.useState(!1);let n;e[0]!==o?(n=()=>at(`${o}/deploy`,"POST",{mode:"current"}),e[0]=o,e[1]=n):n=e[1];let x;e[2]!==l||e[3]!==c||e[4]!==a||e[5]!==i?(x=()=>{c.invalidateQueries({queryKey:Xe.hostingDeployments(l,a)}),c.invalidateQueries({queryKey:Xe.hostingDeploymentHistory(l,a)}),ce.success(i("mainPanelTabs.hostingTab.toastDeployQueued")),s(!1)},e[2]=l,e[3]=c,e[4]=a,e[5]=i,e[6]=x):x=e[6];let b;e[7]!==n||e[8]!==x?(b={mutationFn:n,onSuccess:x,onError:sn},e[7]=n,e[8]=x,e[9]=b):b=e[9];const d=lt(b);let f;e[10]===Symbol.for("react.memo_cache_sentinel")?(f=()=>s(!0),e[10]=f):f=e[10];let u;e[11]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(gt,{}),e[11]=u):u=e[11];let g;e[12]!==d.isPending||e[13]!==i?(g=d.isPending?i("mainPanelTabs.hostingTab.deploying"):i("mainPanelTabs.hostingTab.deploy"),e[12]=d.isPending,e[13]=i,e[14]=g):g=e[14];let h;e[15]!==d.isPending||e[16]!==g?(h=t.jsxs(Qe,{size:"sm",onClick:f,disabled:d.isPending,children:[u,g]}),e[15]=d.isPending,e[16]=g,e[17]=h):h=e[17];let N;e[18]!==i?(N=i("mainPanelTabs.hostingTab.deployConfirmTitle"),e[18]=i,e[19]=N):N=e[19];let C;e[20]!==N?(C=t.jsx(ls,{children:N}),e[20]=N,e[21]=C):C=e[21];let P;e[22]!==i?(P=i("mainPanelTabs.hostingTab.deployConfirmDescription"),e[22]=i,e[23]=P):P=e[23];let S;e[24]!==P?(S=t.jsx(as,{children:P}),e[24]=P,e[25]=S):S=e[25];let y;e[26]!==S||e[27]!==C?(y=t.jsxs(os,{children:[C,S]}),e[26]=S,e[27]=C,e[28]=y):y=e[28];const R=d.isPending;let w;e[29]!==i?(w=i("mainPanelTabs.hostingTab.cancel"),e[29]=i,e[30]=w):w=e[30];let j;e[31]!==d.isPending||e[32]!==w?(j=t.jsx(rs,{disabled:R,children:w}),e[31]=d.isPending,e[32]=w,e[33]=j):j=e[33];let T;e[34]!==d?(T=_=>{_.preventDefault(),d.mutate()},e[34]=d,e[35]=T):T=e[35];const V=d.isPending;let q;e[36]!==i?(q=i("mainPanelTabs.hostingTab.deploy"),e[36]=i,e[37]=q):q=e[37];let F;e[38]!==d.isPending||e[39]!==T||e[40]!==q?(F=t.jsx(cs,{onClick:T,disabled:V,children:q}),e[38]=d.isPending,e[39]=T,e[40]=q,e[41]=F):F=e[41];let v;e[42]!==j||e[43]!==F?(v=t.jsxs(ms,{children:[j,F]}),e[42]=j,e[43]=F,e[44]=v):v=e[44];let H;e[45]!==y||e[46]!==v?(H=t.jsxs(ds,{children:[y,v]}),e[45]=y,e[46]=v,e[47]=H):H=e[47];let A;e[48]!==m||e[49]!==H?(A=t.jsx(fs,{open:m,onOpenChange:s,children:H}),e[48]=m,e[49]=H,e[50]=A):A=e[50];let K;return e[51]!==A||e[52]!==h?(K=t.jsxs(t.Fragment,{children:[h,A]}),e[51]=A,e[52]=h,e[53]=K):K=e[53],K}function sn(r){return ce.error(rt(r))}function nn(r,e){const o=(r??"").toLowerCase();return o.includes("rollback")?t.jsxs(Re,{variant:"warning",children:[t.jsx(ws,{}),e("mainPanelTabs.hostingTab.actionRollback")]}):o.includes("redeploy")?t.jsxs(Re,{variant:"secondary",children:[t.jsx($s,{}),e("mainPanelTabs.hostingTab.actionRedeploy")]}):t.jsxs(Re,{variant:"secondary",children:[t.jsx(gt,{}),e("mainPanelTabs.hostingTab.actionDeploy")]})}function ln(r,e,o){const l=(r??"").toLowerCase();return l==="build"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(is,{}),o("mainPanelTabs.hostingTab.typeBuild")]}):l==="fast-deploy"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(_s,{}),o("mainPanelTabs.hostingTab.typeFastDeploy")]}):l==="deploy"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(gt,{}),o("mainPanelTabs.hostingTab.typeDeploy")]}):nn(e,o)}function an(r,e){const o=(r??"").toLowerCase();return o==="success"?t.jsx(Re,{variant:"success",children:e("mainPanelTabs.hostingTab.outcomeSuccess")}):o==="failure"?t.jsx(Re,{variant:"destructive",children:e("mainPanelTabs.hostingTab.outcomeFailure")}):o==="pending"?t.jsxs(Re,{variant:"secondary",children:[t.jsx(Ds,{}),e("mainPanelTabs.hostingTab.outcomePending")]}):null}function Zt(r){const e=Z.c(7),{commit:o,onClick:l}=r,a=Ae();let i;e[0]!==a?(i=a("mainPanelTabs.hostingTab.buildLogs"),e[0]=a,e[1]=i):i=e[1];const c=!o;let m;e[2]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx(is,{}),e[2]=m):m=e[2];let s;return e[3]!==l||e[4]!==i||e[5]!==c?(s=t.jsx(et,{label:i,onClick:l,disabled:c,children:m}),e[3]=l,e[4]=i,e[5]=c,e[6]=s):s=e[6],s}function on(r){const e=Z.c(37),{base:o,orgSlug:l,site:a,target:i,onOpenChange:c}=r,m=Ae(),s=i!=null,n=i?.commit??"",x=i?.env??"";let b;e[0]!==n||e[1]!==x||e[2]!==l||e[3]!==a?(b=Xe.hostingBuildLogs(l,a,n,x),e[0]=n,e[1]=x,e[2]=l,e[3]=a,e[4]=b):b=e[4];let d;e[5]!==o||e[6]!==n||e[7]!==x?(d=()=>Kt(`${o}/deployments/logs?commit=${encodeURIComponent(n)}&env=${encodeURIComponent(x)}`),e[5]=o,e[6]=n,e[7]=x,e[8]=d):d=e[8];const f=s&&!!n;let u;e[9]!==b||e[10]!==d||e[11]!==f?(u={queryKey:b,queryFn:d,enabled:f,retry:!1,staleTime:0,gcTime:0,refetchOnMount:"always"},e[9]=b,e[10]=d,e[11]=f,e[12]=u):u=e[12];const g=ct(u),h=g.data;let N;e[13]!==m?(N=m("mainPanelTabs.hostingTab.buildLogsTitle"),e[13]=m,e[14]=N):N=e[14];let C;e[15]!==N?(C=t.jsx(ks,{children:N}),e[15]=N,e[16]=C):C=e[16];let P;e[17]!==n||e[18]!==m?(P=m("mainPanelTabs.hostingTab.buildLogsCommit",{commit:n.slice(0,7)}),e[17]=n,e[18]=m,e[19]=P):P=e[19];let S;e[20]!==P?(S=t.jsx("p",{className:"font-mono text-xs text-muted-foreground",children:P}),e[20]=P,e[21]=S):S=e[21];let y;e[22]!==C||e[23]!==S?(y=t.jsxs(Es,{className:"shrink-0 border-b border-border px-5 py-5 md:px-6",children:[C,S]}),e[22]=C,e[23]=S,e[24]=y):y=e[24];let R;e[25]!==h||e[26]!==g.error||e[27]!==g.isLoading||e[28]!==m?(R=t.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto px-5 py-5 md:px-6",children:jt(g.error)?t.jsx(Ze,{icon:t.jsx(_t,{className:"size-5"}),title:m("mainPanelTabs.hostingTab.notConnectedTitle"),description:m("mainPanelTabs.hostingTab.notConnectedDescription")}):g.isLoading?t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsx(dt,{className:"h-4 w-full"}),t.jsx(dt,{className:"h-4 w-full"}),t.jsx(dt,{className:"h-4 w-2/3"})]}):g.error?t.jsx(ot,{children:m("mainPanelTabs.hostingTab.buildLogsError")}):h&&h.configured===!1?t.jsxs("div",{className:"flex flex-col items-center gap-2 rounded-lg border border-border bg-muted/30 px-4 py-8 text-center",children:[t.jsx(Ns,{className:"size-5 text-muted-foreground"}),t.jsx("p",{className:"text-sm font-medium text-foreground",children:m("mainPanelTabs.hostingTab.buildLogsNotWiredTitle")}),t.jsx("p",{className:"text-xs text-muted-foreground",children:h.reason??m("mainPanelTabs.hostingTab.buildLogsNotWiredDescription")})]}):h?.text?t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsx("pre",{className:"overflow-auto font-mono text-[11px] leading-relaxed text-foreground/80 whitespace-pre-wrap break-words",children:h.text}),h.truncated&&t.jsx("p",{className:"text-xs text-warning",children:m("mainPanelTabs.hostingTab.buildLogsTruncated")}),h.url&&t.jsxs("a",{href:h.url,target:"_blank",rel:"noreferrer",className:"inline-flex w-fit items-center gap-1.5 text-xs text-primary hover:underline",children:[t.jsx(kt,{className:"size-3.5"}),m("mainPanelTabs.hostingTab.buildLogsOpenFull")]})]}):h?.url?t.jsxs("a",{href:h.url,target:"_blank",rel:"noreferrer",className:"inline-flex w-fit items-center gap-1.5 text-sm text-primary hover:underline",children:[t.jsx(kt,{className:"size-4"}),m("mainPanelTabs.hostingTab.buildLogsOpenFull")]}):t.jsx(ot,{children:m("mainPanelTabs.hostingTab.buildLogsEmpty")})}),e[25]=h,e[26]=g.error,e[27]=g.isLoading,e[28]=m,e[29]=R):R=e[29];let w;e[30]!==R||e[31]!==y?(w=t.jsxs(Rs,{className:"flex flex-col gap-0 p-0 sm:max-w-2xl",children:[y,R]}),e[30]=R,e[31]=y,e[32]=w):w=e[32];let j;return e[33]!==c||e[34]!==s||e[35]!==w?(j=t.jsx(Fs,{open:s,onOpenChange:c,children:w}),e[33]=c,e[34]=s,e[35]=w,e[36]=j):j=e[36],j}function rn(r){const e=Z.c(52),{base:o,orgSlug:l,site:a,enabled:i,deployments:c,isLoading:m,error:s}=r,n=Ae(),[x,b]=ee.useState(null),[d,f]=ee.useState(en),[u,g]=ee.useState(null);let h;e[0]!==l||e[1]!==a?(h=Xe.hostingDeploymentHistory(l,a),e[0]=l,e[1]=a,e[2]=h):h=e[2];let N;e[3]!==o?(N=()=>Kt(`${o}/deployments/history?limit=50`),e[3]=o,e[4]=N):N=e[4];let C;e[5]!==i||e[6]!==h||e[7]!==N?(C={queryKey:h,queryFn:N,enabled:i,retry:!1,staleTime:3e4},e[5]=i,e[6]=h,e[7]=N,e[8]=C):C=e[8];const P=ct(C);let S,y,R,w;if(e[9]!==c||e[10]!==s||e[11]!==x||e[12]!==d||e[13]!==P.data||e[14]!==P.error||e[15]!==P.isLoading||e[16]!==m||e[17]!==n){const F=mt(P.data,"items"),v=F.slice(0,d),H=F.length-v.length;let A;e[22]!==c?(A=c.find(dn)?.commitSha??c.find(mn)?.commitSha??null,e[22]=c,e[23]=A):A=e[23];const K=A;let _;e[24]===Symbol.for("react.memo_cache_sentinel")?(_=(p,I)=>{p&&g({commit:p,env:I??"production"})},e[24]=_):_=e[24];const W=_;let J;e[25]!==n?(J=n("mainPanelTabs.hostingTab.deployments"),e[25]=n,e[26]=J):J=e[26];let Q;e[27]!==c||e[28]!==s||e[29]!==x||e[30]!==m||e[31]!==n?(Q=m?t.jsx(ht,{}):s?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.deploymentsError")})}):c.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(gt,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noDeployments"),className:"py-10"})}):t.jsxs(Rt,{children:[t.jsx(Ft,{children:t.jsxs(nt,{children:[t.jsx(Me,{className:"pl-4",children:n("mainPanelTabs.hostingTab.colCommit")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colStatus")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colFramework")}),t.jsx(Me,{className:"text-right",children:n("mainPanelTabs.hostingTab.colDuration")}),t.jsx(Me,{className:"text-right",children:n("mainPanelTabs.hostingTab.colUpdated")}),t.jsx(Me,{className:"w-[1%]"})]})}),t.jsx(At,{children:c.map(p=>{const I=!!p.buildMessage,X=x===p.id;return t.jsxs(ee.Fragment,{children:[t.jsxs(nt,{className:xt(I&&"cursor-pointer hover:bg-muted/40"),onClick:I?()=>b(X?null:p.id):void 0,children:[t.jsx(Fe,{className:"px-4",children:t.jsxs("div",{className:"flex items-center gap-1.5",children:[I?t.jsx(Qt,{open:X,onClick:()=>b(X?null:p.id)}):t.jsx(Cs,{className:"size-4 text-muted-foreground/60"}),t.jsx("span",{className:"font-mono text-xs",children:p.shortCommit??p.commitSha?.slice(0,7)??"—"}),p.production===!0&&t.jsx(Re,{variant:"outline",children:n("mainPanelTabs.hostingTab.production")})]})}),t.jsx(Fe,{children:t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(Re,{variant:Ws(p.phase),children:p.phase??"—"}),p.up===!0&&t.jsx(Re,{variant:"success",children:n("mainPanelTabs.hostingTab.live")})]})}),t.jsx(Fe,{className:"text-xs text-muted-foreground",children:zt(p.framework)??"—"}),t.jsx(Fe,{className:"text-right font-mono text-xs text-muted-foreground tabular-nums",children:Js(p.durationMs)}),t.jsx(Fe,{className:"text-right text-xs text-muted-foreground",children:Gt(p.finishedAt??p.startedAt??p.createdAt)}),t.jsx(Fe,{className:"pr-3 text-right",onClick:cn,children:t.jsx(Zt,{commit:p.commitSha,onClick:()=>W(p.commitSha,p.env)})})]}),I&&t.jsx(Gs,{open:X,colSpan:6,children:t.jsx("p",{className:"whitespace-pre-wrap break-words font-mono text-xs text-muted-foreground",children:p.buildMessage})})]},p.id)})})]}),e[27]=c,e[28]=s,e[29]=x,e[30]=m,e[31]=n,e[32]=Q):Q=e[32],e[33]!==Q||e[34]!==J?(w=t.jsx(ut,{title:J,children:Q}),e[33]=Q,e[34]=J,e[35]=w):w=e[35],S=ut,e[36]!==n?(y=n("mainPanelTabs.hostingTab.deployHistory"),e[36]=n,e[37]=y):y=e[37],R=P.isLoading?t.jsx(ht,{}):P.error?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.deployHistoryError")})}):F.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(gt,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noDeployHistory"),className:"py-10"})}):t.jsxs(Rt,{children:[t.jsx(Ft,{children:t.jsxs(nt,{children:[t.jsx(Me,{className:"pl-4",children:n("mainPanelTabs.hostingTab.colAction")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colStatus")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colCommit")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colFramework")}),t.jsx(Me,{children:n("mainPanelTabs.hostingTab.colActor")}),t.jsx(Me,{className:"text-right",children:n("mainPanelTabs.hostingTab.colDate")}),t.jsx(Me,{className:"w-[1%]"})]})}),t.jsxs(At,{children:[v.map(p=>{const I=!!K&&p.commitSha===K;return t.jsxs(nt,{children:[t.jsx(Fe,{className:"pl-4",children:ln(p.type,p.action,n)}),t.jsx(Fe,{children:an(p.outcome,n)}),t.jsx(Fe,{children:t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx("span",{className:"font-mono text-xs",children:p.commitSha?.slice(0,7)??"—"}),I&&t.jsx(Re,{variant:"success",children:n("mainPanelTabs.hostingTab.live")})]})}),t.jsx(Fe,{className:"text-xs text-muted-foreground",children:zt(p.framework)??"—"}),t.jsx(Fe,{className:"text-xs text-muted-foreground",children:p.actor??"—"}),t.jsx(Fe,{className:"text-right text-xs text-muted-foreground",children:Gt(p.createdAt)}),t.jsx(Fe,{className:"pr-3 text-right",children:t.jsx(Zt,{commit:p.commitSha,onClick:()=>W(p.commitSha,p.env)})})]},p.id)}),H>0&&t.jsx(nt,{className:"hover:bg-transparent",children:t.jsx(Fe,{colSpan:7,className:"p-2 text-center",children:t.jsx(Qe,{variant:"ghost",size:"sm",onClick:()=>f(F.length),children:n("mainPanelTabs.hostingTab.showMoreHistory",{count:String(H)})})})})]})]}),e[9]=c,e[10]=s,e[11]=x,e[12]=d,e[13]=P.data,e[14]=P.error,e[15]=P.isLoading,e[16]=m,e[17]=n,e[18]=S,e[19]=y,e[20]=R,e[21]=w}else S=e[18],y=e[19],R=e[20],w=e[21];let j;e[38]!==S||e[39]!==y||e[40]!==R?(j=t.jsx(S,{title:y,children:R}),e[38]=S,e[39]=y,e[40]=R,e[41]=j):j=e[41];let T;e[42]===Symbol.for("react.memo_cache_sentinel")?(T=F=>{F||g(null)},e[42]=T):T=e[42];let V;e[43]!==o||e[44]!==u||e[45]!==l||e[46]!==a?(V=t.jsx(on,{base:o,orgSlug:l,site:a,target:u,onOpenChange:T}),e[43]=o,e[44]=u,e[45]=l,e[46]=a,e[47]=V):V=e[47];let q;return e[48]!==w||e[49]!==j||e[50]!==V?(q=t.jsxs(t.Fragment,{children:[w,j,V]}),e[48]=w,e[49]=j,e[50]=V,e[51]=q):q=e[51],q}function cn(r){return r.stopPropagation()}function mn(r){return r.production===!0&&r.up}function dn(r){return r.up===!0}const fn=["16.148.147.194","52.32.122.94","52.35.156.199"];function un(r){return r.replace(/\.$/,"").split(".").filter(Boolean).length===2}function es(r){const e=r.trim();return e.length>0&&!e.startsWith("/")&&e.includes(".")}function gs(r){const e=Z.c(24),{records:o}=r,l=Ae();let a;e[0]!==l?(a=l("mainPanelTabs.hostingTab.dnsColType"),e[0]=l,e[1]=a):a=e[1];let i;e[2]!==a?(i=t.jsx(Me,{className:"w-16",children:a}),e[2]=a,e[3]=i):i=e[3];let c;e[4]!==l?(c=l("mainPanelTabs.hostingTab.dnsColName"),e[4]=l,e[5]=c):c=e[5];let m;e[6]!==c?(m=t.jsx(Me,{children:c}),e[6]=c,e[7]=m):m=e[7];let s;e[8]!==l?(s=l("mainPanelTabs.hostingTab.dnsColValue"),e[8]=l,e[9]=s):s=e[9];let n;e[10]!==s?(n=t.jsx(Me,{children:s}),e[10]=s,e[11]=n):n=e[11];let x;e[12]===Symbol.for("react.memo_cache_sentinel")?(x=t.jsx(Me,{className:"w-10"}),e[12]=x):x=e[12];let b;e[13]!==i||e[14]!==m||e[15]!==n?(b=t.jsx(Ft,{children:t.jsxs(nt,{children:[i,m,n,x]})}),e[13]=i,e[14]=m,e[15]=n,e[16]=b):b=e[16];let d;e[17]!==o?(d=o.map(hn),e[17]=o,e[18]=d):d=e[18];let f;e[19]!==d?(f=t.jsx(At,{children:d}),e[19]=d,e[20]=f):f=e[20];let u;return e[21]!==f||e[22]!==b?(u=t.jsxs(Rt,{className:"table-fixed",children:[b,f]}),e[21]=f,e[22]=b,e[23]=u):u=e[23],u}function hn(r){return t.jsxs(nt,{children:[t.jsx(Fe,{className:"font-mono text-xs",children:r.type}),t.jsx(Fe,{className:"break-all whitespace-normal font-mono text-xs",children:r.name}),t.jsx(Fe,{className:"break-all whitespace-normal font-mono text-xs text-muted-foreground",children:r.value}),t.jsx(Fe,{className:"text-right",children:t.jsx(Zs,{value:r.value})})]},`${r.type}-${r.name}-${r.value}`)}function bs(r){const e=Z.c(14),{status:o,children:l}=r,a=Ae();let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx(Et,{className:"size-4 text-muted-foreground"}),e[0]=i):i=e[0];let c;e[1]!==a?(c=a("mainPanelTabs.hostingTab.dnsSetupTitle"),e[1]=a,e[2]=c):c=e[2];let m;e[3]!==c?(m=t.jsx("span",{className:"text-sm font-medium",children:c}),e[3]=c,e[4]=m):m=e[4];let s;e[5]!==o||e[6]!==a?(s=o&&t.jsx(Re,{variant:o.active?"success":"outline",className:"ml-auto",children:o.active?a("mainPanelTabs.hostingTab.dnsActive"):a("mainPanelTabs.hostingTab.dnsAwaiting")}),e[5]=o,e[6]=a,e[7]=s):s=e[7];let n;e[8]!==m||e[9]!==s?(n=t.jsxs("div",{className:"flex items-center gap-2",children:[i,m,s]}),e[8]=m,e[9]=s,e[10]=n):n=e[10];let x;return e[11]!==l||e[12]!==n?(x=t.jsxs("div",{className:"flex min-w-0 flex-col gap-3",children:[n,l]}),e[11]=l,e[12]=n,e[13]=x):x=e[13],x}function ts(r){const e=Z.c(21),{from:o,source:l}=r,a=Ae();let i,c,m,s,n;if(e[0]!==o||e[1]!==l||e[2]!==a){const d=o.trim().replace(/\.$/,""),f=d?un(d)?"@":d:"@",u=l==="both";c=bs,e[8]!==u?(s={active:u},e[8]=u,e[9]=s):s=e[9];let g;e[10]!==u||e[11]!==a?(g=a(u?"mainPanelTabs.hostingTab.dnsActiveHint":"mainPanelTabs.hostingTab.dnsAwaitingHint"),e[10]=u,e[11]=a,e[12]=g):g=e[12],n=t.jsxs("p",{className:"text-xs text-muted-foreground",children:[a("mainPanelTabs.hostingTab.dnsRedirectIntent",{from:d||"—"})," ",g]}),i=gs,m=fn.map(h=>({type:"A",name:f,value:h})),e[0]=o,e[1]=l,e[2]=a,e[3]=i,e[4]=c,e[5]=m,e[6]=s,e[7]=n}else i=e[3],c=e[4],m=e[5],s=e[6],n=e[7];let x;e[13]!==i||e[14]!==m?(x=t.jsx(i,{records:m}),e[13]=i,e[14]=m,e[15]=x):x=e[15];let b;return e[16]!==c||e[17]!==s||e[18]!==n||e[19]!==x?(b=t.jsxs(c,{status:s,children:[n,x]}),e[16]=c,e[17]=s,e[18]=n,e[19]=x,e[20]=b):b=e[20],b}function ss(r){const e=Z.c(2),{records:o}=r;if(o.length===0)return null;let l;return e[0]!==o?(l=t.jsx(bs,{children:t.jsx(gs,{records:o})}),e[0]=o,e[1]=l):l=e[1],l}function xn(r){const e=Z.c(16),{domain:o}=r,l=Ae(),a=o.status??"pending";let i;e[0]!==a||e[1]!==l?(i=l(a==="active"?"mainPanelTabs.hostingTab.statusActive":a==="action-required"?"mainPanelTabs.hostingTab.statusActionRequired":"mainPanelTabs.hostingTab.statusPending"),e[0]=a,e[1]=l,e[2]=i):i=e[2];const c=i;let m;e[3]!==o.detail||e[4]!==l?(m=o.detail==="zone-not-onboarded"?l("mainPanelTabs.hostingTab.detailZoneNotOnboarded"):void 0,e[3]=o.detail,e[4]=l,e[5]=m):m=e[5];const s=m,n=a==="active"?"success":a==="action-required"?"warning":"outline";let x;e[6]!==c||e[7]!==n?(x=t.jsx(Re,{variant:n,children:c}),e[6]=c,e[7]=n,e[8]=x):x=e[8];const b=x;if(!s)return b;let d;e[9]!==b?(d=t.jsx(Hs,{asChild:!0,children:b}),e[9]=b,e[10]=d):d=e[10];let f;e[11]!==s?(f=t.jsx(Bs,{className:"max-w-xs",children:s}),e[11]=s,e[12]=f):f=e[12];let u;return e[13]!==d||e[14]!==f?(u=t.jsxs(Os,{children:[d,f]}),e[13]=d,e[14]=f,e[15]=u):u=e[15],u}function gn(r){const e=Z.c(121),{base:o,orgSlug:l,site:a,domains:i,dnsTemplate:c,isLoading:m,error:s}=r,n=Ae(),x=bt(),[b,d]=ee.useState(!1),[f,u]=ee.useState(""),[g,h]=ee.useState(null),[N,C]=ee.useState(null);let P;e[0]!==l||e[1]!==x||e[2]!==a?(P=()=>x.invalidateQueries({queryKey:Xe.hostingDomains(l,a)}),e[0]=l,e[1]=x,e[2]=a,e[3]=P):P=e[3];const S=P;let y;e[4]!==o?(y=$=>at(`${o}/domains`,"PUT",$),e[4]=o,e[5]=y):y=e[5];let R;e[6]!==S||e[7]!==n?(R=()=>{S(),ce.success(n("mainPanelTabs.hostingTab.toastDomainSaved")),d(!1)},e[6]=S,e[7]=n,e[8]=R):R=e[8];let w;e[9]!==y||e[10]!==R?(w={mutationFn:y,onSuccess:R,onError:pn},e[9]=y,e[10]=R,e[11]=w):w=e[11];const j=lt(w);let T;e[12]!==o?(T=$=>at(`${o}/domains/${encodeURIComponent($)}`,"DELETE"),e[12]=o,e[13]=T):T=e[13];let V;e[14]!==S||e[15]!==n?(V=()=>{S(),ce.success(n("mainPanelTabs.hostingTab.toastDomainDeleted")),h(null)},e[14]=S,e[15]=n,e[16]=V):V=e[16];let q;e[17]!==T||e[18]!==V?(q={mutationFn:T,onSuccess:V,onError:bn},e[17]=T,e[18]=V,e[19]=q):q=e[19];const F=lt(q);let v;e[20]!==f||e[21]!==j||e[22]!==n?(v=()=>{const $=f.trim().toLowerCase();if(!$){ce.error(n("mainPanelTabs.hostingTab.errorDomainHostRequired"));return}const se=Xs($);if(se){ce.error(se);return}j.mutate({host:$})},e[20]=f,e[21]=j,e[22]=n,e[23]=v):v=e[23];const H=v;let A;if(e[24]!==c||e[25]!==f){let $;e[27]!==f?($=se=>({...se,name:f.trim().toLowerCase()||se.name}),e[27]=f,e[28]=$):$=e[28],A=c.map($),e[24]=c,e[25]=f,e[26]=A}else A=e[26];const K=A;let _,W;e[29]===Symbol.for("react.memo_cache_sentinel")?(_=()=>{u(""),d(!0)},W=t.jsx(Pt,{}),e[29]=_,e[30]=W):(_=e[29],W=e[30]);let J;e[31]!==n?(J=n("mainPanelTabs.hostingTab.addDomain"),e[31]=n,e[32]=J):J=e[32];let Q;e[33]!==J?(Q=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:_,children:[W,J]}),e[33]=J,e[34]=Q):Q=e[34];const p=Q;let I;e[35]!==n?(I=n("mainPanelTabs.hostingTab.domains"),e[35]=n,e[36]=I):I=e[36];const X=i.length>0?p:void 0;let D;e[37]!==p||e[38]!==F.isPending||e[39]!==N||e[40]!==i||e[41]!==s||e[42]!==m||e[43]!==n?(D=m?t.jsx(ht,{}):s?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.domainsError")})}):i.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Et,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noDomains"),className:"py-10",buttonComponent:p})}):t.jsx(Ie,{children:i.map(($,se)=>{const Se=!$.canonical&&($.dns?.length??0)>0,je=N===$.host;return t.jsxs("div",{children:[t.jsxs(pt,{children:[Se?t.jsx(Qt,{open:je,onClick:()=>C(je?null:$.host)}):t.jsx(Et,{className:"size-4 shrink-0 text-muted-foreground/60"}),t.jsxs("div",{className:"flex min-w-0 flex-1 items-center gap-2",children:[t.jsx("span",{className:"truncate font-mono text-xs",children:$.host}),$.canonical&&t.jsx(Re,{variant:"outline",children:n("mainPanelTabs.hostingTab.canonical")})]}),t.jsx(xn,{domain:$}),!$.canonical&&t.jsx(et,{label:n("mainPanelTabs.hostingTab.deleteDomain"),onClick:()=>h($.host),disabled:F.isPending,className:"text-muted-foreground",children:t.jsx(vt,{})})]}),Se&&t.jsx(hs,{open:je,children:t.jsx(ss,{records:$.dns??[]})})]},`${$.host}-${se}`)})}),e[37]=p,e[38]=F.isPending,e[39]=N,e[40]=i,e[41]=s,e[42]=m,e[43]=n,e[44]=D):D=e[44];let Y;e[45]!==n?(Y=n("mainPanelTabs.hostingTab.addDomainTitle"),e[45]=n,e[46]=Y):Y=e[46];let O;e[47]!==Y?(O=t.jsx(yt,{children:t.jsx(St,{children:Y})}),e[47]=Y,e[48]=O):O=e[48];let k;e[49]!==H?(k=$=>{$.preventDefault(),H()},e[49]=H,e[50]=k):k=e[50];let E;e[51]!==n?(E=n("mainPanelTabs.hostingTab.colHost"),e[51]=n,e[52]=E):E=e[52];let B;e[53]!==E?(B=t.jsx(Ge,{htmlFor:"domain-host",children:E}),e[53]=E,e[54]=B):B=e[54];let G;e[55]!==n?(G=n("mainPanelTabs.hostingTab.domainHostPlaceholder"),e[55]=n,e[56]=G):G=e[56];let te;e[57]===Symbol.for("react.memo_cache_sentinel")?(te=$=>u($.target.value),e[57]=te):te=e[57];let U;e[58]!==f||e[59]!==j.isPending||e[60]!==G?(U=t.jsx(it,{id:"domain-host",placeholder:G,value:f,onChange:te,className:"font-mono text-xs",autoComplete:"off",disabled:j.isPending}),e[58]=f,e[59]=j.isPending,e[60]=G,e[61]=U):U=e[61];let ne;e[62]!==B||e[63]!==U?(ne=t.jsxs("div",{className:"flex flex-col gap-2",children:[B,U]}),e[62]=B,e[63]=U,e[64]=ne):ne=e[64];let ie;e[65]!==f||e[66]!==K?(ie=f.trim()&&t.jsx("div",{className:"rounded-lg border border-border bg-muted/30 p-3",children:t.jsx(ss,{records:K})}),e[65]=f,e[66]=K,e[67]=ie):ie=e[67];let Pe;e[68]===Symbol.for("react.memo_cache_sentinel")?(Pe=()=>d(!1),e[68]=Pe):Pe=e[68];const Ce=j.isPending;let me;e[69]!==n?(me=n("mainPanelTabs.hostingTab.cancel"),e[69]=n,e[70]=me):me=e[70];let pe;e[71]!==j.isPending||e[72]!==me?(pe=t.jsx(Qe,{variant:"outline",type:"button",onClick:Pe,disabled:Ce,children:me}),e[71]=j.isPending,e[72]=me,e[73]=pe):pe=e[73];let le;e[74]!==f||e[75]!==j.isPending?(le=j.isPending||!f.trim(),e[74]=f,e[75]=j.isPending,e[76]=le):le=e[76];let ae;e[77]!==j.isPending||e[78]!==n?(ae=j.isPending?n("mainPanelTabs.hostingTab.saving"):n("mainPanelTabs.hostingTab.save"),e[77]=j.isPending,e[78]=n,e[79]=ae):ae=e[79];let de;e[80]!==le||e[81]!==ae?(de=t.jsx(Qe,{type:"submit",disabled:le,children:ae}),e[80]=le,e[81]=ae,e[82]=de):de=e[82];let De;e[83]!==pe||e[84]!==de?(De=t.jsxs(Nt,{children:[pe,de]}),e[83]=pe,e[84]=de,e[85]=De):De=e[85];let fe;e[86]!==k||e[87]!==ne||e[88]!==ie||e[89]!==De?(fe=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:k,children:[ne,ie,De]}),e[86]=k,e[87]=ne,e[88]=ie,e[89]=De,e[90]=fe):fe=e[90];let ue;e[91]!==O||e[92]!==fe?(ue=t.jsxs(Ct,{className:"sm:max-w-md",children:[O,fe]}),e[91]=O,e[92]=fe,e[93]=ue):ue=e[93];let oe;e[94]!==b||e[95]!==ue?(oe=t.jsx(Dt,{open:b,onOpenChange:d,children:ue}),e[94]=b,e[95]=ue,e[96]=oe):oe=e[96];const Te=g!=null;let he;e[97]===Symbol.for("react.memo_cache_sentinel")?(he=$=>{$||h(null)},e[97]=he):he=e[97];let xe;e[98]!==n?(xe=n("mainPanelTabs.hostingTab.confirmDeleteDomainTitle"),e[98]=n,e[99]=xe):xe=e[99];const ve=g??"";let ye;e[100]!==n||e[101]!==ve?(ye=n("mainPanelTabs.hostingTab.confirmDeleteDomainDescription",{host:ve}),e[100]=n,e[101]=ve,e[102]=ye):ye=e[102];let ge;e[103]!==n?(ge=n("mainPanelTabs.hostingTab.deleteDomain"),e[103]=n,e[104]=ge):ge=e[104];let re;e[105]!==F||e[106]!==g?(re=()=>{g&&F.mutate(g)},e[105]=F,e[106]=g,e[107]=re):re=e[107];let be;e[108]!==F.isPending||e[109]!==Te||e[110]!==xe||e[111]!==ye||e[112]!==ge||e[113]!==re?(be=t.jsx(wt,{open:Te,onOpenChange:he,title:xe,description:ye,confirmLabel:ge,pending:F.isPending,onConfirm:re}),e[108]=F.isPending,e[109]=Te,e[110]=xe,e[111]=ye,e[112]=ge,e[113]=re,e[114]=be):be=e[114];let we;return e[115]!==I||e[116]!==X||e[117]!==D||e[118]!==oe||e[119]!==be?(we=t.jsxs(ut,{title:I,actions:X,children:[D,oe,be]}),e[115]=I,e[116]=X,e[117]=D,e[118]=oe,e[119]=be,e[120]=we):we=e[120],we}function bn(r){return ce.error(rt(r))}function pn(r){return ce.error(rt(r))}function Tn(r){const e=Z.c(24),{value:o,onChange:l,disabled:a,className:i}=r,c=Ae();let m;e[0]!==l?(m=N=>l(N==="build"?"build":"runtime"),e[0]=l,e[1]=m):m=e[1];let s;e[2]!==i?(s=xt("h-8",i),e[2]=i,e[3]=s):s=e[3];let n;e[4]===Symbol.for("react.memo_cache_sentinel")?(n=t.jsx(Bt,{}),e[4]=n):n=e[4];let x;e[5]!==s?(x=t.jsx(Ot,{className:s,children:n}),e[5]=s,e[6]=x):x=e[6];let b;e[7]!==c?(b=c("mainPanelTabs.hostingTab.secretScopeRuntime"),e[7]=c,e[8]=b):b=e[8];let d;e[9]!==b?(d=t.jsx(ft,{value:"runtime",children:b}),e[9]=b,e[10]=d):d=e[10];let f;e[11]!==c?(f=c("mainPanelTabs.hostingTab.secretScopeBuild"),e[11]=c,e[12]=f):f=e[12];let u;e[13]!==f?(u=t.jsx(ft,{value:"build",children:f}),e[13]=f,e[14]=u):u=e[14];let g;e[15]!==d||e[16]!==u?(g=t.jsxs(qt,{children:[d,u]}),e[15]=d,e[16]=u,e[17]=g):g=e[17];let h;return e[18]!==a||e[19]!==m||e[20]!==x||e[21]!==g||e[22]!==o?(h=t.jsxs(Mt,{value:o,onValueChange:m,disabled:a,children:[x,g]}),e[18]=a,e[19]=m,e[20]=x,e[21]=g,e[22]=o,e[23]=h):h=e[23],h}function jn(r){const e=Z.c(151),{base:o,orgSlug:l,site:a,envVars:i,codeVars:c,isLoading:m,error:s}=r,n=Ae(),x=bt(),[b,d]=ee.useState(!1),[f,u]=ee.useState(""),[g,h]=ee.useState(""),[N,C]=ee.useState("runtime"),[P,S]=ee.useState(null),[y,R]=ee.useState(""),[w,j]=ee.useState(null);let T;e[0]===Symbol.for("react.memo_cache_sentinel")?(T=new Set,e[0]=T):T=e[0];const[V,q]=ee.useState(T);let F;e[1]===Symbol.for("react.memo_cache_sentinel")?(F=L=>{q(Ne=>{const We=new Set(Ne);return We.has(L)?We.delete(L):We.add(L),We})},e[1]=F):F=e[1];const v=F;let H;e[2]!==o?(H=L=>at(`${o}/env`,"PUT",{vars:L}),e[2]=o,e[3]=H):H=e[3];let A;e[4]!==l||e[5]!==x||e[6]!==a||e[7]!==n?(A=()=>{x.invalidateQueries({queryKey:Xe.hostingEnv(l,a)}),ce.success(n("mainPanelTabs.hostingTab.toastEnvSaved"))},e[4]=l,e[5]=x,e[6]=a,e[7]=n,e[8]=A):A=e[8];let K;e[9]!==H||e[10]!==A?(K={mutationFn:H,onSuccess:A,onError:vn},e[9]=H,e[10]=A,e[11]=K):K=e[11];const _=lt(K);let W;e[12]!==f||e[13]!==N||e[14]!==g||e[15]!==_||e[16]!==i||e[17]!==n?(W=()=>{const L=f.trim();if(!L){ce.error(n("mainPanelTabs.hostingTab.errorEnvNameRequired"));return}if(i.some(Ne=>Lt(Ne,{name:L,scope:N}))){ce.error(n("mainPanelTabs.hostingTab.errorEnvNameDuplicate"));return}_.mutate([...i,{name:L,value:g,scope:N}],{onSuccess:()=>{d(!1),u(""),h(""),C("runtime")}})},e[12]=f,e[13]=N,e[14]=g,e[15]=_,e[16]=i,e[17]=n,e[18]=W):W=e[18];const J=W;let Q;e[19]!==y||e[20]!==_||e[21]!==i?(Q=L=>{_.mutate(i.map(Ne=>Lt(Ne,L)?{name:L.name,value:y,scope:L.scope}:Ne),{onSuccess:()=>S(null)})},e[19]=y,e[20]=_,e[21]=i,e[22]=Q):Q=e[22];const p=Q;let I;e[23]!==w||e[24]!==_||e[25]!==i?(I=()=>{w&&_.mutate(i.filter(L=>!Lt(L,w)),{onSuccess:()=>j(null)})},e[23]=w,e[24]=_,e[25]=i,e[26]=I):I=e[26];const X=I,D=_.isPending;let Y;e[27]===Symbol.for("react.memo_cache_sentinel")?(Y=()=>{u(""),h(""),C("runtime")},e[27]=Y):Y=e[27];const O=Y;let k,E;e[28]===Symbol.for("react.memo_cache_sentinel")?(k=()=>d(!0),E=t.jsx(Pt,{}),e[28]=k,e[29]=E):(k=e[28],E=e[29]);let B;e[30]!==n?(B=n("mainPanelTabs.hostingTab.addVariable"),e[30]=n,e[31]=B):B=e[31];let G;e[32]!==B?(G=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:k,children:[E,B]}),e[32]=B,e[33]=G):G=e[33];const te=G;let U;e[34]!==n?(U=n("mainPanelTabs.hostingTab.env"),e[34]=n,e[35]=U):U=e[35];const ne=i.length>0||c.length>0?te:void 0;let ie;e[36]!==te||e[37]!==c||e[38]!==y||e[39]!==P?.name||e[40]!==P?.scope||e[41]!==i||e[42]!==s||e[43]!==p||e[44]!==m||e[45]!==D||e[46]!==V||e[47]!==n?(ie=m?t.jsx(ht,{}):s?t.jsx(Ie,{children:t.jsx(ot,{children:n("mainPanelTabs.hostingTab.envError")})}):i.length===0&&c.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Xt,{className:"size-5"}),title:n("mainPanelTabs.hostingTab.noEnv"),className:"py-10",buttonComponent:te})}):t.jsxs(Ie,{children:[i.map(L=>{const Ne=L.scope==="build"?"build":"runtime",We=`${L.name}:${Ne}`,tt=P?.name===L.name&&P?.scope===Ne,st=V.has(We);return t.jsxs(pt,{children:[t.jsxs("div",{className:"flex min-w-0 flex-1 basis-0 items-center gap-2",children:[t.jsx("div",{className:"w-20 shrink-0",children:t.jsx(xs,{scope:Ne})}),t.jsx("span",{className:"truncate font-mono text-xs",children:L.name})]}),t.jsx("div",{className:"flex min-w-0 flex-1 basis-0 items-center justify-end gap-2",children:tt?t.jsxs(t.Fragment,{children:[t.jsx(it,{value:y,onChange:z=>R(z.target.value),onKeyDown:z=>{z.key==="Enter"&&p({name:L.name,scope:Ne}),z.key==="Escape"&&S(null)},autoFocus:!0,className:"h-8 font-mono text-xs"}),t.jsx(Qe,{size:"sm",onClick:()=>p({name:L.name,scope:Ne}),disabled:D,children:n("mainPanelTabs.hostingTab.save")}),t.jsx(Qe,{size:"sm",variant:"ghost",onClick:()=>S(null),disabled:D,children:n("mainPanelTabs.hostingTab.cancel")})]}):t.jsxs(t.Fragment,{children:[t.jsx(et,{label:n(st?"mainPanelTabs.hostingTab.hideValue":"mainPanelTabs.hostingTab.showValue"),onClick:()=>v(We),className:"text-muted-foreground",children:st?t.jsx(qs,{}):t.jsx(Ms,{})}),st?t.jsx("button",{type:"button",onClick:()=>{S({name:L.name,scope:Ne}),R(L.value)},title:n("mainPanelTabs.hostingTab.editValue"),className:"min-w-0 truncate px-1.5 py-0.5 text-right font-mono text-xs text-muted-foreground hover:bg-muted hover:text-foreground rounded-lg",children:L.value||"—"}):t.jsx("span",{className:"min-w-0 truncate px-1.5 py-0.5 text-right font-mono text-xs text-muted-foreground/60",children:L.value?"••••••••••":"—"})]})}),t.jsx(et,{label:n("mainPanelTabs.hostingTab.deleteVariable"),onClick:()=>j({name:L.name,scope:Ne}),disabled:D,className:"text-muted-foreground",children:t.jsx(vt,{})})]},We)}),c.length>0&&t.jsxs(Ht,{children:[t.jsx(Vs,{asChild:!0,children:t.jsxs("button",{type:"button",className:"group flex w-full items-center gap-2 px-4 py-2.5 text-left text-xs text-muted-foreground hover:bg-muted/40",children:[t.jsx(ns,{className:"size-4 transition-transform duration-200 group-data-[state=open]:rotate-90 motion-reduce:transition-none"}),t.jsx(Xt,{className:"size-4"}),n("mainPanelTabs.hostingTab.codeVarsToggle",{count:String(c.length)})]})}),t.jsx(Vt,{children:t.jsx("div",{className:"divide-y divide-border/60 border-t border-border bg-muted/30",children:c.map(Pn)})})]})]}),e[36]=te,e[37]=c,e[38]=y,e[39]=P?.name,e[40]=P?.scope,e[41]=i,e[42]=s,e[43]=p,e[44]=m,e[45]=D,e[46]=V,e[47]=n,e[48]=ie):ie=e[48];let Pe;e[49]===Symbol.for("react.memo_cache_sentinel")?(Pe=L=>{d(L),L||O()},e[49]=Pe):Pe=e[49];let Ce;e[50]!==n?(Ce=n("mainPanelTabs.hostingTab.addVariable"),e[50]=n,e[51]=Ce):Ce=e[51];let me;e[52]!==Ce?(me=t.jsx(yt,{children:t.jsx(St,{children:Ce})}),e[52]=Ce,e[53]=me):me=e[53];let pe;e[54]!==J?(pe=L=>{L.preventDefault(),J()},e[54]=J,e[55]=pe):pe=e[55];let le;e[56]!==n?(le=n("mainPanelTabs.hostingTab.colName"),e[56]=n,e[57]=le):le=e[57];let ae;e[58]!==le?(ae=t.jsx(Ge,{htmlFor:"env-name",children:le}),e[58]=le,e[59]=ae):ae=e[59];let de;e[60]!==n?(de=n("mainPanelTabs.hostingTab.envNamePlaceholder"),e[60]=n,e[61]=de):de=e[61];let De;e[62]===Symbol.for("react.memo_cache_sentinel")?(De=L=>u(L.target.value),e[62]=De):De=e[62];let fe;e[63]!==f||e[64]!==D||e[65]!==de?(fe=t.jsx(it,{id:"env-name",placeholder:de,value:f,onChange:De,className:"font-mono text-xs",autoComplete:"off",disabled:D}),e[63]=f,e[64]=D,e[65]=de,e[66]=fe):fe=e[66];let ue;e[67]!==ae||e[68]!==fe?(ue=t.jsxs("div",{className:"flex flex-col gap-2",children:[ae,fe]}),e[67]=ae,e[68]=fe,e[69]=ue):ue=e[69];let oe;e[70]!==n?(oe=n("mainPanelTabs.hostingTab.colValue"),e[70]=n,e[71]=oe):oe=e[71];let Te;e[72]!==oe?(Te=t.jsx(Ge,{htmlFor:"env-value",children:oe}),e[72]=oe,e[73]=Te):Te=e[73];let he;e[74]!==n?(he=n("mainPanelTabs.hostingTab.envValuePlaceholder"),e[74]=n,e[75]=he):he=e[75];let xe;e[76]===Symbol.for("react.memo_cache_sentinel")?(xe=L=>h(L.target.value),e[76]=xe):xe=e[76];let ve;e[77]!==g||e[78]!==D||e[79]!==he?(ve=t.jsx(it,{id:"env-value",placeholder:he,value:g,onChange:xe,className:"font-mono text-xs",autoComplete:"off",disabled:D}),e[77]=g,e[78]=D,e[79]=he,e[80]=ve):ve=e[80];let ye;e[81]!==Te||e[82]!==ve?(ye=t.jsxs("div",{className:"flex flex-col gap-2",children:[Te,ve]}),e[81]=Te,e[82]=ve,e[83]=ye):ye=e[83];let ge;e[84]!==n?(ge=n("mainPanelTabs.hostingTab.secretScope"),e[84]=n,e[85]=ge):ge=e[85];let re;e[86]!==ge?(re=t.jsx(Ge,{children:ge}),e[86]=ge,e[87]=re):re=e[87];let be;e[88]!==N||e[89]!==D?(be=t.jsx(Tn,{value:N,onChange:C,disabled:D,className:"w-full"}),e[88]=N,e[89]=D,e[90]=be):be=e[90];let we;e[91]!==N||e[92]!==n?(we=n(N==="build"?"mainPanelTabs.hostingTab.secretScopeBuildHint":"mainPanelTabs.hostingTab.secretScopeRuntimeHint"),e[91]=N,e[92]=n,e[93]=we):we=e[93];let $;e[94]!==we?($=t.jsx("p",{className:"text-xs text-muted-foreground",children:we}),e[94]=we,e[95]=$):$=e[95];let se;e[96]!==re||e[97]!==be||e[98]!==$?(se=t.jsxs("div",{className:"flex flex-col gap-2",children:[re,be,$]}),e[96]=re,e[97]=be,e[98]=$,e[99]=se):se=e[99];let Se;e[100]===Symbol.for("react.memo_cache_sentinel")?(Se=()=>{d(!1),O()},e[100]=Se):Se=e[100];let je;e[101]!==n?(je=n("mainPanelTabs.hostingTab.cancel"),e[101]=n,e[102]=je):je=e[102];let $e;e[103]!==D||e[104]!==je?($e=t.jsx(Qe,{variant:"outline",type:"button",onClick:Se,disabled:D,children:je}),e[103]=D,e[104]=je,e[105]=$e):$e=e[105];let ze;e[106]!==f||e[107]!==D?(ze=D||!f.trim(),e[106]=f,e[107]=D,e[108]=ze):ze=e[108];let Ue;e[109]!==D||e[110]!==n?(Ue=n(D?"mainPanelTabs.hostingTab.saving":"mainPanelTabs.hostingTab.add"),e[109]=D,e[110]=n,e[111]=Ue):Ue=e[111];let Le;e[112]!==ze||e[113]!==Ue?(Le=t.jsx(Qe,{type:"submit",disabled:ze,children:Ue}),e[112]=ze,e[113]=Ue,e[114]=Le):Le=e[114];let _e;e[115]!==$e||e[116]!==Le?(_e=t.jsxs(Nt,{children:[$e,Le]}),e[115]=$e,e[116]=Le,e[117]=_e):_e=e[117];let Be;e[118]!==pe||e[119]!==ue||e[120]!==ye||e[121]!==se||e[122]!==_e?(Be=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:pe,children:[ue,ye,se,_e]}),e[118]=pe,e[119]=ue,e[120]=ye,e[121]=se,e[122]=_e,e[123]=Be):Be=e[123];let Ve;e[124]!==me||e[125]!==Be?(Ve=t.jsxs(Ct,{className:"sm:max-w-md",children:[me,Be]}),e[124]=me,e[125]=Be,e[126]=Ve):Ve=e[126];let ke;e[127]!==b||e[128]!==Ve?(ke=t.jsx(Dt,{open:b,onOpenChange:Pe,children:Ve}),e[127]=b,e[128]=Ve,e[129]=ke):ke=e[129];const Je=w!=null;let He;e[130]===Symbol.for("react.memo_cache_sentinel")?(He=L=>{L||j(null)},e[130]=He):He=e[130];let Ee;e[131]!==n?(Ee=n("mainPanelTabs.hostingTab.confirmDeleteVariableTitle"),e[131]=n,e[132]=Ee):Ee=e[132];const Oe=w?.name??"";let qe;e[133]!==n||e[134]!==Oe?(qe=n("mainPanelTabs.hostingTab.confirmDeleteVariableDescription",{name:Oe}),e[133]=n,e[134]=Oe,e[135]=qe):qe=e[135];let Ke;e[136]!==n?(Ke=n("mainPanelTabs.hostingTab.deleteVariable"),e[136]=n,e[137]=Ke):Ke=e[137];let M;e[138]!==X||e[139]!==D||e[140]!==Je||e[141]!==Ee||e[142]!==qe||e[143]!==Ke?(M=t.jsx(wt,{open:Je,onOpenChange:He,title:Ee,description:qe,confirmLabel:Ke,pending:D,onConfirm:X}),e[138]=X,e[139]=D,e[140]=Je,e[141]=Ee,e[142]=qe,e[143]=Ke,e[144]=M):M=e[144];let Ye;return e[145]!==U||e[146]!==ne||e[147]!==ie||e[148]!==ke||e[149]!==M?(Ye=t.jsxs(ut,{title:U,actions:ne,children:[ie,ke,M]}),e[145]=U,e[146]=ne,e[147]=ie,e[148]=ke,e[149]=M,e[150]=Ye):Ye=e[150],Ye}function Pn(r){return t.jsxs("div",{className:"flex items-center gap-3 px-4 py-2 font-mono text-xs",children:[t.jsx("span",{className:"flex-1 basis-0 truncate",children:r.name}),t.jsx("span",{className:"flex-1 basis-0 truncate text-right text-muted-foreground",children:r.value})]},r.name)}function vn(r){return ce.error(rt(r))}function yn(r){const e=Z.c(6),{type:o}=r,l=Ae(),a=o==="permanent"?"secondary":"outline";let i;e[0]!==l||e[1]!==o?(i=l(o==="permanent"?"mainPanelTabs.hostingTab.permanent":"mainPanelTabs.hostingTab.temporary"),e[0]=l,e[1]=o,e[2]=i):i=e[2];let c;return e[3]!==a||e[4]!==i?(c=t.jsx(Re,{variant:a,children:i}),e[3]=a,e[4]=i,e[5]=c):c=e[5],c}function Sn(r){const e=Z.c(163),{base:o,orgSlug:l,site:a,redirects:i,isLoading:c,error:m}=r,s=Ae(),n=bt(),[x,b]=ee.useState(!1),[d,f]=ee.useState(null),[u,g]=ee.useState(""),[h,N]=ee.useState(""),[C,P]=ee.useState("permanent"),[S,y]=ee.useState(null),[R,w]=ee.useState(null);let j;e[0]!==l||e[1]!==n||e[2]!==a?(j=()=>n.invalidateQueries({queryKey:Xe.hostingRedirects(l,a)}),e[0]=l,e[1]=n,e[2]=a,e[3]=j):j=e[3];const T=j;let V;e[4]!==o?(V=z=>at(`${o}/redirects`,"PUT",z),e[4]=o,e[5]=V):V=e[5];let q;e[6]!==T||e[7]!==s?(q=()=>{T(),ce.success(s("mainPanelTabs.hostingTab.toastRedirectSaved")),b(!1)},e[6]=T,e[7]=s,e[8]=q):q=e[8];let F;e[9]!==V||e[10]!==q?(F={mutationFn:V,onSuccess:q,onError:Cn},e[9]=V,e[10]=q,e[11]=F):F=e[11];const v=lt(F);let H;e[12]!==o?(H=z=>at(`${o}/redirects/${encodeURIComponent(z)}`,"DELETE"),e[12]=o,e[13]=H):H=e[13];let A;e[14]!==T||e[15]!==s?(A=()=>{T(),ce.success(s("mainPanelTabs.hostingTab.toastRedirectDeleted")),y(null)},e[14]=T,e[15]=s,e[16]=A):A=e[16];let K;e[17]!==H||e[18]!==A?(K={mutationFn:H,onSuccess:A,onError:Nn},e[17]=H,e[18]=A,e[19]=K):K=e[19];const _=lt(K);let W;e[20]===Symbol.for("react.memo_cache_sentinel")?(W=()=>{f(null),g(""),N(""),P("permanent"),b(!0)},e[20]=W):W=e[20];const J=W;let Q;e[21]===Symbol.for("react.memo_cache_sentinel")?(Q=z=>{f(z.from),g(z.from),N(z.to),P(z.type==="temporary"?"temporary":"permanent"),b(!0)},e[21]=Q):Q=e[21];const p=Q;let I;e[22]!==u||e[23]!==h||e[24]!==C||e[25]!==v||e[26]!==s?(I=()=>{const z=u.trim(),Tt=h.trim();if(!z||!Tt){ce.error(s("mainPanelTabs.hostingTab.errorRedirectFieldsRequired"));return}v.mutate({from:z,to:Tt,type:C})},e[22]=u,e[23]=h,e[24]=C,e[25]=v,e[26]=s,e[27]=I):I=e[27];const X=I;let D;e[28]===Symbol.for("react.memo_cache_sentinel")?(D=t.jsx(Pt,{}),e[28]=D):D=e[28];let Y;e[29]!==s?(Y=s("mainPanelTabs.hostingTab.addRedirect"),e[29]=s,e[30]=Y):Y=e[30];let O;e[31]!==Y?(O=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:J,children:[D,Y]}),e[31]=Y,e[32]=O):O=e[32];const k=O;let E;e[33]!==s?(E=s("mainPanelTabs.hostingTab.redirects"),e[33]=s,e[34]=E):E=e[34];const B=i.length>0?k:void 0;let G;e[35]!==k||e[36]!==_.isPending||e[37]!==R||e[38]!==m||e[39]!==c||e[40]!==v.isPending||e[41]!==i||e[42]!==s?(G=c?t.jsx(ht,{}):m?t.jsx(Ie,{children:t.jsx(ot,{children:s("mainPanelTabs.hostingTab.redirectsError")})}):i.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Yt,{className:"size-5"}),title:s("mainPanelTabs.hostingTab.noRedirects"),className:"py-10",buttonComponent:k})}):t.jsx(Ie,{children:i.map((z,Tt)=>{const Ut=es(z.from),$t=R===z.from;return t.jsxs("div",{children:[t.jsxs(pt,{children:[Ut?t.jsx(Qt,{open:$t,onClick:()=>w($t?null:z.from)}):t.jsx(Yt,{className:"size-4 shrink-0 text-muted-foreground/60"}),t.jsxs("div",{className:"flex min-w-0 flex-1 items-center gap-2 font-mono text-xs",children:[t.jsx("span",{className:"truncate",children:z.from}),t.jsx(Is,{className:"size-3.5 shrink-0 text-muted-foreground/60"}),t.jsx("span",{className:"truncate text-muted-foreground",children:z.to})]}),t.jsx(yn,{type:z.type}),t.jsx(et,{label:s("mainPanelTabs.hostingTab.editRedirect"),onClick:()=>p(z),disabled:v.isPending,className:"text-muted-foreground",children:t.jsx(Ls,{})}),t.jsx(et,{label:s("mainPanelTabs.hostingTab.deleteRedirect"),onClick:()=>y(z.from),disabled:_.isPending,className:"-ml-1 text-muted-foreground",children:t.jsx(vt,{})})]}),Ut&&t.jsx(hs,{open:$t,children:t.jsx(ts,{from:z.from,source:z.source})})]},z.id??`${z.from}-${Tt}`)})}),e[35]=k,e[36]=_.isPending,e[37]=R,e[38]=m,e[39]=c,e[40]=v.isPending,e[41]=i,e[42]=s,e[43]=G):G=e[43];let te;e[44]!==d||e[45]!==s?(te=d!=null?s("mainPanelTabs.hostingTab.editRedirectTitle"):s("mainPanelTabs.hostingTab.addRedirectTitle"),e[44]=d,e[45]=s,e[46]=te):te=e[46];let U;e[47]!==te?(U=t.jsx(yt,{children:t.jsx(St,{children:te})}),e[47]=te,e[48]=U):U=e[48];let ne;e[49]!==X?(ne=z=>{z.preventDefault(),X()},e[49]=X,e[50]=ne):ne=e[50];let ie;e[51]!==s?(ie=s("mainPanelTabs.hostingTab.colFrom"),e[51]=s,e[52]=ie):ie=e[52];let Pe;e[53]!==ie?(Pe=t.jsx(Ge,{htmlFor:"redirect-from",children:ie}),e[53]=ie,e[54]=Pe):Pe=e[54];let Ce;e[55]!==s?(Ce=s("mainPanelTabs.hostingTab.redirectFromPlaceholder"),e[55]=s,e[56]=Ce):Ce=e[56];let me;e[57]===Symbol.for("react.memo_cache_sentinel")?(me=z=>g(z.target.value),e[57]=me):me=e[57];const pe=d!=null||v.isPending;let le;e[58]!==u||e[59]!==Ce||e[60]!==pe?(le=t.jsx(it,{id:"redirect-from",placeholder:Ce,value:u,onChange:me,className:"font-mono text-xs",disabled:pe}),e[58]=u,e[59]=Ce,e[60]=pe,e[61]=le):le=e[61];let ae;e[62]!==Pe||e[63]!==le?(ae=t.jsxs("div",{className:"flex flex-col gap-2",children:[Pe,le]}),e[62]=Pe,e[63]=le,e[64]=ae):ae=e[64];let de;e[65]!==s?(de=s("mainPanelTabs.hostingTab.colTo"),e[65]=s,e[66]=de):de=e[66];let De;e[67]!==de?(De=t.jsx(Ge,{htmlFor:"redirect-to",children:de}),e[67]=de,e[68]=De):De=e[68];let fe;e[69]!==s?(fe=s("mainPanelTabs.hostingTab.redirectToPlaceholder"),e[69]=s,e[70]=fe):fe=e[70];let ue;e[71]===Symbol.for("react.memo_cache_sentinel")?(ue=z=>N(z.target.value),e[71]=ue):ue=e[71];let oe;e[72]!==h||e[73]!==v.isPending||e[74]!==fe?(oe=t.jsx(it,{id:"redirect-to",placeholder:fe,value:h,onChange:ue,className:"font-mono text-xs",disabled:v.isPending}),e[72]=h,e[73]=v.isPending,e[74]=fe,e[75]=oe):oe=e[75];let Te;e[76]!==De||e[77]!==oe?(Te=t.jsxs("div",{className:"flex flex-col gap-2",children:[De,oe]}),e[76]=De,e[77]=oe,e[78]=Te):Te=e[78];let he;e[79]!==s?(he=s("mainPanelTabs.hostingTab.colType"),e[79]=s,e[80]=he):he=e[80];let xe;e[81]!==he?(xe=t.jsx(Ge,{children:he}),e[81]=he,e[82]=xe):xe=e[82];let ve;e[83]===Symbol.for("react.memo_cache_sentinel")?(ve=z=>P(z==="temporary"?"temporary":"permanent"),e[83]=ve):ve=e[83];const ye=v.isPending;let ge;e[84]===Symbol.for("react.memo_cache_sentinel")?(ge=t.jsx(Ot,{className:"w-full",children:t.jsx(Bt,{})}),e[84]=ge):ge=e[84];let re;e[85]!==s?(re=s("mainPanelTabs.hostingTab.permanent"),e[85]=s,e[86]=re):re=e[86];let be;e[87]!==re?(be=t.jsx(ft,{value:"permanent",children:re}),e[87]=re,e[88]=be):be=e[88];let we;e[89]!==s?(we=s("mainPanelTabs.hostingTab.temporary"),e[89]=s,e[90]=we):we=e[90];let $;e[91]!==we?($=t.jsx(ft,{value:"temporary",children:we}),e[91]=we,e[92]=$):$=e[92];let se;e[93]!==be||e[94]!==$?(se=t.jsxs(qt,{children:[be,$]}),e[93]=be,e[94]=$,e[95]=se):se=e[95];let Se;e[96]!==C||e[97]!==v.isPending||e[98]!==se?(Se=t.jsxs(Mt,{value:C,onValueChange:ve,disabled:ye,children:[ge,se]}),e[96]=C,e[97]=v.isPending,e[98]=se,e[99]=Se):Se=e[99];let je;e[100]!==xe||e[101]!==Se?(je=t.jsxs("div",{className:"flex flex-col gap-2",children:[xe,Se]}),e[100]=xe,e[101]=Se,e[102]=je):je=e[102];let $e;e[103]!==d||e[104]!==u||e[105]!==i?($e=es(u)&&t.jsx("div",{className:"rounded-lg border border-border bg-muted/30 p-3",children:t.jsx(ts,{from:u,source:i.find(z=>z.from===d)?.source})}),e[103]=d,e[104]=u,e[105]=i,e[106]=$e):$e=e[106];let ze;e[107]===Symbol.for("react.memo_cache_sentinel")?(ze=()=>b(!1),e[107]=ze):ze=e[107];const Ue=v.isPending;let Le;e[108]!==s?(Le=s("mainPanelTabs.hostingTab.cancel"),e[108]=s,e[109]=Le):Le=e[109];let _e;e[110]!==v.isPending||e[111]!==Le?(_e=t.jsx(Qe,{variant:"outline",type:"button",onClick:ze,disabled:Ue,children:Le}),e[110]=v.isPending,e[111]=Le,e[112]=_e):_e=e[112];let Be;e[113]!==u||e[114]!==h||e[115]!==v.isPending?(Be=v.isPending||!u.trim()||!h.trim(),e[113]=u,e[114]=h,e[115]=v.isPending,e[116]=Be):Be=e[116];let Ve;e[117]!==v.isPending||e[118]!==s?(Ve=v.isPending?s("mainPanelTabs.hostingTab.saving"):s("mainPanelTabs.hostingTab.save"),e[117]=v.isPending,e[118]=s,e[119]=Ve):Ve=e[119];let ke;e[120]!==Be||e[121]!==Ve?(ke=t.jsx(Qe,{type:"submit",disabled:Be,children:Ve}),e[120]=Be,e[121]=Ve,e[122]=ke):ke=e[122];let Je;e[123]!==_e||e[124]!==ke?(Je=t.jsxs(Nt,{children:[_e,ke]}),e[123]=_e,e[124]=ke,e[125]=Je):Je=e[125];let He;e[126]!==ne||e[127]!==ae||e[128]!==Te||e[129]!==je||e[130]!==$e||e[131]!==Je?(He=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:ne,children:[ae,Te,je,$e,Je]}),e[126]=ne,e[127]=ae,e[128]=Te,e[129]=je,e[130]=$e,e[131]=Je,e[132]=He):He=e[132];let Ee;e[133]!==U||e[134]!==He?(Ee=t.jsxs(Ct,{className:"sm:max-w-md",children:[U,He]}),e[133]=U,e[134]=He,e[135]=Ee):Ee=e[135];let Oe;e[136]!==x||e[137]!==Ee?(Oe=t.jsx(Dt,{open:x,onOpenChange:b,children:Ee}),e[136]=x,e[137]=Ee,e[138]=Oe):Oe=e[138];const qe=S!=null;let Ke;e[139]===Symbol.for("react.memo_cache_sentinel")?(Ke=z=>{z||y(null)},e[139]=Ke):Ke=e[139];let M;e[140]!==s?(M=s("mainPanelTabs.hostingTab.confirmDeleteRedirectTitle"),e[140]=s,e[141]=M):M=e[141];const Ye=S??"";let L;e[142]!==s||e[143]!==Ye?(L=s("mainPanelTabs.hostingTab.confirmDeleteRedirectDescription",{from:Ye}),e[142]=s,e[143]=Ye,e[144]=L):L=e[144];let Ne;e[145]!==s?(Ne=s("mainPanelTabs.hostingTab.deleteRedirect"),e[145]=s,e[146]=Ne):Ne=e[146];let We;e[147]!==_||e[148]!==S?(We=()=>{S&&_.mutate(S)},e[147]=_,e[148]=S,e[149]=We):We=e[149];let tt;e[150]!==_.isPending||e[151]!==qe||e[152]!==M||e[153]!==L||e[154]!==Ne||e[155]!==We?(tt=t.jsx(wt,{open:qe,onOpenChange:Ke,title:M,description:L,confirmLabel:Ne,pending:_.isPending,onConfirm:We}),e[150]=_.isPending,e[151]=qe,e[152]=M,e[153]=L,e[154]=Ne,e[155]=We,e[156]=tt):tt=e[156];let st;return e[157]!==E||e[158]!==B||e[159]!==G||e[160]!==Oe||e[161]!==tt?(st=t.jsxs(ut,{title:E,actions:B,children:[G,Oe,tt]}),e[157]=E,e[158]=B,e[159]=G,e[160]=Oe,e[161]=tt,e[162]=st):st=e[162],st}function Nn(r){return ce.error(rt(r))}function Cn(r){return ce.error(rt(r))}function Dn(r){const e=Z.c(160),{base:o,orgSlug:l,site:a,secrets:i,isLoading:c,error:m}=r,s=Ae(),n=bt(),[x,b]=ee.useState(!1),[d,f]=ee.useState(""),[u,g]=ee.useState(""),[h,N]=ee.useState("runtime"),[C,P]=ee.useState(null);let S;e[0]!==l||e[1]!==n||e[2]!==a?(S=()=>n.invalidateQueries({queryKey:Xe.hostingSecrets(l,a)}),e[0]=l,e[1]=n,e[2]=a,e[3]=S):S=e[3];const y=S;let R;e[4]!==o?(R=M=>at(`${o}/secrets`,"PUT",M),e[4]=o,e[5]=R):R=e[5];let w;e[6]!==y||e[7]!==s?(w=()=>{y(),ce.success(s("mainPanelTabs.hostingTab.toastSecretSaved")),b(!1),f(""),g(""),N("runtime")},e[6]=y,e[7]=s,e[8]=w):w=e[8];let j;e[9]!==R||e[10]!==w?(j={mutationFn:R,onSuccess:w,onError:$n},e[9]=R,e[10]=w,e[11]=j):j=e[11];const T=lt(j);let V;e[12]!==o?(V=M=>at(`${o}/secrets/${encodeURIComponent(M.name)}?scope=${M.scope}`,"DELETE"),e[12]=o,e[13]=V):V=e[13];let q;e[14]!==y||e[15]!==s?(q=()=>{y(),ce.success(s("mainPanelTabs.hostingTab.toastSecretDeleted")),P(null)},e[14]=y,e[15]=s,e[16]=q):q=e[16];let F;e[17]!==V||e[18]!==q?(F={mutationFn:V,onSuccess:q,onError:wn},e[17]=V,e[18]=q,e[19]=F):F=e[19];const v=lt(F);let H;e[20]!==d||e[21]!==h||e[22]!==u||e[23]!==T||e[24]!==s?(H=()=>{const M=d.trim();if(!M){ce.error(s("mainPanelTabs.hostingTab.errorSecretNameRequired"));return}if(!u){ce.error(s("mainPanelTabs.hostingTab.errorSecretValueRequired"));return}T.mutate({name:M,value:u,scope:h})},e[20]=d,e[21]=h,e[22]=u,e[23]=T,e[24]=s,e[25]=H):H=e[25];const A=H;let K,_;e[26]===Symbol.for("react.memo_cache_sentinel")?(_=()=>b(!0),K=t.jsx(Pt,{}),e[26]=K,e[27]=_):(K=e[26],_=e[27]);let W;e[28]!==s?(W=s("mainPanelTabs.hostingTab.addSecret"),e[28]=s,e[29]=W):W=e[29];let J;e[30]!==W?(J=t.jsxs(Qe,{size:"sm",variant:"outline",onClick:_,children:[K,W]}),e[30]=W,e[31]=J):J=e[31];const Q=J;let p;e[32]!==s?(p=s("mainPanelTabs.hostingTab.secrets"),e[32]=s,e[33]=p):p=e[33];const I=i.length>0?Q:void 0;let X;e[34]!==Q||e[35]!==v.isPending||e[36]!==m||e[37]!==c||e[38]!==i||e[39]!==s?(X=c?t.jsx(ht,{}):m?t.jsx(Ie,{children:t.jsx(ot,{children:s("mainPanelTabs.hostingTab.secretsError")})}):i.length===0?t.jsx(Ie,{children:t.jsx(Ze,{icon:t.jsx(Wt,{className:"size-5"}),title:s("mainPanelTabs.hostingTab.noSecrets"),className:"py-10",buttonComponent:Q})}):t.jsx(Ie,{children:i.map(M=>{const Ye=M.scope==="build"?"build":"runtime";return t.jsxs(pt,{children:[t.jsx(Wt,{className:"size-4 shrink-0 text-muted-foreground/60"}),t.jsxs("div",{className:"flex min-w-0 flex-1 items-center gap-2",children:[t.jsx("div",{className:"w-20 shrink-0",children:t.jsx(xs,{scope:Ye})}),t.jsx("span",{className:"truncate font-mono text-xs",children:M.name}),M.origin==="worker"&&t.jsx(Re,{variant:"secondary",children:s("mainPanelTabs.hostingTab.secretOnWorker")})]}),t.jsx("span",{className:"font-mono text-xs text-muted-foreground/60",children:s("mainPanelTabs.hostingTab.secretValueHidden")}),t.jsx(et,{label:s("mainPanelTabs.hostingTab.deleteSecret"),onClick:()=>P({name:M.name,scope:Ye}),disabled:v.isPending,className:"text-muted-foreground",children:t.jsx(vt,{})})]},`${M.name}:${Ye}`)})}),e[34]=Q,e[35]=v.isPending,e[36]=m,e[37]=c,e[38]=i,e[39]=s,e[40]=X):X=e[40];let D;e[41]!==s?(D=s("mainPanelTabs.hostingTab.addSecretTitle"),e[41]=s,e[42]=D):D=e[42];let Y;e[43]!==D?(Y=t.jsx(yt,{children:t.jsx(St,{children:D})}),e[43]=D,e[44]=Y):Y=e[44];let O;e[45]!==A?(O=M=>{M.preventDefault(),A()},e[45]=A,e[46]=O):O=e[46];let k;e[47]!==s?(k=s("mainPanelTabs.hostingTab.colName"),e[47]=s,e[48]=k):k=e[48];let E;e[49]!==k?(E=t.jsx(Ge,{htmlFor:"secret-name",children:k}),e[49]=k,e[50]=E):E=e[50];let B;e[51]!==s?(B=s("mainPanelTabs.hostingTab.secretNamePlaceholder"),e[51]=s,e[52]=B):B=e[52];let G;e[53]===Symbol.for("react.memo_cache_sentinel")?(G=M=>f(M.target.value),e[53]=G):G=e[53];let te;e[54]!==d||e[55]!==T.isPending||e[56]!==B?(te=t.jsx(it,{id:"secret-name",placeholder:B,value:d,onChange:G,className:"font-mono text-xs",autoComplete:"off",disabled:T.isPending}),e[54]=d,e[55]=T.isPending,e[56]=B,e[57]=te):te=e[57];let U;e[58]!==E||e[59]!==te?(U=t.jsxs("div",{className:"flex flex-col gap-2",children:[E,te]}),e[58]=E,e[59]=te,e[60]=U):U=e[60];let ne;e[61]!==s?(ne=s("mainPanelTabs.hostingTab.colValue"),e[61]=s,e[62]=ne):ne=e[62];let ie;e[63]!==ne?(ie=t.jsx(Ge,{htmlFor:"secret-value",children:ne}),e[63]=ne,e[64]=ie):ie=e[64];let Pe;e[65]!==s?(Pe=s("mainPanelTabs.hostingTab.secretValuePlaceholder"),e[65]=s,e[66]=Pe):Pe=e[66];let Ce;e[67]===Symbol.for("react.memo_cache_sentinel")?(Ce=M=>g(M.target.value),e[67]=Ce):Ce=e[67];let me;e[68]!==u||e[69]!==T.isPending||e[70]!==Pe?(me=t.jsx(it,{id:"secret-value",type:"password",placeholder:Pe,value:u,onChange:Ce,className:"font-mono text-xs",autoComplete:"new-password",disabled:T.isPending}),e[68]=u,e[69]=T.isPending,e[70]=Pe,e[71]=me):me=e[71];let pe;e[72]!==ie||e[73]!==me?(pe=t.jsxs("div",{className:"flex flex-col gap-2",children:[ie,me]}),e[72]=ie,e[73]=me,e[74]=pe):pe=e[74];let le;e[75]!==s?(le=s("mainPanelTabs.hostingTab.secretScope"),e[75]=s,e[76]=le):le=e[76];let ae;e[77]!==le?(ae=t.jsx(Ge,{children:le}),e[77]=le,e[78]=ae):ae=e[78];let de;e[79]===Symbol.for("react.memo_cache_sentinel")?(de=M=>N(M==="build"?"build":"runtime"),e[79]=de):de=e[79];const De=T.isPending;let fe;e[80]===Symbol.for("react.memo_cache_sentinel")?(fe=t.jsx(Ot,{className:"w-full",children:t.jsx(Bt,{})}),e[80]=fe):fe=e[80];let ue;e[81]!==s?(ue=s("mainPanelTabs.hostingTab.secretScopeRuntime"),e[81]=s,e[82]=ue):ue=e[82];let oe;e[83]!==ue?(oe=t.jsx(ft,{value:"runtime",children:ue}),e[83]=ue,e[84]=oe):oe=e[84];let Te;e[85]!==s?(Te=s("mainPanelTabs.hostingTab.secretScopeBuild"),e[85]=s,e[86]=Te):Te=e[86];let he;e[87]!==Te?(he=t.jsx(ft,{value:"build",children:Te}),e[87]=Te,e[88]=he):he=e[88];let xe;e[89]!==oe||e[90]!==he?(xe=t.jsxs(qt,{children:[oe,he]}),e[89]=oe,e[90]=he,e[91]=xe):xe=e[91];let ve;e[92]!==h||e[93]!==T.isPending||e[94]!==xe?(ve=t.jsxs(Mt,{value:h,onValueChange:de,disabled:De,children:[fe,xe]}),e[92]=h,e[93]=T.isPending,e[94]=xe,e[95]=ve):ve=e[95];let ye;e[96]!==h||e[97]!==s?(ye=s(h==="build"?"mainPanelTabs.hostingTab.secretScopeBuildHint":"mainPanelTabs.hostingTab.secretScopeRuntimeHint"),e[96]=h,e[97]=s,e[98]=ye):ye=e[98];let ge;e[99]!==ye?(ge=t.jsx("p",{className:"text-xs text-muted-foreground",children:ye}),e[99]=ye,e[100]=ge):ge=e[100];let re;e[101]!==ae||e[102]!==ve||e[103]!==ge?(re=t.jsxs("div",{className:"flex flex-col gap-2",children:[ae,ve,ge]}),e[101]=ae,e[102]=ve,e[103]=ge,e[104]=re):re=e[104];let be;e[105]===Symbol.for("react.memo_cache_sentinel")?(be=()=>b(!1),e[105]=be):be=e[105];const we=T.isPending;let $;e[106]!==s?($=s("mainPanelTabs.hostingTab.cancel"),e[106]=s,e[107]=$):$=e[107];let se;e[108]!==T.isPending||e[109]!==$?(se=t.jsx(Qe,{variant:"outline",type:"button",onClick:be,disabled:we,children:$}),e[108]=T.isPending,e[109]=$,e[110]=se):se=e[110];let Se;e[111]!==d||e[112]!==u||e[113]!==T.isPending?(Se=T.isPending||!d.trim()||!u,e[111]=d,e[112]=u,e[113]=T.isPending,e[114]=Se):Se=e[114];let je;e[115]!==T.isPending||e[116]!==s?(je=T.isPending?s("mainPanelTabs.hostingTab.saving"):s("mainPanelTabs.hostingTab.add"),e[115]=T.isPending,e[116]=s,e[117]=je):je=e[117];let $e;e[118]!==Se||e[119]!==je?($e=t.jsx(Qe,{type:"submit",disabled:Se,children:je}),e[118]=Se,e[119]=je,e[120]=$e):$e=e[120];let ze;e[121]!==se||e[122]!==$e?(ze=t.jsxs(Nt,{children:[se,$e]}),e[121]=se,e[122]=$e,e[123]=ze):ze=e[123];let Ue;e[124]!==O||e[125]!==U||e[126]!==pe||e[127]!==re||e[128]!==ze?(Ue=t.jsxs("form",{className:"flex flex-col gap-4",onSubmit:O,children:[U,pe,re,ze]}),e[124]=O,e[125]=U,e[126]=pe,e[127]=re,e[128]=ze,e[129]=Ue):Ue=e[129];let Le;e[130]!==Y||e[131]!==Ue?(Le=t.jsxs(Ct,{className:"sm:max-w-md",children:[Y,Ue]}),e[130]=Y,e[131]=Ue,e[132]=Le):Le=e[132];let _e;e[133]!==x||e[134]!==Le?(_e=t.jsx(Dt,{open:x,onOpenChange:b,children:Le}),e[133]=x,e[134]=Le,e[135]=_e):_e=e[135];const Be=C!=null;let Ve;e[136]===Symbol.for("react.memo_cache_sentinel")?(Ve=M=>{M||P(null)},e[136]=Ve):Ve=e[136];let ke;e[137]!==s?(ke=s("mainPanelTabs.hostingTab.confirmDeleteSecretTitle"),e[137]=s,e[138]=ke):ke=e[138];const Je=C?.name??"";let He;e[139]!==s||e[140]!==Je?(He=s("mainPanelTabs.hostingTab.confirmDeleteSecretDescription",{name:Je}),e[139]=s,e[140]=Je,e[141]=He):He=e[141];let Ee;e[142]!==s?(Ee=s("mainPanelTabs.hostingTab.deleteSecret"),e[142]=s,e[143]=Ee):Ee=e[143];let Oe;e[144]!==v||e[145]!==C?(Oe=()=>{C&&v.mutate(C)},e[144]=v,e[145]=C,e[146]=Oe):Oe=e[146];let qe;e[147]!==v.isPending||e[148]!==Be||e[149]!==ke||e[150]!==He||e[151]!==Ee||e[152]!==Oe?(qe=t.jsx(wt,{open:Be,onOpenChange:Ve,title:ke,description:He,confirmLabel:Ee,pending:v.isPending,onConfirm:Oe}),e[147]=v.isPending,e[148]=Be,e[149]=ke,e[150]=He,e[151]=Ee,e[152]=Oe,e[153]=qe):qe=e[153];let Ke;return e[154]!==p||e[155]!==I||e[156]!==X||e[157]!==_e||e[158]!==qe?(Ke=t.jsxs(ut,{title:p,actions:I,children:[X,_e,qe]}),e[154]=p,e[155]=I,e[156]=X,e[157]=_e,e[158]=qe,e[159]=Ke):Ke=e[159],Ke}function wn(r){return ce.error(rt(r))}function $n(r){return ce.error(rt(r))}const Ln=3e4;function _n(r){const e=Z.c(111),{virtualMcpId:o}=r,l=Ae(),{org:a}=js(),i=ys(o),c=Ss(i),m=!!c,s=c?`/api/${a.slug}/hosting/${encodeURIComponent(c)}`:"";let n;e[0]!==s||e[1]!==m?(n=(O,k)=>({queryKey:O,queryFn:()=>Kt(`${s}${k}`),enabled:m,retry:!1,staleTime:Ln}),e[0]=s,e[1]=m,e[2]=n):n=e[2];const x=n,b=c??"",d=ct(x(Xe.hostingDeployments(a.slug,b),"/deployments")),f=ct(x(Xe.hostingEnv(a.slug,b),"/env")),u=ct(x(Xe.hostingSecrets(a.slug,b),"/secrets")),g=ct(x(Xe.hostingRedirects(a.slug,b),"/redirects")),h=ct(x(Xe.hostingDomains(a.slug,b),"/domains"));if(!c){let O;e[3]===Symbol.for("react.memo_cache_sentinel")?(O=t.jsx(_t,{className:"size-5"}),e[3]=O):O=e[3];let k;e[4]!==l?(k=l("mainPanelTabs.hostingTab.noSiteTitle"),e[4]=l,e[5]=k):k=e[5];let E;e[6]!==l?(E=l("mainPanelTabs.hostingTab.noSiteDescription"),e[6]=l,e[7]=E):E=e[7];let B;return e[8]!==k||e[9]!==E?(B=t.jsx("div",{className:"flex flex-1 items-center justify-center p-6",children:t.jsx(Ze,{icon:O,title:k,description:E})}),e[8]=k,e[9]=E,e[10]=B):B=e[10],B}if(jt(d.error)&&jt(f.error)&&jt(g.error)){let O;e[11]===Symbol.for("react.memo_cache_sentinel")?(O=t.jsx(_t,{className:"size-5"}),e[11]=O):O=e[11];let k;e[12]!==l?(k=l("mainPanelTabs.hostingTab.notConnectedTitle"),e[12]=l,e[13]=k):k=e[13];let E;e[14]!==l?(E=l("mainPanelTabs.hostingTab.notConnectedDescription"),e[14]=l,e[15]=E):E=e[15];let B;return e[16]!==k||e[17]!==E?(B=t.jsx("div",{className:"flex flex-1 items-center justify-center p-6",children:t.jsx(Ze,{icon:O,title:k,description:E})}),e[16]=k,e[17]=E,e[18]=B):B=e[18],B}let C,P,S,y,R,w,j,T,V,q;if(e[19]!==d.data||e[20]!==h.data||e[21]!==f.data||e[22]!==g.data||e[23]!==u.data){P=mt(d.data,"items");let O;e[34]!==f.data?(O=mt(f.data,"vars"),e[34]=f.data,e[35]=O):O=e[35],R=O;let k;e[36]!==f.data?(k=mt(f.data,"codeVars"),e[36]=f.data,e[37]=k):k=e[37],C=k;let E;e[38]!==u.data?(E=mt(u.data,"secrets"),e[38]=u.data,e[39]=E):E=e[39],V=E;let B;e[40]!==g.data?(B=mt(g.data,"items"),e[40]=g.data,e[41]=B):B=e[41],T=B;const G=h.data;let te;e[42]!==G?.items?(te=G?.items??[],e[42]=G?.items,e[43]=te):te=e[43],y=te;let U;e[44]!==G?.dnsTemplate?(U=G?.dnsTemplate??[],e[44]=G?.dnsTemplate,e[45]=U):U=e[45],S=U;const ne=P.find(En);w=zt((ne??P.find(kn))?.framework),j=ne?.servingUrl??null,q=j?j.replace(/^https?:\/\//,"").replace(/\/$/,""):null,e[19]=d.data,e[20]=h.data,e[21]=f.data,e[22]=g.data,e[23]=u.data,e[24]=C,e[25]=P,e[26]=S,e[27]=y,e[28]=R,e[29]=w,e[30]=j,e[31]=T,e[32]=V,e[33]=q}else C=e[24],P=e[25],S=e[26],y=e[27],R=e[28],w=e[29],j=e[30],T=e[31],V=e[32],q=e[33];const F=q;let v;e[46]!==s||e[47]!==a.slug||e[48]!==c?(v=t.jsx(tn,{base:s,orgSlug:a.slug,site:c}),e[46]=s,e[47]=a.slug,e[48]=c,e[49]=v):v=e[49];let H;e[50]!==l?(H=l("mainPanelTabs.hostingTab.title"),e[50]=l,e[51]=H):H=e[51];let A;e[52]!==w?(A=w&&t.jsx(Re,{variant:"secondary",children:w}),e[52]=w,e[53]=A):A=e[53];let K;e[54]!==H||e[55]!==A?(K=t.jsxs("span",{className:"inline-flex items-center gap-2.5",children:[H,A]}),e[54]=H,e[55]=A,e[56]=K):K=e[56];let _;e[57]!==v||e[58]!==K?(_=t.jsx(Jt.Title,{actions:v,children:K}),e[57]=v,e[58]=K,e[59]=_):_=e[59];let W;e[60]!==F||e[61]!==j?(W=j&&F&&t.jsx("p",{className:"flex flex-wrap items-center gap-x-1.5 text-sm text-muted-foreground",children:t.jsxs("a",{href:j,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-1 font-mono text-xs text-foreground hover:underline",children:[F,t.jsx(kt,{className:"size-3"})]})}),e[60]=F,e[61]=j,e[62]=W):W=e[62];let J;e[63]!==_||e[64]!==W?(J=t.jsxs("div",{className:"flex flex-col gap-2",children:[_,W]}),e[63]=_,e[64]=W,e[65]=J):J=e[65];let Q;e[66]!==s||e[67]!==P||e[68]!==d.error||e[69]!==d.isLoading||e[70]!==m||e[71]!==a.slug||e[72]!==c?(Q=t.jsx(rn,{base:s,orgSlug:a.slug,site:c,enabled:m,deployments:P,isLoading:d.isLoading,error:d.error}),e[66]=s,e[67]=P,e[68]=d.error,e[69]=d.isLoading,e[70]=m,e[71]=a.slug,e[72]=c,e[73]=Q):Q=e[73];let p;e[74]!==s||e[75]!==C||e[76]!==f.error||e[77]!==f.isLoading||e[78]!==R||e[79]!==a.slug||e[80]!==c?(p=t.jsx(jn,{base:s,orgSlug:a.slug,site:c,envVars:R,codeVars:C,isLoading:f.isLoading,error:f.error}),e[74]=s,e[75]=C,e[76]=f.error,e[77]=f.isLoading,e[78]=R,e[79]=a.slug,e[80]=c,e[81]=p):p=e[81];let I;e[82]!==s||e[83]!==a.slug||e[84]!==V||e[85]!==u.error||e[86]!==u.isLoading||e[87]!==c?(I=t.jsx(Dn,{base:s,orgSlug:a.slug,site:c,secrets:V,isLoading:u.isLoading,error:u.error}),e[82]=s,e[83]=a.slug,e[84]=V,e[85]=u.error,e[86]=u.isLoading,e[87]=c,e[88]=I):I=e[88];let X;e[89]!==s||e[90]!==S||e[91]!==y||e[92]!==h.error||e[93]!==h.isLoading||e[94]!==a.slug||e[95]!==c?(X=t.jsx(gn,{base:s,orgSlug:a.slug,site:c,domains:y,dnsTemplate:S,isLoading:h.isLoading,error:h.error}),e[89]=s,e[90]=S,e[91]=y,e[92]=h.error,e[93]=h.isLoading,e[94]=a.slug,e[95]=c,e[96]=X):X=e[96];let D;e[97]!==s||e[98]!==a.slug||e[99]!==T||e[100]!==g.error||e[101]!==g.isLoading||e[102]!==c?(D=t.jsx(Sn,{base:s,orgSlug:a.slug,site:c,redirects:T,isLoading:g.isLoading,error:g.error}),e[97]=s,e[98]=a.slug,e[99]=T,e[100]=g.error,e[101]=g.isLoading,e[102]=c,e[103]=D):D=e[103];let Y;return e[104]!==Q||e[105]!==p||e[106]!==I||e[107]!==X||e[108]!==D||e[109]!==J?(Y=t.jsx("div",{className:"h-full min-h-0 overflow-y-auto",children:t.jsx(Jt.Container,{width:"standard",children:t.jsxs(Ps,{children:[J,Q,p,I,X,D]})})}),e[104]=Q,e[105]=p,e[106]=I,e[107]=X,e[108]=D,e[109]=J,e[110]=Y):Y=e[110],Y}function kn(r){return r.framework}function En(r){return r.up===!0}function Rn(){const r=Z.c(3),e=Us(),o=Qs();let l;return r[0]!==o.hosting||r[1]!==e?(l=o.hosting?t.jsx(_n,{virtualMcpId:e}):t.jsx(Ks,{virtualMcpId:e}),r[0]=o.hosting,r[1]=e,r[2]=l):l=r[2],l}function na(){const r=Z.c(1);let e;return r[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(vs.Content,{children:t.jsx(Rn,{})}),r[0]=e):e=r[0],e}export{na as default};
|