@surething/cockpit 1.1.8 → 1.1.9

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 (598) hide show
  1. package/.next-prod/BUILD_ID +1 -1
  2. package/.next-prod/app-path-routes-manifest.json +9 -5
  3. package/.next-prod/build-manifest.json +2 -2
  4. package/.next-prod/cockpit-build.json +1 -1
  5. package/.next-prod/prerender-manifest.json +3 -3
  6. package/.next-prod/routes-manifest.json +24 -0
  7. package/.next-prod/server/app/_global-error/page.js +2 -2
  8. package/.next-prod/server/app/_global-error/page_client-reference-manifest.js +1 -1
  9. package/.next-prod/server/app/_global-error.html +1 -1
  10. package/.next-prod/server/app/_global-error.rsc +1 -1
  11. package/.next-prod/server/app/_global-error.segments/_full.segment.rsc +1 -1
  12. package/.next-prod/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  13. package/.next-prod/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  14. package/.next-prod/server/app/_not-found/page.js +1 -1
  15. package/.next-prod/server/app/_not-found/page_client-reference-manifest.js +1 -1
  16. package/.next-prod/server/app/api/agent/test/route.js +1 -1
  17. package/.next-prod/server/app/api/bash/route.js +1 -1
  18. package/.next-prod/server/app/api/bots/[id]/route.js +1 -1
  19. package/.next-prod/server/app/api/bots/files/route.js +1 -1
  20. package/.next-prod/server/app/api/bots/route.js +1 -1
  21. package/.next-prod/server/app/api/chat/codex/route.js +1 -1
  22. package/.next-prod/server/app/api/chat/deepseek/route.js +1 -1
  23. package/.next-prod/server/app/api/chat/glm/route.js +1 -1
  24. package/.next-prod/server/app/api/chat/grok/route.js +1 -1
  25. package/.next-prod/server/app/api/chat/kimi/route.js +1 -1
  26. package/.next-prod/server/app/api/chat/ollama/route.js +1 -1
  27. package/.next-prod/server/app/api/chat/route.js +1 -1
  28. package/.next-prod/server/app/api/chat/stop/route.js +1 -1
  29. package/.next-prod/server/app/api/claude-stats/route.js +1 -1
  30. package/.next-prod/server/app/api/commands/route.js +1 -1
  31. package/.next-prod/server/app/api/comments/route.js +1 -1
  32. package/.next-prod/server/app/api/db/columns/route.js +1 -1
  33. package/.next-prod/server/app/api/db/connect/route.js +1 -1
  34. package/.next-prod/server/app/api/db/disconnect/route.js +1 -1
  35. package/.next-prod/server/app/api/db/export/route.js +1 -1
  36. package/.next-prod/server/app/api/db/query/route.js +1 -1
  37. package/.next-prod/server/app/api/db/schemas/route.js +2 -2
  38. package/.next-prod/server/app/api/deepseek/balance/route.js +1 -1
  39. package/.next-prod/server/app/api/deepseek/credentials/route.js +1 -1
  40. package/.next-prod/server/app/api/deepseek/models/route.js +1 -1
  41. package/.next-prod/server/app/api/dev/spans/route.js +1 -1
  42. package/.next-prod/server/app/api/extension/version/route.js +1 -1
  43. package/.next-prod/server/app/api/file/route.js +1 -1
  44. package/.next-prod/server/app/api/files/blame/route.js +1 -1
  45. package/.next-prod/server/app/api/files/clipboard/route.js +1 -1
  46. package/.next-prod/server/app/api/files/copy/route.js +1 -1
  47. package/.next-prod/server/app/api/files/delete/route.js +1 -1
  48. package/.next-prod/server/app/api/files/expanded/route.js +1 -1
  49. package/.next-prod/server/app/api/files/index/route.js +1 -1
  50. package/.next-prod/server/app/api/files/init/route.js +1 -1
  51. package/.next-prod/server/app/api/files/paste/route.js +1 -1
  52. package/.next-prod/server/app/api/files/read/route.js +1 -1
  53. package/.next-prod/server/app/api/files/readdir/route.js +1 -1
  54. package/.next-prod/server/app/api/files/recent/route.js +1 -1
  55. package/.next-prod/server/app/api/files/save/route.js +1 -1
  56. package/.next-prod/server/app/api/files/search/route.js +1 -1
  57. package/.next-prod/server/app/api/files/stat/route.js +1 -1
  58. package/.next-prod/server/app/api/files/text/route.js +1 -1
  59. package/.next-prod/server/app/api/fs/dirs/route.js +1 -1
  60. package/.next-prod/server/app/api/git/blob/route.js +1 -1
  61. package/.next-prod/server/app/api/git/branch-diff/route.js +1 -1
  62. package/.next-prod/server/app/api/git/branches/route.js +1 -1
  63. package/.next-prod/server/app/api/git/commit-diff/route.js +1 -1
  64. package/.next-prod/server/app/api/git/commits/route.js +1 -1
  65. package/.next-prod/server/app/api/git/current-branch/route.js +1 -1
  66. package/.next-prod/server/app/api/git/diff/route.js +1 -1
  67. package/.next-prod/server/app/api/git/discard/route.js +1 -1
  68. package/.next-prod/server/app/api/git/stage/route.js +1 -1
  69. package/.next-prod/server/app/api/git/status/route.js +1 -1
  70. package/.next-prod/server/app/api/git/unstage/route.js +1 -1
  71. package/.next-prod/server/app/api/git/worktree/route.js +1 -1
  72. package/.next-prod/server/app/api/glm/credentials/route.js +1 -1
  73. package/.next-prod/server/app/api/glm/models/route.js +1 -1
  74. package/.next-prod/server/app/api/glm/usage/route.js +1 -1
  75. package/.next-prod/server/app/api/global-state/route.js +2 -2
  76. package/.next-prod/server/app/api/grok/models/route.js +1 -1
  77. package/.next-prod/server/app/api/health/route.js +1 -1
  78. package/.next-prod/server/app/api/html-apps/[id]/route.js +1 -1
  79. package/.next-prod/server/app/api/html-apps/files/route.js +1 -1
  80. package/.next-prod/server/app/api/html-apps/route.js +1 -1
  81. package/.next-prod/server/app/api/instructions/config/route.js +1 -1
  82. package/.next-prod/server/app/api/kimi/credentials/route.js +1 -1
  83. package/.next-prod/server/app/api/kimi/models/route.js +1 -1
  84. package/.next-prod/server/app/api/kimi/usage/route.js +1 -1
  85. package/.next-prod/server/app/api/lsp/definition/route.js +1 -1
  86. package/.next-prod/server/app/api/lsp/hover/route.js +1 -1
  87. package/.next-prod/server/app/api/lsp/references/route.js +1 -1
  88. package/.next-prod/server/app/api/lsp/status/route.js +1 -1
  89. package/.next-prod/server/app/api/lsp/warmup/route.js +1 -1
  90. package/.next-prod/server/app/api/mobile-link/route.js +1 -1
  91. package/.next-prod/server/app/api/mysql/columns/route.js +2 -2
  92. package/.next-prod/server/app/api/mysql/connect/route.js +1 -1
  93. package/.next-prod/server/app/api/mysql/disconnect/route.js +1 -1
  94. package/.next-prod/server/app/api/mysql/export/route.js +1 -1
  95. package/.next-prod/server/app/api/mysql/query/route.js +1 -1
  96. package/.next-prod/server/app/api/mysql/schemas/route.js +2 -2
  97. package/.next-prod/server/app/api/neo4j/connect/route.js +1 -1
  98. package/.next-prod/server/app/api/neo4j/disconnect/route.js +1 -1
  99. package/.next-prod/server/app/api/neo4j/query/route.js +1 -1
  100. package/.next-prod/server/app/api/neo4j/schema/route.js +1 -1
  101. package/.next-prod/server/app/api/note/list/route.js +1 -1
  102. package/.next-prod/server/app/api/note/route.js +1 -1
  103. package/.next-prod/server/app/api/ollama/config/route.js +1 -1
  104. package/.next-prod/server/app/api/ollama/default-model/route.js +1 -1
  105. package/.next-prod/server/app/api/ollama/models/route.js +1 -1
  106. package/.next-prod/server/app/api/ollama/start/route.js +1 -1
  107. package/.next-prod/server/app/api/open-cursor/route.js +1 -1
  108. package/.next-prod/server/app/api/open-vscode/route.js +1 -1
  109. package/.next-prod/server/app/api/pi/thinking/route.js +1 -1
  110. package/.next-prod/server/app/api/pinned-sessions/route.js +1 -1
  111. package/.next-prod/server/app/api/project-settings/route.js +1 -1
  112. package/.next-prod/server/app/api/project-state/route.js +2 -2
  113. package/.next-prod/server/app/api/projectGraph/affected/route.js +1 -1
  114. package/.next-prod/server/app/api/projectGraph/callees/route.js +1 -1
  115. package/.next-prod/server/app/api/projectGraph/callers/route.js +1 -1
  116. package/.next-prod/server/app/api/projectGraph/coedit/route.js +1 -1
  117. package/.next-prod/server/app/api/projectGraph/edges/route.js +1 -0
  118. package/.next-prod/server/app/api/projectGraph/edges/route.js.nft.json +1 -0
  119. package/.next-prod/server/app/api/projectGraph/edges/route_client-reference-manifest.js +1 -0
  120. package/.next-prod/server/app/api/projectGraph/file/route.js +1 -1
  121. package/.next-prod/server/app/api/projectGraph/file-functions/route.js +1 -1
  122. package/.next-prod/server/app/api/projectGraph/impact/route.js +1 -1
  123. package/.next-prod/server/app/api/projectGraph/maps/route.js +1 -0
  124. package/.next-prod/server/app/api/projectGraph/maps/route.js.nft.json +1 -0
  125. package/.next-prod/server/app/api/projectGraph/maps/route_client-reference-manifest.js +1 -0
  126. package/.next-prod/server/app/api/projectGraph/related/route.js +1 -1
  127. package/.next-prod/server/app/api/projectGraph/search/route.js +1 -1
  128. package/.next-prod/server/app/api/projectGraph/symbols/route.js +1 -1
  129. package/.next-prod/server/app/api/projects/route.js +1 -1
  130. package/.next-prod/server/app/api/push/public-key/route.js +1 -1
  131. package/.next-prod/server/app/api/push/subscribe/route.js +1 -1
  132. package/.next-prod/server/app/api/push/unsubscribe/route.js +1 -1
  133. package/.next-prod/server/app/api/redis/command/route.js +1 -1
  134. package/.next-prod/server/app/api/redis/connect/route.js +1 -1
  135. package/.next-prod/server/app/api/redis/delete/route.js +1 -1
  136. package/.next-prod/server/app/api/redis/disconnect/route.js +1 -1
  137. package/.next-prod/server/app/api/redis/get/route.js +1 -1
  138. package/.next-prod/server/app/api/redis/keys/route.js +1 -1
  139. package/.next-prod/server/app/api/redis/set/route.js +1 -1
  140. package/.next-prod/server/app/api/restart/route.js +1 -1
  141. package/.next-prod/server/app/api/scheduled-tasks/route.js +2 -2
  142. package/.next-prod/server/app/api/services/config/route.js +1 -1
  143. package/.next-prod/server/app/api/services/scripts/route.js +1 -1
  144. package/.next-prod/server/app/api/session/[sessionId]/fork/route.js +1 -1
  145. package/.next-prod/server/app/api/session/[sessionId]/history/route.js +1 -1
  146. package/.next-prod/server/app/api/session/[sessionId]/turn/route.js +2 -2
  147. package/.next-prod/server/app/api/session/image/route.js +1 -1
  148. package/.next-prod/server/app/api/session/user-messages/route.js +1 -1
  149. package/.next-prod/server/app/api/session-bots/route.js +1 -1
  150. package/.next-prod/server/app/api/session-by-path/route.js +1 -1
  151. package/.next-prod/server/app/api/session-context/route.js +2 -2
  152. package/.next-prod/server/app/api/session-title/route.js +1 -1
  153. package/.next-prod/server/app/api/session-title/suggest/route.js +1 -1
  154. package/.next-prod/server/app/api/sessions/delegate/route.js +1 -1
  155. package/.next-prod/server/app/api/sessions/projects/[encodedPath]/route.js +1 -1
  156. package/.next-prod/server/app/api/sessions/projects/route.js +1 -1
  157. package/.next-prod/server/app/api/sessions/search/route.js +1 -1
  158. package/.next-prod/server/app/api/sessions/status/route.js +1 -1
  159. package/.next-prod/server/app/api/settings/route.js +1 -1
  160. package/.next-prod/server/app/api/shutdown/route.js +1 -1
  161. package/.next-prod/server/app/api/skills/[id]/route.js +1 -1
  162. package/.next-prod/server/app/api/skills/builtin/route.js +1 -1
  163. package/.next-prod/server/app/api/skills/content/route.js +1 -1
  164. package/.next-prod/server/app/api/skills/files/route.js +1 -1
  165. package/.next-prod/server/app/api/skills/route.js +1 -1
  166. package/.next-prod/server/app/api/snapshots/blob/route.js +1 -1
  167. package/.next-prod/server/app/api/snapshots/diff/route.js +1 -1
  168. package/.next-prod/server/app/api/snapshots/mark/route.js +1 -0
  169. package/.next-prod/server/app/api/snapshots/mark/route.js.nft.json +1 -0
  170. package/.next-prod/server/app/api/snapshots/mark/route_client-reference-manifest.js +1 -0
  171. package/.next-prod/server/app/api/snapshots/range-diff/route.js +1 -1
  172. package/.next-prod/server/app/api/snapshots/restore/route.js +1 -0
  173. package/.next-prod/server/app/api/snapshots/restore/route.js.nft.json +1 -0
  174. package/.next-prod/server/app/api/snapshots/restore/route_client-reference-manifest.js +1 -0
  175. package/.next-prod/server/app/api/snapshots/route.js +1 -1
  176. package/.next-prod/server/app/api/terminal/aliases/route.js +1 -1
  177. package/.next-prod/server/app/api/terminal/autocomplete/route.js +1 -1
  178. package/.next-prod/server/app/api/terminal/bubble-order/route.js +1 -1
  179. package/.next-prod/server/app/api/terminal/env/route.js +1 -1
  180. package/.next-prod/server/app/api/terminal/history/route.js +1 -1
  181. package/.next-prod/server/app/api/terminal/running/route.js +1 -1
  182. package/.next-prod/server/app/api/update/route.js +1 -1
  183. package/.next-prod/server/app/api/update-state/route.js +1 -1
  184. package/.next-prod/server/app/api/version/route.js +1 -1
  185. package/.next-prod/server/app/apps/[...path]/route.js +1 -1
  186. package/.next-prod/server/app/favicon.ico/route.js +1 -1
  187. package/.next-prod/server/app/m/page.js +2 -1
  188. package/.next-prod/server/app/m/page_client-reference-manifest.js +1 -1
  189. package/.next-prod/server/app/manifest.webmanifest/route.js +1 -1
  190. package/.next-prod/server/app/page.js +1 -1
  191. package/.next-prod/server/app/page_client-reference-manifest.js +1 -1
  192. package/.next-prod/server/app/project/page.js +1 -1
  193. package/.next-prod/server/app/project/page_client-reference-manifest.js +1 -1
  194. package/.next-prod/server/app-paths-manifest.json +9 -5
  195. package/.next-prod/server/chunks/2493.js +13 -13
  196. package/.next-prod/server/chunks/4949.js +1 -1
  197. package/.next-prod/server/chunks/6610.js +34 -34
  198. package/.next-prod/server/chunks/7270.js +1 -1
  199. package/.next-prod/server/chunks/9830.js +2 -2
  200. package/.next-prod/server/chunks/9998.js +1 -1
  201. package/.next-prod/server/middleware-build-manifest.js +1 -1
  202. package/.next-prod/server/next-font-manifest.js +1 -1
  203. package/.next-prod/server/next-font-manifest.json +1 -1
  204. package/.next-prod/server/pages/500.html +1 -1
  205. package/.next-prod/server/server-reference-manifest.json +1 -1
  206. package/.next-prod/static/LwAYWBEgXwTIkuj7U9BpE/_buildManifest.js +1 -0
  207. package/.next-prod/static/chunks/{50189-b59a96372658a46a.js → 55541-994b26deaa23f4e6.js} +2 -2
  208. package/.next-prod/static/chunks/{731-fd4b8bcd1d40dfe9.js → 6837-78c0d1a8165d46f7.js} +21 -21
  209. package/.next-prod/static/chunks/92000-46024df89fb50e16.js +41 -0
  210. package/.next-prod/static/chunks/98596-4ca2d2544138aefd.js +733 -0
  211. package/.next-prod/static/chunks/app/_global-error/page-6af5bc188af96106.js +1 -0
  212. package/.next-prod/static/chunks/app/api/agent/test/route-6af5bc188af96106.js +1 -0
  213. package/.next-prod/static/chunks/app/api/bash/route-6af5bc188af96106.js +1 -0
  214. package/.next-prod/static/chunks/app/api/bots/[id]/route-6af5bc188af96106.js +1 -0
  215. package/.next-prod/static/chunks/app/api/bots/files/route-6af5bc188af96106.js +1 -0
  216. package/.next-prod/static/chunks/app/api/bots/route-6af5bc188af96106.js +1 -0
  217. package/.next-prod/static/chunks/app/api/chat/codex/route-6af5bc188af96106.js +1 -0
  218. package/.next-prod/static/chunks/app/api/chat/deepseek/route-6af5bc188af96106.js +1 -0
  219. package/.next-prod/static/chunks/app/api/chat/glm/route-6af5bc188af96106.js +1 -0
  220. package/.next-prod/static/chunks/app/api/chat/grok/route-6af5bc188af96106.js +1 -0
  221. package/.next-prod/static/chunks/app/api/chat/kimi/route-6af5bc188af96106.js +1 -0
  222. package/.next-prod/static/chunks/app/api/chat/ollama/route-6af5bc188af96106.js +1 -0
  223. package/.next-prod/static/chunks/app/api/chat/route-6af5bc188af96106.js +1 -0
  224. package/.next-prod/static/chunks/app/api/chat/stop/route-6af5bc188af96106.js +1 -0
  225. package/.next-prod/static/chunks/app/api/claude-stats/route-6af5bc188af96106.js +1 -0
  226. package/.next-prod/static/chunks/app/api/commands/route-6af5bc188af96106.js +1 -0
  227. package/.next-prod/static/chunks/app/api/comments/route-6af5bc188af96106.js +1 -0
  228. package/.next-prod/static/chunks/app/api/db/columns/route-6af5bc188af96106.js +1 -0
  229. package/.next-prod/static/chunks/app/api/db/connect/route-6af5bc188af96106.js +1 -0
  230. package/.next-prod/static/chunks/app/api/db/disconnect/route-6af5bc188af96106.js +1 -0
  231. package/.next-prod/static/chunks/app/api/db/export/route-6af5bc188af96106.js +1 -0
  232. package/.next-prod/static/chunks/app/api/db/query/route-6af5bc188af96106.js +1 -0
  233. package/.next-prod/static/chunks/app/api/db/schemas/route-6af5bc188af96106.js +1 -0
  234. package/.next-prod/static/chunks/app/api/deepseek/balance/route-6af5bc188af96106.js +1 -0
  235. package/.next-prod/static/chunks/app/api/deepseek/credentials/route-6af5bc188af96106.js +1 -0
  236. package/.next-prod/static/chunks/app/api/deepseek/models/route-6af5bc188af96106.js +1 -0
  237. package/.next-prod/static/chunks/app/api/dev/spans/route-6af5bc188af96106.js +1 -0
  238. package/.next-prod/static/chunks/app/api/extension/version/route-6af5bc188af96106.js +1 -0
  239. package/.next-prod/static/chunks/app/api/file/route-6af5bc188af96106.js +1 -0
  240. package/.next-prod/static/chunks/app/api/files/blame/route-6af5bc188af96106.js +1 -0
  241. package/.next-prod/static/chunks/app/api/files/clipboard/route-6af5bc188af96106.js +1 -0
  242. package/.next-prod/static/chunks/app/api/files/copy/route-6af5bc188af96106.js +1 -0
  243. package/.next-prod/static/chunks/app/api/files/delete/route-6af5bc188af96106.js +1 -0
  244. package/.next-prod/static/chunks/app/api/files/expanded/route-6af5bc188af96106.js +1 -0
  245. package/.next-prod/static/chunks/app/api/files/index/route-6af5bc188af96106.js +1 -0
  246. package/.next-prod/static/chunks/app/api/files/init/route-6af5bc188af96106.js +1 -0
  247. package/.next-prod/static/chunks/app/api/files/paste/route-6af5bc188af96106.js +1 -0
  248. package/.next-prod/static/chunks/app/api/files/read/route-6af5bc188af96106.js +1 -0
  249. package/.next-prod/static/chunks/app/api/files/readdir/route-6af5bc188af96106.js +1 -0
  250. package/.next-prod/static/chunks/app/api/files/recent/route-6af5bc188af96106.js +1 -0
  251. package/.next-prod/static/chunks/app/api/files/save/route-6af5bc188af96106.js +1 -0
  252. package/.next-prod/static/chunks/app/api/files/search/route-6af5bc188af96106.js +1 -0
  253. package/.next-prod/static/chunks/app/api/files/stat/route-6af5bc188af96106.js +1 -0
  254. package/.next-prod/static/chunks/app/api/files/text/route-6af5bc188af96106.js +1 -0
  255. package/.next-prod/static/chunks/app/api/fs/dirs/route-6af5bc188af96106.js +1 -0
  256. package/.next-prod/static/chunks/app/api/git/blob/route-6af5bc188af96106.js +1 -0
  257. package/.next-prod/static/chunks/app/api/git/branch-diff/route-6af5bc188af96106.js +1 -0
  258. package/.next-prod/static/chunks/app/api/git/branches/route-6af5bc188af96106.js +1 -0
  259. package/.next-prod/static/chunks/app/api/git/commit-diff/route-6af5bc188af96106.js +1 -0
  260. package/.next-prod/static/chunks/app/api/git/commits/route-6af5bc188af96106.js +1 -0
  261. package/.next-prod/static/chunks/app/api/git/current-branch/route-6af5bc188af96106.js +1 -0
  262. package/.next-prod/static/chunks/app/api/git/diff/route-6af5bc188af96106.js +1 -0
  263. package/.next-prod/static/chunks/app/api/git/discard/route-6af5bc188af96106.js +1 -0
  264. package/.next-prod/static/chunks/app/api/git/stage/route-6af5bc188af96106.js +1 -0
  265. package/.next-prod/static/chunks/app/api/git/status/route-6af5bc188af96106.js +1 -0
  266. package/.next-prod/static/chunks/app/api/git/unstage/route-6af5bc188af96106.js +1 -0
  267. package/.next-prod/static/chunks/app/api/git/worktree/route-6af5bc188af96106.js +1 -0
  268. package/.next-prod/static/chunks/app/api/glm/credentials/route-6af5bc188af96106.js +1 -0
  269. package/.next-prod/static/chunks/app/api/glm/models/route-6af5bc188af96106.js +1 -0
  270. package/.next-prod/static/chunks/app/api/glm/usage/route-6af5bc188af96106.js +1 -0
  271. package/.next-prod/static/chunks/app/api/global-state/route-6af5bc188af96106.js +1 -0
  272. package/.next-prod/static/chunks/app/api/grok/models/route-6af5bc188af96106.js +1 -0
  273. package/.next-prod/static/chunks/app/api/health/route-6af5bc188af96106.js +1 -0
  274. package/.next-prod/static/chunks/app/api/html-apps/[id]/route-6af5bc188af96106.js +1 -0
  275. package/.next-prod/static/chunks/app/api/html-apps/files/route-6af5bc188af96106.js +1 -0
  276. package/.next-prod/static/chunks/app/api/html-apps/route-6af5bc188af96106.js +1 -0
  277. package/.next-prod/static/chunks/app/api/instructions/config/route-6af5bc188af96106.js +1 -0
  278. package/.next-prod/static/chunks/app/api/kimi/credentials/route-6af5bc188af96106.js +1 -0
  279. package/.next-prod/static/chunks/app/api/kimi/models/route-6af5bc188af96106.js +1 -0
  280. package/.next-prod/static/chunks/app/api/kimi/usage/route-6af5bc188af96106.js +1 -0
  281. package/.next-prod/static/chunks/app/api/lsp/definition/route-6af5bc188af96106.js +1 -0
  282. package/.next-prod/static/chunks/app/api/lsp/hover/route-6af5bc188af96106.js +1 -0
  283. package/.next-prod/static/chunks/app/api/lsp/references/route-6af5bc188af96106.js +1 -0
  284. package/.next-prod/static/chunks/app/api/lsp/status/route-6af5bc188af96106.js +1 -0
  285. package/.next-prod/static/chunks/app/api/lsp/warmup/route-6af5bc188af96106.js +1 -0
  286. package/.next-prod/static/chunks/app/api/mobile-link/route-6af5bc188af96106.js +1 -0
  287. package/.next-prod/static/chunks/app/api/mysql/columns/route-6af5bc188af96106.js +1 -0
  288. package/.next-prod/static/chunks/app/api/mysql/connect/route-6af5bc188af96106.js +1 -0
  289. package/.next-prod/static/chunks/app/api/mysql/disconnect/route-6af5bc188af96106.js +1 -0
  290. package/.next-prod/static/chunks/app/api/mysql/export/route-6af5bc188af96106.js +1 -0
  291. package/.next-prod/static/chunks/app/api/mysql/query/route-6af5bc188af96106.js +1 -0
  292. package/.next-prod/static/chunks/app/api/mysql/schemas/route-6af5bc188af96106.js +1 -0
  293. package/.next-prod/static/chunks/app/api/neo4j/connect/route-6af5bc188af96106.js +1 -0
  294. package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-6af5bc188af96106.js +1 -0
  295. package/.next-prod/static/chunks/app/api/neo4j/query/route-6af5bc188af96106.js +1 -0
  296. package/.next-prod/static/chunks/app/api/neo4j/schema/route-6af5bc188af96106.js +1 -0
  297. package/.next-prod/static/chunks/app/api/note/list/route-6af5bc188af96106.js +1 -0
  298. package/.next-prod/static/chunks/app/api/note/route-6af5bc188af96106.js +1 -0
  299. package/.next-prod/static/chunks/app/api/ollama/config/route-6af5bc188af96106.js +1 -0
  300. package/.next-prod/static/chunks/app/api/ollama/default-model/route-6af5bc188af96106.js +1 -0
  301. package/.next-prod/static/chunks/app/api/ollama/models/route-6af5bc188af96106.js +1 -0
  302. package/.next-prod/static/chunks/app/api/ollama/start/route-6af5bc188af96106.js +1 -0
  303. package/.next-prod/static/chunks/app/api/open-cursor/route-6af5bc188af96106.js +1 -0
  304. package/.next-prod/static/chunks/app/api/open-vscode/route-6af5bc188af96106.js +1 -0
  305. package/.next-prod/static/chunks/app/api/pi/thinking/route-6af5bc188af96106.js +1 -0
  306. package/.next-prod/static/chunks/app/api/pinned-sessions/route-6af5bc188af96106.js +1 -0
  307. package/.next-prod/static/chunks/app/api/project-settings/route-6af5bc188af96106.js +1 -0
  308. package/.next-prod/static/chunks/app/api/project-state/route-6af5bc188af96106.js +1 -0
  309. package/.next-prod/static/chunks/app/api/projectGraph/affected/route-6af5bc188af96106.js +1 -0
  310. package/.next-prod/static/chunks/app/api/projectGraph/callees/route-6af5bc188af96106.js +1 -0
  311. package/.next-prod/static/chunks/app/api/projectGraph/callers/route-6af5bc188af96106.js +1 -0
  312. package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-6af5bc188af96106.js +1 -0
  313. package/.next-prod/static/chunks/app/api/projectGraph/edges/route-6af5bc188af96106.js +1 -0
  314. package/.next-prod/static/chunks/app/api/projectGraph/file/route-6af5bc188af96106.js +1 -0
  315. package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-6af5bc188af96106.js +1 -0
  316. package/.next-prod/static/chunks/app/api/projectGraph/impact/route-6af5bc188af96106.js +1 -0
  317. package/.next-prod/static/chunks/app/api/projectGraph/maps/route-6af5bc188af96106.js +1 -0
  318. package/.next-prod/static/chunks/app/api/projectGraph/related/route-6af5bc188af96106.js +1 -0
  319. package/.next-prod/static/chunks/app/api/projectGraph/search/route-6af5bc188af96106.js +1 -0
  320. package/.next-prod/static/chunks/app/api/projectGraph/symbols/route-6af5bc188af96106.js +1 -0
  321. package/.next-prod/static/chunks/app/api/projects/route-6af5bc188af96106.js +1 -0
  322. package/.next-prod/static/chunks/app/api/push/public-key/route-6af5bc188af96106.js +1 -0
  323. package/.next-prod/static/chunks/app/api/push/subscribe/route-6af5bc188af96106.js +1 -0
  324. package/.next-prod/static/chunks/app/api/push/unsubscribe/route-6af5bc188af96106.js +1 -0
  325. package/.next-prod/static/chunks/app/api/redis/command/route-6af5bc188af96106.js +1 -0
  326. package/.next-prod/static/chunks/app/api/redis/connect/route-6af5bc188af96106.js +1 -0
  327. package/.next-prod/static/chunks/app/api/redis/delete/route-6af5bc188af96106.js +1 -0
  328. package/.next-prod/static/chunks/app/api/redis/disconnect/route-6af5bc188af96106.js +1 -0
  329. package/.next-prod/static/chunks/app/api/redis/get/route-6af5bc188af96106.js +1 -0
  330. package/.next-prod/static/chunks/app/api/redis/keys/route-6af5bc188af96106.js +1 -0
  331. package/.next-prod/static/chunks/app/api/redis/set/route-6af5bc188af96106.js +1 -0
  332. package/.next-prod/static/chunks/app/api/restart/route-6af5bc188af96106.js +1 -0
  333. package/.next-prod/static/chunks/app/api/scheduled-tasks/route-6af5bc188af96106.js +1 -0
  334. package/.next-prod/static/chunks/app/api/services/config/route-6af5bc188af96106.js +1 -0
  335. package/.next-prod/static/chunks/app/api/services/scripts/route-6af5bc188af96106.js +1 -0
  336. package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-6af5bc188af96106.js +1 -0
  337. package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-6af5bc188af96106.js +1 -0
  338. package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-6af5bc188af96106.js +1 -0
  339. package/.next-prod/static/chunks/app/api/session/image/route-6af5bc188af96106.js +1 -0
  340. package/.next-prod/static/chunks/app/api/session/user-messages/route-6af5bc188af96106.js +1 -0
  341. package/.next-prod/static/chunks/app/api/session-bots/route-6af5bc188af96106.js +1 -0
  342. package/.next-prod/static/chunks/app/api/session-by-path/route-6af5bc188af96106.js +1 -0
  343. package/.next-prod/static/chunks/app/api/session-context/route-6af5bc188af96106.js +1 -0
  344. package/.next-prod/static/chunks/app/api/session-title/route-6af5bc188af96106.js +1 -0
  345. package/.next-prod/static/chunks/app/api/session-title/suggest/route-6af5bc188af96106.js +1 -0
  346. package/.next-prod/static/chunks/app/api/sessions/delegate/route-6af5bc188af96106.js +1 -0
  347. package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-6af5bc188af96106.js +1 -0
  348. package/.next-prod/static/chunks/app/api/sessions/projects/route-6af5bc188af96106.js +1 -0
  349. package/.next-prod/static/chunks/app/api/sessions/search/route-6af5bc188af96106.js +1 -0
  350. package/.next-prod/static/chunks/app/api/sessions/status/route-6af5bc188af96106.js +1 -0
  351. package/.next-prod/static/chunks/app/api/settings/route-6af5bc188af96106.js +1 -0
  352. package/.next-prod/static/chunks/app/api/shutdown/route-6af5bc188af96106.js +1 -0
  353. package/.next-prod/static/chunks/app/api/skills/[id]/route-6af5bc188af96106.js +1 -0
  354. package/.next-prod/static/chunks/app/api/skills/builtin/route-6af5bc188af96106.js +1 -0
  355. package/.next-prod/static/chunks/app/api/skills/content/route-6af5bc188af96106.js +1 -0
  356. package/.next-prod/static/chunks/app/api/skills/files/route-6af5bc188af96106.js +1 -0
  357. package/.next-prod/static/chunks/app/api/skills/route-6af5bc188af96106.js +1 -0
  358. package/.next-prod/static/chunks/app/api/snapshots/blob/route-6af5bc188af96106.js +1 -0
  359. package/.next-prod/static/chunks/app/api/snapshots/diff/route-6af5bc188af96106.js +1 -0
  360. package/.next-prod/static/chunks/app/api/snapshots/mark/route-6af5bc188af96106.js +1 -0
  361. package/.next-prod/static/chunks/app/api/snapshots/range-diff/route-6af5bc188af96106.js +1 -0
  362. package/.next-prod/static/chunks/app/api/snapshots/restore/route-6af5bc188af96106.js +1 -0
  363. package/.next-prod/static/chunks/app/api/snapshots/route-6af5bc188af96106.js +1 -0
  364. package/.next-prod/static/chunks/app/api/terminal/aliases/route-6af5bc188af96106.js +1 -0
  365. package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-6af5bc188af96106.js +1 -0
  366. package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-6af5bc188af96106.js +1 -0
  367. package/.next-prod/static/chunks/app/api/terminal/env/route-6af5bc188af96106.js +1 -0
  368. package/.next-prod/static/chunks/app/api/terminal/history/route-6af5bc188af96106.js +1 -0
  369. package/.next-prod/static/chunks/app/api/terminal/running/route-6af5bc188af96106.js +1 -0
  370. package/.next-prod/static/chunks/app/api/update/route-6af5bc188af96106.js +1 -0
  371. package/.next-prod/static/chunks/app/api/update-state/route-6af5bc188af96106.js +1 -0
  372. package/.next-prod/static/chunks/app/api/version/route-6af5bc188af96106.js +1 -0
  373. package/.next-prod/static/chunks/app/apps/[...path]/route-6af5bc188af96106.js +1 -0
  374. package/.next-prod/static/chunks/app/{layout-f0ff0ab277c84dc6.js → layout-7107ed4eeac1f693.js} +1 -1
  375. package/.next-prod/static/chunks/app/m/page-0c8e79e2f753aecb.js +2 -0
  376. package/.next-prod/static/chunks/app/manifest.webmanifest/route-6af5bc188af96106.js +1 -0
  377. package/.next-prod/static/chunks/app/{page-d2ccfc2cb47ac4af.js → page-338a2c84319778b1.js} +1 -1
  378. package/.next-prod/static/chunks/app/project/{page-d2ccfc2cb47ac4af.js → page-338a2c84319778b1.js} +1 -1
  379. package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-6af5bc188af96106.js +1 -0
  380. package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-6af5bc188af96106.js +1 -0
  381. package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-6af5bc188af96106.js +1 -0
  382. package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-6af5bc188af96106.js +1 -0
  383. package/.next-prod/static/css/fa34d3b1412ca27a.css +1 -0
  384. package/.next-prod/trace +86 -15
  385. package/.next-prod/trace-build +1 -1
  386. package/.next-prod/types/app/api/projectGraph/edges/route.ts +353 -0
  387. package/.next-prod/types/app/api/projectGraph/maps/route.ts +353 -0
  388. package/.next-prod/types/app/api/snapshots/mark/route.ts +353 -0
  389. package/.next-prod/types/app/api/snapshots/restore/route.ts +353 -0
  390. package/.next-prod/types/routes.d.ts +5 -1
  391. package/.next-prod/types/validator.ts +36 -0
  392. package/README.md +6 -0
  393. package/bin/rotateLog.mjs +6 -5
  394. package/desktop-checksums.json +4 -4
  395. package/dist/{anthropicCompat-PQWSZ3O7.mjs → anthropicCompat-4HZVLIFE.mjs} +3 -2
  396. package/dist/auth.mjs +19 -3
  397. package/dist/authAudit.mjs +79 -0
  398. package/dist/{chunk-6QDJ3QAX.mjs → chunk-6QHHEA3D.mjs} +11 -9
  399. package/dist/{chunk-2PDNZOMA.mjs → chunk-HJT5ZRYY.mjs} +2 -2
  400. package/dist/{chunk-S7FDWHAF.mjs → chunk-LSFNZJMR.mjs} +26825 -29730
  401. package/dist/{chunk-3S5JGONK.mjs → chunk-N3DTLFZE.mjs} +14 -12
  402. package/dist/{chunk-AKBWZB3V.mjs → chunk-QPFJKR3B.mjs} +2 -2
  403. package/dist/{chunk-LQISLDJ5.mjs → chunk-SI632CNY.mjs} +1 -1
  404. package/dist/{chunk-G747UZSS.mjs → chunk-T4M6CNFO.mjs} +132 -34
  405. package/dist/chunk-WSSVELJX.mjs +2920 -0
  406. package/dist/{chunk-2O6IH2TF.mjs → chunk-X4R5HO25.mjs} +2 -2
  407. package/dist/deepseek-YEPNQ2GX.mjs +13 -0
  408. package/dist/glm-SGT2LTOS.mjs +15 -0
  409. package/dist/httpApi.mjs +9 -8
  410. package/dist/kimi-FDXILCYU.mjs +15 -0
  411. package/dist/scheduledTasks.mjs +41 -15
  412. package/dist/{sessionStore-FF2VHKXM.mjs → sessionStore-WJGMZM4A.mjs} +2 -1
  413. package/dist/wsServer.mjs +63 -26
  414. package/package.json +3 -3
  415. package/public/html-lib/markdown.js +1 -1
  416. package/server.mjs +6 -1
  417. package/skills/cr/SKILL.md +184 -11
  418. package/skills/dl/SKILL.md +5 -0
  419. package/skills/rf/SKILL.md +124 -0
  420. package/skills/rf/axes.md +87 -0
  421. package/skills/rf/converge.md +50 -0
  422. package/skills/rf/fix.md +138 -0
  423. package/skills/rf/lenses.md +76 -0
  424. package/skills/rf/report.md +133 -0
  425. package/skills/rf/sources.md +129 -0
  426. package/.next-prod/static/AO-RPvB4uxOb6-XZ_0YXg/_buildManifest.js +0 -1
  427. package/.next-prod/static/chunks/17220-89a26ee102272095.js +0 -732
  428. package/.next-prod/static/chunks/45590-d1a8b4e539cc8dda.js +0 -42
  429. package/.next-prod/static/chunks/app/_global-error/page-42efcb4fd08c5099.js +0 -1
  430. package/.next-prod/static/chunks/app/api/agent/test/route-42efcb4fd08c5099.js +0 -1
  431. package/.next-prod/static/chunks/app/api/bash/route-42efcb4fd08c5099.js +0 -1
  432. package/.next-prod/static/chunks/app/api/bots/[id]/route-42efcb4fd08c5099.js +0 -1
  433. package/.next-prod/static/chunks/app/api/bots/files/route-42efcb4fd08c5099.js +0 -1
  434. package/.next-prod/static/chunks/app/api/bots/route-42efcb4fd08c5099.js +0 -1
  435. package/.next-prod/static/chunks/app/api/chat/codex/route-42efcb4fd08c5099.js +0 -1
  436. package/.next-prod/static/chunks/app/api/chat/deepseek/route-42efcb4fd08c5099.js +0 -1
  437. package/.next-prod/static/chunks/app/api/chat/glm/route-42efcb4fd08c5099.js +0 -1
  438. package/.next-prod/static/chunks/app/api/chat/grok/route-42efcb4fd08c5099.js +0 -1
  439. package/.next-prod/static/chunks/app/api/chat/kimi/route-42efcb4fd08c5099.js +0 -1
  440. package/.next-prod/static/chunks/app/api/chat/ollama/route-42efcb4fd08c5099.js +0 -1
  441. package/.next-prod/static/chunks/app/api/chat/route-42efcb4fd08c5099.js +0 -1
  442. package/.next-prod/static/chunks/app/api/chat/stop/route-42efcb4fd08c5099.js +0 -1
  443. package/.next-prod/static/chunks/app/api/claude-stats/route-42efcb4fd08c5099.js +0 -1
  444. package/.next-prod/static/chunks/app/api/commands/route-42efcb4fd08c5099.js +0 -1
  445. package/.next-prod/static/chunks/app/api/comments/route-42efcb4fd08c5099.js +0 -1
  446. package/.next-prod/static/chunks/app/api/db/columns/route-42efcb4fd08c5099.js +0 -1
  447. package/.next-prod/static/chunks/app/api/db/connect/route-42efcb4fd08c5099.js +0 -1
  448. package/.next-prod/static/chunks/app/api/db/disconnect/route-42efcb4fd08c5099.js +0 -1
  449. package/.next-prod/static/chunks/app/api/db/export/route-42efcb4fd08c5099.js +0 -1
  450. package/.next-prod/static/chunks/app/api/db/query/route-42efcb4fd08c5099.js +0 -1
  451. package/.next-prod/static/chunks/app/api/db/schemas/route-42efcb4fd08c5099.js +0 -1
  452. package/.next-prod/static/chunks/app/api/deepseek/balance/route-42efcb4fd08c5099.js +0 -1
  453. package/.next-prod/static/chunks/app/api/deepseek/credentials/route-42efcb4fd08c5099.js +0 -1
  454. package/.next-prod/static/chunks/app/api/deepseek/models/route-42efcb4fd08c5099.js +0 -1
  455. package/.next-prod/static/chunks/app/api/dev/spans/route-42efcb4fd08c5099.js +0 -1
  456. package/.next-prod/static/chunks/app/api/extension/version/route-42efcb4fd08c5099.js +0 -1
  457. package/.next-prod/static/chunks/app/api/file/route-42efcb4fd08c5099.js +0 -1
  458. package/.next-prod/static/chunks/app/api/files/blame/route-42efcb4fd08c5099.js +0 -1
  459. package/.next-prod/static/chunks/app/api/files/clipboard/route-42efcb4fd08c5099.js +0 -1
  460. package/.next-prod/static/chunks/app/api/files/copy/route-42efcb4fd08c5099.js +0 -1
  461. package/.next-prod/static/chunks/app/api/files/delete/route-42efcb4fd08c5099.js +0 -1
  462. package/.next-prod/static/chunks/app/api/files/expanded/route-42efcb4fd08c5099.js +0 -1
  463. package/.next-prod/static/chunks/app/api/files/index/route-42efcb4fd08c5099.js +0 -1
  464. package/.next-prod/static/chunks/app/api/files/init/route-42efcb4fd08c5099.js +0 -1
  465. package/.next-prod/static/chunks/app/api/files/paste/route-42efcb4fd08c5099.js +0 -1
  466. package/.next-prod/static/chunks/app/api/files/read/route-42efcb4fd08c5099.js +0 -1
  467. package/.next-prod/static/chunks/app/api/files/readdir/route-42efcb4fd08c5099.js +0 -1
  468. package/.next-prod/static/chunks/app/api/files/recent/route-42efcb4fd08c5099.js +0 -1
  469. package/.next-prod/static/chunks/app/api/files/save/route-42efcb4fd08c5099.js +0 -1
  470. package/.next-prod/static/chunks/app/api/files/search/route-42efcb4fd08c5099.js +0 -1
  471. package/.next-prod/static/chunks/app/api/files/stat/route-42efcb4fd08c5099.js +0 -1
  472. package/.next-prod/static/chunks/app/api/files/text/route-42efcb4fd08c5099.js +0 -1
  473. package/.next-prod/static/chunks/app/api/fs/dirs/route-42efcb4fd08c5099.js +0 -1
  474. package/.next-prod/static/chunks/app/api/git/blob/route-42efcb4fd08c5099.js +0 -1
  475. package/.next-prod/static/chunks/app/api/git/branch-diff/route-42efcb4fd08c5099.js +0 -1
  476. package/.next-prod/static/chunks/app/api/git/branches/route-42efcb4fd08c5099.js +0 -1
  477. package/.next-prod/static/chunks/app/api/git/commit-diff/route-42efcb4fd08c5099.js +0 -1
  478. package/.next-prod/static/chunks/app/api/git/commits/route-42efcb4fd08c5099.js +0 -1
  479. package/.next-prod/static/chunks/app/api/git/current-branch/route-42efcb4fd08c5099.js +0 -1
  480. package/.next-prod/static/chunks/app/api/git/diff/route-42efcb4fd08c5099.js +0 -1
  481. package/.next-prod/static/chunks/app/api/git/discard/route-42efcb4fd08c5099.js +0 -1
  482. package/.next-prod/static/chunks/app/api/git/stage/route-42efcb4fd08c5099.js +0 -1
  483. package/.next-prod/static/chunks/app/api/git/status/route-42efcb4fd08c5099.js +0 -1
  484. package/.next-prod/static/chunks/app/api/git/unstage/route-42efcb4fd08c5099.js +0 -1
  485. package/.next-prod/static/chunks/app/api/git/worktree/route-42efcb4fd08c5099.js +0 -1
  486. package/.next-prod/static/chunks/app/api/glm/credentials/route-42efcb4fd08c5099.js +0 -1
  487. package/.next-prod/static/chunks/app/api/glm/models/route-42efcb4fd08c5099.js +0 -1
  488. package/.next-prod/static/chunks/app/api/glm/usage/route-42efcb4fd08c5099.js +0 -1
  489. package/.next-prod/static/chunks/app/api/global-state/route-42efcb4fd08c5099.js +0 -1
  490. package/.next-prod/static/chunks/app/api/grok/models/route-42efcb4fd08c5099.js +0 -1
  491. package/.next-prod/static/chunks/app/api/health/route-42efcb4fd08c5099.js +0 -1
  492. package/.next-prod/static/chunks/app/api/html-apps/[id]/route-42efcb4fd08c5099.js +0 -1
  493. package/.next-prod/static/chunks/app/api/html-apps/files/route-42efcb4fd08c5099.js +0 -1
  494. package/.next-prod/static/chunks/app/api/html-apps/route-42efcb4fd08c5099.js +0 -1
  495. package/.next-prod/static/chunks/app/api/instructions/config/route-42efcb4fd08c5099.js +0 -1
  496. package/.next-prod/static/chunks/app/api/kimi/credentials/route-42efcb4fd08c5099.js +0 -1
  497. package/.next-prod/static/chunks/app/api/kimi/models/route-42efcb4fd08c5099.js +0 -1
  498. package/.next-prod/static/chunks/app/api/kimi/usage/route-42efcb4fd08c5099.js +0 -1
  499. package/.next-prod/static/chunks/app/api/lsp/definition/route-42efcb4fd08c5099.js +0 -1
  500. package/.next-prod/static/chunks/app/api/lsp/hover/route-42efcb4fd08c5099.js +0 -1
  501. package/.next-prod/static/chunks/app/api/lsp/references/route-42efcb4fd08c5099.js +0 -1
  502. package/.next-prod/static/chunks/app/api/lsp/status/route-42efcb4fd08c5099.js +0 -1
  503. package/.next-prod/static/chunks/app/api/lsp/warmup/route-42efcb4fd08c5099.js +0 -1
  504. package/.next-prod/static/chunks/app/api/mobile-link/route-42efcb4fd08c5099.js +0 -1
  505. package/.next-prod/static/chunks/app/api/mysql/columns/route-42efcb4fd08c5099.js +0 -1
  506. package/.next-prod/static/chunks/app/api/mysql/connect/route-42efcb4fd08c5099.js +0 -1
  507. package/.next-prod/static/chunks/app/api/mysql/disconnect/route-42efcb4fd08c5099.js +0 -1
  508. package/.next-prod/static/chunks/app/api/mysql/export/route-42efcb4fd08c5099.js +0 -1
  509. package/.next-prod/static/chunks/app/api/mysql/query/route-42efcb4fd08c5099.js +0 -1
  510. package/.next-prod/static/chunks/app/api/mysql/schemas/route-42efcb4fd08c5099.js +0 -1
  511. package/.next-prod/static/chunks/app/api/neo4j/connect/route-42efcb4fd08c5099.js +0 -1
  512. package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-42efcb4fd08c5099.js +0 -1
  513. package/.next-prod/static/chunks/app/api/neo4j/query/route-42efcb4fd08c5099.js +0 -1
  514. package/.next-prod/static/chunks/app/api/neo4j/schema/route-42efcb4fd08c5099.js +0 -1
  515. package/.next-prod/static/chunks/app/api/note/list/route-42efcb4fd08c5099.js +0 -1
  516. package/.next-prod/static/chunks/app/api/note/route-42efcb4fd08c5099.js +0 -1
  517. package/.next-prod/static/chunks/app/api/ollama/config/route-42efcb4fd08c5099.js +0 -1
  518. package/.next-prod/static/chunks/app/api/ollama/default-model/route-42efcb4fd08c5099.js +0 -1
  519. package/.next-prod/static/chunks/app/api/ollama/models/route-42efcb4fd08c5099.js +0 -1
  520. package/.next-prod/static/chunks/app/api/ollama/start/route-42efcb4fd08c5099.js +0 -1
  521. package/.next-prod/static/chunks/app/api/open-cursor/route-42efcb4fd08c5099.js +0 -1
  522. package/.next-prod/static/chunks/app/api/open-vscode/route-42efcb4fd08c5099.js +0 -1
  523. package/.next-prod/static/chunks/app/api/pi/thinking/route-42efcb4fd08c5099.js +0 -1
  524. package/.next-prod/static/chunks/app/api/pinned-sessions/route-42efcb4fd08c5099.js +0 -1
  525. package/.next-prod/static/chunks/app/api/project-settings/route-42efcb4fd08c5099.js +0 -1
  526. package/.next-prod/static/chunks/app/api/project-state/route-42efcb4fd08c5099.js +0 -1
  527. package/.next-prod/static/chunks/app/api/projectGraph/affected/route-42efcb4fd08c5099.js +0 -1
  528. package/.next-prod/static/chunks/app/api/projectGraph/callees/route-42efcb4fd08c5099.js +0 -1
  529. package/.next-prod/static/chunks/app/api/projectGraph/callers/route-42efcb4fd08c5099.js +0 -1
  530. package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-42efcb4fd08c5099.js +0 -1
  531. package/.next-prod/static/chunks/app/api/projectGraph/file/route-42efcb4fd08c5099.js +0 -1
  532. package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-42efcb4fd08c5099.js +0 -1
  533. package/.next-prod/static/chunks/app/api/projectGraph/impact/route-42efcb4fd08c5099.js +0 -1
  534. package/.next-prod/static/chunks/app/api/projectGraph/related/route-42efcb4fd08c5099.js +0 -1
  535. package/.next-prod/static/chunks/app/api/projectGraph/search/route-42efcb4fd08c5099.js +0 -1
  536. package/.next-prod/static/chunks/app/api/projectGraph/symbols/route-42efcb4fd08c5099.js +0 -1
  537. package/.next-prod/static/chunks/app/api/projects/route-42efcb4fd08c5099.js +0 -1
  538. package/.next-prod/static/chunks/app/api/push/public-key/route-42efcb4fd08c5099.js +0 -1
  539. package/.next-prod/static/chunks/app/api/push/subscribe/route-42efcb4fd08c5099.js +0 -1
  540. package/.next-prod/static/chunks/app/api/push/unsubscribe/route-42efcb4fd08c5099.js +0 -1
  541. package/.next-prod/static/chunks/app/api/redis/command/route-42efcb4fd08c5099.js +0 -1
  542. package/.next-prod/static/chunks/app/api/redis/connect/route-42efcb4fd08c5099.js +0 -1
  543. package/.next-prod/static/chunks/app/api/redis/delete/route-42efcb4fd08c5099.js +0 -1
  544. package/.next-prod/static/chunks/app/api/redis/disconnect/route-42efcb4fd08c5099.js +0 -1
  545. package/.next-prod/static/chunks/app/api/redis/get/route-42efcb4fd08c5099.js +0 -1
  546. package/.next-prod/static/chunks/app/api/redis/keys/route-42efcb4fd08c5099.js +0 -1
  547. package/.next-prod/static/chunks/app/api/redis/set/route-42efcb4fd08c5099.js +0 -1
  548. package/.next-prod/static/chunks/app/api/restart/route-42efcb4fd08c5099.js +0 -1
  549. package/.next-prod/static/chunks/app/api/scheduled-tasks/route-42efcb4fd08c5099.js +0 -1
  550. package/.next-prod/static/chunks/app/api/services/config/route-42efcb4fd08c5099.js +0 -1
  551. package/.next-prod/static/chunks/app/api/services/scripts/route-42efcb4fd08c5099.js +0 -1
  552. package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-42efcb4fd08c5099.js +0 -1
  553. package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-42efcb4fd08c5099.js +0 -1
  554. package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-42efcb4fd08c5099.js +0 -1
  555. package/.next-prod/static/chunks/app/api/session/image/route-42efcb4fd08c5099.js +0 -1
  556. package/.next-prod/static/chunks/app/api/session/user-messages/route-42efcb4fd08c5099.js +0 -1
  557. package/.next-prod/static/chunks/app/api/session-bots/route-42efcb4fd08c5099.js +0 -1
  558. package/.next-prod/static/chunks/app/api/session-by-path/route-42efcb4fd08c5099.js +0 -1
  559. package/.next-prod/static/chunks/app/api/session-context/route-42efcb4fd08c5099.js +0 -1
  560. package/.next-prod/static/chunks/app/api/session-title/route-42efcb4fd08c5099.js +0 -1
  561. package/.next-prod/static/chunks/app/api/session-title/suggest/route-42efcb4fd08c5099.js +0 -1
  562. package/.next-prod/static/chunks/app/api/sessions/delegate/route-42efcb4fd08c5099.js +0 -1
  563. package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-42efcb4fd08c5099.js +0 -1
  564. package/.next-prod/static/chunks/app/api/sessions/projects/route-42efcb4fd08c5099.js +0 -1
  565. package/.next-prod/static/chunks/app/api/sessions/search/route-42efcb4fd08c5099.js +0 -1
  566. package/.next-prod/static/chunks/app/api/sessions/status/route-42efcb4fd08c5099.js +0 -1
  567. package/.next-prod/static/chunks/app/api/settings/route-42efcb4fd08c5099.js +0 -1
  568. package/.next-prod/static/chunks/app/api/shutdown/route-42efcb4fd08c5099.js +0 -1
  569. package/.next-prod/static/chunks/app/api/skills/[id]/route-42efcb4fd08c5099.js +0 -1
  570. package/.next-prod/static/chunks/app/api/skills/builtin/route-42efcb4fd08c5099.js +0 -1
  571. package/.next-prod/static/chunks/app/api/skills/content/route-42efcb4fd08c5099.js +0 -1
  572. package/.next-prod/static/chunks/app/api/skills/files/route-42efcb4fd08c5099.js +0 -1
  573. package/.next-prod/static/chunks/app/api/skills/route-42efcb4fd08c5099.js +0 -1
  574. package/.next-prod/static/chunks/app/api/snapshots/blob/route-42efcb4fd08c5099.js +0 -1
  575. package/.next-prod/static/chunks/app/api/snapshots/diff/route-42efcb4fd08c5099.js +0 -1
  576. package/.next-prod/static/chunks/app/api/snapshots/range-diff/route-42efcb4fd08c5099.js +0 -1
  577. package/.next-prod/static/chunks/app/api/snapshots/route-42efcb4fd08c5099.js +0 -1
  578. package/.next-prod/static/chunks/app/api/terminal/aliases/route-42efcb4fd08c5099.js +0 -1
  579. package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-42efcb4fd08c5099.js +0 -1
  580. package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-42efcb4fd08c5099.js +0 -1
  581. package/.next-prod/static/chunks/app/api/terminal/env/route-42efcb4fd08c5099.js +0 -1
  582. package/.next-prod/static/chunks/app/api/terminal/history/route-42efcb4fd08c5099.js +0 -1
  583. package/.next-prod/static/chunks/app/api/terminal/running/route-42efcb4fd08c5099.js +0 -1
  584. package/.next-prod/static/chunks/app/api/update/route-42efcb4fd08c5099.js +0 -1
  585. package/.next-prod/static/chunks/app/api/update-state/route-42efcb4fd08c5099.js +0 -1
  586. package/.next-prod/static/chunks/app/api/version/route-42efcb4fd08c5099.js +0 -1
  587. package/.next-prod/static/chunks/app/apps/[...path]/route-42efcb4fd08c5099.js +0 -1
  588. package/.next-prod/static/chunks/app/m/page-50e48b4ba0942454.js +0 -1
  589. package/.next-prod/static/chunks/app/manifest.webmanifest/route-42efcb4fd08c5099.js +0 -1
  590. package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-42efcb4fd08c5099.js +0 -1
  591. package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-42efcb4fd08c5099.js +0 -1
  592. package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-42efcb4fd08c5099.js +0 -1
  593. package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-42efcb4fd08c5099.js +0 -1
  594. package/.next-prod/static/css/74144fec62c7ff43.css +0 -1
  595. package/dist/deepseek-5QJ2IWS3.mjs +0 -12
  596. package/dist/glm-SIOUQCWL.mjs +0 -14
  597. package/dist/kimi-NKL4WBNS.mjs +0 -14
  598. /package/.next-prod/static/{AO-RPvB4uxOb6-XZ_0YXg → LwAYWBEgXwTIkuj7U9BpE}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- "use strict";exports.id=4949,exports.ids=[4949],exports.modules={4410:(a,b,c)=>{c.d(b,{Bu:()=>d.Bu,iv:()=>d.iv});var d=c(28677),e=c(76760),f=c.n(e),g=c(83624),h=c(56476);function i(a){let b=[];function c(a){if(!a||"string"!==a.type)return null;for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);if(c&&"string_fragment"===c.type)return c.text}return""}return!function a(d){switch(d.type){case"import_statement":case"export_statement":{let a=c(d.childForFieldName("source"));a&&b.push(a);return}case"call_expression":{let a=d.childForFieldName("function");if(a){let e="import"===a.type,f="identifier"===a.type&&"require"===a.text;if(e||f){let a=d.childForFieldName("arguments");if(a&&a.namedChildCount>0){let d=c(a.namedChild(0));d&&b.push(d)}}}}}for(let b=0;b<d.namedChildCount;b++){let c=d.namedChild(b);c&&a(c)}}(a),b}let j={typescript:i,tsx:i,javascript:i,python:function(a){let b=[];return!function a(c){switch(c.type){case"import_statement":for(let a=0;a<c.childCount;a++){let d=c.child(a);if(d&&"name"===c.fieldNameForChild(a)){if("dotted_name"===d.type)b.push(d.text);else if("aliased_import"===d.type){let a=d.childForFieldName("name");a?.type==="dotted_name"&&b.push(a.text)}}}return;case"import_from_statement":{let a=function(a){let b=a.childForFieldName("module_name");if(!b)return"";if("dotted_name"===b.type)return b.text;if("relative_import"===b.type){let a="",c="";for(let d=0;d<b.namedChildCount;d++){let e=b.namedChild(d);e&&("import_prefix"===e.type?a=e.text:"dotted_name"===e.type&&(c=e.text))}return a+c}return""}(c);a&&b.push(a);return}}for(let b=0;b<c.namedChildCount;b++){let d=c.namedChild(b);d&&a(d)}}(a),b}};function k(a,b){let c=j[b];return c?c(a):[]}var l=c(25344);function m(a){return"function"===a||"class"===a||"method"===a}function n(a,b,c,d,e){let f=JSON.stringify([a.path,b]);if(c>5||d.has(f))return null;let g=new Set(d).add(f),h=(b,d)=>{let f=a.resolvedImports.get(b.specifier),h=f&&e.get(f);return h?n(h,d,c+1,g,e):null},i=a.reexportsByLocalName.get(b);if(i&&"*"!==b){if(i.specifier)return h(i,i.importedName);let b=a.symbolsByName.get(i.importedName),c=null;for(let a of b??[])!a.qualifiedName.includes(">")&&(!c||m(a.kind)&&!m(c.kind)||a.kind===c.kind&&a.endLine-a.startLine>c.endLine-c.startLine)&&(c=a);if(c)return c;let d=a.bindingsByLocalName.get(i.importedName);return d?h(d,d.importedName):null}if("default"===b)return null;let j=null;for(let c of a.importBindings){if(!c.isReexport||"*"!==c.localName||"*"!==c.importedName)continue;let a=h(c,b);if("ambiguous"===a)return a;if(a){if(j&&(j.filePath!==a.filePath||j.qualifiedName!==a.qualifiedName))return"ambiguous";j=a}}return j}function o(a,b){return{grammarId:a,extensions:b,extractSymbols:(a,b)=>(0,g.Hs)(a),extractImports:b=>({specs:k(b,a),bindings:[...(0,h.jv)(b),...(0,h.il)(b)]}),extractCallSites:(a,b)=>(0,h.Lv)(a),async buildProjectContext(a,b,c){let d=new Set(b),e=await (0,l.ZT)(a,c),f=await (0,l.zC)(a,d,c),g=[...f.keys()].sort((a,b)=>b.length-a.length);return{cwd:a,tsconfigs:e,workspaces:f,sortedWsNames:g,owningScopesCache:new Map}},resolveSpecifier(a,b,c,d){let e=c.owningScopesCache.get(b);if(e||(e=c.tsconfigs.filter(a=>(0,l._0)(b,a.scope)),c.owningScopesCache.set(b,e)),a.startsWith("./")||a.startsWith("../"))return(0,l.KP)(f().resolve(c.cwd,f().dirname(b),a),c.cwd,d);if(a.startsWith("/"))return(0,l.KP)(f().resolve(c.cwd,a.slice(1)),c.cwd,d);for(let b of e){let e=b.sortedAliases.find(([b])=>a===b||a.startsWith(b+"/"));if(!e)continue;let[g,h]=e,i=a===g?"":a.slice(g.length+1),j=(0,l.KP)(f().resolve(c.cwd,h,i),c.cwd,d);if(j)return j}for(let b of c.sortedWsNames){if(a!==b&&!a.startsWith(b+"/"))continue;let e=c.workspaces.get(b);if(a===b)return e.entryFile;let g=a.slice(b.length+1);return(0,l.IS)(f().posix.join(e.dir,g),d)??(0,l.IS)(f().posix.join(e.dir,"src",g),d)}return null},resolveCall(a,b,c,d,e){if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(!b)return[];let e=c.resolvedImports.get(b.specifier);if(!e)return[];let f=d.get(e);if(!f)return[];let g=function a(b,c,d,e,f,g){if(e>5)return null;if("*"===c){let a=n(b,d,e,f,g);return a&&"ambiguous"!==a&&m(a.kind)?a:null}let h=JSON.stringify([b.path,c,d]);if(f.has(h))return null;let i=new Set(f).add(h),j=b.reexportsByLocalName.get(c);if(j?.specifier&&"*"===j.importedName){let c=b.resolvedImports.get(j.specifier),f=c&&g.get(c);return f?a(f,"*",d,e+1,i,g):null}let k=n(b,c,e,i,g);if(!k||"ambiguous"===k)return null;let l=g.get(k.filePath),o=l?.symbolsByQname.get(`${k.qualifiedName}>${d}`);return o&&m(o.kind)?o:null}(f,b.importedName,a.calleeName,0,new Set,d);return g?[{kind:"symbol",addr:{filePath:g.filePath,qualifiedName:g.qualifiedName}}]:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let f=c.symbolsByName.get(a.calleeName);if(f&&f.length>0){let a=[];for(let c of f)c.qualifiedName!==b.qualifiedName&&m(c.kind)&&a.push({kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}});return a}let g=c.bindingsByLocalName.get(a.calleeName);if(!g)return[];let h=c.resolvedImports.get(g.specifier);if(!h)return[{kind:"external",name:g.importedName,packageSpec:g.specifier}];let i=d.get(h);if(!i)return[];let j=n(i,g.importedName,0,new Set,d);return j&&"ambiguous"!==j&&m(j.kind)?[{kind:"symbol",addr:{filePath:j.filePath,qualifiedName:j.qualifiedName}}]:[]},moduleForFile:(a,b)=>a}}let p=o("typescript",[".ts"]),q=o("tsx",[".tsx",".jsx"]),r=o("javascript",[".js",".mjs",".cjs"]);function s(a){return"function"===a||"class"===a||"method"===a}function t(a,b,c){let d=b.replace(/\./g,"/"),e=(...a)=>a.filter(a=>""!==a&&"."!==a).join("/");if(!d){let b=e(a,"__init__.py");return c.has(b)?b:null}let f=e(a,d+".py");if(c.has(f))return f;let g=e(a,d,"__init__.py");return c.has(g)?g:null}var u=c(73024);function v(a,b,c,d,e=[],f){return{qualifiedName:d?`${d}>${b}`:b,name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:a.startPosition.row+1,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function w(a){let b=a.childForFieldName("parameters");if(!b)return;let c=[];for(let a=0;a<b.namedChildCount;a++){let d=b.namedChild(a);if(d){if("parameter_declaration"===d.type){let a=d.childForFieldName("name");if(!a){c.push("_");continue}if("identifier"===a.type)c.push(a.text);else if("identifier_list"===a.type)for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);d?.type==="identifier"&&c.push(d.text)}else c.push(a.text)}else if("variadic_parameter_declaration"===d.type){let a=d.childForFieldName("name");a?.type==="identifier"?c.push(`...${a.text}`):c.push("...")}}}return c}async function x(a,b){try{let c=b?await b.readFile("go.mod"):await u.promises.readFile(f().join(a,"go.mod"),"utf8"),d=/^\s*module\s+(\S+)/m.exec(c);return d?d[1].trim():null}catch{return null}}function y(a){return"function"===a||"class"===a||"method"===a}function z(a,b,c,d,e=[],f){return{qualifiedName:d?`${d}>${b}`:b,name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:a.startPosition.row+1,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function A(a){let b=a.childForFieldName("parameters");if(!b)return;let c=[];for(let a=0;a<b.namedChildCount;a++){let d=b.namedChild(a);if(d)if("self_parameter"===d.type)c.push(d.text);else if("parameter"===d.type){let a=d.childForFieldName("pattern");a?c.push(a.text):c.push("_")}else"variadic_parameter"===d.type&&c.push("...")}return c}async function B(a,b,c){let d=new Map,e=new Map,g=new Set;async function h(i,j){let k;if(g.has(j))return;g.add(j),d.set(i,j),e.set(j,i);try{k=c?await c.readFile(j):await u.promises.readFile(f().join(a,j),"utf8")}catch{return}let l=function(a){let b,c=a.replace(/\/\*[\s\S]*?\*\//g,"").replace(/\/\/.*$/gm,"").replace(/"(?:\\.|[^"\\\n])*"/g,'""'),d=[],e=/\b(?:pub(?:\s*\([^)]*\))?\s+)?mod\s+(\w+)\s*;/g;for(;null!==(b=e.exec(c));)d.push(b[1]);return d}(k);if(0===l.length)return;let m=f().posix.dirname(j),n=f().posix.basename(j,".rs"),o="mod"===n||"lib"===n||"main"===n?[m]:[m,f().posix.join(m,n)];for(let a of l){let c=`${i}::${a}`,d=null;for(let c of o){for(let e of[f().posix.join(c,`${a}.rs`),f().posix.join(c,a,"mod.rs")]){let a=e.startsWith("./")?e.slice(2):e;if(b.has(a)){d=a;break}}if(d)break}d&&await h(c,d)}}for(let a of function(a){let b=[];for(let c of a)("src/lib.rs"===c||"src/main.rs"===c||c.endsWith("/src/lib.rs")||c.endsWith("/src/main.rs")||/^src\/bin\/[^/]+\.rs$/.test(c)||/\/src\/bin\/[^/]+\.rs$/.test(c))&&b.push(c);return b}(b))if("src/lib.rs"===a||"src/main.rs"===a)await h("crate",a);else if(a.startsWith("src/bin/"))await h("crate",a);else{let b=a.split("/"),c=b.indexOf("src");if(c>0){let d=b[c-1];await h(d,a)}}return{modTree:d,fileToMod:e}}function C(a){return"function"===a||"class"===a||"method"===a}(0,d.ik)(p),(0,d.ik)(q),(0,d.ik)(r),(0,d.ik)({grammarId:"python",extensions:[".py",".pyi"],extractSymbols:(a,b)=>(0,g.Hs)(a),extractImports:a=>({specs:k(a,"python"),bindings:(0,h.jv)(a)}),extractCallSites:(a,b)=>(0,h.Lv)(a),buildProjectContext(a,b){let c=[a],d=!1;if(b.has("src/__init__.py"))d=!0;else for(let a of b)if(a.startsWith("src/")&&a.endsWith(".py")){d=!0;break}return d&&c.push(f().join(a,"src")),{cwd:a,pythonRoots:c}},resolveSpecifier(a,b,c,d){let e=/^(\.+)/.exec(a);if(e){let c=e[1].length,g=a.slice(c),h=f().dirname(b);for(let a=1;a<c;a++)h=f().dirname(h);return t(h||".",g,d)}for(let b of c.pythonRoots){let e=t(f().relative(c.cwd,b)||".",a,d);if(e)return e}return null},resolveCall(a,b,c,d,e){if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(!b)return[];let e=c.resolvedImports.get(b.specifier);if(!e)return[];let f=d.get(e);if(!f)return[];let g=function(a,b,c){if("*"!==b){let d=`${b}>${c}`,e=a.symbolsByQname.get(d);if(e&&s(e.kind))return e}if("*"===b){let b=a.symbolsByName.get(c);if(b){let a=null;for(let c of b)!c.qualifiedName.includes(">")&&s(c.kind)&&(!a||c.endLine-c.startLine>a.endLine-a.startLine)&&(a=c);if(a)return a}}return null}(f,b.importedName,a.calleeName);return g?[{kind:"symbol",addr:{filePath:g.filePath,qualifiedName:g.qualifiedName}}]:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let f=c.symbolsByName.get(a.calleeName);if(f&&f.length>0){let a=[];for(let c of f)c.qualifiedName!==b.qualifiedName&&s(c.kind)&&a.push({kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}});return a}let g=c.bindingsByLocalName.get(a.calleeName);if(!g)return[];let h=c.resolvedImports.get(g.specifier);if(!h)return[{kind:"external",name:g.importedName,packageSpec:g.specifier}];let i=d.get(h);if(!i)return[];let j=function(a,b){let c=a.symbolsByName.get(b);if(!c)return null;let d=null;for(let a of c)s(a.kind)&&(!d||a.endLine-a.startLine>d.endLine-d.startLine)&&(d=a);return d}(i,g.importedName);return j?[{kind:"symbol",addr:{filePath:j.filePath,qualifiedName:j.qualifiedName}}]:[]},moduleForFile:(a,b)=>a}),(0,d.ik)({grammarId:"go",extensions:[".go"],extractSymbols(a,b){let c=[],d=function(a){let b=[],c=-1,d=-1;for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(f){if("import_declaration"===f.type)b.push(f),c<0&&(c=f.startPosition.row+1),d=f.endPosition.row+1;else if("package_clause"===f.type)continue;else if(c>=0)break}}if(c<0)return null;let e=b.map(a=>a.text).join("\n");return{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:d,declLine:c,contentHash:(0,g.qj)((0,g.NZ)(e)),children:[]}}(a);d&&c.push(d);let{symbols:e,pendingMethods:f}=function(a){let b=[],c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e)switch(e.type){case"function_declaration":{let a=e.childForFieldName("name");if(!a)break;b.push(v(e,a.text,"function",void 0,[],w(e)));break}case"method_declaration":{let a=e.childForFieldName("name");if(!a)break;let d=function(a){let b=a.childForFieldName("receiver");if(!b)return null;for(let a=0;a<b.namedChildCount;a++){let c=b.namedChild(a);if(c?.type!=="parameter_declaration")continue;let d=c.childForFieldName("type");if(!d)break;return function a(b){if("type_identifier"===b.type)return b.text;if("pointer_type"===b.type){for(let c=0;c<b.namedChildCount;c++){let d=b.namedChild(c);if(d){let b=a(d);if(b)return b}}return null}if("generic_type"===b.type){let c=b.childForFieldName("type");if(c)return a(c)}return null}(d)}return null}(e),f=v(e,a.text,"method",d??void 0,[],w(e));d?c.push({receiverType:d,symbol:f}):b.push(f);break}case"type_declaration":b.push(...function(a,b){let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e&&("type_spec"===e.type||"type_alias"===e.type)){let a=e.childForFieldName("name"),d=e.childForFieldName("type");if(!a)continue;let f=a.text,g=d?.type==="interface_type"?"interface":"class";c.push(v(e,f,g,b))}}return c}(e,void 0));break;case"var_declaration":case"const_declaration":b.push(...function(a,b){let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e&&("var_spec"===e.type||"const_spec"===e.type)){let a=e.childForFieldName("name");if(!a)continue;if("identifier_list"===a.type)for(let d=0;d<a.namedChildCount;d++){let f=a.namedChild(d);f?.type==="identifier"&&c.push(v(e,f.text,"const",b))}else"identifier"===a.type&&c.push(v(e,a.text,"const",b))}}return c}(e,void 0))}}return{symbols:b,pendingMethods:c}}(a);return c.push(...function(a,b){if(0===b.length)return a;let c=new Map;for(let b of a)("class"===b.kind||"interface"===b.kind)&&c.set(b.name,b);let d=[];for(let a of b){let b=c.get(a.receiverType);b?b.children=[...b.children,a.symbol]:d.push(a.symbol)}return[...a,...d]}(e,f)),(0,g.mG)(a,c),c.push(...(0,g._B)(a,c)),c},extractImports:a=>(function(a){let b=[],c=[];function d(a){var d;let e,f=a.childForFieldName("path");if(!f)return;let g=(d=f.text).length>=2&&('"'===d[0]||"'"===d[0]||"`"===d[0])&&d[d.length-1]===d[0]?d.slice(1,-1):d;if(!g)return;b.push(g);let h=a.childForFieldName("name");if(h)e=h.text;else{let a=g.split("/");e=a[a.length-1]||g}c.push({specifier:g,importedName:"*",localName:e})}return!function a(b){if("import_declaration"===b.type){for(let a=0;a<b.namedChildCount;a++){let c=b.namedChild(a);if(c){if("import_spec"===c.type)d(c);else if("import_spec_list"===c.type)for(let a=0;a<c.namedChildCount;a++){let b=c.namedChild(a);b?.type==="import_spec"&&d(b)}}}return}for(let c=0;c<b.namedChildCount;c++){let d=b.namedChild(c);d&&a(d)}}(a),{specs:b,bindings:c}})(a),extractCallSites:(a,b)=>{let c;return c=[],!function a(b){if("call_expression"===b.type){let a=b.childForFieldName("function"),d=function a(b){if(!b)return null;if("identifier"===b.type)return b.text;if("selector_expression"===b.type){let a=b.childForFieldName("field");return a?.text??null}return"call_expression"===b.type?a(b.childForFieldName("function")):null}(a);if(d){let e=function(a){if(!a||"selector_expression"!==a.type)return;let b=a;for(;b;){if("identifier"===b.type)return b.text;if("selector_expression"===b.type){b=b.childForFieldName("operand");continue}break}}(a);c.push({calleeName:d,line:b.startPosition.row+1,...e?{receiverName:e}:{}})}}for(let c=0;c<b.childCount;c++){let d=b.child(c);d&&a(d)}}(a),c},async buildProjectContext(a,b,c){let d=await x(a,c);return{cwd:a,modulePath:d,dirToGoFiles:function(a){let b=new Map;for(let c of a){if(!c.endsWith(".go"))continue;let a=f().dirname(c),d=b.get(a);d?d.push(c):b.set(a,[c])}return b}(b)}},resolveSpecifier(a,b,c,d){if(!c.modulePath)return null;if(a===c.modulePath){let a=c.dirToGoFiles.get(".");return a?.[0]??null}if(a.startsWith(c.modulePath+"/")){let b=a.slice(c.modulePath.length+1),d=c.dirToGoFiles.get(b);return d?.[0]??null}return null},resolveCall(a,b,c,d,e){let g=f().dirname(c.path),h=e.dirToGoFiles.get(g)??[c.path];if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(b){let g=c.resolvedImports.get(b.specifier);if(!g)return[{kind:"external",name:a.calleeName,packageSpec:b.specifier}];let h=f().dirname(g);for(let b of e.dirToGoFiles.get(h)??[]){let c,e=d.get(b);if(!e)continue;let f=e.symbolsByName.get(a.calleeName);if(f){for(let a of f)if(!a.qualifiedName.includes(">")&&y(a.kind)){c=a;break}if(c)return[{kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}}]}}return[{kind:"external",name:a.calleeName,packageSpec:b.specifier}]}let g=`${a.receiverName}>${a.calleeName}`;for(let a of h){let b=d.get(a);if(!b)continue;let c=b.symbolsByQname.get(g);if(c&&y(c.kind))return[{kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}}]}return[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let i=[];for(let c of h){let e=d.get(c);if(!e)continue;let f=e.symbolsByName.get(a.calleeName);if(f)for(let a of f)!(a.qualifiedName===b.qualifiedName||a.qualifiedName.includes(">"))&&y(a.kind)&&i.push({kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}})}return i},moduleForFile(a,b){let c=f().dirname(a);return b?.modulePath?"."===c?b.modulePath:`${b.modulePath}/${c}`:c}}),(0,d.ik)({grammarId:"rust",extensions:[".rs"],extractSymbols(a,b){let c=[],d=function(a){let b=[],c=-1,d=-1;for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(f){if("use_declaration"===f.type||"extern_crate_declaration"===f.type)b.push(f),c<0&&(c=f.startPosition.row+1),d=f.endPosition.row+1;else if(c>=0)break}}if(c<0)return null;let e=b.map(a=>a.text).join("\n");return{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:d,declLine:c,contentHash:(0,g.qj)((0,g.NZ)(e)),children:[]}}(a);d&&c.push(d);let{symbols:e,pendingImpls:f}=function(a){let b=[],c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e)switch(e.type){case"function_item":{let a=e.childForFieldName("name");if(!a)break;b.push(z(e,a.text,"function",void 0,[],A(e)));break}case"struct_item":case"union_item":{let a=e.childForFieldName("name");if(!a)break;b.push(z(e,a.text,"class",void 0));break}case"enum_item":{let a=e.childForFieldName("name");if(!a)break;b.push(z(e,a.text,"enum",void 0));break}case"trait_item":{let a=e.childForFieldName("name");if(!a)break;let c=function(a,b){let c=a.childForFieldName("body");if(!c)return[];let d=[];for(let a=0;a<c.namedChildCount;a++){let e=c.namedChild(a);if(e&&("function_item"===e.type||"function_signature_item"===e.type)){let a=e.childForFieldName("name");if(!a)continue;d.push(z(e,a.text,"method",b,[],A(e)))}}return d}(e,a.text);b.push(z(e,a.text,"interface",void 0,c));break}case"impl_item":{let a=function(a){let b=a.childForFieldName("type");return b?function a(b){if("type_identifier"===b.type)return b.text;if("generic_type"===b.type){let c=b.childForFieldName("type");if(c)return a(c)}if("reference_type"===b.type)for(let c=0;c<b.namedChildCount;c++){let d=b.namedChild(c);if(d){let b=a(d);if(b)return b}}if("scoped_type_identifier"===b.type){let a=b.childForFieldName("name");if(a?.type==="type_identifier")return a.text}return null}(b):null}(e);if(!a)break;let b=function(a,b){let c=a.childForFieldName("body");if(!c)return[];let d=[];for(let a=0;a<c.namedChildCount;a++){let e=c.namedChild(a);if(e){if("function_item"===e.type){let a=e.childForFieldName("name");if(!a)continue;d.push(z(e,a.text,"method",b,[],A(e)))}else if("function_signature_item"===e.type){let a=e.childForFieldName("name");if(!a)continue;d.push(z(e,a.text,"method",b,[],A(e)))}}}return d}(e,a);b.length>0&&c.push({targetType:a,methods:b});break}case"const_item":case"static_item":{let a=e.childForFieldName("name");if(!a)break;b.push(z(e,a.text,"const",void 0));break}case"type_item":{let a=e.childForFieldName("name");if(!a)break;b.push(z(e,a.text,"type",void 0));break}case"mod_item":{let a=e.childForFieldName("name"),c=e.childForFieldName("body");if(!a||!c)break;b.push(z(e,a.text,"class",void 0))}}}return{symbols:b,pendingImpls:c}}(a);return c.push(...function(a,b){if(0===b.length)return a;let c=new Map;for(let b of a)("class"===b.kind||"enum"===b.kind||"interface"===b.kind)&&c.set(b.name,b);let d=[];for(let a of b){let b=c.get(a.targetType);b?b.children=[...b.children,...a.methods]:d.push(...a.methods)}return[...a,...d]}(e,f)),(0,g.mG)(a,c),c.push(...(0,g._B)(a,c)),c},extractImports:a=>(function(a){let b=[],c=[];function d(a){if("identifier"===a.type||"crate"===a.type||"self"===a.type||"super"===a.type)return a.text;if("scoped_identifier"===a.type){let b=a.childForFieldName("path"),c=a.childForFieldName("name"),e=b?d(b):"",f=c?.text??"";return e?`${e}::${f}`:f}return a.text}function e(a,b){return a?b?`${a}::${b}`:a:b}function f(a){let b=a.split("::");return b[b.length-1]??a}return!function a(g){if("use_declaration"===g.type)return void function(a){for(let g=0;g<a.namedChildCount;g++){let h=a.namedChild(g);h&&function a(g,h){switch(g.type){case"use_as_clause":{let a=g.childForFieldName("path"),i=g.childForFieldName("alias");if(a&&i){let g=e(h,d(a));b.push(g),c.push({specifier:g,importedName:f(g),localName:i.text})}break}case"use_list":for(let b=0;b<g.namedChildCount;b++){let c=g.namedChild(b);c&&a(c,h)}break;case"scoped_use_list":{let b=g.childForFieldName("path"),c=g.childForFieldName("list"),f=b?e(h,d(b)):h;if(c)for(let b=0;b<c.namedChildCount;b++){let d=c.namedChild(b);d&&a(d,f)}break}case"use_wildcard":{let a=g.childForFieldName("path"),f=a?e(h,d(a)):h;f&&(b.push(f),c.push({specifier:f,importedName:"*",localName:"*"}));break}case"identifier":case"self":case"super":case"crate":case"scoped_identifier":{let a=e(h,d(g));a&&(b.push(a),c.push({specifier:a,importedName:f(a),localName:f(a)}))}}}(h,"")}}(g);if("extern_crate_declaration"===g.type){let a=g.childForFieldName("name");a&&(b.push(a.text),c.push({specifier:a.text,importedName:"*",localName:a.text}));return}if("mod_item"===g.type){let a=g.childForFieldName("body"),c=g.childForFieldName("name");!a&&c&&b.push(c.text);return}for(let b=0;b<g.namedChildCount;b++){let c=g.namedChild(b);c&&a(c)}}(a),{specs:b,bindings:c}})(a),extractCallSites:(a,b)=>{let c;return c=[],!function a(b){if("call_expression"===b.type){let a=b.childForFieldName("function"),d=function(a){if(!a)return null;if("identifier"===a.type)return a.text;if("scoped_identifier"===a.type){let b=a.childForFieldName("name");return b?.text??null}if("field_expression"===a.type){let b=a.childForFieldName("field");return b?.text??null}return null}(a);if(d){let e=function(a){if(a){if("scoped_identifier"===a.type){let b=a;for(;b;){if("identifier"===b.type)return b.text;if("scoped_identifier"===b.type){b=b.childForFieldName("path");continue}break}}if("field_expression"===a.type){let b=a.childForFieldName("value");if(b?.type==="identifier")return b.text}}}(a);c.push({calleeName:d,line:b.startPosition.row+1,...e?{receiverName:e}:{}})}}else if("method_call_expression"===b.type){let a=b.childForFieldName("method"),d=b.childForFieldName("value");if(a){let e=d?.type==="identifier"?d.text:void 0;c.push({calleeName:a.text,line:b.startPosition.row+1,...e?{receiverName:e}:{}})}}for(let c=0;c<b.childCount;c++){let d=b.child(c);d&&a(d)}}(a),c},async buildProjectContext(a,b,c){let{modTree:d,fileToMod:e}=await B(a,b,c);return{cwd:a,modTree:d,fileToMod:e}},resolveSpecifier(a,b,c,d){let e=c.fileToMod.get(b);if(!e)return null;let f=function(a,b){if(a.startsWith("crate::"))return a;if("crate"===a)return"crate";if(a.startsWith("self::"))return`${b}::${a.slice(6)}`;if("self"===a)return b;if(a.startsWith("super::")){let c=b,d=a;for(;d.startsWith("super::");){let a=c.lastIndexOf("::");if(a<0)return null;c=c.slice(0,a),d=d.slice(7)}if("super"===d){let a=c.lastIndexOf("::");return a<0?null:c.slice(0,a)}return d?`${c}::${d}`:c}return null}(a,e);if(!f)return null;if(c.modTree.has(f))return c.modTree.get(f);let g=f.split("::");for(;g.length>1;){g.pop();let a=g.join("::"),b=c.modTree.get(a);if(b)return b}return null},resolveCall(a,b,c,d,e){let f;if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(b){let e=c.resolvedImports.get(b.specifier);if(!e)return[{kind:"external",name:a.calleeName,packageSpec:b.specifier}];let f=d.get(e);if(!f)return[];let g=f.symbolsByName.get(a.calleeName);if(g){for(let a of g)if(!a.qualifiedName.includes(">")&&C(a.kind))return[{kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}}]}let h=`${b.importedName}>${a.calleeName}`,i=f.symbolsByQname.get(h);return i&&C(i.kind)?[{kind:"symbol",addr:{filePath:i.filePath,qualifiedName:i.qualifiedName}}]:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let e=`${a.receiverName}>${a.calleeName}`,f=c.symbolsByQname.get(e);if(f)return[{kind:"symbol",addr:{filePath:f.filePath,qualifiedName:f.qualifiedName}}];let g=[],h=c.symbolsByName.get(a.calleeName);if(h)for(let a of h)"method"===a.kind&&g.push({kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}});return g.length>0?g:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let g=[],h=c.symbolsByName.get(a.calleeName);if(h)for(let a of h)!(a.qualifiedName===b.qualifiedName||a.qualifiedName.includes(">"))&&C(a.kind)&&g.push({kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}});if(g.length>0)return g;let i=c.bindingsByLocalName.get(a.calleeName);if(!i)return[];let j=c.resolvedImports.get(i.specifier);if(!j)return[{kind:"external",name:i.importedName,packageSpec:i.specifier}];let k=d.get(j);if(!k)return[];let l=k.symbolsByName.get(i.importedName);if(l){for(let a of l)if(!a.qualifiedName.includes(">")&&C(a.kind)){f=a;break}}return f?[{kind:"symbol",addr:{filePath:f.filePath,qualifiedName:f.qualifiedName}}]:[]},moduleForFile:(a,b)=>b?.fileToMod.get(a)??f().posix.dirname(a)}),(0,d.ik)({grammarId:"lean",extensions:[".lean"],extractSymbols:(a,b)=>(0,g.Hs)(a,"lean"),extractImports:a=>({specs:[],bindings:[]}),extractCallSites:(a,b)=>[],buildProjectContext(){},resolveSpecifier:()=>null,resolveCall:()=>[],moduleForFile:a=>a.replace(/\.lean$/i,"").replace(/[/\\]/g,".")})},25157:(a,b,c)=>{c.d(b,{d:()=>i});let d=globalThis,e=d.__cockpitGraphProgressListeners??(d.__cockpitGraphProgressListeners=new Map),f=d.__cockpitGraphProgressLastFrame??(d.__cockpitGraphProgressLastFrame=new Map),g=d.__cockpitGraphProgressLastEmitAt??(d.__cockpitGraphProgressLastEmitAt=new Map),h={listing:[0,3],contexts:[3,6],parsing:[6,85],resolving:[85,92],edges:[92,99],done:[100,100]};function i(a,b,c=0,d=0,j,k=!1){let l=e.get(a),m=Date.now();if(!k&&m-(g.get(a)??0)<100)return;g.set(a,m);let n={cwd:a,phase:b,filesDone:c,filesTotal:d,...j?{currentFile:j}:{},percent:function(a,b,c){let[d,e]=h[a];return"parsing"!==a||c<=0?d:Math.min(e,d+(e-d)*b/c)}(b,c,d)};if("done"===b?(f.delete(a),g.delete(a)):f.set(a,n),l&&0!==l.size)for(let a of l)try{a(n)}catch{}}},25344:(a,b,c)=>{c.d(b,{BE:()=>i,IS:()=>p,KP:()=>l,ZT:()=>r,_0:()=>m,zC:()=>n});var d=c(73024),e=c(76760),f=c.n(e),g=c(75775);function h(a,b,c){return c?c.readFile(b):d.promises.readFile(f().join(a,b),"utf8")}let i=g.yj,j=[".ts",".tsx",".js",".jsx",".mjs",".cjs"],k=[".js",".jsx",".mjs",".cjs"];function l(a,b,c){let d=f().relative(b,a).split(f().sep).join("/");if(d.startsWith(".."))return null;for(let a of k)if(d.endsWith(a)){d=d.slice(0,-a.length);break}if(c.has(d))return d;for(let a of j){let b=d+a;if(c.has(b))return b}for(let a of j){let b=f().posix.join(d,"index"+a);if(c.has(b))return b}return null}function m(a,b){return""===b||a===b||a.startsWith(b+"/")}async function n(a,b,c){let d=await o(a,c);if(0===d.length)return new Map;let e=(c?.paths??await (0,g.jR)(a)).filter(a=>a.endsWith("/package.json")).filter(a=>{let b=a.slice(0,-13);return d.some(a=>{var c;return c=b,RegExp("^"+a.replace(/\\/g,"/").replace(/[.+^${}()|[\]]/g,"\\$&").replace(/\*\*/g,"___DOUBLESTAR___").replace(/\*/g,"[^/]*").replace(/___DOUBLESTAR___/g,".*")+"$").test(c)})}),i=new Map;for(let d of e){let e;try{e=JSON.parse(await h(a,d,c))}catch{continue}if("string"!=typeof e.name)continue;let g=f().dirname(d),j=function(a,b,c){let d,e=b=>{let d=b.replace(/^\.\//,"");return p(f().posix.join(a,d),c)},g=b.exports;if("string"==typeof g)d=g;else if(g&&"object"==typeof g&&g["."]){let a=g["."];"string"==typeof a?d=a:a&&"object"==typeof a&&(d=a.types??a.import??a.default??a.require)}if("string"==typeof d){let a=e(d);if(a)return a}if("string"==typeof b.main){let a=e(b.main);if(a)return a}for(let b of["src/index.ts","src/index.tsx","index.ts","index.tsx","src/index.js","index.js"])if(c.has(f().posix.join(a,b)))return f().posix.join(a,b);return null}(g,e,b);i.set(e.name,{name:e.name,dir:g,entryFile:j})}return i}async function o(a,b){try{var c=await h(a,"pnpm-workspace.yaml",b);let d=[],e=!1;for(let a of c.split("\n")){let b=a.replace(/#.*$/,"");if(/^packages\s*:/.test(b)){e=!0;continue}if(!e)continue;let c=b.match(/^\s*-\s*['"]?([^'"#\s]+)['"]?\s*$/);c?d.push(c[1]):/^\S/.test(b)&&(e=!1)}return d}catch{}try{let c=JSON.parse(await h(a,"package.json",b)),d=c?.workspaces;if(Array.isArray(d))return d.filter(a=>"string"==typeof a);if(d&&Array.isArray(d.packages))return d.packages.filter(a=>"string"==typeof a)}catch{}return[]}function p(a,b){if(a.startsWith("..")||a.startsWith("/"))return null;for(let b of k)if(a.endsWith(b)){a=a.slice(0,-b.length);break}if(b.has(a))return a;for(let c of j){let d=a+c;if(b.has(d))return d}for(let c of j){let d=f().posix.join(a,"index"+c);if(b.has(d))return d}return null}async function q(a,b,c){let d,e=new Map;try{let e=(await h(b,f().relative(b,a).split(f().sep).join("/"),c)).replace(/^\s*\/\/.*$/gm,"");d=JSON.parse(e)}catch{return e}let g=d?.compilerOptions?.baseUrl??".",i=d?.compilerOptions?.paths??{},j=f().resolve(f().dirname(a),g),k=f().relative(b,j)||".";for(let[a,b]of Object.entries(i)){if(!Array.isArray(b)||0===b.length)continue;let c=a.replace(/\/\*$/,""),d=b[0].replace(/\/\*$/,"");e.set(c,f().join(k,d))}return e}async function r(a,b){let c=[];for(let d of(b?.paths??await (0,g.jR)(a)).filter(a=>/(^|\/)tsconfig[^/]*\.json$/.test(a))){let e=await q(f().join(a,d),a,b);if(0===e.size)continue;let g=f().dirname(d);c.push({scope:"."===g?"":g,aliases:e,sortedAliases:s(e)})}let d=c.find(a=>""===a.scope);return d||(d={scope:"",aliases:new Map,sortedAliases:[]},c.push(d)),d.aliases.has("@")||(d.aliases.set("@","./src"),d.sortedAliases=s(d.aliases)),c.sort((a,b)=>b.scope.length-a.scope.length)}function s(a){return[...a.entries()].sort(([a],[b])=>b.length-a.length)}},27485:(a,b,c)=>{c.d(b,{_:()=>e});let d=new Set(["function","class","method"]);function e(a){return d.has(a.kind)}},28677:(a,b,c)=>{c.d(b,{Bu:()=>f,cn:()=>h,ik:()=>e,iv:()=>g});let d=new Map;function e(a){d.set(a.grammarId,a)}function f(a){let b=d.get(a);if(!b)throw Error(`[codeMap] no handler registered for grammar '${a}' — did the handler module get imported (handlers/index.ts barrel)?`);return b}function g(a){return d.get(a)}function h(){let a=new Set;for(let b of d.values())for(let c of b.extensions)a.add(c.toLowerCase());return[...a]}},33265:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{E:()=>S,J:()=>Z,KE:()=>J,Mv:()=>Y,NV:()=>B,Xn:()=>X,_7:()=>W,bQ:()=>V,ih:()=>C,lG:()=>H,tI:()=>K,u$:()=>G,uV:()=>I});var e,f=c(78877),g=c(58500),h=c(89705),i=c(15825),j=c(770),k=c(75775),l=c(87956),m=c(86236),n=c(25344),o=c(25157),p=c(27485),q=c(4410),r=c(83624),s=c(45356),t=c(53809),u=c(85836),v=a([l]);async function w(a,b,c){let d,e=Array(a.length),f=0,i=!1,j=performance.now();async function k(){for(;!i&&f<a.length&&(!d&&performance.now()-j>=8&&(d=h.pR5(h.ivC(()=>(0,g.setImmediate)())).then(()=>{j=performance.now(),d=void 0})),d&&await d,!i&&!(f>=a.length));){let b=f++;e[b]=await c(a[b]).catch(a=>{throw i=!0,a})}}let l=(await Promise.allSettled(Array.from({length:Math.min(b,a.length)},k))).find(a=>"rejected"===a.status);if(l?.status==="rejected")throw l.reason;return e}l=(v.then?(await v)():v)[0];let $=/(['"`])([A-Za-z][A-Za-z0-9_.-]{2,63})\1/g;async function x(a,b){let c=(0,l.M)(a);if(!c)return null;let{source:d}=b;if(b.sizeBytes>k.FI)return null;let e=(await (0,l.b)(c)).parse(d);if(!e)throw new j.uV({message:`Unable to parse ${a}`});try{let b,f=(0,q.Bu)(c),g=f.extractSymbols(e.rootNode,d);(0,r.YN)(g);let h=(b=[],!function c(d){for(let e of d)b.push({filePath:a,qualifiedName:e.qualifiedName,name:e.name,kind:e.kind,startLine:e.startLine,endLine:e.endLine,declLine:e.declLine,params:e.params}),c(e.children)}(g),b),{specs:i,bindings:j}=f.extractImports(e.rootNode),k=f.extractCallSites(e.rootNode,h),l=function(a,b){let c,d=[],e=new Set,f=[0];for(let b=0;b<a.length;b++)10===a.charCodeAt(b)&&f.push(b+1);for($.lastIndex=0;null!==(c=$.exec(a))&&!(d.length>=500);){let a=c[2],g=function(a){let b=0,c=f.length-1;for(;b<c;){let d=b+c+1>>>1;f[d]<=a?b=d:c=d-1}return b+1}(c.index),h=`${a}\u0000${g}`;if(e.has(h))continue;e.add(h);let i=y(b,g);d.push({value:a,line:g,...i?{enclosingQname:i.qualifiedName}:{}})}return d}(d,h);return{path:a,language:c,symbolsTree:g,flatSymbols:h,importBindings:j,importSpecifiers:i,rawCalls:k,literals:l}}finally{e.delete()}}function y(a,b){let c=null;for(let d of a)d.startLine<=b&&b<=d.endLine&&(!c||d.endLine-d.startLine<c.endLine-c.startLine)&&(c=d);return c}let _=new WeakMap;async function z(a,b,c,d=!1){let e=Date.now(),f=c&&_.get(c),g=(0,k.po)(f?.hashes??new Map,b.hashes),h=d||g.rebuild||f?.configHash!==b.configHash||f?.git.head!==b.git.head||f?.git.busy!==b.git.busy||f?.git.commonDir!==b.git.commonDir,i=[...b.sources.keys()].sort(),j=b.truncated,p=new Set(i);(0,o.d)(a,"contexts",0,i.length,void 0,!0);let r=await (0,n.ZT)(a,b.contextFiles),s=await (0,n.zC)(a,p,b.contextFiles),t=new Map;for(let c of m.I){let d=(0,q.iv)(c);d&&t.set(c,await d.buildProjectContext(a,p,b.contextFiles))}let u=i.length,v=0,A=0;(0,o.d)(a,"parsing",0,u,void 0,!0);let B=new Map,C=new Map,D=(await w(i,50,async c=>{let e=!d&&f?.git.commonDir===b.git.commonDir&&f?.hashes.get(c)===b.hashes.get(c)&&f?.facts.has(c),g=(0,l.M)(c),h=d||e||!g?void 0:ab.findParse(b.git.commonDir,c,g,b.hashes.get(c));h&&C.set(c,h);let i=e?f.facts.get(c):h?.facts??await x(c,b.sources.get(c));return!e&&!h&&A++,B.set(c,i),v++,(0,o.d)(a,"parsing",v,u,c),i})).filter(a=>null!==a);(0,o.d)(a,"resolving",u,u,void 0,!0);let E=new Map;for(let a of D){let d=(0,q.Bu)(a.language),e=t.get(a.language),g=new Map,h=new Set;for(let b of a.importSpecifiers){if(g.has(b))continue;let c=d.resolveSpecifier(b,a.path,e,p);c&&c!==a.path&&(g.set(b,c),h.add(c))}let i=(f?.facts.get(a.path)===a?c?.files.get(a.path):void 0)??C.get(a.path)?.lookups,j=i?.symbolsByName??new Map,k=i?.symbolsByQname??new Map;for(let b of i?[]:a.flatSymbols){k.set(b.qualifiedName,b);let a=j.get(b.name);a?a.push(b):j.set(b.name,[b])}let l=i?.bindingsByLocalName??new Map,m=i?.reexportsByLocalName??new Map;for(let b of i?[]:a.importBindings)b.isReexport?m.set(b.localName,b):l.set(b.localName,b);E.set(a.path,{path:a.path,language:a.language,mtime:b.sources.get(a.path).mtime,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:h,importedBy:new Set,importBindings:a.importBindings,resolvedImports:g,intraCalls:[],outgoingCalls:[],incomingCalls:[],externalCalls:[],methodCalls:[],symbolsByName:j,symbolsByQname:k,bindingsByLocalName:l,reexportsByLocalName:m})}for(let a of E.values())for(let b of a.importedFiles){let c=E.get(b);c&&c.importedBy.add(a.path)}for(let b of((0,o.d)(a,"edges",u,u,void 0,!0),D)){let a=E.get(b.path),c=(0,q.Bu)(b.language),d=t.get(b.language),e=new Map,f=new Map,g=new Map,h=new Map;for(let i of b.rawCalls){let b=y(a.flatSymbols,i.line);if(b){for(let j of c.resolveCall(i,b,a,E,d))if("symbol"===j.kind)if(j.addr.filePath===a.path){let c=`${b.qualifiedName}${j.addr.qualifiedName}`,d=e.get(c);if(d)d.lines.push(i.line);else{let d={from:b.qualifiedName,to:j.addr.qualifiedName,lines:[i.line]};e.set(c,d),a.intraCalls.push(d)}}else{let c=`${b.qualifiedName}${j.addr.filePath}${j.addr.qualifiedName}`,d=f.get(c);if(d)d.lines.push(i.line);else{let d={from:b.qualifiedName,to:{filePath:j.addr.filePath,qualifiedName:j.addr.qualifiedName},lines:[i.line]};f.set(c,d),a.outgoingCalls.push(d)}}else if("external"===j.kind){let c=`${b.qualifiedName}${j.packageSpec}${j.name}`,d=g.get(c);if(d)d.lines.push(i.line);else{let d={from:b.qualifiedName,packageSpec:j.packageSpec,importedName:j.name,lines:[i.line]};g.set(c,d),a.externalCalls.push(d)}}else if("method-unresolved"===j.kind){let c=a.bindingsByLocalName.get(j.receiverName),d=c?a.resolvedImports.get(c.specifier)??"":"",e=`${b.qualifiedName}${j.receiverName}${j.methodName}`,f=h.get(e);if(f)f.lines.push(i.line);else{let c={from:b.qualifiedName,receiverName:j.receiverName,methodName:j.methodName,receiverFilePath:d,lines:[i.line]};h.set(e,c),a.methodCalls.push(c)}}}}for(let b of a.intraCalls)b.lines.sort((a,b)=>a-b);for(let b of a.outgoingCalls)b.lines.sort((a,b)=>a-b);for(let b of a.externalCalls)b.lines.sort((a,b)=>a-b);for(let b of a.methodCalls)b.lines.sort((a,b)=>a-b)}for(let a of E.values())for(let b of a.outgoingCalls){let c=E.get(b.to.filePath);c&&c.incomingCalls.push({from:{filePath:a.path,qualifiedName:b.from},to:b.to.qualifiedName,lines:b.lines})}let F={cwd:a,files:E,truncated:j,fileCountCap:j?n.BE:void 0,excludedFiles:i.flatMap(a=>{let c=b.sources.get(a);return c.sizeBytes>k.FI?[{filePath:a,reason:"source-too-large",sizeBytes:c.sizeBytes,limitBytes:k.FI}]:[]}),tsconfigs:r,workspaces:s,projectContexts:t,fileSet:p,generatedAt:Date.now(),buildMs:Date.now()-e,revision:(c?.revision??0)+1,update:{mode:c?h?"rebuild":"incremental":"initial",changedFiles:g.count,parsedFiles:A}};return F.truncated||=D.length<i.length,_.set(F,{hashes:b.hashes,configHash:b.configHash,scanTruncated:b.truncated,git:b.git,facts:B}),F}let aa=new Map,ab=new s.l,ac=new Map,ad=new Map;function A(a){let b=0;for(let c of a.files.values())b+=c.flatSymbols.length;return b}let ae=(e=(0,f.getHeapStatistics)().heap_size_limit,Math.max(1e9,Math.min(e-0x40000000,0x80000000))),af="5 minutes",ag=!1;function B(){ag||(ag=!0,h.MY7(h.OH5(()=>{!function(a=Date.now()){let b=a-9e5,c=[];for(let[d,e]of[...aa]){if(ad.has(d))continue;let f=ac.get(d)??0;f>=b||(F(d),c.push(d),console.log(`[codeIndex] released idle ${d} (${A(e)} symbols, unread for ${Math.round((a-f)/6e4)} min)`))}for(let a of ac.keys())aa.has(a)||ac.delete(a)}()}).pipe(h.cbG(af),h.uxO(i.ji(af)))))}let ah=new Map,ai=new Map,aj=null;function C(a){for(let[b,c]of(aj=a,ah))c.unsubscribe?.(),c.unsubscribe=a?.(b,()=>D(b))}function D(a){let b=ah.get(a);b&&b.version++}function E(a,b){aa.delete(a),aa.set(a,b),ac.set(a,Date.now())}function F(a){ab.release(a),aa.delete(a),ac.delete(a),ai.delete(a);let b=ah.get(a);b&&(b.generation++,b.retired=!0,b.unsubscribe?.(),b.unsubscribe=void 0,ad.has(a)||ah.delete(a))}async function G(a,b={}){let c,d=((c=ah.get(a))?c.retired&&(c.retired=!1,c.unsubscribe=aj?.(a,()=>D(a))):(c={version:0,publishedVersion:-1,generation:0,force:!1},ah.set(a,c),c.unsubscribe=aj?.(a,()=>D(a))),c);b.forceRefresh&&(d.generation++,d.version++,d.force=!0,ai.delete(a));let e=d.version;for(let c=0;c<3;c++){let c=ad.get(a);if(c){let f=d.runningGeneration,g=await c.then(a=>({index:a,error:void 0}),a=>({index:void 0,error:a}));if(d.force||f!==d.generation)continue;if(g.error)throw g.error;if(!b.forceRefresh&&g.index&&_.get(g.index)?.git.busy)throw new j.uV({message:"Workspace is changing: finish the Git operation or explicitly rebuild the index"});if(d.publishedVersion>=e&&g.index&&aa.get(a)===g.index)return E(a,g.index),g.index;continue}let f=d.generation,g=d.version,h=d.force;d.force=!1,d.runningGeneration=f;let i=(async()=>{let b=await (0,k.XC)(a,h),c=aa.get(a),e=c&&_.get(c),i=(0,k.po)(e?.hashes??new Map,b.hashes),l=!h&&c&&e&&!i.count&&e.configHash===b.configHash&&e.git.busy===b.git.busy&&e.git.commonDir===b.git.commonDir&&e.scanTruncated===b.truncated,m=l?c:await z(a,b,c,h),n=await (0,k.U0)(a);if(n.commonDir!==b.git.commonDir||!h&&(n.busy||n.head!==b.git.head))throw new j.uV({message:"Workspace changed during indexing; retry after the Git operation finishes"});if(d.generation!==f||ah.get(a)!==d)throw new j.uV({message:"Index update was superseded; retry the query"});if(l&&e&&_.set(m,{...e,git:b.git}),!l){let a=_.get(m);ab.publish(m,b.git.commonDir,a.hashes,a.facts)}return d.publishedVersion=g,E(a,m),ai.delete(a),!function(a,b=0){for(let c of aa.keys()){if(function(){let a=ab.estimatedBytes();for(let[b,c]of aa)ab.has(b)||(a+=4e3*A(c));return a}()+b<=ae)break;c!==a&&(F(c),console.log(`[codeIndex] evicted ${c} — cache over estimated byte budget`))}}(a),m})().catch(b=>{throw ah.get(a)!==d||d.generation!==f||d.force||ai.set(a,b),b}).finally(()=>{ad.get(a)===i&&ad.delete(a),d.retired&&!d.force&&ah.get(a)===d&&(d.unsubscribe?.(),ah.delete(a)),(0,o.d)(a,"done",0,0,void 0,!0)});ad.set(a,i);let l=await i;if(!b.forceRefresh&&_.get(l)?.git.busy)throw new j.uV({message:"Workspace is changing: finish the Git operation or explicitly rebuild the index"});return l}throw new j.uV({message:"Workspace is changing; retry the index query"})}function H(a){let b=aa.get(a);return b&&E(a,b),b??null}function I(a,b={}){!b.forceRefresh&&ai.has(a)||G(a,b).catch(()=>{})}function J(a){return ad.has(a)}async function K(a,b){await (0,k.P3)(a);let c=await (0,k.ax)(a,b);if(!c)return null;let d=H(a),e=d&&_.get(d),f=ah.get(a),g=ai.get(a),h=g?.cause instanceof Error?g.cause.message:g?.message,i=J(a);if(d&&e?.hashes.get(b)===c.hash&&(!f||f.version===f.publishedVersion)){let a=R(d,b);if(a)return{...a,mtimeMs:c.mtime,crossFileRevision:d.revision,crossFilePending:i,crossFileStale:i||!!g,indexUpdateError:h}}let j=await L(a,b,c);return j?{...j,fileCount:d?.files.size??0,crossFileStale:!!d,crossFileRevision:d?.revision,crossFilePending:J(a),indexUpdateError:h}:null}async function L(a,b,c){await (0,k.P3)(a);let d=c??await (0,k.ax)(a,b);if(!d)return null;let e=await x(b,d);if(!e)return null;let f={cwd:a,files:new Map,truncated:!1,tsconfigs:[],workspaces:new Map,projectContexts:new Map([[e.language,"go"===e.language?await (0,q.Bu)("go").buildProjectContext(a,new Set([e.path])):void 0]]),fileSet:new Set([e.path]),generatedAt:Date.now(),buildMs:0};return await M({...e,importBindings:[],importSpecifiers:[]},f,d.mtime),R(f,e.path)}async function M(a,b,c){let d=(0,q.Bu)(a.language),e=b.projectContexts.get(a.language),f=new Map,g=new Set;for(let c of a.importSpecifiers){if(f.has(c))continue;let h=d.resolveSpecifier(c,a.path,e,b.fileSet);h&&h!==a.path&&(f.set(c,h),g.add(h))}let h=new Map,i=new Map;for(let b of a.flatSymbols){i.set(b.qualifiedName,b);let a=h.get(b.name);a?a.push(b):h.set(b.name,[b])}let j=new Map,k=new Map;for(let b of a.importBindings)b.isReexport?k.set(b.localName,b):j.set(b.localName,b);let l={path:a.path,language:a.language,mtime:c,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:g,importedBy:new Set,importBindings:a.importBindings,resolvedImports:f,intraCalls:[],outgoingCalls:[],incomingCalls:[],externalCalls:[],methodCalls:[],symbolsByName:h,symbolsByQname:i,bindingsByLocalName:j,reexportsByLocalName:k},m=new Map,n=new Map,o=new Map,p=new Map;for(let c of(b.files.set(a.path,l),a.rawCalls)){let a=y(l.flatSymbols,c.line);if(a){for(let f of d.resolveCall(c,a,l,b.files,e))if("symbol"===f.kind)if(f.addr.filePath===l.path){let b=`${a.qualifiedName}${f.addr.qualifiedName}`,d=m.get(b);if(d)d.lines.push(c.line);else{let d={from:a.qualifiedName,to:f.addr.qualifiedName,lines:[c.line]};m.set(b,d),l.intraCalls.push(d)}}else{let b=`${a.qualifiedName}${f.addr.filePath}${f.addr.qualifiedName}`,d=n.get(b);if(d)d.lines.push(c.line);else{let d={from:a.qualifiedName,to:{filePath:f.addr.filePath,qualifiedName:f.addr.qualifiedName},lines:[c.line]};n.set(b,d),l.outgoingCalls.push(d)}}else if("external"===f.kind){let b=`${a.qualifiedName}${f.packageSpec}${f.name}`,d=o.get(b);if(d)d.lines.push(c.line);else{let d={from:a.qualifiedName,packageSpec:f.packageSpec,importedName:f.name,lines:[c.line]};o.set(b,d),l.externalCalls.push(d)}}else if("method-unresolved"===f.kind){let b=l.bindingsByLocalName.get(f.receiverName),d=b?l.resolvedImports.get(b.specifier)??"":"",e=`${a.qualifiedName}${f.receiverName}${f.methodName}`,g=p.get(e);if(g)g.lines.push(c.line);else{let b={from:a.qualifiedName,receiverName:f.receiverName,methodName:f.methodName,receiverFilePath:d,lines:[c.line]};p.set(e,b),l.methodCalls.push(b)}}}}for(let a of l.intraCalls)a.lines.sort((a,b)=>a-b);for(let a of l.outgoingCalls)a.lines.sort((a,b)=>a-b);for(let a of l.externalCalls)a.lines.sort((a,b)=>a-b);for(let a of l.methodCalls)a.lines.sort((a,b)=>a-b);return l}function N(a){let b=a.lastIndexOf("/");return b>=0?a.slice(b+1):a}function O(a){return{filePath:a.filePath,qualifiedName:a.qualifiedName,name:a.name,kind:a.kind,startLine:a.startLine,endLine:a.endLine,declLine:a.declLine,params:a.params}}function P(a){let b=a.indexOf(">");return b>=0?a.slice(0,b):a}function Q(a){if(a.length<2)return a;let b=[a[0]];for(let c=1;c<a.length;c++)a[c]!==a[c-1]&&b.push(a[c]);return b}function R(a,b){let c=a.files.get(b);if(!c)return null;let d=c.flatSymbols.filter(a=>!a.qualifiedName.includes(">")).map(O).sort((a,b)=>a.startLine-b.startLine),e=new Set(d.map(a=>a.qualifiedName)),f=new Map,g=[];for(let a of c.intraCalls){let b=P(a.from),c=P(a.to);if(b===c||!e.has(b)||!e.has(c))continue;let d=`${b}|${c}`,h=f.get(d);if(h)for(let b of a.lines)h.lines.push(b);else{let e={from:b,to:c,lines:a.lines.slice()};f.set(d,e),g.push(e)}}for(let a of g)a.lines.sort((a,b)=>a-b),a.lines=Q(a.lines);let h=[],i=new Map;for(let b of c.outgoingCalls){let d=P(b.from);if(!e.has(d)||b.to.filePath===c.path)continue;let f=a.files.get(b.to.filePath);if(!f)continue;let g=f.symbolsByQname.get(b.to.qualifiedName);if(!g||!(0,p._)(g))continue;let j=`${g.filePath}|${g.qualifiedName}|${d}`,k=i.get(j);if(k)for(let a of b.lines)k.lines.push(a);else{let a={external:O(g),focalQname:d,lines:b.lines.slice()};i.set(j,a),h.push(a)}}let j=[],k=new Map;for(let b of c.incomingCalls){let d=P(b.to);if(!e.has(d)||b.from.filePath===c.path)continue;let f=a.files.get(b.from.filePath);if(!f)continue;let g=f.symbolsByQname.get(b.from.qualifiedName);if(!g||!(0,p._)(g))continue;let h=`${g.filePath}|${g.qualifiedName}|${d}`,i=k.get(h);if(i)for(let a of b.lines)i.lines.push(a);else{let a={external:O(g),focalQname:d,lines:b.lines.slice()};k.set(h,a),j.push(a)}}for(let a of h)a.lines.sort((a,b)=>a-b),a.lines=Q(a.lines);for(let a of j)a.lines.sort((a,b)=>a-b),a.lines=Q(a.lines);let l=[],m=new Map;for(let a of c.externalCalls){let b=P(a.from);if(!e.has(b))continue;let c=`${b}|${a.packageSpec}|${a.importedName}`,d=m.get(c);if(d)for(let b of a.lines)d.lines.push(b);else{let d={external:{name:a.importedName,packageSpec:a.packageSpec},focalQname:b,lines:a.lines.slice()};m.set(c,d),l.push(d)}}for(let a of l)a.lines.sort((a,b)=>a-b),a.lines=Q(a.lines);let n=[],o=new Map;for(let a of c.methodCalls){let b=P(a.from);if(!e.has(b))continue;let c=`${b}|${a.receiverName}|${a.methodName}`,d=o.get(c);if(d)for(let b of a.lines)d.lines.push(b);else{let d={focalQname:b,receiverName:a.receiverName,methodName:a.methodName,receiverFilePath:a.receiverFilePath,lines:a.lines.slice()};o.set(c,d),n.push(d)}}for(let a of n)a.lines.sort((a,b)=>a-b),a.lines=Q(a.lines);let q=(a,b)=>a.external.filePath.localeCompare(b.external.filePath)||a.external.qualifiedName.localeCompare(b.external.qualifiedName);return j.sort(q),h.sort(q),l.sort((a,b)=>a.external.packageSpec.localeCompare(b.external.packageSpec)||a.external.name.localeCompare(b.external.name)),n.sort((a,b)=>a.receiverName.localeCompare(b.receiverName)||a.methodName.localeCompare(b.methodName)),{filePath:c.path,language:c.language,fileCount:a.files.size,mtimeMs:c.mtime,functions:d,intraCalls:g,externalCalls:l,methodCalls:n,upstreamCalls:j,downstreamCalls:h}}function S(a,b){let c=a.files.get(b);return c?{filePath:c.path,language:c.language,symbols:function a(b){let c=[];for(let d of b)"unknown"!==d.kind&&c.push({...d,children:a(d.children)});return c}(c.symbolsTree)}:null}function T(a){let b="";for(let c=0;c<a.length;c++){let d=a.charCodeAt(c);95!==d&&45!==d&&46!==d&&32!==d&&(b+=d>=65&&d<=90?String.fromCharCode(d+32):a[c])}return b}let ak=(a,b)=>a.rank-b.rank||a.filePath.localeCompare(b.filePath)||a.qname.localeCompare(b.qname)||a.line-b.line;function U(a,b,c){if(a===b)return 0;let d=T(a);return d===c?1:d.startsWith(c)?2:d.includes(c)?3:-1}function V(a,b,c,d={}){let e=b.trim();if(!e)return d.includeLiterals?{files:[],symbols:[],literals:[]}:{files:[],symbols:[]};let f=T(e);if(!f)return d.includeLiterals?{files:[],symbols:[],literals:[]}:{files:[],symbols:[]};let g=Math.min(500,Math.max(0,Math.floor(c)||0)),h=new u.V(g,ak),i=new u.V(g,ak),j=new u.V(g,ak);for(let b of a.files.values()){if(d.directory&&!b.path.startsWith(`${d.directory}/`)||d.excludeTests&&(0,t.h)(b.path))continue;let a=U(b.path,e,f);if(a>=0){let c=U(N(b.path),e,f);h.add({rank:c>=0?Math.min(c,a):a,filePath:b.path,qname:"",line:0,value:b})}for(let a of b.flatSymbols){if("unknown"===a.kind)continue;let c=U(a.name,e,f);c>=0&&i.add({rank:c,filePath:b.path,qname:a.qualifiedName,line:a.declLine,value:a})}if(d.includeLiterals)for(let a of b.literals){let c=U(a.value,e,f);c>=0&&j.add({rank:c,filePath:b.path,qname:a.value,line:a.line,value:a})}}let k=h.sorted().map(({value:a})=>({type:"file",label:N(a.path),hint:a.path,target:{filePath:a.path}})),l=i.sorted().map(({value:a})=>({type:"symbol",label:a.name,hint:`${a.kind} \xb7 ${a.filePath}`,target:O(a)}));if(!d.includeLiterals)return{files:k,symbols:l};let m=j.sorted().map(({filePath:a,value:b})=>({type:"literal",value:b.value,filePath:a,line:b.line,...b.enclosingQname?{enclosingSymbol:b.enclosingQname}:{}}));return{files:k,symbols:l,literals:m}}function W(a,b,c){if(c){let d=a.files.get(c);return d&&d.symbolsByQname.has(b)?[d]:[]}let d=[];for(let c of a.files.values())c.symbolsByQname.has(b)&&d.push(c);return d}function X(a,b,c){let d=W(a,b,c);if(d.length>1)return{qname:b,target:null,callers:[],ambiguousIn:d.map(a=>a.path).sort()};if(0===d.length)return{qname:b,target:null,callers:[]};let e=[],f=new Map;for(let c of d){for(let a of c.intraCalls){if(a.to!==b)continue;let d=c.symbolsByQname.get(a.from);if(!d)continue;let g=`${c.path}|${a.from}`,h=f.get(g);if(h)for(let b of a.lines)h.callLines.push(b);else{let b={caller:O(d),callLines:a.lines.slice()};f.set(g,b),e.push(b)}}for(let d of c.incomingCalls){if(d.to!==b)continue;let c=a.files.get(d.from.filePath),g=c?.symbolsByQname.get(d.from.qualifiedName);if(!g)continue;let h=`${d.from.filePath}|${d.from.qualifiedName}`,i=f.get(h);if(i)for(let a of d.lines)i.callLines.push(a);else{let a={caller:O(g),callLines:d.lines.slice()};f.set(h,a),e.push(a)}}}for(let a of e)a.callLines.sort((a,b)=>a-b),a.callLines=Q(a.callLines);e.sort((a,b)=>a.caller.filePath.localeCompare(b.caller.filePath)||a.caller.qualifiedName.localeCompare(b.caller.qualifiedName));let g=O(d[0].symbolsByQname.get(b));return{qname:b,target:g,callers:e}}function Y(a,b,c){let d=W(a,b,c);if(d.length>1)return{qname:b,target:null,callees:[],ambiguousIn:d.map(a=>a.path).sort()};if(0===d.length)return{qname:b,target:null,callees:[]};let e=[],f=new Map;for(let c of d){for(let a of c.intraCalls){if(a.from!==b)continue;let d=c.symbolsByQname.get(a.to);if(!d)continue;let g=`${c.path}|${a.to}`,h=f.get(g);if(h)for(let b of a.lines)h.callLines.push(b);else{let b={callee:O(d),callLines:a.lines.slice()};f.set(g,b),e.push(b)}}for(let d of c.outgoingCalls){if(d.from!==b)continue;let c=a.files.get(d.to.filePath),g=c?.symbolsByQname.get(d.to.qualifiedName);if(!g)continue;let h=`${d.to.filePath}|${d.to.qualifiedName}`,i=f.get(h);if(i)for(let a of d.lines)i.callLines.push(a);else{let a={callee:O(g),callLines:d.lines.slice()};f.set(h,a),e.push(a)}}}for(let a of e)a.callLines.sort((a,b)=>a-b),a.callLines=Q(a.callLines);e.sort((a,b)=>a.callee.filePath.localeCompare(b.callee.filePath)||a.callee.qualifiedName.localeCompare(b.callee.qualifiedName));let g=O(d[0].symbolsByQname.get(b));return{qname:b,target:g,callees:e}}function Z(a,b,c,d){let e=W(a,b,d);if(e.length>1)return{qname:b,target:null,nodes:[],truncated:!1,ambiguousIn:e.map(a=>a.path).sort()};if(0===e.length)return{qname:b,target:null,nodes:[],truncated:!1};let f=Math.min(Math.max(c,1),5),g=O(e[0].symbolsByQname.get(b)),h=e.map(a=>({filePath:a.path,qname:b})),i=new Set(h.map(a=>`${a.filePath}|${a.qname}`)),j=h.map(b=>{let c=a.files.get(b.filePath).symbolsByQname.get(b.qname);return{symbol:O(c),depth:0}}),k=h.slice(),l=!1;for(let b=1;b<=f;b++){let c=[];for(let d of k){let e=a.files.get(d.filePath);if(e){for(let a of e.intraCalls){if(a.to!==d.qname)continue;let f=e.symbolsByQname.get(a.from);if(!f)continue;let g=`${e.path}|${a.from}`;if(!i.has(g)&&(i.add(g),j.push({symbol:O(f),depth:b}),c.push({filePath:e.path,qname:a.from}),j.length>=500)){l=!0;break}}if(l)break;for(let f of e.incomingCalls){if(f.to!==d.qname)continue;let e=a.files.get(f.from.filePath),g=e?.symbolsByQname.get(f.from.qualifiedName);if(!g)continue;let h=`${f.from.filePath}|${f.from.qualifiedName}`;if(!i.has(h)&&(i.add(h),j.push({symbol:O(g),depth:b}),c.push({filePath:f.from.filePath,qname:f.from.qualifiedName}),j.length>=500)){l=!0;break}}if(l)break}}if(l||0===c.length)break;k=c}return j.sort((a,b)=>a.depth-b.depth||a.symbol.filePath.localeCompare(b.symbol.filePath)||a.symbol.qualifiedName.localeCompare(b.symbol.qualifiedName)),{qname:b,target:g,nodes:j,truncated:l}}d()}catch(a){d(a)}})},45356:(a,b,c)=>{c.d(b,{l:()=>h});var d=c(77598);let e=["resolvedImports","importedFiles","importedBy","intraCalls","outgoingCalls","incomingCalls","externalCalls","methodCalls"];function f(a,b,c){return JSON.stringify([2,a,b,c])}function g(a){return JSON.stringify(e.map(b=>{let c=a[b];return c instanceof Map||c instanceof Set?[...c]:c}))}class h{findParse(a,b,c,d){return this.repositories.get(a)?.parses.get(f(b,c,d))?.value}publish(a,b,c,e){let h=this.repositories.get(b);h||(h={roots:0,parses:new Map,relations:new Map},this.repositories.set(b,h)),h.roots++;let i={repository:b,parses:[],relations:[],bytes:1024+512*c.size};for(let[b,j]of a.files){let a=e.get(b),k=f(b,j.language,c.get(b)),l=h.parses.get(k);!l&&(l={key:k,value:{facts:a,lookups:{symbolsByName:j.symbolsByName,symbolsByQname:j.symbolsByQname,bindingsByLocalName:j.bindingsByLocalName,reexportsByLocalName:j.reexportsByLocalName}},references:0,bytes:Math.max(768+1024*a.flatSymbols.length+96*a.rawCalls.length+192*a.importBindings.length+64*a.importSpecifiers.length+128*a.literals.length,4e3*a.flatSymbols.length/1.25)},h.parses.set(k,l),this.bytes+=l.bytes);e.set(b,l.value.facts);let m=l.value.facts;j.symbolsTree=m.symbolsTree,j.flatSymbols=m.flatSymbols,j.literals=m.literals,j.importBindings=m.importBindings,Object.assign(j,l.value.lookups),l.references++,i.parses.push(l);let n=g(j),o=JSON.stringify([b,(0,d.createHash)("sha256").update(n).digest("hex")]),p=h.relations.get(o)??[],q=p.find(a=>g(a.value)===n);q||(q={key:o,value:{resolvedImports:j.resolvedImports,importedFiles:j.importedFiles,importedBy:j.importedBy,intraCalls:j.intraCalls,outgoingCalls:j.outgoingCalls,incomingCalls:j.incomingCalls,externalCalls:j.externalCalls,methodCalls:j.methodCalls},references:0,bytes:768+2*Buffer.byteLength(n)},p.push(q),h.relations.set(o,p),this.bytes+=q.bytes),Object.assign(j,q.value),q.references++,i.relations.push(q)}this.release(a.cwd),this.leases.set(a.cwd,i),this.bytes+=i.bytes}release(a){let b=this.leases.get(a);if(!b)return;this.leases.delete(a),this.bytes-=b.bytes;let c=this.repositories.get(b.repository);for(let a of(c.roots--,b.parses))0==--a.references&&(c.parses.delete(a.key),this.bytes-=a.bytes);for(let a of b.relations)if(0==--a.references){let b=c.relations.get(a.key);b.splice(b.indexOf(a),1),b.length||c.relations.delete(a.key),this.bytes-=a.bytes}c.roots||this.repositories.delete(b.repository)}has(a){return this.leases.has(a)}estimatedBytes(){return Math.ceil(1.25*this.bytes)}stats(){let a=0,b=0;for(let c of this.repositories.values())for(let d of(a+=c.parses.size,c.relations.values()))b+=d.length;return{roots:this.leases.size,repositories:this.repositories.size,parses:a,relations:b,estimatedBytes:this.estimatedBytes()}}constructor(){this.repositories=new Map,this.leases=new Map,this.bytes=0}}},53809:(a,b,c)=>{c.d(b,{h:()=>d});function d(a){return/(^|\/)(__tests__|tests?)\//i.test(a)||/\.(test|spec|e2e)\.[^/]+$/i.test(a)||/(^|\/)test_[^/]+\.pyi?$/i.test(a)||/[^/]+_test\.go$/i.test(a)}},56476:(a,b,c)=>{function d(a){let b=[];return!function a(c){if("call_expression"===c.type||"call"===c.type){let a=c.childForFieldName("function"),d=function a(b){if(!b)return null;if("identifier"===b.type||"shorthand_property_identifier"===b.type)return b.text;if("member_expression"===b.type){let a=b.childForFieldName("property");return a?.text??null}if("attribute"===b.type){let a=b.childForFieldName("attribute");return a?.text??null}return"call_expression"===b.type||"call"===b.type?a(b.childForFieldName("function")):null}(a);if(d){let e=function(a){if(!a||"member_expression"!==a.type&&"attribute"!==a.type)return;let b=a;for(;b;){if("identifier"===b.type)return b.text;if("this"===b.type||"super"===b.type)break;if("member_expression"===b.type||"attribute"===b.type){b=b.childForFieldName("object");continue}break}}(a);b.push({calleeName:d,line:c.startPosition.row+1,...e?{receiverName:e}:{}})}}else if("jsx_opening_element"===c.type||"jsx_self_closing_element"===c.type){let a=function a(b){return b?"identifier"===b.type?/^[A-Z]/.test(b.text)?b.text:null:"member_expression"===b.type||"jsx_member_expression"===b.type?a(b.childForFieldName("object")??b.namedChild(0)):null:null}(c.childForFieldName("name"));a&&b.push({calleeName:a,line:c.startPosition.row+1})}for(let b=0;b<c.childCount;b++){let d=c.child(b);d&&a(d)}}(a),b}function e(a){let b=[];for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(d)if("import_statement"===d.type){let a=d.childForFieldName("source");a?function(a,b,c){let d=g(b.text),e=null;for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);if(c?.type==="import_clause"){e=c;break}}if(e)for(let a=0;a<e.namedChildCount;a++){let b=e.namedChild(a);if(b){if("identifier"===b.type)c.push({specifier:d,importedName:"default",localName:b.text});else if("namespace_import"===b.type){let a=function(a,b){for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(d?.type===b)return d}return null}(b,"identifier");a&&c.push({specifier:d,importedName:"*",localName:a.text})}else if("named_imports"===b.type)for(let a=0;a<b.namedChildCount;a++){let e=b.namedChild(a);if(!e||"import_specifier"!==e.type)continue;let f=e.childForFieldName("name"),g=e.childForFieldName("alias");f&&c.push({specifier:d,importedName:f.text,localName:g?.text??f.text})}}}}(d,a,b):function(a,b){for(let c=0;c<a.childCount;c++){let d=a.child(c);if(d&&"name"===a.fieldNameForChild(c)){if("dotted_name"===d.type){let a=d.text,c=a.split(".")[0];b.push({specifier:a,importedName:"*",localName:c})}else if("aliased_import"===d.type){let a=d.childForFieldName("name"),c=d.childForFieldName("alias");a?.type==="dotted_name"&&c&&b.push({specifier:a.text,importedName:"*",localName:c.text})}}}}(d,b)}else"import_from_statement"===d.type&&function(a,b){let c=a.childForFieldName("module_name"),d="";if(c){if("dotted_name"===c.type)d=c.text;else if("relative_import"===c.type){let a="",b="";for(let d=0;d<c.namedChildCount;d++){let e=c.namedChild(d);e&&("import_prefix"===e.type?a=e.text:"dotted_name"===e.type&&(b=e.text))}d=a+b}}if(!d)return;let e=!1;for(let c=0;c<a.childCount;c++){let f=a.child(c);if(!f)continue;let g=a.fieldNameForChild(c);if("wildcard_import"===f.type){e=!0;continue}if("name"===g){if("dotted_name"===f.type){let a=f.text;b.push({specifier:d,importedName:a,localName:a})}else if("aliased_import"===f.type){let a=f.childForFieldName("name"),c=f.childForFieldName("alias");a?.type==="dotted_name"&&c&&b.push({specifier:d,importedName:a.text,localName:c.text})}}}e&&b.push({specifier:d,importedName:"*",localName:"*"})}(d,b)}return b}function f(a){let b=[];for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(!d||"export_statement"!==d.type||d.children.some(a=>"type"===a.type))continue;let e=d.childForFieldName("source"),f=e?g(e.text):"",h=(a,c=a)=>{b.push({localName:a,importedName:c,specifier:f,isReexport:!0})},i=null;for(let a=0;a<d.namedChildCount;a++){let b=d.namedChild(a);if(b?.type==="export_clause"){i=b;break}}if(!i){let a=d.namedChildren.find(a=>"namespace_export"===a.type);if(a){let b=a.namedChild(0);b&&h(b.text,"*")}else if(e&&d.children.some(a=>"*"===a.type))h("*");else{let a=d.childForFieldName("declaration");if(a?.type==="interface_declaration"||a?.type==="type_alias_declaration")continue;let b=d.children.some(a=>"default"===a.type);if(a?.type==="lexical_declaration"||a?.type==="variable_declaration")for(let b of a.namedChildren){let a=b.childForFieldName("name");a?.type==="identifier"&&h(a.text)}else{let c=a?.childForFieldName("name")??d.childForFieldName("value");(c?.type==="identifier"||c?.type==="type_identifier")&&h(b?"default":c.text,c.text)}}continue}for(let a=0;a<i.namedChildCount;a++){let b=i.namedChild(a);if(!b||"export_specifier"!==b.type||b.children.some(a=>"type"===a.type))continue;let c=b.childForFieldName("name"),d=b.childForFieldName("alias");if(!c)continue;let e=c.text;h(d?.text??e,e)}}return b}function g(a){return a.length>=2&&('"'===a[0]||"'"===a[0])&&a[a.length-1]===a[0]?a.slice(1,-1):a}c.d(b,{Lv:()=>d,il:()=>f,jv:()=>e})},64949:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{g:()=>h});var e=c(33265),f=c(88395),g=a([e]);e=(g.then?(await g)():g)[0];let i=!1;function h(){i||(i=!0,(0,e.NV)(),(0,e.ih)((a,b)=>f.t.subscribe(a,a=>{a.some(a=>"file"===a.type||"git"===a.type)&&b()})))}d()}catch(a){d(a)}})},75775:(a,b,c)=>{c.d(b,{FI:()=>p,P3:()=>u,SD:()=>t,U0:()=>x,XC:()=>B,ax:()=>z,jR:()=>v,po:()=>C,xq:()=>D,yj:()=>o});var d=c(31421),e=c(77598),f=c(73024),g=c(76760),h=c.n(g),i=c(57975),j=c(89705),k=c(69181),l=c(770),m=c(28677);let n=(0,i.promisify)(d.execFile),o=1e5,p=2097152;async function q(a){let b=await j.pR5(j.gPK(a));if(k.OC(b))throw b.left;return b.right}async function r(a,b){return q(j.$mh({try:()=>n("git",b,{cwd:a,maxBuffer:0x3200000}).then(a=>a.stdout),catch:a=>new l.uV({message:"Code index Git command failed",cause:a})}))}function s(a){return!a.split("/").some(a=>"node_modules"===a||".git"===a)}function t(a){return s(a)&&(0,m.cn)().includes(h().posix.extname(a).toLowerCase())}async function u(a){return q(j.$mh({try:async()=>{let[b,...c]=(await n("git",["rev-parse","--is-inside-work-tree","--absolute-git-dir"],{cwd:a})).stdout.trimEnd().split("\n");if("true"!==b)throw Error("Not a Git working tree");return c.join("\n")},catch:a=>/not a git repository/i.test(a.stderr??"")||"Not a Git working tree"===a.message?new l.yI({field:"cwd",reason:"Non-Git projects are not supported"}):new l.uV({message:"Unable to inspect Git project",cause:a})}))}async function v(a){return await u(a),[...new Set((await r(a,["ls-files","--cached","--others","--exclude-standard","-z"])).split("\0").filter(a=>a&&s(a)))].sort()}async function w(a){return q(j.$mh({try:a,catch:a=>a}).pipe(j.h9N(a=>"ENOENT"===a.code?j.PyW(null):j.fJG(new l.uU({path:"code-index scan",op:"read",cause:a})))))}async function x(a){let b=await u(a),c=(await r(a,["rev-parse","--path-format=absolute","--git-common-dir"])).trimEnd(),d=await q(j.$mh({try:()=>f.promises.realpath(c),catch:a=>new l.uU({path:c,op:"read",cause:a})})),e=await Promise.all(["index.lock","rebase-merge","rebase-apply","MERGE_HEAD","CHERRY_PICK_HEAD","REVERT_HEAD"].map(a=>w(()=>f.promises.stat(h().join(b,a))))),g=await q(j.$mh({try:()=>n("git",["rev-parse","--verify","--quiet","HEAD"],{cwd:a}).then(a=>a.stdout.trim()),catch:a=>a}).pipe(j.h9N(a=>1===a.code?j.PyW("unborn"):j.fJG(new l.uV({message:"Unable to read Git HEAD",cause:a}))))),i=await r(a,["ls-files","--unmerged","-z"]);return{head:g,busy:e.some(Boolean)||i.length>0,commonDir:d}}let y=a=>(0,e.createHash)("sha256").update(a).digest("hex");async function z(a,b){let c=h().join(a,b);return w(async()=>{let[a,b]=await Promise.all([f.promises.readFile(c),f.promises.stat(c)]);return{source:a.toString("utf8"),hash:y(a),mtime:b.mtimeMs,sizeBytes:a.length}})}function A(a){return/(^|\/)(tsconfig[^/]*\.json|package\.json|pnpm-workspace\.yaml|go\.mod|\.gitignore)$/.test(a)}async function B(a,b=!1){let c=await x(a);if(c.busy&&!b)throw new l.uV({message:"Workspace is changing: finish the Git operation or explicitly rebuild the index"});let d=await v(a),e=d.filter(t),f=e.slice(0,o),g=new Map,h=new Map,i=0,j=!1,k=(await Promise.allSettled(Array.from({length:Math.min(8,f.length)},async()=>{for(;!j&&i<f.length;){let b=f[i++],c=await z(a,b).catch(a=>{throw j=!0,a});c&&(g.set(b,c),h.set(b,c.hash))}}))).find(a=>"rejected"===a.status);if(k?.status==="rejected")throw k.reason;for(let a of e.slice(o))h.set(a,"not-scanned");let m=new Map,n=new Map;for(let b of[...new Set([...d.filter(A),"tsconfig.json","package.json","pnpm-workspace.yaml","go.mod"])].sort())await z(a,b).then(a=>{a&&(m.set(b,a.hash),n.set(b,a.source))});let p=y(JSON.stringify([...m])),q={paths:[...new Set([...d,...n.keys()])],readFile:async a=>{let b=g.get(a)?.source??n.get(a);if(void 0!==b)return b;throw new l.uU({path:a,op:"read",cause:Object.assign(Error(`File not captured: ${a}`),{code:"ENOENT"})})}};return{sources:g,hashes:h,configHash:p,truncated:e.length>o,git:c,contextFiles:q}}function C(a,b){let c=[],d=[],e=[];for(let[e,f]of b)a.has(e)?a.get(e)!==f&&d.push(e):c.push(e);for(let c of a.keys())b.has(c)||e.push(c);let f=c.length+d.length+e.length,g=Math.max(a.size,b.size);return{added:c,changed:d,deleted:e,count:f,rebuild:f>=500||f>=20&&f/g>=.2}}function D(a,b){return a instanceof l.uV||a instanceof l.uU||a instanceof l.yI?a:new l.uV({message:b,cause:a})}},83624:(a,b,c)=>{c.d(b,{Hs:()=>n,NZ:()=>f,YN:()=>o,_B:()=>m,mG:()=>l,qj:()=>e});var d=c(56476);function e(a){let b=0xdeadbeef,c=0x41c6ce57;for(let d=0;d<a.length;d++){let e=a.charCodeAt(d);b=Math.imul(b^e,0x9e3779b1),c=Math.imul(c^e,0x5f356495)}return b=Math.imul(b^b>>>16,0x85ebca6b)^Math.imul(c^c>>>13,0xc2b2ae35),(0x100000000*(2097151&(c=Math.imul(c^c>>>16,0x85ebca6b)^Math.imul(b^b>>>13,0xc2b2ae35)))+(b>>>0)>>>0).toString(16)}function f(a){return a.replace(/\s+/g," ").trim()}function g(a,b){return a?`${a}>${b}`:b}function h(a){let b=a.childForFieldName("name");if(b)return b.text;for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);if(c&&("identifier"===c.type||"type_identifier"===c.type||"property_identifier"===c.type))return c.text}return"<anonymous>"}function i(a,b,c,d,h=[],j){return{qualifiedName:g(d,b),name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:function(a){for(let b=0;b<a.childCount;b++){let c=a.child(b);if(c&&"decorator"!==c.type&&"comment"!==c.type)return c.startPosition.row}return a.startPosition.row}(a)+1,contentHash:e(f(a.text)),children:h,params:j}}function j(a){let b=a.childForFieldName("parameter");if(b)return[b.text];let c=a.childForFieldName("parameters");if(!c)return;let d=[];for(let a=0;a<c.namedChildCount;a++){let b=c.namedChild(a);b&&d.push(function a(b){switch(b.type){case"required_parameter":case"optional_parameter":{let c=b.childForFieldName("pattern");return c?a(c):b.text}case"assignment_pattern":{let c=b.childForFieldName("left");return c?a(c):b.text}case"default_parameter":case"typed_default_parameter":{let a=b.childForFieldName("name");return a?a.text:b.text}case"typed_parameter":for(let a=0;a<b.namedChildCount;a++){let c=b.namedChild(a);if(c?.type==="identifier")return c.text}return b.text;default:return b.text}}(b))}return d}let k={theorem:"function",def:"function",abbrev:"function",example:"function",instance:"const",structure:"class",inductive:"type",axiom:"const",opaque:"const",constant:"const"};function l(a,b){for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(d?.type!=="export_statement")continue;let e=d.childForFieldName("declaration");if(!e||e.startPosition.row===d.startPosition.row)continue;let f=e.startPosition.row+1;for(let a of b)"unknown"!==a.kind&&a.startLine===f&&(a.startLine=d.startPosition.row+1)}let c=new Map;for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);if(!d||!function(a){if("attribute_item"===a.type)return!0;if(!a.type.endsWith("comment"))return!1;for(let b=0;b<a.namedChildCount;b++)if(a.namedChild(b)?.type==="inner_doc_comment_marker")return!1;return!0}(d))continue;let e=0===d.endPosition.column&&d.endPosition.row>d.startPosition.row?d.endPosition.row-1:d.endPosition.row;c.set(e+1,d)}if(0===c.size)return;let d=new Set;for(let a of b)for(let b=a.startLine;b<=a.endLine;b++)d.add(b);for(let a of b){if("unknown"===a.kind)continue;let b=a.startLine;for(;;){let a=c.get(b-1);if(!a)break;let e=a.startPosition.row+1,f=!1;for(let a=e;a<=b-1;a++)if(d.has(a)){f=!0;break}if(f)break;b=e}if(b!==a.startLine){for(let c=b;c<a.startLine;c++)d.add(c);a.startLine=b}}}function m(a,b){let c=a.text.split("\n"),d=c.length;if(0===d)return[];let g=new Uint8Array(d+2);for(let a of b){let b=Math.max(1,a.startLine),c=Math.min(d,a.endLine);for(let a=b;a<=c;a++)g[a]=1}let h=[],i=(a,b)=>{let d=!1;for(let e=a;e<=b;e++){let a=c[e-1];if(a&&a.trim().length>0){d=!0;break}}if(!d)return;let g=c.slice(a-1,b).join("\n");h.push({qualifiedName:`__code_${a}_${b}__`,name:"code",kind:"unknown",startLine:a,endLine:b,declLine:a,contentHash:e(f(g)),children:[]})},j=-1;for(let a=1;a<=d;a++)g[a]?j>=0&&(i(j,a-1),j=-1):j<0&&(j=a);return j>=0&&i(j,d),h}function n(a,b){let c=[],n=function(a){let b=[],c=-1,d=-1;for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(f){if("import_statement"===f.type||"export_statement"===f.type&&null!==f.childForFieldName("source")||"import_from_statement"===f.type||"future_import_statement"===f.type||"import"===f.type)b.push(f),c<0&&(c=f.startPosition.row+1),d=f.endPosition.row+1;else if(c>=0)break}}return c<0?null:{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:d,declLine:c,contentHash:e(f(b.map(a=>a.text).join("\n"))),children:[]}}(a);if(n&&c.push(n),"lean"===b)c.push(...function(a){let b=[],c=[];for(let d=0;d<a.namedChildCount;d++){let g=a.namedChild(d);if(!g)continue;switch(g.type){case"namespace":c.push(g.childForFieldName("name")?.text??null);continue;case"section":c.push(null);continue;case"end":c.pop();continue}let h=null;if("declaration"===g.type)for(let a=0;a<g.namedChildCount;a++){let b=g.namedChild(a);if(b&&b.type in k){h=b;break}}else g.type in k&&(h=g);if(!h)continue;let i=h.childForFieldName("name")?.text??h.type,j=c.filter(a=>null!==a);b.push({qualifiedName:[...j,i].join("."),name:i,kind:k[h.type],startLine:g.startPosition.row+1,endLine:function(a){let b=a.endPosition.row+1,c=a.text.replace(/\s+$/,""),d=a.text.slice(c.length);if(!d)return b;let e=d.split("\n").length-1;return Math.max(a.startPosition.row+1,b-e)}(g),declLine:h.startPosition.row+1,contentHash:e(f(g.text)),children:[]})}return b}(a));else for(let b=0;b<a.namedChildCount;b++){let k=a.namedChild(b);k&&c.push(...function a(b,c,k=!1){switch(b.type){case"export_statement":case"export_default_declaration":{let d=[];for(let e=0;e<b.namedChildCount;e++){let f=b.namedChild(e);f&&d.push(...a(f,c,!0))}return d}case"function_declaration":case"generator_function_declaration":case"function_definition":return[i(b,h(b),"function",c,[],j(b))];case"class_declaration":case"abstract_class_declaration":{let a=h(b),d=g(c,a),e=function(a,b){if(!a)return[];let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e){if("method_definition"===e.type)c.push(i(e,h(e),"method",b,[],j(e)));else if("public_field_definition"===e.type){let a=e.childForFieldName("value");a&&("arrow_function"===a.type||"function_expression"===a.type)&&c.push(i(e,h(e),"method",b,[],j(a)))}}}return c}(b.childForFieldName("body"),d);return[i(b,a,"class",c,e)]}case"interface_declaration":return[i(b,h(b),"interface",c)];case"type_alias_declaration":return[i(b,h(b),"type",c)];case"enum_declaration":return[i(b,h(b),"enum",c)];case"lexical_declaration":case"variable_declaration":return function(a,b){let c=[];for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(!f||"variable_declarator"!==f.type)continue;let g=f.childForFieldName("name"),k=f.childForFieldName("value");if(!g)continue;let l=g.text,m=function a(b,c=0){if(!b||c>8)return null;if("arrow_function"===b.type||"function_expression"===b.type)return b;if(["parenthesized_expression","as_expression","satisfies_expression","non_null_expression"].includes(b.type))return a(b.namedChild(0),c+1);if("call_expression"!==b.type)return null;let e=b.childForFieldName("function");if(!e)return null;let f="member_expression"===e.type?e.childForFieldName("object"):null,g=f?.type==="identifier"?f.text:"identifier"===e.type?e.text:null;if(!g)return null;let h=b;for(;h.parent;)h=h.parent;let i=(0,d.jv)(h).find(a=>a.localName===g);if(!i)return null;let j=f?e.childForFieldName("property")?.text:i.importedName,k="*"===i.importedName||"default"===i.importedName;return(!f||k)&&("@cockpit/effect-runtime/server"===i.specifier?"handler"===j||"dynamicHandler"===j:"react"===i.specifier&&["memo","forwardRef","useCallback"].includes(j??""))?a(b.childForFieldName("arguments")?.namedChild(0)??null,c+1):null}(k),n=null!==m,o=m?j(m):void 0;if(c.push(i(a,l,n?"function":"const",b,[],o)),k&&"object"===k.type&&!n){let a=b?`${b}>${l}`:l;for(let b=0;b<k.namedChildCount;b++){let d=k.namedChild(b);if(d){if("pair"===d.type){let b=d.childForFieldName("key"),e=d.childForFieldName("value");if(!b||!e||"property_identifier"!==b.type&&"identifier"!==b.type||"arrow_function"!==e.type&&"function_expression"!==e.type)continue;c.push(i(d,b.text,"method",a,[],j(e)))}else if("method_definition"===d.type){let b=h(d);b&&c.push(i(d,b,"method",a,[],j(d)))}}}}}return c}(b,c);case"class_definition":{let a=h(b),d=g(c,a),k=function a(b,c){if(!b)return[];let d=[];for(let k=0;k<b.namedChildCount;k++){let l=b.namedChild(k);if(l){if("function_definition"===l.type)d.push(i(l,h(l),"method",c,[],j(l)));else if("decorated_definition"===l.type){let b=l.childForFieldName("definition");if(b?.type==="function_definition")d.push({...i(b,h(b),"method",c,[],j(b)),startLine:l.startPosition.row+1,contentHash:e(f(l.text))});else if(b?.type==="class_definition"){let j=h(b),k=g(c,j),m=a(b.childForFieldName("body"),k);d.push({...i(b,j,"class",c,m),startLine:l.startPosition.row+1,contentHash:e(f(l.text))})}}else if("class_definition"===l.type){let b=h(l),e=g(c,b),f=a(l.childForFieldName("body"),e);d.push(i(l,b,"class",c,f))}}}return d}(b.childForFieldName("body"),d);return[i(b,a,"class",c,k)]}case"decorated_definition":{let d=b.childForFieldName("definition");if(!d)return[];return a(d,c,!1).map(a=>({...a,startLine:b.startPosition.row+1,contentHash:e(f(b.text))}))}case"expression_statement":{let a=[];for(let d=0;d<b.namedChildCount;d++){let h=b.namedChild(d);if(h?.type==="assignment"){let d=function(a,b,c){let d=b.childForFieldName("left");if(!d||"identifier"!==d.type)return null;let h=d.text;return{qualifiedName:g(c,h),name:h,kind:"const",startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:a.startPosition.row+1,contentHash:e(f(a.text)),children:[]}}(b,h,c);d&&a.push(d)}}return a.push(...function(a,b){let c=null;for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);if(d){if("call_expression"===d.type){c=d;break}if("await_expression"===d.type){for(let a=0;a<d.namedChildCount;a++){let b=d.namedChild(a);if(b?.type==="call_expression"){c=b;break}}break}}}if(!c)return[];let d=c.childForFieldName("function"),e=c.childForFieldName("arguments");if(!d||!e)return[];let f=null,g=[];for(let a=0;a<e.namedChildCount;a++){let b=e.namedChild(a);if(b){if(null===f&&("string"===b.type||"template_string"===b.type)){let a=b.text;f=a.length>=2&&/^["'`]/.test(a)?a.slice(1,-1):a}("arrow_function"===b.type||"function_expression"===b.type)&&g.push(b)}}if(0===g.length||!f)return[];let h=function a(b){if("identifier"===b.type)return b.text;if("member_expression"===b.type){let a=b.childForFieldName("property");return a?.text??""}if("call_expression"===b.type){let c=b.childForFieldName("function");return c?a(c):""}return""}(d),k=h?`${h} ${f}`:f;return g.map((a,c)=>i(a,g.length>1?`${k} #${c+1}`:k,"function",b,[],j(a)))}(b,c)),a}default:return[]}}(k,void 0,!1))}return l(a,c),c.push(...m(a,c)),o(c),c}function o(a){let b=new Map,c=a=>{for(let d of a){let a=(b.get(d.qualifiedName)??0)+1;b.set(d.qualifiedName,a),a>1&&(d.qualifiedName=`${d.qualifiedName}#${a}`),c(d.children)}};c(a)}},85836:(a,b,c)=>{c.d(b,{V:()=>d});class d{constructor(a,b){this.limit=a,this.compare=b,this.heap=[]}add(a){if(this.limit<=0)return;if(this.heap.length<this.limit){this.heap.push(a);let b=this.heap.length-1;for(;b>0;){let a=b-1>>>1;if(0>=this.compare(this.heap[b],this.heap[a]))break;[this.heap[b],this.heap[a]]=[this.heap[a],this.heap[b]],b=a}return}if(this.compare(a,this.heap[0])>=0)return;this.heap[0]=a;let b=0;for(;;){let a=2*b+1;if(a>=this.heap.length)break;let c=a+1,d=c<this.heap.length&&this.compare(this.heap[c],this.heap[a])>0?c:a;if(0>=this.compare(this.heap[d],this.heap[b]))break;[this.heap[b],this.heap[d]]=[this.heap[d],this.heap[b]],b=d}}sorted(){return this.heap.slice().sort(this.compare)}}},86236:(a,b,c)=>{c.d(b,{I:()=>d});let d=new Set(["typescript","tsx","javascript","python","go","rust","lean"])},87956:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{M:()=>j,b:()=>i});var e=c(12629),f=c(76760),g=c.n(f),h=a([e]);e=(h.then?(await h)():h)[0];let k=g().join(process.cwd(),"public","tree-sitter"),l=null,m=new Map,n=new Map;async function i(a){let b,c=n.get(a);if(c)return c;let d=await (!(b=m.get(a))&&(b=(async()=>(await (!l&&(l=e.Parser.init({locateFile:a=>g().join(k,a)})),l),e.Language.load(g().join(k,`tree-sitter-${a}.wasm`))))(),m.set(a,b)),b);return(c=new e.Parser).setLanguage(d),n.set(a,c),c}function j(a){switch(a.slice(a.lastIndexOf(".")).toLowerCase()){case".ts":return"typescript";case".tsx":case".jsx":return"tsx";case".js":case".mjs":case".cjs":return"javascript";case".py":case".pyi":return"python";case".go":return"go";case".rs":return"rust";case".lean":return"lean";default:return null}}d()}catch(a){d(a)}})},88395:(a,b,c)=>{c.d(b,{t:()=>j});var d=c(29021),e=c(33873);let f=[".git/HEAD",".git/MERGE_HEAD",".git/REBASE_HEAD"],g=[".git/refs"];class h{subscribe(a,b){let c=this.watchers.get(a);return c||(c=this.createWatcher(a),this.watchers.set(a,c)),c.listeners.add(b),()=>{this.unsubscribe(a,b)}}unsubscribe(a,b){let c=this.watchers.get(a);if(c&&(c.listeners.delete(b),0===c.listeners.size)){for(let a of(c.debounceTimer&&clearTimeout(c.debounceTimer),c.throttleTimer&&clearTimeout(c.throttleTimer),c.cwdRestartTimer&&clearTimeout(c.cwdRestartTimer),c.watchers))try{a.close()}catch{}this.watchers.delete(a)}}createWatcher(a){let b={watchers:[],listeners:new Set,pendingEvents:[],debounceTimer:null,throttleTimer:null,cwdRestartTimer:null},c=a=>{b.pendingEvents.some(b=>b.type===a.type)||b.pendingEvents.push(a),b.debounceTimer&&clearTimeout(b.debounceTimer),b.debounceTimer=setTimeout(()=>{this.flush(b)},500),b.throttleTimer||(b.throttleTimer=setTimeout(()=>{this.flush(b)},3e3))},h=()=>{try{let e=(0,d.watch)(a,{recursive:!0},(a,b)=>{if(b&&!(b.startsWith(".next/")||b.startsWith("node_modules/"))){if(b.startsWith(".git/")){(".git/HEAD"===b||b.startsWith(".git/refs/"))&&c({type:"git"});return}c({type:"file"})}});e.on("error",c=>{console.error(`File watcher error for ${a}:`,c);let d=b.watchers.indexOf(e);-1!==d&&b.watchers.splice(d,1);try{e.close()}catch{}b.listeners.size>0&&!b.cwdRestartTimer&&(b.cwdRestartTimer=setTimeout(()=>{b.cwdRestartTimer=null,b.listeners.size>0&&h()},2e3))}),b.watchers.push(e)}catch(b){console.error(`Failed to watch ${a}:`,b)}};h();let i=function(a){let b=(0,e.join)(a,".git");try{if((0,d.statSync)(b).isDirectory())return b;let c=(0,d.readFileSync)(b,"utf-8").trim().match(/^gitdir:\s*(.+)$/);if(c)return(0,e.resolve)(a,c[1])}catch{}return b}(a),j=a=>{try{let e=(0,d.watch)(a,()=>{c({type:"git"});try{e.close()}catch{}let d=b.watchers.indexOf(e);-1!==d&&b.watchers.splice(d,1),b.listeners.size>0&&setTimeout(()=>j(a),50)});e.on("error",()=>{let c=b.watchers.indexOf(e);-1!==c&&b.watchers.splice(c,1),b.listeners.size>0&&(0,d.existsSync)(a)&&setTimeout(()=>j(a),500)}),b.watchers.push(e)}catch{}};for(let a of f){let b=a.replace(".git/","");j((0,e.join)(i,b))}let k=function(a){try{let b=(0,d.readFileSync)((0,e.join)(a,"commondir"),"utf-8").trim();if(b)return(0,e.resolve)(a,b)}catch{}return a}(i);for(let a of g){let f=a.replace(".git/","");try{let a=(0,d.watch)((0,e.join)(k,f),{recursive:!0},()=>{c({type:"git"})});a.on("error",()=>{}),b.watchers.push(a)}catch{}}return b}flush(a){if(a.debounceTimer&&(clearTimeout(a.debounceTimer),a.debounceTimer=null),a.throttleTimer&&(clearTimeout(a.throttleTimer),a.throttleTimer=null),0===a.pendingEvents.length)return;let b=[...a.pendingEvents];for(let c of(a.pendingEvents=[],a.listeners))try{c(b)}catch(a){console.error("File watcher callback error:",a)}}constructor(){this.watchers=new Map}}let i=globalThis,j=i.__cockpitFileWatcher??(i.__cockpitFileWatcher=new h)}};
1
+ "use strict";exports.id=4949,exports.ids=[4949],exports.modules={4410:(a,b,c)=>{c.d(b,{Bu:()=>d.Bu,iv:()=>d.iv});var d=c(28677),e=c(76760),f=c.n(e),g=c(83624),h=c(56476);function i(a){let b=[];function c(a){if(!a||"string"!==a.type)return null;for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);if(c&&"string_fragment"===c.type)return c.text}return""}return!function a(d){switch(d.type){case"import_statement":case"export_statement":{let a=c(d.childForFieldName("source"));a&&b.push(a);return}case"call_expression":{let a=d.childForFieldName("function");if(a){let e="import"===a.type,f="identifier"===a.type&&"require"===a.text;if(e||f){let a=d.childForFieldName("arguments");if(a&&a.namedChildCount>0){let d=c(a.namedChild(0));d&&b.push(d)}}}}}for(let b=0;b<d.namedChildCount;b++){let c=d.namedChild(b);c&&a(c)}}(a),b}function j(a,b){return/^\.+$/.test(a)?a+b:`${a}.${b}`}let k={typescript:i,tsx:i,javascript:i,python:function(a){let b=[];return!function a(c){switch(c.type){case"import_statement":for(let a=0;a<c.childCount;a++){let d=c.child(a);if(d&&"name"===c.fieldNameForChild(a)){if("dotted_name"===d.type)b.push(d.text);else if("aliased_import"===d.type){let a=d.childForFieldName("name");a?.type==="dotted_name"&&b.push(a.text)}}}return;case"import_from_statement":{let a=function(a){let b=a.childForFieldName("module_name");if(!b)return"";if("dotted_name"===b.type)return b.text;if("relative_import"===b.type){let a="",c="";for(let d=0;d<b.namedChildCount;d++){let e=b.namedChild(d);e&&("import_prefix"===e.type?a=e.text:"dotted_name"===e.type&&(c=e.text))}return a+c}return""}(c);if(!a)return;b.push(a);for(let d=0;d<c.childCount;d++){let e=c.child(d);if(!e||"name"!==c.fieldNameForChild(d))continue;let f="aliased_import"===e.type?e.childForFieldName("name"):e;f?.type==="dotted_name"&&b.push(j(a,f.text))}return}}for(let b=0;b<c.namedChildCount;b++){let d=c.namedChild(b);d&&a(d)}}(a),b}};function l(a,b){let c=k[b];return c?c(a):[]}var m=c(25344);function n(a){return"function"===a||"class"===a||"method"===a}function o(a,b,c,d,e){let f=JSON.stringify([a.path,b]);if(c>5||d.has(f))return null;let g=new Set(d).add(f),h=(b,d)=>{let f=a.resolvedImports.get(b.specifier),h=f&&e.get(f);return h?o(h,d,c+1,g,e):null},i=a.reexportsByLocalName.get(b);if(i&&"*"!==b){if(i.specifier)return h(i,i.importedName);let b=a.symbolsByName.get(i.importedName),c=null;for(let a of b??[])!a.qualifiedName.includes(">")&&(!c||n(a.kind)&&!n(c.kind)||a.kind===c.kind&&a.endLine-a.startLine>c.endLine-c.startLine)&&(c=a);if(c)return c;let d=a.bindingsByLocalName.get(i.importedName);return d?h(d,d.importedName):null}if("default"===b)return null;let j=null;for(let c of a.importBindings){if(!c.isReexport||"*"!==c.localName||"*"!==c.importedName)continue;let a=h(c,b);if("ambiguous"===a)return a;if(a){if(j&&(j.filePath!==a.filePath||j.qualifiedName!==a.qualifiedName))return"ambiguous";j=a}}return j}function p(a,b){return{grammarId:a,extensions:b,extractSymbols:(a,b)=>(0,g.Hs)(a),extractImports:b=>({specs:l(b,a),bindings:[...(0,h.jv)(b),...(0,h.il)(b)]}),extractCallSites:(a,b)=>(0,h.Lv)(a),async buildProjectContext(a,b,c){let d=new Set(b),e=await (0,m.ZT)(a,c),f=await (0,m.zC)(a,d,c),g=[...f.keys()].sort((a,b)=>b.length-a.length);return{cwd:a,tsconfigs:e,workspaces:f,sortedWsNames:g,owningScopesCache:new Map}},resolveSpecifier(a,b,c,d){let e=c.owningScopesCache.get(b);if(e||(e=c.tsconfigs.filter(a=>(0,m._0)(b,a.scope)),c.owningScopesCache.set(b,e)),a.startsWith("./")||a.startsWith("../"))return(0,m.KP)(f().resolve(c.cwd,f().dirname(b),a),c.cwd,d);if(a.startsWith("/"))return(0,m.KP)(f().resolve(c.cwd,a.slice(1)),c.cwd,d);for(let b of e){let e=b.sortedAliases.find(([b])=>a===b||a.startsWith(b+"/"));if(!e)continue;let[g,h]=e,i=a===g?"":a.slice(g.length+1),j=(0,m.KP)(f().resolve(c.cwd,h,i),c.cwd,d);if(j)return j}for(let b of c.sortedWsNames){if(a!==b&&!a.startsWith(b+"/"))continue;let e=c.workspaces.get(b);if(a===b)return e.entryFile;let g=a.slice(b.length+1);return(0,m.IS)(f().posix.join(e.dir,g),d)??(0,m.IS)(f().posix.join(e.dir,"src",g),d)}return null},resolveCall(a,b,c,d,e){if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(!b)return[];let e=c.resolvedImports.get(b.specifier);if(!e)return[];let f=d.get(e);if(!f)return[];let g=function a(b,c,d,e,f,g){if(e>5)return null;if("*"===c){let a=o(b,d,e,f,g);return a&&"ambiguous"!==a&&n(a.kind)?a:null}let h=JSON.stringify([b.path,c,d]);if(f.has(h))return null;let i=new Set(f).add(h),j=b.reexportsByLocalName.get(c);if(j?.specifier&&"*"===j.importedName){let c=b.resolvedImports.get(j.specifier),f=c&&g.get(c);return f?a(f,"*",d,e+1,i,g):null}let k=o(b,c,e,i,g);if(!k||"ambiguous"===k)return null;let l=g.get(k.filePath),m=l?.symbolsByQname.get(`${k.qualifiedName}>${d}`);return m&&n(m.kind)?m:null}(f,b.importedName,a.calleeName,0,new Set,d);return g?[{kind:"symbol",addr:{filePath:g.filePath,qualifiedName:g.qualifiedName}}]:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let f=c.symbolsByName.get(a.calleeName);if(f&&f.length>0){let a=[];for(let c of f)c.qualifiedName!==b.qualifiedName&&n(c.kind)&&a.push({kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}});return a}let g=c.bindingsByLocalName.get(a.calleeName);if(!g)return[];let h=c.resolvedImports.get(g.specifier);if(!h)return[{kind:"external",name:g.importedName,packageSpec:g.specifier}];let i=d.get(h);if(!i)return[];let j=o(i,g.importedName,0,new Set,d);return j&&"ambiguous"!==j&&n(j.kind)?[{kind:"symbol",addr:{filePath:j.filePath,qualifiedName:j.qualifiedName}}]:[]},moduleForFile:(a,b)=>a}}let q=p("typescript",[".ts"]),r=p("tsx",[".tsx",".jsx"]),s=p("javascript",[".js",".mjs",".cjs"]);function t(a){return"function"===a||"class"===a||"method"===a}function u(a,b,c){if("*"!==b){let d=`${b}>${c}`,e=a.symbolsByQname.get(d);if(e&&t(e.kind))return e}if("*"===b){let b=a.symbolsByName.get(c);if(b){let a=null;for(let c of b)!c.qualifiedName.includes(">")&&t(c.kind)&&(!a||c.endLine-c.startLine>a.endLine-a.startLine)&&(a=c);if(a)return a}}return null}function v(a,b,c){let d=b.replace(/\./g,"/"),e=(...a)=>a.filter(a=>""!==a&&"."!==a).join("/");if(!d){let b=e(a,"__init__.py");return c.has(b)?b:null}let f=e(a,d+".py");if(c.has(f))return f;let g=e(a,d,"__init__.py");return c.has(g)?g:null}var w=c(73024);function x(a,b,c,d,e=[],f){return{qualifiedName:d?`${d}>${b}`:b,name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:a.startPosition.row+1,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function y(a){let b=a.childForFieldName("parameters");if(!b)return;let c=[];for(let a=0;a<b.namedChildCount;a++){let d=b.namedChild(a);if(d){if("parameter_declaration"===d.type){let a=d.childForFieldName("name");if(!a){c.push("_");continue}if("identifier"===a.type)c.push(a.text);else if("identifier_list"===a.type)for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);d?.type==="identifier"&&c.push(d.text)}else c.push(a.text)}else if("variadic_parameter_declaration"===d.type){let a=d.childForFieldName("name");a?.type==="identifier"?c.push(`...${a.text}`):c.push("...")}}}return c}async function z(a,b){try{let c=b?await b.readFile("go.mod"):await w.promises.readFile(f().join(a,"go.mod"),"utf8"),d=/^\s*module\s+(\S+)/m.exec(c);return d?d[1].trim():null}catch{return null}}function A(a){return"function"===a||"class"===a||"method"===a}function B(a,b,c,d,e=[],f){return{qualifiedName:d?`${d}>${b}`:b,name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:a.startPosition.row+1,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function C(a){let b=a.childForFieldName("parameters");if(!b)return;let c=[];for(let a=0;a<b.namedChildCount;a++){let d=b.namedChild(a);if(d)if("self_parameter"===d.type)c.push(d.text);else if("parameter"===d.type){let a=d.childForFieldName("pattern");a?c.push(a.text):c.push("_")}else"variadic_parameter"===d.type&&c.push("...")}return c}async function D(a,b,c){let d=new Map,e=new Map,g=new Set;async function h(i,j){let k;if(g.has(j))return;g.add(j),d.set(i,j),e.set(j,i);try{k=c?await c.readFile(j):await w.promises.readFile(f().join(a,j),"utf8")}catch{return}let l=function(a){let b,c=a.replace(/\/\*[\s\S]*?\*\//g,"").replace(/\/\/.*$/gm,"").replace(/"(?:\\.|[^"\\\n])*"/g,'""'),d=[],e=/\b(?:pub(?:\s*\([^)]*\))?\s+)?mod\s+(\w+)\s*;/g;for(;null!==(b=e.exec(c));)d.push(b[1]);return d}(k);if(0===l.length)return;let m=f().posix.dirname(j),n=f().posix.basename(j,".rs"),o="mod"===n||"lib"===n||"main"===n?[m]:[m,f().posix.join(m,n)];for(let a of l){let c=`${i}::${a}`,d=null;for(let c of o){for(let e of[f().posix.join(c,`${a}.rs`),f().posix.join(c,a,"mod.rs")]){let a=e.startsWith("./")?e.slice(2):e;if(b.has(a)){d=a;break}}if(d)break}d&&await h(c,d)}}for(let a of function(a){let b=[];for(let c of a)("src/lib.rs"===c||"src/main.rs"===c||c.endsWith("/src/lib.rs")||c.endsWith("/src/main.rs")||/^src\/bin\/[^/]+\.rs$/.test(c)||/\/src\/bin\/[^/]+\.rs$/.test(c))&&b.push(c);return b}(b))if("src/lib.rs"===a||"src/main.rs"===a)await h("crate",a);else if(a.startsWith("src/bin/"))await h("crate",a);else{let b=a.split("/"),c=b.indexOf("src");if(c>0){let d=b[c-1];await h(d,a)}}return{modTree:d,fileToMod:e}}function E(a){return"function"===a||"class"===a||"method"===a}(0,d.ik)(q),(0,d.ik)(r),(0,d.ik)(s),(0,d.ik)({grammarId:"python",extensions:[".py",".pyi"],extractSymbols:(a,b)=>(0,g.Hs)(a),extractImports:a=>({specs:l(a,"python"),bindings:(0,h.JM)(a)}),extractCallSites:(a,b)=>(0,h.Lv)(a),buildProjectContext(a,b){let c=[a],d=!1;if(b.has("src/__init__.py"))d=!0;else for(let a of b)if(a.startsWith("src/")&&a.endsWith(".py")){d=!0;break}return d&&c.push(f().join(a,"src")),{cwd:a,pythonRoots:c}},resolveSpecifier(a,b,c,d){let e=/^(\.+)/.exec(a);if(e){let c=e[1].length,g=a.slice(c),h=f().dirname(b);for(let a=1;a<c;a++)h=f().dirname(h);return v(h||".",g,d)}for(let b of c.pythonRoots){let e=v(f().relative(c.cwd,b)||".",a,d);if(e)return e}return null},resolveCall(a,b,c,d,e){if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(!b)return[];let e=c.resolvedImports.get(b.specifier),f=e?d.get(e):void 0,g="*"!==b.importedName?c.resolvedImports.get(j(b.specifier,b.importedName)):void 0,h=g?d.get(g):void 0;if(!f&&!h)return[];let i=(f?u(f,b.importedName,a.calleeName):null)??(h?u(h,"*",a.calleeName):null);return i?[{kind:"symbol",addr:{filePath:i.filePath,qualifiedName:i.qualifiedName}}]:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let f=c.symbolsByName.get(a.calleeName);if(f&&f.length>0){let a=[];for(let c of f)c.qualifiedName!==b.qualifiedName&&t(c.kind)&&a.push({kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}});return a}let g=c.bindingsByLocalName.get(a.calleeName);if(!g)return[];let h=c.resolvedImports.get(g.specifier);if(!h)return[{kind:"external",name:g.importedName,packageSpec:g.specifier}];let i=d.get(h);if(!i)return[];let k=function(a,b){let c=a.symbolsByName.get(b);if(!c)return null;let d=null;for(let a of c)t(a.kind)&&(!d||a.endLine-a.startLine>d.endLine-d.startLine)&&(d=a);return d}(i,g.importedName);return k?[{kind:"symbol",addr:{filePath:k.filePath,qualifiedName:k.qualifiedName}}]:[]},moduleForFile:(a,b)=>a}),(0,d.ik)({grammarId:"go",extensions:[".go"],extractSymbols(a,b){let c=[],d=function(a){let b=[],c=-1,d=-1;for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(f){if("import_declaration"===f.type)b.push(f),c<0&&(c=f.startPosition.row+1),d=f.endPosition.row+1;else if("package_clause"===f.type)continue;else if(c>=0)break}}if(c<0)return null;let e=b.map(a=>a.text).join("\n");return{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:d,declLine:c,contentHash:(0,g.qj)((0,g.NZ)(e)),children:[]}}(a);d&&c.push(d);let{symbols:e,pendingMethods:f}=function(a){let b=[],c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e)switch(e.type){case"function_declaration":{let a=e.childForFieldName("name");if(!a)break;b.push(x(e,a.text,"function",void 0,[],y(e)));break}case"method_declaration":{let a=e.childForFieldName("name");if(!a)break;let d=function(a){let b=a.childForFieldName("receiver");if(!b)return null;for(let a=0;a<b.namedChildCount;a++){let c=b.namedChild(a);if(c?.type!=="parameter_declaration")continue;let d=c.childForFieldName("type");if(!d)break;return function a(b){if("type_identifier"===b.type)return b.text;if("pointer_type"===b.type){for(let c=0;c<b.namedChildCount;c++){let d=b.namedChild(c);if(d){let b=a(d);if(b)return b}}return null}if("generic_type"===b.type){let c=b.childForFieldName("type");if(c)return a(c)}return null}(d)}return null}(e),f=x(e,a.text,"method",d??void 0,[],y(e));d?c.push({receiverType:d,symbol:f}):b.push(f);break}case"type_declaration":b.push(...function(a,b){let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e&&("type_spec"===e.type||"type_alias"===e.type)){let a=e.childForFieldName("name"),d=e.childForFieldName("type");if(!a)continue;let f=a.text,g=d?.type==="interface_type"?"interface":"class";c.push(x(e,f,g,b))}}return c}(e,void 0));break;case"var_declaration":case"const_declaration":b.push(...function(a,b){let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e&&("var_spec"===e.type||"const_spec"===e.type)){let a=e.childForFieldName("name");if(!a)continue;if("identifier_list"===a.type)for(let d=0;d<a.namedChildCount;d++){let f=a.namedChild(d);f?.type==="identifier"&&c.push(x(e,f.text,"const",b))}else"identifier"===a.type&&c.push(x(e,a.text,"const",b))}}return c}(e,void 0))}}return{symbols:b,pendingMethods:c}}(a);return c.push(...function(a,b){if(0===b.length)return a;let c=new Map;for(let b of a)("class"===b.kind||"interface"===b.kind)&&c.set(b.name,b);let d=[];for(let a of b){let b=c.get(a.receiverType);b?b.children=[...b.children,a.symbol]:d.push(a.symbol)}return[...a,...d]}(e,f)),(0,g.mG)(a,c),c.push(...(0,g._B)(a,c)),c},extractImports:a=>(function(a){let b=[],c=[];function d(a){var d;let e,f=a.childForFieldName("path");if(!f)return;let g=(d=f.text).length>=2&&('"'===d[0]||"'"===d[0]||"`"===d[0])&&d[d.length-1]===d[0]?d.slice(1,-1):d;if(!g)return;b.push(g);let h=a.childForFieldName("name");if(h)e=h.text;else{let a=g.split("/");e=a[a.length-1]||g}c.push({specifier:g,importedName:"*",localName:e})}return!function a(b){if("import_declaration"===b.type){for(let a=0;a<b.namedChildCount;a++){let c=b.namedChild(a);if(c){if("import_spec"===c.type)d(c);else if("import_spec_list"===c.type)for(let a=0;a<c.namedChildCount;a++){let b=c.namedChild(a);b?.type==="import_spec"&&d(b)}}}return}for(let c=0;c<b.namedChildCount;c++){let d=b.namedChild(c);d&&a(d)}}(a),{specs:b,bindings:c}})(a),extractCallSites:(a,b)=>{let c;return c=[],!function a(b){if("call_expression"===b.type){let a=b.childForFieldName("function"),d=function a(b){if(!b)return null;if("identifier"===b.type)return b.text;if("selector_expression"===b.type){let a=b.childForFieldName("field");return a?.text??null}return"call_expression"===b.type?a(b.childForFieldName("function")):null}(a);if(d){let e=function(a){if(!a||"selector_expression"!==a.type)return;let b=a;for(;b;){if("identifier"===b.type)return b.text;if("selector_expression"===b.type){b=b.childForFieldName("operand");continue}break}}(a);c.push({calleeName:d,line:b.startPosition.row+1,...e?{receiverName:e}:{}})}}for(let c=0;c<b.childCount;c++){let d=b.child(c);d&&a(d)}}(a),c},async buildProjectContext(a,b,c){let d=await z(a,c);return{cwd:a,modulePath:d,dirToGoFiles:function(a){let b=new Map;for(let c of a){if(!c.endsWith(".go"))continue;let a=f().dirname(c),d=b.get(a);d?d.push(c):b.set(a,[c])}return b}(b)}},resolveSpecifier(a,b,c,d){if(!c.modulePath)return null;if(a===c.modulePath){let a=c.dirToGoFiles.get(".");return a?.[0]??null}if(a.startsWith(c.modulePath+"/")){let b=a.slice(c.modulePath.length+1),d=c.dirToGoFiles.get(b);return d?.[0]??null}return null},resolveCall(a,b,c,d,e){let g=f().dirname(c.path),h=e.dirToGoFiles.get(g)??[c.path];if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(b){let g=c.resolvedImports.get(b.specifier);if(!g)return[{kind:"external",name:a.calleeName,packageSpec:b.specifier}];let h=f().dirname(g);for(let b of e.dirToGoFiles.get(h)??[]){let c,e=d.get(b);if(!e)continue;let f=e.symbolsByName.get(a.calleeName);if(f){for(let a of f)if(!a.qualifiedName.includes(">")&&A(a.kind)){c=a;break}if(c)return[{kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}}]}}return[{kind:"external",name:a.calleeName,packageSpec:b.specifier}]}let g=`${a.receiverName}>${a.calleeName}`;for(let a of h){let b=d.get(a);if(!b)continue;let c=b.symbolsByQname.get(g);if(c&&A(c.kind))return[{kind:"symbol",addr:{filePath:c.filePath,qualifiedName:c.qualifiedName}}]}return[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let i=[];for(let c of h){let e=d.get(c);if(!e)continue;let f=e.symbolsByName.get(a.calleeName);if(f)for(let a of f)!(a.qualifiedName===b.qualifiedName||a.qualifiedName.includes(">"))&&A(a.kind)&&i.push({kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}})}return i},moduleForFile(a,b){let c=f().dirname(a);return b?.modulePath?"."===c?b.modulePath:`${b.modulePath}/${c}`:c}}),(0,d.ik)({grammarId:"rust",extensions:[".rs"],extractSymbols(a,b){let c=[],d=function(a){let b=[],c=-1,d=-1;for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(f){if("use_declaration"===f.type||"extern_crate_declaration"===f.type)b.push(f),c<0&&(c=f.startPosition.row+1),d=f.endPosition.row+1;else if(c>=0)break}}if(c<0)return null;let e=b.map(a=>a.text).join("\n");return{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:d,declLine:c,contentHash:(0,g.qj)((0,g.NZ)(e)),children:[]}}(a);d&&c.push(d);let{symbols:e,pendingImpls:f}=function(a){let b=[],c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e)switch(e.type){case"function_item":{let a=e.childForFieldName("name");if(!a)break;b.push(B(e,a.text,"function",void 0,[],C(e)));break}case"struct_item":case"union_item":{let a=e.childForFieldName("name");if(!a)break;b.push(B(e,a.text,"class",void 0));break}case"enum_item":{let a=e.childForFieldName("name");if(!a)break;b.push(B(e,a.text,"enum",void 0));break}case"trait_item":{let a=e.childForFieldName("name");if(!a)break;let c=function(a,b){let c=a.childForFieldName("body");if(!c)return[];let d=[];for(let a=0;a<c.namedChildCount;a++){let e=c.namedChild(a);if(e&&("function_item"===e.type||"function_signature_item"===e.type)){let a=e.childForFieldName("name");if(!a)continue;d.push(B(e,a.text,"method",b,[],C(e)))}}return d}(e,a.text);b.push(B(e,a.text,"interface",void 0,c));break}case"impl_item":{let a=function(a){let b=a.childForFieldName("type");return b?function a(b){if("type_identifier"===b.type)return b.text;if("generic_type"===b.type){let c=b.childForFieldName("type");if(c)return a(c)}if("reference_type"===b.type)for(let c=0;c<b.namedChildCount;c++){let d=b.namedChild(c);if(d){let b=a(d);if(b)return b}}if("scoped_type_identifier"===b.type){let a=b.childForFieldName("name");if(a?.type==="type_identifier")return a.text}return null}(b):null}(e);if(!a)break;let b=function(a,b){let c=a.childForFieldName("body");if(!c)return[];let d=[];for(let a=0;a<c.namedChildCount;a++){let e=c.namedChild(a);if(e){if("function_item"===e.type){let a=e.childForFieldName("name");if(!a)continue;d.push(B(e,a.text,"method",b,[],C(e)))}else if("function_signature_item"===e.type){let a=e.childForFieldName("name");if(!a)continue;d.push(B(e,a.text,"method",b,[],C(e)))}}}return d}(e,a);b.length>0&&c.push({targetType:a,methods:b});break}case"const_item":case"static_item":{let a=e.childForFieldName("name");if(!a)break;b.push(B(e,a.text,"const",void 0));break}case"type_item":{let a=e.childForFieldName("name");if(!a)break;b.push(B(e,a.text,"type",void 0));break}case"mod_item":{let a=e.childForFieldName("name"),c=e.childForFieldName("body");if(!a||!c)break;b.push(B(e,a.text,"class",void 0))}}}return{symbols:b,pendingImpls:c}}(a);return c.push(...function(a,b){if(0===b.length)return a;let c=new Map;for(let b of a)("class"===b.kind||"enum"===b.kind||"interface"===b.kind)&&c.set(b.name,b);let d=[];for(let a of b){let b=c.get(a.targetType);b?b.children=[...b.children,...a.methods]:d.push(...a.methods)}return[...a,...d]}(e,f)),(0,g.mG)(a,c),c.push(...(0,g._B)(a,c)),c},extractImports:a=>(function(a){let b=[],c=[];function d(a){if("identifier"===a.type||"crate"===a.type||"self"===a.type||"super"===a.type)return a.text;if("scoped_identifier"===a.type){let b=a.childForFieldName("path"),c=a.childForFieldName("name"),e=b?d(b):"",f=c?.text??"";return e?`${e}::${f}`:f}return a.text}function e(a,b){return a?b?`${a}::${b}`:a:b}function f(a){let b=a.split("::");return b[b.length-1]??a}return!function a(g){if("use_declaration"===g.type)return void function(a){for(let g=0;g<a.namedChildCount;g++){let h=a.namedChild(g);h&&function a(g,h){switch(g.type){case"use_as_clause":{let a=g.childForFieldName("path"),i=g.childForFieldName("alias");if(a&&i){let g=e(h,d(a));b.push(g),c.push({specifier:g,importedName:f(g),localName:i.text})}break}case"use_list":for(let b=0;b<g.namedChildCount;b++){let c=g.namedChild(b);c&&a(c,h)}break;case"scoped_use_list":{let b=g.childForFieldName("path"),c=g.childForFieldName("list"),f=b?e(h,d(b)):h;if(c)for(let b=0;b<c.namedChildCount;b++){let d=c.namedChild(b);d&&a(d,f)}break}case"use_wildcard":{let a=g.childForFieldName("path"),f=a?e(h,d(a)):h;f&&(b.push(f),c.push({specifier:f,importedName:"*",localName:"*"}));break}case"identifier":case"self":case"super":case"crate":case"scoped_identifier":{let a=e(h,d(g));a&&(b.push(a),c.push({specifier:a,importedName:f(a),localName:f(a)}))}}}(h,"")}}(g);if("extern_crate_declaration"===g.type){let a=g.childForFieldName("name");a&&(b.push(a.text),c.push({specifier:a.text,importedName:"*",localName:a.text}));return}if("mod_item"===g.type){let a=g.childForFieldName("body"),c=g.childForFieldName("name");!a&&c&&b.push(c.text);return}for(let b=0;b<g.namedChildCount;b++){let c=g.namedChild(b);c&&a(c)}}(a),{specs:b,bindings:c}})(a),extractCallSites:(a,b)=>{let c;return c=[],!function a(b){if("call_expression"===b.type){let a=b.childForFieldName("function"),d=function(a){if(!a)return null;if("identifier"===a.type)return a.text;if("scoped_identifier"===a.type){let b=a.childForFieldName("name");return b?.text??null}if("field_expression"===a.type){let b=a.childForFieldName("field");return b?.text??null}return null}(a);if(d){let e=function(a){if(a){if("scoped_identifier"===a.type){let b=a;for(;b;){if("identifier"===b.type)return b.text;if("scoped_identifier"===b.type){b=b.childForFieldName("path");continue}break}}if("field_expression"===a.type){let b=a.childForFieldName("value");if(b?.type==="identifier")return b.text}}}(a);c.push({calleeName:d,line:b.startPosition.row+1,...e?{receiverName:e}:{}})}}else if("method_call_expression"===b.type){let a=b.childForFieldName("method"),d=b.childForFieldName("value");if(a){let e=d?.type==="identifier"?d.text:void 0;c.push({calleeName:a.text,line:b.startPosition.row+1,...e?{receiverName:e}:{}})}}for(let c=0;c<b.childCount;c++){let d=b.child(c);d&&a(d)}}(a),c},async buildProjectContext(a,b,c){let{modTree:d,fileToMod:e}=await D(a,b,c);return{cwd:a,modTree:d,fileToMod:e}},resolveSpecifier(a,b,c,d){let e=c.fileToMod.get(b);if(!e)return null;let f=function(a,b){if(a.startsWith("crate::"))return a;if("crate"===a)return"crate";if(a.startsWith("self::"))return`${b}::${a.slice(6)}`;if("self"===a)return b;if(a.startsWith("super::")){let c=b,d=a;for(;d.startsWith("super::");){let a=c.lastIndexOf("::");if(a<0)return null;c=c.slice(0,a),d=d.slice(7)}if("super"===d){let a=c.lastIndexOf("::");return a<0?null:c.slice(0,a)}return d?`${c}::${d}`:c}return null}(a,e);if(!f)return null;if(c.modTree.has(f))return c.modTree.get(f);let g=f.split("::");for(;g.length>1;){g.pop();let a=g.join("::"),b=c.modTree.get(a);if(b)return b}return null},resolveCall(a,b,c,d,e){let f;if(a.receiverName){let b=c.bindingsByLocalName.get(a.receiverName);if(b){let e=c.resolvedImports.get(b.specifier);if(!e)return[{kind:"external",name:a.calleeName,packageSpec:b.specifier}];let f=d.get(e);if(!f)return[];let g=f.symbolsByName.get(a.calleeName);if(g){for(let a of g)if(!a.qualifiedName.includes(">")&&E(a.kind))return[{kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}}]}let h=`${b.importedName}>${a.calleeName}`,i=f.symbolsByQname.get(h);return i&&E(i.kind)?[{kind:"symbol",addr:{filePath:i.filePath,qualifiedName:i.qualifiedName}}]:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let e=`${a.receiverName}>${a.calleeName}`,f=c.symbolsByQname.get(e);if(f)return[{kind:"symbol",addr:{filePath:f.filePath,qualifiedName:f.qualifiedName}}];let g=[],h=c.symbolsByName.get(a.calleeName);if(h)for(let a of h)"method"===a.kind&&g.push({kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}});return g.length>0?g:[{kind:"method-unresolved",receiverName:a.receiverName,methodName:a.calleeName}]}let g=[],h=c.symbolsByName.get(a.calleeName);if(h)for(let a of h)!(a.qualifiedName===b.qualifiedName||a.qualifiedName.includes(">"))&&E(a.kind)&&g.push({kind:"symbol",addr:{filePath:a.filePath,qualifiedName:a.qualifiedName}});if(g.length>0)return g;let i=c.bindingsByLocalName.get(a.calleeName);if(!i)return[];let j=c.resolvedImports.get(i.specifier);if(!j)return[{kind:"external",name:i.importedName,packageSpec:i.specifier}];let k=d.get(j);if(!k)return[];let l=k.symbolsByName.get(i.importedName);if(l){for(let a of l)if(!a.qualifiedName.includes(">")&&E(a.kind)){f=a;break}}return f?[{kind:"symbol",addr:{filePath:f.filePath,qualifiedName:f.qualifiedName}}]:[]},moduleForFile:(a,b)=>b?.fileToMod.get(a)??f().posix.dirname(a)}),(0,d.ik)({grammarId:"lean",extensions:[".lean"],extractSymbols:(a,b)=>(0,g.Hs)(a,"lean"),extractImports:a=>({specs:[],bindings:[]}),extractCallSites:(a,b)=>[],buildProjectContext(){},resolveSpecifier:()=>null,resolveCall:()=>[],moduleForFile:a=>a.replace(/\.lean$/i,"").replace(/[/\\]/g,".")})},25157:(a,b,c)=>{c.d(b,{d:()=>i});let d=globalThis,e=d.__cockpitGraphProgressListeners??(d.__cockpitGraphProgressListeners=new Map),f=d.__cockpitGraphProgressLastFrame??(d.__cockpitGraphProgressLastFrame=new Map),g=d.__cockpitGraphProgressLastEmitAt??(d.__cockpitGraphProgressLastEmitAt=new Map),h={listing:[0,3],contexts:[3,6],parsing:[6,85],resolving:[85,92],edges:[92,99],done:[100,100]};function i(a,b,c=0,d=0,j,k=!1){let l=e.get(a),m=Date.now();if(!k&&m-(g.get(a)??0)<100)return;g.set(a,m);let n={cwd:a,phase:b,filesDone:c,filesTotal:d,...j?{currentFile:j}:{},percent:function(a,b,c){let[d,e]=h[a];return"parsing"!==a||c<=0?d:Math.min(e,d+(e-d)*b/c)}(b,c,d)};if("done"===b?(f.delete(a),g.delete(a)):f.set(a,n),l&&0!==l.size)for(let a of l)try{a(n)}catch{}}},25344:(a,b,c)=>{c.d(b,{BE:()=>i,IS:()=>p,KP:()=>l,ZT:()=>r,_0:()=>m,zC:()=>n});var d=c(73024),e=c(76760),f=c.n(e),g=c(75775);function h(a,b,c){return c?c.readFile(b):d.promises.readFile(f().join(a,b),"utf8")}let i=g.yj,j=[".ts",".tsx",".js",".jsx",".mjs",".cjs"],k=[".js",".jsx",".mjs",".cjs"];function l(a,b,c){let d=f().relative(b,a).split(f().sep).join("/");if(d.startsWith(".."))return null;for(let a of k)if(d.endsWith(a)){d=d.slice(0,-a.length);break}if(c.has(d))return d;for(let a of j){let b=d+a;if(c.has(b))return b}for(let a of j){let b=f().posix.join(d,"index"+a);if(c.has(b))return b}return null}function m(a,b){return""===b||a===b||a.startsWith(b+"/")}async function n(a,b,c){let d=await o(a,c);if(0===d.length)return new Map;let e=(c?.paths??await (0,g.jR)(a)).filter(a=>a.endsWith("/package.json")).filter(a=>{let b=a.slice(0,-13);return d.some(a=>{var c;return c=b,RegExp("^"+a.replace(/\\/g,"/").replace(/[.+^${}()|[\]]/g,"\\$&").replace(/\*\*/g,"___DOUBLESTAR___").replace(/\*/g,"[^/]*").replace(/___DOUBLESTAR___/g,".*")+"$").test(c)})}),i=new Map;for(let d of e){let e;try{e=JSON.parse(await h(a,d,c))}catch{continue}if("string"!=typeof e.name)continue;let g=f().dirname(d),j=function(a,b,c){let d,e=b=>{let d=b.replace(/^\.\//,"");return p(f().posix.join(a,d),c)},g=b.exports;if("string"==typeof g)d=g;else if(g&&"object"==typeof g&&g["."]){let a=g["."];"string"==typeof a?d=a:a&&"object"==typeof a&&(d=a.types??a.import??a.default??a.require)}if("string"==typeof d){let a=e(d);if(a)return a}if("string"==typeof b.main){let a=e(b.main);if(a)return a}for(let b of["src/index.ts","src/index.tsx","index.ts","index.tsx","src/index.js","index.js"])if(c.has(f().posix.join(a,b)))return f().posix.join(a,b);return null}(g,e,b);i.set(e.name,{name:e.name,dir:g,entryFile:j})}return i}async function o(a,b){try{var c=await h(a,"pnpm-workspace.yaml",b);let d=[],e=!1;for(let a of c.split("\n")){let b=a.replace(/#.*$/,"");if(/^packages\s*:/.test(b)){e=!0;continue}if(!e)continue;let c=b.match(/^\s*-\s*['"]?([^'"#\s]+)['"]?\s*$/);c?d.push(c[1]):/^\S/.test(b)&&(e=!1)}return d}catch{}try{let c=JSON.parse(await h(a,"package.json",b)),d=c?.workspaces;if(Array.isArray(d))return d.filter(a=>"string"==typeof a);if(d&&Array.isArray(d.packages))return d.packages.filter(a=>"string"==typeof a)}catch{}return[]}function p(a,b){if(a.startsWith("..")||a.startsWith("/"))return null;for(let b of k)if(a.endsWith(b)){a=a.slice(0,-b.length);break}if(b.has(a))return a;for(let c of j){let d=a+c;if(b.has(d))return d}for(let c of j){let d=f().posix.join(a,"index"+c);if(b.has(d))return d}return null}async function q(a,b,c){let d,e=new Map;try{let e=(await h(b,f().relative(b,a).split(f().sep).join("/"),c)).replace(/^\s*\/\/.*$/gm,"");d=JSON.parse(e)}catch{return e}let g=d?.compilerOptions?.baseUrl??".",i=d?.compilerOptions?.paths??{},j=f().resolve(f().dirname(a),g),k=f().relative(b,j)||".";for(let[a,b]of Object.entries(i)){if(!Array.isArray(b)||0===b.length)continue;let c=a.replace(/\/\*$/,""),d=b[0].replace(/\/\*$/,"");e.set(c,f().join(k,d))}return e}async function r(a,b){let c=[];for(let d of(b?.paths??await (0,g.jR)(a)).filter(a=>/(^|\/)tsconfig[^/]*\.json$/.test(a))){let e=await q(f().join(a,d),a,b);if(0===e.size)continue;let g=f().dirname(d);c.push({scope:"."===g?"":g,aliases:e,sortedAliases:s(e)})}let d=c.find(a=>""===a.scope);return d||(d={scope:"",aliases:new Map,sortedAliases:[]},c.push(d)),d.aliases.has("@")||(d.aliases.set("@","./src"),d.sortedAliases=s(d.aliases)),c.sort((a,b)=>b.scope.length-a.scope.length)}function s(a){return[...a.entries()].sort(([a],[b])=>b.length-a.length)}},27485:(a,b,c)=>{c.d(b,{_:()=>e});let d=new Set(["function","class","method"]);function e(a){return d.has(a.kind)}},28677:(a,b,c)=>{c.d(b,{Bu:()=>f,cn:()=>h,ik:()=>e,iv:()=>g});let d=new Map;function e(a){d.set(a.grammarId,a)}function f(a){let b=d.get(a);if(!b)throw Error(`[codeMap] no handler registered for grammar '${a}' — did the handler module get imported (handlers/index.ts barrel)?`);return b}function g(a){return d.get(a)}function h(){let a=new Set;for(let b of d.values())for(let c of b.extensions)a.add(c.toLowerCase());return[...a]}},33265:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{E:()=>T,J:()=>$,KE:()=>K,Mv:()=>Z,NV:()=>C,Xn:()=>Y,_7:()=>X,bQ:()=>W,ih:()=>D,lG:()=>I,tI:()=>L,u$:()=>H,uV:()=>J});var e,f=c(78877),g=c(58500),h=c(89705),i=c(15825),j=c(770),k=c(75775),l=c(87956),m=c(86236),n=c(25344),o=c(25157),p=c(27485),q=c(4410),r=c(83624),s=c(45356),t=c(53809),u=c(85836),v=c(52166),w=a([l]);async function x(a,b,c){let d,e=Array(a.length),f=0,i=!1,j=performance.now();async function k(){for(;!i&&f<a.length&&(!d&&performance.now()-j>=8&&(d=h.pR5(h.ivC(()=>(0,g.setImmediate)())).then(()=>{j=performance.now(),d=void 0})),d&&await d,!i&&!(f>=a.length));){let b=f++;e[b]=await c(a[b]).catch(a=>{throw i=!0,a})}}let l=(await Promise.allSettled(Array.from({length:Math.min(b,a.length)},k))).find(a=>"rejected"===a.status);if(l?.status==="rejected")throw l.reason;return e}l=(w.then?(await w)():w)[0];let _=/(['"`])([A-Za-z][A-Za-z0-9_.-]{2,63})\1/g;async function y(a,b){let c=(0,l.M)(a);if(!c)return null;let{source:d}=b;if(b.sizeBytes>k.FI)return null;let e=(await (0,l.b)(c)).parse(d);if(!e)throw new j.uV({message:`Unable to parse ${a}`});try{let b,f=(0,q.Bu)(c),g=f.extractSymbols(e.rootNode,d);(0,r.YN)(g);let h=(b=[],!function c(d){for(let e of d)b.push({filePath:a,qualifiedName:e.qualifiedName,name:e.name,kind:e.kind,startLine:e.startLine,endLine:e.endLine,declLine:e.declLine,params:e.params}),c(e.children)}(g),b),i=(0,v.s)(e.rootNode,c,h);for(let a of h){let b=i.get(a.qualifiedName);void 0!==b&&(a.complexity=b)}let{specs:j,bindings:k}=f.extractImports(e.rootNode),l=f.extractCallSites(e.rootNode,h),m=function(a,b){let c,d=[],e=new Set,f=[0];for(let b=0;b<a.length;b++)10===a.charCodeAt(b)&&f.push(b+1);for(_.lastIndex=0;null!==(c=_.exec(a))&&!(d.length>=500);){let a=c[2],g=function(a){let b=0,c=f.length-1;for(;b<c;){let d=b+c+1>>>1;f[d]<=a?b=d:c=d-1}return b+1}(c.index),h=`${a}\u0000${g}`;if(e.has(h))continue;e.add(h);let i=z(b,g);d.push({value:a,line:g,...i?{enclosingQname:i.qualifiedName}:{}})}return d}(d,h);return{path:a,language:c,symbolsTree:g,flatSymbols:h,importBindings:k,importSpecifiers:j,rawCalls:l,literals:m}}finally{e.delete()}}function z(a,b){let c=null;for(let d of a)d.startLine<=b&&b<=d.endLine&&(!c||d.endLine-d.startLine<c.endLine-c.startLine)&&(c=d);return c}let aa=new WeakMap;async function A(a,b,c,d=!1){let e=Date.now(),f=c&&aa.get(c),g=(0,k.po)(f?.hashes??new Map,b.hashes),h=d||g.rebuild||f?.configHash!==b.configHash||f?.git.head!==b.git.head||f?.git.busy!==b.git.busy||f?.git.commonDir!==b.git.commonDir,i=[...b.sources.keys()].sort(),j=b.truncated,p=new Set(i);(0,o.d)(a,"contexts",0,i.length,void 0,!0);let r=await (0,n.ZT)(a,b.contextFiles),s=await (0,n.zC)(a,p,b.contextFiles),t=new Map;for(let c of m.I){let d=(0,q.iv)(c);d&&t.set(c,await d.buildProjectContext(a,p,b.contextFiles))}let u=i.length,v=0,w=0;(0,o.d)(a,"parsing",0,u,void 0,!0);let B=new Map,C=new Map,D=(await x(i,50,async c=>{let e=!d&&f?.git.commonDir===b.git.commonDir&&f?.hashes.get(c)===b.hashes.get(c)&&f?.facts.has(c),g=(0,l.M)(c),h=d||e||!g?void 0:ac.findParse(b.git.commonDir,c,g,b.hashes.get(c));h&&C.set(c,h);let i=e?f.facts.get(c):h?.facts??await y(c,b.sources.get(c));return!e&&!h&&w++,B.set(c,i),v++,(0,o.d)(a,"parsing",v,u,c),i})).filter(a=>null!==a);(0,o.d)(a,"resolving",u,u,void 0,!0);let E=new Map;for(let a of D){let d=(0,q.Bu)(a.language),e=t.get(a.language),g=new Map,h=new Set;for(let b of a.importSpecifiers){if(g.has(b))continue;let c=d.resolveSpecifier(b,a.path,e,p);c&&c!==a.path&&(g.set(b,c),h.add(c))}let i=(f?.facts.get(a.path)===a?c?.files.get(a.path):void 0)??C.get(a.path)?.lookups,j=i?.symbolsByName??new Map,k=i?.symbolsByQname??new Map;for(let b of i?[]:a.flatSymbols){k.set(b.qualifiedName,b);let a=j.get(b.name);a?a.push(b):j.set(b.name,[b])}let l=i?.bindingsByLocalName??new Map,m=i?.reexportsByLocalName??new Map;for(let b of i?[]:a.importBindings)b.isReexport?m.set(b.localName,b):l.set(b.localName,b);E.set(a.path,{path:a.path,language:a.language,mtime:b.sources.get(a.path).mtime,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:h,importedBy:new Set,importBindings:a.importBindings,resolvedImports:g,intraCalls:[],outgoingCalls:[],incomingCalls:[],externalCalls:[],methodCalls:[],symbolsByName:j,symbolsByQname:k,bindingsByLocalName:l,reexportsByLocalName:m})}for(let a of E.values())for(let b of a.importedFiles){let c=E.get(b);c&&c.importedBy.add(a.path)}for(let b of((0,o.d)(a,"edges",u,u,void 0,!0),D)){let a=E.get(b.path),c=(0,q.Bu)(b.language),d=t.get(b.language),e=new Map,f=new Map,g=new Map,h=new Map;for(let i of b.rawCalls){let b=z(a.flatSymbols,i.line);if(b){for(let j of c.resolveCall(i,b,a,E,d))if("symbol"===j.kind)if(j.addr.filePath===a.path){let c=`${b.qualifiedName}${j.addr.qualifiedName}`,d=e.get(c);if(d)d.lines.push(i.line);else{let d={from:b.qualifiedName,to:j.addr.qualifiedName,lines:[i.line]};e.set(c,d),a.intraCalls.push(d)}}else{let c=`${b.qualifiedName}${j.addr.filePath}${j.addr.qualifiedName}`,d=f.get(c);if(d)d.lines.push(i.line);else{let d={from:b.qualifiedName,to:{filePath:j.addr.filePath,qualifiedName:j.addr.qualifiedName},lines:[i.line]};f.set(c,d),a.outgoingCalls.push(d)}}else if("external"===j.kind){let c=`${b.qualifiedName}${j.packageSpec}${j.name}`,d=g.get(c);if(d)d.lines.push(i.line);else{let d={from:b.qualifiedName,packageSpec:j.packageSpec,importedName:j.name,lines:[i.line]};g.set(c,d),a.externalCalls.push(d)}}else if("method-unresolved"===j.kind){let c=a.bindingsByLocalName.get(j.receiverName),d=c?a.resolvedImports.get(c.specifier)??"":"",e=`${b.qualifiedName}${j.receiverName}${j.methodName}`,f=h.get(e);if(f)f.lines.push(i.line);else{let c={from:b.qualifiedName,receiverName:j.receiverName,methodName:j.methodName,receiverFilePath:d,lines:[i.line]};h.set(e,c),a.methodCalls.push(c)}}}}for(let b of a.intraCalls)b.lines.sort((a,b)=>a-b);for(let b of a.outgoingCalls)b.lines.sort((a,b)=>a-b);for(let b of a.externalCalls)b.lines.sort((a,b)=>a-b);for(let b of a.methodCalls)b.lines.sort((a,b)=>a-b)}for(let a of E.values())for(let b of a.outgoingCalls){let c=E.get(b.to.filePath);c&&c.incomingCalls.push({from:{filePath:a.path,qualifiedName:b.from},to:b.to.qualifiedName,lines:b.lines})}let F={cwd:a,files:E,truncated:j,fileCountCap:j?n.BE:void 0,excludedFiles:i.flatMap(a=>{let c=b.sources.get(a);return c.sizeBytes>k.FI?[{filePath:a,reason:"source-too-large",sizeBytes:c.sizeBytes,limitBytes:k.FI}]:[]}),tsconfigs:r,workspaces:s,projectContexts:t,fileSet:p,generatedAt:Date.now(),buildMs:Date.now()-e,revision:(c?.revision??0)+1,update:{mode:c?h?"rebuild":"incremental":"initial",changedFiles:g.count,parsedFiles:w}};return F.truncated||=D.length<i.length,aa.set(F,{hashes:b.hashes,configHash:b.configHash,scanTruncated:b.truncated,git:b.git,facts:B}),F}let ab=new Map,ac=new s.l,ad=new Map,ae=new Map;function B(a){let b=0;for(let c of a.files.values())b+=c.flatSymbols.length;return b}let af=(e=(0,f.getHeapStatistics)().heap_size_limit,Math.max(1e9,Math.min(e-0x40000000,0x80000000))),ag="5 minutes",ah=!1;function C(){ah||(ah=!0,h.MY7(h.OH5(()=>{!function(a=Date.now()){let b=a-9e5,c=[];for(let[d,e]of[...ab]){if(ae.has(d))continue;let f=ad.get(d)??0;f>=b||(G(d),c.push(d),console.log(`[codeIndex] released idle ${d} (${B(e)} symbols, unread for ${Math.round((a-f)/6e4)} min)`))}for(let a of ad.keys())ab.has(a)||ad.delete(a)}()}).pipe(h.cbG(ag),h.uxO(i.ji(ag)))))}let ai=new Map,aj=new Map,ak=null;function D(a){for(let[b,c]of(ak=a,ai))c.unsubscribe?.(),c.unsubscribe=a?.(b,()=>E(b))}function E(a){let b=ai.get(a);b&&b.version++}function F(a,b){ab.delete(a),ab.set(a,b),ad.set(a,Date.now())}function G(a){ac.release(a),ab.delete(a),ad.delete(a),aj.delete(a);let b=ai.get(a);b&&(b.generation++,b.retired=!0,b.unsubscribe?.(),b.unsubscribe=void 0,ae.has(a)||ai.delete(a))}async function H(a,b={}){let c,d=((c=ai.get(a))?c.retired&&(c.retired=!1,c.unsubscribe=ak?.(a,()=>E(a))):(c={version:0,publishedVersion:-1,generation:0,force:!1},ai.set(a,c),c.unsubscribe=ak?.(a,()=>E(a))),c);b.forceRefresh&&(d.generation++,d.version++,d.force=!0,aj.delete(a));let e=d.version;for(let c=0;c<3;c++){let c=ae.get(a);if(c){let f=d.runningGeneration,g=await c.then(a=>({index:a,error:void 0}),a=>({index:void 0,error:a}));if(d.force||f!==d.generation)continue;if(g.error)throw g.error;if(!b.forceRefresh&&g.index&&aa.get(g.index)?.git.busy)throw new j.uV({message:"Workspace is changing: finish the Git operation or explicitly rebuild the index"});if(d.publishedVersion>=e&&g.index&&ab.get(a)===g.index)return F(a,g.index),g.index;continue}let f=d.generation,g=d.version,h=d.force;d.force=!1,d.runningGeneration=f;let i=(async()=>{let b=await (0,k.XC)(a,h),c=ab.get(a),e=c&&aa.get(c),i=(0,k.po)(e?.hashes??new Map,b.hashes),l=!h&&c&&e&&!i.count&&e.configHash===b.configHash&&e.git.busy===b.git.busy&&e.git.commonDir===b.git.commonDir&&e.scanTruncated===b.truncated,m=l?c:await A(a,b,c,h),n=await (0,k.U0)(a);if(n.commonDir!==b.git.commonDir||!h&&(n.busy||n.head!==b.git.head))throw new j.uV({message:"Workspace changed during indexing; retry after the Git operation finishes"});if(d.generation!==f||ai.get(a)!==d)throw new j.uV({message:"Index update was superseded; retry the query"});if(l&&e&&aa.set(m,{...e,git:b.git}),!l){let a=aa.get(m);ac.publish(m,b.git.commonDir,a.hashes,a.facts)}return d.publishedVersion=g,F(a,m),aj.delete(a),!function(a,b=0){for(let c of ab.keys()){if(function(){let a=ac.estimatedBytes();for(let[b,c]of ab)ac.has(b)||(a+=4e3*B(c));return a}()+b<=af)break;c!==a&&(G(c),console.log(`[codeIndex] evicted ${c} — cache over estimated byte budget`))}}(a),m})().catch(b=>{throw ai.get(a)!==d||d.generation!==f||d.force||aj.set(a,b),b}).finally(()=>{ae.get(a)===i&&ae.delete(a),d.retired&&!d.force&&ai.get(a)===d&&(d.unsubscribe?.(),ai.delete(a)),(0,o.d)(a,"done",0,0,void 0,!0)});ae.set(a,i);let l=await i;if(!b.forceRefresh&&aa.get(l)?.git.busy)throw new j.uV({message:"Workspace is changing: finish the Git operation or explicitly rebuild the index"});return l}throw new j.uV({message:"Workspace is changing; retry the index query"})}function I(a){let b=ab.get(a);return b&&F(a,b),b??null}function J(a,b={}){!b.forceRefresh&&aj.has(a)||H(a,b).catch(()=>{})}function K(a){return ae.has(a)}async function L(a,b){await (0,k.P3)(a);let c=await (0,k.ax)(a,b);if(!c)return null;let d=I(a),e=d&&aa.get(d),f=ai.get(a),g=aj.get(a),h=g?.cause instanceof Error?g.cause.message:g?.message,i=K(a);if(d&&e?.hashes.get(b)===c.hash&&(!f||f.version===f.publishedVersion)){let a=S(d,b);if(a)return{...a,mtimeMs:c.mtime,crossFileRevision:d.revision,crossFilePending:i,crossFileStale:i||!!g,indexUpdateError:h}}let j=await M(a,b,c);return j?{...j,fileCount:d?.files.size??0,crossFileStale:!!d,crossFileRevision:d?.revision,crossFilePending:K(a),indexUpdateError:h}:null}async function M(a,b,c){await (0,k.P3)(a);let d=c??await (0,k.ax)(a,b);if(!d)return null;let e=await y(b,d);if(!e)return null;let f={cwd:a,files:new Map,truncated:!1,tsconfigs:[],workspaces:new Map,projectContexts:new Map([[e.language,"go"===e.language?await (0,q.Bu)("go").buildProjectContext(a,new Set([e.path])):void 0]]),fileSet:new Set([e.path]),generatedAt:Date.now(),buildMs:0};return await N({...e,importBindings:[],importSpecifiers:[]},f,d.mtime),S(f,e.path)}async function N(a,b,c){let d=(0,q.Bu)(a.language),e=b.projectContexts.get(a.language),f=new Map,g=new Set;for(let c of a.importSpecifiers){if(f.has(c))continue;let h=d.resolveSpecifier(c,a.path,e,b.fileSet);h&&h!==a.path&&(f.set(c,h),g.add(h))}let h=new Map,i=new Map;for(let b of a.flatSymbols){i.set(b.qualifiedName,b);let a=h.get(b.name);a?a.push(b):h.set(b.name,[b])}let j=new Map,k=new Map;for(let b of a.importBindings)b.isReexport?k.set(b.localName,b):j.set(b.localName,b);let l={path:a.path,language:a.language,mtime:c,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:g,importedBy:new Set,importBindings:a.importBindings,resolvedImports:f,intraCalls:[],outgoingCalls:[],incomingCalls:[],externalCalls:[],methodCalls:[],symbolsByName:h,symbolsByQname:i,bindingsByLocalName:j,reexportsByLocalName:k},m=new Map,n=new Map,o=new Map,p=new Map;for(let c of(b.files.set(a.path,l),a.rawCalls)){let a=z(l.flatSymbols,c.line);if(a){for(let f of d.resolveCall(c,a,l,b.files,e))if("symbol"===f.kind)if(f.addr.filePath===l.path){let b=`${a.qualifiedName}${f.addr.qualifiedName}`,d=m.get(b);if(d)d.lines.push(c.line);else{let d={from:a.qualifiedName,to:f.addr.qualifiedName,lines:[c.line]};m.set(b,d),l.intraCalls.push(d)}}else{let b=`${a.qualifiedName}${f.addr.filePath}${f.addr.qualifiedName}`,d=n.get(b);if(d)d.lines.push(c.line);else{let d={from:a.qualifiedName,to:{filePath:f.addr.filePath,qualifiedName:f.addr.qualifiedName},lines:[c.line]};n.set(b,d),l.outgoingCalls.push(d)}}else if("external"===f.kind){let b=`${a.qualifiedName}${f.packageSpec}${f.name}`,d=o.get(b);if(d)d.lines.push(c.line);else{let d={from:a.qualifiedName,packageSpec:f.packageSpec,importedName:f.name,lines:[c.line]};o.set(b,d),l.externalCalls.push(d)}}else if("method-unresolved"===f.kind){let b=l.bindingsByLocalName.get(f.receiverName),d=b?l.resolvedImports.get(b.specifier)??"":"",e=`${a.qualifiedName}${f.receiverName}${f.methodName}`,g=p.get(e);if(g)g.lines.push(c.line);else{let b={from:a.qualifiedName,receiverName:f.receiverName,methodName:f.methodName,receiverFilePath:d,lines:[c.line]};p.set(e,b),l.methodCalls.push(b)}}}}for(let a of l.intraCalls)a.lines.sort((a,b)=>a-b);for(let a of l.outgoingCalls)a.lines.sort((a,b)=>a-b);for(let a of l.externalCalls)a.lines.sort((a,b)=>a-b);for(let a of l.methodCalls)a.lines.sort((a,b)=>a-b);return l}function O(a){let b=a.lastIndexOf("/");return b>=0?a.slice(b+1):a}function P(a){return{filePath:a.filePath,qualifiedName:a.qualifiedName,name:a.name,kind:a.kind,startLine:a.startLine,endLine:a.endLine,declLine:a.declLine,params:a.params}}function Q(a){let b=a.indexOf(">");return b>=0?a.slice(0,b):a}function R(a){if(a.length<2)return a;let b=[a[0]];for(let c=1;c<a.length;c++)a[c]!==a[c-1]&&b.push(a[c]);return b}function S(a,b){let c=a.files.get(b);if(!c)return null;let d=c.flatSymbols.filter(a=>!a.qualifiedName.includes(">")).map(P).sort((a,b)=>a.startLine-b.startLine),e=new Set(d.map(a=>a.qualifiedName)),f=new Map,g=[];for(let a of c.intraCalls){let b=Q(a.from),c=Q(a.to);if(b===c||!e.has(b)||!e.has(c))continue;let d=`${b}|${c}`,h=f.get(d);if(h)for(let b of a.lines)h.lines.push(b);else{let e={from:b,to:c,lines:a.lines.slice()};f.set(d,e),g.push(e)}}for(let a of g)a.lines.sort((a,b)=>a-b),a.lines=R(a.lines);let h=[],i=new Map;for(let b of c.outgoingCalls){let d=Q(b.from);if(!e.has(d)||b.to.filePath===c.path)continue;let f=a.files.get(b.to.filePath);if(!f)continue;let g=f.symbolsByQname.get(b.to.qualifiedName);if(!g||!(0,p._)(g))continue;let j=`${g.filePath}|${g.qualifiedName}|${d}`,k=i.get(j);if(k)for(let a of b.lines)k.lines.push(a);else{let a={external:P(g),focalQname:d,lines:b.lines.slice()};i.set(j,a),h.push(a)}}let j=[],k=new Map;for(let b of c.incomingCalls){let d=Q(b.to);if(!e.has(d)||b.from.filePath===c.path)continue;let f=a.files.get(b.from.filePath);if(!f)continue;let g=f.symbolsByQname.get(b.from.qualifiedName);if(!g||!(0,p._)(g))continue;let h=`${g.filePath}|${g.qualifiedName}|${d}`,i=k.get(h);if(i)for(let a of b.lines)i.lines.push(a);else{let a={external:P(g),focalQname:d,lines:b.lines.slice()};k.set(h,a),j.push(a)}}for(let a of h)a.lines.sort((a,b)=>a-b),a.lines=R(a.lines);for(let a of j)a.lines.sort((a,b)=>a-b),a.lines=R(a.lines);let l=[],m=new Map;for(let a of c.externalCalls){let b=Q(a.from);if(!e.has(b))continue;let c=`${b}|${a.packageSpec}|${a.importedName}`,d=m.get(c);if(d)for(let b of a.lines)d.lines.push(b);else{let d={external:{name:a.importedName,packageSpec:a.packageSpec},focalQname:b,lines:a.lines.slice()};m.set(c,d),l.push(d)}}for(let a of l)a.lines.sort((a,b)=>a-b),a.lines=R(a.lines);let n=[],o=new Map;for(let a of c.methodCalls){let b=Q(a.from);if(!e.has(b))continue;let c=`${b}|${a.receiverName}|${a.methodName}`,d=o.get(c);if(d)for(let b of a.lines)d.lines.push(b);else{let d={focalQname:b,receiverName:a.receiverName,methodName:a.methodName,receiverFilePath:a.receiverFilePath,lines:a.lines.slice()};o.set(c,d),n.push(d)}}for(let a of n)a.lines.sort((a,b)=>a-b),a.lines=R(a.lines);let q=(a,b)=>a.external.filePath.localeCompare(b.external.filePath)||a.external.qualifiedName.localeCompare(b.external.qualifiedName);return j.sort(q),h.sort(q),l.sort((a,b)=>a.external.packageSpec.localeCompare(b.external.packageSpec)||a.external.name.localeCompare(b.external.name)),n.sort((a,b)=>a.receiverName.localeCompare(b.receiverName)||a.methodName.localeCompare(b.methodName)),{filePath:c.path,language:c.language,fileCount:a.files.size,mtimeMs:c.mtime,functions:d,intraCalls:g,externalCalls:l,methodCalls:n,upstreamCalls:j,downstreamCalls:h}}function T(a,b){let c=a.files.get(b);return c?{filePath:c.path,language:c.language,symbols:function a(b){let c=[];for(let d of b)"unknown"!==d.kind&&c.push({...d,children:a(d.children)});return c}(c.symbolsTree)}:null}function U(a){let b="";for(let c=0;c<a.length;c++){let d=a.charCodeAt(c);95!==d&&45!==d&&46!==d&&32!==d&&(b+=d>=65&&d<=90?String.fromCharCode(d+32):a[c])}return b}let al=(a,b)=>a.rank-b.rank||a.filePath.localeCompare(b.filePath)||a.qname.localeCompare(b.qname)||a.line-b.line;function V(a,b,c){if(a===b)return 0;let d=U(a);return d===c?1:d.startsWith(c)?2:d.includes(c)?3:-1}function W(a,b,c,d={}){let e=b.trim();if(!e)return d.includeLiterals?{files:[],symbols:[],literals:[]}:{files:[],symbols:[]};let f=U(e);if(!f)return d.includeLiterals?{files:[],symbols:[],literals:[]}:{files:[],symbols:[]};let g=Math.min(500,Math.max(0,Math.floor(c)||0)),h=new u.V(g,al),i=new u.V(g,al),j=new u.V(g,al);for(let b of a.files.values()){if(d.directory&&!b.path.startsWith(`${d.directory}/`)||d.excludeTests&&(0,t.h)(b.path))continue;let a=V(b.path,e,f);if(a>=0){let c=V(O(b.path),e,f);h.add({rank:c>=0?Math.min(c,a):a,filePath:b.path,qname:"",line:0,value:b})}for(let a of b.flatSymbols){if("unknown"===a.kind)continue;let c=V(a.name,e,f);c>=0&&i.add({rank:c,filePath:b.path,qname:a.qualifiedName,line:a.declLine,value:a})}if(d.includeLiterals)for(let a of b.literals){let c=V(a.value,e,f);c>=0&&j.add({rank:c,filePath:b.path,qname:a.value,line:a.line,value:a})}}let k=h.sorted().map(({value:a})=>({type:"file",label:O(a.path),hint:a.path,target:{filePath:a.path}})),l=i.sorted().map(({value:a})=>({type:"symbol",label:a.name,hint:`${a.kind} \xb7 ${a.filePath}`,target:P(a)}));if(!d.includeLiterals)return{files:k,symbols:l};let m=j.sorted().map(({filePath:a,value:b})=>({type:"literal",value:b.value,filePath:a,line:b.line,...b.enclosingQname?{enclosingSymbol:b.enclosingQname}:{}}));return{files:k,symbols:l,literals:m}}function X(a,b,c){if(c){let d=a.files.get(c);return d&&d.symbolsByQname.has(b)?[d]:[]}let d=[];for(let c of a.files.values())c.symbolsByQname.has(b)&&d.push(c);return d}function Y(a,b,c){let d=X(a,b,c);if(d.length>1)return{qname:b,target:null,callers:[],ambiguousIn:d.map(a=>a.path).sort()};if(0===d.length)return{qname:b,target:null,callers:[]};let e=[],f=new Map;for(let c of d){for(let a of c.intraCalls){if(a.to!==b)continue;let d=c.symbolsByQname.get(a.from);if(!d)continue;let g=`${c.path}|${a.from}`,h=f.get(g);if(h)for(let b of a.lines)h.callLines.push(b);else{let b={caller:P(d),callLines:a.lines.slice()};f.set(g,b),e.push(b)}}for(let d of c.incomingCalls){if(d.to!==b)continue;let c=a.files.get(d.from.filePath),g=c?.symbolsByQname.get(d.from.qualifiedName);if(!g)continue;let h=`${d.from.filePath}|${d.from.qualifiedName}`,i=f.get(h);if(i)for(let a of d.lines)i.callLines.push(a);else{let a={caller:P(g),callLines:d.lines.slice()};f.set(h,a),e.push(a)}}}for(let a of e)a.callLines.sort((a,b)=>a-b),a.callLines=R(a.callLines);e.sort((a,b)=>a.caller.filePath.localeCompare(b.caller.filePath)||a.caller.qualifiedName.localeCompare(b.caller.qualifiedName));let g=P(d[0].symbolsByQname.get(b));return{qname:b,target:g,callers:e}}function Z(a,b,c){let d=X(a,b,c);if(d.length>1)return{qname:b,target:null,callees:[],ambiguousIn:d.map(a=>a.path).sort()};if(0===d.length)return{qname:b,target:null,callees:[]};let e=[],f=new Map;for(let c of d){for(let a of c.intraCalls){if(a.from!==b)continue;let d=c.symbolsByQname.get(a.to);if(!d)continue;let g=`${c.path}|${a.to}`,h=f.get(g);if(h)for(let b of a.lines)h.callLines.push(b);else{let b={callee:P(d),callLines:a.lines.slice()};f.set(g,b),e.push(b)}}for(let d of c.outgoingCalls){if(d.from!==b)continue;let c=a.files.get(d.to.filePath),g=c?.symbolsByQname.get(d.to.qualifiedName);if(!g)continue;let h=`${d.to.filePath}|${d.to.qualifiedName}`,i=f.get(h);if(i)for(let a of d.lines)i.callLines.push(a);else{let a={callee:P(g),callLines:d.lines.slice()};f.set(h,a),e.push(a)}}}for(let a of e)a.callLines.sort((a,b)=>a-b),a.callLines=R(a.callLines);e.sort((a,b)=>a.callee.filePath.localeCompare(b.callee.filePath)||a.callee.qualifiedName.localeCompare(b.callee.qualifiedName));let g=P(d[0].symbolsByQname.get(b));return{qname:b,target:g,callees:e}}function $(a,b,c,d){let e=X(a,b,d);if(e.length>1)return{qname:b,target:null,nodes:[],truncated:!1,ambiguousIn:e.map(a=>a.path).sort()};if(0===e.length)return{qname:b,target:null,nodes:[],truncated:!1};let f=Math.min(Math.max(c,1),5),g=P(e[0].symbolsByQname.get(b)),h=e.map(a=>({filePath:a.path,qname:b})),i=new Set(h.map(a=>`${a.filePath}|${a.qname}`)),j=h.map(b=>{let c=a.files.get(b.filePath).symbolsByQname.get(b.qname);return{symbol:P(c),depth:0}}),k=h.slice(),l=!1;for(let b=1;b<=f;b++){let c=[];for(let d of k){let e=a.files.get(d.filePath);if(e){for(let a of e.intraCalls){if(a.to!==d.qname)continue;let f=e.symbolsByQname.get(a.from);if(!f)continue;let g=`${e.path}|${a.from}`;if(!i.has(g)&&(i.add(g),j.push({symbol:P(f),depth:b}),c.push({filePath:e.path,qname:a.from}),j.length>=500)){l=!0;break}}if(l)break;for(let f of e.incomingCalls){if(f.to!==d.qname)continue;let e=a.files.get(f.from.filePath),g=e?.symbolsByQname.get(f.from.qualifiedName);if(!g)continue;let h=`${f.from.filePath}|${f.from.qualifiedName}`;if(!i.has(h)&&(i.add(h),j.push({symbol:P(g),depth:b}),c.push({filePath:f.from.filePath,qname:f.from.qualifiedName}),j.length>=500)){l=!0;break}}if(l)break}}if(l||0===c.length)break;k=c}return j.sort((a,b)=>a.depth-b.depth||a.symbol.filePath.localeCompare(b.symbol.filePath)||a.symbol.qualifiedName.localeCompare(b.symbol.qualifiedName)),{qname:b,target:g,nodes:j,truncated:l}}d()}catch(a){d(a)}})},45356:(a,b,c)=>{c.d(b,{l:()=>h});var d=c(77598);let e=["resolvedImports","importedFiles","importedBy","intraCalls","outgoingCalls","incomingCalls","externalCalls","methodCalls"];function f(a,b,c){return JSON.stringify([2,a,b,c])}function g(a){return JSON.stringify(e.map(b=>{let c=a[b];return c instanceof Map||c instanceof Set?[...c]:c}))}class h{findParse(a,b,c,d){return this.repositories.get(a)?.parses.get(f(b,c,d))?.value}publish(a,b,c,e){let h=this.repositories.get(b);h||(h={roots:0,parses:new Map,relations:new Map},this.repositories.set(b,h)),h.roots++;let i={repository:b,parses:[],relations:[],bytes:1024+512*c.size};for(let[b,j]of a.files){let a=e.get(b),k=f(b,j.language,c.get(b)),l=h.parses.get(k);!l&&(l={key:k,value:{facts:a,lookups:{symbolsByName:j.symbolsByName,symbolsByQname:j.symbolsByQname,bindingsByLocalName:j.bindingsByLocalName,reexportsByLocalName:j.reexportsByLocalName}},references:0,bytes:Math.max(768+1024*a.flatSymbols.length+96*a.rawCalls.length+192*a.importBindings.length+64*a.importSpecifiers.length+128*a.literals.length,4e3*a.flatSymbols.length/1.25)},h.parses.set(k,l),this.bytes+=l.bytes);e.set(b,l.value.facts);let m=l.value.facts;j.symbolsTree=m.symbolsTree,j.flatSymbols=m.flatSymbols,j.literals=m.literals,j.importBindings=m.importBindings,Object.assign(j,l.value.lookups),l.references++,i.parses.push(l);let n=g(j),o=JSON.stringify([b,(0,d.createHash)("sha256").update(n).digest("hex")]),p=h.relations.get(o)??[],q=p.find(a=>g(a.value)===n);q||(q={key:o,value:{resolvedImports:j.resolvedImports,importedFiles:j.importedFiles,importedBy:j.importedBy,intraCalls:j.intraCalls,outgoingCalls:j.outgoingCalls,incomingCalls:j.incomingCalls,externalCalls:j.externalCalls,methodCalls:j.methodCalls},references:0,bytes:768+2*Buffer.byteLength(n)},p.push(q),h.relations.set(o,p),this.bytes+=q.bytes),Object.assign(j,q.value),q.references++,i.relations.push(q)}this.release(a.cwd),this.leases.set(a.cwd,i),this.bytes+=i.bytes}release(a){let b=this.leases.get(a);if(!b)return;this.leases.delete(a),this.bytes-=b.bytes;let c=this.repositories.get(b.repository);for(let a of(c.roots--,b.parses))0==--a.references&&(c.parses.delete(a.key),this.bytes-=a.bytes);for(let a of b.relations)if(0==--a.references){let b=c.relations.get(a.key);b.splice(b.indexOf(a),1),b.length||c.relations.delete(a.key),this.bytes-=a.bytes}c.roots||this.repositories.delete(b.repository)}has(a){return this.leases.has(a)}estimatedBytes(){return Math.ceil(1.25*this.bytes)}stats(){let a=0,b=0;for(let c of this.repositories.values())for(let d of(a+=c.parses.size,c.relations.values()))b+=d.length;return{roots:this.leases.size,repositories:this.repositories.size,parses:a,relations:b,estimatedBytes:this.estimatedBytes()}}constructor(){this.repositories=new Map,this.leases=new Map,this.bytes=0}}},52166:(a,b,c)=>{c.d(b,{s:()=>f});let d={nodes:new Set(["if_statement","for_statement","for_in_statement","while_statement","do_statement","switch_case","catch_clause","ternary_expression"]),binary:{type:"binary_expression",operators:new Set(["&&","||","??"])}},e={typescript:d,tsx:d,javascript:d,python:{nodes:new Set(["if_statement","elif_clause","for_statement","while_statement","except_clause","conditional_expression","case_clause","if_clause","for_in_clause","boolean_operator"])},go:{nodes:new Set(["if_statement","for_statement","expression_case","type_case","communication_case"]),binary:{type:"binary_expression",operators:new Set(["&&","||"])}},rust:{nodes:new Set(["if_expression","while_expression","for_expression","loop_expression","match_arm"]),binary:{type:"binary_expression",operators:new Set(["&&","||"])}}};function f(a,b,c){let d=e[b],f=new Map;if(!d)return f;let g=c.filter(a=>"function"===a.kind||"method"===a.kind);for(let a of g)f.set(a.qualifiedName,1);if(!g.length)return f;let h=new Map,i=a=>{let b=h.get(a);if(void 0===b){let c=null;for(let b of g)b.startLine<=a&&a<=b.endLine&&(!c||b.endLine-b.startLine<c.endLine-c.startLine)&&(c=b);b=c?.qualifiedName??null,h.set(a,b)}return b},j=[a];for(;j.length;){let a=j.pop(),b=d.nodes.has(a.type);if(!b&&d.binary&&a.type===d.binary.type){let c=a.childForFieldName("operator")?.text??a.child(1)?.text;b=!!c&&d.binary.operators.has(c)}if(b){let b=i(a.startPosition.row+1);b&&f.set(b,(f.get(b)??1)+1)}for(let b=a.childCount-1;b>=0;b--){let c=a.child(b);c&&j.push(c)}}return f}},53809:(a,b,c)=>{c.d(b,{h:()=>d});function d(a){return/(^|\/)(__tests__|tests?)\//i.test(a)||/\.(test|spec|e2e)\.[^/]+$/i.test(a)||/(^|\/)test_[^/]+\.pyi?$/i.test(a)||/[^/]+_test\.go$/i.test(a)}},56476:(a,b,c)=>{function d(a){let b=[];return!function a(c){if("call_expression"===c.type||"call"===c.type){let a=c.childForFieldName("function"),d=function a(b){if(!b)return null;if("identifier"===b.type||"shorthand_property_identifier"===b.type)return b.text;if("member_expression"===b.type){let a=b.childForFieldName("property");return a?.text??null}if("attribute"===b.type){let a=b.childForFieldName("attribute");return a?.text??null}return"call_expression"===b.type||"call"===b.type?a(b.childForFieldName("function")):null}(a);if(d){let e=function(a){if(!a||"member_expression"!==a.type&&"attribute"!==a.type)return;let b=a;for(;b;){if("identifier"===b.type)return b.text;if("this"===b.type||"super"===b.type)break;if("member_expression"===b.type||"attribute"===b.type){b=b.childForFieldName("object");continue}break}}(a);b.push({calleeName:d,line:c.startPosition.row+1,...e?{receiverName:e}:{}})}}else if("jsx_opening_element"===c.type||"jsx_self_closing_element"===c.type){let a=function a(b){return b?"identifier"===b.type?/^[A-Z]/.test(b.text)?b.text:null:"member_expression"===b.type||"jsx_member_expression"===b.type?a(b.childForFieldName("object")??b.namedChild(0)):null:null}(c.childForFieldName("name"));a&&b.push({calleeName:a,line:c.startPosition.row+1})}for(let b=0;b<c.childCount;b++){let d=c.child(b);d&&a(d)}}(a),b}function e(a){let b=[];for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(d)if("import_statement"===d.type){let a=d.childForFieldName("source");a?function(a,b,c){let d=j(b.text),e=null;for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);if(c?.type==="import_clause"){e=c;break}}if(e)for(let a=0;a<e.namedChildCount;a++){let b=e.namedChild(a);if(b){if("identifier"===b.type)c.push({specifier:d,importedName:"default",localName:b.text});else if("namespace_import"===b.type){let a=function(a,b){for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(d?.type===b)return d}return null}(b,"identifier");a&&c.push({specifier:d,importedName:"*",localName:a.text})}else if("named_imports"===b.type)for(let a=0;a<b.namedChildCount;a++){let e=b.namedChild(a);if(!e||"import_specifier"!==e.type)continue;let f=e.childForFieldName("name"),g=e.childForFieldName("alias");f&&c.push({specifier:d,importedName:f.text,localName:g?.text??f.text})}}}}(d,a,b):g(d,b)}else"import_from_statement"===d.type&&h(d,b)}return b}function f(a){let b=e(a),c=new Set(b.map(a=>a.localName)),d=[];for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);c&&"import_statement"!==c.type&&"import_from_statement"!==c.type&&d.push(c)}for(;d.length;){let a=d.pop();if("import_statement"===a.type||"import_from_statement"===a.type){let d=[];for(let e of("import_statement"===a.type?g(a,d):h(a,d),d))c.has(e.localName)||(c.add(e.localName),b.push(e));continue}for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);c&&d.push(c)}}return b}function g(a,b){for(let c=0;c<a.childCount;c++){let d=a.child(c);if(d&&"name"===a.fieldNameForChild(c)){if("dotted_name"===d.type){let a=d.text,c=a.split(".")[0];b.push({specifier:a,importedName:"*",localName:c})}else if("aliased_import"===d.type){let a=d.childForFieldName("name"),c=d.childForFieldName("alias");a?.type==="dotted_name"&&c&&b.push({specifier:a.text,importedName:"*",localName:c.text})}}}}function h(a,b){let c=a.childForFieldName("module_name"),d="";if(c){if("dotted_name"===c.type)d=c.text;else if("relative_import"===c.type){let a="",b="";for(let d=0;d<c.namedChildCount;d++){let e=c.namedChild(d);e&&("import_prefix"===e.type?a=e.text:"dotted_name"===e.type&&(b=e.text))}d=a+b}}if(!d)return;let e=!1;for(let c=0;c<a.childCount;c++){let f=a.child(c);if(!f)continue;let g=a.fieldNameForChild(c);if("wildcard_import"===f.type){e=!0;continue}if("name"===g){if("dotted_name"===f.type){let a=f.text;b.push({specifier:d,importedName:a,localName:a})}else if("aliased_import"===f.type){let a=f.childForFieldName("name"),c=f.childForFieldName("alias");a?.type==="dotted_name"&&c&&b.push({specifier:d,importedName:a.text,localName:c.text})}}}e&&b.push({specifier:d,importedName:"*",localName:"*"})}function i(a){let b=[];for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(!d||"export_statement"!==d.type||d.children.some(a=>"type"===a.type))continue;let e=d.childForFieldName("source"),f=e?j(e.text):"",g=(a,c=a)=>{b.push({localName:a,importedName:c,specifier:f,isReexport:!0})},h=null;for(let a=0;a<d.namedChildCount;a++){let b=d.namedChild(a);if(b?.type==="export_clause"){h=b;break}}if(!h){let a=d.namedChildren.find(a=>"namespace_export"===a.type);if(a){let b=a.namedChild(0);b&&g(b.text,"*")}else if(e&&d.children.some(a=>"*"===a.type))g("*");else{let a=d.childForFieldName("declaration");if(a?.type==="interface_declaration"||a?.type==="type_alias_declaration")continue;let b=d.children.some(a=>"default"===a.type);if(a?.type==="lexical_declaration"||a?.type==="variable_declaration")for(let b of a.namedChildren){let a=b.childForFieldName("name");a?.type==="identifier"&&g(a.text)}else{let c=a?.childForFieldName("name")??d.childForFieldName("value");(c?.type==="identifier"||c?.type==="type_identifier")&&g(b?"default":c.text,c.text)}}continue}for(let a=0;a<h.namedChildCount;a++){let b=h.namedChild(a);if(!b||"export_specifier"!==b.type||b.children.some(a=>"type"===a.type))continue;let c=b.childForFieldName("name"),d=b.childForFieldName("alias");if(!c)continue;let e=c.text;g(d?.text??e,e)}}return b}function j(a){return a.length>=2&&('"'===a[0]||"'"===a[0])&&a[a.length-1]===a[0]?a.slice(1,-1):a}c.d(b,{JM:()=>f,Lv:()=>d,il:()=>i,jv:()=>e})},64949:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{g:()=>h});var e=c(33265),f=c(88395),g=a([e]);e=(g.then?(await g)():g)[0];let i=!1;function h(){i||(i=!0,(0,e.NV)(),(0,e.ih)((a,b)=>f.t.subscribe(a,a=>{a.some(a=>"file"===a.type||"git"===a.type)&&b()})))}d()}catch(a){d(a)}})},75775:(a,b,c)=>{c.d(b,{FI:()=>p,P3:()=>u,SD:()=>t,U0:()=>x,XC:()=>B,ax:()=>z,jR:()=>v,po:()=>C,xq:()=>D,yj:()=>o});var d=c(31421),e=c(77598),f=c(73024),g=c(76760),h=c.n(g),i=c(57975),j=c(89705),k=c(69181),l=c(770),m=c(28677);let n=(0,i.promisify)(d.execFile),o=1e5,p=2097152;async function q(a){let b=await j.pR5(j.gPK(a));if(k.OC(b))throw b.left;return b.right}async function r(a,b){return q(j.$mh({try:()=>n("git",b,{cwd:a,maxBuffer:0x3200000}).then(a=>a.stdout),catch:a=>new l.uV({message:"Code index Git command failed",cause:a})}))}function s(a){return!a.split("/").some(a=>"node_modules"===a||".git"===a)}function t(a){return s(a)&&(0,m.cn)().includes(h().posix.extname(a).toLowerCase())}async function u(a){return q(j.$mh({try:async()=>{let[b,...c]=(await n("git",["rev-parse","--is-inside-work-tree","--absolute-git-dir"],{cwd:a})).stdout.trimEnd().split("\n");if("true"!==b)throw Error("Not a Git working tree");return c.join("\n")},catch:a=>/not a git repository/i.test(a.stderr??"")||"Not a Git working tree"===a.message?new l.yI({field:"cwd",reason:"Non-Git projects are not supported"}):new l.uV({message:"Unable to inspect Git project",cause:a})}))}async function v(a){return await u(a),[...new Set((await r(a,["ls-files","--cached","--others","--exclude-standard","-z"])).split("\0").filter(a=>a&&s(a)))].sort()}async function w(a){return q(j.$mh({try:a,catch:a=>a}).pipe(j.h9N(a=>"ENOENT"===a.code?j.PyW(null):j.fJG(new l.uU({path:"code-index scan",op:"read",cause:a})))))}async function x(a){let b=await u(a),c=(await r(a,["rev-parse","--path-format=absolute","--git-common-dir"])).trimEnd(),d=await q(j.$mh({try:()=>f.promises.realpath(c),catch:a=>new l.uU({path:c,op:"read",cause:a})})),e=await Promise.all(["index.lock","rebase-merge","rebase-apply","MERGE_HEAD","CHERRY_PICK_HEAD","REVERT_HEAD"].map(a=>w(()=>f.promises.stat(h().join(b,a))))),g=await q(j.$mh({try:()=>n("git",["rev-parse","--verify","--quiet","HEAD"],{cwd:a}).then(a=>a.stdout.trim()),catch:a=>a}).pipe(j.h9N(a=>1===a.code?j.PyW("unborn"):j.fJG(new l.uV({message:"Unable to read Git HEAD",cause:a}))))),i=await r(a,["ls-files","--unmerged","-z"]);return{head:g,busy:e.some(Boolean)||i.length>0,commonDir:d}}let y=a=>(0,e.createHash)("sha256").update(a).digest("hex");async function z(a,b){let c=h().join(a,b);return w(async()=>{let[a,b]=await Promise.all([f.promises.readFile(c),f.promises.stat(c)]);return{source:a.toString("utf8"),hash:y(a),mtime:b.mtimeMs,sizeBytes:a.length}})}function A(a){return/(^|\/)(tsconfig[^/]*\.json|package\.json|pnpm-workspace\.yaml|go\.mod|\.gitignore)$/.test(a)}async function B(a,b=!1){let c=await x(a);if(c.busy&&!b)throw new l.uV({message:"Workspace is changing: finish the Git operation or explicitly rebuild the index"});let d=await v(a),e=d.filter(t),f=e.slice(0,o),g=new Map,h=new Map,i=0,j=!1,k=(await Promise.allSettled(Array.from({length:Math.min(8,f.length)},async()=>{for(;!j&&i<f.length;){let b=f[i++],c=await z(a,b).catch(a=>{throw j=!0,a});c&&(g.set(b,c),h.set(b,c.hash))}}))).find(a=>"rejected"===a.status);if(k?.status==="rejected")throw k.reason;for(let a of e.slice(o))h.set(a,"not-scanned");let m=new Map,n=new Map;for(let b of[...new Set([...d.filter(A),"tsconfig.json","package.json","pnpm-workspace.yaml","go.mod"])].sort())await z(a,b).then(a=>{a&&(m.set(b,a.hash),n.set(b,a.source))});let p=y(JSON.stringify([...m])),q={paths:[...new Set([...d,...n.keys()])],readFile:async a=>{let b=g.get(a)?.source??n.get(a);if(void 0!==b)return b;throw new l.uU({path:a,op:"read",cause:Object.assign(Error(`File not captured: ${a}`),{code:"ENOENT"})})}};return{sources:g,hashes:h,configHash:p,truncated:e.length>o,git:c,contextFiles:q}}function C(a,b){let c=[],d=[],e=[];for(let[e,f]of b)a.has(e)?a.get(e)!==f&&d.push(e):c.push(e);for(let c of a.keys())b.has(c)||e.push(c);let f=c.length+d.length+e.length,g=Math.max(a.size,b.size);return{added:c,changed:d,deleted:e,count:f,rebuild:f>=500||f>=20&&f/g>=.2}}function D(a,b){return a instanceof l.uV||a instanceof l.uU||a instanceof l.yI?a:new l.uV({message:b,cause:a})}},83624:(a,b,c)=>{c.d(b,{Hs:()=>n,NZ:()=>f,YN:()=>o,_B:()=>m,mG:()=>l,qj:()=>e});var d=c(56476);function e(a){let b=0xdeadbeef,c=0x41c6ce57;for(let d=0;d<a.length;d++){let e=a.charCodeAt(d);b=Math.imul(b^e,0x9e3779b1),c=Math.imul(c^e,0x5f356495)}return b=Math.imul(b^b>>>16,0x85ebca6b)^Math.imul(c^c>>>13,0xc2b2ae35),(0x100000000*(2097151&(c=Math.imul(c^c>>>16,0x85ebca6b)^Math.imul(b^b>>>13,0xc2b2ae35)))+(b>>>0)>>>0).toString(16)}function f(a){return a.replace(/\s+/g," ").trim()}function g(a,b){return a?`${a}>${b}`:b}function h(a){let b=a.childForFieldName("name");if(b)return b.text;for(let b=0;b<a.namedChildCount;b++){let c=a.namedChild(b);if(c&&("identifier"===c.type||"type_identifier"===c.type||"property_identifier"===c.type))return c.text}return"<anonymous>"}function i(a,b,c,d,h=[],j){return{qualifiedName:g(d,b),name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:function(a){for(let b=0;b<a.childCount;b++){let c=a.child(b);if(c&&"decorator"!==c.type&&"comment"!==c.type)return c.startPosition.row}return a.startPosition.row}(a)+1,contentHash:e(f(a.text)),children:h,params:j}}function j(a){let b=a.childForFieldName("parameter");if(b)return[b.text];let c=a.childForFieldName("parameters");if(!c)return;let d=[];for(let a=0;a<c.namedChildCount;a++){let b=c.namedChild(a);b&&d.push(function a(b){switch(b.type){case"required_parameter":case"optional_parameter":{let c=b.childForFieldName("pattern");return c?a(c):b.text}case"assignment_pattern":{let c=b.childForFieldName("left");return c?a(c):b.text}case"default_parameter":case"typed_default_parameter":{let a=b.childForFieldName("name");return a?a.text:b.text}case"typed_parameter":for(let a=0;a<b.namedChildCount;a++){let c=b.namedChild(a);if(c?.type==="identifier")return c.text}return b.text;default:return b.text}}(b))}return d}let k={theorem:"function",def:"function",abbrev:"function",example:"function",instance:"const",structure:"class",inductive:"type",axiom:"const",opaque:"const",constant:"const"};function l(a,b){for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(d?.type!=="export_statement")continue;let e=d.childForFieldName("declaration");if(!e||e.startPosition.row===d.startPosition.row)continue;let f=e.startPosition.row+1;for(let a of b)"unknown"!==a.kind&&a.startLine===f&&(a.startLine=d.startPosition.row+1)}let c=new Map;for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);if(!d||!function(a){if("attribute_item"===a.type)return!0;if(!a.type.endsWith("comment"))return!1;for(let b=0;b<a.namedChildCount;b++)if(a.namedChild(b)?.type==="inner_doc_comment_marker")return!1;return!0}(d))continue;let e=0===d.endPosition.column&&d.endPosition.row>d.startPosition.row?d.endPosition.row-1:d.endPosition.row;c.set(e+1,d)}if(0===c.size)return;let d=new Set;for(let a of b)for(let b=a.startLine;b<=a.endLine;b++)d.add(b);for(let a of b){if("unknown"===a.kind)continue;let b=a.startLine;for(;;){let a=c.get(b-1);if(!a)break;let e=a.startPosition.row+1,f=!1;for(let a=e;a<=b-1;a++)if(d.has(a)){f=!0;break}if(f)break;b=e}if(b!==a.startLine){for(let c=b;c<a.startLine;c++)d.add(c);a.startLine=b}}}function m(a,b){let c=a.text.split("\n"),d=c.length;if(0===d)return[];let g=new Uint8Array(d+2);for(let a of b){let b=Math.max(1,a.startLine),c=Math.min(d,a.endLine);for(let a=b;a<=c;a++)g[a]=1}let h=[],i=(a,b)=>{let d=!1;for(let e=a;e<=b;e++){let a=c[e-1];if(a&&a.trim().length>0){d=!0;break}}if(!d)return;let g=c.slice(a-1,b).join("\n");h.push({qualifiedName:`__code_${a}_${b}__`,name:"code",kind:"unknown",startLine:a,endLine:b,declLine:a,contentHash:e(f(g)),children:[]})},j=-1;for(let a=1;a<=d;a++)g[a]?j>=0&&(i(j,a-1),j=-1):j<0&&(j=a);return j>=0&&i(j,d),h}function n(a,b){let c=[],n=function(a){let b=[],c=-1,d=-1;for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(f){if("import_statement"===f.type||"export_statement"===f.type&&null!==f.childForFieldName("source")||"import_from_statement"===f.type||"future_import_statement"===f.type||"import"===f.type)b.push(f),c<0&&(c=f.startPosition.row+1),d=f.endPosition.row+1;else if(c>=0)break}}return c<0?null:{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:d,declLine:c,contentHash:e(f(b.map(a=>a.text).join("\n"))),children:[]}}(a);if(n&&c.push(n),"lean"===b)c.push(...function(a){let b=[],c=[];for(let d=0;d<a.namedChildCount;d++){let g=a.namedChild(d);if(!g)continue;switch(g.type){case"namespace":c.push(g.childForFieldName("name")?.text??null);continue;case"section":c.push(null);continue;case"end":c.pop();continue}let h=null;if("declaration"===g.type)for(let a=0;a<g.namedChildCount;a++){let b=g.namedChild(a);if(b&&b.type in k){h=b;break}}else g.type in k&&(h=g);if(!h)continue;let i=h.childForFieldName("name")?.text??h.type,j=c.filter(a=>null!==a);b.push({qualifiedName:[...j,i].join("."),name:i,kind:k[h.type],startLine:g.startPosition.row+1,endLine:function(a){let b=a.endPosition.row+1,c=a.text.replace(/\s+$/,""),d=a.text.slice(c.length);if(!d)return b;let e=d.split("\n").length-1;return Math.max(a.startPosition.row+1,b-e)}(g),declLine:h.startPosition.row+1,contentHash:e(f(g.text)),children:[]})}return b}(a));else for(let b=0;b<a.namedChildCount;b++){let k=a.namedChild(b);k&&c.push(...function a(b,c,k=!1){switch(b.type){case"export_statement":case"export_default_declaration":{let d=[];for(let e=0;e<b.namedChildCount;e++){let f=b.namedChild(e);f&&d.push(...a(f,c,!0))}return d}case"function_declaration":case"generator_function_declaration":case"function_definition":return[i(b,h(b),"function",c,[],j(b))];case"class_declaration":case"abstract_class_declaration":{let a=h(b),d=g(c,a),e=function(a,b){if(!a)return[];let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e){if("method_definition"===e.type)c.push(i(e,h(e),"method",b,[],j(e)));else if("public_field_definition"===e.type){let a=e.childForFieldName("value");a&&("arrow_function"===a.type||"function_expression"===a.type)&&c.push(i(e,h(e),"method",b,[],j(a)))}}}return c}(b.childForFieldName("body"),d);return[i(b,a,"class",c,e)]}case"interface_declaration":return[i(b,h(b),"interface",c)];case"type_alias_declaration":return[i(b,h(b),"type",c)];case"enum_declaration":return[i(b,h(b),"enum",c)];case"lexical_declaration":case"variable_declaration":return function(a,b){let c=[];for(let e=0;e<a.namedChildCount;e++){let f=a.namedChild(e);if(!f||"variable_declarator"!==f.type)continue;let g=f.childForFieldName("name"),k=f.childForFieldName("value");if(!g)continue;let l=g.text,m=function a(b,c=0){if(!b||c>8)return null;if("arrow_function"===b.type||"function_expression"===b.type)return b;if(["parenthesized_expression","as_expression","satisfies_expression","non_null_expression"].includes(b.type))return a(b.namedChild(0),c+1);if("call_expression"!==b.type)return null;let e=b.childForFieldName("function");if(!e)return null;let f="member_expression"===e.type?e.childForFieldName("object"):null,g=f?.type==="identifier"?f.text:"identifier"===e.type?e.text:null;if(!g)return null;let h=b;for(;h.parent;)h=h.parent;let i=(0,d.jv)(h).find(a=>a.localName===g);if(!i)return null;let j=f?e.childForFieldName("property")?.text:i.importedName,k="*"===i.importedName||"default"===i.importedName;return(!f||k)&&("@cockpit/effect-runtime/server"===i.specifier?"handler"===j||"dynamicHandler"===j:"react"===i.specifier&&["memo","forwardRef","useCallback"].includes(j??""))?a(b.childForFieldName("arguments")?.namedChild(0)??null,c+1):null}(k),n=null!==m,o=m?j(m):void 0;if(c.push(i(a,l,n?"function":"const",b,[],o)),k&&"object"===k.type&&!n){let a=b?`${b}>${l}`:l;for(let b=0;b<k.namedChildCount;b++){let d=k.namedChild(b);if(d){if("pair"===d.type){let b=d.childForFieldName("key"),e=d.childForFieldName("value");if(!b||!e||"property_identifier"!==b.type&&"identifier"!==b.type||"arrow_function"!==e.type&&"function_expression"!==e.type)continue;c.push(i(d,b.text,"method",a,[],j(e)))}else if("method_definition"===d.type){let b=h(d);b&&c.push(i(d,b,"method",a,[],j(d)))}}}}}return c}(b,c);case"class_definition":{let a=h(b),d=g(c,a),k=function a(b,c){if(!b)return[];let d=[];for(let k=0;k<b.namedChildCount;k++){let l=b.namedChild(k);if(l){if("function_definition"===l.type)d.push(i(l,h(l),"method",c,[],j(l)));else if("decorated_definition"===l.type){let b=l.childForFieldName("definition");if(b?.type==="function_definition")d.push({...i(b,h(b),"method",c,[],j(b)),startLine:l.startPosition.row+1,contentHash:e(f(l.text))});else if(b?.type==="class_definition"){let j=h(b),k=g(c,j),m=a(b.childForFieldName("body"),k);d.push({...i(b,j,"class",c,m),startLine:l.startPosition.row+1,contentHash:e(f(l.text))})}}else if("class_definition"===l.type){let b=h(l),e=g(c,b),f=a(l.childForFieldName("body"),e);d.push(i(l,b,"class",c,f))}}}return d}(b.childForFieldName("body"),d);return[i(b,a,"class",c,k)]}case"decorated_definition":{let d=b.childForFieldName("definition");if(!d)return[];return a(d,c,!1).map(a=>({...a,startLine:b.startPosition.row+1,contentHash:e(f(b.text))}))}case"expression_statement":{let a=[];for(let d=0;d<b.namedChildCount;d++){let h=b.namedChild(d);if(h?.type==="assignment"){let d=function(a,b,c){let d=b.childForFieldName("left");if(!d||"identifier"!==d.type)return null;let h=d.text;return{qualifiedName:g(c,h),name:h,kind:"const",startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,declLine:a.startPosition.row+1,contentHash:e(f(a.text)),children:[]}}(b,h,c);d&&a.push(d)}}return a.push(...function(a,b){let c=null;for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);if(d){if("call_expression"===d.type){c=d;break}if("await_expression"===d.type){for(let a=0;a<d.namedChildCount;a++){let b=d.namedChild(a);if(b?.type==="call_expression"){c=b;break}}break}}}if(!c)return[];let d=c.childForFieldName("function"),e=c.childForFieldName("arguments");if(!d||!e)return[];let f=null,g=[];for(let a=0;a<e.namedChildCount;a++){let b=e.namedChild(a);if(b){if(null===f&&("string"===b.type||"template_string"===b.type)){let a=b.text;f=a.length>=2&&/^["'`]/.test(a)?a.slice(1,-1):a}("arrow_function"===b.type||"function_expression"===b.type)&&g.push(b)}}if(0===g.length||!f)return[];let h=function a(b){if("identifier"===b.type)return b.text;if("member_expression"===b.type){let a=b.childForFieldName("property");return a?.text??""}if("call_expression"===b.type){let c=b.childForFieldName("function");return c?a(c):""}return""}(d),k=h?`${h} ${f}`:f;return g.map((a,c)=>i(a,g.length>1?`${k} #${c+1}`:k,"function",b,[],j(a)))}(b,c)),a}default:return[]}}(k,void 0,!1))}return l(a,c),c.push(...m(a,c)),o(c),c}function o(a){let b=new Map,c=a=>{for(let d of a){let a=(b.get(d.qualifiedName)??0)+1;b.set(d.qualifiedName,a),a>1&&(d.qualifiedName=`${d.qualifiedName}#${a}`),c(d.children)}};c(a)}},85836:(a,b,c)=>{c.d(b,{V:()=>d});class d{constructor(a,b){this.limit=a,this.compare=b,this.heap=[]}add(a){if(this.limit<=0)return;if(this.heap.length<this.limit){this.heap.push(a);let b=this.heap.length-1;for(;b>0;){let a=b-1>>>1;if(0>=this.compare(this.heap[b],this.heap[a]))break;[this.heap[b],this.heap[a]]=[this.heap[a],this.heap[b]],b=a}return}if(this.compare(a,this.heap[0])>=0)return;this.heap[0]=a;let b=0;for(;;){let a=2*b+1;if(a>=this.heap.length)break;let c=a+1,d=c<this.heap.length&&this.compare(this.heap[c],this.heap[a])>0?c:a;if(0>=this.compare(this.heap[d],this.heap[b]))break;[this.heap[b],this.heap[d]]=[this.heap[d],this.heap[b]],b=d}}sorted(){return this.heap.slice().sort(this.compare)}}},86236:(a,b,c)=>{c.d(b,{I:()=>d});let d=new Set(["typescript","tsx","javascript","python","go","rust","lean"])},87956:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{M:()=>j,b:()=>i});var e=c(12629),f=c(76760),g=c.n(f),h=a([e]);e=(h.then?(await h)():h)[0];let k=g().join(process.cwd(),"public","tree-sitter"),l=null,m=new Map,n=new Map;async function i(a){let b,c=n.get(a);if(c)return c;let d=await (!(b=m.get(a))&&(b=(async()=>(await (!l&&(l=e.Parser.init({locateFile:a=>g().join(k,a)})),l),e.Language.load(g().join(k,`tree-sitter-${a}.wasm`))))(),m.set(a,b)),b);return(c=new e.Parser).setLanguage(d),n.set(a,c),c}function j(a){switch(a.slice(a.lastIndexOf(".")).toLowerCase()){case".ts":return"typescript";case".tsx":case".jsx":return"tsx";case".js":case".mjs":case".cjs":return"javascript";case".py":case".pyi":return"python";case".go":return"go";case".rs":return"rust";case".lean":return"lean";default:return null}}d()}catch(a){d(a)}})},88395:(a,b,c)=>{c.d(b,{t:()=>j});var d=c(29021),e=c(33873);let f=[".git/HEAD",".git/MERGE_HEAD",".git/REBASE_HEAD"],g=[".git/refs"];class h{subscribe(a,b){let c=this.watchers.get(a);return c||(c=this.createWatcher(a),this.watchers.set(a,c)),c.listeners.add(b),()=>{this.unsubscribe(a,b)}}unsubscribe(a,b){let c=this.watchers.get(a);if(c&&(c.listeners.delete(b),0===c.listeners.size)){for(let a of(c.debounceTimer&&clearTimeout(c.debounceTimer),c.throttleTimer&&clearTimeout(c.throttleTimer),c.cwdRestartTimer&&clearTimeout(c.cwdRestartTimer),c.watchers))try{a.close()}catch{}this.watchers.delete(a)}}createWatcher(a){let b={watchers:[],listeners:new Set,pendingEvents:[],debounceTimer:null,throttleTimer:null,cwdRestartTimer:null},c=a=>{b.pendingEvents.some(b=>b.type===a.type)||b.pendingEvents.push(a),b.debounceTimer&&clearTimeout(b.debounceTimer),b.debounceTimer=setTimeout(()=>{this.flush(b)},500),b.throttleTimer||(b.throttleTimer=setTimeout(()=>{this.flush(b)},3e3))},h=()=>{try{let e=(0,d.watch)(a,{recursive:!0},(a,b)=>{if(b&&!(b.startsWith(".next/")||b.startsWith("node_modules/"))){if(b.startsWith(".git/")){(".git/HEAD"===b||b.startsWith(".git/refs/"))&&c({type:"git"});return}c({type:"file"})}});e.on("error",c=>{console.error(`File watcher error for ${a}:`,c);let d=b.watchers.indexOf(e);-1!==d&&b.watchers.splice(d,1);try{e.close()}catch{}b.listeners.size>0&&!b.cwdRestartTimer&&(b.cwdRestartTimer=setTimeout(()=>{b.cwdRestartTimer=null,b.listeners.size>0&&h()},2e3))}),b.watchers.push(e)}catch(b){console.error(`Failed to watch ${a}:`,b)}};h();let i=function(a){let b=(0,e.join)(a,".git");try{if((0,d.statSync)(b).isDirectory())return b;let c=(0,d.readFileSync)(b,"utf-8").trim().match(/^gitdir:\s*(.+)$/);if(c)return(0,e.resolve)(a,c[1])}catch{}return b}(a),j=a=>{try{let e=(0,d.watch)(a,()=>{c({type:"git"});try{e.close()}catch{}let d=b.watchers.indexOf(e);-1!==d&&b.watchers.splice(d,1),b.listeners.size>0&&setTimeout(()=>j(a),50)});e.on("error",()=>{let c=b.watchers.indexOf(e);-1!==c&&b.watchers.splice(c,1),b.listeners.size>0&&(0,d.existsSync)(a)&&setTimeout(()=>j(a),500)}),b.watchers.push(e)}catch{}};for(let a of f){let b=a.replace(".git/","");j((0,e.join)(i,b))}let k=function(a){try{let b=(0,d.readFileSync)((0,e.join)(a,"commondir"),"utf-8").trim();if(b)return(0,e.resolve)(a,b)}catch{}return a}(i);for(let a of g){let f=a.replace(".git/","");try{let a=(0,d.watch)((0,e.join)(k,f),{recursive:!0},()=>{c({type:"git"})});a.on("error",()=>{}),b.watchers.push(a)}catch{}}return b}flush(a){if(a.debounceTimer&&(clearTimeout(a.debounceTimer),a.debounceTimer=null),a.throttleTimer&&(clearTimeout(a.throttleTimer),a.throttleTimer=null),0===a.pendingEvents.length)return;let b=[...a.pendingEvents];for(let c of(a.pendingEvents=[],a.listeners))try{c(b)}catch(a){console.error("File watcher callback error:",a)}}constructor(){this.watchers=new Map}}let i=globalThis,j=i.__cockpitFileWatcher??(i.__cockpitFileWatcher=new h)}};