@stigmer/server-slim 3.39.0 → 3.40.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (613) hide show
  1. package/console/404.html +1 -1
  2. package/console/__next.__PAGE__.txt +2 -2
  3. package/console/__next._full.txt +25 -26
  4. package/console/__next._head.txt +4 -4
  5. package/console/__next._index.txt +11 -11
  6. package/console/__next._tree.txt +2 -2
  7. package/console/_next/static/chunks/{0n4wkksuib_98.js → 0.e9hpun4v4_e.js} +2 -2
  8. package/console/_next/static/chunks/004yyfcw31pdb.js +1 -0
  9. package/console/_next/static/chunks/01hep6fbspt.0.js +1 -0
  10. package/console/_next/static/chunks/01ri0nsn3rm5r.js +1 -0
  11. package/console/_next/static/chunks/03~hor0gpydum.js +1 -0
  12. package/console/_next/static/chunks/05uzu4-_sp1yp.js +1 -0
  13. package/console/_next/static/chunks/06oj_98ic1mog.js +1 -0
  14. package/console/_next/static/chunks/072g980hrxnyl.js +1 -0
  15. package/console/_next/static/chunks/09cz6jcnbxze0.js +1 -0
  16. package/console/_next/static/chunks/0dqv0-aq-hk6z.css +1 -0
  17. package/console/_next/static/chunks/0h99brdqtss1e.js +1 -0
  18. package/console/_next/static/chunks/0r5em9p7o4~0a.js +1 -0
  19. package/console/_next/static/chunks/0rh6tj~41xah0.js +34 -0
  20. package/console/_next/static/chunks/0rnuyrmuaqv-y.js +1 -0
  21. package/console/_next/static/chunks/0s7rm5b3t2blp.js +1 -0
  22. package/console/_next/static/chunks/0sdmlljuv44wa.js +2 -0
  23. package/console/_next/static/chunks/{17.swdr64ws0j.js → 0snci6aoq432l.js} +1 -1
  24. package/console/_next/static/chunks/0v092vq67qrfs.js +1 -0
  25. package/console/_next/static/chunks/0wnno83q-9u2z.js +1 -0
  26. package/console/_next/static/chunks/0xu5et89mm2yn.js +1 -0
  27. package/console/_next/static/chunks/0xy23zns071f6.js +1 -0
  28. package/console/_next/static/chunks/14zz9elipv8.k.js +1 -0
  29. package/console/_next/static/chunks/161o._k~z2-bu.js +1 -0
  30. package/console/_not-found/__next._full.txt +28 -29
  31. package/console/_not-found/__next._head.txt +4 -4
  32. package/console/_not-found/__next._index.txt +11 -11
  33. package/console/_not-found/__next._not-found.__PAGE__.txt +3 -3
  34. package/console/_not-found/__next._not-found.txt +3 -3
  35. package/console/_not-found/__next._tree.txt +2 -2
  36. package/console/_not-found.html +1 -1
  37. package/console/_not-found.txt +28 -29
  38. package/console/auth/callback/__next._full.txt +33 -32
  39. package/console/auth/callback/__next._head.txt +4 -4
  40. package/console/auth/callback/__next._index.txt +11 -11
  41. package/console/auth/callback/__next._tree.txt +2 -2
  42. package/console/auth/callback/__next.auth.callback.__PAGE__.txt +4 -4
  43. package/console/auth/callback/__next.auth.callback.txt +3 -3
  44. package/console/auth/callback/__next.auth.txt +3 -3
  45. package/console/auth/callback.html +1 -1
  46. package/console/auth/callback.txt +33 -32
  47. package/console/auth/github/callback/__next._full.txt +35 -33
  48. package/console/auth/github/callback/__next._head.txt +4 -4
  49. package/console/auth/github/callback/__next._index.txt +11 -11
  50. package/console/auth/github/callback/__next._tree.txt +2 -2
  51. package/console/auth/github/callback/__next.auth.github.callback.__PAGE__.txt +4 -4
  52. package/console/auth/github/callback/__next.auth.github.callback.txt +3 -3
  53. package/console/auth/github/callback/__next.auth.github.txt +3 -3
  54. package/console/auth/github/callback/__next.auth.txt +3 -3
  55. package/console/auth/github/callback.html +1 -1
  56. package/console/auth/github/callback.txt +35 -33
  57. package/console/auth/oauth/callback/__next._full.txt +35 -33
  58. package/console/auth/oauth/callback/__next._head.txt +4 -4
  59. package/console/auth/oauth/callback/__next._index.txt +11 -11
  60. package/console/auth/oauth/callback/__next._tree.txt +2 -2
  61. package/console/auth/oauth/callback/__next.auth.oauth.callback.__PAGE__.txt +4 -4
  62. package/console/auth/oauth/callback/__next.auth.oauth.callback.txt +3 -3
  63. package/console/auth/oauth/callback/__next.auth.oauth.txt +3 -3
  64. package/console/auth/oauth/callback/__next.auth.txt +3 -3
  65. package/console/auth/oauth/callback.html +1 -1
  66. package/console/auth/oauth/callback.txt +35 -33
  67. package/console/chat/__placeholder__/__placeholder__/__next._full.txt +25 -25
  68. package/console/chat/__placeholder__/__placeholder__/__next._head.txt +4 -4
  69. package/console/chat/__placeholder__/__placeholder__/__next._index.txt +11 -11
  70. package/console/chat/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  71. package/console/chat/__placeholder__/__placeholder__/__next.chat.$d$org.$d$slug.__PAGE__.txt +3 -3
  72. package/console/chat/__placeholder__/__placeholder__/__next.chat.$d$org.$d$slug.txt +3 -3
  73. package/console/chat/__placeholder__/__placeholder__/__next.chat.$d$org.txt +3 -3
  74. package/console/chat/__placeholder__/__placeholder__/__next.chat.txt +3 -3
  75. package/console/chat/__placeholder__/__placeholder__.html +1 -1
  76. package/console/chat/__placeholder__/__placeholder__.txt +25 -25
  77. package/console/conversations/__next._full.txt +29 -28
  78. package/console/conversations/__next._head.txt +4 -4
  79. package/console/conversations/__next._index.txt +11 -11
  80. package/console/conversations/__next._tree.txt +2 -2
  81. package/console/conversations/__next.conversations.__PAGE__.txt +3 -3
  82. package/console/conversations/__next.conversations.txt +3 -3
  83. package/console/conversations/__placeholder__/__placeholder__/__next._full.txt +23 -23
  84. package/console/conversations/__placeholder__/__placeholder__/__next._head.txt +4 -4
  85. package/console/conversations/__placeholder__/__placeholder__/__next._index.txt +11 -11
  86. package/console/conversations/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  87. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.$d$key.__PAGE__.txt +3 -3
  88. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.$d$key.txt +3 -3
  89. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.txt +3 -3
  90. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.txt +3 -3
  91. package/console/conversations/__placeholder__/__placeholder__.html +1 -1
  92. package/console/conversations/__placeholder__/__placeholder__.txt +23 -23
  93. package/console/conversations.html +1 -1
  94. package/console/conversations.txt +29 -28
  95. package/console/dashboard/__next._full.txt +29 -30
  96. package/console/dashboard/__next._head.txt +4 -4
  97. package/console/dashboard/__next._index.txt +11 -11
  98. package/console/dashboard/__next._tree.txt +2 -2
  99. package/console/dashboard/__next.dashboard.__PAGE__.txt +3 -3
  100. package/console/dashboard/__next.dashboard.txt +3 -3
  101. package/console/dashboard.html +1 -1
  102. package/console/dashboard.txt +29 -30
  103. package/console/desktop/billing/__next._full.txt +38 -0
  104. package/console/desktop/billing/__next._head.txt +6 -0
  105. package/console/desktop/billing/__next._index.txt +15 -0
  106. package/console/desktop/billing/__next._tree.txt +5 -0
  107. package/console/desktop/billing/__next.desktop.billing.__PAGE__.txt +9 -0
  108. package/console/desktop/billing/__next.desktop.billing.txt +5 -0
  109. package/console/desktop/billing/__next.desktop.txt +5 -0
  110. package/console/desktop/billing.html +1 -0
  111. package/console/desktop/billing.txt +38 -0
  112. package/console/executions/__placeholder__/__next._full.txt +30 -28
  113. package/console/executions/__placeholder__/__next._head.txt +4 -4
  114. package/console/executions/__placeholder__/__next._index.txt +11 -11
  115. package/console/executions/__placeholder__/__next._tree.txt +2 -2
  116. package/console/executions/__placeholder__/__next.executions.$d$id.__PAGE__.txt +2 -2
  117. package/console/executions/__placeholder__/__next.executions.$d$id.txt +3 -3
  118. package/console/executions/__placeholder__/__next.executions.txt +3 -3
  119. package/console/executions/__placeholder__.html +1 -1
  120. package/console/executions/__placeholder__.txt +30 -28
  121. package/console/index.html +1 -1
  122. package/console/index.txt +25 -26
  123. package/console/invite/__placeholder__/__next._full.txt +31 -29
  124. package/console/invite/__placeholder__/__next._head.txt +4 -4
  125. package/console/invite/__placeholder__/__next._index.txt +11 -11
  126. package/console/invite/__placeholder__/__next._tree.txt +2 -2
  127. package/console/invite/__placeholder__/__next.invite.$d$token.__PAGE__.txt +3 -3
  128. package/console/invite/__placeholder__/__next.invite.$d$token.txt +3 -3
  129. package/console/invite/__placeholder__/__next.invite.txt +3 -3
  130. package/console/invite/__placeholder__.html +1 -1
  131. package/console/invite/__placeholder__.txt +31 -29
  132. package/console/library/__next._full.txt +30 -31
  133. package/console/library/__next._head.txt +4 -4
  134. package/console/library/__next._index.txt +11 -11
  135. package/console/library/__next._tree.txt +2 -2
  136. package/console/library/__next.library.__PAGE__.txt +3 -3
  137. package/console/library/__next.library.txt +5 -5
  138. package/console/library/agents/__next._full.txt +34 -32
  139. package/console/library/agents/__next._head.txt +4 -4
  140. package/console/library/agents/__next._index.txt +11 -11
  141. package/console/library/agents/__next._tree.txt +2 -2
  142. package/console/library/agents/__next.library.agents.__PAGE__.txt +3 -3
  143. package/console/library/agents/__next.library.agents.txt +3 -3
  144. package/console/library/agents/__next.library.txt +5 -5
  145. package/console/library/agents/__placeholder__/__placeholder__/__next._full.txt +27 -27
  146. package/console/library/agents/__placeholder__/__placeholder__/__next._head.txt +4 -4
  147. package/console/library/agents/__placeholder__/__placeholder__/__next._index.txt +11 -11
  148. package/console/library/agents/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  149. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.$d$slug.__PAGE__.txt +3 -3
  150. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.$d$slug.txt +3 -3
  151. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.txt +3 -3
  152. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.txt +3 -3
  153. package/console/library/agents/__placeholder__/__placeholder__/__next.library.txt +5 -5
  154. package/console/library/agents/__placeholder__/__placeholder__.html +1 -1
  155. package/console/library/agents/__placeholder__/__placeholder__.txt +27 -27
  156. package/console/library/agents/new/__next._full.txt +38 -36
  157. package/console/library/agents/new/__next._head.txt +4 -4
  158. package/console/library/agents/new/__next._index.txt +11 -11
  159. package/console/library/agents/new/__next._tree.txt +2 -2
  160. package/console/library/agents/new/__next.library.agents.new.__PAGE__.txt +4 -4
  161. package/console/library/agents/new/__next.library.agents.new.txt +3 -3
  162. package/console/library/agents/new/__next.library.agents.txt +3 -3
  163. package/console/library/agents/new/__next.library.txt +5 -5
  164. package/console/library/agents/new.html +1 -1
  165. package/console/library/agents/new.txt +38 -36
  166. package/console/library/agents.html +1 -1
  167. package/console/library/agents.txt +34 -32
  168. package/console/library/mcp-servers/__next._full.txt +34 -32
  169. package/console/library/mcp-servers/__next._head.txt +4 -4
  170. package/console/library/mcp-servers/__next._index.txt +11 -11
  171. package/console/library/mcp-servers/__next._tree.txt +2 -2
  172. package/console/library/mcp-servers/__next.library.mcp-servers.__PAGE__.txt +3 -3
  173. package/console/library/mcp-servers/__next.library.mcp-servers.txt +3 -3
  174. package/console/library/mcp-servers/__next.library.txt +5 -5
  175. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._full.txt +20 -20
  176. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._head.txt +4 -4
  177. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._index.txt +11 -11
  178. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  179. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.$d$org.$d$slug.__PAGE__.txt +3 -3
  180. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.$d$org.$d$slug.txt +3 -3
  181. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.$d$org.txt +3 -3
  182. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.mcp-servers.txt +3 -3
  183. package/console/library/mcp-servers/__placeholder__/__placeholder__/__next.library.txt +5 -5
  184. package/console/library/mcp-servers/__placeholder__/__placeholder__.html +1 -1
  185. package/console/library/mcp-servers/__placeholder__/__placeholder__.txt +20 -20
  186. package/console/library/mcp-servers/new/__next._full.txt +38 -36
  187. package/console/library/mcp-servers/new/__next._head.txt +4 -4
  188. package/console/library/mcp-servers/new/__next._index.txt +11 -11
  189. package/console/library/mcp-servers/new/__next._tree.txt +2 -2
  190. package/console/library/mcp-servers/new/__next.library.mcp-servers.new.__PAGE__.txt +4 -4
  191. package/console/library/mcp-servers/new/__next.library.mcp-servers.new.txt +3 -3
  192. package/console/library/mcp-servers/new/__next.library.mcp-servers.txt +3 -3
  193. package/console/library/mcp-servers/new/__next.library.txt +5 -5
  194. package/console/library/mcp-servers/new.html +1 -1
  195. package/console/library/mcp-servers/new.txt +38 -36
  196. package/console/library/mcp-servers.html +1 -1
  197. package/console/library/mcp-servers.txt +34 -32
  198. package/console/library/plugins/__next._full.txt +34 -32
  199. package/console/library/plugins/__next._head.txt +4 -4
  200. package/console/library/plugins/__next._index.txt +11 -11
  201. package/console/library/plugins/__next._tree.txt +2 -2
  202. package/console/library/plugins/__next.library.plugins.__PAGE__.txt +3 -3
  203. package/console/library/plugins/__next.library.plugins.txt +3 -3
  204. package/console/library/plugins/__next.library.txt +5 -5
  205. package/console/library/plugins/__placeholder__/__placeholder__/__next._full.txt +27 -27
  206. package/console/library/plugins/__placeholder__/__placeholder__/__next._head.txt +4 -4
  207. package/console/library/plugins/__placeholder__/__placeholder__/__next._index.txt +11 -11
  208. package/console/library/plugins/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  209. package/console/library/plugins/__placeholder__/__placeholder__/__next.library.plugins.$d$org.$d$slug.__PAGE__.txt +3 -3
  210. package/console/library/plugins/__placeholder__/__placeholder__/__next.library.plugins.$d$org.$d$slug.txt +3 -3
  211. package/console/library/plugins/__placeholder__/__placeholder__/__next.library.plugins.$d$org.txt +3 -3
  212. package/console/library/plugins/__placeholder__/__placeholder__/__next.library.plugins.txt +3 -3
  213. package/console/library/plugins/__placeholder__/__placeholder__/__next.library.txt +5 -5
  214. package/console/library/plugins/__placeholder__/__placeholder__.html +1 -1
  215. package/console/library/plugins/__placeholder__/__placeholder__.txt +27 -27
  216. package/console/library/plugins/upload/__next._full.txt +38 -36
  217. package/console/library/plugins/upload/__next._head.txt +4 -4
  218. package/console/library/plugins/upload/__next._index.txt +11 -11
  219. package/console/library/plugins/upload/__next._tree.txt +2 -2
  220. package/console/library/plugins/upload/__next.library.plugins.txt +3 -3
  221. package/console/library/plugins/upload/__next.library.plugins.upload.__PAGE__.txt +4 -4
  222. package/console/library/plugins/upload/__next.library.plugins.upload.txt +3 -3
  223. package/console/library/plugins/upload/__next.library.txt +5 -5
  224. package/console/library/plugins/upload.html +1 -1
  225. package/console/library/plugins/upload.txt +38 -36
  226. package/console/library/plugins.html +1 -1
  227. package/console/library/plugins.txt +34 -32
  228. package/console/library/schedules/__next._full.txt +34 -32
  229. package/console/library/schedules/__next._head.txt +4 -4
  230. package/console/library/schedules/__next._index.txt +11 -11
  231. package/console/library/schedules/__next._tree.txt +2 -2
  232. package/console/library/schedules/__next.library.schedules.__PAGE__.txt +3 -3
  233. package/console/library/schedules/__next.library.schedules.txt +3 -3
  234. package/console/library/schedules/__next.library.txt +5 -5
  235. package/console/library/schedules/__placeholder__/__placeholder__/__next._full.txt +20 -20
  236. package/console/library/schedules/__placeholder__/__placeholder__/__next._head.txt +4 -4
  237. package/console/library/schedules/__placeholder__/__placeholder__/__next._index.txt +11 -11
  238. package/console/library/schedules/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  239. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.$d$org.$d$slug.__PAGE__.txt +3 -3
  240. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.$d$org.$d$slug.txt +3 -3
  241. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.$d$org.txt +3 -3
  242. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.schedules.txt +3 -3
  243. package/console/library/schedules/__placeholder__/__placeholder__/__next.library.txt +5 -5
  244. package/console/library/schedules/__placeholder__/__placeholder__.html +1 -1
  245. package/console/library/schedules/__placeholder__/__placeholder__.txt +20 -20
  246. package/console/library/schedules/new/__next._full.txt +38 -36
  247. package/console/library/schedules/new/__next._head.txt +4 -4
  248. package/console/library/schedules/new/__next._index.txt +11 -11
  249. package/console/library/schedules/new/__next._tree.txt +2 -2
  250. package/console/library/schedules/new/__next.library.schedules.new.__PAGE__.txt +4 -4
  251. package/console/library/schedules/new/__next.library.schedules.new.txt +3 -3
  252. package/console/library/schedules/new/__next.library.schedules.txt +3 -3
  253. package/console/library/schedules/new/__next.library.txt +5 -5
  254. package/console/library/schedules/new.html +1 -1
  255. package/console/library/schedules/new.txt +38 -36
  256. package/console/library/schedules.html +1 -1
  257. package/console/library/schedules.txt +34 -32
  258. package/console/library/skills/__next._full.txt +34 -32
  259. package/console/library/skills/__next._head.txt +4 -4
  260. package/console/library/skills/__next._index.txt +11 -11
  261. package/console/library/skills/__next._tree.txt +2 -2
  262. package/console/library/skills/__next.library.skills.__PAGE__.txt +3 -3
  263. package/console/library/skills/__next.library.skills.txt +3 -3
  264. package/console/library/skills/__next.library.txt +5 -5
  265. package/console/library/skills/__placeholder__/__placeholder__/__next._full.txt +27 -27
  266. package/console/library/skills/__placeholder__/__placeholder__/__next._head.txt +4 -4
  267. package/console/library/skills/__placeholder__/__placeholder__/__next._index.txt +11 -11
  268. package/console/library/skills/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  269. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.$d$slug.__PAGE__.txt +3 -3
  270. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.$d$slug.txt +3 -3
  271. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.txt +3 -3
  272. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.txt +3 -3
  273. package/console/library/skills/__placeholder__/__placeholder__/__next.library.txt +5 -5
  274. package/console/library/skills/__placeholder__/__placeholder__.html +1 -1
  275. package/console/library/skills/__placeholder__/__placeholder__.txt +27 -27
  276. package/console/library/skills/new/__next._full.txt +38 -36
  277. package/console/library/skills/new/__next._head.txt +4 -4
  278. package/console/library/skills/new/__next._index.txt +11 -11
  279. package/console/library/skills/new/__next._tree.txt +2 -2
  280. package/console/library/skills/new/__next.library.skills.new.__PAGE__.txt +4 -4
  281. package/console/library/skills/new/__next.library.skills.new.txt +3 -3
  282. package/console/library/skills/new/__next.library.skills.txt +3 -3
  283. package/console/library/skills/new/__next.library.txt +5 -5
  284. package/console/library/skills/new.html +1 -1
  285. package/console/library/skills/new.txt +38 -36
  286. package/console/library/skills.html +1 -1
  287. package/console/library/skills.txt +34 -32
  288. package/console/library/workflows/__next._full.txt +34 -32
  289. package/console/library/workflows/__next._head.txt +4 -4
  290. package/console/library/workflows/__next._index.txt +11 -11
  291. package/console/library/workflows/__next._tree.txt +2 -2
  292. package/console/library/workflows/__next.library.txt +5 -5
  293. package/console/library/workflows/__next.library.workflows.__PAGE__.txt +3 -3
  294. package/console/library/workflows/__next.library.workflows.txt +3 -3
  295. package/console/library/workflows/__placeholder__/__placeholder__/__next._full.txt +20 -20
  296. package/console/library/workflows/__placeholder__/__placeholder__/__next._head.txt +4 -4
  297. package/console/library/workflows/__placeholder__/__placeholder__/__next._index.txt +11 -11
  298. package/console/library/workflows/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  299. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.txt +5 -5
  300. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.$d$org.$d$slug.__PAGE__.txt +3 -3
  301. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.$d$org.$d$slug.txt +3 -3
  302. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.$d$org.txt +3 -3
  303. package/console/library/workflows/__placeholder__/__placeholder__/__next.library.workflows.txt +3 -3
  304. package/console/library/workflows/__placeholder__/__placeholder__.html +1 -1
  305. package/console/library/workflows/__placeholder__/__placeholder__.txt +20 -20
  306. package/console/library/workflows/executions/__next._full.txt +35 -33
  307. package/console/library/workflows/executions/__next._head.txt +4 -4
  308. package/console/library/workflows/executions/__next._index.txt +11 -11
  309. package/console/library/workflows/executions/__next._tree.txt +2 -2
  310. package/console/library/workflows/executions/__next.library.txt +5 -5
  311. package/console/library/workflows/executions/__next.library.workflows.executions.__PAGE__.txt +3 -3
  312. package/console/library/workflows/executions/__next.library.workflows.executions.txt +3 -3
  313. package/console/library/workflows/executions/__next.library.workflows.txt +3 -3
  314. package/console/library/workflows/executions.html +1 -1
  315. package/console/library/workflows/executions.txt +35 -33
  316. package/console/library/workflows/new/__next._full.txt +38 -36
  317. package/console/library/workflows/new/__next._head.txt +4 -4
  318. package/console/library/workflows/new/__next._index.txt +11 -11
  319. package/console/library/workflows/new/__next._tree.txt +2 -2
  320. package/console/library/workflows/new/__next.library.txt +5 -5
  321. package/console/library/workflows/new/__next.library.workflows.new.__PAGE__.txt +4 -4
  322. package/console/library/workflows/new/__next.library.workflows.new.txt +3 -3
  323. package/console/library/workflows/new/__next.library.workflows.txt +3 -3
  324. package/console/library/workflows/new.html +1 -1
  325. package/console/library/workflows/new.txt +38 -36
  326. package/console/library/workflows.html +1 -1
  327. package/console/library/workflows.txt +34 -32
  328. package/console/library.html +1 -1
  329. package/console/library.txt +30 -31
  330. package/console/login/__next._full.txt +32 -33
  331. package/console/login/__next._head.txt +4 -4
  332. package/console/login/__next._index.txt +11 -11
  333. package/console/login/__next._tree.txt +2 -2
  334. package/console/login/__next.login.__PAGE__.txt +4 -4
  335. package/console/login/__next.login.txt +3 -3
  336. package/console/login.html +1 -1
  337. package/console/login.txt +32 -33
  338. package/console/marketplace/__next._full.txt +29 -30
  339. package/console/marketplace/__next._head.txt +4 -4
  340. package/console/marketplace/__next._index.txt +11 -11
  341. package/console/marketplace/__next._tree.txt +2 -2
  342. package/console/marketplace/__next.marketplace.__PAGE__.txt +3 -3
  343. package/console/marketplace/__next.marketplace.txt +3 -3
  344. package/console/marketplace.html +1 -1
  345. package/console/marketplace.txt +29 -30
  346. package/console/oauth/slack/callback/__next._full.txt +35 -33
  347. package/console/oauth/slack/callback/__next._head.txt +4 -4
  348. package/console/oauth/slack/callback/__next._index.txt +11 -11
  349. package/console/oauth/slack/callback/__next._tree.txt +2 -2
  350. package/console/oauth/slack/callback/__next.oauth.slack.callback.__PAGE__.txt +4 -4
  351. package/console/oauth/slack/callback/__next.oauth.slack.callback.txt +3 -3
  352. package/console/oauth/slack/callback/__next.oauth.slack.txt +3 -3
  353. package/console/oauth/slack/callback/__next.oauth.txt +3 -3
  354. package/console/oauth/slack/callback.html +1 -1
  355. package/console/oauth/slack/callback.txt +35 -33
  356. package/console/sessions/__placeholder__/__next._full.txt +30 -28
  357. package/console/sessions/__placeholder__/__next._head.txt +4 -4
  358. package/console/sessions/__placeholder__/__next._index.txt +11 -11
  359. package/console/sessions/__placeholder__/__next._tree.txt +2 -2
  360. package/console/sessions/__placeholder__/__next.sessions.$d$id.__PAGE__.txt +2 -2
  361. package/console/sessions/__placeholder__/__next.sessions.$d$id.txt +3 -3
  362. package/console/sessions/__placeholder__/__next.sessions.txt +3 -3
  363. package/console/sessions/__placeholder__.html +1 -1
  364. package/console/sessions/__placeholder__.txt +30 -28
  365. package/console/settings/__next._full.txt +32 -33
  366. package/console/settings/__next._head.txt +4 -4
  367. package/console/settings/__next._index.txt +11 -11
  368. package/console/settings/__next._tree.txt +2 -2
  369. package/console/settings/__next.settings.__PAGE__.txt +4 -4
  370. package/console/settings/__next.settings.txt +5 -5
  371. package/console/settings/account-preferences/__next._full.txt +33 -31
  372. package/console/settings/account-preferences/__next._head.txt +4 -4
  373. package/console/settings/account-preferences/__next._index.txt +11 -11
  374. package/console/settings/account-preferences/__next._tree.txt +2 -2
  375. package/console/settings/account-preferences/__next.settings.account-preferences.__PAGE__.txt +3 -3
  376. package/console/settings/account-preferences/__next.settings.account-preferences.txt +3 -3
  377. package/console/settings/account-preferences/__next.settings.txt +5 -5
  378. package/console/settings/account-preferences.html +1 -1
  379. package/console/settings/account-preferences.txt +33 -31
  380. package/console/settings/api-keys/__next._full.txt +33 -31
  381. package/console/settings/api-keys/__next._head.txt +4 -4
  382. package/console/settings/api-keys/__next._index.txt +11 -11
  383. package/console/settings/api-keys/__next._tree.txt +2 -2
  384. package/console/settings/api-keys/__next.settings.api-keys.__PAGE__.txt +3 -3
  385. package/console/settings/api-keys/__next.settings.api-keys.txt +3 -3
  386. package/console/settings/api-keys/__next.settings.txt +5 -5
  387. package/console/settings/api-keys.html +1 -1
  388. package/console/settings/api-keys.txt +33 -31
  389. package/console/settings/billing/__next._full.txt +36 -34
  390. package/console/settings/billing/__next._head.txt +4 -4
  391. package/console/settings/billing/__next._index.txt +11 -11
  392. package/console/settings/billing/__next._tree.txt +2 -2
  393. package/console/settings/billing/__next.settings.billing.__PAGE__.txt +4 -4
  394. package/console/settings/billing/__next.settings.billing.txt +3 -3
  395. package/console/settings/billing/__next.settings.txt +5 -5
  396. package/console/settings/billing.html +1 -1
  397. package/console/settings/billing.txt +36 -34
  398. package/console/settings/channel-apps/__next._full.txt +33 -31
  399. package/console/settings/channel-apps/__next._head.txt +4 -4
  400. package/console/settings/channel-apps/__next._index.txt +11 -11
  401. package/console/settings/channel-apps/__next._tree.txt +2 -2
  402. package/console/settings/channel-apps/__next.settings.channel-apps.__PAGE__.txt +3 -3
  403. package/console/settings/channel-apps/__next.settings.channel-apps.txt +3 -3
  404. package/console/settings/channel-apps/__next.settings.txt +5 -5
  405. package/console/settings/channel-apps.html +1 -1
  406. package/console/settings/channel-apps.txt +33 -31
  407. package/console/settings/cursor-accounts/__next._full.txt +36 -34
  408. package/console/settings/cursor-accounts/__next._head.txt +4 -4
  409. package/console/settings/cursor-accounts/__next._index.txt +11 -11
  410. package/console/settings/cursor-accounts/__next._tree.txt +2 -2
  411. package/console/settings/cursor-accounts/__next.settings.cursor-accounts.__PAGE__.txt +4 -4
  412. package/console/settings/cursor-accounts/__next.settings.cursor-accounts.txt +3 -3
  413. package/console/settings/cursor-accounts/__next.settings.txt +5 -5
  414. package/console/settings/cursor-accounts.html +1 -1
  415. package/console/settings/cursor-accounts.txt +36 -34
  416. package/console/settings/environments/__next._full.txt +33 -31
  417. package/console/settings/environments/__next._head.txt +4 -4
  418. package/console/settings/environments/__next._index.txt +11 -11
  419. package/console/settings/environments/__next._tree.txt +2 -2
  420. package/console/settings/environments/__next.settings.environments.__PAGE__.txt +3 -3
  421. package/console/settings/environments/__next.settings.environments.txt +3 -3
  422. package/console/settings/environments/__next.settings.txt +5 -5
  423. package/console/settings/environments.html +1 -1
  424. package/console/settings/environments.txt +33 -31
  425. package/console/settings/identity-providers/__next._full.txt +33 -31
  426. package/console/settings/identity-providers/__next._head.txt +4 -4
  427. package/console/settings/identity-providers/__next._index.txt +11 -11
  428. package/console/settings/identity-providers/__next._tree.txt +2 -2
  429. package/console/settings/identity-providers/__next.settings.identity-providers.__PAGE__.txt +3 -3
  430. package/console/settings/identity-providers/__next.settings.identity-providers.txt +3 -3
  431. package/console/settings/identity-providers/__next.settings.txt +5 -5
  432. package/console/settings/identity-providers.html +1 -1
  433. package/console/settings/identity-providers.txt +33 -31
  434. package/console/settings/invitations/__next._full.txt +33 -31
  435. package/console/settings/invitations/__next._head.txt +4 -4
  436. package/console/settings/invitations/__next._index.txt +11 -11
  437. package/console/settings/invitations/__next._tree.txt +2 -2
  438. package/console/settings/invitations/__next.settings.invitations.__PAGE__.txt +3 -3
  439. package/console/settings/invitations/__next.settings.invitations.txt +3 -3
  440. package/console/settings/invitations/__next.settings.txt +5 -5
  441. package/console/settings/invitations.html +1 -1
  442. package/console/settings/invitations.txt +33 -31
  443. package/console/settings/licenses/__next._full.txt +36 -34
  444. package/console/settings/licenses/__next._head.txt +4 -4
  445. package/console/settings/licenses/__next._index.txt +11 -11
  446. package/console/settings/licenses/__next._tree.txt +2 -2
  447. package/console/settings/licenses/__next.settings.licenses.__PAGE__.txt +4 -4
  448. package/console/settings/licenses/__next.settings.licenses.txt +3 -3
  449. package/console/settings/licenses/__next.settings.txt +5 -5
  450. package/console/settings/licenses.html +1 -1
  451. package/console/settings/licenses.txt +36 -34
  452. package/console/settings/members/__next._full.txt +33 -31
  453. package/console/settings/members/__next._head.txt +4 -4
  454. package/console/settings/members/__next._index.txt +11 -11
  455. package/console/settings/members/__next._tree.txt +2 -2
  456. package/console/settings/members/__next.settings.members.__PAGE__.txt +3 -3
  457. package/console/settings/members/__next.settings.members.txt +3 -3
  458. package/console/settings/members/__next.settings.txt +5 -5
  459. package/console/settings/members.html +1 -1
  460. package/console/settings/members.txt +33 -31
  461. package/console/settings/memory/__next._full.txt +33 -31
  462. package/console/settings/memory/__next._head.txt +4 -4
  463. package/console/settings/memory/__next._index.txt +11 -11
  464. package/console/settings/memory/__next._tree.txt +2 -2
  465. package/console/settings/memory/__next.settings.memory.__PAGE__.txt +3 -3
  466. package/console/settings/memory/__next.settings.memory.txt +3 -3
  467. package/console/settings/memory/__next.settings.txt +5 -5
  468. package/console/settings/memory.html +1 -1
  469. package/console/settings/memory.txt +33 -31
  470. package/console/settings/oauth-apps/__next._full.txt +33 -31
  471. package/console/settings/oauth-apps/__next._head.txt +4 -4
  472. package/console/settings/oauth-apps/__next._index.txt +11 -11
  473. package/console/settings/oauth-apps/__next._tree.txt +2 -2
  474. package/console/settings/oauth-apps/__next.settings.oauth-apps.__PAGE__.txt +3 -3
  475. package/console/settings/oauth-apps/__next.settings.oauth-apps.txt +3 -3
  476. package/console/settings/oauth-apps/__next.settings.txt +5 -5
  477. package/console/settings/oauth-apps.html +1 -1
  478. package/console/settings/oauth-apps.txt +33 -31
  479. package/console/settings/org-preferences/__next._full.txt +33 -31
  480. package/console/settings/org-preferences/__next._head.txt +4 -4
  481. package/console/settings/org-preferences/__next._index.txt +11 -11
  482. package/console/settings/org-preferences/__next._tree.txt +2 -2
  483. package/console/settings/org-preferences/__next.settings.org-preferences.__PAGE__.txt +3 -3
  484. package/console/settings/org-preferences/__next.settings.org-preferences.txt +3 -3
  485. package/console/settings/org-preferences/__next.settings.txt +5 -5
  486. package/console/settings/org-preferences.html +1 -1
  487. package/console/settings/org-preferences.txt +33 -31
  488. package/console/settings/org-profile/__next._full.txt +33 -31
  489. package/console/settings/org-profile/__next._head.txt +4 -4
  490. package/console/settings/org-profile/__next._index.txt +11 -11
  491. package/console/settings/org-profile/__next._tree.txt +2 -2
  492. package/console/settings/org-profile/__next.settings.org-profile.__PAGE__.txt +3 -3
  493. package/console/settings/org-profile/__next.settings.org-profile.txt +3 -3
  494. package/console/settings/org-profile/__next.settings.txt +5 -5
  495. package/console/settings/org-profile.html +1 -1
  496. package/console/settings/org-profile.txt +33 -31
  497. package/console/settings/plans/__next._full.txt +40 -0
  498. package/console/settings/plans/__next._head.txt +6 -0
  499. package/console/settings/plans/__next._index.txt +15 -0
  500. package/console/settings/plans/__next._tree.txt +5 -0
  501. package/console/settings/plans/__next.settings.plans.__PAGE__.txt +9 -0
  502. package/console/settings/plans/__next.settings.plans.txt +5 -0
  503. package/console/settings/plans/__next.settings.txt +6 -0
  504. package/console/settings/plans.html +1 -0
  505. package/console/settings/plans.txt +40 -0
  506. package/console/settings/platform-clients/__next._full.txt +33 -31
  507. package/console/settings/platform-clients/__next._head.txt +4 -4
  508. package/console/settings/platform-clients/__next._index.txt +11 -11
  509. package/console/settings/platform-clients/__next._tree.txt +2 -2
  510. package/console/settings/platform-clients/__next.settings.platform-clients.__PAGE__.txt +3 -3
  511. package/console/settings/platform-clients/__next.settings.platform-clients.txt +3 -3
  512. package/console/settings/platform-clients/__next.settings.txt +5 -5
  513. package/console/settings/platform-clients.html +1 -1
  514. package/console/settings/platform-clients.txt +33 -31
  515. package/console/settings/pricing-governance/__next._full.txt +36 -34
  516. package/console/settings/pricing-governance/__next._head.txt +4 -4
  517. package/console/settings/pricing-governance/__next._index.txt +11 -11
  518. package/console/settings/pricing-governance/__next._tree.txt +2 -2
  519. package/console/settings/pricing-governance/__next.settings.pricing-governance.__PAGE__.txt +4 -4
  520. package/console/settings/pricing-governance/__next.settings.pricing-governance.txt +3 -3
  521. package/console/settings/pricing-governance/__next.settings.txt +5 -5
  522. package/console/settings/pricing-governance.html +1 -1
  523. package/console/settings/pricing-governance.txt +36 -34
  524. package/console/settings/provider-standing/__next._full.txt +36 -34
  525. package/console/settings/provider-standing/__next._head.txt +4 -4
  526. package/console/settings/provider-standing/__next._index.txt +11 -11
  527. package/console/settings/provider-standing/__next._tree.txt +2 -2
  528. package/console/settings/provider-standing/__next.settings.provider-standing.__PAGE__.txt +4 -4
  529. package/console/settings/provider-standing/__next.settings.provider-standing.txt +3 -3
  530. package/console/settings/provider-standing/__next.settings.txt +5 -5
  531. package/console/settings/provider-standing.html +1 -1
  532. package/console/settings/provider-standing.txt +36 -34
  533. package/console/settings/teams/__next._full.txt +33 -31
  534. package/console/settings/teams/__next._head.txt +4 -4
  535. package/console/settings/teams/__next._index.txt +11 -11
  536. package/console/settings/teams/__next._tree.txt +2 -2
  537. package/console/settings/teams/__next.settings.teams.__PAGE__.txt +3 -3
  538. package/console/settings/teams/__next.settings.teams.txt +3 -3
  539. package/console/settings/teams/__next.settings.txt +5 -5
  540. package/console/settings/teams.html +1 -1
  541. package/console/settings/teams.txt +33 -31
  542. package/console/settings/usage/__next._full.txt +33 -31
  543. package/console/settings/usage/__next._head.txt +4 -4
  544. package/console/settings/usage/__next._index.txt +11 -11
  545. package/console/settings/usage/__next._tree.txt +2 -2
  546. package/console/settings/usage/__next.settings.txt +5 -5
  547. package/console/settings/usage/__next.settings.usage.__PAGE__.txt +3 -3
  548. package/console/settings/usage/__next.settings.usage.txt +3 -3
  549. package/console/settings/usage.html +1 -1
  550. package/console/settings/usage.txt +33 -31
  551. package/console/settings.html +1 -1
  552. package/console/settings.txt +32 -33
  553. package/console/workflows/__next._full.txt +29 -30
  554. package/console/workflows/__next._head.txt +4 -4
  555. package/console/workflows/__next._index.txt +11 -11
  556. package/console/workflows/__next._tree.txt +2 -2
  557. package/console/workflows/__next.workflows.__PAGE__.txt +2 -2
  558. package/console/workflows/__next.workflows.txt +3 -3
  559. package/console/workflows/__placeholder__/__placeholder__/__next._full.txt +25 -25
  560. package/console/workflows/__placeholder__/__placeholder__/__next._head.txt +4 -4
  561. package/console/workflows/__placeholder__/__placeholder__/__next._index.txt +11 -11
  562. package/console/workflows/__placeholder__/__placeholder__/__next._tree.txt +2 -2
  563. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.$d$org.$d$slug.__PAGE__.txt +3 -3
  564. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.$d$org.$d$slug.txt +3 -3
  565. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.$d$org.txt +3 -3
  566. package/console/workflows/__placeholder__/__placeholder__/__next.workflows.txt +3 -3
  567. package/console/workflows/__placeholder__/__placeholder__.html +1 -1
  568. package/console/workflows/__placeholder__/__placeholder__.txt +25 -25
  569. package/console/workflows/executions/__next._full.txt +31 -29
  570. package/console/workflows/executions/__next._head.txt +4 -4
  571. package/console/workflows/executions/__next._index.txt +11 -11
  572. package/console/workflows/executions/__next._tree.txt +2 -2
  573. package/console/workflows/executions/__next.workflows.executions.__PAGE__.txt +2 -2
  574. package/console/workflows/executions/__next.workflows.executions.txt +3 -3
  575. package/console/workflows/executions/__next.workflows.txt +3 -3
  576. package/console/workflows/executions/__placeholder__/__next._full.txt +25 -25
  577. package/console/workflows/executions/__placeholder__/__next._head.txt +4 -4
  578. package/console/workflows/executions/__placeholder__/__next._index.txt +11 -11
  579. package/console/workflows/executions/__placeholder__/__next._tree.txt +2 -2
  580. package/console/workflows/executions/__placeholder__/__next.workflows.executions.$d$id.__PAGE__.txt +3 -3
  581. package/console/workflows/executions/__placeholder__/__next.workflows.executions.$d$id.txt +3 -3
  582. package/console/workflows/executions/__placeholder__/__next.workflows.executions.txt +3 -3
  583. package/console/workflows/executions/__placeholder__/__next.workflows.txt +3 -3
  584. package/console/workflows/executions/__placeholder__.html +1 -1
  585. package/console/workflows/executions/__placeholder__.txt +25 -25
  586. package/console/workflows/executions.html +1 -1
  587. package/console/workflows/executions.txt +31 -29
  588. package/console/workflows.html +1 -1
  589. package/console/workflows.txt +29 -30
  590. package/main.js +14 -14
  591. package/package.json +6 -6
  592. package/console/_next/static/chunks/01t5bq-0-a_i1.js +0 -1
  593. package/console/_next/static/chunks/03_~yhksuy9sj.js +0 -2
  594. package/console/_next/static/chunks/06.ubnm0x8bcb.js +0 -1
  595. package/console/_next/static/chunks/09a4r7n49gx_k.js +0 -1
  596. package/console/_next/static/chunks/0ckl6nb6jxjmr.js +0 -1
  597. package/console/_next/static/chunks/0cnrykkxe_pym.js +0 -1
  598. package/console/_next/static/chunks/0f9xh0e8xu4u8.js +0 -1
  599. package/console/_next/static/chunks/0fy2-q-5a0j3r.js +0 -1
  600. package/console/_next/static/chunks/0idetqaa6m7tp.js +0 -1
  601. package/console/_next/static/chunks/0jeu-2mti735o.js +0 -1
  602. package/console/_next/static/chunks/0lq22-4n7_uyt.js +0 -34
  603. package/console/_next/static/chunks/0m94l3p58m6us.js +0 -1
  604. package/console/_next/static/chunks/0pu0kqdhekhhu.css +0 -1
  605. package/console/_next/static/chunks/0ruvic3m1tid0.js +0 -1
  606. package/console/_next/static/chunks/0vx4g_lnlck8u.js +0 -1
  607. package/console/_next/static/chunks/0zfzrf3u6eg~~.js +0 -1
  608. package/console/_next/static/chunks/0~lruz9m9iasi.js +0 -1
  609. package/console/_next/static/chunks/11wz2phmo~89v.js +0 -1
  610. package/console/_next/static/chunks/15jp2u46do.ep.js +0 -1
  611. /package/console/_next/static/{KsDOjh35hCsAtLtCZduG8 → 8QW0GR8B_i8LjUXDFgwS7}/_buildManifest.js +0 -0
  612. /package/console/_next/static/{KsDOjh35hCsAtLtCZduG8 → 8QW0GR8B_i8LjUXDFgwS7}/_clientMiddlewareManifest.js +0 -0
  613. /package/console/_next/static/{KsDOjh35hCsAtLtCZduG8 → 8QW0GR8B_i8LjUXDFgwS7}/_ssgManifest.js +0 -0
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,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"}])},818094,e=>{"use strict";var t=e.i(170255),s=e.i(430182);let r=new Map([[t.ApiResourceKind.identity_provider,[s.IamRole.viewer]],[t.ApiResourceKind.oauth_app,[s.IamRole.viewer]],[t.ApiResourceKind.platform_client,[s.IamRole.viewer]],[t.ApiResourceKind.team,[s.IamRole.member]],[t.ApiResourceKind.organization,[s.IamRole.owner,s.IamRole.admin,s.IamRole.member,s.IamRole.viewer]],[t.ApiResourceKind.agent,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.session,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.skill,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.mcp_server,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.agent_instance,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.agent_share,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.agent_channel,[s.IamRole.owner,s.IamRole.viewer,s.IamRole.participant]],[t.ApiResourceKind.channel_app,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.workflow,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.workflow_instance,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.workflow_execution,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.environment,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.artifact,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.schedule,[s.IamRole.owner,s.IamRole.viewer]],[t.ApiResourceKind.plugin,[s.IamRole.owner,s.IamRole.viewer]]]),i=new Map([[t.ApiResourceKind.agent,[s.IamRole.viewer]],[t.ApiResourceKind.skill,[s.IamRole.viewer]],[t.ApiResourceKind.mcp_server,[s.IamRole.viewer]],[t.ApiResourceKind.agent_instance,[s.IamRole.viewer]],[t.ApiResourceKind.agent_channel,[s.IamRole.viewer,s.IamRole.participant]],[t.ApiResourceKind.workflow,[s.IamRole.viewer]],[t.ApiResourceKind.workflow_instance,[s.IamRole.viewer]],[t.ApiResourceKind.workflow_execution,[s.IamRole.viewer]],[t.ApiResourceKind.schedule,[s.IamRole.viewer]],[t.ApiResourceKind.plugin,[s.IamRole.viewer]]]),n=Object.freeze([]);e.s(["getGrantableRoles",0,function(e){return r.get(e)??n},"getTeamGrantableRoles",0,function(e){return i.get(e)??n},"hasGrantableRoles",0,function(e){let t=r.get(e);return void 0!==t&&t.length>0},"hasTeamGrantableRoles",0,function(e){let t=i.get(e);return void 0!==t&&t.length>0},"isRoleGrantable",0,function(e,t){let s=r.get(e);return void 0!==s&&s.includes(t)},"isRoleTeamGrantable",0,function(e,t){let s=i.get(e);return void 0!==s&&s.includes(t)}],818094)},146312,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),i=e.i(869803),n=e.i(818094),a=e.i(691444);let l=[];e.s(["RoleSelector",0,function({kind:e,onSelect:o,selected:c,defaultRole:d,disabled:g=!1,granteeKind:u="identity_account",omitRoles:m,className:p}){let x=(0,s.useId)(),{options:h,selected:f,select:b}=function(e,t,r="identity_account",i=l){let[o,c]=(0,s.useState)(t??null),d=(0,s.useMemo)(()=>{if(null===e)return[];let t=new Set(i);return("team"===r?(0,n.getTeamGrantableRoles)(e):(0,n.getGrantableRoles)(e)).filter(e=>!t.has(e)).map(e=>({role:e,label:(0,a.iamRoleDisplayName)(e),description:(0,a.iamRoleDescription)(e),value:(0,a.iamRoleToString)(e)}))},[e,r,i]),g=(0,s.useMemo)(()=>null!==o?(0,a.iamRoleToString)(o):"",[o]),u=(0,s.useCallback)(e=>c(e),[]),m=(0,s.useCallback)(()=>c(null),[]);return(0,s.useMemo)(()=>({options:d,selected:o,selectedValue:g,select:u,clear:m,hasOptions:d.length>0}),[d,o,g,u,m])}(e,d,u,m),v=void 0!==c?c:f;return 0===h.length?null:(0,t.jsxs)("fieldset",{className:(0,r.cn)(i.UNSTYLED_FIELDSET,"stg:space-y-1.5",p),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:h.map(e=>{let s=v===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",g&&"stg:pointer-events-none stg:opacity-50"),children:[(0,t.jsx)("input",{type:"radio",name:x,value:e.value,checked:s,disabled:g,onChange:()=>{var t;b(t=e.role),o?.(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)},3422,11493,554212,e=>{"use strict";var t=e.i(424407),s=e.i(304532),r=e.i(421415),i=e.i(988158),n=e.i(761867);let a=(0,t.fileDesc)("CiFhaS9zdGlnbWVyL2lhbS90ZWFtL3YxL3NwZWMucHJvdG8SFmFpLnN0aWdtZXIuaWFtLnRlYW0udjEiKQoIVGVhbVNwZWMSHQoLZGVzY3JpcHRpb24YASABKAlCCLpIBXIDGPQDYgZwcm90bzM",[n.file_buf_validate_validate]),l=(0,s.messageDesc)(a,0);e.s(["TeamSpecSchema",0,l,"file_ai_stigmer_iam_team_v1_spec",0,a],11493);let o=(0,t.fileDesc)("CiBhaS9zdGlnbWVyL2lhbS90ZWFtL3YxL2FwaS5wcm90bxIWYWkuc3RpZ21lci5pYW0udGVhbS52MSKXAgoEVGVhbRItCgthcGlfdmVyc2lvbhgBIAEoCUIYukgVchMKEWlhbS5zdGlnbWVyLmFpL3YxEhkKBGtpbmQYAiABKAlCC7pICHIGCgRUZWFtEk0KCG1ldGFkYXRhGAMgASgLMjMuYWkuc3RpZ21lci5jb21tb25zLmFwaXJlc291cmNlLkFwaVJlc291cmNlTWV0YWRhdGFCBrpIA8gBARIuCgRzcGVjGAQgASgLMiAuYWkuc3RpZ21lci5pYW0udGVhbS52MS5UZWFtU3BlYxJGCgZzdGF0dXMYBSABKAsyNi5haS5zdGlnbWVyLmNvbW1vbnMuYXBpcmVzb3VyY2UuQXBpUmVzb3VyY2VBdWRpdFN0YXR1c2IGcHJvdG8z",[r.file_ai_stigmer_commons_apiresource_metadata,i.file_ai_stigmer_commons_apiresource_status,a,n.file_buf_validate_validate]),c=(0,s.messageDesc)(o,0);e.s(["TeamSchema",0,c,"file_ai_stigmer_iam_team_v1_api",0,o],554212);let d=(0,t.fileDesc)("Ch9haS9zdGlnbWVyL2lhbS90ZWFtL3YxL2lvLnByb3RvEhZhaS5zdGlnbWVyLmlhbS50ZWFtLnYxIjYKBVRlYW1zEi0KB2VudHJpZXMYASADKAsyHC5haS5zdGlnbWVyLmlhbS50ZWFtLnYxLlRlYW0iKwoTTGlzdFRlYW1zQnlPcmdJbnB1dBIUCgNvcmcYASABKAlCB7pIBHICEAFiBnByb3RvMw",[o,n.file_buf_validate_validate]),g=(0,s.messageDesc)(d,1);e.s(["ListTeamsByOrgInputSchema",0,g,"file_ai_stigmer_iam_team_v1_io",0,d],3422)},884561,e=>{"use strict";var t=e.i(891287),s=e.i(170255),r=e.i(267872),i=e.i(632897);let n=s.ApiResourceKind[s.ApiResourceKind.identity_account],a=s.ApiResourceKind[s.ApiResourceKind.team],l="member";function o(e){return{kind:"identity_account",id:e}}function c(e){return{kind:"team",id:e}}e.s(["granteeFromView",0,function(e){if(e.id){if(e.kind===n&&""===e.relation)return o(e.id);if(e.kind===a&&e.relation===l)return c(e.id)}},"granteeKey",0,function(e){return`${e.kind}:${e.id}`},"granteeRef",0,function(e){switch(e.kind){case"identity_account":return(0,t.create)(i.ApiResourceRefSchema,{kind:n,id:e.id});case"team":return(0,t.create)(i.ApiResourceRefSchema,{kind:a,id:e.id,relation:l});default:return e}},"isPlatformClientAccount",0,function(e){return e.kind===n&&e.identityOrigin?.provisioningMode===r.IdentityAccountProvisioningMode.platform_client},"personGrantee",0,o,"teamGrantee",0,c])},564035,288441,890079,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 l=(0,i.useStigmer)(),o=e?.kind??null,c=e?.id??null,d=a?.includeInherited??!1,{data:g,isLoading:u,isRefetching:m,error:p,refetch:x}=(0,n.useFetch)(o&&c?()=>{let e=(0,t.create)(s.ListResourceAccessInputSchema,{resource:(0,t.create)(r.ApiResourceRefSchema,{kind:o,id:c}),includeInherited:d});return l.iamPolicy.listResourceAccessByPrincipal(e).then(e=>[...e.entries])}:null,[o,c,d,l],[]);return{members:g,isLoading:u,isRefetching:m,error:p,refetch:x}}],564035);var a=e.i(271645),l=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),o=(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,l.toError)(e)),e}finally{s(!1)}},[e]),isCreating:t,error:r,clearError:o}}],288441),e.s(["useDeleteIamPolicy",0,function(){let e=(0,i.useStigmer)(),[t,s]=(0,a.useState)(!1),[r,n]=(0,a.useState)(null),o=(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,l.toError)(e)),e}finally{s(!1)}},[e]),isDeleting:t,error:r,clearError:o}}],890079)},32011,e=>{"use strict";var t=e.i(843476),s=e.i(893976),r=e.i(188482);function i(e){return e?.identityOrigin?.providerDisplayName??""}e.s(["ProviderBadge",0,function({principal:e,className:n}){let a=i(e);return a?(0,t.jsxs)(r.Tooltip,{children:[(0,t.jsx)(r.TooltipTrigger,{render:(0,t.jsx)("span",{className:(0,s.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",n)}),children:a}),(0,t.jsx)(r.TooltipContent,{side:"top",children:`Identity provider: ${a}`})]}):null},"providerLabel",0,i])},14606,e=>{"use strict";let t=(0,e.i(475254).default)("users-round",[["path",{d:"M18 21a8 8 0 0 0-16 0",key:"3ypg7q"}],["circle",{cx:"10",cy:"8",r:"5",key:"o932ke"}],["path",{d:"M22 20c0-3.37-2-6.5-4-8a5 5 0 0 0-.45-8.3",key:"10s06x"}]]);e.s(["UsersRound",0,t],14606)},681094,e=>{"use strict";var t=e.i(271645),s=e.i(891287),r=e.i(170255),i=e.i(632897),n=e.i(818094),a=e.i(884561),l=e.i(691444),o=e.i(597744),c=e.i(326283),d=e.i(564035),g=e.i(288441),u=e.i(890079);e.s(["useShareFlow",0,function(e){let m=(0,t.useMemo)(()=>e?{kind:e.kind,id:e.id}:null,[e?.kind,e?.id]),{members:p,isLoading:x,isRefetching:h,error:f,refetch:b}=(0,d.useResourceAccess)(m),v=e?.resourceKind??null,{roles:R,hasRoles:w}=(0,t.useMemo)(()=>null===v?{roles:[],hasRoles:!1}:{roles:(0,n.getGrantableRoles)(v),hasRoles:(0,n.hasGrantableRoles)(v)},[v]),y=(0,o.useResourceAvailable)(r.ApiResourceKind.team),j=(0,t.useMemo)(()=>null===v?[]:(0,n.getTeamGrantableRoles)(v),[v]),k=y&&j.length>0,{create:I,isCreating:S,error:N,clearError:A}=(0,g.useCreateIamPolicy)(),{remove:_}=(0,u.useDeleteIamPolicy)(),[C,K]=(0,t.useState)(!1),[M,G]=(0,t.useState)(null),L=(0,t.useRef)(e);L.current=e;let T=(0,t.useRef)(p);T.current=p;let B=(0,t.useCallback)(async(e,t)=>{let r=L.current;r&&(await I((0,s.create)(i.IamPolicySpecSchema,{principal:(0,a.granteeRef)(e),resource:(0,s.create)(i.ApiResourceRefSchema,{kind:r.kind,id:r.id}),relation:(0,l.iamRoleToString)(t)})),b())},[I,b]),W=(0,t.useCallback)(async e=>{let t=L.current;if(!t)return;let r=(0,a.granteeKey)(e),n=T.current.filter(e=>{let t=e.principal?(0,a.granteeFromView)(e.principal):void 0;return void 0!==t&&(0,a.granteeKey)(t)===r}).flatMap(e=>e.roles).filter(e=>!e.isInherited&&e.role?.code).map(e=>e.role?.code??"");K(!0),G(null);try{for(let r of new Set(n))await _((0,s.create)(i.IamPolicySpecSchema,{principal:(0,a.granteeRef)(e),resource:(0,s.create)(i.ApiResourceRefSchema,{kind:t.kind,id:t.id}),relation:r}))}catch(e){throw G((0,c.toError)(e)),e}finally{K(!1),b()}},[_,b]),F=(0,t.useCallback)(()=>{A(),G(null)},[A]);return(0,t.useMemo)(()=>({accessList:p,isLoading:x,isRefetching:h,fetchError:f,grantableRoles:R,hasGrantableRoles:w,teamGrantableRoles:j,canShareWithTeams:k,grant:B,isGranting:S,grantError:N,revoke:W,isRevoking:C,revokeError:M,refetch:b,clearErrors:F}),[p,x,h,f,R,w,j,k,B,S,N,W,C,M,b,F])}],681094)},540279,9531,982943,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),i=e.i(884561),n=e.i(14606);function a({kind:e,name:s,className:i}){return(0,t.jsx)("div",{className:(0,r.cn)("stg:flex stg:h-6 stg:w-6 stg:shrink-0 stg:items-center stg:justify-center stg:rounded-full stg:bg-avatar stg:text-[0.6rem] stg:font-medium stg:text-muted-foreground",i),"aria-hidden":"true",children:"team"===e?(0,t.jsx)(n.UsersRound,{className:"stg:h-3.5 stg:w-3.5"}):(s[0]??"?").toUpperCase()})}var l=e.i(590150);function o(){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"})})}e.s(["AccessRow",0,function({entry:e,grantGate:n,onRemove:c,isRemoving:d,showRoles:g=!0}){let u=e.principal,m=u?(0,i.granteeFromView)(u):void 0,p=m?.kind==="team",x=u?.name||u?.email||u?.id||"Unknown",h=[...new Set(e.roles.map(e=>e.role?.name||e.role?.code).filter(Boolean))].join(", "),f=p?"Team":u?.email&&u.name?u.email:"",b=(0,s.useCallback)(async()=>{if(m)try{await c(m)}catch{}},[m,c]);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)(a,{kind:p?"team":"identity_account",name:u?.name||u?.email||"?"}),(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsx)("p",{className:"stg:text-xs stg:text-foreground stg:truncate",children:x}),f&&(0,t.jsx)("p",{className:"stg:text-[0.6rem] stg:text-muted-foreground stg:truncate",children:f})]})]}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5 stg:shrink-0",children:[g&&(0,t.jsx)("span",{className:"stg:text-[0.6rem] stg:text-muted-foreground stg:capitalize",children:h||"—"}),m&&(0,t.jsx)(l.PermissionGate,{resource:n,relation:"can_grant_access",children:(0,t.jsx)("button",{type:"button",onClick:b,disabled:d,"aria-label":`Remove ${x}'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:focus-visible:opacity-100","stg:hover:text-destructive stg:hover:bg-destructive-subtle","stg:disabled:pointer-events-none stg:disabled:opacity-50","stg:transition-opacity"),children:(0,t.jsx)(o,{})})})]})]})},"accessEntryKey",0,function(e){let t=e.principal;return t?`${t.kind}:${t.id}#${t.relation}`:"unknown"}],540279);var c=e.i(610595),d=e.i(869803),g=e.i(32011),u=e.i(891287),m=e.i(3422),p=e.i(586108),x=e.i(583093);let h=[];function f(e){let t=(0,p.useStigmer)(),{data:r,isLoading:i,isRefetching:n,error:a,refetch:l}=(0,x.useFetch)(e?()=>t.team.listByOrg((0,u.create)(m.ListTeamsByOrgInputSchema,{org:e})).then(e=>[...e.entries]):null,[e,t],h);return(0,s.useMemo)(()=>({teams:r,isLoading:i,isRefetching:n,error:a,refetch:l}),[r,i,n,a,l])}e.s(["useTeamList",0,f],9531);var b=e.i(564035);function v({label:e,count:r,children:i}){let n=(0,s.useId)();return 0===r?null:(0,t.jsxs)("li",{role:"presentation",children:[(0,t.jsx)("div",{id:n,className:"stg:px-2.5 stg:pt-1.5 stg:pb-1 stg:text-[0.6rem] stg:font-medium stg:uppercase stg:tracking-wide stg:text-muted-foreground",children:e}),(0,t.jsx)("ul",{role:"group","aria-labelledby":n,className:d.UNSTYLED_LIST,children:i})]})}function R({candidate:e}){let s="team"===e.kind?e.description:e.email!==e.name?e.email:"";return s?(0,t.jsx)("span",{className:"stg:block stg:truncate stg:text-[0.6rem] stg:text-muted-foreground",children:s}):null}function w({value:e}){return"team"===e.kind?(0,t.jsx)("span",{className:"stg:block stg:truncate stg:text-[0.6rem] stg:text-muted-foreground",children:"Team"}):(0,t.jsx)(R,{candidate:e})}function y(){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"})})}e.s(["PrincipalPicker",0,function({orgId:e,value:n,onChange:l,includeTeams:o=!1,excludeGrantees:u,disabled:m=!1,label:p,autoFocus:x=!0,className:h}){let j=(0,s.useId)(),{people:k,teams:I,isLoading:S,error:N}=function({orgId:e,includeTeams:t}){let r=(0,b.useResourceAccess)(e?{kind:"organization",id:e}:null),n=f(t?e:null),a=(0,s.useMemo)(()=>{let e=new Map;for(let t of r.members){let s=t.principal,r=s?(0,i.granteeFromView)(s):void 0;!s||r?.kind!=="identity_account"||e.has(r.id)||e.set(r.id,{kind:"identity_account",grantee:(0,i.personGrantee)(r.id),name:s.name||s.email||s.id,email:s.email,view:s})}return[...e.values()]},[r.members]),l=(0,s.useMemo)(()=>t?n.teams.flatMap(e=>{let t=e.metadata?.id;return t?[{kind:"team",grantee:(0,i.teamGrantee)(t),name:e.metadata?.name||t,description:e.spec?.description??"",team:e}]:[]}):[],[t,n.teams]),o=r.isLoading||t&&n.isLoading,c=r.error??(t?n.error:null);return(0,s.useMemo)(()=>({people:a,teams:l,isLoading:o,error:c}),[a,l,o,c])}({orgId:e||null,includeTeams:o}),[A,_]=(0,s.useState)(""),[C,K]=(0,s.useState)(!1),[M,G]=(0,s.useState)(0),L=(0,s.useRef)(null),T=(0,s.useMemo)(()=>new Set((u??[]).map(i.granteeKey)),[u]),B=(0,s.useCallback)(e=>T.has((0,i.granteeKey)(e.grantee)),[T]),W=(0,s.useMemo)(()=>{let e=new Map;for(let t of k){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))},[k]),{matchingPeople:F,matchingTeams:P}=(0,s.useMemo)(()=>{let e=A.trim().toLowerCase();return{matchingPeople:e?k.filter(t=>t.name.toLowerCase().includes(e)||t.email.toLowerCase().includes(e)):k,matchingTeams:e?I.filter(t=>t.name.toLowerCase().includes(e)||t.description.toLowerCase().includes(e)):I}},[k,I,A]),Y=(0,s.useMemo)(()=>[...P,...F],[F,P]),D=(0,s.useCallback)(e=>{B(e)||(l(e),_(""),K(!1))},[B,l]),V=(0,s.useCallback)(e=>{if("ArrowDown"===e.key)e.preventDefault(),K(!0),G(e=>Math.min(e+1,Y.length-1));else if("ArrowUp"===e.key)e.preventDefault(),G(e=>Math.max(e-1,0));else if("Enter"===e.key){e.preventDefault();let t=Y[M];t&&D(t)}else"Escape"===e.key&&K(!1)},[Y,M,D]),z=p??(o?"Person or team":"Person");if(n)return(0,t.jsxs)("div",{className:(0,r.cn)("stg:space-y-1",h),children:[(0,t.jsx)("span",{className:"stg:block stg:text-xs stg:font-medium stg:text-foreground",children:z}),(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)(a,{kind:n.kind,name:n.name}),(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:n.name}),"identity_account"===n.kind&&(0,t.jsx)(g.ProviderBadge,{principal:n.view})]}),(0,t.jsx)(w,{value:n})]})]}),(0,t.jsx)("button",{type:"button",onClick:()=>l(null),disabled:m,"aria-label":"team"===n.kind?"Clear selected team":"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)(y,{})})]})]});let E=(e,s)=>{var n,l;let o=B(e),c=s===M;return(0,t.jsxs)("li",{role:"option","aria-selected":c,"aria-disabled":o,onMouseEnter:()=>G(s),onMouseDown:t=>{t.preventDefault(),D(e)},className:(0,r.cn)("stg:flex stg:items-center stg:justify-between stg:gap-2 stg:px-2.5 stg:py-1.5",o?"stg:cursor-not-allowed stg:opacity-50":"stg:cursor-pointer",c&&!o&&"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)(a,{kind:e.kind,name:e.name}),(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:e.name}),"identity_account"===e.kind&&(n=e,l=W,!!(0,g.providerLabel)(n.view)&&(n.view.identityOrigin?.providerDisplayName!=="Stigmer"||!!n.email&&l.has(n.email.toLowerCase())))&&(0,t.jsx)(g.ProviderBadge,{principal:e.view})]}),(0,t.jsx)(R,{candidate:e})]})]}),o&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-[0.6rem] stg:text-muted-foreground",children:"Has access"})]},(0,i.granteeKey)(e.grantee))},U=0===Y.length;return(0,t.jsxs)("div",{className:(0,r.cn)("stg:space-y-1",h),children:[(0,t.jsx)("label",{htmlFor:`${j}-input`,className:"stg:block stg:text-xs stg:font-medium stg:text-foreground",children:z}),(0,t.jsxs)("div",{className:"stg:relative",children:[(0,t.jsx)("input",{id:`${j}-input`,ref:L,type:"text",role:"combobox","aria-expanded":C,"aria-controls":j,"aria-autocomplete":"list",autoComplete:"off",value:A,onChange:e=>{_(e.target.value),K(!0),G(0)},onFocus:()=>K(!0),onBlur:()=>{window.setTimeout(()=>K(!1),120)},onKeyDown:V,placeholder:o?"Search people or teams":"Search by name or email",disabled:m||S,autoFocus:x,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")}),C&&(0,t.jsxs)("ul",{id:j,role:"listbox","aria-label":o?"People and teams":"Organization members",className:(0,r.cn)(d.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:[S&&(0,t.jsx)("li",{className:"stg:px-2.5 stg:py-2 stg:text-xs stg:text-muted-foreground",children:o?"Loading people and teams…":"Loading members…"}),!S&&N&&(0,t.jsx)("li",{className:"stg:px-2.5 stg:py-2 stg:text-[0.65rem] stg:text-destructive",role:"alert",children:(0,c.getUserMessage)(N)}),!S&&!N&&U&&(0,t.jsx)("li",{className:"stg:px-2.5 stg:py-2 stg:text-xs stg:text-muted-foreground",children:A.trim()?"No one matches your search.":"No one to share with."}),!S&&!N&&!U&&!o&&F.map((e,t)=>E(e,t)),!S&&!N&&!U&&o&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(v,{label:"Teams",count:P.length,children:P.map((e,t)=>E(e,t))}),(0,t.jsx)(v,{label:"People",count:F.length,children:F.map((e,t)=>E(e,P.length+t))})]})]})]})]})}],982943)},213149,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),i=e.i(468806),n=e.i(170255),a=e.i(818094),l=e.i(597744),o=e.i(610595),c=e.i(884561),d=e.i(869803),g=e.i(681094),u=e.i(540279),m=e.i(891287),p=e.i(632897),x=e.i(691444),h=e.i(288441),f=e.i(146312),b=e.i(982943),v=e.i(379410);function R({resourceKind:e,resourceKindString:i,resourceId:n,orgId:l,includeTeams:d=!1,excludeGrantees:g,onGranted:u,onCancel:w,className:y}){let{create:j,isCreating:k,error:I,clearError:S}=(0,h.useCreateIamPolicy)(),[N,A]=(0,s.useState)(null),[_,C]=(0,s.useState)(null),K=(0,s.useCallback)(t=>{A(t),C(s=>null===s||null===t||("team"===t.kind?(0,a.isRoleTeamGrantable)(e,s):(0,a.isRoleGrantable)(e,s))?s:null)},[e]),M=null!==N&&null!==_&&!k,G=(0,s.useCallback)(async e=>{if(e.preventDefault(),M&&null!==_&&null!==N){S();try{let e=(0,m.create)(p.IamPolicySpecSchema,{principal:(0,c.granteeRef)(N.grantee),resource:(0,m.create)(p.ApiResourceRefSchema,{kind:i,id:n}),relation:(0,x.iamRoleToString)(_)}),t=await j(e);u?.(t)}catch{}}},[M,_,N,i,n,j,S,u]);return(0,t.jsxs)("form",{onSubmit:G,className:(0,r.cn)("stg:space-y-3",y),children:[(0,t.jsxs)("div",{className:"stg:space-y-3",children:[(0,t.jsx)(b.PrincipalPicker,{orgId:l,value:N,onChange:K,includeTeams:d,excludeGrantees:g,disabled:k}),(0,t.jsx)(f.RoleSelector,{kind:e,granteeKind:N?.kind??"identity_account",selected:_,onSelect:C,disabled:k})]}),I&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,o.getUserMessage)(I)}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[(0,t.jsxs)("button",{type:"submit",disabled:!M,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:[k&&(0,t.jsx)(v.SpinnerIcon,{size:12}),"Grant access"]}),w&&(0,t.jsx)("button",{type:"button",onClick:w,disabled:k,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 w=e.i(590150);function y({resource:e,resourceKindString:i,resourceKind:n,orgId:a,className:m}){let{accessList:p,isLoading:x,fetchError:h,revoke:f,isRevoking:b,revokeError:v,refetch:j,hasGrantableRoles:k,canShareWithTeams:I}=(0,g.useShareFlow)(e),S=(0,l.useDeploymentMode)(),[N,A]=(0,s.useState)(!1),_=(0,s.useMemo)(()=>p.flatMap(e=>{let t=e.principal?(0,c.granteeFromView)(e.principal):void 0;return t?[t]:[]}),[p]);if("local"===S&&"organization"!==e.kind)return(0,t.jsxs)("p",{className:(0,r.cn)("stg:text-xs stg:text-muted-foreground",m),children:["This edition does not share ",i.replaceAll("_"," "),"s with individual people. Sharing with specific people is available in Stigmer Enterprise and Cloud."]});let C={kind:i,id:e.id};return(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:flex-col stg:gap-4",m),children:[(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:x?"Loading access list...":`${p.length} with access`}),h&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,o.getUserMessage)(h)}),!x&&p.length>0&&(0,t.jsx)("ul",{className:(0,r.cn)(d.UNSTYLED_LIST,"stg:space-y-1 stg:mt-2"),"aria-label":"Who has access",children:p.map(e=>(0,t.jsx)(u.AccessRow,{entry:e,grantGate:C,onRemove:f,isRemoving:b},(0,u.accessEntryKey)(e)))}),v&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,o.getUserMessage)(v)})]}),k&&(0,t.jsx)(w.PermissionGate,{resource:C,relation:"can_grant_access",children:(0,t.jsx)("div",{className:"stg:border-t stg:border-border stg:pt-3",children:N?(0,t.jsx)(R,{resourceKind:n,resourceKindString:i,resourceId:e.id,orgId:a,includeTeams:I,excludeGrantees:_,onGranted:()=>{A(!1),j()},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-border-prominent","stg:hover:bg-accent-hover stg:transition-colors"),children:I?"+ Add people or teams":"+ Add people"})})})]})}var j=e.i(388023);function k({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 I(){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:o,resource:c,visibility:d,extraSection:g}){let u=(0,s.useId)(),m=(0,s.useCallback)(()=>{o(!1)},[o]),p=(0,a.hasGrantableRoles)(c.kind),x=(0,l.useResourceAvailable)(n.ApiResourceKind.team)&&(0,a.hasTeamGrantableRoles)(c.kind)?"People and teams with access":"People with access";return(0,t.jsx)(i.DialogShell,{open:e,onOpenChange:o,width:"md","aria-labelledby":u,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:u,className:"stg:text-base stg:font-semibold stg:text-foreground",children:"Manage access"}),c.name&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:truncate stg:text-xs stg:text-muted-foreground",children:c.name})]}),(0,t.jsx)("button",{type:"button",onClick:m,"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)(I,{})})]}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:[d&&(0,t.jsx)(k,{title:"General access",description:"Who can find and open this resource.",children:(0,t.jsx)(j.ResourceVisibilityControl,{kind:d.kind,resourceId:c.id,visibility:d.current,org:d.org,onChanged:d.onChanged})}),p&&(0,t.jsx)(k,{title:x,children:(0,t.jsx)(y,{resource:{kind:c.kindString,id:c.id,resourceKind:c.kind},resourceKindString:c.kindString,resourceKind:c.kind,orgId:c.org})}),g&&(0,t.jsx)(k,{title:g.title,description:g.description,children:g.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:m,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)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,506213,e=>{"use strict";e.s([],593742),e.i(593742);var t,i=e.i(271645),n=e.i(66196),r=e.i(58509),s=e.i(933605),o=e.i(789633),l=e.i(926665),a=e.i(151665),c=e.i(206157);e.i(247167);var u=e.i(367805);let d=i.createContext(void 0);function g(e){let t=i.useContext(d);if(void 0===t&&!e)throw Error((0,u.default)(47));return t}var p=e.i(174080),b=e.i(598263),m=e.i(783921),A=e.i(566745),v=e.i(630628),h=e.i(294365),f=e.i(803404),S=e.i(600628),R=e.i(769375),W=e.i(607335);let y={...S.popupStoreSelectors,disabled:(0,m.createSelector)(e=>e.disabled),instantType:(0,m.createSelector)(e=>e.instantType),openMethod:(0,m.createSelector)(e=>e.openMethod),openChangeReason:(0,m.createSelector)(e=>e.openChangeReason),modal:(0,m.createSelector)(e=>e.modal),stickIfOpen:(0,m.createSelector)(e=>e.stickIfOpen),titleElementId:(0,m.createSelector)(e=>e.titleElementId),descriptionElementId:(0,m.createSelector)(e=>e.descriptionElementId),openOnHover:(0,m.createSelector)(e=>e.openOnHover),closeDelay:(0,m.createSelector)(e=>e.closeDelay),hasViewport:(0,m.createSelector)(e=>e.hasViewport)};class V extends b.ReactStore{constructor(e){const t={...(0,S.createInitialPopupStoreState)(),disabled:!1,modal:!1,instantType:void 0,openMethod:null,openChangeReason:null,titleElementId:void 0,descriptionElementId:void 0,stickIfOpen:!0,nested:!1,openOnHover:!1,closeDelay:0,hasViewport:!1,...e};t.open&&e?.mounted===void 0&&(t.mounted=!0),super(t,{popupRef:i.createRef(),backdropRef:i.createRef(),internalBackdropRef:i.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerFocusTargetRef:i.createRef(),beforeContentFocusGuardRef:i.createRef(),stickIfOpenTimeout:new A.Timeout,triggerElements:new R.PopupTriggerMap},y)}setOpen=(e,t)=>{let i=t.reason===f.REASONS.triggerHover,n=t.reason===f.REASONS.triggerPress&&0===t.event.detail,r=!e&&(t.reason===f.REASONS.escapeKey||null==t.reason);if(t.preventUnmountOnClose=()=>{this.set("preventUnmountingOnClose",!0)},this.context.onOpenChange?.(e,t),t.isCanceled)return;let s={open:e,nativeEvent:t.event,reason:t.reason,nested:this.state.nested,triggerElement:t.trigger},o=this.state.floatingRootContext.context.events;o?.emit("openchange",s);let l=()=>{let i={open:e,openChangeReason:t.reason},n=t.trigger?.id??null;(n||e)&&(i.activeTriggerId=n,i.activeTriggerElement=t.trigger??null),this.update(i)};i?(this.set("stickIfOpen",!0),this.context.stickIfOpenTimeout.start(W.PATIENT_CLICK_THRESHOLD,()=>{this.set("stickIfOpen",!1)}),p.flushSync(l)):l(),n||r?this.set("instantType",n?"click":"dismiss"):t.reason===f.REASONS.focusOut?this.set("instantType","focus"):this.set("instantType",void 0)};static useStore(e,t){let i=(0,v.useRefWithInit)(()=>new V(t)).current,n=e??i;return(0,h.useOnMount)(i.disposeEffect),n}disposeEffect=()=>this.context.stickIfOpenTimeout.disposeEffect()}var x=e.i(5963),G=e.i(258642),E=e.i(450091),I=e.i(843476);function k({props:e}){let{children:t,open:u,defaultOpen:g=!1,onOpenChange:p,onOpenChangeComplete:b,modal:m=!1,handle:A,triggerId:v,defaultTriggerId:h=null}=e,S=V.useStore(A?.store,{modal:m,open:g,openProp:u,activeTriggerId:h,triggerIdProp:v});(0,r.useOnFirstRender)(()=>{void 0===u&&!1===S.state.open&&!0===g&&S.update({open:!0,activeTriggerId:h})}),S.useControlledProp("openProp",u),S.useControlledProp("triggerIdProp",v);let R=S.useState("open"),W=S.useState("positionerElement"),y=S.useState("payload"),Z=S.useState("openChangeReason");S.useContextCallback("onOpenChange",p),S.useContextCallback("onOpenChangeComplete",b);let{openMethod:C,triggerProps:B}=(0,E.useOpenInteractionType)(R);(0,G.useImplicitActiveTrigger)(S);let{forceUnmount:Y}=(0,G.useOpenStateTransitions)(R,S,()=>{S.update({stickIfOpen:!0,openChangeReason:null})});(0,n.useScrollLock)(R&&!0===m&&Z!==f.REASONS.triggerHover&&"touch"!==C,W),i.useEffect(()=>{R||S.context.stickIfOpenTimeout.clear()},[S,R]);let X=i.useCallback(e=>{let t=(0,x.createChangeEventDetails)(e);return t.preventUnmountOnClose=()=>{S.set("preventUnmountingOnClose",!0)},t},[S]),N=i.useCallback(()=>{S.setOpen(!1,X(f.REASONS.imperativeAction))},[S,X]);i.useImperativeHandle(e.actionsRef,()=>({unmount:Y,close:N}),[Y,N]);let F=(0,c.useSyncedFloatingRootContext)({popupStore:S,onOpenChange:S.setOpen}),w=(0,s.useDismiss)(F,{outsidePressEvent:{mouse:"trap-focus"===m?"sloppy":"intentional",touch:"sloppy"}}),L=(0,l.useRole)(F),{getReferenceProps:j,getFloatingProps:_,getTriggerProps:J}=(0,o.useInteractions)([w,L]),M=i.useMemo(()=>j(B),[j,B]),K=i.useMemo(()=>J(B),[J,B]),Q=i.useMemo(()=>_(),[_]);S.useSyncedValues({modal:m,openMethod:C,activeTriggerProps:M,inactiveTriggerProps:K,popupProps:Q,floatingRootContext:F,nested:null!=(0,a.useFloatingParentNodeId)()});let z=i.useMemo(()=>({store:S}),[S]);return(0,I.jsx)(d.Provider,{value:z,children:"function"==typeof t?t({payload:y}):t})}var Z=e.i(676477),C=e.i(991730),B=e.i(383590),Y=e.i(327601),X=e.i(437287),N=e.i(804012),F=e.i(397254),w=e.i(189879),L=e.i(672408),j=e.i(247857),_=e.i(559266);let J=i.forwardRef(function(e,t){let{render:n,className:r,disabled:s=!1,nativeButton:l=!0,handle:a,payload:c,openOnHover:d=!1,delay:b=300,closeDelay:m=0,id:A,...v}=e,h=g(!0),S=a?.store??h?.store;if(!S)throw Error((0,u.default)(74));let R=(0,w.useBaseUiId)(A),y=S.useState("isTriggerActive",R),V=S.useState("floatingRootContext"),E=S.useState("isOpenedByTrigger",R),k=i.useRef(null),{registerTrigger:J,isMountedByThisTrigger:M}=(0,G.useTriggerDataForwarding)(R,k,S,{payload:c,disabled:s,openOnHover:d,closeDelay:m}),K=S.useState("openChangeReason"),Q=S.useState("stickIfOpen"),z=S.useState("openMethod"),T=(0,F.useHoverReferenceInteraction)(V,{enabled:null!=V&&d&&("touch"!==z||K!==f.REASONS.triggerPress),mouseOnly:!0,move:!1,handleClose:(0,X.safePolygon)(),restMs:b,delay:{close:m},triggerElementRef:k,isActiveTrigger:y}),H=(0,N.useClick)(V,{enabled:null!=V,stickIfOpen:Q}),U=(0,o.useInteractions)([H]),D=S.useState("triggerProps",M),{getButtonProps:O,buttonRef:P}=(0,C.useButton)({disabled:s,native:l}),$=i.useMemo(()=>({open:e=>e&&K===f.REASONS.triggerPress?B.pressableTriggerOpenStateMapping.open(e):B.triggerOpenStateMapping.open(e)}),[K]),q=(0,Y.useRenderElement)("button",e,{state:{disabled:s,open:E},ref:[P,t,J,k],props:[U.getReferenceProps(),T,D,{[W.CLICK_TRIGGER_IDENTIFIER]:"",id:R},v,O],stateAttributesMapping:$}),ee=i.useRef(null),et=(0,Z.useStableCallback)(e=>{p.flushSync(()=>{S.setOpen(!1,(0,x.createChangeEventDetails)(f.REASONS.focusOut,e.nativeEvent,e.currentTarget))});let t=(0,_.getTabbableBeforeElement)(ee.current);t?.focus()}),ei=(0,Z.useStableCallback)(e=>{let t=S.select("positionerElement");if(t&&(0,_.isOutsideEvent)(e,t))S.context.beforeContentFocusGuardRef.current?.focus();else{p.flushSync(()=>{S.setOpen(!1,(0,x.createChangeEventDetails)(f.REASONS.focusOut,e.nativeEvent,e.currentTarget))});let i=(0,_.getTabbableAfterElement)(S.context.triggerFocusTargetRef.current||k.current);for(;null!==i&&(0,j.contains)(t,i);){let e=i;if((i=(0,_.getNextTabbable)(i))===e)break}i?.focus()}});return y?(0,I.jsxs)(i.Fragment,{children:[(0,I.jsx)(L.FocusGuard,{ref:ee,onFocus:et}),(0,I.jsx)(i.Fragment,{children:q},R),(0,I.jsx)(L.FocusGuard,{ref:S.context.triggerFocusTargetRef,onFocus:ei})]}):(0,I.jsx)(i.Fragment,{children:q},R)});var M=e.i(937692);let K=i.createContext(void 0),Q=i.forwardRef(function(e,t){let{keepMounted:i=!1,...n}=e,{store:r}=g();return r.useState("mounted")||i?(0,I.jsx)(K.Provider,{value:i,children:(0,I.jsx)(M.FloatingPortal,{ref:t,...n})}):null});var z=e.i(658130),T=e.i(500977);let H=i.createContext(void 0);function U(){let e=i.useContext(H);if(!e)throw Error((0,u.default)(46));return e}var D=e.i(56590),O=e.i(536893),P=e.i(177817),$=e.i(767569),q=e.i(418847);let ee=i.forwardRef(function(e,t){let{render:n,className:r,anchor:s,positionMethod:o="absolute",side:l="bottom",align:c="center",sideOffset:d=0,alignOffset:p=0,collisionBoundary:b="clipping-ancestors",collisionPadding:m=5,arrowPadding:A=5,sticky:v=!1,disableAnchorTracking:h=!1,collisionAvoidance:S=W.POPUP_COLLISION_AVOIDANCE,...R}=e,{store:y}=g(),V=function(){let e=i.useContext(K);if(void 0===e)throw Error((0,u.default)(45));return e}(),x=(0,a.useFloatingNodeId)(),G=y.useState("floatingRootContext"),E=y.useState("mounted"),k=y.useState("open"),Z=y.useState("openChangeReason"),C=y.useState("activeTriggerElement"),X=y.useState("modal"),N=y.useState("positionerElement"),F=y.useState("instantType"),w=y.useState("transitionStatus"),L=y.useState("hasViewport"),j=i.useRef(null),_=(0,P.useAnimationsFinished)(N,!1,!1),J=(0,D.useAnchorPositioning)({anchor:s,floatingRootContext:G,positionMethod:o,mounted:E,side:l,sideOffset:d,align:c,alignOffset:p,arrowPadding:A,collisionBoundary:b,collisionPadding:m,sticky:v,disableAnchorTracking:h,keepMounted:V,nodeId:x,collisionAvoidance:S,adaptiveOrigin:L?$.adaptiveOrigin:void 0}),M=i.useMemo(()=>{let e={};return k||(e.pointerEvents="none"),{role:"presentation",hidden:!E,style:{...J.positionerStyles,...e}}},[k,E,J.positionerStyles]),Q=i.useMemo(()=>({props:M,...J}),[M,J]),U=G.useState("domReferenceElement");(0,T.useIsoLayoutEffect)(()=>{let e=j.current;if(U&&(j.current=U),e&&U&&U!==e){y.set("instantType",void 0);let e=new AbortController;return _(()=>{y.set("instantType","trigger-change")},e.signal),()=>{e.abort()}}},[U,_,y]);let ee={open:k,side:Q.side,align:Q.align,anchorHidden:Q.anchorHidden,instant:F},et=i.useCallback(e=>{y.set("positionerElement",e)},[y]),ei=(0,Y.useRenderElement)("div",e,{state:ee,props:[Q.props,(0,q.getDisabledMountTransitionStyles)(w),R],ref:[t,et],stateAttributesMapping:B.popupStateMapping});return(0,I.jsxs)(H.Provider,{value:Q,children:[E&&!0===X&&Z!==f.REASONS.triggerHover&&(0,I.jsx)(O.InternalBackdrop,{ref:y.context.internalBackdropRef,inert:(0,z.inertValue)(!k),cutout:C}),(0,I.jsx)(a.FloatingNode,{id:x,children:ei})]})});var et=e.i(229315),ei=e.i(488306),en=e.i(761896),er=e.i(284759),es=e.i(889269),eo=e.i(992238),el=e.i(560752);let ea=i.createContext(void 0);function ec(e){let{value:t,children:i}=e;return(0,I.jsx)(ea.Provider,{value:t,children:i})}let eu={...B.popupStateMapping,...er.transitionStatusMapping},ed=i.forwardRef(function(e,t){let{className:n,render:r,initialFocus:s,finalFocus:o,...l}=e,{store:a}=g(),c=U(),u=null!=(0,el.useToolbarRootContext)(!0),{context:d,hasClosePart:p}=function(){let[e,t]=i.useState(0),n=(0,Z.useStableCallback)(()=>(t(e=>e+1),()=>{t(e=>Math.max(0,e-1))}));return{context:i.useMemo(()=>({register:n}),[n]),hasClosePart:e>0}}(),b=a.useState("open"),m=a.useState("openMethod"),A=a.useState("instantType"),v=a.useState("transitionStatus"),h=a.useState("popupProps"),S=a.useState("titleElementId"),R=a.useState("descriptionElementId"),W=a.useState("modal"),y=a.useState("mounted"),V=a.useState("openChangeReason"),x=a.useState("activeTriggerElement"),G=a.useState("floatingRootContext");(0,es.useOpenChangeComplete)({open:b,ref:a.context.popupRef,onComplete(){b&&a.context.onOpenChangeComplete?.(!0)}});let E=a.useState("disabled"),k=a.useState("openOnHover"),C=a.useState("closeDelay");(0,en.useHoverFloatingInteraction)(G,{enabled:k&&!E,closeDelay:C});let B=void 0===s?function(e){return"touch"!==e||a.context.popupRef.current}:s,X={open:b,side:c.side,align:c.align,instant:A,transitionStatus:v},N=i.useCallback(e=>{a.set("popupElement",e)},[a]),F=(0,Y.useRenderElement)("div",e,{state:X,ref:[t,a.context.popupRef,N],props:[h,{"aria-labelledby":S,"aria-describedby":R,onKeyDown(e){u&&eo.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()}},(0,q.getDisabledMountTransitionStyles)(v),l],stateAttributesMapping:eu});return(0,I.jsx)(ei.FloatingFocusManager,{context:G,openInteractionType:m,modal:!1!==W&&p,disabled:!y||V===f.REASONS.triggerHover,initialFocus:B,returnFocus:o,restoreFocus:"popup",previousFocusableElement:(0,et.isHTMLElement)(x)?x:void 0,nextFocusableElement:a.context.triggerFocusTargetRef,beforeContentFocusGuardRef:a.context.beforeContentFocusGuardRef,children:(0,I.jsx)(ec,{value:d,children:F})})}),eg=i.forwardRef(function(e,t){let{className:i,render:n,...r}=e,{store:s}=g(),o=s.useState("open"),{arrowRef:l,side:a,align:c,arrowUncentered:u,arrowStyles:d}=U();return(0,Y.useRenderElement)("div",e,{state:{open:o,side:a,align:c,uncentered:u},ref:[t,l],props:[{style:d,"aria-hidden":!0},r],stateAttributesMapping:B.popupStateMapping})}),ep={...B.popupStateMapping,...er.transitionStatusMapping},eb=i.forwardRef(function(e,t){let{className:i,render:n,...r}=e,{store:s}=g(),o=s.useState("open"),l=s.useState("mounted"),a=s.useState("transitionStatus"),c=s.useState("openChangeReason");return(0,Y.useRenderElement)("div",e,{state:{open:o,transitionStatus:a},ref:[s.context.backdropRef,t],props:[{role:"presentation",hidden:!l,style:{pointerEvents:c===f.REASONS.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},r],stateAttributesMapping:ep})}),em=i.forwardRef(function(e,t){let{render:i,className:n,...r}=e,{store:s}=g(),o=(0,w.useBaseUiId)(r.id);return(0,T.useIsoLayoutEffect)(()=>(s.set("titleElementId",o),()=>{s.set("titleElementId",void 0)}),[s,o]),(0,Y.useRenderElement)("h2",e,{ref:t,props:[{id:o},r]})}),eA=i.forwardRef(function(e,t){let{render:i,className:n,...r}=e,{store:s}=g(),o=(0,w.useBaseUiId)(r.id);return(0,T.useIsoLayoutEffect)(()=>(s.set("descriptionElementId",o),()=>{s.set("descriptionElementId",void 0)}),[s,o]),(0,Y.useRenderElement)("p",e,{ref:t,props:[{id:o},r]})}),ev=i.forwardRef(function(e,t){let n,{render:r,className:s,disabled:o=!1,nativeButton:l=!0,...a}=e,{buttonRef:c,getButtonProps:u}=(0,C.useButton)({disabled:o,focusableWhenDisabled:!1,native:l}),{store:d}=g();return n=i.useContext(ea),(0,T.useIsoLayoutEffect)(()=>n?.register(),[n]),(0,Y.useRenderElement)("button",e,{ref:[t,c],props:[{onClick(e){d.setOpen(!1,(0,x.createChangeEventDetails)(f.REASONS.closePress,e.nativeEvent,e.currentTarget))}},a,u]})}),eh=((t={}).popupWidth="--popup-width",t.popupHeight="--popup-height",t);var ef=e.i(712666);let eS={activationDirection:e=>e?{"data-activation-direction":e}:null},eR=i.forwardRef(function(e,t){let{render:i,className:n,children:r,...s}=e,{store:o}=g(),{side:l}=U(),a=o.useState("instantType"),{children:c,state:u}=(0,ef.usePopupViewport)({store:o,side:l,cssVars:eh,children:r}),d={activationDirection:u.activationDirection,transitioning:u.transitioning,instant:a};return(0,Y.useRenderElement)("div",e,{state:d,ref:t,props:[s,{children:c}],stateAttributesMapping:eS})});class eW{constructor(){this.store=new V}open(e){let t=e?this.store.context.triggerElements.getById(e)??void 0:void 0;if(e&&!t)throw Error((0,u.default)(80,e));this.store.setOpen(!0,(0,x.createChangeEventDetails)(f.REASONS.imperativeAction,void 0,t))}close(){this.store.setOpen(!1,(0,x.createChangeEventDetails)(f.REASONS.imperativeAction,void 0,void 0))}get isOpen(){return this.store.state.open}}e.s(["Arrow",0,eg,"Backdrop",0,eb,"Close",0,ev,"Description",0,eA,"Handle",0,eW,"Popup",0,ed,"Portal",0,Q,"Positioner",0,ee,"Root",0,function(e){return g(!0)?(0,I.jsx)(k,{props:e}):(0,I.jsx)(a.FloatingTree,{children:(0,I.jsx)(k,{props:e})})},"Title",0,em,"Trigger",0,J,"Viewport",0,eR,"createHandle",0,function(){return new eW}],307311);var ey=e.i(307311);e.s(["Popover",0,ey],506213)},597744,937111,283416,50086,940530,e=>{"use strict";var t,i,n,r,s,o,l,a,c=e.i(271645),u=e.i(170255),d=(e.i(113024),e.i(424407)),g=e.i(304532),p=e.i(499328),b=e.i(693569),m=e.i(761867);let A=(0,d.fileDesc)("CihhaS9zdGlnbWVyL3BsYXRmb3JtL3YxL2VudGl0bGVtZW50LnByb3RvEhZhaS5zdGlnbWVyLnBsYXRmb3JtLnYxIo8BCgxFbnRpdGxlbWVudHMSOQoGbGltaXRzGAEgASgLMikuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5FbnRpdGxlbWVudExpbWl0cxJECghmZWF0dXJlcxgCIAMoDjIfLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuRmVhdHVyZUIRukgOkgELGAEiB4IBBBABIAAi2gEKEUVudGl0bGVtZW50TGltaXRzEicKEW1heF9vcmdhbml6YXRpb25zGAEgASgFQge6SAQaAiAASACIAQESHwoJbWF4X3VzZXJzGAIgASgFQge6SAQaAiAASAGIAQESNAoeaW5jbHVkZWRfbWFuYWdlZF9vcmdhbml6YXRpb25zGAMgASgFQge6SAQaAiAASAKIAQFCFAoSX21heF9vcmdhbml6YXRpb25zQgwKCl9tYXhfdXNlcnNCIQofX2luY2x1ZGVkX21hbmFnZWRfb3JnYW5pemF0aW9ucyqkAQoHRmVhdHVyZRIXChNmZWF0dXJlX3Vuc3BlY2lmaWVkEAASEwoPc3NvX2VuZm9yY2VtZW50EAESEwoPcGxhdGZvcm1fY2xpZW50EAISFQoRYnlvX3Byb3ZpZGVyX2tleXMQAxIMCghjaGFubmVscxAEEgsKB3NoYXJpbmcQBRIJCgV0ZWFtcxAGEhkKFW1hbmFnZWRfb3JnYW5pemF0aW9ucxAHQhJCEEVudGl0bGVtZW50UHJvdG9iBnByb3RvMw",[m.file_buf_validate_validate]),v=(0,g.messageDesc)(A,0),h=(0,g.messageDesc)(A,1);(t=s||(s={}))[t.feature_unspecified=0]="feature_unspecified",t[t.sso_enforcement=1]="sso_enforcement",t[t.platform_client=2]="platform_client",t[t.byo_provider_keys=3]="byo_provider_keys",t[t.channels=4]="channels",t[t.sharing=5]="sharing",t[t.teams=6]="teams",t[t.managed_organizations=7]="managed_organizations",e.s(["EntitlementLimitsSchema",0,h,"EntitlementsSchema",0,v,"Feature",0,s,"file_ai_stigmer_platform_v1_entitlement",0,A],937111);var f=e.i(732303);let S=(0,d.fileDesc)("CiRhaS9zdGlnbWVyL3BsYXRmb3JtL3YxL2xpY2Vuc2UucHJvdG8SFmFpLnN0aWdtZXIucGxhdGZvcm0udjEiiQUKDUxpY2Vuc2VDbGFpbXMSGgoKbGljZW5zZV9pZBgBIAEoCUIGukgDyAEBEkEKCGN1c3RvbWVyGAIgASgLMicuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5MaWNlbnNlQ3VzdG9tZXJCBrpIA8gBARJACgR0ZXJtGAMgASgOMiMuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5MaWNlbnNlVGVybUINukgKyAEBggEEEAEgABJCCgxlbnRpdGxlbWVudHMYBCABKAsyJC5haS5zdGlnbWVyLnBsYXRmb3JtLnYxLkVudGl0bGVtZW50c0IGukgDyAEBEjUKCWlzc3VlZF9hdBgFIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3RhbXBCBrpIA8gBARI2CgpleHBpcmVzX2F0GAYgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcEIGukgDyAEBEjcKC2dyYWNlX3VudGlsGAcgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcEIGukgDyAEBOuoBukjmARpqCiJsaWNlbnNlX2NsYWltcy5leHBpcmVzX2FmdGVyX2lzc3VlEiJleHBpcmVzX2F0IG11c3QgYmUgYWZ0ZXIgaXNzdWVkX2F0GiB0aGlzLmV4cGlyZXNfYXQgPiB0aGlzLmlzc3VlZF9hdBp4CiZsaWNlbnNlX2NsYWltcy5ncmFjZV9ub3RfYmVmb3JlX2V4cGlyeRIpZ3JhY2VfdW50aWwgbXVzdCBub3QgYmUgYmVmb3JlIGV4cGlyZXNfYXQaI3RoaXMuZ3JhY2VfdW50aWwgPj0gdGhpcy5leHBpcmVzX2F0InwKD0xpY2Vuc2VDdXN0b21lchISCgJpZBgBIAEoCUIGukgDyAEBEhwKDGRpc3BsYXlfbmFtZRgCIAEoCUIGukgDyAEBEiEKDWNvbnRhY3RfZW1haWwYAyABKAlCCrpIB8gBAXICYAESFAoMb3JnYW5pemF0aW9uGAQgASgJKkAKC0xpY2Vuc2VUZXJtEhwKGGxpY2Vuc2VfdGVybV91bnNwZWNpZmllZBAAEgkKBXRyaWFsEAESCAoEcGFpZBACKncKDExpY2Vuc2VTdGF0ZRIdChlsaWNlbnNlX3N0YXRlX3Vuc3BlY2lmaWVkEAASCgoGYWJzZW50EAESCQoFdmFsaWQQAhIMCghleHBpcmluZxADEgkKBWdyYWNlEAQSCwoHZXhwaXJlZBAFEgsKB2ludmFsaWQQBkIOQgxMaWNlbnNlUHJvdG9iBnByb3RvMw",[A,m.file_buf_validate_validate,f.file_google_protobuf_timestamp]),R=(0,g.messageDesc)(S,1);(i=o||(o={}))[i.license_term_unspecified=0]="license_term_unspecified",i[i.trial=1]="trial",i[i.paid=2]="paid",(n=l||(l={}))[n.license_state_unspecified=0]="license_state_unspecified",n[n.absent=1]="absent",n[n.valid=2]="valid",n[n.expiring=3]="expiring",n[n.grace=4]="grace",n[n.expired=5]="expired",n[n.invalid=6]="invalid",e.s(["LicenseCustomerSchema",0,R,"LicenseState",0,l,"LicenseTerm",0,o,"file_ai_stigmer_platform_v1_license",0,S],283416);let W=(0,d.fileDesc)("CihhaS9zdGlnbWVyL3BsYXRmb3JtL3YxL3NlcnZlcl9pbmZvLnByb3RvEhZhaS5zdGlnbWVyLnBsYXRmb3JtLnYxIhQKEkdldFNlcnZlckluZm9JbnB1dCKgAQoTR2V0U2VydmVySW5mb091dHB1dBI2CgdlZGl0aW9uGAEgASgOMiUuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5TZXJ2ZXJFZGl0aW9uEg8KB3ZlcnNpb24YAiABKAkSJAoXYXV0aGVudGljYXRpb25fcmVxdWlyZWQYAyABKAhIAIgBAUIaChhfYXV0aGVudGljYXRpb25fcmVxdWlyZWQiFwoVR2V0TGljZW5zZVN0YXR1c0lucHV0IsQBChZHZXRMaWNlbnNlU3RhdHVzT3V0cHV0EjMKBXN0YXRlGAEgASgOMiQuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5MaWNlbnNlU3RhdGUSNQoGY2xhaW1zGAIgASgLMiUuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5MaWNlbnNlQ2xhaW1zEg4KBmtleV9pZBgDIAEoCRIuCgpjaGVja2VkX2F0GAQgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcCIfCh1HZXRSdW5uZXJCb290c3RyYXBDb25maWdJbnB1dCLjAgoeR2V0UnVubmVyQm9vdHN0cmFwQ29uZmlnT3V0cHV0EiEKEHRlbXBvcmFsX2FkZHJlc3MYASABKAlCB7pIBHICEAESIwoSdGVtcG9yYWxfbmFtZXNwYWNlGAIgASgJQge6SARyAhABEhsKE3J1bm5lcl9hY2Nlc3NfdG9rZW4YAyABKAkSEgoKdG9rZW5fdHlwZRgEIAEoCRIuCiZydW5uZXJfYWNjZXNzX3Rva2VuX2V4cGlyZXNfaW5fc2Vjb25kcxgFIAEoBRIeChZwYXlsb2FkX2VuY3J5cHRpb25fa2V5GAYgASgJEiEKGXBheWxvYWRfZW5jcnlwdGlvbl9rZXlfaWQYByABKAkSKAogcGF5bG9hZF9lbmNyeXB0aW9uX3NlY29uZGFyeV9rZXkYCCABKAkSKwojcGF5bG9hZF9lbmNyeXB0aW9uX3NlY29uZGFyeV9rZXlfaWQYCSABKAki3AEKGUdldFJ1bm5lclNjb3BlZFRva2VuSW5wdXQSHAoSYWdlbnRfZXhlY3V0aW9uX2lkGAEgASgJSAASHwoVd29ya2Zsb3dfZXhlY3V0aW9uX2lkGAIgASgJSAASNwoKcG9vbF9jbGFpbRgDIAEoCzIhLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuUG9vbENsYWltSAASNwoHcmVuZXdhbBgEIAEoCzIkLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuVG9rZW5SZW5ld2FsSABCDgoFc2NvcGUSBbpIAggBIigKCVBvb2xDbGFpbRIbCgpzZXNzaW9uX2lkGAEgASgJQge6SARyAhABIg4KDFRva2VuUmVuZXdhbCJpChpHZXRSdW5uZXJTY29wZWRUb2tlbk91dHB1dBIbChNydW5uZXJfc2NvcGVkX3Rva2VuGAEgASgJEhIKCnRva2VuX3R5cGUYAiABKAkSGgoSZXhwaXJlc19pbl9zZWNvbmRzGAMgASgFKlMKDVNlcnZlckVkaXRpb24SHgoac2VydmVyX2VkaXRpb25fdW5zcGVjaWZpZWQQABIHCgNvc3MQARIJCgVjbG91ZBACEg4KCmVudGVycHJpc2UQAzKaBAoXUGxhdGZvcm1RdWVyeUNvbnRyb2xsZXISbgoNZ2V0U2VydmVySW5mbxIqLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuR2V0U2VydmVySW5mb0lucHV0GisuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5HZXRTZXJ2ZXJJbmZvT3V0cHV0IgTIuBgBEncKEGdldExpY2Vuc2VTdGF0dXMSLS5haS5zdGlnbWVyLnBsYXRmb3JtLnYxLkdldExpY2Vuc2VTdGF0dXNJbnB1dBouLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuR2V0TGljZW5zZVN0YXR1c091dHB1dCIE0LgYARKPAQoYZ2V0UnVubmVyQm9vdHN0cmFwQ29uZmlnEjUuYWkuc3RpZ21lci5wbGF0Zm9ybS52MS5HZXRSdW5uZXJCb290c3RyYXBDb25maWdJbnB1dBo2LmFpLnN0aWdtZXIucGxhdGZvcm0udjEuR2V0UnVubmVyQm9vdHN0cmFwQ29uZmlnT3V0cHV0IgTQuBgBEoMBChRnZXRSdW5uZXJTY29wZWRUb2tlbhIxLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuR2V0UnVubmVyU2NvcGVkVG9rZW5JbnB1dBoyLmFpLnN0aWdtZXIucGxhdGZvcm0udjEuR2V0UnVubmVyU2NvcGVkVG9rZW5PdXRwdXQiBNC4GAFCEUIPU2VydmVySW5mb1Byb3RvYgZwcm90bzM",[b.file_ai_stigmer_commons_rpc_method_options,S,m.file_buf_validate_validate,f.file_google_protobuf_timestamp]),y=(0,g.messageDesc)(W,0),V=(0,g.messageDesc)(W,2);(r=a||(a={}))[r.server_edition_unspecified=0]="server_edition_unspecified",r[r.oss=1]="oss",r[r.cloud=2]="cloud",r[r.enterprise=3]="enterprise";let x=(0,p.serviceDesc)(W,0);e.s(["GetLicenseStatusInputSchema",0,V,"GetServerInfoInputSchema",0,y,"PlatformQueryController",0,x,"ServerEdition",0,a],50086);let G=new Map([[u.ApiResourceKind.api_resource_version,u.ResourceTier.cloud_only],[u.ApiResourceKind.iam_policy,u.ResourceTier.open_source],[u.ApiResourceKind.identity_account,u.ResourceTier.open_source],[u.ApiResourceKind.api_key,u.ResourceTier.open_source],[u.ApiResourceKind.invitation,u.ResourceTier.enterprise],[u.ApiResourceKind.identity_provider,u.ResourceTier.enterprise],[u.ApiResourceKind.oauth_app,u.ResourceTier.open_source],[u.ApiResourceKind.platform_client,u.ResourceTier.open_source],[u.ApiResourceKind.team,u.ResourceTier.enterprise],[u.ApiResourceKind.organization,u.ResourceTier.open_source],[u.ApiResourceKind.platform,u.ResourceTier.enterprise],[u.ApiResourceKind.agent,u.ResourceTier.open_source],[u.ApiResourceKind.agent_execution,u.ResourceTier.open_source],[u.ApiResourceKind.session,u.ResourceTier.open_source],[u.ApiResourceKind.skill,u.ResourceTier.open_source],[u.ApiResourceKind.mcp_server,u.ResourceTier.open_source],[u.ApiResourceKind.agent_instance,u.ResourceTier.open_source],[u.ApiResourceKind.agent_share,u.ResourceTier.open_source],[u.ApiResourceKind.agent_channel,u.ResourceTier.open_source],[u.ApiResourceKind.channel_app,u.ResourceTier.open_source],[u.ApiResourceKind.workflow,u.ResourceTier.open_source],[u.ApiResourceKind.workflow_instance,u.ResourceTier.open_source],[u.ApiResourceKind.workflow_execution,u.ResourceTier.open_source],[u.ApiResourceKind.environment,u.ResourceTier.open_source],[u.ApiResourceKind.execution_context,u.ResourceTier.open_source],[u.ApiResourceKind.artifact,u.ResourceTier.open_source],[u.ApiResourceKind.schedule,u.ResourceTier.open_source],[u.ApiResourceKind.memory,u.ResourceTier.open_source],[u.ApiResourceKind.plugin,u.ResourceTier.open_source],[u.ApiResourceKind.plan,u.ResourceTier.cloud_only],[u.ApiResourceKind.subscription,u.ResourceTier.cloud_only],[u.ApiResourceKind.license,u.ResourceTier.cloud_only]]);function E(e,t){let i=G.get(e);if(void 0===i)throw Error(`isResourceAvailable: kind ${e} has no tier — only kinds with kind_meta can be asked about`);return function(e){switch(e){case"local":return 1;case"enterprise":return 2;case"cloud":return 3;default:throw Error(`unknown deployment mode: ${String(e)}`)}}(t)>=function(e){switch(e){case u.ResourceTier.open_source:return 1;case u.ResourceTier.enterprise:return 2;case u.ResourceTier.cloud_only:return 3;case u.ResourceTier.resource_tier_unspecified:return 1;default:throw Error(`unknown resource tier: ${String(e)}`)}}(i)}e.s(["deploymentModeOf",0,function(e){switch(e){case a.oss:return"local";case a.enterprise:return"enterprise";case a.cloud:case a.server_edition_unspecified:default:return"cloud"}},"isResourceAvailable",0,E],940530);let I=(0,c.createContext)("cloud");function k(){return(0,c.useContext)(I)}e.s(["DeploymentModeContext",0,I,"useDeploymentMode",0,k,"useResourceAvailable",0,function(e){return E(e,k())}],597744)},267872,e=>{"use strict";var t,i;e.i(113024);let n=(0,e.i(424407).fileDesc)("CixhaS9zdGlnbWVyL2lhbS9pZGVudGl0eWFjY291bnQvdjEvZW51bS5wcm90bxIhYWkuc3RpZ21lci5pYW0uaWRlbnRpdHlhY2NvdW50LnYxKpIBCh9JZGVudGl0eUFjY291bnRQcm92aXNpb25pbmdNb2RlEjIKLmlkZW50aXR5X2FjY291bnRfcHJvdmlzaW9uaW5nX21vZGVfdW5zcGVjaWZpZWQQABIKCgZkaXJlY3QQARINCglmZWRlcmF0ZWQQAhILCgdtYWNoaW5lEAMSEwoPcGxhdGZvcm1fY2xpZW50EARiBnByb3RvMw");(i=t||(t={}))[i.identity_account_provisioning_mode_unspecified=0]="identity_account_provisioning_mode_unspecified",i[i.direct=1]="direct",i[i.federated=2]="federated",i[i.machine=3]="machine",i[i.platform_client=4]="platform_client",e.s(["IdentityAccountProvisioningMode",0,t,"file_ai_stigmer_iam_identityaccount_v1_enum",0,n])},452026,632897,626874,e=>{"use strict";var t=e.i(424407),i=e.i(304532),n=e.i(421415),r=e.i(988158),s=e.i(761867);let o=(0,t.fileDesc)("CiZhaS9zdGlnbWVyL2lhbS9pYW1wb2xpY3kvdjEvc3BlYy5wcm90bxIbYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxIr4BCg1JYW1Qb2xpY3lTcGVjEkYKCXByaW5jaXBhbBgBIAEoCzIrLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5BcGlSZXNvdXJjZVJlZkIGukgDyAEBEkUKCHJlc291cmNlGAIgASgLMisuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmQga6SAPIAQESHgoIcmVsYXRpb24YAyABKAlCDLpICcgBAXIEEAEYQCJkCg5BcGlSZXNvdXJjZVJlZhIbCgRraW5kGAEgASgJQg26SArIAQFyBRABGIACEhkKAmlkGAIgASgJQg26SArIAQFyBRABGIACEhoKCHJlbGF0aW9uGAMgASgJQgi6SAVyAxiAAmIGcHJvdG8z",[s.file_buf_validate_validate]),l=(0,i.messageDesc)(o,0),a=(0,i.messageDesc)(o,1);e.s(["ApiResourceRefSchema",0,a,"IamPolicySpecSchema",0,l,"file_ai_stigmer_iam_iampolicy_v1_spec",0,o],632897);let c=(0,t.fileDesc)("CiVhaS9zdGlnbWVyL2lhbS9pYW1wb2xpY3kvdjEvYXBpLnByb3RvEhthaS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEimQIKCUlhbVBvbGljeRItCgthcGlfdmVyc2lvbhgBIAEoCUIYukgVchMKEWlhbS5zdGlnbWVyLmFpL3YxEh4KBGtpbmQYAiABKAlCELpIDXILCglJYW1Qb2xpY3kSRQoIbWV0YWRhdGEYAyABKAsyMy5haS5zdGlnbWVyLmNvbW1vbnMuYXBpcmVzb3VyY2UuQXBpUmVzb3VyY2VNZXRhZGF0YRI4CgRzcGVjGAQgASgLMiouYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLklhbVBvbGljeVNwZWMSPAoGc3RhdHVzGAUgASgLMiwuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLklhbVBvbGljeVN0YXR1cyJSCg9JYW1Qb2xpY3lTdGF0dXMSPwoFYXVkaXQYASABKAsyMC5haS5zdGlnbWVyLmNvbW1vbnMuYXBpcmVzb3VyY2UuQXBpUmVzb3VyY2VBdWRpdGIGcHJvdG8z",[n.file_ai_stigmer_commons_apiresource_metadata,r.file_ai_stigmer_commons_apiresource_status,o,s.file_buf_validate_validate]);e.s(["file_ai_stigmer_iam_iampolicy_v1_api",0,c],626874);var u=e.i(267872);let d=(0,t.fileDesc)("CiRhaS9zdGlnbWVyL2lhbS9pYW1wb2xpY3kvdjEvaW8ucHJvdG8SG2FpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MSLDAgoSQXBpUmVzb3VyY2VSZWZWaWV3EgwKBGtpbmQYASABKAkSCgoCaWQYAiABKAkSEAoIcmVsYXRpb24YAyABKAkSDAoEbmFtZRgEIAEoCRINCgVlbWFpbBgFIAEoCRIMCgRzbHVnGAYgASgJEg4KBmF2YXRhchgHIAEoCRJACgdtZW1iZXJzGAggAygLMi8uYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmVmlldxI+CgV0ZWFtcxgJIAMoCzIvLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5BcGlSZXNvdXJjZVJlZlZpZXcSRAoPaWRlbnRpdHlfb3JpZ2luGAogASgLMisuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLklkZW50aXR5T3JpZ2luIo4BCg5JZGVudGl0eU9yaWdpbhJdChFwcm92aXNpb25pbmdfbW9kZRgBIAEoDjJCLmFpLnN0aWdtZXIuaWFtLmlkZW50aXR5YWNjb3VudC52MS5JZGVudGl0eUFjY291bnRQcm92aXNpb25pbmdNb2RlEh0KFXByb3ZpZGVyX2Rpc3BsYXlfbmFtZRgCIAEoCSIkCgtJYW1Qb2xpY3lJZBIVCgV2YWx1ZRgBIAEoCUIGukgDyAEBIqcBChZQcmluY2lwYWxSZXNvdXJjZUlucHV0EkYKCXByaW5jaXBhbBgBIAEoCzIrLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5BcGlSZXNvdXJjZVJlZkIGukgDyAEBEkUKCHJlc291cmNlGAIgASgLMisuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmQga6SAPIAQEiqQEKF1Jlc291cmNlUHJpbmNpcGFsc0lucHV0EkUKCHJlc291cmNlGAEgASgLMisuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmQga6SAPIAQESRwoKcHJpbmNpcGFscxgCIAMoCzIrLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5BcGlSZXNvdXJjZVJlZkIGukgDyAEBImQKFFJldm9rZU9yZ0FjY2Vzc0lucHV0EicKE2lkZW50aXR5X2FjY291bnRfaWQYASABKAlCCrpIB8gBAXICEAESIwoPb3JnYW5pemF0aW9uX2lkGAIgASgJQgq6SAfIAQFyAhABIkoKD0lhbVBvbGljaWVzTGlzdBI3CgdlbnRyaWVzGAEgAygLMiYuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLklhbVBvbGljeSJ7ChdMaXN0UmVzb3VyY2VBY2Nlc3NJbnB1dBJFCghyZXNvdXJjZRgBIAEoCzIrLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5BcGlSZXNvdXJjZVJlZkIGukgDyAEBEhkKEWluY2x1ZGVfaW5oZXJpdGVkGAIgASgIIl4KHVJlc291cmNlQWNjZXNzQnlQcmluY2lwYWxMaXN0Ej0KB2VudHJpZXMYASADKAsyLC5haS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEuUHJpbmNpcGFsQWNjZXNzIowBCg9QcmluY2lwYWxBY2Nlc3MSQgoJcHJpbmNpcGFsGAEgASgLMi8uYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmVmlldxI1CgVyb2xlcxgCIAMoCzImLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5Sb2xlR3JhbnQimwEKCVJvbGVHcmFudBIzCgRyb2xlGAEgASgLMiUuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLlJvbGVJbmZvEkMKDm93bmVyX3Jlc291cmNlGAIgASgLMisuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmEhQKDGlzX2luaGVyaXRlZBgDIAEoCCJUChhSZXNvdXJjZUFjY2Vzc0J5Um9sZUxpc3QSOAoHZW50cmllcxgBIAMoCzInLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5Sb2xlQWNjZXNzIocBCgpSb2xlQWNjZXNzEjQKBHJvbGUYASABKAsyJi5haS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEuUm9sZUdyYW50EkMKCnByaW5jaXBhbHMYAiADKAsyLy5haS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEuQXBpUmVzb3VyY2VSZWZWaWV3IkcKCFJvbGVJbmZvEgoKAmlkGAEgASgJEgwKBGNvZGUYAiABKAkSDAoEbmFtZRgDIAEoCRITCgtkZXNjcmlwdGlvbhgEIAEoCSJOChZQcmluY2lwYWxSZXNvdXJjZVJvbGVzEjQKBXJvbGVzGAEgAygLMiUuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLlJvbGVJbmZvIqYBChdDaGVja0F1dGhvcml6YXRpb25JbnB1dBJCCgZwb2xpY3kYASABKAsyKi5haS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEuSWFtUG9saWN5U3BlY0IGukgDyAEBEkcKE2NvbnRleHR1YWxfcG9saWNpZXMYAiADKAsyKi5haS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEuSWFtUG9saWN5U3BlYyIxChhDaGVja0F1dGhvcml6YXRpb25SZXN1bHQSFQoNaXNfYXV0aG9yaXplZBgBIAEoCCLIAQoWQ2hlY2tNeVBlcm1pc3Npb25JbnB1dBJFCghyZXNvdXJjZRgBIAEoCzIrLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5BcGlSZXNvdXJjZVJlZkIGukgDyAEBEh4KCHJlbGF0aW9uGAIgASgJQgy6SAnIAQFyBBABGEASRwoTY29udGV4dHVhbF9wb2xpY2llcxgDIAMoCzIqLmFpLnN0aWdtZXIuaWFtLmlhbXBvbGljeS52MS5JYW1Qb2xpY3lTcGVjIvIBCh5MaXN0QXV0aG9yaXplZFJlc291cmNlSWRzSW5wdXQSRgoJcHJpbmNpcGFsGAEgASgLMisuYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLkFwaVJlc291cmNlUmVmQga6SAPIAQESIQoNcmVzb3VyY2Vfa2luZBgCIAEoCUIKukgHyAEBcgIQARIcCghyZWxhdGlvbhgDIAEoCUIKukgHyAEBcgIQARJHChNjb250ZXh0dWFsX3BvbGljaWVzGAQgAygLMiouYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLklhbVBvbGljeVNwZWMiMQoZQXV0aG9yaXplZFJlc291cmNlSWRzTGlzdBIUCgxyZXNvdXJjZV9pZHMYASADKAki8wEKH0xpc3RBdXRob3JpemVkUHJpbmNpcGFsSWRzSW5wdXQSRQoIcmVzb3VyY2UYASABKAsyKy5haS5zdGlnbWVyLmlhbS5pYW1wb2xpY3kudjEuQXBpUmVzb3VyY2VSZWZCBrpIA8gBARIiCg5wcmluY2lwYWxfa2luZBgCIAEoCUIKukgHyAEBcgIQARIcCghyZWxhdGlvbhgDIAEoCUIKukgHyAEBcgIQARJHChNjb250ZXh0dWFsX3BvbGljaWVzGAQgAygLMiouYWkuc3RpZ21lci5pYW0uaWFtcG9saWN5LnYxLklhbVBvbGljeVNwZWMiMwoaQXV0aG9yaXplZFByaW5jaXBhbElkc0xpc3QSFQoNcHJpbmNpcGFsX2lkcxgBIAMoCSJZChdHZXRQcmluY2lwYWxzQ291bnRJbnB1dBIaCgZvcmdfaWQYASABKAlCCrpIB8gBAXICEAESIgoOcHJpbmNpcGFsX2tpbmQYAiABKAlCCrpIB8gBAXICEAEiIAoPUHJpbmNpcGFsc0NvdW50Eg0KBWNvdW50GAEgASgFYgZwcm90bzM",[c,o,u.file_ai_stigmer_iam_identityaccount_v1_enum,s.file_buf_validate_validate]),g=(0,i.messageDesc)(d,2),p=(0,i.messageDesc)(d,5),b=(0,i.messageDesc)(d,7),m=(0,i.messageDesc)(d,17);e.s(["CheckMyPermissionInputSchema",0,m,"IamPolicyIdSchema",0,g,"ListResourceAccessInputSchema",0,b,"RevokeOrgAccessInputSchema",0,p,"file_ai_stigmer_iam_iampolicy_v1_io",0,d],452026)},981922,e=>{"use strict";var t=e.i(271645),i=e.i(891287),n=e.i(452026),r=e.i(632897),s=e.i(586108);e.s(["useCheckPermission",0,function(e,o,l){let a=(0,s.useStigmer)(),c="open"===(l?.fail??"open"),u=e?`${e.kind}:${e.id}:${o}`:null,d=(0,t.useRef)(new Map),[g,p]=(0,t.useState)(null);(0,t.useEffect)(()=>{if(!e||!u)return;let t=d.current.get(u);if(void 0!==t)return void p({key:u,verdict:t,error:null});let s=!1,l=(0,i.create)(n.CheckMyPermissionInputSchema,{resource:(0,i.create)(r.ApiResourceRefSchema,{kind:e.kind,id:e.id}),relation:o});return a.iamPolicy.checkMyPermission(l).then(e=>{s||(d.current.set(u,e.isAuthorized),p({key:u,verdict:e.isAuthorized,error:null}))}).catch(e=>{s||p({key:u,verdict:null,error:e instanceof Error?e:Error(String(e))})}),()=>{s=!0}},[u,e?.kind,e?.id,o,c,a]);let b=null!==u&&g?.key===u?g:null,m=b?.verdict??c,A=null!==u&&null===b,v=b?.error??null;return(0,t.useMemo)(()=>({allowed:m,isLoading:A,error:v}),[m,A,v])}])},590150,e=>{"use strict";var t=e.i(981922);e.s(["PermissionGate",0,function({resource:e,relation:i,children:n,fallback:r=null,loading:s=null}){let{allowed:o,isLoading:l}=(0,t.useCheckPermission)(e,i);return l?s:o?n:r}])},575407,e=>{"use strict";var t=e.i(271645),i=e.i(891287),n=e.i(725842),r=e.i(910304),s=e.i(586108),o=e.i(326283);e.s(["useSsoProvider",0,function(e){let l=(0,s.useStigmer)(),[a,c]=(0,t.useState)(null),[u,d]=(0,t.useState)(!1),[g,p]=(0,t.useState)(null);return(0,t.useEffect)(()=>{if(!e){c(null),d(!1),p(null);return}let t={current:!1};return d(!0),p(null),l.identityProvider.getSsoProvider((0,i.create)(n.OrganizationSsoLookupSchema,{org:e})).then(e=>{t.current||(c(e),d(!1))},e=>{t.current||((0,r.isNotFound)(e)?c(null):p((0,o.toError)(e)),d(!1))}),()=>{t.current=!0}},[e,l]),{ssoProvider:a,isLoading:u,error:g}}])},388023,853793,758960,e=>{"use strict";var t=e.i(843476),i=e.i(271645),n=e.i(170255),r=e.i(597744),s=e.i(590150),o=e.i(575407),l=e.i(506213),a=e.i(893976),c=e.i(364354),u=e.i(188482),d=e.i(10337),g=e.i(966205);let p="stg:inline-flex stg:shrink-0 stg:items-center stg:gap-1 stg:rounded-full stg:bg-muted stg:px-2 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-muted-foreground",b=(0,i.forwardRef)(function({option:e,isSelected:i,role:n,isHighlighted:r,disabled:s,tabIndex:o,onSelect:l,onMouseEnter:c,onKeyDown:u},d){let g=void 0!==e.lockedReason,p="radio"===n?{"aria-checked":i}:{"aria-selected":i};return(0,t.jsxs)("button",{ref:d,type:"button",role:n,...p,"aria-disabled":g||void 0,tabIndex:o,disabled:s||g,onClick:l,onMouseEnter:c,onKeyDown:u,className:(0,a.cn)("stg:flex stg:w-full stg:items-start stg:gap-2 stg:rounded-md stg:px-2.5 stg:py-2 stg:text-left stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",g?"stg:disabled:pointer-events-none stg:cursor-default":"stg:disabled:pointer-events-none stg:disabled:opacity-50",!g&&(r?"stg:bg-accent stg:text-foreground":"stg:hover:bg-accent-hover")),children:[(0,t.jsx)(A,{tone:e.tone,className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-muted-foreground"}),(0,t.jsxs)("span",{className:"stg:min-w-0 stg:flex-1",children:[(0,t.jsx)("span",{className:(0,a.cn)("stg:block stg:text-xs stg:font-medium",g?"stg:text-muted-foreground":"stg:text-foreground"),children:e.label}),(0,t.jsx)("span",{className:"stg:block stg:text-[0.65rem] stg:leading-snug stg:text-muted-foreground",children:g?e.lockedReason:e.description})]}),g?(0,t.jsx)(v,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-muted-foreground"}):i&&(0,t.jsx)(R,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-primary"})]})}),m={private:{container:"stg:border-amber-200 stg:bg-amber-50 stg:dark:border-amber-800/50 stg:dark:bg-amber-950/30",text:"stg:text-amber-800 stg:dark:text-amber-200",confirm:"stg:bg-amber-600 stg:hover:bg-amber-700 stg:dark:bg-amber-600 stg:dark:hover:bg-amber-500",cancel:"stg:text-amber-700 stg:hover:text-amber-900 stg:dark:text-amber-300 stg:dark:hover:text-amber-100"},org:{container:"stg:border-blue-200 stg:bg-blue-50 stg:dark:border-blue-800/50 stg:dark:bg-blue-950/30",text:"stg:text-blue-800 stg:dark:text-blue-200",confirm:"stg:bg-blue-600 stg:hover:bg-blue-700 stg:dark:bg-blue-600 stg:dark:hover:bg-blue-500",cancel:"stg:text-blue-700 stg:hover:text-blue-900 stg:dark:text-blue-300 stg:dark:hover:text-blue-100"},platform:{container:"stg:border-violet-200 stg:bg-violet-50 stg:dark:border-violet-800/50 stg:dark:bg-violet-950/30",text:"stg:text-violet-800 stg:dark:text-violet-200",confirm:"stg:bg-violet-600 stg:hover:bg-violet-700 stg:dark:bg-violet-600 stg:dark:hover:bg-violet-500",cancel:"stg:text-violet-700 stg:hover:text-violet-900 stg:dark:text-violet-300 stg:dark:hover:text-violet-100"},public:{container:"stg:border-emerald-200 stg:bg-emerald-50 stg:dark:border-emerald-800/50 stg:dark:bg-emerald-950/30",text:"stg:text-emerald-800 stg:dark:text-emerald-200",confirm:"stg:bg-emerald-600 stg:hover:bg-emerald-700 stg:dark:bg-emerald-600 stg:dark:hover:bg-emerald-500",cancel:"stg:text-emerald-700 stg:hover:text-emerald-900 stg:dark:text-emerald-300 stg:dark:hover:text-emerald-100"}};function A({tone:e,className:i}){switch(e){case"org":return(0,t.jsx)(h,{className:i});case"platform":return(0,t.jsx)(f,{className:i});case"public":return(0,t.jsx)(S,{className:i});default:return(0,t.jsx)(v,{className:i})}}function v({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:"3.5",y:"7",width:"9",height:"7",rx:"1.5"}),(0,t.jsx)("path",{d:"M5.5 7V5a2.5 2.5 0 0 1 5 0v2"})]})}function h({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:"6",cy:"5",r:"2.5"}),(0,t.jsx)("path",{d:"M2 13c0-2.21 1.79-4 4-4s4 1.79 4 4"}),(0,t.jsx)("circle",{cx:"11.5",cy:"5.5",r:"2"}),(0,t.jsx)("path",{d:"M14 13c0-1.66-1.12-3-2.5-3-.5 0-1 .14-1.4.4"})]})}function f({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:"M2 14V4.5L6.5 2v12"}),(0,t.jsx)("path",{d:"M6.5 6.5 14 8.5V14"}),(0,t.jsx)("path",{d:"M2 14h12"}),(0,t.jsx)("path",{d:"M4.25 6h.01M4.25 8.5h.01M4.25 11h.01M10.5 10.5h.01M10.5 12.5h.01"})]})}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)("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"})]})}function R({className:e}){return(0,t.jsx)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M3 8.5 6.5 12 13 4.5"})})}var W=e.i(302933);let y={value:W.ApiResourceVisibility.visibility_private,label:"Private",description:"Only you can access",tone:"private"},V={value:W.ApiResourceVisibility.visibility_org,label:"Organization",description:"All members of your organization",confirmPrompt:"Make visible to all org members?",tone:"org"},x={value:W.ApiResourceVisibility.visibility_platform,label:"Platform",description:"All organizations managed by your platform",confirmDialog:{title:"Share with your whole platform?",description:"Every organization managed by your platform will be able to view and use this resource. You can return it to a narrower visibility at any time."},tone:"platform"},G={value:W.ApiResourceVisibility.visibility_public,label:"Public",description:"Retired level — this resource becomes visible to your organization on upgrade",tone:"public"};function E(e){return e.hasIdentityProvider?[y,V,x]:[y,V]}function I(){return[y,{...V,description:"All org members can view executions"}]}function k(e){return"local"===e?[y]:[{...y,description:"Only you can view and use these credentials"},{...V,description:"Agents run in your org — including shared-agent visitors — can use these credentials. Members see names only; secret values stay hidden.",confirmPrompt:"Let agents run in your org use these credentials?"}]}function Z(e){switch(e){case W.ApiResourceVisibility.visibility_org:return V;case W.ApiResourceVisibility.visibility_platform:return x;case W.ApiResourceVisibility.visibility_public:return G;default:return y}}function C({visibility:e,options:n,onVisibilityChange:r,mode:s="manage",isPending:o=!1,disabled:u=!1,ariaLabel:v="Resource visibility",className:h}){let f=(0,c.useStigmerPortalContainer)(),{confirmState:S,confirm:R,handleConfirm:W,handleCancel:y}=(0,g.useConfirmAction)(),[V,x]=(0,i.useState)(!1),[G,E]=(0,i.useState)(null),[I,k]=(0,i.useState)(-1),Y=(0,i.useRef)([]),X=u||o,N=(0,i.useMemo)(()=>n.some(t=>t.value===e)?n:[...n,Z(e)],[n,e]),F=(0,i.useCallback)(t=>{let i=N.map(e=>e.value);return i.indexOf(t)>i.indexOf(e)},[N,e]),w=(0,i.useCallback)(e=>{x(!1),E(null),r(e)},[r]),L=(0,i.useCallback)(t=>{if(void 0!==t.lockedReason)return;let i=t.value;if(i===e){E(null),x(!1);return}if("create"===s||!F(i))return void w(i);if(t.confirmDialog){x(!1),E(null),R({title:t.confirmDialog.title,description:t.confirmDialog.description,confirmLabel:`Make ${t.label}`,variant:"default"}).then(e=>{e&&r(i)});return}t.confirmPrompt?E(i):w(i)},[e,s,F,w,R,r]),j=(0,i.useCallback)((e,t)=>{let i=N.length,n=e;for(let e=0;e<i&&(n=(n+t+i)%i,N[n]?.lockedReason!==void 0);e++);k(n),Y.current[n]?.focus()},[N]),_=(0,i.useCallback)((e,t)=>{switch(e.key){case"ArrowDown":case"ArrowRight":e.preventDefault(),j(t,1);break;case"ArrowUp":case"ArrowLeft":e.preventDefault(),j(t,-1);break;case"Home":e.preventDefault(),k(0),Y.current[0]?.focus();break;case"End":{e.preventDefault();let t=N.length-1;k(t),Y.current[t]?.focus()}}},[j,N.length]);(0,i.useEffect)(()=>{if(!V){E(null),k(-1);return}let t=N.findIndex(t=>t.value===e),i=t>=0?t:0;k(i);let n=requestAnimationFrame(()=>Y.current[i]?.focus());return()=>cancelAnimationFrame(n)},[V,N,e]);let J=(0,t.jsx)(d.ConfirmDialog,{state:S,onConfirm:W,onCancel:y}),M=i=>N.map((n,r)=>(0,t.jsx)(b,{ref:e=>{Y.current[r]=e},option:n,role:i,isSelected:e===n.value,isHighlighted:"option"===i&&I===r,tabIndex:"radio"===i?e===n.value?0:-1:I===r?0:-1,disabled:X,onSelect:()=>L(n),onMouseEnter:"option"===i?()=>k(r):void 0,onKeyDown:e=>_(e,r)},n.value));if("create"===s)return(0,t.jsx)("div",{role:"radiogroup","aria-label":v,"aria-disabled":X||void 0,className:(0,a.cn)("stg:flex stg:flex-col stg:gap-0.5 stg:rounded-md stg:border stg:border-border stg:p-1",X&&"stg:pointer-events-none stg:opacity-50",h),children:M("radio")});let K=Z(e),Q=null!==G?N.find(e=>e.value===G):void 0;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(l.Popover.Root,{open:V,onOpenChange:x,children:[(0,t.jsxs)(l.Popover.Trigger,{disabled:X,"aria-label":`${v}: ${K.label}`,className:(0,a.cn)(p,"stg:transition-colors stg:hover:bg-accent-hover stg:hover:text-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",h),children:[o?(0,t.jsx)("span",{className:"stg:inline-block stg:size-2.5 stg:animate-spin stg:rounded-full stg:border-2 stg:border-current stg:border-t-transparent","aria-hidden":"true"}):(0,t.jsx)(A,{tone:K.tone,className:"stg:size-2.5"}),K.label,(0,t.jsx)(B,{})]}),(0,t.jsx)(l.Popover.Portal,{container:f,children:(0,t.jsx)(l.Popover.Positioner,{sideOffset:4,align:"start",children:(0,t.jsxs)(l.Popover.Popup,{role:"listbox","aria-label":v,className:(0,a.cn)("stg:z-popover stg:w-72 stg:rounded-lg stg:border stg:border-border stg:bg-popover stg:p-1 stg:shadow-md","stg:text-popover-foreground stg:animate-in stg:fade-in-0 stg:zoom-in-95"),children:[M("option"),Q?.confirmPrompt&&(0,t.jsxs)("div",{role:"alert",className:(0,a.cn)("stg:mt-1 stg:flex stg:items-center stg:gap-2 stg:rounded-md stg:border stg:px-2.5 stg:py-1.5",m[Q.tone].container),children:[(0,t.jsx)("span",{className:(0,a.cn)("stg:flex-1 stg:text-[0.65rem] stg:leading-snug",m[Q.tone].text),children:Q.confirmPrompt}),(0,t.jsx)("button",{type:"button",onClick:()=>E(null),className:(0,a.cn)("stg:rounded stg:px-2 stg:py-0.5 stg:text-[0.65rem] stg:font-medium","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",m[Q.tone].cancel),children:"Cancel"}),(0,t.jsx)("button",{type:"button",onClick:()=>w(Q.value),className:(0,a.cn)("stg:rounded stg:px-2 stg:py-0.5 stg:text-[0.65rem] stg:font-medium stg:text-white","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",m[Q.tone].confirm),children:"Confirm"})]})]})})})]}),J]})}function B(){return(0,t.jsx)("svg",{className:"stg:size-2.5 stg:shrink-0 stg:text-muted-foreground",viewBox:"0 0 12 12",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M3 4.5 6 7.5 9 4.5"})})}function Y({visibility:e,className:i,onClick:n}){let r=Z(e),s=(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(A,{tone:r.tone,className:"stg:size-2.5"}),r.label]});return n?(0,t.jsxs)(u.Tooltip,{children:[(0,t.jsx)(u.TooltipTrigger,{render:(0,t.jsx)("button",{type:"button",onClick:n,"aria-label":`${r.label} visibility — manage access`,className:(0,a.cn)(p,"stg:transition-colors stg:hover:bg-accent-hover stg:hover:text-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",i)}),children:s}),(0,t.jsx)(u.TooltipContent,{side:"top",children:"Manage access"})]}):(0,t.jsx)("span",{className:(0,a.cn)(p,i),children:s})}e.s(["blueprintVisibilityLevels",0,E,"environmentVisibilityLevels",0,k,"instanceVisibilityLevels",0,I,"visibilityOption",0,Z],853793),e.s(["VisibilityBadge",0,Y,"VisibilitySelector",0,C],758960);var X=e.i(891287),N=e.i(459153),F=e.i(586108),w=e.i(326283);let L={agent:"agent",workflow:"workflow",plugin:"plugin",skill:"skill",mcpServer:"mcp_server",agentInstance:"agent_instance",workflowInstance:"workflow_instance",environment:"environment"},j=new Set(["agentInstance","workflowInstance"]);e.s(["ResourceVisibilityControl",0,function({kind:e,resourceId:l,visibility:a,org:c,onChanged:u,className:d}){let{updateVisibility:g,isPending:p}=function(e,t){let n=(0,F.useStigmer)(),[r,s]=(0,i.useState)(!1),[o,l]=(0,i.useState)(null);return{updateVisibility:(0,i.useCallback)(async i=>{if(t){s(!0),l(null);try{let r=(0,X.create)(N.UpdateVisibilityInputSchema,{resourceId:t,visibility:i});switch(e){case"skill":await n.skill.updateVisibility(r);break;case"agent":await n.agent.updateVisibility(r);break;case"mcpServer":await n.mcpServer.updateVisibility(r);break;case"workflow":await n.workflow.updateVisibility(r);break;case"plugin":await n.plugin.updateVisibility(r);break;case"agentInstance":await n.agentInstance.updateVisibility(r);break;case"workflowInstance":await n.workflowInstance.updateVisibility(r);break;case"environment":await n.environment.updateVisibility(r)}}catch(e){throw l((0,w.toError)(e)),e}finally{s(!1)}}},[e,t,n]),isPending:r,error:o}}(e,l),b=(0,r.useDeploymentMode)(),m=(0,r.useResourceAvailable)(n.ApiResourceKind.identity_provider),A=j.has(e),v="environment"===e,{ssoProvider:h}=(0,o.useSsoProvider)(A||v||!m?null:c??null),f=v?k(b):A?I():E({hasIdentityProvider:null!==h}),S=(0,i.useCallback)(async e=>{try{await g(e),u?.()}catch{}},[g,u]),R=(0,t.jsx)(Y,{visibility:a,className:d});if(f.length<2)return R;let W=(0,t.jsx)(C,{visibility:a,options:f,onVisibilityChange:S,isPending:p,ariaLabel:A?"Instance visibility":"Resource visibility",className:d});return(0,t.jsx)(s.PermissionGate,{resource:{kind:L[e],id:l},relation:"can_edit",fallback:R,loading:R,children:W})}],388023)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,630983,e=>{"use strict";var t=e.i(843476),s=e.i(893976);function r({className:e}){return(0,t.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:e,"aria-hidden":"true",children:[(0,t.jsx)("circle",{cx:"8",cy:"8",r:"6.25"}),(0,t.jsx)("path",{d:"M8 7v4"}),(0,t.jsx)("circle",{cx:"8",cy:"5",r:"0.5",fill:"currentColor",stroke:"none"})]})}e.s(["CloudFeatureNotice",0,function({children:e,className:a}){return(0,t.jsxs)("div",{role:"status",className:(0,s.cn)("stg:bg-muted-subtle stg:text-muted-foreground stg:flex stg:items-start stg:gap-2.5 stg:rounded-lg stg:border stg:border-transparent stg:px-4 stg:py-3",a),children:[(0,t.jsx)(r,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0"}),(0,t.jsx)("p",{className:"stg:text-xs stg:leading-relaxed",children:e})]})}])},818424,e=>{"use strict";var t=e.i(843476),s=e.i(893976);let r=(0,s.cn)("stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium stg:text-muted-foreground stg:transition-colors","stg:hover:bg-accent stg:hover:text-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-40");e.s(["Pagination",0,function({pageNum:e,totalPages:a,onPageChange:n,ariaLabel:i,className:l}){return(0,t.jsxs)("div",{className:(0,s.cn)("stg:flex stg:items-center stg:justify-between",l),role:"navigation","aria-label":i,children:[(0,t.jsx)("button",{type:"button",disabled:e<=1,onClick:()=>n(e-1),className:r,children:"Previous"}),(0,t.jsxs)("span",{className:"stg:text-xs stg:tabular-nums stg:text-muted-foreground",children:["Page ",e," of ",a]}),(0,t.jsx)("button",{type:"button",disabled:e>=a,onClick:()=>n(e+1),className:r,children:"Next"})]})}])},582458,e=>{"use strict";let t=(0,e.i(475254).default)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);e.s(["default",0,t])},878894,e=>{"use strict";var t=e.i(582458);e.s(["AlertTriangle",()=>t.default])},936175,e=>{"use strict";var t=e.i(586108),s=e.i(583093);e.s(["useBillingAccount",0,function(e){let r=(0,t.useStigmer)(),{data:a,isLoading:n,isRefetching:i,error:l,refetch:g}=(0,s.useFetch)(e?()=>r.billing.getOrCreateBillingAccount(e):null,[e,r],null);return{account:a,isLoading:n,isRefetching:i,error:l,refetch:g}}])},982247,e=>{"use strict";var t=e.i(960511);let s={[t.LedgerEntryType.purchase_credit]:"Credit Purchase",[t.LedgerEntryType.promotional_credit]:"Promotional Credit",[t.LedgerEntryType.usage_debit]:"Usage",[t.LedgerEntryType.reservation_hold]:"Reservation Hold",[t.LedgerEntryType.reservation_release]:"Reservation Release",[t.LedgerEntryType.adjustment_credit]:"Admin Credit",[t.LedgerEntryType.adjustment_debit]:"Admin Debit",[t.LedgerEntryType.refund_reversal]:"Refund",[t.LedgerEntryType.dispute_hold]:"Dispute Hold",[t.LedgerEntryType.dispute_release]:"Dispute Release",[t.LedgerEntryType.expiry_debit]:"Credit Expiry",[t.LedgerEntryType.auto_recharge_credit]:"Auto-Recharge"};e.s(["formatCreditBalance",0,function(e){if(void 0===e)return"$0.00";let t=Number(e)/1e4;return`$${(t/100).toFixed(2)}`},"formatLedgerAmount",0,function(e){let t=BigInt(0),s=Number(e<t?-e:e)/1e6,r=`$${s.toFixed(2)}`;return e>t?`+${r}`:e<t?`-${r}`:r},"formatLedgerDate",0,function(e){let t=new Date(1e3*Number(e));return new Intl.DateTimeFormat("en-US",{month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit"}).format(t)},"isCredit",0,function(e){return e===t.LedgerEntryType.purchase_credit||e===t.LedgerEntryType.promotional_credit||e===t.LedgerEntryType.adjustment_credit||e===t.LedgerEntryType.reservation_release||e===t.LedgerEntryType.dispute_release||e===t.LedgerEntryType.auto_recharge_credit},"isHold",0,function(e){return e===t.LedgerEntryType.reservation_hold||e===t.LedgerEntryType.dispute_hold},"ledgerEntryLabel",0,function(e){return s[e]??"Unknown"}])},443857,e=>{"use strict";var t=e.i(843476),s=e.i(618566),r=e.i(271645),a=e.i(610595),n=e.i(597744),i=e.i(630983),l=e.i(297629),g=e.i(936175),o=e.i(586108),d=e.i(326283),c=e.i(893976),u=e.i(982247);function m({balance:e,isLowBalance:s,className:r}){let a=e.availableMicros,n=BigInt(0),i=a<=n;return(0,t.jsxs)("div",{className:(0,c.cn)("stg:rounded-lg stg:border stg:border-border stg:bg-card stg:px-4 stg:py-4",r),children:[(0,t.jsx)("div",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Available Credits"}),(0,t.jsx)("div",{className:(0,c.cn)("stg:mt-1 stg:text-2xl stg:font-bold stg:tabular-nums",i?"stg:text-destructive":s?"stg:text-warning-foreground":"stg:text-foreground"),children:(0,u.formatCreditBalance)(a)}),(0,t.jsxs)("div",{className:"stg:mt-3 stg:flex stg:flex-wrap stg:gap-x-4 stg:gap-y-1 stg:text-xs stg:tabular-nums stg:text-muted-foreground",children:[e.purchasedMicros>n&&(0,t.jsxs)("span",{children:["Purchased: ",(0,u.formatCreditBalance)(e.purchasedMicros)]}),e.promotionalMicros>n&&(0,t.jsxs)("span",{children:["Promotional: ",(0,u.formatCreditBalance)(e.promotionalMicros)]}),e.reservedMicros>n&&(0,t.jsxs)("span",{children:["Reserved: ",(0,u.formatCreditBalance)(e.reservedMicros)]})]})]})}var x=e.i(960511);let h={visa:"Visa",mastercard:"Mastercard",amex:"American Express",discover:"Discover",diners:"Diners Club",jcb:"JCB",unionpay:"UnionPay"};function p({paymentMethod:e,accountStatus:s,isPortalLoading:r,onManage:a,className:n}){var i,l,g;let o,d,u=s===x.BillingAccountStatus.billing_account_active,m=null!=e&&""!==e.paymentMethodId;return(0,t.jsxs)("div",{className:(0,c.cn)("stg:rounded-lg stg:border stg:border-border stg:bg-card stg:px-4 stg:py-4",n),children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between",children:[(0,t.jsx)("h3",{className:"stg:text-xs stg:font-semibold stg:text-foreground",children:"Payment Method"}),m&&(0,t.jsx)("button",{type:"button",disabled:!u||r,onClick:a,className:(0,c.cn)("stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium stg:transition-colors","stg:text-muted-foreground stg:hover:bg-accent stg:hover:text-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-50"),"aria-busy":r,children:r?"Opening…":"Manage"})]}),m?(0,t.jsxs)("div",{className:"stg:mt-2 stg:flex stg:items-center stg:gap-3",children:[(0,t.jsx)(b,{brand:e.brand}),(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{className:"stg:text-sm stg:font-medium stg:text-foreground",children:[h[(i=e.brand).toLowerCase()]??i," ····"," ",e.last4]}),(0,t.jsxs)("div",{className:"stg:text-xs stg:text-muted-foreground",children:["Expires"," ",(l=e.expMonth,g=e.expYear,o=String(l).padStart(2,"0"),d=String(g).slice(-2),`${o}/${d}`)]})]})]}):(0,t.jsx)("div",{className:"stg:mt-2",children:(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:"No payment method on file. A card will be saved automatically when you purchase your first credit pack."})})]})}function b({brand:e}){return(0,t.jsx)("div",{className:"stg:flex stg:size-9 stg:items-center stg:justify-center stg:rounded-md stg:border stg:border-border stg:bg-background",children:(0,t.jsx)("span",{className:"stg:text-[0.6rem] stg:font-bold stg:uppercase stg:text-muted-foreground",children:e.slice(0,4)})})}function f(e){return e===BigInt(0)?"":(Number(e)/1e6).toString()}function y(e){let t=parseFloat(e);return isNaN(t)||t<0?BigInt(0):BigInt(Math.round(1e6*t))}function j({orgId:e,autoRecharge:s,hasPaymentMethod:n,accountStatus:i,onSaved:l,className:g}){let u=(0,r.useId)(),{setConfig:m,isSubmitting:h,error:p,clearError:b}=function(){let e=(0,o.useStigmer)(),[t,s]=(0,r.useState)(!1),[a,n]=(0,r.useState)(null),i=(0,r.useCallback)(()=>n(null),[]);return{setConfig:(0,r.useCallback)(async t=>{s(!0),n(null);try{return await e.billing.setAutoRechargeConfig({orgId:t.orgId,enabled:t.enabled,thresholdMicros:t.thresholdMicros,rechargeAmountMicros:t.rechargeAmountMicros,monthlyCapMicros:t.monthlyCapMicros})}catch(e){throw n((0,d.toError)(e)),e}finally{s(!1)}},[e]),isSubmitting:t,error:a,clearError:i}}(),[N,k]=(0,r.useState)(s?.enabled??!1),[w,C]=(0,r.useState)(f(s?.thresholdMicros??BigInt(0))),[M,S]=(0,r.useState)(f(s?.rechargeAmountMicros??BigInt(0))),[L,A]=(0,r.useState)(f(s?.monthlyCapMicros??BigInt(0))),[B,I]=(0,r.useState)(!1);(0,r.useEffect)(()=>{s&&(k(s.enabled),C(f(s.thresholdMicros)),S(f(s.rechargeAmountMicros)),A(f(s.monthlyCapMicros)))},[s]);let _=i===x.BillingAccountStatus.billing_account_active,P=n&&_,T=N!==(s?.enabled??!1)||y(w)!==(s?.thresholdMicros??BigInt(0))||y(M)!==(s?.rechargeAmountMicros??BigInt(0))||y(L)!==(s?.monthlyCapMicros??BigInt(0)),E=(0,r.useCallback)(async()=>{b(),I(!1);try{await m({orgId:e,enabled:N,thresholdMicros:y(w),rechargeAmountMicros:y(M),monthlyCapMicros:y(L)}),I(!0),l?.(),setTimeout(()=>I(!1),3e3)}catch{}},[e,N,w,M,L,m,b,l]);return(0,t.jsxs)("div",{className:(0,c.cn)("stg:rounded-lg stg:border stg:border-border stg:bg-card stg:px-4 stg:py-4",g),children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"stg:text-xs stg:font-semibold stg:text-foreground",children:"Auto-Recharge"}),(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-[0.7rem] stg:text-muted-foreground",children:"Automatically add credits when your balance runs low."})]}),(0,t.jsx)("button",{type:"button",role:"switch","aria-checked":N,disabled:!P||h,onClick:()=>k(e=>!e),className:(0,c.cn)("stg:relative stg:inline-flex stg:h-5 stg:w-9 stg:shrink-0 stg:rounded-full stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:disabled:cursor-not-allowed stg:disabled:opacity-50",N?"stg:bg-primary":"stg:bg-muted"),children:(0,t.jsx)("span",{className:(0,c.cn)("stg:pointer-events-none stg:block stg:size-4 stg:rounded-full stg:bg-background stg:shadow-sm stg:ring-0 stg:transition-transform",N?"stg:translate-x-4":"stg:translate-x-0.5","stg:mt-0.5")})})]}),!n&&(0,t.jsx)("p",{className:"stg:mt-3 stg:text-xs stg:text-muted-foreground",children:"A saved payment method is required to enable auto-recharge. Purchase a credit pack first to save a card."}),P&&(0,t.jsxs)("div",{className:"stg:mt-4 stg:space-y-3",children:[(0,t.jsx)(v,{id:`${u}-threshold`,label:"When balance drops below",value:w,onChange:C,disabled:h,placeholder:"e.g. 5"}),(0,t.jsx)(v,{id:`${u}-amount`,label:"Recharge amount",value:M,onChange:S,disabled:h,placeholder:"e.g. 50"}),(0,t.jsx)(v,{id:`${u}-cap`,label:"Monthly cap",value:L,onChange:A,disabled:h,placeholder:"e.g. 200"}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-3 stg:pt-1",children:[(0,t.jsx)("button",{type:"button",disabled:!T||h,onClick:E,className:(0,c.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium stg:transition-colors","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),"aria-busy":h,children:h?"Saving…":"Save"}),B&&(0,t.jsx)("span",{className:"stg:text-xs stg:text-emerald-600 stg:dark:text-emerald-400",children:"Saved"})]}),p&&(0,t.jsx)("p",{className:"stg:text-xs stg:text-destructive",role:"alert",children:(0,a.getUserMessage)(p)})]})]})}function v({id:e,label:s,value:r,onChange:a,disabled:n,placeholder:i}){return(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{htmlFor:e,className:"stg:block stg:text-xs stg:text-muted-foreground",children:s}),(0,t.jsxs)("div",{className:"stg:relative stg:mt-1",children:[(0,t.jsx)("span",{className:"stg:pointer-events-none stg:absolute stg:left-2.5 stg:top-1/2 stg:-translate-y-1/2 stg:text-xs stg:text-muted-foreground",children:"$"}),(0,t.jsx)("input",{id:e,type:"number",min:"0",step:"any",value:r,onChange:e=>a(e.target.value),disabled:n,placeholder:i,className:(0,c.cn)("stg:w-full stg:rounded-md stg:border stg:border-input stg:bg-background stg:py-1.5 stg:pl-6 stg:pr-3 stg:text-xs stg:tabular-nums","stg:text-foreground stg:placeholder:text-muted-foreground-subtle","stg:focus-visible:outline-none stg:focus-visible:ring-1 stg:focus-visible:ring-ring","stg:disabled:cursor-not-allowed stg:disabled:opacity-50")})]})]})}BigInt(1e6);let N=[{packId:"starter",displayName:"Starter",description:"For trying things out",priceCents:1e3,credits:1e3},{packId:"growth",displayName:"Growth",description:"For growing teams",priceCents:5e3,credits:5e3},{packId:"team",displayName:"Team",description:"For production workloads",priceCents:2e4,credits:2e4}];function k({accountStatus:e,purchasingPackId:s,onPurchase:r,className:a}){let n=e===x.BillingAccountStatus.billing_account_active;return(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"stg:mb-2 stg:text-xs stg:font-semibold stg:text-foreground",children:"Purchase Credits"}),(0,t.jsx)("div",{className:(0,c.cn)("stg:grid stg:gap-3 stg:sm:grid-cols-3",a),role:"group","aria-label":"Credit packs",children:N.map(e=>(0,t.jsx)(w,{pack:e,isPurchasing:s===e.packId,isDisabled:!n||null!=s,onPurchase:r},e.packId))}),!n&&(0,t.jsxs)("p",{className:"stg:mt-2 stg:text-xs stg:text-muted-foreground",children:["Credit purchases are unavailable while your billing account is"," ",e===x.BillingAccountStatus.billing_account_suspended?"suspended":"closed","."]})]})}function w({pack:e,isPurchasing:s,isDisabled:r,onPurchase:a}){let n;return(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:rounded-lg stg:border stg:border-border stg:bg-card stg:px-4 stg:py-4",children:[(0,t.jsx)("div",{className:"stg:text-sm stg:font-semibold stg:text-foreground",children:e.displayName}),(0,t.jsx)("div",{className:"stg:mt-0.5 stg:text-xs stg:text-muted-foreground",children:e.description}),(0,t.jsx)("div",{className:"stg:mt-3 stg:flex stg:items-baseline stg:gap-1",children:(0,t.jsx)("span",{className:"stg:text-xl stg:font-bold stg:tabular-nums stg:text-foreground",children:(n=e.priceCents/100)%1==0?`$${n}`:`$${n.toFixed(2)}`})}),(0,t.jsxs)("div",{className:"stg:mt-0.5 stg:text-xs stg:tabular-nums stg:text-muted-foreground",children:[e.credits.toLocaleString("en-US")," credits"]}),(0,t.jsx)("button",{type:"button",disabled:r,onClick:()=>a(e.packId),className:(0,c.cn)("stg:mt-4 stg:w-full stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium stg:transition-colors","stg:bg-primary stg:text-primary-foreground","stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),"aria-busy":s,children:s?"Redirecting…":"Buy"})]})}var C=e.i(818424),M=e.i(583093);function S({orgId:e,className:s}){let[n,i]=(0,r.useState)(1),{ledger:l,isLoading:g,error:d}=function(e,t={}){let s=(0,o.useStigmer)(),{pageNum:r=1,pageSize:a=20,typeFilter:n,view:i}=t,l=n?.join(",")??"",{data:g,isLoading:d,isRefetching:c,error:u,refetch:m}=(0,M.useFetch)(e?()=>s.billing.getCreditLedger({orgId:e,page:{num:r-1,size:a},typeFilter:n,view:i}):null,[e,r,a,l,i,s],null);return{ledger:g,isLoading:d,isRefetching:c,error:u,refetch:m}}(e,{pageNum:n,pageSize:10,view:x.LedgerView.statement});if(g)return(0,t.jsxs)("div",{className:(0,c.cn)("stg:space-y-2",s),"aria-busy":"true",children:[(0,t.jsx)("div",{className:"stg:h-4 stg:w-32 stg:animate-pulse stg:rounded stg:bg-muted-subtle"}),Array.from({length:5},(e,s)=>(0,t.jsx)("div",{className:"stg:h-10 stg:animate-pulse stg:rounded-lg stg:bg-muted-subtle"},s))]});if(d)return(0,t.jsx)("p",{className:(0,c.cn)("stg:text-destructive stg:text-xs",s),role:"alert",children:(0,a.getUserMessage)(d)});let u=l?.entries??[],m=l?.totalPages??0;return(0,t.jsxs)("div",{className:s,children:[(0,t.jsx)("h3",{className:"stg:mb-2 stg:text-xs stg:font-semibold stg:text-foreground",children:"Transaction History"}),0===u.length?(0,t.jsx)(B,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"stg:rounded-lg stg:border stg:border-border stg:bg-card",role:"table","aria-label":"Credit ledger",children:[(0,t.jsx)(L,{}),u.map(e=>(0,t.jsx)(A,{entry:e},e.entryId))]}),m>1&&(0,t.jsx)(C.Pagination,{pageNum:n,totalPages:m,onPageChange:i,ariaLabel:"Ledger pagination",className:"stg:mt-3"})]})]})}function L(){return(0,t.jsxs)("div",{role:"row",className:"stg:grid stg:grid-cols-[1fr_auto] stg:gap-x-4 stg:border-b stg:border-border stg:px-3.5 stg:py-2 stg:text-[0.65rem] stg:font-medium stg:uppercase stg:tracking-wider stg:text-muted-foreground stg:sm:grid-cols-[auto_1fr_auto]",children:[(0,t.jsx)("span",{role:"columnheader",className:"stg:hidden stg:sm:block",children:"Date"}),(0,t.jsx)("span",{role:"columnheader",children:"Type"}),(0,t.jsx)("span",{role:"columnheader",className:"stg:text-right",children:"Amount"})]})}function A({entry:e}){let s=e.type,r=(0,u.isCredit)(s),a=(0,u.isHold)(s);return(0,t.jsxs)("div",{role:"row",className:"stg:grid stg:grid-cols-[1fr_auto] stg:items-center stg:gap-x-4 stg:border-b stg:border-border-muted stg:px-3.5 stg:py-2.5 stg:last:border-b-0 stg:sm:grid-cols-[auto_1fr_auto]",children:[(0,t.jsx)("span",{role:"cell",className:"stg:hidden stg:text-xs stg:tabular-nums stg:text-muted-foreground stg:sm:block stg:sm:w-36",children:e.createdAt?(0,u.formatLedgerDate)(e.createdAt.seconds):"—"}),(0,t.jsxs)("div",{role:"cell",className:"stg:min-w-0",children:[(0,t.jsx)("span",{className:(0,c.cn)("stg:inline-block stg:rounded-full stg:px-2 stg:py-0.5 stg:text-[0.65rem] stg:font-medium",r?"stg:bg-emerald-500/10 stg:text-emerald-600 stg:dark:text-emerald-400":a?"stg:bg-muted stg:text-muted-foreground":"stg:bg-destructive-subtle stg:text-destructive"),children:(0,u.ledgerEntryLabel)(s)}),e.source?.description&&(0,t.jsx)("span",{className:"stg:ml-2 stg:text-xs stg:text-muted-foreground",children:e.source.description}),e.createdAt&&(0,t.jsx)("span",{className:"stg:mt-0.5 stg:block stg:text-[0.6rem] stg:tabular-nums stg:text-muted-foreground stg:sm:hidden",children:(0,u.formatLedgerDate)(e.createdAt.seconds)})]}),(0,t.jsx)("span",{role:"cell",className:(0,c.cn)("stg:text-right stg:text-xs stg:font-medium stg:tabular-nums",r?"stg:text-emerald-600 stg:dark:text-emerald-400":a?"stg:text-muted-foreground":"stg:text-destructive"),children:(0,u.formatLedgerAmount)(e.amountMicros)})]})}function B(){return(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:items-center stg:justify-center stg:rounded-lg stg:border stg:border-border stg:bg-card stg:py-10 stg:text-center",children:[(0,t.jsx)(I,{className:"stg:text-muted-foreground stg:mb-3 stg:size-8"}),(0,t.jsx)("p",{className:"stg:text-sm stg:font-medium stg:text-foreground",children:"No transactions yet"}),(0,t.jsx)("p",{className:"stg:mt-1 stg:max-w-xs stg:text-xs stg:text-muted-foreground",children:"Credit purchases, auto-recharges, and refunds will appear here as your organization funds its account."})]})}function I({className:e}){return(0,t.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:e,"aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z"}),(0,t.jsx)("path",{d:"M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8"}),(0,t.jsx)("path",{d:"M12 17.5v.5M12 6v.5"})]})}var _=e.i(878894);function P({availableMicros:e,thresholdMicros:s,className:r}){if(e>=s)return null;let a=e<=BigInt(0);return(0,t.jsxs)("div",{role:"alert",className:(0,c.cn)("stg:flex stg:items-start stg:gap-2.5 stg:rounded-lg stg:border stg:px-3.5 stg:py-3 stg:text-xs",a?"stg:border-destructive/30 stg:bg-destructive-subtle stg:text-destructive":"stg:border-warning/30 stg:bg-warning/5 stg:text-warning-foreground",r),children:[(0,t.jsx)(_.AlertTriangle,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0","aria-hidden":"true"}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"stg:font-medium",children:a?"Credit balance exhausted":"Low credit balance"}),(0,t.jsx)("p",{className:"stg:mt-0.5 stg:opacity-80",children:a?"Your credit balance is zero. Purchase credits to continue running agent executions.":`Your balance (${(0,u.formatCreditBalance)(e)}) is below the warning threshold. Consider purchasing additional credits.`})]})]})}function T({checkoutSuccess:e,onDismissCheckoutSuccess:s,className:a}){let g=(0,r.useId)(),{activeOrg:o}=(0,l.useOrg)(),d=(0,n.useDeploymentMode)(),c=o?.metadata?.id??"";return(0,t.jsxs)("section",{"aria-labelledby":g,className:a,children:[(0,t.jsx)("h2",{id:g,className:"stg:text-foreground stg:mb-1 stg:text-sm stg:font-semibold",children:"Billing"}),(0,t.jsx)("p",{className:"stg:text-muted-foreground stg:mb-4 stg:text-xs",children:"Manage credits, purchase credit packs, and view transaction history."}),"local"===d?(0,t.jsx)(i.CloudFeatureNotice,{children:"Credit billing and purchases are available on Stigmer Cloud. Local mode uses your own LLM API keys directly — no Stigmer credits needed."}):c?(0,t.jsx)(E,{orgId:c,checkoutSuccess:e,onDismissCheckoutSuccess:s}):(0,t.jsx)("p",{className:"stg:text-muted-foreground stg:py-4 stg:text-center stg:text-xs",children:"Select an organization to view billing."})]})}function E({orgId:e,checkoutSuccess:s,onDismissCheckoutSuccess:n}){let{account:i,isLoading:l,error:c,refetch:u}=(0,g.useBillingAccount)(e),{createSession:x,isSubmitting:h,error:b,clearError:f}=function(){let e=(0,o.useStigmer)(),[t,s]=(0,r.useState)(!1),[a,n]=(0,r.useState)(null),i=(0,r.useCallback)(()=>n(null),[]);return{createSession:(0,r.useCallback)(async t=>{s(!0),n(null);try{let s=await e.billing.createCreditCheckoutSession({orgId:t.orgId,packId:t.packId,successUrl:t.successUrl,cancelUrl:t.cancelUrl});return s.checkoutUrl&&(window.location.href=s.checkoutUrl),s}catch(e){throw n((0,d.toError)(e)),e}finally{s(!1)}},[e]),isSubmitting:t,error:a,clearError:i}}(),{openPortal:y,isLoading:v}=function(){let e=(0,o.useStigmer)(),[t,s]=(0,r.useState)(!1),[a,n]=(0,r.useState)(null),i=(0,r.useCallback)(()=>n(null),[]);return{openPortal:(0,r.useCallback)(async t=>{s(!0),n(null);try{let s=window.location.href,r=await e.billing.createBillingPortalSession({orgId:t,returnUrl:s});r.portalUrl&&(window.location.href=r.portalUrl)}catch(e){throw n((0,d.toError)(e)),e}finally{s(!1)}},[e]),isLoading:t,error:a,clearError:i}}(),[N,w]=(0,r.useState)(null),C=(0,r.useCallback)(t=>{w(t),f();let s=window.location.origin,r=`${s}/settings/billing`;x({orgId:e,packId:t,successUrl:`${r}?checkout=success`,cancelUrl:r}).catch(()=>{w(null)})},[e,x,f]);if(l)return(0,t.jsxs)("div",{className:"stg:space-y-4","aria-busy":"true","aria-label":"Loading billing",children:[(0,t.jsx)("div",{className:"stg:h-24 stg:animate-pulse stg:rounded-lg stg:bg-muted-subtle"}),(0,t.jsx)("div",{className:"stg:grid stg:grid-cols-3 stg:gap-3",children:Array.from({length:3},(e,s)=>(0,t.jsx)("div",{className:"stg:h-36 stg:animate-pulse stg:rounded-lg stg:bg-muted-subtle"},s))}),(0,t.jsx)("div",{className:"stg:h-48 stg:animate-pulse stg:rounded-lg stg:bg-muted-subtle"})]});if(c)return(0,t.jsx)("p",{className:"stg:text-destructive stg:text-xs",role:"alert",children:(0,a.getUserMessage)(c)});if(!i)return null;let M=i.balance;if(!M)return null;let L=M.availableMicros<i.lowBalanceThresholdMicros;return(0,t.jsxs)("div",{className:"stg:space-y-6",children:[s&&(0,t.jsx)(U,{onDismiss:n}),(0,t.jsx)(P,{availableMicros:M.availableMicros,thresholdMicros:i.lowBalanceThresholdMicros}),(0,t.jsx)(m,{balance:M,isLowBalance:L}),(0,t.jsx)(p,{paymentMethod:i.defaultPaymentMethod,accountStatus:i.status,isPortalLoading:v,onManage:()=>y(e)}),(0,t.jsx)(j,{orgId:e,autoRecharge:i.autoRecharge,hasPaymentMethod:null!=i.defaultPaymentMethod&&""!==i.defaultPaymentMethod.paymentMethodId,accountStatus:i.status,onSaved:u}),(0,t.jsx)(k,{accountStatus:i.status,purchasingPackId:h?N:null,onPurchase:C}),b&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-xs",role:"alert",children:(0,a.getUserMessage)(b)}),(0,t.jsx)(S,{orgId:e})]})}function U({onDismiss:e}){return(0,t.jsxs)("div",{role:"status",className:"stg:flex stg:items-center stg:justify-between stg:gap-3 stg:rounded-lg stg:border stg:border-emerald-500/30 stg:bg-emerald-500/5 stg:px-3.5 stg:py-3 stg:text-xs stg:text-emerald-700 stg:dark:text-emerald-300",children:[(0,t.jsxs)("p",{children:[(0,t.jsx)("span",{className:"stg:font-medium",children:"Payment received"})," — ","credits will appear in your balance shortly."]}),e&&(0,t.jsx)("button",{type:"button",onClick:e,className:"stg:shrink-0 stg:rounded stg:p-0.5 stg:transition-colors stg:hover:bg-emerald-500/10","aria-label":"Dismiss",children:(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M18 6 6 18"}),(0,t.jsx)("path",{d:"m6 6 12 12"})]})})]})}e.s(["default",0,function(){let e=(0,s.useSearchParams)(),a=(0,r.useMemo)(()=>"success"===e.get("checkout"),[e]),n=(0,r.useCallback)(()=>{let e=new URL(window.location.href);e.searchParams.delete("checkout"),window.history.replaceState({},"",e.pathname)},[]);return(0,t.jsx)(T,{checkoutSuccess:a,onDismissCheckoutSuccess:n})}],443857)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,261716,e=>{"use strict";var s=e.i(843476),t=e.i(271645),a=e.i(610413),r=e.i(107233),n=e.i(893976),i=e.i(610595),l=e.i(910304),o=e.i(283416),c=e.i(65642),d=e.i(170255),g=e.i(597744),u=e.i(311015),m=e.i(630983),h=e.i(266442),x=e.i(17616),p=e.i(937111);let f={[o.LicenseTerm.trial]:"Trial",[o.LicenseTerm.paid]:"Paid"},b={[p.Feature.sso_enforcement]:{label:"SSO enforcement",description:"Require members to sign in through a registered identity provider."},[p.Feature.byo_provider_keys]:{label:"Bring your own provider keys",description:"Use the customer's own LLM provider keys instead of the metered proxy."},[p.Feature.channels]:{label:"Channels",description:"Deliver agents over messaging channels through a channel runtime."},[p.Feature.sharing]:{label:"Sharing",description:"Share agents with individuals and guests through hosted links."}},j=Object.keys(b).map(Number).sort((e,s)=>e-s);function v(e){return e in b}let N=new Intl.RelativeTimeFormat("en",{numeric:"auto"});function y(e){return e===o.LicenseTerm.trial||e===o.LicenseTerm.paid?f[e]:"Unknown term"}function w(e){return e?(0,x.timestampDate)(e):void 0}function k(e){return e.toISOString().slice(0,10)}function S(e){return k(new Date(e.getTime()-1))}function C(e){return Date.parse(`${e}T00:00:00Z`)}function T(e){return`${e.toISOString().slice(0,16).replace("T"," ")} UTC`}function L(e,s){let t=Math.round((C(e)-C(k(s)))/864e5);return 60>Math.abs(t)?N.format(t,"day"):N.format(Math.round(t/30.44),"month")}function U(e,s){return void 0===e?`Unlimited ${s}s`:$(e,s)}function $(e,s){return`${e} ${s}${1===e?"":"s"}`}function E(e){return e.trim().replace(/\s+/g," ").toLowerCase()}function I(e){return w(e.status?.issuedAt)?.getTime()??-1/0}function A(e){return w(e.spec?.expiresAt)?.getTime()??-1/0}var z=e.i(766354),_=e.i(16715),B=e.i(188482),F=e.i(643531),M=e.i(174886),D=e.i(475254);let O=(0,D.default)("eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]),P=(0,D.default)("eye-off",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);var R=e.i(162697),q=e.i(193799);let Y="stg:size-3.5";function G({ticket:e,isLoading:a,error:r,className:l}){let[o,d]=(0,t.useState)(!1),{copy:g,copied:u}=(0,q.useCopyFeedback)(),m=(0,t.useRef)(null),h=(0,t.useCallback)(async()=>{!e||await g(e)||(d(!0),requestAnimationFrame(()=>{m.current&&(0,R.selectElementText)(m.current)}))},[g,e]);return(0,s.jsxs)("section",{"aria-label":"Ticket",className:(0,n.cn)("stg:space-y-3 stg:rounded-lg stg:border stg:border-border stg:bg-card stg:p-4",l),children:[(0,s.jsxs)("div",{className:"stg:flex stg:flex-wrap stg:items-start stg:justify-between stg:gap-3",children:[(0,s.jsxs)("div",{className:"stg:min-w-0 stg:space-y-1",children:[(0,s.jsx)("h4",{className:"stg:m-0 stg:text-sm stg:font-semibold stg:text-foreground",children:"Ticket"}),(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-muted-foreground",children:"The signed key the customer installs on their server. Anyone holding it can run it as this customer, so send it only to their contact address."})]}),(0,s.jsxs)("div",{className:"stg:flex stg:shrink-0 stg:gap-2",children:[(0,s.jsx)(c.Button,{variant:"outline",className:"stg:w-28 stg:justify-center",disabled:!e,"aria-pressed":o,icon:o?(0,s.jsx)(P,{className:Y,"aria-hidden":"true"}):(0,s.jsx)(O,{className:Y,"aria-hidden":"true"}),onClick:()=>d(e=>!e),children:o?"Hide ticket":"Show ticket"}),(0,s.jsx)(c.Button,{className:"stg:w-28 stg:justify-center",disabled:!e,icon:u?(0,s.jsx)(F.Check,{className:Y,"aria-hidden":"true"}):(0,s.jsx)(M.Copy,{className:Y,"aria-hidden":"true"}),onClick:()=>void h(),children:u?"Copied":"Copy ticket"})]})]}),a&&(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-muted-foreground","aria-busy":"true",children:"Reading the ticket…"}),r&&(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-destructive",role:"alert",children:(0,i.getUserMessage)(r)}),o&&e&&(0,s.jsx)("code",{ref:m,className:(0,n.cn)("stg:block stg:max-h-40 stg:overflow-y-auto stg:break-all stg:select-all stg:rounded-md","stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5","stg:font-mono stg:text-xs stg:text-foreground"),children:e}),(0,s.jsx)("div",{role:"status","aria-live":"polite","aria-atomic":"true",className:"stg:sr-only",children:u&&"Ticket copied to clipboard"})]})}var K=e.i(586108),V=e.i(583093);let W="stg:size-3.5";function H({license:e,issued:a,standing:r,now:i,onBack:l,onRenew:o,className:d}){let g=e.metadata?.id??"",u=a?.status?.ticket,m=function(e,s){let a=(0,K.useStigmer)(),r=(s?.enabled??!0)&&""!==e,{data:n,isLoading:i,error:l,refetch:o}=(0,V.useFetch)(r?()=>a.license.get(e):null,[r,e,a],null);return(0,t.useMemo)(()=>({license:n,isLoading:i,error:l,refetch:o}),[n,i,l,o])}(g,{enabled:!u}),x=u??m.license?.status?.ticket??null,p=e.spec,f=p?.customer,j=p?.entitlements?.limits,N=(p?.entitlements?.features??[]).filter(v),k=w(p?.expiresAt),C=w(p?.graceUntil),U=w(e.status?.issuedAt),$=e.status?.audit?.specAudit?.createdBy,E=k&&C&&C.getTime()>k.getTime()?C:void 0,I=k?S(k):void 0;return(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-4",d),children:[(0,s.jsxs)("div",{className:"stg:space-y-2",children:[(0,s.jsx)(c.Button,{variant:"ghost",size:"xs",icon:(0,s.jsx)(z.ArrowLeft,{className:W,"aria-hidden":"true"}),onClick:l,children:"Licenses"}),(0,s.jsxs)("div",{className:"stg:flex stg:flex-wrap stg:items-start stg:justify-between stg:gap-2",children:[(0,s.jsxs)("div",{className:"stg:min-w-0",children:[(0,s.jsx)("h3",{className:"stg:m-0 stg:truncate stg:text-base stg:font-semibold stg:text-foreground",children:f?.displayName??"Unknown customer"}),(0,s.jsxs)("p",{className:"stg:m-0 stg:mt-1 stg:flex stg:flex-wrap stg:items-center stg:gap-x-2 stg:gap-y-1 stg:text-sm stg:text-muted-foreground",children:[r&&(0,s.jsx)(h.StatusBadge,{phase:r.phase,label:r.label,tooltip:r.reason}),(0,s.jsxs)("span",{children:[`${p?y(p.term):"Unknown term"} \xb7 covered through ${I??"an unknown day"}`,I&&` (${L(I,i)})`]})]})]}),o&&(0,s.jsx)(c.Button,{variant:"outline",icon:(0,s.jsx)(_.RefreshCw,{className:W,"aria-hidden":"true"}),onClick:o,children:"Renew"})]})]}),a&&(0,s.jsxs)("p",{className:"stg:m-0 stg:rounded-md stg:border stg:border-border stg:bg-muted-subtle stg:px-3 stg:py-2 stg:text-sm stg:text-foreground",role:"status",children:["License issued and signed. Copy the ticket below and send it to"," ",f?.contactEmail||"the customer","."]}),(0,s.jsx)(G,{ticket:x,isLoading:!u&&m.isLoading,error:m.error}),(0,s.jsxs)("dl",{className:"stg:m-0 stg:grid stg:grid-cols-1 stg:gap-x-6 stg:gap-y-4 stg:rounded-lg stg:border stg:border-border stg:bg-card stg:p-4 stg:sm:grid-cols-2",children:[(0,s.jsxs)(Z,{label:"Customer",children:[(0,s.jsx)("span",{className:"stg:block",children:f?.displayName}),(0,s.jsx)("span",{className:"stg:block stg:text-muted-foreground",children:f?.contactEmail}),f?.organization&&(0,s.jsx)("span",{className:"stg:block stg:text-muted-foreground",children:`Cloud organization ${f.organization}`})]}),(0,s.jsx)(Z,{label:"Term",children:p?y(p.term):"Unknown"}),(0,s.jsx)(Z,{label:"Covered through",children:k&&I?(0,s.jsx)(J,{date:k,children:`${I} (${L(I,i)})`}):"Unknown"}),(0,s.jsx)(Z,{label:"Grace",children:E?(0,s.jsx)(J,{date:E,children:`Through ${S(E)}`}):"None"}),(0,s.jsxs)(Z,{label:"Limits",children:[(0,s.jsx)("span",{className:"stg:block",children:j?.maxUsers!==void 0?`${j.maxUsers} users`:"Unlimited users"}),(0,s.jsx)("span",{className:"stg:block",children:j?.maxOrganizations!==void 0?`${j.maxOrganizations} organizations`:"Unlimited organizations"})]}),(0,s.jsx)(Z,{label:"Features",children:0===N.length?"None":N.map(e=>(0,s.jsx)("span",{className:"stg:block",children:b[e].label},e))}),(0,s.jsxs)(Z,{label:"Issued",children:[U?(0,s.jsx)(J,{date:U,children:T(U)}):"Unknown",$&&($.email||$.displayName)&&(0,s.jsx)("span",{className:"stg:block stg:text-muted-foreground",children:$.displayName&&$.email?`by ${$.displayName} (${$.email})`:`by ${$.displayName||$.email}`})]}),(0,s.jsx)(Z,{label:"Signing key",children:(0,s.jsx)("span",{className:"stg:font-mono",children:e.status?.keyId||"Unknown"})}),(0,s.jsxs)(Z,{label:"License",children:[(0,s.jsx)("span",{className:"stg:block",children:e.metadata?.name}),(0,s.jsx)("span",{className:"stg:block stg:font-mono stg:text-muted-foreground",children:g})]}),p?.notes&&(0,s.jsx)(Z,{label:"Notes",wide:!0,children:(0,s.jsx)("span",{className:"stg:whitespace-pre-wrap",children:p.notes})})]})]})}function Z({label:e,wide:t,children:a}){return(0,s.jsxs)("div",{className:(0,n.cn)("stg:min-w-0",t&&"stg:sm:col-span-2"),children:[(0,s.jsx)("dt",{className:"stg:text-xs stg:text-muted-foreground",children:e}),(0,s.jsx)("dd",{className:"stg:m-0 stg:mt-0.5 stg:break-words stg:text-sm stg:text-foreground",children:a})]})}function J({date:e,children:t}){return(0,s.jsxs)(B.Tooltip,{children:[(0,s.jsx)(B.TooltipTrigger,{render:(0,s.jsx)("span",{className:"stg:inline-flex"}),children:t}),(0,s.jsx)(B.TooltipContent,{side:"top",children:T(e)})]})}var Q=e.i(251634),X=e.i(565507),ee=e.i(494953),es=e.i(869803),et=e.i(933221),ea=e.i(891914);let er={[o.LicenseTerm.trial]:{days:30},[o.LicenseTerm.paid]:{years:1}},en={[o.LicenseTerm.trial]:0,[o.LicenseTerm.paid]:30};function ei(e,s,t){return`${f[e]} license for ${ed(s)} until ${t}`}function el(e){let s=e.trim();if(""===s)return{ok:!0,value:void 0};let t=Number(s);return!Number.isInteger(t)||t>0x7fffffff?{ok:!1,error:"Enter a whole number, or leave it empty for unlimited."}:{ok:!0,value:t}}let eo="0123456789abcdefghjkmnpqrstvwxyz";function ec(e,s){return k(new Date(C(e)+864e5*s))}function ed(e){return e.trim().replace(/\s+/g," ")}let eg="stg:size-3.5 stg:shrink-0 stg:cursor-pointer stg:accent-primary stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-offset-1",eu={[o.LicenseTerm.trial]:"30 days",[o.LicenseTerm.paid]:"1 year"},em={"spec.customer.display_name":"Name the customer.","spec.customer.contact_email":"Enter the address renewal notices go to.","spec.entitlements.limits.max_users":"Enter at least 1, or leave it empty for unlimited.","spec.entitlements.limits.max_organizations":"Enter at least 1, or leave it empty for unlimited.","spec.notes":"Notes are limited to 4,096 characters."};function eh({customers:e,renewing:a,now:r,isSubmitting:d,submitError:g,onSubmit:u,onCancel:m,className:h}){var x,p,N,y;let T,L,$,I,A,_=(0,t.useId)(),B=a?.spec?.customer?.id??"",F=(N=a?.spec?.term)===o.LicenseTerm.trial||N===o.LicenseTerm.paid?N:void 0,[M,D]=(0,t.useState)(""!==B||e.length>0?"existing":"new"),[O,P]=(0,t.useState)(B),[R,q]=(0,t.useState)(""),[Y,G]=(0,t.useState)(""),[K,V]=(0,t.useState)(""),[W]=(0,t.useState)(()=>(function(e=Date.now(),s=e=>{globalThis.crypto.getRandomValues(e)}){let t="",a=e;for(let e=0;e<10;e+=1)t=eo.charAt(a%32)+t,a=Math.floor(a/32);let r=new Uint8Array(10);s(r);let n="",i=0,l=0;for(let e of r){for(i=i<<8|e,l+=8;l>=5;)n+=eo.charAt(i>>>l-5&31),l-=5;i&=(1<<l)-1}return`cus_${t}${n}`})()),[H,Z]=(0,t.useState)(F??o.LicenseTerm.trial),[J,ej]=(0,t.useState)(null),[ev,eN]=(0,t.useState)(()=>{let e,s;if(!a||void 0===F)return null;let t=(e=w(a.spec?.expiresAt),s=w(a.spec?.graceUntil),e&&s?Math.max(0,Math.round((s.getTime()-e.getTime())/864e5)):0);return t===en[F]?null:String(t)}),[ey,ew]=(0,t.useState)(eb(a?.spec?.entitlements?.limits?.maxUsers)),[ek,eS]=(0,t.useState)(eb(a?.spec?.entitlements?.limits?.maxOrganizations)),[eC,eT]=(0,t.useState)(()=>(a?.spec?.entitlements?.features??[]).filter(v)),[eL,eU]=(0,t.useState)(""),[e$,eE]=(0,t.useState)(!1),eI=k(r),eA=function(e,s){let t=k(e),a=w(s?.spec?.expiresAt);if(!a)return t;let r=ec(S(a),1);return r>t?r:t}(r,a),ez=J??function(e,s){let{days:t,years:a}=er[e],r=a?function(e,s){let[t,a,r]=e.split("-").map(Number);return k(new Date(Date.UTC(t+s,a-1,r)))}(s,a):ec(s,t??0);return ec(r,-1)}(H,eA),e_=ev??String(en[H]),eB=e.find(e=>e.customer.id===O),eF="existing"===M?eB&&{id:eB.customer.id,displayName:eB.customer.displayName,contactEmail:eB.customer.contactEmail,organization:eB.customer.organization}:{id:W,displayName:R,contactEmail:Y,organization:K},eM="new"===M?(L=E((x={displayName:R,contactEmail:Y}).displayName),$=E(x.contactEmail),""===L&&""===$?[]:e.filter(({customer:e})=>""!==L&&E(e.displayName)===L||""!==$&&E(e.contactEmail)===$)):[],eD=(I=Number(e_.trim()),""===e_.trim()||!Number.isInteger(I)||I<0||I>3650?{ok:!1,error:"Enter a whole number of days from 0 to 3650."}:{ok:!0,value:I}),eO=el(ey),eP=el(ek),eR=""===ez?"Choose the last day the license covers.":ez<k(r)?"The last covered day cannot be in the past.":null,eq=[];if(eF&&eD.ok&&eO.ok&&eP.ok&&null===eR){let e,s,t,a,r;s=new Date((e=new Date(C(ec((p={customer:eF,term:H,lastCoveredDay:ez,graceDays:eD.value,maxUsers:eO.value,maxOrganizations:eP.value,features:eC,notes:eL}).lastCoveredDay,1)))).getTime()+864e5*p.graceDays),t={...void 0!==p.maxUsers&&{maxUsers:p.maxUsers},...void 0!==p.maxOrganizations&&{maxOrganizations:p.maxOrganizations}},a=p.customer.organization?.trim(),r=p.notes.trim(),T={name:ei(p.term,p.customer.displayName,p.lastCoveredDay),org:"",customer:{id:p.customer.id,displayName:ed(p.customer.displayName),contactEmail:p.customer.contactEmail.trim(),...a?{organization:a}:{}},entitlements:{...Object.keys(t).length>0&&{limits:t},features:[...p.features]},term:p.term,expiresAt:e,graceUntil:s,...""!==r&&{notes:r}},eq=(0,ea.validateMessage)(ee.LicenseSchema,(0,X.buildLicenseProto)(T))}let eY=e=>{let s=eq.find(s=>(0,Q.pathToString)(s.field)===e);return s?em[e]??s.message:null},eG=(e,s)=>e||e$?s:null,eK=eq.filter(e=>!((0,Q.pathToString)(e.field)in em)),eV=void 0!==T&&0===eq.length,eW=eB?null!==eY("spec.customer.contact_email")||null!==eY("spec.customer.display_name")?"This customer's stored name or address does not pass validation. Issue to them as a new customer with corrected details.":null:"Choose a customer, or enter a new one.",eH=eF?.displayName.trim()?ei(H,eF.displayName,ez||eI):null;return(0,s.jsxs)("form",{className:(0,n.cn)("stg:max-w-xl stg:space-y-5",h),onSubmit:e=>{if(e.preventDefault(),!d){if(!eV||!T)return void eE(!0);u(T)}},noValidate:!0,"aria-labelledby":`${_}-title`,children:[(0,s.jsxs)("div",{className:"stg:space-y-2",children:[(0,s.jsx)(c.Button,{variant:"ghost",size:"xs",icon:(0,s.jsx)(z.ArrowLeft,{className:"stg:size-3.5","aria-hidden":"true"}),onClick:m,disabled:d,children:"Licenses"}),(0,s.jsxs)("div",{children:[(0,s.jsx)("h3",{id:`${_}-title`,className:"stg:m-0 stg:text-base stg:font-semibold stg:text-foreground",children:a?"Renew license":"Issue license"}),(0,s.jsx)("p",{className:"stg:m-0 stg:mt-1 stg:text-sm stg:text-muted-foreground",children:a?"The renewal is a new license. Once it is issued, the calendar shows the current one as renewed.":"A license is final once issued. To change one, issue a new license; the calendar shows the old one as renewed."})]})]}),(0,s.jsxs)(ex,{title:"Customer",children:[a&&eB?(0,s.jsxs)("p",{className:"stg:m-0 stg:text-sm",children:[(0,s.jsx)("span",{className:"stg:block stg:text-foreground",children:eB.customer.displayName}),(0,s.jsx)("span",{className:"stg:block stg:text-muted-foreground",children:eB.customer.contactEmail})]}):null,e.length>0&&!a&&(0,s.jsxs)("fieldset",{className:(0,n.cn)(es.UNSTYLED_FIELDSET,"stg:flex stg:flex-wrap stg:gap-4"),children:[(0,s.jsx)("legend",{className:"stg:sr-only",children:"Customer"}),(0,s.jsx)(ep,{name:`${_}-mode`,checked:"existing"===M,onChange:()=>D("existing"),label:"Existing customer",disabled:d}),(0,s.jsx)(ep,{name:`${_}-mode`,checked:"new"===M,onChange:()=>D("new"),label:"New customer",disabled:d})]}),a?(0,s.jsx)(ef,{message:eW}):"existing"===M?(0,s.jsxs)(et.Field,{label:"Licensed customer",required:!0,children:[(0,s.jsxs)("select",{className:et.INPUT_CLASSES,value:O,onChange:e=>P(e.target.value),disabled:d,children:[(0,s.jsx)("option",{value:"",children:"Choose a customer"}),e.map(({customer:e,licenseCount:t})=>(0,s.jsx)("option",{value:e.id,children:`${e.displayName} — ${e.contactEmail} \xb7 ${t} ${1===t?"license":"licenses"}`},e.id))]}),(0,s.jsx)(ef,{message:eG(void 0!==eB,eW)})]}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(et.Field,{label:"Display name",required:!0,children:[(0,s.jsx)("input",{className:et.INPUT_CLASSES,value:R,onChange:e=>q(e.target.value),placeholder:"As the licensed server shows it, e.g. Acme Corp",disabled:d,autoComplete:"off"}),(0,s.jsx)(ef,{message:eG(""!==R,eY("spec.customer.display_name"))})]}),(0,s.jsxs)(et.Field,{label:"Contact email",required:!0,children:[(0,s.jsx)("input",{className:et.INPUT_CLASSES,type:"email",value:Y,onChange:e=>G(e.target.value),placeholder:"Where renewal and expiry notices go",disabled:d,autoComplete:"off"}),(0,s.jsx)(ef,{message:eG(""!==Y,eY("spec.customer.contact_email"))})]}),(0,s.jsx)(et.Field,{label:"Cloud organization",children:(0,s.jsx)("input",{className:et.INPUT_CLASSES,value:K,onChange:e=>V(e.target.value),placeholder:"Its slug, if the customer also holds one",disabled:d,autoComplete:"off",spellCheck:!1})}),eM.length>0&&(0,s.jsxs)("div",{role:"status",className:"stg:space-y-1.5 stg:rounded-md stg:border stg:border-border stg:bg-muted-subtle stg:px-3 stg:py-2",children:[(0,s.jsxs)("p",{className:"stg:text-xs stg:text-foreground",children:[1===eM.length?"A customer with this name or address already holds licenses.":"Customers with this name or address already hold licenses."," ","Pick them instead, so their renewals stay in one history."]}),(0,s.jsx)("div",{className:"stg:flex stg:flex-wrap stg:gap-2",children:eM.map(({customer:e})=>(0,s.jsx)(c.Button,{size:"xs",variant:"outline",onClick:()=>{P(e.id),D("existing")},children:`Use ${e.displayName}`},e.id))})]})]})]}),(0,s.jsxs)(ex,{title:"Term",children:[(0,s.jsxs)("fieldset",{className:(0,n.cn)(es.UNSTYLED_FIELDSET,"stg:flex stg:flex-wrap stg:gap-4"),children:[(0,s.jsx)("legend",{className:"stg:sr-only",children:"Term"}),[o.LicenseTerm.trial,o.LicenseTerm.paid].map(e=>(0,s.jsx)(ep,{name:`${_}-term`,checked:H===e,onChange:()=>Z(e),label:`${f[e]} \xb7 ${eu[e]}`,disabled:d},e))]}),(0,s.jsxs)("div",{className:"stg:grid stg:grid-cols-1 stg:gap-3 stg:sm:grid-cols-2",children:[(0,s.jsxs)(et.Field,{label:"Covered through (UTC)",required:!0,children:[(0,s.jsx)("input",{className:et.INPUT_CLASSES,type:"date",min:eI,value:ez,onChange:e=>ej(e.target.value),disabled:d}),(0,s.jsx)(ef,{message:eG(!0,eR)})]}),(0,s.jsxs)(et.Field,{label:"Grace period (days)",required:!0,children:[(0,s.jsx)("input",{className:et.INPUT_CLASSES,type:"number",inputMode:"numeric",min:0,step:1,value:e_,onChange:e=>eN(e.target.value),disabled:d}),(0,s.jsx)(ef,{message:eG(!0,eD.ok?null:eD.error)})]})]}),(0,s.jsxs)("p",{className:"stg:text-xs stg:text-muted-foreground",children:[null===J?a?`Continues from the renewed license: ${eu[H]} from ${eA}.`:`${eu[H]} from today.`:"Set by hand."," ","During the grace period the licensed server keeps serving and warns that the license has expired.",null!==J&&(0,s.jsxs)(s.Fragment,{children:[" ",(0,s.jsx)("button",{type:"button",className:"stg:cursor-pointer stg:font-medium stg:text-foreground stg:underline stg:underline-offset-2",onClick:()=>ej(null),disabled:d,children:`Use the ${f[H].toLowerCase()} preset`})]})]})]}),(0,s.jsxs)(ex,{title:"Entitlements",children:[(0,s.jsxs)("div",{className:"stg:grid stg:grid-cols-1 stg:gap-3 stg:sm:grid-cols-2",children:[(0,s.jsxs)(et.Field,{label:"Max users",children:[(0,s.jsx)("input",{className:et.INPUT_CLASSES,type:"number",inputMode:"numeric",min:1,step:1,value:ey,onChange:e=>ew(e.target.value),placeholder:"Unlimited",disabled:d}),(0,s.jsx)(ef,{message:eG(""!==ey,eO.ok?eY("spec.entitlements.limits.max_users"):eO.error)})]}),(0,s.jsxs)(et.Field,{label:"Max organizations",children:[(0,s.jsx)("input",{className:et.INPUT_CLASSES,type:"number",inputMode:"numeric",min:1,step:1,value:ek,onChange:e=>eS(e.target.value),placeholder:"Unlimited",disabled:d}),(0,s.jsx)(ef,{message:eG(""!==ek,eP.ok?eY("spec.entitlements.limits.max_organizations"):eP.error)})]})]}),(0,s.jsxs)("fieldset",{className:(0,n.cn)(es.UNSTYLED_FIELDSET,"stg:space-y-2"),children:[(0,s.jsx)("legend",{className:"stg:mb-1 stg:text-[11px] stg:font-medium stg:text-muted-foreground",children:"Features"}),j.map(e=>(0,s.jsxs)("label",{className:"stg:flex stg:items-start stg:gap-2 stg:text-sm",children:[(0,s.jsx)("input",{type:"checkbox",className:(0,n.cn)(eg,"stg:mt-0.5"),checked:eC.includes(e),onChange:s=>{let t;return t=s.target.checked,eT(s=>t?j.filter(t=>t===e||s.includes(t)):s.filter(s=>s!==e))},disabled:d}),(0,s.jsxs)("span",{children:[(0,s.jsx)("span",{className:"stg:block stg:text-foreground",children:b[e].label}),(0,s.jsx)("span",{className:"stg:block stg:text-xs stg:text-muted-foreground",children:b[e].description})]})]},e))]})]}),(0,s.jsxs)(ex,{title:"Notes",children:[(0,s.jsxs)(et.Field,{label:"Internal note",children:[(0,s.jsx)("textarea",{className:(0,n.cn)(et.INPUT_CLASSES,"stg:min-h-16"),value:eL,onChange:e=>eU(e.target.value),placeholder:"The order, the contact, the reason for a bespoke entitlement",disabled:d}),(0,s.jsx)(ef,{message:eG(""!==eL,eY("spec.notes"))})]}),(0,s.jsx)("p",{className:"stg:m-0 stg:text-xs stg:text-muted-foreground",children:"Never signed into the ticket and never shown to the customer."})]}),(0,s.jsx)("section",{"aria-label":"What will be issued",className:"stg:space-y-1 stg:rounded-lg stg:border stg:border-border stg:bg-muted-subtle stg:p-4",children:eH?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:font-semibold stg:text-foreground",children:eH}),(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-foreground",children:[eO.ok?U(eO.value,"user"):null,eP.ok?U(eP.value,"organization"):null,0===(A=j.filter(e=>eC.includes(e)).map(e=>b[e].label)).length?"No features":A.join(", ")].filter(e=>null!==e).join(" · ")}),eD.ok&&(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-muted-foreground",children:0===eD.value?"No grace period: the licensed server stops the day after.":`Then ${eD.value} days of grace, while the licensed server keeps serving and warns.`})]}):(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-muted-foreground",children:"Choose the customer to see the license this will issue."})}),e$&&eK.length>0&&(0,s.jsx)("ul",{className:(0,n.cn)(es.UNSTYLED_LIST,"stg:space-y-1"),role:"alert",children:eK.map(e=>(0,s.jsx)("li",{className:"stg:text-xs stg:text-destructive",children:e.message},`${(0,Q.pathToString)(e.field)}:${e.ruleId}`))}),g&&(0,s.jsx)("p",{className:"stg:text-xs stg:text-destructive",role:"alert",children:(y=g)instanceof l.StigmerError&&"already-exists"===y.code?"This license was already issued: same customer, term and last covered day. Open it from the list instead of issuing it twice.":(0,i.getUserMessage)(y)}),(0,s.jsxs)("div",{className:"stg:flex stg:gap-2",children:[(0,s.jsx)(c.Button,{type:"submit",disabled:d,children:d?"Issuing…":a?"Issue renewal":"Issue license"}),(0,s.jsx)(c.Button,{variant:"outline",onClick:m,disabled:d,children:"Cancel"})]})]})}function ex({title:e,children:t}){return(0,s.jsxs)("section",{className:"stg:space-y-3 stg:rounded-lg stg:border stg:border-border stg:bg-card stg:p-4","aria-label":e,children:[(0,s.jsx)("h4",{className:"stg:m-0 stg:text-sm stg:font-semibold stg:text-foreground",children:e}),t]})}function ep({name:e,checked:t,onChange:a,label:r,disabled:n}){return(0,s.jsxs)("label",{className:"stg:flex stg:items-center stg:gap-1.5 stg:text-sm stg:text-foreground",children:[(0,s.jsx)("input",{type:"radio",className:eg,name:e,checked:t,onChange:a,disabled:n}),r]})}function ef({message:e}){return e?(0,s.jsx)("span",{className:"stg:block stg:text-xs stg:text-destructive",children:e}):null}function eb(e){return void 0===e?"":String(e)}function ej({className:e}){return(0,s.jsx)(u.EmptyState,{variant:"permission",className:e,title:"Platform operator access required",description:"Licenses are issued by Stigmer's platform operators and carry customer contracts and signed keys. Organization roles do not grant access; if you need it, ask a platform operator to grant you the platform operator role."})}var ev=e.i(326283),eN=e.i(891287),ey=e.i(740694);let ew="stg:size-3.5",ek="stg:grid stg:grid-cols-[minmax(0,2fr)_4rem_minmax(0,1.4fr)_9rem_6rem] stg:items-center stg:gap-3 stg:px-3 stg:py-2";function eS({className:e,now:h}){let x,p=(0,g.useResourceAvailable)(d.ApiResourceKind.license),f=function(e){let s=(0,K.useStigmer)(),a=e?.enabled??!0,{data:r,isLoading:n,isRefetching:i,error:l,refetch:o}=(0,V.useFetch)(a?()=>s.license.list((0,eN.create)(ey.ListLicensesInputSchema)).then(e=>e.entries):null,[a,s],null);return(0,t.useMemo)(()=>({licenses:r,isLoading:n,isRefetching:i,error:l,refetch:o}),[r,n,i,l,o])}({enabled:p}),b=function(){let e=(0,K.useStigmer)(),[s,a]=(0,t.useState)(!1),[r,n]=(0,t.useState)(null),i=(0,t.useCallback)(async s=>{a(!0),n(null);try{return await e.license.create(s)}catch(s){let e=(0,ev.toError)(s);throw n(e),e}finally{a(!1)}},[e.license]),l=(0,t.useCallback)(()=>n(null),[]);return(0,t.useMemo)(()=>({issue:i,isSubmitting:s,error:r,clearError:l}),[i,s,r,l])}(),[j,v]=(0,t.useState)({phase:"list"}),N=h??new Date,y=(0,t.useCallback)(()=>v({phase:"list"}),[]),k=(0,t.useCallback)(e=>{b.clearError(),v({phase:"issue",renewingId:e})},[b.clearError]);if(!p||f.error&&(0,l.isUnimplemented)(f.error))return(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-3",e),children:[(0,s.jsx)(eC,{}),(0,s.jsx)(m.CloudFeatureNotice,{children:"Licenses are issued from the Stigmer Cloud console. The server this console is connected to does not issue them; sign in to Stigmer Cloud to issue or renew a license."})]});if(f.isLoading)return(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-2",e),"aria-busy":"true",children:[(0,s.jsx)("div",{className:"stg:h-4 stg:w-40 stg:animate-pulse stg:rounded stg:bg-muted-subtle"}),Array.from({length:3},(e,t)=>(0,s.jsx)("div",{className:"stg:h-10 stg:animate-pulse stg:rounded-lg stg:bg-muted-subtle"},t))]});if(f.error)return(0,l.isPermissionDenied)(f.error)?(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-3",e),children:[(0,s.jsx)(eC,{}),(0,s.jsx)(ej,{})]}):(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-3",e),children:[(0,s.jsx)(eC,{}),(0,s.jsx)("p",{className:"stg:text-sm stg:text-destructive",role:"alert",children:(0,i.getUserMessage)(f.error)}),(0,s.jsx)(c.Button,{variant:"outline",onClick:f.refetch,children:"Try again"})]});let C="detail"===j.phase?j.issued:void 0,T=C&&!(f.licenses??[]).some(e=>e.metadata?.id===C.metadata?.id)?[...f.licenses??[],C]:f.licenses??[],L=function(e,s){let t=new Map;for(let s of e){let e=s.spec?.customer?.id;if(!e)continue;let a=t.get(e);(!a||A(s)>A(a))&&t.set(e,s)}let a=new Map;for(let r of e){let e=r.metadata?.id??"",n=t.get(r.spec?.customer?.id??""),i=n&&n!==r&&A(n)>A(r)?n:void 0;a.set(e,function(e,s,t){let a=w(e.spec?.expiresAt),r=a?S(a):"an unknown day";if(t){let e=w(t.spec?.expiresAt);return{timeState:s,renewedBy:t.metadata?.id,phase:"disabled",label:"Renewed",reason:e?`Renewed by a license covering through ${S(e)}`:"Renewed by a later license"}}switch(s){case o.LicenseState.valid:return{timeState:s,renewedBy:void 0,phase:"ready",label:"Active",reason:`Covered through ${r}`};case o.LicenseState.expiring:return{timeState:s,renewedBy:void 0,phase:"degraded",label:"Expiring",reason:`Covered through ${r}; renew before it lapses`};case o.LicenseState.grace:{let t=w(e.spec?.graceUntil);return{timeState:s,renewedBy:void 0,phase:"failed",label:"In grace",reason:t?`Coverage ended after ${r}; grace runs through ${S(t)}`:`Coverage ended after ${r}`}}case o.LicenseState.expired:return{timeState:s,renewedBy:void 0,phase:"disabled",label:"Expired",reason:`Coverage ended after ${r}`};default:return s}}(r,function(e,s){let t=w(e.spec?.expiresAt);if(!t)return o.LicenseState.expired;let a=w(e.spec?.graceUntil)??t,r=s.getTime();return r>=t.getTime()?r<a.getTime()?o.LicenseState.grace:o.LicenseState.expired:r>=t.getTime()-function(e,s){let t=w(e.status?.issuedAt);return t?Math.min(2592e6,.25*Math.max(0,s.getTime()-t.getTime())):2592e6}(e,t)?o.LicenseState.expiring:o.LicenseState.valid}(r,s),i))}return a}(T,N),U=e=>void 0===e?void 0:T.find(s=>s.metadata?.id===e);if("issue"===j.phase)return(0,s.jsx)(eh,{className:e,customers:function(e){let s=new Map;for(let t of e){let e=t.spec?.customer?.id;if(!e)continue;let a=s.get(e);if(!a){s.set(e,{latest:t,count:1});continue}a.count+=1,I(t)>I(a.latest)&&(a.latest=t)}let t=[];for(let{latest:e,count:a}of s.values()){let s=e.spec?.customer;s&&t.push({customer:s,licenseCount:a})}return t.sort((e,s)=>e.customer.displayName.localeCompare(s.customer.displayName))}(T),renewing:U(j.renewingId),now:N,isSubmitting:b.isSubmitting,submitError:b.error,onSubmit:e=>{b.issue(e).then(e=>{f.refetch(),v({phase:"detail",licenseId:e.metadata?.id??"",issued:e})},()=>{})},onCancel:y});if("detail"===j.phase){let t=U(j.licenseId);if(!t)return(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-2",e),children:[(0,s.jsx)("p",{className:"stg:text-xs stg:text-destructive",role:"alert",children:"This license is no longer in the list."}),(0,s.jsx)(c.Button,{variant:"outline",onClick:y,children:"Back to licenses"})]});let a=L.get(j.licenseId);return(0,s.jsx)(H,{className:e,license:t,issued:j.issued,standing:a,now:N,onBack:y,onRenew:a&&!a.renewedBy?()=>k(j.licenseId):void 0},j.licenseId)}let $=(x=e=>{let s=L.get(e.metadata?.id??"");if(!s||s.renewedBy)return 4;switch(s.timeState){case o.LicenseState.grace:return 0;case o.LicenseState.expiring:return 1;case o.LicenseState.valid:return 2;case o.LicenseState.expired:return 3;default:return s.timeState}},[...T].sort((e,s)=>{let t=x(e)-x(s);if(0!==t)return t;let a=A(e)-A(s);return x(e)>=3?-a:a})),E=function(e){let s=0,t=0,a=0;for(let r of e.values())r.renewedBy||(r.timeState===o.LicenseState.valid?s+=1:r.timeState===o.LicenseState.expiring?t+=1:r.timeState===o.LicenseState.grace&&(a+=1));return{active:s,expiring:t,grace:a}}(L);return(0,s.jsxs)("div",{className:(0,n.cn)("stg:space-y-3",e),children:[(0,s.jsx)(eC,{summary:T.length>0?`${E.active} active \xb7 ${E.expiring} expiring \xb7 ${E.grace} in grace`:void 0,action:T.length>0?(0,s.jsx)(c.Button,{icon:(0,s.jsx)(r.Plus,{className:ew,"aria-hidden":"true"}),onClick:()=>k(),children:"Issue license"}):void 0}),0===T.length?(0,s.jsx)(u.EmptyState,{variant:"first-use",icon:(0,s.jsx)(a.FileBadge,{className:"stg:size-10","aria-hidden":"true"}),title:"No licenses issued yet",description:"Issue the first one: name the customer, choose the term and set what it unlocks. Every license appears here, ordered by when it needs renewing.",action:{label:"Issue license",onClick:()=>k(),icon:(0,s.jsx)(r.Plus,{className:ew,"aria-hidden":"true"})}}):(0,s.jsx)("div",{className:"stg:overflow-x-auto stg:rounded-lg stg:border stg:border-border stg:bg-card",children:(0,s.jsxs)("div",{role:"table","aria-label":"Licenses",className:"stg:min-w-[42rem]",children:[(0,s.jsxs)("div",{role:"row",className:(0,n.cn)(ek,"stg:border-b stg:border-border stg:text-xs stg:font-medium stg:text-muted-foreground"),children:[(0,s.jsx)("span",{role:"columnheader",children:"Customer"}),(0,s.jsx)("span",{role:"columnheader",children:"Term"}),(0,s.jsx)("span",{role:"columnheader",children:"Entitlements"}),(0,s.jsx)("span",{role:"columnheader",children:"Covered through"}),(0,s.jsx)("span",{role:"columnheader",children:"Standing"})]}),(0,s.jsx)("div",{role:"rowgroup",children:$.map(e=>(0,s.jsx)(eT,{license:e,standing:L.get(e.metadata?.id??""),now:N,onOpen:()=>v({phase:"detail",licenseId:e.metadata?.id??""})},e.metadata?.id))})]})})]})}function eC({summary:e,action:t}){return(0,s.jsxs)("div",{className:"stg:flex stg:flex-wrap stg:items-center stg:justify-between stg:gap-3",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("h3",{className:"stg:m-0 stg:text-base stg:font-semibold stg:text-foreground",children:"Licenses"}),e&&(0,s.jsx)("p",{className:"stg:m-0 stg:text-sm stg:text-muted-foreground",children:e})]}),t]})}function eT({license:e,standing:t,now:a,onOpen:r}){var i;let l,c,d=e.spec?.customer,g=w(e.spec?.expiresAt),u=g?S(g):void 0,m=w(e.spec?.graceUntil),x=t?.phase==="disabled",p=t?.timeState===o.LicenseState.grace&&!t.renewedBy&&m;return(0,s.jsxs)("div",{role:"row",className:(0,n.cn)(ek,"stg:relative stg:border-b stg:border-border stg:text-xs stg:text-muted-foreground stg:last:border-b-0","stg:transition-colors stg:hover:bg-accent stg:motion-reduce:transition-none"),children:[(0,s.jsxs)("span",{role:"cell",className:"stg:min-w-0",children:[(0,s.jsx)("button",{type:"button",onClick:r,className:(0,n.cn)("stg:block stg:max-w-full stg:cursor-pointer stg:truncate stg:text-left stg:text-sm stg:font-medium",x?"stg:text-muted-foreground":"stg:text-foreground","stg:after:absolute stg:after:inset-0","stg:focus-visible:outline-none stg:focus-visible:after:ring-1 stg:focus-visible:after:ring-ring"),children:d?.displayName??"Unknown customer"}),(0,s.jsx)("span",{className:"stg:block stg:truncate",children:d?.contactEmail})]}),(0,s.jsx)("span",{role:"cell",children:e.spec?y(e.spec.term):"—"}),(0,s.jsx)("span",{role:"cell",className:"stg:min-w-0",children:(i=e.spec?.entitlements,l=i?.limits,c=i?.features.filter(v).length??0,[U(l?.maxUsers,"user"),U(l?.maxOrganizations,"organization"),0===c?"No features":$(c,"feature")]).map(e=>(0,s.jsx)("span",{className:"stg:block stg:truncate",children:e},e))}),(0,s.jsxs)("span",{role:"cell",className:"stg:min-w-0",children:[(0,s.jsx)("span",{className:(0,n.cn)("stg:block stg:text-sm",x?"stg:text-muted-foreground":"stg:text-foreground"),children:u??"Unknown"}),p?(0,s.jsx)("span",{className:"stg:block stg:font-medium stg:text-destructive",children:`Grace ends ${S(p)}`}):u&&(0,s.jsx)("span",{className:"stg:block",children:L(u,a)})]}),(0,s.jsx)("span",{role:"cell",className:"stg:relative stg:z-10 stg:justify-self-start",children:t&&(0,s.jsx)(h.StatusBadge,{phase:t.phase,label:t.label,tooltip:t.reason})})]})}e.s(["default",0,function(){return(0,s.jsx)(eS,{})}],261716)}]);
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,730938,e=>{"use strict";e.i(113024);var t,i,a=e.i(424407),r=e.i(304532),c=e.i(761867);let n=(0,a.fileDesc)("CjNhaS9zdGlnbWVyL2FnZW50aWMvYWdlbnRjaGFubmVsL3YxL21lc3NhZ2VfaW8ucHJvdG8SImFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEivQEKF1NlbmRDaGFubmVsTWVzc2FnZUlucHV0EhgKB2NoYW5uZWwYASABKAlCB7pIBHICGD8SFAoDb3JnGAIgASgJQge6SARyAhg/Eh0KCXJlY2lwaWVudBgDIAEoCUIKukgHcgUQARiAARJTCgdwYXlsb2FkGAQgASgLMjouYWkuc3RpZ21lci5hZ2VudGljLmFnZW50Y2hhbm5lbC52MS5DaGFubmVsT3V0Ym91bmRQYXlsb2FkQga6SAPIAQEisQEKFkNoYW5uZWxPdXRib3VuZFBheWxvYWQSPwoEdGV4dBgBIAEoCzIvLmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuVGV4dFBheWxvYWRIABJHCgh0ZW1wbGF0ZRgCIAEoCzIzLmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuVGVtcGxhdGVQYXlsb2FkSABCDQoEa2luZBIFukgCCAEiJwoLVGV4dFBheWxvYWQSGAoEYm9keRgBIAEoCUIKukgHcgUQARiAICKBAgoPVGVtcGxhdGVQYXlsb2FkEhgKBG5hbWUYASABKAlCCrpIB3IFEAEYgAQSGQoIbGFuZ3VhZ2UYAiABKAlCB7pIBHICGBASYQoKcGFyYW1ldGVycxgDIAMoCzJDLmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuVGVtcGxhdGVQYXlsb2FkLlBhcmFtZXRlcnNFbnRyeUIIukgFmgECEDISIwoRaGVhZGVyX2ltYWdlX2xpbmsYBCABKAlCCLpIBXIDGIAQGjEKD1BhcmFtZXRlcnNFbnRyeRILCgNrZXkYASABKAkSDQoFdmFsdWUYAiABKAk6AjgBIq0BChhTZW5kQ2hhbm5lbE1lc3NhZ2VPdXRwdXQSRwoHb3V0Y29tZRgBIAEoDjI2LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ2hhbm5lbFNlbmRPdXRjb21lEhsKE291dGJvdW5kX21lc3NhZ2VfaWQYAiABKAkSGwoTcHJvdmlkZXJfbWVzc2FnZV9pZBgDIAEoCRIOCgZkZXRhaWwYBCABKAkiYgoZTGlzdENoYW5uZWxUZW1wbGF0ZXNJbnB1dBIYCgdjaGFubmVsGAEgASgJQge6SARyAhg/EhQKA29yZxgCIAEoCUIHukgEcgIYPxIVCg1hcHByb3ZlZF9vbmx5GAMgASgIIlgKEENoYW5uZWxUZW1wbGF0ZXMSRAoHZW50cmllcxgBIAMoCzIzLmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuQ2hhbm5lbFRlbXBsYXRlIuYBCg9DaGFubmVsVGVtcGxhdGUSDAoEbmFtZRgBIAEoCRIQCghsYW5ndWFnZRgCIAEoCRIQCghjYXRlZ29yeRgDIAEoCRIOCgZzdGF0dXMYBCABKAkSGAoQcGFyYW1ldGVyX2Zvcm1hdBgFIAEoCRIXCg9wYXJhbWV0ZXJfbmFtZXMYBiADKAkSEQoJYm9keV90ZXh0GAcgASgJEhUKDWhlYWRlcl9mb3JtYXQYCCABKAkSGAoQcmVqZWN0aW9uX3JlYXNvbhgJIAEoCRIaChJ1bnN1cHBvcnRlZF9yZWFzb24YCiABKAkiHAoaTGlzdE1lc3NhZ2luZ0NoYW5uZWxzSW5wdXQiWgoRTWVzc2FnaW5nQ2hhbm5lbHMSRQoHZW50cmllcxgBIAMoCzI0LmFpLnN0aWdtZXIuYWdlbnRpYy5hZ2VudGNoYW5uZWwudjEuTWVzc2FnaW5nQ2hhbm5lbCI1ChBNZXNzYWdpbmdDaGFubmVsEg8KB2NoYW5uZWwYASABKAkSEAoIcHJvdmlkZXIYAiABKAkqYQoSQ2hhbm5lbFNlbmRPdXRjb21lEiQKIGNoYW5uZWxfc2VuZF9vdXRjb21lX3Vuc3BlY2lmaWVkEAASDAoIYWNjZXB0ZWQQARIKCgZxdWV1ZWQQAhILCgdyZWZ1c2VkEANiBnByb3RvMw",[c.file_buf_validate_validate]),o=(0,r.messageDesc)(n,5);(i=t||(t={}))[i.channel_send_outcome_unspecified=0]="channel_send_outcome_unspecified",i[i.accepted=1]="accepted",i[i.queued=2]="queued",i[i.refused=3]="refused",e.s(["ChannelSendOutcome",0,t,"ListChannelTemplatesInputSchema",0,o,"file_ai_stigmer_agentic_agentchannel_v1_message_io",0,n])},960511,e=>{"use strict";var t,i,a,r,c,n,o,l,s,d,u,p,g,h,A,m;e.i(113024);let b=(0,e.i(424407).fileDesc)("CiBhaS9zdGlnbWVyL2JpbGxpbmcvdjEvZW51bS5wcm90bxIVYWkuc3RpZ21lci5iaWxsaW5nLnYxKrYCCg9MZWRnZXJFbnRyeVR5cGUSIQodbGVkZ2VyX2VudHJ5X3R5cGVfdW5zcGVjaWZpZWQQABITCg9wdXJjaGFzZV9jcmVkaXQQARIWChJwcm9tb3Rpb25hbF9jcmVkaXQQAhIPCgt1c2FnZV9kZWJpdBADEhQKEHJlc2VydmF0aW9uX2hvbGQQBBIXChNyZXNlcnZhdGlvbl9yZWxlYXNlEAUSFQoRYWRqdXN0bWVudF9jcmVkaXQQBhIUChBhZGp1c3RtZW50X2RlYml0EAcSEwoPcmVmdW5kX3JldmVyc2FsEAgSEAoMZGlzcHV0ZV9ob2xkEAkSEwoPZGlzcHV0ZV9yZWxlYXNlEAoSEAoMZXhwaXJ5X2RlYml0EAsSGAoUYXV0b19yZWNoYXJnZV9jcmVkaXQQDCpECgpMZWRnZXJWaWV3EhsKF2xlZGdlcl92aWV3X3Vuc3BlY2lmaWVkEAASGQoVbGVkZ2VyX3ZpZXdfc3RhdGVtZW50EAEqZAoPQ3JlZGl0R3JhbnRLaW5kEiEKHWNyZWRpdF9ncmFudF9raW5kX3Vuc3BlY2lmaWVkEAASDQoJcHVyY2hhc2VkEAESDwoLcHJvbW90aW9uYWwQAhIOCgphZGp1c3RtZW50EAMqlQEKFEJpbGxpbmdBY2NvdW50U3RhdHVzEiYKImJpbGxpbmdfYWNjb3VudF9zdGF0dXNfdW5zcGVjaWZpZWQQABIaChZiaWxsaW5nX2FjY291bnRfYWN0aXZlEAESHQoZYmlsbGluZ19hY2NvdW50X3N1c3BlbmRlZBACEhoKFmJpbGxpbmdfYWNjb3VudF9jbG9zZWQQAyqeAQoRUmVzZXJ2YXRpb25TdGF0dXMSIgoecmVzZXJ2YXRpb25fc3RhdHVzX3Vuc3BlY2lmaWVkEAASFgoScmVzZXJ2YXRpb25fYWN0aXZlEAESGQoVcmVzZXJ2YXRpb25fZmluYWxpemVkEAISFwoTcmVzZXJ2YXRpb25fZXhwaXJlZBADEhkKFXJlc2VydmF0aW9uX2NhbmNlbGxlZBAEKocBChZFeGVjdXRpb25CaWxsaW5nU2lnbmFsEigKJGV4ZWN1dGlvbl9iaWxsaW5nX3NpZ25hbF91bnNwZWNpZmllZBAAEhYKEmNvbnRpbnVlX2V4ZWN1dGlvbhABEhcKE2xvd19iYWxhbmNlX3dhcm5pbmcQAhISCg5zdG9wX2V4ZWN1dGlvbhADKrMBChRDcmVkaXRQdXJjaGFzZVN0YXR1cxImCiJjcmVkaXRfcHVyY2hhc2Vfc3RhdHVzX3Vuc3BlY2lmaWVkEAASGwoXY3JlZGl0X3B1cmNoYXNlX3BlbmRpbmcQARIdChljcmVkaXRfcHVyY2hhc2VfY29tcGxldGVkEAISGgoWY3JlZGl0X3B1cmNoYXNlX2ZhaWxlZBADEhsKF2NyZWRpdF9wdXJjaGFzZV9leHBpcmVkEAQqlwEKF0F1dG9SZWNoYXJnZUV2ZW50U3RhdHVzEioKJmF1dG9fcmVjaGFyZ2VfZXZlbnRfc3RhdHVzX3Vuc3BlY2lmaWVkEAASGQoVYXV0b19yZWNoYXJnZV9wZW5kaW5nEAESGwoXYXV0b19yZWNoYXJnZV9zdWNjZWVkZWQQAhIYChRhdXRvX3JlY2hhcmdlX2ZhaWxlZBADYgZwcm90bzM");(s=t||(t={}))[s.ledger_entry_type_unspecified=0]="ledger_entry_type_unspecified",s[s.purchase_credit=1]="purchase_credit",s[s.promotional_credit=2]="promotional_credit",s[s.usage_debit=3]="usage_debit",s[s.reservation_hold=4]="reservation_hold",s[s.reservation_release=5]="reservation_release",s[s.adjustment_credit=6]="adjustment_credit",s[s.adjustment_debit=7]="adjustment_debit",s[s.refund_reversal=8]="refund_reversal",s[s.dispute_hold=9]="dispute_hold",s[s.dispute_release=10]="dispute_release",s[s.expiry_debit=11]="expiry_debit",s[s.auto_recharge_credit=12]="auto_recharge_credit",(d=i||(i={}))[d.unspecified=0]="unspecified",d[d.statement=1]="statement",(u=a||(a={}))[u.credit_grant_kind_unspecified=0]="credit_grant_kind_unspecified",u[u.purchased=1]="purchased",u[u.promotional=2]="promotional",u[u.adjustment=3]="adjustment",(p=r||(r={}))[p.billing_account_status_unspecified=0]="billing_account_status_unspecified",p[p.billing_account_active=1]="billing_account_active",p[p.billing_account_suspended=2]="billing_account_suspended",p[p.billing_account_closed=3]="billing_account_closed",(g=c||(c={}))[g.reservation_status_unspecified=0]="reservation_status_unspecified",g[g.reservation_active=1]="reservation_active",g[g.reservation_finalized=2]="reservation_finalized",g[g.reservation_expired=3]="reservation_expired",g[g.reservation_cancelled=4]="reservation_cancelled",(h=n||(n={}))[h.execution_billing_signal_unspecified=0]="execution_billing_signal_unspecified",h[h.continue_execution=1]="continue_execution",h[h.low_balance_warning=2]="low_balance_warning",h[h.stop_execution=3]="stop_execution",(A=o||(o={}))[A.credit_purchase_status_unspecified=0]="credit_purchase_status_unspecified",A[A.credit_purchase_pending=1]="credit_purchase_pending",A[A.credit_purchase_completed=2]="credit_purchase_completed",A[A.credit_purchase_failed=3]="credit_purchase_failed",A[A.credit_purchase_expired=4]="credit_purchase_expired",(m=l||(l={}))[m.auto_recharge_event_status_unspecified=0]="auto_recharge_event_status_unspecified",m[m.auto_recharge_pending=1]="auto_recharge_pending",m[m.auto_recharge_succeeded=2]="auto_recharge_succeeded",m[m.auto_recharge_failed=3]="auto_recharge_failed",e.s(["BillingAccountStatus",0,r,"LedgerEntryType",0,t,"LedgerView",0,i,"file_ai_stigmer_billing_v1_enum",0,b])},577817,400553,707125,e=>{"use strict";var t=e.i(424407),i=e.i(304532),a=e.i(125322),r=e.i(421415),c=e.i(988158),n=e.i(761867);let o=(0,t.fileDesc)("CidhaS9zdGlnbWVyL2FnZW50aWMvc2Vzc2lvbi92MS9hcGkucHJvdG8SHWFpLnN0aWdtZXIuYWdlbnRpYy5zZXNzaW9uLnYxIqsCCgdTZXNzaW9uEjEKC2FwaV92ZXJzaW9uGAEgASgJQhy6SBlyFwoVYWdlbnRpYy5zdGlnbWVyLmFpL3YxEhwKBGtpbmQYAiABKAlCDrpIC3IJCgdTZXNzaW9uEk0KCG1ldGFkYXRhGAMgASgLMjMuYWkuc3RpZ21lci5jb21tb25zLmFwaXJlc291cmNlLkFwaVJlc291cmNlTWV0YWRhdGFCBrpIA8gBARI4CgRzcGVjGAQgASgLMiouYWkuc3RpZ21lci5hZ2VudGljLnNlc3Npb24udjEuU2Vzc2lvblNwZWMSRgoGc3RhdHVzGAUgASgLMjYuYWkuc3RpZ21lci5jb21tb25zLmFwaXJlc291cmNlLkFwaVJlc291cmNlQXVkaXRTdGF0dXNiBnByb3RvMw",[a.file_ai_stigmer_agentic_session_v1_spec,r.file_ai_stigmer_commons_apiresource_metadata,c.file_ai_stigmer_commons_apiresource_status,n.file_buf_validate_validate]),l=(0,i.messageDesc)(o,0);e.s(["SessionSchema",0,l,"file_ai_stigmer_agentic_session_v1_api",0,o],400553);let s=(0,t.fileDesc)("CiZhaS9zdGlnbWVyL2FnZW50aWMvc2Vzc2lvbi92MS9pby5wcm90bxIdYWkuc3RpZ21lci5hZ2VudGljLnNlc3Npb24udjEiIgoJU2Vzc2lvbklkEhUKBXZhbHVlGAEgASgJQga6SAPIAQEiIAoHQWdlbnRJZBIVCgV2YWx1ZRgBIAEoCUIGukgDyAEBInQKC1Nlc3Npb25MaXN0EhMKC3RvdGFsX3BhZ2VzGAEgASgFEjcKB2VudHJpZXMYAiADKAsyJi5haS5zdGlnbWVyLmFnZW50aWMuc2Vzc2lvbi52MS5TZXNzaW9uEhcKD25leHRfcGFnZV90b2tlbhgDIAEoCSJgChNMaXN0U2Vzc2lvbnNSZXF1ZXN0EhoKCXBhZ2Vfc2l6ZRgBIAEoBUIHukgEGgIoABISCgpwYWdlX3Rva2VuGAIgASgJEgwKBHRhZ3MYAyADKAkSCwoDb3JnGAQgASgJIncKIkxpc3RTZXNzaW9uc0J5QWdlbnRJbnN0YW5jZVJlcXVlc3QSIQoRYWdlbnRfaW5zdGFuY2VfaWQYASABKAlCBrpIA8gBARIaCglwYWdlX3NpemUYAiABKAVCB7pIBBoCKAASEgoKcGFnZV90b2tlbhgDIAEoCSJqChxMaXN0U2Vzc2lvbnNCeUNoYW5uZWxSZXF1ZXN0EhoKCmNoYW5uZWxfaWQYASABKAlCBrpIA8gBARIaCglwYWdlX3NpemUYAiABKAVCB7pIBBoCKAASEgoKcGFnZV90b2tlbhgDIAEoCSJCChtVcGRhdGVTZXNzaW9uU3ViamVjdFJlcXVlc3QSEgoCaWQYASABKAlCBrpIA8gBARIPCgdzdWJqZWN0GAIgASgJYgZwcm90bzM",[o,n.file_buf_validate_validate]),d=(0,i.messageDesc)(s,0),u=(0,i.messageDesc)(s,5);e.s(["ListSessionsByChannelRequestSchema",0,u,"SessionIdSchema",0,d,"file_ai_stigmer_agentic_session_v1_io",0,s],577817);var p=e.i(247167);let g="https://api.stigmer.com/",h=null;async function A(){if(h)return h;let e=await m()??{apiUrl:p.default.env.NEXT_PUBLIC_API_URL??"http://localhost:7234",appUrl:p.default.env.NEXT_PUBLIC_APP_URL??"",authMode:W(p.default.env.NEXT_PUBLIC_AUTH_MODE),oidcIssuer:p.default.env.NEXT_PUBLIC_OIDC_ISSUER??"",oidcClientId:p.default.env.NEXT_PUBLIC_OIDC_CLIENT_ID??"",oidcAudience:p.default.env.NEXT_PUBLIC_OIDC_AUDIENCE??g};return"oidc"===e.authMode&&function(e){if(!e.oidcClientId)throw Error("This server requires sign-in, but no OIDC client is configured for the console. Set STIGMER_OIDC_CONSOLE_CLIENT_ID on the server (or NEXT_PUBLIC_OIDC_CLIENT_ID for a container build) to the public PKCE client you registered for the console at your identity provider.");let t=[];if(e.oidcIssuer||t.push("oidcIssuer (NEXT_PUBLIC_OIDC_ISSUER)"),e.oidcAudience||t.push("oidcAudience (NEXT_PUBLIC_OIDC_AUDIENCE)"),t.length>0)throw Error(`Auth mode is "oidc" but required fields are missing: ${t.join(", ")}. Check /config.json (container) or NEXT_PUBLIC_* env vars (.env).`)}(e),h=Object.freeze(e)}async function m(){try{let e=await fetch("/config.json");if(!e.ok)return null;let t=await e.json();return{apiUrl:b(t.apiUrl,window.location.origin),appUrl:b(t.appUrl,""),authMode:W(t.authMode),oidcIssuer:b(t.oidcIssuer,""),oidcClientId:b(t.oidcClientId,""),oidcAudience:b(t.oidcAudience,g)}}catch{return null}}function b(e,t){return"string"==typeof e&&e.length>0?e:t}function W(e){return"oidc"===e?"oidc":"disabled"}e.s(["getRuntimeConfig",0,function(){if(!h)throw Error("getRuntimeConfig() called before loadRuntimeConfig(). Ensure <ConfigGate> wraps the component tree.");return h},"loadRuntimeConfig",0,A],707125)},472402,e=>{"use strict";var t=e.i(707125);e.s(["getApiBaseUrl",0,function(){return(0,t.getRuntimeConfig)().apiUrl},"getAppBaseUrl",0,function(){let e=(0,t.getRuntimeConfig)().appUrl;return e?e.replace(/\/$/,""):window.location.origin}])},78946,e=>{"use strict";var t=e.i(910304),i=e.i(292558),a=e.i(891287),r=e.i(338300),c=e.i(621559),n=e.i(71268),o=e.i(534125),l=e.i(425285),s=e.i(973955),d=e.i(170255),u=e.i(459153),p=e.i(421415),g=e.i(85849),h=e.i(798525),A=e.i(301218);function m(e){return Object.assign((0,a.create)(s.ToolApprovalPolicySchema),(0,i.stripUndefined)({toolName:e.toolName,message:e.message,fromDestructiveHint:e.fromDestructiveHint}))}function b(e){var t,r,o;let l,d;e.env&&(l=Object.fromEntries(Object.entries(e.env).map(([e,t])=>[e,Object.assign((0,a.create)(c.EnvVarDeclarationSchema),(0,i.stripUndefined)({isSecret:t.isSecret,description:t.description,optional:t.optional}))])));let g=e.pinnedToolApprovals?.map(m),h=e.auth?(t=e.auth,d=(0,a.create)(s.McpServerAuthSchema),(t.oauthAppRef?.slug||t.oauthAppRef?.org)&&(d.oauthAppRef=(0,a.create)(u.ApiResourceReferenceSchema,{...t.oauthAppRef,kind:22})),void 0!==t.targetEnvVar&&(d.targetEnvVar=t.targetEnvVar),void 0!==t.tokenLifetimeHint&&(d.tokenLifetimeHint=t.tokenLifetimeHint),t.scopeHints&&(d.scopeHints=t.scopeHints),void 0!==t.discoveryUrl&&(d.discoveryUrl=t.discoveryUrl),void 0!==t.oauthOnly&&(d.oauthOnly=t.oauthOnly),d):void 0,A=Object.assign((0,a.create)(s.McpServerSpecSchema),(0,i.stripUndefined)({description:e.description,iconUrl:e.iconUrl,tags:e.tags,defaultEnabledTools:e.defaultEnabledTools,env:l,pinnedToolApprovals:g,repositoryUrl:e.repositoryUrl,githubStars:e.githubStars,auth:h}));return e.stdio?A.serverType={case:"stdio",value:(r=e.stdio,Object.assign((0,a.create)(s.StdioServerConfigSchema),(0,i.stripUndefined)({command:r.command,args:r.args,workingDir:r.workingDir})))}:e.http&&(A.serverType={case:"http",value:(o=e.http,Object.assign((0,a.create)(s.HttpServerConfigSchema),(0,i.stripUndefined)({url:o.url,headers:o.headers,queryParams:o.queryParams,timeoutSeconds:o.timeoutSeconds})))}),Object.assign((0,a.create)(n.McpServerSchema),{apiVersion:"agentic.stigmer.ai/v1",kind:"McpServer",metadata:Object.assign((0,a.create)(p.ApiResourceMetadataSchema),{...e.id&&{id:e.id},name:e.name,org:e.org,...e.slug&&{slug:e.slug},...e.labels&&{labels:e.labels},...e.visibility&&{visibility:e.visibility}}),spec:A})}function W(e){return{toolName:e.toolName||void 0,message:e.message||void 0,fromDestructiveHint:e.fromDestructiveHint||void 0}}e.s(["McpServerClient",0,class{command;query;search;constructor(e){this.command=(0,r.createClient)(o.McpServerCommandController,e),this.query=(0,r.createClient)(l.McpServerQueryController,e),this.search=(0,r.createClient)(A.SearchService,e)}async apply(e){try{return await this.command.apply(b(e))}catch(e){throw(0,t.wrapError)(e)}}async create(e){try{return await this.command.create(b(e))}catch(e){throw(0,t.wrapError)(e)}}async update(e){try{return await this.command.update(b(e))}catch(e){throw(0,t.wrapError)(e)}}async delete(e){try{return await this.command.delete((0,a.create)(u.ApiResourceDeleteInputSchema,{resourceId:e.resourceId,versionMessage:e.versionMessage,force:e.force}))}catch(e){throw(0,t.wrapError)(e)}}async updateVisibility(e){try{return await this.command.updateVisibility(e)}catch(e){throw(0,t.wrapError)(e)}}async connect(e){try{return await this.command.connect(e)}catch(e){throw(0,t.wrapError)(e)}}async startConnect(e){try{return await this.command.startConnect(e)}catch(e){throw(0,t.wrapError)(e)}}async initiateOAuthConnect(e){try{return await this.command.initiateOAuthConnect(e)}catch(e){throw(0,t.wrapError)(e)}}async completeOAuthConnect(e){try{return await this.command.completeOAuthConnect(e)}catch(e){throw(0,t.wrapError)(e)}}async disconnectOAuth(e){try{return await this.command.disconnectOAuth(e)}catch(e){throw(0,t.wrapError)(e)}}async setOrgOAuthApp(e){try{return await this.command.setOrgOAuthApp(e)}catch(e){throw(0,t.wrapError)(e)}}async deleteOrgOAuthApp(e){try{return await this.command.deleteOrgOAuthApp(e)}catch(e){throw(0,t.wrapError)(e)}}async get(e){try{return await this.query.get((0,a.create)(u.ApiResourceIdSchema,{value:e}))}catch(e){throw(0,t.wrapError)(e)}}async getByReference(e){try{return await this.query.getByReference((0,a.create)(u.ApiResourceReferenceSchema,{...e,kind:d.ApiResourceKind.mcp_server}))}catch(e){throw(0,t.wrapError)(e)}}async getOAuthGrantStatus(e){try{return await this.query.getOAuthGrantStatus(e)}catch(e){throw(0,t.wrapError)(e)}}async getOrgOAuthApp(e){try{return await this.query.getOrgOAuthApp(e)}catch(e){throw(0,t.wrapError)(e)}}async list(e){try{let t=await this.search.search((0,a.create)(h.SearchRequestSchema,{kinds:[d.ApiResourceKind.mcp_server],query:e.query,org:e.org,page:e.page?(0,a.create)(g.PageInfoSchema,e.page):void 0}));return{entries:t.entries,totalCount:t.totalCount,totalPages:t.totalPages}}catch(e){throw(0,t.wrapError)(e)}}},"buildMcpServerProto",0,b,"toMcpServerUpdateInput",0,function(e){var t,r,c;let n=e.metadata,o=e.spec??(0,a.create)(s.McpServerSpecSchema);return{id:n?.id||void 0,name:n?.name??"",slug:n?.slug||void 0,org:n?.org??"",labels:n?.labels&&Object.keys(n.labels).length>0?{...n.labels}:void 0,visibility:n?.visibility||void 0,description:o.description||void 0,iconUrl:o.iconUrl||void 0,tags:o.tags?.length?[...o.tags]:void 0,stdio:o.serverType?.case==="stdio"?{command:(t=o.serverType.value).command??"",args:t.args?.length?[...t.args]:void 0,workingDir:t.workingDir||void 0}:void 0,http:o.serverType?.case==="http"?{url:(r=o.serverType.value).url??"",headers:Object.keys(r.headers??{}).length>0?{...r.headers}:void 0,queryParams:Object.keys(r.queryParams??{}).length>0?{...r.queryParams}:void 0,timeoutSeconds:r.timeoutSeconds||void 0}:void 0,defaultEnabledTools:o.defaultEnabledTools?.length?[...o.defaultEnabledTools]:void 0,env:Object.keys(o.env??{}).length>0?Object.fromEntries(Object.entries(o.env).map(([e,t])=>[e,{isSecret:t.isSecret||void 0,description:t.description||void 0,optional:t.optional||void 0}])):void 0,pinnedToolApprovals:o.pinnedToolApprovals?.length?o.pinnedToolApprovals.map(W):void 0,repositoryUrl:o.repositoryUrl||void 0,githubStars:o.githubStars||void 0,auth:o.auth?(c=o.auth,{oauthAppRef:(0,i.toResourceRefInput)(c.oauthAppRef),targetEnvVar:c.targetEnvVar||void 0,tokenLifetimeHint:c.tokenLifetimeHint||void 0,scopeHints:c.scopeHints?.length?[...c.scopeHints]:void 0,discoveryUrl:c.discoveryUrl||void 0,oauthOnly:c.oauthOnly||void 0}):void 0}}])},992999,e=>{"use strict";var t=e.i(910304),i=e.i(292558),a=e.i(891287),r=e.i(338300),c=e.i(243176),n=e.i(779805),o=e.i(57674),l=e.i(538634),s=e.i(711961),d=e.i(621559),u=e.i(170255),p=e.i(459153),g=e.i(421415),h=e.i(85849),A=e.i(798525),m=e.i(301218);function b(e){return Object.assign((0,a.create)(s.ToolApprovalOverrideSchema),(0,i.stripUndefined)({toolName:e.toolName,requiresApproval:e.requiresApproval,message:e.message}))}function W(e){let t=(0,a.create)(s.McpServerUsageSchema);return(e.mcpServerRef?.slug||e.mcpServerRef?.org)&&(t.mcpServerRef=(0,a.create)(p.ApiResourceReferenceSchema,{...e.mcpServerRef,kind:44})),e.enabledTools&&(t.enabledTools=e.enabledTools),e.toolApprovalOverrides&&(t.toolApprovalOverrides=e.toolApprovalOverrides.map(b)),t}function Z(e){return Object.assign((0,a.create)(s.McpAccessSchema),(0,i.stripUndefined)({mcpServer:e.mcpServer,enabledTools:e.enabledTools}))}function E(e){let t=(0,a.create)(s.SubAgentSchema);return void 0!==e.name&&(t.name=e.name),void 0!==e.description&&(t.description=e.description),void 0!==e.instructions&&(t.instructions=e.instructions),e.mcpAccess&&(t.mcpAccess=e.mcpAccess.map(Z)),e.skillRefs&&(t.skillRefs=e.skillRefs.map(e=>(0,a.create)(p.ApiResourceReferenceSchema,{...e,kind:43}))),void 0!==e.modelOverride&&(t.modelOverride=e.modelOverride),t}function v(e){let t,r=e.mcpServerUsages?.map(W),n=e.skillRefs?.map(e=>(0,a.create)(p.ApiResourceReferenceSchema,{...e,kind:43})),o=e.subAgents?.map(E);return e.env&&(t=Object.fromEntries(Object.entries(e.env).map(([e,t])=>[e,Object.assign((0,a.create)(d.EnvVarDeclarationSchema),(0,i.stripUndefined)({isSecret:t.isSecret,description:t.description,optional:t.optional}))]))),Object.assign((0,a.create)(c.AgentSchema),{apiVersion:"agentic.stigmer.ai/v1",kind:"Agent",metadata:Object.assign((0,a.create)(g.ApiResourceMetadataSchema),{...e.id&&{id:e.id},name:e.name,org:e.org,...e.slug&&{slug:e.slug},...e.labels&&{labels:e.labels},...e.visibility&&{visibility:e.visibility}}),spec:Object.assign((0,a.create)(s.AgentSpecSchema),(0,i.stripUndefined)({description:e.description,iconUrl:e.iconUrl,instructions:e.instructions,mcpServerUsages:r,skillRefs:n,subAgents:o,env:t}))})}function S(e){return{toolName:e.toolName||void 0,requiresApproval:e.requiresApproval||void 0,message:e.message||void 0}}function R(e){return{mcpServerRef:(0,i.toResourceRefInput)(e.mcpServerRef)??{org:"",slug:""},enabledTools:e.enabledTools?.length?[...e.enabledTools]:void 0,toolApprovalOverrides:e.toolApprovalOverrides?.length?e.toolApprovalOverrides.map(S):void 0}}function V(e){return{mcpServer:e.mcpServer??"",enabledTools:e.enabledTools?.length?[...e.enabledTools]:void 0}}function I(e){return{name:e.name??"",description:e.description||void 0,instructions:e.instructions||void 0,mcpAccess:e.mcpAccess?.length?e.mcpAccess.map(V):void 0,skillRefs:(0,i.toResourceRefInputs)(e.skillRefs),modelOverride:e.modelOverride||void 0}}e.s(["AgentClient",0,class{command;query;search;constructor(e){this.command=(0,r.createClient)(n.AgentCommandController,e),this.query=(0,r.createClient)(l.AgentQueryController,e),this.search=(0,r.createClient)(m.SearchService,e)}async apply(e){try{return await this.command.apply(v(e))}catch(e){throw(0,t.wrapError)(e)}}async create(e){try{return await this.command.create(v(e))}catch(e){throw(0,t.wrapError)(e)}}async update(e){try{return await this.command.update(v(e))}catch(e){throw(0,t.wrapError)(e)}}async updateVisibility(e){try{return await this.command.updateVisibility(e)}catch(e){throw(0,t.wrapError)(e)}}async delete(e){try{return await this.command.delete((0,a.create)(o.AgentIdSchema,{value:e}))}catch(e){throw(0,t.wrapError)(e)}}async get(e){try{return await this.query.get((0,a.create)(o.AgentIdSchema,{value:e}))}catch(e){throw(0,t.wrapError)(e)}}async getByReference(e){try{return await this.query.getByReference((0,a.create)(p.ApiResourceReferenceSchema,{...e,kind:u.ApiResourceKind.agent}))}catch(e){throw(0,t.wrapError)(e)}}async list(e){try{let t=await this.search.search((0,a.create)(A.SearchRequestSchema,{kinds:[u.ApiResourceKind.agent],query:e.query,org:e.org,page:e.page?(0,a.create)(h.PageInfoSchema,e.page):void 0}));return{entries:t.entries,totalCount:t.totalCount,totalPages:t.totalPages}}catch(e){throw(0,t.wrapError)(e)}}},"buildAgentProto",0,v,"toAgentUpdateInput",0,function(e){let t=e.metadata,r=e.spec??(0,a.create)(s.AgentSpecSchema);return{id:t?.id||void 0,name:t?.name??"",slug:t?.slug||void 0,org:t?.org??"",labels:t?.labels&&Object.keys(t.labels).length>0?{...t.labels}:void 0,visibility:t?.visibility||void 0,description:r.description||void 0,iconUrl:r.iconUrl||void 0,instructions:r.instructions||void 0,mcpServerUsages:r.mcpServerUsages?.length?r.mcpServerUsages.map(R):void 0,skillRefs:(0,i.toResourceRefInputs)(r.skillRefs),subAgents:r.subAgents?.length?r.subAgents.map(I):void 0,env:Object.keys(r.env??{}).length>0?Object.fromEntries(Object.entries(r.env).map(([e,t])=>[e,{isSecret:t.isSecret||void 0,description:t.description||void 0,optional:t.optional||void 0}])):void 0}}])},203941,e=>{"use strict";e.i(113024);var t,i,a=e.i(424407);e.i(304532);var r=e.i(988158),c=e.i(761867);let n=(0,a.fileDesc)("CilhaS9zdGlnbWVyL2FnZW50aWMvcGx1Z2luL3YxL3N0YXR1cy5wcm90bxIcYWkuc3RpZ21lci5hZ2VudGljLnBsdWdpbi52MSLqAgoMUGx1Z2luU3RhdHVzEj8KBWF1ZGl0GGMgASgLMjAuYWkuc3RpZ21lci5jb21tb25zLmFwaXJlc291cmNlLkFwaVJlc291cmNlQXVkaXQSKAoGZGlnZXN0GAEgASgJQhi6SBVyEzIRXiR8XlthLWYwLTldezY0fSQSHAoUYXJ0aWZhY3Rfc3RvcmFnZV9rZXkYAiABKAkSOAoFc3RhdGUYAyABKA4yKS5haS5zdGlnbWVyLmFnZW50aWMucGx1Z2luLnYxLlBsdWdpblN0YXRlEg0KBWVycm9yGAQgASgJEkkKDG1hdGVyaWFsaXplZBgFIAEoCzIzLmFpLnN0aWdtZXIuYWdlbnRpYy5wbHVnaW4udjEuUGx1Z2luTWF0ZXJpYWxpemF0aW9uEj0KCHdhcm5pbmdzGAYgAygLMisuYWkuc3RpZ21lci5hZ2VudGljLnBsdWdpbi52MS5QbHVnaW5XYXJuaW5nIl8KFVBsdWdpbk1hdGVyaWFsaXphdGlvbhIOCgZza2lsbHMYASABKAUSEwoLbWNwX3NlcnZlcnMYAiABKAUSDgoGYWdlbnRzGAMgASgFEhEKCXdvcmtmbG93cxgEIAEoBSI8Cg1QbHVnaW5XYXJuaW5nEgwKBGtpbmQYASABKAkSDwoHbWVzc2FnZRgCIAEoCRIMCgRwYXRoGAMgASgJKnkKC1BsdWdpblN0YXRlEhwKGFBMVUdJTl9TVEFURV9VTlNQRUNJRklFRBAAEhsKF1BMVUdJTl9TVEFURV9JTlNUQUxMSU5HEAESFgoSUExVR0lOX1NUQVRFX1JFQURZEAISFwoTUExVR0lOX1NUQVRFX0ZBSUxFRBADYgZwcm90bzM",[r.file_ai_stigmer_commons_apiresource_status,c.file_buf_validate_validate]);(i=t||(t={}))[i.UNSPECIFIED=0]="UNSPECIFIED",i[i.INSTALLING=1]="INSTALLING",i[i.READY=2]="READY",i[i.FAILED=3]="FAILED",e.s(["PluginState",0,t,"file_ai_stigmer_agentic_plugin_v1_status",0,n])},44454,e=>{"use strict";var t=e.i(424407),i=e.i(304532),a=e.i(170255),r=e.i(302933),c=e.i(988158),n=e.i(761867),o=e.i(732303);let l=(0,t.fileDesc)("CiVhaS9zdGlnbWVyL2FnZW50aWMvcGx1Z2luL3YxL2lvLnByb3RvEhxhaS5zdGlnbWVyLmFnZW50aWMucGx1Z2luLnYxIiEKCFBsdWdpbklkEhUKBXZhbHVlGAEgASgJQga6SAPIAQEi9wIKEVB1c2hQbHVnaW5SZXF1ZXN0EhMKA29yZxgBIAEoCUIGukgDyAEBEhAKCGFydGlmYWN0GAIgASgMEhsKE2FydGlmYWN0X3VwbG9hZF9yZWYYAyABKAkSUwoKdmlzaWJpbGl0eRgEIAEoDjI1LmFpLnN0aWdtZXIuY29tbW9ucy5hcGlyZXNvdXJjZS5BcGlSZXNvdXJjZVZpc2liaWxpdHlCCLpIBYIBAhABEg8KB21lc3NhZ2UYBSABKAk6twG6SLMBGrABCiNwdXNoX3BsdWdpbl9yZXF1ZXN0LmFydGlmYWN0X3NvdXJjZRJJZXhhY3RseSBvbmUgb2YgYXJ0aWZhY3QgKGlubGluZSBieXRlcykgb3IgYXJ0aWZhY3RfdXBsb2FkX3JlZiBtdXN0IGJlIHNldBo+KHRoaXMuYXJ0aWZhY3Quc2l6ZSgpID4gMCkgIT0gKHRoaXMuYXJ0aWZhY3RfdXBsb2FkX3JlZiAhPSAnJykiWAokQ3JlYXRlUGx1Z2luQXJ0aWZhY3RVcGxvYWRVcmxSZXF1ZXN0EhMKA29yZxgBIAEoCUIGukgDyAEBEhsKCnNpemVfYnl0ZXMYAiABKANCB7pIBCICIAAiWAoXUGx1Z2luQXJ0aWZhY3RVcGxvYWRVcmwSCwoDdXJsGAEgASgJEhsKE2FydGlmYWN0X3VwbG9hZF9yZWYYAiABKAkSEwoLdHRsX3NlY29uZHMYAyABKAUihQEKDFBsdWdpbk1lbWJlchJNCgRraW5kGAEgASgOMj8uYWkuc3RpZ21lci5jb21tb25zLmFwaXJlc291cmNlLmFwaXJlc291cmNla2luZC5BcGlSZXNvdXJjZUtpbmQSCgoCaWQYAiABKAkSDAoEc2x1ZxgDIAEoCRIMCgRuYW1lGAQgASgJIlgKGUxpc3RQbHVnaW5NZW1iZXJzUmVzcG9uc2USOwoHbWVtYmVycxgBIAMoCzIqLmFpLnN0aWdtZXIuYWdlbnRpYy5wbHVnaW4udjEuUGx1Z2luTWVtYmVyImsKF0xpc3RQbHVnaW5WZXJzaW9uc0lucHV0EhMKA29yZxgBIAEoCUIGukgDyAEBEhQKBHNsdWcYAiABKAlCBrpIA8gBARISCgpwYWdlX3Rva2VuGAMgASgJEhEKCXBhZ2Vfc2l6ZRgEIAEoBSLtAQoSUGx1Z2luVmVyc2lvbkVudHJ5Eg4KBmRpZ2VzdBgBIAEoCRItCglwdXNoZWRfYXQYAiABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wEkgKCXB1c2hlZF9ieRgDIAEoCzI1LmFpLnN0aWdtZXIuY29tbW9ucy5hcGlyZXNvdXJjZS5BcGlSZXNvdXJjZUF1ZGl0QWN0b3ISCwoDdGFnGAQgASgJEhIKCmlzX2N1cnJlbnQYBSABKAgSDwoHbWVzc2FnZRgGIAEoCRIcChRhcnRpZmFjdF9zdG9yYWdlX2tleRgHIAEoCSKOAQoaTGlzdFBsdWdpblZlcnNpb25zUmVzcG9uc2USQgoIdmVyc2lvbnMYASADKAsyMC5haS5zdGlnbWVyLmFnZW50aWMucGx1Z2luLnYxLlBsdWdpblZlcnNpb25FbnRyeRIXCg9uZXh0X3BhZ2VfdG9rZW4YAiABKAkSEwoLdG90YWxfY291bnQYAyABKAViBnByb3RvMw",[a.file_ai_stigmer_commons_apiresource_apiresourcekind_api_resource_kind,r.file_ai_stigmer_commons_apiresource_enum,c.file_ai_stigmer_commons_apiresource_status,n.file_buf_validate_validate,o.file_google_protobuf_timestamp]),s=(0,i.messageDesc)(l,0),d=(0,i.messageDesc)(l,1),u=(0,i.messageDesc)(l,2),p=(0,i.messageDesc)(l,6);e.s(["CreatePluginArtifactUploadUrlRequestSchema",0,u,"ListPluginVersionsInputSchema",0,p,"PluginIdSchema",0,s,"PushPluginRequestSchema",0,d,"file_ai_stigmer_agentic_plugin_v1_io",0,l])},508535,e=>{"use strict";e.i(113024);var t,i,a=e.i(424407);e.i(304532);let r=(0,a.fileDesc)("CidhaS9zdGlnbWVyL2FnZW50aWMvcGx1Z2luL3YxL3NwZWMucHJvdG8SHGFpLnN0aWdtZXIuYWdlbnRpYy5wbHVnaW4udjEigwIKClBsdWdpblNwZWMSDAoEbmFtZRgBIAEoCRIPCgd2ZXJzaW9uGAIgASgJEhMKC2Rlc2NyaXB0aW9uGAMgASgJEjoKBmF1dGhvchgEIAEoCzIqLmFpLnN0aWdtZXIuYWdlbnRpYy5wbHVnaW4udjEuUGx1Z2luQXV0aG9yEhAKCGhvbWVwYWdlGAUgASgJEhIKCnJlcG9zaXRvcnkYBiABKAkSDwoHbGljZW5zZRgHIAEoCRIQCghrZXl3b3JkcxgIIAMoCRI8CgdkaWFsZWN0GAkgASgOMisuYWkuc3RpZ21lci5hZ2VudGljLnBsdWdpbi52MS5QbHVnaW5EaWFsZWN0IjgKDFBsdWdpbkF1dGhvchIMCgRuYW1lGAEgASgJEg0KBWVtYWlsGAIgASgJEgsKA3VybBgDIAEoCSqhAQoNUGx1Z2luRGlhbGVjdBIeChpQTFVHSU5fRElBTEVDVF9VTlNQRUNJRklFRBAAEiAKHFBMVUdJTl9ESUFMRUNUX0FHRU5UX1BMVUdJTlMQARIZChVQTFVHSU5fRElBTEVDVF9DTEFVREUQAhIZChVQTFVHSU5fRElBTEVDVF9DVVJTT1IQAxIYChRQTFVHSU5fRElBTEVDVF9DT0RFWBAEYgZwcm90bzM");(i=t||(t={}))[i.UNSPECIFIED=0]="UNSPECIFIED",i[i.AGENT_PLUGINS=1]="AGENT_PLUGINS",i[i.CLAUDE=2]="CLAUDE",i[i.CURSOR=3]="CURSOR",i[i.CODEX=4]="CODEX",e.s(["PluginDialect",0,t,"file_ai_stigmer_agentic_plugin_v1_spec",0,r])}]);