decocms 3.29.1 → 3.30.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (247) hide show
  1. package/dist/client/assets/{AlertCircle-CIkJ_tva.js → AlertCircle-BQLR7I4E.js} +1 -1
  2. package/dist/client/assets/{ArrowUpRight-DjtsYmlk.js → ArrowUpRight-DSaWSvAP.js} +1 -1
  3. package/dist/client/assets/{Check-DZ5PZYLO.js → Check-DCDpfG7m.js} +1 -1
  4. package/dist/client/assets/{CheckCircle-DyJzuYoS.js → CheckCircle-BBK-3Pzt.js} +1 -1
  5. package/dist/client/assets/{ChevronDown-CGeYjJAK.js → ChevronDown-BD0G-h2k.js} +1 -1
  6. package/dist/client/assets/{ChevronLeft-DWiixe45.js → ChevronLeft-DtP_Ayjz.js} +1 -1
  7. package/dist/client/assets/{ChevronRight-Bm_e-tIB.js → ChevronRight-DUzhuedZ.js} +1 -1
  8. package/dist/client/assets/{ChevronUp-BCv26pBY.js → ChevronUp-D5M0geM5.js} +1 -1
  9. package/dist/client/assets/{Container-DNJNU1b4.js → Container-Catp9d2q.js} +1 -1
  10. package/dist/client/assets/{DotsVertical-CqB_Aadi.js → DotsVertical-Dok1GVxI.js} +1 -1
  11. package/dist/client/assets/{Eye-MkeUTfT3.js → Eye-Dmik5hYP.js} +1 -1
  12. package/dist/client/assets/{FilterLines-CfVg89f7.js → FilterLines-C37LaXJ1.js} +1 -1
  13. package/dist/client/assets/{Globe01-xZhhj276.js → Globe01-D1c-3J9t.js} +1 -1
  14. package/dist/client/assets/{HardDrive-CtdIy8yR.js → HardDrive-C1vRZoAn.js} +1 -1
  15. package/dist/client/assets/{Key01-CXIWciFj.js → Key01-CdveS1HN.js} +1 -1
  16. package/dist/client/assets/{LayoutLeft-CJ48TbRA.js → LayoutLeft-Bfxz6P9F.js} +1 -1
  17. package/dist/client/assets/{LinkExternal01-Bi6In-BW.js → LinkExternal01-CxEkPs1F.js} +1 -1
  18. package/dist/client/assets/{Monitor01-CsSfQSQt.js → Monitor01-Bkoa3Nbe.js} +1 -1
  19. package/dist/client/assets/{Palette-CmO3ZuPu.js → Palette-C74Da44y.js} +1 -1
  20. package/dist/client/assets/{Play-CQ97sIka.js → Play-BERjgeke.js} +1 -1
  21. package/dist/client/assets/{Plus-CTho-g8m.js → Plus-CdvauR8B.js} +1 -1
  22. package/dist/client/assets/{RefreshCcw01-D1X4YmG3.js → RefreshCcw01-4ELQWtuB.js} +1 -1
  23. package/dist/client/assets/{SearchMd-BVJBwCEd.js → SearchMd-DvX2rzEB.js} +1 -1
  24. package/dist/client/assets/{Settings02-Cqx4N2is.js → Settings02-Cqwfv4FN.js} +1 -1
  25. package/dist/client/assets/{Shield01-D5OMek_B.js → Shield01-6id4oLiZ.js} +1 -1
  26. package/dist/client/assets/{Star01-4yFjK6bh.js → Star01--MeVNqbA.js} +1 -1
  27. package/dist/client/assets/{Stars01-DWbsIFJF.js → Stars01-C2BTpZeS.js} +1 -1
  28. package/dist/client/assets/{Stars02-BLn35DBB.js → Stars02-D6zEAnUT.js} +1 -1
  29. package/dist/client/assets/{Sun-FelsR2hx.js → Sun-BGVsB7Cm.js} +1 -1
  30. package/dist/client/assets/{SwitchHorizontal01-Bsjx9paN.js → SwitchHorizontal01-DC97OO23.js} +1 -1
  31. package/dist/client/assets/{Tool01-BxT6lP7E.js → Tool01-DQ4cTbeu.js} +1 -1
  32. package/dist/client/assets/{Trash01-BczIIm5v.js → Trash01-Biurgfq6.js} +1 -1
  33. package/dist/client/assets/{Upload01-nIFiyRcG.js → Upload01-B-0o1yeU.js} +1 -1
  34. package/dist/client/assets/{User01-CamUMrWb.js → User01-CZ5ejYDg.js} +1 -1
  35. package/dist/client/assets/{Users01-CgFieXMp.js → Users01-CKNLJr4G.js} +1 -1
  36. package/dist/client/assets/{Users03-DT_R5tz6.js → Users03-CA9cu5qb.js} +1 -1
  37. package/dist/client/assets/{X-CRg5TH_Y.js → X-DlMQL-XM.js} +1 -1
  38. package/dist/client/assets/{XCircle-DkwGk6Y1.js → XCircle-G0WrPq0g.js} +1 -1
  39. package/dist/client/assets/{XClose-D72Lt3NI.js → XClose-LNW85JIs.js} +1 -1
  40. package/dist/client/assets/{Zap-B-Fg7TEp.js → Zap-CbtV6Vvm.js} +1 -1
  41. package/dist/client/assets/{ZapSquare-BqiIusHB.js → ZapSquare-C9LhFrIW.js} +1 -1
  42. package/dist/client/assets/{ZoomOut-zDFXRspK.js → ZoomOut-CImzlj9g.js} +1 -1
  43. package/dist/client/assets/{access-gate-SfXPQWUj.js → access-gate-DR0BZ9Yv.js} +1 -1
  44. package/dist/client/assets/{accordion-DKdXwYYc.js → accordion-CiWkTYYE.js} +1 -1
  45. package/dist/client/assets/add-section-modal-Dv2cxIh1.js +1 -0
  46. package/dist/client/assets/{agent-capabilities-QxThXvgQ.js → agent-capabilities-l_XcUqX-.js} +1 -1
  47. package/dist/client/assets/{agent-icon-C_8D2J-7.js → agent-icon-CjlB-XbA.js} +1 -1
  48. package/dist/client/assets/{agent-icons-DozoyM-L.js → agent-icons-COjGtXRX.js} +1 -1
  49. package/dist/client/assets/{agents-list-C0ILdC1R.js → agents-list-BbpQy40q.js} +1 -1
  50. package/dist/client/assets/ai-providers-YKtufrsd.js +1 -0
  51. package/dist/client/assets/{alert-Csb33_9v.js → alert-DUOzDLz2.js} +1 -1
  52. package/dist/client/assets/{alert-dialog-CbYM4jmz.js → alert-dialog-ZB1-0uWA.js} +1 -1
  53. package/dist/client/assets/app-editor-CFm4rW9v.js +1 -0
  54. package/dist/client/assets/{auth-catchall-tRl-mCnV.js → auth-catchall-p-9cQrp4.js} +1 -1
  55. package/dist/client/assets/{auth-split-layout-CRIa8lnq.js → auth-split-layout-DCQZj1x8.js} +1 -1
  56. package/dist/client/assets/{automation-list-row-DaUVjzEO.js → automation-list-row-1QBzAyda.js} +1 -1
  57. package/dist/client/assets/{automation-runs-ByMFrYpg.js → automation-runs-CbXniThO.js} +1 -1
  58. package/dist/client/assets/{automations-DOHjwNUR.js → automations-DXbm14M-.js} +1 -1
  59. package/dist/client/assets/{avatar-Bf_YMKWh.js → avatar-DdrKHW7Q.js} +1 -1
  60. package/dist/client/assets/{badge-Di1xo__6.js → badge-GxV01_sa.js} +1 -1
  61. package/dist/client/assets/{brand-context-DVFnuzc3.js → brand-context-CckU9jvo.js} +1 -1
  62. package/dist/client/assets/{buckets-BKqAOUQL.js → buckets-BXxpFWbP.js} +1 -1
  63. package/dist/client/assets/{calendar-BvlrJX6s.js → calendar-ndWEDvWe.js} +1 -1
  64. package/dist/client/assets/{capability-load-error-NgXOd2ZO.js → capability-load-error-C1lcmzPk.js} +1 -1
  65. package/dist/client/assets/{card-CWqz0DaV.js → card-B7vNztnP.js} +1 -1
  66. package/dist/client/assets/{chat-context-BoAn6xWM.js → chat-context-Dr8mURNn.js} +1 -1
  67. package/dist/client/assets/{checkbox-C5cEV_DH.js → checkbox-CvlqSsv8.js} +1 -1
  68. package/dist/client/assets/{cli-auth-success-Da-trtdE.js → cli-auth-success-DbBnzJkW.js} +1 -1
  69. package/dist/client/assets/collection-detail-dh1JPTkf.js +1 -0
  70. package/dist/client/assets/{collection-display-button-BAYgV8vn.js → collection-display-button-ByiFEfVE.js} +1 -1
  71. package/dist/client/assets/{collection-search-Bk4YcOKu.js → collection-search-B62hBYcH.js} +1 -1
  72. package/dist/client/assets/{collection-table-wrapper-DRe15D6A.js → collection-table-wrapper-p305Tve_.js} +1 -1
  73. package/dist/client/assets/{collection-tabs-CSSbV4je.js → collection-tabs-BoWbncvo.js} +1 -1
  74. package/dist/client/assets/{collections-CG_8shjq.js → collections-BU-b7Qnp.js} +1 -1
  75. package/dist/client/assets/{command-CFpCNmCF.js → command-DeymMKPH.js} +1 -1
  76. package/dist/client/assets/{connect-desktop-dialog-BIhfHnnr.js → connect-desktop-dialog-B6fCPmnk.js} +1 -1
  77. package/dist/client/assets/{connection-card-B1-pvTAQ.js → connection-card-BdHs3sI8.js} +1 -1
  78. package/dist/client/assets/{connection-detail-Bh5oWdyn.js → connection-detail-1bfT9skO.js} +1 -1
  79. package/dist/client/assets/{connection-form-helpers-oVYdKzFk.js → connection-form-helpers-Cl8WE-Wv.js} +1 -1
  80. package/dist/client/assets/{connections-Dp3XGEkZ.js → connections-CQfywKkf.js} +1 -1
  81. package/dist/client/assets/decopilot-sse-pool-TF6jERkV.js +1 -0
  82. package/dist/client/assets/{dialog-DzWL-NrT.js → dialog-Bug5LYvY.js} +1 -1
  83. package/dist/client/assets/{domain-settings-DJD9U4sU.js → domain-settings-CiVW_jUc.js} +1 -1
  84. package/dist/client/assets/{drawer-BLGCEP9S.js → drawer-Ckfnpw8I.js} +1 -1
  85. package/dist/client/assets/{dropdown-menu-YzbwHIxx.js → dropdown-menu-CggnBdjt.js} +1 -1
  86. package/dist/client/assets/{dynamic-plugin-layout-BB8gWDVj.js → dynamic-plugin-layout-yS0CT9hK.js} +1 -1
  87. package/dist/client/assets/{empty-state-DfOA7oYG.js → empty-state-C6yeON6c.js} +1 -1
  88. package/dist/client/assets/{empty-state-CEcNMd77.js → empty-state-DtTBbW_W.js} +1 -1
  89. package/dist/client/assets/{extract-connection-data-DzgWcXVA.js → extract-connection-data-BR7VTC2M.js} +1 -1
  90. package/dist/client/assets/{features-CIhQ9FPK.js → features-fQ1ChqbW.js} +1 -1
  91. package/dist/client/assets/file-explorer-Bpe6MxXV.js +2 -0
  92. package/dist/client/assets/{file-type-icon-9WcINLx3.js → file-type-icon-Dg4vNCbL.js} +1 -1
  93. package/dist/client/assets/{files-CfinSi-B.js → files-C7GL35WM.js} +1 -1
  94. package/dist/client/assets/{form-DK41bruw.js → form-Bkkvnz-_.js} +1 -1
  95. package/dist/client/assets/{general-BUSEsa-r.js → general-T2AFh9Ye.js} +1 -1
  96. package/dist/client/assets/{generate-id-DOxNmKSl.js → generate-id-DfnWKozM.js} +1 -1
  97. package/dist/client/assets/github-repo-picker-BKJVsWG6.js +4 -0
  98. package/dist/client/assets/{header-tab-button-BDD5kZQa.js → header-tab-button-CfuW1KOG.js} +1 -1
  99. package/dist/client/assets/{hover-card-C0gmU-KR.js → hover-card-7wnR4X6J.js} +1 -1
  100. package/dist/client/assets/{image-field-CNdkpe4-.js → image-field-DsnvgvCV.js} +1 -1
  101. package/dist/client/assets/{index-4CkRjwqB.js → index-BD68Poau.js} +1 -1
  102. package/dist/client/assets/{index-DzNLTQFE.js → index-BDwe75Ed.js} +2 -2
  103. package/dist/client/assets/{index-DdTSg63X.js → index-BL9vKovB.js} +4 -4
  104. package/dist/client/assets/{index-CpG2_v8p.js → index-BjoOIgbb.js} +3 -3
  105. package/dist/client/assets/{index-D-Er7K2V.js → index-C6AFi5aI.js} +1 -1
  106. package/dist/client/assets/{index-CghQMTVW.js → index-CCldjkHi.js} +1 -1
  107. package/dist/client/assets/{index-rP7Vi9h6.js → index-CV7TX6uY.js} +1 -1
  108. package/dist/client/assets/{index-Bw6dLXGR.js → index-C_NDVGp1.js} +1 -1
  109. package/dist/client/assets/index-CoS-DNLH.js +1 -0
  110. package/dist/client/assets/{index-CH6_c02Q.js → index-CvubZqsl.js} +1 -1
  111. package/dist/client/assets/index-DHXKcvHJ.js +1 -0
  112. package/dist/client/assets/{index-Dd5x1Ugx.js → index-Dow8MSuu.js} +1 -1
  113. package/dist/client/assets/{index-B6yJwY9r.js → index-K-cFrJme.js} +1 -1
  114. package/dist/client/assets/{index-Vm79zSBa.js → index-M8U0QO9V.js} +1 -1
  115. package/dist/client/assets/{index-redirect-B5KfXttx.js → index-redirect-CDKs11B5.js} +1 -1
  116. package/dist/client/assets/{index-CRk3na1v.js → index-uM9cBeAz.js} +1 -1
  117. package/dist/client/assets/{infiniteQueryObserver-DKFzmh7N.js → infiniteQueryObserver-DjRZQa58.js} +1 -1
  118. package/dist/client/assets/{input-BWjbzzQM.js → input-CAytkUdm.js} +1 -1
  119. package/dist/client/assets/{integration-icon-Jhe4mXPc.js → integration-icon-BxZqCPgY.js} +1 -1
  120. package/dist/client/assets/{label-BD30ND7M.js → label-_bcDhrPn.js} +1 -1
  121. package/dist/client/assets/{layout-CshuPuNT.js → layout-D6JyUu-W.js} +1 -1
  122. package/dist/client/assets/{login-xvknfGAE.js → login-D_Y894-5.js} +1 -1
  123. package/dist/client/assets/{members-B-0d8UVK.js → members-BiZDHDwm.js} +1 -1
  124. package/dist/client/assets/{monaco-editor-CO97GxVj.js → monaco-editor-DR1buwuA.js} +1 -1
  125. package/dist/client/assets/{monitoring-stats-row-Cfw3-iQJ.js → monitoring-stats-row-BH1n8Qao.js} +1 -1
  126. package/dist/client/assets/{oauth-callback-OP1K2cBS.js → oauth-callback-Bwrh5dBF.js} +1 -1
  127. package/dist/client/assets/{oauth-callback-ai-provider-AV6p2GPf.js → oauth-callback-ai-provider-DnFWhV-5.js} +1 -1
  128. package/dist/client/assets/{onboarding-BydTnX4J.js → onboarding-0pY55b33.js} +1 -1
  129. package/dist/client/assets/{org-install-By9f70v3.js → org-install-CfS-9owX.js} +1 -1
  130. package/dist/client/assets/{org-layout-Cuv0PXEZ.js → org-layout-WjhxFhVG.js} +1 -1
  131. package/dist/client/assets/{org-plugin-layout-D6ftiJr2.js → org-plugin-layout-CBd88Pps.js} +1 -1
  132. package/dist/client/assets/{page-seo-form-D0J4BsJd.js → page-seo-form-DA-M0CRU.js} +1 -1
  133. package/dist/client/assets/page-seo-sheet-BGJM5zp7.js +1 -0
  134. package/dist/client/assets/pair-rWOsLIRO.js +46 -0
  135. package/dist/client/assets/{plugin-empty-state-CTifOpyh.js → plugin-empty-state-BC-cPjsG.js} +1 -1
  136. package/dist/client/assets/{plugin-header-D63WcJTf.js → plugin-header-CZ1sX2n9.js} +1 -1
  137. package/dist/client/assets/{plugin-layout-DIqP9Bzh.js → plugin-layout-egGFGy3C.js} +1 -1
  138. package/dist/client/assets/{popover-w66kr7qI.js → popover-H1IIsqsO.js} +1 -1
  139. package/dist/client/assets/{post-editor-CcNc2iwJ.js → post-editor-D8Amc377.js} +1 -1
  140. package/dist/client/assets/{primitives-CXAphNCy.js → primitives-DXNs_riQ.js} +1 -1
  141. package/dist/client/assets/{profile-DPgEYebY.js → profile-jQNt2qst.js} +1 -1
  142. package/dist/client/assets/project-app-view-CByPW7cJ.js +1 -0
  143. package/dist/client/assets/record-editor-BoDJjFQA.js +1 -0
  144. package/dist/client/assets/registry-aermVrqm.js +2 -0
  145. package/dist/client/assets/{registry-layout-CpOLAjVd.js → registry-layout-CC29q8fz.js} +1 -1
  146. package/dist/client/assets/{require-capability-BJrX_rPe.js → require-capability-g-UPmpGK.js} +1 -1
  147. package/dist/client/assets/{required-auth-layout-CzrHHdU9.js → required-auth-layout-B5sViZsY.js} +1 -1
  148. package/dist/client/assets/{reset-password-XeANzZ8O.js → reset-password-BC3ZM7w0.js} +1 -1
  149. package/dist/client/assets/{resizable-B8hoAXbl.js → resizable-DaIe2JEk.js} +1 -1
  150. package/dist/client/assets/{roles-CfBRlxaX.js → roles-C5M6mJ4v.js} +1 -1
  151. package/dist/client/assets/save-referenced-block-BLu5E_fA.js +1 -0
  152. package/dist/client/assets/{save-status-Ds8Nwo0Y.js → save-status-DaG-SHKI.js} +1 -1
  153. package/dist/client/assets/{schema-form-914BofiG.js → schema-form-BBSGBJV6.js} +1 -1
  154. package/dist/client/assets/{scroll-area-CFrtCBLi.js → scroll-area-7dB1B4gR.js} +1 -1
  155. package/dist/client/assets/{search-input-BXsljctW.js → search-input-DwwxFJsd.js} +1 -1
  156. package/dist/client/assets/{secrets-Dh_eQg6Y.js → secrets-BVqejBQE.js} +1 -1
  157. package/dist/client/assets/{sections-editor-Cy1_wyqm.js → sections-editor-B1P_XWwE.js} +1 -1
  158. package/dist/client/assets/{select-B0qONt_m.js → select-Dn6Da_1F.js} +1 -1
  159. package/dist/client/assets/{select-model-DV1J8lbW.js → select-model-W59Bilmt.js} +1 -1
  160. package/dist/client/assets/seo-editor-CBSOqlcM.js +1 -0
  161. package/dist/client/assets/settings-layout-DypT7z1u.js +1 -0
  162. package/dist/client/assets/{settings-section-ByFuwsko.js → settings-section-BkgYqxH8.js} +1 -1
  163. package/dist/client/assets/{sheet-BlMfZj2L.js → sheet-CxiAY8T5.js} +1 -1
  164. package/dist/client/assets/{shell-controls-URBQR3Oa.js → shell-controls-rZ6L5v7J.js} +1 -1
  165. package/dist/client/assets/{shell-layout-NuYzN-Gn.js → shell-layout-B5B3hmRp.js} +1 -1
  166. package/dist/client/assets/{shell-route-loading-DCVHDrWy.js → shell-route-loading-BURh1jIH.js} +1 -1
  167. package/dist/client/assets/{sidebar-DceLItg8.js → sidebar-CIJpOENy.js} +1 -1
  168. package/dist/client/assets/{skeleton-07IZijZM.js → skeleton-B0e2OkSv.js} +1 -1
  169. package/dist/client/assets/{sortable.esm-CzY2WOGE.js → sortable.esm-B6-kJBUo.js} +1 -1
  170. package/dist/client/assets/{spinner-B8QiOf4h.js → spinner-C2ljLkNd.js} +1 -1
  171. package/dist/client/assets/{sso-CwWhDCFg.js → sso-DutRn6kP.js} +1 -1
  172. package/dist/client/assets/{store-D9gP4byy.js → store-CuKFTdG_.js} +1 -1
  173. package/dist/client/assets/store-registry-CRmNQ4V9.js +2 -0
  174. package/dist/client/assets/{studio-tools-Cly5ZCG3.js → studio-tools-DfxdEEgB.js} +1 -1
  175. package/dist/client/assets/{switch-BJt48css.js → switch-DDGBJlE2.js} +1 -1
  176. package/dist/client/assets/{tab-id-Cgg9_UqF.js → tab-id-TBSp1YxU.js} +6 -6
  177. package/dist/client/assets/{table-3evUHy3g.js → table-GnXYzms9.js} +1 -1
  178. package/dist/client/assets/{tabs-B1x7Fe-S.js → tabs-BajnAGhM.js} +1 -1
  179. package/dist/client/assets/{task-status-F5X71Or6.js → task-status-fWcsMePP.js} +1 -1
  180. package/dist/client/assets/{textarea-CgmDS1mc.js → textarea-JAS7Y9kw.js} +1 -1
  181. package/dist/client/assets/{toggle-group-DVdH8zGh.js → toggle-group-Bv21I6Mc.js} +1 -1
  182. package/dist/client/assets/{toolbar-CXAxzeUh.js → toolbar-CkGflKXn.js} +1 -1
  183. package/dist/client/assets/{tools-list-B226mv7W.js → tools-list-DKrbt2O-.js} +1 -1
  184. package/dist/client/assets/{tooltip-D5r7nYKO.js → tooltip-CKtclZb-.js} +1 -1
  185. package/dist/client/assets/{types-DIAQ40QE.js → types-2N8PTdbg.js} +1 -1
  186. package/dist/client/assets/{use-ai-providers-BMK8G5pd.js → use-ai-providers-CGLipwx3.js} +1 -1
  187. package/dist/client/assets/{use-automations-CqVVjbv4.js → use-automations-BChOAOA6.js} +1 -1
  188. package/dist/client/assets/{use-capability-Dp-xHWqY.js → use-capability-czp9i90U.js} +1 -1
  189. package/dist/client/assets/{use-clock-tick-Dkz_tj-X.js → use-clock-tick-_Fh5zTFQ.js} +1 -1
  190. package/dist/client/assets/{use-collections-dzWuZTM5.js → use-collections-CrAY0KoX.js} +1 -1
  191. package/dist/client/assets/{use-connection-CbBvGv-y.js → use-connection-NiFefepq.js} +1 -1
  192. package/dist/client/assets/{use-copy-CP7WU0J2.js → use-copy-CQfxrmWX.js} +1 -1
  193. package/dist/client/assets/{use-create-virtual-mcp-Dz02gDB8.js → use-create-virtual-mcp-DwKQGNi1.js} +1 -1
  194. package/dist/client/assets/{use-debounced-autosave-7E-JkkEV.js → use-debounced-autosave-DCM6oAgZ.js} +1 -1
  195. package/dist/client/assets/{use-delete-connection-daNvL5F7.js → use-delete-connection-bIYVec_d.js} +1 -1
  196. package/dist/client/assets/{use-file-configs-CzOp0gY1.js → use-file-configs-CqXWCLQv.js} +1 -1
  197. package/dist/client/assets/{use-infinite-scroll-Dz0Ju18S.js → use-infinite-scroll-CNFLUrB_.js} +1 -1
  198. package/dist/client/assets/{use-list-state-Cf00xLLl.js → use-list-state-DRxXstLB.js} +1 -1
  199. package/dist/client/assets/{use-mcp-client-BDuQ-DKr.js → use-mcp-client-B46VYAN_.js} +1 -1
  200. package/dist/client/assets/{use-mcp-prompts-BfczuqQ1.js → use-mcp-prompts-BfYOND3X.js} +1 -1
  201. package/dist/client/assets/{use-mcp-tools-xqS_ta53.js → use-mcp-tools-wPegb5Xs.js} +1 -1
  202. package/dist/client/assets/{use-members-DH5dae5S.js → use-members-DTpTFucv.js} +1 -1
  203. package/dist/client/assets/{use-navigate-to-agent-CLdhXO-i.js → use-navigate-to-agent-DL0_jMva.js} +1 -1
  204. package/dist/client/assets/{use-org-auth-client-BwDW-s0s.js → use-org-auth-client-DFhI1mXp.js} +1 -1
  205. package/dist/client/assets/{use-org-sso-BO0DGPVQ.js → use-org-sso-B2JHlDcL.js} +1 -1
  206. package/dist/client/assets/{use-organization-roles-ZTYugFdP.js → use-organization-roles-Do917bwO.js} +1 -1
  207. package/dist/client/assets/{use-organization-settings-ofRxNgFR.js → use-organization-settings-CGdaVuD7.js} +1 -1
  208. package/dist/client/assets/{use-registry-connections-Clpq_83P.js → use-registry-connections-B7_YY-15.js} +1 -1
  209. package/dist/client/assets/{use-secrets-CjbHuNwC.js → use-secrets-qOLSEePj.js} +1 -1
  210. package/dist/client/assets/use-status-sounds-EA9ENH60.js +1 -0
  211. package/dist/client/assets/{use-view-mode-CjoQ3b4F.js → use-view-mode-C2K6zcu8.js} +1 -1
  212. package/dist/client/assets/{use-virtual-mcp-BOy7A3-I.js → use-virtual-mcp-DHileccV.js} +1 -1
  213. package/dist/client/assets/useInfiniteQuery-vMxng0_U.js +1 -0
  214. package/dist/client/assets/{useRouterState-BIyanAgq.js → useRouterState-93R-QVdz.js} +1 -1
  215. package/dist/client/assets/useSuspenseInfiniteQuery-_hGeqDYv.js +1 -0
  216. package/dist/client/assets/{user-DjbLcTMi.js → user-T0gsPnBH.js} +1 -1
  217. package/dist/client/assets/{view-mode-toggle-DnMmKH1O.js → view-mode-toggle-BvPi1TV1.js} +1 -1
  218. package/dist/client/assets/watch-sse-pool-BSePGeIN.js +1 -0
  219. package/dist/client/assets/{workflow-D0yr6HGh.js → workflow-aar8VltW.js} +1 -1
  220. package/dist/client/assets/workflow-detail-Cyps73VW.js +1 -0
  221. package/dist/client/index.html +1 -1
  222. package/dist/server/cli.js +499 -417
  223. package/dist/server/server.js +275 -275
  224. package/package.json +1 -1
  225. package/dist/client/assets/add-section-modal-rFZJepGX.js +0 -1
  226. package/dist/client/assets/ai-providers-BQNg7G2z.js +0 -1
  227. package/dist/client/assets/app-editor-D3p9xZvL.js +0 -1
  228. package/dist/client/assets/collection-detail-K9T_V-NT.js +0 -1
  229. package/dist/client/assets/create-sse-subscription-BS5983N4.js +0 -1
  230. package/dist/client/assets/decopilot-sse-pool-CJ_QbSiL.js +0 -1
  231. package/dist/client/assets/file-explorer-Dp5sNAMl.js +0 -2
  232. package/dist/client/assets/github-repo-picker-BJ45Iuw_.js +0 -4
  233. package/dist/client/assets/index-CZ9iD_kA.js +0 -1
  234. package/dist/client/assets/index-PP1_jM4a.js +0 -1
  235. package/dist/client/assets/page-seo-sheet-Q7Y1gsuc.js +0 -1
  236. package/dist/client/assets/pair-D1IR0Baq.js +0 -46
  237. package/dist/client/assets/project-app-view-B73O2qLq.js +0 -1
  238. package/dist/client/assets/record-editor-hFUcPDs2.js +0 -1
  239. package/dist/client/assets/registry-CSai7Qf3.js +0 -2
  240. package/dist/client/assets/save-referenced-block-MdHBsKGI.js +0 -1
  241. package/dist/client/assets/seo-editor-xn4RyB29.js +0 -1
  242. package/dist/client/assets/settings-layout-DagPHYsX.js +0 -1
  243. package/dist/client/assets/store-registry-Bu6pBKfc.js +0 -2
  244. package/dist/client/assets/use-status-sounds-BQhIBN31.js +0 -1
  245. package/dist/client/assets/useInfiniteQuery-BA4Q5DOk.js +0 -1
  246. package/dist/client/assets/useSuspenseInfiniteQuery-PHI3OnKC.js +0 -1
  247. package/dist/client/assets/workflow-detail-BCL21zFy.js +0 -1
