@stigmer/server-slim 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (564) hide show
  1. package/README.md +3 -0
  2. package/console/404.html +1 -0
  3. package/console/__next.__PAGE__.txt +54 -0
  4. package/console/__next._full.txt +71 -0
  5. package/console/__next._index.txt +62 -0
  6. package/console/__next._tree.txt +6 -0
  7. package/console/_next/static/GjBokeF86FffwftazOhh6/_buildManifest.js +11 -0
  8. package/console/_next/static/GjBokeF86FffwftazOhh6/_clientMiddlewareManifest.js +1 -0
  9. package/console/_next/static/GjBokeF86FffwftazOhh6/_ssgManifest.js +1 -0
  10. package/console/_next/static/chunks/0376wi8qbsw94.js +1 -0
  11. package/console/_next/static/chunks/04cglffeuwumk.js +1 -0
  12. package/console/_next/static/chunks/04d276dp3qb52.js +1 -0
  13. package/console/_next/static/chunks/05526ws9tzwim.js +1 -0
  14. package/console/_next/static/chunks/05t5235u7o-c4.js +25 -0
  15. package/console/_next/static/chunks/06fz-g9t73bd6.js +4 -0
  16. package/console/_next/static/chunks/0789xt7opwvm-.js +24 -0
  17. package/console/_next/static/chunks/07twy5plc911w.js +1 -0
  18. package/console/_next/static/chunks/08-p5zefc1rea.js +1 -0
  19. package/console/_next/static/chunks/085db4op75mf5.js +1 -0
  20. package/console/_next/static/chunks/0923388wak11-.js +1 -0
  21. package/console/_next/static/chunks/0_7s7fzux7kiv.js +1 -0
  22. package/console/_next/static/chunks/0_bjj6hug8d9a.js +1 -0
  23. package/console/_next/static/chunks/0_zscrk6o0d0-.js +1 -0
  24. package/console/_next/static/chunks/0a4x97q7frgj3.js +1 -0
  25. package/console/_next/static/chunks/0ab5jlm8l0aud.js +1 -0
  26. package/console/_next/static/chunks/0c_c2b4z1yc02.js +1 -0
  27. package/console/_next/static/chunks/0cuyycns49hl4.js +1 -0
  28. package/console/_next/static/chunks/0cz1d0mv5g_q7.js +1 -0
  29. package/console/_next/static/chunks/0d8f3-znyc_to.js +1 -0
  30. package/console/_next/static/chunks/0e-f1rkyz_u2k.js +1 -0
  31. package/console/_next/static/chunks/0ffx83gbnwq09.js +28 -0
  32. package/console/_next/static/chunks/0fyno0jk61txk.js +115 -0
  33. package/console/_next/static/chunks/0ggwoicp90w_s.js +1 -0
  34. package/console/_next/static/chunks/0h_7_i44vofe3.js +1 -0
  35. package/console/_next/static/chunks/0hagmppwo8s-f.js +1 -0
  36. package/console/_next/static/chunks/0hfvbn6c9k3pf.js +1 -0
  37. package/console/_next/static/chunks/0hw7vilkfpzlc.js +1 -0
  38. package/console/_next/static/chunks/0kb63xcvghh_3.js +1 -0
  39. package/console/_next/static/chunks/0ko5wsi6kukgd.js +1 -0
  40. package/console/_next/static/chunks/0kq99qin4db-q.js +1 -0
  41. package/console/_next/static/chunks/0kqg4u5n17gje.js +1 -0
  42. package/console/_next/static/chunks/0ky9qppyx1n57.js +62 -0
  43. package/console/_next/static/chunks/0og4_5pph-mhm.js +1 -0
  44. package/console/_next/static/chunks/0p7p-bpdrqx75.js +1 -0
  45. package/console/_next/static/chunks/0q2bnr94vvuc2.js +1 -0
  46. package/console/_next/static/chunks/0q3sxhnylk_gn.js +1 -0
  47. package/console/_next/static/chunks/0qg6l3tattq3j.js +1 -0
  48. package/console/_next/static/chunks/0qwyk_70quvjh.js +1 -0
  49. package/console/_next/static/chunks/0qzyqii8_m5r2.js +1 -0
  50. package/console/_next/static/chunks/0rlfx91598uvc.js +1 -0
  51. package/console/_next/static/chunks/0s9njms3lumhx.js +1 -0
  52. package/console/_next/static/chunks/0srualwd948m1.js +29 -0
  53. package/console/_next/static/chunks/0u4m2805tgi7x.js +1 -0
  54. package/console/_next/static/chunks/0udcs-1vq74rp.js +1 -0
  55. package/console/_next/static/chunks/0vno04lmwdchj.js +1 -0
  56. package/console/_next/static/chunks/0vt1_fu_q116n.js +1 -0
  57. package/console/_next/static/chunks/0vuq85gcb9zcl.js +1 -0
  58. package/console/_next/static/chunks/0wxazby0i4xu3.js +5 -0
  59. package/console/_next/static/chunks/0yeh2zqwmmec0.js +22 -0
  60. package/console/_next/static/chunks/0zvl88sijsrqk.js +1 -0
  61. package/console/_next/static/chunks/110bgpy30m6m6.js +1 -0
  62. package/console/_next/static/chunks/14ipylvs6qyyw.js +1 -0
  63. package/console/_next/static/chunks/1745jt9onokna.js +1 -0
  64. package/console/_next/static/chunks/177rfq0tsoku9.js +4 -0
  65. package/console/_next/static/chunks/17mfsiiquey1d.js +1 -0
  66. package/console/_next/static/chunks/197iuvi8udifl.js +1 -0
  67. package/console/_next/static/chunks/1_2-z0tjk0xio.js +1 -0
  68. package/console/_next/static/chunks/1_gh5a14dqnji.js +1 -0
  69. package/console/_next/static/chunks/1ame8n7x9g3xc.js +1 -0
  70. package/console/_next/static/chunks/1apepr-7dz16b.js +1 -0
  71. package/console/_next/static/chunks/1dtukwrl8nulc.js +1 -0
  72. package/console/_next/static/chunks/1e0br64ibniud.js +24 -0
  73. package/console/_next/static/chunks/1fm-45g777ifx.js +1 -0
  74. package/console/_next/static/chunks/1g_iha5barqef.js +1 -0
  75. package/console/_next/static/chunks/1glr_lki18csr.js +2 -0
  76. package/console/_next/static/chunks/1hl355w6m5bp5.js +1 -0
  77. package/console/_next/static/chunks/1id3p9v9v5knn.js +1 -0
  78. package/console/_next/static/chunks/1j6kp4gg0_ylt.js +80 -0
  79. package/console/_next/static/chunks/1jssq3ch7qgd6.js +60 -0
  80. package/console/_next/static/chunks/1jzfyfh-3gqlb.js +1 -0
  81. package/console/_next/static/chunks/1k3d5c49mpp-2.js +1 -0
  82. package/console/_next/static/chunks/1kte_bxw9m-ie.js +1 -0
  83. package/console/_next/static/chunks/1lw52jm27gon2.js +1 -0
  84. package/console/_next/static/chunks/1m9e28v8syzxx.js +34 -0
  85. package/console/_next/static/chunks/1mrmq_pigo_yb.js +1 -0
  86. package/console/_next/static/chunks/1muf1a96cgbv5.js +1 -0
  87. package/console/_next/static/chunks/1n1x0ykt8by6w.js +1 -0
  88. package/console/_next/static/chunks/1qu0tqybdtj0_.js +1 -0
  89. package/console/_next/static/chunks/1r8itpdfffwxa.js +1 -0
  90. package/console/_next/static/chunks/1r_opkrpbuykx.js +1 -0
  91. package/console/_next/static/chunks/1tl0h3c_bp62t.js +1 -0
  92. package/console/_next/static/chunks/1v1m1fr8f0yle.js +1 -0
  93. package/console/_next/static/chunks/1v34vj52v7q0g.js +1 -0
  94. package/console/_next/static/chunks/1wztfxoxnu5_9.js +1 -0
  95. package/console/_next/static/chunks/1x7exm5d_hhb8.js +153 -0
  96. package/console/_next/static/chunks/1xwdphzrhi9cn.js +1 -0
  97. package/console/_next/static/chunks/1yc4gdqzxa5ie.js +1 -0
  98. package/console/_next/static/chunks/1zunrzvni97zi.js +1 -0
  99. package/console/_next/static/chunks/1zv6mtmekep40.js +36 -0
  100. package/console/_next/static/chunks/2-jaie5wchnsy.js +1 -0
  101. package/console/_next/static/chunks/20aa5hen470pm.js +1 -0
  102. package/console/_next/static/chunks/2116ko93nwgx8.js +1 -0
  103. package/console/_next/static/chunks/23vk0ig36j0he.js +1 -0
  104. package/console/_next/static/chunks/245vlws7l85dk.js +1 -0
  105. package/console/_next/static/chunks/24__o4dkdytc8.js +1 -0
  106. package/console/_next/static/chunks/24iwqo9ejhxl8.js +127 -0
  107. package/console/_next/static/chunks/24o9ia1be2cze.js +1 -0
  108. package/console/_next/static/chunks/25aea0bgjydel.css +1 -0
  109. package/console/_next/static/chunks/26-p2jxr4f20d.js +1 -0
  110. package/console/_next/static/chunks/28c--yt2jaxxf.js +1 -0
  111. package/console/_next/static/chunks/28vym848oh1ng.js +1 -0
  112. package/console/_next/static/chunks/29ou6qb6p1lni.js +1 -0
  113. package/console/_next/static/chunks/2aalpmeu_tni-.js +3 -0
  114. package/console/_next/static/chunks/2c4ifddi2dal0.js +20 -0
  115. package/console/_next/static/chunks/2ckm4edha_gkb.js +43 -0
  116. package/console/_next/static/chunks/2d5ods6a8n6yd.js +1 -0
  117. package/console/_next/static/chunks/2dm5g7ylrulvb.js +15 -0
  118. package/console/_next/static/chunks/2dtosus35_o5k.js +1 -0
  119. package/console/_next/static/chunks/2e0_cm1_wv-b4.js +1 -0
  120. package/console/_next/static/chunks/2fh_0n31hibdi.js +226 -0
  121. package/console/_next/static/chunks/2fjsaw5pgjcqb.js +1 -0
  122. package/console/_next/static/chunks/2h5pk3yu15nwr.js +1 -0
  123. package/console/_next/static/chunks/2i7w4yyf77gzw.js +1 -0
  124. package/console/_next/static/chunks/2jo3q7mfk65kd.js +1 -0
  125. package/console/_next/static/chunks/2jutbapb-t64n.js +31 -0
  126. package/console/_next/static/chunks/2k6tx8-w1creu.js +148 -0
  127. package/console/_next/static/chunks/2kh_m5onqedc5.js +1 -0
  128. package/console/_next/static/chunks/2ltzdgpjq3v6a.js +1 -0
  129. package/console/_next/static/chunks/2o2ftjhtb8od3.js +2 -0
  130. package/console/_next/static/chunks/2pyn841-jq-oo.js +10 -0
  131. package/console/_next/static/chunks/2rn289343m-y_.js +139 -0
  132. package/console/_next/static/chunks/2t2l3h2w_04bb.js +1 -0
  133. package/console/_next/static/chunks/2v11hooq3xd5t.js +15 -0
  134. package/console/_next/static/chunks/2vsg5t3fnqmfn.js +1 -0
  135. package/console/_next/static/chunks/2wayafjfoiq7q.css +6 -0
  136. package/console/_next/static/chunks/2xsvteosdtsb-.js +1 -0
  137. package/console/_next/static/chunks/2y-x8nhnufxzb.js +1 -0
  138. package/console/_next/static/chunks/2za4b-si894xj.js +1 -0
  139. package/console/_next/static/chunks/3-igvp1-n4pxs.js +104 -0
  140. package/console/_next/static/chunks/3-k25f-adpe5f.js +1 -0
  141. package/console/_next/static/chunks/3-pzmot7dbrfa.js +1 -0
  142. package/console/_next/static/chunks/3-x5lrgs3wcpl.js +80 -0
  143. package/console/_next/static/chunks/30nrkrr9518_z.js +1 -0
  144. package/console/_next/static/chunks/316lh1-hzgnod.js +1 -0
  145. package/console/_next/static/chunks/31wj1au8smjge.js +1 -0
  146. package/console/_next/static/chunks/329o6uup9qmb3.js +1 -0
  147. package/console/_next/static/chunks/34_1w929-5o6r.js +287 -0
  148. package/console/_next/static/chunks/35szx1ga574xu.js +1 -0
  149. package/console/_next/static/chunks/36tg522pkl8hm.js +1 -0
  150. package/console/_next/static/chunks/37-y9fgnir35a.js +1 -0
  151. package/console/_next/static/chunks/39wss1g0ffaqt.js +1 -0
  152. package/console/_next/static/chunks/3_cv0gj1bm3l6.js +1 -0
  153. package/console/_next/static/chunks/3_f8gd_6816re.js +101 -0
  154. package/console/_next/static/chunks/3a4qfuhsxefh2.js +12 -0
  155. package/console/_next/static/chunks/3asb3ztrvogwl.js +1 -0
  156. package/console/_next/static/chunks/3bsxbw10qhvqo.js +1 -0
  157. package/console/_next/static/chunks/3by94g38ljxl1.js +1 -0
  158. package/console/_next/static/chunks/3c_6owv8m4rta.js +90 -0
  159. package/console/_next/static/chunks/3ea2eo8b5gmju.js +2 -0
  160. package/console/_next/static/chunks/3ercnb2rksl_a.js +1 -0
  161. package/console/_next/static/chunks/3esxfmmm0ypxb.js +2 -0
  162. package/console/_next/static/chunks/3exiw74xbmika.js +1 -0
  163. package/console/_next/static/chunks/3f88-tc5u2heg.js +1 -0
  164. package/console/_next/static/chunks/3f_axahrombdp.js +1 -0
  165. package/console/_next/static/chunks/3gz91kn_v2lfa.js +1 -0
  166. package/console/_next/static/chunks/3i9z3x7tka5x2.js +1 -0
  167. package/console/_next/static/chunks/3ih4kfufd47st.js +1 -0
  168. package/console/_next/static/chunks/3itfi41ayfopd.js +15 -0
  169. package/console/_next/static/chunks/3iwgig-fgcscf.js +15 -0
  170. package/console/_next/static/chunks/3jf8qh1ev3gb4.js +2 -0
  171. package/console/_next/static/chunks/3l6svfyqdsq6o.js +1 -0
  172. package/console/_next/static/chunks/3lj0i-qlb4ah2.js +64 -0
  173. package/console/_next/static/chunks/3lmx6tkunfd3u.js +1 -0
  174. package/console/_next/static/chunks/3lp4d64he__am.js +152 -0
  175. package/console/_next/static/chunks/3m_jz3b2j38nn.js +1 -0
  176. package/console/_next/static/chunks/3oe9w1b39nzmn.js +3 -0
  177. package/console/_next/static/chunks/3on7r_d8o-kna.js +1 -0
  178. package/console/_next/static/chunks/3pbpowf3kdu5z.js +119 -0
  179. package/console/_next/static/chunks/3pwwv0u29nk8c.js +23 -0
  180. package/console/_next/static/chunks/3rweyye6o1z6b.js +79 -0
  181. package/console/_next/static/chunks/3sdqgrmvxm_u4.js +201 -0
  182. package/console/_next/static/chunks/3t3vbs-x5hixj.js +1 -0
  183. package/console/_next/static/chunks/3thqnz0a5zy-h.js +9 -0
  184. package/console/_next/static/chunks/3udubdawo7583.js +1 -0
  185. package/console/_next/static/chunks/3uz4lg6e199sb.js +1 -0
  186. package/console/_next/static/chunks/3v2mkz_46uei2.js +1 -0
  187. package/console/_next/static/chunks/3w5crjmhb-3um.js +1 -0
  188. package/console/_next/static/chunks/3waxhrmr_82j5.js +93 -0
  189. package/console/_next/static/chunks/3zmlzef_jxopu.js +1 -0
  190. package/console/_next/static/chunks/3zqvalj8nr-1y.js +1 -0
  191. package/console/_next/static/chunks/40igag4gq4k0a.js +77 -0
  192. package/console/_next/static/chunks/40wq034qcdji_.js +1 -0
  193. package/console/_next/static/chunks/44crhetqymq_e.js +34 -0
  194. package/console/_next/static/chunks/44q2pv6a3w19q.js +1 -0
  195. package/console/_next/static/chunks/turbopack-2u1d16houkiyo.js +1 -0
  196. package/console/_next/static/media/GeistMono_Variable-s.p.21mfa-4xv0w3g.woff2 +0 -0
  197. package/console/_next/static/media/Geist_Variable-s.p.217kyf1h_p0cg.woff2 +0 -0
  198. package/console/_next/static/media/IBMPlexMono_Medium-s.2v25u5rd2tsaf.woff2 +0 -0
  199. package/console/_next/static/media/IBMPlexMono_Regular-s.09u63wo58kris.woff2 +0 -0
  200. package/console/_next/static/media/IBMPlexSans_Bold-s.3iicodgz0epim.woff2 +0 -0
  201. package/console/_next/static/media/IBMPlexSans_Light-s.3ntejfdcyftfg.woff2 +0 -0
  202. package/console/_next/static/media/IBMPlexSans_Medium-s.3n25cgfiu6qss.woff2 +0 -0
  203. package/console/_next/static/media/IBMPlexSans_Regular-s.2e_-c_m03txvi.woff2 +0 -0
  204. package/console/_next/static/media/IBMPlexSans_SemiBold-s.2sutjpuns2xc5.woff2 +0 -0
  205. package/console/_next/static/media/Inter_Variable-s.2-lfiv6s83kzn.woff2 +0 -0
  206. package/console/_next/static/media/Nunito_Variable-s.3r4_r9s3kxd_-.woff2 +0 -0
  207. package/console/_not-found/__next._full.txt +73 -0
  208. package/console/_not-found/__next._index.txt +62 -0
  209. package/console/_not-found/__next._not-found.__PAGE__.txt +61 -0
  210. package/console/_not-found/__next._tree.txt +5 -0
  211. package/console/_not-found.html +1 -0
  212. package/console/_not-found.txt +73 -0
  213. package/console/apple-touch-icon-dark.png +0 -0
  214. package/console/apple-touch-icon-light.png +0 -0
  215. package/console/auth/callback/__next._full.txt +82 -0
  216. package/console/auth/callback/__next._index.txt +62 -0
  217. package/console/auth/callback/__next._tree.txt +8 -0
  218. package/console/auth/callback/__next.auth.callback.__PAGE__.txt +67 -0
  219. package/console/auth/callback.html +1 -0
  220. package/console/auth/callback.txt +82 -0
  221. package/console/auth/oauth/callback/__next._full.txt +84 -0
  222. package/console/auth/oauth/callback/__next._index.txt +62 -0
  223. package/console/auth/oauth/callback/__next._tree.txt +9 -0
  224. package/console/auth/oauth/callback/__next.auth.oauth.callback.__PAGE__.txt +69 -0
  225. package/console/auth/oauth/callback.html +1 -0
  226. package/console/auth/oauth/callback.txt +84 -0
  227. package/console/brand-avatar.png +0 -0
  228. package/console/chat/__placeholder__/__next._full.txt +80 -0
  229. package/console/chat/__placeholder__/__next._index.txt +62 -0
  230. package/console/chat/__placeholder__/__next._tree.txt +8 -0
  231. package/console/chat/__placeholder__/__next.chat.$d$channel.__PAGE__.txt +65 -0
  232. package/console/chat/__placeholder__.html +1 -0
  233. package/console/chat/__placeholder__.txt +80 -0
  234. package/console/connect/__placeholder__/__next._full.txt +79 -0
  235. package/console/connect/__placeholder__/__next._index.txt +62 -0
  236. package/console/connect/__placeholder__/__next._tree.txt +8 -0
  237. package/console/connect/__placeholder__/__next.connect.$d$token.__PAGE__.txt +64 -0
  238. package/console/connect/__placeholder__.html +1 -0
  239. package/console/connect/__placeholder__.txt +79 -0
  240. package/console/conversations/__next._full.txt +79 -0
  241. package/console/conversations/__next._index.txt +62 -0
  242. package/console/conversations/__next._tree.txt +7 -0
  243. package/console/conversations/__next.conversations.__PAGE__.txt +64 -0
  244. package/console/conversations/__placeholder__/__placeholder__/__next._full.txt +83 -0
  245. package/console/conversations/__placeholder__/__placeholder__/__next._index.txt +62 -0
  246. package/console/conversations/__placeholder__/__placeholder__/__next._tree.txt +9 -0
  247. package/console/conversations/__placeholder__/__placeholder__/__next.conversations.$d$channelId.$d$key.__PAGE__.txt +68 -0
  248. package/console/conversations/__placeholder__/__placeholder__.html +1 -0
  249. package/console/conversations/__placeholder__/__placeholder__.txt +83 -0
  250. package/console/conversations.html +1 -0
  251. package/console/conversations.txt +79 -0
  252. package/console/dashboard/__next._full.txt +77 -0
  253. package/console/dashboard/__next._index.txt +62 -0
  254. package/console/dashboard/__next._tree.txt +7 -0
  255. package/console/dashboard/__next.dashboard.__PAGE__.txt +62 -0
  256. package/console/dashboard.html +1 -0
  257. package/console/dashboard.txt +77 -0
  258. package/console/desktop/billing/__next._full.txt +82 -0
  259. package/console/desktop/billing/__next._index.txt +62 -0
  260. package/console/desktop/billing/__next._tree.txt +8 -0
  261. package/console/desktop/billing/__next.desktop.billing.__PAGE__.txt +67 -0
  262. package/console/desktop/billing.html +1 -0
  263. package/console/desktop/billing.txt +82 -0
  264. package/console/embed.js +1 -0
  265. package/console/favicon-dark-16x16.png +0 -0
  266. package/console/favicon-dark-32x32.png +0 -0
  267. package/console/favicon-dark.ico +0 -0
  268. package/console/favicon-dark.svg +1 -0
  269. package/console/favicon-light-16x16.png +0 -0
  270. package/console/favicon-light-32x32.png +0 -0
  271. package/console/favicon-light.ico +0 -0
  272. package/console/favicon-light.svg +1 -0
  273. package/console/index.html +1 -0
  274. package/console/index.txt +71 -0
  275. package/console/invite/__placeholder__/__next._full.txt +80 -0
  276. package/console/invite/__placeholder__/__next._index.txt +62 -0
  277. package/console/invite/__placeholder__/__next._tree.txt +8 -0
  278. package/console/invite/__placeholder__/__next.invite.$d$token.__PAGE__.txt +65 -0
  279. package/console/invite/__placeholder__.html +1 -0
  280. package/console/invite/__placeholder__.txt +80 -0
  281. package/console/library/__next._full.txt +89 -0
  282. package/console/library/__next._index.txt +62 -0
  283. package/console/library/__next._tree.txt +7 -0
  284. package/console/library/__next.library.__PAGE__.txt +74 -0
  285. package/console/library/agents/__next._full.txt +94 -0
  286. package/console/library/agents/__next._index.txt +62 -0
  287. package/console/library/agents/__next._tree.txt +8 -0
  288. package/console/library/agents/__next.library.agents.__PAGE__.txt +79 -0
  289. package/console/library/agents/__placeholder__/__placeholder__/__next._full.txt +96 -0
  290. package/console/library/agents/__placeholder__/__placeholder__/__next._index.txt +62 -0
  291. package/console/library/agents/__placeholder__/__placeholder__/__next._tree.txt +10 -0
  292. package/console/library/agents/__placeholder__/__placeholder__/__next.library.agents.$d$org.$d$slug.__PAGE__.txt +81 -0
  293. package/console/library/agents/__placeholder__/__placeholder__.html +1 -0
  294. package/console/library/agents/__placeholder__/__placeholder__.txt +96 -0
  295. package/console/library/agents/new/__next._full.txt +99 -0
  296. package/console/library/agents/new/__next._index.txt +62 -0
  297. package/console/library/agents/new/__next._tree.txt +9 -0
  298. package/console/library/agents/new/__next.library.agents.new.__PAGE__.txt +84 -0
  299. package/console/library/agents/new.html +1 -0
  300. package/console/library/agents/new.txt +99 -0
  301. package/console/library/agents.html +1 -0
  302. package/console/library/agents.txt +94 -0
  303. package/console/library/environments/__next._full.txt +95 -0
  304. package/console/library/environments/__next._index.txt +62 -0
  305. package/console/library/environments/__next._tree.txt +8 -0
  306. package/console/library/environments/__next.library.environments.__PAGE__.txt +80 -0
  307. package/console/library/environments/__placeholder__/__placeholder__/__next._full.txt +97 -0
  308. package/console/library/environments/__placeholder__/__placeholder__/__next._index.txt +62 -0
  309. package/console/library/environments/__placeholder__/__placeholder__/__next._tree.txt +10 -0
  310. package/console/library/environments/__placeholder__/__placeholder__/__next.library.environments.$d$org.$d$slug.__PAGE__.txt +82 -0
  311. package/console/library/environments/__placeholder__/__placeholder__.html +1 -0
  312. package/console/library/environments/__placeholder__/__placeholder__.txt +97 -0
  313. package/console/library/environments/new/__next._full.txt +99 -0
  314. package/console/library/environments/new/__next._index.txt +62 -0
  315. package/console/library/environments/new/__next._tree.txt +9 -0
  316. package/console/library/environments/new/__next.library.environments.new.__PAGE__.txt +84 -0
  317. package/console/library/environments/new.html +1 -0
  318. package/console/library/environments/new.txt +99 -0
  319. package/console/library/environments.html +1 -0
  320. package/console/library/environments.txt +95 -0
  321. package/console/library/files/__next._full.txt +94 -0
  322. package/console/library/files/__next._index.txt +62 -0
  323. package/console/library/files/__next._tree.txt +8 -0
  324. package/console/library/files/__next.library.files.__PAGE__.txt +79 -0
  325. package/console/library/files.html +1 -0
  326. package/console/library/files.txt +94 -0
  327. package/console/library/plugins/__next._full.txt +94 -0
  328. package/console/library/plugins/__next._index.txt +62 -0
  329. package/console/library/plugins/__next._tree.txt +8 -0
  330. package/console/library/plugins/__next.library.plugins.__PAGE__.txt +79 -0
  331. package/console/library/plugins/__placeholder__/__placeholder__/__next._full.txt +97 -0
  332. package/console/library/plugins/__placeholder__/__placeholder__/__next._index.txt +62 -0
  333. package/console/library/plugins/__placeholder__/__placeholder__/__next._tree.txt +10 -0
  334. package/console/library/plugins/__placeholder__/__placeholder__/__next.library.plugins.$d$org.$d$slug.__PAGE__.txt +82 -0
  335. package/console/library/plugins/__placeholder__/__placeholder__.html +1 -0
  336. package/console/library/plugins/__placeholder__/__placeholder__.txt +97 -0
  337. package/console/library/plugins/upload/__next._full.txt +99 -0
  338. package/console/library/plugins/upload/__next._index.txt +62 -0
  339. package/console/library/plugins/upload/__next._tree.txt +9 -0
  340. package/console/library/plugins/upload/__next.library.plugins.upload.__PAGE__.txt +84 -0
  341. package/console/library/plugins/upload.html +1 -0
  342. package/console/library/plugins/upload.txt +99 -0
  343. package/console/library/plugins.html +1 -0
  344. package/console/library/plugins.txt +94 -0
  345. package/console/library/routines/__next._full.txt +94 -0
  346. package/console/library/routines/__next._index.txt +62 -0
  347. package/console/library/routines/__next._tree.txt +8 -0
  348. package/console/library/routines/__next.library.routines.__PAGE__.txt +79 -0
  349. package/console/library/routines/__placeholder__/__placeholder__/__next._full.txt +97 -0
  350. package/console/library/routines/__placeholder__/__placeholder__/__next._index.txt +62 -0
  351. package/console/library/routines/__placeholder__/__placeholder__/__next._tree.txt +10 -0
  352. package/console/library/routines/__placeholder__/__placeholder__/__next.library.routines.$d$org.$d$slug.__PAGE__.txt +82 -0
  353. package/console/library/routines/__placeholder__/__placeholder__.html +1 -0
  354. package/console/library/routines/__placeholder__/__placeholder__.txt +97 -0
  355. package/console/library/routines/new/__next._full.txt +98 -0
  356. package/console/library/routines/new/__next._index.txt +62 -0
  357. package/console/library/routines/new/__next._tree.txt +9 -0
  358. package/console/library/routines/new/__next.library.routines.new.__PAGE__.txt +83 -0
  359. package/console/library/routines/new.html +1 -0
  360. package/console/library/routines/new.txt +98 -0
  361. package/console/library/routines.html +1 -0
  362. package/console/library/routines.txt +94 -0
  363. package/console/library/skills/__next._full.txt +94 -0
  364. package/console/library/skills/__next._index.txt +62 -0
  365. package/console/library/skills/__next._tree.txt +8 -0
  366. package/console/library/skills/__next.library.skills.__PAGE__.txt +79 -0
  367. package/console/library/skills/__placeholder__/__placeholder__/__next._full.txt +96 -0
  368. package/console/library/skills/__placeholder__/__placeholder__/__next._index.txt +62 -0
  369. package/console/library/skills/__placeholder__/__placeholder__/__next._tree.txt +10 -0
  370. package/console/library/skills/__placeholder__/__placeholder__/__next.library.skills.$d$org.$d$slug.__PAGE__.txt +81 -0
  371. package/console/library/skills/__placeholder__/__placeholder__.html +1 -0
  372. package/console/library/skills/__placeholder__/__placeholder__.txt +96 -0
  373. package/console/library/skills/new/__next._full.txt +98 -0
  374. package/console/library/skills/new/__next._index.txt +62 -0
  375. package/console/library/skills/new/__next._tree.txt +9 -0
  376. package/console/library/skills/new/__next.library.skills.new.__PAGE__.txt +83 -0
  377. package/console/library/skills/new.html +1 -0
  378. package/console/library/skills/new.txt +98 -0
  379. package/console/library/skills.html +1 -0
  380. package/console/library/skills.txt +94 -0
  381. package/console/library.html +1 -0
  382. package/console/library.txt +89 -0
  383. package/console/login/__next._full.txt +81 -0
  384. package/console/login/__next._index.txt +62 -0
  385. package/console/login/__next._tree.txt +7 -0
  386. package/console/login/__next.login.__PAGE__.txt +66 -0
  387. package/console/login.html +1 -0
  388. package/console/login.txt +81 -0
  389. package/console/marketplace/__next._full.txt +81 -0
  390. package/console/marketplace/__next._index.txt +62 -0
  391. package/console/marketplace/__next._tree.txt +7 -0
  392. package/console/marketplace/__next.marketplace.__PAGE__.txt +66 -0
  393. package/console/marketplace.html +1 -0
  394. package/console/marketplace.txt +81 -0
  395. package/console/models/__next._full.txt +77 -0
  396. package/console/models/__next._index.txt +62 -0
  397. package/console/models/__next._tree.txt +7 -0
  398. package/console/models/__next.models.__PAGE__.txt +62 -0
  399. package/console/models.html +1 -0
  400. package/console/models.txt +77 -0
  401. package/console/oauth/slack/callback/__next._full.txt +84 -0
  402. package/console/oauth/slack/callback/__next._index.txt +62 -0
  403. package/console/oauth/slack/callback/__next._tree.txt +9 -0
  404. package/console/oauth/slack/callback/__next.oauth.slack.callback.__PAGE__.txt +69 -0
  405. package/console/oauth/slack/callback.html +1 -0
  406. package/console/oauth/slack/callback.txt +84 -0
  407. package/console/runs/__placeholder__/__next._full.txt +77 -0
  408. package/console/runs/__placeholder__/__next._index.txt +62 -0
  409. package/console/runs/__placeholder__/__next._tree.txt +8 -0
  410. package/console/runs/__placeholder__/__next.runs.$d$id.__PAGE__.txt +62 -0
  411. package/console/runs/__placeholder__.html +1 -0
  412. package/console/runs/__placeholder__.txt +77 -0
  413. package/console/sessions/__placeholder__/__next._full.txt +77 -0
  414. package/console/sessions/__placeholder__/__next._index.txt +62 -0
  415. package/console/sessions/__placeholder__/__next._tree.txt +8 -0
  416. package/console/sessions/__placeholder__/__next.sessions.$d$id.__PAGE__.txt +62 -0
  417. package/console/sessions/__placeholder__.html +1 -0
  418. package/console/sessions/__placeholder__.txt +77 -0
  419. package/console/settings/__next._full.txt +85 -0
  420. package/console/settings/__next._index.txt +62 -0
  421. package/console/settings/__next._tree.txt +7 -0
  422. package/console/settings/__next.settings.__PAGE__.txt +70 -0
  423. package/console/settings/access-history/__next._full.txt +87 -0
  424. package/console/settings/access-history/__next._index.txt +62 -0
  425. package/console/settings/access-history/__next._tree.txt +8 -0
  426. package/console/settings/access-history/__next.settings.access-history.__PAGE__.txt +72 -0
  427. package/console/settings/access-history.html +1 -0
  428. package/console/settings/access-history.txt +87 -0
  429. package/console/settings/account-preferences/__next._full.txt +87 -0
  430. package/console/settings/account-preferences/__next._index.txt +62 -0
  431. package/console/settings/account-preferences/__next._tree.txt +8 -0
  432. package/console/settings/account-preferences/__next.settings.account-preferences.__PAGE__.txt +72 -0
  433. package/console/settings/account-preferences.html +1 -0
  434. package/console/settings/account-preferences.txt +87 -0
  435. package/console/settings/api-keys/__next._full.txt +86 -0
  436. package/console/settings/api-keys/__next._index.txt +62 -0
  437. package/console/settings/api-keys/__next._tree.txt +8 -0
  438. package/console/settings/api-keys/__next.settings.api-keys.__PAGE__.txt +71 -0
  439. package/console/settings/api-keys.html +1 -0
  440. package/console/settings/api-keys.txt +86 -0
  441. package/console/settings/billing/__next._full.txt +89 -0
  442. package/console/settings/billing/__next._index.txt +62 -0
  443. package/console/settings/billing/__next._tree.txt +8 -0
  444. package/console/settings/billing/__next.settings.billing.__PAGE__.txt +74 -0
  445. package/console/settings/billing.html +1 -0
  446. package/console/settings/billing.txt +89 -0
  447. package/console/settings/channel-apps/__next._full.txt +87 -0
  448. package/console/settings/channel-apps/__next._index.txt +62 -0
  449. package/console/settings/channel-apps/__next._tree.txt +8 -0
  450. package/console/settings/channel-apps/__next.settings.channel-apps.__PAGE__.txt +72 -0
  451. package/console/settings/channel-apps.html +1 -0
  452. package/console/settings/channel-apps.txt +87 -0
  453. package/console/settings/federation-issuers/__next._full.txt +88 -0
  454. package/console/settings/federation-issuers/__next._index.txt +62 -0
  455. package/console/settings/federation-issuers/__next._tree.txt +8 -0
  456. package/console/settings/federation-issuers/__next.settings.federation-issuers.__PAGE__.txt +73 -0
  457. package/console/settings/federation-issuers.html +1 -0
  458. package/console/settings/federation-issuers.txt +88 -0
  459. package/console/settings/invitations/__next._full.txt +87 -0
  460. package/console/settings/invitations/__next._index.txt +62 -0
  461. package/console/settings/invitations/__next._tree.txt +8 -0
  462. package/console/settings/invitations/__next.settings.invitations.__PAGE__.txt +72 -0
  463. package/console/settings/invitations.html +1 -0
  464. package/console/settings/invitations.txt +87 -0
  465. package/console/settings/licenses/__next._full.txt +90 -0
  466. package/console/settings/licenses/__next._index.txt +62 -0
  467. package/console/settings/licenses/__next._tree.txt +8 -0
  468. package/console/settings/licenses/__next.settings.licenses.__PAGE__.txt +75 -0
  469. package/console/settings/licenses.html +1 -0
  470. package/console/settings/licenses.txt +90 -0
  471. package/console/settings/members/__next._full.txt +86 -0
  472. package/console/settings/members/__next._index.txt +62 -0
  473. package/console/settings/members/__next._tree.txt +8 -0
  474. package/console/settings/members/__next.settings.members.__PAGE__.txt +71 -0
  475. package/console/settings/members.html +1 -0
  476. package/console/settings/members.txt +86 -0
  477. package/console/settings/memory/__next._full.txt +86 -0
  478. package/console/settings/memory/__next._index.txt +62 -0
  479. package/console/settings/memory/__next._tree.txt +8 -0
  480. package/console/settings/memory/__next.settings.memory.__PAGE__.txt +71 -0
  481. package/console/settings/memory.html +1 -0
  482. package/console/settings/memory.txt +86 -0
  483. package/console/settings/model-catalog/__next._full.txt +89 -0
  484. package/console/settings/model-catalog/__next._index.txt +62 -0
  485. package/console/settings/model-catalog/__next._tree.txt +8 -0
  486. package/console/settings/model-catalog/__next.settings.model-catalog.__PAGE__.txt +74 -0
  487. package/console/settings/model-catalog.html +1 -0
  488. package/console/settings/model-catalog.txt +89 -0
  489. package/console/settings/notifications/__next._full.txt +89 -0
  490. package/console/settings/notifications/__next._index.txt +62 -0
  491. package/console/settings/notifications/__next._tree.txt +8 -0
  492. package/console/settings/notifications/__next.settings.notifications.__PAGE__.txt +74 -0
  493. package/console/settings/notifications.html +1 -0
  494. package/console/settings/notifications.txt +89 -0
  495. package/console/settings/oauth-apps/__next._full.txt +87 -0
  496. package/console/settings/oauth-apps/__next._index.txt +62 -0
  497. package/console/settings/oauth-apps/__next._tree.txt +8 -0
  498. package/console/settings/oauth-apps/__next.settings.oauth-apps.__PAGE__.txt +72 -0
  499. package/console/settings/oauth-apps.html +1 -0
  500. package/console/settings/oauth-apps.txt +87 -0
  501. package/console/settings/org-embedding/__next._full.txt +87 -0
  502. package/console/settings/org-embedding/__next._index.txt +62 -0
  503. package/console/settings/org-embedding/__next._tree.txt +8 -0
  504. package/console/settings/org-embedding/__next.settings.org-embedding.__PAGE__.txt +72 -0
  505. package/console/settings/org-embedding.html +1 -0
  506. package/console/settings/org-embedding.txt +87 -0
  507. package/console/settings/org-policies/__next._full.txt +87 -0
  508. package/console/settings/org-policies/__next._index.txt +62 -0
  509. package/console/settings/org-policies/__next._tree.txt +8 -0
  510. package/console/settings/org-policies/__next.settings.org-policies.__PAGE__.txt +72 -0
  511. package/console/settings/org-policies.html +1 -0
  512. package/console/settings/org-policies.txt +87 -0
  513. package/console/settings/org-preferences/__next._full.txt +87 -0
  514. package/console/settings/org-preferences/__next._index.txt +62 -0
  515. package/console/settings/org-preferences/__next._tree.txt +8 -0
  516. package/console/settings/org-preferences/__next.settings.org-preferences.__PAGE__.txt +72 -0
  517. package/console/settings/org-preferences.html +1 -0
  518. package/console/settings/org-preferences.txt +87 -0
  519. package/console/settings/org-profile/__next._full.txt +89 -0
  520. package/console/settings/org-profile/__next._index.txt +62 -0
  521. package/console/settings/org-profile/__next._tree.txt +8 -0
  522. package/console/settings/org-profile/__next.settings.org-profile.__PAGE__.txt +74 -0
  523. package/console/settings/org-profile.html +1 -0
  524. package/console/settings/org-profile.txt +89 -0
  525. package/console/settings/plans/__next._full.txt +89 -0
  526. package/console/settings/plans/__next._index.txt +62 -0
  527. package/console/settings/plans/__next._tree.txt +8 -0
  528. package/console/settings/plans/__next.settings.plans.__PAGE__.txt +74 -0
  529. package/console/settings/plans.html +1 -0
  530. package/console/settings/plans.txt +89 -0
  531. package/console/settings/service-accounts/__next._full.txt +87 -0
  532. package/console/settings/service-accounts/__next._index.txt +62 -0
  533. package/console/settings/service-accounts/__next._tree.txt +8 -0
  534. package/console/settings/service-accounts/__next.settings.service-accounts.__PAGE__.txt +72 -0
  535. package/console/settings/service-accounts.html +1 -0
  536. package/console/settings/service-accounts.txt +87 -0
  537. package/console/settings/teams/__next._full.txt +86 -0
  538. package/console/settings/teams/__next._index.txt +62 -0
  539. package/console/settings/teams/__next._tree.txt +8 -0
  540. package/console/settings/teams/__next.settings.teams.__PAGE__.txt +71 -0
  541. package/console/settings/teams.html +1 -0
  542. package/console/settings/teams.txt +86 -0
  543. package/console/settings/usage/__next._full.txt +86 -0
  544. package/console/settings/usage/__next._index.txt +62 -0
  545. package/console/settings/usage/__next._tree.txt +8 -0
  546. package/console/settings/usage/__next.settings.usage.__PAGE__.txt +71 -0
  547. package/console/settings/usage.html +1 -0
  548. package/console/settings/usage.txt +86 -0
  549. package/console/settings/vaults/__next._full.txt +86 -0
  550. package/console/settings/vaults/__next._index.txt +62 -0
  551. package/console/settings/vaults/__next._tree.txt +8 -0
  552. package/console/settings/vaults/__next.settings.vaults.__PAGE__.txt +71 -0
  553. package/console/settings/vaults.html +1 -0
  554. package/console/settings/vaults.txt +86 -0
  555. package/console/settings.html +1 -0
  556. package/console/settings.txt +85 -0
  557. package/main.js +1656 -0
  558. package/mappings.wasm +0 -0
  559. package/package.json +25 -0
  560. package/workflow-bundle-agent-execution.js +29297 -0
  561. package/workflow-bundle-evals.js +11997 -0
  562. package/workflow-bundle-grading.js +11155 -0
  563. package/workflow-bundle-routine.js +11300 -0
  564. package/workflow-worker-thread.cjs +111 -0
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,248018,t=>{"use strict";var i,e=t.i(332090),s=t.i(864421),a=t.i(669587),n=t.i(908381),h=t.i(171206);t.i(947716);var o=t.i(365332),r=t.i(65232);function l(){var t,i,e=(0,r.f)().unknown(void 0),s=e.domain,a=e.range,n=0,h=1,c=!1,g=0,u=0,x=.5;function p(){var e=s().length,o=h<n,r=o?h:n,l=o?n:h;t=(l-r)/Math.max(1,e-g+2*u),c&&(t=Math.floor(t)),r+=(l-r-t*(e-g))*x,i=t*(1-g),c&&(r=Math.round(r),i=Math.round(i));var p=(function(t,i,e){t*=1,i*=1,e=(a=arguments.length)<2?(i=t,t=0,1):a<3?1:+e;for(var s=-1,a=0|Math.max(0,Math.ceil((i-t)/e)),n=Array(a);++s<a;)n[s]=t+s*e;return n})(e).map(function(i){return r+t*i});return a(o?p.reverse():p)}return delete e.unknown,e.domain=function(t){return arguments.length?(s(t),p()):s()},e.range=function(t){return arguments.length?([n,h]=t,n*=1,h*=1,p()):[n,h]},e.rangeRound=function(t){return[n,h]=t,n*=1,h*=1,c=!0,p()},e.bandwidth=function(){return i},e.step=function(){return t},e.round=function(t){return arguments.length?(c=!!t,p()):c},e.padding=function(t){return arguments.length?(g=Math.min(1,u=+t),p()):g},e.paddingInner=function(t){return arguments.length?(g=Math.min(1,t),p()):g},e.paddingOuter=function(t){return arguments.length?(u=+t,p()):u},e.align=function(t){return arguments.length?(x=Math.max(0,Math.min(1,t)),p()):x},e.copy=function(){return l(s(),[n,h]).round(c).paddingInner(g).paddingOuter(u).align(x)},o.f.apply(p(),arguments)}var c=t.i(282803),g=t.i(785833),u=function(){var t=(0,h.p)(function(t,i,e,s){for(e=e||{},s=t.length;s--;e[t[s]]=i);return e},"o"),i=[1,10,12,14,16,18,19,21,23],e=[2,6],s=[1,3],a=[1,5],n=[1,6],o=[1,7],r=[1,5,10,12,14,16,18,19,21,23,34,35,36],l=[1,25],c=[1,26],g=[1,28],u=[1,29],x=[1,30],p=[1,31],d=[1,32],f=[1,33],m=[1,34],y=[1,35],b=[1,36],A=[1,37],w=[1,43],S=[1,42],C=[1,47],k=[1,50],_=[1,10,12,14,16,18,19,21,23,34,35,36],T=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],R=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],D=[1,64],L={trace:(0,h.p)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:(0,h.p)(function(t,i,e,s,a,n,h){var o=n.length-1;switch(a){case 5:s.setOrientation(n[o]);break;case 9:s.setDiagramTitle(n[o].text.trim());break;case 12:s.setLineData({text:"",type:"text"},n[o]);break;case 13:s.setLineData(n[o-1],n[o]);break;case 14:s.setBarData({text:"",type:"text"},n[o]);break;case 15:s.setBarData(n[o-1],n[o]);break;case 16:this.$=n[o].trim(),s.setAccTitle(this.$);break;case 17:case 18:this.$=n[o].trim(),s.setAccDescription(this.$);break;case 19:case 27:this.$=n[o-1];break;case 20:this.$=[Number(n[o-2]),...n[o]];break;case 21:this.$=[Number(n[o])];break;case 22:s.setXAxisTitle(n[o]);break;case 23:s.setXAxisTitle(n[o-1]);break;case 24:s.setXAxisTitle({type:"text",text:""});break;case 25:s.setXAxisBand(n[o]);break;case 26:s.setXAxisRangeData(Number(n[o-2]),Number(n[o]));break;case 28:this.$=[n[o-2],...n[o]];break;case 29:this.$=[n[o]];break;case 30:s.setYAxisTitle(n[o]);break;case 31:s.setYAxisTitle(n[o-1]);break;case 32:s.setYAxisTitle({type:"text",text:""});break;case 33:s.setYAxisRangeData(Number(n[o-2]),Number(n[o]));break;case 37:case 38:this.$={text:n[o],type:"text"};break;case 39:this.$={text:n[o],type:"markdown"};break;case 40:this.$=n[o];break;case 41:this.$=n[o-1]+""+n[o]}},"anonymous"),table:[t(i,e,{3:1,4:2,7:4,5:s,34:a,35:n,36:o}),{1:[3]},t(i,e,{4:2,7:4,3:8,5:s,34:a,35:n,36:o}),t(i,e,{4:2,7:4,6:9,3:10,5:s,8:[1,11],34:a,35:n,36:o}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},t(r,[2,34]),t(r,[2,35]),t(r,[2,36]),{1:[2,1]},t(i,e,{4:2,7:4,3:21,5:s,34:a,35:n,36:o}),{1:[2,3]},t(r,[2,5]),t(i,[2,7],{4:22,34:a,35:n,36:o}),{11:23,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},{11:39,13:38,24:w,27:S,29:40,30:41,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},{11:45,15:44,27:C,33:46,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},{11:49,17:48,24:k,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},{11:52,17:51,24:k,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},{20:[1,53]},{22:[1,54]},t(_,[2,18]),{1:[2,2]},t(_,[2,8]),t(_,[2,9]),t(T,[2,37],{40:55,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A}),t(T,[2,38]),t(T,[2,39]),t(R,[2,40]),t(R,[2,42]),t(R,[2,43]),t(R,[2,44]),t(R,[2,45]),t(R,[2,46]),t(R,[2,47]),t(R,[2,48]),t(R,[2,49]),t(R,[2,50]),t(R,[2,51]),t(_,[2,10]),t(_,[2,22],{30:41,29:56,24:w,27:S}),t(_,[2,24]),t(_,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},t(_,[2,11]),t(_,[2,30],{33:60,27:C}),t(_,[2,32]),{31:[1,61]},t(_,[2,12]),{17:62,24:k},{25:63,27:D},t(_,[2,14]),{17:65,24:k},t(_,[2,16]),t(_,[2,17]),t(R,[2,41]),t(_,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},t(_,[2,31]),{27:[1,69]},t(_,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},t(_,[2,15]),t(_,[2,26]),t(_,[2,27]),{11:59,32:72,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:p,45:d,46:f,47:m,48:y,49:b,50:A},t(_,[2,33]),t(_,[2,19]),{25:73,27:D},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:(0,h.p)(function(t,i){if(i.recoverable)this.trace(t);else{var e=Error(t);throw e.hash=i,e}},"parseError"),parse:(0,h.p)(function(t){var i=this,e=[0],s=[],a=[null],n=[],o=this.table,r="",l=0,c=0,g=0,u=n.slice.call(arguments,1),x=Object.create(this.lexer),p={};for(var d in this.yy)Object.prototype.hasOwnProperty.call(this.yy,d)&&(p[d]=this.yy[d]);x.setInput(t,p),p.lexer=x,p.parser=this,void 0===x.yylloc&&(x.yylloc={});var f=x.yylloc;n.push(f);var m=x.options&&x.options.ranges;function y(){var t;return"number"!=typeof(t=s.pop()||x.lex()||1)&&(t instanceof Array&&(t=(s=t).pop()),t=i.symbols_[t]||t),t}"function"==typeof p.parseError?this.parseError=p.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,h.p)(function(t){e.length=e.length-2*t,a.length=a.length-t,n.length=n.length-t},"popStack"),(0,h.p)(y,"lex");for(var b,A,w,S,C,k,_,T,R,D={};;){if(w=e[e.length-1],this.defaultActions[w]?S=this.defaultActions[w]:(null==b&&(b=y()),S=o[w]&&o[w][b]),void 0===S||!S.length||!S[0]){var L="";for(k in R=[],o[w])this.terminals_[k]&&k>2&&R.push("'"+this.terminals_[k]+"'");L=x.showPosition?"Parse error on line "+(l+1)+":\n"+x.showPosition()+"\nExpecting "+R.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(l+1)+": Unexpected "+(1==b?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(L,{text:x.match,token:this.terminals_[b]||b,line:x.yylineno,loc:f,expected:R})}if(S[0]instanceof Array&&S.length>1)throw Error("Parse Error: multiple actions possible at state: "+w+", token: "+b);switch(S[0]){case 1:e.push(b),a.push(x.yytext),n.push(x.yylloc),e.push(S[1]),b=null,A?(b=A,A=null):(c=x.yyleng,r=x.yytext,l=x.yylineno,f=x.yylloc,g>0&&g--);break;case 2:if(_=this.productions_[S[1]][1],D.$=a[a.length-_],D._$={first_line:n[n.length-(_||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(_||1)].first_column,last_column:n[n.length-1].last_column},m&&(D._$.range=[n[n.length-(_||1)].range[0],n[n.length-1].range[1]]),void 0!==(C=this.performAction.apply(D,[r,c,l,p,S[1],a,n].concat(u))))return C;_&&(e=e.slice(0,-1*_*2),a=a.slice(0,-1*_),n=n.slice(0,-1*_)),e.push(this.productions_[S[1]][0]),a.push(D.$),n.push(D._$),T=o[e[e.length-2]][e[e.length-1]],e.push(T);break;case 3:return!0}}return!0},"parse")};function P(){this.yy={}}return L.lexer={EOF:1,parseError:(0,h.p)(function(t,i){if(this.yy.parser)this.yy.parser.parseError(t,i);else throw Error(t)},"parseError"),setInput:(0,h.p)(function(t,i){return this.yy=i||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,h.p)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,h.p)(function(t){var i=t.length,e=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var s=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),e.length-1&&(this.yylineno-=e.length-1);var a=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:e?(e.length===s.length?this.yylloc.first_column:0)+s[s.length-e.length].length-e[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[a[0],a[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:(0,h.p)(function(){return this._more=!0,this},"more"),reject:(0,h.p)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,h.p)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,h.p)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,h.p)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,h.p)(function(){var t=this.pastInput(),i=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+i+"^"},"showPosition"),test_match:(0,h.p)(function(t,i){var e,s,a;if(this.options.backtrack_lexer&&(a={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(a.yylloc.range=this.yylloc.range.slice(0))),(s=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=s.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:s?s[s.length-1].length-s[s.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],e=this.performAction.call(this,this.yy,this,i,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),e)return e;if(this._backtrack)for(var n in a)this[n]=a[n];return!1},"test_match"),next:(0,h.p)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,i,e,s,a=this._currentRules(),n=0;n<a.length;n++)if((e=this._input.match(this.rules[a[n]]))&&(!i||e[0].length>i[0].length)){if(i=e,s=n,this.options.backtrack_lexer){if(!1!==(t=this.test_match(e,a[n])))return t;if(!this._backtrack)return!1;i=!1;continue}if(!this.options.flex)break}return i?!1!==(t=this.test_match(i,a[s]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,h.p)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,h.p)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,h.p)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,h.p)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,h.p)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,h.p)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,h.p)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,h.p)(function(t,i,e,s){switch(e){case 0:case 1:case 5:case 44:break;case 2:case 3:return this.popState(),34;case 4:return 34;case 6:return 10;case 7:return this.pushState("acc_title"),19;case 8:return this.popState(),"acc_title_value";case 9:return this.pushState("acc_descr"),21;case 10:return this.popState(),"acc_descr_value";case 11:this.pushState("acc_descr_multiline");break;case 12:case 26:case 28:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:case 15:return 5;case 16:return 8;case 17:return this.pushState("axis_data"),"X_AXIS";case 18:return this.pushState("axis_data"),"Y_AXIS";case 19:return this.pushState("axis_band_data"),24;case 20:return 31;case 21:return this.pushState("data"),16;case 22:return this.pushState("data"),18;case 23:return this.pushState("data_inner"),24;case 24:return 27;case 25:return this.popState(),26;case 27:this.pushState("string");break;case 29:return"STR";case 30:return 24;case 31:return 26;case 32:return 43;case 33:return"COLON";case 34:return 44;case 35:return 28;case 36:return 45;case 37:return 46;case 38:return 48;case 39:return 50;case 40:return 47;case 41:return 41;case 42:return 49;case 43:return 42;case 45:return 35;case 46:return 36}},"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\})/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:xychart\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n<md_string>\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n<md_string>\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,24,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,18,21,22,23,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,22,24,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0}}},(0,h.p)(P,"Parser"),P.prototype=L,L.Parser=P,new P}();function x(t){return"bar"===t.type}function p(t){return"band"===t.type}function d(t){return"linear"===t.type}u.parser=u,(0,h.p)(x,"isBarPlot"),(0,h.p)(p,"isBandAxisData"),(0,h.p)(d,"isLinearAxisData");var f=class{constructor(t){this.parentGroup=t}static{(0,h.p)(this,"TextDimensionCalculatorWithFont")}getMaxDimension(t,i){if(!this.parentGroup)return{width:t.reduce((t,i)=>Math.max(i.length,t),0)*i,height:i};let e={width:0,height:0},a=this.parentGroup.append("g").attr("visibility","hidden").attr("font-size",i);for(let n of t){let t=(0,s.f)(a,1,n),h=t?t.width:n.length*i,o=t?t.height:i;e.width=Math.max(e.width,h),e.height=Math.max(e.height,o)}return a.remove(),e}},m=class{constructor(t,i,e,s){this.axisConfig=t,this.title=i,this.textDimensionCalculator=e,this.axisThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left",this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left"}static{(0,h.p)(this,"BaseAxis")}setRange(t){this.range=t,"left"===this.axisPosition||"right"===this.axisPosition?this.boundingRect.height=t[1]-t[0]:this.boundingRect.width=t[1]-t[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(t){this.axisPosition=t,this.setRange(this.range)}getTickDistance(){let t=this.getRange();return Math.abs(t[0]-t[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map(t=>t.toString()),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){.7*this.getTickDistance()>2*this.outerPadding&&(this.outerPadding=Math.floor(.7*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(t){let i=t.height;if(this.axisConfig.showAxisLine&&i>this.axisConfig.axisLineWidth&&(i-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let e=this.getLabelDimension(),s=.2*t.width;this.outerPadding=Math.min(e.width/2,s);let a=e.height+2*this.axisConfig.labelPadding;this.labelTextHeight=e.height,a<=i&&(i-=a,this.showLabel=!0)}if(this.axisConfig.showTick&&i>=this.axisConfig.tickLength&&(this.showTick=!0,i-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let t=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),e=t.height+2*this.axisConfig.titlePadding;this.titleTextHeight=t.height,e<=i&&(i-=e,this.showTitle=!0)}this.boundingRect.width=t.width,this.boundingRect.height=t.height-i}calculateSpaceIfDrawnVertical(t){let i=t.width;if(this.axisConfig.showAxisLine&&i>this.axisConfig.axisLineWidth&&(i-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let e=this.getLabelDimension(),s=.2*t.height;this.outerPadding=Math.min(e.height/2,s);let a=e.width+2*this.axisConfig.labelPadding;a<=i&&(i-=a,this.showLabel=!0)}if(this.axisConfig.showTick&&i>=this.axisConfig.tickLength&&(this.showTick=!0,i-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let t=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),e=t.height+2*this.axisConfig.titlePadding;this.titleTextHeight=t.height,e<=i&&(i-=e,this.showTitle=!0)}this.boundingRect.width=t.width-i,this.boundingRect.height=t.height}calculateSpace(t){return"left"===this.axisPosition||"right"===this.axisPosition?this.calculateSpaceIfDrawnVertical(t):this.calculateSpaceIfDrawnHorizontally(t),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}getDrawableElementsForLeftAxis(){let t=[];if(this.showAxisLine){let i=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["left-axis","axisl-line"],data:[{path:`M ${i},${this.boundingRect.y} L ${i},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["left-axis","label"],data:this.getTickValues().map(t=>({text:t.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(t),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"middle",horizontalPos:"right"}))}),this.showTick){let i=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["left-axis","ticks"],data:this.getTickValues().map(t=>({path:`M ${i},${this.getScaleValue(t)} L ${i-this.axisConfig.tickLength},${this.getScaleValue(t)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["left-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForBottomAxis(){let t=[];if(this.showAxisLine){let i=this.boundingRect.y+this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["bottom-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${i} L ${this.boundingRect.x+this.boundingRect.width},${i}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["bottom-axis","label"],data:this.getTickValues().map(t=>({text:t.toString(),x:this.getScaleValue(t),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){let i=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["bottom-axis","ticks"],data:this.getTickValues().map(t=>({path:`M ${this.getScaleValue(t)},${i} L ${this.getScaleValue(t)},${i+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["bottom-axis","title"],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForTopAxis(){let t=[];if(this.showAxisLine){let i=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["top-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${i} L ${this.boundingRect.x+this.boundingRect.width},${i}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["top-axis","label"],data:this.getTickValues().map(t=>({text:t.toString(),x:this.getScaleValue(t),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+2*this.axisConfig.titlePadding:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){let i=this.boundingRect.y;t.push({type:"path",groupTexts:["top-axis","ticks"],data:this.getTickValues().map(t=>({path:`M ${this.getScaleValue(t)},${i+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(t)},${i+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["top-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElements(){if("left"===this.axisPosition)return this.getDrawableElementsForLeftAxis();if("right"===this.axisPosition)throw Error("Drawing of right axis is not implemented");return"bottom"===this.axisPosition?this.getDrawableElementsForBottomAxis():"top"===this.axisPosition?this.getDrawableElementsForTopAxis():[]}},y=class extends m{static{(0,h.p)(this,"BandAxis")}constructor(t,i,e,s,a){super(t,s,a,i),this.categories=e,this.scale=l().domain(this.categories).range(this.getRange())}setRange(t){super.setRange(t)}recalculateScale(){this.scale=l().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),h.d.trace("BandAxis axis final categories, range: ",this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(t){return this.scale(t)??this.getRange()[0]}},b=class extends m{static{(0,h.p)(this,"LinearAxis")}constructor(t,i,e,s,a){super(t,s,a,i),this.domain=e,this.scale=(0,c.f)().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){let t=[...this.domain];"left"===this.axisPosition&&t.reverse(),this.scale=(0,c.f)().domain(t).range(this.getRange())}getScaleValue(t){return this.scale(t)}};function A(t,i,e,s){let a=new f(s);return p(t)?new y(i,e,t.categories,t.title,a):new b(i,e,[t.min,t.max],t.title,a)}(0,h.p)(A,"getAxis");var w=class{constructor(t,i,e,s){this.textDimensionCalculator=t,this.chartConfig=i,this.chartData=e,this.chartThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}static{(0,h.p)(this,"ChartTitle")}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){let i=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),e=Math.max(i.width,t.width),s=i.height+2*this.chartConfig.titlePadding;return i.width<=e&&i.height<=s&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=e,this.boundingRect.height=s,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){let t=[];return this.showChartTitle&&t.push({groupTexts:["chart-title"],type:"text",data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:"middle",horizontalPos:"center",x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),t}};function S(t,i,e,s){return new w(new f(s),t,i,e)}(0,h.p)(S,"getChartTitleComponent");var C=class{constructor(t,i,e,s,a){this.plotData=t,this.xAxis=i,this.yAxis=e,this.orientation=s,this.plotIndex=a}static{(0,h.p)(this,"LinePlot")}getDrawableElement(){let t,i=this.plotData.data.map(t=>[this.xAxis.getScaleValue(t[0]),this.yAxis.getScaleValue(t[1])]);return(t="horizontal"===this.orientation?(0,g.f)().y(t=>t[0]).x(t=>t[1])(i):(0,g.f)().x(t=>t[0]).y(t=>t[1])(i))?[{groupTexts:["plot",`line-plot-${this.plotIndex}`],type:"path",data:[{path:t,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}]:[]}},k=class{constructor(t,i,e,s,a,n){this.barData=t,this.boundingRect=i,this.xAxis=e,this.yAxis=s,this.orientation=a,this.plotIndex=n}static{(0,h.p)(this,"BarPlot")}getDrawableElement(){let t=this.barData.data.map(t=>[this.xAxis.getScaleValue(t[0]),this.yAxis.getScaleValue(t[1])]),i=.95*Math.min(2*this.xAxis.getAxisOuterPadding(),this.xAxis.getTickDistance()),e=i/2;return"horizontal"===this.orientation?[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(t=>({x:this.boundingRect.x,y:t[0]-e,height:i,width:t[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]:[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(t=>({x:t[0]-e,y:t[1],width:i,height:this.boundingRect.y+this.boundingRect.height-t[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]}},_=class{constructor(t,i,e){this.chartConfig=t,this.chartData=i,this.chartThemeConfig=e,this.boundingRect={x:0,y:0,width:0,height:0}}static{(0,h.p)(this,"BasePlot")}setAxes(t,i){this.xAxis=t,this.yAxis=i}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){return this.boundingRect.width=t.width,this.boundingRect.height=t.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!(this.xAxis&&this.yAxis))throw Error("Axes must be passed to render Plots");let t=[];for(let[i,e]of this.chartData.plots.entries())switch(e.type){case"line":{let s=new C(e,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,i);t.push(...s.getDrawableElement())}break;case"bar":{let s=new k(e,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,i);t.push(...s.getDrawableElement())}}return t}};function T(t,i,e){return new _(t,i,e)}(0,h.p)(T,"getPlotComponent");var R=class{constructor(t,i,e,s){this.chartConfig=t,this.chartData=i,this.componentStore={title:S(t,i,e,s),plot:T(t,i,e),xAxis:A(i.xAxis,t.xAxis,{titleColor:e.xAxisTitleColor,labelColor:e.xAxisLabelColor,tickColor:e.xAxisTickColor,axisLineColor:e.xAxisLineColor},s),yAxis:A(i.yAxis,t.yAxis,{titleColor:e.yAxisTitleColor,labelColor:e.yAxisLabelColor,tickColor:e.yAxisTickColor,axisLineColor:e.yAxisLineColor},s)}}static{(0,h.p)(this,"Orchestrator")}calculateVerticalSpace(){let t=this.chartConfig.width,i=this.chartConfig.height,e=0,s=0,a=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),n=Math.floor(i*this.chartConfig.plotReservedSpacePercent/100),h=this.componentStore.plot.calculateSpace({width:a,height:n});t-=h.width,i-=h.height,s=(h=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:i})).height,i-=h.height,this.componentStore.xAxis.setAxisPosition("bottom"),h=this.componentStore.xAxis.calculateSpace({width:t,height:i}),i-=h.height,this.componentStore.yAxis.setAxisPosition("left"),e=(h=this.componentStore.yAxis.calculateSpace({width:t,height:i})).width,(t-=h.width)>0&&(a+=t,t=0),i>0&&(n+=i,i=0),this.componentStore.plot.calculateSpace({width:a,height:n}),this.componentStore.plot.setBoundingBoxXY({x:e,y:s}),this.componentStore.xAxis.setRange([e,e+a]),this.componentStore.xAxis.setBoundingBoxXY({x:e,y:s+n}),this.componentStore.yAxis.setRange([s,s+n]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:s}),this.chartData.plots.some(t=>x(t))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let t=this.chartConfig.width,i=this.chartConfig.height,e=0,s=0,a=0,n=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),h=Math.floor(i*this.chartConfig.plotReservedSpacePercent/100),o=this.componentStore.plot.calculateSpace({width:n,height:h});t-=o.width,i-=o.height,e=(o=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:i})).height,i-=o.height,this.componentStore.xAxis.setAxisPosition("left"),o=this.componentStore.xAxis.calculateSpace({width:t,height:i}),t-=o.width,s=o.width,this.componentStore.yAxis.setAxisPosition("top"),o=this.componentStore.yAxis.calculateSpace({width:t,height:i}),i-=o.height,a=e+o.height,t>0&&(n+=t,t=0),i>0&&(h+=i,i=0),this.componentStore.plot.calculateSpace({width:n,height:h}),this.componentStore.plot.setBoundingBoxXY({x:s,y:a}),this.componentStore.yAxis.setRange([s,s+n]),this.componentStore.yAxis.setBoundingBoxXY({x:s,y:e}),this.componentStore.xAxis.setRange([a,a+h]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:a}),this.chartData.plots.some(t=>x(t))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){"horizontal"===this.chartConfig.chartOrientation?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();let t=[];for(let i of(this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis),Object.values(this.componentStore)))t.push(...i.getDrawableElements());return t}},D=class{static{(0,h.p)(this,"XYChartBuilder")}static build(t,i,e,s){return new R(t,i,e,s).getDrawableElement()}},L=0,P=z(),v=B(),E=O(),M=v.plotColorPalette.split(",").map(t=>t.trim()),I=!1,$=!1;function B(){let t=(0,n.p)(),i=(0,n.N)();return(0,a.z)(t.xyChart,i.themeVariables.xyChart)}function z(){let t=(0,n.N)();return(0,a.z)(n.f.xyChart,t.xyChart)}function O(){return{yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]}}function F(t){let i=(0,n.N)();return(0,n.w)(t.trim(),i)}function W(t){i=t}function N(t){"horizontal"===t?P.chartOrientation="horizontal":P.chartOrientation="vertical"}function X(t){E.xAxis.title=F(t.text)}function V(t,i){E.xAxis={type:"linear",title:E.xAxis.title,min:t,max:i},I=!0}function Y(t){E.xAxis={type:"band",title:E.xAxis.title,categories:t.map(t=>F(t.text))},I=!0}function U(t){E.yAxis.title=F(t.text)}function H(t,i){E.yAxis={type:"linear",title:E.yAxis.title,min:t,max:i},$=!0}function j(t){let i=Math.min(...t),e=Math.max(...t),s=d(E.yAxis)?E.yAxis.min:1/0,a=d(E.yAxis)?E.yAxis.max:-1/0;E.yAxis={type:"linear",title:E.yAxis.title,min:Math.min(s,i),max:Math.max(a,e)}}function G(t){let i=[];if(0===t.length)return i;if(I||V(Math.min(d(E.xAxis)?E.xAxis.min:1/0,1),Math.max(d(E.xAxis)?E.xAxis.max:-1/0,t.length)),$||j(t),p(E.xAxis)&&(i=E.xAxis.categories.map((i,e)=>[i,t[e]])),d(E.xAxis)){let e=E.xAxis.min,s=E.xAxis.max,a=(s-e)/(t.length-1),n=[];for(let t=e;t<=s;t+=a)n.push(`${t}`);i=n.map((i,e)=>[i,t[e]])}return i}function Q(t){return M[0===t?0:t%M.length]}function K(t,i){let e=G(i);E.plots.push({type:"line",strokeFill:Q(L),strokeWidth:2,data:e}),L++}function Z(t,i){let e=G(i);E.plots.push({type:"bar",fill:Q(L),data:e}),L++}function q(){if(0===E.plots.length)throw Error("No Plot to render, please provide a plot with some data");return E.title=(0,n.F)(),D.build(P,E,v,i)}function J(){return v}function tt(){return P}function ti(){return E}(0,h.p)(B,"getChartDefaultThemeConfig"),(0,h.p)(z,"getChartDefaultConfig"),(0,h.p)(O,"getChartDefaultData"),(0,h.p)(F,"textSanitizer"),(0,h.p)(W,"setTmpSVGG"),(0,h.p)(N,"setOrientation"),(0,h.p)(X,"setXAxisTitle"),(0,h.p)(V,"setXAxisRangeData"),(0,h.p)(Y,"setXAxisBand"),(0,h.p)(U,"setYAxisTitle"),(0,h.p)(H,"setYAxisRangeData"),(0,h.p)(j,"setYAxisRangeFromPlotData"),(0,h.p)(G,"transformDataWithoutCategory"),(0,h.p)(Q,"getPlotColorFromPalette"),(0,h.p)(K,"setLineData"),(0,h.p)(Z,"setBarData"),(0,h.p)(q,"getDrawableElem"),(0,h.p)(J,"getChartThemeConfig"),(0,h.p)(tt,"getChartConfig"),(0,h.p)(ti,"getXYChartData");var te={getDrawableElem:q,clear:(0,h.p)(function(){(0,n.M)(),L=0,P=z(),E=O(),M=(v=B()).plotColorPalette.split(",").map(t=>t.trim()),I=!1,$=!1},"clear"),setAccTitle:n.b,getAccTitle:n.d,setDiagramTitle:n.a,getDiagramTitle:n.F,getAccDescription:n.j,setAccDescription:n.C,setOrientation:N,setXAxisTitle:X,setXAxisRangeData:V,setXAxisBand:Y,setYAxisTitle:U,setYAxisRangeData:H,setLineData:K,setBarData:Z,setTmpSVGG:W,getChartThemeConfig:J,getChartConfig:tt,getXYChartData:ti},ts=(0,h.p)((t,i,s,a)=>{let o=a.db,r=o.getChartThemeConfig(),l=o.getChartConfig(),c=o.getXYChartData().plots[0].data.map(t=>t[1]);function g(t){return"top"===t?"text-before-edge":"middle"}function u(t){return"left"===t?"start":"right"===t?"end":"middle"}function x(t){return`translate(${t.x}, ${t.y}) rotate(${t.rotation||0})`}(0,h.p)(g,"getDominantBaseLine"),(0,h.p)(u,"getTextAnchor"),(0,h.p)(x,"getTextTransformation"),h.d.debug("Rendering xychart chart\n"+t);let p=(0,e.f)(i),d=p.append("g").attr("class","main"),f=d.append("rect").attr("width",l.width).attr("height",l.height).attr("class","background");(0,n.m)(p,l.height,l.width,!0),p.attr("viewBox",`0 0 ${l.width} ${l.height}`),f.attr("fill",r.backgroundColor),o.setTmpSVGG(p.append("g").attr("class","mermaid-tmp-group"));let m=o.getDrawableElem(),y={};function b(t){let i=d,e="";for(let[s]of t.entries()){let a=d;s>0&&y[e]&&(a=y[e]),e+=t[s],(i=y[e])||(i=y[e]=a.append("g").attr("class",t[s]))}return i}for(let t of((0,h.p)(b,"getGroup"),m)){if(0===t.data.length)continue;let i=b(t.groupTexts);switch(t.type){case"rect":if(i.selectAll("rect").data(t.data).enter().append("rect").attr("x",t=>t.x).attr("y",t=>t.y).attr("width",t=>t.width).attr("height",t=>t.height).attr("fill",t=>t.fill).attr("stroke",t=>t.strokeFill).attr("stroke-width",t=>t.strokeWidth),l.showDataLabel){let e=l.showDataLabelOutsideBar;if("horizontal"===l.chartOrientation){let s=function(t,i){let{data:e,label:s}=t;return i*s.length*a<=e.width-n};(0,h.p)(s,"fitsHorizontally");let a=.7,n=10,o=t.data.map((t,i)=>({data:t,label:c[i].toString()})).filter(t=>t.data.width>0&&t.data.height>0),l=Math.floor(Math.min(...o.map(t=>{let{data:i}=t,e=.7*i.height;for(;!s(t,e)&&e>0;)e-=1;return e}))),g=(0,h.p)(t=>e?t.data.x+t.data.width+n:t.data.x+t.data.width-n,"determineLabelXPosition");i.selectAll("text").data(o).enter().append("text").attr("x",g).attr("y",t=>t.data.y+t.data.height/2).attr("text-anchor",e?"start":"end").attr("dominant-baseline","middle").attr("fill",r.dataLabelColor).attr("font-size",`${l}px`).text(t=>t.label)}else{let s=function(t,i,e){let{data:s,label:a}=t,n=i*a.length*.7,h=s.x+s.width/2,o=h-n/2,r=h+n/2,l=o>=s.x&&r<=s.x+s.width,c=s.y+e+i<=s.y+s.height;return l&&c};(0,h.p)(s,"fitsInBar");let a=t.data.map((t,i)=>({data:t,label:c[i].toString()})).filter(t=>t.data.width>0&&t.data.height>0),n=Math.floor(Math.min(...a.map(t=>{let{data:i,label:e}=t,a=i.width/(.7*e.length);for(;!s(t,a,10)&&a>0;)a-=1;return a}))),o=(0,h.p)(t=>e?t.data.y-10:t.data.y+10,"determineLabelYPosition");i.selectAll("text").data(a).enter().append("text").attr("x",t=>t.data.x+t.data.width/2).attr("y",o).attr("text-anchor","middle").attr("dominant-baseline",e?"auto":"hanging").attr("fill",r.dataLabelColor).attr("font-size",`${n}px`).text(t=>t.label)}}break;case"text":i.selectAll("text").data(t.data).enter().append("text").attr("x",0).attr("y",0).attr("fill",t=>t.fill).attr("font-size",t=>t.fontSize).attr("dominant-baseline",t=>g(t.verticalPos)).attr("text-anchor",t=>u(t.horizontalPos)).attr("transform",t=>x(t)).text(t=>t.text);break;case"path":i.selectAll("path").data(t.data).enter().append("path").attr("d",t=>t.path).attr("fill",t=>t.fill?t.fill:"none").attr("stroke",t=>t.strokeFill).attr("stroke-width",t=>t.strokeWidth)}}},"draw");t.s(["diagram",0,{parser:u,db:te,renderer:{draw:ts}}],248018)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,347442,e=>{"use strict";var t=e.i(857844),s=e.i(651023),i=e.i(974265);e.s(["HighlightedCodeBlockBody",0,({code:e,language:a,raw:l,className:u,startLine:r,lineNumbers:o,...c})=>{let{shikiTheme:n}=(0,s.useContext)(t.A),g=(0,t.f)(),[h,d]=(0,s.useState)(l);return(0,s.useEffect)(()=>{if(!g)return void d(l);let t=g.highlight({code:e,language:a,themes:n},e=>{d(e)});t&&d(t)},[e,a,n,g,l]),(0,i.jsx)(t.c,{className:u,language:a,lineNumbers:o,result:h,startLine:r,...c})}])}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,180067,e=>{e.v(e=>Promise.resolve().then(()=>e(229969)))},333009,e=>{e.v(t=>Promise.all(["static/chunks/0vt1_fu_q116n.js"].map(t=>e.l(t))).then(()=>t(655510)))}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,968563,e=>{"use strict";var t=e.i(974265),i=e.i(651023),s=e.i(363178),n=e.i(272012),r=e.i(163308),o=e.i(472402),c=e.i(35127),l=e.i(470858),d=e.i(531466);function a(){let{resolvedTheme:e}=(0,s.i)(),a=(0,i.useMemo)(()=>new n.f({baseUrl:(0,o.T)(),getAccessToken:()=>null}),[]),u=(0,i.useCallback)(()=>{let e=(0,c.f)();"oidc"!==e.mode||(sessionStorage.setItem("stigmer:auth:redirect_path","/"),(0,l.f)(e.oidc).signinRedirect())},[]);return(0,t.jsx)(r.f,{client:a,colorMode:"dark"===e?"dark":"light",children:(0,t.jsx)("div",{className:"flex min-h-screen flex-col items-center justify-center p-4",children:(0,t.jsxs)("div",{className:"w-full max-w-sm space-y-8",children:[(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsx)(d.f,{}),(0,t.jsx)("h1",{className:"text-foreground mt-4 text-lg font-semibold",children:"Sign in to Stigmer"}),(0,t.jsx)("p",{className:"text-muted-foreground mt-1 text-sm",children:"Continue with your identity provider"})]}),(0,t.jsx)("button",{type:"button",onClick:u,className:"border-input bg-background text-foreground hover:bg-accent focus-visible:ring-ring block w-full rounded-md border px-4 py-2.5 text-center text-sm font-medium transition-colors focus-visible:ring-2 focus-visible:outline-none",children:"Sign in"})]})})})}e.s(["default",0,function(){return(0,t.jsx)(a,{})}],968563)},531466,e=>{"use strict";var t=e.i(974265);e.s(["f",0,function(){return(0,t.jsx)("img",{src:"/brand-avatar.png",width:56,height:56,alt:"Stigmer",className:"mx-auto rounded-xl"})}])}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,401568,e=>{"use strict";var t=e.i(660245);e.i(539927),e.S([t,"createTreemapServices,G"],401568)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,298021,e=>{"use strict";var t=e.i(974265),s=e.i(537097),r=e.i(651023),a=e.i(893976),n=e.i(65642),l=e.i(476007),i=e.i(468806),o=e.i(869803),c=e.i(933221),g=e.i(818424),u=e.i(996675),d=e.i(311015);let m=/^https?:\/\/(?:www\.)?github\.com\/([^/\s]+)\/([^/\s#?]+?)(?:\.git)?(?:\/tree\/([^\s#?]+))?\/?$/;function f(e){let t=m.exec(e);if(null!==t){let s=`${t[1]??""}/${t[2]??""}`;if(!x(s))return{ok:!1,message:`'${e}' does not name a GitHub repository`};let r=t[3];return{ok:!0,source:{type:"github",repo:s,...void 0!==r&&""!==r&&{ref:r}}}}let s=e.indexOf("@"),r=-1===s?e:e.slice(0,s),a=-1===s?void 0:e.slice(s+1);return x(r)&&(void 0===a||""!==a)?{ok:!0,source:{type:"github",repo:r,...void 0!==a&&{ref:a}}}:{ok:!1,message:`'${e}' is not a GitHub 'owner/repo'`}}function h(e){return void 0===e.ref?`github.com/${e.repo}`:`github.com/${e.repo}@${e.ref}`}let p=/^[A-Za-z0-9][A-Za-z0-9._-]*$/;function x(e){let t=e.split("/");return 2===t.length&&t.every(e=>p.test(e)&&"."!==e&&".."!==e)}var b=e.i(321252);let w="HEAD",y=new Map;function j(e,t,s){return`https://raw.githubusercontent.com/${e}/${t}/${s.split("/").map(encodeURIComponent).join("/")}`}async function v(e,t){let s=await k(e,t);if(s.truncated)throw new b.D(`${h(e)} lists more files than GitHub returns in one tree, so it cannot be read as a marketplace`,"too-large");let r=s.tree.filter(e=>"blob"===e.type).map(e=>({path:e.path,size:e.size??0}));if(r.length>b.$.entries)throw new b.D(`${h(e)} holds ${r.length} files, over the ${b.$.entries} a marketplace may carry`,"too-large");let a=s.sha,n=new Map(r.map(e=>[e.path,e.size]));return{describe:`${h(e)} (${a.slice(0,7)})`,files:r,fetchFile:s=>N(e.repo,a,s,n.get(s),t),fileUrl:t=>j(e.repo,a,t)}}async function k(e,t){let s,r=`${e.repo}@${e.ref??w}`,a=y.get(r),n={accept:"application/vnd.github+json"};a?.etag&&(n["if-none-match"]=a.etag);try{s=await t(`https://api.github.com/repos/${e.repo}/git/trees/${encodeURIComponent(e.ref??w)}?recursive=1`,{headers:n})}catch(t){throw new b.D(`could not reach GitHub for ${h(e)}: ${t instanceof Error?t.message:String(t)}`,"unreachable")}if(304===s.status&&void 0!==a)return a.listing;if(404===s.status)throw new b.D(`GitHub has no public repository ${h(e)}; private repositories are not marketplaces`,"not-found");if(403===s.status||429===s.status)throw new b.D(`GitHub is rate-limiting this browser (${s.status}); try again in a while, or install with the CLI`,"unreachable");if(!s.ok)throw new b.D(`GitHub answered ${s.status} for ${h(e)}`,"unreachable");let l=await s.json();return y.set(r,{etag:s.headers.get("etag"),listing:l}),l}async function N(e,t,s,r,a){let n;try{n=await a(j(e,t,s))}catch(e){throw new b.D(`could not read '${s}' from GitHub: ${e instanceof Error?e.message:String(e)}`,"unreachable")}if(!n.ok)throw new b.D(`GitHub answered ${n.status} for '${s}'`,"unreachable");let l=new Uint8Array(await n.arrayBuffer());if(void 0!==r&&l.length!==r)throw new b.D(`'${s}' came back ${l.length} bytes where the tree listed ${r}; the repository changed under the read`,"refused");return l}let $=/^\d+\.\d+\.\d+(?:-(?!(?:dev|local)(?:[.-]|$))[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/,C="@stigmer/plugins";function S(e,t){return`https://cdn.jsdelivr.net/npm/${C}@${e}/${t.split("/").map(encodeURIComponent).join("/")}`}async function z(e,t){let s;if(!$.test(e))throw new b.D(`the official marketplace is published with each release, and this server runs a development build (${e}); add a GitHub marketplace to install from, or use the CLI`,"unavailable-on-dev-server");try{s=await t(`https://data.jsdelivr.com/v1/package/npm/${C}@${e}/flat`)}catch(t){throw new b.D(`could not reach the npm CDN for ${C}@${e}: ${t instanceof Error?t.message:String(t)}`,"unreachable")}if(404===s.status)throw new b.D(`${C}@${e} is not published; the catalogue for this server's release is not available yet`,"not-found");if(!s.ok)throw new b.D(`the npm CDN answered ${s.status} for ${C}@${e}`,"unreachable");let r=(await s.json()).files.map(e=>({path:e.name.replace(/^\//,""),size:e.size}));if(r.length>b.$.entries)throw new b.D(`${C}@${e} holds ${r.length} files, over the ${b.$.entries} a marketplace may carry`,"too-large");let a=new Map(r.map(e=>[e.path,e.size]));return{describe:`${C}@${e}`,files:r,fetchFile:async s=>{let r;try{r=await t(S(e,s))}catch(e){throw new b.D(`could not read '${s}' from the npm CDN: ${e instanceof Error?e.message:String(e)}`,"unreachable")}if(!r.ok)throw new b.D(`the npm CDN answered ${r.status} for '${s}'`,"unreachable");let n=new Uint8Array(await r.arrayBuffer()),l=a.get(s);if(void 0!==l&&n.length!==l)throw new b.D(`'${s}' came back ${n.length} bytes where the listing said ${l}`,"refused");return n},fileUrl:t=>S(e,t)}}let I={sm:"stg:size-4",md:"stg:size-6"},M={sm:32,md:48};function A({source:e,size:s="sm",className:n}){let[l,i]=(0,r.useState)(!1);return l?null:(0,t.jsx)("img",{src:function(e,t=64){return`https://github.com/${encodeURIComponent(e)}.png?size=${t}`}(function(e){switch(e.type){case"official":return"stigmer";case"github":var t;let s;return -1===(s=(t=e.repo).indexOf("/"))?t:t.slice(0,s);default:return e}}(e),M[s]),alt:"",loading:"lazy",referrerPolicy:"no-referrer",onError:()=>i(!0),className:(0,a.f)("stg:shrink-0 stg:rounded-sm stg:bg-muted stg:object-cover",I[s],n)})}let D=[];function O({open:e,onClose:s,reads:a=D,marketplaces:l,unreadable:o,isBuiltIn:c,add:g,remove:u}){let d=(0,r.useId)();return(0,t.jsx)(i.f,{open:e,onOpenChange:e=>{e||s()},width:"lg",className:"stg:max-h-[85vh] stg:bg-card stg:text-foreground","aria-labelledby":d,children:e&&(0,t.jsxs)("div",{className:"stg:flex stg:max-h-[85vh] stg:flex-col stg:gap-4 stg:overflow-y-auto stg:p-6",children:[(0,t.jsxs)("header",{children:[(0,t.jsx)("h2",{id:d,className:"stg:text-base stg:font-semibold stg:text-foreground",children:"Sources"}),(0,t.jsx)("p",{className:"stg:mt-0.5 stg:text-xs stg:text-muted-foreground",children:"What the Marketplace shows comes from Stigmer's catalogue, published with each release, and from any catalogue you add. Added sources are remembered in this browser, as the CLI remembers its own."})]}),(0,t.jsx)(R,{reads:a,marketplaces:l,unreadable:o,isBuiltIn:c,remove:u}),(0,t.jsxs)("details",{className:"stg:rounded-md stg:border stg:border-border stg:p-3",children:[(0,t.jsx)("summary",{className:"stg:cursor-pointer stg:text-sm stg:font-medium stg:text-foreground",children:"Add your own catalogue"}),(0,t.jsx)("p",{className:"stg:mt-1 stg:mb-3 stg:text-xs stg:text-muted-foreground",children:"A repository you or your company publish with a marketplace file, read from GitHub."}),(0,t.jsx)(E,{add:g})]}),(0,t.jsx)("footer",{className:"stg:flex stg:justify-end stg:pt-1",children:(0,t.jsx)(n.f,{variant:"outline",size:"sm",onClick:s,children:"Close"})})]})})}function R({reads:e,marketplaces:s,unreadable:l,isBuiltIn:i,remove:c}){let[g,u]=(0,r.useState)(null);return(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-2",children:[(0,t.jsxs)("ul",{className:(0,a.f)(o.J,"stg:divide-y stg:divide-border stg:rounded-md stg:border stg:border-border"),"aria-label":"Known sources",children:[s.map(s=>(0,t.jsxs)("li",{className:"stg:flex stg:flex-col stg:gap-2 stg:px-3 stg:py-2",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:justify-between stg:gap-4",children:[(0,t.jsxs)("div",{className:"stg:flex stg:min-w-0 stg:items-center stg:gap-3",children:[(0,t.jsx)(A,{source:s.source,size:"md"}),(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsx)("p",{className:"stg:text-sm stg:text-foreground",children:s.name}),(0,t.jsxs)("p",{className:"stg:font-mono stg:text-xs stg:text-muted-foreground",children:[function(e){switch(e.type){case"official":return"built in";case"github":return h(e);default:return e}}(s.source),i(s.name)&&"official"!==s.source.type?" (built in)":""]})]})]}),!i(s.name)&&(0,t.jsx)(n.f,{variant:"ghost",size:"sm",onClick:()=>u(c(s.name)),"aria-label":`Remove source ${s.name}`,children:"Remove"})]}),(0,t.jsx)(U,{read:e.find(e=>e.marketplace.name===s.name)})]},s.name)),l.map(e=>(0,t.jsxs)("li",{className:"stg:flex stg:items-center stg:justify-between stg:gap-4 stg:px-3 stg:py-2",role:"alert",children:[(0,t.jsxs)("div",{className:"stg:min-w-0",children:[(0,t.jsx)("p",{className:"stg:text-sm stg:text-foreground",children:e.name}),(0,t.jsxs)("p",{className:"stg:text-xs stg:text-destructive",children:["cannot be read: ",e.reason]})]}),(0,t.jsx)(n.f,{variant:"ghost",size:"sm",onClick:()=>u(c(e.name)),"aria-label":`Forget source ${e.name}`,children:"Forget"})]},e.name))]}),g&&(0,t.jsx)("p",{role:"alert",className:"stg:text-xs stg:text-destructive",children:g})]})}function U({read:e}){if(void 0===e)return null;let{state:s}=e;switch(s.kind){case"reading":return(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:"Reading…"});case"failed":return(0,t.jsxs)("p",{className:"stg:text-xs stg:text-destructive",children:["cannot be read: ",s.error.message]});case"ready":{let e=s.opened.marketplace.plugins.length,r=s.opened.warnings,a=1===e?"Offers 1 plugin":`Offers ${e} plugins`;if(0===r.length)return(0,t.jsxs)("p",{className:"stg:text-xs stg:text-muted-foreground",children:[a,"."]});return(0,t.jsxs)("details",{className:"stg:text-xs stg:text-muted-foreground",children:[(0,t.jsxs)("summary",{className:"stg:cursor-pointer",children:[a,"; ",1===r.length?"1 entry it lists":`${r.length} entries it lists`," cannot be installed from here."]}),(0,t.jsx)("ul",{className:"stg:mt-1 stg:list-disc stg:space-y-1 stg:pl-5",children:r.map((e,s)=>(0,t.jsx)("li",{children:e.message},`${e.kind}:${s}`))})]})}default:return s}}function E({add:e}){let[s,l]=(0,r.useState)(""),[i,o]=(0,r.useState)(""),[g,u]=(0,r.useState)(!1),[d,m]=(0,r.useState)(null),f=`${(0,r.useId)()}-source-hint`;return(0,t.jsxs)("form",{className:"stg:flex stg:flex-col stg:gap-2","aria-label":"Add a source",onSubmit:t=>{t.preventDefault(),u(!0),m(null),e(s,i).then(e=>{u(!1),e.ok?(l(""),o(""),m({kind:"added",text:`Added source '${e.name}'.`})):m({kind:"refusal",text:e.message})})},children:[(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-2 stg:sm:flex-row stg:sm:items-end",children:[(0,t.jsx)(c.N,{label:"GitHub repository",className:"stg:flex-1",children:(0,t.jsx)("input",{className:c.a,value:s,onChange:e=>l(e.target.value),placeholder:"owner/repo or https://github.com/owner/repo","aria-describedby":f})}),(0,t.jsx)(c.N,{label:"Name (optional)",className:"stg:sm:w-48",children:(0,t.jsx)("input",{className:c.a,value:i,onChange:e=>o(e.target.value),placeholder:"the catalogue's own name"})}),(0,t.jsx)(n.f,{type:"submit",variant:"outline",size:"sm",disabled:g||""===s.trim(),children:g?"Reading…":"Add source"})]}),(0,t.jsxs)("p",{id:f,className:"stg:text-xs stg:text-muted-foreground",children:["A source is ","a GitHub repository as 'owner/repo' or 'owner/repo@ref', or that repository's URL (https://github.com/owner/repo)",". It is read before it is added, and takes the name its marketplace file gives itself unless you choose one."]}),d&&(0,t.jsx)("p",{role:"refusal"===d.kind?"alert":"status",className:(0,a.f)("stg:text-xs","refusal"===d.kind?"stg:text-destructive":"stg:text-muted-foreground"),children:d.text})]})}var H=e.i(758301);let L=["stg:border-chart-1","stg:border-chart-2","stg:border-chart-3","stg:border-chart-4","stg:border-chart-5"],G="stg:flex stg:size-10 stg:shrink-0 stg:items-center stg:justify-center stg:overflow-hidden stg:rounded-lg";function P({name:e,displayName:s,logoUrl:n,className:l}){let[i,o]=(0,r.useState)(!1);if(null!==n&&!i)return(0,t.jsx)("span",{className:(0,a.f)(G,"stg:bg-muted",l),children:(0,t.jsx)("img",{src:n,alt:"",loading:"lazy",referrerPolicy:"no-referrer",onError:()=>o(!0),className:"stg:size-full stg:object-contain"})});let c=(s.trim()||e).charAt(0).toUpperCase();return(0,t.jsx)("span",{"aria-hidden":"true","data-monogram":c,className:(0,a.f)(G,"stg:border-2 stg:bg-muted stg:text-base stg:font-semibold stg:text-foreground",function(e){let t=0;for(let s=0;s<e.length;s++)t=31*t+e.charCodeAt(s)|0;return L[Math.abs(t)%L.length]??L[0]}(e),l),children:c})}var B=e.i(466531),T=e.i(75786),F=e.i(782130),J=e.i(378486),K=e.i(833811);let W=new Set(["png","svg","jpg","jpeg","webp","gif"]);function Z(e,t){let s=function(e,t){if("string"!=typeof e)return;let s=e.startsWith("./")?e.slice(2):e;if(!(0,B.S)(s))return;let r=s.lastIndexOf(".");if(-1===r||!W.has(s.slice(r+1).toLowerCase()))return;let a=t.entry(s);if(void 0!==a&&!(a.size>B.W.logo))return s}(e.logo,t);return{...Q("displayName",e.displayName),...Q("category",e.category),...void 0!==s&&{logo:s}}}function Q(e,t){return"string"==typeof t&&""!==t?{[e]:t}:{}}let V=new Set(Object.values(T.t));async function Y(e){let t=new Map;await Promise.all(e.filter(e=>V.has(e.path)).map(async e=>{try{t.set(e.path,await e.read())}catch{}}));var s={entries:e.map(({path:e,size:t})=>({path:e,size:t})).sort((e,t)=>(0,B.r)(e.path,t.path)),read:e=>{let s=t.get(e);if(void 0===s)throw Error(`plugin file '${e}' was not fetched for presentation`);return s}};let r=new B.p(s),a={};for(let e of F.V){let t=function(e,t){let s,r,a=e.entry(t);if(void 0!==a&&!(a.size>B.W.manifest)){try{s=e.files.read(t)}catch{return}if(!(s.length>B.W.manifest)){try{r=JSON.parse((0,B.I)(s))}catch{return}return(0,K.F)(r)?r:void 0}}}(r,T.t[e]);if(void 0===t)continue;let s=function(e,t,s){let r=function(e){let t=function(e){if(!(0,K.F)(e))return;let t={...Q("name",e.name),...Q("email",e.email),...Q("url",e.url)};return 0===Object.keys(t).length?void 0:t}(e.author);return{...Q("version",e.version),...Q("description",e.description),...void 0!==t&&{author:t}}}(t);switch(e){case"cursor":return{...r,...Z(t,s)};case"codex":{let e=t.interface;return(0,K.F)(e)?{...r,...Z(e,s)}:r}case"agent-plugins":{let e=(0,J.j)(t);return void 0===e?r:{...r,...Z(e,s)}}case"claude":return r;default:return e}}(e,t,r);for(let e of Object.keys(s))void 0===a[e]&&Object.assign(a,{[e]:s[e]})}return a}var _=e.i(616701),q=e.i(961378);let X={},ee="stg:flex stg:flex-col stg:gap-3 stg:rounded-lg stg:border stg:border-border stg:bg-card stg:p-4";function et({entry:e,installed:s,onInstall:l,className:i}){let{presentation:o,logoUrl:c}=function(e,t){let s=e&&t?`${e.tree.describe}:${t.dir}`:null,{data:a,isLoading:n}=(0,_.f)(e&&t?()=>Y((0,q.Q)(e,t)):null,[s],X,null===s?{}:{cacheKey:`plugin-presentation:${s}`}),l=(0,r.useMemo)(()=>e&&t&&void 0!==a.logo?e.tree.fileUrl(""===t.dir?a.logo:`${t.dir}/${a.logo}`):null,[e,t,a.logo]);return(0,r.useMemo)(()=>({presentation:a,logoUrl:l,isLoading:n}),[a,l,n])}(e.opened,e.entry),g=e.entry.name,u=o.displayName??g,d=e.entry.description??o.description,m=o.author?.name,f=m?`by ${m}`:u!==g?g:null;return(0,t.jsxs)("li",{className:(0,a.f)(ee,i),children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-3 stg:min-w-0",children:[(0,t.jsx)(P,{name:g,displayName:u,logoUrl:c}),(0,t.jsxs)("div",{className:"stg:min-w-0 stg:flex-1",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:justify-between stg:gap-2",children:[(0,t.jsx)("h3",{className:"stg:m-0 stg:truncate stg:text-sm stg:font-medium stg:text-foreground",children:u}),s&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:rounded-full stg:border stg:border-border stg:bg-muted stg:px-2 stg:py-0.5 stg:text-xs stg:text-muted-foreground",children:"Installed"})]}),f&&(0,t.jsx)("p",{className:"stg:truncate stg:text-xs stg:text-muted-foreground",children:f})]})]}),d&&(0,t.jsx)("p",{className:"stg:line-clamp-2 stg:flex-1 stg:text-xs stg:text-muted-foreground",children:d}),(0,t.jsxs)("div",{className:"stg:mt-auto stg:flex stg:items-center stg:justify-between stg:gap-2 stg:pt-1",children:[(0,t.jsxs)("span",{className:"stg:flex stg:min-w-0 stg:items-center stg:gap-1.5 stg:text-xs stg:text-muted-foreground",children:[(0,t.jsx)(A,{source:e.source.source}),(0,t.jsx)("span",{className:"stg:truncate",children:e.source.name})]}),l?(0,t.jsx)(n.f,{variant:"outline",size:"sm",onClick:()=>l(e),"aria-label":`Install ${g}`,children:s?"Install again":"Install"}):!s&&(0,t.jsx)("span",{className:"stg:shrink-0 stg:text-xs stg:text-muted-foreground",children:"Ask an admin to install"})]})]})}function es({onUpload:e,className:s}){return(0,t.jsx)("li",{className:(0,a.f)(ee,"stg:border-dashed stg:bg-transparent",s),children:(0,t.jsxs)("button",{type:"button",onClick:e,className:(0,a.f)("stg:flex stg:h-full stg:w-full stg:cursor-pointer stg:flex-col stg:items-start stg:gap-3 stg:rounded-md stg:text-left","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring"),children:[(0,t.jsx)("span",{className:"stg:flex stg:size-10 stg:items-center stg:justify-center stg:rounded-lg stg:border stg:border-dashed stg:border-border stg:text-muted-foreground",children:(0,t.jsx)(H.f,{className:"stg:size-5"})}),(0,t.jsx)("span",{className:"stg:text-sm stg:font-medium stg:text-foreground",children:"Upload a plugin"}),(0,t.jsx)("span",{className:"stg:text-xs stg:text-muted-foreground",children:"A Cursor, Claude Code, Codex or Agent Plugins folder from your computer, or a .zip of one."})]})})}var er=e.i(830419),ea=e.i(563212),en=e.i(379410),el=e.i(188482);let ei=(0,a.f)("stg:inline-flex stg:cursor-pointer stg:items-center stg:gap-1.5 stg:rounded-full stg:border stg:px-3 stg:py-1 stg:text-xs stg:font-medium stg:transition-colors","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring");function eo({reads:e,selected:s,onSelect:l,onManage:i,className:o}){let c=(0,r.useRef)([]),g=["",...e.map(e=>e.marketplace.name)],u=s??"",d=(0,r.useCallback)(e=>{l(""===e?null:e)},[l]),m=(0,r.useCallback)((e,t)=>{let s=null;if("ArrowRight"===e.key||"ArrowDown"===e.key?s=(t+1)%g.length:"ArrowLeft"===e.key||"ArrowUp"===e.key?s=(t-1+g.length)%g.length:"Home"===e.key?s=0:"End"===e.key&&(s=g.length-1),null===s)return;e.preventDefault(),c.current[s]?.focus();let r=g[s];void 0!==r&&d(r)},[g,d]),f=e.reduce((e,t)=>e+("ready"===t.state.kind?t.state.opened.marketplace.plugins.length:0),0),h=e.some(e=>"reading"===e.state.kind);return(0,t.jsxs)("div",{className:(0,a.f)("stg:flex stg:flex-wrap stg:items-center stg:gap-2",o),children:[(0,t.jsxs)("div",{role:"radiogroup","aria-label":"Sources",className:"stg:flex stg:flex-wrap stg:items-center stg:gap-2",children:[(0,t.jsxs)(eg,{ref:e=>{c.current[0]=e},selected:""===u,label:"All sources",onClick:()=>d(""),onKeyDown:e=>m(e,0),children:[(0,t.jsx)("span",{children:"All sources"}),(0,t.jsx)(eu,{count:f,reading:h})]}),e.map((e,s)=>(0,t.jsx)(ec,{ref:e=>{c.current[s+1]=e},read:e,selected:u===e.marketplace.name,onClick:()=>d(e.marketplace.name),onKeyDown:e=>m(e,s+1)},e.marketplace.name))]}),(0,t.jsx)(n.f,{variant:"ghost",size:"xs",onClick:i,className:"stg:text-muted-foreground",children:"Manage sources"})]})}function ec({ref:e,read:s,selected:r,onClick:a,onKeyDown:n}){let{marketplace:l,state:i}=s,o=(0,t.jsxs)(eg,{ref:e,selected:r,label:l.name,onClick:a,onKeyDown:n,children:[(0,t.jsx)(A,{source:l.source}),(0,t.jsx)("span",{children:l.name}),"ready"===i.kind&&(0,t.jsx)(eu,{count:i.opened.marketplace.plugins.length,reading:!1}),"reading"===i.kind&&(0,t.jsx)(en.f,{className:"stg:size-3"}),"failed"===i.kind&&(0,t.jsx)(ed,{className:"stg:size-3"})]});return"failed"!==i.kind?o:(0,t.jsxs)(el.W,{children:[(0,t.jsx)(el.y,{render:o}),(0,t.jsx)(el.Y,{side:"bottom",children:i.error.message})]})}function eg({ref:e,selected:s,label:r,onClick:n,onKeyDown:l,children:i}){return(0,t.jsx)("button",{ref:e,type:"button",role:"radio","aria-checked":s,"aria-label":r,tabIndex:s?0:-1,onClick:n,onKeyDown:l,className:(0,a.f)(ei,s?"stg:border-primary stg:bg-primary stg:text-primary-foreground":"stg:border-border stg:bg-card stg:text-muted-foreground stg:hover:bg-accent-hover stg:hover:text-foreground"),children:i})}function eu({count:e,reading:s}){return s&&0===e?(0,t.jsx)(en.f,{className:"stg:size-3"}):(0,t.jsx)("span",{className:"stg:tabular-nums",children:e})}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 2.5 14 13H2L8 2.5Z"}),(0,t.jsx)("path",{d:"M8 6.5v3M8 11.5h.01"})]})}var em=e.i(255817),ef=e.i(781836);let eh={kind:"reading"};class ep{reads=new Map;keys=new Map;generations=new Map;order=[];snapshot=[];listeners=new Set;open=null;subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.snapshot;sync(e,t){this.open=t;let s=new Set(e.map(e=>e.name));for(let e of[...this.reads.keys()])s.has(e)||this.forget(e);for(let t of e){let e=function(e){switch(e.type){case"official":return"official";case"github":return`github:${e.repo}@${e.ref??""}`;default:return e}}(t.source);this.keys.get(t.name)!==e&&(this.keys.set(t.name,e),this.start(t))}this.order=e.map(e=>e.name),this.publish()}refetch(e){let t=this.reads.get(e);void 0!==t&&(this.start(t.marketplace),this.publish())}start(e){let t=this.open;if(null===t)throw Error("MarketplaceCatalogStore.sync must run before a read starts");let s=(this.generations.get(e.name)??0)+1;this.generations.set(e.name,s),this.reads.set(e.name,{marketplace:e,state:eh});let r=t=>{this.generations.get(e.name)===s&&(this.reads.set(e.name,{marketplace:e,state:t}),this.publish())};t(e.source).then(e=>r({kind:"ready",opened:e}),e=>r({kind:"failed",error:(0,ef.f)(e)}))}forget(e){this.reads.delete(e),this.keys.delete(e),this.generations.set(e,(this.generations.get(e)??0)+1)}publish(){let e=[];for(let t of this.order){let s=this.reads.get(t);void 0!==s&&e.push(s)}if(!(e.length===this.snapshot.length&&e.every((e,t)=>e===this.snapshot[t])))for(let t of(this.snapshot=e,this.listeners))t()}}async function ex(e,t,s={}){let r=s.fetchImpl??globalThis.fetch.bind(globalThis);switch(e.type){case"official":{let e=await t.platform.getServerInfo();return(0,q.t)(await z(e.version,r))}case"github":return(0,q.t)(await v(e,r));default:throw Error(`unknown marketplace source ${JSON.stringify(e)}`)}}let eb=[],ew=[{name:"stigmer",source:{type:"official"}}],ey=new Set(ew.map(e=>e.name));function ej(e){return ey.has(e)}function ev(e,t){switch(t){case"add":return`'${e}' is a built-in source and cannot be added or replaced; choose another name`;case"remove":return`'${e}' is a built-in source and cannot be removed`;default:return t}}let ek="stigmer:plugins:marketplaces:v1",eN=ew.map(e=>({name:e.name,source:e.source}));eN[0];let e$=new Set;function eC(e){e$.add(e);let t=t=>{t.key===ek&&e()};return window.addEventListener("storage",t),()=>{e$.delete(e),window.removeEventListener("storage",t)}}function eS(){try{return window.localStorage.getItem(ek)??""}catch{return""}}function ez(e){try{0===Object.keys(e).length?window.localStorage.removeItem(ek):window.localStorage.setItem(ek,JSON.stringify(e))}catch{}for(let e of e$)e()}function eI(e){if(""===e)return{};try{let t=JSON.parse(e);return"object"!=typeof t||null===t||Array.isArray(t)?{}:t}catch{return{}}}async function eM(e,t){try{let s=await (0,q.t)(await v(e,t));return{ok:!0,name:s.marketplace.name}}catch(e){if(e instanceof q.P)return{ok:!1,message:`${e.subject}: ${e.errors.map(e=>e.message).join("; ")}`};return{ok:!1,message:e instanceof Error?e.message:String(e)}}}var eA=e.i(891287),eD=e.i(44454),eO=e.i(766330),eR=e.i(205413);let eU=[];var eE=e.i(962838);function eH({org:e,onInstalled:s,fetchImpl:n,className:l}){let i=function(e={}){let t=(0,r.useSyncExternalStore)(eC,eS,()=>""),s=e.fetchImpl??globalThis.fetch,{marketplaces:a,unreadable:n}=(0,r.useMemo)(()=>{let e=[...eN],s=[];for(let[r,a]of Object.entries(eI(t))){if(ej(r))continue;let t=function(e){if("object"!=typeof e||null===e)return{ok:!1,reason:"not an object"};switch(e.type){case"github":{let t=e.repo;if("string"!=typeof t||!x(t))return{ok:!1,reason:"type 'github' needs 'repo: owner/repo'"};let s=e.ref;if(void 0!==s&&("string"!=typeof s||""===s))return{ok:!1,reason:"'ref' must be a non-empty branch, tag or commit"};return{ok:!0,source:{type:"github",repo:t,..."string"==typeof s&&{ref:s}}}}case void 0:return{ok:!1,reason:"no 'type' (expected 'github')"};default:return{ok:!1,reason:`unknown type '${String(e.type)}' (expected 'github')`}}}(a);t.ok?e.push({name:r,source:t.source}):s.push({name:r,reason:t.reason})}return{marketplaces:e,unreadable:s}},[t]),l=(0,r.useCallback)(async(e,t)=>{let r=f(e.trim());if(!r.ok)return{ok:!1,message:r.message};let a=await eM(r.source,s);if(!a.ok)return a;let n=void 0===t||""===t.trim()?a.name:t.trim();if(ej(n))return{ok:!1,message:ev(n,"add")};if(!(0,F.j)(n))return{ok:!1,message:`'${n}' is not a source name; use lowercase letters, digits, '.' and '-'`};let l=eI(eS());return void 0!==l[n]?{ok:!1,message:`a source named '${n}' is already added; remove it first or choose another name`}:(ez({...l,[n]:r.source}),{ok:!0,name:n})},[s]),i=(0,r.useCallback)(e=>{if(ej(e))return ev(e,"remove");let t=eI(eS());if(void 0===t[e])return`no source named '${e}' is added`;let{[e]:s,...r}=t;return ez(r),null},[]),o=(0,r.useCallback)(e=>f(e.trim()),[]);return(0,r.useMemo)(()=>({marketplaces:a,unreadable:n,add:l,remove:i,parseSource:o,isBuiltIn:ej}),[a,n,l,i,o])}(n?{fetchImpl:n}:{}),{reads:u,refetch:m}=function(e,t={}){let s=(0,em.f)(),{fetchImpl:a}=t,n=(0,r.useRef)(null);null===n.current&&(n.current=new ep);let l=n.current,i=(0,r.useCallback)(e=>ex(e,s,a?{fetchImpl:a}:{}),[s,a]);(0,r.useEffect)(()=>{l.sync(e,i)},[l,e,i]);let o=(0,r.useSyncExternalStore)(l.subscribe,l.getSnapshot,()=>eb),c=(0,r.useCallback)(e=>l.refetch(e),[l]);return(0,r.useMemo)(()=>({reads:o,refetch:c}),[o,c])}(i.marketplaces,n?{fetchImpl:n}:{}),h=function(e){let t=(0,em.f)(),{data:s}=(0,_.f)(e?async()=>(await (0,eR.T)(s=>t.plugin.list((0,eA.f)(eD.c,{org:e,pageSize:eO.J,pageToken:s})))).map(e=>e.metadata?.slug??""):null,[e,t],eU);return(0,r.useMemo)(()=>new Set(s),[s])}(e),p=(0,eE.f)(e),b=p.allowed,[w,y]=(0,r.useState)(null),[j,v]=(0,r.useState)(""),[k,N]=(0,r.useState)(1),[$,C]=(0,r.useState)(null),[S,z]=(0,r.useState)(!1),[I,M]=(0,r.useState)(!1),A=(0,r.useId)(),D=(0,r.useCallback)(e=>{y(e),N(1)},[]),R=(0,r.useCallback)(e=>{v(e),N(1)},[]),U=null!==w&&u.some(e=>e.marketplace.name===w)?w:null,E=(0,r.useMemo)(()=>null===U?u:u.filter(e=>e.marketplace.name===U),[u,U]),H=(0,r.useMemo)(()=>(function(e){let t=[];for(let s of e){if("ready"!==s.state.kind)continue;let{opened:e}=s.state;for(let r of e.marketplace.plugins)t.push({source:s.marketplace,opened:e,entry:r})}return t})(E),[E]),L=(0,r.useMemo)(()=>H.filter(e=>{var t;let s;return t=e.entry,""===(s=j.trim().toLowerCase())||t.name.toLowerCase().includes(s)||(t.description?.toLowerCase().includes(s)??!1)}),[H,j]),G=""!==j.trim(),P=!G&&b,B=Math.max(1,Math.ceil((L.length+ +!!P)/24)),T=Math.min(k,B),J=(T-1)*24,K=+!!P,W=L.slice(Math.max(0,J-K),J-K+24),Z=E.some(e=>"reading"===e.state.kind),Q=E.filter(e=>"failed"===e.state.kind),V=Z&&0===H.length||p.isLoading;return(0,t.jsxs)("div",{className:(0,a.f)("stg:flex stg:flex-col stg:gap-6",l),children:[(0,t.jsx)(eo,{reads:u,selected:U,onSelect:D,onManage:()=>M(!0)}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("label",{htmlFor:A,className:"stg:text-sm stg:font-medium stg:text-foreground",children:"Search plugins"}),(0,t.jsx)("input",{id:A,type:"search",className:c.a,value:j,onChange:e=>R(e.target.value),placeholder:null===U?"Search every source by name or description…":`Search ${U} by name or description…`})]}),Q.length>0&&(0,t.jsx)(eP,{failed:Q,refetch:m,whole:null!==U}),V&&(0,t.jsx)(eG,{label:`Reading ${U??"the sources"}`}),!V&&H.length>0&&0===L.length&&G&&(0,t.jsx)(d.f,{variant:"zero-results",title:`Nothing matches '${j.trim()}'`,description:"Try another word, or search every source."}),!V&&!Z&&0===Q.length&&0===H.length&&(0,t.jsx)(d.f,{variant:"first-use",title:null===U?"No plugins to show":`${U} offers no plugins`,description:null===U?"No source offers a plugin this console can install. Add a catalogue in Manage sources.":`${U} offers no plugins this console can install.`}),!V&&(W.length>0||P&&1===T)&&(0,t.jsxs)("ul",{className:(0,a.f)(o.J,eL),"aria-label":"Plugins",children:[P&&1===T&&(0,t.jsx)(es,{onUpload:()=>z(!0)}),W.map(e=>(0,t.jsx)(et,{entry:e,installed:h.has(e.entry.name),onInstall:b?C:void 0},`${e.source.name}/${e.entry.name}`))]}),!V&&B>1&&(0,t.jsx)(g.f,{pageNumber:T,pageCount:B,hasPrevious:T>1,hasNext:T<B,onPrevious:()=>N(T-1),onNext:()=>N(T+1),ariaLabel:"Plugins pagination"}),(0,t.jsx)(er.H,{opened:$?.opened??null,entryName:$?.entry.name??null,sourceName:$?.source.name??"",org:e,open:null!==$,onClose:()=>C(null),onInstalled:e=>{C(null),s?.(e)}}),(0,t.jsx)(eB,{open:S,org:e,onClose:()=>z(!1),onInstalled:e=>{z(!1),s?.(e)}}),(0,t.jsx)(O,{open:I,onClose:()=>M(!1),reads:u,marketplaces:i.marketplaces,unreadable:i.unreadable,isBuiltIn:i.isBuiltIn,add:i.add,remove:i.remove})]})}let eL="stg:grid stg:gap-3 stg:sm:grid-cols-2 stg:lg:grid-cols-3";function eG({label:e}){return(0,t.jsx)(u.f,{label:e,className:eL,children:[0,1,2,3,4,5].map(e=>(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-3 stg:rounded-lg stg:border stg:border-border stg:bg-card stg:p-4",children:[(0,t.jsxs)("div",{className:"stg:flex stg:items-start stg:gap-3",children:[(0,t.jsx)("div",{className:"stg:size-10 stg:shrink-0 stg:animate-pulse stg:rounded-lg stg:bg-muted"}),(0,t.jsxs)("div",{className:"stg:flex-1 stg:space-y-2",children:[(0,t.jsx)("div",{className:"stg:h-4 stg:w-32 stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsx)("div",{className:"stg:h-3 stg:w-20 stg:animate-pulse stg:rounded stg:bg-muted"})]})]}),(0,t.jsx)("div",{className:"stg:h-3 stg:w-full stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsx)("div",{className:"stg:h-3 stg:w-2/3 stg:animate-pulse stg:rounded stg:bg-muted"})]},e))})}function eP({failed:e,refetch:s,whole:r}){if(r){let[r]=e;return void 0===r||"failed"!==r.state.kind?null:(0,t.jsx)(l.f,{error:r.state.error,retry:()=>s(r.marketplace.name),title:`${r.marketplace.name} cannot be read right now`})}return(0,t.jsx)("ul",{className:(0,a.f)(o.J,"stg:flex stg:flex-col stg:gap-1"),"aria-label":"Sources that cannot be read",children:e.map(e=>"failed"===e.state.kind?(0,t.jsxs)("li",{className:"stg:flex stg:flex-wrap stg:items-baseline stg:gap-x-2 stg:text-xs stg:text-muted-foreground",children:[(0,t.jsx)("span",{className:"stg:font-medium stg:text-foreground",children:e.marketplace.name}),(0,t.jsxs)("span",{children:["cannot be read right now: ",e.state.error.message]}),(0,t.jsx)(n.f,{variant:"ghost",size:"xs",onClick:()=>s(e.marketplace.name),"aria-label":`Retry ${e.marketplace.name}`,children:"Retry"})]},e.marketplace.name):null)})}function eB({open:e,org:s,onClose:a,onInstalled:n}){let l=(0,r.useId)();return(0,t.jsx)(i.f,{open:e,onOpenChange:e=>{e||a()},width:"lg",className:"stg:max-h-[85vh] stg:bg-card stg:text-foreground","aria-labelledby":l,children:e&&(0,t.jsxs)("div",{className:"stg:flex stg:max-h-[85vh] stg:flex-col stg:gap-4 stg:overflow-y-auto stg:p-6",children:[(0,t.jsx)("h2",{id:l,className:"stg:text-base stg:font-semibold stg:text-foreground",children:"Upload a plugin"}),(0,t.jsx)(ea.f,{org:s,onComplete:n,onCancel:a})]})})}var eT=e.i(66724),eF=e.i(297629),eJ=e.i(42592);e.s(["MarketplacePage",0,function(){let e=(0,eF.x)(),r=(0,eF.c)(),a=(0,eJ.b)(),n=(0,s.useRouter)();return e?(0,t.jsxs)("div",{className:"mx-auto w-full max-w-5xl px-6 py-8",children:[(0,t.jsx)(eT.f,{className:"mb-6",title:"Marketplace",description:`Plugins for ${r}'s agents: tools, skills and whole agents, from Stigmer's catalogue or one you add.`}),(0,t.jsx)(eH,{org:e,onInstalled:({plugin:e})=>n.push(`/library/plugins/${a(e.metadata?.org??"")}/${e.metadata?.slug}`)})]}):null}],298021)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,214254,e=>{"use strict";let t=["Bash","Read","Write","Edit","Glob","Grep","Agent","WebFetch","WebSearch","TodoWrite","NotebookEdit","Skill"];new Set(t);let s=new Map([["execute",["Bash"]],["read_file",["Read"]],["write_file",["Write"]],["edit_file",["Edit"]],["delete",["Write"]],["glob",["Glob"]],["ls",["Glob"]],["grep",["Grep"]],["task",["Agent"]],["web_fetch",["WebFetch"]],["write_todos",["TodoWrite"]]]);new Map(t.filter(e=>"Skill"!==e).map(e=>[e,[e]]));let n={pending:"pending",in_progress:"in_progress",inprogress:"in_progress",completed:"completed",cancelled:"cancelled"};function i(e){return"string"==typeof e?e:""}let r=new Set(["completed","failed","cancelled","terminated"]),a=new Set(["exited","timed_out","stopped","failed_to_start"]),o=new Set(["agent","person","approval","turn"]);class l{clock=0;turns=[];turnsById=new Map;items=new Map;setsById=new Map;seen=new Set;held=[];pendingOutput=new Map;queued=new Map;queuedSnapshot=[];status={state:"idle",stopReason:"",waitingOn:[]};lastSeq=0n;idleSeq=0n;snapshotCache;apply(e){let t=this.clock;for(let t of e)this.applyEvent(t);return this.clock!==t}applyFrame(e){let t=this.clock;switch(e.frame.case){case"event":this.applyEvent(e.frame.value);break;case"eventStart":{let t=e.frame.value.event;void 0!==t&&this.openDraft(t.id,"agent.thinking"===t.type?"thinking":"message");break}case"eventDelta":{let t=e.frame.value,s=t.delta?.content?.text??"",n=this.items.get(t.eventId);void 0!==n&&"message"===n.kind&&n.live&&""!==s&&(n.text+=s,this.touch(n));break}case"stigmerToolOutputDelta":{let{toolUseId:t,delta:s}=e.frame.value,n=this.items.get(t);void 0===n?this.pendingOutput.set(t,(this.pendingOutput.get(t)??"")+s):"tool_use"===n.kind&&void 0===n.result&&""!==s?(n.liveOutput+=s,this.touch(n)):"tool_use"===n.kind&&void 0!==n.background&&void 0===n.background.ended&&""!==s&&(n.background.liveOutput+=s,this.touch(n));break}case"stigmerRunLiveness":{let t=e.frame.value,s=this.turnsById.get(t.runId);void 0!==s&&(s.liveness={operations:t.operations.map(e=>({toolUseId:e.toolUseId,name:e.name,threadId:e.threadId,elapsedMs:u(e.elapsed)})),awaitingModelMs:void 0===t.awaitingModelFor?void 0:u(t.awaitingModelFor)},this.touch(s))}}return this.clock!==t}snapshot(){if(this.snapshotCache?.clock===this.clock)return this.snapshotCache.value;let e=this.snapshotCache?.value,t=this.turns.map((e,t)=>this.snapTurn(e,this.endedOf(e,t))),s={turns:void 0!==e&&e.turns.length===t.length&&e.turns.every((e,s)=>e===t[s])?e.turns:t,queued:this.queuedSnapshot,status:this.status,lastSeq:this.lastSeq};return this.snapshotCache={clock:this.clock,value:s},s}applyEvent(e){let t=e.event;if(void 0===t.case)return;e.seq>this.lastSeq&&(this.lastSeq=e.seq,this.tick());let s=t.value.id;if("userMessage"===t.case&&""===e.runId){this.seen.has(s)||this.queued.has(s)||this.setQueued({id:s,text:d(t.value.content),state:"waiting"});return}if(""!==s&&this.seen.has(s))return;""!==s&&this.seen.add(s);let n=t.value.processedAt,i=e.runId;switch(t.case){case"userMessage":{this.queued.delete(s)&&(this.queuedSnapshot=[...this.queued.values()],this.tick());let r=this.turnOf(i),a=d(t.value.content);if(void 0===r.userMessage)r.userMessage={id:s,text:a,processedAt:n},this.touch(r);else if(0===r.items.length){let e=[r.userMessage.text,a].filter(e=>""!==e).join("\n\n");r.userMessage={...r.userMessage,text:e,joinedIds:[...r.userMessage.joinedIds??[],s]},this.touch(r)}else this.addText(e,"user_message",a);break}case"sessionStatusRunning":this.status={state:"running",stopReason:"",waitingOn:[]},this.tick();break;case"sessionStatusIdle":this.status={state:"idle",stopReason:t.value.stopReason?.type??"",waitingOn:[...t.value.stopReason?.eventIds??[]]},this.idleSeq=e.seq,this.tick();break;case"sessionError":{""===i&&this.dropWaiting();let e=""===i?this.turns.at(-1):this.turnOf(i);void 0!==e&&(e.errors.push({id:s,type:t.value.error?.type??"",message:t.value.error?.message??"",processedAt:n}),this.touch(e));break}case"agentMessage":this.addText(e,"message",d(t.value.content));break;case"agentThinking":this.addText(e,"thinking","");break;case"stigmerAgentThinking":{let e=t.value.thinkingId,s=t.value.text;this.whenItem(e,e=>{"thinking"===e.kind&&(e.text=s,this.touch(e))});break}case"stigmerHarnessNote":this.addText(e,"note",t.value.text);break;case"agentThreadContextCompacted":this.addText(e,"compacted","");break;case"agentToolUse":this.addTool(e,t.value.name,"",t.value.input??{},t.value.evaluatedPermission);break;case"agentMcpToolUse":this.addTool(e,t.value.name,t.value.mcpServerName,t.value.input??{},t.value.evaluatedPermission);break;case"agentToolResult":this.addResult(t.value.toolUseId,{id:s,text:d(t.value.content),isError:t.value.isError,processedAt:n});break;case"agentMcpToolResult":this.addResult(t.value.mcpToolUseId,{id:s,text:d(t.value.content),isError:t.value.isError,processedAt:n});break;case"stigmerPermissionAsked":{let e={id:s,message:t.value.message,argsPreview:t.value.argsPreview,policySource:t.value.policySource,policyHook:t.value.policyHook,processedAt:n};this.whenTool(t.value.toolUseId,t=>{t.ask=e});break}case"userToolConfirmation":{let e={id:s,result:"deny"===t.value.result?"deny":"allow",denyMessage:t.value.denyMessage,processedAt:n};this.whenTool(t.value.toolUseId,t=>{t.confirmation=e});break}case"stigmerPermissionGrant":{let e=t.value.lease,i={id:s,scope:t.value.scope,category:e?.category??"",server:e?.server??"",hook:e?.hook,tool:e?.tool??"",processedAt:n};this.whenTool(t.value.toolUseId,e=>{e.grant=i});break}case"stigmerToolResultFullOutput":{let e={storageKey:t.value.storageKey,sizeBytes:t.value.sizeBytes,contentHash:t.value.contentHash,mimeType:t.value.mimeType,isImage:t.value.isImage};this.whenTool(t.value.toolUseId,t=>{var s;let n;i===t.runId&&(s=t.runId,(n=e.storageKey.split("/")).length>2&&"artifacts"===n[0]&&n[1]===s&&n.every(e=>""!==e&&"."!==e&&".."!==e))&&(t.fullOutput=e)});break}case"stigmerBackgroundCommandStatus":{let e=t.value;if(this.whenTool(e.toolUseId,t=>{let s=c(t);if("running"===e.phase){s.timeoutSeconds=e.timeoutSeconds,s.startedAt=n;return}void 0===s.ended&&(s.startedAt||=n,s.ended={state:a.has(e.ending)?e.ending:"stopped",exitCode:e.exitCode,stoppedBy:o.has(e.stoppedBy)?e.stoppedBy:void 0,stoppedByToolUseId:e.stoppedByToolUseId,output:e.output,endedAt:e.endedAt},s.liveOutput="")}),"ended"===e.phase&&""!==e.stoppedByToolUseId){let t=e.toolUseId;this.whenTool(e.stoppedByToolUseId,e=>{e.stoppedBackground=t})}break}case"stigmerBackgroundCommandStopRequested":this.whenTool(t.value.toolUseId,e=>{c(e).stopRequested=!0});break;case"stigmerMcpToolDefinition":break;case"sessionThreadCreated":{let e=this.threadOf(this.turnOf(i),t.value.sessionThreadId);e.agentName=t.value.agentName,this.touch(e);break}case"sessionThreadStatusRunning":{let e=this.threadOf(this.turnOf(i),t.value.sessionThreadId);e.agentName||=t.value.agentName,e.state="running",this.touch(e);break}case"agentThreadMessageSent":{let e=this.threadOf(this.turnOf(i),t.value.toSessionThreadId);e.input=d(t.value.content),e.agentName||=t.value.toAgentName,this.touch(e);break}case"agentThreadMessageReceived":{let e=this.threadOf(this.turnOf(i),t.value.fromSessionThreadId);e.reply=d(t.value.content),this.touch(e);break}case"sessionThreadStatusIdle":{let e=this.threadOf(this.turnOf(i),t.value.sessionThreadId);e.state=t.value.stopReason?.type==="end_turn"?"completed":"failed",this.touch(e);break}case"stigmerAgentStructuredOutput":{let e=this.turnOf(i);e.structuredOutput=t.value.output??{},this.touch(e);break}case"stigmerMemoryRecalled":{let e=this.turnOf(i);e.memory={selectionActive:t.value.selectionActive,injectedMemoryIds:[...t.value.injectedMemoryIds],embeddingModel:t.value.embeddingModel},this.touch(e);break}case"stigmerRunStatus":{let e=this.turnOf(i);e.status={phase:t.value.phase,stopCause:t.value.stopCause,error:t.value.error,processedAt:n},this.touch(e);break}case"stigmerFileReviewChanges":{if(this.setsById.has(t.value.changeSetId))break;let e=this.turnOf(i),r={rev:0,changeSetId:t.value.changeSetId,runId:i,changesEventId:s,aggregateDigest:t.value.aggregateDigest,files:t.value.files.map(e=>({fileChangeId:e.fileChangeId,path:e.path,previousPath:e.previousPath,change:e.change,digest:e.digest,linesAdded:e.linesAdded,linesRemoved:e.linesRemoved,reviewable:e.reviewable})),processedAt:n,decisions:[],reconciles:[]};this.setsById.set(r.changeSetId,r),e.sets.push(r),this.touchSet(r),this.release();break}case"stigmerFileReviewDecided":{let e={id:s,scope:"file"===t.value.scope?"file":"change_set",fileChangeId:t.value.fileChangeId,action:"undo"===t.value.action?"undo":"keep",expectedDigest:t.value.expectedDigest,origin:t.value.origin,reason:t.value.reason,processedAt:n};this.whenSet(t.value.changeSetId,t=>{t.decisions.push(e)});break}case"stigmerFileReviewReconciled":{let e=t.value;this.turnOf(i),this.whenSet(e.changeSetId,t=>{let i=`${t.changesEventId}.r.`;t.reconciles.push({id:s,decidedEventId:s.startsWith(i)?s.slice(i.length):"",undonePaths:[...e.undonePaths],failure:e.failure,failureDetail:e.failureDetail,processedAt:n})});break}case"userInterrupt":this.dropWaiting()}}setQueued(e){this.queued.set(e.id,e),this.queuedSnapshot=[...this.queued.values()],this.tick()}dropWaiting(){let e=[...this.queued.values()].filter(e=>"waiting"===e.state);for(let t of e)this.queued.set(t.id,{...t,state:"dropped"});e.length>0&&(this.queuedSnapshot=[...this.queued.values()],this.tick())}tick(){this.clock+=1}touch(e){this.tick();let t=e;for(;void 0!==t;)t.rev=this.clock,t="turn"===t.kind?void 0:"thread"===t.kind?t.turn:t.owner}touchSet(e){this.tick(),e.rev=this.clock;let t=this.turnsById.get(e.runId);void 0!==t&&this.touch(t)}turnOf(e){let t=this.turnsById.get(e);return void 0===t&&(t={kind:"turn",rev:0,runId:e,appearedAt:this.lastSeq,items:[],threads:new Map,todos:new Map,errors:[],sets:[]},this.turnsById.set(e,t),this.turns.push(t),this.touch(t)),t}threadOf(e,t){let s=e.threads.get(t);return void 0===s&&(s={kind:"thread",rev:0,id:t,turn:e,agentName:"",input:"",reply:"",state:"running",items:[]},e.threads.set(t,s),this.touch(s)),s}ownerOf(e,t){let s=this.turnOf(e);return""===t?s:this.threadOf(s,t)}addText(e,t,s){let n=e.event.value,i=this.items.get(n.id);if(void 0!==i&&i.kind===t&&i.live){i.text="thinking"===t&&""===s?i.text:s,i.live=!1,i.processedAt=n.processedAt,this.touch(i),this.release();return}let r=this.ownerOf(e.runId,e.threadId),a={kind:t,rev:0,id:n.id,text:s,live:!1,processedAt:n.processedAt,owner:r};r.items.push(a),this.items.set(a.id,a),this.touch(a),this.release()}addTool(e,t,s,n,i){let r=e.event.value,a=this.ownerOf(e.runId,e.threadId),o={kind:"tool_use",rev:0,id:r.id,runId:e.runId,threadId:e.threadId,name:t,mcpServerName:s,input:n,evaluatedPermission:i,processedAt:r.processedAt,owner:a,liveOutput:this.pendingOutput.get(r.id)??""};this.pendingOutput.delete(r.id),a.items.push(o),this.items.set(o.id,o),this.touch(o),this.release()}addResult(e,t){this.whenTool(e,e=>{var r;let a;e.result=t,e.liveOutput="";let o=this.turnsById.get(e.runId);void 0!==o&&""===e.threadId&&""===e.mcpServerName&&!t.isError&&(r=e.name,a=s.get(r),a?.includes("TodoWrite")??"TodoWrite"===r)&&(!function(e,t,s){let{merge:r,now:a}=s;if(!Array.isArray(t)||0===t.length)return!r&&e.clear();r||e.clear(),t.forEach((t,s)=>{let o="object"==typeof t&&null!==t?t:{},l=i(o.id)||`todo-${s}`,d=r?e.get(l):void 0;e.set(l,{id:l,content:i(o.content),status:n[(i(o.status)||"pending").toLowerCase()]??"pending",createdAt:d?.createdAt||i(o.created_at)||a,updatedAt:a})})}(o.todos,e.input.todos,{merge:!0===e.input.merge,now:t.processedAt}),this.touch(o))})}openDraft(e,t){if(this.seen.has(e)||this.items.has(e))return;let s=function(e){let t=/^([^.]+)\.(.+)\.[mt]\d+$/.exec(e);if(null===t)return;let s=t[1],n=t[2];return{runId:s,threadId:"root"===n?"":`${s}.${n}`}}(e);if(void 0===s)return;let n=this.ownerOf(s.runId,s.threadId),i={kind:t,rev:0,id:e,text:"",live:!0,processedAt:"",owner:n};n.items.push(i),this.items.set(e,i),this.touch(i)}whenItem(e,t){let s=s=>{let n=s.items.get(e);return void 0!==n&&("tool_use"===n.kind||!n.live)&&(t(n),s.touch(n),!0)};s(this)||this.held.push(s)}whenTool(e,t){this.whenItem(e,e=>{"tool_use"===e.kind&&t(e)})}whenSet(e,t){let s=s=>{let n=s.setsById.get(e);return void 0!==n&&(t(n),s.touchSet(n),!0)};s(this)||this.held.push(s)}release(){if(0!==this.held.length)for(let e of this.held.splice(0))e(this)||this.held.push(e)}endedOf(e,t){if(void 0!==e.status)return r.has(e.status.phase);if(t<this.turns.length-1)return!0;if("idle"!==this.status.state||""===this.status.stopReason||0n!==this.idleSeq&&this.idleSeq<=e.appearedAt)return!1;if("requires_action"!==this.status.stopReason)return!0;let s=new Set(this.status.waitingOn);return![...this.items.values()].some(t=>"tool_use"===t.kind&&t.runId===e.runId&&s.has(t.id))}snapTurn(e,t){let s=`${e.rev}|${t}`;if(e.cache?.key===s)return e.cache.value;let n=[],i=e.items.map(e=>this.snapItem(e,t,n)),r=[...i].reverse().find(e=>"message"===e.kind&&!e.live),a={runId:e.runId,userMessage:e.userMessage,items:g(e.cache?.value.items,i),status:e.status,ended:t,asks:g(e.cache?.value.asks,n),todos:[...e.todos.values()],structuredOutput:e.structuredOutput,memory:e.memory,fileReview:e.sets.map(e=>this.snapSet(e)),errors:[...e.errors],answer:r?.text??"",liveness:t?void 0:this.openLiveness(e.liveness)};return e.cache={key:s,value:a},a}openLiveness(e){if(void 0===e)return;let t=e.operations.filter(e=>{let t=this.items.get(e.toolUseId);return void 0===t||"tool_use"!==t.kind||void 0===t.result});return t.length===e.operations.length?e:{...e,operations:t}}snapItem(e,t,s){var n,i;let r;if("tool_use"!==e.kind){if(e.cache?.key===`${e.rev}`)return e.cache.value;let t=function(e){switch(e.kind){case"message":return{kind:"message",id:e.id,text:e.text,live:e.live,processedAt:e.processedAt};case"thinking":return{kind:"thinking",id:e.id,text:e.text,live:e.live,processedAt:e.processedAt};case"note":return{kind:"note",id:e.id,text:e.text,processedAt:e.processedAt};case"compacted":return{kind:"compacted",id:e.id,processedAt:e.processedAt};case"user_message":return{kind:"user_message",id:e.id,text:e.text,processedAt:e.processedAt}}}(e);return e.cache={key:`${e.rev}`,value:t},t}let a=("thread"===e.owner.kind?e.owner.turn:e.owner).threads.get(e.id),o=[],l=void 0===a?void 0:this.snapThread(a,t,o),d=`${e.rev}|${t}|${a?.rev??-1}`;return e.cache?.key===d?r=e.cache.value:(r={kind:"tool_use",id:e.id,runId:e.runId,threadId:e.threadId,name:e.name,mcpServerName:e.mcpServerName,input:e.input,evaluatedPermission:e.evaluatedPermission,state:(n=e,i=t,n.confirmation?.result==="deny"||"deny"===n.evaluatedPermission?"denied":void 0!==n.result?n.result.isError?"failed":"completed":i?"stopped":"ask"===n.evaluatedPermission&&void 0===n.confirmation?"waiting":"running"),ask:e.ask,confirmation:e.confirmation,grant:e.grant,result:e.result,fullOutput:e.fullOutput,liveOutput:e.liveOutput,background:function(e,t){if(void 0===e)return;let s=e.ended;return void 0!==s?{state:s.state,timeoutSeconds:e.timeoutSeconds,exitCode:s.exitCode,stoppedBy:s.stoppedBy,stoppedByToolUseId:s.stoppedByToolUseId,output:s.output,startedAt:e.startedAt,endedAt:s.endedAt,liveOutput:"",stopRequested:e.stopRequested}:{state:t?"stopped":"running",timeoutSeconds:e.timeoutSeconds,exitCode:void 0,stoppedBy:t?"turn":void 0,stoppedByToolUseId:"",output:t?e.liveOutput:"",startedAt:e.startedAt,endedAt:"",liveOutput:t?"":e.liveOutput,stopRequested:e.stopRequested}}(e.background,t),stoppedBackground:this.stoppedBackgroundOf(e),thread:l,processedAt:e.processedAt},e.cache={key:d,value:r}),"waiting"===r.state&&s.push(r),s.push(...o),r}stoppedBackgroundOf(e){if(void 0===e.stoppedBackground)return;let t=this.items.get(e.stoppedBackground);return{toolUseId:e.stoppedBackground,input:t?.kind==="tool_use"?t.input:{}}}snapThread(e,t,s){let n=e.items.map(e=>this.snapItem(e,t,s)),i=`${e.rev}|${t}`;if(e.cache?.key===i)return e.cache.value;let r={id:e.id,agentName:e.agentName,input:e.input,reply:e.reply,state:"running"===e.state&&t?"stopped":e.state,items:g(e.cache?.value.items,n)};return e.cache={key:i,value:r},r}snapSet(e){let t=`${e.rev}`;if(e.cache?.key===t)return e.cache.value;let s=function(e){let t=new Map;for(let s of e.decisions)if("change_set"===s.scope)for(let n of e.files)t.set(n.fileChangeId,s);else t.set(s.fileChangeId,s);let s=new Map(e.reconciles.map(e=>[e.decidedEventId,e]));return e.files.map(e=>{let n=t.get(e.fileChangeId),i="undecided";if(n?.action==="keep")i="kept";else if(n?.action==="undo"){let e=s.get(n.id);i=void 0===e?"undoing":""===e.failure?"undone":"undo_failed"}return{...e,state:i,decidedBy:n?.origin??""}})}(e),n={changeSetId:e.changeSetId,runId:e.runId,aggregateDigest:e.aggregateDigest,files:s,decisions:[...e.decisions],reconciles:e.reconciles.map(({decidedEventId:e,...t})=>t),undecided:s.some(e=>"undecided"===e.state),processedAt:e.processedAt};return e.cache={key:t,value:n},n}}function d(e){return e.filter(e=>"text"===e.type).map(e=>e.text).join("")}function u(e){return void 0===e?0:1e3*Number(e.seconds)+Math.floor(e.nanos/1e6)}function c(e){return e.background??={timeoutSeconds:0,startedAt:"",liveOutput:"",stopRequested:!1},e.background}function g(e,t){return void 0!==e&&e.length===t.length&&e.every((e,s)=>e===t[s])?e:t}e.s(["H",0,l,"p",0,function(e){let t=new l;return t.apply(e),t.snapshot()},"s",0,function(e){return e.background?.state==="running"}],214254)},196716,836959,e=>{"use strict";var t=e.i(910304),s=e.i(255817),n=e.i(616701);e.s(["f",0,function(e,i){let r=(0,s.f)(),a=e&&i?async()=>{try{return await r.agent.getByReference({org:e,slug:i})}catch(e){if((0,t.c)(e))return null;throw e}}:null,{data:o,isLoading:l,isRefetching:d,error:u,refetch:c}=(0,n.f)(a,[e,i,r],null);return{agent:o,isLoading:l,isRefetching:d,error:u,refetch:c}}],196716);var i=e.i(972992);let r=["session","routine","agent","organization"];function a(e){return null!=e&&((e.slug??"")!==""||(e.id??"")!=="")}function o(e){return{org:e.org,slug:e.slug,...e.id?{id:e.id}:{}}}let l={[i.u.UNSPECIFIED]:void 0,[i.u.SESSION]:"session",[i.u.ROUTINE]:"routine",[i.u.AGENT]:"agent",[i.u.ORGANIZATION]:"organization"};e.s(["c",0,function(e,t=!1){let s=void 0===e?void 0:l[e.environmentSource];return e?.environment!==void 0&&a(e.environment)&&void 0!==s?{kind:"chosen",environment:o(e.environment),source:s}:t?{kind:"own-machine"}:{kind:"none"}},"f",0,function(e,t){return"local"===t?"own-machine":void 0===t&&e?.applies===!1?"not-on-server":void 0},"g",0,function(e){if(void 0!==e.notApplying)return{kind:e.notApplying};let t={session:e.own,routine:e.routine,agent:e.agent,organization:e.organization};for(let e of r){let s=t[e];if(a(s))return{kind:"chosen",environment:o(s),source:e}}return{kind:"none"}}],836959)},780412,e=>{"use strict";var t=e.i(891287),s=e.i(392686),n=e.i(910304),i=e.i(255817),r=e.i(616701),a=e.i(196716);let o={kind:"unknown"};e.s(["f",0,function(e,l=""){let d=(0,i.f)(),{agent:u,isLoading:c}=(0,a.f)(e?.org||null,e?.slug||null),g=u?.metadata?.id??"",h=""!==l,{data:p}=(0,r.f)(h&&""!==g?async()=>{try{let e=await d.agent.getVersion((0,t.f)(s.p,{agentId:g,versionHash:l}));return{kind:"spec",spec:e.specSnapshot}}catch(e){return(0,n.c)(e)?{kind:"absent"}:{kind:"unknown"}}}:null,[h,g,l,d],o),m=h?"spec"===p.kind?p.spec:"absent"===p.kind?u?.spec:void 0:u?.spec;return{agent:u,spec:m,isLoading:c}}])},598292,e=>{"use strict";var t=e.i(974265),s=e.i(893976),n=e.i(610595);let i="/models";e.s(["u",0,i,"b",0,function({error:e,modelsHubHref:r=i,className:a}){return(0,t.jsxs)("div",{className:(0,s.f)("stg:rounded-md stg:border stg:border-border stg:bg-muted-subtle stg:px-3 stg:py-2 stg:text-xs",a),role:"alert",children:[(0,t.jsx)("p",{className:"stg:text-foreground",children:(0,n.g)(e)}),(0,t.jsx)("a",{href:r,className:"stg:mt-1 stg:inline-block stg:font-medium stg:text-primary stg:hover:underline",children:"Open Models & providers"})]})},"A",0,function(e){let t=(0,n.k)(e);return t?.reason!=="PROVIDER_KEY_REQUIRED"?null:{org:t.metadata.org??"",provider:t.metadata.provider??"",model:t.metadata.model??""}}])},247112,e=>{"use strict";var t=e.i(974265),s=e.i(893976),n=e.i(610595),i=e.i(937111),r=e.i(628217);let a="/settings/billing",o={teams:i.x.teams,child_orgs:i.x.child_orgs,access_history:i.x.access_history};e.s(["Q",0,a,"e",0,function({feature:e,error:i,unlockingPlanName:o,billingHref:l=a,className:d}){let u=(0,r.e)(e)?r.o[e]:void 0,c=u?.label??"This feature",g=u?.plural??!1,h=void 0===o||""===o?`${c} ${g?"are":"is"} not included in this organization's plan.`:`${c} ${g?"need":"needs"} the ${o} plan or above.`,p=i?(0,n.g)(i):h;return(0,t.jsxs)("div",{className:(0,s.f)("stg:rounded-md stg:border stg:border-border stg:bg-muted-subtle stg:px-3 stg:py-2 stg:text-xs",d),role:"status",children:[(0,t.jsx)("p",{className:"stg:text-foreground",children:p}),(0,t.jsx)("a",{href:l,className:"stg:mt-1 stg:inline-block stg:font-medium stg:text-primary stg:hover:underline",children:"View plans"})]})},"S",0,function(e){let t=(0,n.k)(e);return t?.reason!=="PLAN_UPGRADE_REQUIRED"?null:o[t.metadata.feature??""]??null}])},373351,348990,e=>{"use strict";var t=e.i(974265),s=e.i(651023),n=e.i(893976),i=e.i(891287),r=e.i(95265),a=e.i(255817),o=e.i(766330),l=e.i(205413),d=e.i(616701);function u(e){let t=(0,a.f)(),s=e?()=>(0,l.T)(s=>t.environment.list((0,i.f)(r.t,{org:e,pageSize:o.J,pageToken:s}))):null,{data:n,isLoading:u,isRefetching:c,error:g,refetch:h}=(0,d.f)(s,[e,t],[]);return{environments:n,isLoading:u,isRefetching:c,error:g,refetch:h}}function c(e){return e.metadata?.name||e.metadata?.slug||""}e.s(["B",0,c,"s",0,u],348990),e.s(["f",0,function({org:e,value:i,onChange:r,defaultLabel:a="Default: none",label:o="Environment",showLabel:l=!1,disabled:d=!1,className:g}){let{environments:h,isLoading:p}=u(e),m=(0,s.useId)(),f=(0,s.useMemo)(()=>{let t=h.map(t=>({org:t.metadata?.org??e,slug:t.metadata?.slug??"",name:c(t)})),s=i?.slug??"";return""===s||t.some(e=>e.slug===s)||t.push({org:i?.org??e,slug:s,name:s}),t},[h,e,i]);return(0,t.jsxs)("div",{className:(0,n.f)("stg:flex stg:flex-col stg:gap-1",g),children:[(0,t.jsx)("label",{htmlFor:m,className:l?"stg:text-xs stg:font-medium stg:text-muted-foreground":"stg:sr-only",children:o}),(0,t.jsxs)("select",{id:m,disabled:d,value:i?.slug??"",onChange:e=>{let t=f.find(t=>t.slug===e.target.value);r(void 0===t?void 0:{org:t.org,slug:t.slug})},className:(0,n.f)("stg:w-full stg:rounded-md stg:border stg:border-border stg:bg-background stg:px-3 stg:py-1.5 stg:text-sm","stg:text-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring","stg:disabled:cursor-not-allowed stg:disabled:opacity-50"),children:[(0,t.jsx)("option",{value:"",children:a}),f.map(e=>(0,t.jsx)("option",{value:e.slug,children:e.name},e.slug)),p&&0===f.length&&(0,t.jsx)("option",{value:"",disabled:!0,children:"Loading environments..."})]})]})}],373351)},653650,e=>{"use strict";let t={session:"chosen for this conversation",routine:"set by the routine",agent:"the agent's default",organization:"the organization's default"},s={"own-machine":"Environments don't apply here: this conversation runs on your own machine","not-on-server":"Environments don't apply here: conversations on this server don't run in sandboxes it starts"};e.s(["A",0,s,"O",0,"Environments don't apply on this server: its conversations don't run in sandboxes it starts. You can still create them for a server that does.","a",0,"This server's sandboxes can't limit networking to listed websites.","j",0,"This server's sandboxes can't install packages.","Q",0,function(e,n=e=>e.slug){return"chosen"===e.kind?`${n(e.environment)} \xb7 ${t[e.source]}`:"none"===e.kind?"No environment: the server's standard sandbox":s[e.kind]},"P",0,function(e,s=e=>e.slug){return"chosen"===e.kind?`Default: ${s(e.environment)} (${t[e.source]})`:"Default: none"}])},282838,699078,e=>{"use strict";var t=e.i(651023);function s(){return!1}e.s(["f",0,s],699078),e.s(["f",0,function(e,n){let i=(0,t.useRef)(0),r=(0,t.useRef)(null);if(!s())return;i.current+=1;let a=i.current,o=r.current;if(a%10==0||1===a){let t=[];if(o)for(let e of Object.keys(n))Object.is(n[e],o[e])||t.push(e);let s=[`[stgm:perf:render] ${e}`,`render=#${a}`];for(let[e,t]of Object.entries(n))"string"==typeof t?s.push(`${e}=${t.length>40?t.slice(0,40)+"…":t}`):("number"==typeof t||"boolean"==typeof t)&&s.push(`${e}=${String(t)}`);o&&s.push(t.length>0?`changed=[${t.join(",")}]`:"changed=[]"),console.debug(s.join(" "))}r.current={...n}}],282838)},628217,e=>{"use strict";var t=e.i(937111);let s={[t.x.channels]:{label:"Slack and WhatsApp",description:"Reach people in Slack and WhatsApp through the hosted channel runtime.",plural:!0},[t.x.chat_links]:{label:"Chat links",description:"Hosted chat links and embeds, for your organization or for anyone with the link.",plural:!0},[t.x.teams]:{label:"Teams",description:"Group members into teams and grant access to a team at once.",plural:!0},[t.x.child_orgs]:{label:"Child organizations",description:"Create organizations for your own customers under this one.",plural:!0},[t.x.access_history]:{label:"Access history",description:"Read and export who gave whom access to what, and when.",plural:!1}};e.s(["o",0,s,"e",0,function(e){return e in s}])},879049,e=>{"use strict";var t=e.i(974265);let s={js:"code",jsx:"code",mjs:"code",cjs:"code",ts:"code",tsx:"code",py:"code",rb:"code",go:"code",rs:"code",java:"code",kt:"code",c:"code",h:"code",cpp:"code",cc:"code",hpp:"code",cs:"code",php:"code",swift:"code",sh:"code",bash:"code",zsh:"code",lua:"code",dart:"code",scala:"code",proto:"code",html:"markup",htm:"markup",xml:"markup",vue:"markup",svelte:"markup",css:"style",scss:"style",sass:"style",less:"style",json:"data",jsonc:"data",yaml:"data",yml:"data",toml:"data",ini:"data",env:"data",csv:"data",tsv:"data",md:"markdown",mdx:"markdown",markdown:"markdown",png:"image",jpg:"image",jpeg:"image",gif:"image",webp:"image",svg:"image",ico:"image",bmp:"image"},n={code:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("path",{d:"M7 8.5L5.75 9.75L7 11"}),(0,t.jsx)("path",{d:"M9 8.5L10.25 9.75L9 11"})]}),markup:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("path",{d:"M6.5 8.5L5.5 9.9L6.5 11.3"}),(0,t.jsx)("path",{d:"M9.5 8.5L10.5 9.9L9.5 11.3"})]}),style:(0,t.jsx)("path",{d:"M5.5 9.3H10.5M5.5 11.1H8.5"}),data:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("path",{d:"M7 8.4C6.2 8.4 6.2 9.3 6.2 9.9C6.2 10.5 6.2 11.4 5.4 11.4"}),(0,t.jsx)("path",{d:"M9 8.4C9.8 8.4 9.8 9.3 9.8 9.9C9.8 10.5 9.8 11.4 10.6 11.4"})]}),markdown:(0,t.jsx)("path",{d:"M5.4 11.3V8.6L6.9 10.1L8.4 8.6V11.3M10.4 8.7V11.1M9.5 10.2L10.4 11.2L11.3 10.2"}),image:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("circle",{cx:"6.4",cy:"9",r:"0.7"}),(0,t.jsx)("path",{d:"M5.2 11.4L7.3 9.9L10.6 11.6"})]}),generic:(0,t.jsx)("path",{d:"M5.5 9.3H10.5M5.5 11.1H10.5"})};e.s(["U",0,function({fileName:e}){let i,r=(i=e.lastIndexOf("."))<0||i===e.length-1?"generic":s[e.slice(i+1).toLowerCase()]??"generic";return(0,t.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",className:"stg:shrink-0","aria-hidden":"true",children:[(0,t.jsx)("path",{d:"M9.5 1.5H4.5C3.95 1.5 3.5 1.95 3.5 2.5V13.5C3.5 14.05 3.95 14.5 4.5 14.5H11.5C12.05 14.5 12.5 14.05 12.5 13.5V4.5L9.5 1.5Z"}),(0,t.jsx)("path",{d:"M9.3 1.7V4.5H12.3"}),n[r]]})},"M",0,function({open:e=!1}){return(0,t.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",className:"stg:shrink-0","aria-hidden":"true",children:e?(0,t.jsx)("path",{d:"M1.8 5.5V12A1 1 0 002.8 13H12.6L14.5 7.5H4.2L2.8 11"}):(0,t.jsx)("path",{d:"M1.8 4.5A1 1 0 012.8 3.5H6L7.3 5H13.2A1 1 0 0114.2 6V12A1 1 0 0113.2 13H2.8A1 1 0 011.8 12V4.5Z"})})}])},536907,e=>{"use strict";var t=e.i(974265),s=e.i(651023),n=e.i(893976),i=e.i(869803),r=e.i(879049);let a="application/x-stigmer-file-ref";e.s(["C",0,a,"B",0,function e({node:o,selectedPath:l,onSelect:d,onActivate:u,depth:c,enableDrag:g=!1,showIcons:h=!1,indentGuides:p=!1,maxInitialDepth:m}){let[f,v]=(0,s.useState)(void 0===m||c<m),x=!!o.children,b=o.path===l,k=g&&!x,y=(0,s.useCallback)(()=>{x?v(e=>!e):d(o.path)},[x,o.path,d]),j=(0,s.useCallback)(()=>{x||u?.(o.path)},[x,o.path,u]),w=(0,s.useCallback)(e=>{e.dataTransfer.setData(a,JSON.stringify({path:o.path})),e.dataTransfer.effectAllowed="link"},[o.path]);return(0,t.jsxs)("li",{role:"treeitem","aria-level":c+1,"aria-expanded":x?f:void 0,children:[(0,t.jsxs)("button",{type:"button",onClick:y,onDoubleClick:u?j:void 0,draggable:k,onDragStart:k?w:void 0,className:(0,n.f)("stg:flex stg:w-full stg:items-center stg:gap-1.5 stg:py-1 stg:text-left stg:text-xs stg:transition-colors","stg:hover:bg-muted","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-inset stg:focus-visible:ring-ring",b&&!x&&"stg:bg-muted stg:text-foreground stg:font-medium",!b&&"stg:text-muted-foreground",k&&"stg:cursor-grab stg:active:cursor-grabbing"),style:{paddingLeft:p?"8px":`${12+12*c}px`,paddingRight:"8px"},"aria-current":b?"true":void 0,children:[x&&(0,t.jsx)("span",{"aria-hidden":"true",className:"stg:text-2xs stg:text-muted-foreground-subtle",children:f?"▼":"▶"}),h&&(x?(0,t.jsx)(r.M,{open:f}):(0,t.jsx)(r.U,{fileName:o.name})),(0,t.jsx)("span",{className:(0,n.f)("stg:truncate",x&&"stg:font-medium stg:text-foreground"),children:o.name})]}),x&&f&&o.children&&(0,t.jsx)("ul",{role:"group",className:(0,n.f)(i.J,p&&"stg:ml-3 stg:border-l stg:border-border"),children:o.children.map(s=>(0,t.jsx)(e,{node:s,selectedPath:l,onSelect:d,onActivate:u,depth:c+1,enableDrag:g,showIcons:h,indentGuides:p,maxInitialDepth:m},s.path))})]})}])},513642,841358,e=>{"use strict";var t=e.i(974265),s=e.i(651023),n=e.i(170255),i=e.i(893976),r=e.i(48386),a=e.i(230849),o=e.i(4144),l=e.i(885795),d=e.i(42592),u=e.i(141249);let c="stgm-plugin-list";function g({text:e,query:s}){if(!s)return(0,t.jsx)(t.Fragment,{children:e});let n=e.toLowerCase().indexOf(s.toLowerCase());return -1===n?(0,t.jsx)(t.Fragment,{children:e}):(0,t.jsxs)(t.Fragment,{children:[e.slice(0,n),(0,t.jsx)("span",{className:"stg:font-semibold",children:e.slice(n,n+s.length)}),e.slice(n+s.length)]})}function h(){return(0,t.jsx)("div",{className:"stg:space-y-1 stg:py-1",children:[55,70,45,62].map((e,s)=>(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1 stg:px-2 stg:py-1.5",children:[(0,t.jsx)("div",{className:"stg:h-3 stg:rounded stg:bg-muted stg:animate-pulse",style:{width:`${e}%`}}),(0,t.jsx)("div",{className:"stg:h-2 stg:rounded stg:bg-muted-subtle stg:animate-pulse",style:{width:`${Math.min(e+15,90)}%`}})]},s))})}function p(){return(0,t.jsx)(u.f,{className:"stg:size-3 stg:shrink-0 stg:text-muted-foreground"})}function m(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 14 14",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M4 4L10 10M10 4L4 10"})})}e.s(["f",0,function({org:e,value:u,onChange:f,onDisplayNameResolved:v,disabled:x,className:b}){let{results:k,isLoading:y,error:j,query:w,setQuery:I}=(0,r.f)(n.X.plugin,e,void 0),[N,S]=(0,s.useState)(-1),M=(0,s.useRef)(null),A=(0,a.f)(),C=(0,a.f)(),$=(0,d.w)(),O=(0,s.useMemo)(()=>new Set(u.map(e=>`${$(e.org)}/${e.slug}`)),[u,$]),T=(0,s.useMemo)(()=>k.filter(e=>!O.has(`${$(e.org)}/${e.slug}`)),[k,O,$]);(0,s.useEffect)(()=>{S(-1)},[w]),(0,s.useEffect)(()=>{N>=0&&A.scrollRef.current?.querySelector(`[data-idx="${N}"]`)?.scrollIntoView({block:"nearest"})},[N,A.scrollRef]);let R=(0,s.useCallback)(e=>{f([...u,{org:e.org,slug:e.slug,kind:n.X.plugin}]),v?.(`${e.org}/${e.slug}`,e.name)},[u,f,v]),B=(0,d.$)(),L=(0,s.useCallback)(e=>{f(u.filter(t=>!B(t,e)))},[u,f,B]),D=(0,s.useCallback)(e=>{"ArrowDown"===e.key?(e.preventDefault(),S(e=>e<T.length-1?e+1:e)):"ArrowUp"===e.key?(e.preventDefault(),S(e=>e>0?e-1:-1)):"Enter"===e.key&&N>=0&&N<T.length?(e.preventDefault(),R(T[N])):"Enter"===e.key&&e.preventDefault()},[T,N,R]);return(0,t.jsxs)("div",{className:["stg:space-y-2 stg:w-72",b].filter(Boolean).join(" "),children:[u.length>0&&(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("div",{className:"stg:text-2xs stg:font-medium stg:text-muted-foreground",children:"Selected"}),(0,t.jsxs)("div",{className:"stg:relative",children:[C.canScrollUp&&(0,t.jsx)(o.f,{position:"top"}),(0,t.jsx)("div",{ref:C.scrollRef,className:"stg:max-h-28 stg:space-y-1 stg:overflow-y-auto",children:u.map((e,s)=>{let n=e.slug||"deleted plugin";return(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:rounded-md stg:bg-muted-faint stg:px-2 stg:py-1 stg:text-xs",children:[(0,t.jsx)(p,{}),(0,t.jsx)("span",{className:"stg:min-w-0 stg:flex-1 stg:truncate stg:text-foreground",children:n}),(0,t.jsx)("button",{type:"button",onClick:()=>L(e),disabled:x,className:"stg:shrink-0 stg:text-muted-foreground stg:hover:text-destructive stg:disabled:pointer-events-none","aria-label":`Remove ${n}`,children:(0,t.jsx)(m,{})})]},`${s}:${e.id||`${e.org}/${e.slug}`}`)})}),C.canScrollDown&&(0,t.jsx)(o.f,{position:"bottom"})]})]}),(0,t.jsx)("input",{ref:M,type:"text",role:"combobox","aria-expanded":!0,"aria-controls":c,"aria-activedescendant":N>=0?`stgm-plugin-${N}`:void 0,placeholder:"Search plugins...",value:w,onChange:e=>I(e.target.value),onKeyDown:D,disabled:x,className:"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",autoFocus:!0}),j&&(0,t.jsx)("p",{className:"stg:text-xs stg:text-destructive",children:j.message}),(0,t.jsxs)("div",{className:"stg:relative",children:[A.canScrollUp&&(0,t.jsx)(o.f,{position:"top"}),(0,t.jsx)("div",{ref:A.scrollRef,id:c,role:"listbox","aria-label":"Plugins",className:"stg:max-h-52 stg:overflow-y-auto",children:y?(0,t.jsx)(h,{}):0===T.length?(0,t.jsx)("div",{className:"stg:py-4 stg:text-center stg:text-xs stg:text-muted-foreground",children:w?"No plugins match your search":u.length>0?"All installed plugins selected":"No plugins installed"}):T.map((e,s)=>(0,t.jsxs)("button",{id:`stgm-plugin-${s}`,type:"button","data-idx":s,onClick:()=>R(e),disabled:x,className:(0,i.f)("stg:group stg:flex stg:w-full stg:flex-col stg:gap-0.5 stg:rounded-md stg:px-2 stg:py-1.5 stg:text-left stg:text-xs stg:transition-colors","stg:disabled:pointer-events-none stg:disabled:opacity-50",s===N?"stg:bg-accent stg:text-foreground":"stg:text-foreground stg:hover:bg-accent-hover"),role:"option","aria-selected":s===N,children:[(0,t.jsxs)("span",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)(p,{}),(0,t.jsx)("span",{className:"stg:truncate stg:font-medium",children:(0,t.jsx)(g,{text:e.name,query:w})}),(0,t.jsx)("span",{className:"stg:ml-auto stg:shrink-0 stg:text-2xs stg:text-muted-foreground",children:(0,t.jsx)(l.f,{orgId:e.org})})]}),e.description&&(0,t.jsx)("span",{className:(0,i.f)("stg:pl-5 stg:text-2xs stg:text-muted-foreground",s!==N&&"stg:line-clamp-2 stg:group-hover:line-clamp-none"),children:e.description})]},e.id))}),A.canScrollDown&&(0,t.jsx)(o.f,{position:"bottom"})]})]})}],513642);let f="stgm-skill-list";function v({text:e,query:s}){if(!s)return(0,t.jsx)(t.Fragment,{children:e});let n=e.toLowerCase().indexOf(s.toLowerCase());return -1===n?(0,t.jsx)(t.Fragment,{children:e}):(0,t.jsxs)(t.Fragment,{children:[e.slice(0,n),(0,t.jsx)("span",{className:"stg:font-semibold",children:e.slice(n,n+s.length)}),e.slice(n+s.length)]})}function x(){return(0,t.jsx)("div",{className:"stg:space-y-1 stg:py-1",children:[55,70,45,62].map((e,s)=>(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1 stg:px-2 stg:py-1.5",children:[(0,t.jsx)("div",{className:"stg:h-3 stg:rounded stg:bg-muted stg:animate-pulse",style:{width:`${e}%`}}),(0,t.jsx)("div",{className:"stg:h-2 stg:rounded stg:bg-muted-subtle stg:animate-pulse",style:{width:`${Math.min(e+15,90)}%`}})]},s))})}function b(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:"stg:shrink-0 stg:text-muted-foreground","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M2 3h12M2 7h8M2 11h10M2 15h6"})})}function k(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 14 14",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M4 4L10 10M10 4L4 10"})})}e.s(["f",0,function({org:e,value:u,onChange:c,onDisplayNameResolved:g,disabled:h,className:p}){let{results:m,isLoading:y,error:j,query:w,setQuery:I}=(0,r.f)(n.X.skill,e,void 0),[N,S]=(0,s.useState)(-1),M=(0,s.useRef)(null),A=(0,a.f)(),C=(0,a.f)(),$=(0,d.w)(),O=(0,s.useMemo)(()=>new Set(u.map(e=>`${$(e.org)}/${e.slug}`)),[u,$]),T=(0,s.useMemo)(()=>m.filter(e=>!O.has(`${$(e.org)}/${e.slug}`)),[m,O,$]);(0,s.useEffect)(()=>{S(-1)},[w]),(0,s.useEffect)(()=>{N>=0&&A.scrollRef.current?.querySelector(`[data-idx="${N}"]`)?.scrollIntoView({block:"nearest"})},[N,A.scrollRef]);let R=(0,s.useCallback)(e=>{c([...u,{org:e.org,slug:e.slug,kind:n.X.skill}]),g?.(`${e.org}/${e.slug}`,e.name)},[u,c,g]),B=(0,d.$)(),L=(0,s.useCallback)(e=>{c(u.filter(t=>!B(t,e)))},[u,c,B]),D=(0,s.useCallback)(e=>{"ArrowDown"===e.key?(e.preventDefault(),S(e=>e<T.length-1?e+1:e)):"ArrowUp"===e.key?(e.preventDefault(),S(e=>e>0?e-1:-1)):"Enter"===e.key&&N>=0&&N<T.length?(e.preventDefault(),R(T[N])):"Enter"===e.key&&e.preventDefault()},[T,N,R]);return(0,t.jsxs)("div",{className:["stg:space-y-2 stg:w-72",p].filter(Boolean).join(" "),children:[u.length>0&&(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("div",{className:"stg:text-2xs stg:font-medium stg:text-muted-foreground",children:"Selected"}),(0,t.jsxs)("div",{className:"stg:relative",children:[C.canScrollUp&&(0,t.jsx)(o.f,{position:"top"}),(0,t.jsx)("div",{ref:C.scrollRef,className:"stg:max-h-28 stg:space-y-1 stg:overflow-y-auto",children:u.map((e,s)=>{let n=e.slug||"deleted skill";return(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:rounded-md stg:bg-muted-faint stg:px-2 stg:py-1 stg:text-xs",children:[(0,t.jsx)(b,{}),(0,t.jsx)("span",{className:"stg:min-w-0 stg:flex-1 stg:truncate stg:text-foreground",children:n}),(0,t.jsx)("button",{type:"button",onClick:()=>L(e),disabled:h,className:"stg:shrink-0 stg:text-muted-foreground stg:hover:text-destructive stg:disabled:pointer-events-none","aria-label":`Remove ${n}`,children:(0,t.jsx)(k,{})})]},`${s}:${e.id||`${e.org}/${e.slug}`}`)})}),C.canScrollDown&&(0,t.jsx)(o.f,{position:"bottom"})]})]}),(0,t.jsx)("input",{ref:M,type:"text",role:"combobox","aria-expanded":!0,"aria-controls":f,"aria-activedescendant":N>=0?`stgm-skill-${N}`:void 0,placeholder:"Search skills...",value:w,onChange:e=>I(e.target.value),onKeyDown:D,disabled:h,className:"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",autoFocus:!0}),j&&(0,t.jsx)("p",{className:"stg:text-xs stg:text-destructive",children:j.message}),(0,t.jsxs)("div",{className:"stg:relative",children:[A.canScrollUp&&(0,t.jsx)(o.f,{position:"top"}),(0,t.jsx)("div",{ref:A.scrollRef,id:f,role:"listbox","aria-label":"Skills",className:"stg:max-h-52 stg:overflow-y-auto",children:y?(0,t.jsx)(x,{}):0===T.length?(0,t.jsx)("div",{className:"stg:py-4 stg:text-center stg:text-xs stg:text-muted-foreground",children:w?"No skills match your search":u.length>0?"All available skills selected":"No skills found"}):T.map((e,s)=>(0,t.jsxs)("button",{id:`stgm-skill-${s}`,type:"button","data-idx":s,onClick:()=>R(e),disabled:h,className:(0,i.f)("stg:group stg:flex stg:w-full stg:flex-col stg:gap-0.5 stg:rounded-md stg:px-2 stg:py-1.5 stg:text-left stg:text-xs stg:transition-colors","stg:disabled:pointer-events-none stg:disabled:opacity-50",s===N?"stg:bg-accent stg:text-foreground":"stg:text-foreground stg:hover:bg-accent-hover"),role:"option","aria-selected":s===N,children:[(0,t.jsxs)("span",{className:"stg:flex stg:items-center stg:gap-1.5",children:[(0,t.jsx)(b,{}),(0,t.jsx)("span",{className:"stg:truncate stg:font-medium",children:(0,t.jsx)(v,{text:e.name,query:w})}),(0,t.jsx)("span",{className:"stg:ml-auto stg:shrink-0 stg:text-2xs stg:text-muted-foreground",children:(0,t.jsx)(l.f,{orgId:e.org})})]}),e.description&&(0,t.jsx)("span",{className:(0,i.f)("stg:pl-5 stg:text-2xs stg:text-muted-foreground",s!==N&&"stg:line-clamp-2 stg:group-hover:line-clamp-none"),children:e.description})]},e.id))}),A.canScrollDown&&(0,t.jsx)(o.f,{position:"bottom"})]})]})}],841358)},855158,e=>{"use strict";var t=e.i(910304),s=e.i(255817),n=e.i(616701);e.s(["f",0,function(e,i){let r=(0,s.f)(),{data:a,isLoading:o,isRefetching:l,error:d,refetch:u}=(0,n.f)(e&&i?async()=>{try{return await r.plugin.getByReference({org:e,slug:i})}catch(e){if((0,t.c)(e))return null;throw e}}:null,[e,i,r],null);return{plugin:a,isLoading:o,isRefetching:l,error:d,refetch:u}}])},332250,e=>{"use strict";e.s(["f",0,function(e){let t=Math.max(0,Math.floor(e/1e3));if(t<60)return`${t} s`;let s=Math.floor(t/60);if(s<60)return t%60==0?`${s} min`:`${s} min ${t%60} s`;let n=s%60;return 0===n?`${Math.floor(s/60)} h`:`${Math.floor(s/60)} h ${n} min`}])},934197,e=>{"use strict";var t=e.i(974265),s=e.i(893976);e.s(["f",0,function({checked:e,onCheckedChange:n,disabled:i,"aria-label":r,"aria-labelledby":a,"aria-describedby":o,id:l,className:d}){return(0,t.jsx)("button",{type:"button",role:"switch",id:l,"aria-checked":e,"aria-label":r,"aria-labelledby":a,"aria-describedby":o,disabled:i,onClick:()=>n(!e),className:(0,s.f)("stg:relative stg:inline-flex stg:h-5 stg:w-9 stg:shrink-0 stg:items-center stg:rounded-full stg:transition-colors","stg:motion-reduce:transition-none",e?"stg:bg-primary":"stg:bg-input","stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-offset-2","stg:disabled:pointer-events-none stg:disabled:opacity-50","stg:after:absolute stg:after:-inset-3 stg:after:content-['']",d),children:(0,t.jsx)("span",{"aria-hidden":"true",className:(0,s.f)("stg:pointer-events-none stg:block stg:size-4 stg:rounded-full stg:bg-background stg:shadow-sm stg:transition-transform","stg:motion-reduce:transition-none",e?"stg:translate-x-[18px]":"stg:translate-x-0.5")})})}])},937719,e=>{"use strict";var t=e.i(974265),s=e.i(651023),n=e.i(893976),i=e.i(869803),r=e.i(302367);let a="My vault";function o(e){return(0,r.V)(e)?a:e.metadata?.name??e.metadata?.slug??""}function l({myVault:e,disabled:i}){let r=(0,s.useId)();return(0,t.jsxs)("div",{className:(0,n.f)("stg:flex stg:items-start stg:gap-2 stg:rounded-md stg:border stg:border-border stg:px-3 stg:py-2","stg:bg-muted"),children:[(0,t.jsx)("input",{id:r,type:"checkbox",checked:e.checked,disabled:i,onChange:t=>e.onChange(t.target.checked),className:"stg:mt-0.5 stg:shrink-0 stg:disabled:cursor-not-allowed"}),(0,t.jsxs)("label",{htmlFor:r,className:"stg:flex-1 stg:min-w-0 stg:cursor-pointer stg:select-none",children:[(0,t.jsx)("span",{className:"stg:block stg:text-sm stg:font-medium stg:text-foreground",children:a}),(0,t.jsx)("span",{className:"stg:block stg:text-2xs stg:text-muted-foreground",children:"Read first. Each person who sends a message uses their own."})]})]})}function d({value:e,disabled:s,resolveName:r,resolveDescription:a,onRemove:o,onMoveUp:l,onMoveDown:c,total:g}){return(0,t.jsx)("ol",{className:(0,n.f)(i.J,"stg:space-y-1.5"),"aria-label":"Selected vaults (in order)",children:e.map((e,i)=>(0,t.jsxs)("li",{className:(0,n.f)("stg:flex stg:items-center stg:gap-2 stg:rounded-md stg:border stg:border-border stg:px-3 stg:py-2","stg:bg-muted/30"),children:[(0,t.jsxs)("span",{className:"stg:shrink-0 stg:w-5 stg:text-xs stg:font-medium stg:text-muted-foreground stg:text-right",children:[i+1,"."]}),(0,t.jsxs)("div",{className:"stg:flex-1 stg:min-w-0",children:[(0,t.jsx)("span",{className:"stg:text-sm stg:font-medium stg:text-foreground stg:truncate stg:block",children:r(e)}),a(e)&&(0,t.jsx)("span",{className:"stg:text-2xs stg:text-muted-foreground stg:truncate stg:block",children:a(e)})]}),!s&&(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-0.5 stg:shrink-0",children:[(0,t.jsx)(u,{direction:"up",disabled:0===i,onClick:()=>l(i),label:`Move ${r(e)} up`}),(0,t.jsx)(u,{direction:"down",disabled:i===g-1,onClick:()=>c(i),label:`Move ${r(e)} down`}),(0,t.jsx)("button",{type:"button",onClick:()=>o(i),"aria-label":`Remove ${r(e)}`,className:(0,n.f)("stg:rounded stg:p-1 stg:text-muted-foreground","stg:hover:text-destructive stg:hover:bg-destructive/10","stg:focus:outline-none stg:focus:ring-1 stg:focus:ring-ring"),children:(0,t.jsx)(h,{})})]})]},`${e.org}-${e.slug}-${i}`))})}function u({direction:e,disabled:s,onClick:i,label:r}){return(0,t.jsx)("button",{type:"button",disabled:s,onClick:i,"aria-label":r,className:(0,n.f)("stg:rounded stg:p-1 stg:text-muted-foreground","stg:hover:text-foreground stg:hover:bg-accent-hover","stg:focus:outline-none stg:focus:ring-1 stg:focus:ring-ring","stg:disabled:opacity-30 stg:disabled:cursor-not-allowed stg:disabled:hover:bg-transparent"),children:"up"===e?(0,t.jsx)(c,{}):(0,t.jsx)(g,{})})}function c(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M6 2.5v7M6 2.5L3 5.5M6 2.5l3 3",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}function g(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M6 9.5v-7M6 9.5L3 6.5M6 9.5l3-3",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}function h(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:(0,t.jsx)("path",{d:"M3 3l6 6M9 3l-6 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}e.s(["f",0,function({org:e,value:i,onChange:a,disabled:u=!1,allowMyVault:c=!1,myVault:g,filterVault:h,selectionNote:p,className:m}){let{vaults:f,isLoading:v}=(0,r.k)(e),x=(0,s.useId)(),b=(0,s.useMemo)(()=>f.filter(e=>(0,r.V)(e)?c:h?.(e)??!0),[f,c,h]),k=(0,s.useMemo)(()=>new Set(i.map(e=>e.slug)),[i]),y=(0,s.useMemo)(()=>b.filter(e=>!k.has(e.metadata?.slug??"")),[b,k]),j=(0,s.useCallback)(t=>{a([...i,{org:e,slug:t}])},[a,e,i]),w=(0,s.useCallback)(e=>{let t=[...i];t.splice(e,1),a(t)},[a,i]),I=(0,s.useCallback)(e=>{if(0===e)return;let t=[...i];[t[e-1],t[e]]=[t[e],t[e-1]],a(t)},[a,i]),N=(0,s.useCallback)(e=>{if(e>=i.length-1)return;let t=[...i];[t[e],t[e+1]]=[t[e+1],t[e]],a(t)},[a,i]),S=(0,s.useCallback)(e=>{let t=f.find(t=>t.metadata?.slug===e.slug);return t?o(t):e.slug},[f]),M=(0,s.useCallback)(e=>{let t=f.find(t=>t.metadata?.slug===e.slug);return t?.spec?.description??""},[f]);return(0,t.jsxs)("div",{className:(0,n.f)("stg:space-y-3",m),role:"group","aria-label":"Vaults",children:[g&&(0,t.jsx)(l,{myVault:g,disabled:u}),i.length>0&&(0,t.jsx)(d,{value:i,disabled:u,resolveName:S,resolveDescription:M,onRemove:w,onMoveUp:I,onMoveDown:N,total:i.length}),i.length+ +!!g?.checked>1&&(0,t.jsx)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:"Vaults are read in order: the first one holding a key or a login wins."}),i.length>0&&p&&(0,t.jsx)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:p}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{htmlFor:x,className:"stg:sr-only",children:"Add vault"}),(0,t.jsxs)("select",{id:x,disabled:u||0===y.length,value:"",onChange:e=>{e.target.value&&j(e.target.value)},className:(0,n.f)("stg:w-full stg:rounded-md stg:border stg:border-border stg:bg-background stg:px-3 stg:py-1.5 stg:text-sm","stg:text-foreground stg:placeholder:text-muted-foreground","stg:focus:outline-none stg:focus:ring-2 stg:focus:ring-ring","stg:disabled:cursor-not-allowed stg:disabled:opacity-50"),children:[(0,t.jsx)("option",{value:"",children:v?"Loading vaults...":0===y.length?i.length>0&&b.length>0?"All vaults selected":"No vaults available":"+ Add vault"}),y.map(e=>(0,t.jsx)("option",{value:e.metadata?.slug,children:o(e)},e.metadata?.slug))]})]})]})}])},302367,e=>{"use strict";var t=e.i(891287),s=e.i(4212),n=e.i(255817),i=e.i(766330),r=e.i(205413),a=e.i(616701);e.s(["V",0,function(e){return e.spec?.owner.case==="person"},"k",0,function(e){let o=(0,n.f)(),l=e?()=>(0,r.T)(n=>o.vault.list((0,t.f)(s.W,{org:e,pageSize:i.J,pageToken:n}))):null,{data:d,isLoading:u,isRefetching:c,error:g,refetch:h}=(0,a.f)(l,[e,o],[]);return{vaults:d,isLoading:u,isRefetching:c,error:g,refetch:h}}])},781126,e=>{"use strict";function t(e){return e.spec?.buildFromPlan===!0}e.s(["b",0,t,"K",0,function(e){let t=e.split("/");return t.length>=3&&"artifacts"===t[0]&&t[1]?t[1]:null},"S",0,function(e){return[...e].sort((e,t)=>{let s=e.metadata?.id??"",n=t.metadata?.id??"";return s===n?0:s?n?s<n?-1:1:-1:1})},"s",0,function(e,t){let s=new Set;for(let t of e){let e=t.spec?.supersedesRunId;e&&s.add(e)}return t&&s.add(t),s},"L",0,function(e){let s=e.spec?.message;return!s||"execute"===s||t(e)?null:s}])}]);
@@ -0,0 +1,24 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,324590,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"ArchitectureTokenBuilder")}constructor(){super(["architecture"])}},a=class extends t.n{static{(0,t.p)(this,"ArchitectureValueConverter")}runCustomConverter(e,t,r){if("ARCH_ICON"===e.name)return t.replace(/[()]/g,"").trim();if("ARCH_TEXT_ICON"===e.name)return t.replace(/["()]/g,"");if("ARCH_TITLE"===e.name){let e=t.replace(/^\[|]$/g,"").trim();return(e.startsWith('"')&&e.endsWith('"')||e.startsWith("'")&&e.endsWith("'"))&&(e=(e=e.slice(1,-1)).replace(/\\"/g,'"').replace(/\\'/g,"'")),e.trim()}}},i={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new a,"ValueConverter")}};function n(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),a=(0,t.h)((0,t.I)({shared:r}),t.F,i);return r.ServiceRegistry.register(a),{shared:r,Architecture:a}}(0,t.p)(n,"createArchitectureServices"),e.s(["L",0,i,"w",0,n])},762592,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"InfoTokenBuilder")}constructor(){super(["info","showInfo"])}},a={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new t.b,"ValueConverter")}};function i(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),n=(0,t.h)((0,t.I)({shared:r}),t.$,a);return r.ServiceRegistry.register(n),{shared:r,Info:n}}(0,t.p)(i,"createInfoServices"),e.s(["w",0,a,"n",0,i])},660245,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"TreemapTokenBuilder")}constructor(){super(["treemap"])}},a=/classDef\s+([A-Z_a-z]\w+)(?:\s+([^\n\r;]*))?;?/,i=class extends t.n{static{(0,t.p)(this,"TreemapValueConverter")}runCustomConverter(e,t,r){if("NUMBER2"===e.name)return parseFloat(t.replace(/,/g,""));if("SEPARATOR"===e.name)return t.substring(1,t.length-1);if("STRING2"===e.name)return t.substring(1,t.length-1);if("INDENTATION"===e.name)return t.length;if("ClassDef"===e.name){if("string"!=typeof t)return t;let e=a.exec(t);if(e)return{$type:"ClassDefStatement",className:e[1],styleText:e[2]||void 0}}}};function n(e){let t=e.validation.TreemapValidator,r=e.validation.ValidationRegistry;if(r){let e={Treemap:t.checkSingleRoot.bind(t)};r.register(e,t)}}(0,t.p)(n,"registerValidationChecks");var s=class{static{(0,t.p)(this,"TreemapValidator")}checkSingleRoot(e,t){let r;for(let a of e.TreemapRows)a.item&&(void 0===r&&void 0===a.indent?r=0:void 0===a.indent?t("error","Multiple root nodes are not allowed in a treemap.",{node:a,property:"item"}):void 0!==r&&r>=parseInt(a.indent,10)&&t("error","Multiple root nodes are not allowed in a treemap.",{node:a,property:"item"}))}},l={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new i,"ValueConverter")},validation:{TreemapValidator:(0,t.p)(()=>new s,"TreemapValidator")}};function o(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),a=(0,t.h)((0,t.I)({shared:r}),t.r,l);return r.ServiceRegistry.register(a),n(a),{shared:r,Treemap:a}}(0,t.p)(o,"createTreemapServices"),e.s(["j",0,l,"G",0,o])},133473,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"RadarTokenBuilder")}constructor(){super(["radar-beta"])}},a={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new t.b,"ValueConverter")}};function i(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),n=(0,t.h)((0,t.I)({shared:r}),t.i,a);return r.ServiceRegistry.register(n),{shared:r,Radar:n}}(0,t.p)(i,"createRadarServices"),e.s(["n",0,a,"P",0,i])},287470,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"PacketTokenBuilder")}constructor(){super(["packet"])}},a={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new t.b,"ValueConverter")}};function i(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),n=(0,t.h)((0,t.I)({shared:r}),t.d,a);return r.ServiceRegistry.register(n),{shared:r,Packet:n}}(0,t.p)(i,"createPacketServices"),e.s(["n",0,a,"q",0,i])},716327,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"PieTokenBuilder")}constructor(){super(["pie","showData"])}},a=class extends t.n{static{(0,t.p)(this,"PieValueConverter")}runCustomConverter(e,t,r){if("PIE_SECTION_LABEL"===e.name)return t.replace(/"/g,"").trim()}},i={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new a,"ValueConverter")}};function n(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),a=(0,t.h)((0,t.I)({shared:r}),t.Q,i);return r.ServiceRegistry.register(a),{shared:r,Pie:a}}(0,t.p)(n,"createPieServices"),e.s(["y",0,i,"Q",0,n])},905834,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"EventModelingTokenBuilder")}constructor(){super(["eventmodeling"])}},a=new Set(["cmd","command"]),i=new Set(["evt","event"]),n=new Set(["rmo","readmodel"]),s=new Set(["pcr","processor"]),l=new Set(["ui"]);function o(e){let t=e.validation.EventModelingValidator,r=e.validation.ValidationRegistry;if(r){let e={EmTimeFrame:t.checkSourceFrameTypes.bind(t),EmResetFrame:t.checkSourceFrameTypes.bind(t)};r.register(e,t)}}(0,t.p)(o,"registerValidationChecks");var c=class{static{(0,t.p)(this,"EventModelingValidator")}checkSourceFrameTypes(e,t){0!==e.sourceFrames.length&&(a.has(e.modelEntityType)?this.validateSources(e,new Set([...l,...s]),"command","ui or processor",t):i.has(e.modelEntityType)?this.validateSources(e,a,"event","command",t):n.has(e.modelEntityType)?this.validateSources(e,i,"read model","event",t):s.has(e.modelEntityType)?this.validateSources(e,n,"processor","read model",t):l.has(e.modelEntityType)&&this.validateSources(e,n,"ui","read model",t))}validateSources(e,t,r,a,i){for(let n of e.sourceFrames){let s=n.ref;void 0===s||t.has(s.modelEntityType)||i("error",`A ${r} can only receive input from a ${a}, not from '${s.modelEntityType}'.`,{node:e,property:"sourceFrames"})}}},u={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new t.b,"ValueConverter")},validation:{EventModelingValidator:(0,t.p)(()=>new c,"EventModelingValidator")}};function d(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),a=(0,t.h)((0,t.I)({shared:r}),t.s,u);return r.ServiceRegistry.register(a),o(a),{shared:r,EventModel:a}}(0,t.p)(d,"createEventModelingServices"),e.s(["w",0,u,"n",0,d])},725188,e=>{"use strict";var t=e.i(539927),r=class extends t.n{static{(0,t.p)(this,"WardleyValueConverter")}runCustomConverter(e,t,r){return"LINK_LABEL"===e.name.toUpperCase()?t.substring(1).trim():void 0}},a={parser:{ValueConverter:(0,t.p)(()=>new r,"ValueConverter")}};function i(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),n=(0,t.h)((0,t.I)({shared:r}),t.M,a);return r.ServiceRegistry.register(n),{shared:r,Wardley:n}}(0,t.p)(i,"createWardleyServices"),e.s(["u",0,a,"A",0,i])},283214,e=>{"use strict";var t=e.i(539927),r=class extends t.y{static{(0,t.p)(this,"GitGraphTokenBuilder")}constructor(){super(["gitGraph"])}},a={parser:{TokenBuilder:(0,t.p)(()=>new r,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new t.b,"ValueConverter")}};function i(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),n=(0,t.h)((0,t.I)({shared:r}),t.e,a);return r.ServiceRegistry.register(n),{shared:r,GitGraph:n}}(0,t.p)(i,"createGitGraphServices"),e.s(["O",0,a,"E",0,i])},127129,e=>{"use strict";var t=e.i(539927),r=class extends t.n{static{(0,t.p)(this,"TreeViewValueConverter")}runCustomConverter(e,t,r){return"INDENTATION"===e.name?t?.length||0:"STRING2"===e.name?t.substring(1,t.length-1):void 0}},a=class extends t.y{static{(0,t.p)(this,"TreeViewTokenBuilder")}constructor(){super(["treeView-beta"])}},i={parser:{TokenBuilder:(0,t.p)(()=>new a,"TokenBuilder"),ValueConverter:(0,t.p)(()=>new r,"ValueConverter")}};function n(e=t._){let r=(0,t.h)((0,t.w)(e),t.a),a=(0,t.h)((0,t.I)({shared:r}),t.j,i);return r.ServiceRegistry.register(a),{shared:r,TreeView:a}}(0,t.p)(n,"createTreeViewServices"),e.s(["U",0,i,"M",0,n])},289590,e=>{"use strict";e.i(133473),e.i(660245),e.i(725188),e.i(283214),e.i(762592),e.i(287470),e.i(716327),e.i(127129),e.i(324590),e.i(905834);var t=e.i(539927),r={},a={info:(0,t.p)(async()=>{let{createInfoServices:t}=await e.A(799352);r.info=t().Info.parser.LangiumParser},"info"),packet:(0,t.p)(async()=>{let{createPacketServices:t}=await e.A(428477);r.packet=t().Packet.parser.LangiumParser},"packet"),pie:(0,t.p)(async()=>{let{createPieServices:t}=await e.A(938722);r.pie=t().Pie.parser.LangiumParser},"pie"),treeView:(0,t.p)(async()=>{let{createTreeViewServices:t}=await e.A(94862);r.treeView=t().TreeView.parser.LangiumParser},"treeView"),architecture:(0,t.p)(async()=>{let{createArchitectureServices:t}=await e.A(220490);r.architecture=t().Architecture.parser.LangiumParser},"architecture"),gitGraph:(0,t.p)(async()=>{let{createGitGraphServices:t}=await e.A(691759);r.gitGraph=t().GitGraph.parser.LangiumParser},"gitGraph"),eventmodeling:(0,t.p)(async()=>{let{createEventModelingServices:t}=await e.A(114878);r.eventmodeling=t().EventModel.parser.LangiumParser},"eventmodeling"),radar:(0,t.p)(async()=>{let{createRadarServices:t}=await e.A(381916);r.radar=t().Radar.parser.LangiumParser},"radar"),treemap:(0,t.p)(async()=>{let{createTreemapServices:t}=await e.A(558201);r.treemap=t().Treemap.parser.LangiumParser},"treemap"),wardley:(0,t.p)(async()=>{let{createWardleyServices:t}=await e.A(122457);r.wardley=t().Wardley.parser.LangiumParser},"wardley")};async function i(e,t){let i=a[e];if(!i)throw Error(`Unknown diagram type: ${e}`);r[e]||await i();let s=r[e].parse(t);if(s.lexerErrors.length>0||s.parserErrors.length>0)throw new n(s);return s.value}(0,t.p)(i,"parse");var n=class extends Error{constructor(e){let t=e.lexerErrors.map(e=>{let t=void 0===e.line||isNaN(e.line)?"?":e.line,r=void 0===e.column||isNaN(e.column)?"?":e.column;return`Lexer error on line ${t}, column ${r}: ${e.message}`}).join("\n"),r=e.parserErrors.map(e=>{let t=void 0===e.token.startLine||isNaN(e.token.startLine)?"?":e.token.startLine,r=void 0===e.token.startColumn||isNaN(e.token.startColumn)?"?":e.token.startColumn;return`Parse error on line ${t}, column ${r}: ${e.message}`}).join("\n");super(`Parsing failed: ${t} ${r}`),this.result=e}static{(0,t.p)(this,"MermaidParseError")}};e.s(["f",0,i])},64912,948293,684511,e=>{"use strict";function t(e,t){if(!isFinite(e)||0===e)return null;var r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),a=e.slice(0,r);return[a.length>1?a[0]+a.slice(2):a,+e.slice(r+1)]}function r(e){return(e=t(Math.abs(e)))?e[1]:0/0}e.s(["f",0,r],948293);var a,i,n,s,l=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function o(e){var t;if(!(t=l.exec(e)))throw Error("invalid format: "+e);return new c({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function c(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function u(e,r){var a=t(e,r);if(!a)return e+"";var i=a[0],n=a[1];return n<0?"0."+Array(-n).join("0")+i:i.length>n+1?i.slice(0,n+1)+"."+i.slice(n+1):i+Array(n-i.length+2).join("0")}o.prototype=c.prototype,c.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type},e.s(["f",0,o],684511);let d={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>u(100*e,t),r:u,s:function(e,r){var i=t(e,r);if(!i)return a=void 0,e.toPrecision(r);var n=i[0],s=i[1],l=s-(a=3*Math.max(-8,Math.min(8,Math.floor(s/3))))+1,o=n.length;return l===o?n:l>o?n+Array(l-o+1).join("0"):l>0?n.slice(0,l)+"."+n.slice(l):"0."+Array(1-l).join("0")+t(e,Math.max(0,r+l-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function p(e){return e}var h=Array.prototype.map,f=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];n=(i=function(e){var t,i,n,s=void 0===e.grouping||void 0===e.thousands?p:(t=h.call(e.grouping,Number),i=e.thousands+"",function(e,r){for(var a=e.length,n=[],s=0,l=t[0],o=0;a>0&&l>0&&(o+l+1>r&&(l=Math.max(1,r-o)),n.push(e.substring(a-=l,a+l)),!((o+=l+1)>r));)l=t[s=(s+1)%t.length];return n.reverse().join(i)}),l=void 0===e.currency?"":e.currency[0]+"",c=void 0===e.currency?"":e.currency[1]+"",u=void 0===e.decimal?".":e.decimal+"",m=void 0===e.numerals?p:(n=h.call(e.numerals,String),function(e){return e.replace(/[0-9]/g,function(e){return n[+e]})}),g=void 0===e.percent?"%":e.percent+"",v=void 0===e.minus?"−":e.minus+"",y=void 0===e.nan?"NaN":e.nan+"";function S(e,t){var r=(e=o(e)).fill,i=e.align,n=e.sign,p=e.symbol,h=e.zero,S=e.width,x=e.comma,w=e.precision,C=e.trim,T=e.type;"n"===T?(x=!0,T="g"):d[T]||(void 0===w&&(w=12),C=!0,T="g"),(h||"0"===r&&"="===i)&&(h=!0,r="0",i="=");var b=(t&&void 0!==t.prefix?t.prefix:"")+("$"===p?l:"#"===p&&/[boxX]/.test(T)?"0"+T.toLowerCase():""),k=("$"===p?c:/[%p]/.test(T)?g:"")+(t&&void 0!==t.suffix?t.suffix:""),M=d[T],$=/[defgprs%]/.test(T);function V(e){var t,l,o,c=b,d=k;if("c"===T)d=M(e)+d,e="";else{var p=(e*=1)<0||1/e<0;if(e=isNaN(e)?y:M(Math.abs(e),w),C&&(e=function(e){e:for(var t,r=e.length,a=1,i=-1;a<r;++a)switch(e[a]){case".":i=t=a;break;case"0":0===i&&(i=a),t=a;break;default:if(!+e[a])break e;i>0&&(i=0)}return i>0?e.slice(0,i)+e.slice(t+1):e}(e)),p&&0==+e&&"+"!==n&&(p=!1),c=(p?"("===n?n:v:"-"===n||"("===n?"":n)+c,d=("s"!==T||isNaN(e)||void 0===a?"":f[8+a/3])+d+(p&&"("===n?")":""),$){for(t=-1,l=e.length;++t<l;)if(48>(o=e.charCodeAt(t))||o>57){d=(46===o?u+e.slice(t+1):e.slice(t))+d,e=e.slice(0,t);break}}}x&&!h&&(e=s(e,1/0));var g=c.length+e.length+d.length,V=g<S?Array(S-g+1).join(r):"";switch(x&&h&&(e=s(V+e,V.length?S-d.length:1/0),V=""),i){case"<":e=c+e+d+V;break;case"=":e=c+V+e+d;break;case"^":e=V.slice(0,g=V.length>>1)+c+e+d+V.slice(g);break;default:e=V+c+e+d}return m(e)}return w=void 0===w?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w)),V.toString=function(){return e+""},V}return{format:S,formatPrefix:function(e,t){var a=3*Math.max(-8,Math.min(8,Math.floor(r(t)/3))),i=Math.pow(10,-a),n=S(((e=o(e)).type="f",e),{suffix:f[8+a/3]});return function(e){return n(i*e)}}}}({thousands:",",grouping:[3],currency:["$",""]})).format,s=i.formatPrefix,e.s(["R",()=>n,"Z",()=>s],64912)},365332,e=>{"use strict";e.s(["f",0,function(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}])},65232,e=>{"use strict";class t extends Map{constructor(e,t=a){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),null!=e)for(let[t,r]of e)this.set(t,r)}get(e){return super.get(r(this,e))}has(e){return super.has(r(this,e))}set(e,t){return super.set(function({_intern:e,_key:t},r){let a=t(r);return e.has(a)?e.get(a):(e.set(a,r),r)}(this,e),t)}delete(e){return super.delete(function({_intern:e,_key:t},r){let a=t(r);return e.has(a)&&(r=e.get(a),e.delete(a)),r}(this,e))}}function r({_intern:e,_key:t},a){let i=t(a);return e.has(i)?e.get(i):a}function a(e){return null!==e&&"object"==typeof e?e.valueOf():e}var i=e.i(365332);let n=Symbol("implicit");e.s(["f",0,function e(){var r=new t,a=[],s=[],l=n;function o(e){let t=r.get(e);if(void 0===t){if(l!==n)return l;r.set(e,t=a.push(e)-1)}return s[t%s.length]}return o.domain=function(e){if(!arguments.length)return a.slice();for(let i of(a=[],r=new t,e))r.has(i)||r.set(i,a.push(i)-1);return o},o.range=function(e){return arguments.length?(s=Array.from(e),o):s.slice()},o.unknown=function(e){return arguments.length?(l=e,o):l},o.copy=function(){return e(a,s).unknown(l)},i.f.apply(o,arguments),o}],65232)},401475,e=>{"use strict";var t=e.i(65232);e.s(["f",()=>t.f])},443578,e=>{"use strict";var t=e.i(908381),r=e.i(171206),a=(0,r.p)((e,a,s,l)=>{e.attr("class",s);let{width:o,height:c,x:u,y:d}=i(e,a);(0,t.m)(e,c,o,l);let p=n(u,d,o,c,a);e.attr("viewBox",p),r.d.debug(`viewBox configured: ${p} with padding: ${a}`)},"setupViewPortForSVG"),i=(0,r.p)((e,t)=>{let r=e.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:r.width+2*t,height:r.height+2*t,x:r.x,y:r.y}},"calculateDimensionsWithPadding"),n=(0,r.p)((e,t,r,a,i)=>`${e-i} ${t-i} ${r} ${a}`,"createViewBox");e.s(["f",0,a])},602099,e=>{"use strict";function t(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}(0,e.i(171206).p)(t,"populateCommonDb"),e.s(["f",0,t])},389920,e=>{"use strict";var t=e.i(332090),r=e.i(443578),a=e.i(620144),i=e.i(602099),n=e.i(669587),s=e.i(908381),l=e.i(171206),o=e.i(289590);e.i(947716);var c=e.i(401475);function u(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}let d=function e(t){function r(e,r,a,i,n){!function(e,t,r,a,i,n){for(var s,l,o,c,u,d,p,h,f,m,g,v=[],y=t.children,S=0,x=0,w=y.length,C=t.value;S<w;){o=i-r,c=n-a;do u=y[x++].value;while(!u&&x<w)for(d=p=u,f=Math.max(p/(g=u*u*(m=Math.max(c/o,o/c)/(C*e))),g/d);x<w;++x){if(u+=l=y[x].value,l<d&&(d=l),l>p&&(p=l),(h=Math.max(p/(g=u*u*m),g/d))>f){u-=l;break}f=h}v.push(s={value:u,dice:o<c,children:y.slice(S,x)}),s.dice?function(e,t,r,a,i){for(var n,s=e.children,l=-1,o=s.length,c=e.value&&(a-t)/e.value;++l<o;)(n=s[l]).y0=r,n.y1=i,n.x0=t,n.x1=t+=n.value*c}(s,r,a,i,C?a+=c*u/C:n):function(e,t,r,a,i){for(var n,s=e.children,l=-1,o=s.length,c=e.value&&(i-r)/e.value;++l<o;)(n=s[l]).x0=t,n.x1=a,n.y0=r,n.y1=r+=n.value*c}(s,r,a,C?r+=o*u/C:i,n),C-=u,S=x}}(t,e,r,a,i,n)}return r.ratio=function(t){return e((t*=1)>1?t:1)},r}((1+Math.sqrt(5))/2);function p(){return 0}function h(e){return function(){return e}}function f(e){var t=0,r=e.children,a=r&&r.length;if(a)for(;--a>=0;)t+=r[a].value;else t=1;e.value=t}function m(e,t){e instanceof Map?(e=[void 0,e],void 0===t&&(t=v)):void 0===t&&(t=g);for(var r,a,i,n,s,l=new x(e),o=[l];r=o.pop();)if((i=t(r.data))&&(s=(i=Array.from(i)).length))for(r.children=i,n=s-1;n>=0;--n)o.push(a=i[n]=new x(i[n])),a.parent=r,a.depth=r.depth+1;return l.eachBefore(S)}function g(e){return e.children}function v(e){return Array.isArray(e)?e[1]:null}function y(e){void 0!==e.data.value&&(e.value=e.data.value),e.data=e.data.data}function S(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function x(e){this.data=e,this.depth=this.height=0,this.parent=null}x.prototype=m.prototype={constructor:x,count:function(){return this.eachAfter(f)},each:function(e,t){let r=-1;for(let a of this)e.call(t,a,++r,this);return this},eachAfter:function(e,t){for(var r,a,i,n=this,s=[n],l=[],o=-1;n=s.pop();)if(l.push(n),r=n.children)for(a=0,i=r.length;a<i;++a)s.push(r[a]);for(;n=l.pop();)e.call(t,n,++o,this);return this},eachBefore:function(e,t){for(var r,a,i=this,n=[i],s=-1;i=n.pop();)if(e.call(t,i,++s,this),r=i.children)for(a=r.length-1;a>=0;--a)n.push(r[a]);return this},find:function(e,t){let r=-1;for(let a of this)if(e.call(t,a,++r,this))return a},sum:function(e){return this.eachAfter(function(t){for(var r=+e(t.data)||0,a=t.children,i=a&&a.length;--i>=0;)r+=a[i].value;t.value=r})},sort:function(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})},path:function(e){for(var t=this,r=function(e,t){if(e===t)return e;var r=e.ancestors(),a=t.ancestors(),i=null;for(e=r.pop(),t=a.pop();e===t;)i=e,e=r.pop(),t=a.pop();return i}(t,e),a=[t];t!==r;)a.push(t=t.parent);for(var i=a.length;e!==r;)a.splice(i,0,e),e=e.parent;return a},ancestors:function(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t},descendants:function(){return Array.from(this)},leaves:function(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e},links:function(){var e=this,t=[];return e.each(function(r){r!==e&&t.push({source:r.parent,target:r})}),t},copy:function(){return m(this).eachBefore(y)},[Symbol.iterator]:function*(){var e,t,r,a,i=this,n=[i];do for(e=n.reverse(),n=[];i=e.pop();)if(yield i,t=i.children)for(r=0,a=t.length;r<a;++r)n.push(t[r]);while(n.length)}};var w=e.i(64912),C=e.i(723685),T=class{constructor(){this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.setAccTitle=s.b,this.getAccTitle=s.d,this.setDiagramTitle=s.a,this.getDiagramTitle=s.F,this.getAccDescription=s.j,this.setAccDescription=s.C}static{(0,l.p)(this,"TreeMapDB")}getNodes(){return this.nodes}getConfig(){let e=s.f,t=(0,s.N)();return(0,n.z)({...e.treemap,...t.treemap??{}})}addNode(e,t){this.nodes.push(e),this.levels.set(e,t),0===t&&(this.outerNodes.push(e),this.root??=e)}getRoot(){return{name:"",children:this.outerNodes}}addClass(e,t){let r=this.classes.get(e)??{id:e,styles:[],textStyles:[]},i=t.replace(/\\,/g,"§§§").replace(/,/g,";").replace(/§§§/g,",").split(";");i&&i.forEach(e=>{(0,a.o)(e)&&(r?.textStyles?r.textStyles.push(e):r.textStyles=[e]),r?.styles?r.styles.push(e):r.styles=[e]}),this.classes.set(e,r)}getClasses(){return this.classes}getStylesForClass(e){return this.classes.get(e)?.styles??[]}clear(){(0,s.M)(),this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.root=void 0}};function b(e){if(!e.length)return[];let t=[],r=[];return e.forEach(e=>{let a={name:e.name,children:"Leaf"===e.type?void 0:[]};for(a.classSelector=e?.classSelector,e?.cssCompiledStyles&&(a.cssCompiledStyles=e.cssCompiledStyles),"Leaf"===e.type&&void 0!==e.value&&(a.value=e.value);r.length>0&&r[r.length-1].level>=e.level;)r.pop();if(0===r.length)t.push(a);else{let e=r[r.length-1].node;e.children?e.children.push(a):e.children=[a]}"Leaf"!==e.type&&r.push({node:a,level:e.level})}),t}(0,l.p)(b,"buildHierarchy");var k=(0,l.p)((e,t)=>{(0,i.f)(e,t);let r=[];for(let r of e.TreemapRows??[])"ClassDefStatement"===r.$type&&t.addClass(r.className??"",r.styleText??"");for(let a of e.TreemapRows??[]){let e=a.item;if(!e)continue;let i=a.indent?parseInt(a.indent):0,n=M(e),s=e.classSelector?t.getStylesForClass(e.classSelector):[],l=s.length>0?s:void 0,o={level:i,name:n,type:e.$type,value:e.value,classSelector:e.classSelector,cssCompiledStyles:l};r.push(o)}let a=b(r),n=(0,l.p)((e,r)=>{for(let a of e)t.addNode(a,r),a.children&&a.children.length>0&&n(a.children,r+1)},"addNodesRecursively");n(a,0)},"populate"),M=(0,l.p)(e=>e.name?String(e.name):"","getItemName"),$={parser:{yy:void 0},parse:(0,l.p)(async e=>{try{let t=o.f,r=await t("treemap",e);l.d.debug("Treemap AST:",r);let a=$.parser?.yy;if(!(a instanceof T))throw Error("parser.parser?.yy was not a TreemapDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");k(r,a)}catch(e){throw l.d.error("Error parsing treemap:",e),e}},"parse")},V=(0,l.p)((e,i,n,o)=>{let f,g=o.db,v=g.getConfig(),y=v.padding??10,S=g.getDiagramTitle(),x=g.getRoot(),{themeVariables:T}=(0,s.N)();if(!x)return;let b=30*!!S,k=(0,t.f)(i),M=v.nodeWidth?10*v.nodeWidth:960,$=v.nodeHeight?10*v.nodeHeight:500,V=$+b;k.attr("viewBox",`0 0 ${M} ${V}`),(0,s.m)(k,V,M,v.useMaxWidth);try{let e=v.valueFormat||",";if("$0,0"===e)f=(0,l.p)(e=>"$"+(0,w.R)(",")(e),"valueFormat");else if(e.startsWith("$")&&e.includes(",")){let t=/\.\d+/.exec(e),r=t?t[0]:"";f=(0,l.p)(e=>"$"+(0,w.R)(","+r)(e),"valueFormat")}else if(e.startsWith("$")){let t=e.substring(1);f=(0,l.p)(e=>"$"+(0,w.R)(t||"")(e),"valueFormat")}else f=(0,w.R)(e)}catch(e){l.d.error("Error creating format function:",e),f=(0,w.R)(",")}let L=(0,c.f)().range(["transparent",T.cScale0,T.cScale1,T.cScale2,T.cScale3,T.cScale4,T.cScale5,T.cScale6,T.cScale7,T.cScale8,T.cScale9,T.cScale10,T.cScale11]),A=(0,c.f)().range(["transparent",T.cScalePeer0,T.cScalePeer1,T.cScalePeer2,T.cScalePeer3,T.cScalePeer4,T.cScalePeer5,T.cScalePeer6,T.cScalePeer7,T.cScalePeer8,T.cScalePeer9,T.cScalePeer10,T.cScalePeer11]),B=(0,c.f)().range([T.cScaleLabel0,T.cScaleLabel1,T.cScaleLabel2,T.cScaleLabel3,T.cScaleLabel4,T.cScaleLabel5,T.cScaleLabel6,T.cScaleLabel7,T.cScaleLabel8,T.cScaleLabel9,T.cScaleLabel10,T.cScaleLabel11]);S&&k.append("text").attr("x",M/2).attr("y",b/2).attr("class","treemapTitle").attr("text-anchor","middle").attr("dominant-baseline","middle").text(S);let P=k.append("g").attr("transform",`translate(0, ${b})`).attr("class","treemapContainer"),E=m(x).sum(e=>e.value??0).sort((e,t)=>(t.value??0)-(e.value??0)),N=(function(){var e=d,t=!1,r=1,a=1,i=[0],n=p,s=p,l=p,o=p,c=p;function f(e){return e.x0=e.y0=0,e.x1=r,e.y1=a,e.eachBefore(m),i=[0],t&&e.eachBefore(u),e}function m(t){var r=i[t.depth],a=t.x0+r,u=t.y0+r,d=t.x1-r,p=t.y1-r;d<a&&(a=d=(a+d)/2),p<u&&(u=p=(u+p)/2),t.x0=a,t.y0=u,t.x1=d,t.y1=p,t.children&&(r=i[t.depth+1]=n(t)/2,a+=c(t)-r,u+=s(t)-r,d-=l(t)-r,p-=o(t)-r,d<a&&(a=d=(a+d)/2),p<u&&(u=p=(u+p)/2),e(t,a,u,d,p))}return f.round=function(e){return arguments.length?(t=!!e,f):t},f.size=function(e){return arguments.length?(r=+e[0],a=+e[1],f):[r,a]},f.tile=function(t){return arguments.length?(e=function(e){if("function"!=typeof e)throw Error();return e}(t),f):e},f.padding=function(e){return arguments.length?f.paddingInner(e).paddingOuter(e):f.paddingInner()},f.paddingInner=function(e){return arguments.length?(n="function"==typeof e?e:h(+e),f):n},f.paddingOuter=function(e){return arguments.length?f.paddingTop(e).paddingRight(e).paddingBottom(e).paddingLeft(e):f.paddingTop()},f.paddingTop=function(e){return arguments.length?(s="function"==typeof e?e:h(+e),f):s},f.paddingRight=function(e){return arguments.length?(l="function"==typeof e?e:h(+e),f):l},f.paddingBottom=function(e){return arguments.length?(o="function"==typeof e?e:h(+e),f):o},f.paddingLeft=function(e){return arguments.length?(c="function"==typeof e?e:h(+e),f):c},f})().size([M,$]).paddingTop(e=>e.children&&e.children.length>0?35:0).paddingInner(y).paddingLeft(e=>e.children&&e.children.length>0?10:0).paddingRight(e=>e.children&&e.children.length>0?10:0).paddingBottom(e=>e.children&&e.children.length>0?10:0).round(!0)(E),R=N.descendants().filter(e=>e.children&&e.children.length>0),I=P.selectAll(".treemapSection").data(R).enter().append("g").attr("class","treemapSection").attr("transform",e=>`translate(${e.x0},${e.y0})`);I.append("rect").attr("width",e=>e.x1-e.x0).attr("height",25).attr("class","treemapSectionHeader").attr("fill","none").attr("fill-opacity",.6).attr("stroke-width",.6).attr("style",e=>0===e.depth?"display: none;":""),I.append("clipPath").attr("id",(e,t)=>`clip-section-${i}-${t}`).append("rect").attr("width",e=>Math.max(0,e.x1-e.x0-12)).attr("height",25),I.append("rect").attr("width",e=>e.x1-e.x0).attr("height",e=>e.y1-e.y0).attr("class",(e,t)=>`treemapSection section${t}`).attr("fill",e=>L(e.data.name)).attr("fill-opacity",.6).attr("stroke",e=>A(e.data.name)).attr("stroke-width",2).attr("stroke-opacity",.4).attr("style",e=>{if(0===e.depth)return"display: none;";let t=(0,a.u)({cssCompiledStyles:e.data.cssCompiledStyles});return t.nodeStyles+";"+t.borderStyles.join(";")}),I.append("text").attr("class","treemapSectionLabel").attr("x",6).attr("y",12.5).attr("dominant-baseline","middle").text(e=>0===e.depth?"":e.data.name).attr("font-weight","bold").attr("style",e=>0===e.depth?"display: none;":"dominant-baseline: middle; font-size: 12px; fill:"+B(e.data.name)+"; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;"+(0,a.u)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:")).each(function(e){if(0===e.depth)return;let t=(0,C.f)(this),r=e.data.name;t.text(r);let a=e.x1-e.x0,i=Math.max(15,!1!==v.showValues&&e.value?a-10-30-10-6:a-6-6),n=t.node();if(n.getComputedTextLength()>i){let e=r;for(;e.length>0;){if(0===(e=r.substring(0,e.length-1)).length){t.text("..."),n.getComputedTextLength()>i&&t.text("");break}if(t.text(e+"..."),n.getComputedTextLength()<=i)break}}}),!1!==v.showValues&&I.append("text").attr("class","treemapSectionValue").attr("x",e=>e.x1-e.x0-10).attr("y",12.5).attr("text-anchor","end").attr("dominant-baseline","middle").text(e=>e.value?f(e.value):"").attr("font-style","italic").attr("style",e=>0===e.depth?"display: none;":"text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:"+B(e.data.name)+"; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;"+(0,a.u)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:"));let z=N.leaves(),F=P.selectAll(".treemapLeafGroup").data(z).enter().append("g").attr("class",(e,t)=>`treemapNode treemapLeafGroup leaf${t}${e.data.classSelector?` ${e.data.classSelector}`:""}x`).attr("transform",e=>`translate(${e.x0},${e.y0})`);F.append("rect").attr("width",e=>e.x1-e.x0).attr("height",e=>e.y1-e.y0).attr("class","treemapLeaf").attr("fill",e=>e.parent?L(e.parent.data.name):L(e.data.name)).attr("style",e=>(0,a.u)({cssCompiledStyles:e.data.cssCompiledStyles}).nodeStyles).attr("fill-opacity",.3).attr("stroke",e=>e.parent?L(e.parent.data.name):L(e.data.name)).attr("stroke-width",3),F.append("clipPath").attr("id",(e,t)=>`clip-${i}-${t}`).append("rect").attr("width",e=>Math.max(0,e.x1-e.x0-4)).attr("height",e=>Math.max(0,e.y1-e.y0-4)),F.append("text").attr("class","treemapLabel").attr("x",e=>(e.x1-e.x0)/2).attr("y",e=>(e.y1-e.y0)/2).attr("style",e=>"text-anchor: middle; dominant-baseline: middle; font-size: 38px;fill:"+B(e.data.name)+";"+(0,a.u)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:")).attr("clip-path",(e,t)=>`url(#clip-${i}-${t})`).text(e=>e.data.name).each(function(e){let t=(0,C.f)(this),r=e.x1-e.x0,a=e.y1-e.y0,i=t.node(),n=r-8,s=a-8;if(n<10||s<10)return void t.style("display","none");let l=parseInt(t.style("font-size"),10);for(;i.getComputedTextLength()>n&&l>8;)l--,t.style("font-size",`${l}px`);let o=Math.max(6,Math.min(28,Math.round(.6*l))),c=l+2+o;for(;c>s&&l>8&&(!((o=Math.max(6,Math.min(28,Math.round(.6*--l))))<6)||8!==l);)t.style("font-size",`${l}px`),c=l+2+o;t.style("font-size",`${l}px`),(i.getComputedTextLength()>n||l<8||s<l)&&t.style("display","none")}),!1!==v.showValues&&F.append("text").attr("class","treemapValue").attr("x",e=>(e.x1-e.x0)/2).attr("y",function(e){return(e.y1-e.y0)/2}).attr("style",e=>"text-anchor: middle; dominant-baseline: hanging; font-size: 28px;fill:"+B(e.data.name)+";"+(0,a.u)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:")).attr("clip-path",(e,t)=>`url(#clip-${i}-${t})`).text(e=>e.value?f(e.value):"").each(function(e){let t=(0,C.f)(this),r=this.parentNode;if(!r)return void t.style("display","none");let a=(0,C.f)(r).select(".treemapLabel");if(a.empty()||"none"===a.style("display"))return void t.style("display","none");let i=parseFloat(a.style("font-size")),n=Math.max(6,Math.min(28,Math.round(.6*i)));t.style("font-size",`${n}px`);let s=(e.y1-e.y0)/2+i/2+2;t.attr("y",s);let l=e.x1-e.x0,o=e.y1-e.y0;t.node().getComputedTextLength()>l-8||s+n>o-4||n<6?t.style("display","none"):t.style("display",null)});let D=v.diagramPadding??8;(0,r.f)(k,D,"flowchart",v?.useMaxWidth||!1)},"draw"),L=(0,l.p)(function(e,t){return t.db.getClasses()},"getClasses"),A={sectionStrokeColor:"black",sectionStrokeWidth:"1",sectionFillColor:"#efefef",leafStrokeColor:"black",leafStrokeWidth:"1",leafFillColor:"#efefef",labelFontSize:"12px",valueFontSize:"10px",titleFontSize:"14px"},B=(0,l.p)(({treemap:e}={})=>{let t=(0,s.p)(),r=(0,s.N)(),a=(0,n.z)(t,r.themeVariables),i=(0,n.z)(A,e),l=i.titleColor??a.titleColor,o=i.labelColor??a.textColor,c=i.valueColor??a.textColor;return`
2
+ .treemapNode.section {
3
+ stroke: ${i.sectionStrokeColor};
4
+ stroke-width: ${i.sectionStrokeWidth};
5
+ fill: ${i.sectionFillColor};
6
+ }
7
+ .treemapNode.leaf {
8
+ stroke: ${i.leafStrokeColor};
9
+ stroke-width: ${i.leafStrokeWidth};
10
+ fill: ${i.leafFillColor};
11
+ }
12
+ .treemapLabel {
13
+ fill: ${o};
14
+ font-size: ${i.labelFontSize};
15
+ }
16
+ .treemapValue {
17
+ fill: ${c};
18
+ font-size: ${i.valueFontSize};
19
+ }
20
+ .treemapTitle {
21
+ fill: ${l};
22
+ font-size: ${i.titleFontSize};
23
+ }
24
+ `},"getStyles");e.s(["diagram",0,{parser:$,get db(){return new T},renderer:{draw:V,getClasses:L},styles:B}],389920)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,40890,e=>{"use strict";var t=e.i(324590);e.i(539927),e.S([t,"createArchitectureServices,w"],40890)}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,580578,e=>{"use strict";var t=e.i(974265),s=e.i(537097),r=e.i(651023),n=e.i(893976),a=e.i(610595),i=e.i(803874),l=e.i(816418),o=e.i(891287),g=e.i(321417),d=e.i(255817),c=e.i(400019),u=e.i(297629),m=e.i(476007);function x({org:e,onOrgChanged:s,className:h}){let f=(0,r.useId)(),p=(0,u.L)()?.setActiveOrg,b=(0,l.$)(),j=(0,i.f)(e&&!1===b?{kind:"organization",id:e}:null,"can_manage_child_orgs",{fail:"closed"}),v=!1===b&&!j.isLoading&&j.allowed,{children:N,hasMore:y,loadMore:k,isLoadingMore:w,loadMoreError:z,error:C,refetch:L}=function(e,t={}){let s=(0,d.f)(),r=t.pageSize??25,n=(0,c.f)(e?t=>s.organization.listChildOrgs((0,o.f)(g.P,{org:e,pageSize:r,pageToken:t})):null,[e,r,s],e=>e.metadata?.id??"");return{children:n.items,hasMore:n.hasMore,loadMore:n.loadMore,isLoadingMore:n.isLoadingMore,loadMoreError:n.loadMoreError,isLoading:n.isLoading,error:n.error,refetch:n.refetch}}(v?e:null);return v&&(0!==N.length||null!==C)?(0,t.jsxs)("section",{"aria-labelledby":f,className:(0,n.f)("stg:mt-8",h),children:[(0,t.jsx)("h3",{id:f,className:"stg:text-foreground stg:mb-1 stg:text-xs stg:font-semibold",children:"Child organizations"}),(0,t.jsxs)("p",{className:"stg:text-muted-foreground stg:mb-3 stg:text-xs",children:["Organizations under this one. This organization's admins are admins in each of them, as their own admins are; each person's conversations, My vault and memories stay private to them.",p&&" Open one to work in it as its admin."]}),null!==C?(0,t.jsx)(m.f,{error:C,title:"The child organizations could not be read",retry:L}):(0,t.jsxs)("table",{className:"stg:w-full stg:text-left stg:text-xs",children:[(0,t.jsx)("thead",{className:"stg:text-muted-foreground",children:(0,t.jsxs)("tr",{children:[(0,t.jsx)("th",{scope:"col",className:"stg:py-1.5 stg:font-medium",children:"Name"}),(0,t.jsx)("th",{scope:"col",className:"stg:py-1.5 stg:font-medium",children:"Slug"}),(0,t.jsx)("th",{scope:"col",className:"stg:py-1.5 stg:font-medium",children:"External id"}),p&&(0,t.jsx)("th",{scope:"col",className:"stg:py-1.5",children:(0,t.jsx)("span",{className:"stg:sr-only",children:"Actions"})})]})}),(0,t.jsx)("tbody",{children:N.map(e=>(0,t.jsxs)("tr",{className:"stg:border-t stg:border-border",children:[(0,t.jsx)("td",{className:"stg:py-1.5 stg:text-foreground",children:e.metadata?.name}),(0,t.jsx)("td",{className:"stg:py-1.5 stg:font-mono stg:text-foreground",children:e.metadata?.slug}),(0,t.jsx)("td",{className:"stg:py-1.5 stg:font-mono stg:text-muted-foreground",children:e.spec?.externalId||"—"}),p&&(0,t.jsx)("td",{className:"stg:py-1.5 stg:text-right",children:(0,t.jsx)("button",{type:"button",onClick:()=>{p?.(e),s?.(e)},"aria-label":`Open ${e.metadata?.name||e.metadata?.slug||"organization"}`,className:"stg:text-primary stg:text-xs stg:font-medium stg:hover:underline",children:"Open"})})]},e.metadata?.id))})]}),null!==z&&(0,t.jsx)("p",{className:"stg:text-destructive stg:mt-2 stg:text-xs",role:"alert",children:(0,a.g)(z)}),y&&(0,t.jsx)("button",{type:"button",onClick:k,disabled:w,className:"stg:text-primary stg:mt-2 stg:text-xs stg:font-medium stg:hover:underline stg:disabled:opacity-50",children:w?"Loading…":"Load more"})]}):null}var h=e.i(785767),f=e.i(998127),p=e.i(313488),b=e.i(333259),j=e.i(459153),v=e.i(781836),N=e.i(853994),y=e.i(796896),k=e.i(971854),w=e.i(170255),z=e.i(379410),C=e.i(193799),L=e.i(734433),S=e.i(252771);function M({org:e,onUpdated:s,className:a}){let o=(0,r.useId)(),{organization:g,isLoading:d,error:c,refetch:x}=(0,p.f)(e||null),j=(0,u.L)(),{update:v,isUpdating:N,error:y,clearError:k}=(0,b.f)(),[w,C]=(0,r.useState)(""),[S,O]=(0,r.useState)(""),[_,E]=(0,r.useState)(""),R=g?.metadata?.name??"",F=g?.spec?.description??"",q=g?.spec?.logoUrl??"",B=g?.metadata?.slug??"",D=g?.metadata?.id??"",U=(0,l.$)(),W=(0,i.f)(D?{kind:"organization",id:D}:null,"can_delete",{fail:"closed"}),P=!1===U&&W.allowed,V=(0,i.f)(D?{kind:"organization",id:D}:null,"can_edit"),K=!V.isLoading&&V.allowed,J=!V.isLoading&&!V.allowed;(0,r.useEffect)(()=>{g&&(C(g.metadata?.name??""),O(g.spec?.description??""),E(g.spec?.logoUrl??""))},[g]);let X=(0,r.useMemo)(()=>w.trim()!==R||S.trim()!==F||_.trim()!==q,[w,S,_,R,F,q]),H=K&&w.trim().length>0&&!N&&X,Y=(0,r.useCallback)(()=>{j?.refresh(j.activeOrg?.metadata?.id)},[j]),Z=(0,r.useCallback)(()=>{C(R),O(F),E(q),k()},[R,F,q,k]),G=(0,r.useCallback)(async e=>{if(e.preventDefault(),H&&g){k();try{let{resource:e,paths:t}=(0,f.N)(g,h.Z,{name:w.trim(),description:S.trim()||void 0,logoUrl:_.trim()||void 0}),r=await v(e,t);x(),Y(),s?.(r)}catch{}}},[H,g,w,S,_,v,k,x,Y,s]);return d&&!g?(0,t.jsx)(L.SettingsSkeleton,{label:"Loading organization profile",rows:2,className:a}):c?(0,t.jsx)(m.f,{error:c,title:"The profile could not be read",retry:x,className:a}):g?(0,t.jsxs)("form",{onSubmit:G,className:(0,n.f)("stg:space-y-6",a),children:[(0,t.jsxs)("div",{className:"stg:space-y-3",children:[P?(0,t.jsx)(A,{orgId:D,currentSlug:B,onRenamed:e=>{x(),Y(),s?.(e)}}):(0,t.jsx)($,{label:"Slug",value:B,mono:!0}),(0,t.jsx)($,{label:"Organization ID",value:D})]}),(0,t.jsx)("hr",{className:"stg:border-border"}),(0,t.jsxs)("div",{className:"stg:space-y-4",children:[(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("label",{htmlFor:`${o}-name`,className:"stg:text-xs stg:font-medium stg:text-foreground",children:"Name"}),(0,t.jsx)("input",{id:`${o}-name`,type:"text",value:w,onChange:e=>C(e.target.value),disabled:N,readOnly:!K,required:!0,className:(0,n.f)("stg:w-full stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:placeholder:text-muted-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-1 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50",J&&"stg:bg-muted-subtle stg:text-muted-foreground")}),(0,t.jsx)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:"The display name shown in the sidebar and across the platform."})]}),(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("label",{htmlFor:`${o}-desc`,className:"stg:text-xs stg:font-medium stg:text-foreground",children:"Description"}),(0,t.jsx)("textarea",{id:`${o}-desc`,value:S,onChange:e=>O(e.target.value),maxLength:500,rows:3,disabled:N,readOnly:!K,placeholder:K?"What is this organization for?":void 0,className:(0,n.f)("stg:w-full stg:resize-y stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:placeholder:text-muted-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-1 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50",J&&"stg:bg-muted-subtle stg:text-muted-foreground")}),K&&(0,t.jsxs)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:[S.length,"/",500," characters"]})]}),(0,t.jsxs)("div",{className:"stg:space-y-1",children:[(0,t.jsx)("label",{htmlFor:`${o}-logo`,className:"stg:text-xs stg:font-medium stg:text-foreground",children:"Logo URL"}),(0,t.jsx)("input",{id:`${o}-logo`,type:"url",value:_,onChange:e=>E(e.target.value),maxLength:2048,disabled:N,readOnly:!K,placeholder:K?"https://example.com/logo.png":void 0,className:(0,n.f)("stg:w-full stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5 stg:text-xs stg:text-foreground","stg:placeholder:text-muted-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-1 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50",J&&"stg:bg-muted-subtle stg:text-muted-foreground")}),(0,t.jsx)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:"A public URL to your organization's logo image."}),(0,t.jsx)(T,{url:_.trim()})]})]}),J&&(0,t.jsx)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:"Only organization admins can edit this profile."}),y&&(0,t.jsx)("p",{className:"stg:text-destructive stg:text-2xs",role:"alert",children:(0,f.q)(y,"organization")}),K&&(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[(0,t.jsxs)("button",{type:"submit",disabled:!H,className:(0,n.f)("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)(z.f,{size:12}),"Save changes"]}),X&&!N&&(0,t.jsx)("button",{type:"button",onClick:Z,className:(0,n.f)("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"),children:"Discard"})]}),(0,t.jsx)(I,{orgId:D})]}):null}function I({orgId:e}){let s=(0,k._)(w.X.federation_issuer),{federationIssuers:r,isLoading:n}=(0,N.f)(s&&e?e:null),a=(0,i.f)(s&&e?{kind:"organization",id:e}:null,"can_create_federation_issuer"),l=!a.isLoading&&!a.allowed;return s&&e?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("hr",{className:"stg:border-border"}),(0,t.jsxs)("div",{className:"stg:space-y-2",children:[(0,t.jsx)("p",{className:"stg:text-2xs stg:font-medium stg:text-muted-foreground stg:uppercase stg:tracking-wider",children:"Federation Issuers"}),n?(0,t.jsx)(L.SettingsSkeleton,{label:"Loading federation issuers",rows:1}):0===r.length&&l?(0,t.jsx)("p",{className:"stg:text-xs stg:text-muted-foreground",children:y.i}):0===r.length?(0,t.jsxs)("p",{className:"stg:text-xs stg:text-muted-foreground",children:["No federation issuers configured."," ",(0,t.jsx)("a",{href:"/settings/federation-issuers",className:"stg:text-primary stg:hover:text-primary-hover stg:underline stg:underline-offset-2",children:"Set up federated authentication"})]}):(0,t.jsxs)("div",{className:"stg:space-y-1.5",children:[r.map(e=>{let s=e.spec,r=s?.displayName||e.metadata?.name||"Unnamed",n=s?.createAccountsOnSignIn;return(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2 stg:text-xs",children:[(0,t.jsx)(O,{}),(0,t.jsx)("span",{className:"stg:text-foreground stg:truncate",children:r}),n&&(0,t.jsx)("span",{className:"stg:rounded-full stg:border stg:border-primary/30 stg:bg-primary-subtle stg:px-1.5 stg:py-px stg:text-2xs stg:font-medium stg:text-primary",children:"JIT"})]},e.metadata?.id)}),(0,t.jsx)("a",{href:"/settings/federation-issuers",className:"stg:inline-block stg:text-2xs stg:text-primary stg:hover:text-primary-hover stg:underline stg:underline-offset-2",children:"Manage"})]})]})]}):null}function O(){return(0,t.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",className:"stg:shrink-0 stg:text-muted-foreground",children:(0,t.jsx)("path",{d:"M8 1.5L2 4v4c0 3.5 2.5 5.5 6 7 3.5-1.5 6-3.5 6-7V4L8 1.5z"})})}function A({orgId:e,currentSlug:s,onRenamed:n}){let{rename:a,isRenaming:i,error:l,clearError:g}=function(){let e=(0,d.f)(),[t,s]=(0,r.useState)(!1),[n,a]=(0,r.useState)(null),i=(0,r.useCallback)(()=>a(null),[]);return{rename:(0,r.useCallback)(async(t,r)=>{s(!0),a(null);try{return await e.organization.rename((0,o.f)(j.I,{resourceId:t,slug:r}))}catch(e){throw a((0,v.f)(e)),e}finally{s(!1)}},[e]),isRenaming:t,error:n,clearError:i}}(),c=(0,r.useCallback)(t=>a(e,t),[a,e]);return(0,t.jsx)(S.V,{currentSlug:s,rename:c,isRenaming:i,error:l,clearError:g,onRenamed:n,hint:"The name in links to this organization. Links with the old slug keep working for 30 days after a rename."})}function $({label:e,value:s,mono:r}){let{copy:a,copied:i}=(0,C.f)();return s?(0,t.jsxs)("div",{className:"stg:space-y-0.5",children:[(0,t.jsx)("p",{className:"stg:text-2xs stg:font-medium stg:text-muted-foreground stg:uppercase stg:tracking-wider",children:e}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[(0,t.jsx)("span",{className:(0,n.f)("stg:text-xs stg:text-foreground stg:select-all",r&&"stg:font-mono"),children:s}),(0,t.jsx)("button",{type:"button",onClick:()=>void a(s),className:(0,n.f)("stg:rounded stg:px-1.5 stg:py-0.5 stg:text-2xs","stg:text-muted-foreground stg:hover:text-foreground stg:hover:bg-accent-hover","stg:transition-colors"),"aria-label":`Copy ${e}`,children:i?"Copied":"Copy"})]})]}):null}function T({url:e}){let[s,a]=(0,r.useState)("idle");return((0,r.useEffect)(()=>{a("idle")},[e]),e&&"error"!==s)?(0,t.jsx)("div",{className:"stg:mt-2",children:(0,t.jsx)("img",{src:e,alt:"Organization logo preview",onLoad:()=>a("loaded"),onError:()=>a("error"),className:(0,n.f)("stg:h-10 stg:w-10 stg:rounded-md stg:border stg:border-border stg:object-contain stg:bg-background","idle"===s&&"stg:opacity-0","loaded"===s&&"stg:opacity-100")})}):null}var _=e.i(193251),E=e.i(365785);function R({onOrgChanged:e}={}){let{activeOrg:s}=(0,u.S)(),r=s?.metadata?.id??"";return(0,t.jsx)(E.f,{title:"Organization profile",description:"This organization's name, description and logo, as its members see them.",children:r?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(M,{org:r}),(0,t.jsx)(x,{org:r,onOrgChanged:e})]}):(0,t.jsx)(_.j,{what:"its profile"})})}e.s(["default",0,function(){let e=(0,s.useRouter)(),n=(0,r.useCallback)(()=>{e.push("/dashboard")},[e]);return(0,t.jsx)(R,{onOrgChanged:n})}],580578)},311015,e=>{"use strict";var t=e.i(974265),s=e.i(893976),r=e.i(65642),n=e.i(651023),a=e.i(475254);let i=(0,a.f)("package",[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]),l=(0,a.f)("search-x",[["path",{d:"m13.5 8.5-5 5",key:"1cs55j"}],["path",{d:"m8.5 8.5 5 5",key:"a8mexj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]),o=(0,a.f)("lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);var g=e.i(63209);let d="stg:h-10 stg:w-10";e.s(["f",0,function({variant:e,resourceLabel:a,icon:c,title:u,description:m,errorMessage:x,action:h,children:f,className:p}){let b=function(e){let{variant:t,resourceLabel:s="resources",title:r,description:a,errorMessage:c}=e;return(0,n.useMemo)(()=>{let e=function(e,t){switch(e){case"first-use":return{title:`No ${t} yet`,description:`Create ${"agents"===t?"an agent":`a ${t.replace(/s$/,"")}`} to get started.`};case"zero-results":return{title:"No results found",description:"Try adjusting your search or filters."};case"permission":return{title:`No access to ${t}`,description:"You don't have permission to view these resources. Contact your organization admin."};case"error":return{title:"Something went wrong",description:"We couldn't load this content. Please try again."}}}(t,s);return{title:r??e.title,description:"error"===t&&c?c:a??e.description,defaultIcon:function(e){switch(e){case"first-use":return(0,n.createElement)(i,{className:d});case"zero-results":return(0,n.createElement)(l,{className:d});case"permission":return(0,n.createElement)(o,{className:d});case"error":return(0,n.createElement)(g.f,{className:d})}}(t),role:"error"===t?"alert":"status"}},[t,s,r,a,c])}({variant:e,resourceLabel:a,title:u,description:m,errorMessage:x});return(0,t.jsxs)("div",{role:b.role,className:(0,s.f)("stg:flex stg:flex-col stg:items-center stg:gap-3 stg:py-12 stg:text-center",p),children:[(0,t.jsx)("div",{className:"stg:text-muted-foreground-faint",children:c??b.defaultIcon}),(0,t.jsxs)("div",{className:"stg:flex stg:flex-col stg:gap-1",children:[(0,t.jsx)("p",{className:"stg:m-0 stg:text-sm stg:font-medium stg:text-muted-foreground",children:b.title}),(0,t.jsx)("p",{className:"stg:m-0 stg:max-w-sm stg:text-xs stg:text-muted-foreground",children:b.description})]}),f?(0,t.jsx)("div",{className:"stg:mt-1",children:f}):h&&(0,t.jsx)(r.f,{variant:"error"===e?"outline":"primary",icon:h.icon,onClick:h.onClick,className:"stg:mt-1",children:h.label})]})}],311015)},476007,e=>{"use strict";var t=e.i(974265),s=e.i(651023),r=e.i(610595),n=e.i(893976);let a={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 i({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 l({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 o({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(["f",0,function({error:e,title:d,retry:c,className:u}){let[m,x]=(0,s.useState)(!1);if(!e)return null;let h=(0,r.V)(e),f=(0,r.g)(e),p=(0,r.X)(e),b=(0,r.f)(e);return(0,t.jsx)("div",{role:"alert",className:(0,n.f)("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"===h||"permission"===h?(0,t.jsx)(l,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0"}):(0,t.jsx)(i,{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:d??a[h]}),(0,t.jsx)("p",{className:"stg:m-0 stg:text-destructive stg:text-sm",children:f}),p&&(0,t.jsxs)("div",{className:"stg:pt-1",children:[(0,t.jsxs)("button",{type:"button",onClick:()=>x(e=>!e),className:"stg:text-destructive stg:hover:underline stg:inline-flex stg:items-center stg:gap-1 stg:text-xs stg:transition-colors",children:[(0,t.jsx)(o,{className:(0,n.f)("stg:size-3 stg:transition-transform",m&&"stg:rotate-180")}),"Technical details"]}),m&&(0,t.jsxs)("dl",{className:"stg:text-destructive 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:p.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:p.path})]})]})]})]}),c&&b&&(0,t.jsxs)("button",{type:"button",onClick:c,className:(0,n.f)("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"]})]})})}])},796896,e=>{"use strict";e.s(["j",0,"The aud claim your identity provider puts in tokens for Stigmer: an API identifier or client ID your organization registered there","_",0,"API identifier or client ID","i",0,"Federation issuers are managed by your organization's admins."])},853994,e=>{"use strict";var t=e.i(891287),s=e.i(997288),r=e.i(255817),n=e.i(766330),a=e.i(205413),i=e.i(616701);e.s(["f",0,function(e){let l=(0,r.f)(),{data:o,isLoading:g,isRefetching:d,error:c,refetch:u}=(0,i.f)(e?()=>(0,a.T)(r=>l.federationIssuer.list((0,t.f)(s.z,{org:e,pageSize:n.J,pageToken:r}))):null,[e,l],[]);return{federationIssuers:o,isLoading:g,isRefetching:d,error:c,refetch:u}}])},630983,e=>{"use strict";var t=e.i(974265),s=e.i(893976);function r({className:e}){return(0,t.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:e,"aria-hidden":"true",children:[(0,t.jsx)("circle",{cx:"8",cy:"8",r:"6.25"}),(0,t.jsx)("path",{d:"M8 7v4"}),(0,t.jsx)("circle",{cx:"8",cy:"5",r:"0.5",fill:"currentColor",stroke:"none"})]})}e.s(["f",0,function({children:e,className:n}){return(0,t.jsxs)("div",{role:"status",className:(0,s.f)("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",n),children:[(0,t.jsx)(r,{className:"stg:mt-0.5 stg:size-4 stg:shrink-0"}),(0,t.jsx)("p",{className:"stg:text-xs stg:leading-relaxed",children:e})]})}])},333259,e=>{"use strict";var t=e.i(651023),s=e.i(255817),r=e.i(781836);e.s(["f",0,function(){let e=(0,s.f)(),[n,a]=(0,t.useState)(!1),[i,l]=(0,t.useState)(null),o=(0,t.useCallback)(()=>l(null),[]);return{update:(0,t.useCallback)(async(t,s)=>{a(!0),l(null);try{return await e.organization.update(t,s)}catch(e){throw l((0,r.f)(e)),e}finally{a(!1)}},[e]),isUpdating:n,error:i,clearError:o}}])},66724,e=>{"use strict";var t=e.i(974265),s=e.i(893976);e.s(["f",0,function({title:e,description:r,actions:n,headingLevel:a=1,headingId:i,className:l}){return(0,t.jsxs)("header",{className:(0,s.f)("stg:flex stg:flex-col stg:gap-1",l),children:[(0,t.jsxs)("div",{className:"stg:flex stg:min-h-8 stg:flex-wrap stg:items-center stg:justify-between stg:gap-x-6 stg:gap-y-2",children:[(0,t.jsx)(1===a?"h1":"h2",{id:i,className:"stg:m-0 stg:text-xl stg:font-semibold stg:tracking-tight stg:text-foreground",children:e}),null!=n&&!1!==n&&(0,t.jsx)("div",{className:"stg:flex stg:shrink-0 stg:items-center stg:gap-2",children:n})]}),null!=r&&(0,t.jsx)("p",{className:"stg:m-0 stg:max-w-2xl stg:text-sm stg:text-muted-foreground",children:r})]})}])},252771,e=>{"use strict";var t=e.i(974265),s=e.i(651023),r=e.i(893976),n=e.i(610595),a=e.i(803874),i=e.i(379410),l=e.i(891287),o=e.i(459153),g=e.i(255817),d=e.i(781836);function c({currentSlug:e,rename:a,isRenaming:l,error:o,clearError:g,onRenamed:d,hint:u,label:m="Slug",className:x}){let h=(0,s.useId)(),[f,p]=(0,s.useState)(e),[b,j]=(0,s.useState)(null);(0,s.useEffect)(()=>{p(e),j(null)},[e]);let v=l||null!==b,N=f.trim(),y=N.length>0&&N!==e&&!v,k=(0,s.useCallback)(async()=>{if(y){g();try{let t=await a(N);j(e),d(t)}catch{}}},[y,g,a,N,e,d]);return(0,t.jsxs)("div",{className:(0,r.f)("stg:space-y-1",x),children:[(0,t.jsx)("label",{htmlFor:h,className:"stg:text-2xs stg:font-medium stg:text-muted-foreground stg:uppercase stg:tracking-wider",children:m}),(0,t.jsxs)("div",{className:"stg:flex stg:items-center stg:gap-2",children:[(0,t.jsx)("input",{id:h,type:"text",value:f,onChange:e=>{p(e.target.value),g()},onKeyDown:e=>{"Enter"===e.key&&(e.preventDefault(),k())},disabled:v,spellCheck:!1,autoComplete:"off",className:(0,r.f)("stg:w-full stg:rounded-md stg:border stg:border-input stg:bg-background stg:px-2.5 stg:py-1.5 stg:font-mono stg:text-xs stg:text-foreground","stg:focus-visible:outline-none stg:focus-visible:ring-1 stg:focus-visible:ring-ring","stg:disabled:pointer-events-none stg:disabled:opacity-50")}),(0,t.jsxs)("button",{type:"button",onClick:()=>void k(),disabled:!y,className:(0,r.f)("stg:inline-flex stg:shrink-0 stg:items-center stg:gap-1.5 stg:rounded-md stg:px-3 stg:py-1.5 stg:text-xs stg:font-medium","stg:border stg:border-input stg:text-foreground stg:hover:bg-accent-hover","stg:disabled:pointer-events-none stg:disabled:opacity-40"),children:[v&&(0,t.jsx)(i.f,{size:12}),"Rename"]})]}),o?(0,t.jsx)("p",{className:"stg:text-destructive stg:text-2xs",role:"alert",children:(0,n.g)(o)}):(0,t.jsx)("p",{className:"stg:text-2xs stg:text-muted-foreground",children:u})]})}e.s(["V",0,c,"e",0,function({kind:e,resourceId:r,currentSlug:n,onRenamed:i,fallback:u=null,className:m}){let x=(0,a.f)(r?{kind:e,id:r}:null,"can_delete",{fail:"closed"}),{rename:h,isRenaming:f,error:p,clearError:b}=function(e){let t=(0,g.f)(),[r,n]=(0,s.useState)(!1),[a,i]=(0,s.useState)(null),c=(0,s.useCallback)(()=>i(null),[]),u=(0,s.useCallback)(async(s,r)=>{n(!0),i(null);let a=(0,l.f)(o.I,{resourceId:s,slug:r});try{return await function(e,t,s){switch(t){case"agent":return e.agent.rename(s);case"vault":return e.vault.rename(s);case"routine":return e.routine.rename(s);case"environment":return e.environment.rename(s);case"channel_app":return e.channelapp.rename(s);case"oauth_app":return e.oauthapp.rename(s);case"team":return e.team.rename(s);case"federation_issuer":return e.federationIssuer.rename(s)}}(t,e,a)}catch(e){throw i((0,d.f)(e)),e}finally{n(!1)}},[t,e]);return(0,s.useMemo)(()=>({rename:u,isRenaming:r,error:a,clearError:c}),[u,r,a,c])}(e),j=(0,s.useCallback)(e=>h(r??"",e),[h,r]);return r&&x.allowed?(0,t.jsx)(c,{currentSlug:n,rename:j,isRenaming:f,error:p,clearError:b,onRenamed:i,hint:"The name in links and files. After a rename the old slug keeps working for reading for 30 days; a file that names it must change to the new one.",className:m}):(0,t.jsx)(t.Fragment,{children:u})}],252771)},193251,e=>{"use strict";var t=e.i(974265),s=e.i(311015);e.s(["H",0,"Ask one of them if this organization needs one.","j",0,function({what:e}){return(0,t.jsx)(s.f,{variant:"first-use",title:"No organization selected",description:`Choose an organization to see ${e}.`,className:"stg:rounded-lg stg:border stg:border-dashed stg:border-border"})}])},365785,e=>{"use strict";var t=e.i(974265),s=e.i(651023),r=e.i(893976),n=e.i(311015),a=e.i(630983),i=e.i(66724);e.s(["f",0,function({title:e,description:l,actions:o,unavailable:g,denied:d=!1,children:c,className:u}){let m=(0,s.useId)(),x=!0===d?{title:`Only an admin can open ${e}`,description:"Ask an owner or an admin of this organization."}:d||null,h=!!g||null!==x;return(0,t.jsxs)("section",{"aria-labelledby":m,className:(0,r.f)("stg:flex stg:flex-col stg:gap-6",u),children:[(0,t.jsx)(i.f,{title:e,description:l,actions:h?void 0:o,headingLevel:2,headingId:m}),g?(0,t.jsx)(a.f,{children:g}):null!==x?(0,t.jsx)(n.f,{variant:"permission",title:x.title,description:x.description,className:"stg:rounded-lg stg:border stg:border-border"}):c]})}])},734433,e=>{"use strict";var t=e.i(974265),s=e.i(893976),r=e.i(996675);e.s(["SettingsSkeleton",0,function({label:e="Loading",variant:n="rows",rows:a,className:i}){return"figures"===n?(0,t.jsxs)(r.f,{label:e,className:(0,s.f)("stg:flex stg:flex-col stg:gap-4",i),children:[(0,t.jsx)("div",{className:"stg:grid stg:grid-cols-1 stg:gap-3 stg:sm:grid-cols-3","aria-hidden":"true",children:Array.from({length:a??3},(e,s)=>(0,t.jsxs)("span",{className:"stg:flex stg:h-20 stg:flex-col stg:justify-center stg:gap-2 stg:rounded-lg stg:border stg:border-border stg:bg-card stg:px-4",children:[(0,t.jsx)("span",{className:"stg:h-2.5 stg:w-20 stg:animate-pulse stg:rounded stg:bg-muted-subtle"}),(0,t.jsx)("span",{className:"stg:h-5 stg:w-24 stg:animate-pulse stg:rounded stg:bg-muted"})]},s))}),(0,t.jsx)("span",{className:"stg:block stg:h-40 stg:animate-pulse stg:rounded-lg stg:border stg:border-border stg:bg-card","aria-hidden":"true"})]}):(0,t.jsx)(r.f,{label:e,className:(0,s.f)("stg:overflow-hidden stg:rounded-lg stg:border stg:border-border stg:bg-card",i),children:(0,t.jsx)("ul",{className:"stg:m-0 stg:list-none stg:divide-y stg:divide-border stg:p-0","aria-hidden":"true",children:Array.from({length:a??4},(e,s)=>(0,t.jsxs)("li",{className:"stg:flex stg:items-center stg:gap-3 stg:px-4 stg:py-3",children:[(0,t.jsx)("span",{className:"stg:size-8 stg:shrink-0 stg:animate-pulse stg:rounded-full stg:bg-muted"}),(0,t.jsxs)("span",{className:"stg:flex stg:flex-1 stg:flex-col stg:gap-1.5",children:[(0,t.jsx)("span",{className:"stg:h-3 stg:w-40 stg:max-w-full stg:animate-pulse stg:rounded stg:bg-muted"}),(0,t.jsx)("span",{className:"stg:h-2.5 stg:w-64 stg:max-w-full stg:animate-pulse stg:rounded stg:bg-muted-subtle"})]}),(0,t.jsx)("span",{className:"stg:h-5 stg:w-14 stg:shrink-0 stg:animate-pulse stg:rounded-full stg:bg-muted"})]},s))})})}])}]);