decocms 4.593.0 → 4.594.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (432) hide show
  1. package/dist/client/assets/{AlertCircle-BPb6lfDc.js → AlertCircle-kHXzu73r.js} +1 -1
  2. package/dist/client/assets/{AreaChart-Yh5pBNgF.js → AreaChart-CJxx8aiG.js} +1 -1
  3. package/dist/client/assets/{ArrowLeft-D_px05Ip.js → ArrowLeft-DcKid1bz.js} +1 -1
  4. package/dist/client/assets/{ArrowRight-DYc-7xj5.js → ArrowRight-ajc9j6D-.js} +1 -1
  5. package/dist/client/assets/{ArrowUp-bsUZSt57.js → ArrowUp-CjAvmMLL.js} +1 -1
  6. package/dist/client/assets/{BookOpen01-CKzuPfPT.js → BookOpen01-CdH9hkvz.js} +1 -1
  7. package/dist/client/assets/{CartesianChart-8sA8UDc5.js → CartesianChart-BRKqG5iH.js} +1 -1
  8. package/dist/client/assets/{CategoricalChart-D0wEIkFu.js → CategoricalChart-DW_7VziR.js} +1 -1
  9. package/dist/client/assets/{CheckCircle-Dvda272I.js → CheckCircle-DG9pUM8a.js} +1 -1
  10. package/dist/client/assets/{ChevronDown-C0zFtKr8.js → ChevronDown-CWnE_Wmz.js} +1 -1
  11. package/dist/client/assets/{ChevronSelectorVertical-BtbkxpS7.js → ChevronSelectorVertical-ByCpNum0.js} +1 -1
  12. package/dist/client/assets/{ChevronUp-CHkdbh-i.js → ChevronUp-C_rAiuf1.js} +1 -1
  13. package/dist/client/assets/{CreditCard01-BnEtKIxX.js → CreditCard01-C6eDo3p0.js} +1 -1
  14. package/dist/client/assets/{Eye-CE9bd3Ra.js → Eye-DFeDq2Hx.js} +1 -1
  15. package/dist/client/assets/{File02-OGn6eCfs.js → File02-R0RW2VCN.js} +1 -1
  16. package/dist/client/assets/{Fingerprint04-ZnmHU3Kp.js → Fingerprint04-D-EFj_6a.js} +1 -1
  17. package/dist/client/assets/{Globe04-BK5-p2nj.js → Globe04-DudUQgTy.js} +1 -1
  18. package/dist/client/assets/{Image01-Do_f-fPi.js → Image01-Dfaw0Ysf.js} +1 -1
  19. package/dist/client/assets/{Key01-C2Ozqf6q.js → Key01-9JQCF719.js} +1 -1
  20. package/dist/client/assets/{LayoutLeft-tXOkIxzs.js → LayoutLeft-B-cVGLzN.js} +1 -1
  21. package/dist/client/assets/{LinkBroken01-sFiApfPs.js → LinkBroken01-CpDM6pG5.js} +1 -1
  22. package/dist/client/assets/{MessageCircle01-LN8Gr1lL.js → MessageCircle01-44De_8cO.js} +1 -1
  23. package/dist/client/assets/{Minus-vz8sJtmc.js → Minus-09UkIbMe.js} +1 -1
  24. package/dist/client/assets/{Monitor01-Ctq4Y9xp.js → Monitor01-BPQw3JGv.js} +1 -1
  25. package/dist/client/assets/{Play-B5OMs0GO.js → Play-BRDYCYl7.js} +1 -1
  26. package/dist/client/assets/{Plus-KLH-MPJh.js → Plus-BJfG2DpW.js} +1 -1
  27. package/dist/client/assets/{ReferenceLine-Hl32My8w.js → ReferenceLine-KUFosDOj.js} +1 -1
  28. package/dist/client/assets/{SearchMd-1p8IP99o.js → SearchMd-DioGBYbO.js} +1 -1
  29. package/dist/client/assets/{ShoppingBag01-BZ5p5Jaw.js → ShoppingBag01-CdQhBv_H.js} +1 -1
  30. package/dist/client/assets/{Sun-8QBdDNyc.js → Sun-U7FHkItb.js} +1 -1
  31. package/dist/client/assets/{SwitchHorizontal01-BRSeU65r.js → SwitchHorizontal01-sPBj-OL8.js} +1 -1
  32. package/dist/client/assets/{Tool01-CIkfFpNs.js → Tool01-BEo5XKkS.js} +1 -1
  33. package/dist/client/assets/{Tooltip-B9ptxG-X.js → Tooltip-2A3BALIx.js} +1 -1
  34. package/dist/client/assets/{Trash01-1e348d5z.js → Trash01-l4iOtEBN.js} +1 -1
  35. package/dist/client/assets/{TrendUp01-Sag3n7qI.js → TrendUp01-aviiZW6M.js} +1 -1
  36. package/dist/client/assets/{Upload01-DQiq1N5L.js → Upload01-BhvyPM8u.js} +1 -1
  37. package/dist/client/assets/{UserCheck01-Dq2vpnim.js → UserCheck01-B1rJ65So.js} +1 -1
  38. package/dist/client/assets/{UserSquare-BAlzvt_y.js → UserSquare-D44lppb_.js} +1 -1
  39. package/dist/client/assets/{Users01-CJNRoJXK.js → Users01-CxQycal6.js} +1 -1
  40. package/dist/client/assets/{XClose-CQjSvos9.js → XClose-BwokcWjs.js} +1 -1
  41. package/dist/client/assets/{Zap-BbT-W69e.js → Zap-DoXbwvKP.js} +1 -1
  42. package/dist/client/assets/{access-gate-BwaSQQ2b.js → access-gate-Cb6wrWbo.js} +1 -1
  43. package/dist/client/assets/{add-connection-dialog-b9bCaaJ-.js → add-connection-dialog-AJ93ohYz.js} +1 -1
  44. package/dist/client/assets/agent-app-BwabK-EN.js +1 -0
  45. package/dist/client/assets/{agent-assets-epUkCzig.js → agent-assets-BjERacII.js} +1 -1
  46. package/dist/client/assets/{agent-automation-DN5QlWy_.js → agent-automation-lPIiQ1-S.js} +1 -1
  47. package/dist/client/assets/{agent-automations-DeGcvAoe.js → agent-automations-DChAwthU.js} +1 -1
  48. package/dist/client/assets/{agent-blog-C-T8yJPu.js → agent-blog-BAFEHC3F.js} +2 -2
  49. package/dist/client/assets/{agent-blog-post-spGtFEpJ.js → agent-blog-post-BfZLJHCc.js} +2 -2
  50. package/dist/client/assets/{agent-calendar-EBTKBv82.js → agent-calendar-DVTbFVx4.js} +1 -1
  51. package/dist/client/assets/{agent-capabilities-Dsy9OzBC.js → agent-capabilities-CJLhsDjp.js} +1 -1
  52. package/dist/client/assets/{agent-connect-sources-B2TM-6qo.js → agent-connect-sources-BUkRDeee.js} +1 -1
  53. package/dist/client/assets/agent-deck-FkIcljPu.js +1 -0
  54. package/dist/client/assets/{agent-e2e-DMK6Z36v.js → agent-e2e-DBAmX-ay.js} +1 -1
  55. package/dist/client/assets/agent-experiments-DDePdz1s.js +1 -0
  56. package/dist/client/assets/agent-file-Dq7RwOoN.js +1 -0
  57. package/dist/client/assets/{agent-hosting-DOLRQkiF.js → agent-hosting-KJs4AVma.js} +1 -1
  58. package/dist/client/assets/{agent-icon-CFsULo4q.js → agent-icon-BS6RPQ_A.js} +1 -1
  59. package/dist/client/assets/agent-library-C06De_Om.js +1 -0
  60. package/dist/client/assets/agent-library-file-DZtwB2bP.js +1 -0
  61. package/dist/client/assets/agent-overview-3kq8I1YX.js +1 -0
  62. package/dist/client/assets/agent-releases-BwIrRp2G.js +3 -0
  63. package/dist/client/assets/agent-settings-CQxH-SU4.js +1 -0
  64. package/dist/client/assets/{agent-site-editor-BiguEz5z.js → agent-site-editor-CyUzqfPD.js} +1 -1
  65. package/dist/client/assets/agent-site-editor-code-lMnnKFV4.js +2 -0
  66. package/dist/client/assets/agent-site-editor-content-BQ-pFVV_.js +1 -0
  67. package/dist/client/assets/agent-site-editor-preview-Dipnwf9A.js +1 -0
  68. package/dist/client/assets/agent-view-D74Nsx4n.js +1 -0
  69. package/dist/client/assets/{agent-view-guard-BRen2fDa.js → agent-view-guard-dXJW4cSq.js} +1 -1
  70. package/dist/client/assets/{ai-providers-X4uIftAC.js → ai-providers-CoJXv_AA.js} +1 -1
  71. package/dist/client/assets/{alert-D6c8UL8s.js → alert-hKxZXEZZ.js} +1 -1
  72. package/dist/client/assets/{analytics-sections-BeagNbn2.js → analytics-sections-D8qsQ7bM.js} +1 -1
  73. package/dist/client/assets/api-keys-B9w3P2co.js +1 -0
  74. package/dist/client/assets/{api-keys-Bhaq6l4m.js → api-keys-BpcBSUmB.js} +1 -1
  75. package/dist/client/assets/{app-editor-BDvMcyIq.js → app-editor-DLwnlaqE.js} +1 -1
  76. package/dist/client/assets/{asset-utils-DedHJB9N.js → asset-utils-CdU3Ttfs.js} +1 -1
  77. package/dist/client/assets/{auth-WUI0GELm.js → auth-C3yWOKhG.js} +1 -1
  78. package/dist/client/assets/{auth-catchall-36sTseza.js → auth-catchall-DheSxLuf.js} +1 -1
  79. package/dist/client/assets/{auth-entry-BtvDZBee.js → auth-entry-C5exDM0H.js} +1 -1
  80. package/dist/client/assets/{auth-split-layout-DbgIe7Q7.js → auth-split-layout-Hg6hlPX8.js} +1 -1
  81. package/dist/client/assets/{authenticate-and-persist-oauth-D7yFnk3v.js → authenticate-and-persist-oauth-CIyQIb0N.js} +1 -1
  82. package/dist/client/assets/{automation-list-row-B-bTXdxL.js → automation-list-row-BYtaYJm7.js} +1 -1
  83. package/dist/client/assets/{automation-runs-DTOCdqSY.js → automation-runs-DvuKFaor.js} +1 -1
  84. package/dist/client/assets/{automations-BXXmJoq9.js → automations-D70iF6cO.js} +1 -1
  85. package/dist/client/assets/{badge-xkOOGTR2.js → badge-wWozseh3.js} +1 -1
  86. package/dist/client/assets/{block-document-ClS1Gx3q.js → block-document-CQOXOWIP.js} +1 -1
  87. package/dist/client/assets/{blocks-preview-workspace-context-BOiyLqjl.js → blocks-preview-workspace-context-BmhSK0mg.js} +1 -1
  88. package/dist/client/assets/{blocks-tab-states-Dgkd6bcn.js → blocks-tab-states-CDYT4Ypi.js} +1 -1
  89. package/dist/client/assets/{blog-preview-url-CQF91dum.js → blog-preview-url-D1Gi50Jy.js} +1 -1
  90. package/dist/client/assets/{blog-schema-B993jmPJ.js → blog-schema-G_pvuSAo.js} +1 -1
  91. package/dist/client/assets/{blog-source-gate-B40koNXU.js → blog-source-gate-Z08IMogx.js} +1 -1
  92. package/dist/client/assets/{blog-view-gate-DYONh8sE.js → blog-view-gate-WETs9z4-.js} +1 -1
  93. package/dist/client/assets/{buckets-W8OuOQja.js → buckets-BcxYNwzK.js} +1 -1
  94. package/dist/client/assets/{build-improve-prompt-doc-7R1He4iw.js → build-improve-prompt-doc-BpGLSKmi.js} +1 -1
  95. package/dist/client/assets/{calendar-CCy2brqO.js → calendar-Sr3cNZGh.js} +1 -1
  96. package/dist/client/assets/{capability-load-error-74rIpav9.js → capability-load-error-Cwe4uK-x.js} +1 -1
  97. package/dist/client/assets/{category-editor-DrOqNXNY.js → category-editor-DZLdQENU.js} +1 -1
  98. package/dist/client/assets/{category-tree-B08EozIk.js → category-tree-oBVfCVRR.js} +1 -1
  99. package/dist/client/assets/{chart-DVwx0iDS.js → chart-D0It11Pz.js} +1 -1
  100. package/dist/client/assets/{chat-context-Dk_Ebz6D.js → chat-context-B6UvvRRf.js} +1 -1
  101. package/dist/client/assets/{chat-draft-x-F0ZPWu.js → chat-draft-D0WJnhz_.js} +1 -1
  102. package/dist/client/assets/{checkbox-DR00CmJr.js → checkbox-Cs2Li62P.js} +1 -1
  103. package/dist/client/assets/{choose-editor-3geZkU-m.js → choose-editor-Cwvr5cPX.js} +1 -1
  104. package/dist/client/assets/{cli-auth-success-CX_XFx5r.js → cli-auth-success-DjQMGZUD.js} +1 -1
  105. package/dist/client/assets/{cms-settings-editor-DMhLCkuK.js → cms-settings-editor-h4wDmiSv.js} +1 -1
  106. package/dist/client/assets/{cms-store-drafts-BdqXOATK.js → cms-store-drafts-DDk2L1_s.js} +1 -1
  107. package/dist/client/assets/{collapsible-C5AFdLwb.js → collapsible-D4n-ssmc.js} +1 -1
  108. package/dist/client/assets/{collection-detail-DJYxfZho.js → collection-detail-CWZme-FJ.js} +1 -1
  109. package/dist/client/assets/{collection-display-button-BS2sbab3.js → collection-display-button--oxelZ8R.js} +1 -1
  110. package/dist/client/assets/{collection-search-ugxEd4a5.js → collection-search-CDDauqCr.js} +1 -1
  111. package/dist/client/assets/{collection-table-wrapper-omwG60bs.js → collection-table-wrapper-B8osPBIm.js} +1 -1
  112. package/dist/client/assets/{collection-tabs-BsiuG_yk.js → collection-tabs-B1EmRyNS.js} +1 -1
  113. package/dist/client/assets/{combobox-BYBZebi0.js → combobox-LL4GsRoi.js} +1 -1
  114. package/dist/client/assets/{command-CRJnywSm.js → command-DQwD4jPt.js} +1 -1
  115. package/dist/client/assets/{companion-mcps-section-C5X6hxKV.js → companion-mcps-section-aZ0yAV9m.js} +1 -1
  116. package/dist/client/assets/{config-Br1Io2is.js → config-zmlExYow.js} +1 -1
  117. package/dist/client/assets/{connect-BvcW8HFx.js → connect-C2FkNxOj.js} +1 -1
  118. package/dist/client/assets/{connect-key-Bng8UgOW.js → connect-key-MUQgzDUZ.js} +1 -1
  119. package/dist/client/assets/{connect-layout-BK-aWbrg.js → connect-layout-C10vBM31.js} +1 -1
  120. package/dist/client/assets/{connect-source-dialog-D8TZSkBE.js → connect-source-dialog-DZFw66w3.js} +1 -1
  121. package/dist/client/assets/{connection-C7PBWSJ2.js → connection-B7vXPxEB.js} +1 -1
  122. package/dist/client/assets/{connection-card-DbjUpBUS.js → connection-card-DqrVYaVF.js} +1 -1
  123. package/dist/client/assets/{connection-detail-FZzRV6Ym.js → connection-detail-BhmikSW0.js} +1 -1
  124. package/dist/client/assets/{connection-form-helpers-tAcDvyB7.js → connection-form-helpers-CipIPASt.js} +1 -1
  125. package/dist/client/assets/{connection-slug-xMtStNjP.js → connection-slug-DgGnB6qk.js} +1 -1
  126. package/dist/client/assets/{connections-IQMsafFW.js → connections-BH6dclGQ.js} +1 -1
  127. package/dist/client/assets/{content-tab-Dby-qF-f.js → content-tab-CMouaD3S.js} +3 -3
  128. package/dist/client/assets/{context-jsYDuqDI.js → context-BXIwVeKt.js} +1 -1
  129. package/dist/client/assets/{context-menu-Cvn-dR-4.js → context-menu-BTcjoIYF.js} +1 -1
  130. package/dist/client/assets/{context-shell-Bm22btDj.js → context-shell-Bh2U1zxs.js} +3 -3
  131. package/dist/client/assets/{create-organization-dialog-CXfqVYbt.js → create-organization-dialog-Dbp2Y7NH.js} +1 -1
  132. package/dist/client/assets/{daily-pulse-CxBxkzGT.js → daily-pulse-BiRUE30R.js} +1 -1
  133. package/dist/client/assets/{delete-copy-tGyXeEYr.js → delete-copy-BH5xrx9H.js} +1 -1
  134. package/dist/client/assets/{device-hint-D3KIwRP_.js → device-hint-CMC1mr9e.js} +1 -1
  135. package/dist/client/assets/{discover-UPogBeQB.js → discover-DN_s50Be.js} +1 -1
  136. package/dist/client/assets/{domain-settings-DarbfYc3.js → domain-settings-DBexbsXu.js} +1 -1
  137. package/dist/client/assets/{drawer-CQosC7Hh.js → drawer-BMY0wk6r.js} +1 -1
  138. package/dist/client/assets/{editor-DnZdk2c2.js → editor-C6mSxTrt.js} +1 -1
  139. package/dist/client/assets/{editor-classes-CiUorYg6.js → editor-classes-BygI_Lvg.js} +1 -1
  140. package/dist/client/assets/{empty-message-CG0mkpBx.js → empty-message-B3ykEghT.js} +1 -1
  141. package/dist/client/assets/{empty-state-D4GKvYHp.js → empty-state-C4vGG4yC.js} +1 -1
  142. package/dist/client/assets/{empty-state-B5kfNSn2.js → empty-state-hp9a4BQn.js} +1 -1
  143. package/dist/client/assets/{experiments-tab-choice-BNwFp10h.js → experiments-tab-choice-a808JseX.js} +1 -1
  144. package/dist/client/assets/{extract-connection-data-BwsA-RYq.js → extract-connection-data-B_eUCQ7e.js} +1 -1
  145. package/dist/client/assets/{feature-gate-WGXGW3TJ.js → feature-gate-DtqeHOu4.js} +1 -1
  146. package/dist/client/assets/{feature-paywall-CXj-cCjT.js → feature-paywall-BGOy9Z00.js} +1 -1
  147. package/dist/client/assets/{file-explorer-CQ0OZXxU.js → file-explorer-q1C_0Dfl.js} +1 -1
  148. package/dist/client/assets/{file-preview-CimYREH1.js → file-preview-Cid_-Y34.js} +1 -1
  149. package/dist/client/assets/{file-share-button-BAqDjZ0D.js → file-share-button-eK3lxbyf.js} +1 -1
  150. package/dist/client/assets/{file-type-icon-Cst2WgHg.js → file-type-icon-DOJ02s9h.js} +1 -1
  151. package/dist/client/assets/{folder-icon-h8_LtFFJ.js → folder-icon-4Pb3O8qn.js} +1 -1
  152. package/dist/client/assets/{form-Bmlz7qRb.js → form-BZ2nSi_9.js} +1 -1
  153. package/dist/client/assets/{frame-navigation-DiMr25uz.js → frame-navigation-C3j5rPCM.js} +1 -1
  154. package/dist/client/assets/{gateway-client-Dcj5rv8f.js → gateway-client-8UpI_Rdq.js} +1 -1
  155. package/dist/client/assets/{general-BTp6LTq7.js → general-bkCbo1TA.js} +1 -1
  156. package/dist/client/assets/{github-icon-HoxHOYky.js → github-icon-C-V2EETw.js} +1 -1
  157. package/dist/client/assets/{held-block-view-CB9_UtVc.js → held-block-view-xCVzC3Lr.js} +1 -1
  158. package/dist/client/assets/{home-CTP0vpaw.js → home-Dgh1Wb3u.js} +1 -1
  159. package/dist/client/assets/{home-overview-oJuOP6Jj.js → home-overview-CzbNLHJq.js} +1 -1
  160. package/dist/client/assets/{hosted-reconcile-DipRdTAf.js → hosted-reconcile-DS6ZmO5s.js} +1 -1
  161. package/dist/client/assets/{icon-button-CkP-MdlY.js → icon-button-CFamiizZ.js} +1 -1
  162. package/dist/client/assets/{index-DCNDjBOm.js → index--r4E_gW7.js} +1 -1
  163. package/dist/client/assets/{index-D4nZeJZF.js → index-6V91lP75.js} +1 -1
  164. package/dist/client/assets/{index-B7BDvGS9.js → index-B-PIhH8l.js} +1 -1
  165. package/dist/client/assets/{index-oZBvLpfd.js → index-B4YS6GMo.js} +1 -1
  166. package/dist/client/assets/{index-DGcnGUGR.js → index-B9tCllzH.js} +1 -1
  167. package/dist/client/assets/{index-CpqnzQ6X.js → index-BFjuxezw.js} +1 -1
  168. package/dist/client/assets/{index-BGvfgBXQ.js → index-BVZH8mqe.js} +5 -5
  169. package/dist/client/assets/{index-CrMNCOay.js → index-BYQu9U5P.js} +1 -1
  170. package/dist/client/assets/{index-jEofb67j.js → index-BeSn1lKu.js} +1 -1
  171. package/dist/client/assets/{index-fjBXVTkP.js → index-BesTmknq.js} +1 -1
  172. package/dist/client/assets/index-CFbcObvG.css +1 -0
  173. package/dist/client/assets/{index-Dj_uCaww.js → index-CJQHYkKb.js} +1 -1
  174. package/dist/client/assets/{index-C4-rqYj_.js → index-CqlRRF6p.js} +1 -1
  175. package/dist/client/assets/{index-Cy5OtK8P.js → index-D9WtqDmJ.js} +1 -1
  176. package/dist/client/assets/{index-CtgoU6en.js → index-D_u7RJfU.js} +1 -1
  177. package/dist/client/assets/{index-C5wldXHS.js → index-DwIomefI.js} +1 -1
  178. package/dist/client/assets/{index-ztFBZP-a.js → index-GMDFirHC.js} +1 -1
  179. package/dist/client/assets/{index-DFEtjxfd.js → index-cjnTxfp5.js} +1 -1
  180. package/dist/client/assets/{index-redirect-DTMlUMlL.js → index-redirect-BMGe_utm.js} +1 -1
  181. package/dist/client/assets/{infiniteQueryObserver-CjHha6VI.js → infiniteQueryObserver-f5kG4cIT.js} +1 -1
  182. package/dist/client/assets/{infra-billing-R5GG28fc.js → infra-billing-DaAfhBWg.js} +1 -1
  183. package/dist/client/assets/{input-CWx7kP2y.js → input-A20A_mwu.js} +1 -1
  184. package/dist/client/assets/{input-CIXcgL8B.js → input-o0eNZBV4.js} +3 -3
  185. package/dist/client/assets/{integration-icon-nO6TvSsO.js → integration-icon-CcV5frEs.js} +1 -1
  186. package/dist/client/assets/{item-actions-DHBqlB8t.js → item-actions-CZD9JeRy.js} +1 -1
  187. package/dist/client/assets/{jira-icon-DX-tTt4z.js → jira-icon-DlgPbK3F.js} +1 -1
  188. package/dist/client/assets/{label-2ri5y0AT.js → label-Dc_tSb6f.js} +1 -1
  189. package/dist/client/assets/{layout-m0ghuzGv.js → layout-514nGx9I.js} +1 -1
  190. package/dist/client/assets/{legacy-admin-welcome-dialog-dJnURvJJ.js → legacy-admin-welcome-dialog-DtYrilLw.js} +1 -1
  191. package/dist/client/assets/{legacy-agents-deep-JluLJXF7.js → legacy-agents-deep-DS7wnjib.js} +1 -1
  192. package/dist/client/assets/{legacy-main-redirect-COiP2ETV.js → legacy-main-redirect-BQ-dfJNU.js} +1 -1
  193. package/dist/client/assets/library-Cy3CmAZa.js +1 -0
  194. package/dist/client/assets/{library-tab-CAU7uiMF.js → library-tab-CZB0EHNl.js} +1 -1
  195. package/dist/client/assets/{login-DgFE1SmG.js → login-BVGV6SaO.js} +1 -1
  196. package/dist/client/assets/{markdown-Du_1i_DV.js → markdown-DvUyMKlV.js} +1 -1
  197. package/dist/client/assets/{mcp-app-renderer-CHuh8eBE.js → mcp-app-renderer-CRu4PbUr.js} +1 -1
  198. package/dist/client/assets/{mcp-oauth-Be_pa5Ik.js → mcp-oauth-CIY9YLWi.js} +1 -1
  199. package/dist/client/assets/{mcp-oauth-Bppcz_3X.js → mcp-oauth-NdGb5Zj9.js} +1 -1
  200. package/dist/client/assets/{members-CS-oK1Zf.js → members-CgoGmOSR.js} +1 -1
  201. package/dist/client/assets/{memory-Bl0VJnb1.js → memory-BfzundeZ.js} +1 -1
  202. package/dist/client/assets/{mock-board-BQeILTVh.js → mock-board-D8DOoo_p.js} +3 -3
  203. package/dist/client/assets/{monaco-editor-DCzjvWW2.js → monaco-editor-C3D0iT4a.js} +1 -1
  204. package/dist/client/assets/{monitoring-B4nvDMf7.js → monitoring-BvN0RJq0.js} +1 -1
  205. package/dist/client/assets/{monitoring-stats-row-BK9I1n3g.js → monitoring-stats-row-By2SXcyl.js} +1 -1
  206. package/dist/client/assets/{multi-select-DLpc9WGW.js → multi-select-Dak9eW6K.js} +1 -1
  207. package/dist/client/assets/{mustache-fgm1GoLm.js → mustache-CMgVEDUc.js} +1 -1
  208. package/dist/client/assets/{named-rule-step-ikHUM8J-.js → named-rule-step-BnN-hlGb.js} +1 -1
  209. package/dist/client/assets/{named-rule-view-BJLF9MVt.js → named-rule-view-hUwolemN.js} +1 -1
  210. package/dist/client/assets/{new-project-dialog-BfJtWdgg.js → new-project-dialog-BeD2i_Hm.js} +1 -1
  211. package/dist/client/assets/{new-project-store-CUIYzGdu.js → new-project-store-BfrY24D-.js} +1 -1
  212. package/dist/client/assets/{oauth-callback-DAF-HNU5.js → oauth-callback-CNqxDLu3.js} +1 -1
  213. package/dist/client/assets/{oauth-callback-ai-provider-BlZK1cl5.js → oauth-callback-ai-provider-0KF_xg3k.js} +1 -1
  214. package/dist/client/assets/{oauth-consent-BjKAsSxp.js → oauth-consent-li4JOhlZ.js} +1 -1
  215. package/dist/client/assets/{onboarding-CStDT_bk.js → onboarding-CzP4oXTn.js} +1 -1
  216. package/dist/client/assets/{openai-conversation-DJ7Npc2v.js → openai-conversation-BMsTp1zg.js} +1 -1
  217. package/dist/client/assets/{optimistic-project-sidebar-views-CaqEFCbi.js → optimistic-project-sidebar-views-C29BxST1.js} +1 -1
  218. package/dist/client/assets/{order-monitor-day-B3sADUCG.js → order-monitor-day-D910WxJ3.js} +1 -1
  219. package/dist/client/assets/{organization-choice-vaH8PRN7.js → organization-choice-BhMXPFKX.js} +1 -1
  220. package/dist/client/assets/{orgs-C-TKQP3D.js → orgs-ZZqk-o74.js} +1 -1
  221. package/dist/client/assets/{own-accounts-section-BpgBL9aq.js → own-accounts-section-4_Hp7fJv.js} +1 -1
  222. package/dist/client/assets/{pair-M_Ks4KYr.js → pair-C4tumP78.js} +1 -1
  223. package/dist/client/assets/{parse-sections-BuUvGGsv.js → parse-sections-B5REiM5j.js} +2 -2
  224. package/dist/client/assets/{plan-ladder-De9sRz_u.js → plan-ladder-BlcJL4hV.js} +1 -1
  225. package/dist/client/assets/{plan-usage-card-8gBO_kT7.js → plan-usage-card-DW3wLLQF.js} +1 -1
  226. package/dist/client/assets/{plan-D-khZ7ZC.js → plan-vUNQzJtH.js} +1 -1
  227. package/dist/client/assets/{popover-BdGhwX6j.js → popover-9q-VKuQx.js} +1 -1
  228. package/dist/client/assets/{post-calendar-CYarN2j3.js → post-calendar-Cw6GB31X.js} +1 -1
  229. package/dist/client/assets/{post-editor-mxtEx2vX.js → post-editor-BUxXB6Uz.js} +1 -1
  230. package/dist/client/assets/{preview-content-Dxe4XKdO.js → preview-content-aN9ghsH_.js} +1 -1
  231. package/dist/client/assets/{preview-dialog--RYpR3-k.js → preview-dialog-DqNYRBay.js} +1 -1
  232. package/dist/client/assets/{preview-panel-Bk5cvms4.js → preview-panel-DV1FaRUZ.js} +1 -1
  233. package/dist/client/assets/{preview-tab-BRY7e3Ww.js → preview-tab-CNYeoSqY.js} +3 -3
  234. package/dist/client/assets/{product-picker-dialog-CIU4p36P.js → product-picker-dialog-DVs_Kuee.js} +1 -1
  235. package/dist/client/assets/{profile-CA2wDqLs.js → profile-DbdvfkDI.js} +1 -1
  236. package/dist/client/assets/{project-app-view-CsobOn93.js → project-app-view-Cfrp6muY.js} +1 -1
  237. package/dist/client/assets/{project-apps-CzXp3RuA.js → project-apps-z0dBtbP_.js} +1 -1
  238. package/dist/client/assets/{project-icon-BUl2sFaB.js → project-icon-C8Sq9Uyo.js} +1 -1
  239. package/dist/client/assets/{project-index-D3eqGaeY.js → project-index-BOyydKXT.js} +1 -1
  240. package/dist/client/assets/project-reports-CN1JvK97.js +1 -0
  241. package/dist/client/assets/project-tasks-Cimkg6Js.js +1 -0
  242. package/dist/client/assets/{projects-DSjvBTqn.js → projects-B5BvS56N.js} +1 -1
  243. package/dist/client/assets/{projects-empty-state-C_4sZ19U.js → projects-empty-state-CDTj5tcd.js} +1 -1
  244. package/dist/client/assets/{prompts-JIqJQ8rm.js → prompts-DfS9pOYH.js} +1 -1
  245. package/dist/client/assets/record-editor-BC_pgxjj.js +1 -0
  246. package/dist/client/assets/{redirect-editor-CIkflDxt.js → redirect-editor-CJJivlqw.js} +1 -1
  247. package/dist/client/assets/reports-BU9i6BvT.js +1 -0
  248. package/dist/client/assets/{reports-DJZwSZy6.js → reports-C624VFLj.js} +1 -1
  249. package/dist/client/assets/{reports-onboarding-CSkswBMH.js → reports-onboarding-_pxt1WkF.js} +1 -1
  250. package/dist/client/assets/{reports-tab-6fV3Jvgl.js → reports-tab-BBmHq9vJ.js} +2 -2
  251. package/dist/client/assets/{repositories-BTuTm0L2.js → repositories-B7d9yCxo.js} +1 -1
  252. package/dist/client/assets/repositories-D-ngJeYU.js +1 -0
  253. package/dist/client/assets/{repository-binding-DrxBu24C.js → repository-binding-BIfwJXBl.js} +1 -1
  254. package/dist/client/assets/{repository-picker-Darc81nL.js → repository-picker-vN0XhyKR.js} +1 -1
  255. package/dist/client/assets/{require-capability-C51SGps0.js → require-capability-B6_v4BKo.js} +1 -1
  256. package/dist/client/assets/{required-auth-layout-pSTI6t_x.js → required-auth-layout-BXbkUsYd.js} +1 -1
  257. package/dist/client/assets/{reset-password-BnNzHLPz.js → reset-password-DPvgQ5Qd.js} +1 -1
  258. package/dist/client/assets/{resizable-BU7UxgwC.js → resizable-AytQ6SyX.js} +1 -1
  259. package/dist/client/assets/{resolve-tab-icon-Bd3WwXB0.js → resolve-tab-icon-BzV0wsYq.js} +1 -1
  260. package/dist/client/assets/{review-settings-D31XkFbq.js → review-settings-BTg5QElS.js} +1 -1
  261. package/dist/client/assets/{role-color-CJIemPpG.js → role-color-CNGxunw8.js} +1 -1
  262. package/dist/client/assets/{roles-C7hVcM54.js → roles-DrWSfOhb.js} +1 -1
  263. package/dist/client/assets/{route-ajk3Lz1i.js → route-BX1VK4D8.js} +1 -1
  264. package/dist/client/assets/route-DxNP7FKc.js +1 -0
  265. package/dist/client/assets/{route-1boDLy4Y.js → route-IYkPM4iL.js} +1 -1
  266. package/dist/client/assets/{route-page-header-D3RVWIBC.js → route-page-header-DnxbH76I.js} +1 -1
  267. package/dist/client/assets/{sandbox-git-api-lqhbN6-M.js → sandbox-git-api-CvJPOlyv.js} +1 -1
  268. package/dist/client/assets/{sandbox-lifecycle-context-QpFv1h24.js → sandbox-lifecycle-context-CO9pd80k.js} +1 -1
  269. package/dist/client/assets/{save-status-96Apsuux.js → save-status-eUv6TQpr.js} +1 -1
  270. package/dist/client/assets/{schema-DIQ-2mII.js → schema-C2ft4i4u.js} +1 -1
  271. package/dist/client/assets/{schema-DklwT0XH.js → schema-CATZG76m.js} +1 -1
  272. package/dist/client/assets/{scroll-area-CLaLCTf7.js → scroll-area-w9_Bvwmf.js} +1 -1
  273. package/dist/client/assets/{search-input-BytjnRYd.js → search-input-D3b0Dc5Y.js} +1 -1
  274. package/dist/client/assets/{search-toggle-BEH-S2im.js → search-toggle-DBEAkZhz.js} +1 -1
  275. package/dist/client/assets/{secret-picker-k0C3uZq8.js → secret-picker-CVfi84wZ.js} +1 -1
  276. package/dist/client/assets/{secrets-1-DGosfc.js → secrets-Bxh8ZQN1.js} +1 -1
  277. package/dist/client/assets/{section-array-field-08gf_aaJ.js → section-array-field-CkDPdYBe.js} +1 -1
  278. package/dist/client/assets/{sections-DfnSEAao.js → sections-BS4WKjIk.js} +1 -1
  279. package/dist/client/assets/{sections-editor-Cm1IpUw4.js → sections-editor-CLaZ0j6X.js} +1 -1
  280. package/dist/client/assets/{select-BH6i4t87.js → select-BJ7g3jt1.js} +1 -1
  281. package/dist/client/assets/{select-model-DuodXwbD.js → select-model-CIoiyBbQ.js} +1 -1
  282. package/dist/client/assets/{seo-editor-vJ_3bHov.js → seo-editor-C5CvtZIp.js} +1 -1
  283. package/dist/client/assets/{separator-DE4QJAwp.js → separator-DUnD5wBI.js} +1 -1
  284. package/dist/client/assets/{session-runtime-CnePJMYk.js → session-runtime-CRv5j4jh.js} +1 -1
  285. package/dist/client/assets/settings-tab-k_yzR7TC.js +1 -0
  286. package/dist/client/assets/{sheet-CX86ajAE.js → sheet-B1zTFenO.js} +1 -1
  287. package/dist/client/assets/{shell-layout-MrR8EGxZ.js → shell-layout-BT6RZJ9X.js} +1 -1
  288. package/dist/client/assets/{site-draft-actions-CCPyXgQA.js → site-draft-actions-BhvNLFOt.js} +1 -1
  289. package/dist/client/assets/{site-draft-view-B3wpg14y.js → site-draft-view-D89p35uK.js} +1 -1
  290. package/dist/client/assets/site-editor-DO2-FIjd.js +1 -0
  291. package/dist/client/assets/{site-editor-toast-DjTYO8yl.js → site-editor-toast-vvVLBG6s.js} +1 -1
  292. package/dist/client/assets/{skills-CwoSapY8.js → skills-C22XOkU8.js} +1 -1
  293. package/dist/client/assets/{slider-B1Q72VZH.js → slider-46E0vJw8.js} +1 -1
  294. package/dist/client/assets/{sortable.esm-CXd3MFy1.js → sortable.esm-BzU9NXcP.js} +1 -1
  295. package/dist/client/assets/{sso-DieJGjil.js → sso-zNrVMXEh.js} +1 -1
  296. package/dist/client/assets/{suggestion-Cpa996zU.js → suggestion-B9N6oqkG.js} +1 -1
  297. package/dist/client/assets/{super-agent-icon-Db04o97L.js → super-agent-icon-AyK0wzxQ.js} +1 -1
  298. package/dist/client/assets/{switch-B7uarNO5.js → switch-BX8b8tB6.js} +1 -1
  299. package/dist/client/assets/{synced-repos-aIXgLnBB.js → synced-repos-DS_Rsdst.js} +1 -1
  300. package/dist/client/assets/{tab-icon-glyph-D_VxeQZE.js → tab-icon-glyph-DpR7ri7q.js} +1 -1
  301. package/dist/client/assets/{table-Bta2Y1CD.js → table-DNvSx4nT.js} +1 -1
  302. package/dist/client/assets/{tabs-s8CSecQV.js → tabs-ClkuSww4.js} +1 -1
  303. package/dist/client/assets/{task-board-DshmncwN.js → task-board-DLNmAHmR.js} +1 -1
  304. package/dist/client/assets/{task-key-PomUyZRb.js → task-key-BjUMQvHV.js} +1 -1
  305. package/dist/client/assets/{task-route-DIKoinWO.js → task-route-B6gZ9LxC.js} +1 -1
  306. package/dist/client/assets/{task-status-LX7lBTjN.js → task-status-CvKutQFi.js} +1 -1
  307. package/dist/client/assets/{taskboard-analytics-DfkqsYeI.js → taskboard-analytics-BgegxTfw.js} +1 -1
  308. package/dist/client/assets/tasks-BZlAEaTY.js +1 -0
  309. package/dist/client/assets/{tasks-BGD-BUHo.js → tasks-VtqJyf5J.js} +1 -1
  310. package/dist/client/assets/{textarea-C_mtz3Kv.js → textarea-BnYcD_gb.js} +1 -1
  311. package/dist/client/assets/{thread-analytics-aGwSdxKv.js → thread-analytics-CHgBpfHv.js} +1 -1
  312. package/dist/client/assets/{thread-button-Bc5fnhGX.js → thread-button-Cra7mRSW.js} +1 -1
  313. package/dist/client/assets/{thread-intent-DJ2isQQx.js → thread-intent-CYNXEfHP.js} +1 -1
  314. package/dist/client/assets/{thread-route-C13LdFpr.js → thread-route-D00Shirq.js} +1 -1
  315. package/dist/client/assets/{thread-route-DI1GCHqT.js → thread-route-muzc431X.js} +1 -1
  316. package/dist/client/assets/{thread-sheet-body-CnbjjV-I.js → thread-sheet-body-B4d3KSH7.js} +1 -1
  317. package/dist/client/assets/{time-range-picker-A0UZNhWR.js → time-range-picker-BzLGuV9Q.js} +1 -1
  318. package/dist/client/assets/{toggle-group-BjeGXB13.js → toggle-group-Cu3LE1oL.js} +1 -1
  319. package/dist/client/assets/{tool-set-selector-rXUFKU4u.js → tool-set-selector-DpIP2fev.js} +1 -1
  320. package/dist/client/assets/{toolbar-icon-button-BmCu83-X.js → toolbar-icon-button-Bo8OSaqx.js} +1 -1
  321. package/dist/client/assets/{tooltip-D0-ybZJ-.js → tooltip-CfeBMv8z.js} +1 -1
  322. package/dist/client/assets/{tooltipContext-Dm5XB4Pa.js → tooltipContext-BMU8k-Rs.js} +1 -1
  323. package/dist/client/assets/{track-BI5WxsF3.js → track-DWmwuKVj.js} +1 -1
  324. package/dist/client/assets/{types-DeHdmC2C.js → types-D_vNw-3-.js} +1 -1
  325. package/dist/client/assets/{url-slug-Bt323BC1.js → url-slug-BOPVIawN.js} +1 -1
  326. package/dist/client/assets/{usage-stats-4TwUkhM4.js → usage-stats-Dzci2XGy.js} +1 -1
  327. package/dist/client/assets/{use-ai-providers-Cykm4Omp.js → use-ai-providers-C30oeluP.js} +1 -1
  328. package/dist/client/assets/{use-api-keys-QqkV0EMu.js → use-api-keys-CK1ZH-th.js} +1 -1
  329. package/dist/client/assets/{use-apply-named-rule-B0v5Nv1Q.js → use-apply-named-rule-DGYGOn-1.js} +1 -1
  330. package/dist/client/assets/use-ask-in-chat-Cp6wJI2T.js +1 -0
  331. package/dist/client/assets/{use-automations-CIfofZgd.js → use-automations-CtbjaE6m.js} +1 -1
  332. package/dist/client/assets/{use-autosave-phCMBUyD.js → use-autosave-Bpr4B2YO.js} +1 -1
  333. package/dist/client/assets/use-blocks-v8-project-DUe21BCo.js +1 -0
  334. package/dist/client/assets/use-blog-view-D_--u8j_.js +1 -0
  335. package/dist/client/assets/{use-chat-layout-state-BWjgOEMc.js → use-chat-layout-state-DBVzfsNg.js} +1 -1
  336. package/dist/client/assets/{use-cms-publish-actions-CPyM3m5I.js → use-cms-publish-actions-CWkUAckV.js} +1 -1
  337. package/dist/client/assets/{use-connect-companion-eWYXL_LA.js → use-connect-companion-iGJRty2G.js} +1 -1
  338. package/dist/client/assets/{use-connection-dER7f5j5.js → use-connection-C-m8b2Fk.js} +1 -1
  339. package/dist/client/assets/{use-content-sync-BSudZND-.js → use-content-sync-BJ7PE3PC.js} +1 -1
  340. package/dist/client/assets/{use-copy-CzwPMJY2.js → use-copy-BHPkBnZF.js} +1 -1
  341. package/dist/client/assets/{use-current-view-BhCzT_on.js → use-current-view-CHhVzMwk.js} +1 -1
  342. package/dist/client/assets/{use-date-fns-locale-DbDI1yRa.js → use-date-fns-locale-Cn791fqZ.js} +1 -1
  343. package/dist/client/assets/{use-debounced-autosave-BUqTz9gI.js → use-debounced-autosave-C6OCZte6.js} +1 -1
  344. package/dist/client/assets/{use-debounced-value-DNV71VAt.js → use-debounced-value-By7KggQt.js} +1 -1
  345. package/dist/client/assets/{use-deco-credits-D1eTXz3B.js → use-deco-credits-19cW8oHb.js} +1 -1
  346. package/dist/client/assets/{use-decopilot-events-DwV1bANi.js → use-decopilot-events-BxfGa0_j.js} +1 -1
  347. package/dist/client/assets/{use-delete-block-B3Q8p71v.js → use-delete-block-3AD9rKWc.js} +1 -1
  348. package/dist/client/assets/{use-delete-connection-KjVy0n0M.js → use-delete-connection-Cma0d5Z7.js} +1 -1
  349. package/dist/client/assets/{use-deployment-admin-U97at0FL.js → use-deployment-admin-COmgwPUq.js} +1 -1
  350. package/dist/client/assets/{use-entitlements-BnUu4797.js → use-entitlements-B8D7pawV.js} +1 -1
  351. package/dist/client/assets/{use-fast-preview-draft-url-Cyb7nHOV.js → use-fast-preview-draft-url-BQhDGlp9.js} +1 -1
  352. package/dist/client/assets/{use-file-configs-D-0GlBYS.js → use-file-configs-CCo70YSN.js} +1 -1
  353. package/dist/client/assets/{use-id-selection-lO2dafiF.js → use-id-selection-BOT74h8X.js} +1 -1
  354. package/dist/client/assets/{use-in-settings-BZ-N_1GQ.js → use-in-settings-qQ2sbeu5.js} +1 -1
  355. package/dist/client/assets/{use-inbox-feed-adObXP9V.js → use-inbox-feed-CIBoyRh8.js} +1 -1
  356. package/dist/client/assets/{use-infinite-scroll-DuNc__Oo.js → use-infinite-scroll-Ct_PbHT3.js} +1 -1
  357. package/dist/client/assets/{use-join-requests-CGnr0fzd.js → use-join-requests-CbaI0xCz.js} +1 -1
  358. package/dist/client/assets/{use-main-panel-tabs-C_KJU7HA.js → use-main-panel-tabs-CPcNwsEn.js} +1 -1
  359. package/dist/client/assets/{use-mcp-auth-status-CIA9x3GT.js → use-mcp-auth-status-BfHI4tpd.js} +1 -1
  360. package/dist/client/assets/{use-mcp-client-CsG2AAiF.js → use-mcp-client-7NPwItGN.js} +1 -1
  361. package/dist/client/assets/{use-mcp-prompts-DJkMWAp0.js → use-mcp-prompts-C7QHdaI_.js} +1 -1
  362. package/dist/client/assets/{use-mcp-tools-C4sfkkEQ.js → use-mcp-tools-DqnFukoV.js} +1 -1
  363. package/dist/client/assets/{use-mobile-B4kazYmP.js → use-mobile-5e0sSd3X.js} +1 -1
  364. package/dist/client/assets/{use-move-blocks-CQpVSPWP.js → use-move-blocks-Cqt9Q8CZ.js} +1 -1
  365. package/dist/client/assets/{use-navigate-to-agent-CYt8D-re.js → use-navigate-to-agent-CtsEyeFb.js} +1 -1
  366. package/dist/client/assets/{use-never-published-Dhj1oB8k.js → use-never-published-BK3TeRer.js} +1 -1
  367. package/dist/client/assets/{use-org-fs-BQ1-EjeH.js → use-org-fs-Cq9dcDh3.js} +1 -1
  368. package/dist/client/assets/{use-org-notice-FqFlDSJV.js → use-org-notice-Dvph2j3S.js} +1 -1
  369. package/dist/client/assets/{use-org-repo-syncs-DZJLO1tr.js → use-org-repo-syncs-CCuZhNZU.js} +1 -1
  370. package/dist/client/assets/{use-org-sso-CCCXGXRa.js → use-org-sso-BKXSOEb_.js} +1 -1
  371. package/dist/client/assets/{use-organization-settings-CcEgBKiR.js → use-organization-settings-BoOQOwrg.js} +1 -1
  372. package/dist/client/assets/{use-panel-navigate-BEVdshk4.js → use-panel-navigate-DPGDB1T1.js} +1 -1
  373. package/dist/client/assets/{use-project-native-view-presence-BWWCr0OJ.js → use-project-native-view-presence-SSp2DD_u.js} +1 -1
  374. package/dist/client/assets/{use-project-scope-DaSiwM20.js → use-project-scope-BIucgFKc.js} +1 -1
  375. package/dist/client/assets/{use-recent-apps-DJU0pj25.js → use-recent-apps-4zSmjU-Q.js} +1 -1
  376. package/dist/client/assets/{use-reports-diagnostic-BBFJaws_.js → use-reports-diagnostic-DWL8tyP6.js} +1 -1
  377. package/dist/client/assets/{use-sandbox-events-Bh6eTl2p.js → use-sandbox-events-TxpzU2Iw.js} +1 -1
  378. package/dist/client/assets/{use-secrets-DRWI9snD.js → use-secrets-CsCKmxLc.js} +1 -1
  379. package/dist/client/assets/{use-section-preview-base-DgxMYdVR.js → use-section-preview-base-BxFRvYUl.js} +1 -1
  380. package/dist/client/assets/{use-sidebar-collapsed-Cb1DkW28.js → use-sidebar-collapsed-DHFFs76T.js} +1 -1
  381. package/dist/client/assets/{use-tags-CY161EKU.js → use-tags-aDaEeB96.js} +1 -1
  382. package/dist/client/assets/{use-task-board-analytics-DstP91hQ.js → use-task-board-analytics-XXuDuH8s.js} +1 -1
  383. package/dist/client/assets/{use-task-board-item-prs-DENiL_-n.js → use-task-board-item-prs-CLDgREI3.js} +1 -1
  384. package/dist/client/assets/{use-task-board-items-BOf8g772.js → use-task-board-items-D4fdH47R.js} +1 -1
  385. package/dist/client/assets/{use-task-board-prompts-Cy7ux4ZM.js → use-task-board-prompts-DRYQb2DR.js} +1 -1
  386. package/dist/client/assets/{use-task-metadata-CLvpp-M5.js → use-task-metadata-CSvrbSt0.js} +1 -1
  387. package/dist/client/assets/{use-thread-outputs-CBGDKGBc.js → use-thread-outputs-CrNLjxTt.js} +1 -1
  388. package/dist/client/assets/{use-view-draft-kind-Bm-Nz5rU.js → use-view-draft-kind-BG3Ihm6n.js} +1 -1
  389. package/dist/client/assets/{use-voice-input-l3y10Zzf.js → use-voice-input-BspgCDOI.js} +1 -1
  390. package/dist/client/assets/useInfiniteQuery-BJoJv4VQ.js +1 -0
  391. package/dist/client/assets/{useQueries-BADhFyMC.js → useQueries-DGhxO9Ry.js} +1 -1
  392. package/dist/client/assets/useSuspenseInfiniteQuery-BFQG7J82.js +1 -0
  393. package/dist/client/assets/{users-BlAutU5k.js → users-CC1uXfIH.js} +1 -1
  394. package/dist/client/assets/{utils-D3hrWqhu.js → utils-JVZxV40b.js} +1 -1
  395. package/dist/client/assets/{variant-calendar-Cf89P2oq.js → variant-calendar-COAsXla8.js} +1 -1
  396. package/dist/client/assets/{variant-matcher-override-cabGpziX.js → variant-matcher-override-Dm9kjKRy.js} +1 -1
  397. package/dist/client/assets/{view-header-CqefLZ8T.js → view-header-d4Obd__T.js} +1 -1
  398. package/dist/client/assets/{virtual-mcp-BfLRvmz0.js → virtual-mcp-TQWeP4ry.js} +1 -1
  399. package/dist/client/assets/{watch-sse-pool-mz6vVQb7.js → watch-sse-pool-CWcYbOm5.js} +1 -1
  400. package/dist/client/index.html +2 -2
  401. package/dist/server/server.js +2 -2
  402. package/package.json +1 -1
  403. package/dist/client/assets/agent-app-qi4Zg0Ko.js +0 -1
  404. package/dist/client/assets/agent-deck-8F4Y3xtF.js +0 -1
  405. package/dist/client/assets/agent-experiments-CxOy1OMh.js +0 -1
  406. package/dist/client/assets/agent-file-BHPXEsLM.js +0 -1
  407. package/dist/client/assets/agent-library-BDMtzZv5.js +0 -1
  408. package/dist/client/assets/agent-library-file-BU6GZbp1.js +0 -1
  409. package/dist/client/assets/agent-overview-BpZl9px0.js +0 -1
  410. package/dist/client/assets/agent-releases-BojH--RB.js +0 -2
  411. package/dist/client/assets/agent-settings-CmejIfdg.js +0 -1
  412. package/dist/client/assets/agent-site-editor-code-CsUpsDOZ.js +0 -2
  413. package/dist/client/assets/agent-site-editor-content-DcDYGjSi.js +0 -1
  414. package/dist/client/assets/agent-site-editor-preview-DoYr2JdT.js +0 -1
  415. package/dist/client/assets/agent-view-5HH2xFah.js +0 -1
  416. package/dist/client/assets/api-keys-tTCGO1A5.js +0 -1
  417. package/dist/client/assets/index-w9K6scL8.css +0 -1
  418. package/dist/client/assets/library-Wi-0o3Yx.js +0 -1
  419. package/dist/client/assets/project-reports-DUszwxkV.js +0 -1
  420. package/dist/client/assets/project-tasks-C9wh-MvK.js +0 -1
  421. package/dist/client/assets/record-editor-5hDNYEyc.js +0 -1
  422. package/dist/client/assets/reports-BQo9TgIr.js +0 -1
  423. package/dist/client/assets/repositories-BT4LP6yW.js +0 -1
  424. package/dist/client/assets/route-FPh-7Znc.js +0 -1
  425. package/dist/client/assets/settings-tab-C97802nQ.js +0 -1
  426. package/dist/client/assets/site-editor-BiU8V7py.js +0 -1
  427. package/dist/client/assets/tasks-B2acfxpH.js +0 -1
  428. package/dist/client/assets/use-ask-in-chat-CJn-8DXz.js +0 -1
  429. package/dist/client/assets/use-blocks-v8-project-BUDjuC95.js +0 -1
  430. package/dist/client/assets/use-blog-view-CZ2egr0r.js +0 -1
  431. package/dist/client/assets/useInfiniteQuery-Comohppg.js +0 -1
  432. package/dist/client/assets/useSuspenseInfiniteQuery-XSNjcYue.js +0 -1
