decocms 4.531.0 → 4.532.1

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.
Files changed (428) hide show
  1. package/dist/client/assets/{ActiveShapeUtils-CUGYcOGt.js → ActiveShapeUtils-DnnbFg2w.js} +1 -1
  2. package/dist/client/assets/{AlertCircle-C0U53qC5.js → AlertCircle-JaYuCWTa.js} +1 -1
  3. package/dist/client/assets/{AreaChart-vwsYBH1z.js → AreaChart-BztD6Eot.js} +1 -1
  4. package/dist/client/assets/{ArrowLeft-BVJNIiuT.js → ArrowLeft-BhJEaZ6B.js} +1 -1
  5. package/dist/client/assets/{ArrowUp-BnowdRj-.js → ArrowUp-YrAe3vgd.js} +1 -1
  6. package/dist/client/assets/{BarChart-CwsIHr2J.js → BarChart-Dm2oPqJS.js} +1 -1
  7. package/dist/client/assets/{Building02-CcI-P3yL.js → Building02-CTmcVqQj.js} +1 -1
  8. package/dist/client/assets/{CartesianChart-Cwfb2Obv.js → CartesianChart-tumrCcCW.js} +1 -1
  9. package/dist/client/assets/{CategoricalChart-CukPvNkf.js → CategoricalChart-BqKIQcdM.js} +1 -1
  10. package/dist/client/assets/{CheckCircle-fAPMl2yd.js → CheckCircle-9jHhe24P.js} +1 -1
  11. package/dist/client/assets/{ChevronSelectorVertical-C-CIIDml.js → ChevronSelectorVertical-CfW1Wzms.js} +1 -1
  12. package/dist/client/assets/{ChevronUp-BMY88wXt.js → ChevronUp-D-7vQNVy.js} +1 -1
  13. package/dist/client/assets/{Copy01-DGy0Absz.js → Copy01-DP6tJ3a3.js} +1 -1
  14. package/dist/client/assets/{CreditCard01-DsjBhiEj.js → CreditCard01-7YXzWPmu.js} +1 -1
  15. package/dist/client/assets/{DotsVertical-Bfe9a_On.js → DotsVertical-BSeiVg8O.js} +1 -1
  16. package/dist/client/assets/{ErrorBarContext-hs9d9Up0.js → ErrorBarContext-DeFYEXHx.js} +1 -1
  17. package/dist/client/assets/{Globe04-B-sNlZxN.js → Globe04-BkUhGI83.js} +1 -1
  18. package/dist/client/assets/{Image01-DtpDUrwF.js → Image01-DLqdm992.js} +1 -1
  19. package/dist/client/assets/{Key01-DifqnYu0.js → Key01-o_hEpYwc.js} +1 -1
  20. package/dist/client/assets/{Link01-oZZyGItc.js → Link01-DDso2VpB.js} +1 -1
  21. package/dist/client/assets/{LinkBroken01-BZrnscWF.js → LinkBroken01-C29KKpU0.js} +1 -1
  22. package/dist/client/assets/{Minus-Dc5wow6R.js → Minus-B--8kp5j.js} +1 -1
  23. package/dist/client/assets/{Monitor01-Bmn1BV5T.js → Monitor01-BtDUnSZq.js} +1 -1
  24. package/dist/client/assets/{Play-IViIK9Vy.js → Play-jy1YZ7pj.js} +1 -1
  25. package/dist/client/assets/{Plus-Bh_xMwh7.js → Plus-4tdoOfzh.js} +1 -1
  26. package/dist/client/assets/{ReferenceLine-DDRDnZWn.js → ReferenceLine-rf71t8Wf.js} +1 -1
  27. package/dist/client/assets/{SearchMd-DB3np2ti.js → SearchMd-J2Rjic9V.js} +1 -1
  28. package/dist/client/assets/{Sector-BbL3mZ4i.js → Sector-Bh4QFYl4.js} +1 -1
  29. package/dist/client/assets/{ShoppingBag01-BaMIB-e_.js → ShoppingBag01-jE2k9Z1o.js} +1 -1
  30. package/dist/client/assets/{Sun-BZlKwpGn.js → Sun-CGNTymUo.js} +1 -1
  31. package/dist/client/assets/{SwitchHorizontal01-fMsLFMs0.js → SwitchHorizontal01-CLXZKY70.js} +1 -1
  32. package/dist/client/assets/{Tool01-CTKnipD_.js → Tool01-DvOyfmVC.js} +1 -1
  33. package/dist/client/assets/{Trash01-BqP8uw7k.js → Trash01-CGaWZsc5.js} +1 -1
  34. package/dist/client/assets/{Upload01-CpPArzNK.js → Upload01-CXqGRfor.js} +1 -1
  35. package/dist/client/assets/{UserSquare-D4xudMmb.js → UserSquare-DV1XZOY6.js} +1 -1
  36. package/dist/client/assets/{Users01-buCmBl1X.js → Users01-CpHvZIR7.js} +1 -1
  37. package/dist/client/assets/{XClose-D48r2tDo.js → XClose-DWQXqdSq.js} +1 -1
  38. package/dist/client/assets/{ZoomOut-BVuJZ-2t.js → ZoomOut-BMZKrcTE.js} +1 -1
  39. package/dist/client/assets/{access-gate-DBOVcx9J.js → access-gate-D7ByZ05F.js} +1 -1
  40. package/dist/client/assets/{add-connection-dialog-o9V9M7_d.js → add-connection-dialog-BAfMm3u3.js} +1 -1
  41. package/dist/client/assets/agent-analytics-50v2bvbj.js +2 -0
  42. package/dist/client/assets/agent-app-q2vsC-My.js +1 -0
  43. package/dist/client/assets/agent-assets-BFfp1GZa.js +1 -0
  44. package/dist/client/assets/{agent-automation-ChlL7V0d.js → agent-automation-cMZeN9lm.js} +2 -2
  45. package/dist/client/assets/agent-automations-C1kW6Kjy.js +1 -0
  46. package/dist/client/assets/agent-calendar-36AOb9o-.js +1 -0
  47. package/dist/client/assets/agent-connect-sources-DPOLWSPQ.js +1 -0
  48. package/dist/client/assets/agent-deck-2j6MNhuy.js +1 -0
  49. package/dist/client/assets/agent-e2e-BAUU5S3t.js +1 -0
  50. package/dist/client/assets/agent-experiments-DilSMM1e.js +1 -0
  51. package/dist/client/assets/agent-file-CVc7OTSX.js +1 -0
  52. package/dist/client/assets/agent-hosting-B3kgszkl.js +1 -0
  53. package/dist/client/assets/{agent-icon-B7Q7dFXY.js → agent-icon-B6DURSl_.js} +1 -1
  54. package/dist/client/assets/agent-library-C4-tevIK.js +1 -0
  55. package/dist/client/assets/agent-library-file-CXzcuEPO.js +1 -0
  56. package/dist/client/assets/agent-monitor-Bic-xfUm.js +1 -0
  57. package/dist/client/assets/agent-overview-B-K4tgsN.js +1 -0
  58. package/dist/client/assets/agent-releases-Cg8gdPI4.js +2 -0
  59. package/dist/client/assets/agent-settings-BTPWu4VN.js +1 -0
  60. package/dist/client/assets/agent-site-editor-code-43f6TRaT.js +2 -0
  61. package/dist/client/assets/agent-site-editor-content-CDIxjk4q.js +1 -0
  62. package/dist/client/assets/agent-site-editor-preview-DMRQM-LG.js +1 -0
  63. package/dist/client/assets/{agent-site-editor-C0ubqGd6.js → agent-site-editor-wbhemRqk.js} +2 -2
  64. package/dist/client/assets/agent-view-CN7cv0Ow.js +1 -0
  65. package/dist/client/assets/{agent-view-guard-CzZjL776.js → agent-view-guard-B65FxQSG.js} +1 -1
  66. package/dist/client/assets/{agents-list-ImvzEVvr.js → agents-list-C2lNfvq5.js} +1 -1
  67. package/dist/client/assets/{ai-providers-Bw8nDtTM.js → ai-providers-yeci77cM.js} +1 -1
  68. package/dist/client/assets/{alert-CHj-Usrj.js → alert-ByYqnTt4.js} +1 -1
  69. package/dist/client/assets/{analytics-sections-CGcyhwwe.js → analytics-sections-D6yo_AiZ.js} +1 -1
  70. package/dist/client/assets/api-keys-DLBTiE6h.js +1 -0
  71. package/dist/client/assets/{api-keys-DSNlUnpn.js → api-keys-MpEUcu1P.js} +1 -1
  72. package/dist/client/assets/app-editor-BJbxwtPb.js +1 -0
  73. package/dist/client/assets/{asset-utils-BvYMWLJK.js → asset-utils-B_sH3eAw.js} +1 -1
  74. package/dist/client/assets/{auth-fndLm_KR.js → auth-DDIbIEWU.js} +1 -1
  75. package/dist/client/assets/{auth-catchall-Yn8u2UhP.js → auth-catchall-C0vPJ0YF.js} +1 -1
  76. package/dist/client/assets/{auth-entry-DF0YJ4h7.js → auth-entry-JIA29m1g.js} +1 -1
  77. package/dist/client/assets/{auth-split-layout-NNmGhYbT.js → auth-split-layout-C9ufzfNF.js} +1 -1
  78. package/dist/client/assets/{authenticate-and-persist-oauth-D7QWYyhR.js → authenticate-and-persist-oauth-Cinc5wU_.js} +1 -1
  79. package/dist/client/assets/{automation-list-row-CTExE_83.js → automation-list-row-D_MyMSDf.js} +1 -1
  80. package/dist/client/assets/{automation-runs-BO9rScSe.js → automation-runs-BYeHhogm.js} +1 -1
  81. package/dist/client/assets/{automations-CHWjvK4W.js → automations-ZXkIniXI.js} +1 -1
  82. package/dist/client/assets/{autosend-VKc1dW3G.js → autosend-CeHYNB5a.js} +1 -1
  83. package/dist/client/assets/{badge-AFOqFwvQ.js → badge-DCdHHENd.js} +1 -1
  84. package/dist/client/assets/{block-document-C22TRUSp.js → block-document-u0VXgZsH.js} +1 -1
  85. package/dist/client/assets/{blocks-preview-workspace-context-Dd8qSyOR.js → blocks-preview-workspace-context-MSwutMpe.js} +1 -1
  86. package/dist/client/assets/{blocks-tab-states-BUek9Urr.js → blocks-tab-states-D7FXIYa1.js} +1 -1
  87. package/dist/client/assets/{blog-schema-DclHtzEx.js → blog-schema-Cj9I5QvS.js} +1 -1
  88. package/dist/client/assets/{buckets-Dq_X_gmQ.js → buckets-Ebvh16O2.js} +1 -1
  89. package/dist/client/assets/{build-improve-prompt-doc-Pe8zfELh.js → build-improve-prompt-doc-MHEVAUpp.js} +1 -1
  90. package/dist/client/assets/{calendar-BZJL1q0i.js → calendar-DGPEnw4y.js} +1 -1
  91. package/dist/client/assets/{capability-load-error-Bn9e6-bb.js → capability-load-error-xTGz1O0J.js} +1 -1
  92. package/dist/client/assets/category-editor-iiVXVslv.js +1 -0
  93. package/dist/client/assets/{cdn-tab-CJ55RYwI.js → cdn-tab-GR3G6uO2.js} +1 -1
  94. package/dist/client/assets/{chart-bf024hGa.js → chart-DGgWZa8N.js} +1 -1
  95. package/dist/client/assets/{chat-context-BI1yxU4R.js → chat-context-EryBIl5y.js} +1 -1
  96. package/dist/client/assets/{chat-draft-B9Sz9SQX.js → chat-draft-C77KukAJ.js} +1 -1
  97. package/dist/client/assets/{checkbox-BGiVnH_E.js → checkbox-DanWxFDQ.js} +1 -1
  98. package/dist/client/assets/{choose-editor-BpSB586s.js → choose-editor-DRItQK1g.js} +1 -1
  99. package/dist/client/assets/{cli-auth-success-CDHZN1Zi.js → cli-auth-success-CbPQDWie.js} +1 -1
  100. package/dist/client/assets/{client-icons-FDKXeHgM.js → client-icons-DM34aWEC.js} +1 -1
  101. package/dist/client/assets/cms-settings-editor-CMB6VNMa.js +1 -0
  102. package/dist/client/assets/{collapsible-B5J2aUd-.js → collapsible-Bxf6Tjj8.js} +1 -1
  103. package/dist/client/assets/collection-detail-Bh4I2YYV.js +1 -0
  104. package/dist/client/assets/{collection-display-button-VDPf0fxx.js → collection-display-button-DKZVrqVY.js} +1 -1
  105. package/dist/client/assets/{collection-search-B_n3Ea8A.js → collection-search-oriFbOeS.js} +1 -1
  106. package/dist/client/assets/{collection-table-wrapper-Dms92TX1.js → collection-table-wrapper-Cx4DeYH2.js} +1 -1
  107. package/dist/client/assets/{collection-tabs-CRfyt8-K.js → collection-tabs-B-KXu_oD.js} +1 -1
  108. package/dist/client/assets/{column-rules-C7sxa0a0.js → column-rules-CQFnitOu.js} +1 -1
  109. package/dist/client/assets/{combobox-BBB78IeP.js → combobox-Cwzc08sq.js} +1 -1
  110. package/dist/client/assets/{command-jlI8eprh.js → command-BPRmBGhB.js} +1 -1
  111. package/dist/client/assets/{companion-mcps-section-C8ZRnbHV.js → companion-mcps-section-CXlo7Sbg.js} +1 -1
  112. package/dist/client/assets/{config-CEPjuV4B.js → config-nwVLBXQV.js} +1 -1
  113. package/dist/client/assets/{connect-D7sTLKym.js → connect-CybWYqFY.js} +1 -1
  114. package/dist/client/assets/{connect-layout-DEhdoMeD.js → connect-layout-E0TTDMsw.js} +1 -1
  115. package/dist/client/assets/{connect-source-dialog-CTDwzNbD.js → connect-source-dialog-2r0XpaoA.js} +1 -1
  116. package/dist/client/assets/{connection-_BLwZIho.js → connection-DyDIuEks.js} +1 -1
  117. package/dist/client/assets/{connection-card-DOb0qtir.js → connection-card-vYaDrRUO.js} +1 -1
  118. package/dist/client/assets/{connection-detail-6FLkb2KJ.js → connection-detail-WxSnF4zc.js} +1 -1
  119. package/dist/client/assets/{connection-form-helpers-Do-juNEt.js → connection-form-helpers-BQJcmj4C.js} +1 -1
  120. package/dist/client/assets/{connections-m8uo2l1C.js → connections-DusfKLJp.js} +1 -1
  121. package/dist/client/assets/{content-tab-CxqGwsRS.js → content-tab-CdSmdOT_.js} +3 -3
  122. package/dist/client/assets/context-Cz086QIc.js +1 -0
  123. package/dist/client/assets/{context-menu-Ckmk21Ru.js → context-menu-gpaAOtWJ.js} +1 -1
  124. package/dist/client/assets/{context-shell-7YO8Ahul.js → context-shell-CPyOecQG.js} +3 -3
  125. package/dist/client/assets/{core.esm-CfGX-VCE.js → core.esm-XMSb_Uka.js} +1 -1
  126. package/dist/client/assets/{create-organization-dialog-Byea9wm5.js → create-organization-dialog-B46HiNm0.js} +1 -1
  127. package/dist/client/assets/{daily-pulse-DWbRk6Tj.js → daily-pulse-D6u_wQB-.js} +1 -1
  128. package/dist/client/assets/discover-Dwa3grGi.js +1 -0
  129. package/dist/client/assets/{domain-settings-D4GbzAgH.js → domain-settings-CZcl4K1o.js} +1 -1
  130. package/dist/client/assets/{drawer-9GcYCTZT.js → drawer-C3PrA-n8.js} +1 -1
  131. package/dist/client/assets/{editor-CVSwKg6T.js → editor-BI9MEm45.js} +1 -1
  132. package/dist/client/assets/{editor-classes-Dkk1S2M6.js → editor-classes-Di69nj2G.js} +1 -1
  133. package/dist/client/assets/{empty-state-CUanQ9Sm.js → empty-state-r_5Rd0dc.js} +1 -1
  134. package/dist/client/assets/{empty-state-BdJInz6a.js → empty-state-tJsREuj4.js} +1 -1
  135. package/dist/client/assets/{experiments-tab-NqV4EeCU.js → experiments-tab-D83vgaBk.js} +1 -1
  136. package/dist/client/assets/{experiments-tab-choice-D5E9lbe8.js → experiments-tab-choice-_FBZoLPZ.js} +1 -1
  137. package/dist/client/assets/{extract-connection-data-BH85Ecx-.js → extract-connection-data-CAX0s-U5.js} +1 -1
  138. package/dist/client/assets/{feature-gate-BaIBNMzy.js → feature-gate-CIVRuSL-.js} +1 -1
  139. package/dist/client/assets/{feature-paywall-BIJDHy8g.js → feature-paywall-B0ICgL5J.js} +1 -1
  140. package/dist/client/assets/file-explorer-CAwP6yms.js +2 -0
  141. package/dist/client/assets/{file-preview-DVCjmYnL.js → file-preview-BS2w8KBn.js} +1 -1
  142. package/dist/client/assets/{file-share-button-B0trNLFa.js → file-share-button-DVQqivw6.js} +1 -1
  143. package/dist/client/assets/{file-type-icon-CLdhbOMq.js → file-type-icon-D-goE4ev.js} +1 -1
  144. package/dist/client/assets/{folder-icon-B4yVMgUj.js → folder-icon-Dh0obbUY.js} +1 -1
  145. package/dist/client/assets/{form-DmKuBQlJ.js → form-BrmBomQx.js} +1 -1
  146. package/dist/client/assets/{general-CzhpbJkY.js → general-6Gb6L9hc.js} +1 -1
  147. package/dist/client/assets/{held-block-view-BCUOCB3X.js → held-block-view-ZDteU5Jg.js} +3 -3
  148. package/dist/client/assets/home-Yx3qRIo8.js +1 -0
  149. package/dist/client/assets/{hosted-publish-feedback-BX6h3oNP.js → hosted-publish-feedback-D-NyDy_o.js} +1 -1
  150. package/dist/client/assets/{icon-button-Rp_ZDDhs.js → icon-button-B8gYI46y.js} +1 -1
  151. package/dist/client/assets/{index-CPu0T3g-.js → index-B_ZSRZ_1.js} +1 -1
  152. package/dist/client/assets/{index-B-980lL8.js → index-BieOo250.js} +1 -1
  153. package/dist/client/assets/{index-CzZ16hae.js → index-CVukLLDd.js} +1 -1
  154. package/dist/client/assets/{index-_MLEN3sq.js → index-CXN_y45N.js} +1 -1
  155. package/dist/client/assets/{index-C8YP0XfX.js → index-CgM7-Ro8.js} +8 -8
  156. package/dist/client/assets/{index-DG18LLWo.js → index-DCM5dVSL.js} +1 -1
  157. package/dist/client/assets/{index-DJmej5q-.js → index-DIKRwX1p.js} +1 -1
  158. package/dist/client/assets/{index-DJxkEvYw.js → index-DRBnjYGA.js} +1 -1
  159. package/dist/client/assets/{index-Q6SZwjyp.js → index-DapED80K.js} +2 -2
  160. package/dist/client/assets/{index-C6KhNCz4.js → index-Dps1wO3D.js} +1 -1
  161. package/dist/client/assets/{index-CjhVW3Ft.js → index-KTP6c0cL.js} +1 -1
  162. package/dist/client/assets/{index-Dc2A9bLg.js → index-SVmnnfb6.js} +1 -1
  163. package/dist/client/assets/{index-EfujrlRm.js → index-_4PHXujT.js} +1 -1
  164. package/dist/client/assets/{index-B0Rg86vv.js → index-bs2MyHCY.js} +1 -1
  165. package/dist/client/assets/{index-BM9HifS6.js → index-cvu6NM2y.js} +1 -1
  166. package/dist/client/assets/{index-redirect-uK6MukHm.js → index-redirect-DS6jhnWT.js} +1 -1
  167. package/dist/client/assets/{infiniteQueryObserver-C8Tx1h_G.js → infiniteQueryObserver-DOIcndov.js} +1 -1
  168. package/dist/client/assets/{infra-billing-XXUCrKTj.js → infra-billing-BvdZetjK.js} +1 -1
  169. package/dist/client/assets/{input-DRaRHcY2.js → input-Cdb_NhY5.js} +1 -1
  170. package/dist/client/assets/{input-DjstRX-_.js → input-DVTIG9aC.js} +3 -3
  171. package/dist/client/assets/{integration-icon-03FWmed-.js → integration-icon-Do2Y8hkm.js} +1 -1
  172. package/dist/client/assets/{jira-icon-Dwf32Q1t.js → jira-icon-WOhDyJEG.js} +1 -1
  173. package/dist/client/assets/{label-BZDtWIcv.js → label-DOI4IEwy.js} +1 -1
  174. package/dist/client/assets/{layout-rILzLvlD.js → layout-Bghhk_lp.js} +1 -1
  175. package/dist/client/assets/{legacy-agents-deep-BASczG03.js → legacy-agents-deep-DxTjI0nW.js} +1 -1
  176. package/dist/client/assets/{legacy-main-redirect-BJoW2swu.js → legacy-main-redirect-BNntnJG2.js} +1 -1
  177. package/dist/client/assets/library-BXV44tew.js +1 -0
  178. package/dist/client/assets/{login-9fIx9llO.js → login-CCI0hYyU.js} +1 -1
  179. package/dist/client/assets/{markdown-DuoP9xIE.js → markdown-BwxTuGGG.js} +1 -1
  180. package/dist/client/assets/{mcp-app-renderer-DWv_y82s.js → mcp-app-renderer-BoiACXPd.js} +1 -1
  181. package/dist/client/assets/{mcp-oauth-CsfxxKaN.js → mcp-oauth-CZ9GqXPF.js} +1 -1
  182. package/dist/client/assets/{mcp-oauth-D-fSN__A.js → mcp-oauth-ysipa0ke.js} +1 -1
  183. package/dist/client/assets/{members-DLnkLpsh.js → members-C7ZgCgdf.js} +1 -1
  184. package/dist/client/assets/{memory-4CHY9Qs2.js → memory-BJg93AJ_.js} +1 -1
  185. package/dist/client/assets/{mini-report-page-MBlPP32_.js → mini-report-page-CG2TDLWW.js} +1 -1
  186. package/dist/client/assets/{mock-board-BtdGtIDb.js → mock-board-6S3zrVza.js} +3 -3
  187. package/dist/client/assets/{monaco-editor-a3IVCcn2.js → monaco-editor-Bu-nU7NV.js} +1 -1
  188. package/dist/client/assets/monitoring-CtNDQEFC.js +1 -0
  189. package/dist/client/assets/{monitoring-stats-row-DBelPaxz.js → monitoring-stats-row-D1_4aDPs.js} +1 -1
  190. package/dist/client/assets/{multi-select-082YyRUR.js → multi-select-B4032GRo.js} +1 -1
  191. package/dist/client/assets/{mustache-BBa51FCf.js → mustache-DKd8K2vx.js} +1 -1
  192. package/dist/client/assets/{named-rule-uses-Yzjx02p5.js → named-rule-uses-BR4TO_up.js} +1 -1
  193. package/dist/client/assets/{new-project-dialog-BuE_SqTn.js → new-project-dialog-DVfPsfG1.js} +1 -1
  194. package/dist/client/assets/{oauth-callback-DDoefwF9.js → oauth-callback-N9-z1VuP.js} +1 -1
  195. package/dist/client/assets/{oauth-callback-ai-provider-C9SrnNuM.js → oauth-callback-ai-provider-CNfO_rYc.js} +1 -1
  196. package/dist/client/assets/{onboarding-DSfiLpX3.js → onboarding-De-qOZCj.js} +1 -1
  197. package/dist/client/assets/{openai-conversation-sk-C_Dmb.js → openai-conversation-CnC0P3bR.js} +1 -1
  198. package/dist/client/assets/{optimistic-project-sidebar-views-DJIKQ8kN.js → optimistic-project-sidebar-views-D1QEaYtv.js} +1 -1
  199. package/dist/client/assets/order-monitor-day-BeeQrZ5U.js +1 -0
  200. package/dist/client/assets/{organization-choice-BnprMn5W.js → organization-choice-CKs_iAfO.js} +1 -1
  201. package/dist/client/assets/{orgs-BwLgPyhv.js → orgs-Dxmpwmqc.js} +1 -1
  202. package/dist/client/assets/{page-seo-form-DcpwPyQd.js → page-seo-form-B6ZA1fPy.js} +1 -1
  203. package/dist/client/assets/{pair-DEJAc3iG.js → pair-BqbhOYo8.js} +1 -1
  204. package/dist/client/assets/{parse-sections-B8Xcvgnu.js → parse-sections-D0EeXwVX.js} +1 -1
  205. package/dist/client/assets/plan-Do0NrPLf.js +1 -0
  206. package/dist/client/assets/{plan-ladder-B0TVgJ_-.js → plan-ladder-DeIr-j94.js} +1 -1
  207. package/dist/client/assets/{popover-C0DIKe_3.js → popover-Cdnki_Jg.js} +1 -1
  208. package/dist/client/assets/post-calendar-BqMsyhtW.js +1 -0
  209. package/dist/client/assets/{post-editor-BAL8WHQL.js → post-editor-d8_PR6QG.js} +2 -2
  210. package/dist/client/assets/{preview-content-4PKjfy6d.js → preview-content-Cfp4wBHT.js} +1 -1
  211. package/dist/client/assets/{preview-dialog-B5Sh6VdD.js → preview-dialog-u-q_Yxod.js} +1 -1
  212. package/dist/client/assets/{preview-panel-CdgtAcKr.js → preview-panel-4HZDowIC.js} +1 -1
  213. package/dist/client/assets/{preview-tab-W7cmZoDH.js → preview-tab-DpIMbT0D.js} +3 -3
  214. package/dist/client/assets/{product-picker-dialog-BMgJeJTt.js → product-picker-dialog-CGoJkeHX.js} +1 -1
  215. package/dist/client/assets/{profile-BGrTACfK.js → profile-CuY7TVPf.js} +1 -1
  216. package/dist/client/assets/project-app-view-BgPENTJM.js +1 -0
  217. package/dist/client/assets/{project-apps-CTDjuD3G.js → project-apps-ZVTNnGHs.js} +1 -1
  218. package/dist/client/assets/{project-feed-BoWXBRyy.js → project-feed-Cnu5Nxao.js} +1 -1
  219. package/dist/client/assets/{project-icon-BSrEdWN1.js → project-icon-DEP8iT8r.js} +1 -1
  220. package/dist/client/assets/project-reports-Btx8fcRg.js +1 -0
  221. package/dist/client/assets/project-tasks-bvOCC5Gl.js +1 -0
  222. package/dist/client/assets/{projects-BN2XX-Mk.js → projects-DIeDg7rY.js} +1 -1
  223. package/dist/client/assets/{projects-empty-state-DE8FaVtJ.js → projects-empty-state-_30UcQ-M.js} +1 -1
  224. package/dist/client/assets/{prompts-CPwtUzza.js → prompts-C8DmbO-y.js} +1 -1
  225. package/dist/client/assets/record-editor-DfuGKIDN.js +1 -0
  226. package/dist/client/assets/redirect-editor-B83cyyW5.js +1 -0
  227. package/dist/client/assets/{releases-api-DGMi80FZ.js → releases-api-A66gUQIn.js} +1 -1
  228. package/dist/client/assets/{reports-DqVaZWmt.js → reports-CeKHgkOO.js} +1 -1
  229. package/dist/client/assets/reports-DeV24_Fp.js +1 -0
  230. package/dist/client/assets/{reports-onboarding-D7aXc-w2.js → reports-onboarding-rU86pVPG.js} +1 -1
  231. package/dist/client/assets/reports-tab-bOaRq3nR.js +2 -0
  232. package/dist/client/assets/{repositories-BdofaJQO.js → repositories-BUtVqCtn.js} +1 -1
  233. package/dist/client/assets/repositories-DWr_TbLg.js +1 -0
  234. package/dist/client/assets/{repository-binding-B-4PI1n3.js → repository-binding-8UNd4La0.js} +1 -1
  235. package/dist/client/assets/{repository-import-picker-BfMMau5M.js → repository-import-picker-OrJw3cIo.js} +1 -1
  236. package/dist/client/assets/{repository-picker-CbWFb7rK.js → repository-picker-B6a9ep3b.js} +1 -1
  237. package/dist/client/assets/{require-capability-C7aMGT2m.js → require-capability-Csx90zSZ.js} +1 -1
  238. package/dist/client/assets/{required-auth-layout-ofmCqqpc.js → required-auth-layout-BZmUgBgt.js} +1 -1
  239. package/dist/client/assets/{reset-password-VX3IBezM.js → reset-password-C1H9wzkd.js} +1 -1
  240. package/dist/client/assets/{resizable-KZ7XhVXp.js → resizable-CsaiXEtB.js} +1 -1
  241. package/dist/client/assets/{resolve-tab-icon-BZyAXpM2.js → resolve-tab-icon-DxDkByKs.js} +1 -1
  242. package/dist/client/assets/{review-settings-BmkypttR.js → review-settings-CbZWzVpV.js} +1 -1
  243. package/dist/client/assets/roles-C9WHdgOh.js +1 -0
  244. package/dist/client/assets/route-DWqde3k7.js +1 -0
  245. package/dist/client/assets/route-Df2Rj5Mk.js +1 -0
  246. package/dist/client/assets/route-RNnMRdq9.js +1 -0
  247. package/dist/client/assets/{sandbox-lifecycle-context-DQ3bjzwr.js → sandbox-lifecycle-context-BmK0O-xa.js} +1 -1
  248. package/dist/client/assets/{schema-nUWXGpCy.js → schema-BrrH5ge3.js} +1 -1
  249. package/dist/client/assets/{schema-CFje17_E.js → schema-OwOGrcTc.js} +1 -1
  250. package/dist/client/assets/{scroll-area-BSd3TrLZ.js → scroll-area-C4hgiBjt.js} +1 -1
  251. package/dist/client/assets/{search-input-CIT_dMpA.js → search-input-BfxNf6mK.js} +1 -1
  252. package/dist/client/assets/{search-toggle-BYErJl4G.js → search-toggle-7CRkYA1R.js} +1 -1
  253. package/dist/client/assets/{secret-picker-CczM3F7L.js → secret-picker-Bo5RqPwz.js} +1 -1
  254. package/dist/client/assets/{secrets-DGc21qBv.js → secrets-3UTWqvR9.js} +1 -1
  255. package/dist/client/assets/{section-array-field-CWeYHp0D.js → section-array-field-Osne9SXG.js} +1 -1
  256. package/dist/client/assets/{sections-f1UrHc1E.js → sections-B7_NO_TB.js} +1 -1
  257. package/dist/client/assets/sections-editor-DU3Z2daJ.js +1 -0
  258. package/dist/client/assets/{select-EVDcG5Hl.js → select-CYUfZrWy.js} +1 -1
  259. package/dist/client/assets/{select-model-CxALqwJ6.js → select-model-BR-Mi2X4.js} +1 -1
  260. package/dist/client/assets/seo-editor-hcPJdZCF.js +1 -0
  261. package/dist/client/assets/{separator-Czsq0Xe-.js → separator-D_EWmGgU.js} +1 -1
  262. package/dist/client/assets/settings-tab-8Q8MqCBu.js +1 -0
  263. package/dist/client/assets/{sheet-ko7a2Uwq.js → sheet-CSTtais0.js} +1 -1
  264. package/dist/client/assets/shell-layout-Dt3eq6Qk.js +1 -0
  265. package/dist/client/assets/{site-draft-actions-PtNrOTTk.js → site-draft-actions-D58qwd26.js} +1 -1
  266. package/dist/client/assets/{site-draft-view-Bnegh8Bv.js → site-draft-view-Lvj7mU3Q.js} +2 -2
  267. package/dist/client/assets/site-editor-Bm2O7VhS.js +1 -0
  268. package/dist/client/assets/{site-editor-toast-D9ddy9a_.js → site-editor-toast-BOx376JN.js} +1 -1
  269. package/dist/client/assets/{skills-CZmhtPN_.js → skills-BBpw_E_H.js} +1 -1
  270. package/dist/client/assets/{slider-Bg5y5q23.js → slider-DykoTN1q.js} +1 -1
  271. package/dist/client/assets/{sortable.esm-Bk2g_Gbz.js → sortable.esm-BcgCBEfW.js} +1 -1
  272. package/dist/client/assets/{sso-Bb3b2KOU.js → sso-_T_doDYh.js} +1 -1
  273. package/dist/client/assets/{suggestion-Bl_JrZPN.js → suggestion-B4JccI3N.js} +1 -1
  274. package/dist/client/assets/{switch-DbWQrL2t.js → switch-gUlNntL4.js} +1 -1
  275. package/dist/client/assets/{symbol-DLC3ejqz.js → symbol-CFT02IQk.js} +1 -1
  276. package/dist/client/assets/{synced-repos-CIyIp6th.js → synced-repos-CLGShc-C.js} +1 -1
  277. package/dist/client/assets/{tab-icon-glyph-D22-rmWX.js → tab-icon-glyph-DkR9ySmC.js} +1 -1
  278. package/dist/client/assets/{table-CIbHZF2_.js → table-DEOdYXzp.js} +1 -1
  279. package/dist/client/assets/{tabs-BbA4-8ma.js → tabs-CDXYpFRp.js} +1 -1
  280. package/dist/client/assets/{task-assignee-avatar-8Sp4Z4mk.js → task-assignee-avatar-DsUwmfw7.js} +1 -1
  281. package/dist/client/assets/{task-board-u5TablbK.js → task-board-boVYnzry.js} +1 -1
  282. package/dist/client/assets/{task-route-B7ChywKT.js → task-route-C59ybgrH.js} +1 -1
  283. package/dist/client/assets/{task-status-Ch8fGpdY.js → task-status-BtlC9VFV.js} +1 -1
  284. package/dist/client/assets/taskboard-analytics-DcngoptN.js +1 -0
  285. package/dist/client/assets/{tasks-B-1EpIoB.js → tasks-BNYUWZ7R.js} +1 -1
  286. package/dist/client/assets/tasks-DpeQyqR3.js +1 -0
  287. package/dist/client/assets/{textarea-BeCs38v-.js → textarea-CKsCKFLy.js} +1 -1
  288. package/dist/client/assets/thread-analytics-u7unmd3i.js +1 -0
  289. package/dist/client/assets/{thread-intent-Cl7xa7dA.js → thread-intent-DRdPtaf2.js} +1 -1
  290. package/dist/client/assets/{thread-route-BCRCqPZe.js → thread-route-BZRksnHH.js} +1 -1
  291. package/dist/client/assets/{thread-route-JcxEqRgq.js → thread-route-Dn9lxS6O.js} +1 -1
  292. package/dist/client/assets/{thread-sheet-body-BZhXd8vN.js → thread-sheet-body-C8RRj0Rt.js} +1 -1
  293. package/dist/client/assets/{time-range-picker-D99DN923.js → time-range-picker-Dhg4t_pK.js} +1 -1
  294. package/dist/client/assets/{toggle-group-CWnjwOku.js → toggle-group-DxXcbqbT.js} +1 -1
  295. package/dist/client/assets/{tool-namespace-ChbHxLTp.js → tool-namespace-B8XtAn-5.js} +1 -1
  296. package/dist/client/assets/{toolbar-icon-button-BUMG5B6x.js → toolbar-icon-button-BnmGAbB7.js} +1 -1
  297. package/dist/client/assets/{tooltip-CJHeHoSn.js → tooltip-BFkmafQU.js} +1 -1
  298. package/dist/client/assets/{tooltipContext-CL92GCVz.js → tooltipContext-CdLg2pG8.js} +1 -1
  299. package/dist/client/assets/{track-B2jTEYXL.js → track-ClUeJJYD.js} +1 -1
  300. package/dist/client/assets/{types-Cwtot2FB.js → types-DdyZFVjB.js} +1 -1
  301. package/dist/client/assets/{url-slug-Dxr7jq0i.js → url-slug-C8ETdBcF.js} +1 -1
  302. package/dist/client/assets/{usage-stats-CNcWehA3.js → usage-stats-0AsfjkwI.js} +1 -1
  303. package/dist/client/assets/{use-ai-providers-DzWzPq_c.js → use-ai-providers-3poZythL.js} +1 -1
  304. package/dist/client/assets/{use-apply-named-rule-QplWW5Pw.js → use-apply-named-rule-CVBNS4ep.js} +1 -1
  305. package/dist/client/assets/{use-automations-DO79ln3M.js → use-automations-VlRh2Wqi.js} +1 -1
  306. package/dist/client/assets/{use-autosave-Bz5jGLfF.js → use-autosave-DO1QHpHp.js} +1 -1
  307. package/dist/client/assets/{use-chat-layout-state-DIXRUqxC.js → use-chat-layout-state-Dw5fxydL.js} +1 -1
  308. package/dist/client/assets/{use-clock-tick-DxI4Q15z.js → use-clock-tick-DYb0Yqfo.js} +1 -1
  309. package/dist/client/assets/{use-cms-publish-actions-B4udZvVh.js → use-cms-publish-actions-B9zJNLow.js} +1 -1
  310. package/dist/client/assets/{use-connect-companion--zaBR_LA.js → use-connect-companion-BsdLzWgT.js} +1 -1
  311. package/dist/client/assets/{use-connection-ClhLV4Ep.js → use-connection-DF35j1XL.js} +1 -1
  312. package/dist/client/assets/{use-copy-BCht-61u.js → use-copy-CS6Ta5ka.js} +1 -1
  313. package/dist/client/assets/{use-create-virtual-mcp-8KmID2cx.js → use-create-virtual-mcp-DqDO6PGs.js} +1 -1
  314. package/dist/client/assets/{use-date-fns-locale-U4hMTG7h.js → use-date-fns-locale-BW0Kg-s0.js} +1 -1
  315. package/dist/client/assets/{use-debounced-autosave-ffUOSkED.js → use-debounced-autosave-BdsEnVek.js} +1 -1
  316. package/dist/client/assets/{use-debounced-value-ZtANdTDD.js → use-debounced-value-BwY4UFXK.js} +1 -1
  317. package/dist/client/assets/{use-deco-credits-D7afhnU-.js → use-deco-credits-D_52syYI.js} +1 -1
  318. package/dist/client/assets/{use-decopilot-events-hbubA99f.js → use-decopilot-events-pkzCwwKp.js} +1 -1
  319. package/dist/client/assets/{use-delete-connection-bB2dgA1j.js → use-delete-connection-CSBLVjvy.js} +1 -1
  320. package/dist/client/assets/{use-deployment-admin-Cjac4tJB.js → use-deployment-admin-MTxNhHb9.js} +1 -1
  321. package/dist/client/assets/{use-fast-preview-draft-url-CoOfoUO_.js → use-fast-preview-draft-url-gEHohveI.js} +1 -1
  322. package/dist/client/assets/{use-file-configs-DI3WjDeq.js → use-file-configs-DQ3f-Q5P.js} +1 -1
  323. package/dist/client/assets/{use-inbox-feed-SND00l1M.js → use-inbox-feed-CACu8jgO.js} +1 -1
  324. package/dist/client/assets/{use-infinite-scroll-CuF9Fnt8.js → use-infinite-scroll-DQ9VVP8_.js} +1 -1
  325. package/dist/client/assets/{use-join-requests-BwDlu4Gp.js → use-join-requests-v6GW4T6a.js} +1 -1
  326. package/dist/client/assets/{use-main-panel-tabs-D5k7CyBc.js → use-main-panel-tabs-C3tLSafV.js} +1 -1
  327. package/dist/client/assets/{use-mcp-auth-status-BwPujbq3.js → use-mcp-auth-status-OhVQpQzs.js} +1 -1
  328. package/dist/client/assets/{use-mcp-client-CkAT8dMu.js → use-mcp-client-Bl_ZkfjH.js} +1 -1
  329. package/dist/client/assets/{use-mcp-prompts-BoifdA0D.js → use-mcp-prompts-Bvk5GzsH.js} +1 -1
  330. package/dist/client/assets/{use-mcp-tools-CIUeYaBw.js → use-mcp-tools-CCzyb7_q.js} +1 -1
  331. package/dist/client/assets/{use-mobile-tv6dKHC3.js → use-mobile-DWwy0G1s.js} +1 -1
  332. package/dist/client/assets/{use-move-blocks-BaNRn466.js → use-move-blocks-ssPS8eLc.js} +1 -1
  333. package/dist/client/assets/{use-navigate-to-agent-BiKQMaG5.js → use-navigate-to-agent-C1cUtbF5.js} +1 -1
  334. package/dist/client/assets/{use-open-billing-url-6v7Ht1P5.js → use-open-billing-url-BBnKa__h.js} +1 -1
  335. package/dist/client/assets/{use-org-fs-ao97Epgk.js → use-org-fs-ByPpnYSO.js} +1 -1
  336. package/dist/client/assets/{use-org-repo-syncs-DOPL9gym.js → use-org-repo-syncs-Dgj11JRA.js} +1 -1
  337. package/dist/client/assets/{use-org-sso-BK4EESlq.js → use-org-sso-lLtOH9c9.js} +1 -1
  338. package/dist/client/assets/{use-organization-roles-CohiN23I.js → use-organization-roles-BxqRa1uL.js} +1 -1
  339. package/dist/client/assets/{use-organization-settings-6EqlUT2Y.js → use-organization-settings-nbIrzOgF.js} +1 -1
  340. package/dist/client/assets/{use-panel-navigate-CTWNyrxK.js → use-panel-navigate-BzdcqjSS.js} +1 -1
  341. package/dist/client/assets/{use-project-native-view-presence-B6fZ68Vq.js → use-project-native-view-presence-z6ElNhcQ.js} +1 -1
  342. package/dist/client/assets/{use-project-scope-BgLQY0Uk.js → use-project-scope-CPYcIvTW.js} +1 -1
  343. package/dist/client/assets/{use-recent-apps-Bpx38utr.js → use-recent-apps-B1qEqr2V.js} +1 -1
  344. package/dist/client/assets/{use-releases-t7sfkrxl.js → use-releases-BM0WbDv5.js} +1 -1
  345. package/dist/client/assets/{use-reports-diagnostic-B3Bb0bBM.js → use-reports-diagnostic-DC431ajk.js} +1 -1
  346. package/dist/client/assets/{use-sandbox-events-Ccm6tkYH.js → use-sandbox-events-Yfi6UXbb.js} +1 -1
  347. package/dist/client/assets/{use-secrets-Cu0JnUiZ.js → use-secrets-CFuBmzkS.js} +1 -1
  348. package/dist/client/assets/{use-section-preview-base-DFCMtdhN.js → use-section-preview-base-CZXn_b0c.js} +1 -1
  349. package/dist/client/assets/{use-session-runtime-pkeEtIbf.js → use-session-runtime-BQ8nqerw.js} +1 -1
  350. package/dist/client/assets/{use-sidebar-collapsed-BwFu6Qgg.js → use-sidebar-collapsed-DpVze00L.js} +1 -1
  351. package/dist/client/assets/{use-tags-M_iZ_HOI.js → use-tags-DAonMHtN.js} +1 -1
  352. package/dist/client/assets/{use-task-board-analytics-BjOmg5HS.js → use-task-board-analytics-ClDqF56t.js} +1 -1
  353. package/dist/client/assets/{use-task-board-events-DGIxUFSu.js → use-task-board-events-BZgY7EAa.js} +1 -1
  354. package/dist/client/assets/{use-task-board-item-prs-BHe2zSmu.js → use-task-board-item-prs-C6S2DydN.js} +1 -1
  355. package/dist/client/assets/{use-task-metadata-D2I0K9KW.js → use-task-metadata-tY7yqfRb.js} +1 -1
  356. package/dist/client/assets/{use-thread-analytics-Bq-Ku2nN.js → use-thread-analytics-C7m6ingu.js} +1 -1
  357. package/dist/client/assets/{use-thread-outputs-am5Vd3rC.js → use-thread-outputs-gO4YyAPs.js} +1 -1
  358. package/dist/client/assets/useInfiniteQuery-D5ei_KuQ.js +1 -0
  359. package/dist/client/assets/{useQueries-Chr0IN_s.js → useQueries-BpncSGWZ.js} +1 -1
  360. package/dist/client/assets/useSuspenseInfiniteQuery-BzA-SXDa.js +1 -0
  361. package/dist/client/assets/{users-CfXhQF2t.js → users-CpQ2UVWD.js} +1 -1
  362. package/dist/client/assets/{utils-Chh_XkCj.js → utils-BKDVVXZB.js} +1 -1
  363. package/dist/client/assets/{variant-calendar-DXW-UB5g.js → variant-calendar-Je9UX6h9.js} +1 -1
  364. package/dist/client/assets/{variant-matcher-override-DV7ZKzex.js → variant-matcher-override-CMA8M4Ll.js} +1 -1
  365. package/dist/client/assets/{view-header-ECu4qrb6.js → view-header-Cq5PRRNl.js} +1 -1
  366. package/dist/client/assets/{virtual-mcp-2K3oYMwm.js → virtual-mcp-BqhVfWuq.js} +1 -1
  367. package/dist/client/assets/{watch-sse-pool-B-0VhxE7.js → watch-sse-pool-DfTC9EXk.js} +1 -1
  368. package/dist/client/index.html +1 -1
  369. package/dist/server/server.js +748 -715
  370. package/package.json +1 -1
  371. package/dist/client/assets/agent-analytics-37IFZCDX.js +0 -1
  372. package/dist/client/assets/agent-app-Br31NfCV.js +0 -1
  373. package/dist/client/assets/agent-assets-OoRFrJh4.js +0 -1
  374. package/dist/client/assets/agent-automations-CFZ5G-rN.js +0 -1
  375. package/dist/client/assets/agent-calendar-C-B6ze0O.js +0 -1
  376. package/dist/client/assets/agent-connect-sources-tJUoo5_M.js +0 -1
  377. package/dist/client/assets/agent-deck-W1uVi0Qe.js +0 -1
  378. package/dist/client/assets/agent-e2e-BJxS0re0.js +0 -1
  379. package/dist/client/assets/agent-experiments-DOcx29VX.js +0 -1
  380. package/dist/client/assets/agent-file-C9s_RWk1.js +0 -1
  381. package/dist/client/assets/agent-hosting-Bn-lQ-QN.js +0 -1
  382. package/dist/client/assets/agent-library-BSF2E1JT.js +0 -1
  383. package/dist/client/assets/agent-library-file-auwmTzQK.js +0 -1
  384. package/dist/client/assets/agent-monitor-DvzxtFAJ.js +0 -1
  385. package/dist/client/assets/agent-overview-BQZTWcdd.js +0 -1
  386. package/dist/client/assets/agent-releases-BbYl9Mwf.js +0 -2
  387. package/dist/client/assets/agent-settings-Uir88FPs.js +0 -1
  388. package/dist/client/assets/agent-site-editor-code-CMk_fLsh.js +0 -2
  389. package/dist/client/assets/agent-site-editor-content-DTsWdPHL.js +0 -1
  390. package/dist/client/assets/agent-site-editor-preview-Br0J113j.js +0 -1
  391. package/dist/client/assets/agent-view-DSlQoDfx.js +0 -1
  392. package/dist/client/assets/analytics-tab-DnWN6v6x.js +0 -2
  393. package/dist/client/assets/api-keys-D17ng_fK.js +0 -1
  394. package/dist/client/assets/app-editor-BBiKxRJS.js +0 -1
  395. package/dist/client/assets/category-editor-Cklcuc6l.js +0 -1
  396. package/dist/client/assets/cms-settings-editor-bw2d5qFj.js +0 -1
  397. package/dist/client/assets/collection-detail-BRa2jvXK.js +0 -1
  398. package/dist/client/assets/context-bZenUCWc.js +0 -1
  399. package/dist/client/assets/discover-DqVrbNaN.js +0 -1
  400. package/dist/client/assets/file-explorer-B-ye_-97.js +0 -2
  401. package/dist/client/assets/home-CD9j4UYU.js +0 -1
  402. package/dist/client/assets/library-PZbd-Doo.js +0 -1
  403. package/dist/client/assets/monitoring-D6l4I6f5.js +0 -1
  404. package/dist/client/assets/order-monitor-day-BTTTp937.js +0 -1
  405. package/dist/client/assets/plan-DWTPbA95.js +0 -1
  406. package/dist/client/assets/post-calendar-CsYHka8d.js +0 -1
  407. package/dist/client/assets/project-app-view-BJ5Jx_gM.js +0 -1
  408. package/dist/client/assets/project-reports-VHT6QaEg.js +0 -1
  409. package/dist/client/assets/project-tasks-CJNYdN6D.js +0 -1
  410. package/dist/client/assets/record-editor-DTffX4wj.js +0 -1
  411. package/dist/client/assets/redirect-editor-BmKYzmzW.js +0 -1
  412. package/dist/client/assets/reports-Bj3OCHyV.js +0 -1
  413. package/dist/client/assets/reports-tab-DqVp7xB2.js +0 -2
  414. package/dist/client/assets/repositories-eo_EMvPJ.js +0 -1
  415. package/dist/client/assets/roles-DWAAM1uf.js +0 -1
  416. package/dist/client/assets/route-BFmFTSop.js +0 -1
  417. package/dist/client/assets/route-BVH9iZ3P.js +0 -1
  418. package/dist/client/assets/route-D-yMUgac.js +0 -1
  419. package/dist/client/assets/sections-editor-BxjGUtMX.js +0 -1
  420. package/dist/client/assets/seo-editor-Pqi1uTMV.js +0 -1
  421. package/dist/client/assets/settings-tab-CG7k6yYL.js +0 -1
  422. package/dist/client/assets/shell-layout-uDYSTXA5.js +0 -1
  423. package/dist/client/assets/site-editor-hILYo6nq.js +0 -1
  424. package/dist/client/assets/taskboard-analytics-DrH4N_FR.js +0 -1
  425. package/dist/client/assets/tasks-BJ_C2gVP.js +0 -1
  426. package/dist/client/assets/thread-analytics-BQ0AO_kH.js +0 -1
  427. package/dist/client/assets/useInfiniteQuery-LBIaZPt-.js +0 -1
  428. package/dist/client/assets/useSuspenseInfiniteQuery-ClnVveRy.js +0 -1
@@ -1 +0,0 @@
1
- import{hM as Ho,bh as Wo,c as jn,b as Rn,r as S,l as ae,j as r,bQ as qo,bd as Vs,hN as Ra,B as Ut,X as rn,aj as Go,Z as Uo,bg as Yo,Y as Zo,q as Jo,hm as Qo,hO as Xo,hP as ei,bp as xn,h as ti,bi as Rt,hQ as st,hR as Wr,hS as gs,hT as ni,hU as qr,hV as si,bw as ri,hW as ai,hX as Gr,hY as oi,t as q,bZ as Ur,hZ as ii,h_ as Kt,h$ as li,i0 as ci,i1 as ui,bY as Yr,i2 as vs,i3 as di,i4 as fi,i5 as mi,bW as pi,bx as hi,i6 as gi,i7 as vi,bT as Si,f7 as yi,K as bi,bu as Zr,i8 as Jr,i9 as xi,ia as _i,ib as ki,ic as Ss,id as wi,ie as ji,ig as Ri,ih as Ei,bR as Qr,ii as Vi,ij as Ti,ik as Xr,il as Ai,bV as Ni}from"./index-C8YP0XfX.js";import{u as Ci}from"./chat-context-BI1yxU4R.js";import{a2 as Pi,K as Qn,a3 as Ki,a4 as Mi,a5 as Bi,a6 as Di,a7 as Fi,a8 as Ii,a9 as ea,aa as Li,ab as Oi,z as Un,x as Yn,d as zi,u as $i,ac as ta,i as Hi,ad as Wi,k as qi,h as Gi,ae as Ea,af as Ui,ag as Yi,v as na,ah as Zi,ai as Ji,aj as Wn,ak as sa,al as ra,am as aa,an as ys,ao as Qi,D as Xi,ap as el,y as tl,aq as oa,ar as nl,as as ia,at as la,au as ca,M as sl,av as ua,a as rl,aw as an,ax as al,ay as ol,t as qn,az as _n}from"./held-block-view-BCUOCB3X.js";import{c as il}from"./repository-binding-B-4PI1n3.js";import{n as ll,t as cl}from"./ChevronUp-BMY88wXt.js";import{a8 as Va,b as Jn,an as ul,H as dl,a2 as da,_ as fa}from"./agent-icon-B7Q7dFXY.js";import{S as on}from"./scroll-area-BSd3TrLZ.js";import{c as Et,T as Vt,a as Tt}from"./tooltip-CJHeHoSn.js";import{l as fl,u as ml,m as pl,D as hl,a1 as gl,B as vl,ac as Mt,ad as Bt,N as Sl,ay as ma,Q as yl,Z as bl}from"./site-editor-toast-D9ddy9a_.js";import{u as xl,X as _l,E as bs,Y as pa,A as kl,Z as wl}from"./blocks-tab-states-BUek9Urr.js";import{m as jl,u as Rl,P as El}from"./mustache-BBa51FCf.js";import{a0 as Gt,T as ks,az as ws,a1 as Dt,U as ln,e as Vl,c as Tl,w as Al,k as Gn,p as wn,a4 as Nl,_ as qt,V as xs,Z as bt,Y as kn,F as Cl,a2 as ha,$ as Pl,ai as Kl,ak as Ml,aA as Bl,aB as Dl,aC as Fl}from"./parse-sections-B8Xcvgnu.js";import{a as Il}from"./Copy01-DGy0Absz.js";import{a as js,e as Ta}from"./UserSquare-D4xudMmb.js";import{i as ga}from"./Tool01-CTKnipD_.js";import{s as va}from"./Image01-DtpDUrwF.js";import{s as Ll}from"./Plus-Bh_xMwh7.js";import{s as Ol}from"./Trash01-BqP8uw7k.js";import{i as Rs}from"./ZoomOut-BVuJZ-2t.js";import{u as zl,a as Sa,K as $l,P as Hl,b as Wl,C as ql,D as Gl,c as Ul}from"./core.esm-CfGX-VCE.js";import{u as Yl,s as Zl,a as Zn,S as Jl,v as Ql}from"./sortable.esm-Bk2g_Gbz.js";import{s as Xl,g as ec,u as tc,A as nc}from"./use-section-preview-base-DFCMtdhN.js";import{a as sc,P as ya,w as rc,b as ac}from"./page-seo-form-DcpwPyQd.js";import{u as oc}from"./use-apply-named-rule-QplWW5Pw.js";import{b as ba,a as ic}from"./variant-matcher-override-DV7ZKzex.js";import{c as xa,d as lc,e as cc}from"./variant-draft-pointer-BeAKcq_c.js";import"./use-panel-navigate-CTWNyrxK.js";import"./thread-route-JcxEqRgq.js";import"./use-project-scope-BgLQY0Uk.js";import"./autosend-VKc1dW3G.js";import"./thread-intent-Cl7xa7dA.js";import"./use-mcp-client-CkAT8dMu.js";import"./auth-fndLm_KR.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./watch-sse-pool-B-0VhxE7.js";import"./task-board-u5TablbK.js";import"./schema-CFje17_E.js";import"./slugify-CEUa2lfQ.js";import"./use-decopilot-events-hbubA99f.js";import"./use-ai-providers-DzWzPq_c.js";import"./location-V0VwTJTt.js";import"./use-organization-settings-6EqlUT2Y.js";import"./utils-Chh_XkCj.js";import"./Play-IViIK9Vy.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./pair-DEJAc3iG.js";import"./LinkBroken01-BZrnscWF.js";import"./collapsible-B5J2aUd-.js";import"./use-copy-BCht-61u.js";import"./usage-stats-CNcWehA3.js";import"./tool-namespace-ChbHxLTp.js";import"./form-DmKuBQlJ.js";import"./label-BZDtWIcv.js";import"./utils-CVEq3hMx.js";import"./markdown-DuoP9xIE.js";import"./use-mobile-tv6dKHC3.js";import"./use-clock-tick-DxI4Q15z.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-DWv_y82s.js";import"./types-Cwtot2FB.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./AlertCircle-C0U53qC5.js";import"./XClose-D48r2tDo.js";import"./ShoppingBag01-BaMIB-e_.js";import"./SearchMd-DB3np2ti.js";import"./shell-layout-uDYSTXA5.js";import"./Building02-CcI-P3yL.js";import"./CheckCircle-fAPMl2yd.js";import"./Monitor01-Bmn1BV5T.js";import"./command-jlI8eprh.js";import"./index-BM9HifS6.js";import"./integration-icon-03FWmed-.js";import"./project-icon-BSrEdWN1.js";import"./new-project-dialog-BuE_SqTn.js";import"./ArrowLeft-BVJNIiuT.js";import"./repository-import-picker-BfMMau5M.js";import"./use-navigate-to-agent-BiKQMaG5.js";import"./repository-picker-CbWFb7rK.js";import"./useInfiniteQuery-LBIaZPt-.js";import"./infiniteQueryObserver-C8Tx1h_G.js";import"./collection-search-B_n3Ea8A.js";import"./use-debounced-value-ZtANdTDD.js";import"./required-auth-layout-ofmCqqpc.js";import"./use-org-sso-BK4EESlq.js";import"./sheet-ko7a2Uwq.js";import"./use-connection-ClhLV4Ep.js";import"./Link01-oZZyGItc.js";import"./use-mcp-prompts-BoifdA0D.js";import"./use-thread-outputs-am5Vd3rC.js";import"./file-type-icon-CLdhbOMq.js";import"./section-array-field-CWeYHp0D.js";import"./alert-CHj-Usrj.js";import"./switch-DbWQrL2t.js";import"./textarea-BeCs38v-.js";import"./ChevronSelectorVertical-C-CIIDml.js";import"./popover-C0DIKe_3.js";import"./monaco-editor-a3IVCcn2.js";import"./editor-CVSwKg6T.js";import"./calendar-BZJL1q0i.js";import"./SwitchHorizontal01-fMsLFMs0.js";import"./Minus-Dc5wow6R.js";import"./select-EVDcG5Hl.js";import"./index-BdQq_4o_.js";import"./index-B0Rg86vv.js";import"./editor-classes-Dkk1S2M6.js";import"./toggle-group-CWnjwOku.js";import"./active-indicator-CCMhAsc_.js";import"./combobox-BBB78IeP.js";import"./Upload01-CpPArzNK.js";import"./DotsVertical-Bfe9a_On.js";import"./search-input-CIT_dMpA.js";import"./tabs-BbA4-8ma.js";import"./use-file-configs-DI3WjDeq.js";import"./asset-utils-BvYMWLJK.js";import"./match-site-slug-config-D3fUJ6vX.js";import"./use-session-runtime-pkeEtIbf.js";import"./sandbox-git-api-DcqI6XE4.js";import"./sandbox-url-D3mC8qhT.js";import"./ArrowUp-BnowdRj-.js";import"./CreditCard01-DsjBhiEj.js";import"./Globe04-B-sNlZxN.js";import"./Key01-DifqnYu0.js";import"./Sun-BZlKwpGn.js";import"./Users01-buCmBl1X.js";import"./experiments-tab-choice-D5E9lbe8.js";import"./use-sandbox-events-Ccm6tkYH.js";import"./slider-Bg5y5q23.js";import"./index-Dc2A9bLg.js";import"./tooltipContext-CL92GCVz.js";import"./CategoricalChart-CukPvNkf.js";import"./index-CzZ16hae.js";import"./ActiveShapeUtils-CUGYcOGt.js";import"./Sector-BbL3mZ4i.js";import"./symbol-DLC3ejqz.js";import"./empty-state-CUanQ9Sm.js";import"./section-preview-url-7zfngvgW.js";import"./use-move-blocks-BaNRn466.js";const uc={escape:Pi};function dc(v,e){for(const p of Xl(v,e)){const y=typeof p.title=="string"?p.title:void 0;if(y?.includes("{{"))return y}}function fc(v,e){if(!e)return;const p=Ho(v,Wo(e));if(p)try{const y=dc(p.resolveType,e);return y&&jl.render(y,p.data,{},uc).trim()||void 0}catch{return}}function mc(v){const e=jn.c(13),{icon:p,label:y,className:b}=v;let V;e[0]!==b?(V=ae("size-3.5",b),e[0]=b,e[1]=V):V=e[1];let B;e[2]!==p||e[3]!==V?(B=r.jsx(p,{className:V}),e[2]=p,e[3]=V,e[4]=B):B=e[4];let w;e[5]!==y||e[6]!==B?(w=r.jsx(Vt,{asChild:!0,children:r.jsx("span",{role:"img","aria-label":y,className:"shrink-0 cursor-help",children:B})}),e[5]=y,e[6]=B,e[7]=w):w=e[7];let K;e[8]!==y?(K=r.jsx(Tt,{className:"max-w-56",children:y}),e[8]=y,e[9]=K):K=e[9];let k;return e[10]!==w||e[11]!==K?(k=r.jsxs(Et,{children:[w,K]}),e[10]=w,e[11]=K,e[12]=k):k=e[12],k}const pc="text-global-section-fg focus:bg-global-section/12 focus:text-global-section-fg dark:text-global-section-fg-dark dark:focus:bg-global-section/15 dark:focus:text-global-section-fg-dark [&_svg]:!text-global-section";function _a(v){return Array.from({length:v},(e,p)=>({id:crypto.randomUUID(),index:p}))}function Aa(v){return v.map((e,p)=>({...e,index:p}))}function hc(v,e){if(e===v.length)return v;if(e<v.length)return Aa(v.slice(0,e));const p=Array.from({length:e-v.length},(y,b)=>({id:crypto.randomUUID(),index:v.length+b}));return[...v,...p]}function Na(v){const e=jn.c(44),{section:p,raw:y,meta:b,decofile:V}=v,B=Rn(),w=Qn(),K=p.isSavedBlock===!0,k=p.isMultivariate===!0;let Q;e[0]!==b||e[1]!==y?(Q=y&&b?ec(y,b):void 0,e[0]=b,e[1]=y,e[2]=Q):Q=e[2];const ge=Q;let Ue;e[3]!==b||e[4]!==k||e[5]!==y||e[6]!==K?(Ue=y&&b&&!K&&!k?fc(y,b):void 0,e[3]=b,e[4]=k,e[5]=y,e[6]=K,e[7]=Ue):Ue=e[7];const Oe=Ue;let Ne;e[8]!==V||e[9]!==b||e[10]!==y||e[11]!==p?(Ne=Ii(y,p,V,b),e[8]=V,e[9]=b,e[10]=y,e[11]=p,e[12]=Ne):Ne=e[12];const oe=Ne;let R;e[13]!==k||e[14]!==y?.__resolveType?(R=!k&&Vs(y?.__resolveType??""),e[13]=k,e[14]=y?.__resolveType,e[15]=R):R=e[15];const c=R,xe=K?Jn:k?Va:Ta;let U;e[16]!==k||e[17]!==K?(U=K?{color:Yo}:k?{color:"oklch(0.65 0.15 160)"}:void 0,e[16]=k,e[17]=K,e[18]=U):U=e[18];const _e=U;let F;e[19]!==xe||e[20]!==w?(F=w?r.jsxs("span",{className:"relative size-4 shrink-0",children:[r.jsx(xe,{className:"absolute inset-0 size-4 text-muted-foreground transition-opacity group-hover:opacity-0 group-has-[:focus-visible]:opacity-0"}),r.jsx(Oi,{"aria-hidden":!0,className:"absolute inset-0 size-4 opacity-0 transition-opacity group-hover:opacity-100 group-has-[:focus-visible]:opacity-100"})]}):r.jsx(ul,{className:"h-4 w-4 shrink-0 text-muted-foreground/40"}),e[19]=xe,e[20]=w,e[21]=F):F=e[21];let ke;e[22]!==ge?(ke=ge&&r.jsx("img",{src:ge,alt:"",referrerPolicy:"no-referrer",className:"h-12 max-w-[100px] shrink-0 rounded-[var(--studio-control-radius,var(--radius))] object-cover"}),e[22]=ge,e[23]=ke):ke=e[23];let f;e[24]!==w||e[25]!==_e?(f=!w&&r.jsx(js,{className:"h-4 w-4 shrink-0",style:_e}),e[24]=w,e[25]=_e,e[26]=f):f=e[26];const ze=w?"shrink":"flex-1",u=p.isHidden&&"line-through opacity-50";let Re;e[27]!==u||e[28]!==ze?(Re=ae("min-w-0 truncate text-sm font-medium",ze,u),e[27]=u,e[28]=ze,e[29]=Re):Re=e[29];const X=Oe??p.label;let $e;e[30]!==Re||e[31]!==X?($e=r.jsx("span",{className:Re,children:X}),e[30]=Re,e[31]=X,e[32]=$e):$e=e[32];let rt;e[33]!==c||e[34]!==w||e[35]!==oe||e[36]!==B?(rt=w?r.jsxs(r.Fragment,{children:[c&&r.jsx(mc,{icon:Rs,label:B("sectionsEditor.sectionList.asyncBadge"),className:"text-muted-foreground"}),oe&&r.jsx(ea,{}),r.jsx("span",{className:"min-w-0 flex-1"})]}):oe&&r.jsx(ea,{className:"absolute -right-0.5 -top-0.5"}),e[33]=c,e[34]=w,e[35]=oe,e[36]=B,e[37]=rt):rt=e[37];let Ce;return e[38]!==$e||e[39]!==rt||e[40]!==F||e[41]!==ke||e[42]!==f?(Ce=r.jsxs(r.Fragment,{children:[F,ke,f,$e,rt]}),e[38]=$e,e[39]=rt,e[40]=F,e[41]=ke,e[42]=f,e[43]=Ce):Ce=e[43],Ce}const gc="text-global-section-fg hover:bg-global-section/12 dark:text-global-section-fg-dark dark:hover:bg-global-section/15",vc="text-[oklch(0.45_0.15_160)] hover:bg-[oklch(0.65_0.15_160/0.12)] dark:text-[oklch(0.78_0.15_160)] dark:hover:bg-[oklch(0.65_0.15_160/0.15)]";function Ca(v,e,p){if(p)return Li({selected:e});const y=v.isSavedBlock===!0,b=v.isMultivariate===!0;return ae("group relative flex select-none items-center gap-2 rounded-[var(--studio-control-radius,var(--radius-md))] px-2 py-2.5",e?"bg-accent text-accent-foreground":y?gc:b?vc:"text-foreground/80 hover:bg-accent hover:text-accent-foreground")}function _s(v,e){return ae("h-7 shrink-0 overflow-hidden",e?"w-7 ml-0 opacity-100 [transition:opacity_150ms_ease-out,width_0ms,margin-left_0ms]":v?"w-7 ml-0 opacity-0 [transition:opacity_150ms_ease-out,width_0ms_150ms,margin-left_0ms_150ms] group-hover:opacity-100 group-has-[:focus-visible]:opacity-100":"w-0 -ml-2 opacity-0 [transition:opacity_150ms_ease-out,width_0ms_150ms,margin-left_0ms_150ms] group-hover:ml-0 group-hover:w-7 group-hover:opacity-100 group-hover:[transition:opacity_150ms_ease-out,width_0ms,margin-left_0ms] group-has-[:focus-visible]:ml-0 group-has-[:focus-visible]:w-7 group-has-[:focus-visible]:opacity-100 group-has-[:focus-visible]:[transition:opacity_150ms_ease-out,width_0ms,margin-left_0ms]")}function Sc(v){const e=jn.c(90),{section:p,raw:y,meta:b,decofile:V,sortableId:B,selected:w,onSelect:K,onDelete:k,onDuplicate:Q,onMakeReusable:ge,onToggleHidden:Ue,onToggleLazy:Oe,onAddVariant:Ne,onDetach:oe}=v,R=Rn(),c=Qn(),xe=y?Vs(y.__resolveType??""):!1,U=p.isHidden===!0,_e=xe||U;let F;e[0]!==p?(F=Ra(p),e[0]=p,e[1]=F):F=e[1];const ke=F,f=!!Oe&&!p.isMultivariate;let ze;e[2]!==B?(ze={id:B,animateLayoutChanges:xc},e[2]=B,e[3]=ze):ze=e[3];const{attributes:u,listeners:Re,setNodeRef:X,transform:$e,isDragging:rt}=Yl(ze);let Ce;e[4]!==$e?(Ce=ql.Transform.toString($e?{...$e,x:0}:null),e[4]=$e,e[5]=Ce):Ce=e[5];const at=rt?0:void 0;let Pe;e[6]!==Ce||e[7]!==at?(Pe={transform:Ce,opacity:at},e[6]=Ce,e[7]=at,e[8]=Pe):Pe=e[8];const _=Pe;let we;e[9]!==p?(we=Mi(p),e[9]=p,e[10]=we):we=e[10];const ot=we,it="button",m=0;let L;e[11]!==K?(L=T=>{(T.key==="Enter"||T.key===" ")&&(T.preventDefault(),K())},e[11]=K,e[12]=L):L=e[12];const et=rt?"cursor-grabbing":"cursor-pointer";let A;e[13]!==c||e[14]!==p||e[15]!==w||e[16]!==et?(A=ae("touch-none transition-colors",et,Ca(p,w,c)),e[13]=c,e[14]=p,e[15]=w,e[16]=et,e[17]=A):A=e[17];let Ye;e[18]!==V||e[19]!==b||e[20]!==y||e[21]!==p?(Ye=r.jsx(Na,{section:p,raw:y,meta:b,decofile:V}),e[18]=V,e[19]=b,e[20]=y,e[21]=p,e[22]=Ye):Ye=e[22];const W=!c&&f&&r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx(Ut,{type:"button",variant:"ghost",size:"icon","aria-label":R(xe?"sectionsEditor.sectionList.disableAsyncRender":"sectionsEditor.sectionList.enableAsyncRender"),className:ae(_s(_e,xe)),onClick:T=>{T.stopPropagation(),Oe?.()},onPointerDown:bc,children:r.jsx(Rs,{className:ae("h-3.5 w-3.5",xe&&"text-warning")})})}),r.jsx(Tt,{side:"bottom",children:R(xe?"sectionsEditor.sectionList.disableAsyncRender":"sectionsEditor.sectionList.enableAsyncRender")})]}),lt=c?r.jsx(Bi,{label:R(U?"sectionsEditor.sectionList.showSection":"sectionsEditor.sectionList.hideSection"),active:U,onToggle:Ue,children:U?r.jsx(ga,{className:"h-3.5 w-3.5"}):r.jsx(va,{className:"h-3.5 w-3.5"})}):r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx(Ut,{type:"button",variant:"ghost",size:"icon","aria-label":R(U?"sectionsEditor.sectionList.showSection":"sectionsEditor.sectionList.hideSection"),className:ae(_s(_e,U)),onClick:T=>{T.stopPropagation(),Ue()},onPointerDown:yc,children:U?r.jsx(ga,{className:"h-3.5 w-3.5"}):r.jsx(va,{className:"h-3.5 w-3.5"})})}),r.jsx(Tt,{side:"bottom",children:R(U?"sectionsEditor.sectionList.showSection":"sectionsEditor.sectionList.hideSection")})]}),fe=Uo,Ze=Di;let ve;e[23]!==R?(ve=R("sectionsEditor.sectionList.sectionActionsMenu"),e[23]=R,e[24]=ve):ve=e[24];const ct=ae(_s(_e,!1),"data-[state=open]:ml-0 data-[state=open]:w-7 data-[state=open]:opacity-100 data-[state=open]:[transition:opacity_150ms_ease-out,width_0ms,margin-left_0ms]");let He;e[25]!==Ze||e[26]!==ve||e[27]!==ct?(He=r.jsx(Ze,{label:ve,classicClassName:ct}),e[25]=Ze,e[26]=ve,e[27]=ct,e[28]=He):He=e[28];let Ee;e[29]!==c||e[30]!==f||e[31]!==xe||e[32]!==Oe||e[33]!==R?(Ee=c&&f&&r.jsxs(r.Fragment,{children:[r.jsxs(rn,{onClick:T=>{T.stopPropagation(),Oe?.()},children:[r.jsx(Rs,{className:"h-4 w-4"}),R(xe?"sectionsEditor.sectionList.disableAsyncRender":"sectionsEditor.sectionList.enableAsyncRender")]}),r.jsx(Go,{})]}),e[29]=c,e[30]=f,e[31]=xe,e[32]=Oe,e[33]=R,e[34]=Ee):Ee=e[34];let Ke;e[35]!==Q?(Ke=T=>{T.stopPropagation(),Q()},e[35]=Q,e[36]=Ke):Ke=e[36];let tt;e[37]===Symbol.for("react.memo_cache_sentinel")?(tt=r.jsx(Il,{className:"h-4 w-4"}),e[37]=tt):tt=e[37];let Me;e[38]!==R?(Me=R("sectionsEditor.sectionList.duplicateMenuItem"),e[38]=R,e[39]=Me):Me=e[39];let Be;e[40]!==Ke||e[41]!==Me?(Be=r.jsxs(rn,{onClick:Ke,children:[tt,Me]}),e[40]=Ke,e[41]=Me,e[42]=Be):Be=e[42];let De;e[43]!==c||e[44]!==ke||e[45]!==Ne||e[46]!==R?(De=ke&&r.jsxs(rn,{className:ae(!c&&Fi),onClick:T=>{T.stopPropagation(),Ne()},children:[r.jsx(Va,{className:"h-4 w-4"}),R("sectionsEditor.sectionList.addVariantMenuItem")]}),e[43]=c,e[44]=ke,e[45]=Ne,e[46]=R,e[47]=De):De=e[47];let Y;e[48]!==c||e[49]!==ot||e[50]!==ge||e[51]!==R?(Y=ot&&r.jsxs(rn,{className:ae(!c&&pc),onClick:T=>{T.stopPropagation(),ge()},children:[c?r.jsx(Jn,{className:"h-4 w-4"}):r.jsx(js,{className:"h-4 w-4"}),R("sectionsEditor.sectionList.makeReusableMenuItem")]}),e[48]=c,e[49]=ot,e[50]=ge,e[51]=R,e[52]=Y):Y=e[52];let Z;e[53]!==c||e[54]!==oe||e[55]!==p.isMultivariate||e[56]!==p.isSavedBlock||e[57]!==R?(Z=p.isSavedBlock===!0&&!p.isMultivariate&&r.jsxs(rn,{onClick:T=>{T.stopPropagation(),oe()},children:[c?r.jsx(Ta,{className:"h-4 w-4"}):r.jsx(js,{className:"h-4 w-4"}),R("sectionsEditor.sectionList.detachMenuItem")]}),e[53]=c,e[54]=oe,e[55]=p.isMultivariate,e[56]=p.isSavedBlock,e[57]=R,e[58]=Z):Z=e[58];let ee;e[59]!==k?(ee=T=>{T.stopPropagation(),k()},e[59]=k,e[60]=ee):ee=e[60];let O;e[61]===Symbol.for("react.memo_cache_sentinel")?(O=r.jsx(Ol,{className:"h-4 w-4"}),e[61]=O):O=e[61];let N;e[62]!==R?(N=R("sectionsEditor.sectionList.deleteMenuItem"),e[62]=R,e[63]=N):N=e[63];let me;e[64]!==ee||e[65]!==N?(me=r.jsxs(rn,{variant:"destructive",onClick:ee,children:[O,N]}),e[64]=ee,e[65]=N,e[66]=me):me=e[66];let We;e[67]!==Ee||e[68]!==Be||e[69]!==De||e[70]!==Y||e[71]!==Z||e[72]!==me?(We=r.jsxs(Zo,{align:"end",className:"w-44",children:[Ee,Be,De,Y,Z,me]}),e[67]=Ee,e[68]=Be,e[69]=De,e[70]=Y,e[71]=Z,e[72]=me,e[73]=We):We=e[73];let qe;e[74]!==fe||e[75]!==He||e[76]!==We?(qe=r.jsxs(fe,{children:[He,We]}),e[74]=fe,e[75]=He,e[76]=We,e[77]=qe):qe=e[77];let Je;return e[78]!==u||e[79]!==Re||e[80]!==K||e[81]!==X||e[82]!==_||e[83]!==A||e[84]!==Ye||e[85]!==W||e[86]!==lt||e[87]!==qe||e[88]!==L?(Je=r.jsxs("div",{ref:X,style:_,...u,...Re,role:it,tabIndex:m,onClick:K,onKeyDown:L,className:A,children:[Ye,W,lt,qe]}),e[78]=u,e[79]=Re,e[80]=K,e[81]=X,e[82]=_,e[83]=A,e[84]=Ye,e[85]=W,e[86]=lt,e[87]=qe,e[88]=L,e[89]=Je):Je=e[89],Je}function yc(v){return v.stopPropagation()}function bc(v){return v.stopPropagation()}function xc(){return!1}function Es(v){const e=jn.c(11),{canAddSection:p,onAddSection:y,className:b,size:V}=v,B=Rn();let w;e[0]!==b?(w=ae("w-full",b),e[0]=b,e[1]=w):w=e[1];const K=!p;let k;e[2]===Symbol.for("react.memo_cache_sentinel")?(k=r.jsx(Ll,{size:14}),e[2]=k):k=e[2];let Q;e[3]!==B?(Q=B("sectionsEditor.sectionList.addSectionButton"),e[3]=B,e[4]=Q):Q=e[4];let ge;return e[5]!==y||e[6]!==V||e[7]!==w||e[8]!==K||e[9]!==Q?(ge=r.jsxs(Ut,{type:"button",variant:"outline",size:V,className:w,disabled:K,onClick:y,children:[k,Q]}),e[5]=y,e[6]=V,e[7]=w,e[8]=K,e[9]=Q,e[10]=ge):ge=e[10],ge}function _c(v){const e=jn.c(101),{listKey:p,rawSections:y,sections:b,meta:V,decofile:B,selectedIndex:w,onSelect:K,onReorder:k,onDelete:Q,onDuplicate:ge,onMakeReusable:Ue,onToggleHidden:Oe,onToggleLazy:Ne,onAddVariant:oe,onDetach:R,onAddSection:c,canAddSection:xe}=v,U=xe===void 0?!0:xe,_e=Rn(),F=Qn();let ke;e[0]!==b.length?(ke=()=>_a(b.length),e[0]=b.length,e[1]=ke):ke=e[1];const[f,ze]=S.useState(ke),[u,Re]=S.useState(null),[X,$e]=S.useState(p),[rt,Ce]=S.useState(b.length),at=S.useRef(!1);X!==p?($e(p),Ce(b.length),ze(_a(b.length))):rt!==b.length&&(Ce(b.length),ze(Fe=>hc(Fe,b.length)));let Pe;e[2]===Symbol.for("react.memo_cache_sentinel")?(Pe={activationConstraint:{distance:8}},e[2]=Pe):Pe=e[2];let _;e[3]===Symbol.for("react.memo_cache_sentinel")?(_={coordinateGetter:Zl},e[3]=_):_=e[3];const we=zl(Sa(Hl,Pe),Sa($l,_));let ot;e[4]!==f?(ot=f.map(kc),e[4]=f,e[5]=ot):ot=e[5];const it=ot;let m;e[6]===Symbol.for("react.memo_cache_sentinel")?(m=Fe=>{Re(String(Fe.active.id))},e[6]=m):m=e[6];const L=m;let et;e[7]!==it||e[8]!==k?(et=Fe=>{Re(null);const{active:G,over:ie}=Fe;if(!ie||G.id===ie.id)return;const Ve=it.indexOf(String(G.id)),Qe=it.indexOf(String(ie.id));Ve===-1||Qe===-1||(ze(nt=>Aa(Zn([...nt],Ve,Qe))),at.current=!0,requestAnimationFrame(()=>{at.current=!1}),k?.(Ve,Qe))},e[7]=it,e[8]=k,e[9]=et):et=e[9];const A=et;let Ye;e[10]===Symbol.for("react.memo_cache_sentinel")?(Ye=()=>{Re(null)},e[10]=Ye):Ye=e[10];const W=Ye;let lt,fe,Ze,ve,ct,He,Ee,Ke,tt,Me,Be,De,Y,Z,ee;if(e[11]!==u||e[12]!==U||e[13]!==F||e[14]!==B||e[15]!==f||e[16]!==it||e[17]!==A||e[18]!==V||e[19]!==c||e[20]!==oe||e[21]!==Q||e[22]!==R||e[23]!==ge||e[24]!==Ue||e[25]!==K||e[26]!==Oe||e[27]!==Ne||e[28]!==y||e[29]!==b||e[30]!==w||e[31]!==we||e[32]!==_e){Z=Symbol.for("react.early_return_sentinel");e:{const Fe=G=>{at.current||K(G)};if(e[48]!==u||e[49]!==U||e[50]!==F||e[51]!==f||e[52]!==c||e[53]!==y||e[54]!==b||e[55]!==_e){const G=u?f.find(ie=>ie.id===u):null;if(ve=G!=null?b[G.index]:null,Ze=G!=null?y[G.index]:void 0,f.length===0){let ie;e[59]!==_e?(ie=_e("sectionsEditor.sectionList.noSections"),e[59]=_e,e[60]=ie):ie=e[60];let Ve;e[61]!==ie?(Ve=r.jsx("p",{className:"px-2 py-3 text-xs text-muted-foreground",children:ie}),e[61]=ie,e[62]=Ve):Ve=e[62];const Qe=Ve;let nt;e[63]!==U||e[64]!==F||e[65]!==Qe||e[66]!==c?(nt=F?Qe:r.jsxs("div",{className:"space-y-2",children:[Qe,r.jsx(Es,{canAddSection:U,onAddSection:c,size:"sm"})]}),e[63]=U,e[64]=F,e[65]=Qe,e[66]=c,e[67]=nt):nt=e[67],Z=nt;break e}Y=ae(G&&"cursor-grabbing"),e[48]=u,e[49]=U,e[50]=F,e[51]=f,e[52]=c,e[53]=y,e[54]=b,e[55]=_e,e[56]=Ze,e[57]=ve,e[58]=Y}else Ze=e[56],ve=e[57],Y=e[58];fe=Gl,Ke=we,tt=Ul,Me=L,Be=A,De=W,lt=Jl,He=it,Ee=Ql,ee="space-y-1",ct=f.map(G=>{const ie=b[G.index];return ie?r.jsx(Sc,{sortableId:G.id,section:ie,raw:y[G.index],meta:V,decofile:B,selected:w===G.index,onSelect:()=>Fe(G.index),onDelete:()=>Q(G.index),onDuplicate:()=>ge(G.index),onMakeReusable:()=>Ue(G.index),onToggleHidden:()=>Oe(G.index),onToggleLazy:Ne?()=>Ne(G.index):void 0,onAddVariant:()=>oe(G.index),onDetach:()=>R(G.index)},G.id):null})}e[11]=u,e[12]=U,e[13]=F,e[14]=B,e[15]=f,e[16]=it,e[17]=A,e[18]=V,e[19]=c,e[20]=oe,e[21]=Q,e[22]=R,e[23]=ge,e[24]=Ue,e[25]=K,e[26]=Oe,e[27]=Ne,e[28]=y,e[29]=b,e[30]=w,e[31]=we,e[32]=_e,e[33]=lt,e[34]=fe,e[35]=Ze,e[36]=ve,e[37]=ct,e[38]=He,e[39]=Ee,e[40]=Ke,e[41]=tt,e[42]=Me,e[43]=Be,e[44]=De,e[45]=Y,e[46]=Z,e[47]=ee}else lt=e[33],fe=e[34],Ze=e[35],ve=e[36],ct=e[37],He=e[38],Ee=e[39],Ke=e[40],tt=e[41],Me=e[42],Be=e[43],De=e[44],Y=e[45],Z=e[46],ee=e[47];if(Z!==Symbol.for("react.early_return_sentinel"))return Z;let O;e[68]!==ct||e[69]!==ee?(O=r.jsx("div",{className:ee,children:ct}),e[68]=ct,e[69]=ee,e[70]=O):O=e[70];let N;e[71]!==lt||e[72]!==He||e[73]!==Ee||e[74]!==O?(N=r.jsx(lt,{items:He,strategy:Ee,children:O}),e[71]=lt,e[72]=He,e[73]=Ee,e[74]=O,e[75]=N):N=e[75];let me;e[76]!==Ze||e[77]!==ve||e[78]!==F||e[79]!==B||e[80]!==V?(me=ve?r.jsx("div",{className:ae("cursor-grabbing shadow-lift",Ca(ve,!1,F)),children:r.jsx(Na,{section:ve,raw:Ze,meta:V,decofile:B})}):null,e[76]=Ze,e[77]=ve,e[78]=F,e[79]=B,e[80]=V,e[81]=me):me=e[81];let We;e[82]!==me?(We=qo.createPortal(r.jsx(Wl,{dropAnimation:Ki,children:me}),document.body),e[82]=me,e[83]=We):We=e[83];let qe;e[84]!==fe||e[85]!==Ke||e[86]!==tt||e[87]!==Me||e[88]!==Be||e[89]!==De||e[90]!==N||e[91]!==We?(qe=r.jsxs(fe,{sensors:Ke,collisionDetection:tt,onDragStart:Me,onDragEnd:Be,onDragCancel:De,children:[N,We]}),e[84]=fe,e[85]=Ke,e[86]=tt,e[87]=Me,e[88]=Be,e[89]=De,e[90]=N,e[91]=We,e[92]=qe):qe=e[92];let Je;e[93]!==U||e[94]!==F||e[95]!==c?(Je=!F&&r.jsx(Es,{canAddSection:U,onAddSection:c,size:"sm",className:"mt-2"}),e[93]=U,e[94]=F,e[95]=c,e[96]=Je):Je=e[96];let T;return e[97]!==Y||e[98]!==qe||e[99]!==Je?(T=r.jsxs("div",{className:Y,children:[qe,Je]}),e[97]=Y,e[98]=qe,e[99]=Je,e[100]=T):T=e[100],T}function kc(v){return v.id}function wc(v,e,p,y){if(!v||typeof v!="object")return{kind:"error",reason:"no-matcher-rule"};const b=e.trim();if(!b)return Gt(v,p,y)?{kind:"inline",blockKey:v.__resolveType??"",inlinedRule:ks(v,p,y)}:{kind:"noop"};const V=ws(v,p,y);if(!V)return{kind:"error",reason:"unreadable-rule"};if(V.blockKey)return{kind:"updateBlock",blockKey:V.blockKey,blockData:Dt(V.resolveType,V.data,b)};const B=Un(b),w=Yn(B,p);return w?{kind:"error",reason:"invalid-block-id",message:w}:{kind:"createBlock",blockId:B,blockData:Dt(V.resolveType,V.data,b),reference:ln(B)}}const ka="section-form-stale-save",jc=3;function wa(v,e,p){const y=e.global&&e.pageKey?[{label:"Default",sections:[{__resolveType:e.pageKey}]}]:Ea(e.pageKey?v[e.pageKey]?.sections:void 0,v,p),b=Math.max(0,Math.min(e.pageVariantIndex,y.length-1)),V=y[b]?.sections??[];return{pageVariants:y,variantIndex:b,rawSections:V,parsedSections:wn(V,v,p)}}const ja=new WeakMap;let Rc=0;function Ec(v){let e=ja.get(v);return e===void 0&&(e=++Rc,ja.set(v,e)),e}function lf({orgSlug:v,virtualMcpId:e,branch:p,previewReady:y=!0,previewUrl:b,currentPath:V,activePageBlockKey:B=null,activeGlobalBlockKey:w=null,externalSelection:K,onSaved:k,initialEditSeo:Q=!1,onExitSeo:ge,onSelectRoot:Ue,onViewJsonFile:Oe,onFocusedBlockChange:Ne,onVariantPreviewOverride:oe,focusVariant:R}){const c=Rn(),xe=Ci(),U=xe?.taskId??null,_e=y?{orgSlug:v,virtualMcpId:e,branch:p,threadId:U,previewUrl:b}:null,[F,ke]=S.useState([]),{data:f,isLoading:ze}=fl(_e,{pollWhile:F.length>0}),{data:u,isLoading:Re}=xl(_e),X=Qn(),$e=xe?.virtualMcpId,Ce=il($e===e?e:null)?.metadata?.siteSlug??null,at=tc({virtualMcpId:e,branch:p,sandboxUrl:b}),Pe=ml(e,p),_=pl(Pe),we=Si(_),ot=!_,it=!!at||_,[m,L]=S.useState(null),[et,A]=S.useState(null),[Ye,W]=S.useState(null),[lt,fe]=S.useState(0),[Ze,ve]=S.useState(void 0),[ct,He]=S.useState(null),[Ee,Ke]=S.useState(null);R&&R.seq!==ct&&(He(R.seq),Ke(R));const[tt,Me]=S.useState(null),Be={index:tt,remember:Me},[De,Y]=S.useState(null),[Z,ee]=S.useState(null),[O,N]=S.useState([]),me=S.useRef(null),[We,qe]=S.useState(O.length);We!==O.length&&(qe(O.length),requestAnimationFrame(()=>{me.current&&(me.current.scrollTop=0)}));const[Je,T]=S.useState(0),[Fe,G]=S.useState(null),[ie,Ve]=S.useState(null),[Qe,nt]=S.useState(null),[Pa,Yt]=S.useState(!1),[Ts,Xn]=S.useState(!1),En=S.useRef(null),[Vn,Ka]=S.useState(!0),[Zt,Tn]=S.useState(!1),[Ft,An]=S.useState(!1),[Te,cn]=S.useState(Q),[As,Ns]=S.useState(Q);Q&&!As&&(Ns(!0),cn(!0),L(null),A(null),W(null),N([])),!Q&&As&&Ns(!1);const[Ma,un]=S.useState(null),[Cs,Nn]=S.useState(void 0),[Ps,It]=S.useState([]),[Ks,Jt]=S.useState(0),[Ie,ut]=S.useState(0),[Ba,Le]=S.useState(null),[Qt,Ge]=S.useState(null),[Ms,Bs]=S.useState(null),Ds=Jo(),Fs=hl({orgSlug:v,virtualMcpId:e,branch:p},{tunnel:!1}),dn=zi({orgSlug:v,virtualMcpId:e,branch:p}),[Da,Fa]=S.useState(V),[Ia,La]=S.useState(B),[Oa,za]=S.useState(w);(Da!==V||Ia!==B||Oa!==w)&&(queueMicrotask(()=>dn.flush()),Fa(V),La(B),za(w),L(null),A(null),W(null),fe(0),Y(null),ee(null),ut(0),Le(null),Ge(null),N([]),T(t=>t+1),cn(!1),un(null),Nn(void 0),It([]),Jt(t=>t+1));const D=$i({orgSlug:v,virtualMcpId:e,branch:p}),fn=rl((t,n)=>{D.mutate({blockKey:t,data:n},{onSuccess:()=>k?.(),onError:D.reportError})}),Cn=Rl({orgSlug:v,virtualMcpId:e,branch:p}),Is=oc({orgSlug:v,virtualMcpId:e,branch:p}),[Xt,en]=S.useState(!1),C=S.useRef(null),wt=S.useRef(null),gt=S.useRef(null),vt=S.useRef(null),Pn=S.useRef({}),Lt=S.useRef(null),mn=S.useRef(!1),pn=S.useRef(!1),Se=S.useRef(new Map),tn=S.useRef(!1),xt=S.useRef([]),es=S.useRef(new WeakSet);gl(v,e,t=>{const{activePageKey:n,rawSections:s,parsedSections:a,selectedSectionIndex:o}=ne.current,i=new Set;n&&i.add(n);for(const l of[wt.current?.sectionIndex,o]){const d=l==null?void 0:s[l],E=l==null?void 0:a[l],h=d&&E?.isSavedBlock?Ss(d,E):null;h&&i.add(h)}if([...i].some(l=>t.has(l))){for(const l of[C,gt,vt])l.current&&clearTimeout(l.current),l.current=null;wt.current=null,Se.current.clear(),n&&t.has(n)&&(Pn.current={})}});const ne=S.useRef({rawSections:[],parsedSections:[],decofile:{},activePageKey:null,pageVariants:[],variantIndex:0,sectionVariantIndex:0,selectedSectionIndex:null}),[Ls,Os]=S.useState(0),[$a,Ha]=S.useState(0),zs=Qo(Pe,{orgSlug:v,virtualMcpId:e,branch:p}),$s=Xo(zs,F[0]?.blockKey??null,F[0]?ei(xn(F[0].plan.theirs)):null),[Wa,qa]=S.useState(null),ts=vl(v,e).epoch,[Ga,Ua]=S.useState(ts);if(!y||ze||Re)return r.jsx("div",{className:"h-full w-full flex items-center justify-center",children:r.jsx(ti,{className:"size-5 text-muted-foreground"})});if(!f||!u)return r.jsx("div",{className:"h-full w-full flex items-center justify-center text-sm text-muted-foreground",children:c("sectionsEditor.sectionsEditor.couldNotLoadSiteData")});const Ya=Vl(f,u),$=!!w,se=$?null:Tl(Ya,V,B),g=$?w:se?.key??null,Kn=$&&w?f[w]:void 0,Hs=$&&w&&Kn?Al(w,Kn):$&&w?w:"",Ot=!$&&g&&f[g]?f[g]:null,ns=Te&&f&&u&&g&&se?ta(f,{kind:"page",pageKey:g,pageName:String(se.name??""),path:String(se.path??"")},u):null,Za=Te?Ot?.seo:void 0,Mn=Cs!==void 0?Cs:Za,Ja=Te?Hi(Mn):void 0,Ws=ns?.seoTypeOptions??[],qs=Te&&u?Wi(u):"",ss=Ma??Ja??{},Bn=Te&&ns?sc(ss,ns):null,Gs=Te&&Bn&&qi(Mn)?Gn(Bn,u):null,Us=Te?Gi(f,u)?.seoData:void 0,le=$?[{label:"Default",sections:[{__resolveType:w}]}]:Ea(Ot?.sections,f??{},_),St=le.length>1,J=Math.min(lt,le.length-1),ye=le[J],M=ye?.sections??[],ce=wn(M,f,_),Dn=!$&&Nl(Ot?.sections,_);if($&&w&&Ms!==w){Bs(w);const t=M[0],n=ce[0];if(t&&n){L(0),ut(0),N([]);const s=Rt(t,n,f,_);s&&(A(s.data),W(s.resolveType),Ge(null),Le(null))}}!$&&Ms!==null&&Bs(null),ne.current={rawSections:M,parsedSections:ce,decofile:f??{},activePageKey:g,pageVariants:le,variantIndex:J,sectionVariantIndex:Ie,selectedSectionIndex:m};const Qa=()=>({multivariate:Dn,index:J,variants:le.map(t=>({rule:t.rule})),lazyValues:_&&Dn&&yi(Ot?.sections?.variants?.[J]?.value)}),rs=(t,n)=>{if(!oe)return;if(!g||!Dn||t.length<=1){oe(null);return}const s={multivariate:!0,index:n,variants:t},a=_?xa(g,s):ba(g,s,f,u);oe(a.length>0?a:null)},as=oe&&g&&Dn&&St&&!ze&&!Re?g:null;if(as!==Wa&&(qa(as),as)){const t=le.map(s=>({rule:s.rule})),n=J;queueMicrotask(()=>rs(t,n))}const zt=(t,n,s)=>{if(!oe)return;if(!g){oe(null);return}const a=Qa(),o=_?xa(g,a):ba(g,a,f,u);if(!t||n<0){oe(o.length>0?o:null);return}const i={pageKey:g,page:a,sectionIndex:n,sectionLazy:ce[n]?.isLazy??!1,mvObj:t,selectedVariantIndex:s},l=_?lc(i):ic({...i,decofile:f,meta:u}),d=_?cc(o,l):[...o,...l];oe(d.length>0?d:null)},_t=(t,n,s,a=m??-1,o=!1)=>{const i=st(t,n);if(!i){A(null),W(null),Ge(null),Le(null),o&&zt(null,a,s);return}const d=qr(i,we)[s];if(!d){A(null),W(null),Ge(null),Le(null),o&&zt(null,a,s);return}const E=ai(d.value,f);A(E?.data??null),W(E?.resolveType??null);const{resolveType:h,formValue:x}=qt(d.rule,f,u??void 0);Ge(h),Le(x),o&&zt(i,a,s)},hn=t=>{Ve(null),fe(t),L(null),A(null),W(null),N([]);const n=le[t]?.rule,{resolveType:s,formValue:a}=qt(n,f??{},u??void 0);ee(s),Y(a),rs(le.map(o=>({rule:o.rule})),t)},Ys=(t,n)=>{const s=M[t],a=ce[t];if(!s||!a)return!1;const o=a.isMultivariate?st(s,a)?.variants?.length??0:0,i=n<o?n:0;if(L(t),ut(i),N([]),T(l=>l+1),a.isMultivariate)_t(s,a,i,t);else{const l=Rt(s,a,f,_);l?(A(l.data),W(l.resolveType)):(A(null),W(null)),Ge(null),Le(null)}return!0},Zs=K?.index;if(K!==void 0&&(K?.seq??null)!==Ze&&(ve(K?.seq??null),typeof Zs=="number"&&Ys(Zs,0)),Ee&&($?Kn:Ot)){const t=Ee.pageVariant,n=!$&&t!==void 0&&t<le.length;if(n&&t!==J)hn(t);else{Ke(null);const{section:s,variant:a}=Ee;if($)a!==void 0&&(Me(a),N([]),T(o=>o+1));else if(s!==void 0&&Ys(s,a??0)){const o=M[s],i=ce[s],l=i.isMultivariate?st(o,i):null;l&&a!==void 0&&queueMicrotask(()=>zt(l,s,a))}else n&&hn(t)}}if(ts!==Ga){Ua(ts);const t=C.current!==null||Se.current.size>0||vt.current!==null||gt.current!==null||D.isPending||dn.isPending||F.length>0,n=m!==null&&Wr(me.current,document.activeElement);if(!t&&n&&(tn.current=!0),!t&&!n&&m!==null){const s=M[m],a=ce[m];if(N([]),T(o=>o+1),!s||!a)L(null),A(null),W(null);else if(a.isMultivariate)_t(s,a,Ie,m);else{const o=Rt(s,a,f,_);A(o?.data??null),W(o?.resolveType??null)}}!t&&Te&&(un(null),Nn(void 0),Jt(s=>s+1))}if(Ls!==$a){Ha(Ls);const t=m!==null?M[m]:null,n=m!==null?ce[m]:null;if(t&&n&&m!==null)if(N([]),T(s=>s+1),n.isMultivariate)_t(t,n,Ie,m);else{const s=Rt(t,n,f,_);A(s?.data??null),W(s?.resolveType??null)}}const dt=F[0];if(dt){const{formBase:t,target:n}=dt,s=wa(f,n,_),a=t.sectionIndex,o=s.rawSections.length===t.sectionCount?gs(s.rawSections[a],s.parsedSections[a],n.sectionVariantIndex,f,_):null,i=ni(dt,o,l=>Gr(t,l));if(i){const d=[{...dt,...i,changedAgain:!0},...F.slice(1)];xt.current=d,ke(d)}}const gn={orgSlug:v,virtualMcpId:e,branch:p,threadId:U,previewUrl:_?void 0:b??void 0,siteSlug:Ce},Fn=Ye&&u?Gn(Ye,u):null,ft=(t,n)=>{if(!g)return;C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear(),vt.current&&(clearTimeout(vt.current),vt.current=null),gt.current&&(clearTimeout(gt.current),gt.current=null);const s=an(f,g,t,J,le);D.mutate({blockKey:g,data:s},{onSuccess:()=>n?.onSuccess?.()??k?.(),onError:a=>{n?.onError?.(),D.reportError(a)}})},$t=()=>{Ne?.(null),L(null),An(!1),A(null),W(null),ut(0),Le(null),Ge(null),N([]),T(t=>t+1)},Js=()=>Wr(me.current,document.activeElement),os=(t=c("sectionsEditor.sectionsEditor.blockChangedElsewhere"))=>{if(C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear(),wt.current=null,q.error(t,{id:ka}),Js()){tn.current=!0;return}Os(n=>n+1)},Qs=()=>{!tn.current||Js()||xt.current.length>0||C.current!==null||mn.current||pn.current||Se.current.size>0||(tn.current=!1,Os(t=>t+1))},Xs=()=>{tn.current&&setTimeout(Qs,0)},er=t=>bl(Ds,Fs,t,Pe.kind==="protocol"?Pe:null),tr=t=>{Se.current.size!==0&&setTimeout(()=>{if(mn.current||pn.current)return;const n=[...Se.current.values()];Se.current.clear();for(const s of n)s()},t)},Xa=t=>{const{activePageKey:n,variantIndex:s,sectionVariantIndex:a}=ne.current,o=Lt.current;return{formBase:o?.sectionIndex===t&&o.variantIndex===a?o:null,pageKey:n,global:$,pageVariantIndex:s,sectionVariantIndex:a,schema:Fn}},vn=t=>{xt.current=t,ke(t)},eo=t=>{const n=xt.current,s=n.findIndex(i=>i.formBase===t.formBase),a=s>=0?n[s]:void 0,o=a?n.with(s,{...t,choices:Jr(a.plan,a.choices,t.plan),fresh:Vi(a.plan,t.plan,a.fresh),changedAgain:a.changedAgain||xn(a.plan.theirs)!==xn(t.plan.theirs)}):[...n,{...t,changedAgain:es.current.has(t.formBase)}];vn(o)},nr=(t,n)=>{const s=xt.current,a=s.findIndex(l=>l.formBase===t),o=s[a];if(!o)return!1;if(xn(o.plan.mine)===xn(n))return!0;const i=Zr({...o.plan,mine:n});if(i.pointers.length===0){const l=s.filter(d=>d!==o);return vn(l),!1}return vn(s.with(a,{...o,plan:i,choices:Jr(o.plan,o.choices,i)})),!0},to=t=>{const n=ne.current;return n.selectedSectionIndex===t.formBase.sectionIndex&&n.activePageKey===t.target.pageKey&&n.variantIndex===t.target.pageVariantIndex&&n.sectionVariantIndex===t.target.sectionVariantIndex},no=()=>{const t=xt.current[0];if(!t)return null;const{formBase:n,target:s}=t;C.current&&wt.current?.sectionIndex===n.sectionIndex&&wt.current.sectionVariantIndex===s.sectionVariantIndex&&(clearTimeout(C.current),C.current=null,wt.current=null),Se.current.delete(`${s.pageKey}:${n.sectionIndex}:${s.sectionVariantIndex}`);const a=n.emitted;return a&&typeof a=="object"&&!nr(n,a)&&Sn(a,n.sectionIndex,0,s),xt.current[0]??null},so=()=>{const t=xt.current[0],n=no();if(!n||!t||n.formBase!==t.formBase||n.plan.pointers.some(i=>!t.plan.pointers.includes(i)))return;const s=hi(n.plan,n.choices);Pe.kind==="protocol"&&Pe.source==="github"&&gi(n.plan,n.choices)&&Sl(c,!1),vn(xt.current.slice(1));const{formBase:a,target:o}=n;a.base=n.plan.theirs,a.version=void 0,a.emitted=s,es.current.add(a),(Lt.current===a||to(n))&&(Lt.current=a,A(s),T(i=>i+1)),Sn(s,a.sectionIndex,0,o)},ro=t=>{const[n,...s]=xt.current;n&&vn([{...n,choices:t},...s])},Sn=(t,n,s=0,a,o=!1)=>{const i=a??Xa(n),l=i.sectionVariantIndex,d=i.formBase,E=wt.current;C.current&&(clearTimeout(C.current),C.current=null,E&&(E.sectionIndex!==n||E.sectionVariantIndex!==l)&&E.write());const h=`${i.pageKey}:${n}:${l}`,x=()=>{if(mn.current||pn.current){Se.current.set(h,x);return}const j=typeof t=="function"?t():t;if(d&&nr(d,j))return;const I=ne.current.decofile,{rawSections:P,parsedSections:pe,pageVariants:ue,variantIndex:be}=wa(I,i,_),z=i.pageKey,H=P[n];if(!H)return;const re=pe[n];if(!re)return;const he=d?.base,Ae=gs(H,re,l,I,_),sn=!!he&&!!Ae&&xi(he,Ae)&&!(d&&Gr(d,Ae));if(sn&&he&&Ae){if(_i(he,Ae)){os(c("sectionsEditor.sectionsEditor.sectionReplacedElsewhere"));return}const te=re.isSavedBlock?"here":ki(he,P.map((de,ht)=>gs(de,pe[ht],l,I,_)),n,d?.sectionCount??P.length);if(te==="unknown"){os(c("sectionsEditor.sectionsEditor.sectionReplacedElsewhere"));return}if(typeof te=="number"&&d){d.sectionCount=P.length,d.sectionIndex=te,Lt.current===d&&L(te),Sn(j,te,s,i);return}}const pt=sn&&he&&Ae?Zr({ancestor:he,mine:j,theirs:Ae}):null;if(pt&&pt.pointers.length>0&&d){d.sectionCount=P.length,eo({plan:pt,formBase:d,target:i,sectionIndex:n,choices:wi(pt),changedAgain:!1,blockKey:re.isSavedBlock?Ss(H,re):z,fresh:{}});return}const Xe=pt?pt.merged:null,Pt=Xe??j,zr=ji({merged:!!Xe,tracked:d,current:Lt.current,saved:j});Xe&&q.info(c("sectionsEditor.sectionsEditor.blockMergedWithOthers"),{id:ka}),zr&&d&&(d.emitted=Xe,A(Xe));const hs=zr||!Xe?Pt:j;d&&(d.base=hs,d.sectionCount=P.length,Ri(d,hs));const $r={onSuccess:()=>{d&&es.current.delete(d),k?.()},onError:te=>{if(d?.base===hs&&he&&(d.base=he),te instanceof yl){if(d&&(d.version=void 0),s<jc){Se.current.delete(h),pn.current=!0;const de=Ti(s,te.carriedStored);setTimeout(()=>{pn.current=!1,Sn(()=>{const ht=d?.emitted;return ht&&typeof ht=="object"?ht:j},n,s+1,i,de.immediate),Se.current.delete(h),tr(_n)},de.delay)}else os();return}D.reportError(te)}},Hr=te=>{mn.current=!0;let de=!1;D.mutateAsync(te).then(()=>$r.onSuccess(),ht=>{de=!0,$r.onError(ht)}).finally(()=>{mn.current=!1,tr(de?_n:0),Qs()})};if(re.isSavedBlock){const te=Ss(H,re);if(!te)return;Hr({blockKey:te,data:Pt,...he?{base:{value:Xe?Ae:he}}:{},rebaseOnConflict:!1,guard:Xr({formBase:d,rebased:!!Xe,versionOf:er})});return}if(!z)return;const Hn={...I[z]},Wt=[...P];if(re.isMultivariate){const te=st(H,re);if(!te||!z)return;const de=Ei(te,l,Pt);Wt[n]=Kt(H,re,de)}else if(re.isHidden){const te=Vs(H.__resolveType),de=te?{...H.section}:{...H},ht=Array.isArray(de.variants)?[...de.variants]:[];ht[0]&&(ht[0]=Qr(de.__resolveType,ht[0],Pt)),de.variants=ht,te?Wt[n]={...H,section:de}:Wt[n]=de}else re.isLazy?Wt[n]={...H,section:Pt}:Wt[n]=Pt;if(ue.length>1){const te=Hn.sections,de=[...te?.variants??[]];de[be]&&(de[be]=Qr(te?.__resolveType,de[be],Wt)),Hn.sections={...te,variants:de}}else Hn.sections=Wt;Hr({blockKey:z,data:Hn,rebaseOnConflict:!1,guard:Xr({formBase:null,rebased:!1,versionOf:er})})};if(wt.current={sectionIndex:n,sectionVariantIndex:l,write:x},o){wt.current=null,x();return}C.current=setTimeout(()=>{C.current=null,x()},_n)},ao=t=>{tn.current=!1,L(t),ut(0),N([]),T(o=>o+1);const n=M[t],s=ce[t];if(Ne?.(s?.isSavedBlock?s.resolveType??null:null),!n||!s)return;if(s.isMultivariate){_t(n,s,0,t);return}const a=Rt(n,s,f,_);if(!a){A(null),W(null),Ge(null),Le(null),zt(null,t,0);return}A(a.data),W(a.resolveType),Ge(null),Le(null),zt(null,t,0)},sr=t=>{const n=t;m!==null&&(Lt.current=vi(Lt.current,{sectionIndex:m,variantIndex:ne.current.sectionVariantIndex,shown:et,next:n,sectionCount:ne.current.rawSections.length})),A(n),m!==null&&Sn(n,m)},is=t=>{if(!g||!f||!u||!se)return;const n={kind:"page",pageKey:g,pageName:String(se.name??""),path:String(se.path??"")},s=ta(f,n,u);s&&dn.save(g,()=>{const a=Ds.getQueryData(bi.decofile(Fs))?.[g];if(!a||typeof a!="object"||a===null||Array.isArray(a))return null;const o={...a,...Pn.current};return Pn.current={},t?.raw!==void 0?rc(o,t.raw,u):t?.inner!==void 0?ac(n,s,o,t.inner):o})},rr=(t,n)=>{g&&(Pn.current[t]=n,is())},oo=(t,n)=>{if(!g)return;const s=Zn([...M],t,n);m!==null&&(m===t?L(n):t<m&&n>=m?L(m-1):t>m&&n<=m&&L(m+1)),ft(s)},io=t=>{if(!g)return;const n=M.filter((s,a)=>a!==t);m===t?$t():m!==null&&m>t&&L(m-1),ft(n)},lo=t=>{if(!g)return;const n=M[t];if(!n)return;const s=[...M];s.splice(t+1,0,al(n)),m!==null&&m>t&&L(m+1),ft(s)},co=t=>{if(!g)return;const n=M[t],s=ce[t];if(!n||!s)return;const a=s.isHidden?fi(n,_):mi(n,u);if(!a)return;const o=[...M];o[t]=a,m===t&&$t(),ft(o)},uo=t=>{if(!g)return;const n=M[t],s=ce[t];if(!n||!s||s.isMultivariate)return;const a=di(n);if(!a)return;const o=[...M];o[t]=a,m===t&&$t(),ft(o)},fo=t=>{if(!g)return;const n=M[t],s=ce[t];if(!n||!s?.isSavedBlock)return;const a=Rt(n,s,f,_);if(!a?.data)return;const{name:o,...i}=a.data,l=[...M];s.isLazy?l[t]={...n,section:i}:l[t]=i,m===t&&$t(),ft(l)},mo=t=>{if(!g)return;const n=[...M,{__resolveType:t.resolveType}],s=n.length-1;ft(n,{onError:()=>{ne.current.selectedSectionIndex===s&&$t()}}),Yt(!1),L(s),ut(0),N([]),T(l=>l+1);const a=n[s],o=wn(n,f,_)[s];if(!a||!o)return;if(o.isMultivariate){_t(a,o,0);return}const i=Rt(a,o,f,_);if(!i){A(null),W(null),Ge(null),Le(null);return}A(i.data),W(i.resolveType),Ge(null),Le(null)},ar=t=>{En.current=t.append,Yt(!0)},po=t=>{const n=En.current;if(!n){mo(t);return}n({__resolveType:t.resolveType}),Yt(!1),En.current=null},or=t=>{if(m===null)return;const n=M[m],s=ce[m];!n||!s?.isMultivariate||(ut(t),N([]),T(a=>a+1),_t(n,s,t,m,!0))},ho=t=>{if(m===null||!g)return;const n=M[m],s=ce[m];if(!n||!s?.isMultivariate)return;const a=st(n,s);if(!a)return;const o=ci(a,t);if(!o){q.error(c("sectionsEditor.sectionsEditor.cannotDeleteOnlyVariant"));return}const i=[...M];i[m]=Kt(n,s,o);const l=o.variants;let d=Ie;t===Ie?d=Math.min(t,l.length-1):t<Ie&&(d=Ie-1),ut(d),N([]),T(E=>E+1),_t(i[m],s,d),ft(i)},go=t=>{if(m===null||!g)return;const n=M[m],s=ce[m];if(!n||!s?.isMultivariate)return;const a=st(n,s);if(!a)return;const o=ui(a,t,_),i=[...M];i[m]=Kt(n,s,o);const l=Yr(a.variants??[],t,_);ut(l),N([]),T(d=>d+1),_t(i[m],s,l,m,_),ft(i)},vo=(t,n)=>{if(m===null||!g||t===n)return;const s=M[m],a=ce[m];if(!s||!a?.isMultivariate)return;const o=st(s,a);if(!o)return;const i=ii(o,t,n),l=[...M];l[m]=Kt(s,a,i);let d=Ie;Ie===t?d=n:t<Ie&&n>=Ie?d=Ie-1:t>Ie&&n<=Ie&&(d=Ie+1),ut(d),_t(l[m],a,d,m,_),ft(l)},yn=t=>{const n=t??m;if(n===null||!g)return;const s=M[n],a=ce[n];if(!s||!a)return;const o=oi(s,a,void 0,u,_);if(!o){q.error(c("sectionsEditor.sectionsEditor.sectionCannotHaveVariants"));return}const i=[...M];i[n]=o.section;const l=wn(i,f,_)[n];if(!l?.isMultivariate){q.error(c("sectionsEditor.sectionsEditor.couldNotAddVariant"));return}L(n),ut(o.newVariantIndex),N([]),T(d=>d+1),_t(o.section,l,o.newVariantIndex,n,_),ft(i)},ir=()=>{if(m===null||!g)return;const t=M[m],n=ce[m];if(!t||!n?.isMultivariate)return;const s=st(t,n);if(!s)return;const a=li(t,n,s);if(!a){q.error(c("sectionsEditor.sectionsEditor.couldNotRemoveVariants"));return}const o=[...M];o[m]=a;const i=wn(o,f,_)[m];if(!i)return;ut(0),Ge(null),Le(null),N([]),T(d=>d+1);const l=Rt(a,i,f,_);l?(A(l.data),W(l.resolveType)):(A(null),W(null)),zt(null,m,0),ft(o)},So=async t=>{if(Fe===null||!g)return;const n=Yn(t,f,u);if(n){q.error(n);return}const s=M[Fe],a=ce[Fe];if(!s||!a)return;const o=Rt(s,a,f,_);if(!o){q.error(c("sectionsEditor.sectionsEditor.sectionCannotBeSavedAsGlobal"));return}const i={...o.data,name:t};try{const l=await D.mutateAsync({blockKey:t,data:i,create:!0}),d=[...M];d[Fe]={__resolveType:t},await D.mutateAsync({blockKey:g,data:an(f,g,d,J,le)}),m===Fe&&$t(),G(null),qn(l)||q.success(c("sectionsEditor.sectionsEditor.savedGlobalBlock",{blockId:t})),k?.()}catch(l){q.error(c("sectionsEditor.sectionsEditor.failedToSaveGlobalBlock"),{description:Mt(c,Bt(l))})}},lr=ye?.rule;if(St&&m===null&&Z===null&&lr){const{resolveType:t,formValue:n}=qt(lr,f??{},u??void 0);ee(t),Y(n)}const nn=u?Ui(u):[],ls=u&&f?Yi(u,f):[],Ht=_&&u&&f?_l(u,f):[],cs=(t,n)=>{if(Ht.length===0)return;const s=Pl(t);return{kinds:Ht,selected:s,campaignPrefill:kl(t),onPick:n}},cr=!$&&!!(it&&u&&f),ur=Z&&u?Gn(Z,u):null,yt=()=>{gt.current&&(clearTimeout(gt.current),gt.current=null),vt.current&&(clearTimeout(vt.current),vt.current=null)},kt=async(t,n)=>{if(!(Dl(n,t,u)>0))try{await Cn.mutateAsync({blockKey:t})}catch(s){q.error(c("sectionsEditor.sectionsEditor.couldNotDeleteMatcherBlock"),{description:Mt(c,Bt(s))})}},dr=t=>{gt.current&&clearTimeout(gt.current),gt.current=setTimeout(()=>{const{activePageKey:n,decofile:s,variantIndex:a}=ne.current;if(!n)return;const o={...s[n]},i={...o.sections},l=[...i.variants??[]],d=l[a],E=d?.rule;if(Gt(E,s,u)){const h=E?.__resolveType??"",x=s[h],j=typeof x?.name=="string"?x.name:h,{__resolveType:I,...P}=t;D.mutate({blockKey:h,data:Dt(I??"",P,j)},{onSuccess:()=>k?.(),onError:D.reportError});return}d&&(l[a]={...d,rule:t}),o.sections={...i,variants:l},D.mutate({blockKey:n,data:o},{onSuccess:()=>k?.(),onError:D.reportError})},_n)},fr=t=>{ee(t);const n=t?ha(t,u):{__resolveType:Ur(u)};Y(t?n:{}),dr(n)},mr=t=>{const n=t;Y(n);const s=Z?{__resolveType:Z,...n}:{...n};dr(s)},In=async(t,n,s)=>{const a=wl(n,t);if(!a.ok)return a.reason==="conflict"&&q.info(t.kind==="experiments"?c("sectionsEditor.namedRulePicker.conflictTests"):c("sectionsEditor.namedRulePicker.conflictCampaigns"),ma),null;const o={};if(s){const i=s(a.rule);if(!i)return null;o[i.blockKey]=i.data}return a.blockWrite&&(o[a.blockWrite.blockKey]=a.blockWrite.block),Object.keys(o).length>0&&!(await Is.apply({writes:o})).ok?null:(a.blockWrite&&q.success(t.kind==="experiments"?c("sectionsEditor.namedRulePicker.createdTest",{name:t.name.trim()}):c("sectionsEditor.namedRulePicker.createdCampaign",{name:t.name.trim()}),{...ma,description:c("sectionsEditor.namedRulePicker.createdHint")}),{rule:a.rule,projected:{...n,...o}})},pr=Ht.length>0?{kinds:Ht,prepare:async t=>(await In(t,ne.current.decofile,void 0))?.rule??null,ensureBlock:async t=>{const n=Kl(ne.current.decofile,t);return n.kind==="saved"?!0:n.kind==="conflict"?!1:(await Is.apply({writes:{[Ml(t).blockKey]:n.block}})).ok}}:null,hr=async t=>{yt();const{activePageKey:n,decofile:s,variantIndex:a}=ne.current;if(!n)return;let o=null;const i=await In(t,s,E=>{const h=s[n],x=h?.sections;if(!x||typeof x!="object"||Array.isArray(x))return null;const j=x;if(!Array.isArray(j.variants))return null;const I=[...j.variants],P=I[a];return P?(o=bt(P.rule,s,u),I[a]={...P,rule:E},{blockKey:n,data:{...h,sections:{...j,variants:I}}}):null});if(!i)return;const{resolveType:l,formValue:d}=qt(i.rule,i.projected,u??void 0);ee(l),Y(d),o&&await kt(o,i.projected),k?.()},gr=async t=>{yt();const{activePageKey:n,decofile:s,variantIndex:a}=ne.current;if(!n)return;const o=s[n],i=o?.sections;if(!i||typeof i!="object"||Array.isArray(i))return;const l=i;if(!Array.isArray(l.variants))return;const d=[...l.variants],E=d[a];if(!E)return;const h=bt(E.rule,s,u),x=ln(t);d[a]={...E,rule:x};const j={...s,[n]:{...o,sections:{...l,variants:d}}},{resolveType:I,formValue:P}=qt(x,j,u??void 0);ee(I),Y(P);try{await D.mutateAsync({blockKey:n,data:j[n]}),h&&h!==t&&await kt(h,j),k?.()}catch(pe){q.error(c("sectionsEditor.sectionsEditor.couldNotApplySavedRule"),{description:Mt(c,Bt(pe))})}},vr=t=>{vt.current&&clearTimeout(vt.current);const{selectedSectionIndex:n,sectionVariantIndex:s}=ne.current;n!==null&&(vt.current=setTimeout(()=>{const{rawSections:a,parsedSections:o,decofile:i,activePageKey:l,pageVariants:d,variantIndex:E}=ne.current;if(!l)return;const h=a[n],x=o[n];if(!h||!x?.isMultivariate)return;const j=st(h,x);if(!j)return;const P=(j.variants??[])[s]?.rule;if(Gt(P,i,u)){const z=P?.__resolveType??"",H=i[z],re=typeof H?.name=="string"?H.name:z,{__resolveType:he,...Ae}=t;D.mutate({blockKey:z,data:Dt(he??"",Ae,re)},{onSuccess:()=>k?.(),onError:D.reportError});return}const pe=vs(j,s,t),ue=[...a];ue[n]=Kt(h,x,pe);const be=an(i,l,ue,E,d);D.mutate({blockKey:l,data:be},{onSuccess:()=>k?.(),onError:D.reportError})},_n))},yo=t=>{Ge(t);const n=t?ha(t,u):{__resolveType:Ur(u)};Le(t?n:{}),vr(n)},bo=t=>{const n=t;Le(n);const s=Qt?{__resolveType:Qt,...n}:{...n};vr(s)},xo=async t=>{yt();const{selectedSectionIndex:n,sectionVariantIndex:s,rawSections:a,parsedSections:o,decofile:i,activePageKey:l,pageVariants:d,variantIndex:E}=ne.current;if(n===null||!l)return;let h=null;const x=await In(t,i,P=>{const pe=a[n],ue=o[n];if(!pe||!ue?.isMultivariate)return null;const be=st(pe,ue);if(!be)return null;const z=be.variants??[];h=bt(z[s]?.rule,i,u);const H=[...a];return H[n]=Kt(pe,ue,vs(be,s,P)),{blockKey:l,data:an(i,l,H,E,d)}});if(!x)return;const{resolveType:j,formValue:I}=qt(x.rule,x.projected,u??void 0);Ge(j),Le(I),h&&await kt(h,x.projected),k?.()},_o=async t=>{yt();const{selectedSectionIndex:n,sectionVariantIndex:s,rawSections:a,parsedSections:o,decofile:i,activePageKey:l,pageVariants:d,variantIndex:E}=ne.current;if(n===null||!l)return;const h=a[n],x=o[n];if(!h||!x?.isMultivariate)return;const j=st(h,x);if(!j)return;const I=j.variants??[],P=bt(I[s]?.rule,i,u),pe=ln(t),ue=vs(j,s,pe),be=[...a];be[n]=Kt(h,x,ue);const z=an(i,l,be,E,d),H={...i,[l]:z},{resolveType:re,formValue:he}=qt(pe,H,u??void 0);Ge(re),Le(he);try{await D.mutateAsync({blockKey:l,data:z}),P&&P!==t&&await kt(P,H),k?.()}catch(Ae){q.error(c("sectionsEditor.sectionsEditor.couldNotApplySavedRule"),{description:Mt(c,Bt(Ae))})}};if(!$&&!se)return r.jsx("div",{className:"h-full w-full flex items-center justify-center text-sm text-muted-foreground",children:c("sectionsEditor.sectionsEditor.noPageFound",{currentPath:V})});if($&&!Kn)return r.jsx("div",{className:"h-full w-full flex items-center justify-center text-sm text-muted-foreground",children:c("sectionsEditor.sectionsEditor.globalBlockNotFound")});const je=m!==null?ce[m]??null:null,Sr=m!==null?M[m]:null,yr=Sr&&je?.isMultivariate?st(Sr,je):null,At=yr?qr(yr,we):[],Ln=Math.min(Ie,Math.max(At.length-1,0)),jt=At[Ln]??null,Nt=je?.isMultivariate===!0,us=m!==null&&je!==null,Ct=us&&(Nt||!!(Fn&&et)),ko=Ct&&!$&&je?.isSavedBlock===!0,mt=$||ko,br=$?Hs:je?.label??"",wo=Qt&&u?Gn(Qt,u):null,xr=(t,n)=>n&&X?`${t} · ${n}`:t,_r=je?je.variantOf??je.label:"",jo=(()=>{const t=Nt&&jt?jt.label:null;return t?X?[xr(_r,t)]:[je.label,t]:[je?.label??""]})(),ds=xr(se?.name??"",St?ye?.label:null),On=Ct&&(!$||O.length>0)?$?[Hs,...O]:[ds,...jo,...O]:[],kr=Te&&se?[se.name,"SEO",...Ps]:[],wr=c("sectionsEditor.pageVariantTabs.variantsLabel"),jr=Zt&&se?[se.name,wr]:Ft&&se&&je?[ds,_r,wr]:[],zn=jr.length>0?jr:kr.length>0?kr:mt?On.length>0?On:[br]:On.length>0?On:[ds],Rr=us&&!Nt&&!je?.isHidden&&!!g,Ro=mt||!$&&St&&!!ye||Rr,Eo=us&&!Nt&&!$&&O.length===0&&!!je&&Ra(je)&&!!g,Vo=X&&Ct&&!Ft&&Nt&&O.length===0&&!!jt,Er=X&&O.length>0?na(O[O.length-1]):null,To=O.length>1?na(O[O.length-2]):null,Vr=mt?br:Ct?je?.label??"":se?.name??"",Ao=Zt||Ft?c("sectionsEditor.pageVariantTabs.variantsLabel"):Te?c("sectionsEditor.panelSections.seo"):Er??Vr,Tr=Ft?je?.variantOf??je?.label??"":Zt||Te?se?.name??"":Er?To??Vr:mt?c("sectionsEditor.sectionsEditor.globalSectionSubtitle"):Ct?se?.name??"":se?.path??"",fs=!Zt&&!Ft&&!Te&&!Ct&&!mt,No=!X&&!Te&&!$&&Nt&&O.length===0,bn=()=>{if(!g)return;yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const t=f[g],n=Cl(t.sections,M,u,_);if(!n)return;const{sections:s,newVariantIndex:a}=n;D.mutate({blockKey:g,data:{...t,sections:s}},{onSuccess:()=>{fe(a),L(null),A(null),W(null),N([]),Y(null),ee(null)},onError:D.reportError})},$n=(t,n,s)=>{if(!g)return;yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const a=f[g],o=a.sections;if(!o||typeof o!="object"||Array.isArray(o))return;const i=o;if(!Array.isArray(i.variants))return;const l=t([...i.variants]);if(!l)return;const d=Bl(i,l),E={...f,[g]:{...a,sections:d}};D.mutate({blockKey:g,data:E[g]},{onSuccess:()=>{n?.();const h=typeof s=="string"?[s]:s??[];(async()=>{for(const x of h)await kt(x,E)})()},onError:D.reportError})},Ar=(t,n)=>{if(t===n)return;let s=J;J===t?s=n:t<J&&n>=J?s=J-1:t>J&&n<=J&&(s=J+1),fe(s);const a=Zn(le.map(o=>({rule:o.rule})),t,n);rs(a,s),$n(o=>Zn(o,t,n))},Nr=t=>{const n=le[t]?.rule,s=bt(n,f??{},u??void 0);$n(a=>a.length<=1?null:(a.splice(t,1),a),()=>{le.length-1===1?fe(0):t<J?fe(J-1):t===J&&fe(Math.max(0,t-1)),L(null),A(null),W(null),N([]),Y(null),ee(null)},s)},Co=()=>{const t=le.map((n,s)=>({variant:n,index:s})).filter(({variant:n})=>!pi(n.rule)).map(({variant:n})=>bt(n.rule,f??{},u??void 0)).filter(n=>!!n);$n(n=>{const s=Ai({variants:n}),a=n[s];return a?[{...a,rule:Ni(u)}]:null},()=>{fe(0),L(null),A(null),W(null),N([]),Y(null),ee(null),Tn(!1)},t)},Cr=t=>{let n=t+1;$n(s=>(n=Yr(s,t,_),Fl(s,t,_)),()=>{fe(n),L(null),A(null),W(null),N([]),Y(null),ee(null)})},Po=async(t,n)=>{yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const s=ne.current.activePageKey,a=ne.current.decofile;if(!s)return;const o=a[s],i=o.sections;if(!i||typeof i!="object"||Array.isArray(i))return;const l=i;if(!Array.isArray(l.variants))return;const d=[...l.variants],E=d[t];if(!E?.rule||typeof E.rule!="object"){q.error(c("sectionsEditor.sectionsEditor.variantHasNoMatcherRule"));return}const h=E.rule,x=n.trim();en(!0);try{if(!x){if(!Gt(h,a,u)){Ve(null);return}const z=h.__resolveType??"";d[t]={...E,rule:ks(h,a,u)};const H={...a,[s]:{...o,sections:{...l,variants:d}}};await D.mutateAsync({blockKey:s,data:H[s]}),await kt(z,H),Ve(null),k?.();return}const j=ws(h,a,u);if(!j){q.error(c("sectionsEditor.sectionsEditor.couldNotReadVariantMatcherRule"));return}if(j.blockKey){await D.mutateAsync({blockKey:j.blockKey,data:Dt(j.resolveType,j.data,x)}),Ve(null),k?.();return}const I=Un(x),P=Yn(I,a,u);if(P){q.error(P);return}const pe=Dt(j.resolveType,j.data,x);let ue=null,be=!1;try{const z=await D.mutateAsync({blockKey:I,data:pe,create:!0});be=qn(z),ue=be?null:I,d[t]={...E,rule:ln(I)},await D.mutateAsync({blockKey:s,data:{...o,sections:{...l,variants:d}}}),ue=null}catch(z){throw ue&&await Cn.mutateAsync({blockKey:ue}).catch(()=>{}),z}Ve(null),be||q.success(c("sectionsEditor.sectionsEditor.savedMatcherAsGlobalBlock",{trimmed:x})),k?.()}catch(j){q.error(c("sectionsEditor.sectionsEditor.failedToRenameVariant"),{description:Mt(c,Bt(j))})}finally{en(!1)}},Ko=async(t,n)=>{yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const{selectedSectionIndex:s,rawSections:a,parsedSections:o,decofile:i,activePageKey:l,pageVariants:d,variantIndex:E}=ne.current;if(s===null||!l)return;const h=a[s],x=o[s];if(!h||!x?.isMultivariate)return;const j=st(h,x);if(!j)return;const I=j.variants??[],P=I[t];if(!P?.rule||typeof P.rule!="object"){q.error(c("sectionsEditor.sectionsEditor.variantHasNoMatcherRule"));return}const pe=P.rule,ue=n.trim();en(!0);const be=async z=>{const H={...j,variants:z},re=[...a];re[s]=Kt(h,x,H);const he=an(i,l,re,E,d);return await D.mutateAsync({blockKey:l,data:he}),{...i,[l]:he}};try{if(!ue){if(!Gt(pe,i,u)){nt(null);return}const pt=pe.__resolveType??"",Xe=[...I];Xe[t]={...P,rule:ks(pe,i,u)};const Pt=await be(Xe);await kt(pt,Pt),nt(null),k?.();return}const z=ws(pe,i,u);if(!z){q.error(c("sectionsEditor.sectionsEditor.couldNotReadVariantMatcherRule"));return}if(z.blockKey){await D.mutateAsync({blockKey:z.blockKey,data:Dt(z.resolveType,z.data,ue)}),nt(null),k?.();return}const H=Un(ue),re=Yn(H,i,u);if(re){q.error(re);return}const he=Dt(z.resolveType,z.data,ue);let Ae=null,sn=!1;try{const pt=await D.mutateAsync({blockKey:H,data:he,create:!0});sn=qn(pt),Ae=sn?null:H;const Xe=[...I];Xe[t]={...P,rule:ln(H)},await be(Xe),Ae=null}catch(pt){throw Ae&&await Cn.mutateAsync({blockKey:Ae}).catch(()=>{}),pt}nt(null),sn||q.success(c("sectionsEditor.sectionsEditor.savedMatcherAsGlobalBlock",{trimmed:ue})),k?.()}catch(z){q.error(c("sectionsEditor.sectionsEditor.failedToRenameVariant"),{description:Mt(c,Bt(z))})}finally{en(!1)}},Pr=async(t,n,s)=>{A(s);try{await D.mutateAsync({blockKey:t,data:s})}catch(a){throw A(o=>o===s?n:o),a}},Mo={rename:async(t,n,s)=>{yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const{activePageKey:a,decofile:o}=ne.current;if(!a)return;const i=Array.isArray(t.variants)?[...t.variants]:[],l=i[n],d=l?.rule&&typeof l.rule=="object"?l.rule:void 0,E=async x=>{const j={...t,variants:x};return await Pr(a,t,j),{...o,[a]:j}},h=wc(d,s,o,u);if(h.kind!=="noop"){if(h.kind==="error"){q.error(h.reason==="no-matcher-rule"?c("sectionsEditor.sectionsEditor.variantHasNoMatcherRule"):h.reason==="unreadable-rule"?c("sectionsEditor.sectionsEditor.couldNotReadVariantMatcherRule"):h.message??c("sectionsEditor.sectionsEditor.failedToRenameVariant"));return}en(!0);try{if(h.kind==="inline"){const I=[...i];I[n]={...l,rule:h.inlinedRule};const P=await E(I);await kt(h.blockKey,P),k?.();return}if(h.kind==="updateBlock"){await D.mutateAsync({blockKey:h.blockKey,data:h.blockData}),k?.();return}let x=null,j=!1;try{const I=await D.mutateAsync({blockKey:h.blockId,data:h.blockData,create:!0});j=qn(I),x=j?null:h.blockId;const P=[...i];P[n]={...l,rule:h.reference},await E(P),x=null}catch(I){throw x&&await Cn.mutateAsync({blockKey:x}).catch(()=>{}),I}j||q.success(c("sectionsEditor.sectionsEditor.savedMatcherAsGlobalBlock",{trimmed:s.trim()})),k?.()}catch(x){q.error(c("sectionsEditor.sectionsEditor.failedToRenameVariant"),{description:Mt(c,Bt(x))})}finally{en(!1)}}},selectGlobal:async(t,n,s)=>{yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const{activePageKey:a,decofile:o}=ne.current;if(!a)return;const i=Array.isArray(t.variants)?[...t.variants]:[],l=i[n];if(!l)return;const d=bt(l.rule,o,u);i[n]={...l,rule:ln(s)};const E={...t,variants:i},h={...o,[a]:E};try{await Pr(a,t,E),d&&d!==s&&await kt(d,h),k?.()}catch(x){q.error(c("sectionsEditor.sectionsEditor.couldNotApplySavedRule"),{description:Mt(c,Bt(x))})}},selectNamedRule:async(t,n,s)=>{yt(),C.current&&(clearTimeout(C.current),C.current=null),Se.current.clear();const{activePageKey:a,decofile:o}=ne.current;if(!a)return;let i=null,l=null;const d=await In(s,o,E=>{const h=Array.isArray(t.variants)?[...t.variants]:[],x=h[n];return x?(i=bt(x.rule,o,u),h[n]={...x,rule:E},l={...t,variants:h},{blockKey:a,data:l}):null});!d||!l||(A(l),i&&await kt(i,d.projected),k?.())}},Kr=()=>{$t()},Mr=t=>{un(t),is({inner:t})},Br=t=>{Nn(t),is({raw:t})},Dr=()=>{un(null),It([])},Fr=()=>Jt(t=>t+1),Ir=()=>{dn.flush(),cn(!1),un(null),Nn(void 0),It([]),Jt(t=>t+1),ge?.()},Bo=()=>{Tn(!1),An(!1),L(null),cn(!0)},Do=()=>{Te&&Ir(),L(null),Tn(!0)},Fo=()=>An(!0),ms=t=>{if(Zt&&t===0){Tn(!1);return}if(Ft&&t<2){An(!1),t===0&&L(null);return}if(Te){if(t===0){Ir();return}if(t===1){It([]),Jt(s=>s+1);return}It(Ps.slice(0,t-1)),Jt(s=>s+1);return}if($){N(O.slice(0,t)),T(s=>s+1);return}if(t===0){Kr();return}if(t===1){N([]),T(s=>s+1);return}const n=!X&&Nt&&jt?1:0;if(n===1&&t===2){N([]),T(s=>s+1);return}N(O.slice(0,t-1-n))},ps=zn.length>1?r.jsx("button",{type:"button",onClick:()=>ms(ol(zn.length,{isMultivariateSectionTop:No})),title:c("sectionsEditor.sectionsEditor.back"),"aria-label":c("sectionsEditor.sectionsEditor.back"),className:ae("shrink-0 inline-flex size-6 items-center justify-center rounded-[var(--studio-control-radius,var(--radius-md))] transition-colors",mt?"text-foreground/80 hover:bg-global-section/15":"text-muted-foreground hover:bg-accent hover:text-accent-foreground"),children:r.jsx(dl,{className:"size-4"})}):null,Io=mt||Ct||Te?Ro&&r.jsxs("div",{className:ae("border-b px-3 py-2.5",mt&&"border-global-section/22 bg-global-section/12 dark:bg-global-section/16"),children:[r.jsxs("div",{className:"flex min-w-0 items-center gap-2 overflow-hidden",children:[!$&&St&&ye&&r.jsxs("button",{type:"button",onClick:Kr,title:c("sectionsEditor.sectionsEditor.editingInVariant",{variant:ye.label}),className:ae("shrink-0 inline-flex items-center gap-1 rounded-lg h-6 px-1.5 text-xs font-medium cursor-pointer transition-opacity hover:opacity-80",Ji),children:[r.jsx(Zi,{rule:xs(ye.rule,f??{},u??void 0),matchers:nn}),r.jsx("span",{className:"max-w-[160px] truncate",children:ye.label})]}),r.jsx("div",{className:"flex-1"}),mt&&r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx("span",{className:"shrink-0 cursor-help",children:r.jsx(Jn,{className:"size-4 text-global-section-fg dark:text-global-section-fg-dark"})})}),r.jsx(Tt,{side:"bottom",className:"max-w-[260px]",children:c("sectionsEditor.sectionsEditor.globalSectionTooltip")})]}),Rr&&r.jsx(Wn,{onClick:()=>yn()})]}),mt&&r.jsx("p",{className:"mt-1.5 py-1.5 pl-1 text-sm leading-snug text-foreground",children:c("sectionsEditor.sectionsEditor.globalSectionBanner")})]}):r.jsxs("div",{className:"flex items-center gap-2 border-b px-3 py-2.5",children:[r.jsx("div",{className:"flex-1 min-w-0",children:r.jsx(sa,{pageKey:g,initialName:se.name,initialPath:se.path,onFieldChange:rr,variant:"header"})}),r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx(Ut,{type:"button",variant:"ghost",size:"icon-sm","aria-label":c("sectionsEditor.sectionsEditor.editSeo"),className:"shrink-0",onClick:()=>cn(!0),children:r.jsx(da,{size:14})})}),r.jsx(Tt,{side:"bottom",children:c("sectionsEditor.sectionsEditor.editSeo")})]}),r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx(Ut,{type:"button",variant:"ghost",size:"icon-sm","aria-label":c("sectionsEditor.sectionsEditor.viewJson"),className:"shrink-0",onClick:()=>Oe&&g?Oe():Xn(!0),children:r.jsx(fa,{size:14})})}),r.jsx(Tt,{side:"bottom",children:c("sectionsEditor.sectionsEditor.viewJson")})]}),r.jsx(Wn,{onClick:bn})]}),Lo=r.jsxs(r.Fragment,{children:[St&&g&&r.jsx(ra,{listKey:g,variants:le,activeIndex:J,decofile:f??{},meta:u,matchers:nn,onSelect:hn,onReorder:Ar,onRename:Ve,onDuplicate:Cr,onDelete:Nr,onAdd:bn}),St&&Z!==null&&r.jsx(aa,{className:"mt-3",children:r.jsx("div",{className:ae("space-y-3",Xt&&"pointer-events-none opacity-50"),children:r.jsx(ys,{currentRt:Z,currentLabel:kn(ye?.rule,f??{},we,u??void 0),currentGlobalKey:bt(ye?.rule,f??{},u??void 0)??void 0,matchers:nn,globals:ls,onSelect:fr,onSelectGlobal:gr,named:cs(ye?.rule,hr),namedRow:bs(ye?.rule,Ht),rule:ye?.rule,schema:ur,formValue:De,onChange:mr,formKey:`${J}:${Z??""}`,formWrapperClassName:"space-y-3",meta:u??void 0,decofile:f,onSaveReferencedBlock:fn,sandbox:gn})})})]}),Lr=r.jsxs(r.Fragment,{children:[r.jsx(Qi,{listKey:`${g??""}:${m??""}`,variants:At.map((t,n)=>({index:n,label:t.label})),selectedIndex:Ln,onSelect:or,onRename:nt,onDuplicate:go,onDelete:ho,onRemoveAll:ir,onReorder:vo,onAdd:()=>yn()}),r.jsx(aa,{children:r.jsx(ys,{currentRt:Qt??"",currentLabel:kn(jt?.rule,f??{},we,u??void 0),currentGlobalKey:bt(jt?.rule,f??{},u??void 0)??void 0,matchers:nn,globals:ls,onSelect:yo,onSelectGlobal:_o,named:cs(jt?.rule,xo),namedRow:bs(jt?.rule,Ht),rule:jt?.rule,schema:wo,formValue:Ba,onChange:bo,formKey:`${m??"none"}:${Ln}:${Qt??""}`,formWrapperClassName:"pt-1",meta:u??void 0,decofile:f,onSaveReferencedBlock:fn,sandbox:gn})})]}),Or=r.jsx("div",{className:ae(X?"px-2":"p-2 pt-3"),children:r.jsx(_c,{listKey:`${g??""}-${J}`,rawSections:M,sections:ce,meta:u,decofile:f,selectedIndex:m,onSelect:ao,onReorder:oo,onDelete:io,onDuplicate:lo,onMakeReusable:G,onToggleHidden:co,onToggleLazy:ot?uo:void 0,onAddVariant:yn,onDetach:fo,onAddSection:()=>Yt(!0),canAddSection:cr})}),Oo=r.jsxs("div",{className:"min-w-0 max-w-full space-y-4 overflow-x-hidden px-3",children:[g&&se&&r.jsx(sa,{pageKey:g,initialName:se.name,initialPath:se.path,onFieldChange:rr}),Ot&&g?r.jsx(ya,{rawSeo:Mn,innerSeo:ss,defaultResolveType:qs,seoTypesLoading:_&&!u,seoSchema:Gs,activeResolveType:Bn,seoTypeOptions:Ws,formResetKey:Ks,siteDefaultSeo:Us,onBreadcrumbChange:It,onPersistRaw:Br,onInnerChange:Mr,onClearForm:Dr,onBumpFormKey:Fr,asyncRenderAvailable:ot}):r.jsx("div",{className:"px-3 py-6 text-center text-xs text-muted-foreground",children:c("sectionsEditor.sectionsEditor.seoSchemaNotFound")})]}),zo=r.jsx(on,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:r.jsx("div",{className:"min-w-0 max-w-full overflow-x-hidden px-6 py-4",children:r.jsx("div",{className:"mx-auto max-w-2xl",children:Ot&&g?r.jsx(ya,{rawSeo:Mn,innerSeo:ss,defaultResolveType:qs,seoTypesLoading:_&&!u,seoSchema:Gs,activeResolveType:Bn,seoTypeOptions:Ws,formResetKey:Ks,siteDefaultSeo:Us,onBreadcrumbChange:It,onPersistRaw:Br,onInnerChange:Mr,onClearForm:Dr,onBumpFormKey:Fr,asyncRenderAvailable:ot}):r.jsx("div",{className:"px-3 py-6 text-center text-xs text-muted-foreground",children:c("sectionsEditor.sectionsEditor.seoSchemaNotFound")})})})},"editor-seo"),$o=r.jsxs(on,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:[St&&g&&r.jsx(ra,{listKey:g,variants:le,activeIndex:J,decofile:f??{},meta:u,matchers:nn,onSelect:hn,onReorder:Ar,onRename:Ve,onDuplicate:Cr,onDelete:Nr,onAdd:bn}),St&&Z!==null&&r.jsxs("div",{className:ae("px-3 border-b",Vn?"pt-3 pb-5 space-y-3":"py-2"),children:[r.jsxs("button",{type:"button",onClick:()=>Ka(t=>!t),className:"flex w-full items-center justify-between gap-2 text-left cursor-pointer rounded-[var(--studio-control-radius,var(--radius-sm))] py-0.5 hover:bg-accent","aria-expanded":Vn,children:[r.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:c("sectionsEditor.sectionsEditor.variantRule")}),Vn?r.jsx(ll,{className:"size-3.5 shrink-0 text-muted-foreground"}):r.jsx(cl,{className:"size-3.5 shrink-0 text-muted-foreground"})]}),Vn&&r.jsx("div",{className:ae("space-y-3",Xt&&"pointer-events-none opacity-50"),children:r.jsx(ys,{currentRt:Z,currentLabel:kn(ye?.rule,f??{},we,u??void 0),currentGlobalKey:bt(ye?.rule,f??{},u??void 0)??void 0,matchers:nn,globals:ls,onSelect:fr,onSelectGlobal:gr,named:cs(ye?.rule,hr),namedRow:bs(ye?.rule,Ht),rule:ye?.rule,schema:ur,formValue:De,onChange:mr,formKey:`${J}:${Z??""}`,formWrapperClassName:"space-y-3",meta:u??void 0,decofile:f,onSaveReferencedBlock:fn,sandbox:gn})})]}),Or]},"editor-section-list");return r.jsx(Xi,{value:_,children:r.jsx(el,{children:r.jsxs("div",{className:"flex h-full min-w-0 w-full flex-col",children:[!X&&ps&&r.jsx("div",{className:"flex min-w-0 shrink-0 items-center gap-2 px-3 py-2",children:ps}),(X||zn.length>1)&&r.jsx(tl,{crumbs:zn,onSelect:ms,onSelectRoot:()=>{dn.flush(),Ue?Ue():ms(0)}}),r.jsx("div",{className:"shrink-0",children:X?r.jsxs("div",{className:ae("flex items-center gap-2 border-b px-3 py-2.5",mt&&"border-global-section/22 bg-global-section/12 dark:bg-global-section/16"),children:[X&&ps,mt&&r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx("span",{className:"shrink-0 cursor-help",children:r.jsx(Jn,{className:"size-4 text-global-section-fg dark:text-global-section-fg-dark"})})}),r.jsx(Tt,{side:"bottom",className:"max-w-[260px]",children:c("sectionsEditor.sectionsEditor.globalSectionTooltip")})]}),r.jsxs("div",{className:"flex min-w-0 flex-1 flex-col leading-tight",children:[r.jsx("span",{className:"truncate text-sm font-semibold",children:Ao}),Tr&&r.jsx("span",{className:"truncate text-xs text-muted-foreground",children:Tr})]}),fs&&St&&ye&&r.jsx(oa,{variants:le,activeIndex:J,onSelect:hn,onManage:Do,onRemoveAll:Co}),Vo&&r.jsx(oa,{variants:At,activeIndex:Ln,onSelect:or,onManage:Fo,onRemoveAll:ir}),fs&&!St&&r.jsx(Wn,{onClick:bn}),Eo&&r.jsx(Wn,{onClick:()=>yn()}),r.jsx(nl,{}),fs&&r.jsxs(r.Fragment,{children:[r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx(Ut,{type:"button",variant:"outline",size:"icon-sm","aria-label":c("sectionsEditor.sectionsEditor.editSeo"),className:"shrink-0",onClick:Bo,children:r.jsx(da,{size:14})})}),r.jsx(Tt,{side:"bottom",children:c("sectionsEditor.sectionsEditor.editSeo")})]}),!Oe&&r.jsxs(Et,{children:[r.jsx(Vt,{asChild:!0,children:r.jsx(Ut,{type:"button",variant:"outline",size:"icon-sm","aria-label":c("sectionsEditor.sectionsEditor.viewJson"),className:"shrink-0",onClick:()=>Xn(!0),children:r.jsx(fa,{size:14})})}),r.jsx(Tt,{side:"bottom",children:c("sectionsEditor.sectionsEditor.viewJson")})]})]})]}):Io}),dt&&r.jsx(si,{open:!0,fields:ri(dt.plan,dt.target.schema),choices:dt.choices,changedAgain:dt.changedAgain,author:$s??null,authorPending:$s===void 0,fieldsAsLabeled:zs!==null,fresh:dt.fresh,onChoose:(t,n)=>ro({...dt.choices,[t]:n}),onApply:so},Ec(dt.formBase)),Ft?r.jsx(ia,{onAdd:()=>yn(),children:Lr},"editor-section-variants"):Ct?r.jsxs(on,{viewportRef:me,onBlur:Xs,className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:[!X&&Nt&&At.length>0&&O.length===0&&Lr,r.jsx(pa,{value:pr,children:r.jsx(la,{value:$&&_?Be:null,children:r.jsx(ca,{activeSchema:Fn,formValue:et,formResetKey:Je,onFormChange:sr,onBreadcrumbChange:N,breadcrumbPath:O,emptyMessage:c("sectionsEditor.sectionsEditor.noEditableFieldsForVariant"),meta:u,decofile:f,onSaveReferencedBlock:fn,sandbox:gn,previewBaseUrl:at,onRequestAddSection:ar,onVariantMatcherOp:$?Mo:void 0})})})]},"editor-section-form"):$?r.jsx(on,{viewportRef:me,onBlur:Xs,className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:r.jsx(pa,{value:pr,children:r.jsx(la,{value:$&&_?Be:null,children:r.jsx(ca,{activeSchema:Fn,formValue:et,formResetKey:Je,onFormChange:sr,onBreadcrumbChange:N,breadcrumbPath:O,emptyMessage:c("sectionsEditor.sectionsEditor.noEditableFieldsForGlobalBlock"),meta:u,decofile:f,onSaveReferencedBlock:fn,sandbox:gn,previewBaseUrl:at,onRequestAddSection:ar})})})},"editor-global-block"):Te?X?r.jsx(on,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:r.jsx("div",{className:"p-3",children:Oo})},"editor-seo"):zo:Zt?r.jsx(ia,{onAdd:bn,children:Lo},"editor-variants"):X?r.jsxs("div",{className:"flex min-h-0 flex-1 flex-col",children:[r.jsx(on,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:r.jsx("div",{className:"py-2",children:Or})}),r.jsx("div",{className:"shrink-0 border-t p-2",children:r.jsx(Es,{canAddSection:cr,onAddSection:()=>Yt(!0)})})]},"editor-section-list"):$o,r.jsx(sl,{open:Fe!==null,onOpenChange:t=>{t||G(null)},defaultBlockId:Fe!==null?Un(ce[Fe]?.label??""):"",isPending:D.isPending,onSubmit:So}),it&&r.jsx(nc,{open:Pa,onOpenChange:t=>{Yt(t),t||(En.current=null)},meta:u,decofile:f,previewBaseUrl:at,onSelect:po}),Ts&&g&&f&&r.jsx(El,{open:Ts,onOpenChange:Xn,pageKey:g,decofile:f}),ie!==null&&r.jsx(ua,{open:!0,initialName:Gt(le[ie]?.rule,f??{},u??void 0)?kn(le[ie]?.rule,f??{},we,u??void 0):"",autoLabel:we(xs(le[ie]?.rule,f??{},u??void 0)),isPending:Xt,onSubmit:async t=>{await Po(ie,t)},onOpenChange:t=>{!t&&!Xt&&Ve(null)}}),Qe!==null&&r.jsx(ua,{open:!0,initialName:Gt(At[Qe]?.rule,f??{},u??void 0)?kn(At[Qe]?.rule,f??{},we,u??void 0):"",autoLabel:we(xs(At[Qe]?.rule,f??{},u??void 0)),isPending:Xt,onSubmit:async t=>{await Ko(Qe,t)},onOpenChange:t=>{!t&&!Xt&&nt(null)}})]})})})}export{lf as SectionsEditor};
@@ -1 +0,0 @@
1
- import{c as T,b as Se,j as o,r as M,ay as Te,B as Ce,h as Re}from"./index-C8YP0XfX.js";import{a2 as ye}from"./agent-icon-B7Q7dFXY.js";import{S as ge}from"./scroll-area-BSd3TrLZ.js";import{I as be,ac as Fe,i as Ke,k as ze,ad as De,h as $e,aE as Ie}from"./held-block-view-BCUOCB3X.js";import{k as Be}from"./parse-sections-B8Xcvgnu.js";import{u as Le,a as Oe,P as Ue}from"./page-seo-form-DcpwPyQd.js";import{c as Ae,b as Me}from"./blocks-tab-states-BUek9Urr.js";import{a as ke}from"./Image01-DtpDUrwF.js";import{u as Ge,m as He}from"./site-editor-toast-D9ddy9a_.js";import"./AlertCircle-C0U53qC5.js";import"./Tool01-CTKnipD_.js";import"./ArrowUp-BnowdRj-.js";import"./ArrowLeft-BVJNIiuT.js";import"./LinkBroken01-BZrnscWF.js";import"./ShoppingBag01-BaMIB-e_.js";import"./ZoomOut-BVuJZ-2t.js";import"./Building02-CcI-P3yL.js";import"./CheckCircle-fAPMl2yd.js";import"./ChevronUp-BMY88wXt.js";import"./ChevronSelectorVertical-C-CIIDml.js";import"./UserSquare-D4xudMmb.js";import"./Copy01-DGy0Absz.js";import"./CreditCard01-DsjBhiEj.js";import"./DotsVertical-Bfe9a_On.js";import"./Globe04-B-sNlZxN.js";import"./SwitchHorizontal01-fMsLFMs0.js";import"./Key01-DifqnYu0.js";import"./Link01-oZZyGItc.js";import"./Minus-Dc5wow6R.js";import"./Monitor01-Bmn1BV5T.js";import"./Sun-BZlKwpGn.js";import"./Play-IViIK9Vy.js";import"./Plus-Bh_xMwh7.js";import"./SearchMd-DB3np2ti.js";import"./Trash01-BqP8uw7k.js";import"./Upload01-CpPArzNK.js";import"./Users01-buCmBl1X.js";import"./XClose-D48r2tDo.js";import"./index-BdQq_4o_.js";import"./utils-Chh_XkCj.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./pair-DEJAc3iG.js";import"./collapsible-B5J2aUd-.js";import"./use-copy-BCht-61u.js";import"./usage-stats-CNcWehA3.js";import"./tool-namespace-ChbHxLTp.js";import"./form-DmKuBQlJ.js";import"./label-BZDtWIcv.js";import"./utils-CVEq3hMx.js";import"./markdown-DuoP9xIE.js";import"./location-V0VwTJTt.js";import"./use-mobile-tv6dKHC3.js";import"./use-panel-navigate-CTWNyrxK.js";import"./thread-route-JcxEqRgq.js";import"./use-project-scope-BgLQY0Uk.js";import"./repository-binding-B-4PI1n3.js";import"./use-mcp-client-CkAT8dMu.js";import"./auth-fndLm_KR.js";import"./tooltip-CJHeHoSn.js";import"./index-B0Rg86vv.js";import"./use-decopilot-events-hbubA99f.js";import"./thread-intent-Cl7xa7dA.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./watch-sse-pool-B-0VhxE7.js";import"./task-board-u5TablbK.js";import"./schema-CFje17_E.js";import"./slugify-CEUa2lfQ.js";import"./chat-context-BI1yxU4R.js";import"./autosend-VKc1dW3G.js";import"./use-ai-providers-DzWzPq_c.js";import"./use-organization-settings-6EqlUT2Y.js";import"./use-clock-tick-DxI4Q15z.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-DWv_y82s.js";import"./types-Cwtot2FB.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./shell-layout-uDYSTXA5.js";import"./command-jlI8eprh.js";import"./index-BM9HifS6.js";import"./integration-icon-03FWmed-.js";import"./project-icon-BSrEdWN1.js";import"./new-project-dialog-BuE_SqTn.js";import"./repository-import-picker-BfMMau5M.js";import"./use-navigate-to-agent-BiKQMaG5.js";import"./repository-picker-CbWFb7rK.js";import"./useInfiniteQuery-LBIaZPt-.js";import"./infiniteQueryObserver-C8Tx1h_G.js";import"./collection-search-B_n3Ea8A.js";import"./use-debounced-value-ZtANdTDD.js";import"./required-auth-layout-ofmCqqpc.js";import"./use-org-sso-BK4EESlq.js";import"./sheet-ko7a2Uwq.js";import"./use-connection-ClhLV4Ep.js";import"./use-mcp-prompts-BoifdA0D.js";import"./use-thread-outputs-am5Vd3rC.js";import"./file-type-icon-CLdhbOMq.js";import"./section-array-field-CWeYHp0D.js";import"./alert-CHj-Usrj.js";import"./switch-DbWQrL2t.js";import"./textarea-BeCs38v-.js";import"./popover-C0DIKe_3.js";import"./monaco-editor-a3IVCcn2.js";import"./editor-CVSwKg6T.js";import"./calendar-BZJL1q0i.js";import"./select-EVDcG5Hl.js";import"./editor-classes-Dkk1S2M6.js";import"./core.esm-CfGX-VCE.js";import"./sortable.esm-Bk2g_Gbz.js";import"./toggle-group-CWnjwOku.js";import"./active-indicator-CCMhAsc_.js";import"./combobox-BBB78IeP.js";import"./search-input-CIT_dMpA.js";import"./tabs-BbA4-8ma.js";import"./use-file-configs-DI3WjDeq.js";import"./asset-utils-BvYMWLJK.js";import"./match-site-slug-config-D3fUJ6vX.js";import"./use-session-runtime-pkeEtIbf.js";import"./sandbox-git-api-DcqI6XE4.js";import"./sandbox-url-D3mC8qhT.js";import"./slider-Bg5y5q23.js";import"./index-Dc2A9bLg.js";import"./tooltipContext-CL92GCVz.js";import"./CategoricalChart-CukPvNkf.js";import"./index-CzZ16hae.js";import"./ActiveShapeUtils-CUGYcOGt.js";import"./Sector-BbL3mZ4i.js";import"./symbol-DLC3ejqz.js";import"./empty-state-CUanQ9Sm.js";import"./experiments-tab-choice-D5E9lbe8.js";import"./use-sandbox-events-Ccm6tkYH.js";function G(d){return typeof d=="string"&&d.trim()?d:void 0}function je(d,e){if(d){if(e)try{const t=new URL(d,e).href;return be(t)}catch{return}return be(d)}}function Ve(d){if(!d)return{};const e=G(d.title),t=G(d.titleTemplate);return{title:e&&t?.includes("%s")?t.replace(/%s/g,e):e,description:G(d.description),image:G(d.image),favicon:G(d.favicon)}}function We(d){if(!d)return"example.com";try{return new URL(d).host}catch{return"example.com"}}const qe=[{id:"google",labelKey:"sectionsEditor.seoPreview.platformGoogle",color:"#4285F4",layout:"search"},{id:"facebook",labelKey:"sectionsEditor.seoPreview.platformFacebook",color:"#1877F2",layout:"card"},{id:"twitter",labelKey:"sectionsEditor.seoPreview.platformTwitter",color:"#0f1419",layout:"card"},{id:"linkedin",labelKey:"sectionsEditor.seoPreview.platformLinkedin",color:"#0A66C2",layout:"card"},{id:"whatsapp",labelKey:"sectionsEditor.seoPreview.platformWhatsapp",color:"#25D366",layout:"chat"},{id:"telegram",labelKey:"sectionsEditor.seoPreview.platformTelegram",color:"#229ED9",layout:"chat"},{id:"slack",labelKey:"sectionsEditor.seoPreview.platformSlack",color:"#611f69",layout:"attachment"},{id:"discord",labelKey:"sectionsEditor.seoPreview.platformDiscord",color:"#5865F2",layout:"attachment"}];function he(d){const e=T.c(10),{src:t,className:r,iconSize:x}=d,a=x===void 0?20:x;if(t){let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m={objectFit:"cover"},e[0]=m):m=e[0];let p;return e[1]!==r||e[2]!==t?(p=o.jsx("img",{src:t,alt:"",referrerPolicy:"no-referrer",className:r,style:m}),e[1]=r,e[2]=t,e[3]=p):p=e[3],p}let s;e[4]===Symbol.for("react.memo_cache_sentinel")?(s={display:"flex",alignItems:"center",justifyContent:"center",background:"#e5e7eb",color:"#9ca3af"},e[4]=s):s=e[4];let i;e[5]!==a?(i=o.jsx(ke,{size:a}),e[5]=a,e[6]=i):i=e[6];let n;return e[7]!==r||e[8]!==i?(n=o.jsx("div",{className:r,style:s,children:i}),e[7]=r,e[8]=i,e[9]=n):n=e[9],n}function Je(d){const e=T.c(33),{seo:t,host:r,path:x,t:a}=d;let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s={background:"#fff",border:"1px solid #dadce0"},e[0]=s):s=e[0];let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i={background:"#f1f3f4"},e[1]=i):i=e[1];let n;e[2]!==t.favicon?(n=o.jsx("div",{className:"flex size-6 shrink-0 items-center justify-center overflow-hidden rounded-full",style:i,children:t.favicon?o.jsx("img",{src:t.favicon,alt:"",className:"size-full object-cover"}):o.jsx(ke,{size:12,color:"#9aa0a6"})}),e[2]=t.favicon,e[3]=n):n=e[3];let m;e[4]===Symbol.for("react.memo_cache_sentinel")?(m={color:"#202124"},e[4]=m):m=e[4];let p;e[5]!==r?(p=o.jsx("div",{className:"truncate text-[13px] leading-tight",style:m,children:r}),e[5]=r,e[6]=p):p=e[6];let f;e[7]===Symbol.for("react.memo_cache_sentinel")?(f={color:"#4d5156"},e[7]=f):f=e[7];let l;e[8]!==r||e[9]!==x?(l=o.jsxs("div",{className:"truncate text-[12px] leading-tight",style:f,children:[r,x]}),e[8]=r,e[9]=x,e[10]=l):l=e[10];let c;e[11]!==p||e[12]!==l?(c=o.jsxs("div",{className:"min-w-0",children:[p,l]}),e[11]=p,e[12]=l,e[13]=c):c=e[13];let h;e[14]!==n||e[15]!==c?(h=o.jsxs("div",{className:"flex items-center gap-2",children:[n,c]}),e[14]=n,e[15]=c,e[16]=h):h=e[16];let u;e[17]===Symbol.for("react.memo_cache_sentinel")?(u={color:"#1a0dab"},e[17]=u):u=e[17];let v;e[18]!==t.title||e[19]!==a?(v=t.title??a("sectionsEditor.seoPreview.fallbackTitle"),e[18]=t.title,e[19]=a,e[20]=v):v=e[20];let y;e[21]!==v?(y=o.jsx("div",{className:"mt-1.5 truncate text-[18px] leading-snug",style:u,children:v}),e[21]=v,e[22]=y):y=e[22];let b;e[23]===Symbol.for("react.memo_cache_sentinel")?(b={color:"#4d5156"},e[23]=b):b=e[23];let S;e[24]!==t.description||e[25]!==a?(S=t.description??a("sectionsEditor.seoPreview.fallbackDescription"),e[24]=t.description,e[25]=a,e[26]=S):S=e[26];let j;e[27]!==S?(j=o.jsx("div",{className:"mt-0.5 line-clamp-2 text-[13px] leading-snug",style:b,children:S}),e[27]=S,e[28]=j):j=e[28];let k;return e[29]!==y||e[30]!==j||e[31]!==h?(k=o.jsxs("div",{className:"rounded-lg p-3 text-left",style:s,children:[h,y,j]}),e[29]=y,e[30]=j,e[31]=h,e[32]=k):k=e[32],k}function Qe(d){const e=T.c(26),{seo:t,host:r,t:x}=d;let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a={background:"#fff",border:"1px solid #e2e8f0"},e[0]=a):a=e[0];let s;e[1]!==t.image?(s=o.jsx(he,{src:t.image,className:"h-40 w-full"}),e[1]=t.image,e[2]=s):s=e[2];let i;e[3]===Symbol.for("react.memo_cache_sentinel")?(i={borderTop:"1px solid #e2e8f0"},e[3]=i):i=e[3];let n;e[4]===Symbol.for("react.memo_cache_sentinel")?(n={color:"#8a9099"},e[4]=n):n=e[4];let m;e[5]!==r?(m=o.jsx("div",{className:"truncate text-[11px]",style:n,children:r}),e[5]=r,e[6]=m):m=e[6];let p;e[7]===Symbol.for("react.memo_cache_sentinel")?(p={color:"#1c2024"},e[7]=p):p=e[7];let f;e[8]!==t.title||e[9]!==x?(f=t.title??x("sectionsEditor.seoPreview.fallbackTitle"),e[8]=t.title,e[9]=x,e[10]=f):f=e[10];let l;e[11]!==f?(l=o.jsx("div",{className:"line-clamp-1 text-[14px] font-semibold",style:p,children:f}),e[11]=f,e[12]=l):l=e[12];let c;e[13]===Symbol.for("react.memo_cache_sentinel")?(c={color:"#60666c"},e[13]=c):c=e[13];let h;e[14]!==t.description||e[15]!==x?(h=t.description??x("sectionsEditor.seoPreview.fallbackDescription"),e[14]=t.description,e[15]=x,e[16]=h):h=e[16];let u;e[17]!==h?(u=o.jsx("div",{className:"line-clamp-2 text-[12px]",style:c,children:h}),e[17]=h,e[18]=u):u=e[18];let v;e[19]!==u||e[20]!==m||e[21]!==l?(v=o.jsxs("div",{className:"px-3 py-2",style:i,children:[m,l,u]}),e[19]=u,e[20]=m,e[21]=l,e[22]=v):v=e[22];let y;return e[23]!==v||e[24]!==s?(y=o.jsxs("div",{className:"overflow-hidden rounded-lg text-left",style:a,children:[s,v]}),e[23]=v,e[24]=s,e[25]=y):y=e[25],y}function Xe(d){const e=T.c(36),{seo:t,host:r,accent:x,t:a}=d;let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s={background:"#f0f2f5"},e[0]=s):s=e[0];let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i={color:"#3b4045"},e[1]=i):i=e[1];let n;e[2]!==a?(n=a("sectionsEditor.seoPreview.chatCardHint"),e[2]=a,e[3]=n):n=e[3];let m;e[4]!==n?(m=o.jsx("p",{className:"px-1 pb-1.5 text-[12px]",style:i,children:n}),e[4]=n,e[5]=m):m=e[5];const p=`3px solid ${x}`;let f;e[6]!==p?(f={background:"#fff",borderLeft:p},e[6]=p,e[7]=f):f=e[7];let l;e[8]!==t.image?(l=o.jsx(he,{src:t.image,className:"h-28 w-full",iconSize:18}),e[8]=t.image,e[9]=l):l=e[9];let c;e[10]===Symbol.for("react.memo_cache_sentinel")?(c={color:"#1c2024"},e[10]=c):c=e[10];let h;e[11]!==t.title||e[12]!==a?(h=t.title??a("sectionsEditor.seoPreview.fallbackTitle"),e[11]=t.title,e[12]=a,e[13]=h):h=e[13];let u;e[14]!==h?(u=o.jsx("div",{className:"line-clamp-1 text-[12px] font-semibold",style:c,children:h}),e[14]=h,e[15]=u):u=e[15];let v;e[16]===Symbol.for("react.memo_cache_sentinel")?(v={color:"#60666c"},e[16]=v):v=e[16];let y;e[17]!==t.description||e[18]!==a?(y=t.description??a("sectionsEditor.seoPreview.fallbackDescription"),e[17]=t.description,e[18]=a,e[19]=y):y=e[19];let b;e[20]!==y?(b=o.jsx("div",{className:"line-clamp-2 text-[11px]",style:v,children:y}),e[20]=y,e[21]=b):b=e[21];let S;e[22]===Symbol.for("react.memo_cache_sentinel")?(S={color:"#8a9099"},e[22]=S):S=e[22];let j;e[23]!==r?(j=o.jsx("div",{className:"mt-0.5 text-[10px]",style:S,children:r}),e[23]=r,e[24]=j):j=e[24];let k;e[25]!==u||e[26]!==b||e[27]!==j?(k=o.jsxs("div",{className:"px-2.5 py-1.5",children:[u,b,j]}),e[25]=u,e[26]=b,e[27]=j,e[28]=k):k=e[28];let g;e[29]!==k||e[30]!==f||e[31]!==l?(g=o.jsxs("div",{className:"overflow-hidden rounded-[var(--studio-surface-radius,var(--radius-md))]",style:f,children:[l,k]}),e[29]=k,e[30]=f,e[31]=l,e[32]=g):g=e[32];let N;return e[33]!==g||e[34]!==m?(N=o.jsxs("div",{className:"rounded-lg p-2 text-left",style:s,children:[m,g]}),e[33]=g,e[34]=m,e[35]=N):N=e[35],N}function Ye(d){const e=T.c(39),{seo:t,host:r,accent:x,dark:a,t:s}=d,i=a?"#2b2d31":"#fff",n=a?"#00a8fc":"#1264a3",m=a?"#dbdee1":"#3b4045",p=a?"#949ba4":"#8a9099",f=a?"none":"1px solid #e2e8f0";let l;e[0]!==i||e[1]!==f?(l={background:i,border:f},e[0]=i,e[1]=f,e[2]=l):l=e[2];const c=`3px solid ${x}`;let h;e[3]!==c?(h={borderLeft:c,borderRadius:2},e[3]=c,e[4]=h):h=e[4];let u;e[5]!==p?(u={color:p},e[5]=p,e[6]=u):u=e[6];let v;e[7]!==r||e[8]!==u?(v=o.jsx("div",{className:"text-[10px]",style:u,children:r}),e[7]=r,e[8]=u,e[9]=v):v=e[9];let y;e[10]!==n?(y={color:n},e[10]=n,e[11]=y):y=e[11];let b;e[12]!==t.title||e[13]!==s?(b=t.title??s("sectionsEditor.seoPreview.fallbackTitle"),e[12]=t.title,e[13]=s,e[14]=b):b=e[14];let S;e[15]!==y||e[16]!==b?(S=o.jsx("div",{className:"line-clamp-1 text-[13px] font-semibold",style:y,children:b}),e[15]=y,e[16]=b,e[17]=S):S=e[17];let j;e[18]!==m?(j={color:m},e[18]=m,e[19]=j):j=e[19];let k;e[20]!==t.description||e[21]!==s?(k=t.description??s("sectionsEditor.seoPreview.fallbackDescription"),e[20]=t.description,e[21]=s,e[22]=k):k=e[22];let g;e[23]!==j||e[24]!==k?(g=o.jsx("div",{className:"line-clamp-2 text-[12px]",style:j,children:k}),e[23]=j,e[24]=k,e[25]=g):g=e[25];let N;e[26]!==g||e[27]!==v||e[28]!==S?(N=o.jsxs("div",{className:"min-w-0 flex-1",children:[v,S,g]}),e[26]=g,e[27]=v,e[28]=S,e[29]=N):N=e[29];let w;e[30]!==t.image?(w=o.jsx(he,{src:t.image,className:"size-14 shrink-0 rounded-[var(--studio-control-radius,var(--radius))]",iconSize:16}),e[30]=t.image,e[31]=w):w=e[31];let E;e[32]!==N||e[33]!==w||e[34]!==h?(E=o.jsxs("div",{className:"flex gap-2.5 pl-2.5",style:h,children:[N,w]}),e[32]=N,e[33]=w,e[34]=h,e[35]=E):E=e[35];let _;return e[36]!==E||e[37]!==l?(_=o.jsx("div",{className:"rounded-lg p-2.5 text-left",style:l,children:E}),e[36]=E,e[37]=l,e[38]=_):_=e[38],_}function Ze(d){const e=T.c(21),{platform:t,seo:r,host:x,path:a,t:s}=d;let i;e[0]!==x||e[1]!==a||e[2]!==t.color||e[3]!==t.id||e[4]!==t.layout||e[5]!==r||e[6]!==s?(i=t.layout==="search"?o.jsx(Je,{seo:r,host:x,path:a,t:s}):t.layout==="card"?o.jsx(Qe,{seo:r,host:x,path:a,t:s}):t.layout==="chat"?o.jsx(Xe,{seo:r,host:x,path:a,accent:t.color,t:s}):o.jsx(Ye,{seo:r,host:x,path:a,accent:t.color,dark:t.id==="discord",t:s}),e[0]=x,e[1]=a,e[2]=t.color,e[3]=t.id,e[4]=t.layout,e[5]=r,e[6]=s,e[7]=i):i=e[7];const n=i;let m;e[8]!==t.color?(m=o.jsx("span",{className:"size-2 shrink-0 rounded-full",style:{background:t.color}}),e[8]=t.color,e[9]=m):m=e[9];let p;e[10]!==t.labelKey||e[11]!==s?(p=s(t.labelKey),e[10]=t.labelKey,e[11]=s,e[12]=p):p=e[12];let f;e[13]!==p?(f=o.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:p}),e[13]=p,e[14]=f):f=e[14];let l;e[15]!==m||e[16]!==f?(l=o.jsxs("div",{className:"mb-1.5 flex items-center gap-1.5",children:[m,f]}),e[15]=m,e[16]=f,e[17]=l):l=e[17];let c;return e[18]!==n||e[19]!==l?(c=o.jsxs("div",{children:[l,n]}),e[18]=n,e[19]=l,e[20]=c):c=e[20],c}function et(d){const e=T.c(18),{seo:t,url:r,path:x}=d,a=x===void 0?"/":x,s=Se();let i,n,m;if(e[0]!==t||e[1]!==r){const y=Ve(t);i=y,n=je(y.image,r),m=je(y.favicon,r),e[0]=t,e[1]=r,e[2]=i,e[3]=n,e[4]=m}else i=e[2],n=e[3],m=e[4];let p;e[5]!==i||e[6]!==n||e[7]!==m?(p={...i,image:n,favicon:m},e[5]=i,e[6]=n,e[7]=m,e[8]=p):p=e[8];const f=p;let l;e[9]!==r?(l=We(r),e[9]=r,e[10]=l):l=e[10];const c=l,h=a==="/"?"":a;let u;e[11]!==h||e[12]!==c||e[13]!==s||e[14]!==f?(u=qe.map(y=>o.jsx(Ze,{platform:y,seo:f,host:c,path:h,t:s},y.id)),e[11]=h,e[12]=c,e[13]=s,e[14]=f,e[15]=u):u=e[15];let v;return e[16]!==u?(v=o.jsx("div",{className:"grid grid-cols-1 gap-4 @2xl:grid-cols-2",children:u}),e[16]=u,e[17]=v):v=e[17],v}function Ti(d){const e=T.c(77),{orgSlug:t,virtualMcpId:r,branch:x,decofile:a,meta:s,target:i,previewBaseUrl:n,onSaved:m,onEditDefaultSeo:p,onBack:f}=d,l=Se(),c=Fe(a,i,s),h=Ge(r,x);let u;e[0]!==h?(u=He(h),e[0]=h,e[1]=u):u=e[1];const v=!u,y=c?.seoData,b=i.kind==="site"?"site":i.pageKey,[S,j]=M.useState(b),[k,g]=M.useState(null),[N,w]=M.useState(0),[E,_]=M.useState(void 0),{persistSeo:K,persistRawSeo:ie,flush:se,isPending:le,hold:Ne}=Le({orgSlug:t,virtualMcpId:r,branch:x,target:i,resolved:c,meta:s,onSaved:m});let H;e[2]!==x||e[3]!==t||e[4]!==r?(H=Ae({orgSlug:t,virtualMcpId:r,branch:x}),e[2]=x,e[3]=t,e[4]=r,e[5]=H):H=e[5];const re=Me(H)(c?.blockKey??""),[we,Ee]=M.useState(re);(S!==b||we!==re)&&(c&&Ne(c.blockKey),j(b),Ee(re),g(null),_(void 0),w(ot));const V=i.kind==="page",_e=V?c?.rawSeoData:void 0,A=E!==void 0?E:_e,Pe=V?Ke(A)??void 0:void 0,P=k??Pe??y??{},C=c?Oe(P,c):null,z=C&&(!V||ze(A))?Be(C,s):null;let W;e[6]!==s?(W=De(s),e[6]=s,e[7]=W):W=e[7];const ce=W;let R,q;e[8]!==a||e[9]!==P||e[10]!==s||e[11]!==i.kind?(R=i.kind==="page"?$e(a,s)?.seoData??{}:{},q=i.kind==="page"?st(R,P):P,e[8]=a,e[9]=P,e[10]=s,e[11]=i.kind,e[12]=R,e[13]=q):(R=e[12],q=e[13]);const ae=q;let J;e[14]!==K||e[15]!==c||e[16]!==g?(J=F=>{if(!c)return;const ve=F;g(ve),K(ve)},e[14]=K,e[15]=c,e[16]=g,e[17]=J):J=e[17];const ne=J;let Q;e[18]!==g?(Q=()=>g(null),e[18]=g,e[19]=Q):Q=e[19];const me=Q;let X;e[20]!==w?(X=()=>w(tt),e[20]=w,e[21]=X):X=e[21];const de=X;let Y;e[22]!==se||e[23]!==f?(Y=()=>{se(),f?.()},e[22]=se,e[23]=f,e[24]=Y):Y=e[24];const pe=Y,D=i.kind==="page"?i.path:"/";let Z;e[25]!==D||e[26]!==n||e[27]!==i.kind?(Z=i.kind==="page"&&n?it(D,n):n??null,e[25]=D,e[26]=n,e[27]=i.kind,e[28]=Z):Z=e[28];const fe=Z;let ee;e[29]!==c||e[30]!==l||e[31]!==i.kind?(ee=i.kind==="site"?l("sectionsEditor.seoEditor.noSiteSeoBlock"):l(c?"sectionsEditor.seoEditor.noSeoSchema":"sectionsEditor.seoEditor.couldNotLoadSeo"),e[29]=c,e[30]=l,e[31]=i.kind,e[32]=ee):ee=e[32];const ue=ee,te=V&&c,xe=i.kind==="site"&&c&&z;let $;e[33]!==pe||e[34]!==l||e[35]!==i.kind||e[36]!==i.pageName?($=i.kind==="page"?o.jsxs("nav",{className:"flex min-w-0 items-center gap-1 text-sm",children:[o.jsx("button",{type:"button",onClick:pe,title:i.pageName,className:"min-w-0 truncate rounded-[var(--studio-control-radius,var(--radius-md))] px-1 py-0.5 text-muted-foreground transition-colors hover:bg-accent hover:text-accent-foreground",children:i.pageName}),o.jsx(Te,{className:"size-3 shrink-0 text-muted-foreground/60"}),o.jsx("span",{className:"px-1 py-0.5 font-medium text-foreground",children:"SEO"})]}):o.jsxs("div",{className:"flex min-w-0 items-center gap-2",children:[o.jsx(ye,{size:16,className:"shrink-0 text-muted-foreground"}),o.jsx("span",{className:"text-sm font-medium",children:l("sectionsEditor.seoEditor.defaultSeoLabel")}),o.jsxs("span",{className:"hidden truncate text-xs text-muted-foreground sm:inline",children:["· ",l("sectionsEditor.seoEditor.appliedToEveryPage")]})]}),e[33]=pe,e[34]=l,e[35]=i.kind,e[36]=i.pageName,e[37]=$):$=e[37];let I;e[38]!==le?(I=le&&o.jsx(Re,{className:"size-3.5 text-muted-foreground"}),e[38]=le,e[39]=I):I=e[39];let B;e[40]!==p||e[41]!==l||e[42]!==i.kind?(B=i.kind==="page"&&p&&o.jsxs(Ce,{type:"button",variant:"outline",size:"sm",onClick:p,children:[o.jsx(ye,{size:14}),l("sectionsEditor.seoEditor.editDefaultSeoButton")]}),e[40]=p,e[41]=l,e[42]=i.kind,e[43]=B):B=e[43];let L;e[44]!==I||e[45]!==B?(L=o.jsxs("div",{className:"ml-auto flex shrink-0 items-center gap-2",children:[I,B]}),e[44]=I,e[45]=B,e[46]=L):L=e[46];let O;e[47]!==$||e[48]!==L?(O=o.jsxs("div",{className:"flex h-12 shrink-0 items-center gap-2 border-b px-4",children:[$,L]}),e[47]=$,e[48]=L,e[49]=O):O=e[49];let U;e[50]!==C||e[51]!==v||e[52]!==de||e[53]!==me||e[54]!==ce||e[55]!==A||e[56]!==P||e[57]!==ue||e[58]!==N||e[59]!==ne||e[60]!==D||e[61]!==ie||e[62]!==K||e[63]!==ae||e[64]!==fe||e[65]!==c||e[66]!==z||e[67]!==g||e[68]!==_||e[69]!==te||e[70]!==xe||e[71]!==R||e[72]!==l?(U=!c||!te&&!xe?o.jsx("div",{className:"flex flex-1 items-center justify-center px-6 text-center text-sm text-muted-foreground",children:ue}):o.jsxs("div",{className:"flex min-h-0 flex-1",children:[o.jsx(ge,{className:"w-full max-w-md shrink-0 border-r [&_[data-slot=scroll-area-viewport]>div]:!block",children:o.jsx("div",{className:"px-5 py-4",children:te?o.jsxs(o.Fragment,{children:[o.jsx("p",{className:"mb-3 text-xs text-muted-foreground",children:l("sectionsEditor.seoEditor.emptyFieldsHint")}),o.jsx(Ue,{rawSeo:A,innerSeo:P,defaultResolveType:ce,seoSchema:z,activeResolveType:C,seoTypeOptions:c.seoTypeOptions,formResetKey:N,siteDefaultSeo:R,onPersistRaw:F=>{_(F),ie(F)},onInnerChange:F=>{g(F),K(F)},onClearForm:me,onBumpFormKey:de,asyncRenderAvailable:v})]}):z&&C&&o.jsx(Ie,{schema:z,resolveType:C,value:P,formResetKey:N,onChange:ne})})}),o.jsx(ge,{className:"min-w-0 flex-1 [&_[data-slot=scroll-area-viewport]>div]:!block",children:o.jsx("div",{className:"@container px-5 py-4",children:o.jsx(et,{seo:ae,url:fe,path:D})})})]}),e[50]=C,e[51]=v,e[52]=de,e[53]=me,e[54]=ce,e[55]=A,e[56]=P,e[57]=ue,e[58]=N,e[59]=ne,e[60]=D,e[61]=ie,e[62]=K,e[63]=ae,e[64]=fe,e[65]=c,e[66]=z,e[67]=g,e[68]=_,e[69]=te,e[70]=xe,e[71]=R,e[72]=l,e[73]=U):U=e[73];let oe;return e[74]!==O||e[75]!==U?(oe=o.jsxs("div",{className:"flex h-full w-full flex-col",children:[O,U]}),e[74]=O,e[75]=U,e[76]=oe):oe=e[76],oe}function tt(d){return d+1}function ot(d){return d+1}function it(d,e){try{return new URL(d,e).href}catch{return e}}function st(d,e){const t=e.__resolveType,r=d.__resolveType;if(typeof t=="string"&&typeof r=="string"&&t!==r)return{...e};const x={...d};for(const[a,s]of Object.entries(e))a!=="__resolveType"&&s!=null&&(typeof s=="string"&&s.trim()===""||(x[a]=s));return x}export{Ti as SeoEditor};
@@ -1 +0,0 @@
1
- import{c as e,j as o}from"./index-C8YP0XfX.js";import{V as a}from"./index-CjhVW3Ft.js";function p(s){const t=e.c(2),{virtualMcpId:r}=s;let i;return t[0]!==r?(i=o.jsx(a,{virtualMcpId:r}),t[0]=r,t[1]=i):i=t[1],i}export{p as S};
@@ -1 +0,0 @@
1
- import{c as R,b as G,e as tt,j as n,B as z,t as Ke,o as st,cV as ae,ag as jt,a as Ue,J as Ut,U as kt,K as Je,cW as Gt,cX as Jt,az as Ge,l as ut,be as Vt,z as mt,r as Q,ae as Wt,af as te,cY as Yt,w as Tt,x as Nt,v as _t,D as Pt,d as At,a4 as ct,R as Ct,m as Fe,C as at,aX as Et,cZ as Qt,b1 as Xt,b8 as ft,H as Zt,c_ as en,aY as tn,y as nn,c$ as sn,d0 as on,d1 as an,d2 as rn,d3 as ln,a5 as cn,u as dn,a6 as un,d4 as mn,d5 as fn,k as Ot,d6 as ht,d7 as hn,O as gn,b3 as gt,d8 as pn,a0 as yn}from"./index-C8YP0XfX.js";import{t as It}from"./Building02-CcI-P3yL.js";import{i as bn,s as ee}from"./UserSquare-D4xudMmb.js";import{ay as xn,U as wn,I as it,a8 as Sn,K as vn,az as jn,n as pt,g as kn,p as Tn,k as Nn,aA as _n,l as Pn}from"./agent-icon-B7Q7dFXY.js";import{s as An}from"./XClose-D48r2tDo.js";import{a as Cn,u as En}from"./use-project-scope-BgLQY0Uk.js";import{u as $t,a as On}from"./use-panel-navigate-CTWNyrxK.js";import{i as se}from"./CheckCircle-fAPMl2yd.js";import{i as yt}from"./Monitor01-Bmn1BV5T.js";import{i as qe}from"./ZoomOut-BVuJZ-2t.js";import{u as In}from"./use-clock-tick-DxI4Q15z.js";import{s as bt}from"./Plus-Bh_xMwh7.js";import{a as $n}from"./Tool01-CTKnipD_.js";import{b as ne,a as Be,f as Ln,e as Dn,c as Rn,C as zn}from"./command-jlI8eprh.js";import{I as qn}from"./integration-icon-03FWmed-.js";import{P as Fn}from"./project-icon-BSrEdWN1.js";import{a as Bn,m as Mn}from"./use-mcp-client-CkAT8dMu.js";import{u as Kn,a as Hn,n as Un}from"./new-project-dialog-BuE_SqTn.js";import{S as Gn,u as Jn}from"./thread-intent-Cl7xa7dA.js";import{R as Vn}from"./required-auth-layout-ofmCqqpc.js";import{A as Wn}from"./autosend-VKc1dW3G.js";import{u as Yn,a as Qn,b as Xn,c as Zn}from"./thread-route-JcxEqRgq.js";import{u as es}from"./use-org-sso-BK4EESlq.js";function ts(t){const e=R.c(49),{orgName:o,orgSlug:r,orgLogo:s,domain:a}=t,i=G();let c;e[0]!==r||e[1]!==i?(c=async()=>{const P=await fetch("/api/auth/custom/domain-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:r})}),C=await P.json();if(!P.ok||!C.success)throw new Error(C.error??i("common.autoDomainJoinScreen.joinError"));return C},e[0]=r,e[1]=i,e[2]=c):c=e[2];let m;e[3]!==r?(m=P=>{window.location.href=`/${P.slug??r}`},e[3]=r,e[4]=m):m=e[4];let h;e[5]!==i?(h=P=>{Ke.error(P instanceof Error?P.message:i("common.autoDomainJoinScreen.joinError"))},e[5]=i,e[6]=h):h=e[6];let S;e[7]!==c||e[8]!==m||e[9]!==h?(S={mutationFn:c,onSuccess:m,onError:h},e[7]=c,e[8]=m,e[9]=h,e[10]=S):S=e[10];const u=tt(S),p=ns;let l;e[11]!==s||e[12]!==o?(l=s?n.jsx(st,{url:s,fallback:o,shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(It,{className:"h-6 w-6 text-primary"})}),e[11]=s,e[12]=o,e[13]=l):l=e[13];let g;e[14]!==o||e[15]!==i?(g=i("common.autoDomainJoinScreen.joinPrompt",{orgName:o}),e[14]=o,e[15]=i,e[16]=g):g=e[16];let f;e[17]!==g?(f=n.jsx("h3",{className:"text-lg font-medium",children:g}),e[17]=g,e[18]=f):f=e[18];let d;e[19]!==a||e[20]!==i?(d=i("common.autoDomainJoinScreen.joinDescription",{domain:a}),e[19]=a,e[20]=i,e[21]=d):d=e[21];let w;e[22]!==d?(w=n.jsx("p",{className:"text-sm text-muted-foreground",children:d}),e[22]=d,e[23]=w):w=e[23];let y;e[24]!==f||e[25]!==w?(y=n.jsxs("div",{className:"space-y-2",children:[f,w]}),e[24]=f,e[25]=w,e[26]=y):y=e[26];let x;e[27]!==u?(x=()=>u.mutate(),e[27]=u,e[28]=x):x=e[28];let v;e[29]!==u.isPending||e[30]!==o||e[31]!==i?(v=u.isPending?i("common.autoDomainJoinScreen.joining"):i("common.autoDomainJoinScreen.enterOrg",{orgName:o}),e[29]=u.isPending,e[30]=o,e[31]=i,e[32]=v):v=e[32];let b;e[33]!==u.isPending||e[34]!==x||e[35]!==v?(b=n.jsx(z,{onClick:x,disabled:u.isPending,children:v}),e[33]=u.isPending,e[34]=x,e[35]=v,e[36]=b):b=e[36];const T=u.isPending;let j;e[37]!==i?(j=i("common.goHome"),e[37]=i,e[38]=j):j=e[38];let k;e[39]!==u.isPending||e[40]!==j?(k=n.jsx(z,{variant:"ghost",onClick:p,disabled:T,children:j}),e[39]=u.isPending,e[40]=j,e[41]=k):k=e[41];let _;e[42]!==b||e[43]!==k?(_=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[b,k]}),e[42]=b,e[43]=k,e[44]=_):_=e[44];let N;return e[45]!==y||e[46]!==_||e[47]!==l?(N=n.jsxs(ae,{children:[l,y,_]}),e[45]=y,e[46]=_,e[47]=l,e[48]=N):N=e[48],N}function ns(){window.location.href="/"}function xt(t){const e=R.c(25),{orgSlug:o,orgName:r,reason:s}=t,a=G(),i=ss,c=s==="not-found",m=c?bn:jt;let h;e[0]!==c||e[1]!==a?(h=a(c?"common.noAccessScreen.organizationNotFound":"common.noAccessScreen.noAccess"),e[0]=c,e[1]=a,e[2]=h):h=e[2];const S=h;let u;e[3]!==c||e[4]!==r||e[5]!==o||e[6]!==a?(u=c?n.jsxs(n.Fragment,{children:[a("common.noAccessScreen.couldNotFind")," ",n.jsx("strong",{children:o}),"."]}):n.jsxs(n.Fragment,{children:[a("common.noAccessScreen.noAccessTo")," ",n.jsx("strong",{children:r??o}),".",n.jsx("br",{}),a("common.noAccessScreen.askAdminToInvite")]}),e[3]=c,e[4]=r,e[5]=o,e[6]=a,e[7]=u):u=e[7];const p=u;let l;e[8]!==m?(l=n.jsx("div",{className:"bg-muted p-3 rounded-full",children:n.jsx(m,{className:"h-6 w-6 text-muted-foreground"})}),e[8]=m,e[9]=l):l=e[9];let g;e[10]!==S?(g=n.jsx("h3",{className:"text-lg font-medium",children:S}),e[10]=S,e[11]=g):g=e[11];let f;e[12]!==p?(f=n.jsx("p",{className:"text-sm text-muted-foreground",children:p}),e[12]=p,e[13]=f):f=e[13];let d;e[14]!==g||e[15]!==f?(d=n.jsxs("div",{className:"space-y-2",children:[g,f]}),e[14]=g,e[15]=f,e[16]=d):d=e[16];let w;e[17]!==a?(w=a("common.goHome"),e[17]=a,e[18]=w):w=e[18];let y;e[19]!==w?(y=n.jsx(z,{onClick:i,children:w}),e[19]=w,e[20]=y):y=e[20];let x;return e[21]!==l||e[22]!==d||e[23]!==y?(x=n.jsxs(ae,{children:[l,d,y]}),e[21]=l,e[22]=d,e[23]=y,e[24]=x):x=e[24],x}function ss(){window.location.href="/"}function os(t){const e=R.c(59),{invitationId:o,orgName:r,orgSlug:s,orgLogo:a}=t,i=G();let c;e[0]!==o?(c=async()=>{const A=await Ue.organization.acceptInvitation({invitationId:o});if(A.error)throw new Error(A.error.message);return A.data},e[0]=o,e[1]=c):c=e[1];let m;e[2]!==s?(m=()=>{Ut(),window.location.href=`/${s}`},e[2]=s,e[3]=m):m=e[3];let h;e[4]!==i?(h=A=>{Ke.error(A instanceof Error?A.message:i("common.pendingInviteScreen.failedToAccept"))},e[4]=i,e[5]=h):h=e[5];let S;e[6]!==c||e[7]!==m||e[8]!==h?(S={mutationFn:c,onSuccess:m,onError:h},e[6]=c,e[7]=m,e[8]=h,e[9]=S):S=e[9];const u=tt(S);let p;e[10]!==o?(p=async()=>{const A=await Ue.organization.rejectInvitation({invitationId:o});if(A.error)throw new Error(A.error.message);return A.data},e[10]=o,e[11]=p):p=e[11];let l,g;e[12]!==i?(l=()=>{Ke.success(i("common.pendingInviteScreen.invitationDeclined")),window.location.href="/"},g=A=>{Ke.error(A instanceof Error?A.message:i("common.pendingInviteScreen.failedToDecline"))},e[12]=i,e[13]=l,e[14]=g):(l=e[13],g=e[14]);let f;e[15]!==p||e[16]!==l||e[17]!==g?(f={mutationFn:p,onSuccess:l,onError:g},e[15]=p,e[16]=l,e[17]=g,e[18]=f):f=e[18];const d=tt(f),w=u.isPending||d.isPending;let y;e[19]!==a||e[20]!==r?(y=a?n.jsx(st,{url:a,fallback:r,shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(xn,{className:"h-6 w-6 text-primary"})}),e[19]=a,e[20]=r,e[21]=y):y=e[21];let x;e[22]!==r||e[23]!==i?(x=i("common.pendingInviteScreen.invitedTo",{orgName:r}),e[22]=r,e[23]=i,e[24]=x):x=e[24];let v;e[25]!==x?(v=n.jsx("h3",{className:"text-lg font-medium",children:x}),e[25]=x,e[26]=v):v=e[26];let b;e[27]!==i?(b=i("common.pendingInviteScreen.acceptDescription"),e[27]=i,e[28]=b):b=e[28];let T;e[29]!==b?(T=n.jsx("p",{className:"text-sm text-muted-foreground",children:b}),e[29]=b,e[30]=T):T=e[30];let j;e[31]!==v||e[32]!==T?(j=n.jsxs("div",{className:"space-y-2",children:[v,T]}),e[31]=v,e[32]=T,e[33]=j):j=e[33];let k;e[34]!==u?(k=()=>u.mutate(),e[34]=u,e[35]=k):k=e[35];let _;e[36]!==u.isPending||e[37]!==i?(_=u.isPending?i("common.pendingInviteScreen.acceptingButton"):i("common.pendingInviteScreen.acceptButton"),e[36]=u.isPending,e[37]=i,e[38]=_):_=e[38];let N;e[39]!==w||e[40]!==k||e[41]!==_?(N=n.jsx(z,{onClick:k,disabled:w,children:_}),e[39]=w,e[40]=k,e[41]=_,e[42]=N):N=e[42];let P;e[43]!==d?(P=()=>d.mutate(),e[43]=d,e[44]=P):P=e[44];let C;e[45]!==d.isPending||e[46]!==i?(C=d.isPending?i("common.pendingInviteScreen.decliningButton"):i("common.pendingInviteScreen.declineButton"),e[45]=d.isPending,e[46]=i,e[47]=C):C=e[47];let I;e[48]!==w||e[49]!==P||e[50]!==C?(I=n.jsx(z,{variant:"ghost",onClick:P,disabled:w,children:C}),e[48]=w,e[49]=P,e[50]=C,e[51]=I):I=e[51];let O;e[52]!==N||e[53]!==I?(O=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[N,I]}),e[52]=N,e[53]=I,e[54]=O):O=e[54];let D;return e[55]!==j||e[56]!==O||e[57]!==y?(D=n.jsxs(ae,{children:[y,j,O]}),e[55]=j,e[56]=O,e[57]=y,e[58]=D):D=e[58],D}function is(t){const e=R.c(23),{orgName:o,orgLogo:r}=t,s=G();let a;e[0]!==r||e[1]!==o?(a=r?n.jsx(st,{url:r,fallback:o,shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full","aria-hidden":"true",children:n.jsx(wn,{className:"h-6 w-6 text-primary"})}),e[0]=r,e[1]=o,e[2]=a):a=e[2];let i;e[3]!==s?(i=s("common.requestPendingScreen.title"),e[3]=s,e[4]=i):i=e[4];let c;e[5]!==i?(c=n.jsx("h3",{className:"text-lg font-medium",children:i}),e[5]=i,e[6]=c):c=e[6];let m;e[7]!==o||e[8]!==s?(m=s("common.requestPendingScreen.description",{orgName:o}),e[7]=o,e[8]=s,e[9]=m):m=e[9];let h;e[10]!==m?(h=n.jsx("p",{className:"text-sm text-muted-foreground",children:m}),e[10]=m,e[11]=h):h=e[11];let S;e[12]!==c||e[13]!==h?(S=n.jsxs("div",{className:"space-y-2",children:[c,h]}),e[12]=c,e[13]=h,e[14]=S):S=e[14];let u;e[15]!==s?(u=s("common.goHome"),e[15]=s,e[16]=u):u=e[16];let p;e[17]!==u?(p=n.jsx(z,{variant:"ghost",onClick:as,children:u}),e[17]=u,e[18]=p):p=e[18];let l;return e[19]!==a||e[20]!==S||e[21]!==p?(l=n.jsxs(ae,{children:[a,S,p]}),e[19]=a,e[20]=S,e[21]=p,e[22]=l):l=e[22],l}function as(){window.location.href="/"}function rs(t){const e=R.c(45),{orgName:o,orgSlug:r,orgLogo:s,domain:a}=t,i=G();let c;e[0]!==r?(c=async()=>{const N=await fetch("/api/auth/custom/domain-request-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:r})}),P=await N.json();if(!N.ok||!P.success)throw new Error(P.error??"Failed to request access");return P},e[0]=r,e[1]=c):c=e[1];let m;e[2]===Symbol.for("react.memo_cache_sentinel")?(m=cs,e[2]=m):m=e[2];let h;e[3]!==i?(h=N=>{Ke.error(N instanceof Error?N.message:i("common.requestToJoinScreen.failedToRequest"))},e[3]=i,e[4]=h):h=e[4];let S;e[5]!==c||e[6]!==h?(S={mutationFn:c,onSuccess:m,onError:h},e[5]=c,e[6]=h,e[7]=S):S=e[7];const u=tt(S);let p;e[8]!==s||e[9]!==o?(p=s?n.jsx(st,{url:s,fallback:o,shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(It,{className:"h-6 w-6 text-primary"})}),e[8]=s,e[9]=o,e[10]=p):p=e[10];let l;e[11]!==o||e[12]!==i?(l=i("common.requestToJoinScreen.title",{orgName:o}),e[11]=o,e[12]=i,e[13]=l):l=e[13];let g;e[14]!==l?(g=n.jsx("h3",{className:"text-lg font-medium",children:l}),e[14]=l,e[15]=g):g=e[15];let f;e[16]!==a||e[17]!==i?(f=i("common.requestToJoinScreen.description",{domain:a}),e[16]=a,e[17]=i,e[18]=f):f=e[18];let d;e[19]!==f?(d=n.jsx("p",{className:"text-sm text-muted-foreground",children:f}),e[19]=f,e[20]=d):d=e[20];let w;e[21]!==g||e[22]!==d?(w=n.jsxs("div",{className:"space-y-2",children:[g,d]}),e[21]=g,e[22]=d,e[23]=w):w=e[23];let y;e[24]!==u?(y=()=>u.mutate(),e[24]=u,e[25]=y):y=e[25];let x;e[26]!==u.isPending||e[27]!==i?(x=u.isPending?i("common.requestToJoinScreen.requesting"):i("common.requestToJoinScreen.requestButton"),e[26]=u.isPending,e[27]=i,e[28]=x):x=e[28];let v;e[29]!==u.isPending||e[30]!==y||e[31]!==x?(v=n.jsx(z,{onClick:y,disabled:u.isPending,children:x}),e[29]=u.isPending,e[30]=y,e[31]=x,e[32]=v):v=e[32];const b=u.isPending;let T;e[33]!==i?(T=i("common.goHome"),e[33]=i,e[34]=T):T=e[34];let j;e[35]!==u.isPending||e[36]!==T?(j=n.jsx(z,{variant:"ghost",onClick:ls,disabled:b,children:T}),e[35]=u.isPending,e[36]=T,e[37]=j):j=e[37];let k;e[38]!==v||e[39]!==j?(k=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[v,j]}),e[38]=v,e[39]=j,e[40]=k):k=e[40];let _;return e[41]!==w||e[42]!==k||e[43]!==p?(_=n.jsxs(ae,{children:[p,w,k]}),e[41]=w,e[42]=k,e[43]=p,e[44]=_):_=e[44],_}function ls(){window.location.href="/"}function cs(t){if(t.alreadyMember&&t.slug){window.location.href=`/${t.slug}`;return}window.location.reload()}function ds(t){const e=R.c(7);let o;e[0]!==t?(o=Je.orgAccessStatus(t),e[0]=t,e[1]=o):o=e[1];let r;e[2]!==t?(r=async()=>{const a=await fetch(`/api/auth/custom/org-access-status/${encodeURIComponent(t)}`,{credentials:"include"});if(!a.ok)throw new Error(`org-access-status failed (${a.status})`);return await a.json()},e[2]=t,e[3]=r):r=e[3];let s;return e[4]!==o||e[5]!==r?(s={queryKey:o,queryFn:r,refetchOnWindowFocus:!1},e[4]=o,e[5]=r,e[6]=s):s=e[6],kt(s)}function us({orgSlug:t}){const{data:e}=ds(t);if(e.status!=="member"){Gt()?.org===t&&Jt();const o=localStorage.getItem(Ge.lastOrgSlug())===t;if(o&&localStorage.removeItem(Ge.lastOrgSlug()),o&&(e.status==="not-found"||e.status==="no-access"))return window.location.href="/",null}return e.status==="not-found"?n.jsx(xt,{orgSlug:t,reason:"not-found"}):e.status==="pending-invite"?n.jsx(os,{invitationId:e.invitation.id,orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo}):e.status==="auto-domain-join"?n.jsx(ts,{orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo,domain:e.organization.domain??""}):e.status==="can-request"?n.jsx(rs,{orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo,domain:e.organization.domain??""}):e.status==="request-pending"?n.jsx(is,{orgName:e.organization.name,orgLogo:e.organization.logo}):e.status==="member"?(window.location.reload(),null):n.jsx(xt,{orgSlug:t,orgName:e.organization.name,reason:"no-access"})}function Lt(t){const e=R.c(42),{ariaLabel:o,dismissLabel:r,eyebrow:s,title:a,description:i,icon:c,children:m,footerLeading:h,actions:S,onDismiss:u,tone:p}=t,l=p===void 0?"neutral":p,g=h||S;let f;e[0]!==l?(f=l==="system"&&n.jsx("div",{className:"h-0.5 bg-special"}),e[0]=l,e[1]=f):f=e[1];let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=n.jsx(An,{size:14}),e[2]=d):d=e[2];let w;e[3]!==r||e[4]!==u?(w=n.jsx(z,{size:"icon-sm",variant:"ghost","aria-label":r,className:"absolute right-2 top-2 z-10 text-muted-foreground",onClick:u,children:d}),e[3]=r,e[4]=u,e[5]=w):w=e[5];const y=c&&"flex items-start gap-3",x=m&&"pb-3";let v;e[6]!==y||e[7]!==x?(v=ut("p-4 pr-11",y,x),e[6]=y,e[7]=x,e[8]=v):v=e[8];let b;e[9]!==c?(b=c&&n.jsx("div",{className:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-special/10 text-special",children:c}),e[9]=c,e[10]=b):b=e[10];let T;e[11]!==s?(T=s&&n.jsx("p",{className:"text-xs text-muted-foreground",children:s}),e[11]=s,e[12]=T):T=e[12];let j;e[13]!==a?(j=n.jsx("h3",{className:"text-base font-semibold text-foreground",children:a}),e[13]=a,e[14]=j):j=e[14];let k;e[15]!==i?(k=i&&n.jsx("p",{className:"mt-1 text-xs text-muted-foreground",children:i}),e[15]=i,e[16]=k):k=e[16];let _;e[17]!==j||e[18]!==k||e[19]!==T?(_=n.jsxs("div",{children:[T,j,k]}),e[17]=j,e[18]=k,e[19]=T,e[20]=_):_=e[20];let N;e[21]!==m?(N=m&&n.jsx("div",{className:"mt-3",children:m}),e[21]=m,e[22]=N):N=e[22];let P;e[23]!==_||e[24]!==N?(P=n.jsxs("div",{className:"min-w-0 flex-1",children:[_,N]}),e[23]=_,e[24]=N,e[25]=P):P=e[25];let C;e[26]!==P||e[27]!==v||e[28]!==b?(C=n.jsxs("div",{className:v,children:[b,P]}),e[26]=P,e[27]=v,e[28]=b,e[29]=C):C=e[29];let I;e[30]!==S||e[31]!==h||e[32]!==g||e[33]!==l?(I=g&&n.jsxs("div",{className:ut("flex items-center justify-between gap-3 px-4 py-2.5",l==="system"?"border-t border-border bg-muted/50":"pt-0"),children:[n.jsx("div",{className:"min-w-0 text-xs text-muted-foreground",children:h}),n.jsx("div",{className:"flex shrink-0 items-center gap-2",children:S})]}),e[30]=S,e[31]=h,e[32]=g,e[33]=l,e[34]=I):I=e[34];let O;return e[35]!==o||e[36]!==C||e[37]!==I||e[38]!==f||e[39]!==w||e[40]!==l?(O=n.jsxs("div",{role:"dialog","aria-label":o,"data-slot":"announcement-card","data-tone":l,className:"relative w-full overflow-hidden rounded-lg bg-popover shadow-soft animate-in fade-in slide-in-from-bottom-2 duration-300",children:[f,w,C,I]}),e[35]=o,e[36]=C,e[37]=I,e[38]=f,e[39]=w,e[40]=l,e[41]=O):O=e[41],O}const ms={switcher:"tour-layout-switcher",nav:"tour-layout-nav",tasks:"tour-layout-tasks",projects:"tour-layout-projects",account:"tour-layout-account",recentActivity:"tour-layout-recent-activity",siteEditor:"tour-layout-site-editor",surfaceTabs:"tour-layout-surface-tabs",branchPicker:"tour-layout-branch-picker",automations:"tour-layout-automations",settings:"tour-layout-settings"};function Dt(t){return`[data-tour="${ms[t]}"]`}const fs=[{scope:"shell",anchor:"switcher",titleKey:"layoutTour.switcher.title",descKey:"layoutTour.switcher.description",side:"right"},{scope:"shell",anchor:"nav",titleKey:"layoutTour.nav.title",descKey:"layoutTour.nav.description",side:"right"},{scope:"shell",anchor:"tasks",titleKey:"layoutTour.tasks.title",descKey:"layoutTour.tasks.description",side:"right"},{scope:"project",anchor:"siteEditor",titleKey:"layoutTour.siteEditor.title",descKey:"layoutTour.siteEditor.description",side:"right"},{scope:"project",anchor:"automations",titleKey:"layoutTour.automations.title",descKey:"layoutTour.automations.description",side:"right"},{scope:"shell",anchor:"settings",titleKey:"layoutTour.settings.title",descKey:"layoutTour.settings.description",side:"right"},{scope:"shell",anchor:"projects",titleKey:"layoutTour.projects.title",descKey:"layoutTour.projects.description",side:"right"},{scope:"shell",anchor:"account",titleKey:"layoutTour.account.title",descKey:"layoutTour.account.description",side:"right"},{scope:"siteEditor",anchor:"surfaceTabs",titleKey:"layoutTour.surfaceTabs.title",descKey:"layoutTour.surfaceTabs.description",side:"bottom"},{scope:"siteEditor",anchor:"branchPicker",titleKey:"layoutTour.branchPicker.title",descKey:"layoutTour.branchPicker.description",side:"bottom"},{scope:"orgHome",anchor:"recentActivity",titleKey:"layoutTour.recentActivity.title",descKey:"layoutTour.recentActivity.description",side:"top"}];function hs(t){return fs.filter(e=>e.scope==="shell"||e.scope==="orgHome"&&t.onOrgHome||e.scope==="project"&&t.inProject||e.scope==="siteEditor"&&t.onSiteEditor)}function gs(t,e){return hs(e).map(o=>({element:Dt(o.anchor),popover:{title:t(o.titleKey),description:t(o.descKey),side:o.side,align:"center"}}))}const ps=Dt("switcher"),ys=30;function Rt(t){const e=document.querySelector(t);return e instanceof HTMLElement&&e.offsetParent!==null}function bs(t,e){return gs(t,e).filter(o=>typeof o.element=="string"&&Rt(o.element))}function xs(t,e){return{showProgress:!0,progressText:t("layoutTour.progress"),nextBtnText:t("layoutTour.next"),prevBtnText:t("layoutTour.prev"),doneBtnText:t("layoutTour.done"),showButtons:["next","previous"],smoothScroll:!0,allowClose:!0,disableActiveInteraction:!0,stagePadding:6,stageRadius:8,waitForElement:0,skipMissingElement:!0,popoverClass:"layout-tour-popover",onPopoverRender:(o,{driver:r})=>{if(o.footerButtons.querySelector(".layout-tour-skip"))return;const s=document.createElement("button");s.type="button",s.className="driver-popover-footer-btn layout-tour-skip",s.textContent=t("layoutTour.skip"),s.addEventListener("click",()=>r.destroy()),o.footerButtons.insertBefore(s,o.footerButtons.firstChild)},onDestroyed:()=>{Me=!1},steps:e}}let Me=!1;async function ws(){return(await Vt(()=>import("./driver.js-Dj4CfABu.js"),[])).driver}function Ss(t,e){if(Me)return;Me=!0;let o=0;const r=()=>{if(!Rt(ps)&&o++<ys){requestAnimationFrame(r);return}const s=bs(t,e);if(s.length===0){Me=!1;return}ws().then(a=>{a(xs(t,s)).drive()}).catch(()=>{Me=!1})};r()}function vs(t){return t!=="off"}function Qo(t){if(!t.hasSource)return[];const e=["site-editor"];return vs(t.cmsMode)&&e.push("content"),t.runtime==="sandbox"&&e.push("code"),e}function zt(t){return t==="site-editor"||t==="content"||t==="code"||t.startsWith("code:")}function Xo(t){return t.reportsOnly&&!t.onReportAgent&&zt(t.tabId)}const qt=[{id:"new-layout",date:"2026-09-22",eyebrow:"Now Available",title:"New Layout",bullets:[{icon:yt,title:"Unified page headers",body:"Every page now has a clear header with navigation breadcrumbs and actions, making it easy to orient yourself and move around."},{icon:it,title:"Consistent navigation and controls",body:"Settings and project pages use a predictable sidebar instead of scattered tabs. Buttons, inputs and toolbars share one shape and one height, and the layout adapts to smaller screens."},{icon:Sn,title:"Site editor redesigned",body:"Try the redesigned blocks editor from Profile & Preferences. Blocks share consistent actions, variants appear beside their block in the header, and section selection is searchable."}],cta:{label:"Take a tour",action:"start-tour"}},{id:"unified-workspace-layout",date:"2026-09-01",eyebrow:"Now Available",title:"A new way around Studio",bullets:[{icon:mt,title:"Unified org switcher",body:"Organizations and agents now share one control at the top of the sidebar. Search it to jump straight to any agent, including ones in your other organizations."},{icon:ee,title:"Your org at a glance",body:"The organization home now opens on the agents your team built and the tasks they are running — no empty board to fill in first."},{icon:yt,title:"Simplified CMS",body:"The CMS opens over the page you are previewing rather than somewhere else, so changing a section never costs you your place."}],cta:{label:"Take the tour",action:"start-tour"}},{id:"codex-gpt-5-6-defaults",date:"2026-07-13",eyebrow:"Now Available",title:"Codex defaults move to GPT-5.6",bullets:[{icon:ee,title:"Sol leads Thinking",body:"Codex Thinking now defaults to `gpt-5.6-sol` for deeper coding and reasoning work."},{icon:se,title:"Terra balances Smart",body:"The Smart tier now uses `gpt-5.6-terra`, replacing GPT-5.4 as the default balanced Codex model."},{icon:qe,title:"Luna speeds up Fast",body:"The Fast tier and lightweight Codex title generation now use `gpt-5.6-luna`. Existing threads that reference older GPT-5.4 or GPT-5.5 model IDs remain supported."}]},{id:"claude-sonnet-5",date:"2026-06-30",eyebrow:"Now Available",title:"Claude Sonnet 5 powers the Smart tier",bullets:[{icon:ee,title:"More agentic coding",body:"Sonnet 5 is Anthropic's strongest Sonnet model yet, with improved reasoning, tool use, coding, and knowledge work compared with Sonnet 4.6."},{icon:se,title:"Available in Claude Code",body:"The Claude Code harness now pins the Smart tier to the new `claude-sonnet-5` model id so new sessions use Sonnet 5 by default."},{icon:qe,title:"Nothing to change",body:"Existing Smart-tier chats and agents pick up Sonnet 5 automatically. Thinking remains on Opus 4.8 1M."}],learnMoreHref:"https://www.anthropic.com/news/claude-sonnet-5"},{id:"fable-5-suspension",date:"2026-06-13",eyebrow:"Important Update",title:"Fable 5 & Mythos 5 suspended — Opus 4.8 takes over",bullets:[{icon:se,title:"US government directive",body:"Anthropic received an export control directive requiring the suspension of Fable 5 and Mythos 5 access for all users, citing national security concerns. Anthropic is complying while it works to resolve the matter."},{icon:ee,title:"Opus 4.8 steps in as the Thinking tier",body:"The Thinking tier now runs on Claude Opus 4.8, which remains fully operational. Performance on most tasks is comparable, and Anthropic reports more than 95% of sessions were unaffected by the Fable 5 classifiers anyway."},{icon:qe,title:"Nothing to change",body:"The switch is automatic — any chat or agent already using the Thinking tier is now served by Opus 4.8. Anthropic will share further details within 24 hours."}],learnMoreHref:"https://www.anthropic.com/news/fable-mythos-access"},{id:"claude-fable-5",date:"2026-06-09",eyebrow:"Now Available",title:"Claude Fable 5 leads the Thinking tier",bullets:[{icon:ee,title:"State-of-the-art reasoning",body:"Fable 5 takes the Thinking tier, posting top scores across software engineering, knowledge work, and vision — and outperforming Opus 4.8 on nearly every benchmark Anthropic tested."},{icon:se,title:"Safety without the slowdown",body:"New classifiers route the small slice of high-risk requests (cybersecurity, bio/chem) back to Opus 4.8. Anthropic reports more than 95% of sessions never trigger a fallback."},{icon:qe,title:"Nothing to change",body:"Chats and agents pick up Fable 5 automatically wherever the Thinking tier is selected. Opus 4.8 stays available as the safety fallback."}],learnMoreHref:"https://www.anthropic.com/news/claude-fable-5-mythos-5"},{id:"claude-opus-4-8",date:"2026-05-28",eyebrow:"Now Available",title:"Claude Opus 4.8 is the new default",bullets:[{icon:ee,title:"Smarter thinking, same price",body:"Opus 4.8 now leads the Thinking and Smarter tiers, outperforming Opus 4.7 on coding, reasoning, and agent tasks at the same cost."},{icon:se,title:"More honest answers",body:"It's about 4× less likely to let a code flaw slip through unflagged, and surfaces uncertainty instead of making unsupported claims."},{icon:qe,title:"Nothing to change",body:"Chats and agents pick up Opus 4.8 automatically wherever the Thinking or Smarter tier is selected."}],learnMoreHref:"https://www.anthropic.com/news/claude-opus-4-8"},{id:"enhanced-sidebar",date:"2026-05-28",eyebrow:"Now Available",title:"Enhanced sidebar",bullets:[{icon:ee,title:"A clearer view of what's running",body:"See every task in your organization at a glance, with each agent and status group laid out so you can spot active work without hunting for it."},{icon:it,title:"Browse one group at a time",body:"Expand the groups you care about and pull in more results on demand — no more endless scrolling to find an older conversation."},{icon:se,title:"Polished and steadier",body:"Several sidebar bugs are fixed, including empty agent groups showing the right action and status filters returning the right tasks."}]},{id:"smarter-task-delegation",date:"2026-05-27",eyebrow:"Now Available",title:"Smarter task delegation",bullets:[{icon:mt,title:"Real results from delegated agents",body:"When one agent hands work to another, you'll see the full report inline — no more empty replies hiding the work that was done."},{icon:qe,title:"Same powers, top to bottom",body:"Delegated agents now work with the same tools, context, and memory as the agent that called them, so complex multi-agent investigations finish on the first try."},{icon:se,title:"Clearer progress signals",body:"When a delegated task hits its limit or runs into a problem, you get a plain-language message instead of a silent stall."}]},{id:"sidebar-task-groups",date:"2026-05-27",eyebrow:"Now Available",title:"Redesigned sidebar",bullets:[{icon:ee,title:"Group by agent or status",body:"Switch the task list between grouping by agent or by status — pick whichever matches how you're working right now."},{icon:it,title:"Sharper filters",body:"Narrow the list to your tasks, manual chats, or automations from a compact filter row above the groups."}]},{id:"release-channel",date:"2026-05-26",eyebrow:"Now Available",title:"Release announcements",bullets:[{icon:ee,title:"Heads-up when features ship",body:"New releases surface in a corner card the first time you see them, then stick around in your inbox."},{icon:vn,title:"Unified inbox",body:"Org invitations and product updates now share one chronological feed in the sidebar."}]}],nt="studio.release-feed.v1",rt=new Set;let oe="",ie={},lt=!1;function js(){if(lt)return oe||"{}";try{return localStorage.getItem(nt)??"{}"}catch{return oe||"{}"}}function Ft(t){try{const e=JSON.parse(t);return e&&typeof e=="object"?e:{}}catch{return{}}}function wt(){const t=js();return t!==oe&&(oe=t,ie=Ft(t)),ie}function ks(t){rt.add(t);const e=o=>{if(!(o.key!==nt&&o.key!==null)){try{const r=localStorage.getItem(nt)??"{}",a={...Ft(r),...ie};ie=a,oe=JSON.stringify(a)}catch{}t()}};return window.addEventListener("storage",e),()=>{rt.delete(t),window.removeEventListener("storage",e)}}function Ts(t){ie=t,oe=JSON.stringify(t);try{localStorage.setItem(nt,oe),lt=!1}catch{lt=!0}rt.forEach(e=>e())}function Ns(){const t=R.c(7),e=Q.useSyncExternalStore(ks,wt,wt);let o;t[0]!==e?(o=m=>!!e[m],t[0]=e,t[1]=o):o=t[1];const r=o,s=_s;let a;t[2]!==e?(a=qt.reduce((m,h)=>e[h.id]?m:m+1,0),t[2]=e,t[3]=a):a=t[3];const i=a;let c;return t[4]!==r||t[5]!==i?(c={isSeen:r,markSeen:s,unseenCount:i},t[4]=r,t[5]=i,t[6]=c):c=t[6],c}function _s(t){ie[t]||Ts({...ie,[t]:{seenAt:new Date().toISOString()}})}const Ps=720*60*60*1e3,As=10080*60*1e3;function Cs(t){const[e,o,r]=t.split("-").map(Number);return!e||!o||!r?new Date(t).getTime():new Date(e,o-1,r).getTime()}function Es(t){const e=qt[0];if(!e)return null;const o=Cs(e.date),r=t-o;return r<0||r>Ps?null:e}function Os(t){if(t instanceof Date)return t.getTime();if(typeof t=="string"||typeof t=="number"){const e=new Date(t).getTime();return Number.isFinite(e)?e:null}return null}function Is(t,e){const o=Os(t);return o===null?!1:e-o>=As}function $s(){const t=R.c(46),e=G(),o=Cn(),r=Wt(),s=$t(),a=!!o,i=r===te.home&&!o;let c;t[0]!==s||t[1]!==a?(c=a&&!!s&&zt(s),t[0]=s,t[1]=a,t[2]=c):c=t[2];const m=c,{data:h}=Ue.useSession(),{isSeen:S,markSeen:u}=Ns(),p=In(6e4);let l,g,f;if(t[3]!==S||t[4]!==p||t[5]!==h?.user?.createdAt){f=Symbol.for("react.early_return_sentinel");e:{if(l=Es(p),!l){f=null;break e}if(!Is(h?.user?.createdAt,p)){f=null;break e}g=S(l.id)}t[3]=S,t[4]=p,t[5]=h?.user?.createdAt,t[6]=l,t[7]=g,t[8]=f}else l=t[6],g=t[7],f=t[8];if(f!==Symbol.for("react.early_return_sentinel"))return f;if(g)return null;let d;t[9]!==l.id||t[10]!==a||t[11]!==u||t[12]!==i||t[13]!==m||t[14]!==e?(d=()=>{u(l.id),Ss(e,{onOrgHome:i,inProject:a,onSiteEditor:m})},t[9]=l.id,t[10]=a,t[11]=u,t[12]=i,t[13]=m,t[14]=e,t[15]=d):d=t[15];const w=d;let y;t[16]!==e?(y=e("announcements.release.ariaLabel"),t[16]=e,t[17]=y):y=t[17];let x;t[18]!==e?(x=e("announcements.release.dismiss"),t[18]=e,t[19]=x):x=t[19];const v=l.eyebrow,b=l.title;let T;t[20]!==l.id||t[21]!==u?(T=()=>u(l.id),t[20]=l.id,t[21]=u,t[22]=T):T=t[22];let j;t[23]!==l.id||t[24]!==l.learnMoreHref||t[25]!==u||t[26]!==e?(j=l.learnMoreHref?n.jsx("a",{href:l.learnMoreHref,target:"_blank",rel:"noreferrer",onClick:()=>u(l.id),className:"underline-offset-2 hover:text-foreground hover:underline",children:e("announcements.release.learnMore")}):null,t[23]=l.id,t[24]=l.learnMoreHref,t[25]=u,t[26]=e,t[27]=j):j=t[27];let k;t[28]!==l.cta||t[29]!==l.id||t[30]!==u||t[31]!==w?(k=l.cta?"href"in l.cta?n.jsx(z,{asChild:!0,size:"sm",onClick:()=>u(l.id),children:n.jsx("a",{href:l.cta.href,children:l.cta.label})}):n.jsx(z,{size:"sm",onClick:w,children:l.cta.label}):null,t[28]=l.cta,t[29]=l.id,t[30]=u,t[31]=w,t[32]=k):k=t[32];let _;t[33]!==l.bullets?(_=l.bullets.map(Ls),t[33]=l.bullets,t[34]=_):_=t[34];let N;t[35]!==_?(N=n.jsx("ul",{className:"flex flex-col gap-3",children:_}),t[35]=_,t[36]=N):N=t[36];let P;return t[37]!==l.eyebrow||t[38]!==l.title||t[39]!==k||t[40]!==N||t[41]!==y||t[42]!==x||t[43]!==T||t[44]!==j?(P=n.jsx(Lt,{ariaLabel:y,dismissLabel:x,eyebrow:v,title:b,onDismiss:T,footerLeading:j,actions:k,children:N}),t[37]=l.eyebrow,t[38]=l.title,t[39]=k,t[40]=N,t[41]=y,t[42]=x,t[43]=T,t[44]=j,t[45]=P):P=t[45],P}function Ls(t,e){return n.jsxs("li",{className:"flex items-start gap-3",children:[n.jsx(t.icon,{size:20,className:"mt-0.5 shrink-0 text-muted-foreground"}),n.jsxs("div",{className:"min-w-0",children:[n.jsx("p",{className:"text-sm font-medium text-foreground",children:t.title}),n.jsx("p",{className:"text-xs text-muted-foreground",children:t.body})]})]},e)}function Ds(t){const e=R.c(11),{open:o,onOpenChange:r}=t,s=G();let a;e[0]!==s?(a=s("common.keyboardShortcutsDialog.title"),e[0]=s,e[1]=a):a=e[1];let i;e[2]!==a?(i=n.jsx(Tt,{children:n.jsx(Nt,{children:a})}),e[2]=a,e[3]=i):i=e[3];let c;e[4]===Symbol.for("react.memo_cache_sentinel")?(c=n.jsx("div",{className:"flex flex-col gap-4",children:Yt.map(Rs)}),e[4]=c):c=e[4];let m;e[5]!==i?(m=n.jsxs(_t,{className:"sm:max-w-md",children:[i,c]}),e[5]=i,e[6]=m):m=e[6];let h;return e[7]!==r||e[8]!==o||e[9]!==m?(h=n.jsx(Pt,{open:o,onOpenChange:r,children:m}),e[7]=r,e[8]=o,e[9]=m,e[10]=h):h=e[10],h}function Rs(t){return n.jsxs("div",{children:[n.jsx("h3",{className:"text-xs font-medium text-muted-foreground mb-2",children:t.label}),n.jsx("div",{className:"flex flex-col gap-1.5",children:t.shortcuts.map(zs)})]},t.label)}function zs(t){return n.jsxs("div",{className:"flex items-center justify-between py-1",children:[n.jsx("span",{className:"text-sm",children:t.description}),n.jsx("div",{className:"flex items-center gap-1",children:t.keys.map(qs)})]},t.description)}function qs(t){return n.jsx("kbd",{className:"inline-flex items-center justify-center min-w-6 h-6 px-1.5 rounded-sm border border-border bg-muted text-muted-foreground text-xs font-mono",children:t},t)}const St=8;function Fs(t){const{org:e}=ct(),o=Bn({connectionId:Ct,orgId:e.id,orgSlug:e.slug}),{data:r}=Fe({queryKey:Je.globalSearch(e.id,t,St),enabled:!!o&&t.trim().length>=2,staleTime:15e3,retry:!1,queryFn:async()=>{if(!o)return[];try{return(await o.callTool({name:"GLOBAL_SEARCH",arguments:{query:t,limit:St}})).structuredContent?.items??[]}catch{return[]}}});return r??[]}function Bs(t){const e=R.c(195),{open:o,onOpenChange:r}=t,s=G(),a=At(),{org:i}=ct(),{projects:c,hasProjects:m}=En(),[h,S]=Q.useState(""),u=Q.useDeferredValue(h),p=Fs(u);let l;e[0]!==r?(l=()=>{r(!1),S("")},e[0]=r,e[1]=l):l=e[1];const g=l;let f;e[2]!==g?(f=(B,M)=>{at("command_palette_used",{kind:M}),B(),g()},e[2]=g,e[3]=f):f=e[3];const d=f;let w;e[4]!==a||e[5]!==i.id||e[6]!==i.slug?(w=B=>{if(B.type==="connection"){if(!B.slug){a({to:"/$org/settings/connections",params:{org:i.slug},search:{tab:"all"}});return}a({to:"/$org/settings/connections/$appSlug",params:{org:i.slug,appSlug:B.slug}});return}if(B.type==="task"){a({to:te.tasks,params:{org:i.slug,taskKey:B.key??void 0}});return}const M=Et(i.id).id;Qt(a,Xt({org:i.slug,agentId:B.virtual_mcp_id??M,superAgentId:M}),{search:()=>({thread:B.id}),replace:!1})},e[4]=a,e[5]=i.id,e[6]=i.slug,e[7]=w):w=e[7];const y=w;let x;e[8]!==h?(x=[h],e[8]=h,e[9]=x):x=e[9];const v=x;let b,T,j,k,_,N,P,C,I,O,D,A,q;if(e[10]!==g||e[11]!==d||e[12]!==m||e[13]!==p||e[14]!==a||e[15]!==r||e[16]!==o||e[17]!==y||e[18]!==i.slug||e[19]!==c||e[20]!==v||e[21]!==s||e[22]!==h){const B=p.filter(Ks),M=p.filter(Ms);let J;e[36]!==i.slug?(J={org:i.slug},e[36]=i.slug,e[37]=J):J=e[37];const $=J;let V;e[38]!==s?(V=s("sidebar.navDestinations.home"),e[38]=s,e[39]=V):V=e[39];let W;e[40]===Symbol.for("react.memo_cache_sentinel")?(W=n.jsx(kn,{"aria-hidden":"true"}),e[40]=W):W=e[40];let H;e[41]!==$||e[42]!==V?(H={key:"home",label:V,icon:W,to:te.home,params:$},e[41]=$,e[42]=V,e[43]=H):H=e[43];let U;e[44]!==s?(U=s("sidebar.navDestinations.reports"),e[44]=s,e[45]=U):U=e[45];let Z;e[46]===Symbol.for("react.memo_cache_sentinel")?(Z=n.jsx(Tn,{"aria-hidden":"true"}),e[46]=Z):Z=e[46];let Y;e[47]!==$||e[48]!==U?(Y={key:"reports",label:U,icon:Z,to:te.reports,params:$},e[47]=$,e[48]=U,e[49]=Y):Y=e[49];let L;e[50]!==s?(L=s("sidebar.navDestinations.tasks"),e[50]=s,e[51]=L):L=e[51];let K;e[52]===Symbol.for("react.memo_cache_sentinel")?(K=n.jsx(pt,{"aria-hidden":"true"}),e[52]=K):K=e[52];let re;e[53]!==i.slug?(re={org:i.slug,taskKey:void 0},e[53]=i.slug,e[54]=re):re=e[54];let le;e[55]!==L||e[56]!==re?(le={key:"tasks",label:L,icon:K,to:te.tasks,params:re},e[55]=L,e[56]=re,e[57]=le):le=e[57];let ce;e[58]!==s?(ce=s("sidebar.navDestinations.library"),e[58]=s,e[59]=ce):ce=e[59];let Ve;e[60]===Symbol.for("react.memo_cache_sentinel")?(Ve=n.jsx(Nn,{"aria-hidden":"true"}),e[60]=Ve):Ve=e[60];let de;e[61]!==$||e[62]!==ce?(de={key:"library",label:ce,icon:Ve,to:te.library,params:$},e[61]=$,e[62]=ce,e[63]=de):de=e[63];let ue;e[64]!==s?(ue=s("sidebar.navDestinations.discover"),e[64]=s,e[65]=ue):ue=e[65];let We;e[66]===Symbol.for("react.memo_cache_sentinel")?(We=n.jsx(_n,{"aria-hidden":"true"}),e[66]=We):We=e[66];let me;e[67]!==$||e[68]!==ue?(me={key:"discover",label:ue,icon:We,to:te.discover,params:$},e[67]=$,e[68]=ue,e[69]=me):me=e[69];let Ye;e[70]!==H||e[71]!==Y||e[72]!==le||e[73]!==de||e[74]!==me?(Ye=[H,Y,le,de,me],e[70]=H,e[71]=Y,e[72]=le,e[73]=de,e[74]=me,e[75]=Ye):Ye=e[75];const ot=Ye;T=Ln,k=o,e[76]!==g||e[77]!==r?(_=E=>E?r(!0):g(),e[76]=g,e[77]=r,e[78]=_):_=e[78],e[79]!==s?(N=s("commandPalette.title"),e[79]=s,e[80]=N):N=e[80],e[81]!==s?(P=s("commandPalette.description"),e[81]=s,e[82]=P):P=e[82];let fe;e[83]!==s?(fe=s("commandPalette.placeholder"),e[83]=s,e[84]=fe):fe=e[84];let he;e[85]!==s?(he=s("commandPalette.placeholder"),e[85]=s,e[86]=he):he=e[86],e[87]!==fe||e[88]!==he||e[89]!==h?(C=n.jsx(Dn,{placeholder:fe,"aria-label":he,value:h,onValueChange:S}),e[87]=fe,e[88]=he,e[89]=h,e[90]=C):C=e[90],b=Rn;let ge;e[91]!==s?(ge=s("commandPalette.empty"),e[91]=s,e[92]=ge):ge=e[92],e[93]!==ge?(I=n.jsx(zn,{children:ge}),e[93]=ge,e[94]=I):I=e[94];let pe;e[95]!==s?(pe=s("commandPalette.goTo"),e[95]=s,e[96]=pe):pe=e[96];let ye;e[97]!==ot||e[98]!==d||e[99]!==a?(ye=ot.map(E=>n.jsxs(ne,{onSelect:()=>d(()=>a({to:E.to,params:E.params}),"destination"),children:[E.icon,n.jsx("span",{children:E.label})]},E.key)),e[97]=ot,e[98]=d,e[99]=a,e[100]=ye):ye=e[100],e[101]!==pe||e[102]!==ye?(O=n.jsx(Be,{heading:pe,children:ye}),e[101]=pe,e[102]=ye,e[103]=O):O=e[103],e[104]!==d||e[105]!==m||e[106]!==a||e[107]!==i.slug||e[108]!==c||e[109]!==s?(D=m&&n.jsx(Be,{heading:s("commandPalette.projects"),children:c.map(E=>n.jsxs(ne,{value:`project ${E.title}`,onSelect:()=>d(()=>a({to:te.projects,params:{org:i.slug,agentId:E.id}}),"project"),children:[n.jsx(Fn,{icon:E.icon,name:E.title,"aria-hidden":"true"}),n.jsx("span",{children:E.title})]},E.id))}),e[104]=d,e[105]=m,e[106]=a,e[107]=i.slug,e[108]=c,e[109]=s,e[110]=D):D=e[110];let be;e[111]!==s?(be=s("commandPalette.actions"),e[111]=s,e[112]=be):be=e[112];let xe;e[113]!==s?(xe=s("commandPalette.newProject"),e[113]=s,e[114]=xe):xe=e[114];let we;e[115]!==d||e[116]!==a||e[117]!==$?(we=()=>d(()=>a({to:te.home,params:$}),"new_project"),e[115]=d,e[116]=a,e[117]=$,e[118]=we):we=e[118];let Qe;e[119]===Symbol.for("react.memo_cache_sentinel")?(Qe=n.jsx(bt,{"aria-hidden":"true"}),e[119]=Qe):Qe=e[119];let Se;e[120]!==s?(Se=s("commandPalette.newProject"),e[120]=s,e[121]=Se):Se=e[121];let ve;e[122]!==Se?(ve=n.jsx("span",{children:Se}),e[122]=Se,e[123]=ve):ve=e[123];let je;e[124]!==xe||e[125]!==we||e[126]!==ve?(je=n.jsxs(ne,{value:xe,onSelect:we,children:[Qe,ve]}),e[124]=xe,e[125]=we,e[126]=ve,e[127]=je):je=e[127];let ke;e[128]!==s?(ke=s("commandPalette.inviteTeammate"),e[128]=s,e[129]=ke):ke=e[129];let Te;e[130]!==d||e[131]!==a||e[132]!==$?(Te=()=>d(()=>a({to:"/$org/settings/members",params:$}),"invite"),e[130]=d,e[131]=a,e[132]=$,e[133]=Te):Te=e[133];let Xe;e[134]===Symbol.for("react.memo_cache_sentinel")?(Xe=n.jsx(Pn,{"aria-hidden":"true"}),e[134]=Xe):Xe=e[134];let Ne;e[135]!==s?(Ne=s("commandPalette.inviteTeammate"),e[135]=s,e[136]=Ne):Ne=e[136];let _e;e[137]!==Ne?(_e=n.jsx("span",{children:Ne}),e[137]=Ne,e[138]=_e):_e=e[138];let Pe;e[139]!==ke||e[140]!==Te||e[141]!==_e?(Pe=n.jsxs(ne,{value:ke,onSelect:Te,children:[Xe,_e]}),e[139]=ke,e[140]=Te,e[141]=_e,e[142]=Pe):Pe=e[142];let Ae;e[143]!==s?(Ae=s("commandPalette.addConnection"),e[143]=s,e[144]=Ae):Ae=e[144];let Ce;e[145]!==d||e[146]!==a||e[147]!==$?(Ce=()=>d(()=>a({to:"/$org/settings/connections",params:$,search:{tab:"all"}}),"add_connection"),e[145]=d,e[146]=a,e[147]=$,e[148]=Ce):Ce=e[148];let Ze;e[149]===Symbol.for("react.memo_cache_sentinel")?(Ze=n.jsx(bt,{"aria-hidden":"true"}),e[149]=Ze):Ze=e[149];let Ee;e[150]!==s?(Ee=s("commandPalette.addConnection"),e[150]=s,e[151]=Ee):Ee=e[151];let Oe;e[152]!==Ee?(Oe=n.jsx("span",{children:Ee}),e[152]=Ee,e[153]=Oe):Oe=e[153];let Ie;e[154]!==Ae||e[155]!==Ce||e[156]!==Oe?(Ie=n.jsxs(ne,{value:Ae,onSelect:Ce,children:[Ze,Oe]}),e[154]=Ae,e[155]=Ce,e[156]=Oe,e[157]=Ie):Ie=e[157];let $e;e[158]!==s?($e=s("commandPalette.settings"),e[158]=s,e[159]=$e):$e=e[159];let Le;e[160]!==d||e[161]!==a||e[162]!==$?(Le=()=>d(()=>a({to:"/$org/settings/general",params:$}),"settings"),e[160]=d,e[161]=a,e[162]=$,e[163]=Le):Le=e[163];let et;e[164]===Symbol.for("react.memo_cache_sentinel")?(et=n.jsx($n,{"aria-hidden":"true"}),e[164]=et):et=e[164];let De;e[165]!==s?(De=s("commandPalette.settings"),e[165]=s,e[166]=De):De=e[166];let Re;e[167]!==De?(Re=n.jsx("span",{children:De}),e[167]=De,e[168]=Re):Re=e[168];let ze;e[169]!==$e||e[170]!==Le||e[171]!==Re?(ze=n.jsxs(ne,{value:$e,onSelect:Le,children:[et,Re]}),e[169]=$e,e[170]=Le,e[171]=Re,e[172]=ze):ze=e[172],e[173]!==be||e[174]!==je||e[175]!==Pe||e[176]!==Ie||e[177]!==ze?(A=n.jsxs(Be,{heading:be,children:[je,Pe,Ie,ze]}),e[173]=be,e[174]=je,e[175]=Pe,e[176]=Ie,e[177]=ze,e[178]=A):A=e[178],q=B.length>0&&n.jsx(Be,{heading:s("commandPalette.connections"),children:B.map(E=>n.jsxs(ne,{value:`${E.title} ${E.id}`,keywords:v,onSelect:()=>d(()=>y(E),"connection"),children:[n.jsx(qn,{icon:E.icon,name:E.title,size:"2xs","aria-hidden":"true"}),n.jsx("span",{className:"truncate",children:E.title})]},`connection:${E.id}`))}),j=M.length>0&&n.jsx(Be,{heading:s("commandPalette.results"),children:M.map(E=>n.jsxs(ne,{value:`${E.title} ${E.id}`,keywords:v,onSelect:()=>d(()=>y(E),E.type),children:[E.type==="thread"?n.jsx(jn,{"aria-hidden":"true"}):n.jsx(pt,{"aria-hidden":"true"}),n.jsx("span",{className:"truncate",children:E.title}),E.type==="task"&&E.key&&n.jsx("span",{className:"ml-auto shrink-0 font-mono text-xs text-muted-foreground",children:E.key})]},`${E.type}:${E.id}`))}),e[10]=g,e[11]=d,e[12]=m,e[13]=p,e[14]=a,e[15]=r,e[16]=o,e[17]=y,e[18]=i.slug,e[19]=c,e[20]=v,e[21]=s,e[22]=h,e[23]=b,e[24]=T,e[25]=j,e[26]=k,e[27]=_,e[28]=N,e[29]=P,e[30]=C,e[31]=I,e[32]=O,e[33]=D,e[34]=A,e[35]=q}else b=e[23],T=e[24],j=e[25],k=e[26],_=e[27],N=e[28],P=e[29],C=e[30],I=e[31],O=e[32],D=e[33],A=e[34],q=e[35];let F;e[179]!==b||e[180]!==j||e[181]!==I||e[182]!==O||e[183]!==D||e[184]!==A||e[185]!==q?(F=n.jsxs(b,{children:[I,O,D,A,q,j]}),e[179]=b,e[180]=j,e[181]=I,e[182]=O,e[183]=D,e[184]=A,e[185]=q,e[186]=F):F=e[186];let X;return e[187]!==T||e[188]!==k||e[189]!==_||e[190]!==N||e[191]!==P||e[192]!==C||e[193]!==F?(X=n.jsxs(T,{open:k,onOpenChange:_,title:N,description:P,children:[C,F]}),e[187]=T,e[188]=k,e[189]=_,e[190]=N,e[191]=P,e[192]=C,e[193]=F,e[194]=X):X=e[194],X}function Ms(t){return t.type!=="connection"}function Ks(t){return t.type==="connection"}const He=new Gn(!1);function Hs(){He.set(!0)}function Us(){He.set(!1)}function Gs(){const t=R.c(2),e=Q.useSyncExternalStore(He.subscribe,He.get);let o;return t[0]!==e?(o=[e,He.set],t[0]=e,t[1]=o):o=t[1],o}const Js=300*1e3,Vs=2;function Ws(t,e,o){return!e||e===o?{version:null,count:0}:t.version===e?{version:e,count:t.count+1}:{version:e,count:1}}function Ys(t,e){return t.count>=Vs&&t.version!==null&&t.version!==e}function Qs(){const t=R.c(31),e=G();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o={queryKey:Je.appVersionCheck(),queryFn:Zs,refetchInterval:Js,refetchIntervalInBackground:!0,staleTime:0},t[0]=o):o=t[0];const{data:r,dataUpdatedAt:s}=Fe(o),[a,i]=Q.useState(0);let c;t[1]===Symbol.for("react.memo_cache_sentinel")?(c={version:null,count:0},t[1]=c):c=t[1];const[m,h]=Q.useState(c);s!==a&&(i(s),h(k=>Ws(k,r,"4.531.0")));const[S,u]=Q.useState(null);if(!Ys(m,S))return null;let p;t[2]!==e?(p=e("announcements.version.ariaLabel"),t[2]=e,t[3]=p):p=t[3];let l;t[4]!==e?(l=e("announcements.version.dismiss"),t[4]=e,t[5]=l):l=t[5];let g;t[6]!==e?(g=e("announcements.version.eyebrow"),t[6]=e,t[7]=g):g=t[7];let f;t[8]!==e?(f=e("announcements.version.title"),t[8]=e,t[9]=f):f=t[9];let d;t[10]!==e?(d=e("announcements.version.description"),t[10]=e,t[11]=d):d=t[11];let w;t[12]===Symbol.for("react.memo_cache_sentinel")?(w=n.jsx(ft,{size:16}),t[12]=w):w=t[12];let y;t[13]!==m.version?(y=()=>u(m.version),t[13]=m.version,t[14]=y):y=t[14];let x;t[15]!==e?(x=e("announcements.version.currentSession",{version:"4.531.0"}),t[15]=e,t[16]=x):x=t[16];let v;t[17]!==e?(v=e("announcements.version.refresh"),t[17]=e,t[18]=v):v=t[18];let b;t[19]===Symbol.for("react.memo_cache_sentinel")?(b=n.jsx(ft,{size:14}),t[19]=b):b=t[19];let T;t[20]!==v?(T=n.jsxs(z,{size:"sm",onClick:Xs,children:[v,b]}),t[20]=v,t[21]=T):T=t[21];let j;return t[22]!==T||t[23]!==p||t[24]!==l||t[25]!==g||t[26]!==f||t[27]!==d||t[28]!==y||t[29]!==x?(j=n.jsx(Lt,{ariaLabel:p,dismissLabel:l,eyebrow:g,title:f,description:d,icon:w,tone:"system",onDismiss:y,footerLeading:x,actions:T}),t[22]=T,t[23]=p,t[24]=l,t[25]=g,t[26]=f,t[27]=d,t[28]=y,t[29]=x,t[30]=j):j=t[30],j}function Xs(){return window.location.reload()}async function Zs(){const t=await fetch("/api/config",{cache:"no-store"}),{config:e}=await t.json();return e.version}function eo(t){return{has(){try{return localStorage.getItem(t)==="1"}catch{return!1}},mark(){try{localStorage.setItem(t,"1")}catch{}}}}const to=Date.parse("2026-07-21T00:00:00Z"),vt=t=>eo(Ge.ptBrAnnouncementSeen(t));function no(){const t=R.c(35),e=G(),[o,r]=Zt(),{data:s,isPending:a}=Ue.useSession(),i=s?.user,c=i?.id,m=i?.createdAt,h=m!=null&&new Date(m).getTime()<to,S=en()==="pt-BR",u=!a&&!!c&&h&&S&&o.language==="en"&&!vt(c).has(),[p,l]=Q.useState(!1),[g,f]=Q.useState(!1);!p&&!a&&(l(!0),u&&c&&(vt(c).mark(),r(oo),f(!0),at("pt_br_auto_switch_shown")));let d;t[0]===Symbol.for("react.memo_cache_sentinel")?(d=X=>{at("pt_br_auto_switch_closed",{action:X}),f(!1)},t[0]=d):d=t[0];const w=d;let y;t[1]!==r?(y=()=>{r(so),w("switch-back")},t[1]=r,t[2]=y):y=t[2];const x=y;let v;t[3]===Symbol.for("react.memo_cache_sentinel")?(v=X=>!X&&w("dismiss"),t[3]=v):v=t[3];let b;t[4]===Symbol.for("react.memo_cache_sentinel")?(b=n.jsx("div",{className:"text-4xl","aria-hidden":"true",children:"🇧🇷"}),t[4]=b):b=t[4];let T;t[5]!==e?(T=e("announcements.ptBr.title"),t[5]=e,t[6]=T):T=t[6];let j;t[7]!==T?(j=n.jsx(Nt,{children:T}),t[7]=T,t[8]=j):j=t[8];let k;t[9]!==e?(k=e("announcements.ptBr.description"),t[9]=e,t[10]=k):k=t[10];let _;t[11]!==k?(_=n.jsx(tn,{children:k}),t[11]=k,t[12]=_):_=t[12];let N;t[13]!==j||t[14]!==_?(N=n.jsxs(Tt,{children:[j,_]}),t[13]=j,t[14]=_,t[15]=N):N=t[15];let P;t[16]!==e?(P=e("announcements.ptBr.switchBack"),t[16]=e,t[17]=P):P=t[17];let C;t[18]!==x||t[19]!==P?(C=n.jsx(z,{variant:"outline",onClick:x,children:P}),t[18]=x,t[19]=P,t[20]=C):C=t[20];let I;t[21]===Symbol.for("react.memo_cache_sentinel")?(I=()=>w("ok"),t[21]=I):I=t[21];let O;t[22]!==e?(O=e("announcements.ptBr.ok"),t[22]=e,t[23]=O):O=t[23];let D;t[24]!==O?(D=n.jsx(z,{onClick:I,children:O}),t[24]=O,t[25]=D):D=t[25];let A;t[26]!==C||t[27]!==D?(A=n.jsxs(nn,{children:[C,D]}),t[26]=C,t[27]=D,t[28]=A):A=t[28];let q;t[29]!==A||t[30]!==N?(q=n.jsxs(_t,{className:"sm:max-w-md",children:[b,N,A]}),t[29]=A,t[30]=N,t[31]=q):q=t[31];let F;return t[32]!==g||t[33]!==q?(F=n.jsx(Pt,{open:g,onOpenChange:v,children:q}),t[32]=g,t[33]=q,t[34]=F):F=t[34],F}function so(t){return{...t,language:"en"}}function oo(t){return{...t,language:"pt-BR"}}function io(t){const e=sn(t);return typeof e=="string"?e:void 0}function ao(){return io("experiment-pipeline-check"),null}function ro(t){const e=R.c(1),{activeOrg:o}=t;if(!o)return null;on(o.id,{name:o.name??void 0,slug:o.slug??void 0}),an();let r;return e[0]===Symbol.for("react.memo_cache_sentinel")?(r=n.jsx(ao,{}),e[0]=r):r=e[0],r}function lo(t){const{prev:e,virtualMcpId:o,decopilotId:r,savedLayout:s,opts:a,autosendValue:i}=t,c={mainpanel:void 0};o?c.virtualmcpid=o:e.virtualmcpid&&(c.virtualmcpid=e.virtualmcpid);const m=typeof e.virtualmcpid=="string"?e.virtualmcpid:r,S=(o??m)!==m;let u,p;return a?.panel?p=a.panel:a?.newThread&&!S&&rn(e.tabId)?(p=e.tabId,c.mainpanel=e.mainpanel,u=e.sidepanel):s?(p=s.tab,s.sidepanel!==void 0&&(u=s.sidepanel),s.mainpanel!==void 0&&(c.mainpanel=s.mainpanel)):!S&&e.tabId&&!ln(e.tabId)&&(p=e.tabId),u!==void 0&&(c.sidepanel=u),a?.autosend&&(c.autosend=i),{tabId:p,search:c}}const Bt="studio:thread-layout:v4",co=50;function Mt(t){const e={};return t===null||typeof t!="object"||(typeof t.tab=="string"&&(e.tab=t.tab),typeof t.mainpanel=="boolean"&&(e.mainpanel=t.mainpanel),typeof t.sidepanel=="boolean"&&(e.sidepanel=t.sidepanel)),e}function uo(t,e,o,r=co){const s=t.filter(([a])=>a!==e);for(s.push([e,Mt(o)]);s.length>r;)s.shift();return s}function dt(){try{const t=sessionStorage.getItem(Bt);if(!t)return[];const e=JSON.parse(t);return Array.isArray(e)?e.filter(o=>Array.isArray(o)&&o.length===2&&typeof o[0]=="string"):[]}catch{return[]}}function Kt(t){try{sessionStorage.setItem(Bt,JSON.stringify(t))}catch{}}function mo(t,e){t&&Kt(uo(dt(),t,e))}function fo(t){if(!t)return null;const e=dt().find(([o])=>o===t);return e?Mt(e[1]):null}function Zo(t){if(!t)return;const e=dt(),o=e.filter(([r])=>r!==t);o.length!==e.length&&Kt(o)}function Ht(t){return{queryKey:Je.homeNextActions(t),queryFn:async()=>{const e=await fetch(`/api/${t}/home-next-actions`,{cache:"no-store"});if(!e.ok)throw new Error("Failed to load home next actions");return await e.json()},staleTime:0,refetchOnWindowFocus:"always"}}function ei(t){const e=R.c(10);let o;e[0]!==t?(o=Ht(t),e[0]=t,e[1]=o):o=e[1];const r=Fe(o);let s;e[2]!==r.data?.prompts?(s=r.data?.prompts??[],e[2]=r.data?.prompts,e[3]=s):s=e[3];let a;e[4]!==r.data?.tiles?(a=r.data?.tiles??[],e[4]=r.data?.tiles,e[5]=a):a=e[5];let i;return e[6]!==r.isLoading||e[7]!==s||e[8]!==a?(i={isLoading:r.isLoading,prompts:s,tiles:a},e[6]=r.isLoading,e[7]=s,e[8]=a,e[9]=i):i=e[9],i}function ho(t){const e=R.c(31),{orgSlug:o,orgName:r,domain:s}=t,a=G();let i;e[0]!==o?(i=()=>{window.location.href=`/api/${encodeURIComponent(o)}/sso/authorize`},e[0]=o,e[1]=i):i=e[1];const c=i,m=go;let h;e[2]===Symbol.for("react.memo_cache_sentinel")?(h=n.jsx("div",{className:"bg-primary/10 p-3 rounded-full","aria-hidden":"true",children:n.jsx(jt,{className:"h-6 w-6 text-primary"})}),e[2]=h):h=e[2];let S;e[3]!==a?(S=a("common.ssoRequiredScreen.title"),e[3]=a,e[4]=S):S=e[4];let u;e[5]!==S?(u=n.jsx("h3",{className:"text-lg font-medium",children:S}),e[5]=S,e[6]=u):u=e[6];let p;e[7]!==s||e[8]!==r||e[9]!==a?(p=r?n.jsxs(n.Fragment,{children:[n.jsx("strong",{children:r})," ",a("common.ssoRequiredScreen.requiresSsoAuth"),s?` ${a("common.ssoRequiredScreen.via",{domain:s})}`:"","."]}):a("common.ssoRequiredScreen.orgRequiresSsoAuth"),e[7]=s,e[8]=r,e[9]=a,e[10]=p):p=e[10];let l;e[11]!==p?(l=n.jsx("p",{className:"text-sm text-muted-foreground",children:p}),e[11]=p,e[12]=l):l=e[12];let g;e[13]!==u||e[14]!==l?(g=n.jsxs("div",{className:"space-y-2",children:[u,l]}),e[13]=u,e[14]=l,e[15]=g):g=e[15];let f;e[16]!==a?(f=a("common.ssoRequiredScreen.signInWithSso"),e[16]=a,e[17]=f):f=e[17];let d;e[18]!==c||e[19]!==f?(d=n.jsx(z,{onClick:c,children:f}),e[18]=c,e[19]=f,e[20]=d):d=e[20];let w;e[21]!==a?(w=a("common.goBack"),e[21]=a,e[22]=w):w=e[22];let y;e[23]!==w?(y=n.jsx(z,{variant:"ghost",onClick:m,children:w}),e[23]=w,e[24]=y):y=e[24];let x;e[25]!==y||e[26]!==d?(x=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[d,y]}),e[25]=y,e[26]=d,e[27]=x):x=e[27];let v;return e[28]!==x||e[29]!==g?(v=n.jsxs(ae,{children:[h,g,x]}),e[28]=x,e[29]=g,e[30]=v):v=e[30],v}function go(){window.location.href="/"}function po(t){const e=R.c(27),{notice:o,orgSlug:r}=t,s=G();let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a=n.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:n.jsx(cn,{className:"h-6 w-6 text-destructive"})}),e[0]=a):a=e[0];let i;e[1]!==o.title?(i=n.jsx("h3",{className:"text-lg font-medium",children:o.title}),e[1]=o.title,e[2]=i):i=e[2];let c;e[3]!==o.message?(c=n.jsx("p",{className:"text-sm text-muted-foreground whitespace-pre-line",children:o.message}),e[3]=o.message,e[4]=c):c=e[4];let m;e[5]!==i||e[6]!==c?(m=n.jsxs("div",{className:"space-y-2",children:[i,c]}),e[5]=i,e[6]=c,e[7]=m):m=e[7];let h;e[8]!==o.ctaLabel||e[9]!==o.ctaUrl?(h=o.ctaUrl&&o.ctaLabel?n.jsx(z,{asChild:!0,children:n.jsx("a",{href:o.ctaUrl,target:"_blank",rel:"noreferrer noopener",children:o.ctaLabel})}):null,e[8]=o.ctaLabel,e[9]=o.ctaUrl,e[10]=h):h=e[10];const S=`/${encodeURIComponent(r)}/settings/infra-billing`;let u;e[11]!==s?(u=s("common.blockedOrgScreen.goToBilling"),e[11]=s,e[12]=u):u=e[12];let p;e[13]!==S||e[14]!==u?(p=n.jsx(z,{variant:"outline",asChild:!0,children:n.jsx("a",{href:S,children:u})}),e[13]=S,e[14]=u,e[15]=p):p=e[15];let l;e[16]!==s?(l=s("common.blockedOrgScreen.switchOrg"),e[16]=s,e[17]=l):l=e[17];let g;e[18]!==l?(g=n.jsx(z,{variant:"ghost",asChild:!0,children:n.jsx("a",{href:"/",children:l})}),e[18]=l,e[19]=g):g=e[19];let f;e[20]!==g||e[21]!==h||e[22]!==p?(f=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[h,p,g]}),e[20]=g,e[21]=h,e[22]=p,e[23]=f):f=e[23];let d;return e[24]!==f||e[25]!==m?(d=n.jsxs(ae,{children:[a,m,f]}),e[24]=f,e[25]=m,e[26]=d):d=e[26],d}function yo(t){const e=R.c(8);let o;e[0]!==t?(o=Je.orgNotice(t??""),e[0]=t,e[1]=o):o=e[1];let r;e[2]!==t?(r=async()=>{const i=await fetch(`/api/${t}/notice`,{credentials:"include"});return i.ok?(await i.json()).notice??null:null},e[2]=t,e[3]=r):r=e[3];const s=!!t;let a;return e[4]!==o||e[5]!==r||e[6]!==s?(a={queryKey:o,queryFn:r,enabled:s,staleTime:6e4},e[4]=o,e[5]=r,e[6]=s,e[7]=a):a=e[7],Fe(a)}const bo="/settings/infra-billing";function xo(t){return(t.endsWith("/")?t.slice(0,-1):t).endsWith(bo)}function wo(t){const e=R.c(7),{org:o,children:r}=t;let s;e[0]!==o.id||e[1]!==o.name?(s={id:o.id,organizationId:o.id,slug:"_org",name:o.name,ui:null},e[0]=o.id,e[1]=o.name,e[2]=s):s=e[2];const a=s;let i;return e[3]!==r||e[4]!==o||e[5]!==a?(i=n.jsx(yn,{org:o,project:a,children:r}),e[3]=r,e[4]=o,e[5]=a,e[6]=i):i=e[6],i}function So(){const t=At(),e=Jn(),{org:o}=ct(),r=dn({strict:!1}),s=$t(),{openPanel:a,closePanel:i}=On(),c=Yn(),m=Qn(),h=Xn(),S=Zn(),u=(f,d=!0)=>t({to:".",search:f,replace:d}),p=()=>u(f=>({...f,sidepanel:!0})),l=(f,d,w)=>{const y=!!m&&m===f;m&&!y&&mo(m,{tab:s,mainpanel:r.mainpanel,sidepanel:r.sidepanel});const x=y?null:fo(f),v=Et(o.id).id,b=lo({prev:{virtualmcpid:c,tabId:s,mainpanel:r.mainpanel,sidepanel:r.sidepanel},virtualMcpId:d,decopilotId:v,savedLayout:x,opts:w,autosendValue:Wn});return S(f,()=>b.search,{virtualMcpId:d,view:{tabId:b.tabId}})};return{openSidePanel:p,setTaskId:l,createNewTask:async(f,d,w)=>{const y=crypto.randomUUID(),x=f??h;try{await e?.create({id:y,virtual_mcp_id:x,...d?{branch:d}:{}})}catch{}l(y,x,{...w,newThread:!0})},openTab:a,closeTab:i}}const vo=new Set(["/$org/","/$org/home"]);function jo(){const t=R.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e={select:ko},t[0]=e):e=t[0],Ot(e)}function ko(t){const e=t.matches.at(-1)?.fullPath;return e!==void 0&&vo.has(e)}function To(){const t=R.c(53);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/shell/$org",shouldThrow:!1},t[0]=e):e=t[0];const r=un(e)?.params.org,[s,a]=Q.useState(!1),[i,c]=Gs(),[m,h]=Kn(),S=mn(),u=jo(),p=r??"";let l;t[1]!==p?(l=Ht(p),t[1]=p,t[2]=l):l=t[2];const g=!!r&&u;let f;t[3]!==l||t[4]!==g?(f={...l,enabled:g},t[3]=l,t[4]=g,t[5]=f):f=t[5],Fe(f);const{data:d}=Ue.useSession(),w=d?.user?.id;let y,x;t[6]!==S?(y=()=>{const L=K=>{if(gt(K)&&K.code==="KeyK"){K.preventDefault(),Hs();return}if(K.key==="?"&&!pn(K.target)){K.preventDefault(),a(!0);return}gt(K)&&K.code==="BracketLeft"&&S.history.canGoBack()&&(K.preventDefault(),S.history.back())};return document.addEventListener("keydown",L),()=>document.removeEventListener("keydown",L)},x=[S],t[6]=S,t[7]=y,t[8]=x):(y=t[7],x=t[8]),Q.useEffect(y,x);let v;t[9]!==r||t[10]!==w?(v=fn(r,w),t[9]=r,t[10]=w,t[11]=v):v=t[11];const{data:b}=kt(v),T=b?.id,j=b?.slug,{data:k}=es(T,j),_=!!k?.ssoRequired&&!k.authenticated,{data:N}=yo(j);let P;t[12]===Symbol.for("react.memo_cache_sentinel")?(P={select:No},t[12]=P):P=t[12];const C=Ot(P),I=N?.severity==="block"&&!xo(C),O=T??"",D=j??"";let A;t[13]!==D||t[14]!==O?(A=Mn({connectionId:Ct,orgId:O,orgSlug:D}),t[13]=D,t[14]=O,t[15]=A):A=t[15];const q=!!T&&!!j;let F;if(t[16]!==A||t[17]!==q?(F={...A,enabled:q},t[16]=A,t[17]=q,t[18]=F):F=t[18],Fe(F),(!b||ht(b)||_||I)&&Us(),!b){let L;return t[19]!==r?(L=n.jsx(us,{orgSlug:r}),t[19]=r,t[20]=L):L=t[20],L}if(ht(b)){localStorage.getItem(Ge.lastOrgSlug())===r&&localStorage.removeItem(Ge.lastOrgSlug());let L;return t[21]!==b.name?(L=n.jsx(hn,{orgName:b.name}),t[21]=b.name,t[22]=L):L=t[22],L}if(I&&N){let L;return t[23]!==b.slug||t[24]!==N?(L=n.jsx(po,{notice:N,orgSlug:b.slug}),t[23]=b.slug,t[24]=N,t[25]=L):L=t[25],L}if(_){let L;return t[26]!==b.id||t[27]!==b.name||t[28]!==b.slug||t[29]!==k.domain?(L=n.jsx(ho,{orgId:b.id,orgSlug:b.slug,orgName:b.name,domain:k.domain}),t[26]=b.id,t[27]=b.name,t[28]=b.slug,t[29]=k.domain,t[30]=L):L=t[30],L}const B=b.logo??null;let M;t[31]!==b||t[32]!==B?(M={...b,logo:B},t[31]=b,t[32]=B,t[33]=M):M=t[33];let J;t[34]!==b?(J=n.jsx(ro,{activeOrg:b}),t[34]=b,t[35]=J):J=t[35];let $;t[36]===Symbol.for("react.memo_cache_sentinel")?($=n.jsx(gn,{}),t[36]=$):$=t[36];let V;t[37]===Symbol.for("react.memo_cache_sentinel")?(V=n.jsxs("div",{className:"fixed bottom-6 right-6 z-50 flex w-[min(360px,calc(100vw-3rem))] flex-col gap-3",children:[n.jsx($s,{}),n.jsx(Qs,{})]}),t[37]=V):V=t[37];let W;t[38]!==i||t[39]!==c?(W=i&&n.jsx(Bs,{open:i,onOpenChange:c}),t[38]=i,t[39]=c,t[40]=W):W=t[40];let H;t[41]!==m||t[42]!==h?(H=m&&n.jsx(Hn,{open:!0,onOpenChange:h,source:Un()}),t[41]=m,t[42]=h,t[43]=H):H=t[43];let U;t[44]!==s?(U=n.jsx(Ds,{open:s,onOpenChange:a}),t[44]=s,t[45]=U):U=t[45];let Z;t[46]===Symbol.for("react.memo_cache_sentinel")?(Z=n.jsx(no,{}),t[46]=Z):Z=t[46];let Y;return t[47]!==M||t[48]!==J||t[49]!==W||t[50]!==H||t[51]!==U?(Y=n.jsxs(wo,{org:M,children:[J,$,V,W,H,U,Z]}),t[47]=M,t[48]=J,t[49]=W,t[50]=H,t[51]=U,t[52]=Y):Y=t[52],Y}function No(t){return t.location.pathname}function _o(){const t=R.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=n.jsx(Vn,{children:n.jsx(To,{})}),t[0]=e):e=t[0],e}const ti=Object.freeze(Object.defineProperty({__proto__:null,default:_o,usePanelActions:So},Symbol.toStringTag,{value:"Module"}));export{ms as L,So as a,vs as b,ei as c,ti as d,Zo as f,zt as i,Hs as o,Qo as r,Xo as s,yo as u};
@@ -1 +0,0 @@
1
- import{c as u,r as g,j as n,H as F,$ as G,a0 as H,a as E,k as P,b as O,n as y,L as M}from"./index-C8YP0XfX.js";import{C as V}from"./chat-context-BI1yxU4R.js";import{C as x}from"./index-C6KhNCz4.js";import{L}from"./index-EfujrlRm.js";import{B as K}from"./blocks-preview-workspace-context-Dd8qSyOR.js";import{e as T,p as W,s as J,a as U,r as z,T as $,u as R,b as q}from"./site-editor-toast-D9ddy9a_.js";import{u as Q,L as B,P as X,S as Y}from"./preview-tab-W7cmZoDH.js";import{C as Z}from"./content-tab-CxqGwsRS.js";import{T as tt}from"./tab-icon-glyph-D22-rmWX.js";import{r as et}from"./resolve-tab-icon-BZyAXpM2.js";import ot from"./agent-site-editor-C0ubqGd6.js";import"./use-panel-navigate-CTWNyrxK.js";import"./thread-route-JcxEqRgq.js";import"./use-project-scope-BgLQY0Uk.js";import"./repository-binding-B-4PI1n3.js";import"./use-mcp-client-CkAT8dMu.js";import"./auth-fndLm_KR.js";import"./autosend-VKc1dW3G.js";import"./thread-intent-Cl7xa7dA.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./watch-sse-pool-B-0VhxE7.js";import"./task-board-u5TablbK.js";import"./schema-CFje17_E.js";import"./slugify-CEUa2lfQ.js";import"./use-decopilot-events-hbubA99f.js";import"./use-ai-providers-DzWzPq_c.js";import"./location-V0VwTJTt.js";import"./use-organization-settings-6EqlUT2Y.js";import"./use-mobile-tv6dKHC3.js";import"./use-sidebar-collapsed-BwFu6Qgg.js";import"./use-chat-layout-state-DIXRUqxC.js";import"./agent-icon-B7Q7dFXY.js";import"./AlertCircle-C0U53qC5.js";import"./Tool01-CTKnipD_.js";import"./ArrowUp-BnowdRj-.js";import"./ArrowLeft-BVJNIiuT.js";import"./LinkBroken01-BZrnscWF.js";import"./ShoppingBag01-BaMIB-e_.js";import"./ZoomOut-BVuJZ-2t.js";import"./Building02-CcI-P3yL.js";import"./CheckCircle-fAPMl2yd.js";import"./ChevronUp-BMY88wXt.js";import"./ChevronSelectorVertical-C-CIIDml.js";import"./UserSquare-D4xudMmb.js";import"./Copy01-DGy0Absz.js";import"./CreditCard01-DsjBhiEj.js";import"./DotsVertical-Bfe9a_On.js";import"./Image01-DtpDUrwF.js";import"./Globe04-B-sNlZxN.js";import"./SwitchHorizontal01-fMsLFMs0.js";import"./Key01-DifqnYu0.js";import"./Link01-oZZyGItc.js";import"./Minus-Dc5wow6R.js";import"./Monitor01-Bmn1BV5T.js";import"./Sun-BZlKwpGn.js";import"./Play-IViIK9Vy.js";import"./Plus-Bh_xMwh7.js";import"./SearchMd-DB3np2ti.js";import"./Trash01-BqP8uw7k.js";import"./Upload01-CpPArzNK.js";import"./Users01-buCmBl1X.js";import"./XClose-D48r2tDo.js";import"./tooltip-CJHeHoSn.js";import"./index-B0Rg86vv.js";import"./toolbar-icon-button-BUMG5B6x.js";import"./shell-layout-uDYSTXA5.js";import"./use-clock-tick-DxI4Q15z.js";import"./command-jlI8eprh.js";import"./index-BM9HifS6.js";import"./integration-icon-03FWmed-.js";import"./project-icon-BSrEdWN1.js";import"./new-project-dialog-BuE_SqTn.js";import"./label-BZDtWIcv.js";import"./repository-import-picker-BfMMau5M.js";import"./use-navigate-to-agent-BiKQMaG5.js";import"./repository-picker-CbWFb7rK.js";import"./useInfiniteQuery-LBIaZPt-.js";import"./infiniteQueryObserver-C8Tx1h_G.js";import"./collection-search-B_n3Ea8A.js";import"./use-debounced-value-ZtANdTDD.js";import"./required-auth-layout-ofmCqqpc.js";import"./use-org-sso-BK4EESlq.js";import"./sheet-ko7a2Uwq.js";import"./resizable-KZ7XhVXp.js";import"./core.esm-CfGX-VCE.js";import"./sortable.esm-Bk2g_Gbz.js";import"./context-menu-Ckmk21Ru.js";import"./create-organization-dialog-Byea9wm5.js";import"./form-DmKuBQlJ.js";import"./project-apps-CTDjuD3G.js";import"./use-recent-apps-Bpx38utr.js";import"./use-session-runtime-pkeEtIbf.js";import"./experiments-tab-choice-D5E9lbe8.js";import"./sandbox-url-D3mC8qhT.js";import"./utils-Chh_XkCj.js";import"./use-sandbox-events-Ccm6tkYH.js";import"./sandbox-git-api-DcqI6XE4.js";import"./held-block-view-BCUOCB3X.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./pair-DEJAc3iG.js";import"./collapsible-B5J2aUd-.js";import"./use-copy-BCht-61u.js";import"./usage-stats-CNcWehA3.js";import"./tool-namespace-ChbHxLTp.js";import"./utils-CVEq3hMx.js";import"./markdown-DuoP9xIE.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-DWv_y82s.js";import"./types-Cwtot2FB.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./use-connection-ClhLV4Ep.js";import"./use-mcp-prompts-BoifdA0D.js";import"./use-thread-outputs-am5Vd3rC.js";import"./file-type-icon-CLdhbOMq.js";import"./section-array-field-CWeYHp0D.js";import"./alert-CHj-Usrj.js";import"./parse-sections-B8Xcvgnu.js";import"./blocks-tab-states-BUek9Urr.js";import"./slider-Bg5y5q23.js";import"./index-Dc2A9bLg.js";import"./index-BdQq_4o_.js";import"./tooltipContext-CL92GCVz.js";import"./CategoricalChart-CukPvNkf.js";import"./index-CzZ16hae.js";import"./ActiveShapeUtils-CUGYcOGt.js";import"./Sector-BbL3mZ4i.js";import"./symbol-DLC3ejqz.js";import"./empty-state-CUanQ9Sm.js";import"./switch-DbWQrL2t.js";import"./textarea-BeCs38v-.js";import"./popover-C0DIKe_3.js";import"./scroll-area-BSd3TrLZ.js";import"./monaco-editor-a3IVCcn2.js";import"./editor-CVSwKg6T.js";import"./calendar-BZJL1q0i.js";import"./select-EVDcG5Hl.js";import"./editor-classes-Dkk1S2M6.js";import"./toggle-group-CWnjwOku.js";import"./active-indicator-CCMhAsc_.js";import"./combobox-BBB78IeP.js";import"./search-input-CIT_dMpA.js";import"./tabs-BbA4-8ma.js";import"./use-file-configs-DI3WjDeq.js";import"./asset-utils-BvYMWLJK.js";import"./match-site-slug-config-D3fUJ6vX.js";import"./sandbox-lifecycle-context-DQ3bjzwr.js";import"./variant-matcher-override-DV7ZKzex.js";import"./variant-draft-pointer-BeAKcq_c.js";import"./section-preview-url-7zfngvgW.js";import"./use-fast-preview-draft-url-CoOfoUO_.js";import"./preview-link-C762yHOt.js";import"./useQueries-Chr0IN_s.js";import"./device-hint-SeLRi17j.js";import"./virtual-mcp-2K3oYMwm.js";import"./url-slug-Dxr7jq0i.js";import"./app-preview-url-9Od4s8Sz.js";import"./preview-source-BsRLGWUP.js";import"./use-task-metadata-D2I0K9KW.js";import"./view-header-ECu4qrb6.js";import"./use-cms-publish-actions-B4udZvVh.js";import"./hosted-publish-feedback-BX6h3oNP.js";import"./mustache-BBa51FCf.js";import"./checkbox-BGiVnH_E.js";import"./date-utils-CrvIKg-s.js";import"./use-move-blocks-BaNRn466.js";import"./badge-AFOqFwvQ.js";import"./empty-state-BdJInz6a.js";import"./collection-table-wrapper-Dms92TX1.js";import"./table-CIbHZF2_.js";import"./site-draft-actions-PtNrOTTk.js";import"./separator-Czsq0Xe-.js";import"./use-releases-t7sfkrxl.js";import"./serial-task-queue-CGOeQgpr.js";import"./index-_MLEN3sq.js";import"./drawer-9GcYCTZT.js";import"./input-DjstRX-_.js";import"./icon-button-Rp_ZDDhs.js";import"./chat-draft-B9Sz9SQX.js";import"./use-deco-credits-D7afhnU-.js";import"./use-open-billing-url-6v7Ht1P5.js";import"./index-CPu0T3g-.js";import"./ai-providers-logos-DD3qZ33J.js";import"./input-DRaRHcY2.js";import"./suggestion-Bl_JrZPN.js";import"./use-org-fs-ao97Epgk.js";import"./question-004-sINsf4GQ.js";import"./feature-paywall-BIJDHy8g.js";import"./plan-ladder-B0TVgJ_-.js";import"./add-connection-dialog-o9V9M7_d.js";import"./extract-connection-data-BH85Ecx-.js";import"./metadata-D72DunRR.js";import"./connection-_BLwZIho.js";import"./connection-card-DOb0qtir.js";import"./connection-slug-CITJ0kGN.js";import"./schema-nUWXGpCy.js";import"./connection-form-helpers-Do-juNEt.js";import"./authenticate-and-persist-oauth-D7QWYyhR.js";import"./mcp-oauth-CsfxxKaN.js";import"./mcp-oauth-D-fSN__A.js";import"./collection-tabs-CRfyt8-K.js";import"./use-infinite-scroll-CuF9Fnt8.js";import"./useSuspenseInfiniteQuery-ClnVveRy.js";import"./use-task-board-events-DGIxUFSu.js";import"./named-rule-uses-Yzjx02p5.js";import"./save-changes-debug-nBi-n9eV.js";import"./releases-api-DGMi80FZ.js";function I(e){return e.kind==="unavailable"&&e.source==="local"&&(e.problem?.reason??"not-answering")==="not-answering"}const it=e=>e;function rt(e){const t=u.c(10),{candidates:o,invalidLink:c,shell:m,editor:i}=e,r=c===void 0?!1:c,s=m===void 0?it:m,[p,l]=g.useState(null);if(p){let f;t[0]===Symbol.for("react.memo_cache_sentinel")?(f=()=>l(null),t[0]=f):f=t[0];let h;return t[1]!==p||t[2]!==i?(h=i(p,f),t[1]=p,t[2]=i,t[3]=h):h=t[3],h}let a;t[4]!==o||t[5]!==r?(a=n.jsx(nt,{candidates:o,invalidLink:r,onConnect:l}),t[4]=o,t[5]=r,t[6]=a):a=t[6];let d;return t[7]!==s||t[8]!==a?(d=s(a),t[7]=s,t[8]=a,t[9]=d):d=t[9],d}function nt(e){const t=u.c(17),{candidates:o,invalidLink:c,onConnect:m}=e,i=c===void 0?!1:c,[r]=F(),{language:s}=r;let p;t[0]!==m?(p=D=>m({endpoint:D}),t[0]=m,t[1]=p):p=t[1];let l;t[2]!==o||t[3]!==p?(l={candidates:o,onFound:p},t[2]=o,t[3]=p,t[4]=l):l=t[4];const a=Q(l),{state:d,access:f,needsGesture:h}=a;let k;t[5]!==o||t[6]!==s?(k=new Intl.ListFormat(s,{style:"long",type:"conjunction"}).format(o.map(T)),t[5]=o,t[6]=s,t[7]=k):k=t[7];const C=k;let j;t[8]!==f||t[9]!==a.start||t[10]!==h||t[11]!==d?(j=f==="denied"?{kind:"denied"}:h?{kind:"needs-gesture",onStart:a.start}:d.problem?{kind:"problem",problem:d.problem,host:T(d.problem.endpoint)}:{kind:"looking",paused:d.status==="paused"},t[8]=f,t[9]=a.start,t[10]=h,t[11]=d,t[12]=j):j=t[12];const _=j;let S;return t[13]!==C||t[14]!==i||t[15]!==_?(S=n.jsx(B,{wait:_,hosts:C,invalidLink:i}),t[13]=C,t[14]=i,t[15]=_,t[16]=S):S=t[16],S}const v="deco-serve",w="working-tree",st={id:"",slug:"",name:"",logo:null},mt={id:v,slug:v},pt={virtualMcpId:v,taskId:null,openTask:()=>{},createTask:()=>"",createTaskWithMessage:()=>{},activeTask:null,isThreadLocked:!1,lockedHarness:null,lockedBranch:null,currentBranch:w,setCurrentTaskBranch:()=>{}};function at(){const e=window.location.hash,t=new URLSearchParams(e.replace(/^#/,"")).has("endpoint"),o=t?W(e):null;return t&&window.history.replaceState(null,"",window.location.pathname+window.location.search),o&&J(o),{candidates:U(o,z()),invalidLink:t&&!o}}const ct=[{id:"site-editor",to:"/site-editor",label:"preview"},{id:"content",to:"/site-editor/content",label:"content"}];function lt(){const e=u.c(6),t=O();let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={select:dt},e[0]=o):o=e[0];const c=P(o);let m;e[1]!==t||e[2]!==c?(m=ct.map(r=>n.jsx(y.Tab,{asChild:!0,active:c==="content"==(r.id==="content"),children:n.jsxs(M,{to:r.to,activeOptions:{exact:!0},children:[n.jsx("span",{"aria-hidden":"true",className:"flex size-4 shrink-0 items-center justify-center",children:n.jsx(tt,{icon:et({tabId:r.id,kind:"system",connections:[]})})}),t(`common.mainPanelTabs.${r.label}`)]})},r.id)),e[1]=t,e[2]=c,e[3]=m):m=e[3];let i;return e[4]!==m?(i=n.jsx(y.Tabs,{children:m}),e[4]=m,e[5]=i):i=e[5],i}function dt(e){return e.matches.at(-1)?.staticData.siteEditorView}function N(e){const t=u.c(14),{children:o}=e,c=O(),{connection:m}=q(v),i=R(v,w);let r,s;if(t[0]!==i||t[1]!==o||t[2]!==m||t[3]!==c){s=Symbol.for("react.early_return_sentinel");t:{if(r=m?T(m.endpoint):"",i.kind==="protocol"){s=o;break t}if(i.kind!=="unavailable"||I(i)){s=n.jsx(Y,{headingLevel:2,waiting:!0,title:c("decoServe.connect.reaching",{host:r})});break t}}t[0]=i,t[1]=o,t[2]=m,t[3]=c,t[4]=r,t[5]=s}else r=t[4],s=t[5];if(s!==Symbol.for("react.early_return_sentinel"))return s;let p;t[6]!==i.problem?(p=i.problem??{reason:"not-answering"},t[6]=i.problem,t[7]=p):p=t[7];let l;t[8]!==r||t[9]!==p?(l={kind:"problem",problem:p,host:r},t[8]=r,t[9]=p,t[10]=l):l=t[10];let a;return t[11]!==r||t[12]!==l?(a=n.jsx(B,{wait:l,hosts:r}),t[11]=r,t[12]=l,t[13]=a):a=t[13],a}function ut(e){const t=u.c(6),{onLost:o}=e,c=R(v,w);let m;t[0]!==c?(m=I(c),t[0]=c,t[1]=m):m=t[1];const i=m;let r,s;return t[2]!==i||t[3]!==o?(r=()=>{i&&o()},s=[i,o],t[2]=i,t[3]=o,t[4]=r,t[5]=s):(r=t[4],s=t[5]),g.useEffect(r,s),null}const A={threadOpen:!1,contentOpen:!0,threadVisibilityExplicit:!1,toggleThread:()=>{},toggleContent:()=>{}};function ft(){const e=u.c(11),{data:t}=E.useSession();let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={select:ht},e[0]=o):o=e[0];const c=P(o),m=!!t?.user;let i;e[1]!==m?(i={rail:m},e[1]=m,e[2]=i):i=e[2];const r=c??"preview";let s,p,l;e[3]===Symbol.for("react.memo_cache_sentinel")?(s=n.jsx(lt,{}),p=n.jsx(x.Thread,{children:null}),l=n.jsx(ot,{}),e[3]=s,e[4]=p,e[5]=l):(s=e[3],p=e[4],l=e[5]);let a;e[6]!==r?(a=n.jsx(L.Content,{children:n.jsxs(x,{...A,threadless:!0,contentKey:r,contentNavigation:s,children:[p,l]})}),e[6]=r,e[7]=a):a=e[7];let d;return e[8]!==i||e[9]!==a?(d=n.jsx(L,{outsideOrg:i,children:a}),e[8]=i,e[9]=a,e[10]=d):d=e[10],d}function ht(e){return e.matches.at(-1)?.staticData.siteEditorView}function vt(e){const t=u.c(8),{children:o}=e,{data:c}=E.useSession(),m=!!c?.user;let i;t[0]!==m?(i={rail:m},t[0]=m,t[1]=i):i=t[1];let r;t[2]===Symbol.for("react.memo_cache_sentinel")?(r=n.jsx(x.Thread,{children:null}),t[2]=r):r=t[2];let s;t[3]!==o?(s=n.jsx(L.Content,{children:n.jsxs(x,{...A,threadless:!0,contentKey:"guide",children:[r,n.jsx(x.Content,{children:o})]})}),t[3]=o,t[4]=s):s=t[4];let p;return t[5]!==i||t[6]!==s?(p=n.jsx(L,{outsideOrg:i,children:s}),t[5]=i,t[6]=s,t[7]=p):p=t[7],p}const b=()=>{},xt={connection:null,set:b,clear:b};function dr(){const e=u.c(3),[t]=g.useState(at);let o;return e[0]!==t.candidates||e[1]!==t.invalidLink?(o=n.jsx(G,{value:!0,children:n.jsx(H,{org:st,project:mt,children:n.jsx(rt,{candidates:t.candidates,invalidLink:t.invalidLink,shell:jt,editor:kt})})}),e[0]=t.candidates,e[1]=t.invalidLink,e[2]=o):o=e[2],o}function kt(e,t){return n.jsxs($.Provider,{value:{connection:e,set:b,clear:b},children:[n.jsx(ut,{onLost:t}),n.jsx(V,{value:pt,children:n.jsx(K,{children:n.jsx(ft,{})})})]})}function jt(e){return n.jsx($.Provider,{value:xt,children:n.jsx(vt,{children:e})})}function ur(){const e=u.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=n.jsx(N,{children:n.jsx(X,{virtualMcpId:v})}),e[0]=t):t=e[0],t}function fr(){const e=u.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=n.jsx(N,{children:n.jsx(Z,{virtualMcpId:v})}),e[0]=t):t=e[0],t}export{fr as SiteEditorContent,ur as SiteEditorPreview,dr as default};
@@ -1 +0,0 @@
1
- import{c as q,b as G,r as B,j as s,n as Q,l as J,f as X}from"./index-C8YP0XfX.js";import{C as Z}from"./index-C6KhNCz4.js";import{C as ee}from"./collection-tabs-CRfyt8-K.js";import{A as M,a as te,b as se,u as ie}from"./use-task-board-analytics-BjOmg5HS.js";import{T as ae,e as W}from"./time-range-picker-D99DN923.js";import{S as oe,d as le,c as re,a as ne,b as me}from"./sheet-ko7a2Uwq.js";import{S as ce,s as pe,D as de}from"./analytics-sections-CGcyhwwe.js";import{f as fe}from"./task-route-B7ChywKT.js";import{C as ge}from"./combobox-BBB78IeP.js";import"./use-mobile-tv6dKHC3.js";import"./use-sidebar-collapsed-BwFu6Qgg.js";import"./use-chat-layout-state-DIXRUqxC.js";import"./thread-route-JcxEqRgq.js";import"./use-panel-navigate-CTWNyrxK.js";import"./use-project-scope-BgLQY0Uk.js";import"./repository-binding-B-4PI1n3.js";import"./use-mcp-client-CkAT8dMu.js";import"./auth-fndLm_KR.js";import"./thread-intent-Cl7xa7dA.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./watch-sse-pool-B-0VhxE7.js";import"./task-board-u5TablbK.js";import"./schema-CFje17_E.js";import"./slugify-CEUa2lfQ.js";import"./agent-icon-B7Q7dFXY.js";import"./AlertCircle-C0U53qC5.js";import"./Tool01-CTKnipD_.js";import"./ArrowUp-BnowdRj-.js";import"./ArrowLeft-BVJNIiuT.js";import"./LinkBroken01-BZrnscWF.js";import"./ShoppingBag01-BaMIB-e_.js";import"./ZoomOut-BVuJZ-2t.js";import"./Building02-CcI-P3yL.js";import"./CheckCircle-fAPMl2yd.js";import"./ChevronUp-BMY88wXt.js";import"./ChevronSelectorVertical-C-CIIDml.js";import"./UserSquare-D4xudMmb.js";import"./Copy01-DGy0Absz.js";import"./CreditCard01-DsjBhiEj.js";import"./DotsVertical-Bfe9a_On.js";import"./Image01-DtpDUrwF.js";import"./Globe04-B-sNlZxN.js";import"./SwitchHorizontal01-fMsLFMs0.js";import"./Key01-DifqnYu0.js";import"./Link01-oZZyGItc.js";import"./Minus-Dc5wow6R.js";import"./Monitor01-Bmn1BV5T.js";import"./Sun-BZlKwpGn.js";import"./Play-IViIK9Vy.js";import"./Plus-Bh_xMwh7.js";import"./SearchMd-DB3np2ti.js";import"./Trash01-BqP8uw7k.js";import"./Upload01-CpPArzNK.js";import"./Users01-buCmBl1X.js";import"./XClose-D48r2tDo.js";import"./tooltip-CJHeHoSn.js";import"./index-B0Rg86vv.js";import"./toolbar-icon-button-BUMG5B6x.js";import"./shell-layout-uDYSTXA5.js";import"./use-clock-tick-DxI4Q15z.js";import"./command-jlI8eprh.js";import"./index-BM9HifS6.js";import"./integration-icon-03FWmed-.js";import"./project-icon-BSrEdWN1.js";import"./new-project-dialog-BuE_SqTn.js";import"./label-BZDtWIcv.js";import"./repository-import-picker-BfMMau5M.js";import"./use-navigate-to-agent-BiKQMaG5.js";import"./repository-picker-CbWFb7rK.js";import"./useInfiniteQuery-LBIaZPt-.js";import"./infiniteQueryObserver-C8Tx1h_G.js";import"./collection-search-B_n3Ea8A.js";import"./use-debounced-value-ZtANdTDD.js";import"./use-organization-settings-6EqlUT2Y.js";import"./required-auth-layout-ofmCqqpc.js";import"./autosend-VKc1dW3G.js";import"./use-org-sso-BK4EESlq.js";import"./resizable-KZ7XhVXp.js";import"./badge-AFOqFwvQ.js";import"./popover-C0DIKe_3.js";import"./scroll-area-BSd3TrLZ.js";import"./index-BdQq_4o_.js";import"./calendar-BZJL1q0i.js";import"./chart-bf024hGa.js";import"./index-CzZ16hae.js";import"./symbol-DLC3ejqz.js";import"./CategoricalChart-CukPvNkf.js";import"./table-CIbHZF2_.js";import"./toggle-group-CWnjwOku.js";import"./active-indicator-CCMhAsc_.js";import"./config-CEPjuV4B.js";import"./core.esm-CfGX-VCE.js";import"./BarChart-CwsIHr2J.js";import"./tooltipContext-CL92GCVz.js";import"./ActiveShapeUtils-CUGYcOGt.js";import"./Sector-BbL3mZ4i.js";import"./ErrorBarContext-hs9d9Up0.js";import"./CartesianChart-Cwfb2Obv.js";import"./AreaChart-vwsYBH1z.js";import"./task-key-BCHdFiOO.js";const ue={TASK_BOARD_OPERATION:"taskBoard.analytics.tabOperation",TASK_BOARD_REWORK:"taskBoard.analytics.tabRework",TASK_BOARD_DELIVERY:"taskBoard.analytics.tabDelivery",TASK_BOARD_SPRINTS:"taskBoard.analytics.tabSprints",TASK_BOARD_STUCK:"taskBoard.analytics.tabStuck",TASK_BOARD_COST:"taskBoard.analytics.tabCost",TASK_BOARD_ERRORS:"taskBoard.analytics.tabErrors",TASK_BOARD_TENANTS:"taskBoard.analytics.tabTenants"};function F(t){const e=new Date;return{from:(W(t.from).date??e).toISOString(),to:(W(t.to).date??e).toISOString()}}function z(t){const e=q.c(6),{className:p}=t;let r;e[0]!==p?(r=J("surface flex flex-col gap-6 p-4",p),e[0]=p,e[1]=r):r=e[1];let a,d;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("div",{className:"h-5 w-24 animate-pulse rounded bg-muted"}),s.jsx("div",{className:"h-10 w-16 animate-pulse rounded bg-muted"})]}),d=s.jsx("div",{className:"h-[140px] w-full animate-pulse rounded bg-muted/60"}),e[2]=a,e[3]=d):(a=e[2],d=e[3]);let n;return e[4]!==r?(n=s.jsxs("div",{className:r,children:[a,d]}),e[4]=r,e[5]=n):n=e[5],n}function xe(){const t=q.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx("div",{className:"grid grid-cols-2 gap-4 lg:grid-cols-4",children:[0,1,2,3].map(he)}),t[0]=e):e=t[0];let p;return t[1]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsxs("div",{className:"flex flex-col gap-4","aria-busy":!0,children:[e,s.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[s.jsx(z,{}),s.jsx(z,{})]}),s.jsx(z,{})]}),t[1]=p):p=t[1],p}function he(t){return s.jsxs("div",{className:"surface flex flex-col gap-1 p-4",children:[s.jsx("div",{className:"h-5 w-24 animate-pulse rounded bg-muted"}),s.jsx("div",{className:"h-10 w-16 animate-pulse rounded bg-muted"})]},t)}function Se(t){const e=q.c(27),{target:p,open:r,onOpenChange:a,params:d,taskHref:n}=t,j=G(),{data:o,isLoading:i,error:y}=se(d,r?p?.drill??null:null);let u;e[0]!==o?.sections?(u=o?.sections.find(ke),e[0]=o?.sections,e[1]=u):u=e[1];const m=u,T=m?.rows.length??0,b=p?.label;let x;e[2]!==b?(x=s.jsx(oe,{children:b}),e[2]=b,e[3]=x):x=e[3];let h;e[4]!==T||e[5]!==j||e[6]!==m?(h=m?j(T===1?"taskBoard.analytics.drillCountOne":"taskBoard.analytics.drillCount",{n:String(T)}):" ",e[4]=T,e[5]=j,e[6]=m,e[7]=h):h=e[7];let f;e[8]!==h?(f=s.jsx(le,{children:h}),e[8]=h,e[9]=f):f=e[9];let g;e[10]!==x||e[11]!==f?(g=s.jsxs(re,{children:[x,f]}),e[10]=x,e[11]=f,e[12]=g):g=e[12];let k;e[13]!==y||e[14]!==i||e[15]!==n||e[16]!==m?(k=i?s.jsx("div",{className:"flex flex-col gap-2 p-2","aria-busy":!0,children:[0,1,2,3,4].map(be)}):y?s.jsx("p",{className:"p-2 text-sm text-destructive",children:y.message}):m?.kind==="table"&&s.jsx(de,{section:m,taskHref:n}),e[13]=y,e[14]=i,e[15]=n,e[16]=m,e[17]=k):k=e[17];let l;e[18]!==k?(l=s.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto px-2 pb-4",children:k}),e[18]=k,e[19]=l):l=e[19];let c;e[20]!==g||e[21]!==l?(c=s.jsxs(ne,{side:"right",size:"lg",children:[g,l]}),e[20]=g,e[21]=l,e[22]=c):c=e[22];let S;return e[23]!==a||e[24]!==r||e[25]!==c?(S=s.jsx(me,{open:r,onOpenChange:a,children:c}),e[23]=a,e[24]=r,e[25]=c,e[26]=S):S=e[26],S}function be(t){return s.jsx("div",{className:"h-11 animate-pulse rounded bg-muted"},t)}function ke(t){return t.kind==="table"}function je(t){const e=q.c(26),{tool:p,org:r,project:a,range:d,taskHref:n}=t;let j;e[0]!==r||e[1]!==a||e[2]!==d?(j={org:r,project:a,...d},e[0]=r,e[1]=a,e[2]=d,e[3]=j):j=e[3];const o=j,{data:i,isPending:y,error:u}=te(p,o),[m,T]=B.useState(null),[b,x]=B.useState(!1);if(u){let l;return e[4]!==u.message?(l=s.jsx("div",{className:"surface p-8 text-center text-sm text-destructive",children:u.message}),e[4]=u.message,e[5]=l):l=e[5],l}if(y||!i){let l;return e[6]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsx(xe,{}),e[6]=l):l=e[6],l}let h;if(e[7]!==i.range||e[8]!==i.sections||e[9]!==r||e[10]!==n){let l;e[12]!==i.range||e[13]!==r||e[14]!==n?(l=c=>s.jsx("div",{className:J("min-w-0",pe(c)==="full"&&"md:col-span-2",c.kind==="table"&&"mt-6"),children:s.jsx(ce,{section:c,threadLinks:!0,showOrg:r==="all",taskHref:n,range:i.range,onDrill:S=>{T(S),x(!0)}})},c.title),e[12]=i.range,e[13]=r,e[14]=n,e[15]=l):l=e[15],h=i.sections.map(l),e[7]=i.range,e[8]=i.sections,e[9]=r,e[10]=n,e[11]=h}else h=e[11];let f;e[16]!==h?(f=s.jsx("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:h}),e[16]=h,e[17]=f):f=e[17];let g;e[18]!==m||e[19]!==b||e[20]!==o||e[21]!==n?(g=s.jsx(Se,{target:m,open:b,onOpenChange:x,params:o,taskHref:n}),e[18]=m,e[19]=b,e[20]=o,e[21]=n,e[22]=g):g=e[22];let k;return e[23]!==f||e[24]!==g?(k=s.jsxs("div",{className:"flex flex-col gap-4",children:[f,g]}),e[23]=f,e[24]=g,e[25]=k):k=e[25],k}function Te(t){const e=q.c(64),{org:p,project:r,taskHref:a,actions:d,notice:n,showTenants:j}=t,o=G(),[i,y]=B.useState("TASK_BOARD_OPERATION");let u;e[0]===Symbol.for("react.memo_cache_sentinel")?(u={from:"now-30d",to:"now"},e[0]=u):u=e[0];const[m,T]=B.useState(u);let b;e[1]!==m?(b=()=>F(m),e[1]=m,e[2]=b):b=e[2];const[x,h]=B.useState(b);let f;if(e[3]!==j||e[4]!==o){let R;e[6]!==j?(R=Y=>Y!=="TASK_BOARD_TENANTS"||j,e[6]=j,e[7]=R):R=e[7];let O;e[8]!==o?(O=Y=>({id:Y,label:o(ue[Y])}),e[8]=o,e[9]=O):O=e[9],f=M.filter(R).map(O),e[3]=j,e[4]=o,e[5]=f}else f=e[5];const g=f;let k;e[10]===Symbol.for("react.memo_cache_sentinel")?(k=R=>{T(R),h(F(R))},e[10]=k):k=e[10];let l;e[11]!==o?(l=o("monitoring.timeRangePicker.absoluteTimeRange"),e[11]=o,e[12]=l):l=e[12];let c;e[13]!==o?(c=o("monitoring.timeRangePicker.from"),e[13]=o,e[14]=c):c=e[14];let S;e[15]!==o?(S=o("monitoring.timeRangePicker.to"),e[15]=o,e[16]=S):S=e[16];let _;e[17]!==o?(_=o("monitoring.timeRangePicker.applyTimeRange"),e[17]=o,e[18]=_):_=e[18];let v;e[19]!==l||e[20]!==c||e[21]!==S||e[22]!==_?(v={absoluteTimeRange:l,from:c,to:S,applyTimeRange:_},e[19]=l,e[20]=c,e[21]=S,e[22]=_,e[23]=v):v=e[23];let A;e[24]!==o?(A=o("monitoring.timeRangePicker.last7Days"),e[24]=o,e[25]=A):A=e[25];let N;e[26]!==A?(N={label:A,from:"now-7d",to:"now",value:"7d"},e[26]=A,e[27]=N):N=e[27];let w;e[28]!==o?(w=o("monitoring.timeRangePicker.last30Days"),e[28]=o,e[29]=w):w=e[29];let D;e[30]!==w?(D={label:w,from:"now-30d",to:"now",value:"30d"},e[30]=w,e[31]=D):D=e[31];let C;e[32]!==o?(C=o("monitoring.timeRangePicker.last90Days"),e[32]=o,e[33]=C):C=e[33];let P;e[34]!==C?(P={label:C,from:"now-90d",to:"now",value:"90d"},e[34]=C,e[35]=P):P=e[35];let E;e[36]!==N||e[37]!==D||e[38]!==P?(E=[N,D,P],e[36]=N,e[37]=D,e[38]=P,e[39]=E):E=e[39];let K;e[40]!==m||e[41]!==E||e[42]!==v?(K=s.jsx(ae,{value:m,onChange:k,labels:v,quickRanges:E}),e[40]=m,e[41]=E,e[42]=v,e[43]=K):K=e[43];let L;e[44]!==d||e[45]!==K?(L=s.jsxs(Q.Actions,{children:[d,K]}),e[44]=d,e[45]=K,e[46]=L):L=e[46];let U;e[47]===Symbol.for("react.memo_cache_sentinel")?(U=R=>{const O=M.find(Y=>Y===R);O&&y(O)},e[47]=U):U=e[47];let $;e[48]!==i||e[49]!==g?($=s.jsx(ee,{placement:"page",tabs:g,activeTab:i,onTabChange:U}),e[48]=i,e[49]=g,e[50]=$):$=e[50];let I;e[51]!==p||e[52]!==r||e[53]!==x||e[54]!==i||e[55]!==a?(I=s.jsx(je,{tool:i,org:p,project:r,range:x,taskHref:a},i),e[51]=p,e[52]=r,e[53]=x,e[54]=i,e[55]=a,e[56]=I):I=e[56];let H;e[57]!==n||e[58]!==I?(H=s.jsxs("div",{className:"mx-auto flex w-full max-w-[1200px] flex-col gap-4 px-4 pt-6 pb-10 md:px-10",children:[n,I]}),e[57]=n,e[58]=I,e[59]=H):H=e[59];let V;return e[60]!==L||e[61]!==$||e[62]!==H?(V=s.jsxs("div",{className:"flex h-full min-h-0 flex-col overflow-auto",children:[L,$,H]}),e[60]=L,e[61]=$,e[62]=H,e[63]=V):V=e[63],V}function hs(){const t=q.c(37),e=G();let p;t[0]===Symbol.for("react.memo_cache_sentinel")?(p={strict:!1},t[0]=p):p=t[0];const r=X(p),a=r.org??"",d=r.agentId,n=ie(),[j,o]=B.useState(a),[i,y]=B.useState(a);a!==j&&(o(a),y(a));const u=!d&&(n.data?.isTaskBoardAdmin??!1);let m;t[1]!==e?(m=e("taskBoard.analytics.orgCurrent"),t[1]=e,t[2]=m):m=t[2];let T;t[3]!==a||t[4]!==m?(T={value:a,label:m},t[3]=a,t[4]=m,t[5]=T):T=t[5];let b;t[6]!==e?(b=e("taskBoard.analytics.orgAll"),t[6]=e,t[7]=b):b=t[7];let x;t[8]!==b?(x={value:"all",label:b},t[8]=b,t[9]=x):x=t[9];let h;if(t[10]!==n.data?.orgs||t[11]!==a||t[12]!==T||t[13]!==x){let v;t[15]!==a?(v=A=>A.slug!==a,t[15]=a,t[16]=v):v=t[16],h=[T,x,...(n.data?.orgs??[]).filter(v).map(ve)],t[10]=n.data?.orgs,t[11]=a,t[12]=T,t[13]=x,t[14]=h}else h=t[14];const f=h;let g;t[17]!==i||t[18]!==a||t[19]!==d?(g=v=>fe(a,{id:v,keySeq:null},d)+(i===a?"":`?boardOrg=${encodeURIComponent(i)}`),t[17]=i,t[18]=a,t[19]=d,t[20]=g):g=t[20];const l=i==="all"?void 0:g;let c;t[21]!==u||t[22]!==i||t[23]!==f||t[24]!==e?(c=u&&s.jsx(ge,{options:f,value:i,onChange:y,width:"w-[220px]",searchPlaceholder:e("taskBoard.analytics.orgSearch"),emptyMessage:e("taskBoard.analytics.orgEmpty")}),t[21]=u,t[22]=i,t[23]=f,t[24]=e,t[25]=c):c=t[25];let S;t[26]!==i||t[27]!==a||t[28]!==e?(S=i!==a&&s.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:i==="all"?e("taskBoard.analytics.bannerAll"):e("taskBoard.analytics.bannerOrg",{org:i})}),t[26]=i,t[27]=a,t[28]=e,t[29]=S):S=t[29];let _;return t[30]!==u||t[31]!==i||t[32]!==d||t[33]!==l||t[34]!==c||t[35]!==S?(_=s.jsx(Z.Content,{children:s.jsx(Te,{org:i,project:d,taskHref:l,showTenants:u,actions:c,notice:S},i)}),t[30]=u,t[31]=i,t[32]=d,t[33]=l,t[34]=c,t[35]=S,t[36]=_):_=t[36],_}function ve(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}export{hs as default};
@@ -1 +0,0 @@
1
- import{c as l,a4 as n,j as r,K as f}from"./index-C8YP0XfX.js";import{C as d}from"./index-C6KhNCz4.js";import{m as u,P as x,T as h}from"./mock-board-BtdGtIDb.js";import{F as j}from"./feature-gate-BaIBNMzy.js";import"./use-mobile-tv6dKHC3.js";import"./use-sidebar-collapsed-BwFu6Qgg.js";import"./use-chat-layout-state-DIXRUqxC.js";import"./thread-route-JcxEqRgq.js";import"./use-panel-navigate-CTWNyrxK.js";import"./use-project-scope-BgLQY0Uk.js";import"./repository-binding-B-4PI1n3.js";import"./use-mcp-client-CkAT8dMu.js";import"./auth-fndLm_KR.js";import"./thread-intent-Cl7xa7dA.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./watch-sse-pool-B-0VhxE7.js";import"./task-board-u5TablbK.js";import"./schema-CFje17_E.js";import"./slugify-CEUa2lfQ.js";import"./agent-icon-B7Q7dFXY.js";import"./AlertCircle-C0U53qC5.js";import"./Tool01-CTKnipD_.js";import"./ArrowUp-BnowdRj-.js";import"./ArrowLeft-BVJNIiuT.js";import"./LinkBroken01-BZrnscWF.js";import"./ShoppingBag01-BaMIB-e_.js";import"./ZoomOut-BVuJZ-2t.js";import"./Building02-CcI-P3yL.js";import"./CheckCircle-fAPMl2yd.js";import"./ChevronUp-BMY88wXt.js";import"./ChevronSelectorVertical-C-CIIDml.js";import"./UserSquare-D4xudMmb.js";import"./Copy01-DGy0Absz.js";import"./CreditCard01-DsjBhiEj.js";import"./DotsVertical-Bfe9a_On.js";import"./Image01-DtpDUrwF.js";import"./Globe04-B-sNlZxN.js";import"./SwitchHorizontal01-fMsLFMs0.js";import"./Key01-DifqnYu0.js";import"./Link01-oZZyGItc.js";import"./Minus-Dc5wow6R.js";import"./Monitor01-Bmn1BV5T.js";import"./Sun-BZlKwpGn.js";import"./Play-IViIK9Vy.js";import"./Plus-Bh_xMwh7.js";import"./SearchMd-DB3np2ti.js";import"./Trash01-BqP8uw7k.js";import"./Upload01-CpPArzNK.js";import"./Users01-buCmBl1X.js";import"./XClose-D48r2tDo.js";import"./tooltip-CJHeHoSn.js";import"./index-B0Rg86vv.js";import"./toolbar-icon-button-BUMG5B6x.js";import"./shell-layout-uDYSTXA5.js";import"./use-clock-tick-DxI4Q15z.js";import"./command-jlI8eprh.js";import"./index-BM9HifS6.js";import"./integration-icon-03FWmed-.js";import"./project-icon-BSrEdWN1.js";import"./new-project-dialog-BuE_SqTn.js";import"./label-BZDtWIcv.js";import"./repository-import-picker-BfMMau5M.js";import"./use-navigate-to-agent-BiKQMaG5.js";import"./repository-picker-CbWFb7rK.js";import"./useInfiniteQuery-LBIaZPt-.js";import"./infiniteQueryObserver-C8Tx1h_G.js";import"./collection-search-B_n3Ea8A.js";import"./use-debounced-value-ZtANdTDD.js";import"./use-organization-settings-6EqlUT2Y.js";import"./required-auth-layout-ofmCqqpc.js";import"./autosend-VKc1dW3G.js";import"./use-org-sso-BK4EESlq.js";import"./sheet-ko7a2Uwq.js";import"./resizable-KZ7XhVXp.js";import"./core.esm-CfGX-VCE.js";import"./sortable.esm-Bk2g_Gbz.js";import"./use-task-board-analytics-BjOmg5HS.js";import"./combobox-BBB78IeP.js";import"./popover-C0DIKe_3.js";import"./usage-stats-CNcWehA3.js";import"./tool-namespace-ChbHxLTp.js";import"./form-DmKuBQlJ.js";import"./utils-CVEq3hMx.js";import"./markdown-DuoP9xIE.js";import"./use-copy-BCht-61u.js";import"./location-V0VwTJTt.js";import"./use-decopilot-events-hbubA99f.js";import"./chat-context-BI1yxU4R.js";import"./use-ai-providers-DzWzPq_c.js";import"./suggestion-Bl_JrZPN.js";import"./column-rules-C7sxa0a0.js";import"./badge-AFOqFwvQ.js";import"./icon-button-Rp_ZDDhs.js";import"./switch-DbWQrL2t.js";import"./textarea-BeCs38v-.js";import"./use-org-fs-ao97Epgk.js";import"./use-automations-DO79ln3M.js";import"./search-toggle-BYErJl4G.js";import"./context-menu-Ckmk21Ru.js";import"./daily-pulse-DWbRk6Tj.js";import"./use-task-board-events-DGIxUFSu.js";import"./config-CEPjuV4B.js";import"./select-EVDcG5Hl.js";import"./index-BdQq_4o_.js";import"./task-route-B7ChywKT.js";import"./task-key-BCHdFiOO.js";import"./task-assignee-avatar-8Sp4Z4mk.js";import"./use-tags-M_iZ_HOI.js";import"./calendar-BZJL1q0i.js";import"./alert-CHj-Usrj.js";import"./collapsible-B5J2aUd-.js";import"./index-DJmej5q-.js";import"./editor-classes-Dkk1S2M6.js";import"./index-DG18LLWo.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./use-task-board-item-prs-BHe2zSmu.js";import"./use-connection-ClhLV4Ep.js";import"./github-repo-scope-ByTYKy_L.js";import"./thread-sheet-body-BZhXd8vN.js";import"./useSuspenseInfiniteQuery-ClnVveRy.js";import"./pair-DEJAc3iG.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-DWv_y82s.js";import"./types-Cwtot2FB.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./use-mcp-prompts-BoifdA0D.js";import"./use-thread-outputs-am5Vd3rC.js";import"./file-type-icon-CLdhbOMq.js";import"./use-infinite-scroll-CuF9Fnt8.js";import"./task-status-Ch8fGpdY.js";import"./use-open-billing-url-6v7Ht1P5.js";import"./chat-draft-B9Sz9SQX.js";import"./separator-Czsq0Xe-.js";import"./feature-paywall-BIJDHy8g.js";import"./plan-ladder-B0TVgJ_-.js";function a(){const t=l.c(1);let o;return t[0]===Symbol.for("react.memo_cache_sentinel")?(o=r.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-hidden",children:r.jsx(h,{})}),t[0]=o):o=t[0],o}function Mo(){const t=l.c(8),{locator:o}=n();let i;t[0]!==o?(i=c=>c.setQueryData(f.taskBoardItems(o),u()),t[0]=o,t[1]=i):i=t[1];let p;t[2]===Symbol.for("react.memo_cache_sentinel")?(p=r.jsx(a,{}),t[2]=p):p=t[2];let m;t[3]!==i?(m=r.jsx(x,{seed:i,children:p}),t[3]=i,t[4]=m):m=t[4];let e;t[5]===Symbol.for("react.memo_cache_sentinel")?(e=r.jsx(a,{}),t[5]=e):e=t[5];let s;return t[6]!==m?(s=r.jsx(d.Content,{children:r.jsx(j,{feature:"kanban",backdrop:m,children:e})}),t[6]=m,t[7]=s):s=t[7],s}export{Mo as default};
@@ -1 +0,0 @@
1
- import{c as U,b as ee,f as ge,r as F,j as s,h as je,a4 as pe,a0 as Se,R as ye}from"./index-C8YP0XfX.js";import{C as se}from"./index-C6KhNCz4.js";import{S as be}from"./analytics-sections-CGcyhwwe.js";import{u as ve,a as Ne,b as Te}from"./use-thread-analytics-Bq-Ku2nN.js";import{B as Ce}from"./badge-AFOqFwvQ.js";import{C as _e}from"./combobox-BBB78IeP.js";import{S as ie,b as oe,a as ne,d as ce,c as Z}from"./select-EVDcG5Hl.js";import{e as Ae,a as we,b as fe,T as V,d as ke,c as K}from"./table-CIbHZF2_.js";import{T as le,a as Le,b as re,c as Ee}from"./tabs-BbA4-8ma.js";import{c as Re,S as Ie,a as $e,b as Be}from"./sheet-ko7a2Uwq.js";import{T as De}from"./thread-sheet-body-BZhXd8vN.js";import{u as Oe}from"./use-connection-ClhLV4Ep.js";import{u as Pe}from"./use-mcp-client-CkAT8dMu.js";import{b as He}from"./repository-binding-B-4PI1n3.js";import"./use-mobile-tv6dKHC3.js";import"./use-sidebar-collapsed-BwFu6Qgg.js";import"./use-chat-layout-state-DIXRUqxC.js";import"./thread-route-JcxEqRgq.js";import"./use-panel-navigate-CTWNyrxK.js";import"./use-project-scope-BgLQY0Uk.js";import"./thread-intent-Cl7xa7dA.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./watch-sse-pool-B-0VhxE7.js";import"./task-board-u5TablbK.js";import"./schema-CFje17_E.js";import"./slugify-CEUa2lfQ.js";import"./agent-icon-B7Q7dFXY.js";import"./AlertCircle-C0U53qC5.js";import"./Tool01-CTKnipD_.js";import"./ArrowUp-BnowdRj-.js";import"./ArrowLeft-BVJNIiuT.js";import"./LinkBroken01-BZrnscWF.js";import"./ShoppingBag01-BaMIB-e_.js";import"./ZoomOut-BVuJZ-2t.js";import"./Building02-CcI-P3yL.js";import"./CheckCircle-fAPMl2yd.js";import"./ChevronUp-BMY88wXt.js";import"./ChevronSelectorVertical-C-CIIDml.js";import"./UserSquare-D4xudMmb.js";import"./Copy01-DGy0Absz.js";import"./CreditCard01-DsjBhiEj.js";import"./DotsVertical-Bfe9a_On.js";import"./Image01-DtpDUrwF.js";import"./Globe04-B-sNlZxN.js";import"./SwitchHorizontal01-fMsLFMs0.js";import"./Key01-DifqnYu0.js";import"./Link01-oZZyGItc.js";import"./Minus-Dc5wow6R.js";import"./Monitor01-Bmn1BV5T.js";import"./Sun-BZlKwpGn.js";import"./Play-IViIK9Vy.js";import"./Plus-Bh_xMwh7.js";import"./SearchMd-DB3np2ti.js";import"./Trash01-BqP8uw7k.js";import"./Upload01-CpPArzNK.js";import"./Users01-buCmBl1X.js";import"./XClose-D48r2tDo.js";import"./tooltip-CJHeHoSn.js";import"./index-B0Rg86vv.js";import"./toolbar-icon-button-BUMG5B6x.js";import"./shell-layout-uDYSTXA5.js";import"./use-clock-tick-DxI4Q15z.js";import"./command-jlI8eprh.js";import"./index-BM9HifS6.js";import"./integration-icon-03FWmed-.js";import"./project-icon-BSrEdWN1.js";import"./new-project-dialog-BuE_SqTn.js";import"./label-BZDtWIcv.js";import"./repository-import-picker-BfMMau5M.js";import"./use-navigate-to-agent-BiKQMaG5.js";import"./repository-picker-CbWFb7rK.js";import"./useInfiniteQuery-LBIaZPt-.js";import"./infiniteQueryObserver-C8Tx1h_G.js";import"./collection-search-B_n3Ea8A.js";import"./use-debounced-value-ZtANdTDD.js";import"./use-organization-settings-6EqlUT2Y.js";import"./required-auth-layout-ofmCqqpc.js";import"./autosend-VKc1dW3G.js";import"./use-org-sso-BK4EESlq.js";import"./resizable-KZ7XhVXp.js";import"./chart-bf024hGa.js";import"./index-CzZ16hae.js";import"./symbol-DLC3ejqz.js";import"./CategoricalChart-CukPvNkf.js";import"./toggle-group-CWnjwOku.js";import"./active-indicator-CCMhAsc_.js";import"./config-CEPjuV4B.js";import"./core.esm-CfGX-VCE.js";import"./BarChart-CwsIHr2J.js";import"./tooltipContext-CL92GCVz.js";import"./ActiveShapeUtils-CUGYcOGt.js";import"./Sector-BbL3mZ4i.js";import"./ErrorBarContext-hs9d9Up0.js";import"./CartesianChart-Cwfb2Obv.js";import"./AreaChart-vwsYBH1z.js";import"./popover-C0DIKe_3.js";import"./index-BdQq_4o_.js";import"./useSuspenseInfiniteQuery-ClnVveRy.js";import"./pair-DEJAc3iG.js";import"./collapsible-B5J2aUd-.js";import"./use-copy-BCht-61u.js";import"./usage-stats-CNcWehA3.js";import"./tool-namespace-ChbHxLTp.js";import"./form-DmKuBQlJ.js";import"./utils-CVEq3hMx.js";import"./markdown-DuoP9xIE.js";import"./location-V0VwTJTt.js";import"./use-decopilot-events-hbubA99f.js";import"./chat-context-BI1yxU4R.js";import"./use-ai-providers-DzWzPq_c.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-DWv_y82s.js";import"./types-Cwtot2FB.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./use-mcp-prompts-BoifdA0D.js";import"./use-thread-outputs-am5Vd3rC.js";import"./file-type-icon-CLdhbOMq.js";import"./use-infinite-scroll-CuF9Fnt8.js";import"./task-status-Ch8fGpdY.js";import"./auth-fndLm_KR.js";const Ve=[1,7,30,90],Ke=["in_progress","requires_action","failed","completed"],Ue=["chat","automation","task"],X="any",me={in_progress:"thread.analytics.statusRunning",requires_action:"thread.analytics.statusWaiting",failed:"thread.analytics.statusFailed",completed:"thread.analytics.statusCompleted"},xe={chat:"thread.analytics.kindChat",automation:"thread.analytics.kindAutomation",task:"thread.analytics.kindTask"},Fe={in_progress:"default",requires_action:"warning",failed:"destructive",completed:"secondary"};function de(){const t=U.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx("div",{className:"flex justify-center py-12",children:s.jsx(je,{className:"size-5 text-muted-foreground"})}),t[0]=e):e=t[0],e}function he(t){const e=U.c(2),{message:l}=t;let r;return e[0]!==l?(r=s.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-destructive",children:l}),e[0]=l,e[1]=r):r=e[1],r}function ae(t){const e=U.c(9),{label:l,value:r}=t;let a;e[0]!==l?(a=s.jsx("div",{className:"text-sm text-muted-foreground",children:l}),e[0]=l,e[1]=a):a=e[1];let m;e[2]!==r?(m=r.toLocaleString(),e[2]=r,e[3]=m):m=e[3];let o;e[4]!==m?(o=s.jsx("div",{className:"mt-1 text-2xl font-medium text-foreground tabular-nums",children:m}),e[4]=m,e[5]=o):o=e[5];let c;return e[6]!==a||e[7]!==o?(c=s.jsxs("div",{className:"rounded-lg border border-border p-4",children:[a,o]}),e[6]=a,e[7]=o,e[8]=c):c=e[8],c}function Ye(t){const e=U.c(56),{thread:l,onOpen:r}=t,a=ee(),m=l.status;let o;e[0]!==l.updatedAt?(o=new Date(l.updatedAt).toLocaleString(),e[0]=l.updatedAt,e[1]=o):o=e[1];let c;e[2]!==o?(c=s.jsx(K,{className:"whitespace-nowrap text-sm tabular-nums text-muted-foreground",children:o}),e[2]=o,e[3]=c):c=e[3];let i;e[4]!==l.orgSlug?(i=s.jsx(K,{className:"text-sm",children:l.orgSlug}),e[4]=l.orgSlug,e[5]=i):i=e[5];let u;e[6]!==r||e[7]!==l?(u=()=>r(l),e[6]=r,e[7]=l,e[8]=u):u=e[8];let n;e[9]!==a||e[10]!==l.title?(n=l.title||a("thread.analytics.untitled"),e[9]=a,e[10]=l.title,e[11]=n):n=e[11];let x;e[12]!==u||e[13]!==n?(x=s.jsx("button",{type:"button",onClick:u,className:"block max-w-full truncate text-left text-foreground underline-offset-2 hover:underline",children:n}),e[12]=u,e[13]=n,e[14]=x):x=e[14];let d;e[15]!==l.failureReason||e[16]!==l.lastError||e[17]!==l.status?(d=l.status==="failed"&&(l.lastError||l.failureReason)&&s.jsx("div",{className:"truncate text-xs text-destructive",children:l.lastError??l.failureReason}),e[15]=l.failureReason,e[16]=l.lastError,e[17]=l.status,e[18]=d):d=e[18];let h;e[19]!==x||e[20]!==d?(h=s.jsxs(K,{className:"max-w-sm text-sm",children:[x,d]}),e[19]=x,e[20]=d,e[21]=h):h=e[21];const g=xe[l.kind];let p;e[22]!==a||e[23]!==g?(p=a(g),e[22]=a,e[23]=g,e[24]=p):p=e[24];let w;e[25]!==p?(w=s.jsx(K,{className:"text-sm",children:p}),e[25]=p,e[26]=w):w=e[26];const k=Fe[m]??"outline";let j;e[27]!==m||e[28]!==a||e[29]!==l.status?(j=me[m]?a(me[m]):l.status,e[27]=m,e[28]=a,e[29]=l.status,e[30]=j):j=e[30];let T;e[31]!==k||e[32]!==j?(T=s.jsx(K,{children:s.jsx(Ce,{variant:k,children:j})}),e[31]=k,e[32]=j,e[33]=T):T=e[33];const L=l.userEmail??l.userName??"—";let S;e[34]!==L?(S=s.jsx(K,{className:"max-w-48 truncate text-sm",children:L}),e[34]=L,e[35]=S):S=e[35];let y;e[36]!==l.agent?(y=s.jsx(K,{className:"max-w-48 truncate text-sm",children:l.agent}),e[36]=l.agent,e[37]=y):y=e[37];let C;e[38]!==l.usd?(C=l.usd===null?"—":`$${l.usd.toFixed(2)}`,e[38]=l.usd,e[39]=C):C=e[39];let b;e[40]!==C?(b=s.jsx(K,{className:"text-sm tabular-nums",children:C}),e[40]=C,e[41]=b):b=e[41];let v;e[42]!==l.tokens?(v=l.tokens===null?"—":l.tokens.toLocaleString(),e[42]=l.tokens,e[43]=v):v=e[43];let N;e[44]!==v?(N=s.jsx(K,{className:"text-sm tabular-nums",children:v}),e[44]=v,e[45]=N):N=e[45];let _;return e[46]!==w||e[47]!==T||e[48]!==S||e[49]!==y||e[50]!==b||e[51]!==c||e[52]!==N||e[53]!==i||e[54]!==h?(_=s.jsxs(fe,{children:[c,i,h,w,T,S,y,b,N]}),e[46]=w,e[47]=T,e[48]=S,e[49]=y,e[50]=b,e[51]=c,e[52]=N,e[53]=i,e[54]=h,e[55]=_):_=e[55],_}function ze(t){const e=U.c(51),{org:l}=t,r=ee(),[a,m]=F.useState(X),[o,c]=F.useState(X),i=a===X?void 0:a,u=o===X?void 0:o;let n;e[0]!==l||e[1]!==i||e[2]!==u?(n={org:l,status:i,kind:u,limit:150},e[0]=l,e[1]=i,e[2]=u,e[3]=n):n=e[3];const x=n,{data:d,isLoading:h,error:g}=Ne(x,!0),[p,w]=F.useState(null);let k;e[4]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx(oe,{className:"w-[180px]",size:"sm",children:s.jsx(ne,{})}),e[4]=k):k=e[4];let j;e[5]!==r?(j=r("thread.analytics.anyStatus"),e[5]=r,e[6]=j):j=e[6];let T;e[7]!==j?(T=s.jsx(Z,{value:X,children:j}),e[7]=j,e[8]=T):T=e[8];let L;e[9]!==r?(L=Ke.map(A=>s.jsx(Z,{value:A,children:r(me[A])},A)),e[9]=r,e[10]=L):L=e[10];let S;e[11]!==T||e[12]!==L?(S=s.jsxs(ce,{children:[T,L]}),e[11]=T,e[12]=L,e[13]=S):S=e[13];let y;e[14]!==a||e[15]!==S?(y=s.jsxs(ie,{value:a,onValueChange:m,children:[k,S]}),e[14]=a,e[15]=S,e[16]=y):y=e[16];let C;e[17]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx(oe,{className:"w-[180px]",size:"sm",children:s.jsx(ne,{})}),e[17]=C):C=e[17];let b;e[18]!==r?(b=r("thread.analytics.anyKind"),e[18]=r,e[19]=b):b=e[19];let v;e[20]!==b?(v=s.jsx(Z,{value:X,children:b}),e[20]=b,e[21]=v):v=e[21];let N;e[22]!==r?(N=Ue.map(A=>s.jsx(Z,{value:A,children:r(xe[A])},A)),e[22]=r,e[23]=N):N=e[23];let _;e[24]!==v||e[25]!==N?(_=s.jsxs(ce,{children:[v,N]}),e[24]=v,e[25]=N,e[26]=_):_=e[26];let E;e[27]!==o||e[28]!==_?(E=s.jsxs(ie,{value:o,onValueChange:c,children:[C,_]}),e[27]=o,e[28]=_,e[29]=E):E=e[29];let D;e[30]===Symbol.for("react.memo_cache_sentinel")?(D=s.jsx("span",{className:"size-2 rounded-full bg-success"}),e[30]=D):D=e[30];let O;e[31]!==r?(O=r("thread.analytics.liveHint"),e[31]=r,e[32]=O):O=e[32];let R;e[33]!==O?(R=s.jsxs("span",{className:"ml-auto flex items-center gap-2 text-xs text-muted-foreground",children:[D,O]}),e[33]=O,e[34]=R):R=e[34];let I;e[35]!==E||e[36]!==R||e[37]!==y?(I=s.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y,E,R]}),e[35]=E,e[36]=R,e[37]=y,e[38]=I):I=e[38];let $;e[39]!==d||e[40]!==g||e[41]!==h||e[42]!==r?($=h?s.jsx(de,{}):g?s.jsx(he,{message:g.message}):d?s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-3",children:[s.jsx(ae,{label:r("thread.analytics.countRunning"),value:d.counts.running}),s.jsx(ae,{label:r("thread.analytics.countWaiting"),value:d.counts.waiting}),s.jsx(ae,{label:r("thread.analytics.countFailedHour"),value:d.counts.failedLastHour})]}),d.threads.length===0?s.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-muted-foreground",children:r("thread.analytics.empty")}):s.jsx("div",{className:"overflow-x-auto rounded-lg border border-border",children:s.jsxs(Ae,{children:[s.jsx(we,{children:s.jsxs(fe,{children:[s.jsx(V,{children:r("thread.analytics.colUpdated")}),s.jsx(V,{children:r("thread.analytics.colOrg")}),s.jsx(V,{children:r("thread.analytics.colChat")}),s.jsx(V,{children:r("thread.analytics.colKind")}),s.jsx(V,{children:r("thread.analytics.colStatus")}),s.jsx(V,{children:r("thread.analytics.colUser")}),s.jsx(V,{children:r("thread.analytics.colAgent")}),s.jsx(V,{children:r("thread.analytics.colCost")}),s.jsx(V,{children:r("thread.analytics.colTokens")})]})}),s.jsx(ke,{children:d.threads.map(A=>s.jsx(Ye,{thread:A,onOpen:w},A.id))})]})})]}):null,e[39]=d,e[40]=g,e[41]=h,e[42]=r,e[43]=$):$=e[43];let P;e[44]===Symbol.for("react.memo_cache_sentinel")?(P=()=>w(null),e[44]=P):P=e[44];let B;e[45]!==p?(B=s.jsx(qe,{thread:p,onClose:P}),e[45]=p,e[46]=B):B=e[46];let H;return e[47]!==I||e[48]!==$||e[49]!==B?(H=s.jsxs("div",{className:"flex flex-col gap-6 py-6",children:[I,$,B]}),e[47]=I,e[48]=$,e[49]=B,e[50]=H):H=e[50],H}function Me(t){const e=U.c(14),{thread:l}=t,{org:r,locator:a}=pe();let m;e[0]!==r.id||e[1]!==r.slug?(m={connectionId:ye,orgId:r.id,orgSlug:r.slug},e[0]=r.id,e[1]=r.slug,e[2]=m):m=e[2];const o=Pe(m),c=Oe(),i=He();let u;e[3]!==l.createdAt||e[4]!==l.id||e[5]!==l.status||e[6]!==l.title?(u={id:l.id,title:l.title,status:l.status,created_at:l.createdAt},e[3]=l.createdAt,e[4]=l.id,e[5]=l.status,e[6]=l.title,e[7]=u):u=e[7];let n;return e[8]!==o||e[9]!==c||e[10]!==a||e[11]!==u||e[12]!==i?(n=s.jsx(De,{thread:u,client:o,locator:a,connections:c,virtualMcps:i,members:void 0,meta:!1}),e[8]=o,e[9]=c,e[10]=a,e[11]=u,e[12]=i,e[13]=n):n=e[13],n}function qe(t){const e=U.c(12),{thread:l,onClose:r}=t,a=ee(),{project:m}=pe(),o=!!l;let c;e[0]!==r?(c=x=>!x&&r(),e[0]=r,e[1]=c):c=e[1];let i;e[2]!==m||e[3]!==a||e[4]!==l?(i=l&&s.jsx(Se,{org:{id:l.orgId,name:l.orgSlug,slug:l.orgSlug,logo:null},project:m,children:s.jsx(F.Suspense,{fallback:s.jsx(Re,{className:"shrink-0 border-b border-border px-5 pb-5 pt-6 md:px-6",children:s.jsx(Ie,{className:"truncate text-sm leading-snug",children:l.title||a("thread.analytics.untitled")})}),children:s.jsx(Me,{thread:l})})}),e[2]=m,e[3]=a,e[4]=l,e[5]=i):i=e[5];let u;e[6]!==i?(u=s.jsx($e,{className:"flex flex-col gap-0 p-0 sm:max-w-2xl",children:i}),e[6]=i,e[7]=u):u=e[7];let n;return e[8]!==o||e[9]!==c||e[10]!==u?(n=s.jsx(Be,{open:o,onOpenChange:c,children:u}),e[8]=o,e[9]=c,e[10]=u,e[11]=n):n=e[11],n}function ue(t){const e=U.c(16),{tool:l,org:r,from:a,to:m}=t,o=ee();let c;e[0]!==a||e[1]!==r||e[2]!==m?(c={org:r,from:a,to:m},e[0]=a,e[1]=r,e[2]=m,e[3]=c):c=e[3];const{data:i,isLoading:u,error:n}=Te(l,c);if(u){let p;return e[4]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(de,{}),e[4]=p):p=e[4],p}if(n){let p;return e[5]!==n.message?(p=s.jsx(he,{message:n.message}),e[5]=n.message,e[6]=p):p=e[6],p}if(!i)return null;let x;e[7]!==i.sections?(x=i.sections.map(Ge),e[7]=i.sections,e[8]=x):x=e[8];let d;e[9]!==o?(d=o("thread.analytics.costFootnote"),e[9]=o,e[10]=d):d=e[10];let h;e[11]!==d?(h=s.jsx("p",{className:"text-xs text-muted-foreground",children:d}),e[11]=d,e[12]=h):h=e[12];let g;return e[13]!==x||e[14]!==h?(g=s.jsxs("div",{className:"flex flex-col gap-8 py-6",children:[x,h]}),e[13]=x,e[14]=h,e[15]=g):g=e[15],g}function Ge(t){return s.jsx(be,{section:t,threadLinks:!0},t.title)}function ml(){const t=U.c(99),e=ee(),l=ge({strict:!1}).org??"",r=ve(),[a,m]=F.useState("all"),[o,c]=F.useState(7),[i,u]=F.useState("live"),[n]=F.useState(Je);let x;t[0]!==n?(x=new Date(n).toISOString(),t[0]=n,t[1]=x):x=t[1];const d=x;let h;t[2]!==o||t[3]!==n?(h=new Date(n-o*864e5).toISOString(),t[2]=o,t[3]=n,t[4]=h):h=t[4];const g=h;if(r.isLoading){let f;return t[5]===Symbol.for("react.memo_cache_sentinel")?(f=s.jsx(se.Content,{children:s.jsx(de,{})}),t[5]=f):f=t[5],f}if(!r.data?.isAdmin){let f;t[6]!==e?(f=e("thread.analytics.notAdmin"),t[6]=e,t[7]=f):f=t[7];let Q;return t[8]!==f?(Q=s.jsx(se.Content,{children:s.jsx("div",{className:"p-8 text-center text-sm text-muted-foreground",children:f})}),t[8]=f,t[9]=Q):Q=t[9],Q}let p;t[10]!==e?(p=e("taskBoard.analytics.orgAll"),t[10]=e,t[11]=p):p=t[11];let w;t[12]!==p?(w={value:"all",label:p},t[12]=p,t[13]=w):w=t[13];let k;t[14]!==e?(k=e("taskBoard.analytics.orgCurrent"),t[14]=e,t[15]=k):k=t[15];let j;t[16]!==l||t[17]!==k?(j={value:l,label:k},t[16]=l,t[17]=k,t[18]=j):j=t[18];let T;if(t[19]!==r.data.orgs||t[20]!==l||t[21]!==w||t[22]!==j){let f;t[24]!==l?(f=Q=>Q.slug!==l,t[24]=l,t[25]=f):f=t[25],T=[w,j,...r.data.orgs.filter(f).map(We)],t[19]=r.data.orgs,t[20]=l,t[21]=w,t[22]=j,t[23]=T}else T=t[23];const L=T;let S;t[26]!==e?(S=e("thread.analytics.title"),t[26]=e,t[27]=S):S=t[27];let y;t[28]!==S?(y=s.jsx("h1",{className:"text-xl font-medium text-foreground",children:S}),t[28]=S,t[29]=y):y=t[29];let C;t[30]!==e?(C=e("taskBoard.analytics.orgSearch"),t[30]=e,t[31]=C):C=t[31];let b;t[32]!==e?(b=e("taskBoard.analytics.orgEmpty"),t[32]=e,t[33]=b):b=t[33];let v;t[34]!==a||t[35]!==L||t[36]!==b||t[37]!==C?(v=s.jsx(_e,{options:L,value:a,onChange:m,width:"w-[240px]",searchPlaceholder:C,emptyMessage:b}),t[34]=a,t[35]=L,t[36]=b,t[37]=C,t[38]=v):v=t[38];let N;t[39]!==o||t[40]!==e||t[41]!==i?(N=i!=="live"&&s.jsxs(ie,{value:String(o),onValueChange:f=>c(Number(f)),children:[s.jsx(oe,{className:"w-[140px]",size:"sm",children:s.jsx(ne,{})}),s.jsx(ce,{children:Ve.map(f=>s.jsx(Z,{value:String(f),children:e("taskBoard.analytics.rangeDays",{days:String(f)})},f))})]}),t[39]=o,t[40]=e,t[41]=i,t[42]=N):N=t[42];let _;t[43]!==v||t[44]!==N?(_=s.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[v,N]}),t[43]=v,t[44]=N,t[45]=_):_=t[45];let E;t[46]!==_||t[47]!==y?(E=s.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y,_]}),t[46]=_,t[47]=y,t[48]=E):E=t[48];let D;t[49]!==a||t[50]!==l||t[51]!==e?(D=a!==l&&s.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:a==="all"?e("taskBoard.analytics.bannerAll"):e("taskBoard.analytics.bannerOrg",{org:a})}),t[49]=a,t[50]=l,t[51]=e,t[52]=D):D=t[52];let O;t[53]===Symbol.for("react.memo_cache_sentinel")?(O=f=>u(f),t[53]=O):O=t[53];let R;t[54]!==e?(R=e("thread.analytics.tabLive"),t[54]=e,t[55]=R):R=t[55];let I;t[56]!==R?(I=s.jsx(le,{value:"live",children:R}),t[56]=R,t[57]=I):I=t[57];let $;t[58]!==e?($=e("thread.analytics.tabUsage"),t[58]=e,t[59]=$):$=t[59];let P;t[60]!==$?(P=s.jsx(le,{value:"usage",children:$}),t[60]=$,t[61]=P):P=t[61];let B;t[62]!==e?(B=e("thread.analytics.tabErrors"),t[62]=e,t[63]=B):B=t[63];let H;t[64]!==B?(H=s.jsx(le,{value:"errors",children:B}),t[64]=B,t[65]=H):H=t[65];let A;t[66]!==I||t[67]!==P||t[68]!==H?(A=s.jsxs(Le,{children:[I,P,H]}),t[66]=I,t[67]=P,t[68]=H,t[69]=A):A=t[69];let Y;t[70]!==a||t[71]!==i?(Y=i==="live"&&s.jsx(ze,{org:a}),t[70]=a,t[71]=i,t[72]=Y):Y=t[72];let z;t[73]!==Y?(z=s.jsx(re,{value:"live",children:Y}),t[73]=Y,t[74]=z):z=t[74];let M;t[75]!==g||t[76]!==a||t[77]!==i||t[78]!==d?(M=i==="usage"&&s.jsx(ue,{tool:"THREAD_ANALYTICS_USAGE",org:a,from:g,to:d}),t[75]=g,t[76]=a,t[77]=i,t[78]=d,t[79]=M):M=t[79];let q;t[80]!==M?(q=s.jsx(re,{value:"usage",children:M}),t[80]=M,t[81]=q):q=t[81];let G;t[82]!==g||t[83]!==a||t[84]!==i||t[85]!==d?(G=i==="errors"&&s.jsx(ue,{tool:"THREAD_ANALYTICS_ERRORS",org:a,from:g,to:d}),t[82]=g,t[83]=a,t[84]=i,t[85]=d,t[86]=G):G=t[86];let W;t[87]!==G?(W=s.jsx(re,{value:"errors",children:G}),t[87]=G,t[88]=W):W=t[88];let J;t[89]!==A||t[90]!==z||t[91]!==q||t[92]!==W||t[93]!==i?(J=s.jsxs(Ee,{value:i,onValueChange:O,children:[A,z,q,W]}),t[89]=A,t[90]=z,t[91]=q,t[92]=W,t[93]=i,t[94]=J):J=t[94];let te;return t[95]!==E||t[96]!==D||t[97]!==J?(te=s.jsx(se.Content,{children:s.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-auto",children:s.jsxs("div",{className:"mx-auto flex w-full max-w-[1680px] flex-col gap-4 px-4 py-6 sm:px-8 sm:py-8",children:[E,D,J]})})}),t[95]=E,t[96]=D,t[97]=J,t[98]=te):te=t[98],te}function We(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}function Je(){return Date.now()}export{ml as default};
@@ -1 +0,0 @@
1
- import{I as u}from"./infiniteQueryObserver-C8Tx1h_G.js";import{er as i}from"./index-C8YP0XfX.js";function t(e,r){return i(e,u,r)}export{t as u};
@@ -1 +0,0 @@
1
- import{I as s}from"./infiniteQueryObserver-C8Tx1h_G.js";import{er as u,ey as n}from"./index-C8YP0XfX.js";function a(e,r){return u({...e,enabled:!0,suspense:!0,throwOnError:n},s,r)}export{a as u};