@xopcai/xopc 0.0.415 → 0.0.417

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 (892) hide show
  1. package/README.md +2 -2
  2. package/README.zh-CN.md +2 -2
  3. package/dist/browser-ext/_locales/en/messages.json +4 -1
  4. package/dist/browser-ext/_locales/zh_CN/messages.json +4 -1
  5. package/dist/browser-ext/dist/assets/{page-context-MuzjMBlJ.js → page-context-BKnEwsOO.js} +2914 -1381
  6. package/dist/browser-ext/dist/background.js +39 -10
  7. package/dist/browser-ext/dist/sidepanel.html +1 -1
  8. package/dist/browser-ext/dist/sidepanel.js +502 -348
  9. package/dist/browser-ext/manifest.json +1 -1
  10. package/dist/extensions/telegram/xopc.extension.json +1 -1
  11. package/dist/gateway/static/root/assets/activity-YogQEteU.js +1 -0
  12. package/dist/gateway/static/root/assets/activity-store-DnqOM8GN.js +1 -0
  13. package/dist/gateway/static/root/assets/agent-avatar-dicebear-1UABT2KS.js +1 -0
  14. package/dist/gateway/static/root/assets/agent-avatar-display-Cy50vjbq.js +2 -0
  15. package/dist/gateway/static/root/assets/agent-defaults-settings-panel-V4NX_cWz.js +1 -0
  16. package/dist/gateway/static/root/assets/agent-display-names-Bje7vfSn.js +1 -0
  17. package/dist/gateway/static/root/assets/agent-plugin-dialog-CQ5LLDMO.js +1 -0
  18. package/dist/gateway/static/root/assets/agents-O7mago-m.js +77 -0
  19. package/dist/gateway/static/root/assets/{agents-admin-api-B1p-ghg9.js → agents-admin-api-CyjykMEh.js} +2 -2
  20. package/dist/gateway/static/root/assets/agents-app-path-ciChvpCS.js +1 -0
  21. package/dist/gateway/static/root/assets/api-C1dxxDZx.js +1 -0
  22. package/dist/gateway/static/root/assets/api-Ddrs70xV.js +1 -0
  23. package/dist/gateway/static/root/assets/app-chrome-BeB4KgOf.js +1 -0
  24. package/dist/gateway/static/root/assets/app-link-CytZ5zkp.js +1 -0
  25. package/dist/gateway/static/root/assets/app-management-settings-panel-C1Zs-eha.js +1 -0
  26. package/dist/gateway/static/root/assets/appearance-settings-lIfGokbz.js +1 -0
  27. package/dist/gateway/static/root/assets/apps-page-CUvtsRYD.js +1 -0
  28. package/dist/gateway/static/root/assets/archive-Dz0hferG.js +1 -0
  29. package/dist/gateway/static/root/assets/{archive-plugin-Ch7wolHE.js → archive-plugin-n5lPr79c.js} +1 -1
  30. package/dist/gateway/static/root/assets/arrow-left-D880xG-P.js +1 -0
  31. package/dist/gateway/static/root/assets/arrow-right-DSSvoX71.js +1 -0
  32. package/dist/gateway/static/root/assets/arrow-up-D5ZtR1QT.js +1 -0
  33. package/dist/gateway/static/root/assets/arrow-up-right-T72JbQ1Q.js +1 -0
  34. package/dist/gateway/static/root/assets/{attachment-preview-renderer-wzIchDSv.js → attachment-preview-renderer-DdOEgexg.js} +3 -3
  35. package/dist/gateway/static/root/assets/{attachment-process-heavy-Db4nTY5N.js → attachment-process-heavy-DGZZ-M85.js} +2 -2
  36. package/dist/gateway/static/root/assets/automation-api-Bld8blNl.js +1 -0
  37. package/dist/gateway/static/root/assets/automation-display-BcfZOQTC.js +2 -0
  38. package/dist/gateway/static/root/assets/{automations-page-DK7AU79v.js → automations-page-oLsNzu_6.js} +1 -1
  39. package/dist/gateway/static/root/assets/automations-workspace-BgtYY2Mm.js +8 -0
  40. package/dist/gateway/static/root/assets/beta-badge-BnzdzIEl.js +1 -0
  41. package/dist/gateway/static/root/assets/{binary-plugins-B4HcHYsC.js → binary-plugins-D9VW7dWP.js} +2 -2
  42. package/dist/gateway/static/root/assets/{block-editor-BQAWEZF-.js → block-editor-C477bTtO.js} +23 -23
  43. package/dist/gateway/static/root/assets/book-open-CCGtrT3R.js +1 -0
  44. package/dist/gateway/static/root/assets/bot-DjLkhyZL.js +1 -0
  45. package/dist/gateway/static/root/assets/box-DvYoGszj.js +1 -0
  46. package/dist/gateway/static/root/assets/braces-Cfmtagno.js +1 -0
  47. package/dist/gateway/static/root/assets/brand-logo-CgT9zQfr.js +1 -0
  48. package/dist/gateway/static/root/assets/briefcase-business-BsoCaI_t.js +1 -0
  49. package/dist/gateway/static/root/assets/browser-BLJWD7WI.js +8 -0
  50. package/dist/gateway/static/root/assets/{browser-automation-inputs-D6AccXaA.js → browser-automation-inputs-CCiYXxmh.js} +1 -1
  51. package/dist/gateway/static/root/assets/browser-automations-page-DIUNY94X.js +3 -0
  52. package/dist/gateway/static/root/assets/browser-control-api-Y3fvmeBk.js +6 -0
  53. package/dist/gateway/static/root/assets/browser-notification-delivery-DmE2FgGc.js +1 -0
  54. package/dist/gateway/static/root/assets/browser-settings-page-DjkGahlz.js +3 -0
  55. package/dist/gateway/static/root/assets/{button-aIC072nz.js → button-CnRSIP6m.js} +1 -1
  56. package/dist/gateway/static/root/assets/calendar-clock-D-quYVPe.js +1 -0
  57. package/dist/gateway/static/root/assets/calendar-days-hw_Y-g-s.js +1 -0
  58. package/dist/gateway/static/root/assets/capabilities-DAyA681v.js +1 -0
  59. package/dist/gateway/static/root/assets/capabilities-DRVXLssH.js +1 -0
  60. package/dist/gateway/static/root/assets/capabilities-page-DFW4Y0x8.js +2 -0
  61. package/dist/gateway/static/root/assets/capabilities-settings-panel-uOHSMQPZ.js +8 -0
  62. package/dist/gateway/static/root/assets/capability-header-actions-CTUCuBlW.js +1 -0
  63. package/dist/gateway/static/root/assets/capability-icon-DVoZxEgW.js +1 -0
  64. package/dist/gateway/static/root/assets/capability-links-DzQWK1Fh.js +1 -0
  65. package/dist/gateway/static/root/assets/channels-D2a69dSt.js +1 -0
  66. package/dist/gateway/static/root/assets/channels-routes-r2g-9DdC.js +1 -0
  67. package/dist/gateway/static/root/assets/chat-agents-api-D5nR_JVe.js +1 -0
  68. package/dist/gateway/static/root/assets/chat-chart-block-K2t333qv.js +2 -0
  69. package/dist/gateway/static/root/assets/chat-page-CG38tCHE.js +71 -0
  70. package/dist/gateway/static/root/assets/chat-page-zQeUaawJ.css +1 -0
  71. package/dist/gateway/static/root/assets/chat-terminal-dock-CkFG6mA3.js +35 -0
  72. package/dist/gateway/static/root/assets/chevron-left-DqFhpbvK.js +1 -0
  73. package/dist/gateway/static/root/assets/chevron-right-BweFrslA.js +1 -0
  74. package/dist/gateway/static/root/assets/chunk-D32TOXHM-DQIy-Baq.js +156 -0
  75. package/dist/gateway/static/root/assets/chunk-KS7C4IRE-CiwuuyV8.js +4 -0
  76. package/dist/gateway/static/root/assets/circle-BoO4YvTx.js +1 -0
  77. package/dist/gateway/static/root/assets/circle-alert-BEjgurr2.js +1 -0
  78. package/dist/gateway/static/root/assets/circle-pause-CN9jYH2s.js +1 -0
  79. package/dist/gateway/static/root/assets/circle-x-DFsCKeya.js +1 -0
  80. package/dist/gateway/static/root/assets/clock-3-DnrAnuyZ.js +1 -0
  81. package/dist/gateway/static/root/assets/cloud-C4-yfnnk.js +1 -0
  82. package/dist/gateway/static/root/assets/cloud-credits-B-nbtkqv.js +1 -0
  83. package/dist/gateway/static/root/assets/code-xml-DJtYhZUF.js +1 -0
  84. package/dist/gateway/static/root/assets/coins-DjP27vUx.js +1 -0
  85. package/dist/gateway/static/root/assets/command-palette-api-Do_66X1B.js +1 -0
  86. package/dist/gateway/static/root/assets/composer-payload-handoff-BU3B-C26.js +1 -0
  87. package/dist/gateway/static/root/assets/computer-settings-page-DBxOcMko.js +1 -0
  88. package/dist/gateway/static/root/assets/confirm-dialog-XGclfBqe.js +1 -0
  89. package/dist/gateway/static/root/assets/connected-providers-grid-Dmnu2zle.js +1 -0
  90. package/dist/gateway/static/root/assets/connector-filters-Cfcx9EA2.js +1 -0
  91. package/dist/gateway/static/root/assets/connector-service-page-rWpnchb3.js +1 -0
  92. package/dist/gateway/static/root/assets/connectors-api-DIBG72k4.js +1 -0
  93. package/dist/gateway/static/root/assets/connectors-page-DT_WrC1y.js +1 -0
  94. package/dist/gateway/static/root/assets/constants-DBtMsXdW.js +1 -0
  95. package/dist/gateway/static/root/assets/copy-text-row-CYIv7RfP.js +1 -0
  96. package/dist/gateway/static/root/assets/cpu-B247669f.js +1 -0
  97. package/dist/gateway/static/root/assets/database-CjjeZfRG.js +1 -0
  98. package/dist/gateway/static/root/assets/date-picker-CE-cZFCU.js +1 -0
  99. package/dist/gateway/static/root/assets/dependency-picker-7SpSfDSg.js +1 -0
  100. package/dist/gateway/static/root/assets/desktop-pet-lorocS9j.js +1 -0
  101. package/dist/gateway/static/root/assets/desktop-pet-narrative-CS8qJpNO.js +1 -0
  102. package/dist/gateway/static/root/assets/desktop-pet-settings-CEcohlZq.js +1 -0
  103. package/dist/gateway/static/root/assets/{desktop-pet-sprite-Bd-aOI7N.js → desktop-pet-sprite-D5YYq2zC.js} +1 -1
  104. package/dist/gateway/static/root/assets/dev-view-store-57HgVuZ6.js +1 -0
  105. package/dist/gateway/static/root/assets/device-pairing-wizard-CLCPuf4R.js +1 -0
  106. package/dist/gateway/static/root/assets/directory-picker-path-field-D4jMhpka.js +1 -0
  107. package/dist/gateway/static/root/assets/discussion-annotation-sync-BKjf9gWe.js +1 -0
  108. package/dist/gateway/static/root/assets/dist-CaUuvp8-.js +1 -0
  109. package/dist/gateway/static/root/assets/dist-DNCdG_qB.js +1 -0
  110. package/dist/gateway/static/root/assets/dist-DfWfZ9iu.js +1 -0
  111. package/dist/gateway/static/root/assets/dist-DusecO_p.js +1 -0
  112. package/dist/gateway/static/root/assets/docx-preview-CnIClbYi.js +20 -0
  113. package/dist/gateway/static/root/assets/earth-BMhZtzcj.js +1 -0
  114. package/dist/gateway/static/root/assets/echarts-runtime-QSmTlXOu.js +18 -0
  115. package/dist/gateway/static/root/assets/electron-env-DHOGevH3.js +1 -0
  116. package/dist/gateway/static/root/assets/extension-debug-page-BsK2LMXQ.js +1 -0
  117. package/dist/gateway/static/root/assets/extension-iframe-host-Dhkk5JV2.js +1 -0
  118. package/dist/gateway/static/root/assets/extension-marketplace-api-CVJPqJOB.js +1 -0
  119. package/dist/gateway/static/root/assets/extension-page-Brps2XDP.js +1 -0
  120. package/dist/gateway/static/root/assets/extension-paths-DvuaZJuy.js +1 -0
  121. package/dist/gateway/static/root/assets/extension-provider-Byrd8Sor.js +1 -0
  122. package/dist/gateway/static/root/assets/extension-settings-page-CHY68DpG.js +1 -0
  123. package/dist/gateway/static/root/assets/file-BqMS_3DT.js +1 -0
  124. package/dist/gateway/static/root/assets/file-archive-DanfQJNe.js +1 -0
  125. package/dist/gateway/static/root/assets/file-preview-surface-BlprUrIs.js +1 -0
  126. package/dist/gateway/static/root/assets/file-text-D12HbeVy.js +1 -0
  127. package/dist/gateway/static/root/assets/file-tree-CFlZnV3Y.js +1 -0
  128. package/dist/gateway/static/root/assets/file-tree-utils-DJs1faGv.js +1 -0
  129. package/dist/gateway/static/root/assets/files-BNL4kkSB.js +1 -0
  130. package/dist/gateway/static/root/assets/floating-ui.dom-seOukHzT.js +1 -0
  131. package/dist/gateway/static/root/assets/folder-CN-pC3XL.js +1 -0
  132. package/dist/gateway/static/root/assets/folder-kanban-CpLlFI1o.js +1 -0
  133. package/dist/gateway/static/root/assets/form-field-width-DJw_jULe.js +1 -0
  134. package/dist/gateway/static/root/assets/{gateway-config-swr-fQKBHBi1.js → gateway-config-swr-BAmUhiP1.js} +1 -1
  135. package/dist/gateway/static/root/assets/gateway-realtime-CsykKL4l.js +1 -0
  136. package/dist/gateway/static/root/assets/gateway-realtime-store-DQqMBruB.js +1 -0
  137. package/dist/gateway/static/root/assets/gateway-restart-Ch128Lrr.js +1 -0
  138. package/dist/gateway/static/root/assets/gateway-settings-BA5-Uuwx.js +1 -0
  139. package/dist/gateway/static/root/assets/{gateway-startup-retry-Cfwxof4k.js → gateway-startup-retry-CtUB3g6N.js} +1 -1
  140. package/dist/gateway/static/root/assets/gauge-C78eD2BA.js +1 -0
  141. package/dist/gateway/static/root/assets/git-branch-Dh9uxTot.js +1 -0
  142. package/dist/gateway/static/root/assets/global-defaults-api-CINf-C6a.js +2 -0
  143. package/dist/gateway/static/root/assets/heart-Cp4rgrqn.js +1 -0
  144. package/dist/gateway/static/root/assets/highlight-code-BH65IIbJ.js +1 -0
  145. package/dist/gateway/static/root/assets/highlighted-body-KQOG7T2V-DKGma5wI.js +1 -0
  146. package/dist/gateway/static/root/assets/history-DXH_9jsE.js +1 -0
  147. package/dist/gateway/static/root/assets/home-page-DaMFBYo1.js +2 -0
  148. package/dist/gateway/static/root/assets/image-Cwyalflz.js +1 -0
  149. package/dist/gateway/static/root/assets/image-generation-api-I_JgLL_m.js +1 -0
  150. package/dist/gateway/static/root/assets/imports-page-BWShtGRQ.js +1 -0
  151. package/dist/gateway/static/root/assets/index-BpCi0TdG.js +11 -0
  152. package/dist/gateway/static/root/assets/index-DY2Y83b9.css +1 -0
  153. package/dist/gateway/static/root/assets/index.module-Cd9ENXfk.js +1 -0
  154. package/dist/gateway/static/root/assets/info-CDrmIZhb.js +1 -0
  155. package/dist/gateway/static/root/assets/install-connector-dialog-DU1Tz7B3.js +1 -0
  156. package/dist/gateway/static/root/assets/interaction-BdhHBbYa.js +1 -0
  157. package/dist/gateway/static/root/assets/is-masked-secret-DOkL5b_X.js +1 -0
  158. package/dist/gateway/static/root/assets/{jszip.min-DT31yWkU.js → jszip.min-Dj17eJqX.js} +1 -1
  159. package/dist/gateway/static/root/assets/key-round-DWbpyU2U.js +1 -0
  160. package/dist/gateway/static/root/assets/keyboard-shortcuts-settings-CdM4BQwp.js +1 -0
  161. package/dist/gateway/static/root/assets/languages-zXtNocoy.js +2 -0
  162. package/dist/gateway/static/root/assets/laptop-CI3hBVrl.js +1 -0
  163. package/dist/gateway/static/root/assets/layers-mJW7JJKm.js +1 -0
  164. package/dist/gateway/static/root/assets/layout-grid-CEVZdVFU.js +1 -0
  165. package/dist/gateway/static/root/assets/list-checks-BbsExAoq.js +1 -0
  166. package/dist/gateway/static/root/assets/list-filter-COkzTdOz.js +1 -0
  167. package/dist/gateway/static/root/assets/list-todo-CTVRto8O.js +1 -0
  168. package/dist/gateway/static/root/assets/list-tree-B0OMswgM.js +1 -0
  169. package/dist/gateway/static/root/assets/local-app-workbench-page-qPflPuQD.js +1 -0
  170. package/dist/gateway/static/root/assets/local-apps-Ck6kACsY.js +1 -0
  171. package/dist/gateway/static/root/assets/local-apps-page-CxyRVfjD.js +1 -0
  172. package/dist/gateway/static/root/assets/local-session-drafts-B9ZPwotC.js +1 -0
  173. package/dist/gateway/static/root/assets/{locale-store-B7s2Hb35.js → locale-store-lIXD1FMw.js} +1 -1
  174. package/dist/gateway/static/root/assets/lock-keyhole-DEK5kH0u.js +1 -0
  175. package/dist/gateway/static/root/assets/logs-page-CbY1N-zi.js +2 -0
  176. package/dist/gateway/static/root/assets/loopi-C09I2mNj.css +1 -0
  177. package/dist/gateway/static/root/assets/loopi-CNtmi9FU.js +1 -0
  178. package/dist/gateway/static/root/assets/management-settings-Diy12JfQ.js +1 -0
  179. package/dist/gateway/static/root/assets/{markdown-editor-phTQ0mox.js → markdown-editor-BuuGlcfG.js} +1 -1
  180. package/dist/gateway/static/root/assets/markdown-view-C-DHb3Io.css +1 -0
  181. package/dist/gateway/static/root/assets/markdown-view-CJt-i2Dp.js +324 -0
  182. package/dist/gateway/static/root/assets/{media-plugins-DYQDjCVQ.js → media-plugins-D_bR23mA.js} +1 -1
  183. package/dist/gateway/static/root/assets/mermaid-MCJ5UELQ-Ur99GwOg.js +1 -0
  184. package/dist/gateway/static/root/assets/mermaid-render-oOellPHt.js +134 -0
  185. package/dist/gateway/static/root/assets/message-circle-Badhj-4D.js +1 -0
  186. package/dist/gateway/static/root/assets/message-square-fVE7Ghj1.js +1 -0
  187. package/dist/gateway/static/root/assets/message-square-plus-XP0tGdlV.js +1 -0
  188. package/dist/gateway/static/root/assets/{messages-BYq0cPbn.js → messages-DRR9N3HC.js} +1 -1
  189. package/dist/gateway/static/root/assets/messages-square-BckAJrEW.js +1 -0
  190. package/dist/gateway/static/root/assets/mic-CuUb7zc-.js +1 -0
  191. package/dist/gateway/static/root/assets/minimize-2-DtOGrlpo.js +1 -0
  192. package/dist/gateway/static/root/assets/mobile-pair-qr-CuIbmw5x.js +1 -0
  193. package/dist/gateway/static/root/assets/model-selector-DCYA_ntf.js +1 -0
  194. package/dist/gateway/static/root/assets/models-hub-cache-za2fWJLg.js +1 -0
  195. package/dist/gateway/static/root/assets/monitor-Af5eAvF7.js +1 -0
  196. package/dist/gateway/static/root/assets/mouse-pointer-2-DZ51Onvj.js +1 -0
  197. package/dist/gateway/static/root/assets/navigation-BkjnOw30.js +1 -0
  198. package/dist/gateway/static/root/assets/network-BUQLY1BV.js +1 -0
  199. package/dist/gateway/static/root/assets/new-session-preferences-gb411vZP.js +1 -0
  200. package/dist/gateway/static/root/assets/note-detail-panel-DBs1yHLy.js +5 -0
  201. package/dist/gateway/static/root/assets/note-image-lightbox-CivkB6LB.js +1 -0
  202. package/dist/gateway/static/root/assets/notes-api-C_458rv5.js +1 -0
  203. package/dist/gateway/static/root/assets/notes-page-DL3c-41a.js +8 -0
  204. package/dist/gateway/static/root/assets/number-input-El7Szeln.js +1 -0
  205. package/dist/gateway/static/root/assets/oauth-api-C3X9FLYw.js +1 -0
  206. package/dist/gateway/static/root/assets/oauth-authorization-window-o6URRos4.js +1 -0
  207. package/dist/gateway/static/root/assets/oauth-provider-connect-H81se_3n.js +1 -0
  208. package/dist/gateway/static/root/assets/package-wATCyihJ.js +1 -0
  209. package/dist/gateway/static/root/assets/page-context-capture-button-BkAlQ7cB.js +1 -0
  210. package/dist/gateway/static/root/assets/page-context-draft-ClLgaOaD.js +1 -0
  211. package/dist/gateway/static/root/assets/page-header-store-DH8K0xii.js +1 -0
  212. package/dist/gateway/static/root/assets/page-tabs-oeTY7z3_.js +1 -0
  213. package/dist/gateway/static/root/assets/panel-left-C8MqSXRZ.js +1 -0
  214. package/dist/gateway/static/root/assets/panel-right-CFGrHTsD.js +1 -0
  215. package/dist/gateway/static/root/assets/paperclip-f1HujQY1.js +1 -0
  216. package/dist/gateway/static/root/assets/pause-DuPxgSxk.js +1 -0
  217. package/dist/gateway/static/root/assets/{pdf-D4PI9qAw.js → pdf-EQHMWEbX.js} +3 -3
  218. package/dist/gateway/static/root/assets/pdf-runtime-JnUAvfIa.js +2 -0
  219. package/dist/gateway/static/root/assets/{pdf.worker.min-B4E34YdZ.js → pdf.worker.min-bpyjgR8v.js} +7 -7
  220. package/dist/gateway/static/root/assets/pencil-DmIY3Oa-.js +1 -0
  221. package/dist/gateway/static/root/assets/personal-avatar-BLtHt8fV.js +1 -0
  222. package/dist/gateway/static/root/assets/personal-avatar-BUCb7OiW.css +1 -0
  223. package/dist/gateway/static/root/assets/personal-page-B5DP3lO-.js +1 -0
  224. package/dist/gateway/static/root/assets/personal-proactivity-DaRnbB1f.js +1 -0
  225. package/dist/gateway/static/root/assets/personal-settings-panel-DjDc5Kaz.js +1 -0
  226. package/dist/gateway/static/root/assets/phone-dependencies-card-DISHarj8.js +1 -0
  227. package/dist/gateway/static/root/assets/phone-model-picker-u8YIQCgo.js +1 -0
  228. package/dist/gateway/static/root/assets/phone-settings-page-el3pT0PD.js +1 -0
  229. package/dist/gateway/static/root/assets/phone-workspace-store-fhnZrgy_.js +1 -0
  230. package/dist/gateway/static/root/assets/pin-off-BMRv-Kxr.js +1 -0
  231. package/dist/gateway/static/root/assets/play-kxZvpBg8.js +1 -0
  232. package/dist/gateway/static/root/assets/plug-DKYPEgkR.js +1 -0
  233. package/dist/gateway/static/root/assets/plug-zap-L8NMe3Sv.js +1 -0
  234. package/dist/gateway/static/root/assets/plugin-details-dialog-CTBs1Jde.js +1 -0
  235. package/dist/gateway/static/root/assets/plus-Q2yW6OE7.js +1 -0
  236. package/dist/gateway/static/root/assets/popover-select-DniHw2dy.js +1 -0
  237. package/dist/gateway/static/root/assets/power-ZI-pBczI.js +1 -0
  238. package/dist/gateway/static/root/assets/power-off-CwwQ7Gp7.js +1 -0
  239. package/dist/gateway/static/root/assets/preference-select-fields-D7oluyHN.js +1 -0
  240. package/dist/gateway/static/root/assets/preload-helper-Czpn1I53.js +1 -0
  241. package/dist/gateway/static/root/assets/preview-open-alternatives-CY_hjK4b.js +1 -0
  242. package/dist/gateway/static/root/assets/product-automation-feedback-DsUSqCOX.js +7 -0
  243. package/dist/gateway/static/root/assets/product-delivery-BU_H84jL.js +1 -0
  244. package/dist/gateway/static/root/assets/product-navigation-Co8pLbDP.js +1 -0
  245. package/dist/gateway/static/root/assets/product-open-page-xn9G4hSI.js +1 -0
  246. package/dist/gateway/static/root/assets/product-preview-content-DcoK-iZe.js +1 -0
  247. package/dist/gateway/static/root/assets/product-preview-modal-Ruw9WSKK.js +2 -0
  248. package/dist/gateway/static/root/assets/project-detail-page-BKvWLiMw.js +7 -0
  249. package/dist/gateway/static/root/assets/project-understanding-BCQr0AZ_.js +1 -0
  250. package/dist/gateway/static/root/assets/projects-page-D4g7bB7X.js +1 -0
  251. package/dist/gateway/static/root/assets/providers-api-CzVkFKFg.js +1 -0
  252. package/dist/gateway/static/root/assets/puzzle-BptcPjKI.js +1 -0
  253. package/dist/gateway/static/root/assets/recording-upload-0jxahBMo.js +1 -0
  254. package/dist/gateway/static/root/assets/refresh-button-bU_0NarN.js +1 -0
  255. package/dist/gateway/static/root/assets/refresh-cw-BRlGaq2w.js +1 -0
  256. package/dist/gateway/static/root/assets/{registry-api-BcfoLEna.js → registry-api-n8TwtJ_j.js} +2 -2
  257. package/dist/gateway/static/root/assets/remote-access-hub-cZpBi4Rk.js +1 -0
  258. package/dist/gateway/static/root/assets/rotate-ccw-JM1TBLpp.js +1 -0
  259. package/dist/gateway/static/root/assets/rotate-cw-LIg3Am9S.js +1 -0
  260. package/dist/gateway/static/root/assets/route-preload-B5UiReO7.js +2 -0
  261. package/dist/gateway/static/root/assets/runtime-health-D2TDFLLq.js +1 -0
  262. package/dist/gateway/static/root/assets/{runtime-tools-api-DesqGCnE.js → runtime-tools-api-D-8KjYK6.js} +1 -1
  263. package/dist/gateway/static/root/assets/runtime-tools-settings-panel-MKlLFuow.js +1 -0
  264. package/dist/gateway/static/root/assets/save-DRDABU--.js +1 -0
  265. package/dist/gateway/static/root/assets/schema-form-v4N4lawq.js +1 -0
  266. package/dist/gateway/static/root/assets/schemas-CCWMleym.js +55 -0
  267. package/dist/gateway/static/root/assets/search-DA7gz22f.js +1 -0
  268. package/dist/gateway/static/root/assets/secret-input-BQvFXqzz.js +1 -0
  269. package/dist/gateway/static/root/assets/secret-input-labels-B5Jl5HqK.js +1 -0
  270. package/dist/gateway/static/root/assets/segmented-styles-Cqb91xsn.js +1 -0
  271. package/dist/gateway/static/root/assets/send-1f1Ntw6E.js +1 -0
  272. package/dist/gateway/static/root/assets/server-BlHCBjiE.js +1 -0
  273. package/dist/gateway/static/root/assets/service-recommendation-list-B1xuVT3N.js +1 -0
  274. package/dist/gateway/static/root/assets/{session-api-DdQnMwkl.js → session-api-CsCoI2im.js} +1 -1
  275. package/dist/gateway/static/root/assets/session-channel-icon-SsY70Z6t.js +1 -0
  276. package/dist/gateway/static/root/assets/session-identity-label-B7sgG1PE.js +1 -0
  277. package/dist/gateway/static/root/assets/session-manager-5l9q0cd5.js +16 -0
  278. package/dist/gateway/static/root/assets/sessions-page-DsLw2aMD.js +1 -0
  279. package/dist/gateway/static/root/assets/settings-2-D-csvaET.js +1 -0
  280. package/dist/gateway/static/root/assets/settings-advanced-gate-B5lQeVNi.js +1 -0
  281. package/dist/gateway/static/root/assets/settings-advanced-section-BqoVSko2.js +1 -0
  282. package/dist/gateway/static/root/assets/settings-form-draft-Dy10ldo8.js +1 -0
  283. package/dist/gateway/static/root/assets/settings-form-section-num14vSv.js +1 -0
  284. package/dist/gateway/static/root/assets/settings-loading-skeleton-BTqvr_Fw.js +1 -0
  285. package/dist/gateway/static/root/assets/settings-mode-store-CBsJ-Qg2.js +1 -0
  286. package/dist/gateway/static/root/assets/settings-page-DROUGyJl.js +1 -0
  287. package/dist/gateway/static/root/assets/settings-page-header-Bv-kQFTm.js +1 -0
  288. package/dist/gateway/static/root/assets/settings-page-layout-DHP6MrrL.js +1 -0
  289. package/dist/gateway/static/root/assets/settings-uiTATseT.js +1 -0
  290. package/dist/gateway/static/root/assets/setup-status-panel-MJE3B_LX.js +1 -0
  291. package/dist/gateway/static/root/assets/share-link-dialog-BJHRQVKC.js +1 -0
  292. package/dist/gateway/static/root/assets/share-preview-page-Bsrv_zOQ.js +2 -0
  293. package/dist/gateway/static/root/assets/shares-api-rtWVHA_d.js +1 -0
  294. package/dist/gateway/static/root/assets/shares-settings-CfIRv4uX.js +1 -0
  295. package/dist/gateway/static/root/assets/shield-B1sI_cxl.js +1 -0
  296. package/dist/gateway/static/root/assets/shield-check-BU58siTV.js +1 -0
  297. package/dist/gateway/static/root/assets/shield-off-2jsucUds.js +1 -0
  298. package/dist/gateway/static/root/assets/side-chat-shortcut-BIw-1TTD.js +1 -0
  299. package/dist/gateway/static/root/assets/skill-api-B_W1K3sv.js +1 -0
  300. package/dist/gateway/static/root/assets/skill-api-utils-C7V4JVXM.js +1 -0
  301. package/dist/gateway/static/root/assets/skill-list-api-BzlKXPsE.js +1 -0
  302. package/dist/gateway/static/root/assets/skill-reload-api-Cff2GgZb.js +1 -0
  303. package/dist/gateway/static/root/assets/skill-wire-pattern-BPpeIcCi.js +1 -0
  304. package/dist/gateway/static/root/assets/skills-page-DtBloYeU.js +2 -0
  305. package/dist/gateway/static/root/assets/sliders-horizontal-DqsYor6I.js +1 -0
  306. package/dist/gateway/static/root/assets/sliding-tab-list-DuQyViqe.js +1 -0
  307. package/dist/gateway/static/root/assets/smartphone-DSSsQFqA.js +1 -0
  308. package/dist/gateway/static/root/assets/{source-workspace-editor-BIvi89Zx.js → source-workspace-editor-kxosllTu.js} +1 -1
  309. package/dist/gateway/static/root/assets/sparkles-DHlfQFAF.js +1 -0
  310. package/dist/gateway/static/root/assets/specialists-xbB3xL9e.js +1 -0
  311. package/dist/gateway/static/root/assets/square-DMK_fB-3.js +1 -0
  312. package/dist/gateway/static/root/assets/square-pen-B8FsvqNu.js +1 -0
  313. package/dist/gateway/static/root/assets/square-terminal-K87bylpZ.js +1 -0
  314. package/dist/gateway/static/root/assets/star-BUWJqJ5c.js +1 -0
  315. package/dist/gateway/static/root/assets/stethoscope-DRqTAtjD.js +1 -0
  316. package/dist/gateway/static/root/assets/sticky-note-fzP7NAJq.js +1 -0
  317. package/dist/gateway/static/root/assets/store-SzD1Jvgm.js +1 -0
  318. package/dist/gateway/static/root/assets/system-settings-panel-BeQeUUMH.js +1 -0
  319. package/dist/gateway/static/root/assets/task-detail-page-Drrv-Hp0.js +2 -0
  320. package/dist/gateway/static/root/assets/task-result-evidence-D1Kyskm_.js +1 -0
  321. package/dist/gateway/static/root/assets/tasks-DRmd6sWt.js +1 -0
  322. package/dist/gateway/static/root/assets/terminal-oKqqZdiG.js +1 -0
  323. package/dist/gateway/static/root/assets/terminal-panel-store-5Fzctajw.js +1 -0
  324. package/dist/gateway/static/root/assets/theme-store-DW45fWYQ.js +1 -0
  325. package/dist/gateway/static/root/assets/timer-rCwGHjuO.js +1 -0
  326. package/dist/gateway/static/root/assets/tool-friendly-title-DGmi7rCQ.js +1 -0
  327. package/dist/gateway/static/root/assets/tracing-settings-page-B12u5D9A.js +1 -0
  328. package/dist/gateway/static/root/assets/trash-2-DusmjVPV.js +1 -0
  329. package/dist/gateway/static/root/assets/triangle-alert-2JXFNNKU.js +1 -0
  330. package/dist/gateway/static/root/assets/tunnel-api-DGO56LQU.js +1 -0
  331. package/dist/gateway/static/root/assets/understanding-activity-store-CTe6TFB0.js +1 -0
  332. package/dist/gateway/static/root/assets/understanding-refresh-store-mE9OKG6q.js +1 -0
  333. package/dist/gateway/static/root/assets/unlink-BEuthaaq.js +1 -0
  334. package/dist/gateway/static/root/assets/upload-rrb46c3c.js +1 -0
  335. package/dist/gateway/static/root/assets/usage-page-Ud2U9UG1.js +1 -0
  336. package/dist/gateway/static/root/assets/use-async-resource-BHFGZCY2.js +1 -0
  337. package/dist/gateway/static/root/assets/use-autosave-Cs2Ga_Y_.js +1 -0
  338. package/dist/gateway/static/root/assets/use-composer-attachments-BCbMj-MN.js +2 -0
  339. package/dist/gateway/static/root/assets/use-directory-picker-C4p7AgWY.js +1 -0
  340. package/dist/gateway/static/root/assets/use-file-preview-expanded-DSpCRXUW.js +2 -0
  341. package/dist/gateway/static/root/assets/use-media-query-ady-FgjK.js +1 -0
  342. package/dist/gateway/static/root/assets/use-personal-profile-BHL2AxWU.js +1 -0
  343. package/dist/gateway/static/root/assets/use-workspace-tree-CnmPZrpx.js +1 -0
  344. package/dist/gateway/static/root/assets/user-model-page-p5iPfnwl.js +2 -0
  345. package/dist/gateway/static/root/assets/user-round-C9jxPhMR.js +1 -0
  346. package/dist/gateway/static/root/assets/{vendor-codemirror-Qdcjid65.js → vendor-codemirror-aCQ0FcJT.js} +8 -8
  347. package/dist/gateway/static/root/assets/{vendor-swr-BIWyz7Rc.js → vendor-swr-CdRzEUwF.js} +1 -1
  348. package/dist/gateway/static/root/assets/video-B6V0GFss.js +1 -0
  349. package/dist/gateway/static/root/assets/voice-api-key-field-3gyc2UV3.js +1 -0
  350. package/dist/gateway/static/root/assets/voice-call-context-BM2A4bLz.js +1 -0
  351. package/dist/gateway/static/root/assets/{voice-config-api-BkUlN7GH.js → voice-config-api-Cda2uBIC.js} +1 -1
  352. package/dist/gateway/static/root/assets/voice-input-shortcut-events-DtYHsPLF.js +1 -0
  353. package/dist/gateway/static/root/assets/voice-transcribe-api-TInEfIYo.js +1 -0
  354. package/dist/gateway/static/root/assets/volume-2-BSJhAY97.js +1 -0
  355. package/dist/gateway/static/root/assets/wand-sparkles-CkSL-3Fy.js +1 -0
  356. package/dist/gateway/static/root/assets/{with-selector-aYPsXwdl.js → with-selector-xonYxPoM.js} +1 -1
  357. package/dist/gateway/static/root/assets/work-discovery-overlay-Dqu5CQCS.js +1 -0
  358. package/dist/gateway/static/root/assets/work-discovery-page-p-8ciZ0i.js +1 -0
  359. package/dist/gateway/static/root/assets/working-directory-picker-modal-DHl2cZY1.js +1 -0
  360. package/dist/gateway/static/root/assets/workspace-api-CtDbI6T7.js +2 -0
  361. package/dist/gateway/static/root/assets/workspace-editor-agent-store-B94Q2nN8.js +1 -0
  362. package/dist/gateway/static/root/assets/workspace-file-preview-dialog-CTIbUfKb.js +1 -0
  363. package/dist/gateway/static/root/assets/workspace-open-location-menu-BwxouqdZ.js +1 -0
  364. package/dist/gateway/static/root/assets/wrench-DFb4r8bH.js +1 -0
  365. package/dist/gateway/static/root/assets/x-B_N4OPjy.js +1 -0
  366. package/dist/gateway/static/root/assets/{xlsx-CKkngM-o.js → xlsx-Cl_0CZaL.js} +11 -11
  367. package/dist/gateway/static/root/assets/xml-_d7dTN2Q.js +3 -0
  368. package/dist/gateway/static/root/assets/xopc-cloud-account-card-CFb-23rS.js +1 -0
  369. package/dist/gateway/static/root/assets/zap-dximCGjy.js +1 -0
  370. package/dist/gateway/static/root/browser-setup-test.html +5 -0
  371. package/dist/gateway/static/root/browser-setup-test.js +7 -0
  372. package/dist/gateway/static/root/index.html +267 -46
  373. package/dist/package.js +1 -1
  374. package/dist/packages/gateway-contract/src/browser-setup.js +6 -0
  375. package/dist/packages/gateway-contract/src/index.js +4 -0
  376. package/dist/packages/gateway-contract/src/phone-setup.js +6 -0
  377. package/dist/packages/realtime-client/src/index.js +1 -0
  378. package/dist/packages/realtime-protocol/src/index.js +1 -0
  379. package/dist/src/activity/emitter.js +1 -2
  380. package/dist/src/activity/service.js +1 -2
  381. package/dist/src/agent/agent-manager.d.ts +5 -0
  382. package/dist/src/agent/agent-manager.js +16 -6
  383. package/dist/src/agent/background-review/run-background-review.js +2 -3
  384. package/dist/src/agent/context/execution-context.js +1 -2
  385. package/dist/src/agent/context/execution-scope.js +1 -2
  386. package/dist/src/agent/context/project-context.js +1 -2
  387. package/dist/src/agent/embedded/agent-profile-context.js +1 -2
  388. package/dist/src/agent/embedded/run-turn.js +2 -4
  389. package/dist/src/agent/embedded/sqlite-hydrating-session-manager.js +1 -2
  390. package/dist/src/agent/embedded/tool-search-extension.js +14 -1
  391. package/dist/src/agent/external-tools/cliProvider.js +3 -4
  392. package/dist/src/agent/external-tools/composio-provider.js +3 -4
  393. package/dist/src/agent/external-tools/endpoint-provider.js +2 -2
  394. package/dist/src/agent/memory/compaction-promotion.js +1 -2
  395. package/dist/src/agent/orchestration/research-checkpoint.js +26 -31
  396. package/dist/src/agent/prompt/response-language.js +1 -2
  397. package/dist/src/agent/prompt/service-prompt-builder.js +3 -6
  398. package/dist/src/agent/prompt/system-prompt.js +1 -2
  399. package/dist/src/agent/service/direct-turn-helpers.js +1 -2
  400. package/dist/src/agent/service/process-direct-streaming.js +1 -2
  401. package/dist/src/agent/service/webchat-tts.js +1 -2
  402. package/dist/src/agent/service.d.ts +1 -0
  403. package/dist/src/agent/service.js +8 -3
  404. package/dist/src/agent/service.types.d.ts +3 -0
  405. package/dist/src/agent/skills/index.js +1 -1
  406. package/dist/src/agent/skills/managed-store.js +1 -1
  407. package/dist/src/agent/skills/skill-manage-ops.js +1 -1
  408. package/dist/src/agent/tool-manuals/computer.d.ts +1 -1
  409. package/dist/src/agent/tool-manuals/computer.js +2 -0
  410. package/dist/src/agent/tool-manuals/phone.d.ts +1 -1
  411. package/dist/src/agent/tool-manuals/phone.js +14 -4
  412. package/dist/src/agent/tool-manuals/xopc-configuration.d.ts +2 -0
  413. package/dist/src/agent/tool-manuals/xopc-configuration.js +29 -0
  414. package/dist/src/agent/tools/browser/tool/browser-use-tool.d.ts +2 -0
  415. package/dist/src/agent/tools/browser/tool/browser-use-tool.js +6 -2
  416. package/dist/src/agent/tools/delegate-tool.js +2 -4
  417. package/dist/src/agent/tools/factory.d.ts +4 -0
  418. package/dist/src/agent/tools/factory.js +23 -9
  419. package/dist/src/agent/tools/personal-read-tool.js +1 -1
  420. package/dist/src/agent/tools/personal-task-tool.js +1 -2
  421. package/dist/src/agent/tools/phone-use-tool.d.ts +2 -0
  422. package/dist/src/agent/tools/phone-use-tool.js +79 -4
  423. package/dist/src/agent/tools/research-checkpoint-tool.js +1 -2
  424. package/dist/src/agent/tools/tool-manual-tool.d.ts +1 -1
  425. package/dist/src/agent/tools/tool-manual-tool.js +3 -1
  426. package/dist/src/agent/tools/toolExposure.js +3 -0
  427. package/dist/src/agent/tools/xopc-use-tool.d.ts +5 -2
  428. package/dist/src/agent/tools/xopc-use-tool.js +47 -6
  429. package/dist/src/agent-catalog/capabilities.js +2 -2
  430. package/dist/src/agent-catalog/repository.js +3 -4
  431. package/dist/src/agent-catalog/test-support.js +1 -2
  432. package/dist/src/agent-matching/selection-repository.js +1 -2
  433. package/dist/src/automations/capabilities/drafts.js +3 -5
  434. package/dist/src/bootstrap/application-state.js +1 -2
  435. package/dist/src/browser/automations/repository.js +1 -2
  436. package/dist/src/browser/drivers/browser-driver.d.ts +2 -2
  437. package/dist/src/browser/drivers/extension-driver.d.ts +2 -2
  438. package/dist/src/browser/drivers/extension-driver.js +6 -3
  439. package/dist/src/browser/native-messaging-host.js +2 -4
  440. package/dist/src/browser/providers/browser-ext-install.js +3 -2
  441. package/dist/src/browser/providers/realtime-extension.js +1 -2
  442. package/dist/src/browser/recordings/service.js +1 -2
  443. package/dist/src/browser/runtime/browser-runtime.d.ts +4 -1
  444. package/dist/src/browser/runtime/browser-runtime.js +29 -17
  445. package/dist/src/browser/setup/repository.d.ts +5 -0
  446. package/dist/src/browser/setup/repository.js +42 -0
  447. package/dist/src/browser/setup/service.d.ts +157 -0
  448. package/dist/src/browser/setup/service.js +433 -0
  449. package/dist/src/browser/setup/types.d.ts +38 -0
  450. package/dist/src/browser/setup/types.js +1 -0
  451. package/dist/src/capabilities/runtime/dispatcher.js +1 -1
  452. package/dist/src/capabilities/runtime/product.js +1 -1
  453. package/dist/src/chat-previews/store.js +1 -2
  454. package/dist/src/cli/commands/agents.js +1 -1
  455. package/dist/src/cli/commands/doctor/checks/automation-integrity.js +1 -2
  456. package/dist/src/cli/commands/doctor/checks/database-relations.js +1 -2
  457. package/dist/src/cli/commands/doctor/checks/database-schema.js +2 -3
  458. package/dist/src/cli/commands/doctor/checks/node-version.js +6 -6
  459. package/dist/src/cli/commands/doctor/checks/session-integrity.js +1 -2
  460. package/dist/src/cli/commands/gateway/lifecycle.js +1 -1
  461. package/dist/src/cli/commands/gateway/shared.js +1 -2
  462. package/dist/src/cli/commands/history.js +1 -2
  463. package/dist/src/cli/commands/models.js +1 -1
  464. package/dist/src/cli/commands/onboard/model.js +1 -1
  465. package/dist/src/cli/commands/project.js +1 -2
  466. package/dist/src/cli/utils/init-workspace-core.js +1 -1
  467. package/dist/src/computer/diagnostics.d.ts +7 -7
  468. package/dist/src/computer/diagnostics.js +8 -2
  469. package/dist/src/computer/errors.js +9 -1
  470. package/dist/src/computer/evaluation.d.ts +4 -4
  471. package/dist/src/computer/keyboard.d.ts +1 -1
  472. package/dist/src/computer/keyboard.js +10 -2
  473. package/dist/src/computer/model-adapter.js +27 -7
  474. package/dist/src/config/agent-profile.js +1 -1
  475. package/dist/src/config/gateway-bind.js +1 -2
  476. package/dist/src/config/schema.d.ts +7 -0
  477. package/dist/src/connectors/cli/lifecycle.js +1 -2
  478. package/dist/src/connectors/composio-managed-events.js +1 -2
  479. package/dist/src/connectors/connected-source-ingestion.js +1 -2
  480. package/dist/src/connectors/connected-source-understanding.js +3 -5
  481. package/dist/src/connectors/content-enrichment.js +1 -2
  482. package/dist/src/connectors/learning-coordinator.js +2 -3
  483. package/dist/src/connectors/runtime-adapter-registry.js +1 -2
  484. package/dist/src/daemon/constants.js +9 -14
  485. package/dist/src/daemon/index.js +1 -4
  486. package/dist/src/daemon/install-plan.js +1 -2
  487. package/dist/src/daemon/launchd.js +1 -2
  488. package/dist/src/daemon/schtasks.js +1 -2
  489. package/dist/src/daemon/service-audit.js +1 -2
  490. package/dist/src/daemon/service.js +1 -2
  491. package/dist/src/daemon/systemd.js +1 -2
  492. package/dist/src/discussions/analyzer.d.ts +3 -3
  493. package/dist/src/endpoint-tools/runtime.js +1 -2
  494. package/dist/src/execution-environments/local-worktree-manager.js +1 -1
  495. package/dist/src/execution-environments/subject.js +1 -2
  496. package/dist/src/extensions/agent-plugins/branding.js +2 -1
  497. package/dist/src/extensions/agent-plugins/cli-authorization.js +2 -1
  498. package/dist/src/extensions/agent-plugins/contained-path.d.ts +1 -0
  499. package/dist/src/extensions/agent-plugins/contained-path.js +29 -0
  500. package/dist/src/extensions/agent-plugins/mcp-adapter.js +2 -1
  501. package/dist/src/extensions/agent-plugins/resources.js +1 -1
  502. package/dist/src/extensions/agent-plugins/skill-catalog.js +3 -2
  503. package/dist/src/extensions/agent-plugins/source-catalog.js +1 -1
  504. package/dist/src/extensions/agent-plugins/store.js +2 -1
  505. package/dist/src/extensions/agent-plugins/validation.d.ts +1 -2
  506. package/dist/src/extensions/agent-plugins/validation.js +3 -26
  507. package/dist/src/gateway/agent-builtin-tools.d.ts +1 -1
  508. package/dist/src/gateway/agents-admin.js +2 -2
  509. package/dist/src/gateway/client-ip.js +1 -2
  510. package/dist/src/gateway/file-space-service.js +1 -2
  511. package/dist/src/gateway/global-defaults-admin.js +1 -1
  512. package/dist/src/gateway/hono/app.js +2 -4
  513. package/dist/src/gateway/hono/middleware/auth.js +3 -6
  514. package/dist/src/gateway/hono/middleware/logger.js +1 -2
  515. package/dist/src/gateway/hono/middleware/public-device-rate-limit.js +1 -2
  516. package/dist/src/gateway/hono/middleware/scopes.js +1 -2
  517. package/dist/src/gateway/hono/middleware/strict-rate-limit.js +1 -2
  518. package/dist/src/gateway/hono/oauth-async.js +1 -2
  519. package/dist/src/gateway/hono/routes/agents.js +1 -1
  520. package/dist/src/gateway/hono/routes/browser-session.js +1 -2
  521. package/dist/src/gateway/hono/routes/browser-setup.d.ts +3 -0
  522. package/dist/src/gateway/hono/routes/browser-setup.js +114 -0
  523. package/dist/src/gateway/hono/routes/browser.d.ts +2 -1
  524. package/dist/src/gateway/hono/routes/browser.js +4 -7
  525. package/dist/src/gateway/hono/routes/cli-connectors.js +1 -2
  526. package/dist/src/gateway/hono/routes/composer-history.js +1 -2
  527. package/dist/src/gateway/hono/routes/config-patch/misc.js +1 -1
  528. package/dist/src/gateway/hono/routes/config.js +1 -2
  529. package/dist/src/gateway/hono/routes/connectors.js +9 -11
  530. package/dist/src/gateway/hono/routes/context-sources.js +1 -2
  531. package/dist/src/gateway/hono/routes/device-pairing-approval.js +2 -4
  532. package/dist/src/gateway/hono/routes/device-push.js +1 -2
  533. package/dist/src/gateway/hono/routes/devices.js +4 -8
  534. package/dist/src/gateway/hono/routes/discussions.js +1 -2
  535. package/dist/src/gateway/hono/routes/endpoint-tools.js +1 -2
  536. package/dist/src/gateway/hono/routes/home.js +2 -3
  537. package/dist/src/gateway/hono/routes/interaction-state.js +1 -2
  538. package/dist/src/gateway/hono/routes/lazy-bundles.js +8 -0
  539. package/dist/src/gateway/hono/routes/memory-learning.js +1 -2
  540. package/dist/src/gateway/hono/routes/notes.js +2 -2
  541. package/dist/src/gateway/hono/routes/personal-agent.js +1 -2
  542. package/dist/src/gateway/hono/routes/phone-dependencies.js +2 -7
  543. package/dist/src/gateway/hono/routes/phone-setup.d.ts +7 -0
  544. package/dist/src/gateway/hono/routes/phone-setup.js +231 -0
  545. package/dist/src/gateway/hono/routes/phone-wireless.d.ts +4 -0
  546. package/dist/src/gateway/hono/routes/phone-wireless.js +63 -0
  547. package/dist/src/gateway/hono/routes/phone.js +119 -28
  548. package/dist/src/gateway/hono/routes/projects.js +3 -4
  549. package/dist/src/gateway/hono/routes/public-gateway.js +4 -3
  550. package/dist/src/gateway/hono/routes/session-input-handler.js +1 -1
  551. package/dist/src/gateway/hono/routes/sessions.js +2 -4
  552. package/dist/src/gateway/hono/routes/shares.js +2 -4
  553. package/dist/src/gateway/hono/routes/tasks.js +2 -3
  554. package/dist/src/gateway/hono/routes/user-model-refresh.js +1 -2
  555. package/dist/src/gateway/hono/routes/user-model.js +1 -2
  556. package/dist/src/gateway/host.js +4 -9
  557. package/dist/src/gateway/image-generation-setup.js +1 -1
  558. package/dist/src/gateway/index.js +2 -6
  559. package/dist/src/gateway/listen.js +1 -2
  560. package/dist/src/gateway/next-turn-suggestions/service.js +1 -2
  561. package/dist/src/gateway/next-turn-suggestions/snapshot.js +1 -2
  562. package/dist/src/gateway/provider-model-setup.js +1 -1
  563. package/dist/src/gateway/rate-limit/auth-policy.js +11 -7
  564. package/dist/src/gateway/rate-limit/buckets.js +220 -211
  565. package/dist/src/gateway/rate-limit/env-flags.js +1 -4
  566. package/dist/src/gateway/rate-limit/index.js +4 -13
  567. package/dist/src/gateway/runtime-config.js +2 -4
  568. package/dist/src/gateway/security/audit.js +1 -2
  569. package/dist/src/gateway/security/browser-session.js +1 -2
  570. package/dist/src/gateway/security/device-request-proof.d.ts +1 -2
  571. package/dist/src/gateway/security/device-request-proof.js +2 -4
  572. package/dist/src/gateway/security/gateway-scopes.js +2 -6
  573. package/dist/src/gateway/security/index.js +1 -4
  574. package/dist/src/gateway/security/loopback.js +6 -7
  575. package/dist/src/gateway/service/agent-runner.js +2 -4
  576. package/dist/src/gateway/service/app-context-access.js +1 -2
  577. package/dist/src/gateway/service/config-coordinator.d.ts +4 -0
  578. package/dist/src/gateway/service/run-gateway-agent.js +2 -4
  579. package/dist/src/gateway/service/session-input-coordinator.js +3 -6
  580. package/dist/src/gateway/service.d.ts +5 -0
  581. package/dist/src/gateway/service.js +64 -22
  582. package/dist/src/gateway/session-context-summary.js +2 -4
  583. package/dist/src/gateway/tailscale-auth.js +1 -2
  584. package/dist/src/gateway/ws-security.js +1 -2
  585. package/dist/src/gateway/xopc-cloud-capability-setup.js +8 -2
  586. package/dist/src/home-intelligence/host.js +2 -2
  587. package/dist/src/imports/importService.js +1 -1
  588. package/dist/src/infra/rate-limit/failure-limiter.js +90 -78
  589. package/dist/src/infra/rate-limit/index.js +3 -11
  590. package/dist/src/infra/rate-limit/keyed-store.js +47 -52
  591. package/dist/src/infra/rate-limit/rate-limiter.js +58 -55
  592. package/dist/src/infra/update-restart.js +1 -1
  593. package/dist/src/infra/update-service-refresh.js +1 -2
  594. package/dist/src/knowledge/chunks.js +1 -4
  595. package/dist/src/knowledge/connected-knowledge-pipeline.js +3 -6
  596. package/dist/src/knowledge/ingestion-service.js +1 -2
  597. package/dist/src/knowledge-memory/repository.js +1 -2
  598. package/dist/src/local-apps/service.js +1 -1
  599. package/dist/src/local-apps/store.js +1 -2
  600. package/dist/src/media/session-references.js +1 -2
  601. package/dist/src/memory-learning/forget-capture.js +1 -2
  602. package/dist/src/memory-learning/forgotten-history.js +3 -6
  603. package/dist/src/memory-learning/service.js +1 -2
  604. package/dist/src/memory-learning/source-learning.js +3 -3
  605. package/dist/src/memory-learning/task-receipts.js +1 -2
  606. package/dist/src/memory-learning/work-candidate.d.ts +29 -0
  607. package/dist/src/memory-learning/work-candidate.js +31 -0
  608. package/dist/src/memory-learning/work-capture.d.ts +2 -29
  609. package/dist/src/memory-learning/work-capture.js +2 -30
  610. package/dist/src/memory-maintenance/service.js +1 -2
  611. package/dist/src/notes/agent-context.js +1 -2
  612. package/dist/src/notes/attachment-ref.js +4 -8
  613. package/dist/src/notes/note-attachment-sync.js +1 -2
  614. package/dist/src/notes/note-index-meta.js +7 -14
  615. package/dist/src/notes/note-markdown.js +7 -13
  616. package/dist/src/notes/service.js +3 -6
  617. package/dist/src/notes/store.js +2 -4
  618. package/dist/src/notifications/clarification.js +1 -2
  619. package/dist/src/notifications/service.js +1 -2
  620. package/dist/src/personal-agent/proactivity/repository.js +1 -2
  621. package/dist/src/personal-agent/proactivity/service.js +1 -2
  622. package/dist/src/personal-agent/prompt-context.js +1 -2
  623. package/dist/src/personal-agent/reply-composer.js +4 -5
  624. package/dist/src/personal-agent/repository.js +1 -2
  625. package/dist/src/personal-agent/request-delivery.js +1 -2
  626. package/dist/src/personal-agent/result-extraction.js +71 -71
  627. package/dist/src/personal-agent/service.js +2 -3
  628. package/dist/src/phone/adb-command.d.ts +1 -0
  629. package/dist/src/phone/adb-command.js +12 -0
  630. package/dist/src/phone/adb-driver.d.ts +6 -2
  631. package/dist/src/phone/adb-driver.js +45 -21
  632. package/dist/src/phone/cloud-adb-connection.d.ts +34 -0
  633. package/dist/src/phone/cloud-adb-connection.js +324 -0
  634. package/dist/src/phone/cloud-adb-writable.d.ts +3 -0
  635. package/dist/src/phone/cloud-adb-writable.js +21 -0
  636. package/dist/src/phone/cloud-adb.d.ts +3 -32
  637. package/dist/src/phone/cloud-adb.js +3 -259
  638. package/dist/src/phone/cloud-key-permissions.d.ts +2 -0
  639. package/dist/src/phone/cloud-key-permissions.js +66 -0
  640. package/dist/src/phone/cloud-phones.js +2 -1
  641. package/dist/src/phone/cloud-scrcpy.d.ts +1 -1
  642. package/dist/src/phone/cloud-scrcpy.js +3 -2
  643. package/dist/src/phone/contracts.d.ts +197 -1
  644. package/dist/src/phone/contracts.js +55 -6
  645. package/dist/src/phone/foreground.d.ts +1 -0
  646. package/dist/src/phone/foreground.js +18 -0
  647. package/dist/src/phone/live-state.d.ts +2 -0
  648. package/dist/src/phone/live-state.js +5 -0
  649. package/dist/src/phone/model-adapter.d.ts +65 -4
  650. package/dist/src/phone/model-adapter.js +157 -48
  651. package/dist/src/phone/numeric-entry.d.ts +31 -0
  652. package/dist/src/phone/numeric-entry.js +126 -0
  653. package/dist/src/phone/planning.d.ts +27 -0
  654. package/dist/src/phone/planning.js +79 -0
  655. package/dist/src/phone/recovery.d.ts +37 -0
  656. package/dist/src/phone/recovery.js +81 -0
  657. package/dist/src/phone/reliability.d.ts +2 -2
  658. package/dist/src/phone/reliability.js +19 -6
  659. package/dist/src/phone/repository.d.ts +4 -1
  660. package/dist/src/phone/repository.js +12 -1
  661. package/dist/src/phone/runtime.d.ts +79 -3
  662. package/dist/src/phone/runtime.js +861 -93
  663. package/dist/src/phone/scrcpy.js +3 -2
  664. package/dist/src/phone/semantic-controls.d.ts +13 -0
  665. package/dist/src/phone/semantic-controls.js +76 -0
  666. package/dist/src/phone/setup/service.d.ts +101 -0
  667. package/dist/src/phone/setup/service.js +296 -0
  668. package/dist/src/phone/task-feedback.d.ts +4 -0
  669. package/dist/src/phone/task-feedback.js +47 -0
  670. package/dist/src/phone/ui-dump-binary.d.ts +1 -0
  671. package/dist/src/phone/ui-dump-binary.js +4 -0
  672. package/dist/src/phone/wireless.d.ts +80 -0
  673. package/dist/src/phone/wireless.js +244 -0
  674. package/dist/src/projects/capabilities/write.js +1 -2
  675. package/dist/src/projects/project-service.js +1 -2
  676. package/dist/src/projects/workspace.js +1 -2
  677. package/dist/src/providers/presentation.js +2 -2
  678. package/dist/src/providers/xopc-cloud-model-source.js +6 -2
  679. package/dist/src/realtime/runtime.d.ts +3 -0
  680. package/dist/src/realtime/runtime.js +16 -3
  681. package/dist/src/remote-access/exposure-guards.js +1 -2
  682. package/dist/src/runtime-tools/archive.js +1 -1
  683. package/dist/src/runtime-tools/catalog.d.ts +1 -1
  684. package/dist/src/runtime-tools/catalog.js +2 -2
  685. package/dist/src/session/config-store.js +1 -2
  686. package/dist/src/session/init-session-turn.js +1 -2
  687. package/dist/src/session/resolve-session.js +1 -2
  688. package/dist/src/session/store.js +2 -4
  689. package/dist/src/share/share-rate-limit.js +1 -2
  690. package/dist/src/share/share-url.js +1 -2
  691. package/dist/src/share/site-share-router.js +1 -2
  692. package/dist/src/storage/sqlite/activity-repository.js +2 -6
  693. package/dist/src/storage/sqlite/browser-tab-binding-repository.js +2 -6
  694. package/dist/src/storage/sqlite/clarification-wait-repository.js +9 -14
  695. package/dist/src/storage/sqlite/collaboration-rule-repository.js +3 -8
  696. package/dist/src/storage/sqlite/composer-input-history-repository.js +3 -8
  697. package/dist/src/storage/sqlite/config-repository.js +5 -9
  698. package/dist/src/storage/sqlite/connector-learning-repository.js +2 -6
  699. package/dist/src/storage/sqlite/connector-sync-policy-repository.js +2 -6
  700. package/dist/src/storage/sqlite/context-evidence-repository.js +3 -8
  701. package/dist/src/storage/sqlite/context-extraction-repository.js +3 -8
  702. package/dist/src/storage/sqlite/device-access-repository.js +16 -23
  703. package/dist/src/storage/sqlite/device-pairing-approval.js +2 -6
  704. package/dist/src/storage/sqlite/device-pairing-repository.js +5 -10
  705. package/dist/src/storage/sqlite/endpoint-principal-repository.js +2 -6
  706. package/dist/src/storage/sqlite/endpoint-session-binding-repository.js +2 -6
  707. package/dist/src/storage/sqlite/endpoint-tool-invocation-repository.js +2 -6
  708. package/dist/src/storage/sqlite/gateway-identity-repository.js +2 -6
  709. package/dist/src/storage/sqlite/home-attention-repository.js +2 -6
  710. package/dist/src/storage/sqlite/index.js +40 -72
  711. package/dist/src/storage/sqlite/interaction-state-repository.js +4 -10
  712. package/dist/src/storage/sqlite/knowledge-repository.js +3 -8
  713. package/dist/src/storage/sqlite/note-agent-context-repository.js +2 -6
  714. package/dist/src/storage/sqlite/notes-repository.js +4 -9
  715. package/dist/src/storage/sqlite/research-checkpoint-repository.js +3 -8
  716. package/dist/src/storage/sqlite/schema.d.ts +2 -2
  717. package/dist/src/storage/sqlite/schema.js +7 -7
  718. package/dist/src/storage/sqlite/schema.sql +10 -0
  719. package/dist/src/storage/sqlite/session-creation-repository.js +2 -4
  720. package/dist/src/storage/sqlite/session-task-plan-repository.js +9 -14
  721. package/dist/src/storage/sqlite/session-turn-replace-repository.js +5 -9
  722. package/dist/src/storage/sqlite/sidebar-layout-repository.js +9 -14
  723. package/dist/src/storage/sqlite/transcript-repository.js +6 -10
  724. package/dist/src/storage/sqlite/upgrades/260_browser_setup.sql +9 -0
  725. package/dist/src/storage/sqlite/user-people-repository.js +3 -8
  726. package/dist/src/storage/sqlite/user-trust-repository.js +4 -9
  727. package/dist/src/tasks/capabilities/read.js +2 -2
  728. package/dist/src/tasks/capabilities/write.js +1 -1
  729. package/dist/src/tasks/execution-context.js +1 -2
  730. package/dist/src/tasks/home-query-service.js +1 -2
  731. package/dist/src/tasks/task-allocation-repository.js +1 -2
  732. package/dist/src/tasks/task-context-assembler.js +1 -2
  733. package/dist/src/tasks/task-handoff.js +2 -4
  734. package/dist/src/tasks/task-instruction-sequence.d.ts +1 -0
  735. package/dist/src/tasks/task-instruction-sequence.js +7 -0
  736. package/dist/src/tasks/task-language.js +1 -2
  737. package/dist/src/tasks/task-research-result.d.ts +1 -2
  738. package/dist/src/tasks/task-research-result.js +1 -3
  739. package/dist/src/tasks/task-result-delivery-repository.js +1 -1
  740. package/dist/src/tasks/task-result-delivery-service.js +3 -3
  741. package/dist/src/tasks/task-run-coordinator.js +3 -3
  742. package/dist/src/tasks/task-run-dispatcher.js +1 -2
  743. package/dist/src/tasks/task-value-metrics-service.js +1 -2
  744. package/dist/src/tui/backends/embedded-backend.js +2 -3
  745. package/dist/src/tui/tui-commands.js +1 -2
  746. package/dist/src/tunnel/registration-proof.js +1 -2
  747. package/dist/src/tunnel/tunnel-rate-limit.js +1 -2
  748. package/dist/src/user-context/access-policy.js +1 -2
  749. package/dist/src/user-context/domain.js +13 -18
  750. package/dist/src/user-context/extraction/registry.js +1 -2
  751. package/dist/src/user-context/interaction-state.js +1 -4
  752. package/dist/src/user-context/relationship-continuity.js +1 -2
  753. package/dist/src/user-context/sources/consent-repository.js +1 -2
  754. package/dist/src/user-context/sources/index.js +1 -1
  755. package/dist/src/user-context/trust-policy.js +8 -13
  756. package/dist/src/user-model/action-rule-suggestions.js +1 -2
  757. package/dist/src/user-model/bootstrap.js +1 -2
  758. package/dist/src/user-model/capture/executor.js +2 -4
  759. package/dist/src/user-model/capture/semantic.d.ts +1 -1
  760. package/dist/src/user-model/capture/semantic.js +1 -1
  761. package/dist/src/user-model/domain.js +30 -35
  762. package/dist/src/user-model/goals.js +1 -2
  763. package/dist/src/user-model/index.js +1 -4
  764. package/dist/src/user-model/observation-repository.js +1 -2
  765. package/dist/src/user-model/repository.js +1 -2
  766. package/dist/src/user-model/usage-policy.js +1 -2
  767. package/dist/src/voice/realtime/memory-context.js +1 -2
  768. package/dist/src/voice/realtime/persona-context.js +1 -1
  769. package/dist/src/work-discovery/service.js +4 -6
  770. package/package.json +8 -8
  771. package/skills/tools/configure-xopc/SKILL.md +54 -0
  772. package/skills/tools/configure-xopc/references/browser/acceptance.md +32 -0
  773. package/skills/tools/configure-xopc/references/browser/chrome-extension.md +23 -0
  774. package/skills/tools/configure-xopc/references/browser/overview.md +19 -0
  775. package/skills/tools/configure-xopc/references/browser/permissions.md +23 -0
  776. package/skills/tools/configure-xopc/references/browser/troubleshooting.md +24 -0
  777. package/skills/tools/configure-xopc/references/phone/acceptance.md +27 -0
  778. package/skills/tools/configure-xopc/references/phone/aliyun.md +29 -0
  779. package/skills/tools/configure-xopc/references/phone/dependencies.md +18 -0
  780. package/skills/tools/configure-xopc/references/phone/local.md +19 -0
  781. package/skills/tools/configure-xopc/references/phone/models.md +21 -0
  782. package/skills/tools/configure-xopc/references/phone/overview.md +25 -0
  783. package/skills/tools/configure-xopc/references/phone/troubleshooting.md +27 -0
  784. package/skills/tools/configure-xopc/references/scene-index.md +12 -0
  785. package/dist/gateway/static/root/assets/agent-avatar-dicebear-CJFwitU2.js +0 -1
  786. package/dist/gateway/static/root/assets/agent-defaults-settings-panel-DclyJr1N.js +0 -1
  787. package/dist/gateway/static/root/assets/agents-jhErNtzi.js +0 -77
  788. package/dist/gateway/static/root/assets/app-management-settings-panel-DgwqNi5i.js +0 -1
  789. package/dist/gateway/static/root/assets/appearance-settings-C0wJfFyz.js +0 -1
  790. package/dist/gateway/static/root/assets/apps-page-C0LcnI4h.js +0 -1
  791. package/dist/gateway/static/root/assets/automation-display-BFN7zWBg.js +0 -2
  792. package/dist/gateway/static/root/assets/automations-workspace-CBxiV34x.js +0 -8
  793. package/dist/gateway/static/root/assets/browser-automations-page-vJIrTxdi.js +0 -3
  794. package/dist/gateway/static/root/assets/browser-settings-page-in5Roh_E.js +0 -3
  795. package/dist/gateway/static/root/assets/capabilities-BlxF36t-.js +0 -1
  796. package/dist/gateway/static/root/assets/capabilities-page-CiGx8wpQ.js +0 -2
  797. package/dist/gateway/static/root/assets/capabilities-settings-panel-a8kqjzQu.js +0 -8
  798. package/dist/gateway/static/root/assets/capability-header-actions-D4Yq35fD.js +0 -1
  799. package/dist/gateway/static/root/assets/channels-C_CxcjKT.js +0 -1
  800. package/dist/gateway/static/root/assets/chat-terminal-dock-zdMySdMm.js +0 -36
  801. package/dist/gateway/static/root/assets/chunk-KS7C4IRE-BvcCCgTW.js +0 -4
  802. package/dist/gateway/static/root/assets/cloud-credits-BMYMiiNn.js +0 -1
  803. package/dist/gateway/static/root/assets/computer-settings-page-C5Z6Jr0p.js +0 -1
  804. package/dist/gateway/static/root/assets/connector-service-page-Cxus0qrZ.js +0 -1
  805. package/dist/gateway/static/root/assets/connectors-page-DCBO2CxK.js +0 -1
  806. package/dist/gateway/static/root/assets/constants-DeXt1mV-.js +0 -1
  807. package/dist/gateway/static/root/assets/date-picker-DuyyD6jz.js +0 -1
  808. package/dist/gateway/static/root/assets/dependency-picker-BZN72rrk.js +0 -1
  809. package/dist/gateway/static/root/assets/desktop-pet-BtvTIDCi.js +0 -1
  810. package/dist/gateway/static/root/assets/desktop-pet-settings-BcyP7Z6v.js +0 -1
  811. package/dist/gateway/static/root/assets/device-pairing-wizard-Ctbgr50F.js +0 -1
  812. package/dist/gateway/static/root/assets/directory-picker-path-field-DOusKz-O.js +0 -1
  813. package/dist/gateway/static/root/assets/dist-C3DSFZCi.js +0 -1
  814. package/dist/gateway/static/root/assets/dist-CI_fqRk-.js +0 -1
  815. package/dist/gateway/static/root/assets/docx-preview-CajIk2FR.js +0 -20
  816. package/dist/gateway/static/root/assets/echarts-runtime-tcHc9TOS.js +0 -18
  817. package/dist/gateway/static/root/assets/electron-env-Dit0bHgy.js +0 -1
  818. package/dist/gateway/static/root/assets/extension-debug-page-Bt4FwsFu.js +0 -1
  819. package/dist/gateway/static/root/assets/extension-page-0vsxX3FB.js +0 -1
  820. package/dist/gateway/static/root/assets/extension-settings-page-5Pt5_ELc.js +0 -1
  821. package/dist/gateway/static/root/assets/files-Bw4SBGdM.js +0 -1
  822. package/dist/gateway/static/root/assets/floating-ui.dom-B7uQOZZW.js +0 -1
  823. package/dist/gateway/static/root/assets/gateway-realtime-DkWCHVzI.js +0 -1
  824. package/dist/gateway/static/root/assets/gateway-realtime-store-Bx9KCID-.js +0 -1
  825. package/dist/gateway/static/root/assets/gateway-settings-BsVOcmV5.js +0 -1
  826. package/dist/gateway/static/root/assets/highlight-code-C8eS9949.js +0 -1
  827. package/dist/gateway/static/root/assets/highlighted-body-KQOG7T2V-Cbk7eMlg.js +0 -1
  828. package/dist/gateway/static/root/assets/home-page-BZDZnmyc.js +0 -2
  829. package/dist/gateway/static/root/assets/image-generation-api-CAS8QVla.js +0 -1
  830. package/dist/gateway/static/root/assets/imports-page-BCLBYzV1.js +0 -1
  831. package/dist/gateway/static/root/assets/index-Bys6njTY.js +0 -710
  832. package/dist/gateway/static/root/assets/index-Vsf0bj5e.css +0 -1
  833. package/dist/gateway/static/root/assets/keyboard-shortcuts-settings-CM_kt5XN.js +0 -1
  834. package/dist/gateway/static/root/assets/languages-byq_L2Ae.js +0 -2
  835. package/dist/gateway/static/root/assets/local-app-workbench-page-Dk87jtcc.js +0 -1
  836. package/dist/gateway/static/root/assets/local-apps-page-BTSOChhk.js +0 -1
  837. package/dist/gateway/static/root/assets/local-apps-yys1VChX.js +0 -1
  838. package/dist/gateway/static/root/assets/local-session-drafts-iGX_6O0O.js +0 -1
  839. package/dist/gateway/static/root/assets/logs-page-D3gVdm8S.js +0 -2
  840. package/dist/gateway/static/root/assets/management-settings-BQNYFE4J.js +0 -1
  841. package/dist/gateway/static/root/assets/mermaid-MCJ5UELQ-ChweJKTv.js +0 -1
  842. package/dist/gateway/static/root/assets/note-detail-panel-CYKwUCte.js +0 -5
  843. package/dist/gateway/static/root/assets/note-image-lightbox-BTSZb9ZT.js +0 -1
  844. package/dist/gateway/static/root/assets/notes-page-CJ5nhWfL.js +0 -8
  845. package/dist/gateway/static/root/assets/number-input-DDeqHK-G.js +0 -1
  846. package/dist/gateway/static/root/assets/page-context-capture-button-DVn_dU83.js +0 -1
  847. package/dist/gateway/static/root/assets/pdf-runtime-DU_sMPjG.js +0 -2
  848. package/dist/gateway/static/root/assets/personal-page-DcW14lqn.js +0 -1
  849. package/dist/gateway/static/root/assets/personal-proactivity-BJcZ3Yhi.js +0 -1
  850. package/dist/gateway/static/root/assets/personal-settings-panel-C16Iqe7X.js +0 -1
  851. package/dist/gateway/static/root/assets/phone-dependencies-card-D3l9uPFM.js +0 -1
  852. package/dist/gateway/static/root/assets/phone-model-picker-DOv38vBn.js +0 -1
  853. package/dist/gateway/static/root/assets/phone-settings-page-DUHp1q_9.js +0 -1
  854. package/dist/gateway/static/root/assets/plugin-details-dialog-BpfgDlVa.js +0 -1
  855. package/dist/gateway/static/root/assets/popover-select-DGKUpVsz.js +0 -1
  856. package/dist/gateway/static/root/assets/preload-helper-zJ_50EbN.js +0 -1
  857. package/dist/gateway/static/root/assets/preview-open-alternatives-RlHk76TI.js +0 -1
  858. package/dist/gateway/static/root/assets/product-delivery-BqNm-8S5.js +0 -1
  859. package/dist/gateway/static/root/assets/product-open-page-Dh-HqLrE.js +0 -1
  860. package/dist/gateway/static/root/assets/product-preview-content-c3K-4DWc.js +0 -1
  861. package/dist/gateway/static/root/assets/project-detail-page-GD8TxKad.js +0 -7
  862. package/dist/gateway/static/root/assets/projects-page-B8HAt9sD.js +0 -1
  863. package/dist/gateway/static/root/assets/remote-access-hub-D3el7lHK.js +0 -1
  864. package/dist/gateway/static/root/assets/runtime-tools-settings-panel-Dbskk6RG.js +0 -1
  865. package/dist/gateway/static/root/assets/schema-form-CXO1B1k4.js +0 -1
  866. package/dist/gateway/static/root/assets/schemas-CObaziC7.js +0 -64
  867. package/dist/gateway/static/root/assets/session-manager-CA1NkTR_.js +0 -16
  868. package/dist/gateway/static/root/assets/sessions-page-07liaSHH.js +0 -1
  869. package/dist/gateway/static/root/assets/settings-advanced-gate-BGjU8rfN.js +0 -1
  870. package/dist/gateway/static/root/assets/settings-form-section-BQxKmbbJ.js +0 -1
  871. package/dist/gateway/static/root/assets/settings-page-DvVMpKiA.js +0 -1
  872. package/dist/gateway/static/root/assets/settings-page-header-CYpuTXUW.js +0 -1
  873. package/dist/gateway/static/root/assets/settings-page-layout-B20AfmFG.js +0 -1
  874. package/dist/gateway/static/root/assets/setup-status-panel-DKo_VTx-.js +0 -1
  875. package/dist/gateway/static/root/assets/share-preview-page-XgZk8Oa1.js +0 -2
  876. package/dist/gateway/static/root/assets/shares-settings-BODFqK8k.js +0 -1
  877. package/dist/gateway/static/root/assets/skill-api-CV-WT2hj.js +0 -1
  878. package/dist/gateway/static/root/assets/skill-reload-api-Ce6OUk2C.js +0 -1
  879. package/dist/gateway/static/root/assets/skills-page-B7ehOIML.js +0 -2
  880. package/dist/gateway/static/root/assets/specialists-4bkS5rZ4.js +0 -1
  881. package/dist/gateway/static/root/assets/system-settings-panel-CxJkZRT4.js +0 -1
  882. package/dist/gateway/static/root/assets/task-detail-page-CxRR0QuW.js +0 -2
  883. package/dist/gateway/static/root/assets/task-result-evidence-D-gGKNX9.js +0 -1
  884. package/dist/gateway/static/root/assets/tasks-TVRjEggr.js +0 -1
  885. package/dist/gateway/static/root/assets/tracing-settings-page-CQw3G-FB.js +0 -1
  886. package/dist/gateway/static/root/assets/tunnel-api-B2HnCi0U.js +0 -1
  887. package/dist/gateway/static/root/assets/usage-page-uUEkO38r.js +0 -1
  888. package/dist/gateway/static/root/assets/use-autosave-Dc0nwUpX.js +0 -1
  889. package/dist/gateway/static/root/assets/user-model-page-ICUutbKL.js +0 -2
  890. package/dist/gateway/static/root/assets/voice-api-key-field-BSWXZkGa.js +0 -1
  891. package/dist/gateway/static/root/assets/work-discovery-overlay-H3cdwq3l.js +0 -1
  892. package/dist/gateway/static/root/assets/xopc-cloud-account-card-CvT_W6YS.js +0 -1