@@ -1 +1 @@
1
- import{r as s,c0 as L,c1 as B,j as c,g0 as q,c6 as y,c4 as b,f$ as K,c7 as E,g1 as _,e1 as T,ck as k,cd as U,co as V}from"./index-BGvfgBXQ.js";var I="Radio",[z,w]=k(I),[H,W]=z(I),P=s.forwardRef((t,d)=>{const{__scopeRadio:o,name:n,checked:e=!1,required:r,disabled:a,value:l="on",onCheck:f,form:R,...v}=t,[p,m]=s.useState(null),i=b(d,x=>m(x)),u=s.useRef(!1),h=p?R||!!p.closest("form"):!0;return c.jsxs(H,{scope:o,checked:e,disabled:a,children:[c.jsx(y.button,{type:"button",role:"radio","aria-checked":e,"data-state":A(e),"data-disabled":a?"":void 0,disabled:a,value:l,...v,ref:i,onClick:E(t.onClick,x=>{e||f?.(),h&&(u.current=x.isPropagationStopped(),u.current||x.stopPropagation())})}),h&&c.jsx(S,{control:p,bubbles:!u.current,name:n,value:l,checked:e,required:r,disabled:a,form:R,style:{transform:"translateX(-100%)"}})]})});P.displayName=I;var g="RadioIndicator",G=s.forwardRef((t,d)=>{const{__scopeRadio:o,forceMount:n,...e}=t,r=W(g,o);return c.jsx(T,{present:n||r.checked,children:c.jsx(y.span,{"data-state":A(r.checked),"data-disabled":r.disabled?"":void 0,...e,ref:d})})});G.displayName=g;var X="RadioBubbleInput",S=s.forwardRef(({__scopeRadio:t,control:d,checked:o,bubbles:n=!0,...e},r)=>{const a=s.useRef(null),l=b(a,r),f=U(o),R=V(d);return s.useEffect(()=>{const v=a.current;if(!v)return;const p=window.HTMLInputElement.prototype,i=Object.getOwnPropertyDescriptor(p,"checked").set;if(f!==o&&i){const u=new Event("click",{bubbles:n});i.call(v,o),v.dispatchEvent(u)}},[f,o,n]),c.jsx(y.input,{type:"radio","aria-hidden":!0,defaultChecked:o,...e,tabIndex:-1,ref:l,style:{...e.style,...R,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});S.displayName=X;function A(t){return t?"checked":"unchecked"}var Y=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],C="RadioGroup",[$]=k(C,[_,w]),j=_(),N=w(),[J,Q]=$(C),D=s.forwardRef((t,d)=>{const{__scopeRadioGroup:o,name:n,defaultValue:e,value:r,required:a=!1,disabled:l=!1,orientation:f,dir:R,loop:v=!0,onValueChange:p,...m}=t,i=j(o),u=L(R),[h,x]=B({prop:r,defaultProp:e??null,onChange:p,caller:C});return c.jsx(J,{scope:o,name:n,required:a,disabled:l,value:h,onValueChange:x,children:c.jsx(q,{asChild:!0,...i,orientation:f,dir:u,loop:v,children:c.jsx(y.div,{role:"radiogroup","aria-required":a,"aria-orientation":f,"data-disabled":l?"":void 0,dir:u,...m,ref:d})})})});D.displayName=C;var M="RadioGroupItem",O=s.forwardRef((t,d)=>{const{__scopeRadioGroup:o,disabled:n,...e}=t,r=Q(M,o),a=r.disabled||n,l=j(o),f=N(o),R=s.useRef(null),v=b(d,R),p=r.value===e.value,m=s.useRef(!1);return s.useEffect(()=>{const i=h=>{Y.includes(h.key)&&(m.current=!0)},u=()=>m.current=!1;return document.addEventListener("keydown",i),document.addEventListener("keyup",u),()=>{document.removeEventListener("keydown",i),document.removeEventListener("keyup",u)}},[]),c.jsx(K,{asChild:!0,...l,focusable:!a,active:p,children:c.jsx(P,{disabled:a,required:r.required,checked:p,...f,...e,name:r.name,ref:v,onCheck:()=>r.onValueChange(e.value),onKeyDown:E(i=>{i.key==="Enter"&&i.preventDefault()}),onFocus:E(e.onFocus,()=>{m.current&&R.current?.click()})})})});O.displayName=M;var Z="RadioGroupIndicator",F=s.forwardRef((t,d)=>{const{__scopeRadioGroup:o,...n}=t,e=N(o);return c.jsx(G,{...e,...n,ref:d})});F.displayName=Z;var oe=D,re=O,te=F;export{re as I,oe as R,te as a};
1
+ import{r as s,c0 as L,c1 as B,j as c,g0 as q,c6 as y,c4 as b,f$ as K,c7 as E,g1 as _,e1 as T,ck as k,cd as U,co as V}from"./index-BVZH8mqe.js";var I="Radio",[z,w]=k(I),[H,W]=z(I),P=s.forwardRef((t,d)=>{const{__scopeRadio:o,name:n,checked:e=!1,required:r,disabled:a,value:l="on",onCheck:f,form:R,...v}=t,[p,m]=s.useState(null),i=b(d,x=>m(x)),u=s.useRef(!1),h=p?R||!!p.closest("form"):!0;return c.jsxs(H,{scope:o,checked:e,disabled:a,children:[c.jsx(y.button,{type:"button",role:"radio","aria-checked":e,"data-state":A(e),"data-disabled":a?"":void 0,disabled:a,value:l,...v,ref:i,onClick:E(t.onClick,x=>{e||f?.(),h&&(u.current=x.isPropagationStopped(),u.current||x.stopPropagation())})}),h&&c.jsx(S,{control:p,bubbles:!u.current,name:n,value:l,checked:e,required:r,disabled:a,form:R,style:{transform:"translateX(-100%)"}})]})});P.displayName=I;var g="RadioIndicator",G=s.forwardRef((t,d)=>{const{__scopeRadio:o,forceMount:n,...e}=t,r=W(g,o);return c.jsx(T,{present:n||r.checked,children:c.jsx(y.span,{"data-state":A(r.checked),"data-disabled":r.disabled?"":void 0,...e,ref:d})})});G.displayName=g;var X="RadioBubbleInput",S=s.forwardRef(({__scopeRadio:t,control:d,checked:o,bubbles:n=!0,...e},r)=>{const a=s.useRef(null),l=b(a,r),f=U(o),R=V(d);return s.useEffect(()=>{const v=a.current;if(!v)return;const p=window.HTMLInputElement.prototype,i=Object.getOwnPropertyDescriptor(p,"checked").set;if(f!==o&&i){const u=new Event("click",{bubbles:n});i.call(v,o),v.dispatchEvent(u)}},[f,o,n]),c.jsx(y.input,{type:"radio","aria-hidden":!0,defaultChecked:o,...e,tabIndex:-1,ref:l,style:{...e.style,...R,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});S.displayName=X;function A(t){return t?"checked":"unchecked"}var Y=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],C="RadioGroup",[$]=k(C,[_,w]),j=_(),N=w(),[J,Q]=$(C),D=s.forwardRef((t,d)=>{const{__scopeRadioGroup:o,name:n,defaultValue:e,value:r,required:a=!1,disabled:l=!1,orientation:f,dir:R,loop:v=!0,onValueChange:p,...m}=t,i=j(o),u=L(R),[h,x]=B({prop:r,defaultProp:e??null,onChange:p,caller:C});return c.jsx(J,{scope:o,name:n,required:a,disabled:l,value:h,onValueChange:x,children:c.jsx(q,{asChild:!0,...i,orientation:f,dir:u,loop:v,children:c.jsx(y.div,{role:"radiogroup","aria-required":a,"aria-orientation":f,"data-disabled":l?"":void 0,dir:u,...m,ref:d})})})});D.displayName=C;var M="RadioGroupItem",O=s.forwardRef((t,d)=>{const{__scopeRadioGroup:o,disabled:n,...e}=t,r=Q(M,o),a=r.disabled||n,l=j(o),f=N(o),R=s.useRef(null),v=b(d,R),p=r.value===e.value,m=s.useRef(!1);return s.useEffect(()=>{const i=h=>{Y.includes(h.key)&&(m.current=!0)},u=()=>m.current=!1;return document.addEventListener("keydown",i),document.addEventListener("keyup",u),()=>{document.removeEventListener("keydown",i),document.removeEventListener("keyup",u)}},[]),c.jsx(K,{asChild:!0,...l,focusable:!a,active:p,children:c.jsx(P,{disabled:a,required:r.required,checked:p,...f,...e,name:r.name,ref:v,onCheck:()=>r.onValueChange(e.value),onKeyDown:E(i=>{i.key==="Enter"&&i.preventDefault()}),onFocus:E(e.onFocus,()=>{m.current&&R.current?.click()})})})});O.displayName=M;var Z="RadioGroupIndicator",F=s.forwardRef((t,d)=>{const{__scopeRadioGroup:o,...n}=t,e=N(o);return c.jsx(G,{...e,...n,ref:d})});F.displayName=Z;var oe=D,re=O,te=F;export{re as I,oe as R,te as a};
@@ -1 +1 @@
1
- import{c as v,a6 as z,K as W,i as Y,m as $,j as l,b as M,B,L as V,r as w,d as K,E as L,x as X,aU as Z,w as J,v as ee,D as te}from"./index-BGvfgBXQ.js";import{n as se}from"./ArrowUp-bsUZSt57.js";import{u as H,f as G,T as ne,A as ae,n as re,o as ie,b as oe,c as le,p as ce,q as ue,t as de,L as fe}from"./chat-context-Dk_Ebz6D.js";import{T as me,c as ge,b as xe,d as pe,H as he}from"./input-CIXcgL8B.js";import{u as je,a as ve,S as be,M as A}from"./pair-M_Ks4KYr.js";import{A as ye,f as Q}from"./agent-icon-CFsULo4q.js";import{n as Ne}from"./use-sandbox-events-Bh6eTl2p.js";import{a as Ce}from"./agent-capabilities-Dsy9OzBC.js";import{a as we}from"./repository-binding-DrxBu24C.js";import{c as Se,i as ke}from"./thread-intent-DJ2isQQx.js";import{a as Te}from"./use-panel-navigate-BEVdshk4.js";import{N as $e}from"./index-ztFBZP-a.js";import{i as Ee}from"./ArrowRight-DYc-7xj5.js";import{d as De}from"./use-entitlements-BnUu4797.js";import{u as Pe}from"./use-deco-credits-D1eTXz3B.js";import{F as _e}from"./feature-paywall-CXj-cCjT.js";import{i as Ie}from"./AlertCircle-BPb6lfDc.js";const Oe=15e3;function Me(e,t,n){const s=v.c(20),r=n===void 0?{}:n,{org:a}=z(),i=we(e);let c;s[0]!==t||s[1]!==i?.metadata||s[2]!==e?(c=!!e&&!!t&&Ce(i?.metadata),s[0]=t,s[1]=i?.metadata,s[2]=e,s[3]=c):c=s[3];const u=c;let o;s[4]!==t||s[5]!==a.slug||s[6]!==e?(o=W.chatDraftChanges(a.slug,e??"",t??""),s[4]=t,s[5]=a.slug,s[6]=e,s[7]=o):o=s[7];let d;s[8]!==t||s[9]!==a.slug||s[10]!==e?(d=()=>Ne(a.slug,e,t),s[8]=t,s[9]=a.slug,s[10]=e,s[11]=d):d=s[11];const p=r.poll===!1?!1:Oe;let g;s[12]!==u||s[13]!==o||s[14]!==d||s[15]!==p?(g={queryKey:o,queryFn:d,enabled:u,refetchInterval:p,retry:!1},s[12]=u,s[13]=o,s[14]=d,s[15]=p,s[16]=g):g=s[16];const{data:m}=Y(g),f=m===void 0?0:m,x=u?i:null;let h;return s[17]!==f||s[18]!==x?(h={project:x,changeCount:f},s[17]=f,s[18]=x,s[19]=h):h=s[19],h}function Fe(){const e=v.c(7),t=H(),n=G(),s=t?.virtualMcpId??null,r=t?.currentBranch??null,{project:a,changeCount:i}=Me(s,r);if(!a||!s||!r||i===0)return null;const c=a.icon??null,u=!!n&&(n.isRunInProgress||n.status==="streaming"||n.status==="submitted");let o;return e[0]!==r||e[1]!==i||e[2]!==a.title||e[3]!==c||e[4]!==u||e[5]!==s?(o={virtualMcpId:s,projectTitle:a.title,projectIcon:c,branch:r,changeCount:i,editing:u},e[0]=r,e[1]=i,e[2]=a.title,e[3]=c,e[4]=u,e[5]=s,e[6]=o):o=e[6],o}function Re(e){const t=v.c(24),{icon:n,title:s,subtitle:r,status:a,detail:i,action:c,className:u}=e;let o;t[0]!==u?(o=$("rounded-xl border border-border bg-card p-3",u),t[0]=u,t[1]=o):o=t[1];let d;t[2]!==n?(d=l.jsx("div",{className:"shrink-0",children:n}),t[2]=n,t[3]=d):d=t[3];let p;t[4]!==s?(p=l.jsx("p",{className:"truncate text-sm font-medium text-foreground",children:s}),t[4]=s,t[5]=p):p=t[5];let g;t[6]!==r?(g=r&&l.jsx("p",{className:"truncate text-xs text-muted-foreground",children:r}),t[6]=r,t[7]=g):g=t[7];let m;t[8]!==p||t[9]!==g?(m=l.jsxs("div",{className:"min-w-0 flex-1",children:[p,g]}),t[8]=p,t[9]=g,t[10]=m):m=t[10];let f;t[11]!==a?(f=a&&l.jsx("span",{className:"flex shrink-0 items-center gap-1.5 text-sm text-muted-foreground",children:a}),t[11]=a,t[12]=f):f=t[12];let x;t[13]!==d||t[14]!==m||t[15]!==f?(x=l.jsxs("div",{className:"flex items-center gap-2.5",children:[d,m,f]}),t[13]=d,t[14]=m,t[15]=f,t[16]=x):x=t[16];let h;t[17]!==c||t[18]!==i?(h=(i||c)&&l.jsxs("div",{className:"mt-3 flex items-center justify-between gap-2",children:[l.jsx("span",{className:"text-sm text-muted-foreground",children:i}),c]}),t[17]=c,t[18]=i,t[19]=h):h=t[19];let b;return t[20]!==o||t[21]!==x||t[22]!==h?(b=l.jsxs("div",{className:o,children:[x,h]}),t[20]=o,t[21]=x,t[22]=h,t[23]=b):b=t[23],b}function ze(e){const t=v.c(10),{draft:n}=e,s=M(),r=n.editing?"animate-pulse bg-warning":"bg-success";let a;t[0]!==r?(a=$("size-1.5 rounded-full",r),t[0]=r,t[1]=a):a=t[1];let i;t[2]!==a?(i=l.jsx("span",{"aria-hidden":!0,className:a}),t[2]=a,t[3]=i):i=t[3];const c=n.editing?"chat.draft.editing":"chat.draft.ready";let u;t[4]!==s||t[5]!==c?(u=s(c),t[4]=s,t[5]=c,t[6]=u):u=t[6];let o;return t[7]!==i||t[8]!==u?(o=l.jsxs(l.Fragment,{children:[i,u]}),t[7]=i,t[8]=u,t[9]=o):o=t[9],o}function Be(e){const t=v.c(11),{draft:n}=e,s=M(),{org:r}=z(),a=H()?.taskId??null;let i;t[0]!==n.virtualMcpId||t[1]!==r.slug?(i={org:r.slug,agentId:n.virtualMcpId},t[0]=n.virtualMcpId,t[1]=r.slug,t[2]=i):i=t[2];let c;t[3]!==a?(c=a?{thread:a}:{},t[3]=a,t[4]=c):c=t[4];let u;t[5]!==s?(u=s("chat.draft.open"),t[5]=s,t[6]=u):u=t[6];let o;return t[7]!==i||t[8]!==c||t[9]!==u?(o=l.jsx(B,{variant:"outline",size:"sm",asChild:!0,children:l.jsx(V,{to:"/$org/projects/$agentId/site-editor",params:i,search:c,children:u})}),t[7]=i,t[8]=c,t[9]=u,t[10]=o):o=t[10],o}function q(){const e=v.c(20),t=M(),n=Fe();if(!n)return null;let s;e[0]!==n.projectIcon||e[1]!==n.projectTitle?(s=l.jsx(ye,{icon:n.projectIcon,name:n.projectTitle,size:"sm"}),e[0]=n.projectIcon,e[1]=n.projectTitle,e[2]=s):s=e[2];const r=n.projectTitle;let a;e[3]!==n.branch?(a=l.jsx("span",{className:"font-mono",children:n.branch}),e[3]=n.branch,e[4]=a):a=e[4];let i;e[5]!==n?(i=l.jsx(ze,{draft:n}),e[5]=n,e[6]=i):i=e[6];const c=n.changeCount===1?"chat.draft.change":"chat.draft.changes";let u;e[7]!==n.changeCount||e[8]!==t||e[9]!==c?(u=t(c,{count:n.changeCount}),e[7]=n.changeCount,e[8]=t,e[9]=c,e[10]=u):u=e[10];let o;e[11]!==n?(o=l.jsx(Be,{draft:n}),e[11]=n,e[12]=o):o=e[12];let d;return e[13]!==n.projectTitle||e[14]!==s||e[15]!==a||e[16]!==i||e[17]!==u||e[18]!==o?(d=l.jsx(Re,{className:"mx-2.5 mb-6",icon:s,title:r,subtitle:a,status:i,detail:u,action:o}),e[13]=n.projectTitle,e[14]=s,e[15]=a,e[16]=i,e[17]=u,e[18]=o,e[19]=d):d=e[19],d}function He(e){return e.parts.some(t=>t.type==="dynamic-tool"||t.type.startsWith("tool-"))}function Le(e){let t=0;for(const n of e)for(const s of n.parts??[]){const r=s;r.type==="tool-load_repo"&&r.state==="output-available"&&r.output?.success===!0&&t++}return t}function Ae(){const e=v.c(11),{openPanel:t}=Te(),n=Se(),s=G()?.messages??[],r=H(),a=r?.taskId??null,i=r?.currentBranch;let c;e[0]!==i?(c=ke(i),e[0]=i,e[1]=c):c=e[1];const u=c;let o;e[2]!==s?(o=Le(s),e[2]=s,e[3]=o):o=e[3];const d=o,p=w.useRef(null),g=w.useRef(null);let m,f;e[4]!==u||e[5]!==d||e[6]!==n||e[7]!==t||e[8]!==a?(m=()=>{if(!d||!a)return;const x=`${a}:${d}`;g.current!==x&&(g.current=x,n?.refreshThreadMetadata(a)),p.current!==a&&(p.current=a,u||t("site-editor"))},f=[d,a,t,n,u],e[4]=u,e[5]=d,e[6]=n,e[7]=t,e[8]=a,e[9]=m,e[10]=f):(m=e[9],f=e[10]),w.useEffect(m,f)}function U(e){return`deco-credits-empty-dismissed:${e}`}function pt(e){try{return localStorage.getItem(U(e))==="1"}catch{return!1}}function qe(){const e=v.c(56),t=M(),{org:n}=z(),s=De("credits"),r=K(),{decoKeyId:a}=Pe(),[i,c]=w.useState(!0);let u;e[0]!==n.id?(u=()=>{L("credits_empty_state_dismissed",{organization_id:n.id}),c(!1);try{localStorage.setItem(U(n.id),"1")}catch{}},e[0]=n.id,e[1]=u):u=e[1];const o=u;let d,p;if(e[2]!==i||e[3]!==n.id?(d=()=>{i&&L("credits_empty_state_shown",{organization_id:n.id})},p=[i,n.id],e[2]=i,e[3]=n.id,e[4]=d,e[5]=p):(d=e[4],p=e[5]),w.useEffect(d,p),!i)return null;if(!s){let k;e[6]!==t?(k=t("chat.input.allowanceExhaustedTitle"),e[6]=t,e[7]=k):k=e[7];let O;e[8]!==k?(O={title:k},e[8]=k,e[9]=O):O=e[9];let R;return e[10]!==o||e[11]!==O?(R=l.jsx(_e,{feature:"chat",copy:O,onDismiss:o}),e[10]=o,e[11]=O,e[12]=R):R=e[12],R}let g;e[13]!==o?(g=k=>!k&&o(),e[13]=o,e[14]=g):g=e[14];let m;e[15]===Symbol.for("react.memo_cache_sentinel")?(m=l.jsx("div",{className:"absolute inset-x-0 top-0 h-24 bg-gradient-to-b from-warning/8 to-transparent pointer-events-none rounded-t-lg"}),e[15]=m):m=e[15];let f;e[16]===Symbol.for("react.memo_cache_sentinel")?(f=l.jsx("div",{className:"flex items-center justify-center size-11 rounded-full bg-warning/10 border border-warning/20 mx-auto",children:l.jsx(Q,{size:20,className:"text-warning"})}),e[16]=f):f=e[16];let x;e[17]!==t?(x=t("chat.creditsEmptyState.title"),e[17]=t,e[18]=x):x=e[18];let h;e[19]!==x?(h=l.jsx(X,{className:"text-lg font-semibold",children:x}),e[19]=x,e[20]=h):h=e[20];let b;e[21]!==t?(b=t("chat.creditsEmptyState.description"),e[21]=t,e[22]=b):b=e[22];let N;e[23]!==b?(N=l.jsx(Z,{className:"mt-2 text-sm leading-relaxed max-w-[320px] mx-auto",children:b}),e[23]=b,e[24]=N):N=e[24];let C;e[25]!==h||e[26]!==N?(C=l.jsxs("div",{className:"relative px-6 pt-7 pb-5",children:[m,l.jsxs(J,{className:"relative gap-3",children:[f,l.jsxs("div",{className:"text-center",children:[h,N]})]})]}),e[25]=h,e[26]=N,e[27]=C):C=e[27];let y;e[28]!==a||e[29]!==o?(y=a&&l.jsx("div",{className:"px-6 pb-5",children:l.jsx(me,{source:"empty_state",onDone:o})}),e[28]=a,e[29]=o,e[30]=y):y=e[30];let S;e[31]!==o||e[32]!==r||e[33]!==n.slug?(S=()=>{r({to:"/$org/settings/ai-providers",params:{org:n.slug}}),o()},e[31]=o,e[32]=r,e[33]=n.slug,e[34]=S):S=e[34];let j;e[35]!==t?(j=t("chat.creditsEmptyState.useYourOwnProvider"),e[35]=t,e[36]=j):j=e[36];let T;e[37]===Symbol.for("react.memo_cache_sentinel")?(T=l.jsx(Ee,{size:12,className:"transition-transform duration-150 group-hover:translate-x-0.5"}),e[37]=T):T=e[37];let E;e[38]!==S||e[39]!==j?(E=l.jsxs("button",{type:"button",className:"group flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground transition-colors",onClick:S,children:[j,T]}),e[38]=S,e[39]=j,e[40]=E):E=e[40];let D;e[41]!==t?(D=t("chat.creditsEmptyState.skipForNow"),e[41]=t,e[42]=D):D=e[42];let P;e[43]!==o||e[44]!==D?(P=l.jsx(B,{variant:"ghost",size:"sm",className:"text-xs text-muted-foreground",onClick:o,children:D}),e[43]=o,e[44]=D,e[45]=P):P=e[45];let _;e[46]!==E||e[47]!==P?(_=l.jsxs("div",{className:"px-6 py-3.5 border-t border-border bg-muted/30 flex items-center justify-between",children:[E,P]}),e[46]=E,e[47]=P,e[48]=_):_=e[48];let I;e[49]!==C||e[50]!==y||e[51]!==_?(I=l.jsxs(ee,{className:"sm:max-w-[500px] gap-0 p-0 overflow-hidden",onOpenAutoFocus:Ke,children:[C,y,_]}),e[49]=C,e[50]=y,e[51]=_,e[52]=I):I=e[52];let F;return e[53]!==I||e[54]!==g?(F=l.jsx(te,{open:!0,onOpenChange:g,children:I}),e[53]=I,e[54]=g,e[55]=F):F=e[55],F}function Ke(e){return e.preventDefault()}function Ge(e){const t=v.c(6),{balanceDollars:n}=e;let s;t[0]!==n?(s=n.toFixed(2),t[0]=n,t[1]=s):s=t[1];const r=s;let a,i;t[2]===Symbol.for("react.memo_cache_sentinel")?(a=$("inline-flex items-center gap-1.5 px-3 py-1 rounded-full","bg-success/10 border border-success/20","animate-in fade-in-0 slide-in-from-bottom-2 duration-300"),i=l.jsx(Q,{size:13,className:"text-success"}),t[2]=a,t[3]=i):(a=t[2],i=t[3]);let c;return t[4]!==r?(c=l.jsxs("div",{className:a,children:[i,l.jsxs("span",{className:"text-xs font-medium text-success tabular-nums",children:["$",r," in credits to get started"]})]}),t[4]=r,t[5]=c):c=t[5],c}function Qe(){const e=v.c(8),{org:t}=z(),n=K();let s;e[0]!==n||e[1]!==t.slug?(s=()=>n({to:"/$org/settings/ai-providers",params:{org:t.slug}}),e[0]=n,e[1]=t.slug,e[2]=s):s=e[2];let r,a,i;e[3]===Symbol.for("react.memo_cache_sentinel")?(r=$("inline-flex items-center gap-1.5 px-3 py-1 rounded-lg cursor-pointer","bg-warning/10 border border-warning/20","hover:bg-warning/15","transition-colors duration-150","animate-in fade-in-0 slide-in-from-bottom-2 duration-300"),a=l.jsx(Ie,{size:13,className:"text-warning"}),i=l.jsx("span",{className:"text-xs font-medium text-warning",children:"No credits remaining · Add more"}),e[3]=r,e[4]=a,e[5]=i):(r=e[3],a=e[4],i=e[5]);let c;return e[6]!==s?(c=l.jsxs("button",{type:"button",onClick:s,className:r,children:[a,i]}),e[6]=s,e[7]=c):c=e[7],c}function Ue(e){const t=v.c(7),{scrollRef:n,sentinelRef:s,hasMoreOlder:r,isFetchingOlder:a,fetchOlderMessages:i}=e;let c,u;t[0]!==i||t[1]!==r||t[2]!==a||t[3]!==n||t[4]!==s?(c=()=>{const o=s.current,d=n.current;if(!o||!d||!r)return;const p=new IntersectionObserver(async g=>{if(!g[0]?.isIntersecting||a||!r)return;const f=d.scrollHeight,x=d.scrollTop;await i(),requestAnimationFrame(()=>{const h=d.scrollHeight;d.scrollTop=x+(h-f)})},{root:d,rootMargin:"200px 0px 0px 0px"});return p.observe(o),()=>p.disconnect()},u=[n,s,r,a,i],t[0]=i,t[1]=r,t[2]=a,t[3]=n,t[4]=s,t[5]=c,t[6]=u):(c=t[5],u=t[6]),w.useEffect(c,u)}function We(e){const t=v.c(5),{className:n,children:s}=e;let r;t[0]!==n?(r=$("flex flex-col h-full w-full bg-background transform-[translateZ(0)]",n),t[0]=n,t[1]=r):r=t[1];let a;return t[2]!==s||t[3]!==r?(a=l.jsx("div",{className:r,children:s}),t[2]=s,t[3]=r,t[4]=a):a=t[4],a}function Ye(e){const t=v.c(5),{children:n,className:s}=e;let r;t[0]!==s?(r=$("flex-1 min-h-0 overflow-y-auto isolate",s),t[0]=s,t[1]=r):r=t[1];let a;return t[2]!==n||t[3]!==r?(a=l.jsx("div",{className:r,children:n}),t[2]=n,t[3]=r,t[4]=a):a=t[4],a}function Ve(e){const t=v.c(2),{children:n}=e;let s;return t[0]!==n?(s=l.jsx("div",{className:"min-h-full shrink-0 w-full flex items-center justify-center max-w-2xl mx-auto py-10",children:n}),t[0]=n,t[1]=s):s=t[1],s}function Xe(){const e=M(),{messages:t,status:n,hasMoreOlder:s,isFetchingOlder:r,fetchOlderMessages:a,isRunInProgress:i}=oe(),{taskId:c}=le();Ae();const u=ce(c??""),o=ue(u),d=o.size===0?t:t.filter(j=>!o.has(j.id)),p=de(d,n==="submitted"||n==="streaming"||i),g=p.visible,m=je(g),f=m.at(-1),x=m.findIndex(j=>!!j.assistant&&He(j.assistant)),b=pe()*he+16,N=w.useRef(null),C=w.useRef(null);Ue({scrollRef:N,sentinelRef:C,hasMoreOlder:s,isFetchingOlder:r,fetchOlderMessages:a});const y=ve({initial:!1}),S=j=>{N.current=j,y.scrollRef(j)};return l.jsx(fe.Provider,{value:p,children:l.jsx(be,{messages:t,children:l.jsxs("div",{className:"relative h-full w-full min-w-0",children:[l.jsx("div",{ref:S,"data-chat-scroller":!0,className:"w-full min-w-0 max-w-full overflow-y-auto h-full [container-type:size]",style:{paddingBottom:b},children:l.jsxs("div",{ref:y.contentRef,className:"overflow-x-clip",children:[l.jsxs("div",{className:"flex flex-col min-w-0 max-w-2xl mx-auto w-full",children:[l.jsx("div",{ref:C,"aria-hidden":!0,className:"h-px"}),r&&l.jsx("div",{className:"flex items-center justify-center py-3 text-xs text-muted-foreground",children:e("chat.chat.loadingOlderMessages")}),m.slice(0,-1).map((j,T)=>l.jsxs(w.Fragment,{children:[l.jsx(A,{pair:j,isLastPair:!1,status:T===m.length-1?n:void 0}),T===x&&l.jsx(q,{})]},`pair-${j.user?.id??j.assistant?.id}`))]}),f&&l.jsxs("div",{className:"min-h-[100cqh] min-w-0 max-w-2xl mx-auto w-full",children:[l.jsx(A,{pair:f,isLastPair:!0,status:n},`pair-${f.user?.id??f.assistant?.id}`),x===m.length-1&&l.jsx(q,{})]})]})}),!y.isAtBottom&&l.jsx(B,{type:"button",variant:"outline",size:"icon-sm","aria-label":e("chat.chat.jumpToLatest"),className:"absolute left-1/2 z-50 -translate-x-1/2 shadow-soft animate-in fade-in duration-200 dark:bg-background dark:hover:bg-accent",style:{bottom:b+8},onClick:()=>{y.scrollToBottom()},children:l.jsx(se,{size:14})})]})})})}function Ze(e){const t=v.c(5),{children:n,className:s}=e;let r;t[0]!==s?(r=$("flex-none w-full mx-auto p-2 pt-0","max-w-2xl min-w-0",s),t[0]=s,t[1]=r):r=t[1];let a;return t[2]!==n||t[3]!==r?(a=l.jsx("div",{className:r,children:n}),t[2]=n,t[3]=r,t[4]=a):a=t[4],a}const ht=Object.assign(We,{Main:Ye,Messages:Xe,EmptyState:Ve,Footer:Ze,Input:xe,Provider:ie,StreamHost:re,ActiveTaskStreamSource:ae,ThreadlessStreamSource:ne,NoAiProviderEmptyState:$e,CreditsEmptyState:qe,CreditsEyebrow:Ge,NoCreditsEyebrow:Qe,CreditsExhaustedBanner:ge});export{ht as C,Me as u,pt as w};
1
+ import{c as v,a6 as z,K as W,i as Y,m as $,j as l,b as M,B,L as V,r as w,d as K,E as L,x as X,aU as Z,w as J,v as ee,D as te}from"./index-BVZH8mqe.js";import{n as se}from"./ArrowUp-CjAvmMLL.js";import{u as H,f as G,T as ne,A as ae,n as re,o as ie,b as oe,c as le,p as ce,q as ue,t as de,L as fe}from"./chat-context-B6UvvRRf.js";import{T as me,c as ge,b as xe,d as pe,H as he}from"./input-o0eNZBV4.js";import{u as je,a as ve,S as be,M as A}from"./pair-C4tumP78.js";import{A as ye,f as Q}from"./agent-icon-BS6RPQ_A.js";import{n as Ne}from"./use-sandbox-events-TxpzU2Iw.js";import{a as Ce}from"./agent-capabilities-CJLhsDjp.js";import{a as we}from"./repository-binding-BIfwJXBl.js";import{c as Se,i as ke}from"./thread-intent-CYNXEfHP.js";import{a as Te}from"./use-panel-navigate-DPGDB1T1.js";import{N as $e}from"./index-GMDFirHC.js";import{i as Ee}from"./ArrowRight-ajc9j6D-.js";import{d as De}from"./use-entitlements-B8D7pawV.js";import{u as Pe}from"./use-deco-credits-19cW8oHb.js";import{F as _e}from"./feature-paywall-BGOy9Z00.js";import{i as Ie}from"./AlertCircle-kHXzu73r.js";const Oe=15e3;function Me(e,t,n){const s=v.c(20),r=n===void 0?{}:n,{org:a}=z(),i=we(e);let c;s[0]!==t||s[1]!==i?.metadata||s[2]!==e?(c=!!e&&!!t&&Ce(i?.metadata),s[0]=t,s[1]=i?.metadata,s[2]=e,s[3]=c):c=s[3];const u=c;let o;s[4]!==t||s[5]!==a.slug||s[6]!==e?(o=W.chatDraftChanges(a.slug,e??"",t??""),s[4]=t,s[5]=a.slug,s[6]=e,s[7]=o):o=s[7];let d;s[8]!==t||s[9]!==a.slug||s[10]!==e?(d=()=>Ne(a.slug,e,t),s[8]=t,s[9]=a.slug,s[10]=e,s[11]=d):d=s[11];const p=r.poll===!1?!1:Oe;let g;s[12]!==u||s[13]!==o||s[14]!==d||s[15]!==p?(g={queryKey:o,queryFn:d,enabled:u,refetchInterval:p,retry:!1},s[12]=u,s[13]=o,s[14]=d,s[15]=p,s[16]=g):g=s[16];const{data:m}=Y(g),f=m===void 0?0:m,x=u?i:null;let h;return s[17]!==f||s[18]!==x?(h={project:x,changeCount:f},s[17]=f,s[18]=x,s[19]=h):h=s[19],h}function Fe(){const e=v.c(7),t=H(),n=G(),s=t?.virtualMcpId??null,r=t?.currentBranch??null,{project:a,changeCount:i}=Me(s,r);if(!a||!s||!r||i===0)return null;const c=a.icon??null,u=!!n&&(n.isRunInProgress||n.status==="streaming"||n.status==="submitted");let o;return e[0]!==r||e[1]!==i||e[2]!==a.title||e[3]!==c||e[4]!==u||e[5]!==s?(o={virtualMcpId:s,projectTitle:a.title,projectIcon:c,branch:r,changeCount:i,editing:u},e[0]=r,e[1]=i,e[2]=a.title,e[3]=c,e[4]=u,e[5]=s,e[6]=o):o=e[6],o}function Re(e){const t=v.c(24),{icon:n,title:s,subtitle:r,status:a,detail:i,action:c,className:u}=e;let o;t[0]!==u?(o=$("rounded-xl border border-border bg-card p-3",u),t[0]=u,t[1]=o):o=t[1];let d;t[2]!==n?(d=l.jsx("div",{className:"shrink-0",children:n}),t[2]=n,t[3]=d):d=t[3];let p;t[4]!==s?(p=l.jsx("p",{className:"truncate text-sm font-medium text-foreground",children:s}),t[4]=s,t[5]=p):p=t[5];let g;t[6]!==r?(g=r&&l.jsx("p",{className:"truncate text-xs text-muted-foreground",children:r}),t[6]=r,t[7]=g):g=t[7];let m;t[8]!==p||t[9]!==g?(m=l.jsxs("div",{className:"min-w-0 flex-1",children:[p,g]}),t[8]=p,t[9]=g,t[10]=m):m=t[10];let f;t[11]!==a?(f=a&&l.jsx("span",{className:"flex shrink-0 items-center gap-1.5 text-sm text-muted-foreground",children:a}),t[11]=a,t[12]=f):f=t[12];let x;t[13]!==d||t[14]!==m||t[15]!==f?(x=l.jsxs("div",{className:"flex items-center gap-2.5",children:[d,m,f]}),t[13]=d,t[14]=m,t[15]=f,t[16]=x):x=t[16];let h;t[17]!==c||t[18]!==i?(h=(i||c)&&l.jsxs("div",{className:"mt-3 flex items-center justify-between gap-2",children:[l.jsx("span",{className:"text-sm text-muted-foreground",children:i}),c]}),t[17]=c,t[18]=i,t[19]=h):h=t[19];let b;return t[20]!==o||t[21]!==x||t[22]!==h?(b=l.jsxs("div",{className:o,children:[x,h]}),t[20]=o,t[21]=x,t[22]=h,t[23]=b):b=t[23],b}function ze(e){const t=v.c(10),{draft:n}=e,s=M(),r=n.editing?"animate-pulse bg-warning":"bg-success";let a;t[0]!==r?(a=$("size-1.5 rounded-full",r),t[0]=r,t[1]=a):a=t[1];let i;t[2]!==a?(i=l.jsx("span",{"aria-hidden":!0,className:a}),t[2]=a,t[3]=i):i=t[3];const c=n.editing?"chat.draft.editing":"chat.draft.ready";let u;t[4]!==s||t[5]!==c?(u=s(c),t[4]=s,t[5]=c,t[6]=u):u=t[6];let o;return t[7]!==i||t[8]!==u?(o=l.jsxs(l.Fragment,{children:[i,u]}),t[7]=i,t[8]=u,t[9]=o):o=t[9],o}function Be(e){const t=v.c(11),{draft:n}=e,s=M(),{org:r}=z(),a=H()?.taskId??null;let i;t[0]!==n.virtualMcpId||t[1]!==r.slug?(i={org:r.slug,agentId:n.virtualMcpId},t[0]=n.virtualMcpId,t[1]=r.slug,t[2]=i):i=t[2];let c;t[3]!==a?(c=a?{thread:a}:{},t[3]=a,t[4]=c):c=t[4];let u;t[5]!==s?(u=s("chat.draft.open"),t[5]=s,t[6]=u):u=t[6];let o;return t[7]!==i||t[8]!==c||t[9]!==u?(o=l.jsx(B,{variant:"outline",size:"sm",asChild:!0,children:l.jsx(V,{to:"/$org/projects/$agentId/site-editor",params:i,search:c,children:u})}),t[7]=i,t[8]=c,t[9]=u,t[10]=o):o=t[10],o}function q(){const e=v.c(20),t=M(),n=Fe();if(!n)return null;let s;e[0]!==n.projectIcon||e[1]!==n.projectTitle?(s=l.jsx(ye,{icon:n.projectIcon,name:n.projectTitle,size:"sm"}),e[0]=n.projectIcon,e[1]=n.projectTitle,e[2]=s):s=e[2];const r=n.projectTitle;let a;e[3]!==n.branch?(a=l.jsx("span",{className:"font-mono",children:n.branch}),e[3]=n.branch,e[4]=a):a=e[4];let i;e[5]!==n?(i=l.jsx(ze,{draft:n}),e[5]=n,e[6]=i):i=e[6];const c=n.changeCount===1?"chat.draft.change":"chat.draft.changes";let u;e[7]!==n.changeCount||e[8]!==t||e[9]!==c?(u=t(c,{count:n.changeCount}),e[7]=n.changeCount,e[8]=t,e[9]=c,e[10]=u):u=e[10];let o;e[11]!==n?(o=l.jsx(Be,{draft:n}),e[11]=n,e[12]=o):o=e[12];let d;return e[13]!==n.projectTitle||e[14]!==s||e[15]!==a||e[16]!==i||e[17]!==u||e[18]!==o?(d=l.jsx(Re,{className:"mx-2.5 mb-6",icon:s,title:r,subtitle:a,status:i,detail:u,action:o}),e[13]=n.projectTitle,e[14]=s,e[15]=a,e[16]=i,e[17]=u,e[18]=o,e[19]=d):d=e[19],d}function He(e){return e.parts.some(t=>t.type==="dynamic-tool"||t.type.startsWith("tool-"))}function Le(e){let t=0;for(const n of e)for(const s of n.parts??[]){const r=s;r.type==="tool-load_repo"&&r.state==="output-available"&&r.output?.success===!0&&t++}return t}function Ae(){const e=v.c(11),{openPanel:t}=Te(),n=Se(),s=G()?.messages??[],r=H(),a=r?.taskId??null,i=r?.currentBranch;let c;e[0]!==i?(c=ke(i),e[0]=i,e[1]=c):c=e[1];const u=c;let o;e[2]!==s?(o=Le(s),e[2]=s,e[3]=o):o=e[3];const d=o,p=w.useRef(null),g=w.useRef(null);let m,f;e[4]!==u||e[5]!==d||e[6]!==n||e[7]!==t||e[8]!==a?(m=()=>{if(!d||!a)return;const x=`${a}:${d}`;g.current!==x&&(g.current=x,n?.refreshThreadMetadata(a)),p.current!==a&&(p.current=a,u||t("site-editor"))},f=[d,a,t,n,u],e[4]=u,e[5]=d,e[6]=n,e[7]=t,e[8]=a,e[9]=m,e[10]=f):(m=e[9],f=e[10]),w.useEffect(m,f)}function U(e){return`deco-credits-empty-dismissed:${e}`}function pt(e){try{return localStorage.getItem(U(e))==="1"}catch{return!1}}function qe(){const e=v.c(56),t=M(),{org:n}=z(),s=De("credits"),r=K(),{decoKeyId:a}=Pe(),[i,c]=w.useState(!0);let u;e[0]!==n.id?(u=()=>{L("credits_empty_state_dismissed",{organization_id:n.id}),c(!1);try{localStorage.setItem(U(n.id),"1")}catch{}},e[0]=n.id,e[1]=u):u=e[1];const o=u;let d,p;if(e[2]!==i||e[3]!==n.id?(d=()=>{i&&L("credits_empty_state_shown",{organization_id:n.id})},p=[i,n.id],e[2]=i,e[3]=n.id,e[4]=d,e[5]=p):(d=e[4],p=e[5]),w.useEffect(d,p),!i)return null;if(!s){let k;e[6]!==t?(k=t("chat.input.allowanceExhaustedTitle"),e[6]=t,e[7]=k):k=e[7];let O;e[8]!==k?(O={title:k},e[8]=k,e[9]=O):O=e[9];let R;return e[10]!==o||e[11]!==O?(R=l.jsx(_e,{feature:"chat",copy:O,onDismiss:o}),e[10]=o,e[11]=O,e[12]=R):R=e[12],R}let g;e[13]!==o?(g=k=>!k&&o(),e[13]=o,e[14]=g):g=e[14];let m;e[15]===Symbol.for("react.memo_cache_sentinel")?(m=l.jsx("div",{className:"absolute inset-x-0 top-0 h-24 bg-gradient-to-b from-warning/8 to-transparent pointer-events-none rounded-t-lg"}),e[15]=m):m=e[15];let f;e[16]===Symbol.for("react.memo_cache_sentinel")?(f=l.jsx("div",{className:"flex items-center justify-center size-11 rounded-full bg-warning/10 border border-warning/20 mx-auto",children:l.jsx(Q,{size:20,className:"text-warning"})}),e[16]=f):f=e[16];let x;e[17]!==t?(x=t("chat.creditsEmptyState.title"),e[17]=t,e[18]=x):x=e[18];let h;e[19]!==x?(h=l.jsx(X,{className:"text-lg font-semibold",children:x}),e[19]=x,e[20]=h):h=e[20];let b;e[21]!==t?(b=t("chat.creditsEmptyState.description"),e[21]=t,e[22]=b):b=e[22];let N;e[23]!==b?(N=l.jsx(Z,{className:"mt-2 text-sm leading-relaxed max-w-[320px] mx-auto",children:b}),e[23]=b,e[24]=N):N=e[24];let C;e[25]!==h||e[26]!==N?(C=l.jsxs("div",{className:"relative px-6 pt-7 pb-5",children:[m,l.jsxs(J,{className:"relative gap-3",children:[f,l.jsxs("div",{className:"text-center",children:[h,N]})]})]}),e[25]=h,e[26]=N,e[27]=C):C=e[27];let y;e[28]!==a||e[29]!==o?(y=a&&l.jsx("div",{className:"px-6 pb-5",children:l.jsx(me,{source:"empty_state",onDone:o})}),e[28]=a,e[29]=o,e[30]=y):y=e[30];let S;e[31]!==o||e[32]!==r||e[33]!==n.slug?(S=()=>{r({to:"/$org/settings/ai-providers",params:{org:n.slug}}),o()},e[31]=o,e[32]=r,e[33]=n.slug,e[34]=S):S=e[34];let j;e[35]!==t?(j=t("chat.creditsEmptyState.useYourOwnProvider"),e[35]=t,e[36]=j):j=e[36];let T;e[37]===Symbol.for("react.memo_cache_sentinel")?(T=l.jsx(Ee,{size:12,className:"transition-transform duration-150 group-hover:translate-x-0.5"}),e[37]=T):T=e[37];let E;e[38]!==S||e[39]!==j?(E=l.jsxs("button",{type:"button",className:"group flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground transition-colors",onClick:S,children:[j,T]}),e[38]=S,e[39]=j,e[40]=E):E=e[40];let D;e[41]!==t?(D=t("chat.creditsEmptyState.skipForNow"),e[41]=t,e[42]=D):D=e[42];let P;e[43]!==o||e[44]!==D?(P=l.jsx(B,{variant:"ghost",size:"sm",className:"text-xs text-muted-foreground",onClick:o,children:D}),e[43]=o,e[44]=D,e[45]=P):P=e[45];let _;e[46]!==E||e[47]!==P?(_=l.jsxs("div",{className:"px-6 py-3.5 border-t border-border bg-muted/30 flex items-center justify-between",children:[E,P]}),e[46]=E,e[47]=P,e[48]=_):_=e[48];let I;e[49]!==C||e[50]!==y||e[51]!==_?(I=l.jsxs(ee,{className:"sm:max-w-[500px] gap-0 p-0 overflow-hidden",onOpenAutoFocus:Ke,children:[C,y,_]}),e[49]=C,e[50]=y,e[51]=_,e[52]=I):I=e[52];let F;return e[53]!==I||e[54]!==g?(F=l.jsx(te,{open:!0,onOpenChange:g,children:I}),e[53]=I,e[54]=g,e[55]=F):F=e[55],F}function Ke(e){return e.preventDefault()}function Ge(e){const t=v.c(6),{balanceDollars:n}=e;let s;t[0]!==n?(s=n.toFixed(2),t[0]=n,t[1]=s):s=t[1];const r=s;let a,i;t[2]===Symbol.for("react.memo_cache_sentinel")?(a=$("inline-flex items-center gap-1.5 px-3 py-1 rounded-full","bg-success/10 border border-success/20","animate-in fade-in-0 slide-in-from-bottom-2 duration-300"),i=l.jsx(Q,{size:13,className:"text-success"}),t[2]=a,t[3]=i):(a=t[2],i=t[3]);let c;return t[4]!==r?(c=l.jsxs("div",{className:a,children:[i,l.jsxs("span",{className:"text-xs font-medium text-success tabular-nums",children:["$",r," in credits to get started"]})]}),t[4]=r,t[5]=c):c=t[5],c}function Qe(){const e=v.c(8),{org:t}=z(),n=K();let s;e[0]!==n||e[1]!==t.slug?(s=()=>n({to:"/$org/settings/ai-providers",params:{org:t.slug}}),e[0]=n,e[1]=t.slug,e[2]=s):s=e[2];let r,a,i;e[3]===Symbol.for("react.memo_cache_sentinel")?(r=$("inline-flex items-center gap-1.5 px-3 py-1 rounded-lg cursor-pointer","bg-warning/10 border border-warning/20","hover:bg-warning/15","transition-colors duration-150","animate-in fade-in-0 slide-in-from-bottom-2 duration-300"),a=l.jsx(Ie,{size:13,className:"text-warning"}),i=l.jsx("span",{className:"text-xs font-medium text-warning",children:"No credits remaining · Add more"}),e[3]=r,e[4]=a,e[5]=i):(r=e[3],a=e[4],i=e[5]);let c;return e[6]!==s?(c=l.jsxs("button",{type:"button",onClick:s,className:r,children:[a,i]}),e[6]=s,e[7]=c):c=e[7],c}function Ue(e){const t=v.c(7),{scrollRef:n,sentinelRef:s,hasMoreOlder:r,isFetchingOlder:a,fetchOlderMessages:i}=e;let c,u;t[0]!==i||t[1]!==r||t[2]!==a||t[3]!==n||t[4]!==s?(c=()=>{const o=s.current,d=n.current;if(!o||!d||!r)return;const p=new IntersectionObserver(async g=>{if(!g[0]?.isIntersecting||a||!r)return;const f=d.scrollHeight,x=d.scrollTop;await i(),requestAnimationFrame(()=>{const h=d.scrollHeight;d.scrollTop=x+(h-f)})},{root:d,rootMargin:"200px 0px 0px 0px"});return p.observe(o),()=>p.disconnect()},u=[n,s,r,a,i],t[0]=i,t[1]=r,t[2]=a,t[3]=n,t[4]=s,t[5]=c,t[6]=u):(c=t[5],u=t[6]),w.useEffect(c,u)}function We(e){const t=v.c(5),{className:n,children:s}=e;let r;t[0]!==n?(r=$("flex flex-col h-full w-full bg-background transform-[translateZ(0)]",n),t[0]=n,t[1]=r):r=t[1];let a;return t[2]!==s||t[3]!==r?(a=l.jsx("div",{className:r,children:s}),t[2]=s,t[3]=r,t[4]=a):a=t[4],a}function Ye(e){const t=v.c(5),{children:n,className:s}=e;let r;t[0]!==s?(r=$("flex-1 min-h-0 overflow-y-auto isolate",s),t[0]=s,t[1]=r):r=t[1];let a;return t[2]!==n||t[3]!==r?(a=l.jsx("div",{className:r,children:n}),t[2]=n,t[3]=r,t[4]=a):a=t[4],a}function Ve(e){const t=v.c(2),{children:n}=e;let s;return t[0]!==n?(s=l.jsx("div",{className:"min-h-full shrink-0 w-full flex items-center justify-center max-w-2xl mx-auto py-10",children:n}),t[0]=n,t[1]=s):s=t[1],s}function Xe(){const e=M(),{messages:t,status:n,hasMoreOlder:s,isFetchingOlder:r,fetchOlderMessages:a,isRunInProgress:i}=oe(),{taskId:c}=le();Ae();const u=ce(c??""),o=ue(u),d=o.size===0?t:t.filter(j=>!o.has(j.id)),p=de(d,n==="submitted"||n==="streaming"||i),g=p.visible,m=je(g),f=m.at(-1),x=m.findIndex(j=>!!j.assistant&&He(j.assistant)),b=pe()*he+16,N=w.useRef(null),C=w.useRef(null);Ue({scrollRef:N,sentinelRef:C,hasMoreOlder:s,isFetchingOlder:r,fetchOlderMessages:a});const y=ve({initial:!1}),S=j=>{N.current=j,y.scrollRef(j)};return l.jsx(fe.Provider,{value:p,children:l.jsx(be,{messages:t,children:l.jsxs("div",{className:"relative h-full w-full min-w-0",children:[l.jsx("div",{ref:S,"data-chat-scroller":!0,className:"w-full min-w-0 max-w-full overflow-y-auto h-full [container-type:size]",style:{paddingBottom:b},children:l.jsxs("div",{ref:y.contentRef,className:"overflow-x-clip",children:[l.jsxs("div",{className:"flex flex-col min-w-0 max-w-2xl mx-auto w-full",children:[l.jsx("div",{ref:C,"aria-hidden":!0,className:"h-px"}),r&&l.jsx("div",{className:"flex items-center justify-center py-3 text-xs text-muted-foreground",children:e("chat.chat.loadingOlderMessages")}),m.slice(0,-1).map((j,T)=>l.jsxs(w.Fragment,{children:[l.jsx(A,{pair:j,isLastPair:!1,status:T===m.length-1?n:void 0}),T===x&&l.jsx(q,{})]},`pair-${j.user?.id??j.assistant?.id}`))]}),f&&l.jsxs("div",{className:"min-h-[100cqh] min-w-0 max-w-2xl mx-auto w-full",children:[l.jsx(A,{pair:f,isLastPair:!0,status:n},`pair-${f.user?.id??f.assistant?.id}`),x===m.length-1&&l.jsx(q,{})]})]})}),!y.isAtBottom&&l.jsx(B,{type:"button",variant:"outline",size:"icon-sm","aria-label":e("chat.chat.jumpToLatest"),className:"absolute left-1/2 z-50 -translate-x-1/2 shadow-soft animate-in fade-in duration-200 dark:bg-background dark:hover:bg-accent",style:{bottom:b+8},onClick:()=>{y.scrollToBottom()},children:l.jsx(se,{size:14})})]})})})}function Ze(e){const t=v.c(5),{children:n,className:s}=e;let r;t[0]!==s?(r=$("flex-none w-full mx-auto p-2 pt-0","max-w-2xl min-w-0",s),t[0]=s,t[1]=r):r=t[1];let a;return t[2]!==n||t[3]!==r?(a=l.jsx("div",{className:r,children:n}),t[2]=n,t[3]=r,t[4]=a):a=t[4],a}const ht=Object.assign(We,{Main:Ye,Messages:Xe,EmptyState:Ve,Footer:Ze,Input:xe,Provider:ie,StreamHost:re,ActiveTaskStreamSource:ae,ThreadlessStreamSource:ne,NoAiProviderEmptyState:$e,CreditsEmptyState:qe,CreditsEyebrow:Ge,NoCreditsEyebrow:Qe,CreditsExhaustedBanner:ge});export{ht as C,Me as u,pt as w};
@@ -1,4 +1,4 @@
1
- import{c as ue,r as xe,d as ns,a6 as ht,b as Pe,j as t,B as je,t as dt,aY as Yt,am as as,K as bt,i as Et,a7 as As,m as ot,gG as _s,o as cs,h as Ks,e0 as Us,ad as Vs,L as qs,u as Hs,n as _t,E as Wt,R as Bs,dW as Js,hf as Gs,T as Qs,W as Ys,I as Xt}from"./index-BGvfgBXQ.js";import{S as Ws}from"./search-input-BytjnRYd.js";import{E as Ht}from"./empty-state-B5kfNSn2.js";import{R as Xs}from"./require-capability-C51SGps0.js";import{f as js}from"./pair-M_Ks4KYr.js";import{b as ts}from"./use-connection-dER7f5j5.js";import{g as Ps}from"./connection-slug-xMtStNjP.js";import{B as Lt}from"./badge-xkOOGTR2.js";import{P as ds,a as ms,b as us}from"./popover-BdGhwX6j.js";import{c as Pt,T as Dt,a as Rt,b as Zs}from"./tooltip-D0-ybZJ-.js";import{z as fs,e as Ut,bw as el,av as Ns,K as tl}from"./agent-icon-CFsULo4q.js";import{i as sl}from"./Key01-C2Ozqf6q.js";import{i as ll}from"./Play-B5OMs0GO.js";import{MonacoCodeEditor as bs}from"./monaco-editor-DCzjvWW2.js";import{u as rl}from"./use-mcp-client-CsG2AAiF.js";import{u as il}from"./repository-binding-DrxBu24C.js";import{n as Ot}from"./LinkBroken01-sFiApfPs.js";import{c as ol}from"./SwitchHorizontal01-BRSeU65r.js";import{s as nl}from"./Plus-KLH-MPJh.js";import{s as al}from"./Trash01-1e348d5z.js";import{M as zt}from"./multi-select-DLpc9WGW.js";import{b as yt,a as wt,c as ze,d as St,S as Ct}from"./select-BH6i4t87.js";import{e as ys,T as cl}from"./time-range-picker-A0UZNhWR.js";import{T as dl}from"./textarea-C_mtz3Kv.js";import{C as Ds}from"./collection-tabs-BsiuG_yk.js";import{S as ml}from"./switch-B7uarNO5.js";import{L as ul}from"./label-2ri5y0AT.js";import{I as It}from"./integration-icon-nO6TvSsO.js";import{A as fl,a as xl,b as pl}from"./alert-D6c8UL8s.js";import{K as gt}from"./monitoring-stats-row-BK9I1n3g.js";import{b as Bt}from"./use-entitlements-BnUu4797.js";import{g as gl,b as ws,f as Nt,c as Zt,d as hl,e as Ss,a as xs,h as vl,i as ps,T as jl,j as Nl,r as bl,k as yl}from"./thread-sheet-body-CnbjjV-I.js";import{u as wl}from"./useSuspenseInfiniteQuery-XSNjcYue.js";import{c as Sl,S as Cl,b as Rs,a as Ls}from"./sheet-CX86ajAE.js";import{c as _e,b as vt,d as Jt,e as Gt,T as ge,a as Qt}from"./table-Bta2Y1CD.js";import{t as ss}from"./ChevronDown-C0zFtKr8.js";import{n as ls}from"./ChevronUp-CHkdbh-i.js";import{u as Os}from"./use-id-selection-lO2dafiF.js";import{u as Fs}from"./use-infinite-scroll-DuNc__Oo.js";import{u as Il}from"./useInfiniteQuery-Comohppg.js";import{g as Tl}from"./task-status-LX7lBTjN.js";import{u as kl,d as Ml}from"./use-automations-CIfofZgd.js";import{A as _l}from"./automation-runs-DTOCdqSY.js";import{i as Pl}from"./ArrowLeft-D_px05Ip.js";import{E as Cs}from"./empty-state-D4GKvYHp.js";import{O as $s}from"./watch-sse-pool-mz6vVQb7.js";import{t as Dl}from"./task-key-PomUyZRb.js";import{b as Rl,r as Ll,O as Ol,e as Fl}from"./order-monitor-day-B3sADUCG.js";import{F as $l}from"./feature-gate-WGXGW3TJ.js";import"./SearchMd-1p8IP99o.js";import"./access-gate-BwaSQQ2b.js";import"./capability-load-error-74rIpav9.js";import"./Tool01-CIkfFpNs.js";import"./ArrowRight-DYc-7xj5.js";import"./collapsible-C5AFdLwb.js";import"./use-copy-CzwPMJY2.js";import"./usage-stats-4TwUkhM4.js";import"./utils-CVEq3hMx.js";import"./markdown-Du_1i_DV.js";import"./chat-context-Dk_Ebz6D.js";import"./use-panel-navigate-BEVdshk4.js";import"./thread-route-DI1GCHqT.js";import"./use-project-scope-DaSiwM20.js";import"./use-view-draft-kind-Bm-Nz5rU.js";import"./use-blog-view-CZ2egr0r.js";import"./use-organization-settings-CcEgBKiR.js";import"./schema-DIQ-2mII.js";import"./task-board-DshmncwN.js";import"./thread-intent-DJ2isQQx.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./session-runtime-CnePJMYk.js";import"./use-ai-providers-Cykm4Omp.js";import"./use-current-view-BhCzT_on.js";import"./use-in-settings-BZ-N_1GQ.js";import"./use-decopilot-events-DwV1bANi.js";import"./use-mobile-B4kazYmP.js";import"./File02-OGn6eCfs.js";import"./gateway-client-Dcj5rv8f.js";import"./form-Bmlz7qRb.js";import"./UserCheck01-Dq2vpnim.js";import"./use-task-board-items-BOf8g772.js";import"./config-Br1Io2is.js";import"./AlertCircle-BPb6lfDc.js";import"./CheckCircle-Dvda272I.js";import"./Eye-CE9bd3Ra.js";import"./task-route-DIKoinWO.js";import"./project-index-D3eqGaeY.js";import"./TrendUp01-Sag3n7qI.js";import"./shell-layout-MrR8EGxZ.js";import"./Globe04-BK5-p2nj.js";import"./UserSquare-BAlzvt_y.js";import"./use-deployment-admin-U97at0FL.js";import"./admin-fetch-BhTJlAsX.js";import"./XClose-CQjSvos9.js";import"./use-org-notice-FqFlDSJV.js";import"./Monitor01-Ctq4Y9xp.js";import"./Zap-BbT-W69e.js";import"./command-CRJnywSm.js";import"./index-B7BDvGS9.js";import"./project-icon-BUl2sFaB.js";import"./use-navigate-to-agent-CYt8D-re.js";import"./use-debounced-value-DNV71VAt.js";import"./new-project-dialog-BfJtWdgg.js";import"./repository-picker-Darc81nL.js";import"./github-icon-HoxHOYky.js";import"./collection-search-ugxEd4a5.js";import"./BookOpen01-CKzuPfPT.js";import"./ShoppingBag01-BZ5p5Jaw.js";import"./new-project-store-CUIYzGdu.js";import"./legacy-admin-welcome-dialog-dJnURvJJ.js";import"./drawer-CQosC7Hh.js";import"./required-auth-layout-pSTI6t_x.js";import"./use-org-sso-CCCXGXRa.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-CHuh8eBE.js";import"./types-DeHdmC2C.js";import"./omit-server-managed-metadata-L5IhjRZB.js";import"./Image01-Do_f-fPi.js";import"./use-mcp-prompts-DJkMWAp0.js";import"./use-thread-outputs-CBGDKGBc.js";import"./file-type-icon-Cst2WgHg.js";import"./index-CpqnzQ6X.js";import"./ArrowUp-bsUZSt57.js";import"./ChevronSelectorVertical-BtbkxpS7.js";import"./CreditCard01-BnEtKIxX.js";import"./MessageCircle01-LN8Gr1lL.js";import"./Fingerprint04-ZnmHU3Kp.js";import"./LayoutLeft-tXOkIxzs.js";import"./Minus-vz8sJtmc.js";import"./Sun-8QBdDNyc.js";import"./Upload01-DQiq1N5L.js";import"./Users01-CJNRoJXK.js";import"./editor-DnZdk2c2.js";import"./auth-WUI0GELm.js";import"./checkbox-DR00CmJr.js";import"./index-BdQq_4o_.js";import"./scroll-area-CLaLCTf7.js";import"./calendar-CCy2brqO.js";import"./chart-DVwx0iDS.js";import"./CategoricalChart-D0wEIkFu.js";import"./index-CrMNCOay.js";import"./tooltipContext-Dm5XB4Pa.js";import"./CartesianChart-8sA8UDc5.js";import"./AreaChart-Yh5pBNgF.js";import"./infiniteQueryObserver-CjHha6VI.js";import"./useQueries-BADhFyMC.js";import"./ReferenceLine-Hl32My8w.js";import"./feature-paywall-CXj-cCjT.js";import"./plan-ladder-De9sRz_u.js";const rs={maxJsonRenderSize:5e4,pageSize:50,streamingRefetchInterval:3e3},zl=["eq","contains","exists","in"];function El(s){return zl.includes(s)}function jt(s){return s.filter(e=>e.key.trim()).map(e=>{const l=encodeURIComponent(e.key.trim()),i=encodeURIComponent(e.value||"");return`${l}:${e.operator}:${i}`}).join(",")}function Al(s){return!s||typeof s!="string"?[]:s.split(",").map(e=>{if(!e)return;const[l,i,...m]=e.split(":"),n=l?decodeURIComponent(l):"";if(n.trim())return{key:n,operator:i&&El(i)?i:"eq",value:decodeURIComponent(m.join(":")||"")}}).filter(e=>e!==void 0)}function Vt(s){return s.filter(e=>e.key.trim()).map(e=>{switch(e.operator){case"eq":return`${e.key}=${e.value}`;case"contains":return`${e.key}~${e.value}`;case"exists":return`${e.key}?`;case"in":return`${e.key}@${e.value}`}}).join(`
1
+ import{c as ue,r as xe,d as ns,a6 as ht,b as Pe,j as t,B as je,t as dt,aY as Yt,am as as,K as bt,i as Et,a7 as As,m as ot,gG as _s,o as cs,h as Ks,e0 as Us,ad as Vs,L as qs,u as Hs,n as _t,E as Wt,R as Bs,dW as Js,hf as Gs,T as Qs,W as Ys,I as Xt}from"./index-BVZH8mqe.js";import{S as Ws}from"./search-input-D3b0Dc5Y.js";import{E as Ht}from"./empty-state-hp9a4BQn.js";import{R as Xs}from"./require-capability-B6_v4BKo.js";import{f as js}from"./pair-C4tumP78.js";import{b as ts}from"./use-connection-C-m8b2Fk.js";import{g as Ps}from"./connection-slug-DgGnB6qk.js";import{B as Lt}from"./badge-wWozseh3.js";import{P as ds,a as ms,b as us}from"./popover-9q-VKuQx.js";import{c as Pt,T as Dt,a as Rt,b as Zs}from"./tooltip-CfeBMv8z.js";import{z as fs,e as Ut,bw as el,av as Ns,K as tl}from"./agent-icon-BS6RPQ_A.js";import{i as sl}from"./Key01-9JQCF719.js";import{i as ll}from"./Play-BRDYCYl7.js";import{MonacoCodeEditor as bs}from"./monaco-editor-C3D0iT4a.js";import{u as rl}from"./use-mcp-client-7NPwItGN.js";import{u as il}from"./repository-binding-BIfwJXBl.js";import{n as Ot}from"./LinkBroken01-CpDM6pG5.js";import{c as ol}from"./SwitchHorizontal01-sPBj-OL8.js";import{s as nl}from"./Plus-BJfG2DpW.js";import{s as al}from"./Trash01-l4iOtEBN.js";import{M as zt}from"./multi-select-Dak9eW6K.js";import{b as yt,a as wt,c as ze,d as St,S as Ct}from"./select-BJ7g3jt1.js";import{e as ys,T as cl}from"./time-range-picker-BzLGuV9Q.js";import{T as dl}from"./textarea-BnYcD_gb.js";import{C as Ds}from"./collection-tabs-B1EmRyNS.js";import{S as ml}from"./switch-BX8b8tB6.js";import{L as ul}from"./label-Dc_tSb6f.js";import{I as It}from"./integration-icon-CcV5frEs.js";import{A as fl,a as xl,b as pl}from"./alert-hKxZXEZZ.js";import{K as gt}from"./monitoring-stats-row-By2SXcyl.js";import{b as Bt}from"./use-entitlements-B8D7pawV.js";import{g as gl,b as ws,f as Nt,c as Zt,d as hl,e as Ss,a as xs,h as vl,i as ps,T as jl,j as Nl,r as bl,k as yl}from"./thread-sheet-body-B4d3KSH7.js";import{u as wl}from"./useSuspenseInfiniteQuery-BFQG7J82.js";import{c as Sl,S as Cl,b as Rs,a as Ls}from"./sheet-B1zTFenO.js";import{c as _e,b as vt,d as Jt,e as Gt,T as ge,a as Qt}from"./table-DNvSx4nT.js";import{t as ss}from"./ChevronDown-CWnE_Wmz.js";import{n as ls}from"./ChevronUp-C_rAiuf1.js";import{u as Os}from"./use-id-selection-BOT74h8X.js";import{u as Fs}from"./use-infinite-scroll-Ct_PbHT3.js";import{u as Il}from"./useInfiniteQuery-BJoJv4VQ.js";import{g as Tl}from"./task-status-CvKutQFi.js";import{u as kl,d as Ml}from"./use-automations-CtbjaE6m.js";import{A as _l}from"./automation-runs-DvuKFaor.js";import{i as Pl}from"./ArrowLeft-DcKid1bz.js";import{E as Cs}from"./empty-state-C4vGG4yC.js";import{O as $s}from"./watch-sse-pool-CWcYbOm5.js";import{t as Dl}from"./task-key-BjUMQvHV.js";import{b as Rl,r as Ll,O as Ol,e as Fl}from"./order-monitor-day-D910WxJ3.js";import{F as $l}from"./feature-gate-DtqeHOu4.js";import"./SearchMd-DioGBYbO.js";import"./access-gate-Cb6wrWbo.js";import"./capability-load-error-Cwe4uK-x.js";import"./Tool01-BEo5XKkS.js";import"./ArrowRight-ajc9j6D-.js";import"./collapsible-D4n-ssmc.js";import"./use-copy-BHPkBnZF.js";import"./usage-stats-Dzci2XGy.js";import"./utils-CVEq3hMx.js";import"./markdown-DvUyMKlV.js";import"./chat-context-B6UvvRRf.js";import"./use-panel-navigate-DPGDB1T1.js";import"./thread-route-muzc431X.js";import"./use-project-scope-BIucgFKc.js";import"./use-view-draft-kind-BG3Ihm6n.js";import"./use-blog-view-D_--u8j_.js";import"./use-organization-settings-BoOQOwrg.js";import"./schema-C2ft4i4u.js";import"./task-board-DLNmAHmR.js";import"./thread-intent-CYNXEfHP.js";import"./delay-CnY5UFtP.js";import"./backoff-CrEUbyZT.js";import"./session-runtime-CRv5j4jh.js";import"./use-ai-providers-C30oeluP.js";import"./use-current-view-CHhVzMwk.js";import"./use-in-settings-qQ2sbeu5.js";import"./use-decopilot-events-BxfGa0_j.js";import"./use-mobile-5e0sSd3X.js";import"./File02-R0RW2VCN.js";import"./gateway-client-8UpI_Rdq.js";import"./form-BZ2nSi_9.js";import"./UserCheck01-B1rJ65So.js";import"./use-task-board-items-D4fdH47R.js";import"./config-zmlExYow.js";import"./AlertCircle-kHXzu73r.js";import"./CheckCircle-DG9pUM8a.js";import"./Eye-DFeDq2Hx.js";import"./task-route-B6gZ9LxC.js";import"./project-index-BOyydKXT.js";import"./TrendUp01-aviiZW6M.js";import"./shell-layout-BT6RZJ9X.js";import"./Globe04-DudUQgTy.js";import"./UserSquare-D44lppb_.js";import"./use-deployment-admin-COmgwPUq.js";import"./admin-fetch-BhTJlAsX.js";import"./XClose-BwokcWjs.js";import"./use-org-notice-Dvph2j3S.js";import"./Monitor01-BPQw3JGv.js";import"./Zap-DoXbwvKP.js";import"./command-DQwD4jPt.js";import"./index-B-PIhH8l.js";import"./project-icon-C8Sq9Uyo.js";import"./use-navigate-to-agent-CtsEyeFb.js";import"./use-debounced-value-By7KggQt.js";import"./new-project-dialog-BeD2i_Hm.js";import"./repository-picker-vN0XhyKR.js";import"./github-icon-C-V2EETw.js";import"./collection-search-CDDauqCr.js";import"./BookOpen01-CdH9hkvz.js";import"./ShoppingBag01-CdQhBv_H.js";import"./new-project-store-BfrY24D-.js";import"./legacy-admin-welcome-dialog-DtYrilLw.js";import"./drawer-BMY0wk6r.js";import"./required-auth-layout-BXbkUsYd.js";import"./use-org-sso-BKXSOEb_.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-CRu4PbUr.js";import"./types-D_vNw-3-.js";import"./omit-server-managed-metadata-L5IhjRZB.js";import"./Image01-Dfaw0Ysf.js";import"./use-mcp-prompts-C7QHdaI_.js";import"./use-thread-outputs-CrNLjxTt.js";import"./file-type-icon-DOJ02s9h.js";import"./index-BFjuxezw.js";import"./ArrowUp-CjAvmMLL.js";import"./ChevronSelectorVertical-ByCpNum0.js";import"./CreditCard01-C6eDo3p0.js";import"./MessageCircle01-44De_8cO.js";import"./Fingerprint04-D-EFj_6a.js";import"./LayoutLeft-B-cVGLzN.js";import"./Minus-09UkIbMe.js";import"./Sun-U7FHkItb.js";import"./Upload01-BhvyPM8u.js";import"./Users01-CxQycal6.js";import"./editor-C6mSxTrt.js";import"./auth-C3yWOKhG.js";import"./checkbox-Cs2Li62P.js";import"./index-BdQq_4o_.js";import"./scroll-area-w9_Bvwmf.js";import"./calendar-Sr3cNZGh.js";import"./chart-D0It11Pz.js";import"./CategoricalChart-DW_7VziR.js";import"./index-BYQu9U5P.js";import"./tooltipContext-BMU8k-Rs.js";import"./CartesianChart-BRKqG5iH.js";import"./AreaChart-CJxx8aiG.js";import"./infiniteQueryObserver-f5kG4cIT.js";import"./useQueries-DGhxO9Ry.js";import"./ReferenceLine-KUFosDOj.js";import"./feature-paywall-BGOy9Z00.js";import"./plan-ladder-BlcJL4hV.js";const rs={maxJsonRenderSize:5e4,pageSize:50,streamingRefetchInterval:3e3},zl=["eq","contains","exists","in"];function El(s){return zl.includes(s)}function jt(s){return s.filter(e=>e.key.trim()).map(e=>{const l=encodeURIComponent(e.key.trim()),i=encodeURIComponent(e.value||"");return`${l}:${e.operator}:${i}`}).join(",")}function Al(s){return!s||typeof s!="string"?[]:s.split(",").map(e=>{if(!e)return;const[l,i,...m]=e.split(":"),n=l?decodeURIComponent(l):"";if(n.trim())return{key:n,operator:i&&El(i)?i:"eq",value:decodeURIComponent(m.join(":")||"")}}).filter(e=>e!==void 0)}function Vt(s){return s.filter(e=>e.key.trim()).map(e=>{switch(e.operator){case"eq":return`${e.key}=${e.value}`;case"contains":return`${e.key}~${e.value}`;case"exists":return`${e.key}?`;case"in":return`${e.key}@${e.value}`}}).join(`
2
2
  `)}function Is(s){return s.trim()?s.split(`
3
3
  `).map(e=>e.trim()).filter(e=>e.length>0).map(e=>{if(e.endsWith("?"))return{key:e.slice(0,-1),operator:"exists",value:""};if(e.includes("=")){const[l,...i]=e.split("=");return{key:l||"",operator:"eq",value:i.join("=")}}if(e.includes("~")){const[l,...i]=e.split("~");return{key:l||"",operator:"contains",value:i.join("~")}}if(e.includes("@")){const[l,...i]=e.split("@");return{key:l||"",operator:"in",value:i.join("@")}}return{key:e,operator:"exists",value:""}}):[]}function Kl(s){const e={},l={},i=[],m={};for(const n of s)if(n.key.trim())switch(n.operator){case"eq":n.value&&(e[n.key]=n.value);break;case"contains":n.value&&(l[n.key]=`%${n.value}%`);break;case"exists":i.push(n.key);break;case"in":n.value&&(m[n.key]=n.value);break}return{properties:Object.keys(e).length>0?e:void 0,propertyPatterns:Object.keys(l).length>0?l:void 0,propertyKeys:i.length>0?i:void 0,propertyInValues:Object.keys(m).length>0?m:void 0}}function Ts(s){if(!s)return{content:"null",isTruncated:!1,originalSize:4};const e=s._decocms_truncated;if(typeof e=="string"&&e.length>0)return{content:e,isTruncated:!0,originalSize:e.length};let l;try{l=JSON.stringify(s,null,2)}catch{return{content:"[Unable to serialize JSON]",isTruncated:!1,originalSize:0}}const i=l.length;return i<=rs.maxJsonRenderSize?{content:l,isTruncated:!1,originalSize:i}:{content:l.slice(0,rs.maxJsonRenderSize)+`
4
4
 
@@ -1,4 +1,4 @@
1
- import{r as $,ca as nt,c as U,b as ie,j as i,gh as ke,o as lt,gi as rt,a6 as be,am as we,q as _e,aF as We,aG as Ue,e as je,I as fe,aH as Be,aI as xe,K as pe,t as le,B as oe,y as Ve,E as ne,D as ot,v as at,w as ct,x as dt,h as Oe,m as ge,e0 as J,d as ht,R as ut,a7 as mt}from"./index-BGvfgBXQ.js";import{C as ft}from"./checkbox-DR00CmJr.js";import{S as pt,b as xt,a as gt,d as vt,c as bt}from"./select-BH6i4t87.js";import{i as He}from"./ArrowLeft-D_px05Ip.js";import{i as yt}from"./ChevronSelectorVertical-BtbkxpS7.js";import{i as jt}from"./Key01-C2Ozqf6q.js";import{i as qe,t as St,f as Nt,e as kt,d as wt,a as _t,s as It}from"./Tool01-CIkfFpNs.js";import{i as Ye}from"./SearchMd-1p8IP99o.js";import{e as Ie,u as Ct,a as Mt,c as Et}from"./use-ai-providers-Cykm4Omp.js";import{d as Ot}from"./chat-context-Dk_Ebz6D.js";import{g as Ce}from"./ai-providers-logos-DD3qZ33J.js";import{g as ve}from"./openai-compatible-presets-BKGfVqEx.js";import{i as zt}from"./Monitor01-Ctq4Y9xp.js";import{i as Pt}from"./AlertCircle-BPb6lfDc.js";import{u as At}from"./use-entitlements-BnUu4797.js";import{s as Ge}from"./Eye-CE9bd3Ra.js";import{t as ze}from"./ChevronDown-C0zFtKr8.js";import{a as Ft}from"./Image01-Do_f-fPi.js";function me(n,e,t){let s=t.initialDeps??[],l,r=!0;function a(){var c,h,d;let o;t.key&&((c=t.debug)!=null&&c.call(t))&&(o=Date.now());const m=n();if(!(m.length!==s.length||m.some((f,g)=>s[g]!==f)))return l;s=m;let u;if(t.key&&((h=t.debug)!=null&&h.call(t))&&(u=Date.now()),l=e(...m),t.key&&((d=t.debug)!=null&&d.call(t))){const f=Math.round((Date.now()-o)*100)/100,g=Math.round((Date.now()-u)*100)/100,I=g/16,S=(y,w)=>{for(y=String(y);y.length<w;)y=" "+y;return y};console.info(`%c⏱ ${S(g,5)} /${S(f,5)} ms`,`
1
+ import{r as $,ca as nt,c as U,b as ie,j as i,gh as ke,o as lt,gi as rt,a6 as be,am as we,q as _e,aF as We,aG as Ue,e as je,I as fe,aH as Be,aI as xe,K as pe,t as le,B as oe,y as Ve,E as ne,D as ot,v as at,w as ct,x as dt,h as Oe,m as ge,e0 as J,d as ht,R as ut,a7 as mt}from"./index-BVZH8mqe.js";import{C as ft}from"./checkbox-Cs2Li62P.js";import{S as pt,b as xt,a as gt,d as vt,c as bt}from"./select-BJ7g3jt1.js";import{i as He}from"./ArrowLeft-DcKid1bz.js";import{i as yt}from"./ChevronSelectorVertical-ByCpNum0.js";import{i as jt}from"./Key01-9JQCF719.js";import{i as qe,t as St,f as Nt,e as kt,d as wt,a as _t,s as It}from"./Tool01-BEo5XKkS.js";import{i as Ye}from"./SearchMd-DioGBYbO.js";import{e as Ie,u as Ct,a as Mt,c as Et}from"./use-ai-providers-C30oeluP.js";import{d as Ot}from"./chat-context-B6UvvRRf.js";import{g as Ce}from"./ai-providers-logos-DD3qZ33J.js";import{g as ve}from"./openai-compatible-presets-BKGfVqEx.js";import{i as zt}from"./Monitor01-BPQw3JGv.js";import{i as Pt}from"./AlertCircle-kHXzu73r.js";import{u as At}from"./use-entitlements-B8D7pawV.js";import{s as Ge}from"./Eye-DFeDq2Hx.js";import{t as ze}from"./ChevronDown-CWnE_Wmz.js";import{a as Ft}from"./Image01-Dfaw0Ysf.js";function me(n,e,t){let s=t.initialDeps??[],l,r=!0;function a(){var c,h,d;let o;t.key&&((c=t.debug)!=null&&c.call(t))&&(o=Date.now());const m=n();if(!(m.length!==s.length||m.some((f,g)=>s[g]!==f)))return l;s=m;let u;if(t.key&&((h=t.debug)!=null&&h.call(t))&&(u=Date.now()),l=e(...m),t.key&&((d=t.debug)!=null&&d.call(t))){const f=Math.round((Date.now()-o)*100)/100,g=Math.round((Date.now()-u)*100)/100,I=g/16,S=(y,w)=>{for(y=String(y);y.length<w;)y=" "+y;return y};console.info(`%c⏱ ${S(g,5)} /${S(f,5)} ms`,`
2
2
  font-size: .6rem;
3
3
  font-weight: bold;
4
4
  color: hsl(${Math.max(0,Math.min(120-120*I,120))}deg 100% 31%);`,t?.key)}return t?.onChange&&!(r&&t.skipInitialOnChange)&&t.onChange(l),r=!1,l}return a.updateDeps=c=>{s=c},a}function Pe(n,e){if(n===void 0)throw new Error("Unexpected undefined");return n}const Tt=(n,e)=>Math.abs(n-e)<1.01,Rt=(n,e,t)=>{let s;return function(...l){n.clearTimeout(s),s=n.setTimeout(()=>e.apply(this,l),t)}},Ae=n=>{const{offsetWidth:e,offsetHeight:t}=n;return{width:e,height:t}},Kt=n=>n,Lt=n=>{const e=Math.max(n.startIndex-n.overscan,0),t=Math.min(n.endIndex+n.overscan,n.count-1),s=[];for(let l=e;l<=t;l++)s.push(l);return s},Dt=(n,e)=>{const t=n.scrollElement;if(!t)return;const s=n.targetWindow;if(!s)return;const l=a=>{const{width:c,height:h}=a;e({width:Math.round(c),height:Math.round(h)})};if(l(Ae(t)),!s.ResizeObserver)return()=>{};const r=new s.ResizeObserver(a=>{const c=()=>{const h=a[0];if(h?.borderBoxSize){const d=h.borderBoxSize[0];if(d){l({width:d.inlineSize,height:d.blockSize});return}}l(Ae(t))};n.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(c):c()});return r.observe(t,{box:"border-box"}),()=>{r.unobserve(t)}},Fe={passive:!0},Te=typeof window>"u"?!0:"onscrollend"in window,$t=(n,e)=>{const t=n.scrollElement;if(!t)return;const s=n.targetWindow;if(!s)return;let l=0;const r=n.options.useScrollendEvent&&Te?()=>{}:Rt(s,()=>{e(l,!1)},n.options.isScrollingResetDelay),a=o=>()=>{const{horizontal:m,isRtl:p}=n.options;l=m?t.scrollLeft*(p&&-1||1):t.scrollTop,r(),e(l,o)},c=a(!0),h=a(!1);t.addEventListener("scroll",c,Fe);const d=n.options.useScrollendEvent&&Te;return d&&t.addEventListener("scrollend",h,Fe),()=>{t.removeEventListener("scroll",c),d&&t.removeEventListener("scrollend",h)}},Wt=(n,e,t)=>{if(e?.borderBoxSize){const s=e.borderBoxSize[0];if(s)return Math.round(s[t.options.horizontal?"inlineSize":"blockSize"])}return n[t.options.horizontal?"offsetWidth":"offsetHeight"]},Ut=(n,{adjustments:e=0,behavior:t},s)=>{var l,r;const a=n+e;(r=(l=s.scrollElement)==null?void 0:l.scrollTo)==null||r.call(l,{[s.options.horizontal?"left":"top"]:a,behavior:t})};class Bt{constructor(e){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.scrollState=null,this.measurementsCache=[],this.itemSizeCache=new Map,this.laneAssignments=new Map,this.pendingMeasuredCacheIndexes=[],this.prevLanes=void 0,this.lanesChangedFlag=!1,this.lanesSettling=!1,this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.now=()=>{var t,s,l;return((l=(s=(t=this.targetWindow)==null?void 0:t.performance)==null?void 0:s.now)==null?void 0:l.call(s))??Date.now()},this.observer=(()=>{let t=null;const s=()=>t||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:t=new this.targetWindow.ResizeObserver(l=>{l.forEach(r=>{const a=()=>{const c=r.target,h=this.indexFromElement(c);if(!c.isConnected){this.observer.unobserve(c);return}this.shouldMeasureDuringScroll(h)&&this.resizeItem(h,this.options.measureElement(c,r,this))};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(a):a()})}));return{disconnect:()=>{var l;(l=s())==null||l.disconnect(),t=null},observe:l=>{var r;return(r=s())==null?void 0:r.observe(l,{box:"border-box"})},unobserve:l=>{var r;return(r=s())==null?void 0:r.unobserve(l)}}})(),this.range=null,this.setOptions=t=>{Object.entries(t).forEach(([s,l])=>{typeof l>"u"&&delete t[s]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:Kt,rangeExtractor:Lt,onChange:()=>{},measureElement:Wt,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,laneAssignmentMode:"estimate",...t}},this.notify=t=>{var s,l;(l=(s=this.options).onChange)==null||l.call(s,this,t)},this.maybeNotify=me(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),t=>{this.notify(t)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(t=>t()),this.unsubs=[],this.observer.disconnect(),this.rafId!=null&&this.targetWindow&&(this.targetWindow.cancelAnimationFrame(this.rafId),this.rafId=null),this.scrollState=null,this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var t;const s=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==s){if(this.cleanup(),!s){this.maybeNotify();return}this.scrollElement=s,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((t=this.scrollElement)==null?void 0:t.window)??null,this.elementsCache.forEach(l=>{this.observer.observe(l)}),this.unsubs.push(this.options.observeElementRect(this,l=>{this.scrollRect=l,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(l,r)=>{this.scrollAdjustments=0,this.scrollDirection=r?this.getScrollOffset()<l?"forward":"backward":null,this.scrollOffset=l,this.isScrolling=r,this.scrollState&&this.scheduleScrollReconcile(),this.maybeNotify()})),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0})}},this.rafId=null,this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(t,s)=>{const l=new Map,r=new Map;for(let a=s-1;a>=0;a--){const c=t[a];if(l.has(c.lane))continue;const h=r.get(c.lane);if(h==null||c.end>h.end?r.set(c.lane,c):c.end<h.end&&l.set(c.lane,!0),l.size===this.options.lanes)break}return r.size===this.options.lanes?Array.from(r.values()).sort((a,c)=>a.end===c.end?a.index-c.index:a.end-c.end)[0]:void 0},this.getMeasurementOptions=me(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled,this.options.lanes,this.options.laneAssignmentMode],(t,s,l,r,a,c,h)=>(this.prevLanes!==void 0&&this.prevLanes!==c&&(this.lanesChangedFlag=!0),this.prevLanes=c,this.pendingMeasuredCacheIndexes=[],{count:t,paddingStart:s,scrollMargin:l,getItemKey:r,enabled:a,lanes:c,laneAssignmentMode:h}),{key:!1}),this.getMeasurements=me(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:t,paddingStart:s,scrollMargin:l,getItemKey:r,enabled:a,lanes:c,laneAssignmentMode:h},d)=>{if(!a)return this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),[];if(this.laneAssignments.size>t)for(const u of this.laneAssignments.keys())u>=t&&this.laneAssignments.delete(u);this.lanesChangedFlag&&(this.lanesChangedFlag=!1,this.lanesSettling=!0,this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),this.pendingMeasuredCacheIndexes=[]),this.measurementsCache.length===0&&!this.lanesSettling&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(u=>{this.itemSizeCache.set(u.key,u.size)}));const o=this.lanesSettling?0:this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[],this.lanesSettling&&this.measurementsCache.length===t&&(this.lanesSettling=!1);const m=this.measurementsCache.slice(0,o),p=new Array(c).fill(void 0);for(let u=0;u<o;u++){const f=m[u];f&&(p[f.lane]=u)}for(let u=o;u<t;u++){const f=r(u),g=this.laneAssignments.get(u);let I,S;const y=h==="estimate"||d.has(f);if(g!==void 0&&this.options.lanes>1){I=g;const N=p[I],x=N!==void 0?m[N]:void 0;S=x?x.end+this.options.gap:s+l}else{const N=this.options.lanes===1?m[u-1]:this.getFurthestMeasurement(m,u);S=N?N.end+this.options.gap:s+l,I=N?N.lane:u%this.options.lanes,this.options.lanes>1&&y&&this.laneAssignments.set(u,I)}const w=d.get(f),_=typeof w=="number"?w:this.options.estimateSize(u),C=S+_;m[u]={index:u,start:S,size:_,end:C,key:f,lane:I},p[I]=u}return this.measurementsCache=m,m},{key:!1,debug:()=>this.options.debug}),this.calculateRange=me(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(t,s,l,r)=>this.range=t.length>0&&s>0?Vt({measurements:t,outerSize:s,scrollOffset:l,lanes:r}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=me(()=>{let t=null,s=null;const l=this.calculateRange();return l&&(t=l.startIndex,s=l.endIndex),this.maybeNotify.updateDeps([this.isScrolling,t,s]),[this.options.rangeExtractor,this.options.overscan,this.options.count,t,s]},(t,s,l,r,a)=>r===null||a===null?[]:t({startIndex:r,endIndex:a,overscan:s,count:l}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=t=>{const s=this.options.indexAttribute,l=t.getAttribute(s);return l?parseInt(l,10):(console.warn(`Missing attribute name '${s}={index}' on measured element.`),-1)},this.shouldMeasureDuringScroll=t=>{var s;if(!this.scrollState||this.scrollState.behavior!=="smooth")return!0;const l=this.scrollState.index??((s=this.getVirtualItemForOffset(this.scrollState.lastTargetOffset))==null?void 0:s.index);if(l!==void 0&&this.range){const r=Math.max(this.options.overscan,Math.ceil((this.range.endIndex-this.range.startIndex)/2)),a=Math.max(0,l-r),c=Math.min(this.options.count-1,l+r);return t>=a&&t<=c}return!0},this.measureElement=t=>{if(!t){this.elementsCache.forEach((a,c)=>{a.isConnected||(this.observer.unobserve(a),this.elementsCache.delete(c))});return}const s=this.indexFromElement(t),l=this.options.getItemKey(s),r=this.elementsCache.get(l);r!==t&&(r&&this.observer.unobserve(r),this.observer.observe(t),this.elementsCache.set(l,t)),(!this.isScrolling||this.scrollState)&&this.shouldMeasureDuringScroll(s)&&this.resizeItem(s,this.options.measureElement(t,void 0,this))},this.resizeItem=(t,s)=>{var l;const r=this.measurementsCache[t];if(!r)return;const a=this.itemSizeCache.get(r.key)??r.size,c=s-a;c!==0&&(((l=this.scrollState)==null?void 0:l.behavior)!=="smooth"&&(this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(r,c,this):r.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=c,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(r.index),this.itemSizeCache=new Map(this.itemSizeCache.set(r.key,s)),this.notify(!1))},this.getVirtualItems=me(()=>[this.getVirtualIndexes(),this.getMeasurements()],(t,s)=>{const l=[];for(let r=0,a=t.length;r<a;r++){const c=t[r],h=s[c];l.push(h)}return l},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=t=>{const s=this.getMeasurements();if(s.length!==0)return Pe(s[Qe(0,s.length-1,l=>Pe(s[l]).start,t)])},this.getMaxScrollOffset=()=>{if(!this.scrollElement)return 0;if("scrollHeight"in this.scrollElement)return this.options.horizontal?this.scrollElement.scrollWidth-this.scrollElement.clientWidth:this.scrollElement.scrollHeight-this.scrollElement.clientHeight;{const t=this.scrollElement.document.documentElement;return this.options.horizontal?t.scrollWidth-this.scrollElement.innerWidth:t.scrollHeight-this.scrollElement.innerHeight}},this.getOffsetForAlignment=(t,s,l=0)=>{if(!this.scrollElement)return 0;const r=this.getSize(),a=this.getScrollOffset();s==="auto"&&(s=t>=a+r?"end":"start"),s==="center"?t+=(l-r)/2:s==="end"&&(t-=r);const c=this.getMaxScrollOffset();return Math.max(Math.min(c,t),0)},this.getOffsetForIndex=(t,s="auto")=>{t=Math.max(0,Math.min(t,this.options.count-1));const l=this.getSize(),r=this.getScrollOffset(),a=this.measurementsCache[t];if(!a)return;if(s==="auto")if(a.end>=r+l-this.options.scrollPaddingEnd)s="end";else if(a.start<=r+this.options.scrollPaddingStart)s="start";else return[r,s];if(s==="end"&&t===this.options.count-1)return[this.getMaxScrollOffset(),s];const c=s==="end"?a.end+this.options.scrollPaddingEnd:a.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(c,s,a.size),s]},this.scrollToOffset=(t,{align:s="start",behavior:l="auto"}={})=>{const r=this.getOffsetForAlignment(t,s),a=this.now();this.scrollState={index:null,align:s,behavior:l,startedAt:a,lastTargetOffset:r,stableFrames:0},this._scrollToOffset(r,{adjustments:void 0,behavior:l}),this.scheduleScrollReconcile()},this.scrollToIndex=(t,{align:s="auto",behavior:l="auto"}={})=>{t=Math.max(0,Math.min(t,this.options.count-1));const r=this.getOffsetForIndex(t,s);if(!r)return;const[a,c]=r,h=this.now();this.scrollState={index:t,align:c,behavior:l,startedAt:h,lastTargetOffset:a,stableFrames:0},this._scrollToOffset(a,{adjustments:void 0,behavior:l}),this.scheduleScrollReconcile()},this.scrollBy=(t,{behavior:s="auto"}={})=>{const l=this.getScrollOffset()+t,r=this.now();this.scrollState={index:null,align:"start",behavior:s,startedAt:r,lastTargetOffset:l,stableFrames:0},this._scrollToOffset(l,{adjustments:void 0,behavior:s}),this.scheduleScrollReconcile()},this.getTotalSize=()=>{var t;const s=this.getMeasurements();let l;if(s.length===0)l=this.options.paddingStart;else if(this.options.lanes===1)l=((t=s[s.length-1])==null?void 0:t.end)??0;else{const r=Array(this.options.lanes).fill(null);let a=s.length-1;for(;a>=0&&r.some(c=>c===null);){const c=s[a];r[c.lane]===null&&(r[c.lane]=c.end),a--}l=Math.max(...r.filter(c=>c!==null))}return Math.max(l-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(t,{adjustments:s,behavior:l})=>{this.options.scrollToFn(t,{behavior:l,adjustments:s},this)},this.measure=()=>{this.itemSizeCache=new Map,this.laneAssignments=new Map,this.notify(!1)},this.setOptions(e)}scheduleScrollReconcile(){if(!this.targetWindow){this.scrollState=null;return}this.rafId==null&&(this.rafId=this.targetWindow.requestAnimationFrame(()=>{this.rafId=null,this.reconcileScroll()}))}reconcileScroll(){if(!this.scrollState||!this.scrollElement)return;if(this.now()-this.scrollState.startedAt>5e3){this.scrollState=null;return}const s=this.scrollState.index!=null?this.getOffsetForIndex(this.scrollState.index,this.scrollState.align):void 0,l=s?s[0]:this.scrollState.lastTargetOffset,r=1,a=l!==this.scrollState.lastTargetOffset;if(!a&&Tt(l,this.getScrollOffset())){if(this.scrollState.stableFrames++,this.scrollState.stableFrames>=r){this.scrollState=null;return}}else this.scrollState.stableFrames=0,a&&(this.scrollState.lastTargetOffset=l,this.scrollState.behavior="auto",this._scrollToOffset(l,{adjustments:void 0,behavior:"auto"}));this.scheduleScrollReconcile()}}const Qe=(n,e,t,s)=>{for(;n<=e;){const l=(n+e)/2|0,r=t(l);if(r<s)n=l+1;else if(r>s)e=l-1;else return l}return n>0?n-1:0};function Vt({measurements:n,outerSize:e,scrollOffset:t,lanes:s}){const l=n.length-1,r=h=>n[h].start;if(n.length<=s)return{startIndex:0,endIndex:l};let a=Qe(0,l,r,t),c=a;if(s===1)for(;c<l&&n[c].end<t+e;)c++;else if(s>1){const h=Array(s).fill(0);for(;c<l&&h.some(o=>o<t+e);){const o=n[c];h[o.lane]=o.end,c++}const d=Array(s).fill(t+e);for(;a>=0&&d.some(o=>o>=t);){const o=n[a];d[o.lane]=o.start,a--}a=Math.max(0,a-a%s),c=Math.min(l,c+(s-1-c%s))}return{startIndex:a,endIndex:c}}const Re=typeof document<"u"?$.useLayoutEffect:$.useEffect;function Ht({useFlushSync:n=!0,...e}){const t=$.useReducer(()=>({}),{})[1],s={...e,onChange:(r,a)=>{var c;n&&a?nt.flushSync(t):t(),(c=e.onChange)==null||c.call(e,r,a)}},[l]=$.useState(()=>new Bt(s));return l.setOptions(s),Re(()=>l._didMount(),[]),Re(()=>l._willUpdate()),l}function qt(n){return Ht({observeElementRect:Dt,observeElementOffset:$t,scrollToFn:Ut,...n})}const Yt=["anthropic","openrouter"],Gt=["google"];function Ne(n){const e=U.c(8),{logo:t,name:s,description:l,onClick:r}=n;let a;e[0]!==t||e[1]!==s?(a=t?i.jsx("img",{src:t,alt:s,className:"size-5 object-contain"}):i.jsx(lt,{fallback:s.charAt(0),className:"size-8 bg-primary/10 text-primary"}),e[0]=t,e[1]=s,e[2]=a):a=e[2];let c;return e[3]!==l||e[4]!==s||e[5]!==r||e[6]!==a?(c=i.jsx(rt,{onClick:r,icon:a,title:s,description:l}),e[3]=l,e[4]=s,e[5]=r,e[6]=a,e[7]=c):c=e[7],c}function Ke(n){const e=U.c(7),{label:t,children:s}=n;let l;e[0]!==t?(l=i.jsx("span",{className:"px-1 text-meta",children:t}),e[0]=t,e[1]=l):l=e[1];let r;e[2]!==s?(r=i.jsx(ke,{children:s}),e[2]=s,e[3]=r):r=e[3];let a;return e[4]!==l||e[5]!==r?(a=i.jsxs("div",{className:"flex flex-col gap-2",children:[l,r]}),e[4]=l,e[5]=r,e[6]=a):a=e[6],a}function Xe(n){const e=U.c(45),{providers:t,onSelect:s}=n,l=ie(),r=At();let a;e[0]!==t?(a=S=>t.find(y=>y.id===S),e[0]=t,e[1]=a):a=e[1];const c=a;let h,d,o,m,p;if(e[2]!==c||e[3]!==s||e[4]!==r){const S=r?void 0:c("deco");let y;e[10]!==c?(y=c("openai-compatible"),e[10]=c,e[11]=y):y=e[11],o=y;let w;e[12]===Symbol.for("react.memo_cache_sentinel")?(w=ve("openai"),e[12]=w):w=e[12];const _=w;let C;e[13]!==s?(C=v=>i.jsx(Ne,{logo:v.logo,name:v.name,description:v.description,onClick:()=>s({kind:"provider",provider:v})},v.id),e[13]=s,e[14]=C):C=e[14];const N=C;if(e[15]!==c||e[16]!==s||e[17]!==o||e[18]!==N){let v;if(e[20]!==c||e[21]!==N?(v=j=>{const M=c(j);return M?[N(M)]:[]},e[20]=c,e[21]=N,e[22]=v):v=e[22],h=Yt.flatMap(v),o&&_){let j;e[23]!==s||e[24]!==o?(j=i.jsx(Ne,{logo:_.logo,name:_.name,description:_.description,onClick:()=>s({kind:"openai-compatible",provider:o,preset:_})},_.id),e[23]=s,e[24]=o,e[25]=j):j=e[25],h.push(j)}e[15]=c,e[16]=s,e[17]=o,e[18]=N,e[19]=h}else h=e[19];let x;e[26]!==c||e[27]!==N?(x=Gt.flatMap(v=>{const j=c(v);return j?[N(j)]:[]}),e[26]=c,e[27]=N,e[28]=x):x=e[28],d=x,m="flex flex-col gap-5",p=S&&i.jsx(ke,{children:N(S)}),e[2]=c,e[3]=s,e[4]=r,e[5]=h,e[6]=d,e[7]=o,e[8]=m,e[9]=p}else h=e[5],d=e[6],o=e[7],m=e[8],p=e[9];let u;e[29]!==h||e[30]!==l?(u=h.length>0&&i.jsx(Ke,{label:l("settings.aiProviders.groupChat"),children:h}),e[29]=h,e[30]=l,e[31]=u):u=e[31];let f;e[32]!==d||e[33]!==l?(f=d.length>0&&i.jsx(Ke,{label:l("settings.aiProviders.groupMedia"),children:d}),e[32]=d,e[33]=l,e[34]=f):f=e[34];let g;e[35]!==s||e[36]!==o||e[37]!==l?(g=o&&i.jsx(ke,{children:i.jsx(Ne,{logo:o.logo,name:l("settings.aiProviders.customOpenAiCompatible"),description:l("settings.aiProviders.customOpenAiDescription"),onClick:()=>s({kind:"openai-compatible",provider:o,preset:null})})}),e[35]=s,e[36]=o,e[37]=l,e[38]=g):g=e[38];let I;return e[39]!==m||e[40]!==p||e[41]!==u||e[42]!==f||e[43]!==g?(I=i.jsxs("div",{className:m,children:[p,u,f,g]}),e[39]=m,e[40]=p,e[41]=u,e[42]=f,e[43]=g,e[44]=I):I=e[44],I}function Qt(n){return Be({label:xe().optional(),apiKey:xe().min(1,n)})}function Xt(n){const e=U.c(91),{providerId:t,onCancel:s,onSuccess:l}=n,{org:r}=be(),a=we(),c=_e(),[h,d]=$.useState(!1),o=ie();let m;e[0]!==o?(m=We(Qt(o("settings.connectForms.apiKeyRequired"))),e[0]=o,e[1]=m):m=e[1];let p;e[2]===Symbol.for("react.memo_cache_sentinel")?(p={label:"",apiKey:""},e[2]=p):p=e[2];let u;e[3]!==m?(u={resolver:m,defaultValues:p},e[3]=m,e[4]=u):u=e[4];const{register:f,handleSubmit:g,formState:I}=Ue(u),{errors:S}=I;let y;e[5]!==t||e[6]!==a||e[7]!==o?(y=async se=>{await a.call("AI_PROVIDER_KEY_CREATE",{providerId:t,label:se.label||o("settings.connectForms.defaultKeyLabel"),apiKey:se.apiKey})},e[5]=t,e[6]=a,e[7]=o,e[8]=y):y=e[8];let w;e[9]!==l||e[10]!==r||e[11]!==c||e[12]!==o?(w=()=>{c.invalidateQueries({queryKey:pe.aiProviderKeys(r.id)}),c.invalidateQueries({queryKey:pe.aiProviders(r.id)}),le.success(o("settings.connectForms.keySavedSuccess")),l()},e[9]=l,e[10]=r,e[11]=c,e[12]=o,e[13]=w):w=e[13];let _;e[14]!==o?(_=se=>{le.error(o("settings.connectForms.failedSaveKey",{error:se.message}))},e[14]=o,e[15]=_):_=e[15];let C;e[16]!==y||e[17]!==w||e[18]!==_?(C={mutationFn:y,onSuccess:w,onError:_},e[16]=y,e[17]=w,e[18]=_,e[19]=C):C=e[19];const{mutate:N,isPending:x,error:v}=je(C);let j;e[20]!==N?(j=se=>N(se),e[20]=N,e[21]=j):j=e[21];let M;e[22]!==g||e[23]!==j?(M=g(j),e[22]=g,e[23]=j,e[24]=M):M=e[24];let E;e[25]!==o?(E=o("settings.connectForms.labelField"),e[25]=o,e[26]=E):E=e[26];let R;e[27]!==E?(R=i.jsx("label",{className:"text-xs font-medium text-muted-foreground",children:E}),e[27]=E,e[28]=R):R=e[28];let A;e[29]!==o?(A=o("settings.connectForms.labelPlaceholder"),e[29]=o,e[30]=A):A=e[30];let b;e[31]!==f?(b=f("label"),e[31]=f,e[32]=b):b=e[32];let k;e[33]!==A||e[34]!==b?(k=i.jsx(fe,{placeholder:A,...b,size:"sm"}),e[33]=A,e[34]=b,e[35]=k):k=e[35];let z;e[36]!==R||e[37]!==k?(z=i.jsxs("div",{className:"space-y-1",children:[R,k]}),e[36]=R,e[37]=k,e[38]=z):z=e[38];let T;e[39]!==o?(T=o("settings.connectForms.apiKeyField"),e[39]=o,e[40]=T):T=e[40];let L;e[41]!==T?(L=i.jsx("label",{className:"text-xs font-medium text-muted-foreground",children:T}),e[41]=T,e[42]=L):L=e[42];const W=h?"text":"password";let P;e[43]!==f?(P=f("apiKey"),e[43]=f,e[44]=P):P=e[44];let V;e[45]!==W||e[46]!==P?(V=i.jsx(fe,{type:W,placeholder:"sk-...",...P,size:"sm",className:"ph-no-capture pr-8"}),e[45]=W,e[46]=P,e[47]=V):V=e[47];let X;e[48]!==h?(X=()=>d(!h),e[48]=h,e[49]=X):X=e[49];let H;e[50]!==h||e[51]!==o?(H=o(h?"settings.connectForms.hideApiKey":"settings.connectForms.showApiKey"),e[50]=h,e[51]=o,e[52]=H):H=e[52];let q;e[53]!==h?(q=h?i.jsx(qe,{size:14}):i.jsx(Ge,{size:14}),e[53]=h,e[54]=q):q=e[54];let Y;e[55]!==X||e[56]!==H||e[57]!==q?(Y=i.jsx("button",{type:"button",onClick:X,"aria-label":H,className:"absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground",children:q}),e[55]=X,e[56]=H,e[57]=q,e[58]=Y):Y=e[58];let ee;e[59]!==V||e[60]!==Y?(ee=i.jsxs("div",{className:"relative",children:[V,Y]}),e[59]=V,e[60]=Y,e[61]=ee):ee=e[61];let G;e[62]!==S.apiKey?(G=S.apiKey&&i.jsx("p",{className:"text-xs text-destructive",children:S.apiKey.message}),e[62]=S.apiKey,e[63]=G):G=e[63];let Q;e[64]!==L||e[65]!==ee||e[66]!==G?(Q=i.jsxs("div",{className:"space-y-1",children:[L,ee,G]}),e[64]=L,e[65]=ee,e[66]=G,e[67]=Q):Q=e[67];let Z;e[68]!==v?(Z=v&&i.jsx("p",{className:"text-xs text-destructive",children:v.message}),e[68]=v,e[69]=Z):Z=e[69];let O;e[70]!==o?(O=o("settings.connectForms.cancel"),e[70]=o,e[71]=O):O=e[71];let F;e[72]!==x||e[73]!==s||e[74]!==O?(F=i.jsx(oe,{type:"button",variant:"ghost",size:"sm",onClick:s,disabled:x,children:O}),e[72]=x,e[73]=s,e[74]=O,e[75]=F):F=e[75];let K;e[76]!==x||e[77]!==o?(K=o(x?"settings.connectForms.saving":"settings.connectForms.saveKey"),e[76]=x,e[77]=o,e[78]=K):K=e[78];let D;e[79]!==x||e[80]!==K?(D=i.jsx(oe,{type:"submit",size:"sm",disabled:x,children:K}),e[79]=x,e[80]=K,e[81]=D):D=e[81];let B;e[82]!==F||e[83]!==D?(B=i.jsxs(Ve,{children:[F,D]}),e[82]=F,e[83]=D,e[84]=B):B=e[84];let te;return e[85]!==M||e[86]!==z||e[87]!==Q||e[88]!==Z||e[89]!==B?(te=i.jsxs("form",{onSubmit:M,className:"space-y-3",children:[z,Q,Z,B]}),e[85]=M,e[86]=z,e[87]=Q,e[88]=Z,e[89]=B,e[90]=te):te=e[90],te}function Jt(n){return Be({label:xe().optional(),baseUrl:xe().min(1,n),apiKey:xe().optional()})}function Zt(n){const e=U.c(109),{preset:t,onCancel:s,onSuccess:l}=n,{org:r}=be(),a=we(),c=_e(),[h,d]=$.useState(!1),o=ie();let m;e[0]!==o?(m=We(Jt(o("settings.connectForms.baseUrlRequired"))),e[0]=o,e[1]=m):m=e[1];const p=t?.defaultBaseUrl??"";let u;e[2]!==p?(u={label:"",baseUrl:p,apiKey:""},e[2]=p,e[3]=u):u=e[3];let f;e[4]!==m||e[5]!==u?(f={resolver:m,defaultValues:u},e[4]=m,e[5]=u,e[6]=f):f=e[6];const{register:g,handleSubmit:I,formState:S}=Ue(f),{errors:y}=S;let w;e[7]!==t||e[8]!==a?(w=async re=>{const it=JSON.stringify({baseUrl:re.baseUrl,apiKey:re.apiKey||""});await a.call("AI_PROVIDER_KEY_CREATE",{providerId:"openai-compatible",label:re.label||t?.name||re.baseUrl,apiKey:it,...t?{presetId:t.id}:{}})},e[7]=t,e[8]=a,e[9]=w):w=e[9];let _;e[10]!==l||e[11]!==r||e[12]!==c||e[13]!==o?(_=()=>{c.invalidateQueries({queryKey:pe.aiProviderKeys(r.id)}),c.invalidateQueries({queryKey:pe.aiProviders(r.id)}),le.success(o("settings.connectForms.connectionSavedSuccess")),l()},e[10]=l,e[11]=r,e[12]=c,e[13]=o,e[14]=_):_=e[14];let C;e[15]!==o?(C=re=>{le.error(o("settings.connectForms.failedSaveConnection",{error:re.message}))},e[15]=o,e[16]=C):C=e[16];let N;e[17]!==w||e[18]!==_||e[19]!==C?(N={mutationFn:w,onSuccess:_,onError:C},e[17]=w,e[18]=_,e[19]=C,e[20]=N):N=e[20];const{mutate:x,isPending:v,error:j}=je(N);let M;e[21]!==t||e[22]!==o?(M=t?o("settings.connectForms.labelPlaceholderPreset",{name:t.name}):o("settings.connectForms.labelPlaceholderOpenAiCompatible"),e[21]=t,e[22]=o,e[23]=M):M=e[23];const E=M;let R;e[24]!==t?.baseUrlPlaceholder||e[25]!==o?(R=t?.baseUrlPlaceholder??o("settings.connectForms.baseUrlPlaceholder"),e[24]=t?.baseUrlPlaceholder,e[25]=o,e[26]=R):R=e[26];const A=R;let b;e[27]!==x?(b=re=>x(re),e[27]=x,e[28]=b):b=e[28];let k;e[29]!==I||e[30]!==b?(k=I(b),e[29]=I,e[30]=b,e[31]=k):k=e[31];let z;e[32]!==o?(z=o("settings.connectForms.labelField"),e[32]=o,e[33]=z):z=e[33];let T;e[34]!==z?(T=i.jsx("label",{className:"text-xs font-medium text-muted-foreground",children:z}),e[34]=z,e[35]=T):T=e[35];let L;e[36]!==g?(L=g("label"),e[36]=g,e[37]=L):L=e[37];let W;e[38]!==E||e[39]!==L?(W=i.jsx(fe,{placeholder:E,...L,size:"sm"}),e[38]=E,e[39]=L,e[40]=W):W=e[40];let P;e[41]!==T||e[42]!==W?(P=i.jsxs("div",{className:"space-y-1",children:[T,W]}),e[41]=T,e[42]=W,e[43]=P):P=e[43];let V;e[44]!==A||e[45]!==y||e[46]!==t?.defaultBaseUrl||e[47]!==g||e[48]!==o?(V=t?.defaultBaseUrl?i.jsx("input",{type:"hidden",...g("baseUrl")}):i.jsxs("div",{className:"space-y-1",children:[i.jsx("label",{className:"text-xs font-medium text-muted-foreground",children:o("settings.connectForms.baseUrlField")}),i.jsx(fe,{type:"url",placeholder:A,...g("baseUrl"),size:"sm"}),y.baseUrl&&i.jsx("p",{className:"text-xs text-destructive",children:y.baseUrl.message})]}),e[44]=A,e[45]=y,e[46]=t?.defaultBaseUrl,e[47]=g,e[48]=o,e[49]=V):V=e[49];let X;e[50]!==o?(X=o("settings.connectForms.apiKeyField"),e[50]=o,e[51]=X):X=e[51];let H;e[52]!==t?.apiKeyRecommended||e[53]!==o?(H=t?.apiKeyRecommended?o("settings.connectForms.recommended"):o("settings.connectForms.optional"),e[52]=t?.apiKeyRecommended,e[53]=o,e[54]=H):H=e[54];let q;e[55]!==H?(q=i.jsxs("span",{className:"text-muted-foreground/60",children:["(",H,")"]}),e[55]=H,e[56]=q):q=e[56];let Y;e[57]!==X||e[58]!==q?(Y=i.jsxs("label",{className:"text-xs font-medium text-muted-foreground",children:[X," ",q]}),e[57]=X,e[58]=q,e[59]=Y):Y=e[59];const ee=h?"text":"password";let G;e[60]!==g?(G=g("apiKey"),e[60]=g,e[61]=G):G=e[61];let Q;e[62]!==ee||e[63]!==G?(Q=i.jsx(fe,{type:ee,placeholder:"sk-...",...G,size:"sm",className:"ph-no-capture pr-8"}),e[62]=ee,e[63]=G,e[64]=Q):Q=e[64];let Z;e[65]!==h?(Z=()=>d(!h),e[65]=h,e[66]=Z):Z=e[66];let O;e[67]!==h||e[68]!==o?(O=o(h?"settings.connectForms.hideApiKey":"settings.connectForms.showApiKey"),e[67]=h,e[68]=o,e[69]=O):O=e[69];let F;e[70]!==h?(F=h?i.jsx(qe,{size:14}):i.jsx(Ge,{size:14}),e[70]=h,e[71]=F):F=e[71];let K;e[72]!==Z||e[73]!==O||e[74]!==F?(K=i.jsx("button",{type:"button",onClick:Z,"aria-label":O,className:"absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground",children:F}),e[72]=Z,e[73]=O,e[74]=F,e[75]=K):K=e[75];let D;e[76]!==Q||e[77]!==K?(D=i.jsxs("div",{className:"relative",children:[Q,K]}),e[76]=Q,e[77]=K,e[78]=D):D=e[78];let B;e[79]!==Y||e[80]!==D?(B=i.jsxs("div",{className:"space-y-1",children:[Y,D]}),e[79]=Y,e[80]=D,e[81]=B):B=e[81];let te;e[82]!==t?(te=t?.helpText&&i.jsx("p",{className:"text-xs text-muted-foreground",children:t.helpText}),e[82]=t,e[83]=te):te=e[83];let se;e[84]!==j?(se=j&&i.jsx("p",{className:"text-xs text-destructive",children:j.message}),e[84]=j,e[85]=se):se=e[85];let ae;e[86]!==o?(ae=o("settings.connectForms.cancel"),e[86]=o,e[87]=ae):ae=e[87];let ce;e[88]!==v||e[89]!==s||e[90]!==ae?(ce=i.jsx(oe,{type:"button",variant:"ghost",size:"sm",onClick:s,disabled:v,children:ae}),e[88]=v,e[89]=s,e[90]=ae,e[91]=ce):ce=e[91];let de;e[92]!==v||e[93]!==o?(de=o(v?"settings.connectForms.saving":"settings.connectForms.saveConnection"),e[92]=v,e[93]=o,e[94]=de):de=e[94];let he;e[95]!==v||e[96]!==de?(he=i.jsx(oe,{type:"submit",size:"sm",disabled:v,children:de}),e[95]=v,e[96]=de,e[97]=he):he=e[97];let ue;e[98]!==ce||e[99]!==he?(ue=i.jsxs(Ve,{children:[ce,he]}),e[98]=ce,e[99]=he,e[100]=ue):ue=e[100];let ye;return e[101]!==k||e[102]!==P||e[103]!==V||e[104]!==B||e[105]!==te||e[106]!==se||e[107]!==ue?(ye=i.jsxs("form",{onSubmit:k,className:"space-y-3",children:[P,V,B,te,se,ue]}),e[101]=k,e[102]=P,e[103]=V,e[104]=B,e[105]=te,e[106]=se,e[107]=ue,e[108]=ye):ye=e[108],ye}const es={kind:"closed"};function ts(n,e){switch(e.type){case"open":return n.kind==="closed"?{kind:"grid"}:n;case"close":return{kind:"closed"};case"back":switch(n.kind){case"form":case"oauth-pending":case"provision-pending":case"provision-error":return{kind:"grid"};default:return n}case"select-form":return n.kind!=="grid"?n:{kind:"form",providerId:e.providerId,presetId:e.presetId};case"select-oauth":return n.kind!=="grid"?n:{kind:"oauth-pending",providerId:e.providerId,stateToken:e.stateToken};case"oauth-failed":return n.kind==="oauth-pending"?{kind:"grid"}:n;case"select-provision":return n.kind!=="grid"?n:{kind:"provision-pending",providerId:e.providerId};case"provision-error":return n.kind!=="provision-pending"?n:{kind:"provision-error",providerId:n.providerId,error:e.error};case"retry-provision":return n.kind!=="provision-error"?n:{kind:"provision-pending",providerId:n.providerId}}}function ss(n){switch(n.kind){case"form":case"oauth-pending":case"provision-pending":case"provision-error":return n.providerId;default:return null}}function is({open:n,onOpenChange:e,initialProvider:t}){const s=ie(),r=Ie()?.providers??[],{org:a}=be(),c=we(),h=_e(),[d,o]=$.useReducer(ts,es),m=$.useRef(!1);$.useEffect(()=>{n&&d.kind==="closed"?o({type:"open"}):!n&&d.kind!=="closed"&&o({type:"close"})},[n,d.kind]);const p=()=>{m.current=!1,o({type:"close"}),e(!1)},u=()=>{h.invalidateQueries({queryKey:pe.aiProviderKeys(a.id)}),h.invalidateQueries({queryKey:pe.aiProviders(a.id)})},{mutate:f}=je({mutationFn:async({providerId:b,code:k,stateToken:z,label:T})=>(await c.call("AI_PROVIDER_OAUTH_EXCHANGE",{providerId:b,code:k,stateToken:z,label:T}),b),onSuccess:b=>{ne("ai_provider_oauth_succeeded",{provider_id:b}),u();const k=r.find(z=>z.id===b);le.success(s("settings.connectProviderDialog.oauthSuccessMessage",{provider:k?.name??s("settings.connectProviderDialog.defaultProviderName")})),p()},onError:(b,k)=>{ne("ai_provider_oauth_failed",{provider_id:k.providerId,error:b.message}),le.error(s("settings.connectProviderDialog.oauthFailedMessage",{error:b.message})),o({type:"oauth-failed"})}}),{mutate:g}=je({mutationFn:async b=>(await c.call("AI_PROVIDER_PROVISION_KEY",{providerId:b}),b),onSuccess:b=>{ne("ai_provider_provision_succeeded",{provider_id:b}),u();const k=r.find(z=>z.id===b);le.success(s("settings.connectProviderDialog.provisionSuccessMessage",{provider:k?.name??s("settings.connectProviderDialog.defaultProviderName")})),p()},onError:(b,k)=>{ne("ai_provider_provision_failed",{provider_id:k,error:b.message}),o({type:"provision-error",error:b.message})}}),I=async b=>{const{provider:k}=b,z=b.kind==="openai-compatible"?b.preset?.id??null:null,T=k.supportedMethods.includes("oauth-pkce"),L=k.supportedMethods.includes("api-key");if(k.supportsProvision===!0){ne("ai_provider_connect_clicked",{provider_id:k.id,method:"provision"}),o({type:"select-provision",providerId:k.id}),g(k.id);return}if(T){ne("ai_provider_connect_clicked",{provider_id:k.id,method:"oauth-pkce"});try{const P=await c.call("AI_PROVIDER_OAUTH_URL",{providerId:k.id,callbackUrl:`${window.location.origin}/oauth/callback/ai-provider`});if(!P?.url)throw new Error("Invalid response from AI_PROVIDER_OAUTH_URL");o({type:"select-oauth",providerId:k.id,stateToken:P.stateToken}),window.open(P.url,"AiProviderOAuth","width=600,height=700")}catch(P){le.error(s("settings.connectProviderDialog.startOAuthFailedMessage",{error:P instanceof Error?P.message:String(P)}))}return}L&&(ne("ai_provider_connect_clicked",{provider_id:k.id,...z!==null?{preset_id:z}:{},method:"api-key"}),o({type:"select-form",providerId:k.id,presetId:z}))},S=$.useRef(I);S.current=I;const y=$.useRef(t);y.current=t,$.useEffect(()=>{!y.current||d.kind!=="grid"||m.current||(m.current=!0,S.current(y.current))},[d.kind]);const w=d.kind==="oauth-pending"?d.stateToken:null,_=d.kind==="oauth-pending"?d.providerId:null;$.useEffect(()=>{if(d.kind!=="oauth-pending")return;let b=!1;const k=d.stateToken,z=d.providerId,T=W=>{if(W.origin!==window.location.origin||W.data?.type!=="AI_PROVIDER_OAUTH_CALLBACK")return;const{code:P,stateToken:V}=W.data;if(V!==k){le.error(s("settings.connectProviderDialog.securityCheckFailedMessage")),o({type:"oauth-failed"});return}b=!0;const X=r.find(H=>H.id===z);f({providerId:z,code:P,stateToken:k,label:X?.name??z})};window.addEventListener("message",T);const L=setTimeout(()=>{b||(ne("ai_provider_oauth_timeout",{provider_id:z}),o({type:"oauth-failed"}),le.error(s("settings.connectProviderDialog.connectionTimedOutMessage")))},12e4);return()=>{window.removeEventListener("message",T),clearTimeout(L)}},[d.kind,w,_,f]);const[C,N]=$.useState(d);d.kind!=="closed"&&d!==C&&N(d);const x=d.kind==="closed"?C:d,v=ss(x),j=v?r.find(b=>b.id===v):null,E=(x.kind==="form"&&x.presetId?ve(x.presetId):null)?.name??j?.name??s("settings.connectProviderDialog.defaultTitle"),R=x.kind!=="grid"&&x.kind!=="closed",A=()=>{t?p():o({type:"back"})};return i.jsx(ot,{open:d.kind!=="closed",onOpenChange:b=>!b&&p(),children:i.jsxs(at,{className:"sm:max-w-md max-h-[90vh] overflow-y-auto",children:[i.jsx(ct,{children:i.jsxs("div",{className:"flex items-center gap-2",children:[R&&i.jsx(oe,{variant:"ghost",size:"icon-sm","aria-label":s("settings.connectProviderDialog.backButtonLabel"),onClick:A,children:i.jsx(He,{size:16})}),i.jsx(dt,{children:E})]})}),x.kind==="grid"&&!t&&i.jsx(Xe,{providers:r,onSelect:I}),x.kind==="form"&&(x.providerId==="openai-compatible"?i.jsx(Zt,{preset:x.presetId?ve(x.presetId):void 0,onCancel:()=>o({type:"back"}),onSuccess:()=>{u(),p()}}):i.jsx(Xt,{providerId:x.providerId,onCancel:()=>o({type:"back"}),onSuccess:()=>{u(),p()}})),x.kind==="oauth-pending"&&i.jsxs("div",{className:"flex flex-col items-center gap-4 py-8",children:[i.jsx(Oe,{size:"lg"}),i.jsx("p",{className:"text-sm text-muted-foreground text-center",children:s("settings.connectProviderDialog.oauthPendingMessage")})]}),x.kind==="provision-pending"&&i.jsxs("div",{className:"flex flex-col items-center gap-4 py-8",children:[i.jsx(Oe,{size:"lg"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:s("settings.connectProviderDialog.provisionPendingMessage")})]}),x.kind==="provision-error"&&i.jsxs("div",{className:"flex flex-col items-center gap-4 py-6",children:[i.jsx(Pt,{size:28,className:"text-destructive"}),i.jsx("p",{className:"text-sm text-foreground text-center",children:x.error}),i.jsxs("div",{className:"flex gap-2",children:[i.jsx(oe,{variant:"outline",size:"sm",onClick:()=>o({type:"back"}),children:s("settings.connectProviderDialog.backButton")}),i.jsx(oe,{size:"sm",onClick:()=>{o({type:"retry-provision"}),g(x.providerId)},children:s("settings.connectProviderDialog.retryButton")})]})]})]})})}function ns(n){const e=U.c(35);let t;e[0]!==n?(t=n===void 0?{}:n,e[0]=n,e[1]=t):t=e[1];const{title:s,description:l,providerFilter:r}=t,a=ie(),{org:c}=be(),[h,d]=$.useState(null),o=Ie();let m;e[2]!==o?.providers?(m=o?.providers??[],e[2]=o?.providers,e[3]=m):m=e[3];let p;if(e[4]!==r||e[5]!==m){let b;e[7]!==r?(b=k=>!r||r(k.id),e[7]=r,e[8]=b):b=e[8],p=m.filter(b),e[4]=r,e[5]=m,e[6]=p}else p=e[6];const u=p,f=c.name;let g;e[9]!==f||e[10]!==a||e[11]!==s?(g=s??(f?a("chat.noAiProviderEmptyState.headingWithOrg",{org:f}):a("chat.noAiProviderEmptyState.headingDefault")),e[9]=f,e[10]=a,e[11]=s,e[12]=g):g=e[12];const I=g;let S;e[13]!==l||e[14]!==a?(S=l??a("chat.noAiProviderEmptyState.subtitleDefault"),e[13]=l,e[14]=a,e[15]=S):S=e[15];const y=S;let w;e[16]===Symbol.for("react.memo_cache_sentinel")?(w=i.jsx("div",{className:"flex items-center justify-center size-14 rounded-2xl bg-muted border border-border",children:i.jsx(zt,{size:24,className:"text-muted-foreground"})}),e[16]=w):w=e[16];let _;e[17]!==I?(_=i.jsx("p",{className:"text-xl font-semibold text-foreground tracking-tight",children:I}),e[17]=I,e[18]=_):_=e[18];let C;e[19]!==y?(C=i.jsx("p",{className:"text-sm text-muted-foreground max-w-md",children:y}),e[19]=y,e[20]=C):C=e[20];let N;e[21]!==_||e[22]!==C?(N=i.jsxs("div",{className:"flex flex-col items-center gap-4 text-center",children:[w,i.jsxs("div",{className:"space-y-2",children:[_,C]})]}),e[21]=_,e[22]=C,e[23]=N):N=e[23];let x;e[24]===Symbol.for("react.memo_cache_sentinel")?(x=b=>d(b),e[24]=x):x=e[24];let v;e[25]!==u?(v=i.jsx("div",{className:"w-full",children:i.jsx(Xe,{providers:u,onSelect:x})}),e[25]=u,e[26]=v):v=e[26];const j=h!==null;let M;e[27]===Symbol.for("react.memo_cache_sentinel")?(M=b=>{b||d(null)},e[27]=M):M=e[27];const E=h??void 0;let R;e[28]!==j||e[29]!==E?(R=i.jsx(is,{open:j,onOpenChange:M,initialProvider:E}),e[28]=j,e[29]=E,e[30]=R):R=e[30];let A;return e[31]!==v||e[32]!==R||e[33]!==N?(A=i.jsxs("div",{className:"flex flex-col items-center gap-8 w-full max-w-3xl px-4",children:[N,v,R]}),e[31]=v,e[32]=R,e[33]=N,e[34]=A):A=e[34],A}function Me(n){const e=n.title.includes(": ");return{provider:e?n.title.split(": ")[0]??"":n.modelId.split("/")[0]??"",displayName:e?n.title.split(": ").slice(1).join(": "):n.title}}function ls(n){return n<32e3?{level:1,labelKey:"chat.shared.contextLevelSmall",descriptionKey:"chat.shared.contextLevelSmallDesc"}:n<2e5?{level:2,labelKey:"chat.shared.contextLevelMedium",descriptionKey:"chat.shared.contextLevelMediumDesc"}:n<5e5?{level:3,labelKey:"chat.shared.contextLevelLarge",descriptionKey:"chat.shared.contextLevelLargeDesc"}:{level:4,labelKey:"chat.shared.contextLevelVeryLarge",descriptionKey:"chat.shared.contextLevelVeryLargeDesc"}}const rs=["bg-destructive","bg-warning","bg-success","bg-success"],os=["text-success","text-warning","text-warning","text-destructive"];function as(n,e){const t=Math.round(n*.75/1e3),s=t>=1?`${t}K`:`${Math.round(n*.75)}`;return e("chat.shared.approxWords",{wordCount:s})}function cs(n){return n<1?{level:1,labelKey:"chat.shared.costLevelCheap"}:n<5?{level:2,labelKey:"chat.shared.costLevelModerate"}:n<15?{level:3,labelKey:"chat.shared.costLevelHigh"}:{level:4,labelKey:"chat.shared.costLevelExpensive"}}const ds={text:{icon:i.jsx(wt,{className:"size-3.5"}),labelKey:"chat.shared.capabilityText"},vision:{icon:i.jsx(Ft,{className:"size-3.5"}),labelKey:"chat.shared.capabilityVision"},image:{icon:i.jsx(kt,{className:"size-3.5"}),labelKey:"chat.shared.capabilityImage"},tools:{icon:i.jsx(Nt,{className:"size-3.5"}),labelKey:"chat.shared.capabilityTools"},reasoning:{icon:i.jsx(St,{className:"size-3.5"}),labelKey:"chat.shared.capabilityReasoning"},"web-search":{icon:i.jsx(Ye,{className:"size-3.5"}),labelKey:"chat.shared.capabilityWebSearch"}};function hs(n){const e=U.c(10),{capability:t}=n,s=ie(),l=ds[t];if(l){const h=l.icon;let d;e[0]!==l.labelKey||e[1]!==s?(d=s(l.labelKey),e[0]=l.labelKey,e[1]=s,e[2]=d):d=e[2];let o;return e[3]!==l.icon||e[4]!==d?(o=i.jsxs("span",{className:"inline-flex items-center gap-1 text-xs text-muted-foreground border border-border rounded px-2 py-0.5",children:[h,d]}),e[3]=l.icon,e[4]=d,e[5]=o):o=e[5],o}let r;e[6]!==t?(r=t.charAt(0).toUpperCase(),e[6]=t,e[7]=r):r=e[7];const a=r+t.slice(1);let c;return e[8]!==a?(c=i.jsx("span",{className:"inline-flex items-center gap-1 text-xs text-muted-foreground border border-border rounded px-2 py-0.5",children:a}),e[8]=a,e[9]=c):c=e[9],c}function us(n){const e=U.c(59),{model:t,compact:s}=n,l=s===void 0?!1:s,r=ie();if(!t){let x;e[0]!==r?(x=r("chat.shared.hoverToPreview"),e[0]=r,e[1]=x):x=e[1];let v;return e[2]!==x?(v=i.jsx("div",{className:"flex items-center justify-center h-full text-muted-foreground text-sm",children:x}),e[2]=x,e[3]=v):v=e[3],v}const a=t.costs?.input!=null?t.costs.input*1e6:null,c=t.costs?.output!=null?t.costs.output*1e6:null;let h;e[4]!==t?(h=Me(t),e[4]=t,e[5]=h):h=e[5];const{provider:d,displayName:o}=h;if(l){let x;e[6]!==t.limits||e[7]!==r?(x=t.limits?.contextWindow&&i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:r("chat.shared.context")}),i.jsxs("span",{className:"text-foreground font-medium",children:[t.limits.contextWindow.toLocaleString()," ",r("chat.shared.tokens")]})]}),e[6]=t.limits,e[7]=r,e[8]=x):x=e[8];let v;e[9]!==a||e[10]!==r?(v=a!=null&&i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:r("chat.shared.input")}),i.jsxs("span",{className:"text-foreground font-medium",children:["$",a.toFixed(2)," / 1M"]})]}),e[9]=a,e[10]=r,e[11]=v):v=e[11];let j;e[12]!==c||e[13]!==r?(j=c!=null&&i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:r("chat.shared.output")}),i.jsxs("span",{className:"text-foreground font-medium",children:["$",c.toFixed(2)," / 1M"]})]}),e[12]=c,e[13]=r,e[14]=j):j=e[14];let M;e[15]!==t.limits||e[16]!==r?(M=t.limits?.maxOutputTokens&&i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:r("chat.shared.outputLimit")}),i.jsxs("span",{className:"text-foreground font-medium",children:[t.limits.maxOutputTokens.toLocaleString()," ",r("chat.shared.tokens")]})]}),e[15]=t.limits,e[16]=r,e[17]=M):M=e[17];let E;return e[18]!==x||e[19]!==v||e[20]!==j||e[21]!==M?(E=i.jsxs("div",{className:"flex flex-col gap-2 pt-3 pb-3 px-3 text-xs",children:[x,v,j,M]}),e[18]=x,e[19]=v,e[20]=j,e[21]=M,e[22]=E):E=e[22],E}let m;e[23]!==d?(m=i.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:d}),e[23]=d,e[24]=m):m=e[24];let p;e[25]!==t.logo||e[26]!==t.title?(p=t.logo&&i.jsx("img",{src:t.logo,className:"size-6 shrink-0 rounded-md dark:bg-white dark:rounded-sm dark:p-px",alt:t.title}),e[25]=t.logo,e[26]=t.title,e[27]=p):p=e[27];let u;e[28]!==o?(u=i.jsx("p",{className:"text-lg font-semibold leading-snug tracking-tight",children:o}),e[28]=o,e[29]=u):u=e[29];let f;e[30]!==p||e[31]!==u?(f=i.jsxs("div",{className:"flex items-center gap-2.5",children:[p,u]}),e[30]=p,e[31]=u,e[32]=f):f=e[32];let g;e[33]!==t.modelId?(g=i.jsx("p",{className:"text-xs text-muted-foreground/50 font-mono",children:t.modelId}),e[33]=t.modelId,e[34]=g):g=e[34];let I;e[35]!==m||e[36]!==f||e[37]!==g?(I=i.jsxs("div",{className:"flex flex-col gap-1 pt-1 pr-6",children:[m,f,g]}),e[35]=m,e[36]=f,e[37]=g,e[38]=I):I=e[38];let S;e[39]!==t.capabilities?(S=t.capabilities&&t.capabilities.length>0&&i.jsx("div",{className:"flex flex-wrap items-center gap-1.5 pb-4 border-b border-border",children:[...new Set(t.capabilities)].map(ms)}),e[39]=t.capabilities,e[40]=S):S=e[40];let y;e[41]!==t.limits||e[42]!==r?(y=t.limits?.contextWindow&&(()=>{const{level:x,labelKey:v,descriptionKey:j}=ls(t.limits.contextWindow);return i.jsxs("div",{className:"flex flex-col gap-1.5",children:[i.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:r("chat.shared.contextWindow")}),i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("div",{className:"flex items-center gap-0.5",children:[1,2,3,4].map(M=>i.jsx("div",{className:ge("w-2 h-2 rounded-full",M<=x?rs[x-1]:"bg-muted")},M))}),i.jsx("span",{className:"text-xs text-muted-foreground font-medium",children:r(v)}),i.jsxs("span",{className:"text-xs text-muted-foreground",children:["— ",r(j)]})]}),i.jsxs("span",{className:"text-sm text-muted-foreground",children:[t.limits.contextWindow.toLocaleString()," ",r("chat.shared.tokens")]})]})})(),e[41]=t.limits,e[42]=r,e[43]=y):y=e[43];let w;e[44]!==t.limits||e[45]!==r?(w=t.limits?.maxOutputTokens&&i.jsxs("div",{className:"flex flex-col gap-1",children:[i.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:r("chat.shared.outputLimit")}),i.jsxs("div",{className:"flex items-baseline gap-2",children:[i.jsxs("span",{className:"text-sm text-foreground",children:[t.limits.maxOutputTokens.toLocaleString()," ",r("chat.shared.tokens")]}),i.jsx("span",{className:"text-sm text-muted-foreground",children:as(t.limits.maxOutputTokens,r)})]})]}),e[44]=t.limits,e[45]=r,e[46]=w):w=e[46];let _;e[47]!==a||e[48]!==c||e[49]!==r?(_=(a!=null||c!=null)&&(()=>{const{level:x,labelKey:v}=a!=null?cs(a):{level:0,labelKey:null};return i.jsxs("div",{className:"flex flex-col gap-2",children:[i.jsx("span",{className:"text-xs font-medium text-muted-foreground",children:r("chat.shared.pricing")}),a!=null&&i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("div",{className:"flex items-center",children:[1,2,3,4].map(j=>i.jsx("span",{className:ge("text-sm font-semibold leading-none",j<=x?os[x-1]:"text-muted-foreground/20"),children:"$"},j))}),i.jsx("span",{className:"text-xs text-muted-foreground font-medium",children:v?r(v):""})]}),i.jsxs("div",{className:"flex flex-col gap-1",children:[a!=null&&i.jsxs("div",{className:"flex justify-between items-center",children:[i.jsx("span",{className:"text-xs text-muted-foreground",children:r("chat.shared.input")}),i.jsxs("span",{className:"text-xs text-foreground",children:["$",a.toFixed(2)," / 1M"," ",r("chat.shared.tokens")]})]}),c!=null&&i.jsxs("div",{className:"flex justify-between items-center",children:[i.jsx("span",{className:"text-xs text-muted-foreground",children:r("chat.shared.output")}),i.jsxs("span",{className:"text-xs text-foreground",children:["$",c.toFixed(2)," / 1M"," ",r("chat.shared.tokens")]})]})]})]})})(),e[47]=a,e[48]=c,e[49]=r,e[50]=_):_=e[50];let C;e[51]!==y||e[52]!==w||e[53]!==_?(C=i.jsxs("div",{className:"flex flex-col gap-6",children:[y,w,_]}),e[51]=y,e[52]=w,e[53]=_,e[54]=C):C=e[54];let N;return e[55]!==C||e[56]!==I||e[57]!==S?(N=i.jsxs("div",{className:"flex flex-col gap-5 py-1 px-1.5",children:[I,S,C]}),e[55]=C,e[56]=I,e[57]=S,e[58]=N):N=e[58],N}function ms(n){return i.jsx(hs,{capability:n},n)}function ni(n){const e=U.c(22),{model:t,placeholder:s,isLoading:l}=n,r=l===void 0?!1:l,a=ie();let c;e[0]!==s||e[1]!==a?(c=s??a("chat.shared.selectModel"),e[0]=s,e[1]=a,e[2]=c):c=e[2];const h=c;if(r){let S;return e[3]===Symbol.for("react.memo_cache_sentinel")?(S=i.jsxs("div",{className:"flex items-center gap-1.5",children:[i.jsx(J,{className:"w-5 h-5 rounded-sm shrink-0"}),i.jsx(J,{className:"w-16 h-3 hidden md:block"})]}),e[3]=S):S=e[3],S}if(!t){let S;e[4]!==h?(S=i.jsx("span",{className:"text-sm text-muted-foreground",children:h}),e[4]=h,e[5]=S):S=e[5];let y;e[6]===Symbol.for("react.memo_cache_sentinel")?(y=i.jsx(ze,{size:14,className:"text-muted-foreground opacity-50 shrink-0"}),e[6]=y):y=e[6];let w;return e[7]!==S?(w=i.jsxs("div",{className:"flex items-center gap-1.5",children:[S,y]}),e[7]=S,e[8]=w):w=e[8],w}let d;e[9]!==t?(d=Me(t),e[9]=t,e[10]=d):d=e[10];const{displayName:o}=d;let m;e[11]!==t?(m=Ce(t),e[11]=t,e[12]=m):m=e[12];const p=m;let u;e[13]!==t.title||e[14]!==p?(u=i.jsx("img",{src:p,className:"w-3.5 h-3.5 shrink-0 rounded-sm dark:bg-white dark:rounded-sm dark:p-px",alt:t.title}),e[13]=t.title,e[14]=p,e[15]=u):u=e[15];let f;e[16]!==o?(f=i.jsx("span",{className:"text-sm truncate whitespace-nowrap text-muted-foreground max-w-[100px] sm:max-w-none",children:o}),e[16]=o,e[17]=f):f=e[17];let g;e[18]===Symbol.for("react.memo_cache_sentinel")?(g=i.jsx(ze,{size:14,className:"text-muted-foreground opacity-50 shrink-0"}),e[18]=g):g=e[18];let I;return e[19]!==u||e[20]!==f?(I=i.jsxs("div",{className:"flex items-center gap-1.5 min-w-0 overflow-hidden",children:[u,f,g]}),e[19]=u,e[20]=f,e[21]=I):I=e[21],I}const fs=["vision","image","file","audio","video"],Je=["image/png","image/jpeg","image/gif","image/webp"],Ze=["application/vnd.openxmlformats-officedocument.presentationml.presentation","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"];function Ee(n){const e=n?.capabilities;return e?fs.some(t=>e.includes(t)):!1}function li(n,e){if(!n)return!1;if(n.startsWith("text/"))return!0;const t=e?.capabilities??[],s=t.includes("vision")||t.includes("image"),l=t.includes("file"),r=t.includes("audio"),a=t.includes("video");return!!(s&&Je.includes(n)||l&&n==="application/pdf"||r&&n.startsWith("audio/")||a&&n.startsWith("video/")||Ee(e)&&Ze.includes(n))}function ri(n){const e=n?.capabilities??[],t=["text/*"];return(e.includes("vision")||e.includes("image"))&&t.push(...Je),e.includes("file")&&t.push("application/pdf"),e.includes("audio")&&t.push("audio/*"),e.includes("video")&&t.push("video/*"),Ee(n)&&t.push(...Ze),t.join(",")}function oi(n){const e=n?.capabilities??[],t=[];return(e.includes("vision")||e.includes("image"))&&t.push("chat.shared.fileTypeImages"),e.includes("file")&&t.push("chat.shared.fileTypePdfs"),e.includes("audio")&&t.push("chat.shared.fileTypeAudio"),e.includes("video")&&t.push("chat.shared.fileTypeVideo"),Ee(n)&&t.push("chat.shared.fileTypeOffice"),{parts:t,count:t.length}}const et=["smarter","faster","cheaper"],ps={smarter:"chat.decopilot.tierSmarter",faster:"chat.decopilot.tierFaster",cheaper:"chat.decopilot.tierCheaper"},xs=[{tier:"smarter",prefixes:["anthropic/claude-opus-4.8","anthropic/claude-sonnet-4.6","anthropic/claude-4.6-sonnet","openai/gpt-5.3-codex","google/gemini-3-pro","google/gemini-2.5-pro","cohere/command-r-plus","cohere/command-a"]},{tier:"faster",prefixes:["anthropic/claude-haiku-4.5","anthropic/claude-4.5-haiku","google/gemini-3-flash","openai/gpt-5.1-codex-mini","x-ai/grok-code-fast","x-ai/grok-3","mistralai/mistral-large","mistralai/codestral","mistralai/mistral-medium","minimax/minimax-m1"]},{tier:"cheaper",prefixes:["google/gemini-2.5-flash-lite","google/gemini-2.5-flash","google/gemini-2.0-flash","deepseek/deepseek-v3","openai/gpt-oss-120b","mistralai/mistral-small","mistralai/pixtral","cohere/command-r"]}],gs=xs.flatMap(({tier:n,prefixes:e})=>e.map(t=>({tier:n,prefix:t}))).sort((n,e)=>e.prefix.length-n.prefix.length),vs="google/gemini-2.5-pro",Le=new Map;function bs(n){const e=Le.get(n);if(e!==void 0)return e;let t=null;if(n.endsWith(":free"))t="cheaper";else for(const{tier:s,prefix:l}of gs)if(n.startsWith(l)){if(l===vs&&n.length>l.length&&n[l.length]==="-"){const a=n[l.length+1];if(!a||!/\d/.test(a))continue}t=s;break}return Le.set(n,t),t}function ys(n,e,t){if(t)return n;const s=n.filter(l=>e.has(l.modelId));return s.length>0?s:n}function De(n){const e={smarter:[],faster:[],cheaper:[],other:[]};for(const t of n){const s=bs(t.modelId);e[s??"other"].push(t)}for(const t of Object.keys(e))e[t].sort((s,l)=>s.title.localeCompare(l.title));return e}const tt="studio:model-shortlist:",js=new Set(["anthropic/claude-opus-4.8","anthropic/claude-sonnet-4.6","anthropic/claude-4.6-sonnet","anthropic/claude-sonnet-4.6:extended","openai/gpt-5.3-codex","google/gemini-3-pro-preview","google/gemini-2.5-pro","anthropic/claude-haiku-4.5","anthropic/claude-haiku-4.5-20251001","anthropic/claude-4.5-haiku","google/gemini-3-flash-preview","openai/gpt-5.1-codex-mini","x-ai/grok-code-fast-1","google/gemini-2.5-flash","deepseek/deepseek-v3.2","google/gemini-2.5-flash-lite","openai/gpt-oss-120b:free"]);function Ss(n){try{const e=localStorage.getItem(tt+n);return e?new Set(JSON.parse(e)):null}catch{return null}}function Ns(n,e){localStorage.setItem(tt+n,JSON.stringify([...e]))}function ks(n){const e=U.c(21),{model:t,onHover:s}=n;let l;e[0]!==t?(l=Me(t),e[0]=t,e[1]=l):l=e[1];const{displayName:r,provider:a}=l;let c;e[2]!==t?(c=Ce(t),e[2]=t,e[3]=c):c=e[3];const h=c;let d;e[4]!==t||e[5]!==s?(d=()=>s(t),e[4]=t,e[5]=s,e[6]=d):d=e[6];let o;e[7]!==t.title||e[8]!==h?(o=i.jsx("img",{src:h,className:"w-4 h-4 shrink-0 rounded-sm dark:bg-white dark:rounded-sm dark:p-px",alt:t.title}),e[7]=t.title,e[8]=h,e[9]=o):o=e[9];let m;e[10]!==r?(m=i.jsx("span",{className:"text-sm text-foreground leading-tight truncate",children:r}),e[10]=r,e[11]=m):m=e[11];let p;e[12]!==a?(p=i.jsx("span",{className:"text-xs text-muted-foreground/60 leading-tight",children:a}),e[12]=a,e[13]=p):p=e[13];let u;e[14]!==m||e[15]!==p?(u=i.jsxs("div",{className:"flex flex-col flex-1 min-w-0",children:[m,p]}),e[14]=m,e[15]=p,e[16]=u):u=e[16];let f;return e[17]!==d||e[18]!==o||e[19]!==u?(f=i.jsxs("div",{className:"flex items-center gap-2.5 py-2 px-3 hover:bg-accent cursor-pointer rounded-lg",onMouseEnter:d,children:[o,u]}),e[17]=d,e[18]=o,e[19]=u,e[20]=f):f=e[20],f}function ws(n){const e=U.c(16),{error:t,onRetry:s}=n,l=ie();let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=i.jsx("div",{className:"bg-destructive/10 p-2 rounded-full",children:i.jsx(mt,{className:"size-5 text-destructive"})}),e[0]=r):r=e[0];const a=l("chat.decopilot.failedToLoadModels");let c;e[1]!==a?(c=i.jsx("p",{className:"text-sm font-medium text-foreground",children:a}),e[1]=a,e[2]=c):c=e[2];const h=t?.message||l("chat.decopilot.couldNotFetchModels"),d=" "+l("chat.decopilot.tryAnotherProviderOrRetry");let o;e[3]!==h||e[4]!==d?(o=i.jsxs("p",{className:"text-xs text-muted-foreground max-w-[260px]",children:[h,d]}),e[3]=h,e[4]=d,e[5]=o):o=e[5];let m;e[6]!==c||e[7]!==o?(m=i.jsxs("div",{className:"flex flex-col gap-1",children:[c,o]}),e[6]=c,e[7]=o,e[8]=m):m=e[8];let p;e[9]===Symbol.for("react.memo_cache_sentinel")?(p=i.jsx(It,{className:"size-3.5"}),e[9]=p):p=e[9];const u=l("chat.decopilot.retry");let f;e[10]!==s||e[11]!==u?(f=i.jsx("div",{className:"flex items-center gap-2",children:i.jsxs(oe,{variant:"outline",size:"sm",onClick:s,className:"gap-1.5",children:[p,u]})}),e[10]=s,e[11]=u,e[12]=f):f=e[12];let g;return e[13]!==f||e[14]!==m?(g=i.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center gap-3 px-4 py-8 text-center",children:[r,m,f]}),e[13]=f,e[14]=m,e[15]=g):g=e[15],g}function _s(){const n=U.c(1);let e;return n[0]===Symbol.for("react.memo_cache_sentinel")?(e=i.jsx("div",{className:"flex-1 overflow-y-auto p-2 space-y-1",children:Array.from({length:6}).map(Is)}),n[0]=e):e=n[0],e}function Is(n,e){return i.jsxs("div",{className:"flex items-center gap-2 min-h-8 py-3 px-3 rounded-lg",children:[i.jsx(J,{className:"size-5 shrink-0 rounded-sm"}),i.jsx(J,{className:"flex-1 h-4"}),i.jsx(J,{className:"w-16 h-5 shrink-0 rounded-md"})]},e)}function $e(n){const e=U.c(12),{label:t,models:s,onSelect:l,onHover:r}=n;if(s.length===0)return null;let a;e[0]!==t?(a=i.jsx("div",{className:"text-xs font-medium text-muted-foreground px-3 pt-3 pb-1",children:t}),e[0]=t,e[1]=a):a=e[1];let c;if(e[2]!==s||e[3]!==r||e[4]!==l){let d;e[6]!==r||e[7]!==l?(d=o=>i.jsx("button",{type:"button",onClick:()=>l(o),onFocus:()=>r(o),className:"w-full text-left cursor-pointer",children:i.jsx(ks,{model:o,onHover:r})},o.modelId),e[6]=r,e[7]=l,e[8]=d):d=e[8],c=s.map(d),e[2]=s,e[3]=r,e[4]=l,e[5]=c}else c=e[5];let h;return e[9]!==a||e[10]!==c?(h=i.jsxs("div",{children:[a,c]}),e[9]=a,e[10]=c,e[11]=h):h=e[11],h}function Se(n,e){return e(n==="other"?"chat.decopilot.tierOther":ps[n])}function Cs(n){const e=U.c(21),{model:t,isChecked:s,onToggle:l,onHover:r}=n,[a,c]=$.useState(s);a!==s&&c(s);let h;e[0]!==t?(h=Ce(t),e[0]=t,e[1]=h):h=e[1];const d=h;let o;e[2]!==t||e[3]!==r?(o=()=>r(t),e[2]=t,e[3]=r,e[4]=o):o=e[4];let m;e[5]!==t.modelId||e[6]!==l?(m=()=>{c(Ms),l(t.modelId)},e[5]=t.modelId,e[6]=l,e[7]=m):m=e[7];let p;e[8]!==a||e[9]!==m?(p=i.jsx(ft,{checked:a,onCheckedChange:m}),e[8]=a,e[9]=m,e[10]=p):p=e[10];let u;e[11]!==d||e[12]!==t.title?(u=i.jsx("img",{src:d,className:"w-5 h-5 shrink-0 rounded-sm dark:bg-white dark:rounded-sm dark:p-px",alt:t.title}),e[11]=d,e[12]=t.title,e[13]=u):u=e[13];let f;e[14]!==t.title?(f=i.jsx("span",{className:"text-sm text-foreground flex-1 min-w-0 line-clamp-1",children:t.title}),e[14]=t.title,e[15]=f):f=e[15];let g;return e[16]!==o||e[17]!==p||e[18]!==u||e[19]!==f?(g=i.jsxs("label",{className:"flex items-center gap-3 min-h-8 py-2.5 px-3 hover:bg-accent cursor-pointer rounded-lg",onMouseEnter:o,children:[p,u,f]}),e[16]=o,e[17]=p,e[18]=u,e[19]=f,e[20]=g):g=e[20],g}function Ms(n){return!n}function Es(n,e){const t=[];for(const s of et)if(n[s].length>0){t.push({type:"header",label:Se(s,e)});for(const l of n[s])t.push({type:"model",model:l})}if(n.other.length>0){t.push({type:"header",label:Se("other",e)});for(const s of n.other)t.push({type:"model",model:s})}return t}function Os({items:n,shortlistSet:e,onToggle:t,onHover:s}){const l=$.useRef(null),r=qt({count:n.length,getScrollElement:()=>l.current,estimateSize:a=>n[a]?.type==="header"?36:44,overscan:6});return i.jsx("div",{ref:l,className:"flex-1 overflow-y-auto",children:i.jsx("div",{className:"relative",style:{height:r.getTotalSize()},children:r.getVirtualItems().map(a=>{const c=n[a.index];return c?i.jsx("div",{"data-index":a.index,ref:r.measureElement,className:"absolute left-0 right-0 top-0 px-0.5",style:{transform:`translateY(${a.start}px)`},children:c.type==="header"?i.jsx("div",{className:"text-xs font-medium text-muted-foreground px-3 pt-3 pb-1",children:c.label}):i.jsx(Cs,{model:c.model,isChecked:e.has(c.model.modelId),onToggle:t,onHover:s})},a.key):null})})})}function zs(n){const e=U.c(28),{keyId:t,searchTerm:s,onHover:l,onModelSelect:r,managing:a,onToggleManage:c,filterModels:h}=n,d=ie(),{models:o}=Mt(t),m=h?o.filter(h):o.filter(Et);let p;e[0]!==t?(p=()=>(t?Ss(t):null)??js,e[0]=t,e[1]=p):p=e[1];const[u,f]=$.useState(p),[,g]=$.useTransition();let I;e[2]!==t||e[3]!==g?(I=j=>{t&&g(()=>{f(M=>{const E=new Set(M);return E.has(j)?E.delete(j):E.add(j),Ns(t,E),E})})},e[2]=t,e[3]=g,e[4]=I):I=e[4];const S=I,y=s.toLowerCase().trim(),w=j=>y?j.filter(M=>M.title.toLowerCase().includes(y)||M.modelId.toLowerCase().includes(y)):j;if(a){const j=De(w(m)),M=Es(j,d);let E;e[5]!==u?(E=z=>u.has(z.modelId),e[5]=u,e[6]=E):E=e[6];const R=m.filter(E).length;let A;e[7]===Symbol.for("react.memo_cache_sentinel")?(A=i.jsx(He,{size:14}),e[7]=A):A=e[7];let b;e[8]!==d?(b=d("chat.decopilot.back"),e[8]=d,e[9]=b):b=e[9];let k;return e[10]!==c||e[11]!==b?(k=i.jsxs("button",{type:"button",onClick:c,className:"flex items-center gap-1.5 text-sm text-muted-foreground hover:text-foreground cursor-pointer",children:[A,b]}),e[10]=c,e[11]=b,e[12]=k):k=e[12],i.jsxs("div",{className:"flex-1 flex flex-col overflow-hidden",children:[i.jsxs("div",{className:"flex items-center justify-between px-3 py-2 border-b border-border",children:[k,i.jsx("span",{className:"text-xs text-muted-foreground",children:d("chat.decopilot.selectedCount",{count:R})})]}),i.jsx(Os,{items:M,shortlistSet:u,onToggle:S,onHover:l})]})}const _=De(w(ys(m,u,y)));let C;e[13]!==_||e[14]!==l||e[15]!==r||e[16]!==d?(C=et.map(j=>i.jsx($e,{label:Se(j,d),models:_[j],onSelect:r,onHover:l},j)),e[13]=_,e[14]=l,e[15]=r,e[16]=d,e[17]=C):C=e[17];let N;e[18]!==d?(N=Se("other",d),e[18]=d,e[19]=N):N=e[19];let x;e[20]!==_.other||e[21]!==l||e[22]!==r||e[23]!==N?(x=i.jsx($e,{label:N,models:_.other,onSelect:r,onHover:l}),e[20]=_.other,e[21]=l,e[22]=r,e[23]=N,e[24]=x):x=e[24];let v;return e[25]!==C||e[26]!==x?(v=i.jsxs("div",{className:"flex-1 overflow-y-auto px-0.5 pt-1 [touch-action:pan-y]",children:[C,x]}),e[25]=C,e[26]=x,e[27]=v):v=e[27],v}function ai(){const n=U.c(6);let e;n[0]===Symbol.for("react.memo_cache_sentinel")?(e=i.jsx("div",{className:"border-b border-border h-12 bg-background/95 backdrop-blur sticky top-0 z-10",children:i.jsxs("div",{className:"flex items-center gap-2.5 h-12 px-4",children:[i.jsx(J,{className:"size-4 shrink-0"}),i.jsx(J,{className:"flex-1 h-6"}),i.jsx(J,{className:"w-[140px] h-8 shrink-0"})]})}),n[0]=e):e=n[0];let t;n[1]===Symbol.for("react.memo_cache_sentinel")?(t=i.jsxs("div",{className:"flex-1 flex flex-col md:border-r md:w-[420px] md:min-w-[420px] min-h-0 overflow-hidden",children:[e,i.jsx("div",{className:"flex-1 overflow-y-auto p-2 space-y-1",children:Array.from({length:8}).map(Ps)})]}),n[1]=t):t=n[1];let s;n[2]===Symbol.for("react.memo_cache_sentinel")?(s=i.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[i.jsx(J,{className:"size-6 shrink-0"}),i.jsx(J,{className:"h-6 w-32"})]}),n[2]=s):s=n[2];let l;n[3]===Symbol.for("react.memo_cache_sentinel")?(l=i.jsxs("div",{className:"flex flex-col gap-3 py-2 px-0",children:[s,i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx(J,{className:"h-6 w-20 rounded-md"}),i.jsx(J,{className:"h-6 w-24 rounded-md"})]})]}),n[3]=l):l=n[3];let r;n[4]===Symbol.for("react.memo_cache_sentinel")?(r=i.jsxs("div",{className:"flex flex-col gap-1.5",children:[i.jsx(J,{className:"h-4 w-24"}),i.jsx(J,{className:"h-4 w-32"})]}),n[4]=r):r=n[4];let a;return n[5]===Symbol.for("react.memo_cache_sentinel")?(a=i.jsxs("div",{className:"flex flex-col md:flex-row h-full sm:h-[460px] min-h-0",children:[t,i.jsx("div",{className:"hidden md:block md:w-[320px] md:shrink-0 p-3",children:i.jsxs("div",{className:"flex flex-col gap-3 py-1 px-1.5",children:[l,i.jsxs("div",{className:"flex flex-col gap-4",children:[r,i.jsxs("div",{className:"flex flex-col gap-1.5",children:[i.jsx(J,{className:"h-4 w-16"}),i.jsx(J,{className:"h-4 w-40"})]})]})]})})]}),n[5]=a):a=n[5],a}function Ps(n,e){return i.jsxs("div",{className:"flex items-center gap-2 min-h-8 py-3 px-3 rounded-lg",children:[i.jsx(J,{className:"size-5 shrink-0 rounded-sm"}),i.jsx(J,{className:"flex-1 h-4"}),i.jsx(J,{className:"w-16 h-5 shrink-0 rounded-md"})]},e)}function st(n){const e=U.c(66),{onClose:t,credentialId:s,onCredentialChange:l,selectedModel:r,onModelChange:a,filterModels:c,compact:h}=n,d=ie(),[o,m]=$.useState(null),[p,u]=$.useState(""),[f,g]=$.useState(!1),I=Ie(),S=Ct();let y;e[0]!==I?.providers?(y=Object.fromEntries((I?.providers??[]).map(Ts)),e[0]=I?.providers,e[1]=y):y=e[1];const w=y,_=ht(),{org:C}=be();let N;e[2]!==l?(N=O=>{l(O),m(null)},e[2]=l,e[3]=N):N=e[3];const x=N;let v;e[4]!==s||e[5]!==t||e[6]!==a?(v=O=>{s&&(a(O),u(""),t())},e[4]=s,e[5]=t,e[6]=a,e[7]=v):v=e[7];const j=v;if(S.length===0){const O=!h&&"sm:w-[740px]";let F;e[8]!==O?(F=ge("flex items-center justify-center p-8 w-full",O),e[8]=O,e[9]=F):F=e[9];let K;e[10]===Symbol.for("react.memo_cache_sentinel")?(K=i.jsx(ns,{}),e[10]=K):K=e[10];let D;return e[11]!==F?(D=i.jsx("div",{className:F,children:K}),e[11]=F,e[12]=D):D=e[12],D}const M=h?"sm:h-[420px]":"sm:h-[460px]";let E;e[13]!==M?(E=ge("flex flex-col md:flex-row h-full min-h-0",M),e[13]=M,e[14]=E):E=e[14];const R=h?"w-full":"md:border-r md:w-[420px] md:min-w-[420px]";let A;e[15]!==R?(A=ge("flex-1 flex flex-col min-h-0 overflow-hidden",R),e[15]=R,e[16]=A):A=e[16];let b;e[17]===Symbol.for("react.memo_cache_sentinel")?(b=i.jsx(Ye,{size:16,className:"text-muted-foreground shrink-0"}),e[17]=b):b=e[17];let k;e[18]!==f||e[19]!==d?(k=d(f?"chat.decopilot.searchAllModels":"chat.decopilot.searchForModel"),e[18]=f,e[19]=d,e[20]=k):k=e[20];let z;e[21]===Symbol.for("react.memo_cache_sentinel")?(z=O=>u(O.target.value),e[21]=z):z=e[21];let T;e[22]!==p||e[23]!==k?(T=i.jsx(fe,{autoFocus:!0,type:"text",placeholder:k,value:p,onChange:z,className:"flex-1 min-w-0 border-0 !shadow-none px-0 h-full text-sm placeholder:text-muted-foreground/50 bg-transparent"}),e[22]=p,e[23]=k,e[24]=T):T=e[24];let L;e[25]!==s||e[26]!==x||e[27]!==S||e[28]!==w||e[29]!==d?(L=S.length>0&&i.jsxs(pt,{value:s??"",onValueChange:x,children:[i.jsxs(xt,{size:"sm",className:"w-auto max-w-[140px] h-8 shrink-0 gap-1.5 px-2 [&>svg:last-child]:hidden",onClick:Fs,children:[i.jsx(gt,{placeholder:d("chat.decopilot.key"),children:(()=>{const O=S.find(te=>te.id===s),F=O?w[O.providerId]:void 0,K=ve(O?.presetId),D=K?.logo??F?.logo,B=K?.name??F?.name??O?.providerId??"Key";return i.jsxs("span",{className:"flex items-center gap-1.5 min-w-0",children:[D?i.jsx("img",{src:D,alt:B,className:"w-4 h-4 rounded shrink-0 dark:bg-white dark:rounded-sm dark:p-px"}):i.jsx("div",{className:"w-4 h-4 rounded bg-primary/10 flex items-center justify-center text-xs font-semibold text-primary shrink-0",children:B.slice(0,1).toUpperCase()}),i.jsx("span",{className:"text-xs truncate",children:B})]})})()}),i.jsx(yt,{className:"size-4 opacity-50 shrink-0 pointer-events-none"})]}),i.jsx(vt,{children:S.map(O=>{const F=w[O.providerId],K=ve(O.presetId),D=K?.logo??F?.logo,B=K?.name??F?.name??O.providerId;return i.jsx(bt,{value:O.id,children:i.jsxs("div",{className:"flex items-center gap-2",children:[D?i.jsx("img",{src:D,alt:B,className:"w-4 h-4 rounded dark:bg-white dark:rounded-sm dark:p-px"}):i.jsx("div",{className:"w-4 h-4 rounded bg-primary/10 flex items-center justify-center text-xs font-semibold text-primary",children:B.slice(0,1).toUpperCase()}),i.jsxs("span",{children:[B," — ",O.label]})]})},O.id)})})]}),e[25]=s,e[26]=x,e[27]=S,e[28]=w,e[29]=d,e[30]=L):L=e[30];let W;e[31]!==T||e[32]!==L?(W=i.jsx("div",{className:"border-b border-border h-12 bg-background/95 backdrop-blur sticky top-0 z-10",children:i.jsxs("label",{className:"flex items-center gap-2.5 h-12 px-4 pr-12 md:pr-4 cursor-text",children:[b,T,L]})}),e[31]=T,e[32]=L,e[33]=W):W=e[33];let P;e[34]!==s?(P=O=>{const{error:F,resetError:K}=O;return i.jsx(ws,{error:F,onRetry:K,credentialId:s??void 0})},e[34]=s,e[35]=P):P=e[35];let V;e[36]===Symbol.for("react.memo_cache_sentinel")?(V=i.jsx(_s,{}),e[36]=V):V=e[36];const X=s??void 0;let H;e[37]===Symbol.for("react.memo_cache_sentinel")?(H=()=>g(As),e[37]=H):H=e[37];let q;e[38]!==c||e[39]!==j||e[40]!==f||e[41]!==p||e[42]!==X?(q=i.jsx($.Suspense,{fallback:V,children:i.jsx(zs,{keyId:X,searchTerm:p,onHover:m,onModelSelect:j,managing:f,onToggleManage:H,filterModels:c})}),e[38]=c,e[39]=j,e[40]=f,e[41]=p,e[42]=X,e[43]=q):q=e[43];let Y;e[44]!==s||e[45]!==P||e[46]!==q?(Y=i.jsx(ut,{fallback:P,children:q},s),e[44]=s,e[45]=P,e[46]=q,e[47]=Y):Y=e[47];let ee;e[48]!==f||e[49]!==_||e[50]!==C||e[51]!==d?(ee=!f&&i.jsxs("div",{className:"border-t border-border flex",children:[i.jsxs("button",{type:"button",onClick:()=>$.startTransition(()=>g(!0)),className:"flex items-center gap-2 flex-1 px-4 py-2.5 text-xs text-muted-foreground hover:text-foreground hover:bg-accent cursor-pointer",children:[i.jsx(_t,{className:"size-3.5 shrink-0"}),d("chat.decopilot.manageModels")]}),i.jsx("div",{className:"w-px bg-border shrink-0"}),i.jsxs("button",{type:"button",onClick:()=>_({to:"/$org/settings/ai-providers",params:{org:C.slug}}),className:"flex items-center gap-2 flex-1 px-4 py-2.5 text-xs text-muted-foreground hover:text-foreground hover:bg-accent cursor-pointer",children:[i.jsx(jt,{className:"size-3.5 shrink-0"}),d("chat.decopilot.manageApiKeys")]})]}),e[48]=f,e[49]=_,e[50]=C,e[51]=d,e[52]=ee):ee=e[52];let G;e[53]!==W||e[54]!==Y||e[55]!==ee||e[56]!==A?(G=i.jsxs("div",{className:A,children:[W,Y,ee]}),e[53]=W,e[54]=Y,e[55]=ee,e[56]=A,e[57]=G):G=e[57];let Q;e[58]!==h||e[59]!==o||e[60]!==r?(Q=!h&&i.jsx("div",{className:"hidden md:flex md:flex-col md:w-[320px] md:shrink-0 p-3",children:i.jsx(us,{model:o??r??null})}),e[58]=h,e[59]=o,e[60]=r,e[61]=Q):Q=e[61];let Z;return e[62]!==G||e[63]!==Q||e[64]!==E?(Z=i.jsxs("div",{className:E,children:[G,Q]}),e[62]=G,e[63]=Q,e[64]=E,e[65]=Z):Z=e[65],Z}function As(n){return!n}function Fs(n){return n.stopPropagation()}function Ts(n){return[n.id,n]}function Rs(n){const e=U.c(12),{onClose:t}=n,{credentialId:s,setCredentialId:l,selectedModel:r,setModel:a}=Ot();let c;e[0]!==l?(c=o=>{ne("chat_credential_changed",{credential_id:o}),l(o)},e[0]=l,e[1]=c):c=e[1];let h;e[2]!==s||e[3]!==r?.modelId||e[4]!==a?(h=o=>{s&&(ne("chat_model_changed",{from_model_id:r?.modelId??null,to_model_id:o.modelId,to_model_provider:o.providerId??null,credential_id:s}),a({...o,keyId:s}))},e[2]=s,e[3]=r?.modelId,e[4]=a,e[5]=h):h=e[5];let d;return e[6]!==s||e[7]!==t||e[8]!==r||e[9]!==c||e[10]!==h?(d=i.jsx(st,{onClose:t,credentialId:s,onCredentialChange:c,selectedModel:r,onModelChange:h}),e[6]=s,e[7]=t,e[8]=r,e[9]=c,e[10]=h,e[11]=d):d=e[11],d}function Ks(n){const e=U.c(2),{onClose:t}=n;let s;return e[0]!==t?(s=i.jsx(Rs,{onClose:t}),e[0]=t,e[1]=s):s=e[1],s}function Ls(n){const e=U.c(2);let t;return e[0]!==n?(t=i.jsx(st,{...n}),e[0]=n,e[1]=t):t=e[1],t}function ci(n){const e=U.c(2),{onClose:t}=n;let s;return e[0]!==t?(s=i.jsx(Ks,{onClose:t}),e[0]=t,e[1]=s):s=e[1],s}function di(n){const e=U.c(4);let t;e[0]!==n?({...t}=n,e[0]=n,e[1]=t):t=e[1];let s;return e[2]!==t?(s=i.jsx(Ls,{...t}),e[2]=t,e[3]=s):s=e[3],s}export{is as C,di as M,ns as N,Xe as P,ni as S,ai as a,oi as b,ci as c,ri as g,li as i,Ee as m};