@@ -1,4 +1,4 @@
1
- import{e5 as se,e as I,j as o,B as te,l as Yt,b5 as Ae,e6 as Gs,r as X,q as oe,c as $,g as Qs,G as Zt,e7 as Nt,e8 as es,o as Ys,v as Zs,e9 as en,ea as tn}from"./index-CpG2_v8p.js";import{D as sn,F as nn,B as on}from"./index-Bw6dLXGR.js";import{h as De,i as rn,u as ae}from"./use-mcp-client-BDuQ-DKr.js";import{a as ts}from"./use-virtual-mcp-BOy7A3-I.js";import{M as Oe}from"./monaco-editor-CO97GxVj.js";import{b as ln,R as zt,a as cn}from"./resizable-B8hoAXbl.js";import{B as le}from"./badge-Di1xo__6.js";import{b as xt,d as ht,c as Ze,a as gt,S as bt}from"./select-B0qONt_m.js";import{S as et}from"./spinner-B8QiOf4h.js";import{V as an}from"./view-mode-toggle-DnMmKH1O.js";import{aj as un,q as dn,i as fn,B as ss,ak as mn,a4 as pn,v as xn,al as ns,aa as hn,O as os,am as gn,an as bn,a6 as ft,ao as jn}from"./agent-icon-C_8D2J-7.js";import{i as rs}from"./Play-CQ97sIka.js";import{b as Sn,a as yn,V as Ge}from"./layout-CshuPuNT.js";import{c as is,b as ls,T as cs,a as as}from"./tooltip-D5r7nYKO.js";import{u as wn,a as vn}from"./use-connection-CbBvGv-y.js";import{u as kt,d as It,b as us}from"./use-mcp-tools-xqS_ta53.js";import{b as Nn,c as kn,e as In,d as _n,a as Cn,D as Tn}from"./dialog-DzWL-NrT.js";import"./index-CH6_c02Q.js";import{N as En,m as $n,n as On,o as Ke,P as Mn,i as Rn,R as Ln,u as zn,p as An,e as At,d as Wn,q as Pn,S as Dn}from"./scroll-area-CFrtCBLi.js";import{S as Fn}from"./index-B6yJwY9r.js";import{H as Vn,a as qn,b as Hn}from"./hover-card-C0gmU-KR.js";import{D as ds,a as fs,b as ms,c as Qe}from"./dropdown-menu-YzbwHIxx.js";import{s as Un}from"./Plus-CTho-g8m.js";import{b as ps}from"./Tool01-BxT6lP7E.js";import{i as Fe}from"./Check-DZ5PZYLO.js";import{s as _t}from"./XClose-D72Lt3NI.js";import{I as Ct}from"./integration-icon-Jhe4mXPc.js";import{A as Kn,c as Bn,a as Xn,b as Jn}from"./accordion-DKdXwYYc.js";import"./index-CghQMTVW.js";import{i as xs}from"./X-CRg5TH_Y.js";import{u as hs,a as Gn}from"./use-collections-dzWuZTM5.js";import{E as gs}from"./empty-state-DfOA7oYG.js";import{c as Qn}from"./create-sse-subscription-BS5983N4.js";import{I as Wt}from"./input-BWjbzzQM.js";const bs=se("Box",[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);const js=se("Braces",[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1",key:"ezmyqa"}],["path",{d:"M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1",key:"e1hn23"}]]);const tt=se("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);const st=se("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);const Yn=se("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);const Ss=se("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);const Zn=se("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);const ys=se("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);const ws=se("File",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}]]);const vs=se("Hash",[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]]);const eo=se("OctagonAlert",[["path",{d:"M12 16h.01",key:"1drbdi"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M15.312 2a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586l-4.688-4.688A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2z",key:"1fd625"}]]);const Ns=se("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);const ks=se("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);const to=se("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);const Is=se("Type",[["polyline",{points:"4 7 4 4 20 4 20 7",key:"1nosan"}],["line",{x1:"9",x2:"15",y1:"20",y2:"20",key:"swin9y"}],["line",{x1:"12",x2:"12",y1:"4",y2:"20",key:"1tx1rr"}]]);function so(t){const e=I.c(15),{onSave:n,onUndo:s,isDirty:i,isSaving:r,saveLabel:l,undoLabel:c}=t,a=l===void 0?"Save":l,u=c===void 0?"Undo":c;if(!i)return null;let d;e[0]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx(un,{size:14}),e[0]=d):d=e[0];let f;e[1]!==r||e[2]!==s||e[3]!==u?(f=o.jsxs(te,{variant:"outline",size:"sm",onClick:s,disabled:r,"aria-label":u,children:[d,u]}),e[1]=r,e[2]=s,e[3]=u,e[4]=f):f=e[4];let m;e[5]!==r?(m=r?o.jsx(Yt,{size:14,className:"animate-spin"}):o.jsx(dn,{size:14}),e[5]=r,e[6]=m):m=e[6];let p;e[7]!==r||e[8]!==n||e[9]!==a||e[10]!==m?(p=o.jsxs(te,{variant:"default",size:"sm",onClick:n,disabled:r,"aria-label":a,children:[m,a]}),e[7]=r,e[8]=n,e[9]=a,e[10]=m,e[11]=p):p=e[11];let x;return e[12]!==f||e[13]!==p?(x=o.jsxs(o.Fragment,{children:[f,p]}),e[12]=f,e[13]=p,e[14]=x):x=e[14],x}const Pt=t=>{let e;const n=new Set,s=(u,d)=>{const f=typeof u=="function"?u(e):u;if(!Object.is(f,e)){const m=e;e=d??(typeof f!="object"||f===null)?f:Object.assign({},e,f),n.forEach(p=>p(e,m))}},i=()=>e,c={setState:s,getState:i,getInitialState:()=>a,subscribe:u=>(n.add(u),()=>n.delete(u))},a=e=t(s,i,c);return c},Tt=(t=>t?Pt(t):Pt),no=t=>t;function jt(t,e=no){const n=Ae.useSyncExternalStore(t.subscribe,Ae.useCallback(()=>e(t.getState()),[t,e]),Ae.useCallback(()=>e(t.getInitialState()),[t,e]));return Ae.useDebugValue(n),n}const oo=t=>{const e=Tt(t),n=s=>jt(e,s);return Object.assign(n,e),n},ro=(t=>oo);function _s(t,e){let n;try{n=t()}catch{return}return{getItem:i=>{var r;const l=a=>a===null?null:JSON.parse(a,void 0),c=(r=n.getItem(i))!=null?r:null;return c instanceof Promise?c.then(l):l(c)},setItem:(i,r)=>n.setItem(i,JSON.stringify(r,void 0)),removeItem:i=>n.removeItem(i)}}const St=t=>e=>{try{const n=t(e);return n instanceof Promise?n:{then(s){return St(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return St(s)(n)}}}},io=(t,e)=>(n,s,i)=>{let r={storage:_s(()=>window.localStorage),partialize:g=>g,version:0,merge:(g,b)=>({...b,...g}),...e},l=!1,c=0;const a=new Set,u=new Set;let d=r.storage;if(!d)return t((...g)=>{console.warn(`[zustand persist middleware] Unable to update item '${r.name}', the given storage is currently unavailable.`),n(...g)},s,i);const f=()=>{const g=r.partialize({...s()});return d.setItem(r.name,{state:g,version:r.version})},m=i.setState;i.setState=(g,b)=>(m(g,b),f());const p=t((...g)=>(n(...g),f()),s,i);i.getInitialState=()=>p;let x;const h=()=>{var g,b;if(!d)return;const S=++c;l=!1,a.forEach(y=>{var j;return y((j=s())!=null?j:p)});const w=((b=r.onRehydrateStorage)==null?void 0:b.call(r,(g=s())!=null?g:p))||void 0;return St(d.getItem.bind(d))(r.name).then(y=>{if(y)if(typeof y.version=="number"&&y.version!==r.version){if(r.migrate){const j=r.migrate(y.state,y.version);return j instanceof Promise?j.then(v=>[!0,v]):[!0,j]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,y.state];return[!1,void 0]}).then(y=>{var j;if(S!==c)return;const[v,N]=y;if(x=r.merge(N,(j=s())!=null?j:p),n(x,!0),v)return f()}).then(()=>{S===c&&(w?.(s(),void 0),x=s(),l=!0,u.forEach(y=>y(x)))}).catch(y=>{S===c&&w?.(void 0,y)})};return i.persist={setOptions:g=>{r={...r,...g},g.storage&&(d=g.storage)},clearStorage:()=>{d?.removeItem(r.name)},getOptions:()=>r,rehydrate:()=>h(),hasHydrated:()=>l,onHydrate:g=>(a.add(g),()=>{a.delete(g)}),onFinishHydration:g=>(u.add(g),()=>{u.delete(g)})},r.skipHydration||h(),x||p},Cs=io,{useSyncExternalStoreWithSelector:lo}=Gs,co=t=>t;function ao(t,e=co,n){const s=lo(t.subscribe,t.getState,t.getInitialState,e,n);return Ae.useDebugValue(s),s}const Dt=t=>Symbol.iterator in t,Ft=t=>"entries"in t,Vt=(t,e)=>{const n=t instanceof Map?t:new Map(t.entries()),s=e instanceof Map?e:new Map(e.entries());if(n.size!==s.size)return!1;for(const[i,r]of n)if(!s.has(i)||!Object.is(r,s.get(i)))return!1;return!0},uo=(t,e)=>{const n=t[Symbol.iterator](),s=e[Symbol.iterator]();let i=n.next(),r=s.next();for(;!i.done&&!r.done;){if(!Object.is(i.value,r.value))return!1;i=n.next(),r=s.next()}return!!i.done&&!!r.done};function fo(t,e){return Object.is(t,e)?!0:typeof t!="object"||t===null||typeof e!="object"||e===null||Object.getPrototypeOf(t)!==Object.getPrototypeOf(e)?!1:Dt(t)&&Dt(e)?Ft(t)&&Ft(e)?Vt(t,e):uo(t,e):Vt({entries:()=>Object.entries(t)},{entries:()=>Object.entries(e)})}function Ts(t,e="Output"){if(!t)return`interface ${e} {}`;function n(r){if(!r||typeof r!="object")return"unknown";const l=r.type;if(Array.isArray(l))return l.map(c=>s(c)).join(" | ");switch(l){case"string":return r.enum?r.enum.map(c=>`"${c}"`).join(" | "):"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";case"array":{const c=r.items;return c?`${n(c)}[]`:"unknown[]"}case"object":return i(r);default:return r.anyOf?r.anyOf.map(n).join(" | "):r.oneOf?r.oneOf.map(n).join(" | "):r.allOf?r.allOf.map(n).join(" & "):"unknown"}}function s(r){switch(r){case"string":return"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";default:return"unknown"}}function i(r){const l=r.properties;if(!l)return"Record<string, unknown>";const c=new Set(r.required||[]);return`{
1
+ import{e5 as se,e as I,j as o,B as te,l as Yt,b5 as Ae,e6 as Gs,r as X,q as oe,c as $,g as Qs,G as Zt,e7 as Nt,e8 as es,o as Ys,v as Zs,e9 as en,ea as tn}from"./index-BjoOIgbb.js";import{D as sn,F as nn,B as on}from"./index-C_NDVGp1.js";import{h as De,i as rn,u as ae}from"./use-mcp-client-B46VYAN_.js";import{a as ts}from"./use-virtual-mcp-DHileccV.js";import{M as Oe}from"./monaco-editor-DR1buwuA.js";import{b as ln,R as zt,a as cn}from"./resizable-DaIe2JEk.js";import{B as le}from"./badge-GxV01_sa.js";import{b as xt,d as ht,c as Ze,a as gt,S as bt}from"./select-Dn6Da_1F.js";import{S as et}from"./spinner-C2ljLkNd.js";import{V as an}from"./view-mode-toggle-BvPi1TV1.js";import{aj as un,q as dn,i as fn,B as ss,ak as mn,a4 as pn,v as xn,al as ns,aa as hn,O as os,am as gn,an as bn,a6 as ft,ao as jn}from"./agent-icon-CjlB-XbA.js";import{i as rs}from"./Play-BERjgeke.js";import{b as Sn,a as yn,V as Ge}from"./layout-D6JyUu-W.js";import{c as is,b as ls,T as cs,a as as}from"./tooltip-CKtclZb-.js";import{u as wn,a as vn}from"./use-connection-NiFefepq.js";import{u as kt,d as It,b as us}from"./use-mcp-tools-wPegb5Xs.js";import{b as Nn,c as kn,e as In,d as _n,a as Cn,D as Tn}from"./dialog-Bug5LYvY.js";import"./index-CvubZqsl.js";import{N as En,m as $n,n as On,o as Ke,P as Mn,i as Rn,R as Ln,u as zn,p as An,e as At,d as Wn,q as Pn,S as Dn}from"./scroll-area-7dB1B4gR.js";import{S as Fn}from"./index-K-cFrJme.js";import{H as Vn,a as qn,b as Hn}from"./hover-card-7wnR4X6J.js";import{D as ds,a as fs,b as ms,c as Qe}from"./dropdown-menu-CggnBdjt.js";import{s as Un}from"./Plus-CdvauR8B.js";import{b as ps}from"./Tool01-DQ4cTbeu.js";import{i as Fe}from"./Check-DCDpfG7m.js";import{s as _t}from"./XClose-LNW85JIs.js";import{I as Ct}from"./integration-icon-BxZqCPgY.js";import{A as Kn,c as Bn,a as Xn,b as Jn}from"./accordion-CiWkTYYE.js";import"./index-CCldjkHi.js";import{i as xs}from"./X-DlMQL-XM.js";import{u as hs,a as Gn}from"./use-collections-CrAY0KoX.js";import{E as gs}from"./empty-state-C6yeON6c.js";import{w as Qn}from"./watch-sse-pool-BSePGeIN.js";import{I as Wt}from"./input-CAytkUdm.js";const bs=se("Box",[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);const js=se("Braces",[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1",key:"ezmyqa"}],["path",{d:"M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1",key:"e1hn23"}]]);const tt=se("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);const st=se("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);const Yn=se("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);const Ss=se("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);const Zn=se("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);const ys=se("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);const ws=se("File",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}]]);const vs=se("Hash",[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]]);const eo=se("OctagonAlert",[["path",{d:"M12 16h.01",key:"1drbdi"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M15.312 2a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586l-4.688-4.688A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2z",key:"1fd625"}]]);const Ns=se("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);const ks=se("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);const to=se("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);const Is=se("Type",[["polyline",{points:"4 7 4 4 20 4 20 7",key:"1nosan"}],["line",{x1:"9",x2:"15",y1:"20",y2:"20",key:"swin9y"}],["line",{x1:"12",x2:"12",y1:"4",y2:"20",key:"1tx1rr"}]]);function so(t){const e=I.c(15),{onSave:n,onUndo:s,isDirty:i,isSaving:r,saveLabel:l,undoLabel:c}=t,a=l===void 0?"Save":l,u=c===void 0?"Undo":c;if(!i)return null;let d;e[0]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx(un,{size:14}),e[0]=d):d=e[0];let f;e[1]!==r||e[2]!==s||e[3]!==u?(f=o.jsxs(te,{variant:"outline",size:"sm",onClick:s,disabled:r,"aria-label":u,children:[d,u]}),e[1]=r,e[2]=s,e[3]=u,e[4]=f):f=e[4];let m;e[5]!==r?(m=r?o.jsx(Yt,{size:14,className:"animate-spin"}):o.jsx(dn,{size:14}),e[5]=r,e[6]=m):m=e[6];let p;e[7]!==r||e[8]!==n||e[9]!==a||e[10]!==m?(p=o.jsxs(te,{variant:"default",size:"sm",onClick:n,disabled:r,"aria-label":a,children:[m,a]}),e[7]=r,e[8]=n,e[9]=a,e[10]=m,e[11]=p):p=e[11];let x;return e[12]!==f||e[13]!==p?(x=o.jsxs(o.Fragment,{children:[f,p]}),e[12]=f,e[13]=p,e[14]=x):x=e[14],x}const Pt=t=>{let e;const n=new Set,s=(u,d)=>{const f=typeof u=="function"?u(e):u;if(!Object.is(f,e)){const m=e;e=d??(typeof f!="object"||f===null)?f:Object.assign({},e,f),n.forEach(p=>p(e,m))}},i=()=>e,c={setState:s,getState:i,getInitialState:()=>a,subscribe:u=>(n.add(u),()=>n.delete(u))},a=e=t(s,i,c);return c},Tt=(t=>t?Pt(t):Pt),no=t=>t;function jt(t,e=no){const n=Ae.useSyncExternalStore(t.subscribe,Ae.useCallback(()=>e(t.getState()),[t,e]),Ae.useCallback(()=>e(t.getInitialState()),[t,e]));return Ae.useDebugValue(n),n}const oo=t=>{const e=Tt(t),n=s=>jt(e,s);return Object.assign(n,e),n},ro=(t=>oo);function _s(t,e){let n;try{n=t()}catch{return}return{getItem:i=>{var r;const l=a=>a===null?null:JSON.parse(a,void 0),c=(r=n.getItem(i))!=null?r:null;return c instanceof Promise?c.then(l):l(c)},setItem:(i,r)=>n.setItem(i,JSON.stringify(r,void 0)),removeItem:i=>n.removeItem(i)}}const St=t=>e=>{try{const n=t(e);return n instanceof Promise?n:{then(s){return St(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return St(s)(n)}}}},io=(t,e)=>(n,s,i)=>{let r={storage:_s(()=>window.localStorage),partialize:g=>g,version:0,merge:(g,b)=>({...b,...g}),...e},l=!1,c=0;const a=new Set,u=new Set;let d=r.storage;if(!d)return t((...g)=>{console.warn(`[zustand persist middleware] Unable to update item '${r.name}', the given storage is currently unavailable.`),n(...g)},s,i);const f=()=>{const g=r.partialize({...s()});return d.setItem(r.name,{state:g,version:r.version})},m=i.setState;i.setState=(g,b)=>(m(g,b),f());const p=t((...g)=>(n(...g),f()),s,i);i.getInitialState=()=>p;let x;const h=()=>{var g,b;if(!d)return;const S=++c;l=!1,a.forEach(y=>{var j;return y((j=s())!=null?j:p)});const w=((b=r.onRehydrateStorage)==null?void 0:b.call(r,(g=s())!=null?g:p))||void 0;return St(d.getItem.bind(d))(r.name).then(y=>{if(y)if(typeof y.version=="number"&&y.version!==r.version){if(r.migrate){const j=r.migrate(y.state,y.version);return j instanceof Promise?j.then(v=>[!0,v]):[!0,j]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,y.state];return[!1,void 0]}).then(y=>{var j;if(S!==c)return;const[v,N]=y;if(x=r.merge(N,(j=s())!=null?j:p),n(x,!0),v)return f()}).then(()=>{S===c&&(w?.(s(),void 0),x=s(),l=!0,u.forEach(y=>y(x)))}).catch(y=>{S===c&&w?.(void 0,y)})};return i.persist={setOptions:g=>{r={...r,...g},g.storage&&(d=g.storage)},clearStorage:()=>{d?.removeItem(r.name)},getOptions:()=>r,rehydrate:()=>h(),hasHydrated:()=>l,onHydrate:g=>(a.add(g),()=>{a.delete(g)}),onFinishHydration:g=>(u.add(g),()=>{u.delete(g)})},r.skipHydration||h(),x||p},Cs=io,{useSyncExternalStoreWithSelector:lo}=Gs,co=t=>t;function ao(t,e=co,n){const s=lo(t.subscribe,t.getState,t.getInitialState,e,n);return Ae.useDebugValue(s),s}const Dt=t=>Symbol.iterator in t,Ft=t=>"entries"in t,Vt=(t,e)=>{const n=t instanceof Map?t:new Map(t.entries()),s=e instanceof Map?e:new Map(e.entries());if(n.size!==s.size)return!1;for(const[i,r]of n)if(!s.has(i)||!Object.is(r,s.get(i)))return!1;return!0},uo=(t,e)=>{const n=t[Symbol.iterator](),s=e[Symbol.iterator]();let i=n.next(),r=s.next();for(;!i.done&&!r.done;){if(!Object.is(i.value,r.value))return!1;i=n.next(),r=s.next()}return!!i.done&&!!r.done};function fo(t,e){return Object.is(t,e)?!0:typeof t!="object"||t===null||typeof e!="object"||e===null||Object.getPrototypeOf(t)!==Object.getPrototypeOf(e)?!1:Dt(t)&&Dt(e)?Ft(t)&&Ft(e)?Vt(t,e):uo(t,e):Vt({entries:()=>Object.entries(t)},{entries:()=>Object.entries(e)})}function Ts(t,e="Output"){if(!t)return`interface ${e} {}`;function n(r){if(!r||typeof r!="object")return"unknown";const l=r.type;if(Array.isArray(l))return l.map(c=>s(c)).join(" | ");switch(l){case"string":return r.enum?r.enum.map(c=>`"${c}"`).join(" | "):"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";case"array":{const c=r.items;return c?`${n(c)}[]`:"unknown[]"}case"object":return i(r);default:return r.anyOf?r.anyOf.map(n).join(" | "):r.oneOf?r.oneOf.map(n).join(" | "):r.allOf?r.allOf.map(n).join(" & "):"unknown"}}function s(r){switch(r){case"string":return"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";default:return"unknown"}}function i(r){const l=r.properties;if(!l)return"Record<string, unknown>";const c=new Set(r.required||[]);return`{
2
2
  ${Object.entries(l).map(([u,d])=>{const f=c.has(u)?"":"?";return`${d.description?` /** ${d.description} */
3
3
  `:""} ${u}${f}: ${n(d)};`}).join(`
4
4
  `)}
@@ -23,4 +23,4 @@ export default async function(stepInput: Input): Promise<Output> {
23
23
  return {
24
24
  result: stepInput,
25
25
  };
26
- }`;s(n.name,{action:{...n.action,transformCode:_}}),l(mi)},e[2]=m,e[3]=n.action,e[4]=n.name,e[5]=s,e[6]=p):p=e[6];const x=p;let h;e[7]!==n.action||e[8]!==n.name||e[9]!==s?(h=(k,_)=>{s(n.name,{action:{...n.action,transformCode:k},..._?{outputSchema:_}:{}})},e[7]=n.action,e[8]=n.name,e[9]=s,e[10]=h):h=e[10];const g=h;if("code"in n.action&&n.action.code)return null;const b=r?"flex-1 min-h-0 overflow-hidden":"shrink-0";let S;e[11]!==b?(S=$("flex flex-col flex-1 min-h-0 overflow-hidden border-b border-border",b),e[11]=b,e[12]=S):S=e[12];let w;e[13]===Symbol.for("react.memo_cache_sentinel")?(w=o.jsx("h3",{className:"text-sm font-medium text-muted-foreground",children:"Transform Code"}),e[13]=w):w=e[13];let y;e[14]!==r?(y=o.jsxs("div",{className:"flex items-center justify-between",children:[w,r?o.jsx(st,{size:14,className:"text-muted-foreground"}):o.jsx(tt,{size:14,className:"text-muted-foreground"})]}),e[14]=r,e[15]=y):y=e[15];let j;e[16]!==y||e[17]!==x?(j=o.jsx("div",{className:"p-5 shrink-0 cursor-pointer hover:bg-accent/50 transition-colors",onClick:x,children:y}),e[16]=y,e[17]=x,e[18]=j):j=e[18];let v;e[19]!==g||e[20]!==r||e[21]!==n.name||e[22]!==i||e[23]!==d?(v=r&&o.jsx("div",{className:"flex-1 min-h-0",children:o.jsx(Oe,{code:d,language:"typescript",readOnly:i!==void 0,onSave:g,height:"100%"},`transform-code-${n.name}-${i}`)}),e[19]=g,e[20]=r,e[21]=n.name,e[22]=i,e[23]=d,e[24]=v):v=e[24];let N;return e[25]!==S||e[26]!==j||e[27]!==v?(N=o.jsxs("div",{className:S,children:[j,v]}),e[25]=S,e[26]=j,e[27]=v,e[28]=N):N=e[28],N}function mi(t){return!t}function pi(t){return!t}function xi(t){const e=I.c(25),{step:n}=t,[s,i]=X.useState(!1),{updateStep:r}=ne(),l=ue(),c="code"in n.action&&n.action.code?n.action.code:null,a=Y();if(!c)return null;let u;e[0]!==n.action||e[1]!==n.name||e[2]!==r?(u=(m,p)=>{r(n.name,{action:{...n.action,code:m},...p?{outputSchema:p}:{}})},e[0]=n.action,e[1]=n.name,e[2]=r,e[3]=u):u=e[3];const d=u;let f;if(e[4]!==c||e[5]!==d||e[6]!==s||e[7]!==n.action||e[8]!==n.input||e[9]!==n.name||e[10]!==a||e[11]!==r||e[12]!==l.input_schema||e[13]!==l.steps){const m=[],p=l.input_schema;p&&m.push({name:"input",label:"Workflow Input",schema:p});for(const N of l.steps){if(N.name===n.name)break;m.push({name:N.name,label:N.name,schema:N.outputSchema})}const x=n.input??{},h=new Set(Object.entries(x).filter(gi).map(hi)),g=N=>{const k={...x};if(h.has(N)){const R=Object.entries(k).find(O=>{const[,P]=O;return P===`@${N}`})?.[0];R&&delete k[R]}else k[N]=`@${N}`;const _={};for(const[R,O]of Object.entries(k)){if(typeof O!="string"||!O.startsWith("@"))continue;const P=O.slice(1),D=m.find(L=>L.name===P);D?.schema&&(_[R]=D.schema)}const T=Object.keys(_).length>0?{type:"object",properties:_,required:Object.keys(_)}:null,W=T?Ts(T,"Input"):"interface Input {}",A=n.action,C=Es(A.code,W);r(n.name,{input:k,action:{...n.action,code:C}})},b=s?"flex-1 min-h-0 overflow-hidden":"shrink-0";let S;e[15]!==b?(S=$("flex flex-col border-b border-border",b),e[15]=b,e[16]=S):S=e[16];let w;e[17]!==s?(w=()=>i(!s),e[17]=s,e[18]=w):w=e[18];let y;e[19]===Symbol.for("react.memo_cache_sentinel")?(y=o.jsx("h3",{className:"text-sm font-medium text-muted-foreground",children:"Step Code"}),e[19]=y):y=e[19];let j;e[20]!==s?(j=o.jsxs("div",{className:"flex items-center justify-between",children:[y,s?o.jsx(st,{size:14,className:"text-muted-foreground"}):o.jsx(tt,{size:14,className:"text-muted-foreground"})]}),e[20]=s,e[21]=j):j=e[21];let v;e[22]!==w||e[23]!==j?(v=o.jsx("div",{className:"p-5 shrink-0 cursor-pointer hover:bg-accent/50 transition-colors",onClick:w,children:j}),e[22]=w,e[23]=j,e[24]=v):v=e[24],f=o.jsxs("div",{className:S,children:[v,s&&o.jsxs(o.Fragment,{children:[!a&&m.length>0&&o.jsxs("div",{className:"px-5 pb-3 shrink-0 border-b border-border/50",children:[o.jsxs("p",{className:"text-xs text-muted-foreground mb-2",children:["Select variables available to your code as"," ",o.jsx("code",{className:"text-[11px] bg-accent px-1 py-0.5 rounded",children:"input"}),":"]}),o.jsx("div",{className:"flex flex-wrap gap-1.5",children:m.map(N=>{const k=h.has(N.name);return o.jsxs("button",{type:"button",className:$("h-7 px-2.5 text-xs font-medium rounded-lg border transition-colors inline-flex items-center gap-1.5",k?"bg-accent border-border text-foreground":"bg-transparent border-transparent text-muted-foreground hover:bg-accent/50 hover:text-foreground"),onClick:()=>g(N.name),children:[k&&o.jsx(Fe,{size:12,className:"text-success"}),o.jsxs("span",{className:"font-mono",children:["@",N.name]})]},N.name)})})]}),o.jsx("div",{className:"flex-1 min-h-0",children:o.jsx(Oe,{onSave:(N,k)=>d(N,k),code:c,language:"typescript",height:"100%",readOnly:a!==void 0},`step-code-${n.name}-${a}`)})]})]}),e[4]=c,e[5]=d,e[6]=s,e[7]=n.action,e[8]=n.input,e[9]=n.name,e[10]=a,e[11]=r,e[12]=l.input_schema,e[13]=l.steps,e[14]=f}else f=e[14];return f}function hi(t){const[,e]=t;return e.slice(1)}function gi(t){const[,e]=t;return typeof e=="string"&&e.startsWith("@")}function Je(t){if(Array.isArray(t.type))return t.type.map(n=>Je({...t,type:n})).join(" | ");switch(t.type){case"string":return"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"array":return t.items?`${Je(t.items)}[]`:"unknown[]";case"object":return t.properties?`{ ${Object.entries(t.properties).map(([s,i])=>{const r=Je(i),l=!t.required?.includes(s);return`${s}${l?"?":""}: ${r}`}).join("; ")} }`:"Record<string, unknown>";case"null":return"null";default:return"unknown"}}function bi(t){const{status:e}=t,n=(t.completed_steps?.error?.length??0)>0;if(e==="success"&&n)return o.jsxs(le,{variant:"warning",className:"gap-1",children:[o.jsx(Zs,{size:11}),"Partial"]});switch(e){case"success":return o.jsxs(le,{variant:"success",className:"gap-1",children:[o.jsx(Fe,{size:11}),"Success"]});case"error":case"failed":return o.jsxs(le,{variant:"destructive",className:"gap-1",children:[o.jsx(ns,{size:11}),"Error"]});case"running":return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(ft,{size:11}),"Running"]});case"enqueued":return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(ft,{size:11}),"On hold"]});case"cancelled":return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(xs,{size:11}),"Cancelled"]});default:return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(ft,{size:11}),e]})}}function ji(t){return`Run #${t.slice(-4).toUpperCase()}`}function Si(t){const e=I.c(21),{className:n}=t,{executions:s,isLoading:i}=Io(),{setShowExecutionsList:r}=Et(),{setTrackingExecutionId:l}=ne(),c=Y();let a;e[0]!==l?(a=w=>{l(w)},e[0]=l,e[1]=a):a=e[1];const u=a;let d;e[2]!==r?(d=()=>{r(!1)},e[2]=r,e[3]=d):d=e[3];const f=d;let m;e[4]!==n?(m=$("flex flex-col h-full bg-sidebar border-l border-border",n),e[4]=n,e[5]=m):m=e[5];let p;e[6]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsx("p",{className:"flex-1 text-base font-medium text-foreground",children:"Runs"}),e[6]=p):p=e[6];let x;e[7]===Symbol.for("react.memo_cache_sentinel")?(x=o.jsx(xs,{size:11}),e[7]=x):x=e[7];let h;e[8]!==f?(h=o.jsxs("div",{className:"flex items-center h-12 px-5 border-b border-border shrink-0",children:[p,o.jsx(te,{variant:"ghost",size:"icon",className:"size-7",onClick:f,children:x})]}),e[8]=f,e[9]=h):h=e[9];let g;e[10]!==s||e[11]!==u||e[12]!==i||e[13]!==c?(g=i?o.jsx("div",{className:"flex items-center justify-center h-full text-sm text-muted-foreground",children:"Loading executions..."}):s.map((w,y)=>o.jsx(yi,{execution:w,isSelected:w.id===c,isFirst:y===0,onSelect:()=>u(w.id)},w.id)),e[10]=s,e[11]=u,e[12]=i,e[13]=c,e[14]=g):g=e[14];let b;e[15]!==g?(b=o.jsx("div",{className:"flex-1 overflow-auto",children:g}),e[15]=g,e[16]=b):b=e[16];let S;return e[17]!==m||e[18]!==h||e[19]!==b?(S=o.jsxs("div",{className:m,children:[h,b]}),e[17]=m,e[18]=h,e[19]=b,e[20]=S):S=e[20],S}function yi(t){const e=I.c(17),{execution:n,isSelected:s,isFirst:i,onSelect:r}=t,l=s&&"bg-accent/50",c=i&&s&&"bg-accent/50",a=!s&&"hover:bg-accent/30";let u;e[0]!==l||e[1]!==c||e[2]!==a?(u=$("flex flex-col justify-center h-[60px] px-4 border-b border-border cursor-pointer transition-colors",l,c,a),e[0]=l,e[1]=c,e[2]=a,e[3]=u):u=e[3];let d;e[4]!==n?(d=bi(n),e[4]=n,e[5]=d):d=e[5];let f;e[6]!==n.id?(f=ji(n.id),e[6]=n.id,e[7]=f):f=e[7];let m;e[8]!==f?(m=o.jsx("p",{className:"flex-1 text-base font-medium text-foreground",children:f}),e[8]=f,e[9]=m):m=e[9];let p;e[10]!==d||e[11]!==m?(p=o.jsxs("div",{className:"flex items-center gap-2 w-full",children:[d,m]}),e[10]=d,e[11]=m,e[12]=p):p=e[12];let x;return e[13]!==r||e[14]!==u||e[15]!==p?(x=o.jsx("div",{className:u,onClick:r,children:p}),e[13]=r,e[14]=u,e[15]=p,e[16]=x):x=e[16],x}const wi=["workflow.execution.created","workflow.execution.resumed","workflow.step.execute","workflow.step.completed"],vi=Qn({buildUrl:t=>`/api/${encodeURIComponent(t)}/watch?types=workflow.*`,eventTypes:wi}),Ni=["COLLECTION_WORKFLOW_EXECUTION_LIST","COLLECTION_WORKFLOW_EXECUTION_GET","COLLECTION_WORKFLOW_EXECUTION_GET_STEP_RESULT"],ki=500,Pe=new Map,We=new Map;function Ii(t){const e=We.get(t);if(e)for(const n of e)n.invalidateQueries({predicate:s=>s.queryKey.some(i=>typeof i=="string"&&Ni.includes(i))})}function _i(t){Pe.has(t)||Pe.set(t,setTimeout(()=>{Pe.delete(t),Ii(t)},ki))}const Jt=()=>0;function Ci(){const t=I.c(4),{org:e}=oe(),n=Zt(),s=e.id,i=e.slug;let r;t[0]!==s||t[1]!==i||t[2]!==n?(r=c=>{let a=We.get(s);a||(a=new Set,We.set(s,a)),a.add(n);const u=()=>{_i(s),c()},d=vi.subscribe(i,u);return()=>{d(),a.delete(n),a.size===0&&We.delete(s);const f=Pe.get(s);f&&!We.has(s)&&(clearTimeout(f),Pe.delete(s))}},t[0]=s,t[1]=i,t[2]=n,t[3]=r):r=t[3];const l=r;X.useSyncExternalStore(l,Jt,Jt)}const Gt=[{value:"string",label:"String"},{value:"number",label:"Number"},{value:"integer",label:"Integer"},{value:"boolean",label:"Boolean"},{value:"object",label:"Object"},{value:"array",label:"Array"}],Ti={type:"object",properties:{field:{type:"string",description:"An input field"}},required:["field"]},Ei=2;function $i(t){const e=I.c(66),{className:n}=t,s=ue(),{setWorkflow:i}=ne(),[r,l]=X.useState("visual"),[c,a]=X.useState(!1);let u;e[0]===Symbol.for("react.memo_cache_sentinel")?(u={},e[0]=u):u=e[0];const[d,f]=X.useState(u),m=s.input_schema??null;let p;e[1]!==i||e[2]!==s?(p=M=>{i({...s,input_schema:M})},e[1]=i,e[2]=s,e[3]=p):p=e[3];const x=p;let h;e[4]!==x?(h=M=>{try{const J=JSON.parse(M);x(J)}catch{}},e[4]=x,e[5]=h):h=e[5];const g=h;let b;e[6]!==x?(b=()=>{x(Ti)},e[6]=x,e[7]=b):b=e[7];const S=b;let w;e[8]!==x?(w=()=>{x(void 0)},e[8]=x,e[9]=w):w=e[9];const y=w;if(!m){let M;e[10]!==n?(M=$("flex flex-col h-full bg-sidebar",n),e[10]=n,e[11]=M):M=e[11];let J;e[12]===Symbol.for("react.memo_cache_sentinel")?(J=o.jsx(Qt,{}),e[12]=J):J=e[12];let Q;e[13]===Symbol.for("react.memo_cache_sentinel")?(Q=o.jsx("p",{className:"text-sm text-muted-foreground",children:"No input schema defined. Add one to require structured input when running this workflow."}),e[13]=Q):Q=e[13];let E;e[14]===Symbol.for("react.memo_cache_sentinel")?(E=o.jsx(Ns,{size:14}),e[14]=E):E=e[14];let z;e[15]!==S?(z=o.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center gap-3 p-8 text-center",children:[Q,o.jsxs(te,{variant:"outline",size:"sm",className:"gap-2",onClick:S,children:[E,"Add input schema"]})]}),e[15]=S,e[16]=z):z=e[16];let ee;return e[17]!==z||e[18]!==M?(ee=o.jsxs("div",{className:M,children:[J,z]}),e[17]=z,e[18]=M,e[19]=ee):ee=e[19],ee}let j;e[20]!==n?(j=$("flex flex-col h-full bg-sidebar",n),e[20]=n,e[21]=j):j=e[21];const v=r==="visual"?"bg-accent text-foreground":"text-muted-foreground hover:text-foreground";let N;e[22]!==v?(N=$("h-6 px-2 rounded text-xs font-medium transition-colors",v),e[22]=v,e[23]=N):N=e[23];let k,_;e[24]===Symbol.for("react.memo_cache_sentinel")?(_=()=>l("visual"),k=o.jsx(jn,{size:12}),e[24]=k,e[25]=_):(k=e[24],_=e[25]);let T;e[26]!==N?(T=o.jsx("button",{type:"button",className:N,onClick:_,children:k}),e[26]=N,e[27]=T):T=e[27];const W=r==="code"?"bg-accent text-foreground":"text-muted-foreground hover:text-foreground";let A;e[28]!==W?(A=$("h-6 px-2 rounded text-xs font-medium transition-colors",W),e[28]=W,e[29]=A):A=e[29];let C,R;e[30]===Symbol.for("react.memo_cache_sentinel")?(C=()=>l("code"),R=o.jsx(ss,{size:12}),e[30]=C,e[31]=R):(C=e[30],R=e[31]);let O;e[32]!==A?(O=o.jsx("button",{type:"button",className:A,onClick:C,children:R}),e[32]=A,e[33]=O):O=e[33];let P;e[34]!==T||e[35]!==O?(P=o.jsx(Qt,{children:o.jsxs("div",{className:"flex items-center gap-1 border border-border rounded-lg p-0.5",children:[T,O]})}),e[34]=T,e[35]=O,e[36]=P):P=e[36];let D;e[37]!==g||e[38]!==m||e[39]!==x||e[40]!==r||e[41]!==s.id?(D=r==="visual"?o.jsx(o.Fragment,{children:o.jsx("div",{className:"flex-1 overflow-auto",children:o.jsx(vt,{schema:m,onChange:M=>x(M),depth:0})})}):o.jsx("div",{className:"flex-1 min-h-0",children:o.jsx(Oe,{code:JSON.stringify(m,null,2),language:"json",height:"100%",onSave:g},`input-schema-${s.id}`)}),e[37]=g,e[38]=m,e[39]=x,e[40]=r,e[41]=s.id,e[42]=D):D=e[42];let L;e[43]!==c?(L=()=>a(!c),e[43]=c,e[44]=L):L=e[44];let F;e[45]===Symbol.for("react.memo_cache_sentinel")?(F=o.jsx("span",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wider",children:"Preview"}),e[45]=F):F=e[45];let H;e[46]!==c?(H=c?o.jsx(st,{size:14,className:"text-muted-foreground"}):o.jsx(tt,{size:14,className:"text-muted-foreground"}),e[46]=c,e[47]=H):H=e[47];let G;e[48]!==L||e[49]!==H?(G=o.jsxs("button",{type:"button",className:"w-full px-5 py-3 flex items-center justify-between hover:bg-accent/50 transition-colors",onClick:L,children:[F,H]}),e[48]=L,e[49]=H,e[50]=G):G=e[50];let B;e[51]!==m||e[52]!==d||e[53]!==c?(B=c&&o.jsx("div",{className:"px-5 pb-4 max-h-64 overflow-auto",children:o.jsx(Ot,{inputSchema:m,inputParams:d,setInputParams:f,mentions:[]})}),e[51]=m,e[52]=d,e[53]=c,e[54]=B):B=e[54];let V;e[55]!==G||e[56]!==B?(V=o.jsxs("div",{className:"shrink-0 border-t border-border",children:[G,B]}),e[55]=G,e[56]=B,e[57]=V):V=e[57];let q;e[58]!==y?(q=o.jsx("div",{className:"px-5 py-3 shrink-0 border-t border-border",children:o.jsx("button",{type:"button",className:"text-xs text-muted-foreground hover:text-destructive transition-colors",onClick:y,children:"Remove input schema"})}),e[58]=y,e[59]=q):q=e[59];let U;return e[60]!==P||e[61]!==D||e[62]!==V||e[63]!==q||e[64]!==j?(U=o.jsxs("div",{className:j,children:[P,D,V,q]}),e[60]=P,e[61]=D,e[62]=V,e[63]=q,e[64]=j,e[65]=U):U=e[65],U}function Qt(t){const e=I.c(4),{children:n}=t;let s,i;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=o.jsx(os,{className:"w-4 h-4 text-muted-foreground shrink-0"}),i=o.jsx("span",{className:"text-base font-medium text-foreground flex-1",children:"Workflow Input"}),e[0]=s,e[1]=i):(s=e[0],i=e[1]);let r;return e[2]!==n?(r=o.jsxs("div",{className:"border-b border-border p-5 shrink-0 flex items-center gap-2",children:[s,i,n]}),e[2]=n,e[3]=r):r=e[3],r}function vt({schema:t,onChange:e,depth:n}){const s=t.properties??{},i=t.required??[],r=()=>{const f=Object.keys(s);let m="field",p=1;for(;f.includes(m);)m=`field_${p}`,p++;e({...t,properties:{...s,[m]:{type:"string"}},required:[...i,m]})},l=f=>{const{[f]:m,...p}=s;e({...t,properties:p,required:i.filter(x=>x!==f)})},c=(f,m)=>{e({...t,properties:{...s,[f]:m}})},a=(f,m)=>{if(!m.trim()||m===f||s[m])return;const p={};for(const[x,h]of Object.entries(s))p[x===f?m:x]=h;e({...t,properties:p,required:i.map(x=>x===f?m:x)})},u=f=>{const m=i.includes(f);e({...t,required:m?i.filter(p=>p!==f):[...i,f]})},d=Object.entries(s);return o.jsxs("div",{children:[d.length===0&&n===0&&o.jsx("div",{className:"p-5 text-sm text-muted-foreground text-center",children:"No fields defined yet."}),o.jsx("div",{className:"divide-y divide-border",children:d.map(([f,m])=>o.jsx(Oi,{name:f,schema:m,isRequired:i.includes(f),depth:n,onRename:p=>a(f,p),onUpdate:p=>c(f,p),onToggleRequired:()=>u(f),onRemove:()=>l(f)},f))}),o.jsx("div",{className:$("p-3",n>0&&"pb-1"),children:o.jsxs(te,{variant:"outline",size:"sm",className:"w-full gap-2",onClick:r,children:[o.jsx(Ns,{size:14}),"Add field"]})})]})}function Oi(t){const e=I.c(72),{name:n,schema:s,isRequired:i,depth:r,onRename:l,onUpdate:c,onToggleRequired:a,onRemove:u}=t,[d,f]=X.useState(!1),[m,p]=X.useState(n),x=s.type??"string",h=x==="array",g=x==="object",b=r<Ei;let S;e[0]!==m||e[1]!==n||e[2]!==l?(S=()=>{f(!1),m.trim()&&m!==n?l(m.trim()):p(n)},e[0]=m,e[1]=n,e[2]=l,e[3]=S):S=e[3];const w=S;let y;e[4]!==b||e[5]!==c||e[6]!==s.description||e[7]!==s.items||e[8]!==s.properties||e[9]!==s.required?(y=E=>{const z={type:E};s.description&&(z.description=s.description),E==="array"&&(z.items=s.items??{type:"string"}),E==="object"&&b&&(z.properties=s.properties??{},z.required=s.required??[]),c(z)},e[4]=b,e[5]=c,e[6]=s.description,e[7]=s.items,e[8]=s.properties,e[9]=s.required,e[10]=y):y=e[10];const j=y;let v;e[11]!==c||e[12]!==s?(v=E=>{const z={...s};E?z.description=E:delete z.description,c(z)},e[11]=c,e[12]=s,e[13]=v):v=e[13];const N=v;let k;e[14]!==b||e[15]!==c||e[16]!==s?(k=E=>{const z={type:E};E==="object"&&b&&(z.properties=s.items?.properties??{},z.required=s.items?.required??[]),c({...s,items:z})},e[14]=b,e[15]=c,e[16]=s,e[17]=k):k=e[17];const _=k,T=r>0&&"py-3";let W;e[18]!==T?(W=$("flex flex-col gap-2 p-4",T),e[18]=T,e[19]=W):W=e[19];let A;e[20]!==w||e[21]!==m||e[22]!==d||e[23]!==n?(A=d?o.jsx(Wt,{value:m,onChange:E=>p(E.target.value),onBlur:w,onKeyDown:E=>{E.key==="Enter"&&w(),E.key==="Escape"&&(p(n),f(!1))},className:"h-7 text-sm font-medium flex-1 min-w-0",autoFocus:!0}):o.jsx("button",{type:"button",className:"text-sm font-medium text-foreground flex-1 text-left truncate hover:underline cursor-text min-w-0",onClick:()=>{p(n),f(!0)},children:n}),e[20]=w,e[21]=m,e[22]=d,e[23]=n,e[24]=A):A=e[24];let C;e[25]===Symbol.for("react.memo_cache_sentinel")?(C=o.jsx(bt,{className:"h-7 w-24 text-xs shrink-0",children:o.jsx(gt,{})}),e[25]=C):C=e[25];let R;e[26]===Symbol.for("react.memo_cache_sentinel")?(R=o.jsx(xt,{children:Gt.map(Ri)}),e[26]=R):R=e[26];let O;e[27]!==x||e[28]!==j?(O=o.jsxs(ht,{value:x,onValueChange:j,children:[C,R]}),e[27]=x,e[28]=j,e[29]=O):O=e[29];let P;e[30]===Symbol.for("react.memo_cache_sentinel")?(P=o.jsx(es,{size:14}),e[30]=P):P=e[30];let D;e[31]!==u?(D=o.jsx(te,{variant:"ghost",size:"icon",className:"size-7 shrink-0 text-muted-foreground hover:text-destructive",onClick:u,children:P}),e[31]=u,e[32]=D):D=e[32];let L;e[33]!==O||e[34]!==D||e[35]!==A?(L=o.jsxs("div",{className:"flex items-center gap-2",children:[A,O,D]}),e[33]=O,e[34]=D,e[35]=A,e[36]=L):L=e[36];const F=s.description??"";let H;e[37]!==N?(H=E=>N(E.target.value),e[37]=N,e[38]=H):H=e[38];let G;e[39]!==F||e[40]!==H?(G=o.jsx(Wt,{value:F,onChange:H,placeholder:"Description (optional)",className:"h-7 text-xs text-muted-foreground"}),e[39]=F,e[40]=H,e[41]=G):G=e[41];let B;e[42]!==i||e[43]!==a?(B=o.jsx("input",{type:"checkbox",checked:i,onChange:a,className:"rounded border-border"}),e[42]=i,e[43]=a,e[44]=B):B=e[44];let V;e[45]===Symbol.for("react.memo_cache_sentinel")?(V=o.jsx("span",{className:"text-xs text-muted-foreground",children:"Required"}),e[45]=V):V=e[45];let q;e[46]!==B?(q=o.jsxs("label",{className:"flex items-center gap-2 cursor-pointer",children:[B,V]}),e[46]=B,e[47]=q):q=e[47];let U;e[48]!==_||e[49]!==h||e[50]!==s.items?(U=h&&o.jsxs("div",{className:"flex items-center gap-2 pl-2 border-l-2 border-border ml-1",children:[o.jsx("span",{className:"text-xs text-muted-foreground",children:"Items:"}),o.jsxs(ht,{value:s.items?.type??"string",onValueChange:_,children:[o.jsx(bt,{className:"h-7 w-24 text-xs",children:o.jsx(gt,{})}),o.jsx(xt,{children:Gt.map(Mi)})]})]}),e[48]=_,e[49]=h,e[50]=s.items,e[51]=U):U=e[51];let M;e[52]!==b||e[53]!==r||e[54]!==h||e[55]!==c||e[56]!==s?(M=h&&b&&s.items?.type==="object"&&o.jsxs("div",{className:"pl-2 border-l-2 border-border ml-1",children:[o.jsx("span",{className:"text-xs text-muted-foreground mb-1 block",children:"Item properties:"}),o.jsx(vt,{schema:s.items,onChange:E=>c({...s,items:E}),depth:r+1})]}),e[52]=b,e[53]=r,e[54]=h,e[55]=c,e[56]=s,e[57]=M):M=e[57];let J;e[58]!==b||e[59]!==r||e[60]!==g||e[61]!==c||e[62]!==s?(J=g&&b&&o.jsxs("div",{className:"pl-2 border-l-2 border-border ml-1",children:[o.jsx("span",{className:"text-xs text-muted-foreground mb-1 block",children:"Properties:"}),o.jsx(vt,{schema:s,onChange:E=>c(E),depth:r+1})]}),e[58]=b,e[59]=r,e[60]=g,e[61]=c,e[62]=s,e[63]=J):J=e[63];let Q;return e[64]!==L||e[65]!==G||e[66]!==q||e[67]!==U||e[68]!==M||e[69]!==J||e[70]!==W?(Q=o.jsxs("div",{className:W,children:[L,G,q,U,M,J]}),e[64]=L,e[65]=G,e[66]=q,e[67]=U,e[68]=M,e[69]=J,e[70]=W,e[71]=Q):Q=e[71],Q}function Mi(t){return o.jsx(Ze,{value:t.value,children:t.label},t.value)}function Ri(t){return o.jsx(Ze,{value:t.value,children:t.label},t.value)}function Hs(t){const e=I.c(11),{itemId:n,connectionId:s}=t,[i,r]=X.useState(!1),l=s??"self",c=l??"no-connection",{org:a}=oe(),u=l??null;let d;e[0]!==a.id||e[1]!==a.slug||e[2]!==u?(d={connectionId:u,orgId:a.id,orgSlug:a.slug},e[0]=a.id,e[1]=a.slug,e[2]=u,e[3]=d):d=e[3];const f=ae(d),m=hs(c,"WORKFLOW",n,f),p=Gn(c,"WORKFLOW",f);let x;e[4]!==p||e[5]!==n?(x=async b=>{r(!0),await p.update.mutateAsync({id:n,data:b}).finally(()=>{r(!1)})},e[4]=p,e[5]=n,e[6]=x):x=e[6];const h=x;let g;return e[7]!==i||e[8]!==m||e[9]!==h?(g={item:m,update:h,isUpdating:i},e[7]=i,e[8]=m,e[9]=h,e[10]=g):g=e[10],g}function Li(t){const e=I.c(19),{workflow:n,onUpdate:s}=t,{setWorkflow:i}=ne();let r,l,c,a;if(e[0]!==n.description||e[1]!==n.id||e[2]!==n.input_schema||e[3]!==n.steps||e[4]!==n.title){const f={title:n.title,description:n.description,input_schema:n.input_schema,steps:n.steps};r=Oe,l=`workflow-${n.id}`,c="100%",a=JSON.stringify(f,null,2),e[0]=n.description,e[1]=n.id,e[2]=n.input_schema,e[3]=n.steps,e[4]=n.title,e[5]=r,e[6]=l,e[7]=c,e[8]=a}else r=e[5],l=e[6],c=e[7],a=e[8];let u;e[9]!==s||e[10]!==i||e[11]!==n?(u=f=>{const m=JSON.parse(f);i({...n,...m}),s(m)},e[9]=s,e[10]=i,e[11]=n,e[12]=u):u=e[12];let d;return e[13]!==r||e[14]!==l||e[15]!==c||e[16]!==a||e[17]!==u?(d=o.jsx(r,{height:c,code:a,language:"json",onSave:u},l),e[13]=r,e[14]=l,e[15]=c,e[16]=a,e[17]=u,e[18]=d):d=e[18],d}function zi(){const t=I.c(9),e=Y(),{item:n}=de(e),s=n?.start_at_epoch_ms,i=n?.completed_at_epoch_ms,r=n?.status==="running"&&s&&!i;let l;t[0]===Symbol.for("react.memo_cache_sentinel")?(l=Date.now(),t[0]=l):l=t[0];const c=X.useRef(l);let a;t[1]!==r?(a=h=>{if(!r)return Ai;const g=setInterval(()=>{c.current=Date.now(),h()},50);return()=>clearInterval(g)},t[1]=r,t[2]=a):a=t[2];const u=a;let d;t[3]!==r?(d=()=>r?c.current:0,t[3]=r,t[4]=d):d=t[4];const f=d,m=X.useSyncExternalStore(u,f,f),p=i&&s?Math.max(0,i-s):null;let x=null;if(s){let h;t[5]!==s?(h=new Date(s).getTime(),t[5]=s,t[6]=h):h=t[6];const g=h;if(i){let b;t[7]!==i?(b=new Date(i).getTime(),t[7]=i,t[8]=b):b=t[8],x=Math.max(0,b-g)}else r&&(x=Math.max(0,m-g))}return x??p}function Ai(){}function Wi(t){if(t<1e3)return`${t}ms`;const e=t/1e3,n=e%60,s=Math.floor(e/60),i=s%60,r=Math.floor(s/60);return r>0?`${r}h ${i}m ${n.toFixed(3)}s`:i>0?`${i}m ${n.toFixed(3)}s`:`${n.toFixed(3)}s`}function Pi(){const t=I.c(29),{setTrackingExecutionId:e}=ne(),n=Y(),{item:s}=de(n),i=zi();let r;t[0]!==i?(r=i!=null?Wi(i):null,t[0]=i,t[1]=r):r=t[1];const l=r,c=s?.status,a=c==="error"||c==="failed",u=(s?.completed_steps?.error?.length??0)>0,d=c==="success"&&u,f=c==="success"&&!u;let m;t[2]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsx("div",{className:"flex items-center justify-center h-full w-12",children:o.jsx(en,{className:"w-4 h-4 text-muted-foreground"})}),t[2]=m):m=t[2];let p;t[3]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsx("strong",{className:"text-base text-foreground",children:"Run"}),t[3]=p):p=t[3];let x;t[4]!==n?(x=o.jsxs("p",{className:"flex gap-3 items-center h-full",children:[p,o.jsxs("span",{className:"text-sm text-muted-foreground",children:["#",n]})]}),t[4]=n,t[5]=x):x=t[5];let h;t[6]!==f?(h=f&&o.jsxs(le,{variant:"success",className:"gap-1 ml-3",children:[o.jsx(tn,{size:11}),"Success"]}),t[6]=f,t[7]=h):h=t[7];let g;t[8]!==d?(g=d&&o.jsxs(le,{variant:"warning",className:"gap-1 ml-3",children:[o.jsx(to,{size:11}),"Partial success"]}),t[8]=d,t[9]=g):g=t[9];let b;t[10]!==a?(b=a&&o.jsxs(le,{variant:"destructive",className:"gap-1 ml-3",children:[o.jsx(eo,{size:11}),"Failed"]}),t[10]=a,t[11]=b):b=t[11];let S;t[12]===Symbol.for("react.memo_cache_sentinel")?(S=o.jsx(Yn,{className:"w-4 h-4 text-muted-foreground"}),t[12]=S):S=t[12];let w;t[13]!==l?(w=o.jsxs("div",{className:"flex items-center gap-1 ml-6",children:[S,o.jsx("span",{className:"text-sm text-muted-foreground",children:l})]}),t[13]=l,t[14]=w):w=t[14];let y;t[15]!==x||t[16]!==h||t[17]!==g||t[18]!==b||t[19]!==w?(y=o.jsxs("div",{className:"flex items-center h-full",children:[m,x,h,g,b,w]}),t[15]=x,t[16]=h,t[17]=g,t[18]=b,t[19]=w,t[20]=y):y=t[20];let j;t[21]!==e?(j=()=>e(void 0),t[21]=e,t[22]=j):j=t[22];let v;t[23]===Symbol.for("react.memo_cache_sentinel")?(v=o.jsx(Nt,{className:"w-4 h-4 text-muted-foreground"}),t[23]=v):v=t[23];let N;t[24]!==j?(N=o.jsx(te,{variant:"ghost",size:"xs",onClick:j,children:v}),t[24]=j,t[25]=N):N=t[25];let k;return t[26]!==N||t[27]!==y?(k=o.jsx("div",{className:"flex flex-col border-b border-border",children:o.jsxs("div",{className:"h-10 bg-accent flex items-center justify-between",children:[y,N]})}),t[26]=N,t[27]=y,t[28]=k):k=t[28],k}function vl(t){const e=I.c(14),{itemId:n}=t;let s;e[0]!==n?(s={itemId:n},e[0]=n,e[1]=s):s=e[1];const{item:i,update:r,isUpdating:l}=Hs(s);let c;e[2]!==i?(c=JSON.stringify(i),e[2]=i,e[3]=c):c=e[3];const a=c;if(!i){let m;return e[4]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsx(Ge,{children:o.jsx("div",{className:"flex h-full w-full bg-background",children:o.jsx(gs,{icon:o.jsx(ws,{className:"w-10 h-10 text-muted-foreground"}),title:"Workflow not found",description:"This workflow may have been deleted or you may not have access to it."})})}),e[4]=m):m=e[4],m}let u;e[5]!==i?(u={workflow:i,trackingExecutionId:void 0,currentStepTab:"input"},e[5]=i,e[6]=u):u=e[6];let d;e[7]!==l||e[8]!==r?(d=o.jsx(Di,{onUpdate:r,isUpdating:l}),e[7]=l,e[8]=r,e[9]=d):d=e[9];let f;return e[10]!==a||e[11]!==u||e[12]!==d?(f=o.jsx(po,{initialState:u,children:d},a),e[10]=a,e[11]=u,e[12]=d,e[13]=f):f=e[13],f}function Di(t){const e=I.c(22),{onUpdate:n,isUpdating:s}=t;Ci();const i=ue(),r=Y(),{viewMode:l,showExecutionsList:c}=Et(),a=Ve(),u=Ms();let d;e[0]!==n||e[1]!==i?(d=async()=>{await n(i)},e[0]=n,e[1]=i,e[2]=d):d=e[2];const f=d,m=a&&"toolName"in a.action,p=m?a.action.toolName:null,x=m&&!p&&!r,h=u&&!r,g=!x&&!h&&(a||r||!c);let b;e[3]!==f||e[4]!==s||e[5]!==i.description||e[6]!==i.title?(b=o.jsx(wr,{title:i.title,description:i.description,onSave:f,isSaving:s}),e[3]=f,e[4]=s,e[5]=i.description,e[6]=i.title,e[7]=b):b=e[7];let S;e[8]!==r?(S=r&&o.jsx(Pi,{}),e[8]=r,e[9]=S):S=e[9];let w;e[10]!==n||e[11]!==c||e[12]!==h||e[13]!==g||e[14]!==x||e[15]!==l||e[16]!==i?(w=o.jsx("div",{className:"flex-1 overflow-hidden",children:l==="code"?o.jsx(Li,{workflow:i,onUpdate:n}):o.jsxs(ln,{direction:"horizontal",className:"flex w-full h-full",children:[o.jsx(zt,{defaultSize:50,minSize:30,children:o.jsx(Fr,{})}),o.jsx(cn,{}),o.jsxs(zt,{defaultSize:50,minSize:25,children:[x&&o.jsx(Xr,{className:"border-l border-border"}),h&&o.jsx($i,{className:"border-l border-border"}),c&&o.jsx(Si,{}),g&&o.jsx(ei,{className:"border-l border-border"})]})]})}),e[10]=n,e[11]=c,e[12]=h,e[13]=g,e[14]=x,e[15]=l,e[16]=i,e[17]=w):w=e[17];let y;return e[18]!==b||e[19]!==S||e[20]!==w?(y=o.jsx(Ge,{children:o.jsxs("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:[b,S,w]})}),e[18]=b,e[19]=S,e[20]=w,e[21]=y):y=e[21],y}function Fi(t){const e=I.c(6),{itemId:n,connectionId:s}=t,i=s??"self",r=i??"no-connection",{org:l}=oe(),c=i??null;let a;e[0]!==l.id||e[1]!==l.slug||e[2]!==c?(a={connectionId:c,orgId:l.id,orgSlug:l.slug},e[0]=l.id,e[1]=l.slug,e[2]=c,e[3]=a):a=e[3];const u=ae(a),d=hs(r,"WORKFLOW_EXECUTION",n,u);let f;return e[4]!==d?(f={item:d},e[4]=d,e[5]=f):f=e[5],f}function Nl(t){const e=I.c(7),{itemId:n}=t;let s;e[0]!==n?(s={itemId:n},e[0]=n,e[1]=s):s=e[1];const{item:i}=Fi(s);if(!i){let c;return e[2]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx(Ge,{children:o.jsx("div",{className:"flex h-full w-full bg-background",children:o.jsx(gs,{icon:o.jsx(ws,{className:"w-10 h-10 text-muted-foreground"}),title:"Workflow execution not found",description:"This workflow execution may have been deleted or you may not have access to it."})})}),e[2]=c):c=e[2],c}let r;e[3]!==i?(r=JSON.stringify(i,null,2),e[3]=i,e[4]=r):r=e[4];let l;return e[5]!==r?(l=o.jsx(Ge,{children:o.jsx("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:o.jsx(Oe,{height:"100%",code:r,language:"json",readOnly:!0})})}),e[5]=r,e[6]=l):l=e[6],l}export{so as S,Nl as W,vl as a};
26
+ }`;s(n.name,{action:{...n.action,transformCode:_}}),l(mi)},e[2]=m,e[3]=n.action,e[4]=n.name,e[5]=s,e[6]=p):p=e[6];const x=p;let h;e[7]!==n.action||e[8]!==n.name||e[9]!==s?(h=(k,_)=>{s(n.name,{action:{...n.action,transformCode:k},..._?{outputSchema:_}:{}})},e[7]=n.action,e[8]=n.name,e[9]=s,e[10]=h):h=e[10];const g=h;if("code"in n.action&&n.action.code)return null;const b=r?"flex-1 min-h-0 overflow-hidden":"shrink-0";let S;e[11]!==b?(S=$("flex flex-col flex-1 min-h-0 overflow-hidden border-b border-border",b),e[11]=b,e[12]=S):S=e[12];let w;e[13]===Symbol.for("react.memo_cache_sentinel")?(w=o.jsx("h3",{className:"text-sm font-medium text-muted-foreground",children:"Transform Code"}),e[13]=w):w=e[13];let y;e[14]!==r?(y=o.jsxs("div",{className:"flex items-center justify-between",children:[w,r?o.jsx(st,{size:14,className:"text-muted-foreground"}):o.jsx(tt,{size:14,className:"text-muted-foreground"})]}),e[14]=r,e[15]=y):y=e[15];let j;e[16]!==y||e[17]!==x?(j=o.jsx("div",{className:"p-5 shrink-0 cursor-pointer hover:bg-accent/50 transition-colors",onClick:x,children:y}),e[16]=y,e[17]=x,e[18]=j):j=e[18];let v;e[19]!==g||e[20]!==r||e[21]!==n.name||e[22]!==i||e[23]!==d?(v=r&&o.jsx("div",{className:"flex-1 min-h-0",children:o.jsx(Oe,{code:d,language:"typescript",readOnly:i!==void 0,onSave:g,height:"100%"},`transform-code-${n.name}-${i}`)}),e[19]=g,e[20]=r,e[21]=n.name,e[22]=i,e[23]=d,e[24]=v):v=e[24];let N;return e[25]!==S||e[26]!==j||e[27]!==v?(N=o.jsxs("div",{className:S,children:[j,v]}),e[25]=S,e[26]=j,e[27]=v,e[28]=N):N=e[28],N}function mi(t){return!t}function pi(t){return!t}function xi(t){const e=I.c(25),{step:n}=t,[s,i]=X.useState(!1),{updateStep:r}=ne(),l=ue(),c="code"in n.action&&n.action.code?n.action.code:null,a=Y();if(!c)return null;let u;e[0]!==n.action||e[1]!==n.name||e[2]!==r?(u=(m,p)=>{r(n.name,{action:{...n.action,code:m},...p?{outputSchema:p}:{}})},e[0]=n.action,e[1]=n.name,e[2]=r,e[3]=u):u=e[3];const d=u;let f;if(e[4]!==c||e[5]!==d||e[6]!==s||e[7]!==n.action||e[8]!==n.input||e[9]!==n.name||e[10]!==a||e[11]!==r||e[12]!==l.input_schema||e[13]!==l.steps){const m=[],p=l.input_schema;p&&m.push({name:"input",label:"Workflow Input",schema:p});for(const N of l.steps){if(N.name===n.name)break;m.push({name:N.name,label:N.name,schema:N.outputSchema})}const x=n.input??{},h=new Set(Object.entries(x).filter(gi).map(hi)),g=N=>{const k={...x};if(h.has(N)){const R=Object.entries(k).find(O=>{const[,P]=O;return P===`@${N}`})?.[0];R&&delete k[R]}else k[N]=`@${N}`;const _={};for(const[R,O]of Object.entries(k)){if(typeof O!="string"||!O.startsWith("@"))continue;const P=O.slice(1),D=m.find(L=>L.name===P);D?.schema&&(_[R]=D.schema)}const T=Object.keys(_).length>0?{type:"object",properties:_,required:Object.keys(_)}:null,W=T?Ts(T,"Input"):"interface Input {}",A=n.action,C=Es(A.code,W);r(n.name,{input:k,action:{...n.action,code:C}})},b=s?"flex-1 min-h-0 overflow-hidden":"shrink-0";let S;e[15]!==b?(S=$("flex flex-col border-b border-border",b),e[15]=b,e[16]=S):S=e[16];let w;e[17]!==s?(w=()=>i(!s),e[17]=s,e[18]=w):w=e[18];let y;e[19]===Symbol.for("react.memo_cache_sentinel")?(y=o.jsx("h3",{className:"text-sm font-medium text-muted-foreground",children:"Step Code"}),e[19]=y):y=e[19];let j;e[20]!==s?(j=o.jsxs("div",{className:"flex items-center justify-between",children:[y,s?o.jsx(st,{size:14,className:"text-muted-foreground"}):o.jsx(tt,{size:14,className:"text-muted-foreground"})]}),e[20]=s,e[21]=j):j=e[21];let v;e[22]!==w||e[23]!==j?(v=o.jsx("div",{className:"p-5 shrink-0 cursor-pointer hover:bg-accent/50 transition-colors",onClick:w,children:j}),e[22]=w,e[23]=j,e[24]=v):v=e[24],f=o.jsxs("div",{className:S,children:[v,s&&o.jsxs(o.Fragment,{children:[!a&&m.length>0&&o.jsxs("div",{className:"px-5 pb-3 shrink-0 border-b border-border/50",children:[o.jsxs("p",{className:"text-xs text-muted-foreground mb-2",children:["Select variables available to your code as"," ",o.jsx("code",{className:"text-[11px] bg-accent px-1 py-0.5 rounded",children:"input"}),":"]}),o.jsx("div",{className:"flex flex-wrap gap-1.5",children:m.map(N=>{const k=h.has(N.name);return o.jsxs("button",{type:"button",className:$("h-7 px-2.5 text-xs font-medium rounded-lg border transition-colors inline-flex items-center gap-1.5",k?"bg-accent border-border text-foreground":"bg-transparent border-transparent text-muted-foreground hover:bg-accent/50 hover:text-foreground"),onClick:()=>g(N.name),children:[k&&o.jsx(Fe,{size:12,className:"text-success"}),o.jsxs("span",{className:"font-mono",children:["@",N.name]})]},N.name)})})]}),o.jsx("div",{className:"flex-1 min-h-0",children:o.jsx(Oe,{onSave:(N,k)=>d(N,k),code:c,language:"typescript",height:"100%",readOnly:a!==void 0},`step-code-${n.name}-${a}`)})]})]}),e[4]=c,e[5]=d,e[6]=s,e[7]=n.action,e[8]=n.input,e[9]=n.name,e[10]=a,e[11]=r,e[12]=l.input_schema,e[13]=l.steps,e[14]=f}else f=e[14];return f}function hi(t){const[,e]=t;return e.slice(1)}function gi(t){const[,e]=t;return typeof e=="string"&&e.startsWith("@")}function Je(t){if(Array.isArray(t.type))return t.type.map(n=>Je({...t,type:n})).join(" | ");switch(t.type){case"string":return"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"array":return t.items?`${Je(t.items)}[]`:"unknown[]";case"object":return t.properties?`{ ${Object.entries(t.properties).map(([s,i])=>{const r=Je(i),l=!t.required?.includes(s);return`${s}${l?"?":""}: ${r}`}).join("; ")} }`:"Record<string, unknown>";case"null":return"null";default:return"unknown"}}function bi(t){const{status:e}=t,n=(t.completed_steps?.error?.length??0)>0;if(e==="success"&&n)return o.jsxs(le,{variant:"warning",className:"gap-1",children:[o.jsx(Zs,{size:11}),"Partial"]});switch(e){case"success":return o.jsxs(le,{variant:"success",className:"gap-1",children:[o.jsx(Fe,{size:11}),"Success"]});case"error":case"failed":return o.jsxs(le,{variant:"destructive",className:"gap-1",children:[o.jsx(ns,{size:11}),"Error"]});case"running":return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(ft,{size:11}),"Running"]});case"enqueued":return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(ft,{size:11}),"On hold"]});case"cancelled":return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(xs,{size:11}),"Cancelled"]});default:return o.jsxs(le,{variant:"secondary",className:"gap-1",children:[o.jsx(ft,{size:11}),e]})}}function ji(t){return`Run #${t.slice(-4).toUpperCase()}`}function Si(t){const e=I.c(21),{className:n}=t,{executions:s,isLoading:i}=Io(),{setShowExecutionsList:r}=Et(),{setTrackingExecutionId:l}=ne(),c=Y();let a;e[0]!==l?(a=w=>{l(w)},e[0]=l,e[1]=a):a=e[1];const u=a;let d;e[2]!==r?(d=()=>{r(!1)},e[2]=r,e[3]=d):d=e[3];const f=d;let m;e[4]!==n?(m=$("flex flex-col h-full bg-sidebar border-l border-border",n),e[4]=n,e[5]=m):m=e[5];let p;e[6]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsx("p",{className:"flex-1 text-base font-medium text-foreground",children:"Runs"}),e[6]=p):p=e[6];let x;e[7]===Symbol.for("react.memo_cache_sentinel")?(x=o.jsx(xs,{size:11}),e[7]=x):x=e[7];let h;e[8]!==f?(h=o.jsxs("div",{className:"flex items-center h-12 px-5 border-b border-border shrink-0",children:[p,o.jsx(te,{variant:"ghost",size:"icon",className:"size-7",onClick:f,children:x})]}),e[8]=f,e[9]=h):h=e[9];let g;e[10]!==s||e[11]!==u||e[12]!==i||e[13]!==c?(g=i?o.jsx("div",{className:"flex items-center justify-center h-full text-sm text-muted-foreground",children:"Loading executions..."}):s.map((w,y)=>o.jsx(yi,{execution:w,isSelected:w.id===c,isFirst:y===0,onSelect:()=>u(w.id)},w.id)),e[10]=s,e[11]=u,e[12]=i,e[13]=c,e[14]=g):g=e[14];let b;e[15]!==g?(b=o.jsx("div",{className:"flex-1 overflow-auto",children:g}),e[15]=g,e[16]=b):b=e[16];let S;return e[17]!==m||e[18]!==h||e[19]!==b?(S=o.jsxs("div",{className:m,children:[h,b]}),e[17]=m,e[18]=h,e[19]=b,e[20]=S):S=e[20],S}function yi(t){const e=I.c(17),{execution:n,isSelected:s,isFirst:i,onSelect:r}=t,l=s&&"bg-accent/50",c=i&&s&&"bg-accent/50",a=!s&&"hover:bg-accent/30";let u;e[0]!==l||e[1]!==c||e[2]!==a?(u=$("flex flex-col justify-center h-[60px] px-4 border-b border-border cursor-pointer transition-colors",l,c,a),e[0]=l,e[1]=c,e[2]=a,e[3]=u):u=e[3];let d;e[4]!==n?(d=bi(n),e[4]=n,e[5]=d):d=e[5];let f;e[6]!==n.id?(f=ji(n.id),e[6]=n.id,e[7]=f):f=e[7];let m;e[8]!==f?(m=o.jsx("p",{className:"flex-1 text-base font-medium text-foreground",children:f}),e[8]=f,e[9]=m):m=e[9];let p;e[10]!==d||e[11]!==m?(p=o.jsxs("div",{className:"flex items-center gap-2 w-full",children:[d,m]}),e[10]=d,e[11]=m,e[12]=p):p=e[12];let x;return e[13]!==r||e[14]!==u||e[15]!==p?(x=o.jsx("div",{className:u,onClick:r,children:p}),e[13]=r,e[14]=u,e[15]=p,e[16]=x):x=e[16],x}const wi=Qn,vi=["COLLECTION_WORKFLOW_EXECUTION_LIST","COLLECTION_WORKFLOW_EXECUTION_GET","COLLECTION_WORKFLOW_EXECUTION_GET_STEP_RESULT"],Ni=500,Pe=new Map,We=new Map;function ki(t){const e=We.get(t);if(e)for(const n of e)n.invalidateQueries({predicate:s=>s.queryKey.some(i=>typeof i=="string"&&vi.includes(i))})}function Ii(t){Pe.has(t)||Pe.set(t,setTimeout(()=>{Pe.delete(t),ki(t)},Ni))}const Jt=()=>0;function _i(){const t=I.c(4),{org:e}=oe(),n=Zt(),s=e.id,i=e.slug;let r;t[0]!==s||t[1]!==i||t[2]!==n?(r=c=>{let a=We.get(s);a||(a=new Set,We.set(s,a)),a.add(n);const u=()=>{Ii(s),c()},d=wi.subscribe(i,u);return()=>{d(),a.delete(n),a.size===0&&We.delete(s);const f=Pe.get(s);f&&!We.has(s)&&(clearTimeout(f),Pe.delete(s))}},t[0]=s,t[1]=i,t[2]=n,t[3]=r):r=t[3];const l=r;X.useSyncExternalStore(l,Jt,Jt)}const Gt=[{value:"string",label:"String"},{value:"number",label:"Number"},{value:"integer",label:"Integer"},{value:"boolean",label:"Boolean"},{value:"object",label:"Object"},{value:"array",label:"Array"}],Ci={type:"object",properties:{field:{type:"string",description:"An input field"}},required:["field"]},Ti=2;function Ei(t){const e=I.c(66),{className:n}=t,s=ue(),{setWorkflow:i}=ne(),[r,l]=X.useState("visual"),[c,a]=X.useState(!1);let u;e[0]===Symbol.for("react.memo_cache_sentinel")?(u={},e[0]=u):u=e[0];const[d,f]=X.useState(u),m=s.input_schema??null;let p;e[1]!==i||e[2]!==s?(p=M=>{i({...s,input_schema:M})},e[1]=i,e[2]=s,e[3]=p):p=e[3];const x=p;let h;e[4]!==x?(h=M=>{try{const J=JSON.parse(M);x(J)}catch{}},e[4]=x,e[5]=h):h=e[5];const g=h;let b;e[6]!==x?(b=()=>{x(Ci)},e[6]=x,e[7]=b):b=e[7];const S=b;let w;e[8]!==x?(w=()=>{x(void 0)},e[8]=x,e[9]=w):w=e[9];const y=w;if(!m){let M;e[10]!==n?(M=$("flex flex-col h-full bg-sidebar",n),e[10]=n,e[11]=M):M=e[11];let J;e[12]===Symbol.for("react.memo_cache_sentinel")?(J=o.jsx(Qt,{}),e[12]=J):J=e[12];let Q;e[13]===Symbol.for("react.memo_cache_sentinel")?(Q=o.jsx("p",{className:"text-sm text-muted-foreground",children:"No input schema defined. Add one to require structured input when running this workflow."}),e[13]=Q):Q=e[13];let E;e[14]===Symbol.for("react.memo_cache_sentinel")?(E=o.jsx(Ns,{size:14}),e[14]=E):E=e[14];let z;e[15]!==S?(z=o.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center gap-3 p-8 text-center",children:[Q,o.jsxs(te,{variant:"outline",size:"sm",className:"gap-2",onClick:S,children:[E,"Add input schema"]})]}),e[15]=S,e[16]=z):z=e[16];let ee;return e[17]!==z||e[18]!==M?(ee=o.jsxs("div",{className:M,children:[J,z]}),e[17]=z,e[18]=M,e[19]=ee):ee=e[19],ee}let j;e[20]!==n?(j=$("flex flex-col h-full bg-sidebar",n),e[20]=n,e[21]=j):j=e[21];const v=r==="visual"?"bg-accent text-foreground":"text-muted-foreground hover:text-foreground";let N;e[22]!==v?(N=$("h-6 px-2 rounded text-xs font-medium transition-colors",v),e[22]=v,e[23]=N):N=e[23];let k,_;e[24]===Symbol.for("react.memo_cache_sentinel")?(_=()=>l("visual"),k=o.jsx(jn,{size:12}),e[24]=k,e[25]=_):(k=e[24],_=e[25]);let T;e[26]!==N?(T=o.jsx("button",{type:"button",className:N,onClick:_,children:k}),e[26]=N,e[27]=T):T=e[27];const W=r==="code"?"bg-accent text-foreground":"text-muted-foreground hover:text-foreground";let A;e[28]!==W?(A=$("h-6 px-2 rounded text-xs font-medium transition-colors",W),e[28]=W,e[29]=A):A=e[29];let C,R;e[30]===Symbol.for("react.memo_cache_sentinel")?(C=()=>l("code"),R=o.jsx(ss,{size:12}),e[30]=C,e[31]=R):(C=e[30],R=e[31]);let O;e[32]!==A?(O=o.jsx("button",{type:"button",className:A,onClick:C,children:R}),e[32]=A,e[33]=O):O=e[33];let P;e[34]!==T||e[35]!==O?(P=o.jsx(Qt,{children:o.jsxs("div",{className:"flex items-center gap-1 border border-border rounded-lg p-0.5",children:[T,O]})}),e[34]=T,e[35]=O,e[36]=P):P=e[36];let D;e[37]!==g||e[38]!==m||e[39]!==x||e[40]!==r||e[41]!==s.id?(D=r==="visual"?o.jsx(o.Fragment,{children:o.jsx("div",{className:"flex-1 overflow-auto",children:o.jsx(vt,{schema:m,onChange:M=>x(M),depth:0})})}):o.jsx("div",{className:"flex-1 min-h-0",children:o.jsx(Oe,{code:JSON.stringify(m,null,2),language:"json",height:"100%",onSave:g},`input-schema-${s.id}`)}),e[37]=g,e[38]=m,e[39]=x,e[40]=r,e[41]=s.id,e[42]=D):D=e[42];let L;e[43]!==c?(L=()=>a(!c),e[43]=c,e[44]=L):L=e[44];let F;e[45]===Symbol.for("react.memo_cache_sentinel")?(F=o.jsx("span",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wider",children:"Preview"}),e[45]=F):F=e[45];let H;e[46]!==c?(H=c?o.jsx(st,{size:14,className:"text-muted-foreground"}):o.jsx(tt,{size:14,className:"text-muted-foreground"}),e[46]=c,e[47]=H):H=e[47];let G;e[48]!==L||e[49]!==H?(G=o.jsxs("button",{type:"button",className:"w-full px-5 py-3 flex items-center justify-between hover:bg-accent/50 transition-colors",onClick:L,children:[F,H]}),e[48]=L,e[49]=H,e[50]=G):G=e[50];let B;e[51]!==m||e[52]!==d||e[53]!==c?(B=c&&o.jsx("div",{className:"px-5 pb-4 max-h-64 overflow-auto",children:o.jsx(Ot,{inputSchema:m,inputParams:d,setInputParams:f,mentions:[]})}),e[51]=m,e[52]=d,e[53]=c,e[54]=B):B=e[54];let V;e[55]!==G||e[56]!==B?(V=o.jsxs("div",{className:"shrink-0 border-t border-border",children:[G,B]}),e[55]=G,e[56]=B,e[57]=V):V=e[57];let q;e[58]!==y?(q=o.jsx("div",{className:"px-5 py-3 shrink-0 border-t border-border",children:o.jsx("button",{type:"button",className:"text-xs text-muted-foreground hover:text-destructive transition-colors",onClick:y,children:"Remove input schema"})}),e[58]=y,e[59]=q):q=e[59];let U;return e[60]!==P||e[61]!==D||e[62]!==V||e[63]!==q||e[64]!==j?(U=o.jsxs("div",{className:j,children:[P,D,V,q]}),e[60]=P,e[61]=D,e[62]=V,e[63]=q,e[64]=j,e[65]=U):U=e[65],U}function Qt(t){const e=I.c(4),{children:n}=t;let s,i;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=o.jsx(os,{className:"w-4 h-4 text-muted-foreground shrink-0"}),i=o.jsx("span",{className:"text-base font-medium text-foreground flex-1",children:"Workflow Input"}),e[0]=s,e[1]=i):(s=e[0],i=e[1]);let r;return e[2]!==n?(r=o.jsxs("div",{className:"border-b border-border p-5 shrink-0 flex items-center gap-2",children:[s,i,n]}),e[2]=n,e[3]=r):r=e[3],r}function vt({schema:t,onChange:e,depth:n}){const s=t.properties??{},i=t.required??[],r=()=>{const f=Object.keys(s);let m="field",p=1;for(;f.includes(m);)m=`field_${p}`,p++;e({...t,properties:{...s,[m]:{type:"string"}},required:[...i,m]})},l=f=>{const{[f]:m,...p}=s;e({...t,properties:p,required:i.filter(x=>x!==f)})},c=(f,m)=>{e({...t,properties:{...s,[f]:m}})},a=(f,m)=>{if(!m.trim()||m===f||s[m])return;const p={};for(const[x,h]of Object.entries(s))p[x===f?m:x]=h;e({...t,properties:p,required:i.map(x=>x===f?m:x)})},u=f=>{const m=i.includes(f);e({...t,required:m?i.filter(p=>p!==f):[...i,f]})},d=Object.entries(s);return o.jsxs("div",{children:[d.length===0&&n===0&&o.jsx("div",{className:"p-5 text-sm text-muted-foreground text-center",children:"No fields defined yet."}),o.jsx("div",{className:"divide-y divide-border",children:d.map(([f,m])=>o.jsx($i,{name:f,schema:m,isRequired:i.includes(f),depth:n,onRename:p=>a(f,p),onUpdate:p=>c(f,p),onToggleRequired:()=>u(f),onRemove:()=>l(f)},f))}),o.jsx("div",{className:$("p-3",n>0&&"pb-1"),children:o.jsxs(te,{variant:"outline",size:"sm",className:"w-full gap-2",onClick:r,children:[o.jsx(Ns,{size:14}),"Add field"]})})]})}function $i(t){const e=I.c(72),{name:n,schema:s,isRequired:i,depth:r,onRename:l,onUpdate:c,onToggleRequired:a,onRemove:u}=t,[d,f]=X.useState(!1),[m,p]=X.useState(n),x=s.type??"string",h=x==="array",g=x==="object",b=r<Ti;let S;e[0]!==m||e[1]!==n||e[2]!==l?(S=()=>{f(!1),m.trim()&&m!==n?l(m.trim()):p(n)},e[0]=m,e[1]=n,e[2]=l,e[3]=S):S=e[3];const w=S;let y;e[4]!==b||e[5]!==c||e[6]!==s.description||e[7]!==s.items||e[8]!==s.properties||e[9]!==s.required?(y=E=>{const z={type:E};s.description&&(z.description=s.description),E==="array"&&(z.items=s.items??{type:"string"}),E==="object"&&b&&(z.properties=s.properties??{},z.required=s.required??[]),c(z)},e[4]=b,e[5]=c,e[6]=s.description,e[7]=s.items,e[8]=s.properties,e[9]=s.required,e[10]=y):y=e[10];const j=y;let v;e[11]!==c||e[12]!==s?(v=E=>{const z={...s};E?z.description=E:delete z.description,c(z)},e[11]=c,e[12]=s,e[13]=v):v=e[13];const N=v;let k;e[14]!==b||e[15]!==c||e[16]!==s?(k=E=>{const z={type:E};E==="object"&&b&&(z.properties=s.items?.properties??{},z.required=s.items?.required??[]),c({...s,items:z})},e[14]=b,e[15]=c,e[16]=s,e[17]=k):k=e[17];const _=k,T=r>0&&"py-3";let W;e[18]!==T?(W=$("flex flex-col gap-2 p-4",T),e[18]=T,e[19]=W):W=e[19];let A;e[20]!==w||e[21]!==m||e[22]!==d||e[23]!==n?(A=d?o.jsx(Wt,{value:m,onChange:E=>p(E.target.value),onBlur:w,onKeyDown:E=>{E.key==="Enter"&&w(),E.key==="Escape"&&(p(n),f(!1))},className:"h-7 text-sm font-medium flex-1 min-w-0",autoFocus:!0}):o.jsx("button",{type:"button",className:"text-sm font-medium text-foreground flex-1 text-left truncate hover:underline cursor-text min-w-0",onClick:()=>{p(n),f(!0)},children:n}),e[20]=w,e[21]=m,e[22]=d,e[23]=n,e[24]=A):A=e[24];let C;e[25]===Symbol.for("react.memo_cache_sentinel")?(C=o.jsx(bt,{className:"h-7 w-24 text-xs shrink-0",children:o.jsx(gt,{})}),e[25]=C):C=e[25];let R;e[26]===Symbol.for("react.memo_cache_sentinel")?(R=o.jsx(xt,{children:Gt.map(Mi)}),e[26]=R):R=e[26];let O;e[27]!==x||e[28]!==j?(O=o.jsxs(ht,{value:x,onValueChange:j,children:[C,R]}),e[27]=x,e[28]=j,e[29]=O):O=e[29];let P;e[30]===Symbol.for("react.memo_cache_sentinel")?(P=o.jsx(es,{size:14}),e[30]=P):P=e[30];let D;e[31]!==u?(D=o.jsx(te,{variant:"ghost",size:"icon",className:"size-7 shrink-0 text-muted-foreground hover:text-destructive",onClick:u,children:P}),e[31]=u,e[32]=D):D=e[32];let L;e[33]!==O||e[34]!==D||e[35]!==A?(L=o.jsxs("div",{className:"flex items-center gap-2",children:[A,O,D]}),e[33]=O,e[34]=D,e[35]=A,e[36]=L):L=e[36];const F=s.description??"";let H;e[37]!==N?(H=E=>N(E.target.value),e[37]=N,e[38]=H):H=e[38];let G;e[39]!==F||e[40]!==H?(G=o.jsx(Wt,{value:F,onChange:H,placeholder:"Description (optional)",className:"h-7 text-xs text-muted-foreground"}),e[39]=F,e[40]=H,e[41]=G):G=e[41];let B;e[42]!==i||e[43]!==a?(B=o.jsx("input",{type:"checkbox",checked:i,onChange:a,className:"rounded border-border"}),e[42]=i,e[43]=a,e[44]=B):B=e[44];let V;e[45]===Symbol.for("react.memo_cache_sentinel")?(V=o.jsx("span",{className:"text-xs text-muted-foreground",children:"Required"}),e[45]=V):V=e[45];let q;e[46]!==B?(q=o.jsxs("label",{className:"flex items-center gap-2 cursor-pointer",children:[B,V]}),e[46]=B,e[47]=q):q=e[47];let U;e[48]!==_||e[49]!==h||e[50]!==s.items?(U=h&&o.jsxs("div",{className:"flex items-center gap-2 pl-2 border-l-2 border-border ml-1",children:[o.jsx("span",{className:"text-xs text-muted-foreground",children:"Items:"}),o.jsxs(ht,{value:s.items?.type??"string",onValueChange:_,children:[o.jsx(bt,{className:"h-7 w-24 text-xs",children:o.jsx(gt,{})}),o.jsx(xt,{children:Gt.map(Oi)})]})]}),e[48]=_,e[49]=h,e[50]=s.items,e[51]=U):U=e[51];let M;e[52]!==b||e[53]!==r||e[54]!==h||e[55]!==c||e[56]!==s?(M=h&&b&&s.items?.type==="object"&&o.jsxs("div",{className:"pl-2 border-l-2 border-border ml-1",children:[o.jsx("span",{className:"text-xs text-muted-foreground mb-1 block",children:"Item properties:"}),o.jsx(vt,{schema:s.items,onChange:E=>c({...s,items:E}),depth:r+1})]}),e[52]=b,e[53]=r,e[54]=h,e[55]=c,e[56]=s,e[57]=M):M=e[57];let J;e[58]!==b||e[59]!==r||e[60]!==g||e[61]!==c||e[62]!==s?(J=g&&b&&o.jsxs("div",{className:"pl-2 border-l-2 border-border ml-1",children:[o.jsx("span",{className:"text-xs text-muted-foreground mb-1 block",children:"Properties:"}),o.jsx(vt,{schema:s,onChange:E=>c(E),depth:r+1})]}),e[58]=b,e[59]=r,e[60]=g,e[61]=c,e[62]=s,e[63]=J):J=e[63];let Q;return e[64]!==L||e[65]!==G||e[66]!==q||e[67]!==U||e[68]!==M||e[69]!==J||e[70]!==W?(Q=o.jsxs("div",{className:W,children:[L,G,q,U,M,J]}),e[64]=L,e[65]=G,e[66]=q,e[67]=U,e[68]=M,e[69]=J,e[70]=W,e[71]=Q):Q=e[71],Q}function Oi(t){return o.jsx(Ze,{value:t.value,children:t.label},t.value)}function Mi(t){return o.jsx(Ze,{value:t.value,children:t.label},t.value)}function Hs(t){const e=I.c(11),{itemId:n,connectionId:s}=t,[i,r]=X.useState(!1),l=s??"self",c=l??"no-connection",{org:a}=oe(),u=l??null;let d;e[0]!==a.id||e[1]!==a.slug||e[2]!==u?(d={connectionId:u,orgId:a.id,orgSlug:a.slug},e[0]=a.id,e[1]=a.slug,e[2]=u,e[3]=d):d=e[3];const f=ae(d),m=hs(c,"WORKFLOW",n,f),p=Gn(c,"WORKFLOW",f);let x;e[4]!==p||e[5]!==n?(x=async b=>{r(!0),await p.update.mutateAsync({id:n,data:b}).finally(()=>{r(!1)})},e[4]=p,e[5]=n,e[6]=x):x=e[6];const h=x;let g;return e[7]!==i||e[8]!==m||e[9]!==h?(g={item:m,update:h,isUpdating:i},e[7]=i,e[8]=m,e[9]=h,e[10]=g):g=e[10],g}function Ri(t){const e=I.c(19),{workflow:n,onUpdate:s}=t,{setWorkflow:i}=ne();let r,l,c,a;if(e[0]!==n.description||e[1]!==n.id||e[2]!==n.input_schema||e[3]!==n.steps||e[4]!==n.title){const f={title:n.title,description:n.description,input_schema:n.input_schema,steps:n.steps};r=Oe,l=`workflow-${n.id}`,c="100%",a=JSON.stringify(f,null,2),e[0]=n.description,e[1]=n.id,e[2]=n.input_schema,e[3]=n.steps,e[4]=n.title,e[5]=r,e[6]=l,e[7]=c,e[8]=a}else r=e[5],l=e[6],c=e[7],a=e[8];let u;e[9]!==s||e[10]!==i||e[11]!==n?(u=f=>{const m=JSON.parse(f);i({...n,...m}),s(m)},e[9]=s,e[10]=i,e[11]=n,e[12]=u):u=e[12];let d;return e[13]!==r||e[14]!==l||e[15]!==c||e[16]!==a||e[17]!==u?(d=o.jsx(r,{height:c,code:a,language:"json",onSave:u},l),e[13]=r,e[14]=l,e[15]=c,e[16]=a,e[17]=u,e[18]=d):d=e[18],d}function Li(){const t=I.c(9),e=Y(),{item:n}=de(e),s=n?.start_at_epoch_ms,i=n?.completed_at_epoch_ms,r=n?.status==="running"&&s&&!i;let l;t[0]===Symbol.for("react.memo_cache_sentinel")?(l=Date.now(),t[0]=l):l=t[0];const c=X.useRef(l);let a;t[1]!==r?(a=h=>{if(!r)return zi;const g=setInterval(()=>{c.current=Date.now(),h()},50);return()=>clearInterval(g)},t[1]=r,t[2]=a):a=t[2];const u=a;let d;t[3]!==r?(d=()=>r?c.current:0,t[3]=r,t[4]=d):d=t[4];const f=d,m=X.useSyncExternalStore(u,f,f),p=i&&s?Math.max(0,i-s):null;let x=null;if(s){let h;t[5]!==s?(h=new Date(s).getTime(),t[5]=s,t[6]=h):h=t[6];const g=h;if(i){let b;t[7]!==i?(b=new Date(i).getTime(),t[7]=i,t[8]=b):b=t[8],x=Math.max(0,b-g)}else r&&(x=Math.max(0,m-g))}return x??p}function zi(){}function Ai(t){if(t<1e3)return`${t}ms`;const e=t/1e3,n=e%60,s=Math.floor(e/60),i=s%60,r=Math.floor(s/60);return r>0?`${r}h ${i}m ${n.toFixed(3)}s`:i>0?`${i}m ${n.toFixed(3)}s`:`${n.toFixed(3)}s`}function Wi(){const t=I.c(29),{setTrackingExecutionId:e}=ne(),n=Y(),{item:s}=de(n),i=Li();let r;t[0]!==i?(r=i!=null?Ai(i):null,t[0]=i,t[1]=r):r=t[1];const l=r,c=s?.status,a=c==="error"||c==="failed",u=(s?.completed_steps?.error?.length??0)>0,d=c==="success"&&u,f=c==="success"&&!u;let m;t[2]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsx("div",{className:"flex items-center justify-center h-full w-12",children:o.jsx(en,{className:"w-4 h-4 text-muted-foreground"})}),t[2]=m):m=t[2];let p;t[3]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsx("strong",{className:"text-base text-foreground",children:"Run"}),t[3]=p):p=t[3];let x;t[4]!==n?(x=o.jsxs("p",{className:"flex gap-3 items-center h-full",children:[p,o.jsxs("span",{className:"text-sm text-muted-foreground",children:["#",n]})]}),t[4]=n,t[5]=x):x=t[5];let h;t[6]!==f?(h=f&&o.jsxs(le,{variant:"success",className:"gap-1 ml-3",children:[o.jsx(tn,{size:11}),"Success"]}),t[6]=f,t[7]=h):h=t[7];let g;t[8]!==d?(g=d&&o.jsxs(le,{variant:"warning",className:"gap-1 ml-3",children:[o.jsx(to,{size:11}),"Partial success"]}),t[8]=d,t[9]=g):g=t[9];let b;t[10]!==a?(b=a&&o.jsxs(le,{variant:"destructive",className:"gap-1 ml-3",children:[o.jsx(eo,{size:11}),"Failed"]}),t[10]=a,t[11]=b):b=t[11];let S;t[12]===Symbol.for("react.memo_cache_sentinel")?(S=o.jsx(Yn,{className:"w-4 h-4 text-muted-foreground"}),t[12]=S):S=t[12];let w;t[13]!==l?(w=o.jsxs("div",{className:"flex items-center gap-1 ml-6",children:[S,o.jsx("span",{className:"text-sm text-muted-foreground",children:l})]}),t[13]=l,t[14]=w):w=t[14];let y;t[15]!==x||t[16]!==h||t[17]!==g||t[18]!==b||t[19]!==w?(y=o.jsxs("div",{className:"flex items-center h-full",children:[m,x,h,g,b,w]}),t[15]=x,t[16]=h,t[17]=g,t[18]=b,t[19]=w,t[20]=y):y=t[20];let j;t[21]!==e?(j=()=>e(void 0),t[21]=e,t[22]=j):j=t[22];let v;t[23]===Symbol.for("react.memo_cache_sentinel")?(v=o.jsx(Nt,{className:"w-4 h-4 text-muted-foreground"}),t[23]=v):v=t[23];let N;t[24]!==j?(N=o.jsx(te,{variant:"ghost",size:"xs",onClick:j,children:v}),t[24]=j,t[25]=N):N=t[25];let k;return t[26]!==N||t[27]!==y?(k=o.jsx("div",{className:"flex flex-col border-b border-border",children:o.jsxs("div",{className:"h-10 bg-accent flex items-center justify-between",children:[y,N]})}),t[26]=N,t[27]=y,t[28]=k):k=t[28],k}function wl(t){const e=I.c(14),{itemId:n}=t;let s;e[0]!==n?(s={itemId:n},e[0]=n,e[1]=s):s=e[1];const{item:i,update:r,isUpdating:l}=Hs(s);let c;e[2]!==i?(c=JSON.stringify(i),e[2]=i,e[3]=c):c=e[3];const a=c;if(!i){let m;return e[4]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsx(Ge,{children:o.jsx("div",{className:"flex h-full w-full bg-background",children:o.jsx(gs,{icon:o.jsx(ws,{className:"w-10 h-10 text-muted-foreground"}),title:"Workflow not found",description:"This workflow may have been deleted or you may not have access to it."})})}),e[4]=m):m=e[4],m}let u;e[5]!==i?(u={workflow:i,trackingExecutionId:void 0,currentStepTab:"input"},e[5]=i,e[6]=u):u=e[6];let d;e[7]!==l||e[8]!==r?(d=o.jsx(Pi,{onUpdate:r,isUpdating:l}),e[7]=l,e[8]=r,e[9]=d):d=e[9];let f;return e[10]!==a||e[11]!==u||e[12]!==d?(f=o.jsx(po,{initialState:u,children:d},a),e[10]=a,e[11]=u,e[12]=d,e[13]=f):f=e[13],f}function Pi(t){const e=I.c(22),{onUpdate:n,isUpdating:s}=t;_i();const i=ue(),r=Y(),{viewMode:l,showExecutionsList:c}=Et(),a=Ve(),u=Ms();let d;e[0]!==n||e[1]!==i?(d=async()=>{await n(i)},e[0]=n,e[1]=i,e[2]=d):d=e[2];const f=d,m=a&&"toolName"in a.action,p=m?a.action.toolName:null,x=m&&!p&&!r,h=u&&!r,g=!x&&!h&&(a||r||!c);let b;e[3]!==f||e[4]!==s||e[5]!==i.description||e[6]!==i.title?(b=o.jsx(wr,{title:i.title,description:i.description,onSave:f,isSaving:s}),e[3]=f,e[4]=s,e[5]=i.description,e[6]=i.title,e[7]=b):b=e[7];let S;e[8]!==r?(S=r&&o.jsx(Wi,{}),e[8]=r,e[9]=S):S=e[9];let w;e[10]!==n||e[11]!==c||e[12]!==h||e[13]!==g||e[14]!==x||e[15]!==l||e[16]!==i?(w=o.jsx("div",{className:"flex-1 overflow-hidden",children:l==="code"?o.jsx(Ri,{workflow:i,onUpdate:n}):o.jsxs(ln,{direction:"horizontal",className:"flex w-full h-full",children:[o.jsx(zt,{defaultSize:50,minSize:30,children:o.jsx(Fr,{})}),o.jsx(cn,{}),o.jsxs(zt,{defaultSize:50,minSize:25,children:[x&&o.jsx(Xr,{className:"border-l border-border"}),h&&o.jsx(Ei,{className:"border-l border-border"}),c&&o.jsx(Si,{}),g&&o.jsx(ei,{className:"border-l border-border"})]})]})}),e[10]=n,e[11]=c,e[12]=h,e[13]=g,e[14]=x,e[15]=l,e[16]=i,e[17]=w):w=e[17];let y;return e[18]!==b||e[19]!==S||e[20]!==w?(y=o.jsx(Ge,{children:o.jsxs("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:[b,S,w]})}),e[18]=b,e[19]=S,e[20]=w,e[21]=y):y=e[21],y}function Di(t){const e=I.c(6),{itemId:n,connectionId:s}=t,i=s??"self",r=i??"no-connection",{org:l}=oe(),c=i??null;let a;e[0]!==l.id||e[1]!==l.slug||e[2]!==c?(a={connectionId:c,orgId:l.id,orgSlug:l.slug},e[0]=l.id,e[1]=l.slug,e[2]=c,e[3]=a):a=e[3];const u=ae(a),d=hs(r,"WORKFLOW_EXECUTION",n,u);let f;return e[4]!==d?(f={item:d},e[4]=d,e[5]=f):f=e[5],f}function vl(t){const e=I.c(7),{itemId:n}=t;let s;e[0]!==n?(s={itemId:n},e[0]=n,e[1]=s):s=e[1];const{item:i}=Di(s);if(!i){let c;return e[2]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx(Ge,{children:o.jsx("div",{className:"flex h-full w-full bg-background",children:o.jsx(gs,{icon:o.jsx(ws,{className:"w-10 h-10 text-muted-foreground"}),title:"Workflow execution not found",description:"This workflow execution may have been deleted or you may not have access to it."})})}),e[2]=c):c=e[2],c}let r;e[3]!==i?(r=JSON.stringify(i,null,2),e[3]=i,e[4]=r):r=e[4];let l;return e[5]!==r?(l=o.jsx(Ge,{children:o.jsx("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:o.jsx(Oe,{height:"100%",code:r,language:"json",readOnly:!0})})}),e[5]=r,e[6]=l):l=e[6],l}export{so as S,vl as W,wl as a};