@@ -0,0 +1,55 @@
1
+ function e(e){let t=Object.values(e).filter(e=>typeof e==`number`);return Object.entries(e).filter(([e,n])=>t.indexOf(+e)===-1).map(([e,t])=>t)}function t(e,t=`|`){return e.map(e=>se(e)).join(t)}function n(e,t){return typeof t==`bigint`?t.toString():t}var r=class{constructor(e){this._getter=e,this._value=void 0}get value(){let e=this._getter;return e!==void 0&&(this._value=e(),this._getter=void 0),this._value}};function i(e){return new r(e)}function a(e){return e==null}function o(e){let t=+!!e.startsWith(`^`),n=e.endsWith(`$`)?e.length-1:e.length;return e.slice(t,n)}function s(e,t){let n=e/t,r=Math.round(n),i=4*2**-52*Math.max(Math.abs(n),1);return Math.abs(n-r)<i?0:n-r}var c=Symbol(`evaluating`);function l(e,t,n){let r;Object.defineProperty(e,t,{get(){if(r!==c)return r===void 0&&(r=c,r=n()),r},set(n){Object.defineProperty(e,t,{value:n})},configurable:!0})}function u(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function d(e){let t=Object.getOwnPropertyDescriptor(e,`shape`);return t?.get?t.get.raw:t?.value}function f(e){return d(e._zod.def)??e._zod.def.shape}function p(e,t,n){Object.defineProperty(e,t,{get(){let e=n();return u(this,t,e),e},enumerable:!0,configurable:!0})}function m(e,t,n){t in e?u(e,t,n):e[t]=n}function h(e,t,n,r){let i=f(t);for(let a of n){let n=Object.getOwnPropertyDescriptor(i,a);n.enumerable&&(n.get?p(e,a,()=>{let e=t._zod.def.shape[a];return r?r(e,a):e}):m(e,a,r?r(n.value,a):n.value))}}function ee(e,t){for(let n of Reflect.ownKeys(t)){let r=Object.getOwnPropertyDescriptor(t,n);r.enumerable&&(r.get?p(e,n,()=>t[n]):m(e,n,r.value))}}function g(...e){let t={};for(let n of e){let e=Object.getOwnPropertyDescriptors(n);Object.assign(t,e)}return Object.defineProperties({},t)}function te(e){return JSON.stringify(e)}function ne(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,``).replace(/[\s_-]+/g,`-`).replace(/^-+|-+$/g,``)}var re=`captureStackTrace`in Error?Error.captureStackTrace:(...e)=>{};function _(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}var ie=i(()=>{if(M.jitless||typeof navigator<`u`&&navigator?.userAgent?.includes(`Cloudflare`))return!1;try{return Function(``),!0}catch{return!1}});function v(e){if(_(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!=`function`)return!0;let n=t.prototype;return!(_(n)===!1||Object.prototype.hasOwnProperty.call(n,`isPrototypeOf`)===!1)}function ae(e){return v(e)?{...e}:Array.isArray(e)?[...e]:e instanceof Map?new Map(e):e instanceof Set?new Set(e):e}var oe=new Set([`string`,`number`,`symbol`]);function y(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}function b(e,t,n){let r=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(r._zod.parent=e),r}function x(e){let t=e;if(!t)return{};if(typeof t==`string`)return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error==`string`?{...t,error:()=>t.error}:t}function se(e){return typeof e==`bigint`?e.toString()+`n`:typeof e==`string`?`"${e}"`:`${e}`}function ce(e){return Object.keys(e).filter(t=>e[t]._zod.optin!==void 0&&e[t]._zod.optout===`optional`)}var le={safeint:[-(2**53-1),2**53-1],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},ue={int64:[BigInt(`-9223372036854775808`),BigInt(`9223372036854775807`)],uint64:[BigInt(0),BigInt(`18446744073709551615`)]};function de(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw Error(`.pick() cannot be used on object schemas containing refinements`);let i={};return h(i,e,fe(e,t)),b(e,g(n,{shape:i,checks:[]}))}function fe(e,t){let n=f(e),r=[];for(let e of Reflect.ownKeys(t)){if(!Object.getOwnPropertyDescriptor(n,e)?.enumerable)throw Error(`Unrecognized key: "${String(e)}"`);t[e]&&r.push(e)}return r}function pe(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw Error(`.omit() cannot be used on object schemas containing refinements`);let i=new Set(fe(e,t)),a={};return h(a,e,Reflect.ownKeys(f(e)).filter(e=>!i.has(e))),b(e,g(n,{shape:a,checks:[]}))}function me(e,t){if(!v(t))throw Error(`Invalid input to extend: expected a plain object`);let n=e._zod.def.checks;if(n&&n.length>0){let n=f(e);for(let e of Reflect.ownKeys(t))if(Object.getOwnPropertyDescriptor(n,e)!==void 0)throw Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}return b(e,g(e._zod.def,{shape:he(e,t)}))}function he(e,t){let n={};return h(n,e,Reflect.ownKeys(f(e))),ee(n,t),n}function ge(e,t){if(!v(t))throw Error(`Invalid input to safeExtend: expected a plain object`);return b(e,g(e._zod.def,{shape:he(e,t)}))}function _e(e,t){if(!t?._zod?.def)throw Error("Invalid input to merge: expected an object schema. To merge a plain shape, use `.extend()`.");if(e._zod.def.checks?.length)throw Error(`.merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.`);let n={};return h(n,e,Reflect.ownKeys(f(e))),h(n,t,Reflect.ownKeys(f(t))),b(e,g(e._zod.def,{shape:n,get catchall(){return t._zod.def.catchall},checks:t._zod.def.checks??[]}))}function ve(e,t,n,r=`partial`){let i=t._zod.def.checks;if(i&&i.length>0)throw Error(`.${r}() cannot be used on object schemas containing refinements`);let a=n?new Set(fe(t,n)):void 0,o={};return h(o,t,Reflect.ownKeys(f(t)),e&&((t,n)=>a&&!a.has(n)?t:new e({type:`optional`,innerType:t}))),b(t,g(t._zod.def,{shape:o,checks:[]}))}function ye(e,t,n){let r=n?new Set(fe(t,n)):void 0,i={};return h(i,t,Reflect.ownKeys(f(t)),(t,n)=>r&&!r.has(n)?t:new e({type:`nonoptional`,innerType:t})),b(t,g(t._zod.def,{shape:i}))}function S(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function be(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue===!1)return!0;return!1}function C(e,t){return t.map(t=>{var n;return(n=t).path??(n.path=[]),t.path.unshift(e),t})}function w(e){return typeof e==`string`?e:e?.message}function xe(e){let t=[];for(let n of e??[]){let e=n._zod.def;if(!/_(length|size)$|_equals$/.test(e.check))break;let r=e.maximum??e.length??e.size;r>=0&&t.push([r,n])}return t}function Se(e,t,n){var r;for(let i=t;i<e.length;i++)(r=e[i]).schema??(r.schema=n)}function T(e,t,n){var r;let i=e.inst?._zod?.traits;i?.has(`$ZodType`)&&(i.has(`$ZodCheck`)?(r=e).schema??(r.schema=e.inst):e.schema=e.inst);let a=e.schema===e.inst?void 0:e.schema?._zod.def?.error,o=e.message?e.message:w(e.inst?._zod.def?.error?.(e))??w(a?.(e))??w(t?.error?.(e))??w(n.customError?.(e))??w(n.localeError?.(e))??`Invalid input`,s={};for(let t of Object.keys(e))t===`inst`||t===`schema`||t===`continue`||t===`input`||t===`__proto__`||(s[t]=e[t]);return s.path??=[],s.message=o,t?.reportInput&&(s.input=e.input),s}var Ce=/[\uD800-\uDBFF]/;function we(e){let t=e.length;if(!Ce.test(e))return t;let n=t;for(let r=0;r<t-1;r++)(e.charCodeAt(r)&64512)==55296&&(e.charCodeAt(r+1)&64512)==56320&&(n--,r++);return n}function Te(e){return Array.isArray(e)?`array`:typeof e==`string`?`string`:`unknown`}function Ee(e){let t=typeof e;switch(t){case`number`:return Number.isNaN(e)?`nan`:`number`;case`object`:{if(e===null)return`null`;if(Array.isArray(e))return`array`;let t=e;if(t&&Object.getPrototypeOf(t)!==Object.prototype&&`constructor`in t&&t.constructor)return t.constructor.name}}return t}function E(...e){let[t,n,r]=e;return typeof t==`string`?{message:t,code:`custom`,input:n,inst:r}:{...t}}function De(e,t){for(let n in t){let r=Object.getOwnPropertyDescriptor(t,n);r.get?Object.defineProperty(e,n,{...r,enumerable:!1}):Ae(e,n,r.value)}}function D(e,t,n,r=!0){return Object.defineProperty(e,t,{configurable:!0,writable:!0,enumerable:r,value:n}),n}function Oe(e,t,n){return D(e,t,n,!1)}function ke(e,t){for(let n in e){let r=e[n];Object.defineProperty(t,n,{configurable:!0,enumerable:!0,get(){return D(this,n,r(this))},set(e){D(this,n,e)}})}return t}function Ae(e,t,n){Object.defineProperty(e,t,{configurable:!0,get(){return this==null?n:D(this,t,n.bind(this))},set(e){D(this,t,e)}})}function je(e,t){let n=Object.getPrototypeOf(e);return t in n?void 0:n}var Me,O=!1,Ne={configurable:!0,get(){O=!0}};function k(e,t,n){let r=Object.getPrototypeOf(e._zod);if(t in r&&Me!==e._zod){Me=void 0;return}Me=e._zod,Object.defineProperty(r,t,{configurable:!0,get(){Object.defineProperty(this,t,Ne);let e=O;O=!1;try{let r=n(this);return O?delete this[t]:Object.defineProperty(this,t,{configurable:!0,writable:!0,value:r}),O||=e,r}catch(n){throw delete this[t],O||=e,n}},set(e){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:e})}})}function Pe(e,t,n,r){let i=je(e,t);i&&Object.defineProperty(i,t,{configurable:!0,get(){let e={configurable:!0,writable:!0,enumerable:r,value:void 0};return Object.defineProperty(this,t,e),e.value=n(this),Object.defineProperty(this,t,e),e.value},set(e){Object.defineProperty(this,t,{configurable:!0,writable:!0,enumerable:r,value:e})}})}var Fe=`~constantCatch`;function Ie(e){let t=()=>e;return t[Fe]=!0,t}var Le,Re={value:void 0,enumerable:!1},ze=`captureStackTrace`in Error?Error:null;function Be(e){let t=ze;if(t){let n=t.stackTraceLimit;if(typeof n==`number`){try{t.stackTraceLimit=0}catch{return ze=null,new e}try{return new e}finally{t.stackTraceLimit=n}}}return new e}function A(e,t,n,r){let i={};function a(e){this.def=e,this.constr=d,this.traits=new Set}a.prototype=i;let o=n,s=o&&new WeakSet;function c(n,r){if(!n._zod){Re.value=new a(r);try{Object.defineProperty(n,"_zod",Re)}finally{Re.value=void 0}}else if(n._zod.traits.has(e))return;if(n._zod.traits.add(e),t(n,r),s){let e=Object.getPrototypeOf(n),t=n._zod.constr.prototype,r=e;for(;r&&r!==t;)r=Object.getPrototypeOf(r);let i=r??e;s.has(i)||(s.add(i),De(i,o))}let i=d.prototype;for(let e in i)Object.prototype.hasOwnProperty.call(i,e)&&(e in n||(n[e]=i[e].bind(n)))}let l=r?.Parent??Object;class u extends l{}Object.defineProperty(u,"name",{value:e});function d(e){let t=r?.Parent?Be(u):this;c(t,e);let n=t._zod.deferred;if(n){for(let e of n)e();t._zod.deferred=void 0}let i=globalThis.__zod_globalConfig?.postProcessor;return i&&i(t),t}return Object.defineProperty(d,"init",{value:c}),Object.defineProperty(d,Symbol.hasInstance,{value:t=>r?.Parent&&t instanceof r.Parent?!0:t?._zod?.traits?.has(e)}),Object.defineProperty(d,"name",{value:e}),d}var j=class extends Error{constructor(){super(`Encountered Promise during synchronous parse. Use .parseAsync() instead.`)}},Ve=class extends Error{constructor(e){super(`Encountered unidirectional transform during encode: ${e}`),this.name=`ZodEncodeError`}};(Le=globalThis).__zod_globalConfig??(Le.__zod_globalConfig={});var M=globalThis.__zod_globalConfig;function N(e){return e&&Object.assign(M,e),M}function He(){let e=this._zod;return e.message??=JSON.stringify(e.def,n,2),e.message}function Ue(e){this._zod.message=e}var We={get:He,set:Ue,enumerable:!0,configurable:!0},Ge={value:void 0,enumerable:!1},Ke=new WeakSet([Object.prototype,Error.prototype]),qe=(e,t)=>{e.name=`$ZodError`,Ge.value=t,Object.defineProperty(e,"issues",Ge),Ge.value=void 0,Object.defineProperty(e,"message",We);let n=Object.getPrototypeOf(e);Ke.has(n)||(Ke.add(n),Object.defineProperty(n,"toString",{configurable:!0,enumerable:!1,get(){let e=()=>this.message;return Object.defineProperty(this,"toString",{value:e,configurable:!0,writable:!0}),e},set(e){Object.defineProperty(this,"toString",{value:e,configurable:!0,writable:!0})}}))},Je=A(`$ZodError`,qe);A(`$ZodError`,qe,void 0,{Parent:Error});function Ye(e,t,n){return Object.prototype.hasOwnProperty.call(e,t)||(t===`__proto__`?Object.defineProperty(e,t,{value:n(),writable:!0,enumerable:!0,configurable:!0}):e[t]=n()),e[t]}function Xe(e,t=e=>e.message){let n={},r=[];for(let i of e.issues)i.path.length>0?Ye(n,i.path[0],()=>[]).push(t(i)):r.push(t(i));return{formErrors:r,fieldErrors:n}}function Ze(e,t=e=>e.message){let n={_errors:[]},r=(e,i=[])=>{for(let a of e.issues)if(a.code===`invalid_union`&&a.errors.length)a.errors.map(e=>r({issues:e},[...i,...a.path]));else if(a.code===`invalid_key`)r({issues:a.issues},[...i,...a.path]);else if(a.code===`invalid_element`)r({issues:a.issues},[...i,...a.path]);else{let e=[...i,...a.path];if(e.length===0)n._errors.push(t(a));else{let r=n,i=0;for(;i<e.length;){let n=e[i],o=i===e.length-1;if(n===`_errors`){o&&r._errors.push(t(a)),i++;continue}Object.prototype.hasOwnProperty.call(r,n)||Object.defineProperty(r,n,{value:{_errors:[]},enumerable:!0,writable:!0,configurable:!0});let s=r[n];o&&s._errors.push(t(a)),r=s,i++}}}};return r(e),n}function Qe(e,t){return{callee:t?.callee??e,Err:t?.Err}}var $e=e=>{let t=(n,r,i,a)=>{let o=i?{...i,async:!1}:{async:!1},s=n._zod.run({value:r,issues:[]},o);if(s instanceof Promise)throw new j;if(s.issues.length){let n=new((a?.Err)??e)(s.issues.map(e=>T(e,o,N())));throw re(n,a?.callee??t),n}return s.value};return t},et=e=>{let t=async(n,r,i,a)=>{let o=i?{...i,async:!0}:{async:!0},s=n._zod.run({value:r,issues:[]},o);if(s instanceof Promise&&(s=await s),s.issues.length){let n=new((a?.Err)??e)(s.issues.map(e=>T(e,o,N())));throw re(n,a?.callee??t),n}return s.value};return t},tt=e=>(t,n,r)=>{let i=r?{...r,async:!1}:{async:!1},a=t._zod.run({value:n,issues:[]},i);if(a instanceof Promise)throw new j;return a.issues.length?nt(e,a.issues,i):{success:!0,data:a.value}};function nt(e,t,n){let r;return{success:!1,get error(){return r||(r=new e(t.map(e=>T(e,n,N()))),t=void 0,n=void 0),r},set error(e){r=e,t=void 0,n=void 0}}}var rt=e=>async(t,n,r)=>{let i=r?{...r,async:!0}:{async:!0},a=t._zod.run({value:n,issues:[]},i);return a instanceof Promise&&(a=await a),a.issues.length?nt(e,a.issues,i):{success:!0,data:a.value}},it=Symbol.for(`zod.compile.invalid`),at=Symbol.for(`zod.compile.fallback`),ot=((e,t,n)=>{let r=e._zod.bag.validator;if(r!==void 0){if(r(t)!==it)return!0;if(r.definite===!0&&n===void 0)return!1}return st(e,t,n)});function st(e,t,n){let r=n?{...n,async:!1,abortEarly:!0}:{async:!1,abortEarly:!0},i=e._zod.bag.fallbackRun,a;if(i?(r[at]=!0,a=i({value:t,issues:[]},r)):a=e._zod.run({value:t,issues:[]},r),a instanceof Promise)throw new j;return a.issues.length===0}var ct=async(e,t,n)=>{let r=n?{...n,async:!0,abortEarly:!0}:{async:!0,abortEarly:!0},i=e._zod.run({value:t,issues:[]},r);return i instanceof Promise&&(i=await i),i.issues.length===0},lt=e=>{let t=$e(e),n=(e,r,i,a)=>{let o=i?{...i,direction:`backward`}:{direction:`backward`};return t(e,r,o,Qe(n,a))};return n},ut=e=>{let t=$e(e),n=(e,r,i,a)=>t(e,r,i,Qe(n,a));return n},dt=e=>{let t=et(e),n=async(e,r,i,a)=>{let o=i?{...i,direction:`backward`}:{direction:`backward`};return await t(e,r,o,Qe(n,a))};return n},ft=e=>{let t=et(e),n=async(e,r,i,a)=>await t(e,r,i,Qe(n,a));return n},pt=e=>(t,n,r)=>{let i=r?{...r,direction:`backward`}:{direction:`backward`};return tt(e)(t,n,i)},mt=e=>(t,n,r)=>tt(e)(t,n,r),ht=e=>async(t,n,r)=>{let i=r?{...r,direction:`backward`}:{direction:`backward`};return rt(e)(t,n,i)},gt=e=>async(t,n,r)=>rt(e)(t,n,r),_t=/^[cC][0-9a-z]{6,}$/,vt=/^[0-9a-z]+$/,yt=/^[0-7][0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{25}$/,bt=/^[0-9a-vA-V]{20}$/,xt=/^[A-Za-z0-9]{27}$/,St=/^[a-zA-Z0-9_-]{21}$/;function Ct(e){return RegExp(`^[a-zA-Z0-9_-]{${e}}$`)}var wt=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,Tt=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Et=e=>e?RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,Dt=/^(?:[A-Za-z0-9_'+\-]+\.)*[A-Za-z0-9_'+\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,Ot=`^(?=[\\s\\S]*[\\p{Extended_Pictographic}\\p{Regional_Indicator}\\u20E3])[\\p{Extended_Pictographic}\\p{Emoji_Component}]+$`;function kt(){return new RegExp(Ot,`u`)}var At=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,jt=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,Mt=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,Nt=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Pt=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ft=/^(?:[A-Za-z0-9_-]{4})*(?:[A-Za-z0-9_-]{2,3})?$/,It=/^https?$/,Lt=/^\+[1-9]\d{6,14}$/,Rt=`(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))`;function zt(e){return RegExp(`^${e}$`)}var Bt=zt(Rt);function Vt(e){let t=`(?:[01]\\d|2[0-3]):[0-5]\\d`;return typeof e.precision==`number`?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:e.seconds?`${t}:[0-5]\\d(?:\\.\\d+)?`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Ht(e){return RegExp(`^${Vt(e)}$`)}function Ut(e){let t=[`Z`];e.offset&&t.push(`([+-](?:[01]\\d|2[0-3]):[0-5]\\d)`);let n=`${Vt({precision:e.precision,seconds:!0})}(?:${t.join(`|`)})`,r=e.local?`${n}|${Vt({precision:e.precision})}`:n;return RegExp(`^${Rt}T(?:${r})$`)}var Wt=/^[\s\S]{0,}$/,Gt=/^-?\d+$/,Kt=/^-?\d+(?:\.\d+)?$/,qt=/^(?:true|false)$/i,Jt=/^null$/i,Yt=/^[^A-Z]*$/,Xt=/^[^a-z]*$/,P=A(`$ZodCheck`,(e,t)=>{var n;e._zod??={},e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),Zt=e=>{let t=e.value;return!a(t)&&t.length!==void 0},Qt={number:`number`,bigint:`bigint`,object:`date`},$t=A(`$ZodCheckLessThan`,(e,t)=>{P.init(e,t);let n=Qt[typeof t.value];e._zod.check=r=>{(t.inclusive?r.value<=t.value:r.value<t.value)||r.issues.push({origin:Qt[typeof r.value]??n,code:`too_big`,maximum:typeof t.value==`object`?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),en=A(`$ZodCheckGreaterThan`,(e,t)=>{P.init(e,t);let n=Qt[typeof t.value];e._zod.check=r=>{(t.inclusive?r.value>=t.value:r.value>t.value)||r.issues.push({origin:Qt[typeof r.value]??n,code:`too_small`,minimum:typeof t.value==`object`?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),tn=A(`$ZodCheckMultipleOf`,(e,t)=>{P.init(e,t),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw Error(`Cannot mix number and bigint in multiple_of check.`);(typeof n.value==`bigint`?t.value!==BigInt(0)&&n.value%t.value===BigInt(0):s(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:`not_multiple_of`,divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),nn=A(`$ZodCheckNumberFormat`,(e,t)=>{P.init(e,t),t.format=t.format||`float64`;let n=t.format?.includes(`int`),r=n?`int`:`number`,[i,a]=le[t.format];e._zod.check=o=>{let s=o.value;if(n){if(!Number.isInteger(s)){o.issues.push({expected:r,format:t.format,code:`invalid_type`,continue:!1,input:s,inst:e});return}if(!Number.isSafeInteger(s)){s>0?o.issues.push({input:s,code:`too_big`,maximum:2**53-1,note:`Integers must be within the safe integer range.`,inst:e,origin:r,inclusive:!0,continue:!t.abort}):o.issues.push({input:s,code:`too_small`,minimum:-(2**53-1),note:`Integers must be within the safe integer range.`,inst:e,origin:r,inclusive:!0,continue:!t.abort});return}}s<i&&o.issues.push({origin:`number`,input:s,code:`too_small`,minimum:i,inclusive:!0,inst:e,continue:!t.abort}),s>a&&o.issues.push({origin:`number`,input:s,code:`too_big`,maximum:a,inclusive:!0,inst:e,continue:!t.abort})}}),rn=A(`$ZodCheckMaxLength`,(e,t)=>{var n;P.init(e,t),(n=e._zod.def).when??(n.when=Zt),e._zod.check=n=>{let r=n.value,i=r.length;if((typeof r==`string`&&i>t.maximum?we(r):i)<=t.maximum)return;let a=Te(r);n.issues.push({origin:a,code:`too_big`,maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),an=A(`$ZodCheckMinLength`,(e,t)=>{var n;P.init(e,t),(n=e._zod.def).when??(n.when=Zt),e._zod.check=n=>{let r=n.value,i=r.length;if((typeof r==`string`&&i>=t.minimum&&i<t.minimum*2?we(r):i)>=t.minimum)return;let a=Te(r);n.issues.push({origin:a,code:`too_small`,minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),on=A(`$ZodCheckLengthEquals`,(e,t)=>{var n;P.init(e,t),(n=e._zod.def).when??(n.when=Zt),e._zod.check=n=>{let r=n.value,i=r.length,a=typeof r==`string`&&i>=t.length&&i<=t.length*2?we(r):i;if(a===t.length)return;let o=Te(r),s=a>t.length;n.issues.push({origin:o,...s?{code:`too_big`,maximum:t.length}:{code:`too_small`,minimum:t.length},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),sn=A(`$ZodCheckStringFormat`,(e,t)=>{var n,r;P.init(e,t),t.pattern?(n=e._zod).check??(n.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:`string`,code:`invalid_format`,format:t.format,input:n.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(r=e._zod).check??(r.check=()=>{})}),cn=A(`$ZodCheckRegex`,(e,t)=>{sn.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:`string`,code:`invalid_format`,format:`regex`,input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),ln=A(`$ZodCheckLowerCase`,(e,t)=>{t.pattern??=Yt,sn.init(e,t)}),un=A(`$ZodCheckUpperCase`,(e,t)=>{t.pattern??=Xt,sn.init(e,t)}),dn=A(`$ZodCheckIncludes`,(e,t)=>{P.init(e,t);let n=y(t.includes);t.pattern=new RegExp(typeof t.position==`number`?`^.{${t.position},}${n}`:n),e._zod.check=n=>{n.value.includes(t.includes,t.position)||n.issues.push({origin:`string`,code:`invalid_format`,format:`includes`,includes:t.includes,input:n.value,inst:e,continue:!t.abort})}}),fn=A(`$ZodCheckStartsWith`,(e,t)=>{P.init(e,t);let n=RegExp(`^${y(t.prefix)}.*`);t.pattern??=n,e._zod.check=n=>{n.value.startsWith(t.prefix)||n.issues.push({origin:`string`,code:`invalid_format`,format:`starts_with`,prefix:t.prefix,input:n.value,inst:e,continue:!t.abort})}}),pn=A(`$ZodCheckEndsWith`,(e,t)=>{P.init(e,t);let n=RegExp(`.*${y(t.suffix)}$`);t.pattern??=n,e._zod.check=n=>{n.value.endsWith(t.suffix)||n.issues.push({origin:`string`,code:`invalid_format`,format:`ends_with`,suffix:t.suffix,input:n.value,inst:e,continue:!t.abort})}}),mn=A(`$ZodCheckOverwrite`,(e,t)=>{P.init(e,t),e._zod.check=e=>{e.value=t.tx(e.value)}}),hn=class{constructor(e=[],t={}){this.content=[],this.indent=0,this.args=e,this.closed=t}indented(e){this.indent+=1;try{e(this)}finally{--this.indent}}write(e){if(typeof e==`function`){e(this,{execution:`sync`}),e(this,{execution:`async`});return}let t=e.split(`
2
+ `).filter(e=>e),n=Math.min(...t.map(e=>e.length-e.trimStart().length)),r=t.map(e=>e.slice(n)).map(e=>` `.repeat(this.indent*2)+e);for(let e of r)this.content.push(e)}compile(){let e=Function,t=this?.content??[``];return new e(...Object.keys(this.closed),`return function (${this.args.join(`, `)}) {\n${t.join(`
3
+ `)}\n};`)(...Object.values(this.closed))}},gn={major:4,minor:6,patch:6},F=A(`$ZodType`,(e,t)=>{var n;e??={},e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=gn;let r=e._zod.def.checks,i=e._zod.traits.has(`$ZodCheck`)?[e,...r??[]]:r?.length?[...r]:[];for(let t of i)for(let n of t._zod.onattach)n(e);if(i.length===0)(n=e._zod).deferred??(n.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let t=(t,n,r)=>{if(t.memo)return t;let i=S(t),a;for(let o of n){if(o._zod.def.when){if(be(t)||!o._zod.def.when(t))continue}else if(i)continue;let n=t.issues.length,s=o._zod.check(t);if(s instanceof Promise&&r?.async===!1)throw new j;if(a||s instanceof Promise)a=(a??Promise.resolve()).then(async()=>{await s,t.issues.length!==n&&(Se(t.issues,n,e),i||=S(t,n))});else{if(t.issues.length===n)continue;Se(t.issues,n,e),i||=S(t,n)}}return a?a.then(()=>t):t},n=(n,r,a)=>{if(S(n))return n.aborted=!0,n;let o=t(r,i,a);if(o instanceof Promise){if(a.async===!1)throw new j;return o.then(t=>e._zod.parse(t,a))}return e._zod.parse(o,a)};e._zod.run=(r,a)=>{if(a.skipChecks)return e._zod.parse(r,a);if(a.direction===`backward`){let t=e._zod.parse({value:r.value,issues:[]},{...a,skipChecks:!0});return t instanceof Promise?t.then(e=>n(e,r,a)):n(t,r,a)}let o=e._zod.parse(r,a);if(o instanceof Promise){if(a.async===!1)throw new j;return o.then(e=>t(e,i,a))}return t(o,i,a)}}},{get"~standard"(){return Oe(this,`~standard`,yn(this))},set"~standard"(e){D(this,`~standard`,e)}}),_n=(e,t)=>e.issues.length?{issues:e.issues.map(e=>T(e,t,N()))}:{value:e.value};async function vn(e,t){let n={async:!0};return _n(await e._zod.run({value:t,issues:[]},n),n)}function yn(e){return{validate:t=>{let n={async:!1};try{let r=e._zod.run({value:t,issues:[]},n);if(!(r instanceof Promise))return _n(r,n)}catch{}return vn(e,t)},vendor:`zod`,version:1}}var bn=A(`$ZodString`,(e,t)=>{F.init(e,t),e._zod.pattern=t.pattern??Wt,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=String(n.value)}catch{}return typeof n.value==`string`||n.issues.push({expected:`string`,code:`invalid_type`,input:n.value,inst:e}),n}}),I=A(`$ZodStringFormat`,(e,t)=>{sn.init(e,t),bn.init(e,t)}),xn=A(`$ZodGUID`,(e,t)=>{t.pattern??=Tt,I.init(e,t)}),Sn=A(`$ZodUUID`,(e,t)=>{if(t.version){let e={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(e===void 0)throw Error(`Invalid UUID version: "${t.version}"`);t.pattern??=Et(e)}else t.pattern??=Et();I.init(e,t)}),Cn=A(`$ZodEmail`,(e,t)=>{t.pattern??=Dt,I.init(e,t)});function wn(e){try{return typeof URL<`u`&&typeof URL.canParse==`function`?URL.canParse(e):(new URL(e),!0)}catch{return!1}}function Tn(e,t){return!(`normalize`in t)&&!(`hostname`in t)&&!(`protocol`in t)?wn(e)||2:En(e,t)}function En(e,t){if(!t.normalize&&t.protocol?.source===It.source&&!/^https?:\/\//i.test(e))return 1;try{if(typeof URL<`u`){let t=URL;if(typeof t.parse==`function`)return t.parse(e)??2}return new URL(e)}catch{return 2}}var Dn=/[\t\n\r]/g;function On(e){return e.replace(Dn,``)}function kn(e,t){return t.lastIndex=0,t.test(e.hostname)}function An(e,t){return t.lastIndex=0,t.test(e.protocol.endsWith(`:`)?e.protocol.slice(0,-1):e.protocol)}var jn=A(`$ZodURL`,(e,t)=>{I.init(e,t),e._zod.check=n=>{try{let r=n.value.trim(),i=Tn(r,t);if(i===1){n.issues.push({code:`invalid_format`,format:`url`,note:`Invalid URL format`,input:n.value,inst:e,continue:!t.abort});return}if(i===2){n.issues.push({code:`invalid_format`,format:`url`,input:n.value,inst:e,continue:!t.abort});return}if(i===!0){n.value=On(r);return}t.hostname&&!kn(i,t.hostname)&&n.issues.push({code:`invalid_format`,format:`url`,note:`Invalid hostname`,pattern:t.hostname.source,input:n.value,inst:e,continue:!t.abort}),t.protocol&&!An(i,t.protocol)&&n.issues.push({code:`invalid_format`,format:`url`,note:`Invalid protocol`,pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort}),n.value=t.normalize?i.href:On(r);return}catch{n.issues.push({code:`invalid_format`,format:`url`,input:n.value,inst:e,continue:!t.abort})}}}),Mn=A(`$ZodEmoji`,(e,t)=>{t.pattern??=kt(),I.init(e,t)}),Nn=A(`$ZodNanoID`,(e,t)=>{if(t.length!==void 0&&(!Number.isInteger(t.length)||t.length<1))throw Error(`Invalid nanoid length: ${t.length}`);t.pattern??=t.length===void 0?St:Ct(t.length),I.init(e,t)}),Pn=A(`$ZodCUID`,(e,t)=>{t.pattern??=_t,I.init(e,t)}),Fn=A(`$ZodCUID2`,(e,t)=>{t.pattern??=vt,I.init(e,t)}),In=A(`$ZodULID`,(e,t)=>{t.pattern??=yt,I.init(e,t)}),Ln=A(`$ZodXID`,(e,t)=>{t.pattern??=bt,I.init(e,t)}),Rn=A(`$ZodKSUID`,(e,t)=>{t.pattern??=xt,I.init(e,t)}),zn=A(`$ZodISODateTime`,(e,t)=>{t.pattern??=Ut(t),I.init(e,t)}),Bn=A(`$ZodISODate`,(e,t)=>{t.pattern??=Bt,I.init(e,t)}),Vn=A(`$ZodISOTime`,(e,t)=>{t.pattern??=Ht(t),I.init(e,t)}),Hn=A(`$ZodISODuration`,(e,t)=>{t.pattern??=wt,I.init(e,t)}),Un=A(`$ZodIPv4`,(e,t)=>{t.pattern??=At,I.init(e,t)}),Wn=/^[0-9a-fA-F:.]+$/;function Gn(e){return Wn.test(e)?wn(`http://[${e}]`):!1}var Kn=A(`$ZodIPv6`,(e,t)=>{t.pattern??=jt,I.init(e,t),e._zod.check=n=>{Gn(n.value)||n.issues.push({code:`invalid_format`,format:`ipv6`,input:n.value,inst:e,continue:!t.abort})}}),qn=A(`$ZodCIDRv4`,(e,t)=>{t.pattern??=Mt,I.init(e,t)});function Jn(e){let t=e.split(`/`);if(t.length!==2)return!1;let[n,r]=t;if(!r)return!1;let i=Number(r);return`${i}`!==r||i<0||i>128?!1:Gn(n)}var Yn=A(`$ZodCIDRv6`,(e,t)=>{t.pattern??=Nt,I.init(e,t),e._zod.check=n=>{Jn(n.value)||n.issues.push({code:`invalid_format`,format:`cidrv6`,input:n.value,inst:e,continue:!t.abort})}});function Xn(e){if(e===``)return!0;if(/\s/.test(e)||e.length%4!=0)return!1;try{return atob(e),!0}catch{return!1}}var Zn=/^[0-9a-zA-Z+/]*={0,2}$/,Qn=A(`$ZodBase64`,(e,t)=>{t.pattern??=Zn,I.init(e,t),e._zod.check=n=>{Xn(n.value)||n.issues.push({code:`invalid_format`,format:`base64`,input:n.value,inst:e,continue:!t.abort})}}),$n=/^[A-Za-z0-9_-]*$/;function er(e){if(!$n.test(e))return!1;let t=e.replace(/[-_]/g,e=>e===`-`?`+`:`/`);return Xn(t.padEnd(Math.ceil(t.length/4)*4,`=`))}var tr=A(`$ZodBase64URL`,(e,t)=>{t.pattern??=$n,I.init(e,t),e._zod.check=n=>{er(n.value)||n.issues.push({code:`invalid_format`,format:`base64url`,input:n.value,inst:e,continue:!t.abort})}}),nr=A(`$ZodE164`,(e,t)=>{t.pattern??=Lt,I.init(e,t)});function rr(e,t=null){try{let n=e.split(`.`);if(n.length!==3)return!1;let[r]=n;if(!r)return!1;let i=JSON.parse(atob(r));return!(`typ`in i&&i?.typ!==`JWT`||!i.alg||t&&(!(`alg`in i)||i.alg!==t))}catch{return!1}}var ir=A(`$ZodJWT`,(e,t)=>{I.init(e,t),e._zod.check=n=>{rr(n.value,t.alg)||n.issues.push({code:`invalid_format`,format:`jwt`,input:n.value,inst:e,continue:!t.abort})}}),ar=A(`$ZodNumber`,(e,t)=>{F.init(e,t),e._zod.pattern=Kt,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=Number(n.value)}catch{}let i=n.value;if(typeof i==`number`&&!Number.isNaN(i)&&Number.isFinite(i))return n;let a=typeof i==`number`?Number.isNaN(i)?`NaN`:Number.isFinite(i)?void 0:String(i):void 0;return n.issues.push({expected:`number`,code:`invalid_type`,input:i,inst:e,...a?{received:a}:{}}),n}}),or=A(`$ZodNumberFormat`,(e,t)=>{nn.init(e,t),ar.init(e,t)}),sr=A(`$ZodBoolean`,(e,t)=>{F.init(e,t),e._zod.pattern=qt,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=!!n.value}catch{}let i=n.value;return typeof i==`boolean`||n.issues.push({expected:`boolean`,code:`invalid_type`,input:i,inst:e}),n}}),cr=A(`$ZodNull`,(e,t)=>{F.init(e,t),e._zod.pattern=Jt,e._zod.values=new Set([null]),e._zod.parse=(t,n)=>{let r=t.value;return r===null||t.issues.push({expected:`null`,code:`invalid_type`,input:r,inst:e}),t}}),lr=A(`$ZodUnknown`,(e,t)=>{F.init(e,t),e._zod.parse=e=>e}),ur=A(`$ZodNever`,(e,t)=>{F.init(e,t),e._zod.parse=(t,n)=>(t.issues.push({expected:`never`,code:`invalid_type`,input:t.value,inst:e}),t)});function dr(e,t){let n=xe(e._zod.def.checks);if(!n.length)return;let r=Math.min(...n.map(e=>e[0])),i=e._zod.parse;e._zod.parse=(n,a)=>{let o=t(n.value);if(o>r&&!a?.skipChecks&&a?.direction!==`backward`){for(let[t,r]of xe(e._zod.def.checks))if(o>t&&r._zod.def.when(n)){let t=n.issues.length;return r._zod.check(n),n.issues[t].continue=!1,Se(n.issues,t,e),n}}return i(n,a)}}var fr=e=>Array.isArray(e)?e.length:-1;function pr(e,t,n){e.issues.length&&t.issues.push(...C(n,e.issues)),t.value[n]=e.value}var mr=A(`$ZodArray`,(e,t)=>{F.init(e,t);let n=M.memoizer;n?.attach(e),e._zod.parse=(r,i)=>{let a=r.value;if(!Array.isArray(a))return r.issues.push({expected:`array`,code:`invalid_type`,input:a,inst:e}),r;r.value=n?n.alloc(e,r,Array(a.length),i):Array(a.length);let o=[],s=i?.abortEarly;for(let e=0;e<a.length;e++){let n=a[e],c=t.element._zod.run({value:n,issues:[]},i);if(c instanceof Promise)o.push(c.then(t=>pr(t,r,e)));else if(pr(c,r,e),s&&c.issues.length!==0&&S(c))break}return o.length?Promise.all(o).then(()=>r):r},dr(e,fr)});function hr(e,t,n,r,i,a){let o=n in r,s=a===`optional`;if(!(!o&&s&&i===`optional`)){if(e.issues.length){if(i!==void 0&&s&&!o)return;t.issues.push(...C(n,e.issues))}if(!o&&i===void 0){e.issues.length||t.issues.push({code:`invalid_type`,expected:`nonoptional`,input:void 0,path:[n]});return}e.value===void 0?(o||i===`defaulted`&&!s)&&(t.value[n]=void 0):t.value[n]=e.value}}var gr=[];function _r(e){let t=Object.keys(e.shape),n=Object.getOwnPropertySymbols(e.shape),r=n.length?n:gr,i=r.length?[...t,...r]:t;for(let t of i)if(!e.shape?.[t]?._zod?.traits?.has(`$ZodType`))throw Error(`Invalid element at key "${String(t)}": expected a Zod schema`);let a=ce(e.shape);return{...e,allKeys:i,symbolKeys:r,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(a)}}function vr(e,t,n,r,i,a,o){let s=[],c=i.keySet,l=i.catchall._zod,u=l.def.type,d=l.optin,f=l.optout,p=0;for(let i in t){if(o&&n.issues.length!==p){if(S(n,p))break;p=n.issues.length}if(c.has(i))continue;if(i===`__proto__`){u===`never`&&s.push(i);continue}if(u===`never`){s.push(i);continue}let a=l.run({value:t[i],issues:[]},r);a instanceof Promise?e.push(a.then(e=>hr(e,n,i,t,d,f))):hr(a,n,i,t,d,f)}return s.length&&n.issues.push({code:`unrecognized_keys`,keys:s,input:t,inst:a,continue:!0}),e.length?Promise.all(e).then(()=>n):n}var yr=A(`$ZodObject`,(e,t)=>{F.init(e,t);let n=Object.getOwnPropertyDescriptor(t,`shape`),r=n?.get?n.get.raw:t.shape??{};if(r){let e=()=>{let n={...r};return Object.defineProperty(t,"shape",{value:n}),e.raw=n,n};e.raw=r,Object.defineProperty(t,"shape",{get:e})}let a=i(()=>_r(t));k(e,`propValues`,e=>{let t=e.def.shape,n={};for(let e in t){let r=t[e]._zod;if(r.values){Object.prototype.hasOwnProperty.call(n,e)||u(n,e,new Set);for(let t of r.values)n[e].add(t);r.optin!==void 0&&n[e].add(void 0)}}return n});let o=_,s=t.catchall,c,l=M.memoizer;l?.attach(e),e._zod.parse=(t,n)=>{c??=a.value;let r=t.value;if(!o(r))return t.issues.push({expected:`object`,code:`invalid_type`,input:r,inst:e}),t;t.value=l?l.alloc(e,t,{},n):{};let i=[],u=c.shape,d=n?.abortEarly,f=t.issues.length;for(let e of c.allKeys){if(d&&t.issues.length!==f){if(S(t,f))break;f=t.issues.length}if(e===`__proto__`)continue;let a=u[e],o=a._zod.optin,s=a._zod.optout,c=a._zod.run({value:r[e],issues:[]},n);c instanceof Promise?i.push(c.then(n=>hr(n,t,e,r,o,s))):hr(c,t,e,r,o,s)}return s?vr(i,r,t,n,a.value,e,d===!0):i.length?Promise.all(i).then(()=>t):t}}),br=A(`$ZodObjectJIT`,(e,t)=>{yr.init(e,t);let n=e._zod.parse,r=i(()=>_r(t)),a=M.memoizer,o=t=>{let n=r.value,i=n.symbolKeys,o=new hn([`payload`,`ctx`],{shape:t,inst:e,memo:a,syms:i}),s=e=>`shape[${e}]._zod.run({ value: input[${e}], issues: [] }, ctx)`,c=(e,t)=>`
4
+ let ${e}_ab = false;
5
+ for (let i = 0; i < ${e}.issues.length; i++) {
6
+ const iss = ${e}.issues[i];
7
+ iss.path = iss.path ? [${t}, ...iss.path] : [${t}];
8
+ payload.issues.push(iss);
9
+ if (iss.continue !== true) ${e}_ab = true;
10
+ }
11
+ if (${e}_ab && ctx && ctx.abortEarly) {
12
+ payload.value = newResult;
13
+ return payload;
14
+ }`;o.write(`const input = payload.value;`);let l=Object.create(null),u=0;for(let e of n.allKeys)l[e]=`key_${u++}`;o.write(a?`const newResult = memo.alloc(inst, payload, {}, ctx);`:`const newResult = {};`);for(let e of n.allKeys){if(e===`__proto__`)continue;let n=l[e],r=typeof e==`symbol`?`syms[${i.indexOf(e)}]`:te(e),a=`${r} in input`,u=t[e],d=u?._zod?.optin,f=d!==void 0,p=u?._zod?.optout===`optional`;if(o.write(`const ${n} = ${s(r)};`),f&&p){let e=d===`optional`?`${n}_present`:`${n}.value !== undefined || ${n}_present`;o.write(`
15
+ const ${n}_present = ${a};
16
+ if (!${n}.issues.length || ${n}_present) {
17
+ if (${n}.issues.length) {${c(n,r)}
18
+ }
19
+
20
+ if (${e}) {
21
+ newResult[${r}] = ${n}.value;
22
+ }
23
+ }
24
+
25
+ `)}else f?(o.write(`
26
+ if (${n}.issues.length) {${c(n,r)}
27
+ }
28
+ `),d===`defaulted`?o.write(`newResult[${r}] = ${n}.value;`):o.write(`
29
+ if (${n}.value !== undefined || ${a}) {
30
+ newResult[${r}] = ${n}.value;
31
+ }
32
+ `)):o.write(`
33
+ const ${n}_present = ${a};
34
+ if (${n}.issues.length) {${c(n,r)}
35
+ }
36
+ if (!${n}_present && !${n}.issues.length) {
37
+ payload.issues.push({
38
+ code: "invalid_type",
39
+ expected: "nonoptional",
40
+ input: undefined,
41
+ path: [${r}]
42
+ });
43
+ if (ctx && ctx.abortEarly) {
44
+ payload.value = newResult;
45
+ return payload;
46
+ }
47
+ }
48
+
49
+ if (${n}_present) {
50
+ newResult[${r}] = ${n}.value;
51
+ }
52
+
53
+ `)}return o.write(`payload.value = newResult;`),o.write(`return payload;`),o.compile()},s,c=_,l=!M.jitless,u=l&&ie.value,d=t.catchall,f;e._zod.parse=(i,a)=>{f??=r.value;let p=i.value;return c(p)?l&&u&&a?.async===!1&&a.jitless!==!0?(s||=o(t.shape),i=s(i,a),d?vr([],p,i,a,f,e,a?.abortEarly===!0):i):n(i,a):(i.issues.push({expected:`object`,code:`invalid_type`,input:p,inst:e}),i)}});function xr(e,t,n,r){for(let n of e)if(n.issues.length===0)return t.value=n.value,t;let i=e.filter(e=>!S(e));return i.length===1?(t.value=i[0].value,i[0]):(t.issues.push({code:`invalid_union`,input:t.value,inst:n,errors:e.map(e=>e.issues.map(e=>T(e,r,N())))}),t)}var Sr=A(`$ZodUnion`,(e,t)=>{F.init(e,t),k(e,`optin`,e=>e.def.options.some(e=>e._zod.optin===`defaulted`)?`defaulted`:e.def.options.some(e=>e._zod.optin!==void 0)?`optional`:void 0),k(e,`optout`,e=>e.def.options.some(e=>e._zod.optout===`optional`)?`optional`:void 0),k(e,`values`,e=>{if(e.def.options.every(e=>e._zod.values))return new Set(e.def.options.flatMap(e=>Array.from(e._zod.values)))}),k(e,`pattern`,e=>{if(e.def.options.every(e=>e._zod.pattern)){let t=e.def.options.map(e=>e._zod.pattern);return RegExp(`^(${t.map(e=>o(e.source)).join(`|`)})$`)}});let n=t.options.length===1?t.options[0]._zod.run:null;e._zod.parse=(r,i)=>{if(n)return n(r,i);let a=!1,o=[];for(let e of t.options){let t=e._zod.run({value:r.value,issues:[]},i);if(t instanceof Promise)o.push(t),a=!0;else{if(t.issues.length===0)return t;o.push(t)}}return a?Promise.all(o).then(t=>xr(t,r,e,i)):xr(o,r,e,i)}});function Cr(e){let t=new Map;for(let n of e.options){let r=n._zod.propValues?.[e.discriminator];if(!r||r.size===0)throw Error(`Invalid discriminated union option at index "${e.options.indexOf(n)}"`);for(let e of r)if(t.has(e)){if(e!==void 0)throw Error(`Duplicate discriminator value "${String(e)}"`);t.set(e,null)}else t.set(e,n)}return t}var wr=A(`$ZodDiscriminatedUnion`,(e,t)=>{t.inclusive=!1,Sr.init(e,t);let n=e._zod.parse;k(e,`propValues`,e=>{let t={},n=0;for(let r of e.def.options){let i=r._zod.propValues;if(!i||Object.keys(i).length===0)throw Error(`Invalid discriminated union option at index "${e.def.options.indexOf(r)}"`);i[e.def.discriminator]?.has(void 0)&&n++;for(let[e,n]of Object.entries(i)){Object.prototype.hasOwnProperty.call(t,e)||u(t,e,new Set);for(let r of n)t[e].add(r)}}return!e.def.unionFallback&&n>1&&t[e.def.discriminator]?.delete(void 0),t}),t.options.forEach((e,n)=>{let r=d(e._zod.def);if(r&&!Object.prototype.hasOwnProperty.call(r,t.discriminator))throw Error(`Invalid discriminated union option at index "${n}"`)});let r=i(()=>Cr(t));e._zod.parse=(i,a)=>{let o=i.value;if(!_(o))return i.issues.push({code:`invalid_type`,expected:`object`,input:o,inst:e}),i;let s=o?.[t.discriminator],c=r.value.get(s);return c&&(s!==void 0||a.direction!==`backward`)?c._zod.run(i,a):t.unionFallback||a.direction===`backward`?n(i,a):(i.issues.push({code:`invalid_union`,errors:[],note:`No matching discriminator`,discriminator:t.discriminator,options:Array.from(r.value.keys()).filter(e=>r.value.get(e)!==null),input:o,path:[t.discriminator],inst:e}),i)}}),Tr=A(`$ZodIntersection`,(e,t)=>{F.init(e,t),e._zod.parse=(e,n)=>{let r=e.value,i=t.left._zod.run({value:r,issues:[]},n),a=t.right._zod.run({value:r,issues:[]},n);return i instanceof Promise||a instanceof Promise?Promise.all([i,a]).then(([t,n])=>Dr(e,t,n)):Dr(e,i,a)}});function Er(e,t){if(e===t||e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(v(e)&&v(t)){let n=Object.keys(t),r=Object.keys(e).filter(e=>n.indexOf(e)!==-1),i={...e,...t};Object.prototype.hasOwnProperty.call(i,`__proto__`)&&delete i.__proto__;for(let n of r){if(n===`__proto__`)continue;let r=Er(e[n],t[n]);if(!r.valid)return{valid:!1,mergeErrorPath:[n,...r.mergeErrorPath]};i[n]=r.data}return{valid:!0,data:i}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let r=0;r<e.length;r++){let i=e[r],a=t[r],o=Er(i,a);if(!o.valid)return{valid:!1,mergeErrorPath:[r,...o.mergeErrorPath]};n.push(o.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function Dr(e,t,n){let r=new Map,i,a=new Map,o=(e,t)=>{let n;if(e.code===`unrecognized_keys`&&!e.path?.length)i??=e,n=e.keys;else if(e.code===`invalid_key`&&e.origin===`record`&&e.path?.length===1){let t=String(e.path[0]);a.has(t)||a.set(t,e),n=[t]}else return!1;for(let e of n)r.has(e)||r.set(e,{}),r.get(e)[t]=!0;return!0};for(let n of t.issues)o(n,`l`)||e.issues.push(n);for(let t of n.issues)o(t,`r`)||e.issues.push(t);let s=[...r].filter(([,e])=>e.l&&e.r).map(([e])=>e);if(s.length){let t=i?s.filter(e=>i.keys.includes(e)):[];t.length&&e.issues.push({...i,keys:t});for(let n of s)!t.includes(n)&&a.has(n)&&e.issues.push(a.get(n))}let c=Er(t.value,n.value);if(!c.valid){if(S(e))return e;throw Error(`Unmergable intersection. Error path: ${JSON.stringify(c.mergeErrorPath)}`)}return e.value=c.data,e}var Or=A(`$ZodTuple`,(e,t)=>{F.init(e,t);let n=t.items,r=M.memoizer;r?.attach(e),e._zod.parse=(i,a)=>{let o=i.value;if(!Array.isArray(o))return i.issues.push({input:o,inst:e,expected:`tuple`,code:`invalid_type`}),i;i.value=r?r.alloc(e,i,[],a):[];let s=[],c=kr(n,`optin`),l=kr(n,`optout`);if(!t.rest){if(o.length<c)return i.issues.push({code:`too_small`,minimum:c,inclusive:!0,input:o,inst:e,origin:`array`}),i;o.length>n.length&&i.issues.push({code:`too_big`,maximum:n.length,inclusive:!0,input:o,inst:e,origin:`array`})}let u=Array(n.length),d=t.rest?a?.abortEarly:void 0,f=!1;for(let e=0;e<n.length;e++){let t=n[e]._zod.run({value:o[e],issues:[]},a);t instanceof Promise?s.push(t.then(t=>{u[e]=t})):(u[e]=t,d&&!f&&t.issues.length&&(f=S(t)))}if(t.rest&&!f){let e=n.length-1,r=o.slice(n.length),c=i.issues.length;for(let n of r){if(d&&i.issues.length!==c){if(S(i,c))break;c=i.issues.length}e++;let r=t.rest._zod.run({value:n,issues:[]},a);r instanceof Promise?s.push(r.then(t=>Ar(t,i,e))):Ar(r,i,e)}}return s.length?Promise.all(s).then(()=>jr(u,i,n,o,l)):jr(u,i,n,o,l)}});function kr(e,t){for(let n=e.length-1;n>=0;n--)if(!(t===`optin`?e[n]._zod.optin!==void 0:e[n]._zod.optout===`optional`))return n+1;return 0}function Ar(e,t,n){e.issues.length&&t.issues.push(...C(n,e.issues)),t.value[n]=e.value}function jr(e,t,n,r,i){for(let a=0;a<n.length;a++){let o=e[a],s=a<r.length;if(!s&&a>=i&&n[a]._zod.optin===`optional`){t.value.length=a;break}if(o.issues.length){if(!s&&a>=i){t.value.length=a;break}t.issues.push(...C(a,o.issues))}t.value[a]=o.value}for(let e=t.value.length-1;e>=r.length&&n[e]._zod.optout===`optional`&&t.value[e]===void 0;e--)t.value.length=e;return t}var Mr=A(`$ZodRecord`,(e,t)=>{F.init(e,t);let n=M.memoizer;n?.attach(e),e._zod.parse=(r,i)=>{let a=r.value;if(!v(a))return r.issues.push({expected:`record`,code:`invalid_type`,input:a,inst:e}),r;let o=[],s=t.keyType._zod.values;if(s&&!t.partial){r.value=n?n.alloc(e,r,{},i):{};let c=new Set;for(let n of s)if(typeof n==`string`||typeof n==`number`||typeof n==`symbol`){if(c.add(typeof n==`number`?n.toString():n),n===`__proto__`)continue;let s=t.keyType._zod.run({value:n,issues:[]},i);if(s instanceof Promise)throw Error(`Async schemas not supported in object keys currently`);if(s.issues.length){r.issues.push({code:`invalid_key`,origin:`record`,issues:s.issues.map(e=>T(e,i,N())),input:n,path:[n],inst:e});continue}let l=s.value;if(l===`__proto__`)continue;let u=t.valueType._zod.run({value:a[n],issues:[]},i);u instanceof Promise?o.push(u.then(e=>{e.issues.length&&r.issues.push(...C(n,e.issues)),r.value[l]=e.value})):(u.issues.length&&r.issues.push(...C(n,u.issues)),r.value[l]=u.value)}let l;for(let e in a)if(!c.has(e))if(t.mode===`loose`){if(e===`__proto__`)continue;r.value[e]=a[e]}else l??=[],l.push(e);l&&l.length>0&&r.issues.push({code:`unrecognized_keys`,input:a,inst:e,keys:l,continue:!0})}else{r.value=n?n.alloc(e,r,{},i):{};let c;for(let n of Reflect.ownKeys(a)){if(n===`__proto__`||!Object.prototype.propertyIsEnumerable.call(a,n))continue;let l=t.keyType._zod.run({value:n,issues:[]},i);if(l instanceof Promise)throw Error(`Async schemas not supported in object keys currently`);if(typeof n==`string`&&Kt.test(n)&&l.issues.length){let e=t.keyType._zod.run({value:Number(n),issues:[]},i);if(e instanceof Promise)throw Error(`Async schemas not supported in object keys currently`);e.issues.length===0&&(l=e)}if(l.issues.length){t.mode===`loose`?r.value[n]=a[n]:s?(c??=[],c.push(n)):r.issues.push({code:`invalid_key`,origin:`record`,issues:l.issues.map(e=>T(e,i,N())),input:n,path:[n],inst:e});continue}let u=l.value;if(u===`__proto__`)continue;let d=t.valueType._zod.run({value:a[n],issues:[]},i);d instanceof Promise?o.push(d.then(e=>{e.issues.length&&r.issues.push(...C(n,e.issues)),r.value[u]=e.value})):(d.issues.length&&r.issues.push(...C(n,d.issues)),r.value[u]=d.value)}c&&c.length>0&&r.issues.push({code:`unrecognized_keys`,input:a,inst:e,keys:c,continue:!0})}return o.length?Promise.all(o).then(()=>r):r}}),Nr=A(`$ZodEnum`,(t,n)=>{F.init(t,n);let r=e(n.entries),i=new Set(r);t._zod.values=i,k(t,`pattern`,t=>{let n=e(t.def.entries).filter(e=>oe.has(typeof e));return RegExp(n.length?`^(${n.map(e=>y(e.toString())).join(`|`)})$`:`^[^\\s\\S]$`)}),t._zod.parse=(e,n)=>{let a=e.value;return i.has(a)||e.issues.push({code:`invalid_value`,values:r,input:a,inst:t}),e}}),Pr=A(`$ZodLiteral`,(e,t)=>{F.init(e,t);let n=new Set(t.values);e._zod.values=n,k(e,`pattern`,e=>{let t=e.def.values;return RegExp(t.length?`^(${t.map(e=>typeof e==`string`?y(e):e?y(e.toString()):String(e)).join(`|`)})$`:`^[^\\s\\S]$`)}),e._zod.parse=(r,i)=>{let a=r.value;return n.has(a)||r.issues.push({code:`invalid_value`,values:t.values,input:a,inst:e}),r}}),Fr=A(`$ZodTransform`,(e,t)=>{F.init(e,t),e._zod.optin=`optional`,M.memoizer?.guard(e),e._zod.parse=(n,r)=>{if(r.direction===`backward`)throw new Ve(e.constructor.name);let i=t.transform(n.value,n);if(r.async)return(i instanceof Promise?i:Promise.resolve(i)).then(e=>(n.value=e,n));if(i instanceof Promise)throw new j;return n.value=i,n}});function Ir(e,t){return e.value=t.issues.length?void 0:t.value,e}var Lr=A(`$ZodOptional`,(e,t)=>{F.init(e,t),k(e,`optin`,e=>e.def.innerType._zod.optin===`defaulted`?`defaulted`:`optional`),e._zod.optout=`optional`,k(e,`values`,e=>{let t=e.def.innerType._zod.values;return t?new Set([...t,void 0]):void 0}),k(e,`pattern`,e=>{let t=e.def.innerType._zod.pattern;return t?RegExp(`^(${o(t.source)})?$`):void 0}),e._zod.parse=(e,n)=>{if(e.value===void 0){if(t.innerType._zod.optin!==`defaulted`)return e;let r=t.innerType._zod.run({value:e.value,issues:[]},n);return r instanceof Promise?r.then(t=>Ir(e,t)):Ir(e,r)}return t.innerType._zod.run(e,n)}}),Rr=A(`$ZodExactOptional`,(e,t)=>{Lr.init(e,t),k(e,`values`,e=>e.def.innerType._zod.values),k(e,`pattern`,e=>e.def.innerType._zod.pattern),e._zod.parse=(e,n)=>t.innerType._zod.run(e,n)}),zr=A(`$ZodNullable`,(e,t)=>{F.init(e,t),k(e,`optin`,e=>e.def.innerType._zod.optin),k(e,`optout`,e=>e.def.innerType._zod.optout),k(e,`pattern`,e=>{let t=e.def.innerType._zod.pattern;return t?RegExp(`^(${o(t.source)}|null)$`):void 0}),k(e,`values`,e=>e.def.innerType._zod.values?new Set([...e.def.innerType._zod.values,null]):void 0),e._zod.parse=(e,n)=>e.value===null?e:t.innerType._zod.run(e,n)}),Br=A(`$ZodDefault`,(e,t)=>{F.init(e,t),e._zod.optin=`defaulted`,k(e,`values`,e=>e.def.innerType._zod.values),e._zod.parse=(e,n)=>{if(n.direction===`backward`)return t.innerType._zod.run(e,n);if(e.value===void 0)return e.value=t.defaultValue,e;let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(e=>Vr(e,t)):Vr(r,t)}});function Vr(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}var Hr=A(`$ZodPrefault`,(e,t)=>{F.init(e,t),e._zod.optin=`defaulted`,k(e,`values`,e=>e.def.innerType._zod.values),e._zod.parse=(e,n)=>(n.direction===`backward`||e.value===void 0&&(e.value=t.defaultValue),t.innerType._zod.run(e,n))}),Ur=A(`$ZodNonOptional`,(e,t)=>{F.init(e,t),k(e,`values`,e=>{let t=e.def.innerType._zod.values;return t?new Set([...t].filter(e=>e!==void 0)):void 0}),e._zod.parse=(n,r)=>{let i=t.innerType._zod.run(n,r);return i instanceof Promise?i.then(t=>Wr(t,e)):Wr(i,e)}});function Wr(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:`invalid_type`,expected:`nonoptional`,input:e.value,inst:t}),e}function Gr(e,t,n,r){return t.issues.length?(e.value=n.catchValue({...t,value:e.value,error:{issues:t.issues.map(e=>T(e,r,N()))},input:e.value}),e):(e.value=t.value,t.memo&&(e.memo=!0),e)}var Kr=A(`$ZodCatch`,(e,t)=>{F.init(e,t),k(e,`optin`,e=>e.def.innerType._zod.optin===`defaulted`?`defaulted`:`optional`),k(e,`optout`,e=>e.def.innerType._zod.optout),k(e,`values`,e=>e.def.innerType._zod.values),e._zod.parse=(e,n)=>{if(n.direction===`backward`)return t.innerType._zod.run(e,n);let r=t.innerType._zod.run({value:e.value,issues:[]},n);return r instanceof Promise?r.then(r=>Gr(e,r,t,n)):Gr(e,r,t,n)}}),qr=A(`$ZodPipe`,(e,t)=>{F.init(e,t),k(e,`values`,e=>e.def.in._zod.values),k(e,`optin`,e=>e.def.in._zod.optin),k(e,`optout`,e=>e.def.out._zod.optout),k(e,`propValues`,e=>e.def.in._zod.propValues),e._zod.parse=(e,n)=>{if(n.direction===`backward`){let r=t.out._zod.run(e,n);return r instanceof Promise?r.then(e=>Jr(e,t.in,n)):Jr(r,t.in,n)}let r=t.in._zod.run(e,n);return r instanceof Promise?r.then(e=>Jr(e,t.out,n)):Jr(r,t.out,n)}});function Jr(e,t,n){return e.issues.some(e=>e.code!==`unrecognized_keys`)?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}var Yr=A(`$ZodReadonly`,(e,t)=>{F.init(e,t),k(e,`propValues`,e=>e.def.innerType._zod.propValues),k(e,`values`,e=>e.def.innerType._zod.values),k(e,`optin`,e=>e.def.innerType?._zod?.optin),k(e,`optout`,e=>e.def.innerType?._zod?.optout),e._zod.parse=(e,n)=>{if(n.direction===`backward`)return t.innerType._zod.run(e,n);let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(Xr):Xr(r)}});function Xr(e){return e.memo||(e.value=Object.freeze(e.value)),e}var Zr=A(`$ZodLazy`,(e,t)=>{F.init(e,t),l(e._zod,`innerType`,()=>{let e=t;return e._cachedInner||=t.getter(),e._cachedInner}),k(e,`pattern`,e=>e.innerType?._zod?.pattern),k(e,`propValues`,e=>e.innerType?._zod?.propValues),k(e,`optin`,e=>e.innerType?._zod?.optin??void 0),k(e,`optout`,e=>e.innerType?._zod?.optout??void 0),e._zod.parse=(t,n)=>e._zod.innerType._zod.run(t,n)}),Qr=A(`$ZodCustom`,(e,t)=>{P.init(e,t),F.init(e,t),e._zod.parse=(e,t)=>e,e._zod.check=n=>{let r=n.value,i=t.fn(r);if(i instanceof Promise)return i.then(t=>$r(t,n,r,e));$r(i,n,r,e)}});function $r(e,t,n,r){if(!e){let e={code:`custom`,input:n,inst:r,path:[...r._zod.def.path??[]],continue:!r._zod.def.abort};r._zod.def.params&&(e.params=r._zod.def.params),t.issues.push(E(e))}}var ei=class extends Error{constructor(){super(`Cannot parse a reference cycle that closes through a transform`),this.name=`ZodCyclicError`}},ti=`~memo`,ni=[];function ri(e){return typeof e==`object`&&!!e}function ii(e){return e.map(e=>e.path?{...e,path:e.path.slice()}:{...e})}var ai=new WeakMap,L=0,oi=1,R=2;function si(e,t,n){let r=ai.get(e);if(r!==void 0)return r?R:L;if(t.has(e))return R;t.add(e);let i=L,a=e=>{if(i!==R&&e?._zod){let r=si(e,t,n);r>i&&(i=r)}},o=(e,r)=>{let i=L;for(let a of Reflect.ownKeys(e)){let o=Object.getOwnPropertyDescriptor(e,a);if(r&&!o.enumerable)continue;let s=o.get?oi:o.value?._zod?si(o.value,t,n):L;s>i&&(i=s)}return i},s=e=>{e>i&&(i=e)},c=e._zod.def;switch(c.type){case`object`:{let e=d(c);s(e?o(e,!0):oi),a(c.catchall);break}case`array`:a(c.element);break;case`tuple`:for(let e of c.items)a(e);a(c.rest);break;case`record`:case`map`:a(c.keyType),a(c.valueType);break;case`set`:a(c.valueType);break;case`union`:for(let e of c.options)a(e);break;case`intersection`:a(c.left),a(c.right);break;case`optional`:case`nullable`:case`default`:case`prefault`:case`catch`:case`readonly`:case`nonoptional`:case`promise`:case`success`:a(c.innerType);break;case`pipe`:a(c.in),a(c.out);break;case`function`:a(c.input),a(c.output);break;case`lazy`:{let r=c._cachedInner??(n?e._zod.innerType:void 0);s(r?si(r,t,!1):oi);break}case`template_literal`:case`string`:case`number`:case`int`:case`boolean`:case`bigint`:case`symbol`:case`undefined`:case`null`:case`void`:case`never`:case`any`:case`unknown`:case`date`:case`nan`:case`enum`:case`literal`:case`file`:case`transform`:case`custom`:break;default:for(let e in c){let t=Object.getOwnPropertyDescriptor(c,e);if(!t||t.get)continue;let n=t.value;if(!(!n||typeof n!=`object`)){if(n._zod)a(n);else if(Array.isArray(n))for(let e of n)a(e)}}}return t.delete(e),ci(e,i)}function ci(e,t){return t!==oi&&ai.set(e,t===R),t}function li(e,t){let n=e.buckets.get(t);return n||(n=new WeakMap,e.buckets.set(t,n)),n}var ui,di=[],fi={alloc(e,t,n){let r=ui;if(!r)return n;ui=void 0;let i={value:n,issues:null};return r.set(t.value,i),di.push(i),n},guard(e){var t;(t=e._zod).deferred??(t.deferred=[]),e._zod.deferred.push(()=>{let t=e._zod.parse,n=(e,n)=>{if(n.direction!==`backward`&&mi(n,e.value))throw new ei;return t(e,n)};e._zod.parse=n,e._zod.run===t&&(e._zod.run=n)})},attach(e){var t;let n,r=!1,i,a;(t=e._zod).deferred??(t.deferred=[]),e._zod.deferred.push(()=>{let t=e._zod.parse,o=(s,c)=>{if(n===void 0){let i=si(e,new Set,!1);if(i===L)return e._zod.parse=t,e._zod.run===o&&(e._zod.run=t),t(s,c);i===R||r?n=!0:r=!0}let l=s.value;if(!ri(l))return t(s,c);let u=c[ti];u||(u={buckets:new WeakMap,backEdges:void 0},c[ti]=u);let d;i===c?d=a:(d=li(u,e),i=c,a=d);let f=d.get(l);if(f)return s.value=f.value,f.issues?f.issues.length&&s.issues.push(...ii(f.issues)):(s.memo=!0,u.backEdges??=new WeakSet,u.backEdges.add(f.value)),s;ui=d;let p=di.length,m=t(s,c);ui=void 0;let h=di.length>p?di.pop():void 0;return m instanceof Promise?m.then(e=>(h&&(h.issues=e.issues.length?ii(e.issues):ni),e)):(h&&(h.issues=m.issues.length?ii(m.issues):ni),m)};e._zod.parse=o,e._zod.run===t&&(e._zod.run=o)})}};function pi(){return fi}function mi(e,t){let n=e[ti]?.backEdges;return n!==void 0&&ri(t)&&n.has(t)}var hi=()=>{let e={string:{unit:`characters`,verb:`to have`},file:{unit:`bytes`,verb:`to have`},array:{unit:`items`,verb:`to have`},set:{unit:`items`,verb:`to have`},map:{unit:`entries`,verb:`to have`}};function n(t){return e[t]??null}let r={regex:`input`,email:`email address`,url:`URL`,emoji:`emoji`,uuid:`UUID`,uuidv4:`UUIDv4`,uuidv6:`UUIDv6`,nanoid:`nanoid`,guid:`GUID`,cuid:`cuid`,cuid2:`cuid2`,ulid:`ULID`,xid:`XID`,ksuid:`KSUID`,datetime:`ISO datetime`,date:`ISO date`,time:`ISO time`,duration:`ISO duration`,ipv4:`IPv4 address`,ipv6:`IPv6 address`,mac:`MAC address`,cidrv4:`IPv4 range`,cidrv6:`IPv6 range`,base64:`base64-encoded string`,base64url:`base64url-encoded string`,json_string:`JSON string`,e164:`E.164 number`,currency_code:`currency code`,credit_card:`credit card number`,iban:`IBAN`,jwt:`JWT`,template_literal:`input`},i={nan:`NaN`};function a(e,t){return e===`number`&&typeof t==`number`&&!Number.isFinite(t)?String(t):i[e]??e}return e=>{switch(e.code){case`invalid_type`:return`Invalid input: expected ${a(e.expected)}, received ${a(Ee(e.input),e.input)}`;case`invalid_value`:return e.values.length===1?`Invalid input: expected ${se(e.values[0])}`:`Invalid option: expected one of ${t(e.values,`|`)}`;case`too_big`:{let t=e.exact?`exactly `:e.inclusive?`<=`:`<`,r=n(e.origin);return r?`Too big: expected ${e.origin??`value`} to have ${t}${e.maximum.toString()} ${r.unit??`elements`}`:`Too big: expected ${e.origin??`value`} to be ${t}${e.maximum.toString()}`}case`too_small`:{let t=e.exact?`exactly `:e.inclusive?`>=`:`>`,r=n(e.origin);return r?`Too small: expected ${e.origin} to have ${t}${e.minimum.toString()} ${r.unit}`:`Too small: expected ${e.origin} to be ${t}${e.minimum.toString()}`}case`invalid_format`:{let t=e;return t.format===`starts_with`?`Invalid string: must start with "${t.prefix}"`:t.format===`ends_with`?`Invalid string: must end with "${t.suffix}"`:t.format===`includes`?`Invalid string: must include "${t.includes}"`:t.format===`regex`?`Invalid string: must match pattern ${t.pattern}`:`Invalid ${r[t.format]??e.format}`}case`not_multiple_of`:return`Invalid number: must be a multiple of ${e.divisor}`;case`unrecognized_keys`:return`Unrecognized key${e.keys.length>1?`s`:``}: ${t(e.keys,`, `)}`;case`invalid_key`:return`Invalid key in ${e.origin}`;case`invalid_union`:return e.options&&Array.isArray(e.options)&&e.options.length>0?`Invalid discriminator value. Expected ${e.options.map(e=>`'${e}'`).join(` | `)}`:e.inclusive===!1?`Invalid input: more than one option matched`:`Invalid input`;case`invalid_element`:return`Invalid value in ${e.origin}`;default:return`Invalid input`}}};function gi(){return{localeError:hi()}}var _i,vi=class{constructor(){this._map=new WeakMap,this._idmap=new Map}add(e,...t){let n=t[0];return this._map.set(e,n),n&&typeof n==`object`&&`id`in n&&this._idmap.set(n.id,e),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(e){let t=this._map.get(e);return t&&typeof t==`object`&&`id`in t&&this._idmap.delete(t.id),this._map.delete(e),this}get(e){let t=e._zod.parent;if(t){let n={...this.get(t)??{}};delete n.id;let r={...n,...this._map.get(e)};return Object.keys(r).length?r:void 0}return this._map.get(e)}has(e){return this._map.has(e)}};function yi(){return new vi}(_i=globalThis).__zod_globalRegistry??(_i.__zod_globalRegistry=yi());var z=globalThis.__zod_globalRegistry;function bi(e){return e.checks&&=[...e.checks],e}function xi(e,t){return new e(bi({type:`string`,...x(t)}))}function Si(e,t){return new e({type:`string`,format:`email`,check:`string_format`,abort:!1,...x(t)})}function Ci(e,t){return new e({type:`string`,format:`guid`,check:`string_format`,abort:!1,...x(t)})}function wi(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,...x(t)})}function Ti(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,version:`v4`,...x(t)})}function Ei(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,version:`v6`,...x(t)})}function Di(e,t){return new e({type:`string`,format:`uuid`,check:`string_format`,abort:!1,version:`v7`,...x(t)})}function Oi(e,t){return new e({type:`string`,format:`url`,check:`string_format`,abort:!1,...x(t)})}function ki(e,t){return new e({type:`string`,format:`emoji`,check:`string_format`,abort:!1,...x(t)})}function Ai(e,t){return new e({type:`string`,format:`nanoid`,check:`string_format`,abort:!1,...x(t)})}function ji(e,t){return new e({type:`string`,format:`cuid`,check:`string_format`,abort:!1,...x(t)})}function Mi(e,t){return new e({type:`string`,format:`cuid2`,check:`string_format`,abort:!1,...x(t)})}function Ni(e,t){return new e({type:`string`,format:`ulid`,check:`string_format`,abort:!1,...x(t)})}function Pi(e,t){return new e({type:`string`,format:`xid`,check:`string_format`,abort:!1,...x(t)})}function Fi(e,t){return new e({type:`string`,format:`ksuid`,check:`string_format`,abort:!1,...x(t)})}function Ii(e,t){return new e({type:`string`,format:`ipv4`,check:`string_format`,abort:!1,...x(t)})}function Li(e,t){return new e({type:`string`,format:`ipv6`,check:`string_format`,abort:!1,...x(t)})}function Ri(e,t){return new e({type:`string`,format:`cidrv4`,check:`string_format`,abort:!1,...x(t)})}function zi(e,t){return new e({type:`string`,format:`cidrv6`,check:`string_format`,abort:!1,...x(t)})}function Bi(e,t){return new e({type:`string`,format:`base64`,check:`string_format`,abort:!1,...x(t)})}function Vi(e,t){return new e({type:`string`,format:`base64url`,check:`string_format`,abort:!1,...x(t)})}function Hi(e,t){return new e({type:`string`,format:`e164`,check:`string_format`,abort:!1,...x(t)})}function Ui(e,t){return new e({type:`string`,format:`jwt`,check:`string_format`,abort:!1,...x(t)})}function Wi(e,t){return new e({type:`string`,format:`datetime`,check:`string_format`,offset:!1,local:!1,precision:null,...x(t)})}function Gi(e,t){return new e({type:`string`,format:`date`,check:`string_format`,...x(t)})}function Ki(e,t){return new e({type:`string`,format:`time`,check:`string_format`,precision:null,...x(t)})}function qi(e,t){return new e({type:`string`,format:`duration`,check:`string_format`,...x(t)})}function Ji(e,t){return new e(bi({type:`number`,checks:[],...x(t)}))}function Yi(e,t){return new e({type:`number`,check:`number_format`,abort:!1,format:`safeint`,...x(t)})}function Xi(e,t){return new e({type:`boolean`,...x(t)})}function Zi(e,t){return new e({type:`null`,...x(t)})}function Qi(e){return new e({type:`unknown`})}function $i(e,t){return new e({type:`never`,...x(t)})}function ea(e,t){return new $t({check:`less_than`,...x(t),value:e,inclusive:!1})}function ta(e,t){return new $t({check:`less_than`,...x(t),value:e,inclusive:!0})}function na(e,t){return new en({check:`greater_than`,...x(t),value:e,inclusive:!1})}function ra(e,t){return new en({check:`greater_than`,...x(t),value:e,inclusive:!0})}function ia(e,t){return new tn({check:`multiple_of`,...x(t),value:e})}function aa(e,t){return new rn({check:`max_length`,...x(t),maximum:e})}function oa(e,t){return new an({check:`min_length`,...x(t),minimum:e})}function sa(e,t){return new on({check:`length_equals`,...x(t),length:e})}function ca(e,t){return new cn({check:`string_format`,format:`regex`,...x(t),pattern:e})}function la(e){return new ln({check:`string_format`,format:`lowercase`,...x(e)})}function ua(e){return new un({check:`string_format`,format:`uppercase`,...x(e)})}function da(e,t){return new dn({check:`string_format`,format:`includes`,...x(t),includes:e})}function fa(e,t){return new fn({check:`string_format`,format:`starts_with`,...x(t),prefix:e})}function pa(e,t){return new pn({check:`string_format`,format:`ends_with`,...x(t),suffix:e})}function B(e){return new mn({check:`overwrite`,tx:e})}function ma(e){return B(t=>t.normalize(e))}function ha(){return B(e=>e.trim())}function ga(){return B(e=>e.toLowerCase())}function _a(){return B(e=>e.toUpperCase())}function va(){return B(e=>ne(e))}function ya(e,t,n){return new e({type:`array`,element:t,...x(n)})}function ba(e,t,n){return new e({type:`custom`,check:`custom`,fn:t,...x(n)})}function xa(e,t){let n=Sa(t=>(t.addIssue=e=>{if(typeof e==`string`)t.issues.push(E(e,t.value,n._zod.def));else{let r=e;r.fatal&&(r.continue=!1),r.code??=`custom`,`input`in r||(r.input=t.value),r.inst??=n,r.continue??=!n._zod.def.abort,t.issues.push(E(r))}},e(t.value,t)),t);return n}function Sa(e,t){let n=new P({check:`custom`,...x(t)});return n._zod.check=e,n}function V(e,...t){for(let n of t)for(let t of Reflect.ownKeys(n))Object.prototype.propertyIsEnumerable.call(n,t)&&u(e,t,n[t]);return e}function Ca(e){let t=e?.target??`draft-2020-12`;return t===`draft-4`&&(t=`draft-04`),t===`draft-7`&&(t=`draft-07`),{processors:e.processors??{},metadataRegistry:e?.metadata??z,target:t,unrepresentable:e?.unrepresentable??`throw`,override:e?.override??(()=>{}),io:e?.io??`output`,counter:0,seen:new Map,sharedDefsExtractedFor:void 0,sharedEmitDoneFor:void 0,cycles:e?.cycles??`ref`,reused:e?.reused??`inline`,intersections:[],deferred:[],external:e?.external??void 0}}function H(e,t,n,r,i){let a=typeof t.unrepresentable==`function`?t.unrepresentable({zodSchema:e,path:r.path,message:i}):t.unrepresentable;if(a===`any`)return!1;if(a===void 0||a===`throw`)throw Error(i);return Object.assign(n,a),!0}function U(e,t,n={path:[],schemaPath:[]}){var r;let i=e._zod.def,a=t.seen.get(e);if(a)return a.count++,n.schemaPath.includes(e)&&(a.cycle=n.path),a.schema;let o={schema:{},count:1,cycle:void 0,path:n.path};t.seen.set(e,o),t.sharedDefsExtractedFor=void 0,t.sharedEmitDoneFor=void 0;let s=e._zod.toJSONSchema?.();if(s)o.schema=s;else{let r={...n,schemaPath:[...n.schemaPath,e],path:n.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,o.schema,r);else{let n=o.schema,a=t.processors[i.type];if(!a)throw Error(`[toJSONSchema]: Non-representable type encountered: ${i.type}`);a(e,t,n,r)}let a=e._zod.parent;a&&(o.ref||=a,U(a,t,r),t.seen.get(a).isParent=!0)}let c=t.metadataRegistry.get(e);return c&&V(o.schema,c),t.io===`input`&&W(e)&&(delete o.schema.examples,delete o.schema.default),t.io===`input`&&`_prefault`in o.schema&&((r=o.schema).default??(r.default=o.schema._prefault)),delete o.schema._prefault,t.seen.get(e).schema}function wa(e){return e.replace(/~/g,`~0`).replace(/\//g,`~1`)}function Ta(e,t){let n=e.seen.get(t);if(!n)throw Error(`Unprocessed schema. This is a bug in Zod.`);if(e.external&&e.sharedDefsExtractedFor===e.external)return;let r=new Map;for(let t of e.seen.entries()){let n=e.metadataRegistry.get(t[0])?.id;if(n){let e=r.get(n);if(e&&e!==t[0])throw Error(`Duplicate schema id "${n}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(n,t[0])}}let i=t=>{let r=e.target===`draft-2020-12`?`$defs`:`definitions`;if(e.external){let n=e.external.registry.get(t[0])?.id,i=e.external.uri??(e=>e);if(n)return{ref:i(n)};let a=t[1].defId??t[1].schema.id??`schema${e.counter++}`;return t[1].defId=a,{defId:a,ref:`${i(`__shared`)}#/${r}/${wa(a)}`}}let i=`#/${r}/`;if(t[1]===n&&!t[1].schema.id)return{ref:`#`};let a=t[1].schema.id??`__schema${e.counter++}`;return{defId:a,ref:i+wa(a)}},a=e=>{if(e[1].schema.$ref)return;let t=e[1],{ref:n,defId:r}=i(e);t.def={...t.schema},r&&(t.defId=r);let a=t.schema;for(let e in a)delete a[e];a.$ref=n};if(e.cycles===`throw`)for(let t of e.seen.entries()){let e=t[1];if(e.cycle)throw Error(`Cycle detected: #/${e.cycle?.join(`/`)}/<root>
54
+
55
+ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let n of e.seen.entries()){let r=n[1];if(t===n[0]){a(n);continue}if(e.external){let r=e.external.registry.get(n[0])?.id;if(t!==n[0]&&r){a(n);continue}}if(e.metadataRegistry.get(n[0])?.id){a(n);continue}if(r.cycle){a(n);continue}r.count>1&&e.reused===`ref`&&a(n)}e.external&&(e.sharedDefsExtractedFor=e.external)}function Ea(e){let t=e.anyOf;if(!Array.isArray(t)||t.length===0||e.type!==void 0)return;let n=[];for(let e of t){if(!e||typeof e!=`object`)return;Ea(e);let t=Object.keys(e);if(t.length!==1||t[0]!==`type`)return;let r=e.type;for(let e of Array.isArray(r)?r:[r]){if(typeof e!=`string`)return;n.includes(e)||n.push(e)}}delete e.anyOf,e.type=n.length===1?n[0]:n}var Da=new Set([`type`,`properties`,`required`,`additionalProperties`]),Oa=[`oneOf`,`anyOf`];function ka(e){let t=e.additionalProperties;return t===void 0||t===!1||typeof t!=`object`||!t?null:Object.keys(t).length?t:null}function Aa(e){let t=[];for(let n of e){if(typeof n!=`object`||n.type!==`object`)return null;for(let e in n)if(!Da.has(e))return null;t.push(n)}let n={},r=new Set;for(let e of t){for(let r in e.properties){if(Object.prototype.hasOwnProperty.call(n,r))continue;let e=[];for(let n of t){let t=n.properties?.[r]??ka(n);t!=null&&(e.some(e=>JSON.stringify(e)===JSON.stringify(t))||e.push(t))}u(n,r,e.length===1?e[0]:Aa(e)??{allOf:e})}for(let t of e.required??[])r.add(t)}let i={type:`object`,properties:n};if(r.size&&(i.required=[...r]),t.every(e=>e.additionalProperties===!1))i.additionalProperties=!1;else{let e=[];for(let n of t){let t=ka(n);t&&!e.some(e=>JSON.stringify(e)===JSON.stringify(t))&&e.push(t)}e.length===1?i.additionalProperties=e[0]:e.length>1&&(i.additionalProperties={allOf:e})}return i}function ja(e){let t=e.allOf;if(!Array.isArray(t)||t.length<2)return;for(let t of Da)if(t in e)return;let n=t.filter(e=>Oa.some(t=>Array.isArray(e[t]))),r=null;if(!n.length)r=Aa(t);else{let e=n[0],i=Oa.find(t=>Array.isArray(e[t]));if(Object.keys(e).length!==1)return;let a=t.filter(t=>t!==e),o=e[i].map(e=>Aa([...a,e]));if(o.some(e=>!e))return;r={[i]:o}}r&&(delete e.allOf,V(e,r))}function Ma(e,t){let n=e.seen.get(t);if(!n)throw Error(`Unprocessed schema. This is a bug in Zod.`);let r=t=>{let n=e.seen.get(t);if(n.ref===null)return;let i=n.def??n.schema,a={...i},o=n.ref;if(n.ref=null,o){r(o);let n=e.seen.get(o),s=n.schema;if(s.$ref&&(e.target===`draft-07`||e.target===`draft-04`||e.target===`openapi-3.0`)?(i.allOf=i.allOf??[],i.allOf.push(s)):V(i,s),V(i,a),t._zod.parent===o)for(let e in i)e===`$ref`||e===`allOf`||e in a||delete i[e];if(s.$ref&&n.def)for(let e in i)e===`$ref`||e===`allOf`||e in n.def&&JSON.stringify(i[e])===JSON.stringify(n.def[e])&&delete i[e]}let s=t._zod.parent;if(s&&s!==o){r(s);let t=e.seen.get(s);if(t?.schema.$ref&&(i.$ref=t.schema.$ref,t.def))for(let e in i)e===`$ref`||e===`allOf`||e in t.def&&JSON.stringify(i[e])===JSON.stringify(t.def[e])&&delete i[e]}e.override({zodSchema:t,jsonSchema:i,path:n.path??[]})};if(!e.external||e.sharedEmitDoneFor!==e.external){for(let t of[...e.seen.entries()].reverse())r(t[0]);if(e.target!==`openapi-3.0`)for(let t of e.seen.entries())Ea(t[1].def??t[1].schema);for(let t of e.deferred)t();if(e.intersections.length){let t=new Map;for(let n of e.seen.values())for(let e of[n.schema,n.def]){let n=e?.allOf;if(!Array.isArray(n))continue;let r=t.get(n);r?r.push(e):t.set(n,[e])}for(let n of e.intersections)for(let e of t.get(n)??[])ja(e)}}let i={};if(e.target===`draft-2020-12`?i.$schema=`https://json-schema.org/draft/2020-12/schema`:e.target===`draft-07`?i.$schema=`http://json-schema.org/draft-07/schema#`:e.target===`draft-04`?i.$schema=`http://json-schema.org/draft-04/schema#`:e.target,e.external?.uri){let n=e.external.registry.get(t)?.id;if(!n)throw Error("Schema is missing an `id` property");i.$id=e.external.uri(n)}V(i,n.defId?n.schema:n.def??n.schema);let a=e.metadataRegistry.get(t)?.id;a!==void 0&&i.id===a&&delete i.id;let o=e.external?.defs??{};if(!e.external||e.sharedEmitDoneFor!==e.external)for(let t of e.seen.entries()){let e=t[1];e.def&&e.defId&&(e.def.id===e.defId&&delete e.def.id,u(o,e.defId,e.def))}e.external&&(e.sharedEmitDoneFor=e.external),e.external||Object.keys(o).length>0&&(e.target===`draft-2020-12`?i.$defs=o:i.definitions=o);try{let n=JSON.parse(JSON.stringify(i));return Object.defineProperty(n,"~standard",{value:{...t[`~standard`],jsonSchema:{input:Pa(t,`input`,e.processors),output:Pa(t,`output`,e.processors)}},enumerable:!1,writable:!1}),n}catch{throw Error(`Error converting schema to JSON.`)}}function W(e,t){let n=t??{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let r=e._zod.def;if(r.type===`transform`)return!0;if(r.type===`array`)return W(r.element,n);if(r.type===`set`)return W(r.valueType,n);if(r.type===`lazy`)return W(r.getter(),n);if(r.type===`promise`||r.type===`optional`||r.type===`nonoptional`||r.type===`nullable`||r.type===`readonly`||r.type==="default"||r.type===`prefault`||r.type===`catch`)return W(r.innerType,n);if(r.type===`intersection`)return W(r.left,n)||W(r.right,n);if(r.type===`record`||r.type===`map`)return W(r.keyType,n)||W(r.valueType,n);if(r.type===`pipe`)return e._zod.traits.has(`$ZodCodec`)?!0:W(r.in,n)||W(r.out,n);if(r.type===`object`){for(let e in r.shape)if(W(r.shape[e],n))return!0;return!1}if(r.type===`union`){for(let e of r.options)if(W(e,n))return!0;return!1}if(r.type===`tuple`){for(let e of r.items)if(W(e,n))return!0;return!!(r.rest&&W(r.rest,n))}return!1}var Na=(e,t={})=>n=>{let r=Ca({...n,processors:t});return U(e,r),Ta(r,e),Ma(r,e)},Pa=(e,t,n={})=>r=>{let{libraryOptions:i,target:a}=r??{},o=Ca({...i??{},target:a,io:t,processors:n});return U(e,o),Ta(o,e),Ma(o,e)},G=(e,t,n)=>{(e[t]===void 0||n>e[t])&&(e[t]=n)},K=(e,t,n)=>{(e[t]===void 0||n<e[t])&&(e[t]=n)},Fa=(e,t)=>{G(e,`minimum`,t),K(e,`maximum`,t)},Ia=(e,t)=>{e.multipleOf??=[],e.multipleOf.includes(t)||e.multipleOf.push(t)},La=(e,t)=>{e.patterns??=new Set,e.patterns.add(t)},Ra=(e,t)=>{e.mime=e.mime?e.mime.filter(e=>t.includes(e)):[...t]},za=(e,t)=>{e.format=t,t.includes(`int`)&&(e.isInt=!0)},Ba=(e,t)=>G(e,`minimum`,t.minimum),Va=(e,t)=>K(e,`maximum`,t.maximum),Ha=e=>(t,n)=>{za(t,n.format);let[r,i]=e[n.format];G(t,`minimum`,r),K(t,`maximum`,i)},Ua={greater_than:(e,t)=>G(e,t.inclusive?`minimum`:`exclusiveMinimum`,t.value),less_than:(e,t)=>K(e,t.inclusive?`maximum`:`exclusiveMaximum`,t.value),multiple_of:(e,t)=>Ia(e,t.value),number_format:Ha(le),bigint_format:Ha(ue),min_length:Ba,max_length:Va,length_equals:(e,t)=>Fa(e,t.length),min_size:Ba,max_size:Va,size_equals:(e,t)=>Fa(e,t.size),string_format:(e,t)=>{za(e,t.format),t.pattern&&La(e,t.pattern),(t.format===`base64`||t.format===`base64url`)&&(e.contentEncoding=t.format),(t.local||t.precision===-1)&&(e.laxFormat=!0)},mime_type:(e,t)=>Ra(e,t.mime)};function q(e){let t={},n=e._zod.def,r=e._zod.traits.has(`$ZodCheck`)?[e,...n.checks??[]]:n.checks??[];for(let e of r)Ua[e._zod.def.check]?.(t,e._zod.def);let i=e._zod.bag;i.minimum!==void 0&&G(t,`minimum`,i.minimum),i.exclusiveMinimum!==void 0&&G(t,`exclusiveMinimum`,i.exclusiveMinimum),i.maximum!==void 0&&K(t,`maximum`,i.maximum),i.exclusiveMaximum!==void 0&&K(t,`exclusiveMaximum`,i.exclusiveMaximum),i.multipleOf!==void 0&&Ia(t,i.multipleOf),i.format!==void 0&&(t.format??=i.format,i.format.includes(`int`)&&(t.isInt=!0)),i.mime&&Ra(t,i.mime);for(let e of i.patterns??[])La(t,e);return t}var Wa={guid:`uuid`,url:`uri`,datetime:`date-time`,json_string:`json-string`,regex:``},Ga=new Map([[Zn,Pt],[$n,Ft]]),Ka=e=>Ga.get(e)??e,qa=(e,t,n,r)=>{let i=n;i.type=`string`;let{minimum:a,maximum:o,format:s,patterns:c,contentEncoding:l,laxFormat:u}=q(e);if(typeof a==`number`&&(i.minLength=a),typeof o==`number`&&(i.maxLength=o),s&&(i.format=Wa[s]??s,i.format===``&&delete i.format,(s===`time`||u)&&delete i.format),l&&(i.contentEncoding=l),c&&c.size>0){let e=[...c].map(Ka);e.length===1?i.pattern=e[0].source:e.length>1&&(i.allOf=[...e.map(e=>({...t.target===`draft-07`||t.target===`draft-04`||t.target===`openapi-3.0`?{type:`string`}:{},pattern:e.source}))])}},Ja=(e,t,n,r)=>{let i=n,{minimum:a,maximum:o,multipleOf:s,exclusiveMaximum:c,exclusiveMinimum:l,isInt:u}=q(e);i.type=u?`integer`:`number`;let d=typeof l==`number`&&l>=(a??-1/0),f=typeof c==`number`&&c<=(o??1/0),p=t.target===`draft-04`||t.target===`openapi-3.0`;if(d?p?(i.minimum=l,i.exclusiveMinimum=!0):i.exclusiveMinimum=l:typeof a==`number`&&(i.minimum=a),f?p?(i.maximum=c,i.exclusiveMaximum=!0):i.exclusiveMaximum=c:typeof o==`number`&&(i.maximum=o),s){let n=new Set;for(let a of s)Number.isFinite(a)&&a!==0?n.add(Math.abs(a)):H(e,t,i,r,`A multipleOf divisor of ${a} cannot be represented in JSON Schema`);let[a,...o]=n;a!==void 0&&(i.multipleOf=a),o.length&&(i.allOf=[...i.allOf??[],...o.map(e=>({multipleOf:e}))])}},Ya=(e,t,n,r)=>{n.type=`boolean`},Xa=(e,t,n,r)=>{t.target===`openapi-3.0`?(n.type=`string`,n.nullable=!0,n.enum=[null]):n.type=`null`},Za=(e,t,n,r)=>{n.not={}},Qa=(t,n,r,i)=>{let a=t._zod.def,o=e(a.entries);if(o.length===0){r.not={};return}o.every(e=>typeof e==`number`)&&(r.type=`number`),o.every(e=>typeof e==`string`)&&(r.type=`string`),r.enum=o},$a=(e,t,n,r)=>{let i=e._zod.def;if(i.values.length===0){n.not={};return}let a=[];for(let o of i.values)if(o===void 0){if(H(e,t,n,r,"Literal `undefined` cannot be represented in JSON Schema"))return}else if(typeof o==`bigint`){if(H(e,t,n,r,`BigInt literals cannot be represented in JSON Schema`))return;a.push(Number(o))}else a.push(o);if(a.length!==0)if(a.length===1){let e=a[0];n.type=e===null?`null`:typeof e,t.target===`draft-04`||t.target===`openapi-3.0`?n.enum=[e]:n.const=e}else a.every(e=>typeof e==`number`)&&(n.type=`number`),a.every(e=>typeof e==`string`)&&(n.type=`string`),a.every(e=>typeof e==`boolean`)&&(n.type=`boolean`),a.every(e=>e===null)&&(n.type=`null`),n.enum=a},eo=(e,t,n,r)=>{H(e,t,n,r,`Custom types cannot be represented in JSON Schema`)},to=(e,t,n,r)=>{H(e,t,n,r,`Transforms cannot be represented in JSON Schema`)},no=(e,t,n,r)=>{let i=n,a=e._zod.def,{minimum:o,maximum:s}=q(e);typeof o==`number`&&(i.minItems=o),typeof s==`number`&&(i.maxItems=s),i.type=`array`,i.items=U(a.element,t,{...r,path:[...r.path,`items`]})};function J(e){let t=e._zod.def;return t.type===`pipe`&&t.in._zod.traits.has(`$ZodTransform`)?J(t.out):t.type===`catch`?J(t.innerType):e._zod.optin}var ro=(e,t,n,r)=>{let i=n,a=e._zod.def,o=a.shape;if(Object.getOwnPropertySymbols(o).length&&H(e,t,i,r,`Symbol keys cannot be represented in JSON Schema`))return;i.type=`object`,i.properties={};for(let e in o)u(i.properties,e,U(o[e],t,{...r,path:[...r.path,`properties`,e]}));let s=[];for(let e of Object.keys(o)){let n=a.shape[e];(t.io===`input`?J(n)===void 0:n._zod.optout===void 0)&&s.push(e)}s.length>0&&(i.required=s),a.catchall?._zod.def.type===`never`?i.additionalProperties=!1:a.catchall?a.catchall&&(i.additionalProperties=U(a.catchall,t,{...r,path:[...r.path,`additionalProperties`]})):t.io===`output`&&(i.additionalProperties=!1)},io=(e,t,n,r)=>{let i=e._zod.def,a=i.inclusive===!1,o=i.options.map((e,n)=>U(e,t,{...r,path:[...r.path,a?`oneOf`:`anyOf`,n]}));a?n.oneOf=o:n.anyOf=o},ao=(e,t,n,r)=>{let i=e._zod.def,a=U(i.left,t,{...r,path:[...r.path,`allOf`,0]}),o=U(i.right,t,{...r,path:[...r.path,`allOf`,1]}),s=e=>`allOf`in e&&Object.keys(e).length===1,c=[...s(a)?a.allOf:[a],...s(o)?o.allOf:[o]];n.allOf=c,t.intersections.push(c)},oo=(e,t,n,r)=>{let i=n,a=e._zod.def;i.type=`array`;let o=t.target===`draft-2020-12`?`prefixItems`:`items`,s=t.target===`draft-2020-12`||t.target===`openapi-3.0`?`items`:`additionalItems`,c=a.items.map((e,n)=>U(e,t,{...r,path:[...r.path,o,n]})),l=a.rest?U(a.rest,t,{...r,path:[...r.path,s,...t.target===`openapi-3.0`?[a.items.length]:[]]}):null,u=a.items.length;for(;u>0;){let e=a.items[u-1];if(!(t.io===`input`?J(e)!==void 0:e._zod.optout===`optional`))break;u--}let d=a.items.length,f=!a.rest;t.target===`draft-2020-12`?(i.prefixItems=c,f?i.items=!1:l&&(i.items=l),u>0&&(i.minItems=u),f&&(i.maxItems=d)):t.target===`openapi-3.0`?(i.items={anyOf:c},l&&i.items.anyOf.push(l),u>0&&(i.minItems=u),f&&(i.maxItems=d)):(i.items=c,f?i.additionalItems=!1:l&&(i.additionalItems=l),u>0&&(i.minItems=u),f&&(i.maxItems=d));let{minimum:p,maximum:m}=q(e);typeof p==`number`&&(i.minItems=p),typeof m==`number`&&(i.maxItems=m)};function so(e,t,n){if(t.$ref){if(n.has(t))return t;n.add(t);let r=e.get(t)?.def;if(!r)return t;let i=so(e,r,n);return i===r?t:i}for(let r of[`anyOf`,`oneOf`]){let i=t[r];if(!Array.isArray(i))continue;let a=i.map(t=>so(e,t,n));a.some((e,t)=>e!==i[t])&&(t={...t,[r]:a})}let r=Array.isArray(t.type)?t.type:[t.type],i=!r.includes(`string`)&&r.some(e=>e===`number`||e===`integer`),a=t.enum??(t.const===void 0?void 0:[t.const]);if(!i&&!a?.some(e=>typeof e==`number`))return t;let{minimum:o,maximum:s,exclusiveMinimum:c,exclusiveMaximum:l,multipleOf:u,format:d,id:f,...p}=t;return p.enum?p.enum=p.enum.map(e=>typeof e==`number`?String(e):e):typeof p.const==`number`&&(p.const=String(p.const)),i?(p.type=`string`,a||(p.pattern=(r.includes(`number`)?Kt:Gt).source),p):p}var co=new WeakMap;function lo(e){let t=new Map;for(let n of e.seen.values())n.def&&!t.has(n.schema)&&t.set(n.schema,n);let n=new Map;for(let r of co.get(e)??[]){let i=e.seen.get(r),a=(i?.def??i?.schema)?.propertyNames;if(!a||a===!0||n.has(a))continue;let o=so(t,a,new Set);o!==a&&n.set(a,o)}if(n.size)for(let t of e.seen.values())for(let e of[t.schema,t.def]){let t=e&&n.get(e.propertyNames);t&&(e.propertyNames=t)}}var uo=(e,t,n,r)=>{let i=n,a=e._zod.def;i.type=`object`;let o=a.keyType,s=q(o).patterns;if(a.mode===`loose`&&s&&s.size>0){let e=U(a.valueType,t,{...r,path:[...r.path,`patternProperties`,`*`]});i.patternProperties={};for(let t of s)u(i.patternProperties,Ka(t).source,e)}else{if(t.target===`draft-07`||t.target===`draft-2020-12`){i.propertyNames=U(a.keyType,t,{...r,path:[...r.path,`propertyNames`]});let n=co.get(t);n||(n=[],co.set(t,n),t.deferred.push(()=>lo(t))),n.push(e)}i.additionalProperties=U(a.valueType,t,{...r,path:[...r.path,`additionalProperties`]})}let c=o._zod.values,l=t.io===`input`&&J(a.valueType)!==void 0;if(c&&!a.partial&&!l){let e=[...c].filter(e=>typeof e==`string`||typeof e==`number`);e.length>0&&(i.required=e.map(String))}},fo=(e,t,n,r)=>{let i=e._zod.def,a=U(i.innerType,t,r),o=t.seen.get(e);t.target===`openapi-3.0`?(o.ref=i.innerType,n.nullable=!0):n.anyOf=[a,{type:`null`}]},po=(e,t,n,r)=>{let i=e._zod.def;U(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType},mo=Symbol();function ho(e,t,n,r,i){let a=!1,o=JSON.stringify(e,(e,t)=>typeof t==`bigint`?(a=!0,null):t);return a?(H(t,n,r,i,`BigInt defaults cannot be represented in JSON Schema`),mo):JSON.parse(o)}var go=(e,t,n,r)=>{let i=e._zod.def;U(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType;let o=ho(i.defaultValue,e,t,n,r);o!==mo&&(n.default=o)},_o=(e,t,n,r)=>{let i=e._zod.def;U(i.innerType,t,r);let a=t.seen.get(e);if(a.ref=i.innerType,t.io!==`input`)return;let o=ho(i.defaultValue,e,t,n,r);o!==mo&&(n._prefault=o)},vo=(e,t,n,r)=>{let i=e._zod.def;U(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType;let o;try{o=i.catchValue(void 0)}catch{H(e,t,n,r,`Dynamic catch values are not supported in JSON Schema`);return}n.default=o},yo=(e,t,n,r)=>{let i=e._zod.def,a=i.in._zod.traits.has(`$ZodTransform`),o=t.io===`input`?a?i.out:i.in:i.out;U(o,t,r);let s=t.seen.get(e);s.ref=o},bo=(e,t,n,r)=>{let i=e._zod.def;U(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType,n.readOnly=!0},xo=(e,t,n,r)=>{let i=e._zod.def;U(i.innerType,t,r);let a=t.seen.get(e);a.ref=i.innerType},So=(e,t,n,r)=>{let i=e._zod.innerType;U(i,t,r);let a=t.seen.get(e);a.ref=i},Co=new WeakSet([Object.prototype,Error.prototype]);function wo(e,t,n){Object.defineProperty(e,t,{configurable:!0,enumerable:!1,get(){let e=n(this);return Object.defineProperty(this,t,{value:e,configurable:!0,writable:!0}),e},set(e){Object.defineProperty(this,t,{value:e,configurable:!0,writable:!0})}})}var Y=A(`ZodError`,(e,t)=>{Je.init(e,t),e.name=`ZodError`;let r=Object.getPrototypeOf(e);Co.has(r)||(Co.add(r),wo(r,`format`,e=>t=>Ze(e,t)),wo(r,`flatten`,e=>t=>Xe(e,t)),wo(r,`addIssue`,e=>t=>{e.issues.push(t),e.message=JSON.stringify(e.issues,n,2)}),wo(r,`addIssues`,e=>t=>{e.issues.push(...t),e.message=JSON.stringify(e.issues,n,2)}),Object.defineProperty(r,"isEmpty",{configurable:!0,enumerable:!1,get(){return this.issues.length===0}}))},void 0,{Parent:Error}),To=$e(Y),Eo=et(Y),Do=tt(Y),Oo=rt(Y),ko=lt(Y),Ao=ut(Y),jo=dt(Y),Mo=ft(Y),No=pt(Y),Po=mt(Y),Fo=ht(Y),Io=gt(Y);function Lo(){M.localeError||N(gi())}function X(){M.memoizer||N({memoizer:pi()})}var Z=A(`ZodType`,(e,t)=>(Lo(),F.init(e,t),e.def=t,e.type=t.type,e),{check(...e){let t=this.def;return this.clone(g(t,{checks:[...t.checks??[],...e.map(e=>typeof e==`function`?{_zod:{check:e,def:{check:`custom`},onattach:[]}}:e)]}),{parent:!0})},with(...e){return this.check(...e)},clone(e,t){return b(this,e,t)},brand(){return this},register(e,t){return e.add(this,t),this},refine(e,t){return this.check(fc(e,t))},superRefine(e,t){return this.check(pc(e,t))},overwrite(e){return this.check(B(e))},optional(){return Ks(this)},exactOptional(){return Js(this)},nullable(){return Xs(this)},nullish(){return Ks(Xs(this))},nonoptional(e){return nc(this,e)},array(){return ws(this)},or(e){return As([this,e])},and(e){return Ps(this,e)},transform(e){return oc(this,Ws(e))},default(e){return Qs(this,e)},prefault(e){return ec(this,e)},catch(e){return ic(this,e)},pipe(e){return oc(this,e)},readonly(){return cc(this)},describe(e){let t=this.clone();return z.add(t,{description:e}),t},meta(...e){if(e.length===0)return z.get(this);let t=this.clone();return z.add(t,e[0]),t},isOptional(){return this.safeParse(void 0).success},isNullable(){return this.safeParse(null).success},apply(e,...t){return t.length===0?e(this):e(this,...t)},get"~standard"(){return Oe(this,`~standard`,{...yn(this),jsonSchema:{input:Pa(this,`input`),output:Pa(this,`output`)}})},set"~standard"(e){D(this,`~standard`,e)},parse:function e(t,n){return To(this,t,n,{callee:e})},parseAsync:async function e(t,n){return await Eo(this,t,n,{callee:e})},safeParse(e,t){return Do(this,e,t)},async safeParseAsync(e,t){return Oo(this,e,t)},get spa(){return this?.safeParseAsync},set spa(e){D(this,`spa`,e)},validate(e,t){return ot(this,e,t)},validateAsync(e,t){return ct(this,e,t)},encode:function e(t,n){return ko(this,t,n,{callee:e})},decode:function e(t,n){return Ao(this,t,n,{callee:e})},encodeAsync:async function e(t,n){return await jo(this,t,n,{callee:e})},decodeAsync:async function e(t,n){return await Mo(this,t,n,{callee:e})},safeEncode(e,t){return No(this,e,t)},safeDecode(e,t){return Po(this,e,t)},async safeEncodeAsync(e,t){return Fo(this,e,t)},async safeDecodeAsync(e,t){return Io(this,e,t)},toJSONSchema(e){return Na(this,{})(e)},get description(){return z.get(this)?.description},get _def(){return this._zod.def}}),Ro=A(`_ZodString`,(e,t)=>{bn.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>qa(e,t,n,r)},ke({format:e=>q(e).format??null,minLength:e=>q(e).minimum??null,maxLength:e=>q(e).maximum??null},{regex(...e){return this.check(ca(...e))},includes(...e){return this.check(da(...e))},startsWith(...e){return this.check(fa(...e))},endsWith(...e){return this.check(pa(...e))},min(...e){return this.check(oa(...e))},max(...e){return this.check(aa(...e))},length(...e){return this.check(sa(...e))},nonempty(...e){return this.check(oa(1,...e))},lowercase(e){return this.check(la(e))},uppercase(e){return this.check(ua(e))},trim(){return this.check(ha())},normalize(...e){return this.check(ma(...e))},toLowerCase(){return this.check(ga())},toUpperCase(){return this.check(_a())},slugify(){return this.check(va())}})),zo=A(`ZodString`,(e,t)=>{bn.init(e,t),Ro.init(e,t)},{email(e){return this.check(Si(Go,e))},url(e){return this.check(Oi(Jo,e))},jwt(e){return this.check(Ui(us,e))},emoji(e){return this.check(ki(Xo,e))},guid(e){return this.check(Ci(Ko,e))},uuid(e){return this.check(wi($,e))},uuidv4(e){return this.check(Ti($,e))},uuidv6(e){return this.check(Ei($,e))},uuidv7(e){return this.check(Di($,e))},nanoid(e){return this.check(Ai(Zo,e))},cuid(e){return this.check(ji(Qo,e))},cuid2(e){return this.check(Mi($o,e))},ulid(e){return this.check(Ni(es,e))},base64(e){return this.check(Bi(ss,e))},base64url(e){return this.check(Vi(cs,e))},xid(e){return this.check(Pi(ts,e))},ksuid(e){return this.check(Fi(ns,e))},ipv4(e){return this.check(Ii(rs,e))},ipv6(e){return this.check(Li(is,e))},cidrv4(e){return this.check(Ri(as,e))},cidrv6(e){return this.check(zi(os,e))},e164(e){return this.check(Hi(ls,e))},datetime(e){return this.check(Wi(Vo,e))},date(e){return this.check(Gi(Ho,e))},time(e){return this.check(Ki(Uo,e))},duration(e){return this.check(qi(Wo,e))}});function Bo(e){return xi(zo,e)}var Q=A(`ZodStringFormat`,(e,t)=>{I.init(e,t),Ro.init(e,t)}),Vo=A(`ZodISODateTime`,(e,t)=>{zn.init(e,t),Q.init(e,t)}),Ho=A(`ZodISODate`,(e,t)=>{Bn.init(e,t),Q.init(e,t)}),Uo=A(`ZodISOTime`,(e,t)=>{Vn.init(e,t),Q.init(e,t)}),Wo=A(`ZodISODuration`,(e,t)=>{Hn.init(e,t),Q.init(e,t)}),Go=A(`ZodEmail`,(e,t)=>{Cn.init(e,t),Q.init(e,t)}),Ko=A(`ZodGUID`,(e,t)=>{xn.init(e,t),Q.init(e,t)}),$=A(`ZodUUID`,(e,t)=>{Sn.init(e,t),Q.init(e,t)});function qo(e){return wi($,e)}var Jo=A(`ZodURL`,(e,t)=>{jn.init(e,t),Q.init(e,t)});function Yo(e){return Oi(Jo,e)}var Xo=A(`ZodEmoji`,(e,t)=>{Mn.init(e,t),Q.init(e,t)}),Zo=A(`ZodNanoID`,(e,t)=>{Nn.init(e,t),Q.init(e,t)}),Qo=A(`ZodCUID`,(e,t)=>{Pn.init(e,t),Q.init(e,t)}),$o=A(`ZodCUID2`,(e,t)=>{Fn.init(e,t),Q.init(e,t)}),es=A(`ZodULID`,(e,t)=>{In.init(e,t),Q.init(e,t)}),ts=A(`ZodXID`,(e,t)=>{Ln.init(e,t),Q.init(e,t)}),ns=A(`ZodKSUID`,(e,t)=>{Rn.init(e,t),Q.init(e,t)}),rs=A(`ZodIPv4`,(e,t)=>{Un.init(e,t),Q.init(e,t)}),is=A(`ZodIPv6`,(e,t)=>{Kn.init(e,t),Q.init(e,t)}),as=A(`ZodCIDRv4`,(e,t)=>{qn.init(e,t),Q.init(e,t)}),os=A(`ZodCIDRv6`,(e,t)=>{Yn.init(e,t),Q.init(e,t)}),ss=A(`ZodBase64`,(e,t)=>{Qn.init(e,t),Q.init(e,t)}),cs=A(`ZodBase64URL`,(e,t)=>{tr.init(e,t),Q.init(e,t)}),ls=A(`ZodE164`,(e,t)=>{nr.init(e,t),Q.init(e,t)}),us=A(`ZodJWT`,(e,t)=>{ir.init(e,t),Q.init(e,t)}),ds=A(`ZodNumber`,(e,t)=>{ar.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ja(e,t,n,r),e.isFinite=!0},ke({minValue:e=>{let{minimum:t,exclusiveMinimum:n}=q(e);return Math.max(t??-1/0,n??-1/0)},maxValue:e=>{let{maximum:t,exclusiveMaximum:n}=q(e);return Math.min(t??1/0,n??1/0)},isInt:e=>{let{isInt:t,multipleOf:n}=q(e);return!!t||!!n?.some(Number.isSafeInteger)},format:e=>q(e).format??null},{gt(e,t){return this.check(na(e,t))},gte(e,t){return this.check(ra(e,t))},min(e,t){return this.check(ra(e,t))},lt(e,t){return this.check(ea(e,t))},lte(e,t){return this.check(ta(e,t))},max(e,t){return this.check(ta(e,t))},int(e){return this.check(ms(e))},safe(e){return this.check(ms(e))},positive(e){return this.check(na(0,e))},nonnegative(e){return this.check(ra(0,e))},negative(e){return this.check(ea(0,e))},nonpositive(e){return this.check(ta(0,e))},multipleOf(e,t){return this.check(ia(e,t))},step(e,t){return this.check(ia(e,t))},finite(){return this}}));function fs(e){return Ji(ds,e)}var ps=A(`ZodNumberFormat`,(e,t)=>{or.init(e,t),ds.init(e,t)});function ms(e){return Yi(ps,e)}var hs=A(`ZodBoolean`,(e,t)=>{sr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Ya(e,t,n,r)});function gs(e){return Xi(hs,e)}var _s=A(`ZodNull`,(e,t)=>{cr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Xa(e,t,n,r)});function vs(e){return Zi(_s,e)}var ys=A(`ZodUnknown`,(e,t)=>{lr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(e,t,n)=>void 0});function bs(){return Qi(ys)}var xs=A(`ZodNever`,(e,t)=>{ur.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Za(e,t,n,r)});function Ss(e){return $i(xs,e)}var Cs=A(`ZodArray`,(e,t)=>{X(),mr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>no(e,t,n,r),e.element=t.element},{min(e,t){return this.check(oa(e,t))},nonempty(e){return this.check(oa(1,e))},max(e,t){return this.check(aa(e,t))},length(e,t){return this.check(sa(e,t))},unwrap(){return this.element}});function ws(e,t){return ya(Cs,e,t)}var Ts=A(`ZodObject`,(e,t)=>{X(),br.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ro(e,t,n,r),Pe(e,`shape`,e=>e._zod.def.shape,!1)},{keyof(){return Bs(Object.keys(this._zod.def.shape))},catchall(e){return this.clone(g(this._zod.def,{catchall:e}))},passthrough(){return this.clone(g(this._zod.def,{catchall:bs()}))},loose(){return this.clone(g(this._zod.def,{catchall:bs()}))},strict(){return this.clone(g(this._zod.def,{catchall:Ss()}))},strip(){return this.clone(g(this._zod.def,{catchall:void 0}))},extend(e){return me(this,e)},safeExtend(e){return ge(this,e)},merge(e){return _e(this,e)},pick(e){return de(this,e)},omit(e){return pe(this,e)},partial(...e){return ve(Gs,this,e[0])},exactPartial(...e){return ve(qs,this,e[0],`exactPartial`)},required(...e){return ye(tc,this,e[0])}});function Es(e,t){return new Ts({type:`object`,shape:e??{},...x(t)})}function Ds(e,t){return new Ts({type:`object`,shape:e,catchall:Ss(),...x(t)})}function Os(e,t){return new Ts({type:`object`,shape:e,catchall:bs(),...x(t)})}var ks=A(`ZodUnion`,(e,t)=>{Sr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>io(e,t,n,r),e.options=t.options});function As(e,t){return new ks({type:`union`,options:e,...x(t)})}var js=A(`ZodDiscriminatedUnion`,(e,t)=>{ks.init(e,t),wr.init(e,t)});function Ms(e,t,n){return new js({type:`union`,options:t,discriminator:e,...x(n)})}var Ns=A(`ZodIntersection`,(e,t)=>{Tr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ao(e,t,n,r)});function Ps(e,t){return new Ns({type:`intersection`,left:e,right:t})}var Fs=A(`ZodTuple`,(e,t)=>{X(),Or.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>oo(e,t,n,r)},{rest(e){return this.clone({...this._zod.def,rest:e})},partial(){let e=this._zod.def;if(e.checks?.length)throw Error(`.partial() cannot be used on tuple schemas containing refinements`);return this.clone({...e,items:e.items.map(e=>new Gs({type:`optional`,innerType:e}))})}});function Is(e,t,n){let r=t instanceof F;return new Fs({type:`tuple`,items:e,rest:r?t:null,...x(r?n:t)})}var Ls=A(`ZodRecord`,(e,t)=>{X(),Mr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>uo(e,t,n,r),e.keyType=t.keyType,e.valueType=t.valueType});function Rs(e,t,n){return!t||!t._zod?new Ls({type:`record`,keyType:Bo(),valueType:e,...x(t)}):new Ls({type:`record`,keyType:e,valueType:t,...x(n)})}var zs=A(`ZodEnum`,(e,t)=>{Nr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>Qa(e,t,n,r),e.enum=t.entries,e.options=[...e._zod.values];let n=new Set(Object.keys(t.entries));e.extract=(e,r)=>{let i={};for(let r of e)if(n.has(r))i[r]=t.entries[r];else throw Error(`Key ${r} not found in enum`);return new zs({...t,checks:[],...x(r),entries:i})},e.exclude=(e,r)=>{let i={...t.entries};for(let t of e)if(n.has(t))delete i[t];else throw Error(`Key ${t} not found in enum`);return new zs({...t,checks:[],...x(r),entries:i})}});function Bs(e,t){return new zs({type:`enum`,entries:Array.isArray(e)?Object.fromEntries(e.map(e=>[e,e])):e,...x(t)})}var Vs=A(`ZodLiteral`,(e,t)=>{Pr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>$a(e,t,n,r),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function Hs(e,t){return new Vs({type:`literal`,values:Array.isArray(e)?e:[e],...x(t)})}var Us=A(`ZodTransform`,(e,t)=>{X(),Fr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>to(e,t,n,r),e._zod.parse=(n,r)=>{if(r.direction===`backward`)throw new Ve(e.constructor.name);n.addIssue=r=>{if(typeof r==`string`)n.issues.push(E(r,n.value,t));else{let t=r;t.fatal&&(t.continue=!1),t.code??=`custom`,`input`in t||(t.input=n.value),t.inst??=e,n.issues.push(E(t))}};let i=t.transform(n.value,n);return i instanceof Promise?i.then(e=>(n.value=e,n)):(n.value=i,n)}});function Ws(e){return new Us({type:`transform`,transform:e})}var Gs=A(`ZodOptional`,(e,t)=>{Lr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>xo(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Ks(e){return new Gs({type:`optional`,innerType:e})}var qs=A(`ZodExactOptional`,(e,t)=>{Rr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>xo(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Js(e){return new qs({type:`optional`,innerType:e})}var Ys=A(`ZodNullable`,(e,t)=>{zr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>fo(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function Xs(e){return new Ys({type:`nullable`,innerType:e})}var Zs=A(`ZodDefault`,(e,t)=>{Br.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>go(e,t,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Qs(e,t){return new Zs({type:`default`,innerType:e,get defaultValue(){return typeof t==`function`?t():ae(t)}})}var $s=A(`ZodPrefault`,(e,t)=>{Hr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>_o(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function ec(e,t){return new $s({type:`prefault`,innerType:e,get defaultValue(){return typeof t==`function`?t():ae(t)}})}var tc=A(`ZodNonOptional`,(e,t)=>{Ur.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>po(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function nc(e,t){return new tc({type:`nonoptional`,innerType:e,...x(t)})}var rc=A(`ZodCatch`,(e,t)=>{Kr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>vo(e,t,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function ic(e,t){return new rc({type:`catch`,innerType:e,catchValue:typeof t==`function`?t:Ie(t)})}var ac=A(`ZodPipe`,(e,t)=>{qr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>yo(e,t,n,r),e.in=t.in,e.out=t.out});function oc(e,t){return new ac({type:`pipe`,in:e,out:t})}var sc=A(`ZodReadonly`,(e,t)=>{Yr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>bo(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function cc(e){return new sc({type:`readonly`,innerType:e})}var lc=A(`ZodLazy`,(e,t)=>{Zr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>So(e,t,n,r),e.unwrap=()=>e._zod.def.getter()});function uc(e){return new lc({type:`lazy`,getter:e})}var dc=A(`ZodCustom`,(e,t)=>{Qr.init(e,t),Z.init(e,t),e._zod.processJSONSchema=(t,n,r)=>eo(e,t,n,r)});function fc(e,t={}){return ba(dc,e,t)}function pc(e,t){return xa(e,t)}function mc(e){let t=uc(()=>As([Bo(e),fs(),gs(),vs(),ws(t),Rs(Bo(),t)]));return t}export{bs as _,gs as a,Wi as b,Hs as c,Es as d,Rs as f,As as g,Is as h,ws as i,Os as l,Bo as m,Bs as n,Ms as o,Ds as p,vs as r,mc as s,Vo as t,fs as u,Yo as v,qo as y};
@@ -0,0 +1 @@
1
+ import{t as e}from"./createLucideIcon-DPHK1VkS.js";var t=e(`search`,[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]);export{t};
@@ -0,0 +1 @@
1
+ import{i as e}from"./rolldown-runtime-aKtaBQYM.js";import{a as t,n,t as r}from"./vendor-react-BOUWij0V.js";import{t as i}from"./createLucideIcon-DPHK1VkS.js";import{t as a}from"./circle-check-C23XjkUj.js";import{t as o}from"./copy-Dv6d4Dvw.js";import{t as s}from"./eye-CABVeTq0.js";import{t as c}from"./loader-circle-CifKLtgG.js";import{t as l}from"./cn-0WouolD0.js";import{t as ee}from"./copy-to-clipboard-HOJ79TWv.js";import{n as u}from"./interaction-BdhHBbYa.js";import{s as d}from"./form-field-width-DJw_jULe.js";import{n as f,t as te}from"./is-masked-secret-DOkL5b_X.js";var ne=i(`eye-off`,[[`path`,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,key:`ct8e1f`}],[`path`,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,key:`151rxh`}],[`path`,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,key:`13bj9a`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),re=n(),p=e(t(),1),m={showKey:!1,revealed:void 0,revealLoading:!1,revealErr:null,copied:!1};function h(e,t){switch(t.type){case`reset-reveal`:return{...e,showKey:!1,revealed:void 0,revealErr:null};case`toggle-show`:return{...e,showKey:!e.showKey};case`reveal-start`:return{...e,revealLoading:!0,revealErr:null};case`reveal-success`:return{...e,revealed:t.value,revealLoading:!1,showKey:t.show??!0,revealErr:null};case`reveal-error`:return{...e,revealed:null,revealLoading:!1,revealErr:t.message};case`copied`:return{...e,copied:!0};case`clear-copied`:return{...e,copied:!1};case`invalidate-reveal`:return{...e,revealed:void 0,showKey:!1}}}function g(e){let{value:t,reveal:n,loadFailedLabel:r=`Failed to load secret`,baselineValue:i,allowUnrevealedCopy:a=!1}=e,[o,s]=(0,p.useReducer)(h,m),c=f(t),l=!!(i?.trim()&&t===i&&!c),u=(0,p.useRef)(n);u.current=n;let d=(0,p.useRef)({masked:c,value:t,unchangedConcealed:l});(!c&&!l&&(d.current.masked||d.current.unchangedConcealed)||d.current.value!==t&&!l)&&s({type:`reset-reveal`}),d.current={masked:c,value:t,unchangedConcealed:l};let ne=l&&!o.showKey?te(t.length):c&&o.showKey&&typeof o.revealed==`string`?o.revealed:t,re=l&&!o.showKey?`password`:l&&o.showKey?`text`:c?o.showKey&&typeof o.revealed==`string`?`text`:`password`:o.showKey?`text`:`password`,g=l&&!o.showKey,_=l&&t.trim()||!c&&t.trim()&&!f(t)?t.trim():typeof o.revealed==`string`&&o.revealed.length>0?o.revealed:``,ie=_.length>0||a&&c&&!!n,v=(0,p.useCallback)(async()=>{let e=_;if(!e&&a&&c&&u.current){s({type:`reveal-start`});try{let t=await u.current();s({type:`reveal-success`,value:t,show:!1}),e=t??``}catch(e){s({type:`reveal-error`,message:e instanceof Error?e.message:r});return}}e&&await ee(e)&&(s({type:`copied`}),window.setTimeout(()=>s({type:`clear-copied`}),2e3))},[a,_,r,c]),y=(0,p.useCallback)(async()=>{if(l||!c){s({type:`toggle-show`});return}if(o.revealed!==void 0){s({type:`toggle-show`});return}if(!u.current){s({type:`toggle-show`});return}s({type:`reveal-start`});try{let e=await u.current();s({type:`reveal-success`,value:e})}catch(e){s({type:`reveal-error`,message:e instanceof Error?e.message:r})}},[r,c,l,o.revealed]),b=(0,p.useCallback)((e,t)=>{g||(c&&typeof o.revealed==`string`&&o.showKey&&e!==o.revealed&&s({type:`invalidate-reveal`}),t(e))},[c,g,o.revealed,o.showKey]),x=o.revealLoading||!c&&!l&&!t.trim()||c&&!n&&o.revealed===void 0;return{masked:c,unchangedConcealed:l,showKey:o.showKey,revealed:o.revealed,revealLoading:o.revealLoading,revealErr:o.revealErr,copied:o.copied,inputValue:ne,inputType:re,readOnly:g,copyEnabled:ie,copySecret:v,toggleEye:y,onInputChange:b,eyeDisabled:x}}var _=r(),ie=l(`w-full rounded-lg border border-edge bg-surface-panel py-2 pl-3 pr-20 font-mono text-sm text-fg`,`placeholder:text-fg-subtle`,d,`dark:border-edge`);function v(e){let t=(0,re.c)(71),{id:n,name:r,ariaDescribedBy:i,ariaInvalid:ee,value:d,onChange:f,placeholder:te,disabled:p,readOnly:m,className:h,inputClassName:v,labels:y,reveal:b,allowUnrevealedCopy:x,loadFailedLabel:ae,maskedHelp:S,notInConfigFile:C,baselineValue:oe,autoComplete:se,onKeyDown:w,inputRef:T}=e,E=p!==void 0&&p,ce=m!==void 0&&m,le=se===void 0?`off`:se,D;t[0]!==x||t[1]!==oe||t[2]!==ae||t[3]!==b||t[4]!==d?(D={value:d,reveal:b,loadFailedLabel:ae,baselineValue:oe,allowUnrevealedCopy:x},t[0]=x,t[1]=oe,t[2]=ae,t[3]=b,t[4]=d,t[5]=D):D=t[5];let{masked:O,showKey:k,revealed:ue,revealLoading:A,revealErr:j,copied:M,inputValue:de,inputType:fe,readOnly:pe,copyEnabled:N,copySecret:P,toggleEye:F,onInputChange:I,eyeDisabled:me}=g(D),L=ce||pe,R;t[6]===h?R=t[7]:(R=l(`flex flex-col gap-1.5`,h),t[6]=h,t[7]=R);let z;t[8]!==O||t[9]!==S?(z=O&&S?(0,_.jsx)(`p`,{className:`text-xs text-fg-subtle`,children:S}):null,t[8]=O,t[9]=S,t[10]=z):z=t[10];let B=ee||void 0,he=O?void 0:te,V;t[11]!==f||t[12]!==I?(V=f?e=>I(e.target.value,f):void 0,t[11]=f,t[12]=I,t[13]=V):V=t[13];let H;t[14]===v?H=t[15]:(H=l(ie,v),t[14]=v,t[15]=H);let U;t[16]!==i||t[17]!==le||t[18]!==E||t[19]!==n||t[20]!==T||t[21]!==fe||t[22]!==de||t[23]!==r||t[24]!==w||t[25]!==L||t[26]!==H||t[27]!==B||t[28]!==he||t[29]!==V?(U=(0,_.jsx)(`input`,{ref:T,id:n,name:r,"aria-describedby":i,"aria-invalid":B,type:fe,autoComplete:le,spellCheck:!1,disabled:E,readOnly:L,value:de,placeholder:he,onChange:V,onKeyDown:w,className:H}),t[16]=i,t[17]=le,t[18]=E,t[19]=n,t[20]=T,t[21]=fe,t[22]=de,t[23]=r,t[24]=w,t[25]=L,t[26]=H,t[27]=B,t[28]=he,t[29]=V,t[30]=U):U=t[30];let W;t[31]!==M||t[32]!==N||t[33]!==P||t[34]!==E||t[35]!==y.copied||t[36]!==y.copy||t[37]!==A?(W=N?(0,_.jsx)(`button`,{type:`button`,className:l(`rounded p-1.5 text-fg-subtle hover:bg-surface-hover hover:text-fg`,u.transition,u.press,u.focusRingPanel),title:M?y.copied:y.copy,"aria-label":M?y.copied:y.copy,disabled:E||A,onClick:()=>void P(),children:M?(0,_.jsx)(a,{className:`size-3.5`}):(0,_.jsx)(o,{className:`size-3.5`})}):null,t[31]=M,t[32]=N,t[33]=P,t[34]=E,t[35]=y.copied,t[36]=y.copy,t[37]=A,t[38]=W):W=t[38];let G;t[39]===Symbol.for(`react.memo_cache_sentinel`)?(G=l(`rounded p-1.5 text-fg-subtle hover:bg-surface-hover hover:text-fg disabled:opacity-40`,u.transition,u.press,u.focusRingPanel),t[39]=G):G=t[39];let ge=k?y.hide:y.show,_e=k?y.hide:y.show,ve=E||me,K;t[40]===F?K=t[41]:(K=()=>void F(),t[40]=F,t[41]=K);let q;t[42]!==A||t[43]!==k?(q=A?(0,_.jsx)(c,{className:`size-3.5 animate-spin`,"aria-hidden":!0}):k?(0,_.jsx)(ne,{className:`size-3.5`,"aria-hidden":!0}):(0,_.jsx)(s,{className:`size-3.5`,"aria-hidden":!0}),t[42]=A,t[43]=k,t[44]=q):q=t[44];let J;t[45]!==ge||t[46]!==_e||t[47]!==ve||t[48]!==K||t[49]!==q?(J=(0,_.jsx)(`button`,{type:`button`,className:G,title:ge,"aria-label":_e,disabled:ve,onClick:K,children:q}),t[45]=ge,t[46]=_e,t[47]=ve,t[48]=K,t[49]=q,t[50]=J):J=t[50];let Y;t[51]!==W||t[52]!==J?(Y=(0,_.jsxs)(`div`,{className:`absolute right-1 top-1/2 flex -translate-y-1/2 gap-0.5`,children:[W,J]}),t[51]=W,t[52]=J,t[53]=Y):Y=t[53];let X;t[54]!==U||t[55]!==Y?(X=(0,_.jsxs)(`div`,{className:`relative min-w-0`,children:[U,Y]}),t[54]=U,t[55]=Y,t[56]=X):X=t[56];let Z;t[57]!==O||t[58]!==C||t[59]!==j||t[60]!==ue||t[61]!==k?(Z=O&&k&&ue===null&&!j&&C?(0,_.jsx)(`p`,{className:`text-xs text-amber-700 dark:text-amber-400/90`,children:C}):null,t[57]=O,t[58]=C,t[59]=j,t[60]=ue,t[61]=k,t[62]=Z):Z=t[62];let Q;t[63]===j?Q=t[64]:(Q=j?(0,_.jsx)(`p`,{className:`text-xs text-red-600 dark:text-red-400`,children:j}):null,t[63]=j,t[64]=Q);let $;return t[65]!==X||t[66]!==Z||t[67]!==Q||t[68]!==R||t[69]!==z?($=(0,_.jsxs)(`div`,{className:R,children:[z,X,Z,Q]}),t[65]=X,t[66]=Z,t[67]=Q,t[68]=R,t[69]=z,t[70]=$):$=t[70],$}export{ne as n,v as t};
@@ -0,0 +1 @@
1
+ var e={show:`Show`,hide:`Hide`,copy:`Copy`,copied:`Copied`};function t(e){return{show:e.show,hide:e.hide,copy:e.copy,copied:e.copied}}function n(e){return t(e)}function r(e){return{show:e.show,hide:e.hide,copy:`Copy`,copied:`Copied`}}export{r as i,t as n,n as r,e as t};
@@ -0,0 +1 @@
1
+ var e=`inline-flex items-center gap-px rounded-pill border border-edge bg-surface-hover p-1 dark:border-edge`,t=`touch-target inline-flex shrink-0 items-center justify-center rounded-pill text-xs font-medium leading-none transition-[color,background-color,box-shadow] duration-150 ease-out text-fg-subtle focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent focus-visible:ring-offset-2 focus-visible:ring-offset-surface-panel active:scale-100`,n=`bg-surface-panel shadow-sm dark:bg-surface-panel dark:shadow-sm dark:ring-1 dark:ring-edge-strong/40`;export{t as n,e as r,n as t};
@@ -0,0 +1 @@
1
+ import{t as e}from"./createLucideIcon-DPHK1VkS.js";var t=e(`circle-dot`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`circle`,{cx:`12`,cy:`12`,r:`1`,key:`41hilf`}]]),n=e(`send`,[[`path`,{d:`M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z`,key:`1ffxy3`}],[`path`,{d:`m21.854 2.147-10.94 10.939`,key:`12cjpa`}]]);export{t as n,n as t};
@@ -0,0 +1 @@
1
+ import{t as e}from"./createLucideIcon-DPHK1VkS.js";var t=e(`server`,[[`rect`,{width:`20`,height:`8`,x:`2`,y:`2`,rx:`2`,ry:`2`,key:`ngkwjq`}],[`rect`,{width:`20`,height:`8`,x:`2`,y:`14`,rx:`2`,ry:`2`,key:`iecqi9`}],[`line`,{x1:`6`,x2:`6.01`,y1:`6`,y2:`6`,key:`16zg32`}],[`line`,{x1:`6`,x2:`6.01`,y1:`18`,y2:`18`,key:`nzw8ys`}]]);export{t};
@@ -0,0 +1 @@
1
+ import{i as e}from"./rolldown-runtime-aKtaBQYM.js";import{a as t,t as n}from"./vendor-react-BOUWij0V.js";import{u as r}from"./chunk-KS7C4IRE-CiwuuyV8.js";import{t as i}from"./createLucideIcon-DPHK1VkS.js";import{t as a}from"./chevron-down-ccbiQQz_.js";import{i as o}from"./working-directory-picker-modal-DHl2cZY1.js";import{t as s}from"./loader-circle-CifKLtgG.js";import{s as c,t as ee}from"./install-connector-dialog-DU1Tz7B3.js";import{t as l}from"./package-wATCyihJ.js";import{t as u}from"./plus-Q2yW6OE7.js";import{t as d}from"./messages-DRR9N3HC.js";import{t as f}from"./cn-0WouolD0.js";import{i as p,n as m,o as h}from"./locale-store-lIXD1FMw.js";import{i as g}from"./vendor-swr-CdRzEUwF.js";import{t as te}from"./button-CnRSIP6m.js";import{t as _}from"./skeleton-BI5TyibZ.js";import{a as v,i as y,o as b,s as x}from"./connectors-api-DIBG72k4.js";import{t as S}from"./agent-plugin-dialog-CQ5LLDMO.js";import{t as C}from"./capability-icon-DVoZxEgW.js";import{t as w}from"./extension-marketplace-api-CVJPqJOB.js";var T=i(`cable`,[[`path`,{d:`M17 19a1 1 0 0 1-1-1v-2a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2a1 1 0 0 1-1 1z`,key:`trhst0`}],[`path`,{d:`M17 21v-2`,key:`ds4u3f`}],[`path`,{d:`M19 14V6.5a1 1 0 0 0-7 0v11a1 1 0 0 1-7 0V10`,key:`1mo9zo`}],[`path`,{d:`M21 21v-2`,key:`eo0ou`}],[`path`,{d:`M3 5V3`,key:`1k5hjh`}],[`path`,{d:`M4 10a2 2 0 0 1-2-2V6a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2a2 2 0 0 1-2 2z`,key:`1dd30t`}],[`path`,{d:`M7 5V3`,key:`1t1388`}]]),E=e(t(),1),D={"notion-office":`notion`,"todoist-mcp":`todoist`,"amap-maps":`amap`,"feishu-workspace":`feishu`,"wecom-workspace":`wecom`,"dingtalk-workspace":`dingtalk`,"wps365-workspace":`wps365`},O=[`feishu`,`wecom`,`dingtalk`,`tencent-docs`,`wps365`,`yuque`,`dida365`,`flomo`,`tencent-meeting`,`amap`,`bailian-web-search`,`railway-12306`,`antv-chart`],k={"store-plugin":0,"builtin-connector":1,"store-connector":2,"registry-connector":3};function A(e){let t=e.toLowerCase().replace(/^composio-/,``);return D[t]??t}function j(e){if(!e)return 2**53-1;let t=O.indexOf(A(e.id));return t>=0?t:e.regions?.includes(`china`)?O.length:2**53-1}function M(e,t){let n=new Map;for(let t of e){if(!t.service)continue;let e=A(t.service.id),r=n.get(e);(!r?.service||k[t.service.source]<k[r.service.source])&&n.set(e,t)}let r=e.filter(e=>!e.service||n.get(A(e.service.id))===e);return t.startsWith(`zh`)?r.toSorted((e,t)=>j(e.service)-j(t.service)):r}function N(e,t){let n=t.trim().toLocaleLowerCase();return!n||[e.name,e.description,e.source,...e.tags].some(e=>e.toLocaleLowerCase().includes(n))}function P(e){return e?[`failed`,`unauthorized`,`degraded`,`not_configured`].includes(e.status)?`attention`:`installed`:`available`}function F(e,t,n,r=`en`){return M(e,r).filter(e=>(t===`all`||e.kind===t)&&N(e,n))}function I(e,t,n,r=`en`){let i=new Map(n.map(e=>[e.connectorId,e])),a=new Map;for(let t of e){let e=i.get(t.id);a.set(t.id,{id:t.id,service:{id:t.id,source:t.source===`builtin`?`builtin-connector`:t.source===`store`?`store-connector`:`registry-connector`},kind:`connector`,name:t.displayName,description:t.description,source:t.source,status:P(e),tags:[t.category,t.kind,...t.tags??[]],href:`/capabilities/connectors?tab=${e?`connected`:`discover`}&${e?`instance`:`connector`}=${encodeURIComponent(e?.instanceId??t.id)}`,iconUrl:t.branding?.logoUrl})}for(let e of t){let t=e.name,n=e.localizations?.[r.startsWith(`zh`)?`zh-CN`:`en`],o=i.get(t);a.set(`store:${t}`,{id:t,service:{id:t,source:`store-connector`,regions:e.regions},kind:`connector`,name:n?.displayName??e.name,description:n?.description??e.description,source:e.author.username||`XOPC Store`,status:P(o),tags:[e.name,e.category,...e.tags??[]].filter(e=>!!e),href:o?`/capabilities/connectors?tab=connected&instance=${encodeURIComponent(o.instanceId)}`:`/capabilities/connectors?tab=discover&storeConnector=${encodeURIComponent(t)}`,iconUrl:e.branding?.iconUrl})}return M([...a.values()],r)}function L(e,t,n=`en`){return e.map(e=>({id:e.id,kind:`extension`,...e.packageType===`plugin`?{service:{id:e.id,source:`store-plugin`}}:{},name:e.localizations?.[n.startsWith(`zh`)?`zh-CN`:`en`]?.displayName??e.name,description:e.localizations?.[n.startsWith(`zh`)?`zh-CN`:`en`]?.description??e.description??``,source:e.author||e.npmPackage,status:t.has(e.id)?`installed`:`available`,tags:[e.id,...e.categories??[],...e.tags??[]],href:`/capabilities/extensions?tab=marketplace&q=${encodeURIComponent(e.name)}`,iconUrl:e.branding?.iconUrl}))}async function R(e=``){let t=await b({q:e,page:1,pageSize:50,sort:`downloads`}),n=await Promise.all(Array.from({length:Math.max(0,t.meta.totalPages-1)},(t,n)=>b({q:e,page:n+2,pageSize:50,sort:`downloads`})));return[...t.items,...n.flatMap(e=>e.items)]}async function z(e){let[t,n,r]=await Promise.allSettled([w(),y(),R()]),i=[t,n,r].filter(e=>e.status===`rejected`).length;if(i===3)throw Error(`Service recommendations unavailable`);let a=n.status===`fulfilled`?n.value:[];return{items:M([...L(t.status===`fulfilled`?t.value.filter(e=>e.packageType===`plugin`):[],new Set,e),...I(a,r.status===`fulfilled`?r.value:[],[],e)],e),definitions:a,failedSources:i}}var B=n();function V({initialCount:e=3,query:t=``,layout:n=`list`,onChanged:i}){let y=r(),b=m(e=>e.language),w=b.startsWith(`zh`),D=d(b).onboarding.workDiscovery,O=d(b).connectorsSettings,{data:k,error:A,isLoading:j,mutate:M}=g([`service-recommendations`,b],()=>z(b),{revalidateOnFocus:!1}),{data:N,error:P,mutate:I}=g(`recommended-connector-instances`,v),{data:L,error:R,mutate:V}=g(`gateway-extensions-list`,()=>h(p(`/api/extensions`))),[H,U]=(0,E.useState)(!1),[W,G]=(0,E.useState)(null),[K,q]=(0,E.useState)(null),[J,Y]=(0,E.useState)(null),[X,Z]=(0,E.useState)(``),Q=F(k?.items??[],`all`,t,b);async function $(){let e=(await Promise.allSettled([I(),V(),Promise.resolve().then(()=>i?.())])).find(e=>e.status===`rejected`);e?.status===`rejected`&&Z(String(e.reason))}async function ne(e,t){if(Z(``),e.service?.source===`store-plugin`){q({id:e.id,extension:t});return}let n=N?.find(t=>t.connectorId===e.id);if(n){y(`/capabilities/connectors?tab=connected&instance=${encodeURIComponent(n.instanceId)}`);return}Y(e.id);try{if(e.service?.source===`store-connector`){let t=await x(e.id);G(c(t.definition,{packageName:t.packageName,version:t.version,reviewHash:t.reviewHash,permissions:t.permissions}))}else{let t=k?.definitions.find(t=>t.id===e.id);t&&G(c(t))}}catch(e){Z(e instanceof Error?e.message:String(e))}finally{Y(null)}}return(0,B.jsxs)(`div`,{children:[j?(0,B.jsx)(`div`,{className:n===`cards`?`grid gap-4 sm:grid-cols-2 xl:grid-cols-3`:`space-y-2`,"aria-busy":`true`,children:Array.from({length:e},(e,t)=>(0,B.jsx)(_,{className:n===`cards`?`h-[8.75rem] rounded-xl`:`h-20 rounded-xl`},t))}):null,A||k?.failedSources||P||R?(0,B.jsxs)(`p`,{className:`mb-3 text-sm text-fg-muted`,role:`status`,children:[D.connectorLoadFailed,` `,(0,B.jsx)(`button`,{type:`button`,className:`text-accent-fg hover:underline`,onClick:()=>{M(),I(),V()},children:w?`重试`:`Retry`})]}):null,!j&&!A&&Q.length===0?(0,B.jsx)(`p`,{className:`py-6 text-center text-sm text-fg-muted`,children:D.noWorkServices}):null,(0,B.jsx)(`div`,{className:n===`cards`?`grid gap-4 sm:grid-cols-2 xl:grid-cols-3`:`divide-y divide-edge-subtle rounded-xl border border-edge-subtle bg-surface-base/55`,children:(H?Q:Q.slice(0,e)).map(e=>{let t=L?.extensions.find(t=>t.format===`agent-plugin`&&t.provenance?.packageName===e.id),r=N?.find(t=>t.connectorId===e.id),i=e.service?.source===`store-plugin`,a=i?!!(t?.active&&t.readiness===`ready`&&[`connected`,`not_required`].includes(t.authorizationStatus??``)):!!(r?.enabled&&r.status===`connected`),o=i?!!t:!!r,c=(i?!L&&!R:!N&&!P)?(0,B.jsx)(_,{className:`h-8 w-16 shrink-0 rounded-lg`}):(0,B.jsxs)(te,{type:`button`,variant:`secondary`,className:`h-8 shrink-0 px-3 text-xs`,disabled:J!==null,onClick:()=>void ne(e,t),children:[J===e.id?(0,B.jsx)(s,{className:`size-3.5 animate-spin`}):o?null:(0,B.jsx)(u,{className:`size-3.5`}),a?w?`管理`:`Manage`:o?w?`继续设置`:`Set up`:O.connect]});return(0,B.jsx)(`article`,{className:f(n===`cards`?`group flex min-h-[8.75rem] min-w-0 flex-col rounded-xl border border-edge bg-surface-panel p-4 transition-colors hover:bg-surface-hover/45 focus-within:ring-2 focus-within:ring-accent/30`:`flex min-h-20 items-center gap-3 px-3 py-3 sm:px-4`),children:n===`cards`?(0,B.jsxs)(B.Fragment,{children:[(0,B.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,B.jsxs)(`div`,{className:`flex min-w-0 items-start gap-3`,children:[(0,B.jsx)(C,{iconUrl:e.iconUrl,fallback:i?l:T}),(0,B.jsx)(`h3`,{className:`min-w-0 truncate text-sm font-semibold text-fg`,children:e.name})]}),c]}),(0,B.jsx)(`p`,{className:`mt-3 line-clamp-2 text-sm leading-6 text-fg-muted`,title:e.description,children:e.description})]}):(0,B.jsxs)(B.Fragment,{children:[(0,B.jsx)(C,{iconUrl:e.iconUrl,fallback:i?l:T}),(0,B.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,B.jsx)(`h3`,{className:`truncate text-sm font-semibold text-fg`,children:e.name}),(0,B.jsx)(`p`,{className:`mt-1 line-clamp-2 text-xs text-fg-muted`,children:e.description})]}),c]})},`${e.kind}:${e.id}`)})}),Q.length>e?(0,B.jsxs)(`button`,{type:`button`,className:`mx-auto mt-3 flex items-center gap-1.5 px-3 py-1.5 text-xs font-medium text-accent-fg hover:underline`,onClick:()=>U(e=>!e),children:[H?(0,B.jsx)(o,{className:`size-3.5`}):(0,B.jsx)(a,{className:`size-3.5`}),H?D.showFewerServices:D.showMoreServices]}):null,X?(0,B.jsx)(`p`,{className:`mt-3 text-xs text-danger`,role:`alert`,children:X}):null,W?(0,B.jsx)(ee,{draft:W,onChange:G,onClose:()=>G(null),t:O,onInstalled:async()=>{await $(),G(null)}}):null,K?(0,B.jsx)(S,{initialSource:`store:${K.id}`,extension:K.extension,onClose:()=>{q(null),$()}}):null]})}export{T as a,M as i,z as n,A as r,V as t};
@@ -1 +1 @@
1
- import{i as e,o as t}from"./locale-store-B7s2Hb35.js";import{d as n,g as r,h as i,i as a,l as o,p as s,r as c,s as l,t as u,u as d,v as f}from"./schemas-CObaziC7.js";import{t as p}from"./gateway-startup-retry-Cfwxof4k.js";f().transform(e=>e.toLowerCase()).brand();var m=s().trim().regex(/^[a-z0-9][a-z0-9._-]{0,127}$/i).brand(),h=u([`active`,`idle`,`archived`,`pinned`]),g=d({agentId:s().optional(),source:s().optional(),accountId:s().optional(),peerKind:s().optional(),peerId:s().optional(),threadId:s().optional(),scopeId:s().optional()}).passthrough();d({agentId:s().optional(),projectId:s().optional(),key:s(),transcriptId:m.optional(),name:s().optional(),title:s().optional(),displayName:s().optional(),messageCount:o(),updatedAt:s(),sourceChannel:s().optional(),status:h.optional(),usage:d({calls:o().int().nonnegative(),unknownCostCalls:o().int().nonnegative(),totalTokens:o().int().nonnegative(),knownCostUsd:s(),costCompleteness:u([`complete`,`partial`,`unknown`])}).optional(),routing:g.optional()}).passthrough();var _=d({items:c(r()),total:o(),limit:o(),offset:o(),hasMore:a()}),v=d({role:s(),content:r(),timestamp:i([s(),o()]).optional()}).passthrough(),y=d({key:s(),messages:c(v)}).passthrough(),b=d({session:y}),x=d({session:d({key:s(),transcriptId:m.optional(),messages:c(v),name:s().optional(),status:h.optional(),sourceChannel:s().optional(),sourceChatId:s().optional(),projectId:s().optional(),customData:n(s(),r()).optional(),routing:g.optional()}).passthrough(),pagination:d({total:o(),limit:o(),offset:o(),hasMore:a(),before:s().optional(),nextBeforeCursor:s().optional(),revision:o().int().nonnegative().optional()}).passthrough()}).passthrough(),ee=d({ok:l(!0),conversationId:f(),rowCount:o().int().nonnegative(),lastTurnId:s().min(1),session:y}).passthrough(),S=d({ok:a().optional(),payload:d({active:a(),runId:s().optional()}).passthrough().optional()}).passthrough(),C=d({ok:a().optional(),error:s().optional()}).passthrough(),w=C.extend({renamed:a().optional()}),T=C.extend({reset:a().optional(),transcriptId:m.optional(),previousTranscriptId:s().optional(),session:r().optional()}),E=d({totalSessions:o(),activeSessions:o(),archivedSessions:o(),pinnedSessions:o(),totalMessages:o(),totalTokens:o(),oldestSession:s().optional(),newestSession:s().optional(),byChannel:n(s(),o())}).passthrough();d({ok:a(),payload:d({conversationId:f(),transcriptId:m,session:r()}).passthrough().optional(),error:s().optional()}).passthrough();var D=d({ok:l(!0),projects:d({items:c(d({project:r(),sessions:c(r()),sessionTotal:o(),sessionHasMore:a()}).passthrough()),total:o(),limit:o(),offset:o(),hasMore:a()}),inbox:_,pinned:c(r()).default([]),layouts:n(s(),d({itemIds:c(s()),revision:o().int().nonnegative()})).default({}),childrenByConversationId:n(s(),d({total:o(),activeCount:o(),items:c(d({taskId:s(),title:s(),phase:s(),runStatus:s().optional(),activeConversationId:s().optional()}))})).default({})}).passthrough();function O(e){return b.parse(e)}function k(e){return x.parse(e)}function A(e){return ee.parse(e)}function j(e){return S.parse(e)}function M(e){return C.parse(e)}function N(e){return w.parse(e)}function P(e){return T.parse(e)}function F(e){return E.parse(e)}function I(e){return D.parse(e)}function L(e){let t=j(e).payload,n=typeof t?.runId==`string`?t.runId.trim():``;return!t?.active||!n?{active:!1}:{active:!0,runId:n}}function R(e){let t=new URLSearchParams;if(!e)return``;e.status&&t.set(`status`,e.status),e.search&&t.set(`search`,e.search),e.channel&&t.set(`channel`,e.channel),e.sources?.length&&t.set(`sources`,e.sources.join(`,`)),e.purposes?.length&&t.set(`purposes`,e.purposes.join(`,`)),e.activity&&t.set(`activity`,e.activity),e.agentId&&t.set(`agentId`,e.agentId),e.excludeArchived&&t.set(`excludeArchived`,`true`),e.projectId&&t.set(`projectId`,e.projectId),e.unassigned&&t.set(`unassigned`,`true`),e.updatedAfter!=null&&t.set(`updatedAfter`,String(e.updatedAfter)),e.includePinned&&t.set(`includePinned`,`true`),e.includeConversationId&&t.set(`includeConversationId`,e.includeConversationId),e.rootConversationsOnly&&t.set(`rootConversationsOnly`,`true`),e.sessionTypes?.length&&t.set(`types`,e.sessionTypes.join(`,`)),e.sortBy&&t.set(`sortBy`,e.sortBy),e.sortOrder&&t.set(`sortOrder`,e.sortOrder),e.limit!=null&&t.set(`limit`,String(e.limit)),e.offset!=null&&t.set(`offset`,String(e.offset));let n=t.toString();return n?`?${n}`:``}function z(e,t){let n=[];t?.includeTranscript&&n.push(`transcript`),t?.includeTranscriptRows&&n.push(`transcriptRows`);let r=n.length?`?include=${n.join(`,`)}`:``;return`/api/sessions/${encodeURIComponent(e)}${r}`}function B(e){return`/api/sessions/${encodeURIComponent(e)}/fork-at-turn`}function V(e,t){let n=new URLSearchParams;n.set(`limit`,String(t?.limit??50));let r=t?.before?.trim();return r?n.set(`before`,r):t?.offset!=null&&n.set(`offset`,String(t.offset)),`/api/sessions/${encodeURIComponent(e)}/history?${n.toString()}`}function te(e){return`/api/sessions/${encodeURIComponent(e)}/run`}function H(){return`/api/sessions/stats`}function U(e){let t=new URLSearchParams;e?.projectLimit!=null&&t.set(`projectLimit`,String(e.projectLimit)),e?.projectOffset!=null&&t.set(`projectOffset`,String(e.projectOffset)),e?.sessionPreviewLimit!=null&&t.set(`sessionPreviewLimit`,String(e.sessionPreviewLimit)),e?.inboxLimit!=null&&t.set(`inboxLimit`,String(e.inboxLimit)),e?.inboxOffset!=null&&t.set(`inboxOffset`,String(e.inboxOffset)),e?.staleDays!=null&&t.set(`staleDays`,String(e.staleDays)),e?.includeConversationId&&t.set(`includeConversationId`,e.includeConversationId);let n=t.toString();return`/api/sidebar/chat-list${n?`?${n}`:``}`}function W(e){return`/api/sidebar/layouts/${encodeURIComponent(e)}`}function G(e,t){let n=encodeURIComponent(e);return t===`delete`?`/api/sessions/${n}`:`/api/sessions/${n}/${t}`}function K(e){return e?JSON.stringify({status:e.status,search:e.search,channel:e.channel,sources:e.sources,purposes:e.purposes,activity:e.activity,agentId:e.agentId,excludeArchived:e.excludeArchived,projectId:e.projectId,unassigned:e.unassigned,updatedAfter:e.updatedAfter,includePinned:e.includePinned,includeConversationId:e.includeConversationId,sessionTypes:e.sessionTypes,sortBy:e.sortBy,sortOrder:e.sortOrder,limit:e.limit,offset:e.offset}):`default`}var q=new Map;async function J(t){let n=K(t),r=q.get(n);if(r)return r;let i=e(`/api/sessions${R(t)}`),a=(async()=>{let e=await p(i);if(!e.ok){let t=await e.json().catch(()=>({})),n=typeof t.error==`string`?t.error:t.error?.message;throw Error(n??`HTTP ${e.status}`)}return await e.json()})().finally(()=>{q.delete(n)});return q.set(n,a),a}async function Y(n){return I(await t(e(U(n))))}async function X(n){let r=await t(e(W(n.containerId)),{method:`PUT`,body:JSON.stringify({itemIds:n.itemIds,expectedRevision:n.expectedRevision})});if(!r.ok||!r.layout)throw Error(r.error??`Failed to save sidebar order`);return r.layout}async function Z(){return F(await t(e(H())))}async function Q(n,r){let i=O(await t(e(z(n,r))));if(!i.session)throw Error(`Session not found`);return i.session}async function ne(n){let r=await t(e(`/api/sessions/resolve`),{method:`POST`,body:JSON.stringify(n)});if(!r.ok||!r.payload)throw Error(r.error??`Session not found`);return r.payload}async function $(n){M(await t(e(G(n,`delete`)),{method:`DELETE`}))}async function re(n,r){return{renamed:N(await t(e(G(n,`rename`)),{method:`POST`,body:JSON.stringify({name:r})})).renamed===!0}}async function ie(n){M(await t(e(G(n,`archive`)),{method:`POST`}))}async function ae(n){M(await t(e(G(n,`unarchive`)),{method:`POST`}))}async function oe(n){M(await t(e(G(n,`pin`)),{method:`POST`}))}async function se(n){M(await t(e(G(n,`unpin`)),{method:`POST`}))}async function ce(n){return(await t(e(`/api/sessions/${encodeURIComponent(n)}/export?format=json`))).content}export{L as _,Q as a,P as b,oe as c,X as d,ae as f,te as g,V as h,Y as i,re as l,B as m,$ as n,Z as o,se as p,ce as r,J as s,ie as t,ne as u,A as v,k as y};
1
+ import{i as e,o as t}from"./locale-store-lIXD1FMw.js";import{_ as n,a as r,c as i,d as a,f as o,g as s,i as c,m as l,n as u,u as d,y as f}from"./schemas-CCWMleym.js";import{t as p}from"./gateway-startup-retry-CtUB3g6N.js";f().transform(e=>e.toLowerCase()).brand();var m=l().trim().regex(/^[a-z0-9][a-z0-9._-]{0,127}$/i).brand(),h=u([`active`,`idle`,`archived`,`pinned`]),g=a({agentId:l().optional(),source:l().optional(),accountId:l().optional(),peerKind:l().optional(),peerId:l().optional(),threadId:l().optional(),scopeId:l().optional()}).passthrough();a({agentId:l().optional(),projectId:l().optional(),key:l(),transcriptId:m.optional(),name:l().optional(),title:l().optional(),displayName:l().optional(),messageCount:d(),updatedAt:l(),sourceChannel:l().optional(),status:h.optional(),usage:a({calls:d().int().nonnegative(),unknownCostCalls:d().int().nonnegative(),totalTokens:d().int().nonnegative(),knownCostUsd:l(),costCompleteness:u([`complete`,`partial`,`unknown`])}).optional(),routing:g.optional()}).passthrough();var _=a({items:c(n()),total:d(),limit:d(),offset:d(),hasMore:r()}),v=a({role:l(),content:n(),timestamp:s([l(),d()]).optional()}).passthrough(),y=a({key:l(),messages:c(v)}).passthrough(),b=a({session:y}),ee=a({session:a({key:l(),transcriptId:m.optional(),messages:c(v),name:l().optional(),status:h.optional(),sourceChannel:l().optional(),sourceChatId:l().optional(),projectId:l().optional(),customData:o(l(),n()).optional(),routing:g.optional()}).passthrough(),pagination:a({total:d(),limit:d(),offset:d(),hasMore:r(),before:l().optional(),nextBeforeCursor:l().optional(),revision:d().int().nonnegative().optional()}).passthrough()}).passthrough(),x=a({ok:i(!0),conversationId:f(),rowCount:d().int().nonnegative(),lastTurnId:l().min(1),session:y}).passthrough(),S=a({ok:r().optional(),payload:a({active:r(),runId:l().optional()}).passthrough().optional()}).passthrough(),C=a({ok:r().optional(),error:l().optional()}).passthrough(),w=C.extend({renamed:r().optional()}),T=C.extend({reset:r().optional(),transcriptId:m.optional(),previousTranscriptId:l().optional(),session:n().optional()}),E=a({totalSessions:d(),activeSessions:d(),archivedSessions:d(),pinnedSessions:d(),totalMessages:d(),totalTokens:d(),oldestSession:l().optional(),newestSession:l().optional(),byChannel:o(l(),d())}).passthrough();a({ok:r(),payload:a({conversationId:f(),transcriptId:m,session:n()}).passthrough().optional(),error:l().optional()}).passthrough();var D=a({ok:i(!0),projects:a({items:c(a({project:n(),sessions:c(n()),sessionTotal:d(),sessionHasMore:r()}).passthrough()),total:d(),limit:d(),offset:d(),hasMore:r()}),inbox:_,pinned:c(n()).default([]),layouts:o(l(),a({itemIds:c(l()),revision:d().int().nonnegative()})).default({}),childrenByConversationId:o(l(),a({total:d(),activeCount:d(),items:c(a({taskId:l(),title:l(),phase:l(),runStatus:l().optional(),activeConversationId:l().optional()}))})).default({})}).passthrough();function O(e){return b.parse(e)}function k(e){return ee.parse(e)}function A(e){return x.parse(e)}function j(e){return S.parse(e)}function M(e){return C.parse(e)}function N(e){return w.parse(e)}function P(e){return T.parse(e)}function F(e){return E.parse(e)}function I(e){return D.parse(e)}function L(e){let t=j(e).payload,n=typeof t?.runId==`string`?t.runId.trim():``;return!t?.active||!n?{active:!1}:{active:!0,runId:n}}function R(e){let t=new URLSearchParams;if(!e)return``;e.status&&t.set(`status`,e.status),e.search&&t.set(`search`,e.search),e.channel&&t.set(`channel`,e.channel),e.sources?.length&&t.set(`sources`,e.sources.join(`,`)),e.purposes?.length&&t.set(`purposes`,e.purposes.join(`,`)),e.activity&&t.set(`activity`,e.activity),e.agentId&&t.set(`agentId`,e.agentId),e.excludeArchived&&t.set(`excludeArchived`,`true`),e.projectId&&t.set(`projectId`,e.projectId),e.unassigned&&t.set(`unassigned`,`true`),e.updatedAfter!=null&&t.set(`updatedAfter`,String(e.updatedAfter)),e.includePinned&&t.set(`includePinned`,`true`),e.includeConversationId&&t.set(`includeConversationId`,e.includeConversationId),e.rootConversationsOnly&&t.set(`rootConversationsOnly`,`true`),e.sessionTypes?.length&&t.set(`types`,e.sessionTypes.join(`,`)),e.sortBy&&t.set(`sortBy`,e.sortBy),e.sortOrder&&t.set(`sortOrder`,e.sortOrder),e.limit!=null&&t.set(`limit`,String(e.limit)),e.offset!=null&&t.set(`offset`,String(e.offset));let n=t.toString();return n?`?${n}`:``}function z(e,t){let n=[];t?.includeTranscript&&n.push(`transcript`),t?.includeTranscriptRows&&n.push(`transcriptRows`);let r=n.length?`?include=${n.join(`,`)}`:``;return`/api/sessions/${encodeURIComponent(e)}${r}`}function B(e){return`/api/sessions/${encodeURIComponent(e)}/fork-at-turn`}function te(e,t){let n=new URLSearchParams;n.set(`limit`,String(t?.limit??50));let r=t?.before?.trim();return r?n.set(`before`,r):t?.offset!=null&&n.set(`offset`,String(t.offset)),`/api/sessions/${encodeURIComponent(e)}/history?${n.toString()}`}function V(e){return`/api/sessions/${encodeURIComponent(e)}/run`}function H(){return`/api/sessions/stats`}function U(e){let t=new URLSearchParams;e?.projectLimit!=null&&t.set(`projectLimit`,String(e.projectLimit)),e?.projectOffset!=null&&t.set(`projectOffset`,String(e.projectOffset)),e?.sessionPreviewLimit!=null&&t.set(`sessionPreviewLimit`,String(e.sessionPreviewLimit)),e?.inboxLimit!=null&&t.set(`inboxLimit`,String(e.inboxLimit)),e?.inboxOffset!=null&&t.set(`inboxOffset`,String(e.inboxOffset)),e?.staleDays!=null&&t.set(`staleDays`,String(e.staleDays)),e?.includeConversationId&&t.set(`includeConversationId`,e.includeConversationId);let n=t.toString();return`/api/sidebar/chat-list${n?`?${n}`:``}`}function W(e){return`/api/sidebar/layouts/${encodeURIComponent(e)}`}function G(e,t){let n=encodeURIComponent(e);return t===`delete`?`/api/sessions/${n}`:`/api/sessions/${n}/${t}`}function K(e){return e?JSON.stringify({status:e.status,search:e.search,channel:e.channel,sources:e.sources,purposes:e.purposes,activity:e.activity,agentId:e.agentId,excludeArchived:e.excludeArchived,projectId:e.projectId,unassigned:e.unassigned,updatedAfter:e.updatedAfter,includePinned:e.includePinned,includeConversationId:e.includeConversationId,sessionTypes:e.sessionTypes,sortBy:e.sortBy,sortOrder:e.sortOrder,limit:e.limit,offset:e.offset}):`default`}var q=new Map;async function J(t){let n=K(t),r=q.get(n);if(r)return r;let i=e(`/api/sessions${R(t)}`),a=(async()=>{let e=await p(i);if(!e.ok){let t=await e.json().catch(()=>({})),n=typeof t.error==`string`?t.error:t.error?.message;throw Error(n??`HTTP ${e.status}`)}return await e.json()})().finally(()=>{q.delete(n)});return q.set(n,a),a}async function Y(n){return I(await t(e(U(n))))}async function X(n){let r=await t(e(W(n.containerId)),{method:`PUT`,body:JSON.stringify({itemIds:n.itemIds,expectedRevision:n.expectedRevision})});if(!r.ok||!r.layout)throw Error(r.error??`Failed to save sidebar order`);return r.layout}async function Z(){return F(await t(e(H())))}async function Q(n,r){let i=O(await t(e(z(n,r))));if(!i.session)throw Error(`Session not found`);return i.session}async function ne(n){let r=await t(e(`/api/sessions/resolve`),{method:`POST`,body:JSON.stringify(n)});if(!r.ok||!r.payload)throw Error(r.error??`Session not found`);return r.payload}async function $(n){M(await t(e(G(n,`delete`)),{method:`DELETE`}))}async function re(n,r){return{renamed:N(await t(e(G(n,`rename`)),{method:`POST`,body:JSON.stringify({name:r})})).renamed===!0}}async function ie(n){M(await t(e(G(n,`archive`)),{method:`POST`}))}async function ae(n){M(await t(e(G(n,`unarchive`)),{method:`POST`}))}async function oe(n){M(await t(e(G(n,`pin`)),{method:`POST`}))}async function se(n){M(await t(e(G(n,`unpin`)),{method:`POST`}))}async function ce(n){return(await t(e(`/api/sessions/${encodeURIComponent(n)}/export?format=json`))).content}export{L as _,Q as a,P as b,oe as c,X as d,ae as f,V as g,te as h,Y as i,re as l,B as m,$ as n,Z as o,se as p,ce as r,J as s,ie as t,ne as u,A as v,k as y};
@@ -0,0 +1 @@
1
+ import{n as e,t}from"./vendor-react-BOUWij0V.js";import{t as n}from"./createLucideIcon-DPHK1VkS.js";import{t as r}from"./clock-3-DnrAnuyZ.js";import{t as i}from"./git-branch-Dh9uxTot.js";import{t as a}from"./message-circle-Badhj-4D.js";import{t as o}from"./message-square-fVE7Ghj1.js";import{t as s}from"./plug-DKYPEgkR.js";import{t as c}from"./settings-2-D-csvaET.js";import{t as l}from"./terminal-oKqqZdiG.js";import{t as u}from"./cn-0WouolD0.js";import{a as d,d as f,i as p,m,n as h}from"./schemas-CCWMleym.js";var g=n(`panels-top-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M3 9h18`,key:`1pudct`}],[`path`,{d:`M9 21V9`,key:`1oto5p`}]]),_={workbench:[`webchat`,`web`,`ui`,`webui`,`gateway`],browser:[`browser_extension`],terminal:[`cli`,`tui`],telegram:[`telegram`],wechat:[`wechat`,`weixin`],feishu:[`feishu`,`lark`],api:[`api`,`mcp`],automation:[`automation`,`cron`],system:[`heartbeat`,`system`]},v=[...Object.keys(_),`other`],y=[`chat`,`automation`,`subagent`,`system`],b=f({sources:p(h(v)).max(v.length).optional(),purposes:p(h(y)).max(y.length).optional(),activity:h([`manual`,`automatic`]).optional(),agentId:m().trim().min(1).max(128).optional(),excludeArchived:d().optional()});function x(e){let t=e.sourceChannel.trim().toLowerCase(),n=e.customData??{},r=`other`;for(let[e,n]of Object.entries(_))n.includes(t)&&(r=e);n.createdSurface===`browser_extension`&&(r=`browser`),(n.origin===`automation`||n.triggerSource===`automation`||e.sessionType===`cron`)&&(r=`automation`),e.sessionType===`heartbeat`&&(r=`system`);let i=r===`system`?`system`:e.sessionType===`subagent`?`subagent`:r===`automation`?`automation`:`chat`;return{source:r,purpose:i,automatic:r===`automation`||r===`system`}}var S=e(),C=t(),w={feishu:`/channel-icons/feishu.svg`,lark:`/channel-icons/lark.svg`,telegram:`/channel-icons/telegram.svg`,wechat:`/channel-icons/wechat.svg`,weixin:`/channel-icons/weixin.svg`};function T(e){let t=(0,S.c)(16),{sourceChannel:n,className:d,session:f}=e,p=x(f??{sourceChannel:n}),m;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(m={automation:r,subagent:i,system:c},t[0]=m):m=t[0];let h=m,_=p.purpose===`chat`?void 0:h[p.purpose];if(_){let e;t[1]===d?e=t[2]:(e=u(`shrink-0`,d),t[1]=d,t[2]=e);let n;return t[3]!==_||t[4]!==e?(n=(0,C.jsx)(_,{className:e,strokeWidth:1.75,"aria-hidden":!0}),t[3]=_,t[4]=e,t[5]=n):n=t[5],n}let v=w[n.trim().toLowerCase()];if(v&&[`telegram`,`wechat`,`feishu`].includes(p.source)){let e;t[6]===d?e=t[7]:(e=u(`shrink-0`,d),t[6]=d,t[7]=e);let n;return t[8]!==v||t[9]!==e?(n=(0,C.jsx)(`img`,{src:v,alt:``,draggable:!1,className:e,"aria-hidden":!0}),t[8]=v,t[9]=e,t[10]=n):n=t[10],n}let y=p.source===`workbench`?o:p.source===`browser`?g:p.source===`terminal`?l:p.source===`api`?s:a,b;t[11]===d?b=t[12]:(b=u(`shrink-0`,d),t[11]=d,t[12]=b);let T;return t[13]!==y||t[14]!==b?(T=(0,C.jsx)(y,{className:b,strokeWidth:1.75,"aria-hidden":!0}),t[13]=y,t[14]=b,t[15]=T):T=t[15],T}export{x as a,b as i,y as n,g as o,v as r,T as t};
@@ -0,0 +1 @@
1
+ import{t as e}from"./createLucideIcon-DPHK1VkS.js";import{a as t}from"./session-channel-icon-SsY70Z6t.js";var n=e(`archive-restore`,[[`rect`,{width:`20`,height:`5`,x:`2`,y:`3`,rx:`1`,key:`1wp1u1`}],[`path`,{d:`M4 8v11a2 2 0 0 0 2 2h2`,key:`tvwodi`}],[`path`,{d:`M20 8v11a2 2 0 0 1-2 2h-2`,key:`1gkqxj`}],[`path`,{d:`m9 15 3-3 3 3`,key:`1pd0qc`}],[`path`,{d:`M12 12v9`,key:`192myk`}]]),r=e(`layout-list`,[[`rect`,{width:`7`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`1g98yp`}],[`rect`,{width:`7`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`1bb6yr`}],[`path`,{d:`M14 4h7`,key:`3xa0d5`}],[`path`,{d:`M14 9h7`,key:`1icrd9`}],[`path`,{d:`M14 15h7`,key:`1mj8o2`}],[`path`,{d:`M14 20h7`,key:`11slyb`}]]);function i(e,n){let{source:r,purpose:i}=t(e),a=i===`chat`?[n.sources[r]]:[n.purposes[i]];return i!==`chat`&&r!==`other`&&!(i===`automation`&&r===`automation`)&&!(i===`system`&&r===`system`)&&a.push(n.sources[r]),i===`chat`&&r===`other`&&e.sourceChannel&&a.push(e.sourceChannel),[...new Set(a)].join(` · `)}export{r as n,n as r,i as t};