@stigmer/server-slim 3.13.0 → 3.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (525) hide show
  1. package/console/404.html +1 -1
  2. package/console/__next.__PAGE__.txt +2 -2
  3. package/console/__next._full.txt +16 -16
  4. package/console/__next._head.txt +4 -4
  5. package/console/__next._index.txt +10 -10
  6. package/console/__next._tree.txt +2 -2
  7. package/console/_next/static/chunks/00609po93aecc.js +1 -0
  8. package/console/_next/static/chunks/{0o-.19qua6web.js → 0243~hpvegq~b.js} +2 -2
  9. package/console/_next/static/chunks/{0iwpyv2wbln6f.js → 0a2~15er-td24.js} +1 -1
  10. package/console/_next/static/chunks/0bssx61s0a_wl.js +1 -0
  11. package/console/_next/static/chunks/{0qji_.pm~u8x3.js → 0d~8qc-i_t3~z.js} +1 -1
  12. package/console/_next/static/chunks/{04nu-nyhd8yfk.js → 0e21g0s~5r7o9.js} +2 -2
  13. package/console/_next/static/chunks/0fss.uff1x3km.js +2 -0
  14. package/console/_next/static/chunks/0gpuzaltw6-8i.js +1 -0
  15. package/console/_next/static/chunks/0q80yr288t-5-.css +1 -0
  16. package/console/_next/static/chunks/{0icsogze8wb_v.js → 0uq41itbafxa3.js} +1 -1
  17. package/console/_next/static/chunks/0wsn_vbkz2vb9.js +1 -0
  18. package/console/_next/static/chunks/0x0c3-ubfxc~5.js +1 -0
  19. package/console/_next/static/chunks/0zf7ijjyl6exo.js +1 -0
  20. package/console/_next/static/chunks/{0zsntdh42--v1.js → 0~l2og0651chl.js} +1 -1
  21. package/console/_next/static/chunks/10ki-iljfqcs_.js +1 -0
  22. package/console/_next/static/chunks/163ne8a28fcm8.js +1 -0
  23. package/console/_not-found/__next._full.txt +16 -16
  24. package/console/_not-found/__next._head.txt +4 -4
  25. package/console/_not-found/__next._index.txt +10 -10
  26. package/console/_not-found/__next._not-found.__PAGE__.txt +3 -3
  27. package/console/_not-found/__next._not-found.txt +3 -3
  28. package/console/_not-found/__next._tree.txt +2 -2
  29. package/console/_not-found.html +1 -1
  30. package/console/_not-found.txt +16 -16
  31. package/console/auth/callback/__next._full.txt +18 -18
  32. package/console/auth/callback/__next._head.txt +4 -4
  33. package/console/auth/callback/__next._index.txt +10 -10
  34. package/console/auth/callback/__next._tree.txt +2 -2
  35. package/console/auth/callback/__next.auth.callback.__PAGE__.txt +4 -4
  36. package/console/auth/callback/__next.auth.callback.txt +3 -3
  37. package/console/auth/callback/__next.auth.txt +3 -3
  38. package/console/auth/callback.html +1 -1
  39. package/console/auth/callback.txt +18 -18
  40. package/console/auth/github/callback/__next._full.txt +18 -18
  41. package/console/auth/github/callback/__next._head.txt +4 -4
  42. package/console/auth/github/callback/__next._index.txt +10 -10
  43. package/console/auth/github/callback/__next._tree.txt +2 -2
  44. package/console/auth/github/callback/__next.auth.github.callback.__PAGE__.txt +4 -4
  45. package/console/auth/github/callback/__next.auth.github.callback.txt +3 -3
  46. package/console/auth/github/callback/__next.auth.github.txt +3 -3
  47. package/console/auth/github/callback/__next.auth.txt +3 -3
  48. package/console/auth/github/callback.html +1 -1
  49. package/console/auth/github/callback.txt +18 -18
  50. package/console/auth/oauth/callback/__next._full.txt +18 -18
  51. package/console/auth/oauth/callback/__next._head.txt +4 -4
  52. package/console/auth/oauth/callback/__next._index.txt +10 -10
  53. package/console/auth/oauth/callback/__next._tree.txt +2 -2
  54. package/console/auth/oauth/callback/__next.auth.oauth.callback.__PAGE__.txt +4 -4
  55. package/console/auth/oauth/callback/__next.auth.oauth.callback.txt +3 -3
  56. package/console/auth/oauth/callback/__next.auth.oauth.txt +3 -3
  57. package/console/auth/oauth/callback/__next.auth.txt +3 -3
  58. package/console/auth/oauth/callback.html +1 -1
  59. package/console/auth/oauth/callback.txt +18 -18
  60. package/console/chat/__placeholder__/__placeholder__/__next._full.txt +17 -17
  61. package/console/chat/__placeholder__/__placeholder__/__next._head.txt +4 -4
  62. package/console/chat/__placeholder__/__placeholder__/__next._index.txt +10 -10
  63. package/console/chat/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  64. package/console/chat/__placeholder__/__placeholder__/__next.chat.$d$org.$d$slug.__PAGE__.txt +3 -3
  65. package/console/chat/__placeholder__/__placeholder__/__next.chat.$d$org.$d$slug.txt +3 -3
  66. package/console/chat/__placeholder__/__placeholder__/__next.chat.$d$org.txt +3 -3
  67. package/console/chat/__placeholder__/__placeholder__/__next.chat.txt +3 -3
  68. package/console/chat/__placeholder__/__placeholder__.html +1 -1
  69. package/console/chat/__placeholder__/__placeholder__.txt +17 -17
  70. package/console/conversations/__next._full.txt +17 -17
  71. package/console/conversations/__next._head.txt +4 -4
  72. package/console/conversations/__next._index.txt +10 -10
  73. package/console/conversations/__next._tree.txt +2 -2
  74. package/console/conversations/__next.conversations.__PAGE__.txt +3 -3
  75. package/console/conversations/__next.conversations.txt +3 -3
  76. package/console/conversations/__placeholder__/__placeholder__/__next._full.txt +17 -17
  77. package/console/conversations/__placeholder__/__placeholder__/__next._head.txt +4 -4
  78. package/console/conversations/__placeholder__/__placeholder__/__next._index.txt +10 -10
  79. package/console/conversations/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  80. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.$d$key.__PAGE__.txt +3 -3
  81. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.$d$key.txt +3 -3
  82. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.txt +3 -3
  83. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.txt +3 -3
  84. package/console/conversations/__placeholder__/__placeholder__.html +1 -1
  85. package/console/conversations/__placeholder__/__placeholder__.txt +17 -17
  86. package/console/conversations.html +1 -1
  87. package/console/conversations.txt +17 -17
  88. package/console/dashboard/__next._full.txt +17 -17
  89. package/console/dashboard/__next._head.txt +4 -4
  90. package/console/dashboard/__next._index.txt +10 -10
  91. package/console/dashboard/__next._tree.txt +2 -2
  92. package/console/dashboard/__next.dashboard.__PAGE__.txt +3 -3
  93. package/console/dashboard/__next.dashboard.txt +3 -3
  94. package/console/dashboard.html +1 -1
  95. package/console/dashboard.txt +17 -17
  96. package/console/executions/__placeholder__/__next._full.txt +16 -16
  97. package/console/executions/__placeholder__/__next._head.txt +4 -4
  98. package/console/executions/__placeholder__/__next._index.txt +10 -10
  99. package/console/executions/__placeholder__/__next._tree.txt +2 -2
  100. package/console/executions/__placeholder__/__next.executions.$d$id.__PAGE__.txt +2 -2
  101. package/console/executions/__placeholder__/__next.executions.$d$id.txt +3 -3
  102. package/console/executions/__placeholder__/__next.executions.txt +3 -3
  103. package/console/executions/__placeholder__.html +1 -1
  104. package/console/executions/__placeholder__.txt +16 -16
  105. package/console/index.html +1 -1
  106. package/console/index.txt +16 -16
  107. package/console/invite/__placeholder__/__next._full.txt +17 -17
  108. package/console/invite/__placeholder__/__next._head.txt +4 -4
  109. package/console/invite/__placeholder__/__next._index.txt +10 -10
  110. package/console/invite/__placeholder__/__next._tree.txt +2 -2
  111. package/console/invite/__placeholder__/__next.invite.$d$token.__PAGE__.txt +3 -3
  112. package/console/invite/__placeholder__/__next.invite.$d$token.txt +3 -3
  113. package/console/invite/__placeholder__/__next.invite.txt +3 -3
  114. package/console/invite/__placeholder__.html +1 -1
  115. package/console/invite/__placeholder__.txt +17 -17
  116. package/console/library/__next._full.txt +20 -20
  117. package/console/library/__next._head.txt +4 -4
  118. package/console/library/__next._index.txt +10 -10
  119. package/console/library/__next._tree.txt +2 -2
  120. package/console/library/__next.library.__PAGE__.txt +3 -3
  121. package/console/library/__next.library.txt +5 -5
  122. package/console/library/agents/__next._full.txt +20 -20
  123. package/console/library/agents/__next._head.txt +4 -4
  124. package/console/library/agents/__next._index.txt +10 -10
  125. package/console/library/agents/__next._tree.txt +2 -2
  126. package/console/library/agents/__next.library.agents.__PAGE__.txt +3 -3
  127. package/console/library/agents/__next.library.agents.txt +3 -3
  128. package/console/library/agents/__next.library.txt +5 -5
  129. package/console/library/agents/__placeholder__/__placeholder__/__next._full.txt +20 -20
  130. package/console/library/agents/__placeholder__/__placeholder__/__next._head.txt +4 -4
  131. package/console/library/agents/__placeholder__/__placeholder__/__next._index.txt +10 -10
  132. package/console/library/agents/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  133. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.$d$slug.__PAGE__.txt +3 -3
  134. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.$d$slug.txt +3 -3
  135. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.txt +3 -3
  136. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.txt +3 -3
  137. package/console/library/agents/__placeholder__/__placeholder__/__next.library.txt +5 -5
  138. package/console/library/agents/__placeholder__/__placeholder__.html +1 -1
  139. package/console/library/agents/__placeholder__/__placeholder__.txt +20 -20
  140. package/console/library/agents/new/__next._full.txt +21 -21
  141. package/console/library/agents/new/__next._head.txt +4 -4
  142. package/console/library/agents/new/__next._index.txt +10 -10
  143. package/console/library/agents/new/__next._tree.txt +2 -2
  144. package/console/library/agents/new/__next.library.agents.new.__PAGE__.txt +4 -4
  145. package/console/library/agents/new/__next.library.agents.new.txt +3 -3
  146. package/console/library/agents/new/__next.library.agents.txt +3 -3
  147. package/console/library/agents/new/__next.library.txt +5 -5
  148. package/console/library/agents/new.html +1 -1
  149. package/console/library/agents/new.txt +21 -21
  150. package/console/library/agents.html +1 -1
  151. package/console/library/agents.txt +20 -20
  152. package/console/library/mcp-servers/__next._full.txt +20 -20
  153. package/console/library/mcp-servers/__next._head.txt +4 -4
  154. package/console/library/mcp-servers/__next._index.txt +10 -10
  155. package/console/library/mcp-servers/__next._tree.txt +2 -2
  156. package/console/library/mcp-servers/__next.library.mcp-servers.__PAGE__.txt +3 -3
  157. package/console/library/mcp-servers/__next.library.mcp-servers.txt +3 -3
  158. package/console/library/mcp-servers/__next.library.txt +5 -5
  159. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._full.txt +20 -20
  160. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._head.txt +4 -4
  161. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._index.txt +10 -10
  162. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  163. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.$d$org.$d$slug.__PAGE__.txt +3 -3
  164. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.$d$org.$d$slug.txt +3 -3
  165. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.$d$org.txt +3 -3
  166. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.txt +3 -3
  167. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.txt +5 -5
  168. package/console/library/mcp-servers/__placeholder__/__placeholder__.html +1 -1
  169. package/console/library/mcp-servers/__placeholder__/__placeholder__.txt +20 -20
  170. package/console/library/mcp-servers/new/__next._full.txt +21 -21
  171. package/console/library/mcp-servers/new/__next._head.txt +4 -4
  172. package/console/library/mcp-servers/new/__next._index.txt +10 -10
  173. package/console/library/mcp-servers/new/__next._tree.txt +2 -2
  174. package/console/library/mcp-servers/new/__next.library.mcp-servers.new.__PAGE__.txt +4 -4
  175. package/console/library/mcp-servers/new/__next.library.mcp-servers.new.txt +3 -3
  176. package/console/library/mcp-servers/new/__next.library.mcp-servers.txt +3 -3
  177. package/console/library/mcp-servers/new/__next.library.txt +5 -5
  178. package/console/library/mcp-servers/new.html +1 -1
  179. package/console/library/mcp-servers/new.txt +21 -21
  180. package/console/library/mcp-servers.html +1 -1
  181. package/console/library/mcp-servers.txt +20 -20
  182. package/console/library/schedules/__next._full.txt +20 -20
  183. package/console/library/schedules/__next._head.txt +4 -4
  184. package/console/library/schedules/__next._index.txt +10 -10
  185. package/console/library/schedules/__next._tree.txt +2 -2
  186. package/console/library/schedules/__next.library.schedules.__PAGE__.txt +3 -3
  187. package/console/library/schedules/__next.library.schedules.txt +3 -3
  188. package/console/library/schedules/__next.library.txt +5 -5
  189. package/console/library/schedules/__placeholder__/__placeholder__/__next._full.txt +20 -20
  190. package/console/library/schedules/__placeholder__/__placeholder__/__next._head.txt +4 -4
  191. package/console/library/schedules/__placeholder__/__placeholder__/__next._index.txt +10 -10
  192. package/console/library/schedules/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  193. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.$d$org.$d$slug.__PAGE__.txt +3 -3
  194. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.$d$org.$d$slug.txt +3 -3
  195. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.$d$org.txt +3 -3
  196. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.txt +3 -3
  197. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.txt +5 -5
  198. package/console/library/schedules/__placeholder__/__placeholder__.html +1 -1
  199. package/console/library/schedules/__placeholder__/__placeholder__.txt +20 -20
  200. package/console/library/schedules/new/__next._full.txt +21 -21
  201. package/console/library/schedules/new/__next._head.txt +4 -4
  202. package/console/library/schedules/new/__next._index.txt +10 -10
  203. package/console/library/schedules/new/__next._tree.txt +2 -2
  204. package/console/library/schedules/new/__next.library.schedules.new.__PAGE__.txt +4 -4
  205. package/console/library/schedules/new/__next.library.schedules.new.txt +3 -3
  206. package/console/library/schedules/new/__next.library.schedules.txt +3 -3
  207. package/console/library/schedules/new/__next.library.txt +5 -5
  208. package/console/library/schedules/new.html +1 -1
  209. package/console/library/schedules/new.txt +21 -21
  210. package/console/library/schedules.html +1 -1
  211. package/console/library/schedules.txt +20 -20
  212. package/console/library/skills/__next._full.txt +20 -20
  213. package/console/library/skills/__next._head.txt +4 -4
  214. package/console/library/skills/__next._index.txt +10 -10
  215. package/console/library/skills/__next._tree.txt +2 -2
  216. package/console/library/skills/__next.library.skills.__PAGE__.txt +3 -3
  217. package/console/library/skills/__next.library.skills.txt +3 -3
  218. package/console/library/skills/__next.library.txt +5 -5
  219. package/console/library/skills/__placeholder__/__placeholder__/__next._full.txt +20 -20
  220. package/console/library/skills/__placeholder__/__placeholder__/__next._head.txt +4 -4
  221. package/console/library/skills/__placeholder__/__placeholder__/__next._index.txt +10 -10
  222. package/console/library/skills/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  223. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.$d$slug.__PAGE__.txt +3 -3
  224. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.$d$slug.txt +3 -3
  225. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.txt +3 -3
  226. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.txt +3 -3
  227. package/console/library/skills/__placeholder__/__placeholder__/__next.library.txt +5 -5
  228. package/console/library/skills/__placeholder__/__placeholder__.html +1 -1
  229. package/console/library/skills/__placeholder__/__placeholder__.txt +20 -20
  230. package/console/library/skills/new/__next._full.txt +21 -21
  231. package/console/library/skills/new/__next._head.txt +4 -4
  232. package/console/library/skills/new/__next._index.txt +10 -10
  233. package/console/library/skills/new/__next._tree.txt +2 -2
  234. package/console/library/skills/new/__next.library.skills.new.__PAGE__.txt +4 -4
  235. package/console/library/skills/new/__next.library.skills.new.txt +3 -3
  236. package/console/library/skills/new/__next.library.skills.txt +3 -3
  237. package/console/library/skills/new/__next.library.txt +5 -5
  238. package/console/library/skills/new.html +1 -1
  239. package/console/library/skills/new.txt +21 -21
  240. package/console/library/skills.html +1 -1
  241. package/console/library/skills.txt +20 -20
  242. package/console/library/workflows/__next._full.txt +20 -20
  243. package/console/library/workflows/__next._head.txt +4 -4
  244. package/console/library/workflows/__next._index.txt +10 -10
  245. package/console/library/workflows/__next._tree.txt +2 -2
  246. package/console/library/workflows/__next.library.txt +5 -5
  247. package/console/library/workflows/__next.library.workflows.__PAGE__.txt +3 -3
  248. package/console/library/workflows/__next.library.workflows.txt +3 -3
  249. package/console/library/workflows/__placeholder__/__placeholder__/__next._full.txt +20 -20
  250. package/console/library/workflows/__placeholder__/__placeholder__/__next._head.txt +4 -4
  251. package/console/library/workflows/__placeholder__/__placeholder__/__next._index.txt +10 -10
  252. package/console/library/workflows/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  253. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.txt +5 -5
  254. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.$d$org.$d$slug.__PAGE__.txt +3 -3
  255. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.$d$org.$d$slug.txt +3 -3
  256. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.$d$org.txt +3 -3
  257. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.txt +3 -3
  258. package/console/library/workflows/__placeholder__/__placeholder__.html +1 -1
  259. package/console/library/workflows/__placeholder__/__placeholder__.txt +20 -20
  260. package/console/library/workflows/executions/__next._full.txt +20 -20
  261. package/console/library/workflows/executions/__next._head.txt +4 -4
  262. package/console/library/workflows/executions/__next._index.txt +10 -10
  263. package/console/library/workflows/executions/__next._tree.txt +2 -2
  264. package/console/library/workflows/executions/__next.library.txt +5 -5
  265. package/console/library/workflows/executions/__next.library.workflows.executions.__PAGE__.txt +3 -3
  266. package/console/library/workflows/executions/__next.library.workflows.executions.txt +3 -3
  267. package/console/library/workflows/executions/__next.library.workflows.txt +3 -3
  268. package/console/library/workflows/executions.html +1 -1
  269. package/console/library/workflows/executions.txt +20 -20
  270. package/console/library/workflows/new/__next._full.txt +21 -21
  271. package/console/library/workflows/new/__next._head.txt +4 -4
  272. package/console/library/workflows/new/__next._index.txt +10 -10
  273. package/console/library/workflows/new/__next._tree.txt +2 -2
  274. package/console/library/workflows/new/__next.library.txt +5 -5
  275. package/console/library/workflows/new/__next.library.workflows.new.__PAGE__.txt +4 -4
  276. package/console/library/workflows/new/__next.library.workflows.new.txt +3 -3
  277. package/console/library/workflows/new/__next.library.workflows.txt +3 -3
  278. package/console/library/workflows/new.html +1 -1
  279. package/console/library/workflows/new.txt +21 -21
  280. package/console/library/workflows.html +1 -1
  281. package/console/library/workflows.txt +20 -20
  282. package/console/library.html +1 -1
  283. package/console/library.txt +20 -20
  284. package/console/login/__next._full.txt +18 -18
  285. package/console/login/__next._head.txt +4 -4
  286. package/console/login/__next._index.txt +10 -10
  287. package/console/login/__next._tree.txt +2 -2
  288. package/console/login/__next.login.__PAGE__.txt +4 -4
  289. package/console/login/__next.login.txt +3 -3
  290. package/console/login.html +1 -1
  291. package/console/login.txt +18 -18
  292. package/console/oauth/slack/callback/__next._full.txt +18 -18
  293. package/console/oauth/slack/callback/__next._head.txt +4 -4
  294. package/console/oauth/slack/callback/__next._index.txt +10 -10
  295. package/console/oauth/slack/callback/__next._tree.txt +2 -2
  296. package/console/oauth/slack/callback/__next.oauth.slack.callback.__PAGE__.txt +4 -4
  297. package/console/oauth/slack/callback/__next.oauth.slack.callback.txt +3 -3
  298. package/console/oauth/slack/callback/__next.oauth.slack.txt +3 -3
  299. package/console/oauth/slack/callback/__next.oauth.txt +3 -3
  300. package/console/oauth/slack/callback.html +1 -1
  301. package/console/oauth/slack/callback.txt +18 -18
  302. package/console/sessions/__placeholder__/__next._full.txt +16 -16
  303. package/console/sessions/__placeholder__/__next._head.txt +4 -4
  304. package/console/sessions/__placeholder__/__next._index.txt +10 -10
  305. package/console/sessions/__placeholder__/__next._tree.txt +2 -2
  306. package/console/sessions/__placeholder__/__next.sessions.$d$id.__PAGE__.txt +2 -2
  307. package/console/sessions/__placeholder__/__next.sessions.$d$id.txt +3 -3
  308. package/console/sessions/__placeholder__/__next.sessions.txt +3 -3
  309. package/console/sessions/__placeholder__.html +1 -1
  310. package/console/sessions/__placeholder__.txt +16 -16
  311. package/console/settings/__next._full.txt +20 -20
  312. package/console/settings/__next._head.txt +4 -4
  313. package/console/settings/__next._index.txt +10 -10
  314. package/console/settings/__next._tree.txt +2 -2
  315. package/console/settings/__next.settings.__PAGE__.txt +4 -4
  316. package/console/settings/__next.settings.txt +5 -5
  317. package/console/settings/account-preferences/__next._full.txt +19 -19
  318. package/console/settings/account-preferences/__next._head.txt +4 -4
  319. package/console/settings/account-preferences/__next._index.txt +10 -10
  320. package/console/settings/account-preferences/__next._tree.txt +2 -2
  321. package/console/settings/account-preferences/__next.settings.account-preferences.__PAGE__.txt +3 -3
  322. package/console/settings/account-preferences/__next.settings.account-preferences.txt +3 -3
  323. package/console/settings/account-preferences/__next.settings.txt +5 -5
  324. package/console/settings/account-preferences.html +1 -1
  325. package/console/settings/account-preferences.txt +19 -19
  326. package/console/settings/api-keys/__next._full.txt +19 -19
  327. package/console/settings/api-keys/__next._head.txt +4 -4
  328. package/console/settings/api-keys/__next._index.txt +10 -10
  329. package/console/settings/api-keys/__next._tree.txt +2 -2
  330. package/console/settings/api-keys/__next.settings.api-keys.__PAGE__.txt +3 -3
  331. package/console/settings/api-keys/__next.settings.api-keys.txt +3 -3
  332. package/console/settings/api-keys/__next.settings.txt +5 -5
  333. package/console/settings/api-keys.html +1 -1
  334. package/console/settings/api-keys.txt +19 -19
  335. package/console/settings/billing/__next._full.txt +20 -20
  336. package/console/settings/billing/__next._head.txt +4 -4
  337. package/console/settings/billing/__next._index.txt +10 -10
  338. package/console/settings/billing/__next._tree.txt +2 -2
  339. package/console/settings/billing/__next.settings.billing.__PAGE__.txt +4 -4
  340. package/console/settings/billing/__next.settings.billing.txt +3 -3
  341. package/console/settings/billing/__next.settings.txt +5 -5
  342. package/console/settings/billing.html +1 -1
  343. package/console/settings/billing.txt +20 -20
  344. package/console/settings/channel-apps/__next._full.txt +19 -19
  345. package/console/settings/channel-apps/__next._head.txt +4 -4
  346. package/console/settings/channel-apps/__next._index.txt +10 -10
  347. package/console/settings/channel-apps/__next._tree.txt +2 -2
  348. package/console/settings/channel-apps/__next.settings.channel-apps.__PAGE__.txt +3 -3
  349. package/console/settings/channel-apps/__next.settings.channel-apps.txt +3 -3
  350. package/console/settings/channel-apps/__next.settings.txt +5 -5
  351. package/console/settings/channel-apps.html +1 -1
  352. package/console/settings/channel-apps.txt +19 -19
  353. package/console/settings/cursor-accounts/__next._full.txt +21 -21
  354. package/console/settings/cursor-accounts/__next._head.txt +4 -4
  355. package/console/settings/cursor-accounts/__next._index.txt +10 -10
  356. package/console/settings/cursor-accounts/__next._tree.txt +2 -2
  357. package/console/settings/cursor-accounts/__next.settings.cursor-accounts.__PAGE__.txt +4 -4
  358. package/console/settings/cursor-accounts/__next.settings.cursor-accounts.txt +3 -3
  359. package/console/settings/cursor-accounts/__next.settings.txt +5 -5
  360. package/console/settings/cursor-accounts.html +1 -1
  361. package/console/settings/cursor-accounts.txt +21 -21
  362. package/console/settings/environments/__next._full.txt +19 -19
  363. package/console/settings/environments/__next._head.txt +4 -4
  364. package/console/settings/environments/__next._index.txt +10 -10
  365. package/console/settings/environments/__next._tree.txt +2 -2
  366. package/console/settings/environments/__next.settings.environments.__PAGE__.txt +3 -3
  367. package/console/settings/environments/__next.settings.environments.txt +3 -3
  368. package/console/settings/environments/__next.settings.txt +5 -5
  369. package/console/settings/environments.html +1 -1
  370. package/console/settings/environments.txt +19 -19
  371. package/console/settings/identity-providers/__next._full.txt +19 -19
  372. package/console/settings/identity-providers/__next._head.txt +4 -4
  373. package/console/settings/identity-providers/__next._index.txt +10 -10
  374. package/console/settings/identity-providers/__next._tree.txt +2 -2
  375. package/console/settings/identity-providers/__next.settings.identity-providers.__PAGE__.txt +3 -3
  376. package/console/settings/identity-providers/__next.settings.identity-providers.txt +3 -3
  377. package/console/settings/identity-providers/__next.settings.txt +5 -5
  378. package/console/settings/identity-providers.html +1 -1
  379. package/console/settings/identity-providers.txt +19 -19
  380. package/console/settings/invitations/__next._full.txt +19 -19
  381. package/console/settings/invitations/__next._head.txt +4 -4
  382. package/console/settings/invitations/__next._index.txt +10 -10
  383. package/console/settings/invitations/__next._tree.txt +2 -2
  384. package/console/settings/invitations/__next.settings.invitations.__PAGE__.txt +3 -3
  385. package/console/settings/invitations/__next.settings.invitations.txt +3 -3
  386. package/console/settings/invitations/__next.settings.txt +5 -5
  387. package/console/settings/invitations.html +1 -1
  388. package/console/settings/invitations.txt +19 -19
  389. package/console/settings/members/__next._full.txt +19 -19
  390. package/console/settings/members/__next._head.txt +4 -4
  391. package/console/settings/members/__next._index.txt +10 -10
  392. package/console/settings/members/__next._tree.txt +2 -2
  393. package/console/settings/members/__next.settings.members.__PAGE__.txt +3 -3
  394. package/console/settings/members/__next.settings.members.txt +3 -3
  395. package/console/settings/members/__next.settings.txt +5 -5
  396. package/console/settings/members.html +1 -1
  397. package/console/settings/members.txt +19 -19
  398. package/console/settings/memory/__next._full.txt +19 -19
  399. package/console/settings/memory/__next._head.txt +4 -4
  400. package/console/settings/memory/__next._index.txt +10 -10
  401. package/console/settings/memory/__next._tree.txt +2 -2
  402. package/console/settings/memory/__next.settings.memory.__PAGE__.txt +3 -3
  403. package/console/settings/memory/__next.settings.memory.txt +3 -3
  404. package/console/settings/memory/__next.settings.txt +5 -5
  405. package/console/settings/memory.html +1 -1
  406. package/console/settings/memory.txt +19 -19
  407. package/console/settings/oauth-apps/__next._full.txt +19 -19
  408. package/console/settings/oauth-apps/__next._head.txt +4 -4
  409. package/console/settings/oauth-apps/__next._index.txt +10 -10
  410. package/console/settings/oauth-apps/__next._tree.txt +2 -2
  411. package/console/settings/oauth-apps/__next.settings.oauth-apps.__PAGE__.txt +3 -3
  412. package/console/settings/oauth-apps/__next.settings.oauth-apps.txt +3 -3
  413. package/console/settings/oauth-apps/__next.settings.txt +5 -5
  414. package/console/settings/oauth-apps.html +1 -1
  415. package/console/settings/oauth-apps.txt +19 -19
  416. package/console/settings/org-preferences/__next._full.txt +19 -19
  417. package/console/settings/org-preferences/__next._head.txt +4 -4
  418. package/console/settings/org-preferences/__next._index.txt +10 -10
  419. package/console/settings/org-preferences/__next._tree.txt +2 -2
  420. package/console/settings/org-preferences/__next.settings.org-preferences.__PAGE__.txt +3 -3
  421. package/console/settings/org-preferences/__next.settings.org-preferences.txt +3 -3
  422. package/console/settings/org-preferences/__next.settings.txt +5 -5
  423. package/console/settings/org-preferences.html +1 -1
  424. package/console/settings/org-preferences.txt +19 -19
  425. package/console/settings/org-profile/__next._full.txt +19 -19
  426. package/console/settings/org-profile/__next._head.txt +4 -4
  427. package/console/settings/org-profile/__next._index.txt +10 -10
  428. package/console/settings/org-profile/__next._tree.txt +2 -2
  429. package/console/settings/org-profile/__next.settings.org-profile.__PAGE__.txt +3 -3
  430. package/console/settings/org-profile/__next.settings.org-profile.txt +3 -3
  431. package/console/settings/org-profile/__next.settings.txt +5 -5
  432. package/console/settings/org-profile.html +1 -1
  433. package/console/settings/org-profile.txt +19 -19
  434. package/console/settings/platform-clients/__next._full.txt +19 -19
  435. package/console/settings/platform-clients/__next._head.txt +4 -4
  436. package/console/settings/platform-clients/__next._index.txt +10 -10
  437. package/console/settings/platform-clients/__next._tree.txt +2 -2
  438. package/console/settings/platform-clients/__next.settings.platform-clients.__PAGE__.txt +3 -3
  439. package/console/settings/platform-clients/__next.settings.platform-clients.txt +3 -3
  440. package/console/settings/platform-clients/__next.settings.txt +5 -5
  441. package/console/settings/platform-clients.html +1 -1
  442. package/console/settings/platform-clients.txt +19 -19
  443. package/console/settings/pricing-governance/__next._full.txt +20 -20
  444. package/console/settings/pricing-governance/__next._head.txt +4 -4
  445. package/console/settings/pricing-governance/__next._index.txt +10 -10
  446. package/console/settings/pricing-governance/__next._tree.txt +2 -2
  447. package/console/settings/pricing-governance/__next.settings.pricing-governance.__PAGE__.txt +4 -4
  448. package/console/settings/pricing-governance/__next.settings.pricing-governance.txt +3 -3
  449. package/console/settings/pricing-governance/__next.settings.txt +5 -5
  450. package/console/settings/pricing-governance.html +1 -1
  451. package/console/settings/pricing-governance.txt +20 -20
  452. package/console/settings/provider-standing/__next._full.txt +20 -20
  453. package/console/settings/provider-standing/__next._head.txt +4 -4
  454. package/console/settings/provider-standing/__next._index.txt +10 -10
  455. package/console/settings/provider-standing/__next._tree.txt +2 -2
  456. package/console/settings/provider-standing/__next.settings.provider-standing.__PAGE__.txt +4 -4
  457. package/console/settings/provider-standing/__next.settings.provider-standing.txt +3 -3
  458. package/console/settings/provider-standing/__next.settings.txt +5 -5
  459. package/console/settings/provider-standing.html +1 -1
  460. package/console/settings/provider-standing.txt +20 -20
  461. package/console/settings/usage/__next._full.txt +19 -19
  462. package/console/settings/usage/__next._head.txt +4 -4
  463. package/console/settings/usage/__next._index.txt +10 -10
  464. package/console/settings/usage/__next._tree.txt +2 -2
  465. package/console/settings/usage/__next.settings.txt +5 -5
  466. package/console/settings/usage/__next.settings.usage.__PAGE__.txt +3 -3
  467. package/console/settings/usage/__next.settings.usage.txt +3 -3
  468. package/console/settings/usage.html +1 -1
  469. package/console/settings/usage.txt +19 -19
  470. package/console/settings.html +1 -1
  471. package/console/settings.txt +20 -20
  472. package/console/workflows/__next._full.txt +16 -16
  473. package/console/workflows/__next._head.txt +4 -4
  474. package/console/workflows/__next._index.txt +10 -10
  475. package/console/workflows/__next._tree.txt +2 -2
  476. package/console/workflows/__next.workflows.__PAGE__.txt +2 -2
  477. package/console/workflows/__next.workflows.txt +3 -3
  478. package/console/workflows/__placeholder__/__placeholder__/__next._full.txt +17 -17
  479. package/console/workflows/__placeholder__/__placeholder__/__next._head.txt +4 -4
  480. package/console/workflows/__placeholder__/__placeholder__/__next._index.txt +10 -10
  481. package/console/workflows/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  482. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.$d$org.$d$slug.__PAGE__.txt +3 -3
  483. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.$d$org.$d$slug.txt +3 -3
  484. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.$d$org.txt +3 -3
  485. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.txt +3 -3
  486. package/console/workflows/__placeholder__/__placeholder__.html +1 -1
  487. package/console/workflows/__placeholder__/__placeholder__.txt +17 -17
  488. package/console/workflows/executions/__next._full.txt +16 -16
  489. package/console/workflows/executions/__next._head.txt +4 -4
  490. package/console/workflows/executions/__next._index.txt +10 -10
  491. package/console/workflows/executions/__next._tree.txt +2 -2
  492. package/console/workflows/executions/__next.workflows.executions.__PAGE__.txt +2 -2
  493. package/console/workflows/executions/__next.workflows.executions.txt +3 -3
  494. package/console/workflows/executions/__next.workflows.txt +3 -3
  495. package/console/workflows/executions/__placeholder__/__next._full.txt +17 -17
  496. package/console/workflows/executions/__placeholder__/__next._head.txt +4 -4
  497. package/console/workflows/executions/__placeholder__/__next._index.txt +10 -10
  498. package/console/workflows/executions/__placeholder__/__next._tree.txt +2 -2
  499. package/console/workflows/executions/__placeholder__/__next.workflows.executions.$d$id.__PAGE__.txt +3 -3
  500. package/console/workflows/executions/__placeholder__/__next.workflows.executions.$d$id.txt +3 -3
  501. package/console/workflows/executions/__placeholder__/__next.workflows.executions.txt +3 -3
  502. package/console/workflows/executions/__placeholder__/__next.workflows.txt +3 -3
  503. package/console/workflows/executions/__placeholder__.html +1 -1
  504. package/console/workflows/executions/__placeholder__.txt +17 -17
  505. package/console/workflows/executions.html +1 -1
  506. package/console/workflows/executions.txt +16 -16
  507. package/console/workflows.html +1 -1
  508. package/console/workflows.txt +16 -16
  509. package/main.js +286 -100
  510. package/package.json +6 -6
  511. package/workflow-bundle-agent-execution.js +26 -8
  512. package/workflow-bundle-workflow-execution.js +25 -7
  513. package/console/_next/static/chunks/0-l4jzu40dd8w.js +0 -1
  514. package/console/_next/static/chunks/0-z-fnjdx4ulh.js +0 -1
  515. package/console/_next/static/chunks/07wnm1~gr1rx~.js +0 -1
  516. package/console/_next/static/chunks/0af53k.rxu1kn.js +0 -1
  517. package/console/_next/static/chunks/0cgp87bgoglgv.js +0 -1
  518. package/console/_next/static/chunks/0g-98wql22rf4.css +0 -1
  519. package/console/_next/static/chunks/0oprw5m.lmqln.js +0 -1
  520. package/console/_next/static/chunks/0ptwwlt0l20~o.js +0 -1
  521. package/console/_next/static/chunks/0taiwi2j.k7mm.js +0 -1
  522. package/console/_next/static/chunks/11xfx57fbi3md.js +0 -2
  523. /package/console/_next/static/{XrBnttPHHP5Wmi7mT4uLM → _-1QOBCdmEZcdWQHZomTm}/_buildManifest.js +0 -0
  524. /package/console/_next/static/{XrBnttPHHP5Wmi7mT4uLM → _-1QOBCdmEZcdWQHZomTm}/_clientMiddlewareManifest.js +0 -0
  525. /package/console/_next/static/{XrBnttPHHP5Wmi7mT4uLM → _-1QOBCdmEZcdWQHZomTm}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,297629,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(586108),s=e.i(941693);let i=(0,r.createContext)(null),a="stigmer:activeOrgSlug";function o(e){try{localStorage.setItem(a,e)}catch{}}function l(){let e=(0,r.useContext)(i);if(!e)throw Error("useOrg must be used within <OrgProvider>. Wrap your component tree with <OrgProvider> inside a <StigmerProvider>.");return e}e.s(["OrgProvider",0,function({children:e}){let l=(0,n.useStigmer)(),c=(0,s.useFetchCache)(),[u,d]=(0,r.useState)([]),[g,h]=(0,r.useState)(null),[m,f]=(0,r.useState)(!0),[p,b]=(0,r.useState)(null),v=(0,r.useRef)(0),x=(0,r.useCallback)(async e=>{let t=++v.current;f(!0),b(null);try{let r=(await l.organization.findMyOrganizations()).entries;if(t!==v.current)return;if(d(r),0===r.length)return void h(null);let n=e??function(){try{return localStorage.getItem(a)}catch{return null}}(),s=(n?r.find(e=>e.metadata?.slug===n):void 0)??r[0];h(s),s.metadata?.slug&&o(s.metadata.slug)}catch(e){if(t!==v.current)return;b(e instanceof Error?e.message:"Failed to load organizations"),d([]),h(null)}finally{t===v.current&&f(!1)}},[l]);(0,r.useEffect)(()=>{x()},[x]);let y=(0,r.useCallback)(e=>{h(e),e.metadata?.slug&&o(e.metadata.slug)},[]),k=(0,r.useRef)(null),A=g?.metadata?.slug??null;(0,r.useEffect)(()=>{let e=k.current;k.current=A,null!==e&&null!==A&&e!==A&&c?.clear()},[A,c]);let w=(0,r.useMemo)(()=>({orgs:u,activeOrg:g,setActiveOrg:y,isLoading:m,error:p,retry:x,refresh:x}),[u,g,y,m,p,x]);return(0,t.jsx)(i.Provider,{value:w,children:e})},"useActiveOrgId",0,function(){let{activeOrg:e}=l();return e?.metadata?.id??""},"useActiveOrgSlug",0,function(){let{activeOrg:e}=l();return e?.metadata?.slug??""},"useOrg",0,l])},869803,e=>{"use strict";e.s(["UNSTYLED_FIELDSET",0,"stg:m-0 stg:min-w-0 stg:p-0","UNSTYLED_LIST",0,"stg:m-0 stg:list-none stg:p-0"])},597744,e=>{"use strict";var t=e.i(271645),r=e.i(170255);let n=new Set([r.ApiResourceKind.api_resource_version,r.ApiResourceKind.iam_policy,r.ApiResourceKind.identity_account,r.ApiResourceKind.invitation,r.ApiResourceKind.identity_provider,r.ApiResourceKind.oauth_app,r.ApiResourceKind.platform_client,r.ApiResourceKind.platform]),s=(0,t.createContext)("cloud");function i(){return(0,t.useContext)(s)}e.s(["DeploymentModeContext",0,s,"useDeploymentMode",0,i,"useResourceAvailable",0,function(e){return"cloud"===i()||!n.has(e)}],597744)},893976,e=>{"use strict";var t=e.i(207670),r=e.i(919056);let n="stg:",s=(0,r.extendTailwindMerge)({experimentalParseClassName:({className:e,parseClassName:t})=>t(e.startsWith(n)?e.slice(n.length):e)});e.s(["cn",0,function(...e){return s((0,t.clsx)(e))}])},304532,e=>{"use strict";e.s(["messageDesc",0,function(e,t,...r){return r.reduce((e,t)=>e.nestedMessages[t],e.messages[t])}])},81027,e=>{"use strict";var t=e.i(424407),r=e.i(14156);let n=(0,t.fileDesc)("Ch5nb29nbGUvcHJvdG9idWYvZHVyYXRpb24ucHJvdG8SD2dvb2dsZS5wcm90b2J1ZiIqCghEdXJhdGlvbhIPCgdzZWNvbmRzGAEgASgDEg0KBW5hbm9zGAIgASgFQoMBChNjb20uZ29vZ2xlLnByb3RvYnVmQg1EdXJhdGlvblByb3RvUAFaMWdvb2dsZS5nb2xhbmcub3JnL3Byb3RvYnVmL3R5cGVzL2tub3duL2R1cmF0aW9ucGL4AQGiAgNHUEKqAh5Hb29nbGUuUHJvdG9idWYuV2VsbEtub3duVHlwZXNiBnByb3RvMw"),s=(0,r.messageDesc)(n,0);e.s(["DurationSchema",0,s,"file_google_protobuf_duration",0,n])},586108,156463,e=>{"use strict";var t=e.i(271645);let r=(0,t.createContext)(null);e.s(["StigmerContext",0,r],156463),e.s(["useStigmer",0,function(){let e=(0,t.useContext)(r);if(!e)throw Error("useStigmer must be used within <StigmerProvider>. Wrap your component tree with <StigmerProvider client={stigmerClient}>.");return e}],586108)},326283,e=>{"use strict";e.s(["toError",0,function(e){return e instanceof Error?e:"string"==typeof e?Error(e):Error("An unexpected error occurred")}])},941693,e=>{"use strict";var t=e.i(843476),r=e.i(271645);class n{_entries=new Map;_maxEntries;_ttl;constructor(e){this._maxEntries=e?.maxEntries??100,this._ttl=e?.ttl??3e5}get(e){let t=this._entries.get(e);if(t)return this._isExpired(t)?void this._entries.delete(e):t.data}has(e){return void 0!==this.get(e)}set(e,t){this._entries.delete(e),this._entries.set(e,{data:t,timestamp:Date.now()}),this._evict()}invalidate(e){this._entries.delete(e)}invalidatePrefix(e){for(let t of this._entries.keys())t.startsWith(e)&&this._entries.delete(t)}prefetch(e,t){t().then(t=>this.set(e,t),()=>{})}clear(){this._entries.clear()}get size(){for(let[e,t]of this._entries)this._isExpired(t)&&this._entries.delete(e);return this._entries.size}_isExpired(e){return Date.now()-e.timestamp>this._ttl}_evict(){if(this._entries.size<=this._maxEntries)return;let e=this._entries.size-this._maxEntries,t=this._entries.keys();for(let r=0;r<e;r++){let{value:e,done:r}=t.next();if(r)break;this._entries.delete(e)}}}let s=(0,r.createContext)(null);e.s(["FetchCacheProvider",0,function({children:e,maxEntries:i,ttl:a}){let o=(0,r.useRef)(null);return o.current||(o.current=new n({maxEntries:i,ttl:a})),(0,t.jsx)(s.Provider,{value:o.current,children:e})},"useFetchCache",0,function(){return(0,r.useContext)(s)}],941693)},583093,e=>{"use strict";var t=e.i(271645),r=e.i(941693),n=e.i(326283);e.s(["useFetch",0,function(e,s,i,a){let o=(0,r.useFetchCache)(),l=a?.cacheKey,[c,u]=(0,t.useState)(()=>{if(l&&o){let e=o.get(l);if(void 0!==e)return e}return i}),[d,g]=(0,t.useState)(null),[h,m]=(0,t.useState)(0),f=(0,t.useRef)(!!l&&!!o&&o.has(l)),p=(0,t.useRef)(null!==e),[b,v]=(0,t.useState)(null!==e),x=(0,t.useRef)(o);x.current=o;let y=(0,t.useRef)(s),k=(0,t.useCallback)(()=>m(e=>e+1),[]);(0,t.useEffect)(()=>{if(!e){u(i),v(!1),p.current=!1,g(null),f.current=!1,y.current=s;return}let t=s.length!==y.current.length||s.some((e,t)=>!Object.is(e,y.current[t]));if(y.current=s,t)if(l&&x.current){let e=x.current.get(l);void 0!==e?(u(e),f.current=!0):(u(i),f.current=!1)}else l||(u(i),f.current=!1);let r={current:!1};return v(!0),p.current=!0,g(null),e().then(e=>{!r.current&&(u(e),f.current=!0,v(!1),p.current=!1,l&&x.current&&x.current.set(l,e))},e=>{r.current||(g((0,n.toError)(e)),v(!1),p.current=!1)}),()=>{r.current=!0}},[...s,h]);let A=null!==e,w=a?.refetchInterval;(0,t.useEffect)(()=>{if(!w||w<=0||!A)return;let e=setInterval(()=>{p.current||k()},w);return()=>clearInterval(e)},[w,A,k]);let E=a?.refetchOnWindowFocus;return(0,t.useEffect)(()=>{if(!E||!A)return;let e=()=>{p.current||k()},t=()=>{"visible"===document.visibilityState&&e()};return window.addEventListener("focus",e),document.addEventListener("visibilitychange",t),()=>{window.removeEventListener("focus",e),document.removeEventListener("visibilitychange",t)}},[E,A,k]),{data:c,isLoading:b&&!f.current,isRefetching:b&&f.current,error:d,refetch:k}}])},167937,939910,524093,e=>{"use strict";let t;(r=n||(n={}))[r.Canceled=1]="Canceled",r[r.Unknown=2]="Unknown",r[r.InvalidArgument=3]="InvalidArgument",r[r.DeadlineExceeded=4]="DeadlineExceeded",r[r.NotFound=5]="NotFound",r[r.AlreadyExists=6]="AlreadyExists",r[r.PermissionDenied=7]="PermissionDenied",r[r.ResourceExhausted=8]="ResourceExhausted",r[r.FailedPrecondition=9]="FailedPrecondition",r[r.Aborted=10]="Aborted",r[r.OutOfRange=11]="OutOfRange",r[r.Unimplemented=12]="Unimplemented",r[r.Internal=13]="Internal",r[r.Unavailable=14]="Unavailable",r[r.DataLoss=15]="DataLoss",r[r.Unauthenticated=16]="Unauthenticated",e.s(["Code",0,n],939910);var r,n,s=e.i(891287),i=e.i(29671);function a(e){let t=n[e];return"string"!=typeof t?e.toString():t[0].toLowerCase()+t.substring(1).replace(/[A-Z]/g,e=>"_"+e.toLowerCase())}e.s(["codeFromString",0,function(e){if(!t)for(let e of(t={},Object.values(n)))"string"!=typeof e&&(t[a(e)]=e);return t[e]},"codeToString",0,a],524093);class o extends Error{constructor(e,t=n.Unknown,r,s,i){super(function(e,t){return e.length?`[${a(t)}] ${e}`:`[${a(t)}]`}(e,t)),this.name="ConnectError",Object.setPrototypeOf(this,new.target.prototype),this.rawMessage=e,this.code=t,this.metadata=new Headers(null!=r?r:{}),this.details=null!=s?s:[],this.cause=i}static from(e,t=n.Unknown){return e instanceof o?e:e instanceof Error?"AbortError"==e.name||"TimeoutError"==e.name?new o(e.message,n.Canceled):new o(e.message,t,void 0,void 0,e):new o(String(e),t,void 0,void 0,e)}static[Symbol.hasInstance](e){return e instanceof Error&&(Object.getPrototypeOf(e)===o.prototype||"ConnectError"===e.name&&"code"in e&&"number"==typeof e.code&&"metadata"in e&&"details"in e&&Array.isArray(e.details)&&"rawMessage"in e&&"string"==typeof e.rawMessage&&"cause"in e)}findDetails(e){let t="message"===e.kind?{getMessage:t=>t===e.typeName?e:void 0}:e,r=[];for(let e of this.details){if("desc"in e){t.getMessage(e.desc.typeName)&&r.push((0,s.create)(e.desc,e.value));continue}let n=t.getMessage(e.type);if(n)try{r.push((0,i.fromBinary)(n,e.value))}catch(e){}}return r}}e.s(["ConnectError",0,o],167937)},849156,e=>{"use strict";var t=e.i(424407),r=e.i(304532),n=e.i(81027);let s=(0,t.fileDesc)("Ch5nb29nbGUvcnBjL2Vycm9yX2RldGFpbHMucHJvdG8SCmdvb2dsZS5ycGMikwEKCUVycm9ySW5mbxIOCgZyZWFzb24YASABKAkSDgoGZG9tYWluGAIgASgJEjUKCG1ldGFkYXRhGAMgAygLMiMuZ29vZ2xlLnJwYy5FcnJvckluZm8uTWV0YWRhdGFFbnRyeRovCg1NZXRhZGF0YUVudHJ5EgsKA2tleRgBIAEoCRINCgV2YWx1ZRgCIAEoCToCOAEiOwoJUmV0cnlJbmZvEi4KC3JldHJ5X2RlbGF5GAEgASgLMhkuZ29vZ2xlLnByb3RvYnVmLkR1cmF0aW9uIjIKCURlYnVnSW5mbxIVCg1zdGFja19lbnRyaWVzGAEgAygJEg4KBmRldGFpbBgCIAEoCSKPAwoMUXVvdGFGYWlsdXJlEjYKCnZpb2xhdGlvbnMYASADKAsyIi5nb29nbGUucnBjLlF1b3RhRmFpbHVyZS5WaW9sYXRpb24axgIKCVZpb2xhdGlvbhIPCgdzdWJqZWN0GAEgASgJEhMKC2Rlc2NyaXB0aW9uGAIgASgJEhMKC2FwaV9zZXJ2aWNlGAMgASgJEhQKDHF1b3RhX21ldHJpYxgEIAEoCRIQCghxdW90YV9pZBgFIAEoCRJRChBxdW90YV9kaW1lbnNpb25zGAYgAygLMjcuZ29vZ2xlLnJwYy5RdW90YUZhaWx1cmUuVmlvbGF0aW9uLlF1b3RhRGltZW5zaW9uc0VudHJ5EhMKC3F1b3RhX3ZhbHVlGAcgASgDEh8KEmZ1dHVyZV9xdW90YV92YWx1ZRgIIAEoA0gAiAEBGjYKFFF1b3RhRGltZW5zaW9uc0VudHJ5EgsKA2tleRgBIAEoCRINCgV2YWx1ZRgCIAEoCToCOAFCFQoTX2Z1dHVyZV9xdW90YV92YWx1ZSKVAQoTUHJlY29uZGl0aW9uRmFpbHVyZRI9Cgp2aW9sYXRpb25zGAEgAygLMikuZ29vZ2xlLnJwYy5QcmVjb25kaXRpb25GYWlsdXJlLlZpb2xhdGlvbho/CglWaW9sYXRpb24SDAoEdHlwZRgBIAEoCRIPCgdzdWJqZWN0GAIgASgJEhMKC2Rlc2NyaXB0aW9uGAMgASgJIswBCgpCYWRSZXF1ZXN0Ej8KEGZpZWxkX3Zpb2xhdGlvbnMYASADKAsyJS5nb29nbGUucnBjLkJhZFJlcXVlc3QuRmllbGRWaW9sYXRpb24afQoORmllbGRWaW9sYXRpb24SDQoFZmllbGQYASABKAkSEwoLZGVzY3JpcHRpb24YAiABKAkSDgoGcmVhc29uGAMgASgJEjcKEWxvY2FsaXplZF9tZXNzYWdlGAQgASgLMhwuZ29vZ2xlLnJwYy5Mb2NhbGl6ZWRNZXNzYWdlIjcKC1JlcXVlc3RJbmZvEhIKCnJlcXVlc3RfaWQYASABKAkSFAoMc2VydmluZ19kYXRhGAIgASgJImAKDFJlc291cmNlSW5mbxIVCg1yZXNvdXJjZV90eXBlGAEgASgJEhUKDXJlc291cmNlX25hbWUYAiABKAkSDQoFb3duZXIYAyABKAkSEwoLZGVzY3JpcHRpb24YBCABKAkiVgoESGVscBIkCgVsaW5rcxgBIAMoCzIVLmdvb2dsZS5ycGMuSGVscC5MaW5rGigKBExpbmsSEwoLZGVzY3JpcHRpb24YASABKAkSCwoDdXJsGAIgASgJIjMKEExvY2FsaXplZE1lc3NhZ2USDgoGbG9jYWxlGAEgASgJEg8KB21lc3NhZ2UYAiABKAlCbAoOY29tLmdvb2dsZS5ycGNCEUVycm9yRGV0YWlsc1Byb3RvUAFaP2dvb2dsZS5nb2xhbmcub3JnL2dlbnByb3RvL2dvb2dsZWFwaXMvcnBjL2VycmRldGFpbHM7ZXJyZGV0YWlsc6ICA1JQQ2IGcHJvdG8z",[n.file_google_protobuf_duration]),i=(0,r.messageDesc)(s,0);e.s(["ErrorInfoSchema",0,i])},910304,e=>{"use strict";var t=e.i(167937),r=e.i(939910);let n={[r.Code.NotFound]:"not-found",[r.Code.PermissionDenied]:"permission-denied",[r.Code.Unauthenticated]:"unauthenticated",[r.Code.InvalidArgument]:"invalid-argument",[r.Code.AlreadyExists]:"already-exists",[r.Code.ResourceExhausted]:"resource-exhausted",[r.Code.FailedPrecondition]:"failed-precondition",[r.Code.Internal]:"internal",[r.Code.Unavailable]:"unavailable",[r.Code.Canceled]:"cancelled"};class s extends Error{code;connectCode;constructor(e,t,r,n){super(t,n),this.name="StigmerError",this.code=e,this.connectCode=r}}e.s(["StigmerError",0,s,"isNotFound",0,function(e){return e instanceof s&&"not-found"===e.code},"isPermissionDenied",0,function(e){return e instanceof s&&"permission-denied"===e.code},"isUnimplemented",0,function(e){return e instanceof s&&e.connectCode===r.Code.Unimplemented},"wrapError",0,function(e){return e instanceof t.ConnectError?new s(n[e.code]??"unknown",e.rawMessage||e.message,e.code,{cause:e}):e instanceof s?e:e instanceof Error?new s("unknown",e.message,r.Code.Unknown,{cause:e}):new s("unknown",String(e),r.Code.Unknown)}])},610595,e=>{"use strict";var t=e.i(167937),r=e.i(939910),n=e.i(849156),s=e.i(910304);let i={[r.Code.Unauthenticated]:"auth",[r.Code.PermissionDenied]:"permission",[r.Code.NotFound]:"not-found",[r.Code.InvalidArgument]:"validation",[r.Code.FailedPrecondition]:"validation",[r.Code.OutOfRange]:"validation",[r.Code.AlreadyExists]:"validation",[r.Code.Aborted]:"validation",[r.Code.Internal]:"server",[r.Code.Unknown]:"server",[r.Code.DataLoss]:"server",[r.Code.Unimplemented]:"server",[r.Code.Unavailable]:"unavailable",[r.Code.DeadlineExceeded]:"unavailable",[r.Code.ResourceExhausted]:"unavailable",[r.Code.Canceled]:"cancelled"},a={unauthenticated:"auth","permission-denied":"permission","not-found":"not-found","invalid-argument":"validation","already-exists":"validation","failed-precondition":"validation","resource-exhausted":"unavailable",internal:"server",unavailable:"unavailable",cancelled:"cancelled",unknown:"server"};function o(e){return e instanceof t.ConnectError}function l(e){return e instanceof s.StigmerError?a[e.code]??"unknown":o(e)?i[e.code]??"unknown":"unknown"}let c=new Set(["server","unavailable"]);function u(e){return c.has(l(e))}let d={auth:"Your session has expired. Please sign in again.",permission:"You do not have permission to perform this action.","not-found":"The requested resource was not found.",validation:"The request contains invalid data.",server:"An unexpected server error occurred. Please try again.",unavailable:"The server is temporarily unavailable. Please try again in a moment.",cancelled:"The request was cancelled.",unknown:"An unexpected error occurred."},g=[[/token audience does not match/i,"The token's audience does not match the IdentityProvider's expected_audience. Verify your Auth0 API identifier matches the expected_audience configured in Stigmer."],[/token signature verification failed/i,"Token signature verification failed. Check that the IdentityProvider's jwks_uri points to the correct JWKS endpoint."],[/token has expired/i,"The access token has expired. Request a new token and retry."],[/federated identity account not found/i,"No identity account exists for this user. The platform must create a federated account via createFederatedAccount before the user can authenticate."],[/account provisioning failed/i,"SSO account provisioning failed. Ensure the IdentityProvider's userinfo_endpoint is configured and the access token includes the 'openid email profile' scopes."]],h=[[/no healthy upstream/i,"The server is temporarily unavailable."],[/ECONNREFUSED/i,"Unable to connect to the server."],[/ECONNRESET/i,"The connection to the server was lost."],[/ETIMEDOUT/i,"The request timed out. Please try again."],[/fetch failed/i,"Unable to reach the server. Check your connection."],[/network error/i,"A network error occurred. Check your connection."],[/failed to fetch/i,"Unable to reach the server. Check your connection."],[/load failed/i,"The connection to the server was lost."],[/load balancer/i,"The server is temporarily unavailable."],[/illegal invocation/i,"A browser API call failed. Please try again."],[/can only call .+ on instances of/i,"A browser API call failed. Please try again."]];function m(e){return e instanceof s.StigmerError?e.message:o(e)?e.rawMessage:e instanceof Error?e.message:"string"==typeof e?e:""}let f=new WeakMap;e.s(["annotateRpcError",0,function(e,t){f.set(e,t)},"classifyError",0,l,"getErrorReason",0,function(e){let t=e;for(;null!=t;){if(o(t)){let e=t.findDetails(n.ErrorInfoSchema)[0];if(!e)return null;return{reason:e.reason,domain:e.domain,metadata:{...e.metadata}}}t=t instanceof Error?t.cause:void 0}return null},"getRpcMetadata",0,function(e){if(null!==e&&"object"==typeof e)return f.get(e)},"getUserMessage",0,function(e,t){let r=function(e){if(!e)return"";for(let[t,r]of g)if(t.test(e))return r;for(let[t,r]of h)if(t.test(e))return r;return e}(m(e));if(r)return r;let n=l(e);return t??d[n]},"isRetryableError",0,u,"isTransientStreamError",0,function(e){return!!u(e)||function(e){if(!e)return!1;for(let[t]of h)if(t.test(e))return!0;return!1}(m(e))}])},379410,e=>{"use strict";var t=e.i(843476),r=e.i(893976);e.s(["SpinnerIcon",0,function({size:e=16,className:n}={}){return(0,t.jsx)("svg",{width:e,height:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:(0,r.cn)("stg:animate-spin",n),"aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}])},17616,e=>{"use strict";var t=e.i(732303),r=e.i(891287),n=e.i(314511);function s(e){return i(e.getTime())}function i(e){let s=Math.floor(e/1e3);return(0,r.create)(t.TimestampSchema,{seconds:n.protoInt64.parse(s),nanos:(e-1e3*s)*1e6})}e.s(["timestampDate",0,function(e){var t;return new Date(1e3*Number((t=e).seconds)+Math.round(t.nanos/1e6))},"timestampFromDate",0,s,"timestampFromMs",0,i,"timestampNow",0,function(){return s(new Date)}])},193799,e=>{"use strict";var t=e.i(271645);e.s(["useCopyFeedback",0,function(){let[e,r]=(0,t.useState)(!1),n=(0,t.useRef)(null);(0,t.useEffect)(()=>()=>{null!==n.current&&clearTimeout(n.current)},[]);let s=(0,t.useCallback)(async e=>{try{await navigator.clipboard.writeText(e)}catch{return!1}return r(!0),null!==n.current&&clearTimeout(n.current),n.current=setTimeout(()=>r(!1),2e3),!0},[]);return(0,t.useMemo)(()=>({copy:s,copied:e}),[s,e])}])},102508,e=>{"use strict";let t,r;var n=e.i(843476);e.i(247167);var s=e.i(271645),i=e.i(991730),a=e.i(327601);let o=s.forwardRef(function(e,t){let{render:r,className:n,disabled:s=!1,focusableWhenDisabled:o=!1,nativeButton:l=!0,...c}=e,{getButtonProps:u,buttonRef:d}=(0,i.useButton)({disabled:s,focusableWhenDisabled:o,native:l});return(0,a.useRenderElement)("button",e,{state:{disabled:s},ref:[t,d],props:[c,u]})});var l=e.i(207670);let c=e=>"boolean"==typeof e?`${e}`:0===e?"0":e,u=l.clsx;var d=e.i(893976);let g=(t="group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",r={variants:{variant:{default:"bg-primary text-primary-foreground [a]:hover:bg-primary-hover",outline:"border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",ghost:"hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted-subtle",destructive:"bg-destructive-subtle text-destructive hover:bg-accent hover:text-destructive focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:hover:bg-accent dark:focus-visible:ring-destructive/40",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",xs:"h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",lg:"h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-3 has-data-[icon=inline-start]:pl-3",icon:"size-8","icon-xs":"size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg","icon-lg":"size-9"}},defaultVariants:{variant:"default",size:"default"}},e=>{var n;if((null==r?void 0:r.variants)==null)return u(t,null==e?void 0:e.class,null==e?void 0:e.className);let{variants:s,defaultVariants:i}=r,a=Object.keys(s).map(t=>{let r=null==e?void 0:e[t],n=null==i?void 0:i[t];if(null===r)return null;let a=c(r)||c(n);return s[t][a]}),o=e&&Object.entries(e).reduce((e,t)=>{let[r,n]=t;return void 0===n||(e[r]=n),e},{});return u(t,a,null==r||null==(n=r.compoundVariants)?void 0:n.reduce((e,t)=>{let{class:r,className:n,...s}=t;return Object.entries(s).every(e=>{let[t,r]=e;return Array.isArray(r)?r.includes({...i,...o}[t]):({...i,...o})[t]===r})?[...e,r,n]:e},[]),null==e?void 0:e.class,null==e?void 0:e.className)});e.s(["Button",0,function({className:e,variant:t="default",size:r="default",...s}){return(0,n.jsx)(o,{"data-slot":"button",className:(0,d.cn)(g({variant:t,size:r,className:e})),...s})}],102508)},254450,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(893976),s=e.i(188482);let i=[{value:"org",label:"Org",ariaLabel:"Organization only",icon:function({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("rect",{x:"4",y:"2",width:"8",height:"12",rx:"1"}),(0,t.jsx)("path",{d:"M6.5 5h3M6.5 8h3M6.5 11h3"})]})}},{value:"all",label:"All",ariaLabel:"All including public",icon:function({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("circle",{cx:"8",cy:"8",r:"6"}),(0,t.jsx)("path",{d:"M2 8h12"}),(0,t.jsx)("path",{d:"M8 2c1.66 1.46 2.6 3.63 2.6 6s-.94 4.54-2.6 6c-1.66-1.46-2.6-3.63-2.6-6s.94-4.54 2.6-6Z"})]})}}];e.s(["ScopeToggle",0,function({value:e,onChange:a,disabled:o=!1,className:l,compact:c=!1}){let u=(0,r.useRef)([]),d=(0,r.useCallback)(t=>{t!==e&&a(t)},[e,a]),g=(0,r.useCallback)((e,t)=>{let r=null;"ArrowRight"===e.key||"ArrowDown"===e.key?(e.preventDefault(),r=(t+1)%i.length):("ArrowLeft"===e.key||"ArrowUp"===e.key)&&(e.preventDefault(),r=(t-1+i.length)%i.length),null!==r&&(u.current[r]?.focus(),d(i[r].value))},[d]);return(0,t.jsx)("div",{role:"radiogroup","aria-label":"Resource scope","aria-disabled":o||void 0,className:(0,n.cn)("stg:inline-flex stg:rounded-md stg:bg-muted stg:p-0.5",o&&"stg:pointer-events-none stg:opacity-50",l),children:i.map((r,i)=>{let a=e===r.value,l=r.icon,h=(0,t.jsxs)("button",{ref:e=>{u.current[i]=e},type:"button",role:"radio","aria-checked":a,"aria-label":r.ariaLabel,tabIndex:a?0:-1,disabled:o,onClick:()=>d(r.value),onKeyDown:e=>g(e,i),className:(0,n.cn)("stg:inline-flex stg:cursor-pointer stg:items-center stg:gap-1 stg:rounded-sm stg:px-2 stg:py-1 stg:text-xs stg:font-medium stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",a?"stg:bg-background stg:text-foreground stg:shadow-sm":"stg:text-muted-foreground stg:hover:text-foreground"),children:[(0,t.jsx)(l,{className:"stg:size-3"}),!c&&r.label]},r.value);return c?(0,t.jsxs)(s.Tooltip,{children:[(0,t.jsx)(s.TooltipTrigger,{render:h}),(0,t.jsx)(s.TooltipContent,{side:"top",children:r.ariaLabel})]},r.value):h})})}])},195057,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={formatUrl:function(){return o},formatWithValidation:function(){return c},urlObjectKeys:function(){return l}};for(var s in n)Object.defineProperty(r,s,{enumerable:!0,get:n[s]});let i=e.r(190809)._(e.r(998183)),a=/https?|ftp|gopher|file/;function o(e){let{auth:t,hostname:r}=e,n=e.protocol||"",s=e.pathname||"",o=e.hash||"",l=e.query||"",c=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?c=t+e.host:r&&(c=t+(~r.indexOf(":")?`[${r}]`:r),e.port&&(c+=":"+e.port)),l&&"object"==typeof l&&(l=String(i.urlQueryToSearchParams(l)));let u=e.search||l&&`?${l}`||"";return n&&!n.endsWith(":")&&(n+=":"),e.slashes||(!n||a.test(n))&&!1!==c?(c="//"+(c||""),s&&"/"!==s[0]&&(s="/"+s)):c||(c=""),o&&"#"!==o[0]&&(o="#"+o),u&&"?"!==u[0]&&(u="?"+u),s=s.replace(/[?#]/g,encodeURIComponent),u=u.replace("#","%23"),`${n}${c}${s}${u}${o}`}let l=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function c(e){return o(e)}},818581,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"useMergedRef",{enumerable:!0,get:function(){return s}});let n=e.r(271645);function s(e,t){let r=(0,n.useRef)(null),s=(0,n.useRef)(null);return(0,n.useCallback)(n=>{if(null===n){let e=r.current;e&&(r.current=null,e());let t=s.current;t&&(s.current=null,t())}else e&&(r.current=i(e,n)),t&&(s.current=i(t,n))},[e,t])}function i(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let r=e(t);return"function"==typeof r?r:()=>e(null)}}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},573668,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"isLocalURL",{enumerable:!0,get:function(){return i}});let n=e.r(718967),s=e.r(652817);function i(e){if(!(0,n.isAbsoluteUrl)(e))return!0;try{let t=(0,n.getLocationOrigin)(),r=new URL(e,t);return r.origin===t&&(0,s.hasBasePath)(r.pathname)}catch(e){return!1}}},284508,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"errorOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},522016,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={default:function(){return b},useLinkStatus:function(){return x}};for(var s in n)Object.defineProperty(r,s,{enumerable:!0,get:n[s]});let i=e.r(190809),a=e.r(843476),o=i._(e.r(271645)),l=e.r(195057),c=e.r(8372),u=e.r(818581),d=e.r(718967),g=e.r(405550);e.r(233525);let h=e.r(388540),m=e.r(91949),f=e.r(573668),p=e.r(509396);function b(t){var r,n;let s,i,b,[x,y]=(0,o.useOptimistic)(m.IDLE_LINK_STATUS),k=(0,o.useRef)(null),{href:A,as:w,children:E,prefetch:S=null,passHref:C,replace:j,shallow:R,scroll:W,onClick:M,onMouseEnter:N,onTouchStart:I,legacyBehavior:_=!1,onNavigate:Z,transitionTypes:G,ref:V,unstable_dynamicOnHover:L,...Y}=t;s=E,_&&("string"==typeof s||"number"==typeof s)&&(s=(0,a.jsx)("a",{children:s}));let F=o.default.useContext(c.AppRouterContext),B=!1!==S,T=!1!==S?null===(n=S)||"auto"===n?p.FetchStrategy.PPR:p.FetchStrategy.Full:p.FetchStrategy.PPR,X="string"==typeof(r=w||A)?r:(0,l.formatUrl)(r);if(_){if(s?.$$typeof===Symbol.for("react.lazy"))throw Object.defineProperty(Error("`<Link legacyBehavior>` received a direct child that is either a Server Component, or JSX that was loaded with React.lazy(). This is not supported. Either remove legacyBehavior, or make the direct child a Client Component that renders the Link's `<a>` tag."),"__NEXT_ERROR_CODE",{value:"E863",enumerable:!1,configurable:!0});i=o.default.Children.only(s)}let D=_?i&&"object"==typeof i&&i.ref:V,O=o.default.useCallback(e=>(null!==F&&(k.current=(0,m.mountLinkInstance)(e,X,F,T,B,y)),()=>{k.current&&((0,m.unmountLinkForCurrentNavigation)(k.current),k.current=null),(0,m.unmountPrefetchableInstance)(e)}),[B,X,F,T,y]),K={ref:(0,u.useMergedRef)(O,D),onClick(t){_||"function"!=typeof M||M(t),_&&i.props&&"function"==typeof i.props.onClick&&i.props.onClick(t),!F||t.defaultPrevented||function(t,r,n,s,i,a,l){if("u">typeof window){let c,{nodeName:u}=t.currentTarget;if("A"===u.toUpperCase()&&((c=t.currentTarget.getAttribute("target"))&&"_self"!==c||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.nativeEvent&&2===t.nativeEvent.which)||t.currentTarget.hasAttribute("download"))return;if(!(0,f.isLocalURL)(r)){s&&(t.preventDefault(),location.replace(r));return}if(t.preventDefault(),a){let e=!1;if(a({preventDefault:()=>{e=!0}}),e)return}let{dispatchNavigateAction:d}=e.r(699781);o.default.startTransition(()=>{d(r,s?"replace":"push",!1===i?h.ScrollBehavior.NoScroll:h.ScrollBehavior.Default,n.current,l)})}}(t,X,k,j,W,Z,G)},onMouseEnter(e){_||"function"!=typeof N||N(e),_&&i.props&&"function"==typeof i.props.onMouseEnter&&i.props.onMouseEnter(e),F&&B&&(0,m.onNavigationIntent)(e.currentTarget,!0===L)},onTouchStart:function(e){_||"function"!=typeof I||I(e),_&&i.props&&"function"==typeof i.props.onTouchStart&&i.props.onTouchStart(e),F&&B&&(0,m.onNavigationIntent)(e.currentTarget,!0===L)}};return(0,d.isAbsoluteUrl)(X)?K.href=X:_&&!C&&("a"!==i.type||"href"in i.props)||(K.href=(0,g.addBasePath)(X)),b=_?o.default.cloneElement(i,K):(0,a.jsx)("a",{...Y,...K,children:s}),(0,a.jsx)(v.Provider,{value:x,children:b})}e.r(284508);let v=(0,o.createContext)(m.IDLE_LINK_STATUS),x=()=>(0,o.useContext)(v);("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},107233,e=>{"use strict";let t=(0,e.i(475254).default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",0,t],107233)},174886,e=>{"use strict";let t=(0,e.i(475254).default)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);e.s(["Copy",0,t],174886)},348990,e=>{"use strict";var t=e.i(271645),r=e.i(891287),n=e.i(95265),s=e.i(586108),i=e.i(583093);e.s(["useEnvironmentList",0,function(e,a){let o=(0,s.useStigmer)(),l=(0,t.useRef)(a);a!==l.current&&JSON.stringify(a)!==JSON.stringify(l.current)&&(l.current=a);let c=l.current,u=e?async()=>{let t=await o.environment.list((0,r.create)(n.ListEnvironmentsRequestSchema,{org:e,labels:c??{}}));return{environments:t.items,totalCount:t.totalCount}}:null,{data:d,isLoading:g,isRefetching:h,error:m,refetch:f}=(0,i.useFetch)(u,[e,c,o],{environments:[],totalCount:0});return{environments:d.environments,totalCount:d.totalCount,isLoading:g,isRefetching:h,error:m,refetch:f}}])},367539,e=>{"use strict";e.s(["generateSlug",0,function(e){return e.toLowerCase().replace(/[ .]/g,"-").replace(/[^a-z0-9-]/g,"").replace(/-{2,}/g,"-").replace(/^-+|-+$/g,"")},"generateSlugSuffix",0,function(){return crypto.randomUUID().replace(/-/g,"").slice(0,8)}])},207344,e=>{"use strict";var t=e.i(271645),r=e.i(891287),n=e.i(95265),s=e.i(621559),i=e.i(586108),a=e.i(367539),o=e.i(326283),l=e.i(348990);let c={"stigmer.ai/personal":"true"};e.s(["usePersonalEnvironment",0,function(e){let u=(0,i.useStigmer)(),{environments:d,isLoading:g,error:h,refetch:m}=(0,l.useEnvironmentList)(e,c),f=(0,t.useMemo)(()=>d[0]??null,[d]),[p,b]=(0,t.useState)(!1),[v,x]=(0,t.useState)(null),y=(0,t.useRef)(f);y.current=f;let k=(0,t.useRef)(g);k.current=g;let A=(0,t.useCallback)(async t=>{if(y.current)return y.current;if(!e)throw Error("usePersonalEnvironment: cannot call getOrCreate when org is null.");if(k.current)throw Error("usePersonalEnvironment: cannot call getOrCreate while the environment list is loading. Wait for isLoading to become false before calling getOrCreate().");b(!0),x(null);try{let r;t&&Object.keys(t).length>0&&(r=t);let n=await u.environment.create({name:"Personal Environment",slug:`env-personal-${(0,a.generateSlugSuffix)()}`,org:e,labels:c,data:r});return y.current=n,m(),n}catch(e){throw x((0,o.toError)(e)),e}finally{b(!1)}},[e,u,m]),w=(0,t.useCallback)(async e=>{let t=y.current;if(!t)throw Error("usePersonalEnvironment: personal environment does not exist. Call getOrCreate() before addVariables().");b(!0),x(null);try{let i=Object.fromEntries(Object.entries(e).map(([e,t])=>[e,(0,r.create)(s.EnvironmentValueSchema,{value:t.value,isSecret:t.isSecret,description:t.description})])),a=(0,r.create)(n.UpdateEnvironmentVariablesRequestSchema,{environmentId:t.metadata.id,variables:i}),o=await u.environment.updateVariables(a);return m(),o}catch(e){throw x((0,o.toError)(e)),e}finally{b(!1)}},[u,m]),E=(0,t.useCallback)(async e=>{let t=y.current;if(!t)throw Error("usePersonalEnvironment: personal environment does not exist. Call getOrCreate() before removeVariables().");b(!0),x(null);try{let s=(0,r.create)(n.RemoveEnvironmentVariablesRequestSchema,{environmentId:t.metadata.id,keys:e}),i=await u.environment.removeVariables(s);return m(),i}catch(e){throw x((0,o.toError)(e)),e}finally{b(!1)}},[u,m]);return{environment:f,isLoading:g,error:v??h,refetch:m,getOrCreate:A,addVariables:w,removeVariables:E,isMutating:p}}])},903198,e=>{"use strict";let t="stigmer:oauth:callback",r="stigmer:oauth:broadcast";function n(e){try{e?.close()}catch{}}e.s(["OAUTH_BROADCAST_CHANNEL",0,r,"OAUTH_CALLBACK_MESSAGE_TYPE",0,t,"closeOAuthPopup",0,n,"openOAuthPopup",0,function(){let e=window.screenX+(window.outerWidth-600)/2,t=window.screenY+(window.outerHeight-700)/2;return window.open("about:blank","stigmer_oauth",`width=600,height=700,left=${e},top=${t},popup=yes`)},"popupBlockedError",0,function(){return Error("Your browser blocked the authentication popup. Please allow popups for this site and try again.")},"waitForOAuthCallback",0,function(e,s,i){return new Promise((a,o)=>{let l,c,u=!1,d=null,g=!1;function h(e){if(!u){u=!0,l&&clearTimeout(l),c&&clearInterval(c),window.removeEventListener("message",f);try{d?.close()}catch{}e instanceof Error?o(e):a(e)}}function m(e){if(e?.type===t){if(e.state!==s)return void h(Error("OAuth state mismatch — the callback did not match the initiated flow. Please try again."));if(!e.code)return void h(Error("No authorization code received from the OAuth provider."));h({code:e.code,state:e.state})}}function f(e){e.origin===window.location.origin&&m(e.data)}i(()=>{h(Error("OAuth flow was cancelled.")),n(e)}),window.addEventListener("message",f);try{d=new BroadcastChannel(r),g=!0,d.onmessage=e=>{m(e.data)}}catch{}l=setTimeout(()=>{h(Error("OAuth authentication timed out. Ensure your callback page renders <OAuthCallbackHandler /> from @stigmer/react at the URL configured as your OAuth redirect URI.")),n(e)},12e4);let p=null;c=setInterval(()=>{!g&&(e.closed?null===p?p=Date.now():Date.now()-p>5e3&&h(Error("The authentication window was closed before completing sign-in.")):p=null)},500)})}])},230849,4144,e=>{"use strict";var t=e.i(271645);e.s(["useScrollShadows",0,function(){let e=(0,t.useRef)(null),[r,n]=(0,t.useState)(!1),[s,i]=(0,t.useState)(!1),a=(0,t.useCallback)(()=>{let t=e.current;t&&(n(t.scrollTop>0),i(t.scrollTop+t.clientHeight<t.scrollHeight-1))},[]);return(0,t.useEffect)(()=>{let t=e.current;if(!t)return;t.addEventListener("scroll",a,{passive:!0});let r=new ResizeObserver(a);return r.observe(t),a(),()=>{t.removeEventListener("scroll",a),r.disconnect()}},[a]),{scrollRef:e,canScrollUp:r,canScrollDown:s}}],230849);var r=e.i(843476);e.s(["ScrollFade",0,function({position:e}){let t="top"===e;return(0,r.jsx)("div",{className:["stg:pointer-events-none stg:absolute stg:inset-x-0 stg:z-10 stg:h-3",t?"stg:top-0":"stg:bottom-0"].join(" "),style:{background:t?"linear-gradient(to bottom, var(--color-popover, hsl(0 0% 9%)), transparent)":"linear-gradient(to top, var(--color-popover, hsl(0 0% 9%)), transparent)"},"aria-hidden":"true"})}],4144)},351240,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(893976),s=e.i(230849),i=e.i(4144),a=e.i(379410);function o(){return(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M1.5 8s2.5-4.5 6.5-4.5S14.5 8 14.5 8s-2.5 4.5-6.5 4.5S1.5 8 1.5 8z"}),(0,t.jsx)("circle",{cx:"8",cy:"8",r:"2"})]})}function l(){return(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M6.59 6.59a2 2 0 0 0 2.82 2.82"}),(0,t.jsx)("path",{d:"M10.73 10.73A6.5 6.5 0 0 1 8 12.5c-4 0-6.5-4.5-6.5-4.5a11.5 11.5 0 0 1 3.77-3.73"}),(0,t.jsx)("path",{d:"M5.71 3.56A6.3 6.3 0 0 1 8 3.5c4 0 6.5 4.5 6.5 4.5a11.5 11.5 0 0 1-1.28 1.73"}),(0,t.jsx)("path",{d:"M2 2l12 12"})]})}e.s(["EnvVarForm",0,function({variables:e,onSubmit:c,onCancel:u,isSubmitting:d,disabled:g,title:h,description:m,submitLabel:f,cancelLabel:p="Back",defaultSaveForFuture:b=!0,hideSaveToggle:v=!1,poolValues:x,className:y,ariaLabel:k}){let[A,w]=(0,r.useState)(()=>Object.fromEntries(e.map(e=>{let t=x?.(e.key);return[e.key,t?.value??""]}))),[E]=(0,r.useState)(()=>{if(!x)return new Set;let t=new Set;for(let r of e)x(r.key)&&t.add(r.key);return t}),[S,C]=(0,r.useState)(new Set),[j,R]=(0,r.useState)(b),W=(0,r.useRef)(null),M=(0,s.useScrollShadows)(),N=(0,r.useId)(),I=`${N}-save-toggle`,_=g||d,Z=e.every(e=>A[e.key]?.trim()!==""),G=(0,r.useCallback)((e,t)=>{w(r=>({...r,[e]:t}))},[]),V=(0,r.useCallback)(e=>{C(t=>{let r=new Set(t);return r.has(e)?r.delete(e):r.add(e),r})},[]),L=(0,r.useCallback)(t=>{if(t.preventDefault(),!Z||_)return;let r={};for(let t of e)r[t.key]={value:A[t.key],isSecret:t.isSecret,...t.description&&{description:t.description}};c(r,{saveForFuture:j})},[Z,_,A,e,c,j]),Y=k??(h?`Configure ${h}`:"Configure environment variables"),F=f??(j?"Save":"Use once");return(0,t.jsxs)("form",{onSubmit:L,className:(0,n.cn)("stg:w-72 stg:space-y-3",y),"aria-label":Y,children:[h&&(0,t.jsxs)("div",{className:"stg:space-y-0.5",children:[(0,t.jsx)("h3",{className:"stg:text-xs stg:font-medium stg:text-foreground",children:h}),m&&(0,t.jsx)("p",{className:"stg:text-[0.65rem] stg:text-muted-foreground",children:m})]}),(0,t.jsxs)("div",{className:"stg:relative",children:[M.canScrollUp&&(0,t.jsx)(i.ScrollFade,{position:"top"}),(0,t.jsx)("div",{ref:M.scrollRef,className:"stg:max-h-64 stg:space-y-2.5 stg:overflow-y-auto",children:e.map((e,r)=>{let s=`${N}-env-${e.key}`,i=e.description?`${s}-desc`:void 0,a=S.has(e.key);return(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsxs)("label",{htmlFor:s,className:"stg:flex stg:items-baseline stg:gap-1.5 stg:text-[0.65rem] stg:font-medium stg:text-muted-foreground",children:[(0,t.jsx)("span",{className:"stg:font-mono",children:e.key}),e.isSecret&&(0,t.jsx)("span",{className:"stg:text-[0.55rem] stg:uppercase stg:tracking-wider stg:text-muted-foreground-subtle",children:"secret"})]}),(0,t.jsxs)("div",{className:"stg:relative",children:[(0,t.jsx)("input",{ref:0===r?W:void 0,id:s,type:e.isSecret&&!a?"password":"text",value:A[e.key],onChange:t=>G(e.key,t.target.value),disabled:_,required:!0,"aria-required":!0,"aria-describedby":i,autoComplete:"off",autoFocus:0===r,className:(0,n.cn)("stg:w-full stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:placeholder:text-muted-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50",e.isSecret&&"stg:pr-8")}),e.isSecret&&(0,t.jsx)("button",{type:"button",onClick:()=>V(e.key),disabled:_,className:(0,n.cn)("stg:absolute stg:right-2 stg:top-1/2 stg:-translate-y-1/2","stg:text-muted-foreground stg:hover:text-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-50"),"aria-label":a?`Hide ${e.key}`:`Show ${e.key}`,tabIndex:-1,children:a?(0,t.jsx)(l,{}):(0,t.jsx)(o,{})})]}),e.description&&(0,t.jsx)("p",{id:i,className:"stg:text-[0.6rem] stg:leading-relaxed stg:text-muted-foreground-subtle",children:e.description}),E.has(e.key)&&(0,t.jsx)("p",{className:"stg:text-[0.55rem] stg:text-primary-muted",children:"Pre-filled from session variables"})]},e.key)})}),M.canScrollDown&&(0,t.jsx)(i.ScrollFade,{position:"bottom"})]}),!v&&(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-2 stg:pt-0.5",children:[(0,t.jsx)("button",{id:I,type:"button",role:"switch","aria-checked":j,onClick:()=>R(e=>!e),disabled:_,className:(0,n.cn)("stg:relative stg:mt-0.5 stg:inline-flex stg:h-4 stg:w-7 stg:shrink-0 stg:cursor-pointer stg:rounded-full stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-offset-2","stg:disabled:pointer-events-none stg:disabled:opacity-50",j?"stg:bg-primary":"stg:bg-input"),children:(0,t.jsx)("span",{className:(0,n.cn)("stg:pointer-events-none stg:block stg:h-3 stg:w-3 stg:translate-y-0.5 stg:rounded-full stg:bg-background stg:shadow-sm stg:ring-0 stg:transition-transform",j?"stg:translate-x-3.5":"stg:translate-x-0.5")})}),(0,t.jsxs)("label",{htmlFor:I,className:"stg:cursor-pointer stg:select-none stg:space-y-0.5",children:[(0,t.jsx)("span",{className:"stg:block stg:text-[0.65rem] stg:font-medium stg:text-muted-foreground",children:"Save for future runs"}),!j&&(0,t.jsx)("span",{className:"stg:block stg:text-[0.6rem] stg:leading-relaxed stg:text-muted-foreground-subtle",children:"These values will only be used for this run."})]})]}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-end stg:gap-2 stg:pt-1",children:[u&&(0,t.jsx)("button",{type:"button",onClick:u,disabled:_,className:(0,n.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs","stg:text-muted-foreground stg:hover:text-foreground stg:hover:bg-accent-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:p}),(0,t.jsxs)("button",{type:"submit",disabled:!Z||_,"data-cursor-target":"env-form-submit",className:(0,n.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium","stg:bg-primary stg:text-primary-foreground","stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-40"),children:[d&&(0,t.jsx)(a.SpinnerIcon,{size:12}),F]})]})]})}])},793907,e=>{"use strict";var t=e.i(843476),r=e.i(893976);function n({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M8 1.5 1 14h14L8 1.5Z"}),(0,t.jsx)("path",{d:"M8 6v3.5"}),(0,t.jsx)("circle",{cx:"8",cy:"11.5",r:"0.5",fill:"currentColor",stroke:"none"})]})}function s({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M12 8.667v4A1.333 1.333 0 0 1 10.667 14H3.333A1.333 1.333 0 0 1 2 12.667V5.333A1.333 1.333 0 0 1 3.333 4h4"}),(0,t.jsx)("path",{d:"M10 2h4v4"}),(0,t.jsx)("path",{d:"M6.667 9.333 14 2"})]})}e.s(["VendorApprovalBlockedNotice",0,function({blocked:e,pending:i,manualEntrySupported:a,canBringOwnApp:o,docsUrl:l,onBringOwnApp:c,compact:u,className:d}){if(!e)return null;let g=i?"The platform's OAuth app is awaiting vendor approval.":"The platform's OAuth app was not approved by the vendor.",h=o?a?"You can use your own OAuth app or enter a token manually.":"You can use your own OAuth app.":a?"You can still connect by entering your own token manually.":"OAuth sign-in is temporarily unavailable for this server.",m=o&&c,f=!!l&&!o;return u?(0,t.jsxs)("div",{className:(0,r.cn)("stg:text-[0.65rem] stg:text-amber-700 stg:dark:text-amber-300",d),children:[(0,t.jsxs)("p",{children:[g," ",h]}),m&&(0,t.jsx)("button",{type:"button",onClick:c,className:"stg:mt-1 stg:inline-flex stg:items-center stg:gap-1 stg:rounded stg:bg-amber-600 stg:px-2 stg:py-0.5 stg:text-[0.6rem] stg:font-medium stg:text-white stg:hover:bg-amber-700 stg:dark:bg-amber-500 stg:dark:text-amber-950 stg:dark:hover:bg-amber-400",children:"Use your own OAuth app"}),f&&(0,t.jsx)("a",{href:l??void 0,target:"_blank",rel:"noopener noreferrer",className:"stg:underline stg:decoration-amber-600/40 stg:underline-offset-2 stg:hover:decoration-amber-600 stg:dark:decoration-amber-400/40 stg:dark:hover:decoration-amber-400",children:"Learn how to bring your own token"})]}):(0,t.jsxs)("div",{role:"status",className:(0,r.cn)("stg:flex stg:items-start stg:gap-2 stg:bg-amber-500/5 stg:px-3 stg:py-2",d),children:[(0,t.jsx)(n,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-amber-600 stg:dark:text-amber-400"}),(0,t.jsxs)("div",{className:"stg:flex-1 stg:text-xs stg:text-amber-700 stg:dark:text-amber-300",children:[(0,t.jsxs)("p",{children:[g," ",h]}),m&&(0,t.jsx)("button",{type:"button",onClick:c,"data-cursor-target":"byoa-cta-button",className:"stg:mt-1.5 stg:inline-flex stg:items-center stg:gap-1 stg:rounded-md stg:bg-amber-600 stg:px-2.5 stg:py-1 stg:text-[11px] stg:font-medium stg:text-white stg:hover:bg-amber-700 stg:dark:bg-amber-500 stg:dark:text-amber-950 stg:dark:hover:bg-amber-400",children:"Use your own OAuth app"}),f&&(0,t.jsxs)("a",{href:l??void 0,target:"_blank",rel:"noopener noreferrer",className:"stg:mt-1 stg:inline-flex stg:items-center stg:gap-1 stg:underline stg:decoration-amber-600/40 stg:underline-offset-2 stg:hover:decoration-amber-600 stg:dark:decoration-amber-400/40 stg:dark:hover:decoration-amber-400",children:["Learn how to bring your own token",(0,t.jsx)(s,{className:"stg:size-3 stg:shrink-0"})]})]})]})}])},20883,e=>{"use strict";var t=e.i(939910),r=e.i(167937),n=e.i(498931),s=e.i(910304);class i extends Error{mcpServerId;constructor(e,t){super(`the connect of MCP server '${e}' is still running server-side after ${Math.round(t/1e3)}s — it will persist its result on its own; re-read the server to observe the outcome`),this.name="ConnectStillRunningError",this.mcpServerId=e}}async function a(e,a,l){let c,u=l?.pollIntervalMs??2500,d=Math.min(l?.deadlineMs??39e5,39e5);try{c=await e.startConnect(a)}catch(t){if(!(0,s.isUnimplemented)(t))throw t;return o(e,a,d)}l?.onStarted?.(c);let g=Date.now()+d;for(;;){if(Date.now()>=g)throw new i(a.mcpServerId,d);await function(e){return new Promise(t=>setTimeout(t,e))}(Math.min(u,Math.max(1,g-Date.now())));let o=await e.get(a.mcpServerId),l=o.status?.connectStatus;if(l?.phase===n.ConnectPhase.succeeded)return o;if(l?.phase===n.ConnectPhase.failed)throw function(e,n){let i=t.Code[e];return(0,s.wrapError)(new r.ConnectError(n,"number"==typeof i?i:t.Code.Unknown))}(l.failureCode,l.failureMessage)}}async function o(e,t,r){let n,s=e.connect(t);s.catch(()=>{});let a=new Promise((e,s)=>{n=setTimeout(()=>s(new i(t.mcpServerId,r)),r)});try{return await Promise.race([s,a])}finally{void 0!==n&&clearTimeout(n)}}e.s(["connectAndWait",0,a])},139666,e=>{"use strict";let t="STIGMER_SERVER_ADDRESS",r="STIGMER_API_KEY",n=new Set([t,r]);async function s(e){var n;let s=await e.getAuthCredential();return n=e.baseUrl,{[t]:{value:function(e){try{let t=new URL(e),r=t.hostname,n=t.port||("https:"===t.protocol?"443":"80");return`${r}:${n}`}catch{return e}}(n),isSecret:!1,description:"Auto-resolved from the current Stigmer connection."},[r]:{value:s||"unused",isSecret:!0,description:"Auto-resolved from the current Stigmer auth context."}}}async function i(e,t){let r=t instanceof Set?t:new Set(t);if(![...n].some(e=>r.has(e)))return{};let i=await s(e),a={};for(let[e,t]of Object.entries(i))r.has(e)&&(a[e]=t);return a}e.s(["SYSTEM_ENV_VAR_KEYS",0,n,"resolveDeclaredSystemEnvVars",0,i,"resolveSystemEnvVarValues",0,s])},168197,e=>{"use strict";var t=e.i(271645),r=e.i(891287),n=e.i(20883),s=e.i(610595),i=e.i(336973),a=e.i(586108),o=e.i(139666),l=e.i(326283),c=e.i(903198);e.s(["getOAuthConnectErrorMessage",0,function(e,t){let r=(0,s.getUserMessage)(e);return"connecting"===t?`Signed in successfully, but tool discovery failed: ${r}`:r},"useMcpServerOAuthConnect",0,function(){let e=(0,a.useStigmer)(),[s,u]=(0,t.useState)("idle"),[d,g]=(0,t.useState)(null),[h,m]=(0,t.useState)(null),f=(0,t.useRef)(null),p=(0,t.useRef)(null),b=(0,t.useRef)(!1),v=(0,t.useRef)("idle"),x=(0,t.useCallback)(e=>{v.current=e,u(e)},[]);(0,t.useEffect)(()=>()=>{p.current?.()},[]);let y=(0,t.useCallback)(()=>{(p.current||f.current)&&(b.current=!0,p.current?.(),(0,c.closeOAuthPopup)(f.current),f.current=null,p.current=null),x("idle"),g(null),m(null)},[x]);return{startOAuth:(0,t.useCallback)(async(t,s,a)=>{x("initiating"),g(null),m(null),b.current=!1,p.current?.();let u=(0,c.openOAuthPopup)();if(!u){let e=(0,c.popupBlockedError)();throw g(e),m("initiating"),x("idle"),e}f.current=u;try{let l=await e.mcpServer.initiateOAuthConnect((0,r.create)(i.InitiateOAuthConnectInputSchema,{mcpServerId:t,org:s}));u.location.href=l.authorizationUrl,x("awaiting-callback");let{code:d,state:g}=await (0,c.waitForOAuthCallback)(u,l.state,e=>{p.current=e});x("completing"),await e.mcpServer.completeOAuthConnect((0,r.create)(i.CompleteOAuthConnectInputSchema,{mcpServerId:t,authorizationCode:d,state:g})),x("connecting");let h=a?await (0,o.resolveDeclaredSystemEnvVars)(e,a):{},m={};for(let[e,t]of Object.entries(h))m[e]={value:t.value,isSecret:t.isSecret??!1};let f=(0,r.create)(i.ConnectInputSchema,{mcpServerId:t,org:s,...Object.keys(m).length>0?{runtimeEnv:m}:{}}),b=await (0,n.connectAndWait)(e.mcpServer,f);return x("done"),b}catch(t){let e=(0,l.toError)(t);throw b.current||(g(e),m(v.current),x("idle"),(0,c.closeOAuthPopup)(u)),b.current=!1,e}finally{f.current=null,p.current=null}},[e,x]),isInProgress:"idle"!==s&&"done"!==s,phase:s,error:d,failedPhase:h,clearError:y}}])},862645,e=>{"use strict";var t=e.i(271645),r=e.i(891287),n=e.i(336973),s=e.i(20883),i=e.i(586108),a=e.i(139666),o=e.i(326283);e.s(["useMcpServerConnect",0,function(){let e=(0,i.useStigmer)(),[l,c]=(0,t.useState)(!1),[u,d]=(0,t.useState)(null),g=(0,t.useCallback)(()=>d(null),[]);return{connect:(0,t.useCallback)(async(t,i,l,u)=>{c(!0),d(null);try{let o={...u?await (0,a.resolveDeclaredSystemEnvVars)(e,u):{},...l??{}},c={};for(let[e,t]of Object.entries(o))c[e]={value:t.value,isSecret:t.isSecret??!1};let d=(0,r.create)(n.ConnectInputSchema,{mcpServerId:t,org:i,...Object.keys(c).length>0?{runtimeEnv:c}:{}});return await (0,s.connectAndWait)(e.mcpServer,d)}catch(t){let e=(0,o.toError)(t);throw d(e),e}finally{c(!1)}},[e]),isConnecting:l,error:u,clearError:g}}])},288270,e=>{"use strict";e.s(["diffEnv",0,function(e,t,r){let n=[];for(let[s,i]of Object.entries(e))!t.has(s)&&(r?.has(s)||n.push({key:s,isSecret:i.isSecret,...i.description&&{description:i.description},...i.optional&&{optional:!0}}));return n}])},727996,e=>{"use strict";var t=e.i(910304),r=e.i(586108),n=e.i(583093);e.s(["useMcpServer",0,function(e,s){let i=(0,r.useStigmer)(),{data:a,isLoading:o,isRefetching:l,error:c,refetch:u}=(0,n.useFetch)(e&&s?async()=>{try{return await i.mcpServer.getByReference({org:e,slug:s})}catch(e){if((0,t.isNotFound)(e))return null;throw e}}:null,[e,s,i],null);return{mcpServer:a,isLoading:o,isRefetching:l,error:c,refetch:u}}])},768079,e=>{"use strict";let t=(0,e.i(271645).createContext)(null);e.s(["AuthContext",0,t])},531278,e=>{"use strict";let t=(0,e.i(475254).default)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);e.s(["Loader2",0,t],531278)},55389,e=>{"use strict";var t=e.i(271645),r=e.i(891287),n=e.i(95265),s=e.i(586108),i=e.i(207344);let a="stigmer:github:oauth-state",o="GITHUB_TOKEN",l="stigmer:github:callback-success";async function c(e){try{let t=await fetch("https://api.github.com/user",{headers:{Authorization:`Bearer ${e}`}});if(!t.ok)return null;let r=await t.json();return{login:r.login,avatarUrl:r.avatar_url,name:r.name??null}}catch{return null}}function u(e,t){return e?.spec?.data!=null&&t in e.spec.data}e.s(["GITHUB_CALLBACK_MESSAGE_TYPE",0,l,"useGitHubConnection",0,function(e,d){let g=(0,s.useStigmer)(),[h,m]=(0,t.useState)(null),[f,p]=(0,t.useState)(null),[b,v]=(0,t.useState)(!0),[x,y]=(0,t.useState)(!1),[k,A]=(0,t.useState)(!1),w=(0,i.usePersonalEnvironment)(e||null),E=(0,t.useRef)(w);E.current=w;let S=(0,t.useRef)(!1),C=(0,t.useRef)(null),j=(0,t.useRef)(null),[R,W]=(0,t.useState)(e);e!==R&&(W(e),v(!!e),S.current=!1),(0,t.useEffect)(()=>{if(!e||w.isLoading||S.current)return;S.current=!0;let t=w.environment;if(!u(t,o)||!t)return void v(!1);let s=!1;return async function(){try{let e=await g.environment.getSecretValue((0,r.create)(n.EnvironmentSecretValueInputSchema,{environmentId:t.metadata.id,key:o}));if(s)return;let i=e.value;if(i){let e=await c(i);if(s)return;if(e)m(i),p(e);else{try{await E.current.removeVariables([o])}catch{}m(null),p(null)}}}catch{}s||v(!1)}(),()=>{s=!0}},[e,w.isLoading,w.environment,g]),(0,t.useEffect)(()=>{function e(e){e.origin!==window.location.origin||e.data?.type===l&&(j.current&&(clearInterval(j.current),j.current=null),C.current=null,y(!1),v(!0),S.current=!1,E.current.refetch())}return window.addEventListener("message",e),()=>window.removeEventListener("message",e)},[]),(0,t.useEffect)(()=>()=>{j.current&&clearInterval(j.current)},[]);let M=(0,t.useCallback)(async(e,t)=>{let r=d?.callbackUrl??e,{authorizeUrl:n,state:s}=await g.github.getOAuthAuthorizeUrl({redirectUri:r});if(sessionStorage.setItem(a,s),!t?.popup){window.location.href=n;return}if(d?.openUrl){y(!0),await d.openUrl(n);return}if(C.current&&!C.current.closed)return void C.current.focus();let i=window.screenX+(window.outerWidth-600)/2,o=window.screenY+(window.outerHeight-700)/2,l=window.open(n,"stigmer-github-auth",`width=600,height=700,left=${i},top=${o},popup=yes`);if(!l||l.closed)return void A(!0);A(!1),y(!0),C.current=l;let c=setInterval(()=>{l.closed&&(clearInterval(c),j.current===c&&(j.current=null,C.current=null,y(!1),v(!0),S.current=!1,E.current.refetch()))},500);j.current=c},[g,d?.openUrl,d?.callbackUrl]),N=(0,t.useCallback)(async(e,t,r)=>{let n=function(){try{if(window.opener&&!window.opener.closed){let e=window.opener.sessionStorage.getItem(a);if(e)return e}}catch{}return sessionStorage.getItem(a)}();if(n&&n!==t)throw Error("OAuth state mismatch — possible CSRF attack");sessionStorage.removeItem(a);try{window.opener?.sessionStorage?.removeItem(a)}catch{}try{let{accessToken:n}=await g.github.exchangeOAuthCode({code:e,state:t,redirectUri:r});await E.current.getOrCreate(),await E.current.addVariables({[o]:{value:n,isSecret:!0}}),m(n);let s=await c(n);p(s)}finally{y(!1)}},[g]),I=(0,t.useCallback)(()=>{y(!1),v(!0),S.current=!1,E.current.refetch()},[]),_=(0,t.useCallback)(()=>{sessionStorage.removeItem(a),m(null),p(null),C.current&&!C.current.closed&&C.current.close(),C.current=null,j.current&&(clearInterval(j.current),j.current=null),y(!1);let e=E.current.environment;e&&u(e,o)&&E.current.removeVariables([o]).catch(()=>{})},[]),Z=null!==h;return(0,t.useMemo)(()=>({isConnected:Z,isLoading:b,isConnecting:x,popupBlocked:k,user:f,token:h,connect:M,handleCallback:N,reconcile:I,disconnect:_}),[Z,b,x,k,f,h,M,N,I,_])}])},536907,879049,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(893976),s=e.i(869803);let i={js:"code",jsx:"code",mjs:"code",cjs:"code",ts:"code",tsx:"code",py:"code",rb:"code",go:"code",rs:"code",java:"code",kt:"code",c:"code",h:"code",cpp:"code",cc:"code",hpp:"code",cs:"code",php:"code",swift:"code",sh:"code",bash:"code",zsh:"code",lua:"code",dart:"code",scala:"code",proto:"code",html:"markup",htm:"markup",xml:"markup",vue:"markup",svelte:"markup",css:"style",scss:"style",sass:"style",less:"style",json:"data",jsonc:"data",yaml:"data",yml:"data",toml:"data",ini:"data",env:"data",csv:"data",tsv:"data",md:"markdown",mdx:"markdown",markdown:"markdown",png:"image",jpg:"image",jpeg:"image",gif:"image",webp:"image",svg:"image",ico:"image",bmp:"image"};function a({fileName:e}){let r,n=(r=e.lastIndexOf("."))<0||r===e.length-1?"generic":i[e.slice(r+1).toLowerCase()]??"generic";return(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",className:"stg:shrink-0","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M9.5 1.5H4.5C3.95 1.5 3.5 1.95 3.5 2.5V13.5C3.5 14.05 3.95 14.5 4.5 14.5H11.5C12.05 14.5 12.5 14.05 12.5 13.5V4.5L9.5 1.5Z"}),(0,t.jsx)("path",{d:"M9.3 1.7V4.5H12.3"}),o[n]]})}let o={code:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("path",{d:"M7 8.5L5.75 9.75L7 11"}),(0,t.jsx)("path",{d:"M9 8.5L10.25 9.75L9 11"})]}),markup:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("path",{d:"M6.5 8.5L5.5 9.9L6.5 11.3"}),(0,t.jsx)("path",{d:"M9.5 8.5L10.5 9.9L9.5 11.3"})]}),style:(0,t.jsx)("path",{d:"M5.5 9.3H10.5M5.5 11.1H8.5"}),data:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("path",{d:"M7 8.4C6.2 8.4 6.2 9.3 6.2 9.9C6.2 10.5 6.2 11.4 5.4 11.4"}),(0,t.jsx)("path",{d:"M9 8.4C9.8 8.4 9.8 9.3 9.8 9.9C9.8 10.5 9.8 11.4 10.6 11.4"})]}),markdown:(0,t.jsx)("path",{d:"M5.4 11.3V8.6L6.9 10.1L8.4 8.6V11.3M10.4 8.7V11.1M9.5 10.2L10.4 11.2L11.3 10.2"}),image:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("circle",{cx:"6.4",cy:"9",r:"0.7"}),(0,t.jsx)("path",{d:"M5.2 11.4L7.3 9.9L10.6 11.6"})]}),generic:(0,t.jsx)("path",{d:"M5.5 9.3H10.5M5.5 11.1H10.5"})};function l({open:e=!1}){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",className:"stg:shrink-0","aria-hidden":"true",children:e?(0,t.jsx)("path",{d:"M1.8 5.5V12A1 1 0 002.8 13H12.6L14.5 7.5H4.2L2.8 11"}):(0,t.jsx)("path",{d:"M1.8 4.5A1 1 0 012.8 3.5H6L7.3 5H13.2A1 1 0 0114.2 6V12A1 1 0 0113.2 13H2.8A1 1 0 011.8 12V4.5Z"})})}e.s(["FileTypeIcon",0,a,"FolderTypeIcon",0,l],879049);let c="application/x-stigmer-file-ref";e.s(["FILE_REF_MIME",0,c,"FileTreeNode",0,function e({node:i,selectedPath:o,onSelect:u,onActivate:d,depth:g,enableDrag:h=!1,showIcons:m=!1,indentGuides:f=!1,maxInitialDepth:p}){let[b,v]=(0,r.useState)(void 0===p||g<p),x=!!i.children,y=i.path===o,k=h&&!x,A=(0,r.useCallback)(()=>{x?v(e=>!e):u(i.path)},[x,i.path,u]),w=(0,r.useCallback)(()=>{x||d?.(i.path)},[x,i.path,d]),E=(0,r.useCallback)(e=>{e.dataTransfer.setData(c,JSON.stringify({path:i.path})),e.dataTransfer.effectAllowed="link"},[i.path]);return(0,t.jsxs)("li",{role:"treeitem","aria-level":g+1,"aria-expanded":x?b:void 0,children:[(0,t.jsxs)("button",{type:"button",onClick:A,onDoubleClick:d?w:void 0,draggable:k,onDragStart:k?E:void 0,className:(0,n.cn)("stg:flex stg:w-full stg:items-center stg:gap-1.5 stg:py-1 stg:text-left stg:text-xs stg:transition-colors","stg:hover:bg-muted","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-inset stg:focus-visible:ring-ring",y&&!x&&"stg:bg-muted stg:text-foreground stg:font-medium",!y&&"stg:text-muted-foreground",k&&"stg:cursor-grab stg:active:cursor-grabbing"),style:{paddingLeft:f?"8px":`${12+12*g}px`,paddingRight:"8px"},"aria-current":y?"true":void 0,children:[x&&(0,t.jsx)("span",{"aria-hidden":"true",className:"stg:text-[10px] stg:text-muted-foreground-subtle",children:b?"▼":"▶"}),m&&(x?(0,t.jsx)(l,{open:b}):(0,t.jsx)(a,{fileName:i.name})),(0,t.jsx)("span",{className:(0,n.cn)("stg:truncate",x&&"stg:font-medium stg:text-foreground"),children:i.name})]}),x&&b&&i.children&&(0,t.jsx)("ul",{role:"group",className:(0,n.cn)(s.UNSTYLED_LIST,f&&"stg:ml-3 stg:border-l stg:border-border"),children:i.children.map(r=>(0,t.jsx)(e,{node:r,selectedPath:o,onSelect:u,onActivate:d,depth:g+1,enableDrag:h,showIcons:m,indentGuides:f,maxInitialDepth:p},r.path))})]})}],536907)},469196,e=>{"use strict";e.s(["buildFileTree",0,function(e){let t=[];for(let r of[...e].sort((e,t)=>e.path.localeCompare(t.path))){let e=r.path.split("/");if(1===e.length)t.push({name:e[0],path:r.path});else{let n=t;for(let t=0;t<e.length-1;t++){let r=e[t],s=n.find(e=>e.name===r&&e.children);s||(s={name:r,path:e.slice(0,t+1).join("/")+"/",children:[]},n.push(s)),n=s.children}n.push({name:e[e.length-1],path:r.path})}}return t}])},254347,488479,e=>{"use strict";var t=e.i(910304),r=e.i(586108),n=e.i(583093);e.s(["useSkill",0,function(e,s,i){let a=(0,r.useStigmer)(),{data:o,isLoading:l,isRefetching:c,error:u,refetch:d}=(0,n.useFetch)(e&&s?async()=>{try{return await a.skill.getByReference({org:e,slug:s,version:i})}catch(e){if((0,t.isNotFound)(e))return null;throw e}}:null,[e,s,i,a],null);return{skill:o,isLoading:l,isRefetching:c,error:u,refetch:d}}],254347);var s=e.i(843476),i=e.i(893976);function a({changeType:e}){return(0,s.jsx)("span",{className:(0,i.cn)("stg:shrink-0 stg:font-mono stg:text-[10px] stg:font-bold","modified"===e?"stg:text-diff-hunk-header-fg":"added"===e?"stg:text-diff-added-fg":"stg:text-diff-removed-fg"),"aria-label":e,children:"modified"===e?"M":"added"===e?"A":"D"})}function o({additions:e,deletions:t}){return(0,s.jsxs)("span",{className:"stg:shrink-0 stg:font-mono stg:text-[10px]",children:[e>0&&(0,s.jsxs)("span",{className:"stg:text-diff-added-fg",children:["+",e]}),e>0&&t>0&&" ",t>0&&(0,s.jsxs)("span",{className:"stg:text-diff-removed-fg",children:["-",t]})]})}e.s(["DiffFileList",0,function({files:e,selectedPath:t,onSelect:r,className:n}){return 0===e.length?null:(0,s.jsx)("nav",{"aria-label":"Changed files",className:(0,i.cn)("stg:flex stg:flex-col stg:overflow-auto",n),children:e.map(e=>(0,s.jsxs)("button",{type:"button",onClick:()=>r(e.path),"aria-current":e.path===t?"true":void 0,className:(0,i.cn)("stg:flex stg:items-center stg:gap-2 stg:px-3 stg:py-1.5 stg:text-left stg:text-xs stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-inset",e.path===t?"stg:bg-accent-hover stg:text-foreground":"stg:text-muted-foreground stg:hover:bg-accent-hover stg:hover:text-foreground"),children:[(0,s.jsx)(a,{changeType:e.changeType}),(0,s.jsx)("span",{className:"stg:min-w-0 stg:flex-1 stg:truncate stg:font-mono",children:e.path}),(0,s.jsx)(o,{additions:e.additions,deletions:e.deletions})]},e.path))})}],488479)},686311,e=>{"use strict";let t=(0,e.i(475254).default)("message-square",[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]]);e.s(["MessageSquare",0,t],686311)},705450,e=>{"use strict";var t=e.i(142245),r=e.i(57897),n=e.i(274217),s=e.i(971811),i=e.i(647767);function a(e,t,n,s){return t.$typeName==e.typeName&&n.$typeName==e.typeName&&(t===n||o((0,r.reflect)(e,t),(0,r.reflect)(e,n),s))}function o(e,r,o){if("google.protobuf.Any"===e.desc.typeName&&(null==o?void 0:o.unpackAny)==!0)return function(e,r,i){if(e.typeUrl!==r.typeUrl)return!1;let o=(0,s.anyUnpack)(e,i.registry),l=(0,s.anyUnpack)(r,i.registry);if(o&&l){let e=i.registry.getMessage(o.$typeName);if(e)return a(e,o,l,i)}return(0,t.scalarEquals)(n.ScalarType.BYTES,e.value,r.value)}(e.message,r.message,o);for(let t of e.fields)if(!l(t,e,r,o))return!1;return((null==o?void 0:o.unknown)!=!0||!!function(e,r,s){function i(e,t){var r;let n=null!=(r=e.getUnknown())?r:[];return t?n.filter(r=>!t.getExtensionFor(e.desc,r.no)):n}let a=i(e,s),o=i(r,s);if(a.length!=o.length)return!1;for(let e=0;e<a.length;e++){let r=a[e],s=o[e];if(r.no!=s.no||r.wireType!=s.wireType||!(0,t.scalarEquals)(n.ScalarType.BYTES,r.data,s.data))return!1}return!0}(e,r,o.registry))&&((null==o?void 0:o.extensions)!=!0||!!function(e,t,r){function n(e,t){var r;return(null!=(r=e.getUnknown())?r:[]).map(r=>t.getExtensionFor(e.desc,r.no)).filter(e=>void 0!=e).filter((e,t,r)=>r.indexOf(e)===t)}let s=n(e,r.registry),a=n(t,r.registry);if(s.length!=a.length||s.some(e=>!a.includes(e)))return!1;for(let n of s){let[s,a]=(0,i.createExtensionContainer)(n,(0,i.getExtension)(e.message,n)),[o]=(0,i.createExtensionContainer)(n,(0,i.getExtension)(t.message,n));if(!l(a,s,o,r))return!1}return!0}(e,r,o))}function l(e,r,n,s){if(!r.isSet(e)&&!n.isSet(e))return!0;if(!r.isSet(e)||!n.isSet(e))return!1;switch(e.fieldKind){case"scalar":return(0,t.scalarEquals)(e.scalar,r.get(e),n.get(e));case"enum":return r.get(e)===n.get(e);case"message":return o(r.get(e),n.get(e),s);case"map":{let i=r.get(e),a=n.get(e),l=[];for(let e of i.keys()){if(!a.has(e))return!1;l.push(e)}for(let e of a.keys())if(!i.has(e))return!1;for(let r of l){let n=i.get(r),l=a.get(r);if(n!==l)switch(e.mapKind){case"enum":return!1;case"message":if(!o(n,l,s))return!1;break;case"scalar":if(!(0,t.scalarEquals)(e.scalar,n,l))return!1}}break}case"list":{let i=r.get(e),a=n.get(e);if(i.size!=a.size)return!1;for(let r=0;r<i.size;r++){let n=i.get(r),l=a.get(r);if(n!==l)switch(e.listKind){case"enum":return!1;case"message":if(!o(n,l,s))return!1;break;case"scalar":if(!(0,t.scalarEquals)(e.scalar,n,l))return!1}}}}return!0}e.s(["equals",0,a])},37727,e=>{"use strict";let t=(0,e.i(475254).default)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);e.s(["X",0,t],37727)},284614,e=>{"use strict";let t=(0,e.i(475254).default)("user",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);e.s(["User",0,t],284614)},12556,913668,215133,e=>{"use strict";e.i(113024);var t,r,n,s,i,a,o,l,c,u,d,g,h,m,f,p,b=e.i(424407),v=e.i(304532),x=e.i(732303);let y=(0,b.fileDesc)("CjFhaS9zdGlnbWVyL2FnZW50aWMvYWdlbnRjaGFubmVsL3YxL2RlbGl2ZXJ5LnByb3RvEiJhaS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxIvwFCg9DaGFubmVsRGVsaXZlcnkSEwoLZGVsaXZlcnlfaWQYASABKAkSGAoQYWdlbnRfY2hhbm5lbF9pZBgCIAEoCRILCgNvcmcYAyABKAkSFAoMZXhlY3V0aW9uX2lkGAQgASgJEhIKCnNlc3Npb25faWQYBSABKAkSGAoQY29udmVyc2F0aW9uX2tleRgGIAEoCRIZChFleHRlcm5hbF91c2VyX2tleRgHIAEoCRJJCgZzdGF0dXMYCCABKA4yOS5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNoYW5uZWxEZWxpdmVyeVN0YXR1cxIQCghhdHRlbXB0cxgJIAEoBRISCgpsYXN0X2Vycm9yGAogASgJEhcKD2lkZW1wb3RlbmN5X2tleRgLIAEoCRJJCgVzbGFjaxgMIAEoCzI4LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuU2xhY2tEZWxpdmVyeUNvbnRleHRIABJPCgh3aGF0c2FwcBgQIAEoCzI7LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuV2hhdHNBcHBEZWxpdmVyeUNvbnRleHRIABIuCgpjcmVhdGVkX2F0GA0gASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcBIuCgp1cGRhdGVkX2F0GA4gASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcBIzCg9uZXh0X2F0dGVtcHRfYXQYDyABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wEhIKCnJlcGx5X3RleHQYESABKAkSUwoMZmFpbHVyZV9raW5kGBIgASgOMj0uYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5DaGFubmVsQXR0ZW1wdEZhaWx1cmVLaW5kEhYKDmF0dGVtcHRfZGV0YWlsGBMgASgJQhIKEGRlbGl2ZXJ5X2NvbnRleHQiVQoUU2xhY2tEZWxpdmVyeUNvbnRleHQSEgoKY2hhbm5lbF9pZBgBIAEoCRIRCgl0aHJlYWRfdHMYAiABKAkSFgoOcGxhY2Vob2xkZXJfdHMYAyABKAkiSwoXV2hhdHNBcHBEZWxpdmVyeUNvbnRleHQSFwoPcGhvbmVfbnVtYmVyX2lkGAEgASgJEhcKD3JlY2lwaWVudF93YV9pZBgCIAEoCSqIAQoVQ2hhbm5lbERlbGl2ZXJ5U3RhdHVzEicKI2NoYW5uZWxfZGVsaXZlcnlfc3RhdHVzX3Vuc3BlY2lmaWVkEAASCwoHcGVuZGluZxABEg4KCmRlbGl2ZXJpbmcQAhINCglkZWxpdmVyZWQQAxIKCgZmYWlsZWQQBBIOCgpzdXBwcmVzc2VkEAUqfQoZQ2hhbm5lbEF0dGVtcHRGYWlsdXJlS2luZBIfChthdHRlbXB0X2ZhaWx1cmVfdW5zcGVjaWZpZWQQABITCg9hdHRlbXB0X3JlZnVzZWQQARITCg9hdHRlbXB0X2Vycm9yZWQQAhIVChFhdHRlbXB0X3dpdGhkcmF3bhADYgZwcm90bzM",[x.file_google_protobuf_timestamp]);(t=c||(c={}))[t.channel_delivery_status_unspecified=0]="channel_delivery_status_unspecified",t[t.pending=1]="pending",t[t.delivering=2]="delivering",t[t.delivered=3]="delivered",t[t.failed=4]="failed",t[t.suppressed=5]="suppressed",(r=u||(u={}))[r.attempt_failure_unspecified=0]="attempt_failure_unspecified",r[r.attempt_refused=1]="attempt_refused",r[r.attempt_errored=2]="attempt_errored",r[r.attempt_withdrawn=3]="attempt_withdrawn",e.s(["ChannelAttemptFailureKind",0,u,"ChannelDeliveryStatus",0,c,"file_ai_stigmer_agentic_agentchannel_v1_delivery",0,y],913668);var k=e.i(730938);let A=(0,b.fileDesc)("CjFhaS9zdGlnbWVyL2FnZW50aWMvYWdlbnRjaGFubmVsL3YxL291dGJvdW5kLnByb3RvEiJhaS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxIo8HChZDaGFubmVsT3V0Ym91bmRNZXNzYWdlEhsKE291dGJvdW5kX21lc3NhZ2VfaWQYASABKAkSGAoQYWdlbnRfY2hhbm5lbF9pZBgCIAEoCRILCgNvcmcYAyABKAkSEgoKc2Vzc2lvbl9pZBgEIAEoCRJJCgZvcmlnaW4YBSABKA4yOS5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNoYW5uZWxPdXRib3VuZE9yaWdpbhIRCglyZWNpcGllbnQYBiABKAkSSwoHcGF5bG9hZBgHIAEoCzI6LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ2hhbm5lbE91dGJvdW5kUGF5bG9hZBJJCgZzdGF0dXMYCCABKA4yOS5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNoYW5uZWxEZWxpdmVyeVN0YXR1cxIQCghhdHRlbXB0cxgJIAEoBRISCgpsYXN0X2Vycm9yGAogASgJEhcKD2lkZW1wb3RlbmN5X2tleRgLIAEoCRIbChNwcm92aWRlcl9tZXNzYWdlX2lkGAwgASgJEi4KCmNyZWF0ZWRfYXQYDSABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wEi4KCnVwZGF0ZWRfYXQYDiABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wEjMKD25leHRfYXR0ZW1wdF9hdBgPIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3RhbXASTgoNcmVjZWlwdF9zdGF0ZRgQIAEoDjI3LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ2hhbm5lbFJlY2VpcHRTdGF0ZRIWCg5yZWNlaXB0X2RldGFpbBgRIAEoCRIaChJyZWNlaXB0X2Vycm9yX2NvZGUYEiABKAUSLgoKcmVjZWlwdF9hdBgTIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3RhbXASFQoNcmVuZGVyZWRfYm9keRgUIAEoCRJTCgxmYWlsdXJlX2tpbmQYFSABKA4yPS5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNoYW5uZWxBdHRlbXB0RmFpbHVyZUtpbmQSFgoOYXR0ZW1wdF9kZXRhaWwYFiABKAkqgwEKE0NoYW5uZWxSZWNlaXB0U3RhdGUSHQoZcmVjZWlwdF9zdGF0ZV91bnNwZWNpZmllZBAAEhAKDHJlY2VpcHRfc2VudBABEhUKEXJlY2VpcHRfZGVsaXZlcmVkEAISEAoMcmVjZWlwdF9yZWFkEAMSEgoOcmVjZWlwdF9mYWlsZWQQBCqHAQoVQ2hhbm5lbE91dGJvdW5kT3JpZ2luEicKI2NoYW5uZWxfb3V0Ym91bmRfb3JpZ2luX3Vuc3BlY2lmaWVkEAASGAoUY2hhbm5lbF9jb252ZXJzYXRpb24QARIMCghvcGVyYXRvchACEgwKCHBsYXRmb3JtEAMSDwoLcGFydGljaXBhbnQQBGIGcHJvdG8z",[y,k.file_ai_stigmer_agentic_agentchannel_v1_message_io,x.file_google_protobuf_timestamp]);(n=d||(d={}))[n.receipt_state_unspecified=0]="receipt_state_unspecified",n[n.receipt_sent=1]="receipt_sent",n[n.receipt_delivered=2]="receipt_delivered",n[n.receipt_read=3]="receipt_read",n[n.receipt_failed=4]="receipt_failed",(s=g||(g={}))[s.channel_outbound_origin_unspecified=0]="channel_outbound_origin_unspecified",s[s.channel_conversation=1]="channel_conversation",s[s.operator=2]="operator",s[s.platform=3]="platform",s[s.participant=4]="participant",e.s(["ChannelReceiptState",0,d,"file_ai_stigmer_agentic_agentchannel_v1_outbound",0,A],215133);var w=e.i(85849),E=e.i(761867);let S=(0,b.fileDesc)("CjhhaS9zdGlnbWVyL2FnZW50aWMvYWdlbnRjaGFubmVsL3YxL2NvbnZlcnNhdGlvbl9pby5wcm90bxIiYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MSL+AwoTQ2hhbm5lbENvbnZlcnNhdGlvbhIYChBhZ2VudF9jaGFubmVsX2lkGAEgASgJEhgKEGNvbnZlcnNhdGlvbl9rZXkYAiABKAkSCwoDb3JnGAMgASgJEkgKB2NvbnRyb2wYBCABKA4yNy5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNvbnZlcnNhdGlvbkNvbnRyb2wSFQoNY29udHJvbGxlZF9ieRgFIAEoCRI2ChJjb250cm9sX2NoYW5nZWRfYXQYBiABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wEhcKD25lZWRzX2F0dGVudGlvbhgHIAEoCBIYChBhdHRlbnRpb25fcmVhc29uGAggASgJEjgKFGF0dGVudGlvbl9jaGFuZ2VkX2F0GAkgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcBIUCgxkaXNwbGF5X25hbWUYCiABKAkSPAoYbGFzdF9jdXN0b21lcl9tZXNzYWdlX2F0GAsgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcBI0ChBsYXN0X2FjdGl2aXR5X2F0GAwgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcBIWCg5hd2FpdGluZ19yZXBseRgNIAEoCCKGBgoYQ29udmVyc2F0aW9uVGltZWxpbmVJdGVtEg8KB2l0ZW1faWQYASABKAkSQgoEbGFuZRgCIAEoDjI0LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ29udmVyc2F0aW9uTGFuZRJKCgZhdXRob3IYAyABKA4yOi5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNvbnZlcnNhdGlvbkl0ZW1BdXRob3ISEwoLYXV0aG9yZWRfYnkYBCABKAkSDAoEdGV4dBgFIAEoCRIdChVwcm92aWRlcl9tZXNzYWdlX3R5cGUYBiABKAkSJgoCYXQYByABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wElIKD2RlbGl2ZXJ5X3N0YXR1cxgIIAEoDjI5LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ2hhbm5lbERlbGl2ZXJ5U3RhdHVzEk4KDXJlY2VpcHRfc3RhdGUYCSABKA4yNy5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNoYW5uZWxSZWNlaXB0U3RhdGUSSQoGb3JpZ2luGAogASgOMjkuYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5DaGFubmVsT3V0Ym91bmRPcmlnaW4SFgoOcmVjZWlwdF9kZXRhaWwYCyABKAkSGgoScmVjZWlwdF9lcnJvcl9jb2RlGAwgASgFEkcKBW1lZGlhGA0gASgLMjguYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5Db252ZXJzYXRpb25NZWRpYVJlZhIWCg5hdHRlbXB0X2RldGFpbBgOIAEoCRJbChRhdHRlbXB0X2ZhaWx1cmVfa2luZBgPIAEoDjI9LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ2hhbm5lbEF0dGVtcHRGYWlsdXJlS2luZCJSChRDb252ZXJzYXRpb25NZWRpYVJlZhIQCghmaWxlbmFtZRgBIAEoCRIUCgxjb250ZW50X3R5cGUYAiABKAkSEgoKc2l6ZV9ieXRlcxgDIAEoAyLjAQodTGlzdENoYW5uZWxDb252ZXJzYXRpb25zSW5wdXQSFgoDb3JnGAEgASgJQgm6SAZyBBABGD8SIgoQYWdlbnRfY2hhbm5lbF9pZBgCIAEoCUIIukgFcgMYgAESMwoJcGFnZV9pbmZvGAMgASgLMiAuYWkuc3RpZ21lci5jb21tb25zLnJwYy5QYWdlSW5mbxJRCgZmaWx0ZXIYBCABKA4yQS5haS5zdGlnbWVyLmFnZW50aWMuYWdlbnRjaGFubmVsLnYxLkNoYW5uZWxDb252ZXJzYXRpb25MaXN0RmlsdGVyInYKF0NoYW5uZWxDb252ZXJzYXRpb25MaXN0EhMKC3RvdGFsX2NvdW50GAEgASgFEkYKBWl0ZW1zGAIgAygLMjcuYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5DaGFubmVsQ29udmVyc2F0aW9uImkKG0dldENoYW5uZWxDb252ZXJzYXRpb25JbnB1dBIkChBhZ2VudF9jaGFubmVsX2lkGAEgASgJQgq6SAdyBRABGIABEiQKEGNvbnZlcnNhdGlvbl9rZXkYAiABKAlCCrpIB3IFEAEYgAEikQEKHEdldENvbnZlcnNhdGlvblRpbWVsaW5lSW5wdXQSJAoQYWdlbnRfY2hhbm5lbF9pZBgBIAEoCUIKukgHcgUQARiAARIkChBjb252ZXJzYXRpb25fa2V5GAIgASgJQgq6SAdyBRABGIABEhEKCXBhZ2Vfc2l6ZRgDIAEoBRISCgpwYWdlX3Rva2VuGAQgASgJInwKFENvbnZlcnNhdGlvblRpbWVsaW5lEksKBWl0ZW1zGAEgAygLMjwuYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5Db252ZXJzYXRpb25UaW1lbGluZUl0ZW0SFwoPbmV4dF9wYWdlX3Rva2VuGAIgASgJIo8BCiRHZXRDb252ZXJzYXRpb25NZWRpYURvd25sb2FkVXJsSW5wdXQSJAoQYWdlbnRfY2hhbm5lbF9pZBgBIAEoCUIKukgHcgUQARiAARIkChBjb252ZXJzYXRpb25fa2V5GAIgASgJQgq6SAdyBRABGIABEhsKB2l0ZW1faWQYAyABKAlCCrpIB3IFEAEYgAIiWwocQ29udmVyc2F0aW9uTWVkaWFEb3dubG9hZFVybBILCgN1cmwYASABKAkSLgoKZXhwaXJlc19hdBgCIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3RhbXAiZgoYQ29udmVyc2F0aW9uQ29udHJvbElucHV0EiQKEGFnZW50X2NoYW5uZWxfaWQYASABKAlCCrpIB3IFEAEYgAESJAoQY29udmVyc2F0aW9uX2tleRgCIAEoCUIKukgHcgUQARiAASK7AQoYUmVwbHlUb0NvbnZlcnNhdGlvbklucHV0EiQKEGFnZW50X2NoYW5uZWxfaWQYASABKAlCCrpIB3IFEAEYgAESJAoQY29udmVyc2F0aW9uX2tleRgCIAEoCUIKukgHcgUQARiAARJTCgdwYXlsb2FkGAMgASgLMjouYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5DaGFubmVsT3V0Ym91bmRQYXlsb2FkQga6SAPIAQEiNwoZRXNjYWxhdGVDb252ZXJzYXRpb25JbnB1dBIaCgZyZWFzb24YASABKAlCCrpIB3IFEAEYgAgqYQoTQ29udmVyc2F0aW9uQ29udHJvbBIkCiBjb252ZXJzYXRpb25fY29udHJvbF91bnNwZWNpZmllZBAAEhEKDWNvbnRyb2xfYWdlbnQQARIRCg1jb250cm9sX2h1bWFuEAIqWQoQQ29udmVyc2F0aW9uTGFuZRIhCh1jb252ZXJzYXRpb25fbGFuZV91bnNwZWNpZmllZBAAEg8KC2xhbmVfcHVibGljEAESEQoNbGFuZV9pbnRlcm5hbBACKpMBChZDb252ZXJzYXRpb25JdGVtQXV0aG9yEigKJGNvbnZlcnNhdGlvbl9pdGVtX2F1dGhvcl91bnNwZWNpZmllZBAAEhMKD2F1dGhvcl9jdXN0b21lchABEhAKDGF1dGhvcl9hZ2VudBACEhMKD2F1dGhvcl90ZWFtbWF0ZRADEhMKD2F1dGhvcl9wbGF0Zm9ybRAEKmkKHUNoYW5uZWxDb252ZXJzYXRpb25MaXN0RmlsdGVyEjAKLGNoYW5uZWxfY29udmVyc2F0aW9uX2xpc3RfZmlsdGVyX3Vuc3BlY2lmaWVkEAASFgoSZmlsdGVyX3dhbnRzX2h1bWFuEAFiBnByb3RvMw",[y,k.file_ai_stigmer_agentic_agentchannel_v1_message_io,A,w.file_ai_stigmer_commons_rpc_pagination,E.file_buf_validate_validate,x.file_google_protobuf_timestamp]),C=(0,v.messageDesc)(S,0),j=(0,v.messageDesc)(S,1),R=(0,v.messageDesc)(S,3),W=(0,v.messageDesc)(S,5),M=(0,v.messageDesc)(S,6),N=(0,v.messageDesc)(S,8),I=(0,v.messageDesc)(S,10),_=(0,v.messageDesc)(S,11);(i=h||(h={}))[i.conversation_control_unspecified=0]="conversation_control_unspecified",i[i.control_agent=1]="control_agent",i[i.control_human=2]="control_human",(a=m||(m={}))[a.conversation_lane_unspecified=0]="conversation_lane_unspecified",a[a.lane_public=1]="lane_public",a[a.lane_internal=2]="lane_internal",(o=f||(f={}))[o.conversation_item_author_unspecified=0]="conversation_item_author_unspecified",o[o.author_customer=1]="author_customer",o[o.author_agent=2]="author_agent",o[o.author_teammate=3]="author_teammate",o[o.author_platform=4]="author_platform",(l=p||(p={}))[l.channel_conversation_list_filter_unspecified=0]="channel_conversation_list_filter_unspecified",l[l.filter_wants_human=1]="filter_wants_human",e.s(["ChannelConversationListFilter",0,p,"ChannelConversationSchema",0,C,"ConversationControl",0,h,"ConversationControlInputSchema",0,I,"ConversationItemAuthor",0,f,"ConversationLane",0,m,"ConversationTimelineItemSchema",0,j,"GetChannelConversationInputSchema",0,W,"GetConversationMediaDownloadUrlInputSchema",0,N,"GetConversationTimelineInputSchema",0,M,"ListChannelConversationsInputSchema",0,R,"ReplyToConversationInputSchema",0,_,"file_ai_stigmer_agentic_agentchannel_v1_conversation_io",0,S],12556)},973621,711364,945850,e=>{"use strict";var t=e.i(271645);e.s(["useComposer",0,function({onSubmit:e,disabled:r=!1,maxHeight:n=240,autoFocusOnEnable:s=!0}){let i=(0,t.useRef)(null),[a,o]=(0,t.useState)(""),l=(0,t.useRef)(r),c=a.trim().length>0&&!r;(0,t.useEffect)(()=>{s&&l.current&&!r&&i.current?.focus(),l.current=r},[r,s]);let u=(0,t.useCallback)(()=>{let e=i.current;e&&(e.style.height="auto",e.style.height=`${Math.min(e.scrollHeight,n)}px`)},[n]),d=(0,t.useCallback)(()=>{let e=i.current;e&&(e.style.height="auto")},[]),g=(0,t.useCallback)(()=>{o(""),d()},[d]),h=(0,t.useCallback)(()=>{let t=a.trim();t&&!r&&(e(t),g())},[a,r,e,g]),m=(0,t.useCallback)(e=>{"Enter"!==e.key||e.shiftKey||(e.preventDefault(),h())},[h]),f=(0,t.useCallback)(e=>{o(e.target.value),u()},[u]);return{message:a,setMessage:o,textareaRef:i,textareaProps:{ref:i,value:a,onChange:f,onKeyDown:m,disabled:r},canSubmit:c,submit:h,clear:g}}],973621);let r={".md":"text/markdown",".markdown":"text/markdown",".yaml":"application/x-yaml",".yml":"application/x-yaml",".json":"application/json",".csv":"text/csv",".tsv":"text/tab-separated-values",".xml":"application/xml",".html":"text/html",".htm":"text/html",".css":"text/css",".js":"application/javascript",".ts":"application/typescript",".py":"text/x-python",".go":"text/x-go",".rs":"text/x-rust",".java":"text/x-java",".rb":"text/x-ruby",".sh":"application/x-sh",".bash":"application/x-sh",".sql":"application/sql",".toml":"application/toml",".ini":"text/plain",".cfg":"text/plain",".conf":"text/plain",".env":"text/plain",".txt":"text/plain",".log":"text/plain",".pdf":"application/pdf",".zip":"application/zip",".gz":"application/gzip",".tar":"application/x-tar",".png":"image/png",".jpg":"image/jpeg",".jpeg":"image/jpeg",".gif":"image/gif",".svg":"image/svg+xml",".webp":"image/webp"},n=["B","KB","MB","GB"];function s(e){if(0===e)return"0 B";let t=Math.min(Math.floor(Math.log(e)/Math.log(1024)),n.length-1),r=e/Math.pow(1024,t);return 0===t?`${e} B`:`${r.toFixed(1)} ${n[t]}`}e.s(["detectContentType",0,function(e){if(e.type&&"application/octet-stream"!==e.type)return e.type;let t=e.name.lastIndexOf(".");if(-1!==t){let n=r[e.name.slice(t).toLowerCase()];if(n)return n}return"application/octet-stream"},"formatFileSize",0,s,"uniquifyFilename",0,function(e,t){if(!t.has(e))return e;let r=e.lastIndexOf("."),n=r>0?e.slice(0,r):e,s=r>0?e.slice(r):"";for(let e=2;;e++){let r=`${n}-${e}${s}`;if(!t.has(r))return r}},"validateAttachmentSize",0,function(e){return e.size>0xa00000?`${e.name} exceeds the 10 MB attachment limit (${s(e.size)})`:null}],711364);var i=e.i(326283);let a=new Set,o=new Map;e.s(["useKeyedSubmission",0,function(){let[e,r]=(0,t.useState)(a),[n,s]=(0,t.useState)(o),l=(0,t.useCallback)(()=>s(o),[]),c=(0,t.useCallback)(async(e,t)=>{r(t=>{let r=new Set(t);return r.add(e),r}),s(t=>{if(!t.has(e))return t;let r=new Map(t);return r.delete(e),r});try{return await t()}catch(r){let t=(0,i.toError)(r);throw s(r=>new Map(r).set(e,t)),r}finally{r(t=>{if(!t.has(e))return t;let r=new Set(t);return r.delete(e),r})}},[]);return(0,t.useMemo)(()=>({submittingKeys:e,errorsByKey:n,run:c,clearErrors:l}),[e,n,c,l])}],945850)},217127,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(893976),s=e.i(590150),i=e.i(213149);function a(){return(0,t.jsxs)("svg",{width:"13",height:"13",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("circle",{cx:"12",cy:"3.5",r:"1.75"}),(0,t.jsx)("circle",{cx:"4",cy:"8",r:"1.75"}),(0,t.jsx)("circle",{cx:"12",cy:"12.5",r:"1.75"}),(0,t.jsx)("path",{d:"M5.5 7.1l5-2.7M5.5 8.9l5 2.7"})]})}e.s(["ManageAccessButton",0,function({resource:e,visibility:o,extraSection:l,label:c="Manage access",className:u}){let[d,g]=(0,r.useState)(!1);return(0,t.jsxs)(s.PermissionGate,{resource:{kind:e.kindString,id:e.id},relation:"can_view_access",children:[(0,t.jsxs)("button",{type:"button",onClick:()=>g(!0),className:(0,n.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:border stg:border-border stg:text-foreground stg:hover:bg-accent-hover","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring",u),children:[(0,t.jsx)(a,{}),c]}),(0,t.jsx)(i.ManageAccessDialog,{open:d,onOpenChange:g,resource:e,visibility:o,extraSection:l})]})}])},766354,799190,e=>{"use strict";let t=(0,e.i(475254).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",0,t],766354),e.s(["CONVERSATION_BADGE_POLL_INTERVAL_MS",0,6e4,"CONVERSATION_DETAIL_POLL_INTERVAL_MS",0,5e3,"CONVERSATION_LIST_POLL_INTERVAL_MS",0,2e4],799190)},981997,e=>{"use strict";let t=(0,e.i(475254).default)("messages-square",[["path",{d:"M16 10a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 14.286V4a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2z",key:"1n2ejm"}],["path",{d:"M20 9a2 2 0 0 1 2 2v10.286a.71.71 0 0 1-1.212.502l-2.202-2.202A2 2 0 0 0 17.172 19H10a2 2 0 0 1-2-2v-1",key:"1qfcsi"}]]);e.s(["MessagesSquare",0,t],981997)},465261,649582,e=>{"use strict";var t=e.i(475254);let r=(0,t.default)("key-round",[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]]);e.s(["KeyRound",0,r],465261);let n=(0,t.default)("sliders-horizontal",[["path",{d:"M10 5H3",key:"1qgfaw"}],["path",{d:"M12 19H3",key:"yhmn1j"}],["path",{d:"M14 3v4",key:"1sua03"}],["path",{d:"M16 17v4",key:"1q0r14"}],["path",{d:"M21 12h-9",key:"1o4lsq"}],["path",{d:"M21 19h-5",key:"1rlt1p"}],["path",{d:"M21 5h-7",key:"1oszz2"}],["path",{d:"M8 10v4",key:"tgpxqk"}],["path",{d:"M8 12H3",key:"a7s4jb"}]]);e.s(["SlidersHorizontal",0,n],649582)},287237,e=>{"use strict";var t=e.i(972992);let r={native:{label:"Stigmer",description:"Stigmer's native agent runtime"},cursor:{label:"Cursor",description:"Cursor IDE agent with codebase indexing"},copilot:{label:"GitHub Copilot",description:"GitHub-native sub-agent orchestration"},claude_code:{label:"Claude Agent SDK",description:"Anthropic's agent SDK with built-in tools"},codex:{label:"OpenAI Codex",description:"Thread-based execution with structured output"},devin:{label:"Devin",description:"Full autonomous engineer, session-based"}},n=Object.fromEntries(Object.entries(r).map(([e,t])=>[e,t.label]));e.s(["DEFAULT_HARNESS",0,"native","HARNESS_LABELS",0,n,"HARNESS_META",0,r,"HARNESS_OPTIONS",0,["native","cursor","copilot","claude_code","codex","devin"],"fromProtoHarness",0,function(e){switch(e){case t.Harness.CURSOR:return"cursor";case t.Harness.NATIVE:case t.Harness.UNSPECIFIED:default:return"native"}},"toProtoHarness",0,function(e){return"cursor"===e?t.Harness.CURSOR:t.Harness.NATIVE}])},444857,766817,e=>{"use strict";var t=e.i(661438);e.s(["FAST_SERVICE_TIER",0,"fast","fromProtoServiceTier",0,function(e){switch(e){case t.ServiceTier.STANDARD:return"standard";case t.ServiceTier.FAST:return"fast";default:return}},"toProtoServiceTier",0,function(e){return"fast"===e?t.ServiceTier.FAST:t.ServiceTier.STANDARD}],444857),e.s(["fromProtoThinkingMode",0,function(e){switch(e){case t.ThinkingMode.DISABLED:return"disabled";case t.ThinkingMode.ENABLED:return"enabled";default:return}},"toProtoThinkingMode",0,function(e){return"enabled"===e?t.ThinkingMode.ENABLED:t.ThinkingMode.DISABLED}],766817)},383406,e=>{"use strict";var t=e.i(271645);let r=(0,t.createContext)({models:[],isLoading:!0,error:null,refetch:()=>{}});e.s(["ModelRegistryContext",0,r,"useModelRegistryContext",0,function(){return(0,t.useContext)(r)}])},614920,e=>{"use strict";let t=new Set(["ollama"]),r=new Set(["economy","standard","premium"]),n=new Set(["fastest","fast","balanced","slow"]),s=new Set(["native","cursor","copilot","claude_code","codex","devin"]);function i(e){return"string"==typeof e.id&&"string"==typeof e.displayName&&"string"==typeof e.provider&&"string"==typeof e.harness&&s.has(e.harness)&&"string"==typeof e.costTier&&r.has(e.costTier)}async function a(e,t,r){let s=r??globalThis.fetch,a={};t&&(a.Authorization=`Bearer ${t}`);let o=await s(`${e}/v1/proxy/model-registry`,{headers:a});if(!o.ok)throw Error(`Model registry fetch failed: ${o.status}`);var l=await o.json();if(!l||"object"!=typeof l)return{models:[]};let c=l.models;if(!Array.isArray(c))return{models:[]};let u=c.filter(i).map(e=>{let t=function(e){if(!e||"object"!=typeof e)return;let t=e.vision;return"boolean"==typeof t?t:void 0}(e.capabilities),r=function(e){if(!e||"object"!=typeof e)return;let t=e.thinking;return"boolean"==typeof t?t:void 0}(e.capabilities);return{modelId:e.id,provider:e.provider,displayName:e.displayName,shortDescription:e.shortDescription??"",speedTier:n.has(e.speedTier??"")?e.speedTier:"fast",costTier:e.costTier,harness:e.harness,featured:e.featured??!1,serviceTiers:e.pricingVariants&&"object"==typeof e.pricingVariants?Object.keys(e.pricingVariants).sort():[],...void 0!==t?{visionCapability:t}:{},...void 0!==r?{thinkingCapable:r}:{}}}),d=function(e){let t=e.limits;if(!t||"object"!=typeof t)return;let r=t.vision;if(!r||"object"!=typeof r)return;let{maxImageBytes:n,maxTotalBytes:s,maxImages:i}=r;if("number"==typeof n&&!(n<=0)&&"number"==typeof s&&!(s<=0)&&"number"==typeof i&&!(i<=0))return{maxImageBytes:n,maxTotalBytes:s,maxImages:i}}(l);return{models:u,...void 0!==d?{visionLimits:d}:{}}}let o="claude-sonnet-4.6",l="default";e.s(["DEFAULT_MODEL_ID",0,o,"DISABLED_PROVIDERS",0,t,"fetchModelRegistryDocument",0,a,"modelKey",0,function(e,t){return`${e}/${t}`},"parseModelKey",0,function(e){let t=e.indexOf("/");if(t<1)return;let r=e.slice(0,t);if("native"===r||"cursor"===r)return{harness:r,modelId:e.slice(t+1)}},"resolveDefaultModelId",0,function(e,t,r){if(r?.userPreference){let n=t.find(t=>t.harness===e&&t.modelId===r.userPreference);if(n)return{modelId:n.modelId,source:"user_preference"}}if(r?.orgDefault){let n=t.find(t=>t.harness===e&&t.modelId===r.orgDefault);if(n)return{modelId:n.modelId,source:"org_default"}}if(r?.agentDefault){let n=t.find(t=>t.harness===e&&t.modelId===r.agentDefault);if(n)return{modelId:n.modelId,source:"agent_default"}}if("cursor"===e){let r=t.find(t=>t.harness===e&&t.modelId===l);if(r)return{modelId:r.modelId,source:"harness_default"}}else{let r=t.find(t=>t.harness===e&&t.featured&&"standard"===t.costTier)??t.find(t=>t.harness===e&&"standard"===t.costTier);if(r)return{modelId:r.modelId,source:"harness_default"}}let n=t.find(t=>t.harness===e&&t.featured);return n?{modelId:n.modelId,source:"harness_default"}:{modelId:"cursor"===e?l:o,source:"platform_fallback"}}])},934197,e=>{"use strict";var t=e.i(843476),r=e.i(893976);e.s(["Switch",0,function({checked:e,onCheckedChange:n,disabled:s,"aria-label":i,"aria-labelledby":a,"aria-describedby":o,id:l,className:c}){return(0,t.jsx)("button",{type:"button",role:"switch",id:l,"aria-checked":e,"aria-label":i,"aria-labelledby":a,"aria-describedby":o,disabled:s,onClick:()=>n(!e),className:(0,r.cn)("stg:relative stg:inline-flex stg:h-5 stg:w-9 stg:shrink-0 stg:items-center stg:rounded-full stg:transition-colors","stg:motion-reduce:transition-none",e?"stg:bg-primary":"stg:bg-input","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-offset-2","stg:disabled:pointer-events-none stg:disabled:opacity-50","stg:after:absolute stg:after:-inset-3 stg:after:content-['']",c),children:(0,t.jsx)("span",{"aria-hidden":"true",className:(0,r.cn)("stg:pointer-events-none stg:block stg:size-4 stg:rounded-full stg:bg-background stg:shadow-sm stg:transition-transform","stg:motion-reduce:transition-none",e?"stg:translate-x-[18px]":"stg:translate-x-0.5")})})}])},557702,e=>{"use strict";var t=e.i(271645),r=e.i(614920),n=e.i(383406);e.s(["useModelRegistry",0,function(e){let s=e?.harness,{models:i,visionLimits:a,isLoading:o,error:l,refetch:c}=(0,n.useModelRegistryContext)();return(0,t.useMemo)(()=>{let e,t=void 0===s,{modelId:n}=s?(0,r.resolveDefaultModelId)(s,i):{modelId:r.DEFAULT_MODEL_ID},u=new Map,d=new Map,g=new Map,h=[],m=[];for(let a of i){if(t){if(r.DISABLED_PROVIDERS.has(a.provider))continue}else if(a.harness!==s||r.DISABLED_PROVIDERS.has(a.provider))continue;h.push(a),g.set((0,r.modelKey)(a.harness,a.modelId),a),d.has(a.modelId)||d.set(a.modelId,a);let i=u.get(a.provider);i?i.push(a):u.set(a.provider,[a]),a.modelId===n&&(e??=a),a.featured&&m.push(a)}let f=Array.from(u.keys());return{models:h,byProvider:u,defaultModel:e??h[0],getModel:e=>d.get(e),providers:f,featured:m,getByKey:e=>g.get(e),visionLimits:a,isLoading:o,error:l,refetch:c}},[s,i,a,o,l,c])}])},216386,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(506213),s=e.i(893976),i=e.i(364354),a=e.i(934197),o=e.i(557702),l=e.i(287237),c=e.i(444857);let u={economy:"$",standard:"$$",premium:"$$$"},d={fastest:"Fastest",fast:"Fast",balanced:"Balanced",slow:"Powerful"};function g(e){return"cursor"===e.harness&&!0===e.thinkingCapable}function h({model:e,isSelected:r,isHighlighted:n,showDescription:i,showSpeedBadge:a,onClick:o,onMouseEnter:l}){return(0,t.jsxs)("button",{"data-model-option":"",role:"option","aria-selected":r,type:"button",className:(0,s.cn)("stg:flex stg:w-full stg:cursor-pointer stg:flex-col stg:rounded-md stg:px-2 stg:py-1.5 stg:text-xs stg:outline-none","stg:transition-colors",n&&"stg:bg-accent stg:text-accent-foreground",!n&&"stg:hover:bg-accent-hover"),onClick:o,onMouseEnter:l,children:[(0,t.jsxs)("div",{className:"stg:flex stg:w-full stg:items-center stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:flex-1 stg:truncate stg:text-left stg:font-medium",children:e.displayName}),!1===e.visionCapability&&(0,t.jsxs)("span",{className:"stg:flex stg:shrink-0 stg:items-center stg:gap-0.5 stg:text-[0.6rem] stg:text-muted-foreground",children:[(0,t.jsx)(p,{}),"No image input"]}),(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-[0.6rem] stg:text-muted-foreground",children:a?`${d[e.speedTier]} ${u[e.costTier]}`:u[e.costTier]}),r&&(0,t.jsx)(f,{className:"stg:shrink-0 stg:text-primary"})]}),i&&e.shortDescription&&(0,t.jsx)("span",{className:"stg:mt-0.5 stg:block stg:text-left stg:text-[0.65rem] stg:text-muted-foreground",children:e.shortDescription})]})}function m(){return(0,t.jsx)("svg",{className:"stg:shrink-0 stg:text-muted-foreground",width:"10",height:"10",viewBox:"0 0 10 10",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:(0,t.jsx)("path",{d:"M2.5 3.75L5 6.25L7.5 3.75"})})}function f({className:e}){return(0,t.jsx)("svg",{className:e,width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,t.jsx)("path",{d:"M2 6L5 9L10 3"})})}function p(){return(0,t.jsxs)("svg",{width:"11",height:"11",viewBox:"0 0 12 12",fill:"none",stroke:"currentColor",strokeWidth:"1.2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":!0,children:[(0,t.jsx)("rect",{x:"1.5",y:"2",width:"9",height:"8",rx:"1.2"}),(0,t.jsx)("path",{d:"M1.5 8L4.2 5.6L6.4 7.6"}),(0,t.jsx)("circle",{cx:"7.6",cy:"4.6",r:"0.8",fill:"currentColor",stroke:"none"}),(0,t.jsx)("path",{d:"M1 1L11 11"})]})}function b(){return(0,t.jsx)("svg",{className:"stg:shrink-0",width:"8",height:"10",viewBox:"0 0 8 10",fill:"currentColor","aria-hidden":!0,children:(0,t.jsx)("path",{d:"M4.9 0.2L0.6 5.6h2.6L3.1 9.8l4.3-5.4H4.8L4.9 0.2z"})})}e.s(["ModelSelector",0,function({value:e,onValueChange:u,harness:d,initialHarness:p,onHarnessChange:v,onHarnessResolved:x,availableHarnesses:y,curatedModels:k,groupBy:A="provider",showSpeedBadge:w=!0,showDescriptions:E=!0,compact:S=!1,className:C,disabled:j,placeholderLabel:R,serviceTier:W="standard",onServiceTierChange:M,thinkingMode:N="disabled",onThinkingModeChange:I}){let _=(0,i.useStigmerPortalContainer)(),Z=void 0!==d,[G,V]=(0,r.useState)(d??p??"native"),L=d??G;(0,r.useEffect)(()=>{Z||void 0===p||V(p)},[p,Z]);let{models:Y,featured:F,defaultModel:B,getModel:T,byProvider:X,isLoading:D,error:O,refetch:K}=(0,o.useModelRegistry)({harness:L}),[P,z]=(0,r.useState)(!1),[U,J]=(0,r.useState)(!1),[H,Q]=(0,r.useState)(""),[$,q]=(0,r.useState)(!1),[ee,et]=(0,r.useState)(-1),er=(0,r.useRef)(null),en=(0,r.useRef)(null),es=(0,r.useMemo)(()=>y||l.HARNESS_OPTIONS.filter(e=>"native"===e||"cursor"===e),[y]),ei=(e?T(e):void 0)??B??void 0,ea=H.length>0,eo=H.toLowerCase(),el=(0,r.useMemo)(()=>k?new Set(k):null,[k]),ec=(0,r.useMemo)(()=>el?Y.filter(e=>el.has(e.modelId)):F,[Y,F,el]),eu=(0,r.useMemo)(()=>ea?Y.filter(e=>e.displayName.toLowerCase().includes(eo)||e.modelId.toLowerCase().includes(eo)||e.shortDescription.toLowerCase().includes(eo)):$?Y:ec.length>0?ec:Y,[Y,ec,ea,$,eo]),ed=(0,r.useMemo)(()=>{if(!$||"none"===A||ea)return null;let e=new Map;for(let t of Y){let r="provider"===A?t.provider:t.costTier,n=e.get(r);n?n.push(t):e.set(r,[t])}return e},[Y,$,A,ea]);(0,r.useEffect)(()=>{et(-1)},[eu]),(0,r.useEffect)(()=>{P||(Q(""),q(!1),et(-1),J(!1))},[P]),(0,r.useEffect)(()=>{P&&requestAnimationFrame(()=>er.current?.focus())},[P]);let eg=(0,r.useCallback)(e=>{V(e),v?.(e),x?.(e),q(!1),Q("")},[v,x]),eh=(0,r.useCallback)(e=>{u(e.modelId),"fast"===W&&M&&!e.serviceTiers.includes(c.FAST_SERVICE_TIER)&&M("standard"),"enabled"===N&&I&&!g(e)&&I("disabled"),z(!1)},[u,W,M,N,I]),em=(0,r.useCallback)(e=>{let t=en.current;if(!t)return;let r=t.querySelectorAll("[data-model-option]");r[e]?.scrollIntoView({block:"nearest"})},[]),ef=(0,r.useCallback)(e=>{let t=eu.length;if(0!==t)switch(e.key){case"ArrowDown":{e.preventDefault();let r=ee<t-1?ee+1:0;et(r),em(r);break}case"ArrowUp":{e.preventDefault();let r=ee>0?ee-1:t-1;et(r),em(r);break}case"Enter":{e.preventDefault();let t=ee>=0?eu[ee]:eu[0];t&&eh(t);break}case"Escape":e.preventDefault(),z(!1)}},[eu,ee,eh,em]),ep=!ea&&!$&&ec.length>0&&ec.length<Y.length,eb=void 0!==M&&void 0!==ei&&ei.serviceTiers.includes(c.FAST_SERVICE_TIER),ev="fast"===W&&(ei?.serviceTiers.includes(c.FAST_SERVICE_TIER)??!1),ex=void 0!==I&&void 0!==ei&&g(ei),ey="enabled"===N&&void 0!==ei&&g(ei),ek=!e&&void 0!==R,eA=ek?R:ei?.displayName??"Select model",ew=Z||ek?void 0:l.HARNESS_META[L].label;return(0,t.jsxs)(n.Popover.Root,{open:P,onOpenChange:z,children:[(0,t.jsxs)(n.Popover.Trigger,{disabled:j,className:(0,s.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:border stg:border-border","stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:hover:bg-accent-hover stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50","stg:transition-colors stg:max-w-[20rem] stg:max-sm:max-w-[12rem]",C),children:[ew&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-muted-foreground",children:ew}),ew&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-border","aria-hidden":!0,children:"·"}),(0,t.jsx)("span",{className:"stg:truncate",children:eA}),ev&&(0,t.jsxs)("span",{className:(0,s.cn)("stg:inline-flex stg:shrink-0 stg:items-center stg:gap-0.5 stg:rounded-full stg:border stg:border-primary stg:px-1.5 stg:py-px","stg:text-[0.6rem] stg:font-medium stg:uppercase stg:tracking-wider stg:text-primary"),children:[(0,t.jsx)(b,{}),"Fast"]}),ey&&(0,t.jsx)("span",{className:(0,s.cn)("stg:inline-flex stg:shrink-0 stg:items-center stg:gap-0.5 stg:rounded-full stg:border stg:border-primary stg:px-1.5 stg:py-px","stg:text-[0.6rem] stg:font-medium stg:uppercase stg:tracking-wider stg:text-primary"),children:"Thinking"}),(0,t.jsx)(m,{})]}),(0,t.jsx)(n.Popover.Portal,{container:_,children:(0,t.jsx)(n.Popover.Positioner,{sideOffset:4,children:(0,t.jsxs)(n.Popover.Popup,{role:"dialog","aria-label":"Model selector",className:(0,s.cn)("stg:z-popover stg:w-72 stg:rounded-lg stg:border stg:border-border stg:bg-popover stg:shadow-md","stg:text-popover-foreground"),children:[(0,t.jsxs)("div",{className:"stg:relative stg:flex stg:items-center stg:justify-between stg:border-b stg:border-border stg:px-3 stg:py-2",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:"Harness"}),(0,t.jsxs)("button",{type:"button","aria-haspopup":"listbox","aria-expanded":U,"aria-label":"Select harness",disabled:Z,className:(0,s.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:border stg:border-border","stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",Z?"stg:cursor-not-allowed stg:opacity-50":"stg:hover:bg-accent-hover"),onClick:()=>{Z||J(!U)},onKeyDown:e=>{"Escape"===e.key&&U&&(e.stopPropagation(),J(!1))},children:[(0,t.jsx)("span",{children:l.HARNESS_META[L].label}),!Z&&(0,t.jsx)(m,{})]}),!Z&&U&&(0,t.jsx)("div",{role:"listbox","aria-label":"Available harnesses",className:(0,s.cn)("stg:absolute stg:right-3 stg:top-full stg:z-10 stg:mt-1 stg:overflow-hidden stg:rounded-md stg:border stg:border-border","stg:bg-popover stg:shadow-md"),children:es.map(e=>{let r=e===L;return(0,t.jsxs)("button",{type:"button",role:"option","aria-selected":r,className:(0,s.cn)("stg:flex stg:w-full stg:items-center stg:gap-2 stg:px-2.5 stg:py-1.5 stg:text-xs stg:transition-colors","stg:hover:bg-accent-hover",r&&"stg:font-medium"),onClick:()=>{eg(e),J(!1)},children:[(0,t.jsx)("span",{className:"stg:flex-1 stg:text-left",children:l.HARNESS_META[e].label}),r&&(0,t.jsx)(f,{className:"stg:shrink-0 stg:text-primary"})]},e)})})]}),eb&&(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between stg:border-b stg:border-border stg:px-3 stg:py-2",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:text-foreground",children:"Fast tier"}),(0,t.jsx)("span",{className:"stg:text-[0.65rem] stg:text-muted-foreground",children:"Faster responses at higher per-token rates"})]}),(0,t.jsx)(a.Switch,{checked:ev,onCheckedChange:e=>M?.(e?"fast":"standard"),"aria-label":"Fast tier"})]}),ex&&(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between stg:border-b stg:border-border stg:px-3 stg:py-2",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:text-foreground",children:"Thinking"}),(0,t.jsx)("span",{className:"stg:text-[0.65rem] stg:text-muted-foreground",children:"Extended reasoning; uses more output tokens"})]}),(0,t.jsx)(a.Switch,{checked:ey,onCheckedChange:e=>I?.(e?"enabled":"disabled"),"aria-label":"Thinking"})]}),(0,t.jsx)("div",{className:"stg:border-b stg:border-border stg:px-3 stg:py-1.5",children:(0,t.jsx)("input",{ref:er,role:"searchbox","aria-label":"Search models",placeholder:"Search models…",value:H,onChange:e=>Q(e.target.value),onKeyDown:ef,className:(0,s.cn)("stg:w-full stg:bg-transparent stg:text-xs stg:text-foreground stg:placeholder:text-muted-foreground","stg:outline-none")})}),(0,t.jsxs)("div",{ref:en,role:"listbox","aria-label":"Available models",className:"stg:max-h-72 stg:overflow-y-auto stg:p-1",children:[0===eu.length&&D&&(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-center stg:gap-2 stg:px-2 stg:py-3",children:[(0,t.jsx)("div",{className:"stg:size-3 stg:animate-spin stg:rounded-full stg:border stg:border-muted stg:border-t-primary"}),(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:"Loading models…"})]}),0===eu.length&&!D&&null!=O&&(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:items-center stg:gap-1.5 stg:px-2 stg:py-3",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:"Failed to load models"}),(0,t.jsx)("button",{type:"button",className:(0,s.cn)("stg:rounded-md stg:border stg:border-border stg:bg-background stg:px-2.5 stg:py-1 stg:text-xs stg:text-foreground","stg:hover:bg-accent-hover stg:transition-colors stg:cursor-pointer"),onClick:K,children:"Retry"})]}),0===eu.length&&!D&&null==O&&(0,t.jsx)("div",{className:"stg:px-2 stg:py-3 stg:text-center stg:text-xs stg:text-muted-foreground",children:"No models found"}),ed?Array.from(ed.entries()).map(([e,r])=>(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"stg:px-2 stg:pb-0.5 stg:pt-2 stg:text-[0.6rem] stg:font-medium stg:uppercase stg:tracking-wider stg:text-muted-foreground",children:e}),r.map(e=>(0,t.jsx)(h,{model:e,isSelected:e.modelId===ei?.modelId,showDescription:!1,showSpeedBadge:w,onClick:()=>eh(e)},e.modelId))]},e)):eu.map((e,r)=>(0,t.jsx)(h,{model:e,isSelected:e.modelId===ei?.modelId,isHighlighted:r===ee,showDescription:E&&!S&&!ea&&!$,showSpeedBadge:w,onClick:()=>eh(e),onMouseEnter:()=>et(r)},e.modelId)),ep&&(0,t.jsx)("button",{type:"button",className:(0,s.cn)("stg:mt-1 stg:flex stg:w-full stg:items-center stg:justify-center stg:rounded-md stg:border stg:border-dashed stg:border-border","stg:px-2 stg:py-1.5 stg:text-xs stg:text-muted-foreground","stg:hover:bg-accent-hover stg:hover:text-foreground stg:transition-colors stg:cursor-pointer"),onClick:()=>q(!0),children:"Show all models"})]})]})})})]})}])},526025,e=>{"use strict";e.s(["channelSessionExternalUserKey",0,function(e){return e?.metadata?.labels?.["stigmer.ai/channel-external-user-key"]},"isChannelOriginSession",0,function(e){return!!e?.metadata?.labels?.["stigmer.ai/channel-id"]}])},590745,e=>{"use strict";var t=e.i(414385);e.i(222258);var r=e.i(967785),n=e.i(310713);e.s(["serializeManifest",0,function(e){var s;let i=(0,n.manifestHandlerForTypeName)(e.$typeName);if(void 0===i){let t=(0,n.manifestKinds)().map(e=>e.yamlKind).join(", ");throw Error(`Cannot serialize ${e.$typeName} as a manifest: kind is not in the manifest registry. Supported kinds: ${t}.`)}let a=(0,t.toJson)(i.schema,e,{useProtoFieldName:!0});if(null===a||"object"!=typeof a||Array.isArray(a))throw Error(`Cannot serialize ${i.displayName}: unexpected non-object protojson projection.`);let{api_version:o,kind:l,status:c,metadata:u,...d}=a,g={apiVersion:"string"==typeof o&&""!==o?o:i.apiVersion,kind:"string"==typeof l&&""!==l?l:i.yamlKind,..."object"==typeof(s=u)&&null!==s&&!Array.isArray(s)&&{metadata:function(e){let{version:t,...r}=e;return r}(u)},...d};return(0,r.stringify)(g,{lineWidth:0,blockQuote:"literal"})}])},926059,e=>{"use strict";e.i(222258);var t=e.i(967785),r=e.i(735922);function n(e){var t;let r={name:e.name,kind:(t=e.kind,s.get(t)??`unknown_${t}`)};return e.taskConfig&&Object.keys(e.taskConfig).length>0&&(r.task_config=function e(t){if(null==t)return t;if("bigint"==typeof t)return Number(t);if("object"!=typeof t)return t;if(Array.isArray(t))return t.map(e);let r={};for(let[n,s]of Object.entries(t))r[n]=e(s);return r}(e.taskConfig)),e.export?.as&&(r.export={as:e.export.as}),e.flow?.then&&(r.flow={then:e.flow.then}),r}let s=new Map(Object.entries(r.WorkflowTaskKind).filter(e=>"number"==typeof e[1]&&e[1]!==r.WorkflowTaskKind.workflow_task_kind_unspecified).map(([e,t])=>[t,e])),i=new Map(Array.from(s.entries()).map(([e,t])=>[t,e])),a=new Map([[r.BudgetExceededPolicy.budget_exceeded_terminate,"budget_exceeded_terminate"],[r.BudgetExceededPolicy.budget_exceeded_human_review,"budget_exceeded_human_review"],[r.BudgetExceededPolicy.budget_exceeded_warn,"budget_exceeded_warn"]]),o=new Map(Array.from(a.entries()).map(([e,t])=>[t,e]));function l(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)}function c(e,t,r){let n=e[t];if("string"!=typeof n||0===n.length)throw Error(`Workflow YAML is missing required field: ${r}.`);return n}function u(e,t){let r=e[t];return"string"==typeof r&&r.length>0?r:void 0}function d(e){if("bigint"==typeof e)return e;if("number"==typeof e&&Number.isFinite(e))return BigInt(Math.round(e));if("string"==typeof e)try{return BigInt(e)}catch{}}e.s(["parseWorkflowYaml",0,function(e,r){let n=function(e){let r;try{r=(0,t.parse)(e)}catch{throw Error("Failed to parse content as YAML.")}if(!l(r))throw Error("YAML must be a mapping document, not a scalar or list.");return r}(e);var s=n;let a=s.kind;if("string"==typeof a&&"Workflow"!==a)throw Error(`Expected resource kind "Workflow", got "${a}".`);if(!l(s.metadata))throw Error("Workflow YAML is missing required field: metadata.");if(!l(s.spec))throw Error("Workflow YAML is missing required field: spec.");let g=n.metadata,h=n.spec,m=c(g,"name","metadata.name"),f=u(g,"slug"),p=function(e,t){let r=e[t];if(!l(r))return;let n={},s=!1;for(let[e,t]of Object.entries(r))"string"==typeof t&&(n[e]=t,s=!0);return s?n:void 0}(g,"labels"),b=function(e){let t=e.document;if(!l(t))throw Error("Workflow YAML is missing required field: spec.document.");return{dsl:u(t,"dsl")??"1.0.0",namespace:c(t,"namespace","spec.document.namespace"),name:c(t,"name","spec.document.name"),version:c(t,"version","spec.document.version"),...t.description&&"string"==typeof t.description?{description:t.description}:{}}}(h),v=function(e){let t=e.tasks;if(!Array.isArray(t)||0===t.length)throw Error("Workflow YAML is missing required field: spec.tasks (must be a non-empty list).");return t.filter(l).map((e,t)=>{var r;let n=e.name;if("string"!=typeof n||0===n.length)throw Error(`Workflow YAML: task at index ${t} is missing required field: name.`);let s=e.kind;if("string"!=typeof s||0===s.length)throw Error(`Workflow YAML: task "${n}" is missing required field: kind.`);let a=(r=s,i.get(r));if(void 0===a)throw Error(`Workflow YAML: task "${n}" has unknown kind "${s}".`);let o=e.task_config??e.taskConfig;if(!l(o))throw Error(`Workflow YAML: task "${n}" is missing required field: task_config.`);let c=e.export??e.export,u=e.flow,d={name:n,kind:a,taskConfig:o};if(l(c)){let e=c.as;"string"==typeof e&&e.length>0&&(d.export={as:e})}if(l(u)){let e=u.then;"string"==typeof e&&e.length>0&&(d.flow={then:e})}return d})}(h),x=function(e){let t=e.env;if(!l(t))return;let r={},n=!1;for(let[e,s]of Object.entries(t)){if(!l(s))continue;let t=s.is_secret??s.isSecret,i=s.description,a=s.optional;r[e]={..."boolean"==typeof t&&{isSecret:t},..."string"==typeof i&&{description:i},..."boolean"==typeof a&&{optional:a}},n=!0}return n?r:void 0}(h),y=function(e){var t;let r=e.budget;if(!l(r))return;let n=d(r.max_cost_micros??r.maxCostMicros),s=d(r.max_total_tokens??r.maxTotalTokens),i=function(e){if("number"==typeof e&&Number.isFinite(e))return e;if("string"==typeof e){let t=Number(e);return Number.isFinite(t)?t:void 0}}(r.max_duration_seconds??r.maxDurationSeconds),a=r.on_exceeded??r.onExceeded,c="string"==typeof a?(t=a,o.get(t)):void 0;if(void 0!==n&&n>BigInt(0)||void 0!==s&&s>BigInt(0)||void 0!==i&&i>0)return{...void 0!==n&&{maxCostMicros:n},...void 0!==s&&{maxTotalTokens:s},...void 0!==i&&{maxDurationSeconds:i},...void 0!==c&&{onExceeded:c}}}(h),k=u(h,"description");return{name:m,org:r,...void 0!==f&&{slug:f},...void 0!==p&&{labels:p},...void 0!==k&&{description:k},document:b,tasks:v,...void 0!==x&&{env:x},...void 0!==y&&{budget:y}}},"serializeWorkflowYaml",0,function(e){let s={apiVersion:e.apiVersion||"agentic.stigmer.ai/v1",kind:e.kind||"Workflow",metadata:function(e){let t=e.metadata;if(!t)return{};let r={name:t.name};return t.org&&(r.org=t.org),t.slug&&t.slug!==t.name&&(r.slug=t.slug),t.labels&&Object.keys(t.labels).length>0&&(r.labels={...t.labels}),r}(e),spec:function(e){var t,s,i,o;let l,c,u,d;if(!e)return{};let g={};return e.description&&(g.description=e.description),e.document&&(t=e.document,l={},t.dsl&&(l.dsl=t.dsl),t.namespace&&(l.namespace=t.namespace),t.name&&(l.name=t.name),t.version&&(l.version=t.version),t.description&&(l.description=t.description),g.document=l),e.tasks.length>0&&(g.tasks=e.tasks.map(n)),e.env&&Object.keys(e.env).length>0&&(g.env=function(e){let t={};for(let[r,n]of Object.entries(e)){let e={};n.isSecret&&(e.is_secret=!0),n.description&&(e.description=n.description),n.optional&&(e.optional=!0),t[r]=e}return t}(e.env)),e.budget&&(Number((s=e.budget).maxCostMicros)>0||Number(s.maxTotalTokens)>0||s.maxDurationSeconds>0)&&(i=e.budget,c={},u=Number(i.maxCostMicros),d=Number(i.maxTotalTokens),u>0&&(c.max_cost_micros=u),d>0&&(c.max_total_tokens=d),i.maxDurationSeconds>0&&(c.max_duration_seconds=i.maxDurationSeconds),i.onExceeded!==r.BudgetExceededPolicy.budget_exceeded_policy_unspecified&&(o=i.onExceeded,c.on_exceeded=a.get(o)??"budget_exceeded_policy_unspecified"),g.budget=c),g}(e.spec)};return(0,t.stringify)(s,{lineWidth:0,blockQuote:"literal"})}])},745176,e=>{"use strict";e.s(["downloadTextFile",0,function(e,t,r){let n=new Blob([e],{type:`${r};charset=utf-8;`}),s=URL.createObjectURL(n),i=document.createElement("a");i.href=s,i.download=t,i.style.display="none",document.body.appendChild(i),i.click(),document.body.removeChild(i),URL.revokeObjectURL(s)}])},475254,e=>{"use strict";var t=e.i(271645);let r=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim(),n=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)};var s={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let i=(0,t.forwardRef)(({color:e="currentColor",size:n=24,strokeWidth:i=2,absoluteStrokeWidth:a,className:o="",children:l,iconNode:c,...u},d)=>(0,t.createElement)("svg",{ref:d,...s,width:n,height:n,stroke:e,strokeWidth:a?24*Number(i)/Number(n):i,className:r("lucide",o),...!l&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0;return!1})(u)&&{"aria-hidden":"true"},...u},[...c.map(([e,r])=>(0,t.createElement)(e,r)),...Array.isArray(l)?l:[l]]));e.s(["default",0,(e,s)=>{let a=(0,t.forwardRef)(({className:a,...o},l)=>(0,t.createElement)(i,{ref:l,iconNode:s,className:r(`lucide-${n(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,a),...o}));return a.displayName=n(e),a}],475254)},678745,e=>{"use strict";let t=(0,e.i(475254).default)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);e.s(["default",0,t])},845132,678784,916624,e=>{"use strict";var t=e.i(843476),r=e.i(893976),n=e.i(704077),s=e.i(678745);e.s(["CheckIcon",()=>s.default],678784);var s=s,i=e.i(364354);function a(e){return(0,t.jsx)(n.Menu.Root,{...e})}function o(e){return(0,t.jsx)(n.Menu.Trigger,{...e})}function l({align:e="start",alignOffset:s=0,side:a="bottom",sideOffset:o=4,className:c,...u}){let d=(0,i.useStigmerPortalContainer)();return(0,t.jsx)(n.Menu.Portal,{container:d,children:(0,t.jsx)(n.Menu.Positioner,{className:"stg:isolate stg:z-50 stg:outline-none",align:e,alignOffset:s,side:a,sideOffset:o,children:(0,t.jsx)(n.Menu.Popup,{className:(0,r.cn)("stg:bg-popover stg:text-popover-foreground stg:ring-foreground/10","stg:data-[side=bottom]:slide-in-from-top-2 stg:data-[side=inline-end]:slide-in-from-left-2 stg:data-[side=inline-start]:slide-in-from-right-2 stg:data-[side=left]:slide-in-from-right-2 stg:data-[side=right]:slide-in-from-left-2 stg:data-[side=top]:slide-in-from-bottom-2","stg:data-open:animate-in stg:data-open:fade-in-0 stg:data-open:zoom-in-95","stg:data-closed:animate-out stg:data-closed:fade-out-0 stg:data-closed:zoom-out-95","stg:z-50 stg:max-h-(--available-height) stg:w-(--anchor-width) stg:min-w-32 stg:origin-(--transform-origin) stg:overflow-x-hidden stg:overflow-y-auto stg:rounded-lg stg:p-1 stg:shadow-md stg:ring-1 stg:duration-100 stg:outline-none stg:data-closed:overflow-hidden",c),...u})})})}function c({className:e,variant:s="default",...i}){return(0,t.jsx)(n.Menu.Item,{"data-variant":s,className:(0,r.cn)("stg:focus:bg-accent stg:focus:text-accent-foreground stg:not-data-[variant=destructive]:focus:**:text-accent-foreground","stg:data-[variant=destructive]:text-destructive stg:data-[variant=destructive]:focus:bg-destructive-subtle stg:data-[variant=destructive]:focus:text-destructive stg:data-[variant=destructive]:*:[svg]:text-destructive","stg:relative stg:flex stg:cursor-default stg:items-center stg:gap-1.5 stg:rounded-md stg:px-1.5 stg:py-1 stg:text-sm stg:outline-hidden stg:select-none","stg:data-disabled:pointer-events-none stg:data-disabled:opacity-50","stg:[&_svg]:pointer-events-none stg:[&_svg]:shrink-0 stg:[&_svg:not([class*='size-'])]:size-4",e),...i})}function u({className:e,...s}){return(0,t.jsx)(n.Menu.Separator,{className:(0,r.cn)("stg:bg-border stg:-mx-1 stg:my-1 stg:h-px",e),...s})}function d({className:e,...r}){return(0,t.jsx)("div",{role:"group",className:e,...r})}function g({className:e,...n}){return(0,t.jsx)("span",{className:(0,r.cn)("stg:text-muted-foreground stg:block stg:px-1.5 stg:py-1 stg:text-[11px] stg:font-medium stg:uppercase stg:tracking-wider stg:select-none",e),...n})}e.s(["Menu",0,a,"MenuContent",0,l,"MenuGroup",0,d,"MenuItem",0,c,"MenuLabel",0,g,"MenuRadioGroup",0,function(e){return(0,t.jsx)(n.Menu.RadioGroup,{...e})},"MenuRadioItem",0,function({className:e,children:i,...a}){return(0,t.jsxs)(n.Menu.RadioItem,{className:(0,r.cn)("stg:focus:bg-accent stg:focus:text-accent-foreground stg:focus:**:text-accent-foreground","stg:relative stg:flex stg:cursor-default stg:items-center stg:gap-1.5 stg:rounded-md stg:py-1 stg:pr-8 stg:pl-1.5 stg:text-sm stg:outline-hidden stg:select-none","stg:data-disabled:pointer-events-none stg:data-disabled:opacity-50","stg:[&_svg]:pointer-events-none stg:[&_svg]:shrink-0 stg:[&_svg:not([class*='size-'])]:size-4",e),...a,children:[(0,t.jsx)("span",{className:"stg:pointer-events-none stg:absolute stg:right-2 stg:flex stg:items-center stg:justify-center",children:(0,t.jsx)(n.Menu.RadioItemIndicator,{children:(0,t.jsx)(s.default,{})})}),i]})},"MenuSeparator",0,u,"MenuTrigger",0,o],916624);let h=Object.assign(function({children:e}){return(0,t.jsx)(a,{children:e})},{Trigger:function({children:e,className:n,"aria-label":s="Actions"}){return(0,t.jsx)(o,{className:(0,r.cn)("stg:inline-flex stg:items-center stg:justify-center stg:rounded-md stg:p-1","stg:text-muted-foreground stg:hover:text-foreground stg:hover:bg-accent","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:data-popup-open:bg-accent stg:data-popup-open:text-foreground",n),"aria-label":s,children:e})},Content:function({children:e,align:n="end",className:s}){return(0,t.jsx)(l,{align:n,className:(0,r.cn)("stg:min-w-44",s),children:e})},Item:function({children:e,onSelect:n,icon:s,shortcut:i,variant:a="default",disabled:o,className:l}){return(0,t.jsxs)(c,{variant:a,disabled:o,onClick:n,className:(0,r.cn)("stg:justify-between",l),children:[(0,t.jsxs)("span",{className:"stg:flex stg:items-center stg:gap-2",children:[s,(0,t.jsx)("span",{children:e})]}),i&&(0,t.jsx)("kbd",{className:"stg:ml-auto stg:text-[11px] stg:tracking-widest stg:text-muted-foreground-subtle",children:i})]})},Separator:function({className:e}){return(0,t.jsx)(u,{className:e})},Group:function({children:e,label:r,className:n}){return(0,t.jsxs)(d,{className:n,children:[r&&(0,t.jsx)(g,{children:r}),e]})}});e.s(["ActionMenu",0,h],845132)},107141,e=>{"use strict";var t=e.i(271645),r=e.i(618566);let n="__placeholder__";e.s(["useStaticRouteParam",0,function(e,s=1){let i=(0,r.useParams)()[e];return(0,t.useMemo)(()=>{if(i!==n)return i;let e=window.location.pathname.split("/").filter(Boolean),t=e[e.length-s];return t&&t!==n?t:null},[i,s])}])},361353,e=>{"use strict";e.s(["formatRelativeTime",0,function(e,t){let r=t??new Date,n=r.getTime()-e.getTime();if(n<6e4)return"now";let s=Math.floor(n/6e4);if(s<60)return`${s}m`;let i=Math.floor(s/60);if(i<24)return`${i}h`;let a=Math.floor(i/24);if(a<7)return`${a}d`;let o=e.getFullYear()===r.getFullYear();return e.toLocaleDateString(void 0,{month:"short",day:"numeric",...o?{}:{year:"numeric"}})}])},312056,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(618566);let s=(0,r.createContext)(null);function i(){return window.location.pathname}e.s(["AppNavigationProvider",0,function({children:e}){let[a,o]=(0,r.useState)(i),l=(0,r.useRef)(a);(0,r.useEffect)(()=>{l.current=a},[a]);let c=(0,n.usePathname)(),[u,d]=(0,r.useState)(c);c!==u&&(d(c),c!==a&&o(c));let g=(0,r.useCallback)(e=>{e!==l.current&&(o(e),window.history.pushState(null,"",e))},[]);(0,r.useEffect)(()=>{function e(){o(window.location.pathname)}return window.addEventListener("popstate",e),()=>window.removeEventListener("popstate",e)},[]);let h=(0,r.useMemo)(()=>({currentPath:a,navigate:g}),[a,g]);return(0,t.jsx)(s.Provider,{value:h,children:e})},"useAppNavigation",0,function(){let e=(0,r.useContext)(s);if(!e)throw Error("useAppNavigation must be used within <AppNavigationProvider>");return e}])},635549,e=>{"use strict";var t=e.i(271645),r=e.i(312056);let n=/^\/executions\/(.+)/;e.s(["useExecutionNavigation",0,function(){let{currentPath:e,navigate:s}=(0,r.useAppNavigation)(),i=n.test(e);return{activeExecutionId:i?e.match(n)?.[1]??null:null,isExecutionZone:i,navigateToExecution:(0,t.useCallback)(e=>{s(`/executions/${e}`)},[s])}}])},244686,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(566022),s=e.i(893976);let i=new Map([[n.ExecutionPhase.EXECUTION_PENDING,{label:"Pending",icon:o,colorClass:"stg:text-muted-foreground"}],[n.ExecutionPhase.EXECUTION_IN_PROGRESS,{label:"Running",icon:o,colorClass:"stg:text-foreground"}],[n.ExecutionPhase.EXECUTION_COMPLETED,{label:"Completed",icon:function(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,t.jsx)("path",{d:"M2.5 6L5 8.5L9.5 3.5"})})},colorClass:"stg:text-success"}],[n.ExecutionPhase.EXECUTION_FAILED,{label:"Failed",icon:l,colorClass:"stg:text-destructive"}],[n.ExecutionPhase.EXECUTION_CANCELLED,{label:"Cancelled",icon:l,colorClass:"stg:text-muted-foreground"}],[n.ExecutionPhase.EXECUTION_TERMINATED,{label:"Terminated",icon:function(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"currentColor",children:(0,t.jsx)("rect",{x:"2",y:"2",width:"8",height:"8",rx:"1"})})},colorClass:"stg:text-destructive"}],[n.ExecutionPhase.EXECUTION_PAUSED,{label:"Paused",icon:function(){return(0,t.jsxs)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"currentColor",children:[(0,t.jsx)("rect",{x:"2.5",y:"2",width:"2.5",height:"8",rx:"0.5"}),(0,t.jsx)("rect",{x:"7",y:"2",width:"2.5",height:"8",rx:"0.5"})]})},colorClass:"stg:text-muted-foreground"}]]),a=(0,r.memo)(function({phase:e,className:r}){let n=i.get(e);if(!n)return null;let a=n.icon;return(0,t.jsxs)("span",{role:"status","aria-label":n.label,className:(0,s.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:text-xs stg:font-medium",n.colorClass,r),children:[(0,t.jsx)("span",{"aria-hidden":"true",children:(0,t.jsx)(a,{})}),n.label]})});function o(){return(0,t.jsxs)("span",{className:"stg:relative stg:flex stg:h-2 stg:w-2",children:[(0,t.jsx)("span",{className:"stg:absolute stg:inline-flex stg:h-full stg:w-full stg:animate-ping stg:rounded-full stg:bg-current stg:opacity-75"}),(0,t.jsx)("span",{className:"stg:relative stg:inline-flex stg:h-2 stg:w-2 stg:rounded-full stg:bg-current"})]})}function l(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,t.jsx)("path",{d:"M3 3L9 9M9 3L3 9"})})}e.s(["WorkflowExecutionPhaseBadge",0,a])},879738,e=>{"use strict";var t=e.i(891287),r=e.i(218766),n=e.i(586108),s=e.i(583093);let i={executions:[],totalPages:0};e.s(["useWorkflowExecutionList",0,function(e){let a=(0,n.useStigmer)(),o=e?.pageSize??20,l=e?.pageToken??"",c=e?.workflowId??null,u=e?.org??"",d=async()=>{if(c){let e=await a.workflowExecution.listByWorkflow((0,t.create)(r.ListWorkflowExecutionsByWorkflowRequestSchema,{workflowId:c,pageSize:o,pageToken:l}));return{executions:[...e.entries],totalPages:e.totalPages}}let e=await a.workflowExecution.list((0,t.create)(r.ListWorkflowExecutionsRequestSchema,{pageSize:o,pageToken:l,org:u}));return{executions:[...e.entries],totalPages:e.totalPages}},{data:g,isLoading:h,isRefetching:m,error:f,refetch:p}=(0,s.useFetch)(d,[a,c,u,o,l],i);return{executions:g.executions,totalPages:g.totalPages,isLoading:h,isRefetching:m,error:f,refetch:p}}])},267460,e=>{"use strict";let t=BigInt(0);function r(e){if(e<1e3)return`${e}ms`;let t=e/1e3;if(t<60)return`${t.toFixed(1)}s`;let r=Math.floor(t/60),n=Math.round(t%60);if(r<60)return n>0?`${r}m ${n}s`:`${r}m`;let s=Math.floor(r/60),i=r%60;return i>0?`${s}h ${i}m`:`${s}h`}function n(e){let t=Number(e)/1e6;return t<.01?`$${t.toFixed(4)}`:`$${t.toFixed(2)}`}e.s(["formatDuration",0,r,"formatDurationSec",0,function(e){if(e<60)return`${Math.round(e)}s`;if(e<3600){let t=Math.floor(e/60),r=Math.round(e%60);return r>0?`${t}m ${r}s`:`${t}m`}let t=Math.floor(e/3600),r=Math.floor(e%3600/60);return r>0?`${t}h ${r}m`:`${t}h`},"formatMetaChips",0,function(e){let s=[];return e.durationMs&&e.durationMs>0&&s.push(r(e.durationMs)),e.costMicros&&e.costMicros>t&&s.push(n(e.costMicros)),e.tokens&&e.tokens>t&&s.push(`${e.tokens.toLocaleString()} tok`),s.length>0?s.join(" · "):null},"formatMicroUsd",0,n,"formatTimestamp",0,function(e){if(!e)return"";try{let t=new Date(e);if(Number.isNaN(t.getTime()))return e;return t.toLocaleTimeString(void 0,{hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1})}catch{return e}},"formatTokenCount",0,function(e){let t=Number(e);return t>=1e6?`${(t/1e6).toFixed(1)}M`:t>=1e3?`${(t/1e3).toFixed(1)}K`:t.toLocaleString()}])},911237,e=>{"use strict";var t=e.i(566022);BigInt(0);let r=new Set([t.WorkflowTaskStatus.WORKFLOW_TASK_COMPLETED,t.WorkflowTaskStatus.WORKFLOW_TASK_FAILED,t.WorkflowTaskStatus.WORKFLOW_TASK_SKIPPED]);function n(e){if(!e)return null;let t=new Date(e);return Number.isNaN(t.getTime())?null:t}function s(e){let s=e.metadata,i=e.status,a=i?.tasks??[],o=n(i?.startedAt),l=n(i?.completedAt),c=null;o&&l?c=l.getTime()-o.getTime():o&&i?.phase===t.ExecutionPhase.EXECUTION_IN_PROGRESS&&(c=Date.now()-o.getTime());let u=null,d=null,g=0,h=0,m=!1;for(let e of a)r.has(e.status)&&g++,u||e.status!==t.WorkflowTaskStatus.WORKFLOW_TASK_FAILED||(u=e.taskName||null),d||e.status!==t.WorkflowTaskStatus.WORKFLOW_TASK_IN_PROGRESS||(d=e.taskName||null),e.status===t.WorkflowTaskStatus.WORKFLOW_TASK_WAITING_APPROVAL&&(m=!0,d||(d=e.taskName||null)),h+=function(e){if(!e?.fields)return 0;let t=e.fields.retry_count??e.fields.retryCount;return t&&"object"==typeof t&&null!==t&&"numberValue"in t?Math.max(0,Math.floor(t.numberValue??0)):0}(e.metadata);let f=BigInt(i?.totalCostMicros??0),p=BigInt(i?.totalInputTokens??0),b=BigInt(i?.totalOutputTokens??0);return{id:s?.id??"",name:s?.name||s?.slug||"",phase:i?.phase??t.ExecutionPhase.EXECUTION_PHASE_UNSPECIFIED,startedAt:o,completedAt:l,durationMs:c,costMicros:f,inputTokens:p,outputTokens:b,totalTokens:p+b,taskCount:a.length,completedTaskCount:g,failedTaskName:u,currentTaskName:d,retryCount:h,hasHumanWait:m,error:i?.error||null,_source:e}}let i={name:(e,t)=>e.name.localeCompare(t.name),phase:(e,t)=>e.phase-t.phase,startedAt:(e,t)=>(e.startedAt?.getTime()??0)-(t.startedAt?.getTime()??0),duration:(e,t)=>(e.durationMs??-1)-(t.durationMs??-1),cost:(e,t)=>Number(e.costMicros-t.costMicros),tokens:(e,t)=>Number(e.totalTokens-t.totalTokens),tasks:(e,t)=>e.taskCount-t.taskCount};e.s(["deriveExecutionRow",0,s,"deriveExecutionRows",0,function(e){return e.map(s)},"filterExecutionRows",0,function(e,t){return e.filter(e=>(!t.phases?.length||!!t.phases.includes(e.phase))&&(null==t.minDurationMs||!((e.durationMs??-1)<t.minDurationMs))&&(null==t.maxDurationMs||!((e.durationMs??1/0)>t.maxDurationMs))&&(null==t.minCostMicros||!(e.costMicros<t.minCostMicros))&&(null==t.maxCostMicros||!(e.costMicros>t.maxCostMicros))&&(!t.failedTaskName||e.failedTaskName===t.failedTaskName)&&(!t.hasRetries||0!==e.retryCount)&&!0)},"sortExecutionRows",0,function(e,t,r){let n=i[t],s="desc"===r?-1:1;return[...e].sort((e,t)=>s*n(e,t))}])},640524,e=>{"use strict";let t=(0,e.i(475254).default)("workflow",[["rect",{width:"8",height:"8",x:"3",y:"3",rx:"2",key:"by2w9f"}],["path",{d:"M7 11v4a2 2 0 0 0 2 2h4",key:"xkn7yn"}],["rect",{width:"8",height:"8",x:"13",y:"13",rx:"2",key:"1cgmvn"}]]);e.s(["Workflow",0,t],640524)},615987,e=>{"use strict";var t=e.i(586108),r=e.i(583093);e.s(["useMyIdentityAccount",0,function(e){let n=(0,t.useStigmer)(),s=e?.enabled??!0,{data:i,isLoading:a,isRefetching:o,error:l,refetch:c}=(0,r.useFetch)(s?()=>n.identityAccount.whoAmI():null,[n,s],null,{cacheKey:s?"identity-account:me":void 0});return{account:i,isLoading:a,isRefetching:o,error:l,refetch:c}}])},21218,e=>{"use strict";let t=(0,e.i(475254).default)("activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);e.s(["Activity",0,t],21218)},607486,e=>{"use strict";let t=(0,e.i(475254).default)("building-2",[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]]);e.s(["Building2",0,t],607486)},20753,e=>{"use strict";var t=e.i(271645),r=e.i(981922),n=e.i(21218),s=e.i(475254);let i=(0,s.default)("app-window",[["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}],["path",{d:"M10 4v4",key:"pp8u80"}],["path",{d:"M2 8h20",key:"d11cs7"}],["path",{d:"M6 4v4",key:"1svtjw"}]]),a=(0,s.default)("chart-column",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]),o=(0,s.default)("box",[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]),l=(0,s.default)("brain",[["path",{d:"M12 18V5",key:"adv99a"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4",key:"1e3is1"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5",key:"1gqd8o"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77",key:"iwvgf7"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464",key:"efp6ie"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517",key:"1gq6am"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464",key:"k1g0md"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77",key:"q97ue3"}]]);var c=e.i(607486);let u=(0,s.default)("credit-card",[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]]);var d=e.i(465261);let g=(0,s.default)("link",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]]);var h=e.i(686311);let m=(0,s.default)("mouse-pointer-click",[["path",{d:"M14 4.1 12 6",key:"ita8i4"}],["path",{d:"m5.1 8-2.9-.8",key:"1go3kf"}],["path",{d:"m6 12-1.9 2",key:"mnht97"}],["path",{d:"M7.2 2.2 8 5.1",key:"1cfko1"}],["path",{d:"M9.037 9.69a.498.498 0 0 1 .653-.653l11 4.5a.5.5 0 0 1-.074.949l-4.349 1.041a1 1 0 0 0-.74.739l-1.04 4.35a.5.5 0 0 1-.95.074z",key:"s0h3yz"}]]),f=(0,s.default)("plug",[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z",key:"1xoxul"}],["path",{d:"M9 8V2",key:"14iosj"}]]),p=(0,s.default)("scale",[["path",{d:"M12 3v18",key:"108xh3"}],["path",{d:"m19 8 3 8a5 5 0 0 1-6 0zV7",key:"zcdpyk"}],["path",{d:"M3 7h1a17 17 0 0 0 8-2 17 17 0 0 0 8 2h1",key:"1yorad"}],["path",{d:"m5 8 3 8a5 5 0 0 1-6 0zV7",key:"eua70x"}],["path",{d:"M7 21h10",key:"1b0cd5"}]]),b=(0,s.default)("shield-check",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);var v=e.i(649582);let x=(0,s.default)("user-cog",[["path",{d:"M10 15H6a4 4 0 0 0-4 4v2",key:"1nfge6"}],["path",{d:"m14.305 16.53.923-.382",key:"1itpsq"}],["path",{d:"m15.228 13.852-.923-.383",key:"eplpkm"}],["path",{d:"m16.852 12.228-.383-.923",key:"13v3q0"}],["path",{d:"m16.852 17.772-.383.924",key:"1i8mnm"}],["path",{d:"m19.148 12.228.383-.923",key:"1q8j1v"}],["path",{d:"m19.53 18.696-.382-.924",key:"vk1qj3"}],["path",{d:"m20.772 13.852.924-.383",key:"n880s0"}],["path",{d:"m20.772 16.148.924.383",key:"1g6xey"}],["circle",{cx:"18",cy:"15",r:"3",key:"gjjjvw"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]]),y=(0,s.default)("users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]]),k=[{label:"Organization",description:"Manage your team, organization identity, and identity providers.",items:[{href:"/settings/org-profile",label:"Org Profile",icon:c.Building2},{href:"/settings/org-preferences",label:"Preferences",icon:v.SlidersHorizontal},{href:"/settings/members",label:"Members",icon:y},{href:"/settings/invitations",label:"Invitations",icon:g},{href:"/settings/identity-providers",label:"Identity Providers",icon:b}]},{label:"Configuration",description:"API keys, environment variables, and OAuth app credentials for your integrations.",items:[{href:"/settings/api-keys",label:"API Keys",icon:d.KeyRound},{href:"/settings/platform-clients",label:"Platform Clients",icon:f},{href:"/settings/environments",label:"Environments",icon:o},{href:"/settings/oauth-apps",label:"OAuth Apps",icon:i},{href:"/settings/channel-apps",label:"Channel Apps",icon:h.MessageSquare}]},{label:"Billing & Usage",description:"Credit management and usage metrics.",items:[{href:"/settings/billing",label:"Billing",icon:u},{href:"/settings/usage",label:"Usage",icon:a}]},{label:"Account",description:"Personal settings that apply to you across the platform.",items:[{href:"/settings/account-preferences",label:"Preferences",icon:x},{href:"/settings/memory",label:"Memory",icon:l}]}],A={label:"Platform",description:"Stigmer-internal operations. Visible to platform operators only.",items:[{href:"/settings/pricing-governance",label:"Pricing Governance",icon:p,requiredPermission:"can_manage_model_pricing"},{href:"/settings/cursor-accounts",label:"Cursor Accounts",icon:m,requiredPermission:"can_manage_cursor_accounts"},{href:"/settings/provider-standing",label:"Provider Standing",icon:n.Activity,requiredPermission:"can_view_provider_standing"}]},w={kind:"platform",id:"stigmer"};e.s(["useSettingsNavGroups",0,function(){let e=(0,r.useCheckPermission)(w,"can_manage_model_pricing",{fail:"closed"}),n=(0,r.useCheckPermission)(w,"can_manage_cursor_accounts",{fail:"closed"}),s=(0,r.useCheckPermission)(w,"can_view_provider_standing",{fail:"closed"}),i=e.allowed,a=n.allowed,o=s.allowed;return(0,t.useMemo)(()=>{let e={can_manage_model_pricing:i,can_manage_cursor_accounts:a,can_view_provider_standing:o},t=A.items.filter(t=>void 0!==t.requiredPermission&&!0===e[t.requiredPermission]);return 0===t.length?k:[...k,{...A,items:t}]},[i,a,o])}],20753)},781195,e=>{e.v(t=>Promise.all(["static/chunks/0n2qydw3oc1oj.js","static/chunks/0g4_345f39a55.js"].map(t=>e.l(t))).then(()=>t(791738)))},769781,e=>{e.v(t=>Promise.all(["static/chunks/06huuay3x3z07.js"].map(t=>e.l(t))).then(()=>t(347442)))},321591,e=>{e.v(t=>Promise.all(["static/chunks/01.9x7hzkgv7j.js"].map(t=>e.l(t))).then(()=>t(236863)))},695802,e=>{e.v(t=>Promise.all(["static/chunks/0hhe78mplcj67.js","static/chunks/0hq~c-~dp2g~1.js","static/chunks/15wc.2zpsy4wc.js","static/chunks/06o.rsm2b~dht.js","static/chunks/0_mhv9_2_g.-d.js","static/chunks/0lp.du_t-~cqs.js","static/chunks/0ed3hfv95qark.js","static/chunks/03v0v690_bw8u.js"].map(t=>e.l(t))).then(()=>t(876913)))},714587,e=>{e.v(t=>Promise.all(["static/chunks/0jxlubusvmdjm.js"].map(t=>e.l(t))).then(()=>t(777094)))}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,10337,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),i=e.i(468806);e.s(["ConfirmDialog",0,function({state:e,onConfirm:n,onCancel:a}){let o=(0,s.useCallback)(e=>{e||a()},[a]);if(!e)return null;let l="destructive"===e.variant;return(0,t.jsx)(i.DialogShell,{open:!0,onOpenChange:o,width:"sm","aria-label":e.title,children:(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-4 stg:p-6",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("h3",{className:"stg:text-base stg:font-semibold stg:text-foreground",children:e.title}),(0,t.jsx)("p",{className:"stg:text-sm stg:text-muted-foreground",children:e.description})]}),(0,t.jsxs)("div",{className:"stg:flex stg:justify-end stg:gap-2",children:[(0,t.jsx)("button",{type:"button",onClick:a,className:(0,r.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-sm stg:font-medium stg:transition-colors","stg:border stg:border-input stg:bg-background stg:text-foreground","stg:hover:bg-accent stg:hover:text-accent-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:e.cancelLabel??"Cancel"}),(0,t.jsx)("button",{type:"button",onClick:n,className:(0,r.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-sm stg:font-medium stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",l?"stg:bg-destructive stg:text-destructive-foreground stg:hover:bg-destructive-hover":"stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover"),children:e.confirmLabel??"Confirm"})]})]})})}])},966205,e=>{"use strict";var t=e.i(271645);e.s(["useConfirmAction",0,function(){let[e,s]=(0,t.useState)(null),r=(0,t.useCallback)(e=>new Promise(t=>{s({...e,resolve:t})}),[]),i=(0,t.useCallback)(()=>{e?.resolve(!0),s(null)},[e]),n=(0,t.useCallback)(()=>{e?.resolve(!1),s(null)},[e]);return(0,t.useMemo)(()=>({confirmState:e,confirm:r,handleConfirm:i,handleCancel:n}),[e,r,i,n])}])},63209,e=>{"use strict";let t=(0,e.i(475254).default)("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);e.s(["AlertCircle",0,t],63209)},691444,e=>{"use strict";var t=e.i(430182);let s={[t.IamRole.iam_role_unspecified]:"unspecified",[t.IamRole.owner]:"owner",[t.IamRole.admin]:"admin",[t.IamRole.member]:"member",[t.IamRole.viewer]:"viewer",[t.IamRole.participant]:"participant"},r={owner:t.IamRole.owner,admin:t.IamRole.admin,member:t.IamRole.member,viewer:t.IamRole.viewer,participant:t.IamRole.participant},i={[t.IamRole.iam_role_unspecified]:"Unspecified",[t.IamRole.owner]:"Owner",[t.IamRole.admin]:"Admin",[t.IamRole.member]:"Member",[t.IamRole.viewer]:"Viewer",[t.IamRole.participant]:"Participant"},n={[t.IamRole.iam_role_unspecified]:"",[t.IamRole.owner]:"Full access including delete and access management",[t.IamRole.admin]:"Edit access and member management",[t.IamRole.member]:"Standard access to organization resources",[t.IamRole.viewer]:"Read-only access",[t.IamRole.participant]:"Reply to customers and manage conversation takeover"};e.s(["iamRoleDescription",0,function(e){return n[e]??""},"iamRoleDisplayName",0,function(e){return i[e]??"Unknown"},"iamRoleFromString",0,function(e){return r[e]},"iamRoleToString",0,function(e){return s[e]??"unspecified"}])},146312,818094,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),i=e.i(869803),n=e.i(170255),a=e.i(430182);let o=new Map([[n.ApiResourceKind.identity_provider,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.oauth_app,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.platform_client,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.organization,[a.IamRole.owner,a.IamRole.admin,a.IamRole.member,a.IamRole.viewer]],[n.ApiResourceKind.agent,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.session,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.skill,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.mcp_server,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.agent_instance,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.agent_share,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.agent_channel,[a.IamRole.owner,a.IamRole.viewer,a.IamRole.participant]],[n.ApiResourceKind.channel_app,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.workflow,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.workflow_instance,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.workflow_execution,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.environment,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.artifact,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.schedule,[a.IamRole.owner,a.IamRole.viewer]],[n.ApiResourceKind.project,[a.IamRole.owner,a.IamRole.viewer]]]),l=Object.freeze([]);function c(e){return o.get(e)??l}e.s(["getGrantableRoles",0,c,"hasGrantableRoles",0,function(e){let t=o.get(e);return void 0!==t&&t.length>0}],818094);var g=e.i(691444);e.s(["RoleSelector",0,function({kind:e,onSelect:n,selected:a,defaultRole:o,disabled:l=!1,className:d}){let u=(0,s.useId)(),{options:m,selected:p,select:x}=function(e,t){let[r,i]=(0,s.useState)(t??null),n=(0,s.useMemo)(()=>null===e?[]:c(e).map(e=>({role:e,label:(0,g.iamRoleDisplayName)(e),description:(0,g.iamRoleDescription)(e),value:(0,g.iamRoleToString)(e)})),[e]),a=(0,s.useMemo)(()=>null!==r?(0,g.iamRoleToString)(r):"",[r]);return{options:n,selected:r,selectedValue:a,select:(0,s.useCallback)(e=>i(e),[]),clear:(0,s.useCallback)(()=>i(null),[]),hasOptions:n.length>0}}(e,o),h=void 0!==a?a:p;return 0===m.length?null:(0,t.jsxs)("fieldset",{className:(0,r.cn)(i.UNSTYLED_FIELDSET,"stg:space-y-1.5",d),children:[(0,t.jsx)("legend",{className:"stg:text-xs stg:font-medium stg:text-foreground",children:"Role"}),(0,t.jsx)("div",{className:"stg:flex stg:flex-wrap stg:gap-2",children:m.map(e=>{let s=h===e.role;return(0,t.jsxs)("label",{className:(0,r.cn)("stg:inline-flex stg:cursor-pointer stg:flex-col stg:rounded-md stg:border stg:px-3 stg:py-1.5 stg:text-xs stg:transition-colors",s?"stg:border-primary stg:bg-primary-subtle stg:text-primary stg:font-medium":"stg:border-input stg:bg-background stg:text-muted-foreground stg:hover:border-border stg:hover:text-foreground",l&&"stg:pointer-events-none stg:opacity-50"),children:[(0,t.jsx)("input",{type:"radio",name:u,value:e.value,checked:s,disabled:l,onChange:()=>{var t;x(t=e.role),n?.(t)},className:"stg:sr-only"}),(0,t.jsx)("span",{children:e.label}),(0,t.jsx)("span",{className:"stg:text-[0.625rem] stg:text-muted-foreground stg:font-normal stg:mt-0.5",children:e.description})]},e.value)})})]})}],146312)},564035,288441,890079,32011,e=>{"use strict";var t=e.i(891287),s=e.i(452026),r=e.i(632897),i=e.i(586108),n=e.i(583093);e.s(["useResourceAccess",0,function(e,a){let o=(0,i.useStigmer)(),l=e?.kind??null,c=e?.id??null,g=a?.includeInherited??!1,{data:d,isLoading:u,isRefetching:m,error:p,refetch:x}=(0,n.useFetch)(l&&c?()=>{let e=(0,t.create)(s.ListResourceAccessInputSchema,{resource:(0,t.create)(r.ApiResourceRefSchema,{kind:l,id:c}),includeInherited:g});return o.iamPolicy.listResourceAccessByPrincipal(e).then(e=>[...e.entries])}:null,[l,c,g,o],[]);return{members:d,isLoading:u,isRefetching:m,error:p,refetch:x}}],564035);var a=e.i(271645),o=e.i(326283);e.s(["useCreateIamPolicy",0,function(){let e=(0,i.useStigmer)(),[t,s]=(0,a.useState)(!1),[r,n]=(0,a.useState)(null),l=(0,a.useCallback)(()=>n(null),[]);return{create:(0,a.useCallback)(async t=>{s(!0),n(null);try{return await e.iamPolicy.create(t)}catch(e){throw n((0,o.toError)(e)),e}finally{s(!1)}},[e]),isCreating:t,error:r,clearError:l}}],288441),e.s(["useDeleteIamPolicy",0,function(){let e=(0,i.useStigmer)(),[t,s]=(0,a.useState)(!1),[r,n]=(0,a.useState)(null),l=(0,a.useCallback)(()=>n(null),[]);return{remove:(0,a.useCallback)(async t=>{s(!0),n(null);try{return await e.iamPolicy.delete(t)}catch(e){throw n((0,o.toError)(e)),e}finally{s(!1)}},[e]),isDeleting:t,error:r,clearError:l}}],890079);var l=e.i(843476),c=e.i(893976),g=e.i(188482);function d(e){return e?.identityOrigin?.providerDisplayName??""}e.s(["ProviderBadge",0,function({principal:e,className:t}){let s=d(e);return s?(0,l.jsxs)(g.Tooltip,{children:[(0,l.jsx)(g.TooltipTrigger,{render:(0,l.jsx)("span",{className:(0,c.cn)("stg:inline-flex stg:items-center stg:rounded stg:px-1.5 stg:py-0.5 stg:text-[0.6rem] stg:font-medium","stg:bg-muted-subtle stg:text-muted-foreground",t)}),children:s}),(0,l.jsx)(g.TooltipContent,{side:"top",children:`Identity provider: ${s}`})]}):null},"providerLabel",0,d],32011)},213149,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),i=e.i(468806),n=e.i(818094),a=e.i(869803),o=e.i(610595),l=e.i(891287),c=e.i(632897),g=e.i(564035),d=e.i(288441),u=e.i(890079),m=e.i(691444),p=e.i(146312),x=e.i(32011);function h({orgId:e,value:i,onChange:n,excludePrincipalIds:l,disabled:c=!1,className:d}){let u=(0,s.useId)(),{members:m,isLoading:p,error:b}=(0,g.useResourceAccess)(e?{kind:"organization",id:e}:null),[v,R]=(0,s.useState)(""),[y,w]=(0,s.useState)(!1),[j,k]=(0,s.useState)(0),I=(0,s.useRef)(null),N=(0,s.useMemo)(()=>new Set(l??[]),[l]),C=(0,s.useMemo)(()=>{let e=new Map;for(let t of m){let s=t.principal;s&&"identity_account"===s.kind&&s.id&&(e.has(s.id)||e.set(s.id,s))}return[...e.values()]},[m]),S=(0,s.useMemo)(()=>{let e=new Map;for(let t of C){let s=t.email?.toLowerCase();s&&e.set(s,(e.get(s)??0)+1)}return new Set([...e.entries()].filter(([,e])=>e>1).map(([e])=>e))},[C]),A=(0,s.useMemo)(()=>{let e=v.trim().toLowerCase();return e?C.filter(t=>{let s=(t.name??"").toLowerCase(),r=(t.email??"").toLowerCase();return s.includes(e)||r.includes(e)}):C},[C,v]),M=(0,s.useCallback)(e=>{N.has(e.id)||(n({id:e.id,name:e.name||e.email||e.id,email:e.email,view:e}),R(""),w(!1))},[N,n]),K=(0,s.useCallback)(e=>{if("ArrowDown"===e.key)e.preventDefault(),w(!0),k(e=>Math.min(e+1,A.length-1));else if("ArrowUp"===e.key)e.preventDefault(),k(e=>Math.max(e-1,0));else if("Enter"===e.key){e.preventDefault();let t=A[j];t&&!N.has(t.id)&&M(t)}else"Escape"===e.key&&w(!1)},[A,j,N,M]);return i?(0,t.jsxs)("div",{className:(0,r.cn)("stg:space-y-1",d),children:[(0,t.jsx)("span",{className:"stg:block stg:text-xs stg:font-medium stg:text-foreground",children:"Person"}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between stg:gap-2 stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5",children:[(0,t.jsxs)("div",{className:"stg:flex stg:min-w-0 stg:items-center stg:gap-2",children:[(0,t.jsx)("div",{className:"stg:flex stg:h-6 stg:w-6 stg:shrink-0 stg:items-center stg:justify-center stg:rounded-full stg:bg-muted stg:text-[0.6rem] stg:font-medium stg:text-muted-foreground","aria-hidden":"true",children:(i.name[0]??"?").toUpperCase()}),(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)("span",{className:"stg:truncate stg:text-xs stg:text-foreground",children:i.name}),(0,t.jsx)(x.ProviderBadge,{principal:i.view})]}),i.email&&i.email!==i.name&&(0,t.jsx)("span",{className:"stg:block stg:truncate stg:text-[0.6rem] stg:text-muted-foreground",children:i.email})]})]}),(0,t.jsx)("button",{type:"button",onClick:()=>n(null),disabled:c,"aria-label":"Clear selected person",className:(0,r.cn)("stg:shrink-0 stg:rounded stg:p-0.5 stg:text-muted-foreground","stg:hover:text-foreground stg:hover:bg-accent-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:(0,t.jsx)(f,{})})]})]}):(0,t.jsxs)("div",{className:(0,r.cn)("stg:space-y-1",d),children:[(0,t.jsx)("label",{htmlFor:`${u}-input`,className:"stg:block stg:text-xs stg:font-medium stg:text-foreground",children:"Person"}),(0,t.jsxs)("div",{className:"stg:relative",children:[(0,t.jsx)("input",{id:`${u}-input`,ref:I,type:"text",role:"combobox","aria-expanded":y,"aria-controls":u,"aria-autocomplete":"list",autoComplete:"off",value:v,onChange:e=>{R(e.target.value),w(!0),k(0)},onFocus:()=>w(!0),onBlur:()=>{window.setTimeout(()=>w(!1),120)},onKeyDown:K,placeholder:"Search by name or email",disabled:c||p,autoFocus:!0,className:(0,r.cn)("stg:w-full stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:placeholder:text-muted-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-1 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50")}),y&&(0,t.jsxs)("ul",{id:u,role:"listbox","aria-label":"Organization members",className:(0,r.cn)(a.UNSTYLED_LIST,"stg:absolute stg:z-10 stg:mt-1 stg:max-h-56 stg:w-full stg:overflow-auto stg:rounded-md stg:border stg:border-border stg:bg-popover stg:py-1 stg:shadow-md"),children:[p&&(0,t.jsx)("li",{className:"stg:px-2.5 stg:py-2 stg:text-xs stg:text-muted-foreground",children:"Loading members…"}),!p&&b&&(0,t.jsx)("li",{className:"stg:px-2.5 stg:py-2 stg:text-[0.65rem] stg:text-destructive",role:"alert",children:(0,o.getUserMessage)(b)}),!p&&!b&&0===A.length&&(0,t.jsx)("li",{className:"stg:px-2.5 stg:py-2 stg:text-xs stg:text-muted-foreground",children:v.trim()?"No members match your search.":"No members to share with."}),!p&&!b&&A.map((e,s)=>{let i=N.has(e.id),n=s===j,a=e.name||e.email||e.id,o=!!(0,x.providerLabel)(e)&&(e.identityOrigin?.providerDisplayName!=="Stigmer"||!!e.email&&S.has(e.email.toLowerCase()));return(0,t.jsxs)("li",{role:"option","aria-selected":n,"aria-disabled":i,onMouseEnter:()=>k(s),onMouseDown:t=>{t.preventDefault(),i||M(e)},className:(0,r.cn)("stg:flex stg:items-center stg:justify-between stg:gap-2 stg:px-2.5 stg:py-1.5",i?"stg:cursor-not-allowed stg:opacity-50":"stg:cursor-pointer",n&&!i&&"stg:bg-accent-hover"),children:[(0,t.jsxs)("div",{className:"stg:flex stg:min-w-0 stg:items-center stg:gap-2",children:[(0,t.jsx)("div",{className:"stg:flex stg:h-6 stg:w-6 stg:shrink-0 stg:items-center stg:justify-center stg:rounded-full stg:bg-muted stg:text-[0.6rem] stg:font-medium stg:text-muted-foreground","aria-hidden":"true",children:(a[0]??"?").toUpperCase()}),(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)("span",{className:"stg:truncate stg:text-xs stg:text-foreground",children:a}),o&&(0,t.jsx)(x.ProviderBadge,{principal:e})]}),e.email&&e.email!==a&&(0,t.jsx)("span",{className:"stg:block stg:truncate stg:text-[0.6rem] stg:text-muted-foreground",children:e.email})]})]}),i&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-[0.6rem] stg:text-muted-foreground",children:"Has access"})]},e.id)})]})]})]})}function f(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M4 4l8 8M12 4l-8 8"})})}var b=e.i(379410);function v({resourceKind:e,resourceKindString:i,resourceId:n,orgId:a,excludePrincipalIds:g,onGranted:u,onCancel:x,className:f}){let{create:R,isCreating:y,error:w,clearError:j}=(0,d.useCreateIamPolicy)(),[k,I]=(0,s.useState)(null),[N,C]=(0,s.useState)(null),S=null!==k&&null!==N&&!y,A=(0,s.useCallback)(async e=>{if(e.preventDefault(),S&&null!==N&&null!==k){j();try{let e=(0,l.create)(c.IamPolicySpecSchema,{principal:(0,l.create)(c.ApiResourceRefSchema,{kind:"identity_account",id:k.id}),resource:(0,l.create)(c.ApiResourceRefSchema,{kind:i,id:n}),relation:(0,m.iamRoleToString)(N)}),t=await R(e);u?.(t)}catch{}}},[S,N,k,i,n,R,j,u]);return(0,t.jsxs)("form",{onSubmit:A,className:(0,r.cn)("stg:space-y-3",f),children:[(0,t.jsxs)("div",{className:"stg:space-y-3",children:[(0,t.jsx)(h,{orgId:a,value:k,onChange:I,excludePrincipalIds:g,disabled:y}),(0,t.jsx)(p.RoleSelector,{kind:e,selected:N,onSelect:C,disabled:y})]}),w&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,o.getUserMessage)(w)}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[(0,t.jsxs)("button",{type:"submit",disabled:!S,className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-40"),children:[y&&(0,t.jsx)(b.SpinnerIcon,{size:12}),"Grant access"]}),x&&(0,t.jsx)("button",{type:"button",onClick:x,disabled:y,className:(0,r.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs","stg:text-muted-foreground stg:hover:text-foreground stg:hover:bg-accent-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:"Cancel"})]})]})}var R=e.i(590150);function y({resource:e,resourceKindString:i,resourceKind:m,orgId:p,className:x}){let{accessList:h,isLoading:f,fetchError:b,revokeAccess:j,isRevoking:k,revokeError:I,refetch:N,hasGrantableRoles:C}=function(e){var t;let r=(0,s.useMemo)(()=>e?{kind:e.kind,id:e.id}:null,[e?.kind,e?.id]),{members:i,isLoading:a,isRefetching:o,error:m,refetch:p}=(0,g.useResourceAccess)(r),{roles:x,hasRoles:h}=(t=e?.resourceKind??null,(0,s.useMemo)(()=>null===t?{roles:[],hasRoles:!1}:{roles:(0,n.getGrantableRoles)(t),hasRoles:(0,n.hasGrantableRoles)(t)},[t])),{create:f,isCreating:b,error:v,clearError:R}=(0,d.useCreateIamPolicy)(),{remove:y,isDeleting:w,error:j,clearError:k}=(0,u.useDeleteIamPolicy)(),I=(0,s.useRef)(e);I.current=e;let N=(0,s.useCallback)(async(e,t)=>{let s=I.current;if(!s)return;let r=(0,l.create)(c.IamPolicySpecSchema,{principal:(0,l.create)(c.ApiResourceRefSchema,{kind:"identity_account",id:e}),resource:(0,l.create)(c.ApiResourceRefSchema,{kind:s.kind,id:s.id}),relation:t});await f(r),p()},[f,p]);return{accessList:i,isLoading:a,isRefetching:o,fetchError:m,grantableRoles:x,hasGrantableRoles:h,grantAccess:N,isGranting:b,grantError:v,revokeAccess:(0,s.useCallback)(async(e,t)=>{let s=I.current;if(!s)return;let r=(0,l.create)(c.IamPolicySpecSchema,{principal:(0,l.create)(c.ApiResourceRefSchema,{kind:"identity_account",id:e}),resource:(0,l.create)(c.ApiResourceRefSchema,{kind:s.kind,id:s.id}),relation:t});await y(r),p()},[y,p]),isRevoking:w,revokeError:j,refetch:p,clearErrors:(0,s.useCallback)(()=>{R(),k()},[R,k])}}(e),[S,A]=(0,s.useState)(!1),M=h.map(e=>e.principal?.id).filter(e=>!!e),K={kind:i,id:e.id};return(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:flex-col stg:gap-4",x),children:[(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:f?"Loading access list...":`${h.length} ${1===h.length?"person":"people"} with access`}),b&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,o.getUserMessage)(b)}),!f&&h.length>0&&(0,t.jsx)("ul",{className:(0,r.cn)(a.UNSTYLED_LIST,"stg:space-y-1 stg:mt-2"),"aria-label":"People with access",children:h.map(e=>(0,t.jsx)(w,{entry:e,grantGate:K,onRevoke:j,isRevoking:k},e.principal?.id??"unknown"))}),I&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,o.getUserMessage)(I)})]}),C&&(0,t.jsx)(R.PermissionGate,{resource:K,relation:"can_grant_access",children:(0,t.jsx)("div",{className:"stg:border-t stg:border-border stg:pt-3",children:S?(0,t.jsx)(v,{resourceKind:m,resourceKindString:i,resourceId:e.id,orgId:p,excludePrincipalIds:M,onGranted:()=>{A(!1),N()},onCancel:()=>A(!1)}):(0,t.jsx)("button",{type:"button",onClick:()=>A(!0),className:(0,r.cn)("stg:w-full stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium stg:text-center","stg:border stg:border-dashed stg:border-border","stg:text-muted-foreground stg:hover:text-foreground stg:hover:border-foreground/30","stg:hover:bg-accent-hover stg:transition-colors"),children:"+ Add people"})})})]})}function w({entry:e,grantGate:i,onRevoke:n,isRevoking:a}){let o=e.principal,l=e.roles,c=o?.name||o?.email||o?.id||"Unknown",g=l[0]?.role,d=(0,s.useCallback)(async()=>{o?.id&&g?.code&&await n(o.id,g.code)},[o?.id,g?.code,n]);return(0,t.jsxs)("li",{className:"stg:flex stg:items-center stg:justify-between stg:gap-2 stg:rounded-md stg:px-2 stg:py-1.5 stg:hover:bg-accent-hover stg:group",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:min-w-0",children:[(0,t.jsx)("div",{className:"stg:h-6 stg:w-6 stg:rounded-full stg:bg-muted stg:flex stg:items-center stg:justify-center stg:text-[0.6rem] stg:font-medium stg:text-muted-foreground stg:shrink-0","aria-hidden":"true",children:(o?.name?.[0]??o?.email?.[0]??"?").toUpperCase()}),(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsx)("p",{className:"stg:text-xs stg:text-foreground stg:truncate",children:c}),o?.email&&o.name&&(0,t.jsx)("p",{className:"stg:text-[0.6rem] stg:text-muted-foreground stg:truncate",children:o.email})]})]}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5 stg:shrink-0",children:[(0,t.jsx)("span",{className:"stg:text-[0.6rem] stg:text-muted-foreground stg:capitalize",children:g?.name??g?.code??"—"}),(0,t.jsx)(R.PermissionGate,{resource:i,relation:"can_grant_access",children:(0,t.jsx)("button",{type:"button",onClick:d,disabled:a,"aria-label":`Remove ${c}'s access`,className:(0,r.cn)("stg:rounded stg:p-0.5 stg:text-muted-foreground stg:opacity-0 stg:group-hover:opacity-100","stg:hover:text-destructive stg:hover:bg-destructive/10","stg:disabled:pointer-events-none stg:disabled:opacity-50","stg:transition-opacity"),children:(0,t.jsx)(j,{})})})]})]})}function j(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M4 4l8 8M12 4l-8 8"})})}var k=e.i(388023);function I({title:e,description:s,children:r}){return(0,t.jsxs)("section",{className:"stg:px-6 stg:py-4",children:[(0,t.jsx)("h3",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:e}),s&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-[0.65rem] stg:text-muted-foreground",children:s}),(0,t.jsx)("div",{className:"stg:mt-2.5",children:r})]})}function N(){return(0,t.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M4 4l8 8M12 4l-8 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}e.s(["ManageAccessDialog",0,function({open:e,onOpenChange:a,resource:o,visibility:l,extraSection:c}){let g=(0,s.useId)(),d=(0,s.useCallback)(()=>{a(!1)},[a]),u=(0,n.hasGrantableRoles)(o.kind);return(0,t.jsx)(i.DialogShell,{open:e,onOpenChange:a,width:"md","aria-labelledby":g,children:e&&(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:justify-between stg:border-b stg:border-border stg:px-6 stg:py-4",children:[(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsx)("h2",{id:g,className:"stg:text-base stg:font-semibold stg:text-foreground",children:"Manage access"}),o.name&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:truncate stg:text-xs stg:text-muted-foreground",children:o.name})]}),(0,t.jsx)("button",{type:"button",onClick:d,"aria-label":"Close",className:(0,r.cn)("stg:rounded-md stg:p-1 stg:text-muted-foreground","stg:hover:text-foreground stg:hover:bg-accent-hover","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring"),children:(0,t.jsx)(N,{})})]}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:[l&&(0,t.jsx)(I,{title:"General access",description:"Who can find and open this resource.",children:(0,t.jsx)(k.ResourceVisibilityControl,{kind:l.kind,resourceId:o.id,visibility:l.current,org:l.org,onChanged:l.onChanged})}),u&&(0,t.jsx)(I,{title:"People with access",children:(0,t.jsx)(y,{resource:{kind:o.kindString,id:o.id,resourceKind:o.kind},resourceKindString:o.kindString,resourceKind:o.kind,orgId:o.org})}),c&&(0,t.jsx)(I,{title:c.title,description:c.description,children:c.content})]}),(0,t.jsx)("div",{className:"stg:flex stg:items-center stg:justify-end stg:border-t stg:border-border stg:px-6 stg:py-3",children:(0,t.jsx)("button",{type:"button",onClick:d,className:(0,r.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-sm stg:font-medium","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring stg:focus:ring-offset-2"),children:"Done"})})]})})}],213149)}]);