@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
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,52595,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976);function n({className:e}){return(0,t.jsx)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 3v10M3 8h10"})})}function i({className:e}){return(0,t.jsx)("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 4h12M5.333 4V2.667a1.333 1.333 0 0 1 1.334-1.334h2.666a1.333 1.333 0 0 1 1.334 1.334V4M12.667 4v9.333a1.333 1.333 0 0 1-1.334 1.334H4.667a1.333 1.333 0 0 1-1.334-1.334V4"})})}function o(){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:"stg:animate-spin","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}e.s(["InlineEditKeyValue",0,function({value:e,onSave:a,keyLabel:g="Key",showValue:l=!1,valueLabel:d="Value",showSecretToggle:c=!1,showOptionalToggle:u=!1,showDescription:x=!1,editing:m,onEditingChange:p,disabled:h,isSaving:f,error:v,className:b}){let[j,N]=(0,s.useState)(!1),y=m??j,k=(0,s.useCallback)(e=>{N(e),p?.(e)},[p]);(0,s.useEffect)(()=>{void 0!==m&&N(m)},[m]);let[C,w]=(0,s.useState)([...e]);(0,s.useCallback)(()=>{w([...e]),k(!0)},[e,k]);let S=(0,s.useCallback)(()=>{k(!1),w([...e])},[e,k]),E=(0,s.useCallback)(async()=>{let e=C.filter(e=>e.key.trim());await a(e)&&k(!1)},[C,a,k]),A=(0,s.useCallback)((e,t)=>{w(s=>s.map((s,r)=>r===e?{...s,...t}:s))},[]),O=(0,s.useCallback)(e=>{w(t=>t.filter((t,s)=>s!==e))},[]),L=(0,s.useCallback)(()=>{w(e=>[...e,{key:"",value:"",isSecret:!1,description:""}])},[]);return h||!y?(0,t.jsx)("div",{className:(0,r.cn)("stg:flex stg:flex-col",b),children:e.length>0?(0,t.jsx)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:e.map(e=>(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-3 stg:px-3 stg:py-2.5",children:[(0,t.jsx)("code",{className:"stg:shrink-0 stg:font-mono stg:text-sm stg:font-medium stg:text-foreground",children:e.key}),l&&(0,t.jsx)("span",{className:"stg:min-w-0 stg:break-all stg:font-mono stg:text-xs stg:text-muted-foreground",children:e.value}),c&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-muted-foreground",children:e.isSecret?"secret":"config"}),u&&e.optional&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-muted-foreground-subtle",children:"optional"}),e.description&&(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:e.description})]},e.key))}):(0,t.jsx)("p",{className:"stg:px-3 stg:py-3 stg:text-xs stg:text-muted-foreground stg:italic",children:"No entries"})}):(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:flex-col stg:gap-3",b),children:[C.map((e,s)=>(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-2 stg:rounded-md stg:border stg:border-border stg:bg-muted-faint stg:p-2.5",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-1 stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("input",{type:"text",value:e.key,onChange:e=>A(s,{key:e.target.value}),placeholder:g,className:(0,r.cn)("stg:rounded-md stg:border stg:border-border stg:bg-input-bg stg:px-2 stg:py-1 stg:font-mono stg:text-sm stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring")}),l&&(0,t.jsx)("input",{type:"text",value:e.value,onChange:e=>A(s,{value:e.target.value}),placeholder:d,className:(0,r.cn)("stg:rounded-md stg:border stg:border-border stg:bg-input-bg stg:px-2 stg:py-1 stg:font-mono stg:text-sm stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring")}),x&&(0,t.jsx)("input",{type:"text",value:e.description??"",onChange:e=>A(s,{description:e.target.value}),placeholder:"Description",className:(0,r.cn)("stg:rounded-md stg:border stg:border-border stg:bg-input-bg stg:px-2 stg:py-1 stg:text-xs stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring")}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-3",children:[c&&(0,t.jsxs)("label",{className:"stg:inline-flex stg:items-center stg:gap-1.5 stg:text-xs stg:text-muted-foreground stg:cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",checked:e.isSecret??!1,onChange:e=>A(s,{isSecret:e.target.checked}),className:"stg:size-3.5 stg:rounded stg:border-border"}),"Secret"]}),u&&(0,t.jsxs)("label",{className:"stg:inline-flex stg:items-center stg:gap-1.5 stg:text-xs stg:text-muted-foreground stg:cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",checked:e.optional??!1,onChange:e=>A(s,{optional:e.target.checked}),className:"stg:size-3.5 stg:rounded stg:border-border"}),"Optional"]})]})]}),(0,t.jsx)("button",{type:"button",onClick:()=>O(s),"aria-label":`Remove ${e.key||"entry"}`,className:(0,r.cn)("stg:mt-1 stg:inline-flex stg:size-6 stg:items-center stg:justify-center stg:rounded-md stg:text-muted-foreground","stg:hover:bg-destructive-subtle stg:hover:text-destructive","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:(0,t.jsx)(i,{className:"stg:size-3.5"})})]},s)),(0,t.jsxs)("button",{type:"button",onClick:L,className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1 stg:rounded-md stg:px-2.5 stg:py-1.5 stg:text-xs stg:font-medium","stg:border stg:border-dashed stg:border-border stg:text-muted-foreground","stg:hover:border-muted-foreground stg:hover:text-foreground stg:hover:bg-muted-subtle","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:transition-colors"),children:[(0,t.jsx)(n,{className:"stg:size-3"}),"Add entry"]}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-end stg:gap-1.5",children:[(0,t.jsx)("button",{type:"button",onClick:S,disabled:f,className:(0,r.cn)("stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:"Cancel"}),(0,t.jsxs)("button",{type:"button",onClick:E,disabled:f,className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:[f&&(0,t.jsx)(o,{}),"Save changes"]})]}),v&&(0,t.jsx)("p",{className:"stg:px-1 stg:text-xs stg:text-destructive",role:"alert",children:v})]})}])},81346,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976);function n({className:e}){return(0,t.jsx)("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:"M11.5 1.5a2.121 2.121 0 0 1 3 3L5 14l-4 1 1-4Z"})})}function i({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 3.5 3.5 6.5-8"})})}function o({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:"m4 4 8 8M12 4l-8 8"})})}function a({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:"2",y:"2",width:"12",height:"12",rx:"1.5"}),(0,t.jsx)("circle",{cx:"5.5",cy:"5.5",r:"1"}),(0,t.jsx)("path",{d:"m14 10.5-3-3L4 14"})]})}function g(){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:"stg:animate-spin","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}e.s(["InlineEditImage",0,function({value:e,onSave:l,fallback:d,size:c="md",disabled:u,isSaving:x,error:m,className:p}){let[h,f]=(0,s.useState)(!1),[v,b]=(0,s.useState)(e),[j,N]=(0,s.useState)(null),y=(0,s.useRef)(null);(0,s.useEffect)(()=>{h&&(b(e),N(null),requestAnimationFrame(()=>y.current?.focus()))},[h,e]);let k=(0,s.useCallback)(async()=>{let t=v.trim();t===e?f(!1):t&&!function(e){try{return new URL(e),!0}catch{return!1}}(t)?N("Enter a valid URL"):await l(t)&&f(!1)},[v,e,l]),C=(0,s.useCallback)(()=>{f(!1),b(e),N(null)},[e]),w=(0,s.useCallback)(e=>{"Enter"===e.key?(e.preventDefault(),k()):"Escape"===e.key&&C()},[k,C]),S="sm"===c?"stg:size-6":"stg:size-8",E=j||m;return u||!h?(0,t.jsx)("div",{className:(0,r.cn)("stg:group/inline-edit stg:inline-flex",p),children:(0,t.jsxs)("button",{type:"button",onClick:()=>{u||f(!0)},disabled:u,className:(0,r.cn)("stg:relative stg:rounded-md stg:p-0.5 stg:transition-colors",!u&&"stg:hover:bg-accent-hover stg:cursor-pointer","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),"aria-label":"Change icon",children:[e?(0,t.jsx)("img",{src:e,alt:"",className:(0,r.cn)(S,"stg:shrink-0 stg:rounded stg:object-cover")}):d??(0,t.jsx)(a,{className:(0,r.cn)(S,"stg:text-muted-foreground")}),!u&&(0,t.jsx)("span",{className:"stg:absolute stg:-bottom-0.5 stg:-right-0.5 stg:flex stg:size-4 stg:items-center stg:justify-center stg:rounded-full stg:bg-muted stg:text-muted-foreground stg:opacity-0 stg:transition-opacity stg:group-hover/inline-edit:opacity-100",children:(0,t.jsx)(n,{className:"stg:size-2.5"})})]})}):(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:flex-col stg:gap-1",p),children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)("input",{ref:y,type:"url",value:v,onChange:e=>{b(e.target.value),N(null)},onKeyDown:w,disabled:x,placeholder:"https://example.com/icon.png",className:(0,r.cn)("stg:flex-1 stg:rounded-md stg:border stg:border-border stg:bg-input-bg stg:px-2 stg:py-1 stg:text-sm stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring","stg:disabled:opacity-50",E&&"stg:border-destructive")}),(0,t.jsx)("button",{type:"button",onClick:k,disabled:x,"aria-label":"Save",className:(0,r.cn)("stg:inline-flex stg:size-7 stg:items-center stg:justify-center stg:rounded-md","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:x?(0,t.jsx)(g,{}):(0,t.jsx)(i,{className:"stg:size-3.5"})}),(0,t.jsx)("button",{type:"button",onClick:C,disabled:x,"aria-label":"Cancel",className:(0,r.cn)("stg:inline-flex stg:size-7 stg:items-center stg:justify-center stg:rounded-md","stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:(0,t.jsx)(o,{className:"stg:size-3.5"})}),v&&(0,t.jsx)("button",{type:"button",onClick:()=>b(""),disabled:x,"aria-label":"Clear",className:"stg:text-xs stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground",children:"Clear"})]}),E&&(0,t.jsx)("p",{className:"stg:px-1 stg:text-xs stg:text-destructive",role:"alert",children:E})]})}])},521557,e=>{"use strict";e.s(["isUnimplemented",0,function(e){if(!e||"object"!=typeof e)return!1;if("connectCode"in e&&12===e.connectCode)return!0;let t=e.message??"";return t.includes("[unimplemented]")||t.includes("UNIMPLEMENTED")}])},141249,e=>{"use strict";var t=e.i(843476);e.s(["PluginIcon",0,function({className:e}){return(0,t.jsx)("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:"M6 2.5a1.5 1.5 0 0 1 3 0V4h2.5A1.5 1.5 0 0 1 13 5.5V8h-1.5a1.5 1.5 0 0 0 0 3H13v2.5a1.5 1.5 0 0 1-1.5 1.5H9v-1.5a1.5 1.5 0 0 0-3 0V15H3.5A1.5 1.5 0 0 1 2 13.5V11h1.5a1.5 1.5 0 0 0 0-3H2V5.5A1.5 1.5 0 0 1 3.5 4H6V2.5Z"})})}])},292420,e=>{"use strict";var t=e.i(843476),s=e.i(893976),r=e.i(141249);e.s(["ManagedByPluginNotice",0,function({plugin:e,onPluginClick:n,className:i}){if(null===e)return null;let o=e.metadata,a=o?.name||o?.slug||"a plugin",g=o?{org:o.org,slug:o.slug}:null;return(0,t.jsxs)("div",{role:"note",className:(0,s.cn)("stg:flex stg:items-start stg:gap-2 stg:rounded-md stg:border stg:border-border stg:bg-muted stg:px-3 stg:py-2 stg:text-sm stg:text-foreground",i),children:[(0,t.jsx)(r.PluginIcon,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0 stg:text-muted-foreground"}),(0,t.jsxs)("p",{children:["Installed by the plugin"," ",n&&g?(0,t.jsx)("button",{type:"button",onClick:()=>n(g),className:"stg:cursor-pointer stg:font-medium stg:underline stg:decoration-dotted stg:underline-offset-2 stg:hover:text-primary",children:a}):(0,t.jsx)("span",{className:"stg:font-medium",children:a}),". To change it, change the plugin and push it again; to customise, compose your own agent over its skills and servers."]})]})}])},473489,e=>{"use strict";var t=e.i(271645),s=e.i(910304),r=e.i(586108),n=e.i(583093);let i="stigmer.ai/plugin";e.s(["PLUGIN_LABEL",0,i,"useManagingPlugin",0,function(e){let o=(0,r.useStigmer)(),a=e?.[i]??null,{data:g,isLoading:l}=(0,n.useFetch)(a?async()=>{try{return await o.plugin.get(a)}catch(e){if((0,s.isNotFound)(e))return null;throw e}}:null,[a,o],null);return(0,t.useMemo)(()=>({plugin:g,isLoading:l}),[g,l])}])},244990,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976);function n({className:e}){return(0,t.jsx)("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:"M11.5 1.5a2.121 2.121 0 0 1 3 3L5 14l-4 1 1-4Z"})})}function i({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 3.5 3.5 6.5-8"})})}function o({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:"m4 4 8 8M12 4l-8 8"})})}function a(){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:"stg:animate-spin","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}e.s(["InlineEditText",0,function({value:e,onSave:g,placeholder:l="Click to edit",validate:d,variant:c="default",disabled:u,isSaving:x,error:m,className:p}){let[h,f]=(0,s.useState)(!1),[v,b]=(0,s.useState)(e),[j,N]=(0,s.useState)(null),y=(0,s.useRef)(null);(0,s.useEffect)(()=>{h&&(b(e),N(null),requestAnimationFrame(()=>y.current?.focus()))},[h,e]);let k=(0,s.useCallback)(async()=>{let t=v.trim();if(t===e)return void f(!1);if(d){let e=d(t);if(e)return void N(e)}await g(t)&&f(!1)},[v,e,d,g]),C=(0,s.useCallback)(()=>{f(!1),b(e),N(null)},[e]),w=(0,s.useCallback)(e=>{"Enter"===e.key?(e.preventDefault(),k()):"Escape"===e.key&&C()},[k,C]),S=j||m;return u||!h?(0,t.jsx)("div",{className:(0,r.cn)("stg:group/inline-edit",p),children:(0,t.jsxs)("button",{type:"button",onClick:()=>{u||f(!0)},disabled:u,className:(0,r.cn)("stg:inline-flex stg:w-full stg:items-center stg:gap-1.5 stg:rounded-md stg:px-1.5 stg:py-0.5 stg:text-left stg:transition-colors",!u&&"stg:hover:bg-accent-hover stg:cursor-pointer",u&&"stg:cursor-default","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-inset stg:focus-visible:ring-ring"),children:[(0,t.jsx)("span",{className:(0,r.cn)("stg:min-w-0 stg:truncate","heading"===c?"stg:text-lg stg:font-semibold stg:text-foreground":"stg:text-sm stg:text-foreground",!e&&"stg:text-muted-foreground stg:italic"),children:e||l}),!u&&(0,t.jsx)(n,{className:"stg:size-3 stg:shrink-0 stg:text-muted-foreground stg:opacity-0 stg:transition-opacity stg:group-hover/inline-edit:opacity-100"})]})}):(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:flex-col stg:gap-1",p),children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)("input",{ref:y,type:"text",value:v,onChange:e=>{b(e.target.value),N(null)},onKeyDown:w,disabled:x,placeholder:l,className:(0,r.cn)("stg:flex-1 stg:rounded-md stg:border stg:border-border stg:bg-input-bg stg:px-2 stg:py-1 stg:text-sm stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring","stg:disabled:opacity-50","heading"===c&&"stg:text-lg stg:font-semibold",S&&"stg:border-destructive")}),(0,t.jsx)("button",{type:"button",onClick:k,disabled:x,"aria-label":"Save",className:(0,r.cn)("stg:inline-flex stg:size-7 stg:items-center stg:justify-center stg:rounded-md","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:x?(0,t.jsx)(a,{}):(0,t.jsx)(i,{className:"stg:size-3.5"})}),(0,t.jsx)("button",{type:"button",onClick:C,disabled:x,"aria-label":"Cancel",className:(0,r.cn)("stg:inline-flex stg:size-7 stg:items-center stg:justify-center stg:rounded-md","stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent stg:hover:text-accent-foreground","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:(0,t.jsx)(o,{className:"stg:size-3.5"})})]}),S&&(0,t.jsx)("p",{className:"stg:px-1 stg:text-xs stg:text-destructive",role:"alert",children:S})]})}])},674542,e=>{"use strict";var t=e.i(843476),s=e.i(271645),r=e.i(893976),n=e.i(610595),i=e.i(17616),o=e.i(336973),a=e.i(498931),g=e.i(727996),l=e.i(586108),d=e.i(326283),c=e.i(78946),u=e.i(862645),x=e.i(153158),m=e.i(168197),p=e.i(844533),h=e.i(801731),f=e.i(793907),v=e.i(388894),b=e.i(651424),j=e.i(379410);function N({providerName:e,vendorDocsUrl:i,onSubmit:o,onCancel:a,isSubmitting:g,error:l,className:d}){let[c,u]=(0,s.useState)(""),[x,m]=(0,s.useState)(""),[p,h]=(0,s.useState)(!1),f=(0,s.useId)(),v=`${f}-client-id`,b=`${f}-client-secret`,w=c.trim().length>0&&x.trim().length>0,S=(0,s.useCallback)(async e=>{e.preventDefault(),w&&!g&&await o(c.trim(),x.trim())},[w,g,o,c,x]);return(0,t.jsxs)("form",{onSubmit:S,className:(0,r.cn)("stg:flex stg:flex-col stg:gap-4",d),children:[(0,t.jsxs)("div",{className:"stg:space-y-1.5",children:[(0,t.jsxs)("p",{className:"stg:text-sm stg:text-foreground",children:["Register an OAuth app with"," ",(0,t.jsx)("span",{className:"stg:font-medium",children:e})," and enter your credentials below."]}),i&&(0,t.jsxs)("a",{href:i,target:"_blank",rel:"noopener noreferrer",className:"stg:inline-flex stg:items-center stg:gap-1 stg:text-xs stg:text-primary stg:underline stg:decoration-primary/40 stg:underline-offset-2 stg:hover:decoration-primary",children:[e," OAuth app registration",(0,t.jsx)(y,{className:"stg:size-3 stg:shrink-0"})]})]}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-3",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("label",{htmlFor:v,className:"stg:text-xs stg:font-medium stg:text-foreground",children:"Client ID"}),(0,t.jsx)("input",{id:v,type:"text",value:c,onChange:e=>u(e.target.value),disabled:g,required:!0,"aria-required":!0,autoComplete:"off",autoFocus:!0,placeholder:"e.g. 1234567890abcdef",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-2 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50")})]}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("label",{htmlFor:b,className:"stg:text-xs stg:font-medium stg:text-foreground",children:"Client Secret"}),(0,t.jsxs)("div",{className:"stg:relative",children:[(0,t.jsx)("input",{id:b,type:p?"text":"password",value:x,onChange:e=>m(e.target.value),disabled:g,required:!0,"aria-required":!0,autoComplete:"off",placeholder:"Your client secret",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:pr-8 stg:text-xs stg:text-foreground","stg:placeholder:text-muted-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50")}),(0,t.jsx)("button",{type:"button",onClick:()=>h(e=>!e),disabled:g,className:(0,r.cn)("stg:absolute stg:right-2 stg:top-1/2 stg:-translate-y-1/2","stg:text-muted-foreground stg:hover:text-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-50"),"aria-label":p?"Hide client secret":"Show client secret",tabIndex:-1,children:p?(0,t.jsx)(C,{}):(0,t.jsx)(k,{})})]})]})]}),l&&(0,t.jsx)("div",{role:"alert",className:"stg:rounded-md stg:border stg:border-destructive/30 stg:bg-destructive-subtle stg:px-2.5 stg:py-2 stg:text-xs stg:text-destructive",children:(0,n.getUserMessage)(l)}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-end stg:gap-2",children:[(0,t.jsx)("button",{type:"button",onClick:a,disabled:g,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"}),(0,t.jsxs)("button",{type:"submit",disabled:!w||g,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:[g&&(0,t.jsx)(j.SpinnerIcon,{size:12}),"Save"]})]})]})}function y({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:"M6 3.5H3.5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V10"}),(0,t.jsx)("path",{d:"M9.5 2.5h4v4"}),(0,t.jsx)("path",{d:"M13.5 2.5 8 8"})]})}function k(){return(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M1.5 8s2.5-4.5 6.5-4.5S14.5 8 14.5 8s-2.5 4.5-6.5 4.5S1.5 8 1.5 8z"}),(0,t.jsx)("circle",{cx:"8",cy:"8",r:"2"})]})}function C(){return(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M6.59 6.59a2 2 0 0 0 2.82 2.82"}),(0,t.jsx)("path",{d:"M10.73 10.73A6.5 6.5 0 0 1 8 12.5c-4 0-6.5-4.5-6.5-4.5a11.5 11.5 0 0 1 3.77-3.73"}),(0,t.jsx)("path",{d:"M5.71 3.56A6.3 6.3 0 0 1 8 3.5c4 0 6.5 4.5 6.5 4.5a11.5 11.5 0 0 1-1.28 1.73"}),(0,t.jsx)("path",{d:"M2 2l12 12"})]})}var w=e.i(170255),S=e.i(476007),E=e.i(188482),A=e.i(468806),O=e.i(351240),L=e.i(758960),M=e.i(484763),T=e.i(927056),D=e.i(668093),B=e.i(652337),H=e.i(244990),z=e.i(261722),P=e.i(81346);function I({value:e,options:n,onSave:i,disabled:o,isSaving:a,error:g,className:l}){let[d,c]=(0,s.useState)(!1),u=(0,s.useRef)(null),x=n.find(t=>t.value===e)?.label??e;(0,s.useEffect)(()=>{if(!d)return;let e=e=>{u.current&&!u.current.contains(e.target)&&c(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[d]);let m=(0,s.useCallback)(async t=>{t===e?c(!1):await i(t)&&c(!1)},[e,i]);return o||!d?(0,t.jsx)("div",{className:(0,r.cn)("stg:group/inline-edit",l),children:(0,t.jsxs)("button",{type:"button",onClick:()=>{o||c(!0)},disabled:o,className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-1.5 stg:py-0.5 stg:text-left stg:transition-colors",!o&&"stg:hover:bg-accent-hover stg:cursor-pointer","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-inset stg:focus-visible:ring-ring"),children:[(0,t.jsx)("span",{className:"stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:font-mono stg:text-xs stg:font-medium stg:text-foreground",children:x}),!o&&(0,t.jsx)(U,{className:"stg:size-3 stg:shrink-0 stg:text-muted-foreground stg:opacity-0 stg:transition-opacity stg:group-hover/inline-edit:opacity-100"})]})}):(0,t.jsxs)("div",{ref:u,className:(0,r.cn)("stg:flex stg:flex-col stg:gap-1",l),children:[(0,t.jsx)("div",{className:"stg:rounded-lg stg:border stg:border-border stg:bg-background stg:p-1",role:"radiogroup",children:n.map(s=>(0,t.jsxs)("button",{type:"button",role:"radio","aria-checked":s.value===e,disabled:a,onClick:()=>m(s.value),className:(0,r.cn)("stg:flex stg:w-full stg:items-start stg:gap-2 stg:rounded-md stg:px-2.5 stg:py-1.5 stg:text-left stg:transition-colors",s.value===e?"stg:bg-muted-subtle stg:text-foreground":"stg:hover:bg-accent-hover stg:text-foreground","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-inset stg:focus-visible:ring-ring"),children:[(0,t.jsx)("div",{className:(0,r.cn)("stg:mt-0.5 stg:flex stg:size-4 stg:shrink-0 stg:items-center stg:justify-center stg:rounded-full stg:border",s.value===e?"stg:border-primary stg:bg-primary":"stg:border-muted-foreground"),children:s.value===e&&(0,t.jsx)("div",{className:"stg:size-1.5 stg:rounded-full stg:bg-primary-foreground"})}),(0,t.jsxs)("div",{className:"stg:min-w-0 stg:flex-1",children:[(0,t.jsx)("span",{className:"stg:text-sm stg:font-medium",children:s.label}),s.description&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-xs stg:text-muted-foreground",children:s.description})]}),a&&s.value!==e&&(0,t.jsx)(R,{})]},s.value))}),g&&(0,t.jsx)("p",{className:"stg:px-1 stg:text-xs stg:text-destructive",role:"alert",children:g})]})}function U({className:e}){return(0,t.jsx)("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:"m4 6 4 4 4-4"})})}function R(){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:"stg:animate-spin","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}var V=e.i(52595),_=e.i(292420),W=e.i(473489);function F({isConnecting:e,connectionError:i,connectionErrorMessage:a,onConnect:g,onClearConnectionError:l,hasDiscoveredTools:d,isOAuthStranded:c,credentialsLoading:u,oauthPhase:x,authMode:m,isOAuthConnected:p,connectionHealth:h,canDisconnect:v,onDisconnect:b,isDisconnecting:j,disconnectError:N,onClearDisconnectError:y,serverName:k,accessTokenExpiresAt:C,tokenLifetimeHint:w,isVendorApprovalPending:S,isVendorApprovalBlocked:E,vendorApprovalDocsUrl:A,canBringOwnApp:O,isOrgOAuthApp:L,onBringOwnApp:M,onRemoveOrgApp:T,isRemovingOrgApp:D,removeOrgAppError:B,onClearRemoveOrgAppError:H,manualEntrySupported:z,manualOverride:P,onManualOverride:I,onBackToOAuth:U,onCancelOAuth:R}){let[V,_]=(0,s.useState)("idle"),[W,q]=(0,s.useState)("idle"),K="initiating"===x||"awaiting-callback"===x||"completing"===x||"connecting"===x,X="oauth"===m&&!p&&!P,Z=h===o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_TOKEN_EXPIRED,Y=E&&X&&!L,G=e||K||j||D,J=K?$(x):e?"Connecting...":L&&X?"Sign in with your app":X||Z?"Sign in to connect":c?"Discover tools":d?"Reconnect":"Connect",Q=K||e?(0,t.jsx)(eN,{}):X||Z?(0,t.jsx)(eh,{className:"stg:size-3.5"}):d?(0,t.jsx)(eu,{className:"stg:size-3.5"}):(0,t.jsx)(ec,{className:"stg:size-3.5"}),ee=(()=>{if("oauth"===m&&p){if(c)return"Signed in — tools not discovered yet";let e=function(e,t,s){switch(e){case o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_HEALTHY:{let e=function(e){if(e===BigInt(0))return null;let t=e-BigInt(Math.floor(Date.now()/1e3));if(t<=BigInt(0))return"Token expired";let s=Number(t/BigInt(60));if(s<1)return"Expires in <1 min";if(s<60)return`Expires in ${s} min`;let r=Math.floor(s/60);if(r<24)return`Expires in ${r}h ${s%60}m`;let n=Math.floor(r/24);return`Expires in ${n}d`}(t);if(e)return`Tokens refresh automatically \u00B7 ${e}`;let r=s&&"never"!==s?` \u00B7 Session lasts ~${s}`:"";return`Tokens refresh automatically${r}`}case o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_TOKEN_EXPIRED_REFRESHABLE:return"Will refresh automatically on next use";case o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_TOKEN_EXPIRED:return"Token expired — sign in again to reconnect";default:return"Not connected yet"}}(h,C,w);return L?`${e} \u00B7 Using your OAuth app`:e}return L&&X?"Using your OAuth app":P?"Entering token manually":d?"Connected":"Not connected yet"})(),et=function(e,t){if(t)return{pillClass:"stg:bg-amber-500/10 stg:text-amber-600 stg:dark:text-amber-400",dotClass:"stg:bg-amber-500",label:"Pending approval"};switch(e){case o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_HEALTHY:return{pillClass:"stg:bg-success/10 stg:text-success",dotClass:"stg:bg-success",label:"Connected"};case o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_TOKEN_EXPIRED_REFRESHABLE:return{pillClass:"stg:bg-amber-500/10 stg:text-amber-600 stg:dark:text-amber-400",dotClass:"stg:bg-amber-500",label:"Token expired"};case o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_TOKEN_EXPIRED:return{pillClass:"stg:bg-destructive-subtle stg:text-destructive",dotClass:"stg:bg-destructive",label:"Re-auth needed"};default:return{pillClass:"stg:bg-muted stg:text-muted-foreground",dotClass:"stg:bg-muted-foreground",label:"Not connected"}}}(h,S&&!p),es=L&&!G&&"idle"===W;return"confirming"===V||"disconnecting"===V?(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:px-3 stg:py-2",children:[(0,t.jsx)(ed,{className:"stg:size-3.5 stg:shrink-0 stg:text-destructive"}),(0,t.jsxs)("p",{className:"stg:flex-1 stg:text-xs stg:text-foreground",children:["Remove OAuth credentials for ",(0,t.jsx)("span",{className:"stg:font-medium",children:k}),"? You can reconnect at any time."]}),(0,t.jsxs)("div",{className:"stg:flex stg:shrink-0 stg:items-center stg:gap-1.5",children:[(0,t.jsxs)("button",{type:"button",disabled:j,onClick:async()=>{_("disconnecting");try{await b(),_("idle")}catch{_("confirming")}},className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:bg-destructive stg:text-destructive-foreground stg:hover:bg-destructive-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:[j&&(0,t.jsx)(eN,{}),"Disconnect"]}),(0,t.jsx)("button",{type:"button",disabled:j,onClick:()=>{_("idle"),y()},className:(0,r.cn)("stg:inline-flex stg:items-center stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent stg:hover:text-accent-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:"Cancel"})]})]}),N&&(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-2 stg:border-t stg:border-destructive/20 stg:bg-destructive-subtle stg:px-3 stg:py-2",children:[(0,t.jsx)(ed,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-destructive"}),(0,t.jsx)("p",{className:"stg:flex-1 stg:text-xs stg:text-destructive",children:(0,n.getUserMessage)(N)}),(0,t.jsx)("button",{type:"button",onClick:y,className:"stg:shrink-0 stg:text-xs stg:text-destructive-muted stg:hover:text-destructive","aria-label":"Dismiss error",children:"Dismiss"})]})]}):"confirming"===W||"removing"===W?(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:px-3 stg:py-2",children:[(0,t.jsx)(ed,{className:"stg:size-3.5 stg:shrink-0 stg:text-destructive"}),(0,t.jsxs)("p",{className:"stg:flex-1 stg:text-xs stg:text-foreground",children:["Remove your custom OAuth app for"," ",(0,t.jsx)("span",{className:"stg:font-medium",children:k}),"? The server will revert to the platform's OAuth app."]}),(0,t.jsxs)("div",{className:"stg:flex stg:shrink-0 stg:items-center stg:gap-1.5",children:[(0,t.jsxs)("button",{type:"button",disabled:D,onClick:async()=>{q("removing");try{await T(),q("idle")}catch{q("confirming")}},className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:bg-destructive stg:text-destructive-foreground stg:hover:bg-destructive-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:[D&&(0,t.jsx)(eN,{}),"Remove"]}),(0,t.jsx)("button",{type:"button",disabled:D,onClick:()=>{q("idle"),H()},className:(0,r.cn)("stg:inline-flex stg:items-center stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent stg:hover:text-accent-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:"Cancel"})]})]}),B&&(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-2 stg:border-t stg:border-destructive/20 stg:bg-destructive-subtle stg:px-3 stg:py-2",children:[(0,t.jsx)(ed,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-destructive"}),(0,t.jsx)("p",{className:"stg:flex-1 stg:text-xs stg:text-destructive",children:(0,n.getUserMessage)(B)}),(0,t.jsx)("button",{type:"button",onClick:H,className:"stg:shrink-0 stg:text-xs stg:text-destructive-muted stg:hover:text-destructive","aria-label":"Dismiss error",children:"Dismiss"})]})]}):(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between stg:px-3 stg:py-2",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:["oauth"===m&&!P&&(0,t.jsxs)("span",{className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-full stg:px-2 stg:py-0.5 stg:text-[10px] stg:font-medium",et.pillClass),children:[(0,t.jsx)("span",{className:(0,r.cn)("stg:size-1.5 stg:rounded-full",et.dotClass),"aria-hidden":"true"}),et.label]}),(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:Y?"OAuth sign-in is pending vendor approval":ee}),v&&!G&&!P&&"idle"===V&&(0,t.jsx)("button",{type:"button",onClick:()=>_("confirming"),className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:"Disconnect"}),es&&(0,t.jsx)("button",{type:"button",onClick:()=>q("confirming"),className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:"Remove custom app"})]}),(0,t.jsxs)("button",{type:"button",onClick:g,disabled:G||u||Y,"data-cursor-target":"connect-button",className:(0,r.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium",X||Z?"stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover":"stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent stg:hover:text-accent-foreground","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:[Q,J]})]}),"awaiting-callback"===x&&(0,t.jsx)("div",{className:"stg:flex stg:items-center stg:gap-3 stg:border-t stg:border-border stg:px-3 stg:py-1.5",children:(0,t.jsx)("button",{type:"button",onClick:R,className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:"Cancel sign-in"})}),Y&&(0,t.jsx)(f.VendorApprovalBlockedNotice,{blocked:!0,pending:S,manualEntrySupported:z,canBringOwnApp:O,docsUrl:A,onBringOwnApp:M,className:"stg:border-t stg:border-amber-500/20"}),"oauth"===m&&!p&&!K&&!e&&(P||z||O)&&(0,t.jsx)("div",{className:"stg:flex stg:items-center stg:gap-3 stg:border-t stg:border-border stg:px-3 stg:py-1.5",children:P?(0,t.jsx)("button",{type:"button",onClick:U,className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:S?"Back to OAuth status":"Sign in with OAuth instead"}):(0,t.jsxs)(t.Fragment,{children:[z&&(0,t.jsx)("button",{type:"button",onClick:I,className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:"Enter token manually"}),O&&!E&&(0,t.jsx)("button",{type:"button",onClick:M,className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:"Use your own OAuth app"})]})}),i&&(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-2 stg:border-t stg:border-destructive/20 stg:bg-destructive-subtle stg:px-3 stg:py-2",role:"alert",children:[(0,t.jsx)(ed,{className:"stg:mt-0.5 stg:size-3.5 stg:shrink-0 stg:text-destructive"}),(0,t.jsx)("p",{className:"stg:flex-1 stg:text-xs stg:text-destructive",children:a??(0,n.getUserMessage)(i)}),(0,t.jsxs)("div",{className:"stg:flex stg:shrink-0 stg:items-center stg:gap-2",children:[(0,n.isRetryableError)(i)&&(0,t.jsx)("button",{type:"button",onClick:()=>{l(),g()},className:"stg:text-xs stg:font-medium stg:text-destructive stg:underline stg:underline-offset-2 stg:hover:no-underline",children:"Try again"}),(0,t.jsx)("button",{type:"button",onClick:l,className:"stg:text-xs stg:text-destructive-muted stg:hover:text-destructive","aria-label":"Dismiss error",children:"Dismiss"})]})]})]})}function $(e){switch(e){case"initiating":return"Starting sign-in...";case"awaiting-callback":return"Waiting for authorization...";case"completing":return"Completing sign-in...";case"connecting":return"Discovering tools...";default:return"Connecting..."}}function q({message:e}){return(0,t.jsxs)("div",{role:"alert",className:"stg:flex stg:items-start stg:gap-2.5 stg:rounded-lg stg:border stg:border-destructive/30 stg:bg-destructive-subtle stg:px-4 stg:py-3",children:[(0,t.jsx)(ed,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0 stg:text-destructive"}),(0,t.jsxs)("div",{className:"stg:min-w-0 stg:flex-1",children:[(0,t.jsx)("p",{className:"stg:text-sm stg:font-medium stg:text-destructive",children:"Invalid Configuration"}),(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-xs stg:text-destructive-muted",children:e})]})]})}function K({state:e}){switch(e){case a.ValidationState.valid:return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(ei,{}),(0,t.jsxs)("span",{className:"stg:inline-flex stg:items-center stg:gap-1 stg:text-emerald-600 stg:dark:text-emerald-400",children:[(0,t.jsx)(el,{className:"stg:size-3"}),"Valid"]})]});case a.ValidationState.invalid:return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(ei,{}),(0,t.jsx)("span",{className:"stg:text-destructive",children:"Invalid"})]});default:return null}}let X=[{value:"http",label:"HTTP",description:"Connect via HTTP/SSE endpoint"},{value:"stdio",label:"Stdio",description:"Launch a local process with stdin/stdout"}];function Z({serverType:e,editable:r,isSaving:n,saveMcpField:i}){let[o,a]=(0,s.useState)(!1),[g,l]=(0,s.useState)(!1),d=(0,s.useMemo)(()=>{if(e?.case!=="http")return null;let t=e.value;return{url:t.url,headers:t.headers&&Object.keys(t.headers).length>0?{...t.headers}:void 0,queryParams:t.queryParams&&Object.keys(t.queryParams).length>0?{...t.queryParams}:void 0,timeoutSeconds:t.timeoutSeconds||void 0}},[e]),c=(0,s.useCallback)(async e=>{if(!i)return!1;if("http"===e){let e=await i("http",{url:""});return e&&await i("stdio",void 0),e}let t=await i("stdio",{command:""});return t&&await i("http",void 0),t},[i]),u=(0,s.useMemo)(()=>d?.headers?Object.entries(d.headers).map(([e,t])=>({key:e,value:t})):[],[d?.headers]),x=(0,s.useMemo)(()=>d?.queryParams?Object.entries(d.queryParams).map(([e,t])=>({key:e,value:t})):[],[d?.queryParams]),m=(0,s.useCallback)(async e=>{if(!i||!d)return!1;let t={};for(let s of e)s.key.trim()&&(t[s.key.trim()]=s.value);return i("http",{...d,headers:Object.keys(t).length>0?t:void 0})},[i,d]),p=(0,s.useCallback)(async e=>{if(!i||!d)return!1;let t={};for(let s of e)s.key.trim()&&(t[s.key.trim()]=s.value);return i("http",{...d,queryParams:Object.keys(t).length>0?t:void 0})},[i,d]);return(0,t.jsxs)(B.Section,{title:"Server Configuration",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-2 stg:p-3",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Type"}),r&&i?(0,t.jsx)(I,{value:e?.case??"http",options:X,onSave:c,isSaving:n}):(0,t.jsx)("span",{className:"stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:font-mono stg:text-xs stg:font-medium stg:text-foreground",children:e?.case??"none"})]}),e?.case==="stdio"&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Command"}),r&&i?(0,t.jsx)(H.InlineEditText,{value:`${e.value.command}${e.value.args.length>0?` ${e.value.args.join(" ")}`:""}`,onSave:async e=>{let t=e.trim().split(/\s+/);return i("stdio",{command:t[0]||"",args:t.slice(1)})},isSaving:n,placeholder:"e.g. npx -y @modelcontextprotocol/server"}):(0,t.jsxs)("code",{className:"stg:font-mono stg:text-sm stg:text-foreground",children:[e.value.command,e.value.args.length>0&&` ${e.value.args.join(" ")}`]})]}),(r||e.value.workingDir)&&(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Working Dir"}),r&&i?(0,t.jsx)(H.InlineEditText,{value:e.value.workingDir??"",onSave:async t=>i("stdio",{command:e.value.command,args:[...e.value.args],workingDir:t||void 0}),isSaving:n,placeholder:"/path/to/working/dir"}):(0,t.jsx)("code",{className:"stg:font-mono stg:text-xs stg:text-foreground",children:e.value.workingDir})]})]}),e?.case==="http"&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:"URL"}),r&&i?(0,t.jsx)(H.InlineEditText,{value:e.value.url,onSave:async e=>i("http",{...d,url:e}),isSaving:n,placeholder:"https://example.com/mcp"}):(0,t.jsx)("code",{className:"stg:break-all stg:font-mono stg:text-sm stg:text-foreground",children:e.value.url})]}),(r||e.value.timeoutSeconds>0)&&(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Timeout"}),r&&i?(0,t.jsx)(H.InlineEditText,{value:e.value.timeoutSeconds>0?String(e.value.timeoutSeconds):"",onSave:async e=>i("http",{...d,timeoutSeconds:e?Number(e):void 0}),isSaving:n,placeholder:"30",validate:e=>e&&(isNaN(Number(e))||0>Number(e))?"Must be a positive number":null}):(0,t.jsxs)("span",{className:"stg:text-xs stg:text-foreground",children:[e.value.timeoutSeconds,"s"]})]})]})]}),e?.case==="http"&&(r||u.length>0)&&(0,t.jsx)(Y,{title:"Headers",count:u.length,rows:u,editable:r,isSaving:n,editing:o,onEditingChange:a,onSave:m,keyLabel:"Header name"}),e?.case==="http"&&(r||x.length>0)&&(0,t.jsx)(Y,{title:"Query Parameters",count:x.length,rows:x,editable:r,isSaving:n,editing:g,onEditingChange:l,onSave:p,keyLabel:"Parameter name"})]})}function Y({title:e,count:s,rows:r,editable:n,isSaving:i,editing:o,onEditingChange:a,onSave:g,keyLabel:l}){return(0,t.jsxs)("div",{className:"stg:border-t stg:border-border",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between stg:px-3 stg:py-2",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)("span",{className:"stg:text-xs stg:font-medium stg:text-muted-foreground",children:e}),s>0&&(0,t.jsx)("span",{className:"stg:inline-flex stg:min-w-[1.25rem] stg:items-center stg:justify-center stg:rounded-full stg:bg-muted stg:px-1 stg:py-px stg:text-[10px] stg:font-medium stg:leading-none stg:text-muted-foreground",children:s})]}),n&&(0,t.jsx)("button",{type:"button",onClick:()=>a(!o),className:"stg:text-[11px] stg:text-muted-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:text-foreground stg:hover:decoration-foreground",children:o?"Done":"Edit"})]}),n&&o?(0,t.jsx)(V.InlineEditKeyValue,{value:[...r],onSave:g,isSaving:i,editing:o,onEditingChange:a,keyLabel:l,showValue:!0,valueLabel:"Value"}):(0,t.jsx)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:r.map(e=>(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-2 stg:px-3 stg:py-1.5",children:[(0,t.jsx)("code",{className:"stg:shrink-0 stg:font-mono stg:text-xs stg:font-medium stg:text-foreground",children:e.key}),(0,t.jsx)("span",{className:"stg:min-w-0 stg:break-all stg:font-mono stg:text-xs stg:text-muted-foreground",children:function(e){let s;if(!G.test(e))return e;G.lastIndex=0;let r=[],n=0;for(;null!==(s=G.exec(e));)s.index>n&&r.push(e.slice(n,s.index)),r.push((0,t.jsxs)(E.Tooltip,{children:[(0,t.jsx)(E.TooltipTrigger,{render:(0,t.jsx)("span",{className:"stg:inline-flex stg:items-center stg:gap-0.5 stg:rounded stg:bg-primary-subtle stg:px-1 stg:py-px stg:text-[10px] stg:font-medium stg:text-primary"}),children:s[0]}),(0,t.jsx)(E.TooltipContent,{side:"top",children:`Resolved from environment variable: ${s[1]}`})]},s.index)),n=s.index+s[0].length;return n<e.length&&r.push(e.slice(n)),(0,t.jsx)(t.Fragment,{children:r})}(e.value)})]},e.key))})]})}let G=/\$\{([^}]+)\}/g;function J({spec:e}){return(0,t.jsx)(B.Section,{title:"Source",children:(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-2 stg:p-3",children:[e.repositoryUrl&&(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Repository"}),(0,t.jsxs)("a",{href:e.repositoryUrl,target:"_blank",rel:"noopener noreferrer",className:"stg:inline-flex stg:items-center stg:gap-1 stg:break-all stg:font-mono stg:text-xs stg:text-foreground stg:underline stg:decoration-muted-foreground/40 stg:underline-offset-2 stg:hover:decoration-foreground",children:[e.repositoryUrl,(0,t.jsx)(ef,{className:"stg:size-3 stg:shrink-0"})]})]}),e.githubStars>0&&(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-xs stg:font-medium stg:text-muted-foreground",children:"Stars"}),(0,t.jsx)("span",{className:"stg:text-xs stg:text-foreground",children:e.githubStars.toLocaleString()})]})]})})}function Q({templates:e}){return 0===e.length?null:(0,t.jsx)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:e.map(e=>(0,t.jsxs)("div",{className:"stg:px-3 stg:py-2.5",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("span",{className:"stg:text-sm stg:font-medium stg:text-foreground",children:e.name}),(0,t.jsx)("code",{className:"stg:font-mono stg:text-[10px] stg:text-muted-foreground",children:e.uriTemplate})]}),e.description&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-xs stg:text-muted-foreground",children:e.description})]},e.uriTemplate||e.name))})}function ee({data:e,oauthTargetEnvVar:r,editable:n,isSaving:i,saveMcpField:o}){let a=Object.entries(e).sort(([e],[t])=>e.localeCompare(t)),g=(0,s.useMemo)(()=>a.map(([e,t])=>({key:e,value:"",isSecret:t.isSecret,description:t.description,optional:t.optional})),[a]),l=(0,s.useCallback)(async e=>{if(!o)return!1;let t={};for(let s of e)s.key.trim()&&(t[s.key.trim()]={isSecret:s.isSecret||void 0,description:s.description||void 0,optional:s.optional||void 0});return o("env",Object.keys(t).length>0?t:void 0)},[o]),[d,c]=(0,s.useState)(!1);return(0,t.jsx)(B.Section,{title:"Environment Variables",count:a.length,onEdit:n?()=>c(e=>!e):void 0,children:n?(0,t.jsx)(V.InlineEditKeyValue,{value:g,onSave:l,isSaving:i,editing:d,onEditingChange:c,showSecretToggle:!0,showOptionalToggle:!0,showDescription:!0,keyLabel:"Variable name"}):(0,t.jsx)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:a.map(([e,s])=>{let n=e===r;return(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-3 stg:px-3 stg:py-2",children:[(0,t.jsx)("code",{className:"stg:shrink-0 stg:font-mono stg:text-sm stg:font-medium stg:text-foreground",children:e}),(0,t.jsx)("span",{className:"stg:shrink-0 stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-muted-foreground",children:s.isSecret?"secret":"config"}),n&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:rounded stg:bg-primary-subtle stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-primary",children:"oauth"}),s.optional&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-muted-foreground-subtle",children:"optional"}),s.description&&(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:s.description})]},e)})})})}function et({tags:e,editable:s}){return(0,t.jsx)(B.Section,{title:"Tags",count:e.length,children:(0,t.jsxs)("div",{className:"stg:flex stg:flex-wrap stg:gap-1.5 stg:p-3",children:[e.map(e=>(0,t.jsx)("span",{className:"stg:rounded-full stg:bg-muted stg:px-2.5 stg:py-0.5 stg:text-xs stg:font-medium stg:text-muted-foreground",children:e},e)),s&&0===e.length&&(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground stg:italic",children:"No tags"})]})})}function es({tools:e,isOAuthStranded:n,onDiscover:i,isDiscovering:o}){let[a,g]=(0,s.useState)(""),[l,d]=(0,s.useState)(null),c=(0,s.useMemo)(()=>{if(!a.trim())return e;let t=a.toLowerCase();return e.filter(e=>e.name.toLowerCase().includes(t)||e.description?.toLowerCase().includes(t))},[e,a]);if(0===e.length)return(0,t.jsxs)("div",{className:"stg:px-3 stg:py-8 stg:text-center",children:[(0,t.jsx)(ec,{className:"stg:mx-auto stg:mb-2 stg:size-6 stg:text-muted-foreground-faint"}),n?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:"Signed in, but tools haven't been discovered yet."}),(0,t.jsxs)("button",{type:"button",onClick:i,disabled:o,className:(0,r.cn)("stg:mt-3 stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:[o&&(0,t.jsx)(eN,{}),o?"Discovering tools...":"Discover tools"]})]}):(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:"Connect to this MCP server to discover its available tools."})]});let u=a.trim().length>0;return(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:px-3 stg:pb-2",children:[(0,t.jsxs)("div",{className:"stg:relative stg:flex-1",children:[(0,t.jsx)(ev,{className:"stg:pointer-events-none stg:absolute stg:left-2 stg:top-1/2 stg:size-3.5 stg:-translate-y-1/2 stg:text-muted-foreground"}),(0,t.jsx)("input",{type:"text",value:a,onChange:e=>g(e.target.value),placeholder:"Search tools…","aria-label":"Search tools",className:"stg:w-full stg:rounded-md stg:border stg:border-border stg:bg-background stg:py-1.5 stg:pl-7 stg:pr-7 stg:text-xs stg:text-foreground stg:placeholder:text-muted-foreground stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring"}),u&&(0,t.jsx)("button",{type:"button",onClick:()=>g(""),"aria-label":"Clear search",className:"stg:absolute stg:right-2 stg:top-1/2 stg:-translate-y-1/2 stg:text-muted-foreground stg:hover:text-foreground",children:(0,t.jsx)(eb,{className:"stg:size-3"})})]}),(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-[10px] stg:text-muted-foreground",children:u?`${c.length} of ${e.length}`:e.length})]}),0===c.length?(0,t.jsx)("div",{className:"stg:px-3 stg:py-6 stg:text-center",children:(0,t.jsxs)("p",{className:"stg:text-xs stg:text-muted-foreground",children:["No tools matching “",a,"”"]})}):(0,t.jsx)("div",{className:"stg:max-h-96 stg:overflow-y-auto",children:(0,t.jsx)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:c.map(e=>{let s=l===e.name,n=null!=e.inputSchema&&Object.keys(e.inputSchema).length>0;return(0,t.jsxs)("div",{children:[(0,t.jsxs)("button",{type:"button",onClick:()=>d(s?null:e.name),className:"stg:flex stg:w-full stg:items-start stg:gap-2 stg:px-3 stg:py-2.5 stg:text-left stg:transition-colors stg:hover:bg-muted-faint","aria-expanded":s,children:[(0,t.jsx)(ej,{className:(0,r.cn)("stg:mt-0.5 stg:size-3 stg:shrink-0 stg:text-muted-foreground stg:transition-transform",s&&"stg:rotate-90")}),(0,t.jsxs)("div",{className:"stg:min-w-0 stg:flex-1",children:[(0,t.jsx)("code",{className:"stg:font-mono stg:text-sm stg:font-medium stg:text-foreground",children:e.name}),e.description&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-xs stg:text-muted-foreground",children:e.description})]}),n&&(0,t.jsx)("span",{className:"stg:mt-0.5 stg:shrink-0 stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-muted-foreground",children:"schema"})]}),s&&n&&(0,t.jsx)("div",{className:"stg:border-t stg:border-border stg:bg-muted-faint stg:px-3 stg:py-2",children:(0,t.jsx)("pre",{className:"stg:max-h-64 stg:overflow-auto stg:whitespace-pre-wrap stg:break-words stg:rounded stg:border stg:border-border stg:bg-background stg:p-2 stg:font-mono stg:text-[11px] stg:text-foreground",children:JSON.stringify(e.inputSchema,null,2)})})]},e.name)})})})]})}function er({pinnedPolicies:e,classifiedPolicies:r,hasDiscoveredTools:n,isOAuthStranded:i}){let[o,a]=(0,s.useState)(""),g=e.length+r.length,l=g>0,d=(0,s.useMemo)(()=>{if(!o.trim())return e;let t=o.toLowerCase();return e.filter(e=>e.toolName.toLowerCase().includes(t)||e.message?.toLowerCase().includes(t))},[e,o]),c=(0,s.useMemo)(()=>{if(!o.trim())return r;let e=o.toLowerCase();return r.filter(t=>t.toolName.toLowerCase().includes(e)||t.message?.toLowerCase().includes(e))},[r,o]),u=d.length+c.length,x=o.trim().length>0;return l?(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:px-3 stg:pb-2",children:[(0,t.jsxs)("div",{className:"stg:relative stg:flex-1",children:[(0,t.jsx)(ev,{className:"stg:pointer-events-none stg:absolute stg:left-2 stg:top-1/2 stg:size-3.5 stg:-translate-y-1/2 stg:text-muted-foreground"}),(0,t.jsx)("input",{type:"text",value:o,onChange:e=>a(e.target.value),placeholder:"Search policies…","aria-label":"Search policies",className:"stg:w-full stg:rounded-md stg:border stg:border-border stg:bg-background stg:py-1.5 stg:pl-7 stg:pr-7 stg:text-xs stg:text-foreground stg:placeholder:text-muted-foreground stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring"}),x&&(0,t.jsx)("button",{type:"button",onClick:()=>a(""),"aria-label":"Clear search",className:"stg:absolute stg:right-2 stg:top-1/2 stg:-translate-y-1/2 stg:text-muted-foreground stg:hover:text-foreground",children:(0,t.jsx)(eb,{className:"stg:size-3"})})]}),(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-[10px] stg:text-muted-foreground",children:x?`${u} of ${g}`:g})]}),0===u?(0,t.jsx)("div",{className:"stg:px-3 stg:py-6 stg:text-center",children:(0,t.jsxs)("p",{className:"stg:text-xs stg:text-muted-foreground",children:["No policies matching “",o,"”"]})}):(0,t.jsxs)("div",{className:"stg:max-h-96 stg:overflow-y-auto",children:[d.length>0&&(0,t.jsx)(en,{icon:(0,t.jsx)(em,{className:"stg:size-3.5"}),label:"Pinned",policies:d}),c.length>0&&(0,t.jsx)(en,{icon:(0,t.jsx)(ep,{className:"stg:size-3.5"}),label:"Auto-classified",policies:c})]})]}):(0,t.jsxs)("div",{className:"stg:px-3 stg:py-8 stg:text-center",children:[(0,t.jsx)(ex,{className:"stg:mx-auto stg:mb-2 stg:size-6 stg:text-muted-foreground-faint"}),(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:n?"No approval policies yet. Reconnect to reclassify tools.":i?"Signed in — discover tools to auto-classify approval policies.":"Connect to discover tools and auto-classify approval policies."})]})}function en({icon:e,label:s,policies:r}){return(0,t.jsxs)("div",{className:"stg:flex stg:flex-col",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5 stg:border-b stg:border-border stg:bg-muted-faint stg:px-3 stg:py-1.5",children:[(0,t.jsx)("span",{className:"stg:text-muted-foreground",children:e}),(0,t.jsx)("span",{className:"stg:text-[10px] stg:font-medium stg:uppercase stg:tracking-wider stg:text-muted-foreground",children:s}),(0,t.jsxs)("span",{className:"stg:text-[10px] stg:text-muted-foreground",children:["(",r.length,")"]})]}),(0,t.jsx)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:r.map(e=>(0,t.jsxs)("div",{className:"stg:px-3 stg:py-2.5",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-baseline stg:gap-2",children:[(0,t.jsx)("code",{className:"stg:font-mono stg:text-sm stg:font-medium stg:text-foreground",children:e.toolName}),(0,t.jsxs)("span",{className:"stg:inline-flex stg:items-center stg:gap-1 stg:rounded stg:bg-amber-500/10 stg:px-1.5 stg:py-0.5 stg:text-[10px] stg:font-medium stg:text-amber-600 stg:dark:text-amber-400",children:[(0,t.jsx)(ex,{className:"stg:size-2.5"}),"requires approval"]})]}),e.message&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-xs stg:text-muted-foreground",children:e.message})]},e.toolName))})]})}function ei(){return(0,t.jsx)("span",{className:"stg:shrink-0","aria-hidden":"true",children:"·"})}function eo({className:e}){return(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:flex-col stg:gap-6",e),"aria-busy":"true","aria-label":"Loading MCP server details",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-3",children:[(0,t.jsx)("div",{className:"stg:mt-1 stg:size-6 stg:shrink-0 stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsxs)("div",{className:"stg:flex-1 stg:space-y-2",children:[(0,t.jsx)("div",{className:"stg:h-5 stg:w-48 stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsx)("div",{className:"stg:h-3 stg:w-64 stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsx)("div",{className:"stg:h-4 stg:w-full stg:max-w-md stg:animate-pulse stg:rounded stg:bg-muted"})]})]}),[24,48,16,12].map((e,s)=>(0,t.jsxs)("div",{className:"stg:space-y-2",children:[(0,t.jsx)("div",{className:"stg:h-3 stg:w-28 stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsx)("div",{className:"stg:animate-pulse stg:rounded-lg stg:border stg:border-border stg:bg-muted-faint",style:{height:`${4*e}px`}})]},s))]})}function ea({className:e}){return(0,t.jsxs)("div",{role:"status",className:(0,r.cn)("stg:flex stg:flex-col stg:items-center stg:gap-2 stg:py-12 stg:text-center",e),children:[(0,t.jsx)(eg,{className:"stg:size-10 stg:text-muted-foreground-faint"}),(0,t.jsx)("p",{className:"stg:text-sm stg:font-medium stg:text-muted-foreground",children:"MCP Server not found"}),(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground-subtle",children:"This MCP server doesn't exist or you don't have access to it."})]})}function eg({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:"2",y:"2",width:"12",height:"5",rx:"1"}),(0,t.jsx)("rect",{x:"2",y:"9",width:"12",height:"5",rx:"1"}),(0,t.jsx)("circle",{cx:"5",cy:"4.5",r:"0.75",fill:"currentColor",stroke:"none"}),(0,t.jsx)("circle",{cx:"5",cy:"11.5",r:"0.75",fill:"currentColor",stroke:"none"})]})}function el({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 3.5 3.5 6.5-8"})})}function ed({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M8 1.5 1 14h14L8 1.5Z"}),(0,t.jsx)("path",{d:"M8 6v3.5"}),(0,t.jsx)("circle",{cx:"8",cy:"11.5",r:"0.5",fill:"currentColor",stroke:"none"})]})}function ec({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:"M6.5 6.5 4.25 4.25"}),(0,t.jsx)("path",{d:"m9.5 9.5 2.25 2.25"}),(0,t.jsx)("rect",{x:"1.5",y:"1.5",width:"5",height:"5",rx:"1"}),(0,t.jsx)("rect",{x:"9.5",y:"9.5",width:"5",height:"5",rx:"1"}),(0,t.jsx)("path",{d:"m6.5 9.5-3 3"}),(0,t.jsx)("path",{d:"m9.5 6.5 3-3"})]})}function eu({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.5 8a5.5 5.5 0 0 1 9.36-3.92"}),(0,t.jsx)("path",{d:"M13.5 8a5.5 5.5 0 0 1-9.36 3.92"}),(0,t.jsx)("path",{d:"M12 2v3h-3"}),(0,t.jsx)("path",{d:"M4 14v-3h3"})]})}function ex({className:e}){return(0,t.jsx)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 1.5 2.5 4v4c0 3.31 2.35 6.4 5.5 7 3.15-.6 5.5-3.69 5.5-7V4L8 1.5Z"})})}function em({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:"M9.5 2.5 13.5 6.5"}),(0,t.jsx)("path",{d:"M5 7 3 14l7-2"}),(0,t.jsx)("path",{d:"m5 7 2-2 4.5-1 1.5 1.5-1 4.5-2 2z"})]})}function ep({className:e}){return(0,t.jsx)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 1v2M8 13v2M1 8h2M13 8h2M3.05 3.05l1.41 1.41M11.54 11.54l1.41 1.41M3.05 12.95l1.41-1.41M11.54 4.46l1.41-1.41"})})}function eh({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:"1.5",y:"5",width:"13",height:"8",rx:"1.5"}),(0,t.jsx)("path",{d:"M4.5 5V3.5a3.5 3.5 0 0 1 7 0V5"}),(0,t.jsx)("circle",{cx:"8",cy:"9.5",r:"1.25"})]})}function ef({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M12 8.667v4A1.333 1.333 0 0 1 10.667 14H3.333A1.333 1.333 0 0 1 2 12.667V5.333A1.333 1.333 0 0 1 3.333 4h4"}),(0,t.jsx)("path",{d:"M10 2h4v4"}),(0,t.jsx)("path",{d:"M6.667 9.333 14 2"})]})}function ev({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:"7",cy:"7",r:"4.5"}),(0,t.jsx)("path",{d:"m10.5 10.5 3 3"})]})}function eb({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:"m4 4 8 8M12 4l-8 8"})})}function ej({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:"m6 4 4 4-4 4"})})}function eN(){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:"stg:animate-spin","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}e.s(["McpServerDetailView",0,function({org:e,slug:r,mcpServerState:f,onResourceLoad:j,defaultCapabilityTab:y="tools",defaultShowCredentialForm:k=!1,credentialPoolValues:C,activeOrg:E,primaryAction:I,actions:U,onPluginClick:R,editable:V=!1,onResourceUpdated:$,className:X}){let Y=(0,g.useMcpServer)(f?null:e,f?null:r),{mcpServer:G,isLoading:en,error:el,refetch:ed}=f??Y,ec=(0,W.useManagingPlugin)(G?.metadata?.labels),eu=V&&null===ec.plugin,{update:ex,isUpdating:em}=function(){let e=(0,l.useStigmer)(),[t,r]=(0,s.useState)(!1),[n,i]=(0,s.useState)(null),o=(0,s.useCallback)(()=>i(null),[]);return{update:(0,s.useCallback)(async t=>{r(!0),i(null);try{return await e.mcpServer.update(t)}catch(e){throw i((0,d.toError)(e)),e}finally{r(!1)}},[e]),isUpdating:t,error:n,clearError:o}}(),ep=(0,s.useCallback)(async(e,t)=>{if(!G)return!1;let s=(0,c.toMcpServerUpdateInput)(G);s[e]=t;try{let e=await ex(s);return $?.(e),ed(),!0}catch{return!1}},[G,ex,$,ed]),eh=(0,x.useMcpServerCredentials)(E??e,G??null),ef=(0,u.useMcpServerConnect)(),ev=(0,m.useMcpServerOAuthConnect)(),eb=(0,v.useDisconnectOAuth)(),ej=(0,b.useOrgOAuthApp)(G?.metadata?.id??null,E??e),[eN,ey]=(0,s.useState)(k),[ek,eC]=(0,s.useState)(!1),[ew,eS]=(0,s.useState)(y),eE=(0,s.useRef)(j);eE.current=j,(0,s.useEffect)(()=>{G?.metadata?.name&&eE.current?.({name:G.metadata.name,id:G.metadata.id})},[G]);let eA=(0,s.useCallback)(async()=>{if(!G?.metadata?.id)return;let t=Object.keys(G.spec?.env??{});try{await ev.startOAuth(G.metadata.id,E??e,t),eh.refetch(),ed()}catch{eh.refetch(),ed()}},[G,ev,eh,ed]),eO="oauth"===eh.authMode&&"connecting"===ev.failedPhase,eL=(0,s.useCallback)(async()=>{if(!G?.metadata?.id)return;if("oauth"===eh.authMode&&!eh.isOAuthConnected&&!eh.manualOverride&&!eO)return void eA();if(!eh.isReady&&!eO)return void ey(!0);let t=Object.keys(G.spec?.env??{});try{await ef.connect(G.metadata.id,E??e,void 0,t),ev.clearError(),ed()}catch{}},[G,eh.authMode,eh.isOAuthConnected,eh.manualOverride,eh.isReady,eO,ef,ev.clearError,ed,eA,E,e]),eM=(0,s.useCallback)(async(t,s)=>{try{if(s.saveForFuture&&(await eh.saveCredentials(t),eh.refetch()),G?.metadata?.id){let s=Object.keys(G.spec?.env??{}),r=E??e;await ef.connect(G.metadata.id,r,t,s),ed()}ey(!1)}catch{}},[eh,G,ef,ed]),eT=(0,s.useCallback)(async()=>{if(G?.metadata?.id)try{await eb.disconnect(G.metadata.id,E??e),eh.refetch(),ed()}catch{}},[G,eb,eh,ed,E,e]),eD=(0,s.useCallback)(e=>{e||(eC(!1),ej.clearErrors())},[ej]),eB=(0,s.useCallback)(async(e,t)=>{await ej.setOrgOAuthApp(e,t),eC(!1),ej.refetch(),eh.refetch(),ed()},[ej,eh,ed]),eH=(0,s.useCallback)(async()=>{await ej.deleteOrgOAuthApp(),ej.refetch(),eh.refetch(),ed()},[ej,eh,ed]),ez=G?.spec,eP=G?.status,eI=ez&&(ez.repositoryUrl||ez.githubStars>0),eU=eP?.audit?.specAudit,eR=eP?.discoveredCapabilities,eV=ez?.pinnedToolApprovals??[],e_=eP?.toolApprovals??[],eW=eV.length+e_.length,eF=eR?.tools??[],e$=eR?.resourceTemplates??[],eq=eF.length>0,eK="oauth"===eh.authMode&&eh.isOAuthConnected&&eh.connectionHealth!==o.OAuthConnectionHealth.OAUTH_CONNECTION_HEALTH_TOKEN_EXPIRED&&!eq,eX=(0,s.useMemo)(()=>{let e=[{id:"tools",label:"Tools",badge:eF.length},{id:"policies",label:"Policies",badge:eW}];return e$.length>0&&e.push({id:"resources",label:"Resources",badge:e$.length}),e},[eF.length,eW,e$.length]),eZ=ef.error??ev.error,eY=ef.error?(0,n.getUserMessage)(ef.error):ev.error?(0,m.getOAuthConnectErrorMessage)(ev.error,ev.failedPhase):null,eG=(0,s.useCallback)(()=>{ef.clearError(),ev.clearError()},[ef,ev]),eJ=(0,M.useManageAccess)({resource:G?.metadata?{kind:w.ApiResourceKind.mcp_server,kindString:"mcp_server",id:G.metadata.id,org:G.metadata.org,name:G.metadata.name}:null,visibility:G?.metadata?{kind:"mcpServer",current:G.metadata.visibility,org:G.metadata.org,onChanged:ed}:void 0});if(en)return(0,t.jsx)(eo,{className:X});if(el)return(0,t.jsx)(S.ErrorMessage,{error:el,retry:ed,className:X});if(!G)return(0,t.jsx)(ea,{className:X});let eQ=G.metadata,e0=eR?.lastDiscoveredAt?(0,i.timestampDate)(eR.lastDiscoveredAt):null,e1={name:eQ?.name||eQ?.slug||"Untitled",nameElement:eu&&ep?(0,t.jsx)(H.InlineEditText,{value:eQ?.name||"",onSave:e=>ep("name",e),isSaving:em,variant:"heading",placeholder:"Server name",validate:e=>e.trim()?null:"Name is required"}):void 0,id:eQ?.id||"",org:eQ?.org,slug:eQ?.slug,qualifiedSlug:eQ?.slug?eQ.org?`${eQ.org}/${eQ.slug}`:eQ.slug:void 0,icon:eu&&ep?(0,t.jsx)(P.InlineEditImage,{value:ez?.iconUrl??"",onSave:e=>ep("iconUrl",e||void 0),isSaving:em,fallback:(0,t.jsx)(eg,{className:"stg:size-6 stg:text-muted-foreground"}),size:"md"}):ez?.iconUrl?void 0:(0,t.jsx)(eg,{className:"stg:size-6 stg:text-muted-foreground"}),iconUrl:eu?void 0:ez?.iconUrl||void 0,createdAt:eU?.createdAt?(0,i.timestampDate)(eU.createdAt):null,updatedAt:eU?.updatedAt?(0,i.timestampDate)(eU.updatedAt):null},e5=eQ?(0,t.jsx)(L.VisibilityBadge,{visibility:eQ.visibility,onClick:eJ.action?eJ.open:void 0}):void 0,e2=eJ.action?[...U??[],eJ.action]:U,e3=(0,t.jsxs)(t.Fragment,{children:[eP&&(0,t.jsx)(K,{state:eP.validationState}),e0&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(ei,{}),(0,t.jsxs)("span",{children:["Discovered ",e0.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})]})]})]}),e6=(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(_.ManagedByPluginNotice,{plugin:ec.plugin,onPluginClick:R}),eP?.validationState===a.ValidationState.invalid&&eP.validationMessage?(0,t.jsx)(q,{message:eP.validationMessage}):null]});return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(D.ResourceDetailShell,{header:e1,visibilityControl:e5,headerMetaExtra:e3,headerBanner:e6,primaryAction:I,actions:e2,className:X,children:[(eu||ez?.description)&&(0,t.jsx)(B.Section,{title:"Description",children:eu&&ep?(0,t.jsx)("div",{className:"stg:max-h-20 stg:overflow-y-auto stg:p-3",children:(0,t.jsx)(z.InlineEditTextarea,{value:ez?.description||"",onSave:e=>ep("description",e||void 0),isSaving:em,placeholder:"Add a description",minRows:2})}):(0,t.jsx)("div",{className:"stg:p-3",children:(0,t.jsx)("pre",{className:"stg:whitespace-pre-wrap stg:break-words stg:text-sm stg:text-foreground stg:font-sans",children:ez?.description})})}),eI&&(0,t.jsx)(J,{spec:ez}),(eu||ez?.serverType.case)&&(0,t.jsx)(Z,{serverType:ez?.serverType,editable:eu,isSaving:em,saveMcpField:ep}),(eu||ez?.env&&Object.keys(ez.env).length>0)&&(0,t.jsx)(ee,{data:ez?.env??{},oauthTargetEnvVar:eh.oauthTargetEnvVar,editable:eu,isSaving:em,saveMcpField:ep}),(0,t.jsxs)(B.Section,{title:"Connection",scrollTarget:"mcp-connection",children:[(0,t.jsx)(p.StdioSandboxNotice,{serverType:ez?.serverType,className:"stg:mb-3"}),(0,t.jsx)(h.OAuthRequiredNotice,{oauthOnly:ez?.auth?.oauthOnly,className:"stg:mb-3"}),(0,t.jsx)(F,{manualEntrySupported:eh.manualEntrySupported,isConnecting:ef.isConnecting||ev.isInProgress,connectionError:eZ,connectionErrorMessage:eY,onConnect:eL,onClearConnectionError:eG,hasDiscoveredTools:eq,isOAuthStranded:eK,credentialsLoading:eh.isLoading,oauthPhase:ev.phase,authMode:eh.authMode,isOAuthConnected:eh.isOAuthConnected,connectionHealth:eh.connectionHealth,canDisconnect:eh.canDisconnect,onDisconnect:eT,isDisconnecting:eb.isDisconnecting,disconnectError:eb.error,onClearDisconnectError:eb.clearError,serverName:G?.metadata?.name??r,accessTokenExpiresAt:eh.accessTokenExpiresAt,tokenLifetimeHint:eh.tokenLifetimeHint,isVendorApprovalPending:eh.isVendorApprovalPending,isVendorApprovalBlocked:eh.isVendorApprovalBlocked,vendorApprovalDocsUrl:eh.vendorApprovalDocsUrl,canBringOwnApp:eh.canBringOwnApp,isOrgOAuthApp:eh.isOrgOAuthApp,onBringOwnApp:()=>eC(!0),onRemoveOrgApp:eH,isRemovingOrgApp:ej.isDeleting,removeOrgAppError:ej.deleteError,onClearRemoveOrgAppError:ej.clearErrors,manualOverride:eh.manualOverride,onManualOverride:()=>{eh.setManualOverride(!0),ey(!0)},onBackToOAuth:()=>{eh.setManualOverride(!1),ey(!1)},onCancelOAuth:ev.clearError}),eN&&eh.missingVariables.length>0&&(0,t.jsx)("div",{className:"stg:border-b stg:border-border stg:p-4","data-cursor-target":"credential-form",children:(0,t.jsx)(O.EnvVarForm,{title:"Credentials Required",description:'Enter the credentials needed to connect to this MCP server. Toggle "Save for future runs" to persist them in your personal environment, or leave it off for one-time use.',variables:eh.missingVariables,onSubmit:(e,t)=>eM(e,t),onCancel:()=>ey(!1),isSubmitting:eh.isSaving,poolValues:C,className:"stg:w-full stg:max-w-md"})})]}),(0,t.jsxs)(A.DialogShell,{open:ek,onOpenChange:eD,width:"md",className:"stg:p-6","aria-label":"Use your own OAuth app",children:[(0,t.jsx)("h3",{className:"stg:mb-4 stg:text-base stg:font-semibold stg:text-foreground",children:"Use your own OAuth app"}),(0,t.jsx)(N,{providerName:G?.metadata?.name??r,vendorDocsUrl:eh.vendorApprovalDocsUrl,onSubmit:eB,onCancel:()=>{eC(!1),ej.clearErrors()},isSubmitting:ej.isSetting,error:ej.setError})]}),(0,t.jsx)(B.Section,{title:"Capabilities",scrollTarget:"mcp-capabilities",children:(0,t.jsxs)(T.Tabs,{tabs:eX,activeTab:ew,onTabChange:e=>eS(e),"aria-label":"MCP server capabilities",children:["tools"===ew&&(0,t.jsx)(es,{tools:eF,isOAuthStranded:eK,onDiscover:eL,isDiscovering:ef.isConnecting||ev.isInProgress}),"policies"===ew&&(0,t.jsx)(er,{pinnedPolicies:eV,classifiedPolicies:e_,hasDiscoveredTools:eq,isOAuthStranded:eK}),"resources"===ew&&(0,t.jsx)(Q,{templates:e$})]})}),(eu||ez&&ez.tags.length>0)&&(0,t.jsx)(et,{tags:ez?.tags??[],editable:eu})]}),eJ.dialog]})},"oauthPhaseLabel",0,$],674542)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,936175,e=>{"use strict";var t=e.i(586108),r=e.i(583093);e.s(["useBillingAccount",0,function(e,n){let i=(0,t.useStigmer)(),{data:s,isLoading:a,isRefetching:o,error:u,refetch:d}=(0,r.useFetch)(e?()=>i.billing.getOrCreateBillingAccount(e):null,[e,i],null,{refetchOnWindowFocus:n?.refetchOnWindowFocus??!1});return{account:s,isLoading:a,isRefetching:o,error:u,refetch:d}}])},818424,e=>{"use strict";var t=e.i(843476),r=e.i(893976);let n=(0,r.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:i,onPageChange:s,ariaLabel:a,className:o}){return(0,t.jsxs)("div",{className:(0,r.cn)("stg:flex stg:items-center stg:justify-between",o),role:"navigation","aria-label":a,children:[(0,t.jsx)("button",{type:"button",disabled:e<=1,onClick:()=>s(e-1),className:n,children:"Previous"}),(0,t.jsxs)("span",{className:"stg:text-xs stg:tabular-nums stg:text-muted-foreground",children:["Page ",e," of ",i]}),(0,t.jsx)("button",{type:"button",disabled:e>=i,onClick:()=>s(e+1),className:n,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])},630983,e=>{"use strict";var t=e.i(843476),r=e.i(893976);function n({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:i}){return(0,t.jsxs)("div",{role:"status",className:(0,r.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",i),children:[(0,t.jsx)(n,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0"}),(0,t.jsx)("p",{className:"stg:text-xs stg:leading-relaxed",children:e})]})}])},982247,e=>{"use strict";var t=e.i(960511);let r={[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),r=Number(e<t?-e:e)/1e6,n=`$${r.toFixed(2)}`;return e>t?`+${n}`:e<t?`-${n}`:n},"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 r[e]??"Unknown"}])},628217,e=>{"use strict";var t=e.i(937111);let r={[t.Feature.sso_enforcement]:{label:"SSO enforcement",description:"Require members to sign in through a registered identity provider."},[t.Feature.byo_provider_keys]:{label:"Bring your own provider keys",description:"Use the customer's own LLM provider keys instead of the metered proxy."},[t.Feature.channels]:{label:"Channels",description:"Deliver agents over messaging channels through a channel runtime."},[t.Feature.sharing]:{label:"Sharing",description:"Share agents with individuals and guests through hosted links."},[t.Feature.teams]:{label:"Teams",description:"Group members into teams and grant access to a team at once."},[t.Feature.managed_organizations]:{label:"Managed organizations",description:"Run organizations for your own customers under your identity provider."}};e.s(["FEATURE_COPY",0,r,"isNamedFeature",0,function(e){return e in r}])},335264,722764,e=>{"use strict";var t=e.i(17616),r=e.i(191470),n=e.i(931664),i=e.i(937111),s=e.i(628217),a=e.i(982247);let o=BigInt(0),u=new Set([i.Feature.byo_provider_keys]);function d(e){return[...new Set(e?.features??[])].filter(e=>(0,s.isNamedFeature)(e)&&!u.has(e)).sort((e,t)=>e-t).map(e=>({feature:e,...s.FEATURE_COPY[e]}))}function l(e){return e.filter(e=>e.spec?.instrument===r.PlanInstrument.subscription&&e.status?.lifecycle===n.PlanLifecycle.active).map((e,t)=>({plan:e,index:t})).sort((e,t)=>{var r,n;let i,s;return r=e.plan,n=t.plan,i=r.spec?.terms?.monthlyMinimumMicros??o,(i===(s=n.spec?.terms?.monthlyMinimumMicros??o)?0:i<s?-1:1)||e.index-t.index}).map(({plan:e})=>e)}function c(e){let t=e?.usageShareBasisPoints??0;return 0===t?"":`${t%100==0?`${t/100}`:(t/100).toFixed(2)}%`}let m=new Intl.DateTimeFormat("en-US",{month:"short",day:"numeric",year:"numeric",timeZone:"UTC"});function g(e){return m.format(e)}e.s(["buyablePlans",0,l,"explainUsageShare",0,function(e){let t=c(e);if(""===t)return"";let r=BigInt(e?.usageShareBasisPoints??0),n=(e?.monthlyMinimumMicros??o)*BigInt(1e4)/r;return`Usage is still paid from credits. The ${t} commission on it counts toward the minimum, so from ${(0,a.formatCreditBalance)(n)} a month in provider costs the plan costs nothing extra.`},"featuresLost",0,function(e,t){let r=new Set(d(t.spec?.entitlements).map(e=>e.feature));return d(e?.spec?.entitlements).filter(e=>!r.has(e.feature))},"formatDay",0,g,"formatManagedOrganizations",0,function(e,t){if(!(e?.features??[]).includes(i.Feature.managed_organizations))return"";let r=e?.limits?.includedManagedOrganizations,n=t?.perExtraOrganizationMicros??o;if(void 0===r)return"Unlimited managed organizations";let s=n>o?`, then ${(0,a.formatCreditBalance)(n)}/month each`:"";return`${r} managed organization${1===r?"":"s"} included${s}`},"formatMonthlyMinimum",0,function(e){return`${(0,a.formatCreditBalance)(e?.monthlyMinimumMicros??o)}/month`},"formatPeriodDay",0,function(e){return void 0===e?"":g((0,t.timestampDate)(e))},"formatUsageShare",0,function(e){let t=c(e);return""===t?"":`or ${t} of provider cost, whichever is greater; the commission already paid on tokens counts toward it`},"lowestPlanWith",0,function(e,t){return l(e).find(e=>d(e.spec?.entitlements).some(e=>e.feature===t))},"offeredFeatures",0,d,"sharePercent",0,c],335264);var p=e.i(271645),h=e.i(891287),y=e.i(434517),f=e.i(586108),v=e.i(583093);e.s(["usePlans",0,function(e){let t=(0,f.useStigmer)(),r=e?.enabled??!0,n=e?.includeRetired??!1,{data:i,isLoading:s,isRefetching:a,error:o,refetch:u}=(0,v.useFetch)(r?()=>t.plan.list((0,h.create)(y.ListPlansInputSchema,{includeRetired:n})).then(e=>e.entries):null,[r,n,t],null);return(0,p.useMemo)(()=>({plans:i,isLoading:s,isRefetching:a,error:o,refetch:u}),[i,s,a,o,u])}],722764)}]);
@@ -0,0 +1 @@
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"},n={owner:t.IamRole.owner,admin:t.IamRole.admin,member:t.IamRole.member,viewer:t.IamRole.viewer,participant:t.IamRole.participant},r={[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"},i={[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 i[e]??""},"iamRoleDisplayName",0,function(e){return r[e]??"Unknown"},"iamRoleFromString",0,function(e){return n[e]},"iamRoleToString",0,function(e){return s[e]??"unspecified"}])},818094,e=>{"use strict";var t=e.i(170255),s=e.i(430182);let n=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]]]),r=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]]]),i=Object.freeze([]);e.s(["getGrantableRoles",0,function(e){return n.get(e)??i},"getTeamGrantableRoles",0,function(e){return r.get(e)??i},"hasGrantableRoles",0,function(e){let t=n.get(e);return void 0!==t&&t.length>0},"hasTeamGrantableRoles",0,function(e){let t=r.get(e);return void 0!==t&&t.length>0},"isRoleGrantable",0,function(e,t){let s=n.get(e);return void 0!==s&&s.includes(t)},"isRoleTeamGrantable",0,function(e,t){let s=r.get(e);return void 0!==s&&s.includes(t)}],818094)},146312,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(893976),r=e.i(869803),i=e.i(818094),a=e.i(691444);let o=[];e.s(["RoleSelector",0,function({kind:e,onSelect:l,selected:g,defaultRole:c,disabled:d=!1,granteeKind:u="identity_account",omitRoles:m,className:x}){let p=(0,s.useId)(),{options:f,selected:h,select:b}=function(e,t,n="identity_account",r=o){let[l,g]=(0,s.useState)(t??null),c=(0,s.useMemo)(()=>{if(null===e)return[];let t=new Set(r);return("team"===n?(0,i.getTeamGrantableRoles)(e):(0,i.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,n,r]),d=(0,s.useMemo)(()=>null!==l?(0,a.iamRoleToString)(l):"",[l]),u=(0,s.useCallback)(e=>g(e),[]),m=(0,s.useCallback)(()=>g(null),[]);return(0,s.useMemo)(()=>({options:c,selected:l,selectedValue:d,select:u,clear:m,hasOptions:c.length>0}),[c,l,d,u,m])}(e,c,u,m),v=void 0!==g?g:h;return 0===f.length?null:(0,t.jsxs)("fieldset",{className:(0,n.cn)(r.UNSTYLED_FIELDSET,"stg:space-y-1.5",x),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:f.map(e=>{let s=v===e.role;return(0,t.jsxs)("label",{className:(0,n.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",d&&"stg:pointer-events-none stg:opacity-50"),children:[(0,t.jsx)("input",{type:"radio",name:p,value:e.value,checked:s,disabled:d,onChange:()=>{var t;b(t=e.role),l?.(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)},213149,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(893976),r=e.i(468806),i=e.i(170255),a=e.i(818094),o=e.i(597744),l=e.i(610595),g=e.i(884561),c=e.i(869803),d=e.i(681094),u=e.i(540279),m=e.i(891287),x=e.i(632897),p=e.i(691444),f=e.i(288441),h=e.i(146312),b=e.i(982943),v=e.i(379410);function j({resourceKind:e,resourceKindString:r,resourceId:i,orgId:o,includeTeams:c=!1,excludeGrantees:d,onGranted:u,onCancel:R,className:w}){let{create:y,isCreating:N,error:k,clearError:I}=(0,f.useCreateIamPolicy)(),[C,M]=(0,s.useState)(null),[A,S]=(0,s.useState)(null),K=(0,s.useCallback)(t=>{M(t),S(s=>null===s||null===t||("team"===t.kind?(0,a.isRoleTeamGrantable)(e,s):(0,a.isRoleGrantable)(e,s))?s:null)},[e]),_=null!==C&&null!==A&&!N,T=(0,s.useCallback)(async e=>{if(e.preventDefault(),_&&null!==A&&null!==C){I();try{let e=(0,m.create)(x.IamPolicySpecSchema,{principal:(0,g.granteeRef)(C.grantee),resource:(0,m.create)(x.ApiResourceRefSchema,{kind:r,id:i}),relation:(0,p.iamRoleToString)(A)}),t=await y(e);u?.(t)}catch{}}},[_,A,C,r,i,y,I,u]);return(0,t.jsxs)("form",{onSubmit:T,className:(0,n.cn)("stg:space-y-3",w),children:[(0,t.jsxs)("div",{className:"stg:space-y-3",children:[(0,t.jsx)(b.PrincipalPicker,{orgId:o,value:C,onChange:K,includeTeams:c,excludeGrantees:d,disabled:N}),(0,t.jsx)(h.RoleSelector,{kind:e,granteeKind:C?.kind??"identity_account",selected:A,onSelect:S,disabled:N})]}),k&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,l.getUserMessage)(k)}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[(0,t.jsxs)("button",{type:"submit",disabled:!_,className:(0,n.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-40"),children:[N&&(0,t.jsx)(v.SpinnerIcon,{size:12}),"Grant access"]}),R&&(0,t.jsx)("button",{type:"button",onClick:R,disabled:N,className:(0,n.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs","stg:text-muted-foreground stg:hover:text-foreground stg:hover:bg-accent-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:"Cancel"})]})]})}var R=e.i(590150);function w({resource:e,resourceKindString:r,resourceKind:i,orgId:a,className:m}){let{accessList:x,isLoading:p,fetchError:f,revoke:h,isRevoking:b,revokeError:v,refetch:y,hasGrantableRoles:N,canShareWithTeams:k}=(0,d.useShareFlow)(e),I=(0,o.useDeploymentMode)(),[C,M]=(0,s.useState)(!1),A=(0,s.useMemo)(()=>x.flatMap(e=>{let t=e.principal?(0,g.granteeFromView)(e.principal):void 0;return t?[t]:[]}),[x]);if("local"===I&&"organization"!==e.kind)return(0,t.jsxs)("p",{className:(0,n.cn)("stg:text-xs stg:text-muted-foreground",m),children:["This edition does not share ",r.replaceAll("_"," "),"s with individual people. Sharing with specific people is available in Stigmer Enterprise and Cloud."]});let S={kind:r,id:e.id};return(0,t.jsxs)("div",{className:(0,n.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:p?"Loading access list...":`${x.length} with access`}),f&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,l.getUserMessage)(f)}),!p&&x.length>0&&(0,t.jsx)("ul",{className:(0,n.cn)(c.UNSTYLED_LIST,"stg:space-y-1 stg:mt-2"),"aria-label":"Who has access",children:x.map(e=>(0,t.jsx)(u.AccessRow,{entry:e,grantGate:S,onRemove:h,isRemoving:b},(0,u.accessEntryKey)(e)))}),v&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-[0.65rem]",role:"alert",children:(0,l.getUserMessage)(v)})]}),N&&(0,t.jsx)(R.PermissionGate,{resource:S,relation:"can_grant_access",children:(0,t.jsx)("div",{className:"stg:border-t stg:border-border stg:pt-3",children:C?(0,t.jsx)(j,{resourceKind:i,resourceKindString:r,resourceId:e.id,orgId:a,includeTeams:k,excludeGrantees:A,onGranted:()=>{M(!1),y()},onCancel:()=>M(!1)}):(0,t.jsx)("button",{type:"button",onClick:()=>M(!0),className:(0,n.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:k?"+ Add people or teams":"+ Add people"})})})]})}var y=e.i(388023);function N({title:e,description:s,children:n}){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:n})]})}function k(){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:l,resource:g,visibility:c,extraSection:d}){let u=(0,s.useId)(),m=(0,s.useCallback)(()=>{l(!1)},[l]),x=(0,a.hasGrantableRoles)(g.kind),p=(0,o.useResourceAvailable)(i.ApiResourceKind.team)&&(0,a.hasTeamGrantableRoles)(g.kind)?"People and teams with access":"People with access";return(0,t.jsx)(r.DialogShell,{open:e,onOpenChange:l,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"}),g.name&&(0,t.jsx)("p",{className:"stg:mt-0.5 stg:truncate stg:text-xs stg:text-muted-foreground",children:g.name})]}),(0,t.jsx)("button",{type:"button",onClick:m,"aria-label":"Close",className:(0,n.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)(k,{})})]}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:divide-y stg:divide-border",children:[c&&(0,t.jsx)(N,{title:"General access",description:"Who can find and open this resource.",children:(0,t.jsx)(y.ResourceVisibilityControl,{kind:c.kind,resourceId:g.id,visibility:c.current,org:c.org,onChanged:c.onChanged})}),x&&(0,t.jsx)(N,{title:p,children:(0,t.jsx)(w,{resource:{kind:g.kindString,id:g.id,resourceKind:g.kind},resourceKindString:g.kindString,resourceKind:g.kind,orgId:g.org})}),d&&(0,t.jsx)(N,{title:d.title,description:d.description,children:d.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,n.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)},10337,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(893976),r=e.i(468806);e.s(["ConfirmDialog",0,function({state:e,onConfirm:i,onCancel:a}){let o=(0,s.useCallback)(e=>{e||a()},[a]);if(!e)return null;let l="destructive"===e.variant;return(0,t.jsx)(r.DialogShell,{open:!0,onOpenChange:o,width:"sm","aria-label":e.title,children:(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-4 stg:p-6",children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("h3",{className:"stg:text-base stg:font-semibold stg:text-foreground",children:e.title}),(0,t.jsx)("p",{className:"stg:text-sm stg:text-muted-foreground",children:e.description})]}),(0,t.jsxs)("div",{className:"stg:flex stg:justify-end stg:gap-2",children:[(0,t.jsx)("button",{type:"button",onClick:a,className:(0,n.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-sm stg:font-medium stg:transition-colors","stg:border stg:border-input stg:bg-background stg:text-foreground","stg:hover:bg-accent stg:hover:text-accent-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:e.cancelLabel??"Cancel"}),(0,t.jsx)("button",{type:"button",onClick:i,className:(0,n.cn)("stg:rounded-md stg:px-3 stg:py-1.5 stg:text-sm stg:font-medium stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring",l?"stg:bg-destructive stg:text-destructive-foreground stg:hover:bg-destructive-hover":"stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover"),children:e.confirmLabel??"Confirm"})]})]})})}])},966205,e=>{"use strict";var t=e.i(271645);e.s(["useConfirmAction",0,function(){let[e,s]=(0,t.useState)(null),n=(0,t.useCallback)(e=>new Promise(t=>{s({...e,resolve:t})}),[]),r=(0,t.useCallback)(()=>{e?.resolve(!0),s(null)},[e]),i=(0,t.useCallback)(()=>{e?.resolve(!1),s(null)},[e]);return(0,t.useMemo)(()=>({confirmState:e,confirm:n,handleConfirm:r,handleCancel:i}),[e,n,r,i])}])},678745,e=>{"use strict";let t=(0,e.i(475254).default)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);e.s(["default",0,t])},845132,678784,916624,e=>{"use strict";var t=e.i(843476),s=e.i(893976),n=e.i(704077),r=e.i(678745);e.s(["CheckIcon",()=>r.default],678784);var r=r,i=e.i(364354);function a(e){return(0,t.jsx)(n.Menu.Root,{...e})}function o(e){return(0,t.jsx)(n.Menu.Trigger,{...e})}function l({align:e="start",alignOffset:r=0,side:a="bottom",sideOffset:o=4,className:g,...c}){let d=(0,i.useStigmerPortalContainer)();return(0,t.jsx)(n.Menu.Portal,{container:d,children:(0,t.jsx)(n.Menu.Positioner,{className:"stg:isolate stg:z-50 stg:outline-none",align:e,alignOffset:r,side:a,sideOffset:o,children:(0,t.jsx)(n.Menu.Popup,{className:(0,s.cn)("stg:bg-popover stg:text-popover-foreground stg:ring-foreground/10","stg:data-[side=bottom]:slide-in-from-top-2 stg:data-[side=inline-end]:slide-in-from-left-2 stg:data-[side=inline-start]:slide-in-from-right-2 stg:data-[side=left]:slide-in-from-right-2 stg:data-[side=right]:slide-in-from-left-2 stg:data-[side=top]:slide-in-from-bottom-2","stg:data-open:animate-in stg:data-open:fade-in-0 stg:data-open:zoom-in-95","stg:data-closed:animate-out stg:data-closed:fade-out-0 stg:data-closed:zoom-out-95","stg:z-50 stg:max-h-(--available-height) stg:w-(--anchor-width) stg:min-w-32 stg:origin-(--transform-origin) stg:overflow-x-hidden stg:overflow-y-auto stg:rounded-lg stg:p-1 stg:shadow-md stg:ring-1 stg:duration-100 stg:outline-none stg:data-closed:overflow-hidden",g),...c})})})}function g({className:e,variant:r="default",...i}){return(0,t.jsx)(n.Menu.Item,{"data-variant":r,className:(0,s.cn)("stg:focus:bg-accent stg:focus:text-accent-foreground stg:not-data-[variant=destructive]:focus:**:text-accent-foreground","stg:data-[variant=destructive]:text-destructive stg:data-[variant=destructive]:focus:bg-destructive-subtle stg:data-[variant=destructive]:focus:text-destructive stg:data-[variant=destructive]:*:[svg]:text-destructive","stg:relative stg:flex stg:cursor-default stg:items-center stg:gap-1.5 stg:rounded-md stg:px-1.5 stg:py-1 stg:text-sm stg:outline-hidden stg:select-none","stg:data-disabled:pointer-events-none stg:data-disabled:opacity-50","stg:[&_svg]:pointer-events-none stg:[&_svg]:shrink-0 stg:[&_svg:not([class*='size-'])]:size-4",e),...i})}function c({className:e,...r}){return(0,t.jsx)(n.Menu.Separator,{className:(0,s.cn)("stg:bg-border stg:-mx-1 stg:my-1 stg:h-px",e),...r})}function d({className:e,...s}){return(0,t.jsx)("div",{role:"group",className:e,...s})}function u({className:e,...n}){return(0,t.jsx)("span",{className:(0,s.cn)("stg:text-muted-foreground stg:block stg:px-1.5 stg:py-1 stg:text-[11px] stg:font-medium stg:uppercase stg:tracking-wider stg:select-none",e),...n})}e.s(["Menu",0,a,"MenuContent",0,l,"MenuGroup",0,d,"MenuItem",0,g,"MenuLabel",0,u,"MenuRadioGroup",0,function(e){return(0,t.jsx)(n.Menu.RadioGroup,{...e})},"MenuRadioItem",0,function({className:e,children:i,...a}){return(0,t.jsxs)(n.Menu.RadioItem,{className:(0,s.cn)("stg:focus:bg-accent stg:focus:text-accent-foreground stg:focus:**:text-accent-foreground","stg:relative stg:flex stg:cursor-default stg:items-center stg:gap-1.5 stg:rounded-md stg:py-1 stg:pr-8 stg:pl-1.5 stg:text-sm stg:outline-hidden stg:select-none","stg:data-disabled:pointer-events-none stg:data-disabled:opacity-50","stg:[&_svg]:pointer-events-none stg:[&_svg]:shrink-0 stg:[&_svg:not([class*='size-'])]:size-4",e),...a,children:[(0,t.jsx)("span",{className:"stg:pointer-events-none stg:absolute stg:right-2 stg:flex stg:items-center stg:justify-center",children:(0,t.jsx)(n.Menu.RadioItemIndicator,{children:(0,t.jsx)(r.default,{})})}),i]})},"MenuSeparator",0,c,"MenuTrigger",0,o],916624);let m=Object.assign(function({children:e}){return(0,t.jsx)(a,{children:e})},{Trigger:function({children:e,className:n,"aria-label":r="Actions"}){return(0,t.jsx)(o,{className:(0,s.cn)("stg:inline-flex stg:items-center stg:justify-center stg:rounded-md stg:p-1","stg:text-muted-foreground stg:hover:text-foreground stg:hover:bg-accent","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:data-popup-open:bg-accent stg:data-popup-open:text-foreground",n),"aria-label":r,children:e})},Content:function({children:e,align:n="end",className:r}){return(0,t.jsx)(l,{align:n,className:(0,s.cn)("stg:min-w-44",r),children:e})},Item:function({children:e,onSelect:n,icon:r,shortcut:i,variant:a="default",disabled:o,className:l}){return(0,t.jsxs)(g,{variant:a,disabled:o,onClick:n,className:(0,s.cn)("stg:justify-between",l),children:[(0,t.jsxs)("span",{className:"stg:flex stg:items-center stg:gap-2",children:[r,(0,t.jsx)("span",{children:e})]}),i&&(0,t.jsx)("kbd",{className:"stg:ml-auto stg:text-[11px] stg:tracking-widest stg:text-muted-foreground-subtle",children:i})]})},Separator:function({className:e}){return(0,t.jsx)(c,{className:e})},Group:function({children:e,label:s,className:n}){return(0,t.jsxs)(d,{className:n,children:[s&&(0,t.jsx)(u,{children:s}),e]})}});e.s(["ActionMenu",0,m],845132)},266442,e=>{"use strict";var t=e.i(843476),s=e.i(893976),n=e.i(188482);let r={ready:"Ready",running:"Running",pending:"Pending",degraded:"Degraded",failed:"Failed",disabled:"Disabled",draft:"Draft"};e.s(["StatusBadge",0,function({phase:e,label:i,tooltip:a,className:o}){let l=i??r[e],g=(0,t.jsxs)("span",{className:(0,s.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-full stg:px-2 stg:py-0.5 stg:text-[11px] stg:font-medium stg:leading-none",function(e){switch(e){case"ready":return"stg:bg-[var(--stgm-status-ready-subtle)] stg:text-[var(--stgm-status-ready)]";case"running":return"stg:bg-[var(--stgm-status-running-subtle)] stg:text-[var(--stgm-status-running)]";case"pending":return"stg:bg-[var(--stgm-status-pending-subtle)] stg:text-[var(--stgm-status-pending)]";case"degraded":return"stg:bg-[var(--stgm-status-degraded-subtle)] stg:text-[var(--stgm-status-degraded)]";case"failed":return"stg:bg-[var(--stgm-status-failed-subtle)] stg:text-[var(--stgm-status-failed)]";case"disabled":return"stg:bg-[var(--stgm-status-disabled-subtle)] stg:text-[var(--stgm-status-disabled)]";case"draft":return"stg:bg-[var(--stgm-status-draft-subtle)] stg:text-[var(--stgm-status-draft)]"}}(e),o),children:[(0,t.jsx)("span",{className:(0,s.cn)("stg:size-1.5 stg:shrink-0 stg:rounded-full",function(e){switch(e){case"ready":return"stg:bg-[var(--stgm-status-ready)]";case"running":return"stg:bg-[var(--stgm-status-running)]";case"pending":return"stg:bg-[var(--stgm-status-pending)]";case"degraded":return"stg:bg-[var(--stgm-status-degraded)]";case"failed":return"stg:bg-[var(--stgm-status-failed)]";case"disabled":return"stg:bg-[var(--stgm-status-disabled)]";case"draft":return"stg:bg-[var(--stgm-status-draft)]"}}(e)),"aria-hidden":"true"}),l]});return a?(0,t.jsxs)(n.Tooltip,{children:[(0,t.jsx)(n.TooltipTrigger,{render:(0,t.jsx)("span",{className:"stg:inline-flex"}),children:g}),(0,t.jsx)(n.TooltipContent,{side:"top",children:a})]}):g}])},476007,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(610595),r=e.i(893976);let i={auth:"Authentication required",permission:"Access denied","not-found":"Not found",validation:"Invalid request",server:"Server error",unavailable:"Service unavailable",cancelled:"Request cancelled",unknown:"Something went wrong"};function a({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)("path",{d:"M7.13 2.5a1 1 0 0 1 1.74 0l5.5 9.5A1 1 0 0 1 13.5 13.5h-11a1 1 0 0 1-.87-1.5l5.5-9.5z"}),(0,t.jsx)("path",{d:"M8 6v3"}),(0,t.jsx)("circle",{cx:"8",cy:"11",r:"0.5",fill:"currentColor",stroke:"none"})]})}function o({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)("path",{d:"M8 1.5l5 2v4c0 3.5-2.5 5.5-5 6.5-2.5-1-5-3-5-6.5v-4l5-2z"}),(0,t.jsx)("path",{d:"M6 6.5l4 4M10 6.5l-4 4"})]})}function l({className:e}){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,"aria-hidden":"true",children:(0,t.jsx)("path",{d:"M4 6l4 4 4-4"})})}function g({className:e}){return(0,t.jsxs)("svg",{width:"12",height:"12",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)("path",{d:"M2 6.5h4v-4"}),(0,t.jsx)("path",{d:"M3.5 11.5a5.5 5.5 0 1 0 .5-6l-2 1"})]})}e.s(["ErrorMessage",0,function({error:e,title:c,retry:d,className:u}){let[m,x]=(0,s.useState)(!1);if(!e)return null;let p=(0,n.classifyError)(e),f=(0,n.getUserMessage)(e),h=(0,n.getRpcMetadata)(e),b=(0,n.isRetryableError)(e);return(0,t.jsx)("div",{role:"alert",className:(0,r.cn)("stg:bg-destructive-subtle stg:border-destructive/20 stg:text-destructive stg:rounded-lg stg:border stg:p-4",u),children:(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-3",children:["auth"===p||"permission"===p?(0,t.jsx)(o,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0"}):(0,t.jsx)(a,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0"}),(0,t.jsxs)("div",{className:"stg:min-w-0 stg:flex-1 stg:space-y-1",children:[(0,t.jsx)("p",{className:"stg:text-sm stg:font-medium",children:c??i[p]}),(0,t.jsx)("p",{className:"stg:text-destructive-muted stg:text-sm",children:f}),h&&(0,t.jsxs)("div",{className:"stg:pt-1",children:[(0,t.jsxs)("button",{type:"button",onClick:()=>x(e=>!e),className:"stg:text-destructive-muted stg:hover:text-destructive-muted stg:inline-flex stg:items-center stg:gap-1 stg:text-xs stg:transition-colors",children:[(0,t.jsx)(l,{className:(0,r.cn)("stg:size-3 stg:transition-transform",m&&"stg:rotate-180")}),"Technical details"]}),m&&(0,t.jsxs)("dl",{className:"stg:text-destructive-muted stg:mt-1.5 stg:space-y-0.5 stg:font-mono stg:text-xs",children:[(0,t.jsxs)("div",{className:"stg:flex stg:gap-2",children:[(0,t.jsx)("dt",{className:"stg:shrink-0",children:"Method:"}),(0,t.jsx)("dd",{className:"stg:truncate",children:h.method})]}),(0,t.jsxs)("div",{className:"stg:flex stg:gap-2",children:[(0,t.jsx)("dt",{className:"stg:shrink-0",children:"Path:"}),(0,t.jsx)("dd",{className:"stg:truncate",children:h.path})]})]})]})]}),d&&b&&(0,t.jsxs)("button",{type:"button",onClick:d,className:(0,r.cn)("stg:inline-flex stg:shrink-0 stg:items-center stg:gap-1.5 stg:rounded-md stg:border stg:px-2.5 stg:py-1.5 stg:text-xs stg:font-medium","stg:border-destructive/20 stg:text-destructive stg:hover:bg-destructive-subtle","stg:transition-colors"),children:[(0,t.jsx)(g,{className:"stg:size-3"}),"Retry"]})]})})}])},193799,e=>{"use strict";var t=e.i(271645);e.s(["useCopyFeedback",0,function(){let[e,s]=(0,t.useState)(!1),n=(0,t.useRef)(null);(0,t.useEffect)(()=>()=>{null!==n.current&&clearTimeout(n.current)},[]);let r=(0,t.useCallback)(async e=>{try{await navigator.clipboard.writeText(e)}catch{return!1}return s(!0),null!==n.current&&clearTimeout(n.current),n.current=setTimeout(()=>s(!1),2e3),!0},[]);return(0,t.useMemo)(()=>({copy:r,copied:e}),[r,e])}])},927056,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(893976);e.s(["Tabs",0,function({tabs:e,activeTab:r,onTabChange:i,children:a,"aria-label":o,className:l}){let g=(0,s.useId)(),c=(0,s.useRef)(new Map),d=e=>`${g}-tab-${e}`,u=e=>`${g}-panel-${e}`,m=(0,s.useCallback)(e=>{c.current.get(e)?.focus(),i(e)},[i]),x=(0,s.useCallback)(t=>{let s=e.findIndex(e=>e.id===r);if(-1===s)return;let n=null;switch(t.key){case"ArrowRight":n=(s+1)%e.length;break;case"ArrowLeft":n=(s-1+e.length)%e.length;break;case"Home":n=0;break;case"End":n=e.length-1;break;default:return}t.preventDefault(),m(e[n].id)},[e,r,m]);return(0,t.jsxs)("div",{className:(0,n.cn)("stg:flex stg:flex-col",l),children:[(0,t.jsx)("div",{role:"tablist","aria-label":o,onKeyDown:x,className:"stg:flex stg:border-b stg:border-border",children:e.map(e=>{let s=e.id===r;return(0,t.jsxs)("button",{ref:t=>{t?c.current.set(e.id,t):c.current.delete(e.id)},id:d(e.id),role:"tab",type:"button","aria-selected":s,"aria-controls":u(e.id),tabIndex:s?0:-1,onClick:()=>i(e.id),"data-cursor-target":`tab-${e.id}`,className:(0,n.cn)("stg:relative stg:inline-flex stg:items-center stg:gap-1.5 stg:px-3 stg:py-2 stg:text-xs stg:font-medium stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-offset-1",s?"stg:text-foreground":"stg:text-muted-foreground stg:hover:text-foreground"),children:[e.icon,e.label,null!=e.badge&&e.badge>0&&(0,t.jsx)("span",{"aria-hidden":"true",className:(0,n.cn)("stg:inline-flex stg:min-w-[1.25rem] stg:items-center stg:justify-center stg:rounded-full stg:px-1 stg:py-px stg:text-[10px] stg:font-medium stg:leading-none",s?"stg:bg-primary-subtle stg:text-primary":"stg:bg-muted stg:text-muted-foreground"),children:e.badge}),s&&(0,t.jsx)("span",{className:"stg:absolute stg:inset-x-0 stg:-bottom-px stg:h-0.5 stg:bg-primary","aria-hidden":"true"})]},e.id)})}),(0,t.jsx)("div",{id:u(r),role:"tabpanel","aria-labelledby":d(r),tabIndex:0,className:"stg:min-h-0 stg:flex-1 stg:pt-4 stg:focus-visible:outline-none",children:a})]})}])},107141,e=>{"use strict";var t=e.i(271645),s=e.i(618566);let n="__placeholder__";e.s(["useStaticRouteParam",0,function(e,r=1){let i=(0,s.useParams)()[e];return(0,t.useMemo)(()=>{if(i!==n)return i;let e=window.location.pathname.split("/").filter(Boolean),t=e[e.length-r];return t&&t!==n?t:null},[i,r])}])},668093,652337,e=>{"use strict";var t=e.i(843476),s=e.i(893976),n=e.i(266442),r=e.i(927056),i=e.i(271645),a=e.i(845132);function o({primaryAction:e,actions:n,className:r}){let i=null!=n&&n.length>0;return e||i?(0,t.jsxs)("div",{className:(0,s.cn)("stg:flex stg:items-center stg:gap-2",r),children:[e&&(0,t.jsxs)("button",{type:"button",onClick:e.onAction,disabled:e.disabled,className:(0,s.cn)("stg:inline-flex stg:items-center stg:gap-1.5 stg:rounded-md stg:px-3 stg:py-1.5 stg:text-sm stg:font-medium stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:pointer-events-none stg:disabled:opacity-50"),children:[e.icon,e.label]}),i&&(0,t.jsx)(l,{actions:n})]}):null}function l({actions:e}){var s;let n=(s=e,(0,i.useMemo)(()=>{let e=new Map;for(let t of s){let s=t.group??"__default",n=e.get(s);n?n.push(t):e.set(s,[t])}return Array.from(e.entries()).map(([e,t])=>({key:e,items:t}))},[s]));return(0,t.jsxs)(a.ActionMenu,{children:[(0,t.jsx)(a.ActionMenu.Trigger,{"aria-label":"More actions",children:(0,t.jsx)(g,{className:"stg:size-4"})}),(0,t.jsx)(a.ActionMenu.Content,{children:n.map((e,s)=>(0,t.jsxs)(a.ActionMenu.Group,{children:[s>0&&(0,t.jsx)(a.ActionMenu.Separator,{}),e.items.map(e=>(0,t.jsx)(a.ActionMenu.Item,{icon:e.icon,shortcut:e.shortcut,variant:e.variant,disabled:e.disabled,onSelect:e.onAction,children:e.label},e.id))]},e.key))})]})}function g({className:e}){return(0,t.jsxs)("svg",{className:e,viewBox:"0 0 16 16",fill:"currentColor","aria-hidden":"true",children:[(0,t.jsx)("circle",{cx:"8",cy:"3",r:"1.25"}),(0,t.jsx)("circle",{cx:"8",cy:"8",r:"1.25"}),(0,t.jsx)("circle",{cx:"8",cy:"13",r:"1.25"})]})}function c({header:e,visibilityControl:s,metaExtra:r}){let{name:i,nameElement:a,org:o,slug:l,qualifiedSlug:g,description:m,iconUrl:x,icon:p,createdAt:f,updatedAt:h,status:b,statusLabel:v}=e,j=l&&l!==i&&!g;return(0,t.jsxs)("div",{className:"stg:flex stg:min-w-0 stg:items-start stg:gap-3",children:[x?(0,t.jsx)("img",{src:x,alt:"",className:"stg:mt-0.5 stg:size-8 stg:shrink-0 stg:rounded stg:object-cover"}):p?(0,t.jsx)("span",{className:"stg:mt-1 stg:shrink-0",children:p}):null,(0,t.jsxs)("div",{className:"stg:min-w-0 stg:flex-1",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[a??(0,t.jsx)("h2",{className:"stg:truncate stg:text-lg stg:font-semibold stg:text-foreground",children:i}),j&&(0,t.jsx)("code",{className:"stg:shrink-0 stg:rounded stg:bg-muted stg:px-1.5 stg:py-0.5 stg:text-xs stg:font-medium stg:text-muted-foreground",children:l}),b&&(0,t.jsx)(n.StatusBadge,{phase:b,label:v}),s]}),g&&(0,t.jsx)("span",{className:"stg:mt-0.5 stg:block stg:truncate stg:font-mono stg:text-xs stg:text-muted-foreground",children:g}),(0,t.jsxs)("div",{className:"stg:mt-0.5 stg:flex stg:flex-wrap stg:items-center stg:gap-x-1.5 stg:text-xs stg:text-muted-foreground",children:[o&&(0,t.jsx)("span",{children:o}),r,f&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d,{}),(0,t.jsxs)("span",{children:["Created ",u(f)]})]}),h&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d,{}),(0,t.jsxs)("span",{children:["Updated ",u(h)]})]})]}),m&&(0,t.jsx)("p",{className:"stg:mt-2 stg:text-sm stg:text-muted-foreground",children:m})]})]})}function d(){return(0,t.jsx)("span",{className:"stg:shrink-0","aria-hidden":"true",children:"·"})}function u(e){return e.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function m({className:e}){return(0,t.jsx)("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:"M11.5 1.5a2.121 2.121 0 0 1 3 3L5 14l-4 1 1-4Z"})})}e.s(["ResourceDetailShell",0,function({header:e,visibilityControl:n,headerMetaExtra:i,headerBanner:a,primaryAction:l,actions:g,tabs:d,activeTab:u,onTabChange:m,tabsAriaLabel:x,children:p,className:f}){let h=null!=d&&d.length>0;return(0,t.jsxs)("div",{className:(0,s.cn)("stg:flex stg:flex-col stg:gap-6",f),children:[a,(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:justify-between stg:gap-4",children:[(0,t.jsx)(c,{header:e,visibilityControl:n,metaExtra:i}),(0,t.jsx)(o,{primaryAction:l,actions:g,className:"stg:shrink-0"})]}),h&&u&&m?(0,t.jsx)(r.Tabs,{tabs:d,activeTab:u,onTabChange:m,"aria-label":x,children:p}):p]})}],668093),e.s(["Section",0,function({title:e,count:n,headerActions:r,onEdit:i,scrollTarget:a,children:o,className:l}){return(0,t.jsxs)("section",{className:l,"data-scroll-target":a,children:[(0,t.jsxs)("div",{className:"stg:mb-2 stg:flex stg:items-center stg:gap-2",children:[(0,t.jsx)("h3",{className:"stg:text-xs stg:font-medium stg:uppercase stg:tracking-wider stg:text-muted-foreground",children:e}),null!=n&&n>0&&(0,t.jsx)("span",{className:"stg:inline-flex stg:size-5 stg:items-center stg:justify-center stg:rounded-full stg:bg-muted stg:text-[10px] stg:font-semibold stg:text-muted-foreground",children:n}),(r||i)&&(0,t.jsxs)("div",{className:"stg:ml-auto stg:flex stg:items-center stg:gap-1",children:[r,i&&(0,t.jsx)("button",{type:"button",onClick:i,"aria-label":`Edit ${e.toLowerCase()}`,className:(0,s.cn)("stg:inline-flex stg:size-6 stg:items-center stg:justify-center stg:rounded-md stg:text-muted-foreground","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:transition-colors"),children:(0,t.jsx)(m,{className:"stg:size-3.5"})})]})]}),(0,t.jsx)("div",{className:"stg:overflow-hidden stg:rounded-lg stg:border stg:border-border",children:o})]})}],652337)},261722,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(893976);function r({className:e}){return(0,t.jsx)("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:"M11.5 1.5a2.121 2.121 0 0 1 3 3L5 14l-4 1 1-4Z"})})}function i(){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",className:"stg:animate-spin","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M8 2a6 6 0 1 0 6 6"})})}e.s(["InlineEditTextarea",0,function({value:e,onSave:a,placeholder:o="Click to edit",validate:l,minRows:g=3,disabled:c,isSaving:d,error:u,className:m}){let[x,p]=(0,s.useState)(!1),[f,h]=(0,s.useState)(e),[b,v]=(0,s.useState)(null),j=(0,s.useRef)(null);(0,s.useEffect)(()=>{x&&(h(e),v(null),requestAnimationFrame(()=>{let e=j.current;e&&(e.focus(),e.selectionStart=e.value.length)}))},[x,e]),(0,s.useEffect)(()=>{let e=j.current;e&&(e.style.height="auto",e.style.height=`${e.scrollHeight}px`)},[f,x]);let R=(0,s.useCallback)(async()=>{if(f===e)return void p(!1);if(l){let e=l(f);if(e)return void v(e)}await a(f)&&p(!1)},[f,e,l,a]),w=(0,s.useCallback)(()=>{p(!1),h(e),v(null)},[e]),y=(0,s.useCallback)(e=>{"Enter"===e.key&&(e.ctrlKey||e.metaKey)?(e.preventDefault(),R()):"Escape"===e.key&&w()},[R,w]),N=b||u;return c||!x?(0,t.jsx)("div",{className:(0,n.cn)("stg:group/inline-edit",m),children:(0,t.jsx)("button",{type:"button",onClick:()=>{c||p(!0)},disabled:c,className:(0,n.cn)("stg:w-full stg:rounded-md stg:px-2 stg:py-1.5 stg:text-left stg:transition-colors",!c&&"stg:hover:bg-accent-hover stg:cursor-pointer",c&&"stg:cursor-default","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-inset stg:focus-visible:ring-ring"),children:(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:justify-between stg:gap-2",children:[(0,t.jsx)("pre",{className:(0,n.cn)("stg:min-w-0 stg:whitespace-pre-wrap stg:break-words stg:font-mono stg:text-sm stg:text-foreground",!e&&"stg:text-muted-foreground stg:italic stg:font-sans"),children:e||o}),!c&&(0,t.jsx)(r,{className:"stg:mt-0.5 stg:size-3 stg:shrink-0 stg:text-muted-foreground stg:opacity-0 stg:transition-opacity stg:group-hover/inline-edit:opacity-100"})]})})}):(0,t.jsxs)("div",{className:(0,n.cn)("stg:flex stg:flex-col stg:gap-1.5",m),children:[(0,t.jsx)("textarea",{ref:j,value:f,onChange:e=>{h(e.target.value),v(null)},onKeyDown:y,disabled:d,placeholder:o,rows:g,className:(0,n.cn)("stg:w-full stg:resize-y stg:rounded-md stg:border stg:border-border stg:bg-input-bg stg:px-3 stg:py-2 stg:font-mono stg:text-sm stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring","stg:disabled:opacity-50",N&&"stg:border-destructive")}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between",children:[(0,t.jsx)("span",{className:"stg:text-[10px] stg:text-muted-foreground",children:d?"Saving...":"Ctrl+Enter to save, Escape to cancel"}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)("button",{type:"button",onClick:w,disabled:d,className:(0,n.cn)("stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:border stg:border-border stg:bg-background stg:text-foreground stg:hover:bg-accent stg:hover:text-accent-foreground","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:"Cancel"}),(0,t.jsxs)("button",{type:"button",onClick:R,disabled:d,className:(0,n.cn)("stg:inline-flex stg:items-center stg:gap-1 stg:rounded-md stg:px-2.5 stg:py-1 stg:text-xs stg:font-medium","stg:bg-primary stg:text-primary-foreground stg:hover:bg-primary-hover","stg:disabled:opacity-50","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:[d&&(0,t.jsx)(i,{}),"Save"]})]})]}),N&&(0,t.jsx)("p",{className:"stg:px-1 stg:text-xs stg:text-destructive",role:"alert",children:N})]})}])},484763,e=>{"use strict";var t=e.i(843476),s=e.i(271645),n=e.i(981922),r=e.i(213149);e.s(["useManageAccess",0,function({resource:e,visibility:i,extraSection:a,label:o="Manage access"}){let[l,g]=(0,s.useState)(!1),{allowed:c}=(0,n.useCheckPermission)(e?{kind:e.kindString,id:e.id}:null,"can_view_access"),d=(0,s.useCallback)(()=>g(!0),[]);return{action:e&&c?{id:"manage-access",label:o,group:"sharing",onAction:d}:null,dialog:e?(0,t.jsx)(r.ManageAccessDialog,{open:l,onOpenChange:g,resource:e,visibility:i,extraSection:a}):null,open:d,isOpen:l}}])}]);