@surething/cockpit 1.0.272 → 1.0.274
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.
- package/.next-prod/BUILD_ID +1 -1
- package/.next-prod/app-path-routes-manifest.json +8 -6
- package/.next-prod/build-manifest.json +3 -3
- package/.next-prod/cockpit-build.json +1 -1
- package/.next-prod/prerender-manifest.json +4 -4
- package/.next-prod/react-loadable-manifest.json +0 -12
- package/.next-prod/routes-manifest.json +20 -6
- package/.next-prod/server/app/_global-error/page.js +2 -2
- package/.next-prod/server/app/_global-error/page.js.nft.json +1 -1
- package/.next-prod/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/_global-error.html +1 -1
- package/.next-prod/server/app/_global-error.rsc +1 -1
- package/.next-prod/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next-prod/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/.next-prod/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next-prod/server/app/_not-found/page.js +1 -1
- package/.next-prod/server/app/_not-found/page.js.nft.json +1 -1
- package/.next-prod/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/_not-found.html +2 -2
- package/.next-prod/server/app/_not-found.rsc +3 -3
- package/.next-prod/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/.next-prod/server/app/_not-found.segments/_index.segment.rsc +3 -3
- package/.next-prod/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next-prod/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next-prod/server/app/api/agent/test/route.js +1 -1
- package/.next-prod/server/app/api/agent/test/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/bash/route.js +1 -1
- package/.next-prod/server/app/api/bash/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/codex/route.js +1 -1
- package/.next-prod/server/app/api/chat/codex/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/deepseek/route.js +1 -1
- package/.next-prod/server/app/api/chat/deepseek/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/glm/route.js +1 -1
- package/.next-prod/server/app/api/chat/glm/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/kimi/route.js +1 -1
- package/.next-prod/server/app/api/chat/kimi/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/ollama/route.js +1 -1
- package/.next-prod/server/app/api/chat/ollama/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/route.js +1 -1
- package/.next-prod/server/app/api/chat/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/stop/route.js +1 -1
- package/.next-prod/server/app/api/chat/stop/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/claude-stats/route.js +1 -1
- package/.next-prod/server/app/api/claude-stats/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/commands/route.js +1 -1
- package/.next-prod/server/app/api/commands/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/comments/route.js +1 -1
- package/.next-prod/server/app/api/comments/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/columns/route.js +1 -1
- package/.next-prod/server/app/api/db/columns/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/connect/route.js +1 -1
- package/.next-prod/server/app/api/db/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/db/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/export/route.js +1 -1
- package/.next-prod/server/app/api/db/export/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/query/route.js +1 -1
- package/.next-prod/server/app/api/db/query/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/schemas/route.js +1 -1
- package/.next-prod/server/app/api/db/schemas/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/deepseek/balance/route.js +1 -1
- package/.next-prod/server/app/api/deepseek/balance/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/deepseek/credentials/route.js +1 -1
- package/.next-prod/server/app/api/deepseek/credentials/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/deepseek/models/route.js +1 -1
- package/.next-prod/server/app/api/deepseek/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/dev/spans/route.js +1 -1
- package/.next-prod/server/app/api/dev/spans/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/extension/version/route.js +1 -1
- package/.next-prod/server/app/api/extension/version/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/file/route.js +1 -1
- package/.next-prod/server/app/api/file/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/blame/route.js +1 -1
- package/.next-prod/server/app/api/files/blame/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/clipboard/route.js +1 -1
- package/.next-prod/server/app/api/files/clipboard/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/copy/route.js +1 -1
- package/.next-prod/server/app/api/files/copy/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/delete/route.js +1 -1
- package/.next-prod/server/app/api/files/delete/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/expanded/route.js +1 -1
- package/.next-prod/server/app/api/files/expanded/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/index/route.js +1 -1
- package/.next-prod/server/app/api/files/index/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/init/route.js +1 -1
- package/.next-prod/server/app/api/files/init/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/paste/route.js +1 -1
- package/.next-prod/server/app/api/files/paste/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/read/route.js +1 -1
- package/.next-prod/server/app/api/files/read/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/readdir/route.js +1 -1
- package/.next-prod/server/app/api/files/readdir/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/recent/route.js +1 -1
- package/.next-prod/server/app/api/files/recent/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/save/route.js +1 -1
- package/.next-prod/server/app/api/files/save/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/search/route.js +1 -1
- package/.next-prod/server/app/api/files/search/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/stat/route.js +1 -1
- package/.next-prod/server/app/api/files/stat/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/text/route.js +1 -1
- package/.next-prod/server/app/api/files/text/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/blob/route.js +1 -1
- package/.next-prod/server/app/api/git/blob/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/branch-diff/route.js +1 -1
- package/.next-prod/server/app/api/git/branch-diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/branches/route.js +1 -1
- package/.next-prod/server/app/api/git/branches/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/commit-diff/route.js +1 -1
- package/.next-prod/server/app/api/git/commit-diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/commits/route.js +1 -1
- package/.next-prod/server/app/api/git/commits/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/current-branch/route.js +1 -1
- package/.next-prod/server/app/api/git/current-branch/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/diff/route.js +1 -1
- package/.next-prod/server/app/api/git/diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/discard/route.js +1 -1
- package/.next-prod/server/app/api/git/discard/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/stage/route.js +1 -1
- package/.next-prod/server/app/api/git/stage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/status/route.js +1 -1
- package/.next-prod/server/app/api/git/status/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/unstage/route.js +1 -1
- package/.next-prod/server/app/api/git/unstage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/worktree/route.js +1 -1
- package/.next-prod/server/app/api/git/worktree/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/glm/credentials/route.js +1 -1
- package/.next-prod/server/app/api/glm/credentials/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/glm/models/route.js +1 -1
- package/.next-prod/server/app/api/glm/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/glm/usage/route.js +1 -1
- package/.next-prod/server/app/api/glm/usage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/global-state/route.js +1 -1
- package/.next-prod/server/app/api/global-state/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/health/route.js +1 -1
- package/.next-prod/server/app/api/health/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/html-apps/[id]/route.js +1 -1
- package/.next-prod/server/app/api/html-apps/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/html-apps/route.js +1 -1
- package/.next-prod/server/app/api/html-apps/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/instructions/config/route.js +1 -0
- package/.next-prod/server/app/api/{prompts → instructions}/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/instructions/config/route_client-reference-manifest.js +1 -0
- package/.next-prod/server/app/api/kimi/credentials/route.js +1 -1
- package/.next-prod/server/app/api/kimi/credentials/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/kimi/models/route.js +1 -1
- package/.next-prod/server/app/api/kimi/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/kimi/usage/route.js +1 -1
- package/.next-prod/server/app/api/kimi/usage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/definition/route.js +1 -1
- package/.next-prod/server/app/api/lsp/definition/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/hover/route.js +1 -1
- package/.next-prod/server/app/api/lsp/hover/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/references/route.js +1 -1
- package/.next-prod/server/app/api/lsp/references/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/status/route.js +1 -1
- package/.next-prod/server/app/api/lsp/status/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/warmup/route.js +1 -1
- package/.next-prod/server/app/api/lsp/warmup/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/columns/route.js +1 -1
- package/.next-prod/server/app/api/mysql/columns/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/connect/route.js +1 -1
- package/.next-prod/server/app/api/mysql/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/mysql/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/export/route.js +1 -1
- package/.next-prod/server/app/api/mysql/export/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/query/route.js +1 -1
- package/.next-prod/server/app/api/mysql/query/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/schemas/route.js +2 -2
- package/.next-prod/server/app/api/mysql/schemas/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/connect/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/query/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/query/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/schema/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/schema/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/note/route.js +1 -1
- package/.next-prod/server/app/api/note/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/config/route.js +1 -1
- package/.next-prod/server/app/api/ollama/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/models/route.js +1 -1
- package/.next-prod/server/app/api/ollama/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/start/route.js +1 -1
- package/.next-prod/server/app/api/ollama/start/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/open-cursor/route.js +1 -1
- package/.next-prod/server/app/api/open-cursor/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/open-vscode/route.js +1 -1
- package/.next-prod/server/app/api/open-vscode/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/pick-folder/route.js +1 -1
- package/.next-prod/server/app/api/pick-folder/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/pinned-sessions/route.js +1 -1
- package/.next-prod/server/app/api/pinned-sessions/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/project-settings/route.js +1 -1
- package/.next-prod/server/app/api/project-settings/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/project-state/route.js +2 -2
- package/.next-prod/server/app/api/project-state/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/affected/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/affected/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/callees/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/callees/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/callers/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/callers/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/coedit/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/coedit/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/context/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/context/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/file/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/file/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/file-functions/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/file-functions/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/impact/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/impact/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/related/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/related/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/risk/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/risk/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/search/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/search/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projects/route.js +1 -1
- package/.next-prod/server/app/api/projects/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/push/public-key/route.js +1 -1
- package/.next-prod/server/app/api/push/public-key/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/push/subscribe/route.js +1 -1
- package/.next-prod/server/app/api/push/subscribe/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/push/unsubscribe/route.js +1 -1
- package/.next-prod/server/app/api/push/unsubscribe/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/command/route.js +1 -1
- package/.next-prod/server/app/api/redis/command/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/connect/route.js +1 -1
- package/.next-prod/server/app/api/redis/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/delete/route.js +1 -1
- package/.next-prod/server/app/api/redis/delete/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/redis/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/get/route.js +1 -1
- package/.next-prod/server/app/api/redis/get/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/keys/route.js +1 -1
- package/.next-prod/server/app/api/redis/keys/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/set/route.js +1 -1
- package/.next-prod/server/app/api/redis/set/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/restart/route.js +1 -1
- package/.next-prod/server/app/api/restart/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/[id]/comments/route.js +1 -1
- package/.next-prod/server/app/api/review/[id]/comments/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/[id]/replies/route.js +1 -1
- package/.next-prod/server/app/api/review/[id]/replies/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/[id]/route.js +1 -1
- package/.next-prod/server/app/api/review/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/identify/route.js +1 -1
- package/.next-prod/server/app/api/review/identify/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/order/route.js +1 -1
- package/.next-prod/server/app/api/review/order/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/route.js +1 -1
- package/.next-prod/server/app/api/review/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/share-info/route.js +1 -1
- package/.next-prod/server/app/api/review/share-info/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/users/route.js +1 -1
- package/.next-prod/server/app/api/review/users/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/scheduled-tasks/route.js +2 -2
- package/.next-prod/server/app/api/scheduled-tasks/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/services/config/route.js +1 -1
- package/.next-prod/server/app/api/services/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/services/scripts/route.js +1 -1
- package/.next-prod/server/app/api/services/scripts/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/fork/route.js +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/fork/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/history/route.js +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/history/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/turn/route.js +2 -0
- package/.next-prod/server/app/api/session/[sessionId]/turn/route.js.nft.json +1 -0
- package/.next-prod/server/app/api/session/[sessionId]/turn/route_client-reference-manifest.js +1 -0
- package/.next-prod/server/app/api/session/user-messages/route.js +1 -0
- package/.next-prod/server/app/api/session/user-messages/route.js.nft.json +1 -0
- package/.next-prod/server/app/api/session/user-messages/route_client-reference-manifest.js +1 -0
- package/.next-prod/server/app/api/session-by-path/route.js +1 -3
- package/.next-prod/server/app/api/session-by-path/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/projects/[encodedPath]/route.js +1 -1
- package/.next-prod/server/app/api/sessions/projects/[encodedPath]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/projects/route.js +1 -1
- package/.next-prod/server/app/api/sessions/projects/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/route.js +1 -1
- package/.next-prod/server/app/api/sessions/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/settings/route.js +1 -1
- package/.next-prod/server/app/api/settings/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/shutdown/route.js +1 -1
- package/.next-prod/server/app/api/shutdown/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/skills/[id]/route.js +1 -1
- package/.next-prod/server/app/api/skills/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/skills/content/route.js +1 -1
- package/.next-prod/server/app/api/skills/content/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/skills/route.js +1 -1
- package/.next-prod/server/app/api/skills/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/blob/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/blob/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/diff/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/aliases/route.js +1 -1
- package/.next-prod/server/app/api/terminal/aliases/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/autocomplete/route.js +1 -1
- package/.next-prod/server/app/api/terminal/autocomplete/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/bubble-order/route.js +1 -1
- package/.next-prod/server/app/api/terminal/bubble-order/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/env/route.js +1 -1
- package/.next-prod/server/app/api/terminal/env/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/history/route.js +1 -1
- package/.next-prod/server/app/api/terminal/history/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/update/route.js +1 -1
- package/.next-prod/server/app/api/update/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/update-state/route.js +1 -1
- package/.next-prod/server/app/api/update-state/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/version/route.js +1 -1
- package/.next-prod/server/app/api/version/route.js.nft.json +1 -1
- package/.next-prod/server/app/apps/[...path]/route.js +1 -1
- package/.next-prod/server/app/apps/[...path]/route.js.nft.json +1 -1
- package/.next-prod/server/app/favicon.ico/route.js +1 -1
- package/.next-prod/server/app/favicon.ico/route.js.nft.json +1 -1
- package/.next-prod/server/app/m/page.js +1 -1
- package/.next-prod/server/app/m/page.js.nft.json +1 -1
- package/.next-prod/server/app/m/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/manifest.webmanifest/route.js +2 -2
- package/.next-prod/server/app/manifest.webmanifest/route.js.nft.json +1 -1
- package/.next-prod/server/app/page.js +1 -1
- package/.next-prod/server/app/page.js.nft.json +1 -1
- package/.next-prod/server/app/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/project/page.js +1 -1
- package/.next-prod/server/app/project/page.js.nft.json +1 -1
- package/.next-prod/server/app/project/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/review/[id]/page.js +1 -1
- package/.next-prod/server/app/review/[id]/page.js.nft.json +1 -1
- package/.next-prod/server/app/review/[id]/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app-paths-manifest.json +8 -6
- package/.next-prod/server/chunks/1237.js +1 -0
- package/.next-prod/server/chunks/2493.js +3 -3
- package/.next-prod/server/chunks/3286.js +1 -1
- package/.next-prod/server/chunks/4949.js +1 -1
- package/.next-prod/server/chunks/516.js +1 -1
- package/.next-prod/server/chunks/5750.js +19 -19
- package/.next-prod/server/chunks/6495.js +1 -1
- package/.next-prod/server/chunks/6548.js +1 -1
- package/.next-prod/server/chunks/{5766.js → 7956.js} +9 -10
- package/.next-prod/server/chunks/8616.js +3 -0
- package/.next-prod/server/chunks/9830.js +1 -1
- package/.next-prod/server/chunks/9891.js +7 -0
- package/.next-prod/server/functions-config-manifest.json +1 -1
- package/.next-prod/server/middleware-build-manifest.js +1 -1
- package/.next-prod/server/middleware-react-loadable-manifest.js +1 -1
- package/.next-prod/server/pages/404.html +2 -2
- package/.next-prod/server/pages/500.html +1 -1
- package/.next-prod/server/server-reference-manifest.json +1 -1
- package/.next-prod/static/Ltfbusd381Du6etTab1ug/_buildManifest.js +1 -0
- package/.next-prod/static/chunks/{4137-7d6f2498d03b184d.js → 103-1788abe4fb625136.js} +7 -7
- package/.next-prod/static/chunks/{1332-e26fddaef359ce51.js → 1332-e51496c0bf36be06.js} +5 -5
- package/.next-prod/static/chunks/{2032-8326efdf5830d58c.js → 2032-c4d080bb65101d4c.js} +1 -1
- package/.next-prod/static/chunks/2539-52ea8019220fc163.js +17 -0
- package/.next-prod/static/chunks/{9200-2d063007a9a86cd2.js → 8707-60c93d98f9ca9be7.js} +2 -2
- package/.next-prod/static/chunks/9092-9c01b3ae176018c5.js +716 -0
- package/.next-prod/static/chunks/9656-da407fc0921ddc52.js +32 -0
- package/.next-prod/static/chunks/96c8525a-b50f9758924ea57d.js +1 -0
- package/.next-prod/static/chunks/app/_global-error/page-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/agent/test/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/bash/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/codex/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/deepseek/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/glm/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/kimi/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/ollama/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/stop/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/claude-stats/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/commands/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/comments/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/db/columns/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/db/connect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/db/disconnect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/db/export/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/db/query/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/db/schemas/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/deepseek/balance/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/deepseek/credentials/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/deepseek/models/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/dev/spans/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/extension/version/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/file/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/blame/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/clipboard/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/copy/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/delete/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/expanded/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/index/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/init/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/paste/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/read/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/readdir/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/recent/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/save/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/search/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/stat/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/files/text/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/blob/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/branch-diff/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/branches/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/commit-diff/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/commits/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/current-branch/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/diff/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/discard/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/stage/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/status/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/unstage/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/git/worktree/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/glm/credentials/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/glm/models/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/glm/usage/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/global-state/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/health/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/html-apps/[id]/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/html-apps/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/instructions/config/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/kimi/credentials/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/kimi/models/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/kimi/usage/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/definition/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/hover/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/references/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/status/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/warmup/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/columns/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/connect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/disconnect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/export/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/query/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/schemas/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/connect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/query/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/schema/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/note/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/config/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/models/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/start/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/open-cursor/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/open-vscode/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/pick-folder/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/pinned-sessions/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/project-settings/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/project-state/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/affected/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/callees/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/callers/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/context/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/file/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/impact/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/related/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/risk/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/search/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/projects/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/push/public-key/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/push/subscribe/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/push/unsubscribe/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/command/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/connect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/delete/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/disconnect/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/get/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/keys/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/set/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/restart/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/[id]/comments/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/[id]/replies/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/[id]/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/identify/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/order/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/share-info/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/review/users/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/scheduled-tasks/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/services/config/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/services/scripts/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/session/user-messages/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/session-by-path/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/projects/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/settings/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/shutdown/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/skills/[id]/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/skills/content/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/skills/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/blob/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/diff/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/aliases/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/env/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/history/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/update/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/update-state/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/api/version/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/apps/[...path]/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/{layout-4d9685b25807b4c6.js → layout-c78a23d9fb720698.js} +1 -1
- package/.next-prod/static/chunks/app/m/page-54ed2c27ba82b757.js +1 -0
- package/.next-prod/static/chunks/app/manifest.webmanifest/route-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/app/{page-af99426a6c82e466.js → page-7219de792c309861.js} +1 -1
- package/.next-prod/static/chunks/app/project/{page-af99426a6c82e466.js → page-7219de792c309861.js} +1 -1
- package/.next-prod/static/chunks/app/review/[id]/{page-1fe42d46b22c6482.js → page-70fc17b48dfdf8d3.js} +1 -1
- package/.next-prod/static/chunks/bc21e3dd-86c39ec41fe6001c.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-dd925381ab99e37b.js +1 -0
- package/.next-prod/static/chunks/{webpack-82f9e372d672c6bc.js → webpack-9a02cd12ee150c50.js} +1 -1
- package/.next-prod/static/css/08c892de6d5e2335.css +1 -0
- package/.next-prod/trace +14 -14
- package/.next-prod/trace-build +1 -1
- package/.next-prod/types/app/api/{prompts → instructions}/config/route.ts +3 -3
- package/.next-prod/types/app/api/session/[sessionId]/turn/route.ts +353 -0
- package/.next-prod/types/app/api/session/user-messages/route.ts +353 -0
- package/.next-prod/types/routes.d.ts +4 -2
- package/.next-prod/types/validator.ts +27 -9
- package/dist/{cache-GIQJA4HL.mjs → cache-VBRI47HG.mjs} +28 -0
- package/dist/{chunk-TOA52B2X.mjs → chunk-OFFSCRWY.mjs} +18 -13
- package/dist/{chunk-PB4GBZQO.mjs → chunk-OO4ODUAC.mjs} +1 -1
- package/dist/{chunk-4EU4KZIO.mjs → chunk-SJ7VM26B.mjs} +4 -14
- package/dist/chunk-UG6WUXIQ.mjs +2907 -0
- package/dist/httpApi.mjs +2 -2
- package/dist/scheduledTasks.mjs +864 -512
- package/dist/wsServer.mjs +23 -2810
- package/package.json +3 -3
- package/public/html-lib/markdown.css +114 -70
- package/public/html-lib/markdown.js +12 -12
- package/public/tree-sitter/tree-sitter-lean.wasm +0 -0
- package/scripts/copy-tree-sitter-wasms.mjs +33 -3
- package/skills/cg/SKILL.md +140 -14
- package/.next-prod/server/app/api/prompts/config/route.js +0 -1
- package/.next-prod/server/app/api/prompts/config/route_client-reference-manifest.js +0 -1
- package/.next-prod/server/chunks/2540.js +0 -1
- package/.next-prod/server/chunks/2728.js +0 -1
- package/.next-prod/server/chunks/3718.js +0 -1
- package/.next-prod/server/chunks/9312.js +0 -1
- package/.next-prod/server/chunks/9352.js +0 -6
- package/.next-prod/static/ZqxwSTxy2HJcALhnBemS7/_buildManifest.js +0 -1
- package/.next-prod/static/chunks/6024-31a42934bf55e9e9.js +0 -32
- package/.next-prod/static/chunks/7184-2a5621de437121a2.js +0 -17
- package/.next-prod/static/chunks/7562.8fdc3abdd45c77ab.js +0 -1
- package/.next-prod/static/chunks/9012.6ed079104670001d.js +0 -1
- package/.next-prod/static/chunks/9092-f7267cbb4deb6fd5.js +0 -716
- package/.next-prod/static/chunks/96c8525a-f1e0653013503d49.js +0 -2
- package/.next-prod/static/chunks/app/_global-error/page-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/agent/test/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/bash/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/codex/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/deepseek/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/glm/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/kimi/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/ollama/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/stop/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/claude-stats/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/commands/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/comments/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/db/columns/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/db/connect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/db/disconnect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/db/export/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/db/query/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/db/schemas/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/deepseek/balance/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/deepseek/credentials/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/deepseek/models/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/dev/spans/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/extension/version/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/file/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/blame/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/clipboard/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/copy/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/delete/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/expanded/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/index/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/init/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/paste/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/read/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/readdir/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/recent/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/save/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/search/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/stat/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/files/text/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/blob/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/branch-diff/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/branches/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/commit-diff/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/commits/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/current-branch/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/diff/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/discard/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/stage/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/status/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/unstage/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/git/worktree/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/glm/credentials/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/glm/models/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/glm/usage/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/global-state/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/health/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/html-apps/[id]/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/html-apps/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/kimi/credentials/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/kimi/models/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/kimi/usage/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/definition/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/hover/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/references/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/status/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/warmup/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/columns/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/connect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/disconnect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/export/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/query/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/schemas/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/connect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/query/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/schema/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/note/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/config/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/models/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/start/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/open-cursor/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/open-vscode/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/pick-folder/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/pinned-sessions/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/project-settings/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/project-state/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/affected/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/callees/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/callers/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/context/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/file/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/impact/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/related/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/risk/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/search/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/projects/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/prompts/config/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/push/public-key/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/push/subscribe/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/push/unsubscribe/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/command/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/connect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/delete/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/disconnect/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/get/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/keys/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/set/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/restart/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/[id]/comments/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/[id]/replies/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/[id]/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/identify/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/order/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/share-info/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/review/users/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/scheduled-tasks/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/services/config/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/services/scripts/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/session-by-path/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/projects/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/settings/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/shutdown/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/skills/[id]/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/skills/content/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/skills/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/blob/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/diff/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/aliases/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/env/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/history/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/update/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/update-state/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/api/version/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/apps/[...path]/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/app/m/page-af6600597536f9a9.js +0 -1
- package/.next-prod/static/chunks/app/manifest.webmanifest/route-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/bc21e3dd-a78364524623b9b0.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-891e1a9c2b8144f7.js +0 -1
- package/.next-prod/static/css/ea27ccfe01ce807c.css +0 -1
- /package/.next-prod/static/{ZqxwSTxy2HJcALhnBemS7 → Ltfbusd381Du6etTab1ug}/_ssgManifest.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";exports.id=4949,exports.ids=[4949],exports.modules={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:()=>l,IS:()=>v,KP:()=>r,ZT:()=>x,_0:()=>s,iU:()=>n,jH:()=>o,zC:()=>t});var d=c(31421),e=c(73024),f=c(76760),g=c.n(f),h=c(57975),i=c(28677);let j=(0,h.promisify)(d.exec),k=new Set([".git","node_modules"]),l=15e3;function m(a){let b=a.toLowerCase(),c=b.lastIndexOf(".");if(c<0)return!1;let d=b.slice(c);for(let a of(0,i.cn)())if(a.toLowerCase()===d)return!0;return!1}async function n(a){try{await j("git rev-parse --git-dir",{cwd:a})}catch{return null}let{stdout:b}=await j("git -c core.quotePath=false ls-files --cached --others --exclude-standard",{cwd:a,maxBuffer:0x3200000}),c=[];for(let a of b.split("\n")){let b=a.trim();if(b&&m(b.slice(b.lastIndexOf("/")+1))&&(c.push(b),c.length>=l))break}return c}async function o(a,b,c){let d;if(!(c.length>=l)){try{d=await e.promises.readdir(a,{withFileTypes:!0})}catch{return}for(let e of d){if(c.length>=l)return;if(k.has(e.name)||e.name.startsWith(".git"))continue;let d=g().join(a,e.name);e.isDirectory()?await o(d,b,c):e.isFile()&&m(e.name)&&c.push(g().relative(b,d))}}}let p=[".ts",".tsx",".js",".jsx",".mjs",".cjs"],q=[".js",".jsx",".mjs",".cjs"];function r(a,b,c){let d=g().relative(b,a);if(d.startsWith(".."))return null;for(let a of q)if(d.endsWith(a)){d=d.slice(0,-a.length);break}if(c.has(d))return d;for(let a of p){let b=d+a;if(c.has(b))return b}for(let a of p){let b=g().join(d,"index"+a);if(c.has(b))return b}return null}function s(a,b){return""===b||a===b||a.startsWith(b+"/")}async function t(a,b){let c=await u(a);if(0===c.length)return new Map;let d=[];try{let{stdout:b}=await j("git -c core.quotePath=false ls-files --cached --others --exclude-standard",{cwd:a,maxBuffer:0x3200000});d=b.split("\n").map(a=>a.trim()).filter(a=>a.endsWith("/package.json")&&!a.includes("node_modules/"))}catch{return new Map}let f=d.filter(a=>{let b=a.slice(0,-13);return c.some(a=>{var c;return c=b,RegExp("^"+a.replace(/\\/g,"/").replace(/[.+^${}()|[\]]/g,"\\$&").replace(/\*\*/g,"___DOUBLESTAR___").replace(/\*/g,"[^/]*").replace(/___DOUBLESTAR___/g,".*")+"$").test(c)})}),h=new Map;for(let c of f){let d;try{d=JSON.parse(await e.promises.readFile(g().join(a,c),"utf8"))}catch{continue}if("string"!=typeof d.name)continue;let f=g().dirname(c),i=function(a,b,c){let d,e=b=>{let d=b.replace(/^\.\//,"");return v(g().posix.join(a,d),c)},f=b.exports;if("string"==typeof f)d=f;else if(f&&"object"==typeof f&&f["."]){let a=f["."];"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(g().posix.join(a,b)))return g().posix.join(a,b);return null}(f,d,b);h.set(d.name,{name:d.name,dir:f,entryFile:i})}return h}async function u(a){try{var b=await e.promises.readFile(g().join(a,"pnpm-workspace.yaml"),"utf8");let c=[],d=!1;for(let a of b.split("\n")){let b=a.replace(/#.*$/,"");if(/^packages\s*:/.test(b)){d=!0;continue}if(!d)continue;let e=b.match(/^\s*-\s*['"]?([^'"#\s]+)['"]?\s*$/);e?c.push(e[1]):/^\S/.test(b)&&(d=!1)}return c}catch{}try{let b=JSON.parse(await e.promises.readFile(g().join(a,"package.json"),"utf8")),c=b?.workspaces;if(Array.isArray(c))return c.filter(a=>"string"==typeof a);if(c&&Array.isArray(c.packages))return c.packages.filter(a=>"string"==typeof a)}catch{}return[]}function v(a,b){if(a.startsWith("..")||a.startsWith("/"))return null;for(let b of q)if(a.endsWith(b)){a=a.slice(0,-b.length);break}if(b.has(a))return a;for(let c of p){let d=a+c;if(b.has(d))return d}for(let c of p){let d=g().posix.join(a,"index"+c);if(b.has(d))return d}return null}async function w(a,b){let c,d=new Map;try{let b=(await e.promises.readFile(a,"utf8")).replace(/^\s*\/\/.*$/gm,"");c=JSON.parse(b)}catch{return d}let f=c?.compilerOptions?.baseUrl??".",h=c?.compilerOptions?.paths??{},i=g().resolve(g().dirname(a),f),j=g().relative(b,i)||".";for(let[a,b]of Object.entries(h)){if(!Array.isArray(b)||0===b.length)continue;let c=a.replace(/\/\*$/,""),e=b[0].replace(/\/\*$/,"");d.set(c,g().join(j,e))}return d}async function x(a){let b=[],c=[];try{let{stdout:b}=await j("git -c core.quotePath=false ls-files --cached --others --exclude-standard",{cwd:a,maxBuffer:0x3200000});c=b.split("\n").map(a=>a.trim()).filter(a=>/(^|\/)tsconfig[^/]*\.json$/.test(a)&&!a.includes("node_modules/"))}catch{try{await e.promises.access(g().join(a,"tsconfig.json")),c=["tsconfig.json"]}catch{}}for(let d of c){let c=await w(g().join(a,d),a);if(0===c.size)continue;let e=g().dirname(d);b.push({scope:"."===e?"":e,aliases:c,sortedAliases:y(c)})}let d=b.find(a=>""===a.scope);return d||(d={scope:"",aliases:new Map,sortedAliases:[]},b.push(d)),d.aliases.has("@")||(d.aliases.set("@","./src"),d.sortedAliases=y(d.aliases)),b.sort((a,b)=>b.scope.length-a.scope.length)}function y(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:()=>g,ik:()=>e});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(){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:()=>I,J:()=>O,Mv:()=>N,Xn:()=>M,bQ:()=>K,cl:()=>y,ih:()=>v,s7:()=>H,u$:()=>x,xl:()=>D});var e=c(73024),f=c(76760),g=c.n(f),h=c(31421),i=c(57975),j=c(87956),k=c(86236),l=c(25344),m=c(25157),n=c(27485),o=c(97669),p=c(83624),q=a([j]);async function r(a,b,c){let d=Array(a.length),e=0;async function f(){for(;e<a.length;){let b=e++;d[b]=await c(a[b])}}return await Promise.all(Array.from({length:Math.min(b,a.length)},f)),d}j=(q.then?(await q)():q)[0];let P=/(['"`])([A-Za-z][A-Za-z0-9_.-]{2,63})\1/g;async function s(a,b){let c,d,f,g=(0,j.M)(b);if(!g)return null;try{[c,d]=await Promise.all([e.promises.readFile(a,"utf8"),e.promises.stat(a).then(a=>a.mtimeMs)])}catch{return null}if(c.length>1e6)return null;let h=await (0,j.b)(g);try{f=h.parse(c)}catch(a){return console.error("[codeIndex] parse failed for",b,a),null}if(!f)return null;try{let a,e=(0,o.Bu)(g),h=e.extractSymbols(f.rootNode,c);(0,p.YN)(h);let i=(a=[],!function c(d){for(let e of d)a.push({filePath:b,qualifiedName:e.qualifiedName,name:e.name,kind:e.kind,startLine:e.startLine,endLine:e.endLine,params:e.params}),c(e.children)}(h),a),{specs:j,bindings:k}=e.extractImports(f.rootNode),l=e.extractCallSites(f.rootNode,i),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(P.lastIndex=0;null!==(c=P.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=t(b,g);d.push({value:a,line:g,...i?{enclosingQname:i.qualifiedName}:{}})}return d}(c,i);return{path:b,language:g,mtime:d,symbolsTree:h,flatSymbols:i,importBindings:k,importSpecifiers:j,rawCalls:l,literals:m}}finally{f.delete()}}function t(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}async function u(a){let b=Date.now();(0,m.d)(a,"listing",0,0,void 0,!0);let c=await (0,l.iU)(a);c||(c=[],await (0,l.jH)(a,a,c));let d=c.length>l.BE;d&&(c=c.slice(0,l.BE));let e=new Set(c);(0,m.d)(a,"contexts",0,c.length,void 0,!0);let f=await (0,l.ZT)(a),h=await (0,l.zC)(a,e),i=new Map;for(let b of k.I){let c=(0,o.Bu)(b);i.set(b,await c.buildProjectContext(a,e))}let j=c.length,n=0;(0,m.d)(a,"parsing",0,j,void 0,!0);let p=(await r(c,50,async b=>{let c=await s(g().join(a,b),b);return n+=1,(0,m.d)(a,"parsing",n,j,b),c})).filter(a=>null!==a);(0,m.d)(a,"resolving",j,j,void 0,!0);let q=new Map;for(let a of p){let b=(0,o.Bu)(a.language),c=i.get(a.language),d=new Map,f=new Set;for(let g of a.importSpecifiers){if(d.has(g))continue;let h=b.resolveSpecifier(g,a.path,c,e);h&&h!==a.path&&(d.set(g,h),f.add(h))}let g=new Map,h=new Map;for(let b of a.flatSymbols){h.set(b.qualifiedName,b);let a=g.get(b.name);a?a.push(b):g.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);q.set(a.path,{path:a.path,language:a.language,mtime:a.mtime,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:f,importedBy:new Set,importBindings:a.importBindings,resolvedImports:d,intraCalls:[],outgoingCalls:[],incomingCalls:[],externalCalls:[],methodCalls:[],symbolsByName:g,symbolsByQname:h,bindingsByLocalName:j,reexportsByLocalName:k})}for(let a of q.values())for(let b of a.importedFiles){let c=q.get(b);c&&c.importedBy.add(a.path)}for(let b of((0,m.d)(a,"edges",j,j,void 0,!0),p)){let a=q.get(b.path),c=(0,o.Bu)(b.language),d=i.get(b.language),e=new Map,f=new Map,g=new Map,h=new Map;for(let i of b.rawCalls){let b=t(a.flatSymbols,i.line);if(b){for(let j of c.resolveCall(i,b,a,q,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 q.values())for(let b of a.outgoingCalls){let c=q.get(b.to.filePath);c&&c.incomingCalls.push({from:{filePath:a.path,qualifiedName:b.from},to:b.to.qualifiedName,lines:b.lines})}return(0,m.d)(a,"done",j,j,void 0,!0),{cwd:a,files:q,truncated:d,fileCountCap:d?l.BE:void 0,tsconfigs:f,workspaces:h,projectContexts:i,fileSet:e,generatedAt:Date.now(),buildMs:Date.now()-b}}let Q=new Map,R=new Map,S=new Set,T=new Set,U=null;function v(a){if(U=a,a)for(let b of T)a(b,()=>S.add(b))}async function w(a,b){let c=Array.from(b.files.keys()),d=0,e=async()=>{for(;d<c.length;){let e=d++;try{await D(a,c[e],b)}catch{}}};await Promise.all(Array.from({length:Math.min(8,c.length)},e))}async function x(a,b={}){!T.has(a)&&(T.add(a),U&&U(a,()=>S.add(a))),b.forceRefresh&&(Q.delete(a),S.delete(a));let d=Q.get(a);if(d){if(S.has(a)){S.delete(a);try{await w(a,d)}catch{}}return d}let e=R.get(a);if(e)return e;let f=u(a).then(b=>(Q.set(a,b),R.delete(a),S.delete(a),Promise.all([c.e(4008),c.e(2540)]).then(c.bind(c,92540)).then(c=>c.precomputeAnalytics(a,b)).catch(a=>{console.error("[codeIndex] analytics precompute failed:",a)}),b)).catch(b=>{throw(0,m.d)(a,"done",0,0,void 0,!0),R.delete(a),b});return R.set(a,f),f}function y(a){if(Promise.all([c.e(4008),c.e(2540)]).then(c.bind(c,92540)).then(b=>b.invalidateAnalytics(a)).catch(()=>{}),!a){Q.clear(),R.clear(),S.clear();return}Q.delete(a),R.delete(a),S.delete(a)}let V=(0,i.promisify)(h.exec);async function z(a,b){let c=!0;try{await V("git rev-parse --git-dir",{cwd:a})}catch{c=!1}if(!c)return!(b.startsWith(".git")||b.startsWith("node_modules/")||b.includes("/node_modules/"));try{return await V(`git -c core.quotePath=false ls-files --cached --others --exclude-standard --error-unmatch -- '${b.replace(/'/g,"'\\''")}'`,{cwd:a}),!0}catch{return!1}}function A(a){Promise.all([c.e(4008),c.e(2540)]).then(c.bind(c,92540)).then(b=>b.invalidateAnalytics(a)).catch(()=>{})}async function B(a,b,c){if(!(0,j.M)(b)||c.files.size>=l.BE||!await z(a,b))return!1;let d=await s(g().join(a,b),b);return!!d&&(c.fileSet.add(d.path),await C(d,null,c),A(a),!0)}async function C(a,b,c){let d=(0,o.Bu)(a.language),e=c.projectContexts.get(a.language),f=new Map,g=new Set;for(let b of a.importSpecifiers){if(f.has(b))continue;let h=d.resolveSpecifier(b,a.path,e,c.fileSet);h&&h!==a.path&&(f.set(b,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:a.mtime,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:g,importedBy:b?.importedBy??new Set,importBindings:a.importBindings,resolvedImports:f,intraCalls:[],outgoingCalls:[],incomingCalls:b?.incomingCalls??[],externalCalls:[],methodCalls:[],symbolsByName:h,symbolsByQname:i,bindingsByLocalName:j,reexportsByLocalName:k},m=new Map,n=new Map,p=new Map,q=new Map;for(let b of(c.files.set(a.path,l),a.rawCalls)){let a=t(l.flatSymbols,b.line);if(a){for(let f of d.resolveCall(b,a,l,c.files,e))if("symbol"===f.kind)if(f.addr.filePath===l.path){let c=`${a.qualifiedName}${f.addr.qualifiedName}`,d=m.get(c);if(d)d.lines.push(b.line);else{let d={from:a.qualifiedName,to:f.addr.qualifiedName,lines:[b.line]};m.set(c,d),l.intraCalls.push(d)}}else{let c=`${a.qualifiedName}${f.addr.filePath}${f.addr.qualifiedName}`,d=n.get(c);if(d)d.lines.push(b.line);else{let d={from:a.qualifiedName,to:{filePath:f.addr.filePath,qualifiedName:f.addr.qualifiedName},lines:[b.line]};n.set(c,d),l.outgoingCalls.push(d)}}else if("external"===f.kind){let c=`${a.qualifiedName}${f.packageSpec}${f.name}`,d=p.get(c);if(d)d.lines.push(b.line);else{let d={from:a.qualifiedName,packageSpec:f.packageSpec,importedName:f.name,lines:[b.line]};p.set(c,d),l.externalCalls.push(d)}}else if("method-unresolved"===f.kind){let c=l.bindingsByLocalName.get(f.receiverName),d=c?l.resolvedImports.get(c.specifier)??"":"",e=`${a.qualifiedName}${f.receiverName}${f.methodName}`,g=q.get(e);if(g)g.lines.push(b.line);else{let c={from:a.qualifiedName,receiverName:f.receiverName,methodName:f.methodName,receiverFilePath:d,lines:[b.line]};q.set(e,c),l.methodCalls.push(c)}}}}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}async function D(a,b,c){let d,f=c.files.get(b);if(!f)return B(a,b,c);try{d=(await e.promises.stat(g().join(a,b))).mtimeMs}catch{return!1}if(d===f.mtime)return!1;let h=await s(g().join(a,b),b);return!!h&&(await C(h,f,c),A(a),!0)}function E(a){return{filePath:a.filePath,qualifiedName:a.qualifiedName,name:a.name,kind:a.kind,startLine:a.startLine,endLine:a.endLine,params:a.params}}function F(a){let b=a.indexOf(">");return b>=0?a.slice(0,b):a}function G(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 H(a,b){let c=a.files.get(b);if(!c)return null;let d=c.flatSymbols.filter(a=>!a.qualifiedName.includes(">")).map(E).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=F(a.from),c=F(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=G(a.lines);let h=[],i=new Map;for(let b of c.outgoingCalls){let d=F(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,n._)(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:E(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=F(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,n._)(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:E(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=G(a.lines);for(let a of j)a.lines.sort((a,b)=>a-b),a.lines=G(a.lines);let l=[],m=new Map;for(let a of c.externalCalls){let b=F(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=G(a.lines);let o=[],p=new Map;for(let a of c.methodCalls){let b=F(a.from);if(!e.has(b))continue;let c=`${b}|${a.receiverName}|${a.methodName}`,d=p.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()};p.set(c,d),o.push(d)}}for(let a of o)a.lines.sort((a,b)=>a-b),a.lines=G(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)),o.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:o,upstreamCalls:j,downstreamCalls:h}}function I(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 J(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}function K(a,b,c,d={}){let e=b.trim();if(!e)return d.includeLiterals?{files:[],symbols:[],literals:[]}:{files:[],symbols:[]};let f=J(e),g=[];for(let b of a.files.values()){if(g.length>=c)break;J(b.path).includes(f)&&g.push({type:"file",label:function(a){let b=a.lastIndexOf("/");return b>=0?a.slice(b+1):a}(b.path),hint:b.path,target:{kind:"file",filePath:b.path}})}let h=[];for(let b of a.files.values()){let a=!1;if(!function a(b,c){for(let d of b)if(c(d)||a(d.children,c))return!0;return!1}(b.symbolsTree,d=>h.length>=c?(a=!0,!0):"unknown"!==d.kind&&(J(d.name).includes(f)&&h.push({type:"symbol",label:d.name,hint:`${d.kind} \xb7 ${b.path}`,target:{kind:"symbol",filePath:b.path,line:d.startLine,symbolName:d.name,symbolKind:d.kind,qualifiedName:d.qualifiedName}}),!1)),a)break}if(!d.includeLiterals)return{files:g,symbols:h};let i=[];a:for(let b of a.files.values())for(let a of b.literals){if(i.length>=c)break a;J(a.value).includes(f)&&i.push({type:"literal",value:a.value,filePath:b.path,line:a.line,...a.enclosingQname?{enclosingSymbol:a.enclosingQname}:{}})}return{files:g,symbols:h,literals:i}}function L(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 M(a,b,c){let d=L(a,b,c);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:E(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:E(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=G(a.callLines);e.sort((a,b)=>a.caller.filePath.localeCompare(b.caller.filePath)||a.caller.qualifiedName.localeCompare(b.caller.qualifiedName));let g=E(d[0].symbolsByQname.get(b)),h=d.length>1?d.map(a=>a.path):void 0;return{qname:b,target:g,callers:e,ambiguousIn:h}}function N(a,b,c){let d=L(a,b,c);if(0===d.length)return{qname:b,source: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:E(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:E(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=G(a.callLines);e.sort((a,b)=>a.callee.filePath.localeCompare(b.callee.filePath)||a.callee.qualifiedName.localeCompare(b.callee.qualifiedName));let g=E(d[0].symbolsByQname.get(b)),h=d.length>1?d.map(a=>a.path):void 0;return{qname:b,source:g,callees:e,ambiguousIn:h}}function O(a,b,c,d){let e=L(a,b,d);if(0===e.length)return{qname:b,target:null,nodes:[],truncated:!1};let f=Math.min(Math.max(c,1),5),g=E(e[0].symbolsByQname.get(b)),h=e.length>1?e.map(a=>a.path):void 0,i=e.map(a=>({filePath:a.path,qname:b})),j=new Set(i.map(a=>`${a.filePath}|${a.qname}`)),k=i.map(b=>{let c=a.files.get(b.filePath).symbolsByQname.get(b.qname);return{symbol:E(c),depth:0}}),l=i.slice(),m=!1;for(let b=1;b<=f;b++){let c=[];for(let d of l){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(!j.has(g)&&(j.add(g),k.push({symbol:E(f),depth:b}),c.push({filePath:e.path,qname:a.from}),k.length>=500)){m=!0;break}}if(m)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(!j.has(h)&&(j.add(h),k.push({symbol:E(g),depth:b}),c.push({filePath:f.from.filePath,qname:f.from.qualifiedName}),k.length>=500)){m=!0;break}}if(m)break}}if(m||0===c.length)break;l=c}return k.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:k,truncated:m,ambiguousIn:h}}d()}catch(a){d(a)}})},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.ih)((a,b)=>{f.t.subscribe(a,a=>{a.some(a=>"file"===a.type||"git"===a.type)&&b()})}))}d()}catch(a){d(a)}})},83624:(a,b,c)=>{function d(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 e(a){return a.replace(/\s+/g," ").trim()}function f(a,b){return a?`${a}>${b}`:b}function g(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 h(a,b,c,g,i=[],j){return{qualifiedName:f(g,b),name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,contentHash:d(e(a.text)),children:i,params:j}}function i(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}function j(a,b){let c=new Map;for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);d&&d.type.endsWith("comment")&&c.set(d.endPosition.row+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 k(a,b){let c=a.text.split("\n"),f=c.length;if(0===f)return[];let g=new Uint8Array(f+2);for(let a of b){let b=Math.max(1,a.startLine),c=Math.min(f,a.endLine);for(let a=b;a<=c;a++)g[a]=1}let h=[],i=(a,b)=>{let f=!1;for(let d=a;d<=b;d++){let a=c[d-1];if(a&&a.trim().length>0){f=!0;break}}if(!f)return;let g=c.slice(a-1,b).join("\n");h.push({qualifiedName:`__code_${a}_${b}__`,name:"code",kind:"unknown",startLine:a,endLine:b,contentHash:d(e(g)),children:[]})},j=-1;for(let a=1;a<=f;a++)g[a]?j>=0&&(i(j,a-1),j=-1):j<0&&(j=a);return j>=0&&i(j,f),h}function l(a){let b=[],c=function(a){let b=[],c=-1,f=-1;for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e){if("import_statement"===e.type||"export_statement"===e.type&&null!==e.childForFieldName("source")||"import_from_statement"===e.type||"future_import_statement"===e.type)b.push(e),c<0&&(c=e.startPosition.row+1),f=e.endPosition.row+1;else if(c>=0)break}}return c<0?null:{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:f,contentHash:d(e(b.map(a=>a.text).join("\n"))),children:[]}}(a);c&&b.push(c);for(let c=0;c<a.namedChildCount;c++){let j=a.namedChild(c);j&&b.push(...function a(b,c,j=!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[h(b,g(b),"function",c,[],i(b))];case"class_declaration":case"abstract_class_declaration":{let a=g(b),d=f(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(h(e,g(e),"method",b,[],i(e)));else if("public_field_definition"===e.type){let a=e.childForFieldName("value");a&&("arrow_function"===a.type||"function_expression"===a.type)&&c.push(h(e,g(e),"method",b,[],i(a)))}}}return c}(b.childForFieldName("body"),d);return[h(b,a,"class",c,e)]}case"interface_declaration":return[h(b,g(b),"interface",c)];case"type_alias_declaration":return[h(b,g(b),"type",c)];case"enum_declaration":return[h(b,g(b),"enum",c)];case"lexical_declaration":case"variable_declaration":return function(a,b){let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(!e||"variable_declarator"!==e.type)continue;let f=e.childForFieldName("name"),j=e.childForFieldName("value");if(!f)continue;let k=f.text,l=j&&("arrow_function"===j.type||"function_expression"===j.type),m=l&&j?i(j):void 0;if(c.push(h(a,k,l?"function":"const",b,[],m)),j&&"object"===j.type&&!l){let a=b?`${b}>${k}`:k;for(let b=0;b<j.namedChildCount;b++){let d=j.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(h(d,b.text,"method",a,[],i(e)))}else if("method_definition"===d.type){let b=g(d);b&&c.push(h(d,b,"method",a,[],i(d)))}}}}}return c}(b,c);case"class_definition":{let a=g(b),j=f(c,a),k=function a(b,c){if(!b)return[];let j=[];for(let k=0;k<b.namedChildCount;k++){let l=b.namedChild(k);if(l){if("function_definition"===l.type)j.push(h(l,g(l),"method",c,[],i(l)));else if("decorated_definition"===l.type){let b=l.childForFieldName("definition");if(b?.type==="function_definition")j.push({...h(b,g(b),"method",c,[],i(b)),startLine:l.startPosition.row+1,contentHash:d(e(l.text))});else if(b?.type==="class_definition"){let i=g(b),k=f(c,i),m=a(b.childForFieldName("body"),k);j.push({...h(b,i,"class",c,m),startLine:l.startPosition.row+1,contentHash:d(e(l.text))})}}else if("class_definition"===l.type){let b=g(l),d=f(c,b),e=a(l.childForFieldName("body"),d);j.push(h(l,b,"class",c,e))}}}return j}(b.childForFieldName("body"),j);return[h(b,a,"class",c,k)]}case"decorated_definition":{let f=b.childForFieldName("definition");if(!f)return[];return a(f,c,!1).map(a=>({...a,startLine:b.startPosition.row+1,contentHash:d(e(b.text))}))}case"expression_statement":{let a=[];for(let g=0;g<b.namedChildCount;g++){let h=b.namedChild(g);if(h?.type==="assignment"){let g=function(a,b,c){let g=b.childForFieldName("left");if(!g||"identifier"!==g.type)return null;let h=g.text;return{qualifiedName:f(c,h),name:h,kind:"const",startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,contentHash:d(e(a.text)),children:[]}}(b,h,c);g&&a.push(g)}}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 j=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=j?`${j} ${f}`:f;return g.map((a,c)=>h(a,g.length>1?`${k} #${c+1}`:k,"function",b,[],i(a)))}(b,c)),a}default:return[]}}(j,void 0,!1))}return j(a,b),b.push(...k(a,b)),m(b),b}function m(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)}c.d(b,{Hs:()=>l,NZ:()=>e,YN:()=>m,_B:()=>k,mG:()=>j,qj:()=>d})},86236:(a,b,c)=>{c.d(b,{I:()=>d});let d=new Set(["typescript","tsx","javascript","python","go","rust"])},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";default:return null}}d()}catch(a){d(a)}})},88395:(a,b,c)=>{c.d(b,{t:()=>l});var d=c(29021),e=c(33873),f=c(7939);let g=[".git/HEAD",".git/MERGE_HEAD",".git/REBASE_HEAD"],h=[".git/refs"];class i{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))},f=()=>{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&&f()},2e3))}),b.watchers.push(e)}catch(b){console.error(`Failed to watch ${a}:`,b)}};f();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 g){let b=a.replace(".git/","");j((0,e.join)(i,b))}for(let a of h){let f=a.replace(".git/","");try{let a=(0,d.watch)((0,e.join)(i,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}}class j{subscribe(a){return this.listeners.add(a),this.watcher||this.start(),()=>{this.listeners.delete(a),0===this.listeners.size&&this.stop()}}start(){try{(0,d.existsSync)(f.Tb)||(0,d.mkdirSync)(f.Tb,{recursive:!0}),(0,d.existsSync)(f.jp)||(0,d.writeFileSync)(f.jp,"0"),this.watcher=(0,d.watch)(f.jp,()=>{this.debounceTimer&&clearTimeout(this.debounceTimer),this.debounceTimer=setTimeout(()=>this.notify(),300)}),this.watcher.on("error",()=>{this.stop(),setTimeout(()=>{this.listeners.size>0&&this.start()},2e3)})}catch{}}stop(){if(this.watcher){try{this.watcher.close()}catch{}this.watcher=null}this.debounceTimer&&(clearTimeout(this.debounceTimer),this.debounceTimer=null)}notify(){for(let a of this.listeners)try{a()}catch(a){console.error("ReviewWatcher callback error:",a)}}constructor(){this.listeners=new Set,this.watcher=null,this.debounceTimer=null}}let k=globalThis,l=k.__cockpitFileWatcher??(k.__cockpitFileWatcher=new i);k.__cockpitReviewWatcher??(k.__cockpitReviewWatcher=new j)},97669:(a,b,c)=>{c.d(b,{Bu:()=>d.Bu});var d=c(28677),e=c(76760),f=c.n(e),g=c(83624);function h(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 i(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):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 j(a){return a.length>=2&&('"'===a[0]||"'"===a[0])&&a[a.length-1]===a[0]?a.slice(1,-1):a}function k(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 l={typescript:k,tsx:k,javascript:k,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 m(a,b){let c=l[b];return c?c(a):[]}var n=c(25344);function o(a){return"function"===a||"class"===a||"method"===a}function p(a,b){return{grammarId:a,extensions:b,extractSymbols:(a,b)=>(0,g.Hs)(a),extractImports:b=>({specs:m(b,a),bindings:[...i(b),...function(a){let b=[];for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(!d||"export_statement"!==d.type)continue;let e=d.childForFieldName("source");if(!e)continue;let f=j(e.text),g=null;for(let a=0;a<d.namedChildCount;a++){let b=d.namedChild(a);if(b?.type==="export_clause"){g=b;break}}if(g)for(let a=0;a<g.namedChildCount;a++){let c=g.namedChild(a);if(!c||"export_specifier"!==c.type)continue;let d=c.childForFieldName("name"),e=c.childForFieldName("alias");if(!d)continue;let h=d.text,i=e?.text??h;b.push({localName:i,specifier:f,importedName:h,isReexport:!0})}}return b}(b)]}),extractCallSites:(a,b)=>h(a),async buildProjectContext(a,b){let c=new Set(b),d=await (0,n.ZT)(a),e=await (0,n.zC)(a,c),f=[...e.keys()].sort((a,b)=>b.length-a.length);return{cwd:a,tsconfigs:d,workspaces:e,sortedWsNames:f,owningScopesCache:new Map}},resolveSpecifier(a,b,c,d){let e=c.owningScopesCache.get(b);if(e||(e=c.tsconfigs.filter(a=>(0,n._0)(b,a.scope)),c.owningScopesCache.set(b,e)),a.startsWith("./")||a.startsWith("../"))return(0,n.KP)(f().resolve(c.cwd,f().dirname(b),a),c.cwd,d);if(a.startsWith("/"))return(0,n.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,n.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,n.IS)(f().posix.join(e.dir,g),d)??(0,n.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||f.has(b.path))return null;if(f.add(b.path),"*"!==c){let a=`${c}>${d}`,e=b.symbolsByQname.get(a);if(e&&o(e.kind))return e}if("*"===c){let a=b.symbolsByName.get(d);if(a){let b=null;for(let c of a)!c.qualifiedName.includes(">")&&o(c.kind)&&(!b||c.endLine-c.startLine>b.endLine-b.startLine)&&(b=c);if(b)return b}}let h=b.reexportsByLocalName.get(c);if(h){let c=b.resolvedImports.get(h.specifier);if(c){let b=g.get(c);if(b){let c=a(b,h.importedName,d,e+1,f,g);if(c)return c}}}return 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&&o(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,c,d,e,f){if(d>5||e.has(b.path))return null;e.add(b.path);let g=b.symbolsByName.get(c);if(g){let a=null;for(let b of g)o(b.kind)&&(!a||b.endLine-b.startLine>a.endLine-a.startLine)&&(a=b);if(a)return a}let h=b.reexportsByLocalName.get(c);if(h){let c=b.resolvedImports.get(h.specifier);if(c){let b=f.get(c);if(b){let c=a(b,h.importedName,d+1,e,f);if(c)return c}}}return null}(i,g.importedName,0,new Set,d);return j?[{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){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 v=c(73024);function w(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,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function x(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 y(a){try{let b=await v.promises.readFile(f().join(a,"go.mod"),"utf8"),c=/^\s*module\s+(\S+)/m.exec(b);return c?c[1].trim():null}catch{return null}}function z(a){return"function"===a||"class"===a||"method"===a}function A(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,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function B(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 C(a,b){let c=new Map,d=new Map,e=new Set;async function g(h,i){let j;if(e.has(i))return;e.add(i),c.set(h,i),d.set(i,h);try{j=await v.promises.readFile(f().join(a,i),"utf8")}catch{return}let k=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}(j);if(0===k.length)return;let l=f().dirname(i),m=f().basename(i,".rs"),n="mod"===m||"lib"===m||"main"===m?[l]:[l,f().join(l,m)];for(let a of k){let c=`${h}::${a}`,d=null;for(let c of n){for(let e of[f().join(c,`${a}.rs`),f().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 g(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 g("crate",a);else if(a.startsWith("src/bin/"))await g("crate",a);else{let b=a.split("/"),c=b.indexOf("src");if(c>0){let d=b[c-1];await g(d,a)}}return{modTree:c,fileToMod:d}}function D(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:m(a,"python"),bindings:i(a)}),extractCallSites:(a,b)=>h(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 u(h||".",g,d)}for(let b of c.pythonRoots){let e=u(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&&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}(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&&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 j=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 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,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(w(e,a.text,"function",void 0,[],x(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=w(e,a.text,"method",d??void 0,[],x(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(w(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(w(e,f.text,"const",b))}else"identifier"===a.type&&c.push(w(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){let c=await y(a);return{cwd:a,modulePath:c,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(">")&&z(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&&z(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(">"))&&z(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,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(A(e,a.text,"function",void 0,[],B(e)));break}case"struct_item":case"union_item":{let a=e.childForFieldName("name");if(!a)break;b.push(A(e,a.text,"class",void 0));break}case"enum_item":{let a=e.childForFieldName("name");if(!a)break;b.push(A(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(A(e,a.text,"method",b,[],B(e)))}}return d}(e,a.text);b.push(A(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(A(e,a.text,"method",b,[],B(e)))}else if("function_signature_item"===e.type){let a=e.childForFieldName("name");if(!a)continue;d.push(A(e,a.text,"method",b,[],B(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(A(e,a.text,"const",void 0));break}case"type_item":{let a=e.childForFieldName("name");if(!a)break;b.push(A(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(A(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){let{modTree:c,fileToMod:d}=await C(a,b);return{cwd:a,modTree:c,fileToMod:d}},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(">")&&D(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&&D(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(">"))&&D(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(">")&&D(a.kind)){f=a;break}}return f?[{kind:"symbol",addr:{filePath:f.filePath,qualifiedName:f.qualifiedName}}]:[]},moduleForFile:(a,b)=>b?.fileToMod.get(a)??f().dirname(a)})}};
|
|
1
|
+
"use strict";exports.id=4949,exports.ids=[4949],exports.modules={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:()=>l,IS:()=>v,KP:()=>r,ZT:()=>x,_0:()=>s,iU:()=>n,jH:()=>o,zC:()=>t});var d=c(31421),e=c(73024),f=c(76760),g=c.n(f),h=c(57975),i=c(28677);let j=(0,h.promisify)(d.exec),k=new Set([".git","node_modules"]),l=1e5;function m(a){let b=a.toLowerCase(),c=b.lastIndexOf(".");if(c<0)return!1;let d=b.slice(c);for(let a of(0,i.cn)())if(a.toLowerCase()===d)return!0;return!1}async function n(a){try{await j("git rev-parse --git-dir",{cwd:a})}catch{return null}let{stdout:b}=await j("git -c core.quotePath=false ls-files --cached --others --exclude-standard",{cwd:a,maxBuffer:0x3200000}),c=[];for(let a of b.split("\n")){let b=a.trim();if(b&&m(b.slice(b.lastIndexOf("/")+1))&&(c.push(b),c.length>=l))break}return c}async function o(a,b,c){let d;if(!(c.length>=l)){try{d=await e.promises.readdir(a,{withFileTypes:!0})}catch{return}for(let e of d){if(c.length>=l)return;if(k.has(e.name)||e.name.startsWith(".git"))continue;let d=g().join(a,e.name);e.isDirectory()?await o(d,b,c):e.isFile()&&m(e.name)&&c.push(g().relative(b,d))}}}let p=[".ts",".tsx",".js",".jsx",".mjs",".cjs"],q=[".js",".jsx",".mjs",".cjs"];function r(a,b,c){let d=g().relative(b,a);if(d.startsWith(".."))return null;for(let a of q)if(d.endsWith(a)){d=d.slice(0,-a.length);break}if(c.has(d))return d;for(let a of p){let b=d+a;if(c.has(b))return b}for(let a of p){let b=g().join(d,"index"+a);if(c.has(b))return b}return null}function s(a,b){return""===b||a===b||a.startsWith(b+"/")}async function t(a,b){let c=await u(a);if(0===c.length)return new Map;let d=[];try{let{stdout:b}=await j("git -c core.quotePath=false ls-files --cached --others --exclude-standard",{cwd:a,maxBuffer:0x3200000});d=b.split("\n").map(a=>a.trim()).filter(a=>a.endsWith("/package.json")&&!a.includes("node_modules/"))}catch{return new Map}let f=d.filter(a=>{let b=a.slice(0,-13);return c.some(a=>{var c;return c=b,RegExp("^"+a.replace(/\\/g,"/").replace(/[.+^${}()|[\]]/g,"\\$&").replace(/\*\*/g,"___DOUBLESTAR___").replace(/\*/g,"[^/]*").replace(/___DOUBLESTAR___/g,".*")+"$").test(c)})}),h=new Map;for(let c of f){let d;try{d=JSON.parse(await e.promises.readFile(g().join(a,c),"utf8"))}catch{continue}if("string"!=typeof d.name)continue;let f=g().dirname(c),i=function(a,b,c){let d,e=b=>{let d=b.replace(/^\.\//,"");return v(g().posix.join(a,d),c)},f=b.exports;if("string"==typeof f)d=f;else if(f&&"object"==typeof f&&f["."]){let a=f["."];"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(g().posix.join(a,b)))return g().posix.join(a,b);return null}(f,d,b);h.set(d.name,{name:d.name,dir:f,entryFile:i})}return h}async function u(a){try{var b=await e.promises.readFile(g().join(a,"pnpm-workspace.yaml"),"utf8");let c=[],d=!1;for(let a of b.split("\n")){let b=a.replace(/#.*$/,"");if(/^packages\s*:/.test(b)){d=!0;continue}if(!d)continue;let e=b.match(/^\s*-\s*['"]?([^'"#\s]+)['"]?\s*$/);e?c.push(e[1]):/^\S/.test(b)&&(d=!1)}return c}catch{}try{let b=JSON.parse(await e.promises.readFile(g().join(a,"package.json"),"utf8")),c=b?.workspaces;if(Array.isArray(c))return c.filter(a=>"string"==typeof a);if(c&&Array.isArray(c.packages))return c.packages.filter(a=>"string"==typeof a)}catch{}return[]}function v(a,b){if(a.startsWith("..")||a.startsWith("/"))return null;for(let b of q)if(a.endsWith(b)){a=a.slice(0,-b.length);break}if(b.has(a))return a;for(let c of p){let d=a+c;if(b.has(d))return d}for(let c of p){let d=g().posix.join(a,"index"+c);if(b.has(d))return d}return null}async function w(a,b){let c,d=new Map;try{let b=(await e.promises.readFile(a,"utf8")).replace(/^\s*\/\/.*$/gm,"");c=JSON.parse(b)}catch{return d}let f=c?.compilerOptions?.baseUrl??".",h=c?.compilerOptions?.paths??{},i=g().resolve(g().dirname(a),f),j=g().relative(b,i)||".";for(let[a,b]of Object.entries(h)){if(!Array.isArray(b)||0===b.length)continue;let c=a.replace(/\/\*$/,""),e=b[0].replace(/\/\*$/,"");d.set(c,g().join(j,e))}return d}async function x(a){let b=[],c=[];try{let{stdout:b}=await j("git -c core.quotePath=false ls-files --cached --others --exclude-standard",{cwd:a,maxBuffer:0x3200000});c=b.split("\n").map(a=>a.trim()).filter(a=>/(^|\/)tsconfig[^/]*\.json$/.test(a)&&!a.includes("node_modules/"))}catch{try{await e.promises.access(g().join(a,"tsconfig.json")),c=["tsconfig.json"]}catch{}}for(let d of c){let c=await w(g().join(a,d),a);if(0===c.size)continue;let e=g().dirname(d);b.push({scope:"."===e?"":e,aliases:c,sortedAliases:y(c)})}let d=b.find(a=>""===a.scope);return d||(d={scope:"",aliases:new Map,sortedAliases:[]},b.push(d)),d.aliases.has("@")||(d.aliases.set("@","./src"),d.sortedAliases=y(d.aliases)),b.sort((a,b)=>b.scope.length-a.scope.length)}function y(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:()=>J,FW:()=>v,J:()=>P,Mv:()=>O,Xn:()=>N,bQ:()=>L,cl:()=>z,ih:()=>w,s7:()=>I,u$:()=>y,xl:()=>E});var e=c(73024),f=c(76760),g=c.n(f),h=c(31421),i=c(57975),j=c(87956),k=c(86236),l=c(25344),m=c(25157),n=c(27485),o=c(91939),p=c(83624),q=a([j]);async function r(a,b,c){let d=Array(a.length),e=0;async function f(){for(;e<a.length;){let b=e++;d[b]=await c(a[b])}}return await Promise.all(Array.from({length:Math.min(b,a.length)},f)),d}j=(q.then?(await q)():q)[0];let Q=/(['"`])([A-Za-z][A-Za-z0-9_.-]{2,63})\1/g;async function s(a,b){let c,d,f,g=(0,j.M)(b);if(!g)return null;try{[c,d]=await Promise.all([e.promises.readFile(a,"utf8"),e.promises.stat(a).then(a=>a.mtimeMs)])}catch{return null}if(c.length>1e6)return null;let h=await (0,j.b)(g);try{f=h.parse(c)}catch(a){return console.error("[codeIndex] parse failed for",b,a),null}if(!f)return null;try{let a,e=(0,o.Bu)(g),h=e.extractSymbols(f.rootNode,c);(0,p.YN)(h);let i=(a=[],!function c(d){for(let e of d)a.push({filePath:b,qualifiedName:e.qualifiedName,name:e.name,kind:e.kind,startLine:e.startLine,endLine:e.endLine,params:e.params}),c(e.children)}(h),a),{specs:j,bindings:k}=e.extractImports(f.rootNode),l=e.extractCallSites(f.rootNode,i),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(Q.lastIndex=0;null!==(c=Q.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=t(b,g);d.push({value:a,line:g,...i?{enclosingQname:i.qualifiedName}:{}})}return d}(c,i);return{path:b,language:g,mtime:d,symbolsTree:h,flatSymbols:i,importBindings:k,importSpecifiers:j,rawCalls:l,literals:m}}finally{f.delete()}}function t(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}async function u(a){let b=Date.now();(0,m.d)(a,"listing",0,0,void 0,!0);let c=await (0,l.iU)(a);c||(c=[],await (0,l.jH)(a,a,c));let d=c.length>l.BE;d&&(c=c.slice(0,l.BE));let e=new Set(c);(0,m.d)(a,"contexts",0,c.length,void 0,!0);let f=await (0,l.ZT)(a),h=await (0,l.zC)(a,e),i=new Map;for(let b of k.I){let c=(0,o.iv)(b);c&&i.set(b,await c.buildProjectContext(a,e))}let j=c.length,n=0;(0,m.d)(a,"parsing",0,j,void 0,!0);let p=(await r(c,50,async b=>{let c=await s(g().join(a,b),b);return n+=1,(0,m.d)(a,"parsing",n,j,b),c})).filter(a=>null!==a);(0,m.d)(a,"resolving",j,j,void 0,!0);let q=new Map;for(let a of p){let b=(0,o.Bu)(a.language),c=i.get(a.language),d=new Map,f=new Set;for(let g of a.importSpecifiers){if(d.has(g))continue;let h=b.resolveSpecifier(g,a.path,c,e);h&&h!==a.path&&(d.set(g,h),f.add(h))}let g=new Map,h=new Map;for(let b of a.flatSymbols){h.set(b.qualifiedName,b);let a=g.get(b.name);a?a.push(b):g.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);q.set(a.path,{path:a.path,language:a.language,mtime:a.mtime,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:f,importedBy:new Set,importBindings:a.importBindings,resolvedImports:d,intraCalls:[],outgoingCalls:[],incomingCalls:[],externalCalls:[],methodCalls:[],symbolsByName:g,symbolsByQname:h,bindingsByLocalName:j,reexportsByLocalName:k})}for(let a of q.values())for(let b of a.importedFiles){let c=q.get(b);c&&c.importedBy.add(a.path)}for(let b of((0,m.d)(a,"edges",j,j,void 0,!0),p)){let a=q.get(b.path),c=(0,o.Bu)(b.language),d=i.get(b.language),e=new Map,f=new Map,g=new Map,h=new Map;for(let i of b.rawCalls){let b=t(a.flatSymbols,i.line);if(b){for(let j of c.resolveCall(i,b,a,q,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 q.values())for(let b of a.outgoingCalls){let c=q.get(b.to.filePath);c&&c.incomingCalls.push({from:{filePath:a.path,qualifiedName:b.from},to:b.to.qualifiedName,lines:b.lines})}return(0,m.d)(a,"done",j,j,void 0,!0),{cwd:a,files:q,truncated:d,fileCountCap:d?l.BE:void 0,tsconfigs:f,workspaces:h,projectContexts:i,fileSet:e,generatedAt:Date.now(),buildMs:Date.now()-b}}let R=new Map,S=new Map;function v(a){let b=0;for(let c of a.files.values())b+=c.flatSymbols.length;return b}let T=new Set,U=new Set,V=null;function w(a){if(V=a,a)for(let b of U)a(b,()=>T.add(b))}async function x(a,b){let c=Array.from(b.files.keys()),d=0,e=async()=>{for(;d<c.length;){let e=d++;try{await E(a,c[e],b)}catch{}}};await Promise.all(Array.from({length:Math.min(8,c.length)},e))}async function y(a,b={}){!U.has(a)&&(U.add(a),V&&V(a,()=>T.add(a))),b.forceRefresh&&(R.delete(a),T.delete(a));let d=R.get(a);if(d){if(R.delete(a),R.set(a,d),T.has(a)){T.delete(a);try{await x(a,d)}catch{}}return d}let e=S.get(a);if(e)return e;let f=u(a).then(b=>{R.set(a,b);let d=0,e=new Map;for(let[a,b]of R){let c=v(b);e.set(a,c),d+=c}if(!(d<=1e6))for(let b of[...R.keys()]){if(d<=1e6)break;if(b===a)continue;let c=e.get(b)??0;R.delete(b),T.delete(b),B(b),d-=c,console.log(`[codeIndex] evicted ${b} (${c} symbols) — cache over MAX_CACHED_SYMBOLS=1000000`)}return S.delete(a),T.delete(a),Promise.all([c.e(4008),c.e(1237)]).then(c.bind(c,21237)).then(c=>c.precomputeAnalytics(a,b)).catch(a=>{console.error("[codeIndex] analytics precompute failed:",a)}),b}).catch(b=>{throw(0,m.d)(a,"done",0,0,void 0,!0),S.delete(a),b});return S.set(a,f),f}function z(a){if(Promise.all([c.e(4008),c.e(1237)]).then(c.bind(c,21237)).then(b=>b.invalidateAnalytics(a)).catch(()=>{}),!a){R.clear(),S.clear(),T.clear();return}R.delete(a),S.delete(a),T.delete(a)}let W=(0,i.promisify)(h.exec);async function A(a,b){let c=!0;try{await W("git rev-parse --git-dir",{cwd:a})}catch{c=!1}if(!c)return!(b.startsWith(".git")||b.startsWith("node_modules/")||b.includes("/node_modules/"));try{return await W(`git -c core.quotePath=false ls-files --cached --others --exclude-standard --error-unmatch -- '${b.replace(/'/g,"'\\''")}'`,{cwd:a}),!0}catch{return!1}}function B(a){Promise.all([c.e(4008),c.e(1237)]).then(c.bind(c,21237)).then(b=>b.invalidateAnalytics(a)).catch(()=>{})}async function C(a,b,c){if(!(0,j.M)(b)||c.files.size>=l.BE||!await A(a,b))return!1;let d=await s(g().join(a,b),b);return!!d&&(c.fileSet.add(d.path),await D(d,null,c),B(a),!0)}async function D(a,b,c){let d=(0,o.Bu)(a.language),e=c.projectContexts.get(a.language),f=new Map,g=new Set;for(let b of a.importSpecifiers){if(f.has(b))continue;let h=d.resolveSpecifier(b,a.path,e,c.fileSet);h&&h!==a.path&&(f.set(b,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:a.mtime,symbolsTree:a.symbolsTree,flatSymbols:a.flatSymbols,literals:a.literals,importedFiles:g,importedBy:b?.importedBy??new Set,importBindings:a.importBindings,resolvedImports:f,intraCalls:[],outgoingCalls:[],incomingCalls:b?.incomingCalls??[],externalCalls:[],methodCalls:[],symbolsByName:h,symbolsByQname:i,bindingsByLocalName:j,reexportsByLocalName:k},m=new Map,n=new Map,p=new Map,q=new Map;for(let b of(c.files.set(a.path,l),a.rawCalls)){let a=t(l.flatSymbols,b.line);if(a){for(let f of d.resolveCall(b,a,l,c.files,e))if("symbol"===f.kind)if(f.addr.filePath===l.path){let c=`${a.qualifiedName}${f.addr.qualifiedName}`,d=m.get(c);if(d)d.lines.push(b.line);else{let d={from:a.qualifiedName,to:f.addr.qualifiedName,lines:[b.line]};m.set(c,d),l.intraCalls.push(d)}}else{let c=`${a.qualifiedName}${f.addr.filePath}${f.addr.qualifiedName}`,d=n.get(c);if(d)d.lines.push(b.line);else{let d={from:a.qualifiedName,to:{filePath:f.addr.filePath,qualifiedName:f.addr.qualifiedName},lines:[b.line]};n.set(c,d),l.outgoingCalls.push(d)}}else if("external"===f.kind){let c=`${a.qualifiedName}${f.packageSpec}${f.name}`,d=p.get(c);if(d)d.lines.push(b.line);else{let d={from:a.qualifiedName,packageSpec:f.packageSpec,importedName:f.name,lines:[b.line]};p.set(c,d),l.externalCalls.push(d)}}else if("method-unresolved"===f.kind){let c=l.bindingsByLocalName.get(f.receiverName),d=c?l.resolvedImports.get(c.specifier)??"":"",e=`${a.qualifiedName}${f.receiverName}${f.methodName}`,g=q.get(e);if(g)g.lines.push(b.line);else{let c={from:a.qualifiedName,receiverName:f.receiverName,methodName:f.methodName,receiverFilePath:d,lines:[b.line]};q.set(e,c),l.methodCalls.push(c)}}}}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}async function E(a,b,c){let d,f=c.files.get(b);if(!f)return C(a,b,c);try{d=(await e.promises.stat(g().join(a,b))).mtimeMs}catch{return!1}if(d===f.mtime)return!1;let h=await s(g().join(a,b),b);return!!h&&(await D(h,f,c),B(a),!0)}function F(a){return{filePath:a.filePath,qualifiedName:a.qualifiedName,name:a.name,kind:a.kind,startLine:a.startLine,endLine:a.endLine,params:a.params}}function G(a){let b=a.indexOf(">");return b>=0?a.slice(0,b):a}function H(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 I(a,b){let c=a.files.get(b);if(!c)return null;let d=c.flatSymbols.filter(a=>!a.qualifiedName.includes(">")).map(F).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=G(a.from),c=G(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=H(a.lines);let h=[],i=new Map;for(let b of c.outgoingCalls){let d=G(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,n._)(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:F(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=G(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,n._)(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:F(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=H(a.lines);for(let a of j)a.lines.sort((a,b)=>a-b),a.lines=H(a.lines);let l=[],m=new Map;for(let a of c.externalCalls){let b=G(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=H(a.lines);let o=[],p=new Map;for(let a of c.methodCalls){let b=G(a.from);if(!e.has(b))continue;let c=`${b}|${a.receiverName}|${a.methodName}`,d=p.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()};p.set(c,d),o.push(d)}}for(let a of o)a.lines.sort((a,b)=>a-b),a.lines=H(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)),o.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:o,upstreamCalls:j,downstreamCalls:h}}function J(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 K(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}function L(a,b,c,d={}){let e=b.trim();if(!e)return d.includeLiterals?{files:[],symbols:[],literals:[]}:{files:[],symbols:[]};let f=K(e),g=[];for(let b of a.files.values()){if(g.length>=c)break;K(b.path).includes(f)&&g.push({type:"file",label:function(a){let b=a.lastIndexOf("/");return b>=0?a.slice(b+1):a}(b.path),hint:b.path,target:{filePath:b.path}})}let h=[];for(let b of a.files.values()){let a=!1;if(!function a(b,c){for(let d of b)if(c(d)||a(d.children,c))return!0;return!1}(b.symbolsTree,d=>h.length>=c?(a=!0,!0):"unknown"!==d.kind&&(K(d.name).includes(f)&&h.push({type:"symbol",label:d.name,hint:`${d.kind} \xb7 ${b.path}`,target:{filePath:b.path,qualifiedName:d.qualifiedName,name:d.name,kind:d.kind,startLine:d.startLine,endLine:d.endLine,...d.params?{params:d.params}:{}}}),!1)),a)break}if(!d.includeLiterals)return{files:g,symbols:h};let i=[];a:for(let b of a.files.values())for(let a of b.literals){if(i.length>=c)break a;K(a.value).includes(f)&&i.push({type:"literal",value:a.value,filePath:b.path,line:a.line,...a.enclosingQname?{enclosingSymbol:a.enclosingQname}:{}})}return{files:g,symbols:h,literals:i}}function M(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 N(a,b,c){let d=M(a,b,c);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:F(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:F(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=H(a.callLines);e.sort((a,b)=>a.caller.filePath.localeCompare(b.caller.filePath)||a.caller.qualifiedName.localeCompare(b.caller.qualifiedName));let g=F(d[0].symbolsByQname.get(b)),h=d.length>1?d.map(a=>a.path):void 0;return{qname:b,target:g,callers:e,ambiguousIn:h}}function O(a,b,c){let d=M(a,b,c);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:F(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:F(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=H(a.callLines);e.sort((a,b)=>a.callee.filePath.localeCompare(b.callee.filePath)||a.callee.qualifiedName.localeCompare(b.callee.qualifiedName));let g=F(d[0].symbolsByQname.get(b)),h=d.length>1?d.map(a=>a.path):void 0;return{qname:b,target:g,callees:e,ambiguousIn:h}}function P(a,b,c,d){let e=M(a,b,d);if(0===e.length)return{qname:b,target:null,nodes:[],truncated:!1};let f=Math.min(Math.max(c,1),5),g=F(e[0].symbolsByQname.get(b)),h=e.length>1?e.map(a=>a.path):void 0,i=e.map(a=>({filePath:a.path,qname:b})),j=new Set(i.map(a=>`${a.filePath}|${a.qname}`)),k=i.map(b=>{let c=a.files.get(b.filePath).symbolsByQname.get(b.qname);return{symbol:F(c),depth:0}}),l=i.slice(),m=!1;for(let b=1;b<=f;b++){let c=[];for(let d of l){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(!j.has(g)&&(j.add(g),k.push({symbol:F(f),depth:b}),c.push({filePath:e.path,qname:a.from}),k.length>=500)){m=!0;break}}if(m)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(!j.has(h)&&(j.add(h),k.push({symbol:F(g),depth:b}),c.push({filePath:f.from.filePath,qname:f.from.qualifiedName}),k.length>=500)){m=!0;break}}if(m)break}}if(m||0===c.length)break;l=c}return k.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:k,truncated:m,ambiguousIn:h}}d()}catch(a){d(a)}})},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.ih)((a,b)=>{f.t.subscribe(a,a=>{a.some(a=>"file"===a.type||"git"===a.type)&&b()})}))}d()}catch(a){d(a)}})},83624:(a,b,c)=>{function d(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 e(a){return a.replace(/\s+/g," ").trim()}function f(a,b){return a?`${a}>${b}`:b}function g(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 h(a,b,c,g,i=[],j){return{qualifiedName:f(g,b),name:b,kind:c,startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,contentHash:d(e(a.text)),children:i,params:j}}function i(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}c.d(b,{Hs:()=>m,NZ:()=>e,YN:()=>n,_B:()=>l,mG:()=>k,qj:()=>d});let j={theorem:"function",def:"function",abbrev:"function",example:"function",instance:"const",structure:"class",inductive:"type",axiom:"const",opaque:"const",constant:"const"};function k(a,b){let c=new Map;for(let b=0;b<a.namedChildCount;b++){let d=a.namedChild(b);d&&d.type.endsWith("comment")&&c.set(d.endPosition.row+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 l(a,b){let c=a.text.split("\n"),f=c.length;if(0===f)return[];let g=new Uint8Array(f+2);for(let a of b){let b=Math.max(1,a.startLine),c=Math.min(f,a.endLine);for(let a=b;a<=c;a++)g[a]=1}let h=[],i=(a,b)=>{let f=!1;for(let d=a;d<=b;d++){let a=c[d-1];if(a&&a.trim().length>0){f=!0;break}}if(!f)return;let g=c.slice(a-1,b).join("\n");h.push({qualifiedName:`__code_${a}_${b}__`,name:"code",kind:"unknown",startLine:a,endLine:b,contentHash:d(e(g)),children:[]})},j=-1;for(let a=1;a<=f;a++)g[a]?j>=0&&(i(j,a-1),j=-1):j<0&&(j=a);return j>=0&&i(j,f),h}function m(a,b){let c=[],m=function(a){let b=[],c=-1,f=-1;for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(e){if("import_statement"===e.type||"export_statement"===e.type&&null!==e.childForFieldName("source")||"import_from_statement"===e.type||"future_import_statement"===e.type||"import"===e.type)b.push(e),c<0&&(c=e.startPosition.row+1),f=e.endPosition.row+1;else if(c>=0)break}}return c<0?null:{qualifiedName:"__imports__",name:"imports",kind:"unknown",startLine:c,endLine:f,contentHash:d(e(b.map(a=>a.text).join("\n"))),children:[]}}(a);if(m&&c.push(m),"lean"===b)c.push(...function(a){let b=[],c=[];for(let f=0;f<a.namedChildCount;f++){let g=a.namedChild(f);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 j){h=b;break}}else g.type in j&&(h=g);if(!h)continue;let i=h.childForFieldName("name")?.text??h.type,k=c.filter(a=>null!==a);b.push({qualifiedName:[...k,i].join("."),name:i,kind:j[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),contentHash:d(e(g.text)),children:[]})}return b}(a));else for(let b=0;b<a.namedChildCount;b++){let j=a.namedChild(b);j&&c.push(...function a(b,c,j=!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[h(b,g(b),"function",c,[],i(b))];case"class_declaration":case"abstract_class_declaration":{let a=g(b),d=f(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(h(e,g(e),"method",b,[],i(e)));else if("public_field_definition"===e.type){let a=e.childForFieldName("value");a&&("arrow_function"===a.type||"function_expression"===a.type)&&c.push(h(e,g(e),"method",b,[],i(a)))}}}return c}(b.childForFieldName("body"),d);return[h(b,a,"class",c,e)]}case"interface_declaration":return[h(b,g(b),"interface",c)];case"type_alias_declaration":return[h(b,g(b),"type",c)];case"enum_declaration":return[h(b,g(b),"enum",c)];case"lexical_declaration":case"variable_declaration":return function(a,b){let c=[];for(let d=0;d<a.namedChildCount;d++){let e=a.namedChild(d);if(!e||"variable_declarator"!==e.type)continue;let f=e.childForFieldName("name"),j=e.childForFieldName("value");if(!f)continue;let k=f.text,l=j&&("arrow_function"===j.type||"function_expression"===j.type),m=l&&j?i(j):void 0;if(c.push(h(a,k,l?"function":"const",b,[],m)),j&&"object"===j.type&&!l){let a=b?`${b}>${k}`:k;for(let b=0;b<j.namedChildCount;b++){let d=j.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(h(d,b.text,"method",a,[],i(e)))}else if("method_definition"===d.type){let b=g(d);b&&c.push(h(d,b,"method",a,[],i(d)))}}}}}return c}(b,c);case"class_definition":{let a=g(b),j=f(c,a),k=function a(b,c){if(!b)return[];let j=[];for(let k=0;k<b.namedChildCount;k++){let l=b.namedChild(k);if(l){if("function_definition"===l.type)j.push(h(l,g(l),"method",c,[],i(l)));else if("decorated_definition"===l.type){let b=l.childForFieldName("definition");if(b?.type==="function_definition")j.push({...h(b,g(b),"method",c,[],i(b)),startLine:l.startPosition.row+1,contentHash:d(e(l.text))});else if(b?.type==="class_definition"){let i=g(b),k=f(c,i),m=a(b.childForFieldName("body"),k);j.push({...h(b,i,"class",c,m),startLine:l.startPosition.row+1,contentHash:d(e(l.text))})}}else if("class_definition"===l.type){let b=g(l),d=f(c,b),e=a(l.childForFieldName("body"),d);j.push(h(l,b,"class",c,e))}}}return j}(b.childForFieldName("body"),j);return[h(b,a,"class",c,k)]}case"decorated_definition":{let f=b.childForFieldName("definition");if(!f)return[];return a(f,c,!1).map(a=>({...a,startLine:b.startPosition.row+1,contentHash:d(e(b.text))}))}case"expression_statement":{let a=[];for(let g=0;g<b.namedChildCount;g++){let h=b.namedChild(g);if(h?.type==="assignment"){let g=function(a,b,c){let g=b.childForFieldName("left");if(!g||"identifier"!==g.type)return null;let h=g.text;return{qualifiedName:f(c,h),name:h,kind:"const",startLine:a.startPosition.row+1,endLine:a.endPosition.row+1,contentHash:d(e(a.text)),children:[]}}(b,h,c);g&&a.push(g)}}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 j=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=j?`${j} ${f}`:f;return g.map((a,c)=>h(a,g.length>1?`${k} #${c+1}`:k,"function",b,[],i(a)))}(b,c)),a}default:return[]}}(j,void 0,!1))}return k(a,c),c.push(...l(a,c)),n(c),c}function n(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)}},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:()=>l});var d=c(29021),e=c(33873),f=c(7939);let g=[".git/HEAD",".git/MERGE_HEAD",".git/REBASE_HEAD"],h=[".git/refs"];class i{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))},f=()=>{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&&f()},2e3))}),b.watchers.push(e)}catch(b){console.error(`Failed to watch ${a}:`,b)}};f();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 g){let b=a.replace(".git/","");j((0,e.join)(i,b))}for(let a of h){let f=a.replace(".git/","");try{let a=(0,d.watch)((0,e.join)(i,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}}class j{subscribe(a){return this.listeners.add(a),this.watcher||this.start(),()=>{this.listeners.delete(a),0===this.listeners.size&&this.stop()}}start(){try{(0,d.existsSync)(f.Tb)||(0,d.mkdirSync)(f.Tb,{recursive:!0}),(0,d.existsSync)(f.jp)||(0,d.writeFileSync)(f.jp,"0"),this.watcher=(0,d.watch)(f.jp,()=>{this.debounceTimer&&clearTimeout(this.debounceTimer),this.debounceTimer=setTimeout(()=>this.notify(),300)}),this.watcher.on("error",()=>{this.stop(),setTimeout(()=>{this.listeners.size>0&&this.start()},2e3)})}catch{}}stop(){if(this.watcher){try{this.watcher.close()}catch{}this.watcher=null}this.debounceTimer&&(clearTimeout(this.debounceTimer),this.debounceTimer=null)}notify(){for(let a of this.listeners)try{a()}catch(a){console.error("ReviewWatcher callback error:",a)}}constructor(){this.listeners=new Set,this.watcher=null,this.debounceTimer=null}}let k=globalThis,l=k.__cockpitFileWatcher??(k.__cockpitFileWatcher=new i);k.__cockpitReviewWatcher??(k.__cockpitReviewWatcher=new j)},91939:(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);function h(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 i(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):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 j(a){return a.length>=2&&('"'===a[0]||"'"===a[0])&&a[a.length-1]===a[0]?a.slice(1,-1):a}function k(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 l={typescript:k,tsx:k,javascript:k,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 m(a,b){let c=l[b];return c?c(a):[]}var n=c(25344);function o(a){return"function"===a||"class"===a||"method"===a}function p(a,b){return{grammarId:a,extensions:b,extractSymbols:(a,b)=>(0,g.Hs)(a),extractImports:b=>({specs:m(b,a),bindings:[...i(b),...function(a){let b=[];for(let c=0;c<a.namedChildCount;c++){let d=a.namedChild(c);if(!d||"export_statement"!==d.type)continue;let e=d.childForFieldName("source");if(!e)continue;let f=j(e.text),g=null;for(let a=0;a<d.namedChildCount;a++){let b=d.namedChild(a);if(b?.type==="export_clause"){g=b;break}}if(g)for(let a=0;a<g.namedChildCount;a++){let c=g.namedChild(a);if(!c||"export_specifier"!==c.type)continue;let d=c.childForFieldName("name"),e=c.childForFieldName("alias");if(!d)continue;let h=d.text,i=e?.text??h;b.push({localName:i,specifier:f,importedName:h,isReexport:!0})}}return b}(b)]}),extractCallSites:(a,b)=>h(a),async buildProjectContext(a,b){let c=new Set(b),d=await (0,n.ZT)(a),e=await (0,n.zC)(a,c),f=[...e.keys()].sort((a,b)=>b.length-a.length);return{cwd:a,tsconfigs:d,workspaces:e,sortedWsNames:f,owningScopesCache:new Map}},resolveSpecifier(a,b,c,d){let e=c.owningScopesCache.get(b);if(e||(e=c.tsconfigs.filter(a=>(0,n._0)(b,a.scope)),c.owningScopesCache.set(b,e)),a.startsWith("./")||a.startsWith("../"))return(0,n.KP)(f().resolve(c.cwd,f().dirname(b),a),c.cwd,d);if(a.startsWith("/"))return(0,n.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,n.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,n.IS)(f().posix.join(e.dir,g),d)??(0,n.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||f.has(b.path))return null;if(f.add(b.path),"*"!==c){let a=`${c}>${d}`,e=b.symbolsByQname.get(a);if(e&&o(e.kind))return e}if("*"===c){let a=b.symbolsByName.get(d);if(a){let b=null;for(let c of a)!c.qualifiedName.includes(">")&&o(c.kind)&&(!b||c.endLine-c.startLine>b.endLine-b.startLine)&&(b=c);if(b)return b}}let h=b.reexportsByLocalName.get(c);if(h){let c=b.resolvedImports.get(h.specifier);if(c){let b=g.get(c);if(b){let c=a(b,h.importedName,d,e+1,f,g);if(c)return c}}}return 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&&o(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,c,d,e,f){if(d>5||e.has(b.path))return null;e.add(b.path);let g=b.symbolsByName.get(c);if(g){let a=null;for(let b of g)o(b.kind)&&(!a||b.endLine-b.startLine>a.endLine-a.startLine)&&(a=b);if(a)return a}let h=b.reexportsByLocalName.get(c);if(h){let c=b.resolvedImports.get(h.specifier);if(c){let b=f.get(c);if(b){let c=a(b,h.importedName,d+1,e,f);if(c)return c}}}return null}(i,g.importedName,0,new Set,d);return j?[{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){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 v=c(73024);function w(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,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function x(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 y(a){try{let b=await v.promises.readFile(f().join(a,"go.mod"),"utf8"),c=/^\s*module\s+(\S+)/m.exec(b);return c?c[1].trim():null}catch{return null}}function z(a){return"function"===a||"class"===a||"method"===a}function A(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,contentHash:(0,g.qj)((0,g.NZ)(a.text)),children:e,params:f}}function B(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 C(a,b){let c=new Map,d=new Map,e=new Set;async function g(h,i){let j;if(e.has(i))return;e.add(i),c.set(h,i),d.set(i,h);try{j=await v.promises.readFile(f().join(a,i),"utf8")}catch{return}let k=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}(j);if(0===k.length)return;let l=f().dirname(i),m=f().basename(i,".rs"),n="mod"===m||"lib"===m||"main"===m?[l]:[l,f().join(l,m)];for(let a of k){let c=`${h}::${a}`,d=null;for(let c of n){for(let e of[f().join(c,`${a}.rs`),f().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 g(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 g("crate",a);else if(a.startsWith("src/bin/"))await g("crate",a);else{let b=a.split("/"),c=b.indexOf("src");if(c>0){let d=b[c-1];await g(d,a)}}return{modTree:c,fileToMod:d}}function D(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:m(a,"python"),bindings:i(a)}),extractCallSites:(a,b)=>h(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 u(h||".",g,d)}for(let b of c.pythonRoots){let e=u(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&&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}(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&&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 j=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 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,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(w(e,a.text,"function",void 0,[],x(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=w(e,a.text,"method",d??void 0,[],x(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(w(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(w(e,f.text,"const",b))}else"identifier"===a.type&&c.push(w(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){let c=await y(a);return{cwd:a,modulePath:c,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(">")&&z(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&&z(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(">"))&&z(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,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(A(e,a.text,"function",void 0,[],B(e)));break}case"struct_item":case"union_item":{let a=e.childForFieldName("name");if(!a)break;b.push(A(e,a.text,"class",void 0));break}case"enum_item":{let a=e.childForFieldName("name");if(!a)break;b.push(A(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(A(e,a.text,"method",b,[],B(e)))}}return d}(e,a.text);b.push(A(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(A(e,a.text,"method",b,[],B(e)))}else if("function_signature_item"===e.type){let a=e.childForFieldName("name");if(!a)continue;d.push(A(e,a.text,"method",b,[],B(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(A(e,a.text,"const",void 0));break}case"type_item":{let a=e.childForFieldName("name");if(!a)break;b.push(A(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(A(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){let{modTree:c,fileToMod:d}=await C(a,b);return{cwd:a,modTree:c,fileToMod:d}},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(">")&&D(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&&D(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(">"))&&D(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(">")&&D(a.kind)){f=a;break}}return f?[{kind:"symbol",addr:{filePath:f.filePath,qualifiedName:f.qualifiedName}}]:[]},moduleForFile:(a,b)=>b?.fileToMod.get(a)??f().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,".")})}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";exports.id=516,exports.ids=[516],exports.modules={40516:(a,b,c)=>{c.d(b,{$G:()=>T,$H:()=>h,BZ:()=>U,Bn:()=>o,C4:()=>e,Dn:()=>g,F3:()=>M,Hq:()=>X,JD:()=>k,L8:()=>ab,RA:()=>d,TB:()=>v,U6:()=>t,Uk:()=>p,VW:()=>G,Y8:()=>q,YU:()=>u,Zj:()=>N,dR:()=>K,dr:()=>Z,g$:()=>j,hO:()=>R,iN:()=>H,jB:()=>i,nE:()=>Y,nq:()=>V,o4:()=>P,p7:()=>W,q4:()=>J,qW:()=>r,tq:()=>S,uz:()=>s,wL:()=>f,yM:()=>n});let d="[Image]",e={bash:"Bash",applyPatch:"ApplyPatch",read:"Read",task:"Task",todo:"TodoWrite",webSearch:"WebSearch",webFetch:"WebFetch"},f="mcp__",g=(a,b)=>`${f}${a}__${b}`,h="spawn_agent",i="wait_agent",j=new Set([h,i,"close_agent","send_input","resume_agent","list_agents"]),k="agent_message",l="update_plan",m="view_image",n="apply_patch",o="exec",p=new Set([n,o]);function q(a,b){return b?.startsWith(f)?`${b}__${a}`:"shell_command"===a||"exec_command"===a?e.bash:"apply_patch"===a?e.applyPatch:a===h?e.task:a===l?e.todo:a===m?e.read:a}function r(a){return{todos:(a??[]).flatMap(a=>"string"==typeof a?.text?[{content:a.text,status:a.completed?"completed":"pending"}]:[])}}function s(a){let b=a.filter(a=>"completed"===a.status).length;return`${b}/${a.length} completed`}function t(a,b){if(b?.type==="open_page"&&b.url)return{name:e.webFetch,input:{url:b.url},result:b.url};let c=b?.query||a||"",d=b?.queries?.length?b.queries:c?[c]:[];return{name:e.webSearch,input:{query:c},result:d.join("\n")}}function u(a){return a.error?.message?a.error.message:null===a.result||void 0===a.result?"":"string"==typeof a.result?a.result:JSON.stringify(a.result,null,2)}function v(a){let b,c=[],d=/^\*\*\* (Add|Update|Delete) File: (.+)$/gm;for(;b=d.exec(a);)c.push({path:b[2].trim(),kind:b[1].toLowerCase()});return{changes:c}}let w=/"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|`(?:\\.|[^`\\])*`/g,x={n:"\n",r:"\r",t:" ",b:"\b",f:"\f",v:"\v",0:"\0"};function y(a){if(a.startsWith('"'))try{return JSON.parse(a)}catch{}return a.slice(1,-1).replace(/\\(u\{[0-9a-fA-F]+\}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{2}|[\s\S])/g,(a,b)=>b.startsWith("u{")?String.fromCodePoint(parseInt(b.slice(2,-1),16)):b.startsWith("u")||b.startsWith("x")?String.fromCharCode(parseInt(b.slice(1),16)):x[b]??b)}let z=/^[A-Za-z_$][A-Za-z0-9_$]*/,A=/^(-?\d[\d_]*(?:\.\d*)?(?:[eE][+-]?\d+)?|true|false|null|undefined)/,B=a=>{for(;a.i<a.s.length&&/\s/.test(a.s[a.i]);)a.i++};function C(a){let b=a.s[a.i];if('"'!==b&&"'"!==b&&"`"!==b)return null;let c=a.i;for(a.i++;a.i<a.s.length;){let d=a.s[a.i];if("\\"===d){a.i+=2;continue}if(d===b)return a.i++,y(a.s.slice(c,a.i));a.i++}return null}function D(a){if("{"!==a.s[a.i])return null;a.i++;let b={};for(;;){if(B(a),"}"===a.s[a.i])return a.i++,{v:b};if(a.i>=a.s.length)return null;let c=null,d=a.s[a.i];if('"'===d||"'"===d||"`"===d)c=C(a);else{let b=z.exec(a.s.slice(a.i));b&&(c=b[0],a.i+=b[0].length)}if(null===c||(B(a),":"!==a.s[a.i]))return null;a.i++;let e=function a(b){B(b);let c=b.s[b.i];if(void 0===c)return null;if('"'===c||"'"===c||"`"===c){let a=C(b);return null===a?null:{v:a}}if("{"===c)return D(b);if("["===c){var d=b;if("["!==d.s[d.i])return null;d.i++;let c=[];for(;;){if(B(d),"]"===d.s[d.i])return d.i++,{v:c};if(d.i>=d.s.length)return null;let b=a(d);if(!b)return null;if(c.push(b.v),B(d),","===d.s[d.i]){d.i++;continue}if("]"===d.s[d.i])return d.i++,{v:c};return null}return}let e=A.exec(b.s.slice(b.i));if(!e)return null;b.i+=e[0].length;let f=e[0];if("true"===f)return{v:!0};if("false"===f)return{v:!1};if("null"===f||"undefined"===f)return{v:null};let g=Number(f.replace(/_/g,""));return Number.isNaN(g)?null:{v:g}}(a);if(!e)return null;if(b[c]=e.v,B(a),","===a.s[a.i]){a.i++;continue}if("}"===a.s[a.i])return a.i++,{v:b};return null}}function E(a,b){let c=a.indexOf("{",b);if(-1===c)return null;let d=D({s:a,i:c});return d&&d.v&&"object"==typeof d.v?d.v:null}let F=/tools\.([A-Za-z_$][A-Za-z0-9_$]*)\s*\(/g;function G(a){let b,c=function(a){let b;for(w.lastIndex=0;b=w.exec(a);){let a=y(b[0]);if(a.includes("*** Begin Patch"))return a}return null}(a);if(c)return{kind:"patch",patch:c};let d=-1===(b=a.indexOf("tools.exec_command("))?null:E(a,b);if(d)return{kind:"exec",command:"string"==typeof d.cmd?d.cmd:"",args:d};let e=function(a){let b;for(F.lastIndex=0;b=F.exec(a);){let c=b[1];if("exec_command"===c||"apply_patch"===c)continue;let d=E(a,b.index);if(d)return{tool:c,args:d}}return null}(a);return e?{kind:"other",tool:e.tool,args:e.args}:{kind:"unknown"}}function H(a){let b=G(a);return"patch"===b.kind?{name:e.applyPatch,input:v(b.patch)}:"exec"===b.kind?{name:e.bash,input:Z("exec_command",b.args)}:"other"===b.kind?{name:q(b.tool),input:Z(b.tool,b.args)}:{name:e.bash,input:{command:a}}}function I(a){let b=JSON.stringify(a)??"";return b.length<=4e3?b:`${b.slice(0,4e3)}… (${b.length} chars truncated)`}function J(a){if(null==a)return"";if("string"==typeof a)return a;if(Array.isArray(a))return a.map(J).join("");if("object"==typeof a){let b=a.text;return"string"==typeof b?b:!function(a){let{type:b,image_url:c}=a;return"string"==typeof c||"input_image"===b||"output_image"===b}(a)?I(a):d}return String(a)}function K(a){if(!a||"token_count"!==a.type)return null;let b=a.info;if(!b||"object"!=typeof b)return null;let c=b.last_token_usage;if(!c||"object"!=typeof c)return null;let d=a=>"number"==typeof c[a]?c[a]:void 0,e={...void 0!==d("input_tokens")?{input_tokens:d("input_tokens")}:{},...void 0!==d("output_tokens")?{output_tokens:d("output_tokens")}:{},...void 0!==d("cached_input_tokens")?{cache_read_input_tokens:d("cached_input_tokens")}:{},...void 0!==d("cache_write_input_tokens")?{cache_creation_input_tokens:d("cache_write_input_tokens")}:{}};return Object.keys(e).length>0?e:null}let L=new Set(["function_call","function_call_output","custom_tool_call","custom_tool_call_output"]);function M(a){if(!a||"string"!=typeof a.type||L.has(a.type))return null;let b="string"==typeof a.call_id?a.call_id:"";return b?{callId:b,name:"string"==typeof a.name&&a.name?a.name:a.type,input:function(a){let b=a.arguments;if(b&&"object"==typeof b&&!Array.isArray(b))return b;if("string"==typeof b&&b.trim()){try{let a=JSON.parse(b);if(a&&"object"==typeof a&&!Array.isArray(a))return a}catch{}return{arguments:b}}return"string"==typeof a.input&&a.input?{input:a.input}:{}}(a)}:null}function N(a){if(void 0!==a.output)return J(a.output);let{type:b,id:c,call_id:d,...e}=a;return Object.keys(e).length>0?I(e):""}let O=new Set(["completed","errored","interrupted","not_found","failed"]);function P(a,b){let c="string"==typeof a.message?a.message:"",d=Q.test(c.trim()),e=d?"":c,f="string"==typeof a.agent_type?a.agent_type:"string"==typeof a.task_name?R(a.task_name):void 0;return{...f?{subagent_type:f}:{},description:U(b?.nickname,f,e),...d?{message_encrypted:!0}:{prompt:e},...b?.agentId?{agent_id:b.agentId}:{}}}let Q=/^gAAAAA[A-Za-z0-9_-]{32,}={0,2}$/;function R(a){let b=a.split("/").filter(Boolean);return b[b.length-1]||a}function S(a){if(!a)return null;let b=a.item,c="sub_agent_activity"===a.type?{...a,callId:a.event_id}:b&&"SubAgentActivity"===b.type?{...b,callId:b.id}:null;if(!c)return null;let{callId:d,agent_thread_id:e}=c;return"string"==typeof d&&d&&"string"==typeof e&&e?{callId:d,agentThreadId:e,..."string"==typeof c.agent_path?{agentPath:c.agent_path}:{},..."string"==typeof c.kind?{kind:c.kind}:{}}:null}function T(a){if(!a||a.type!==k)return null;let b="string"==typeof a.author?a.author:"";if(!b)return null;let c=Array.isArray(a.content)?a.content.map(a=>"string"==typeof a?.text?a.text:"").join(""):"string"==typeof a.content?a.content:"",d=c.match(/^Message Type:\s*(\S+)/m)?.[1],e=c.match(/^Payload:[ \t]*$/m),f=c;if(e?.index!==void 0){let a=c.indexOf("\n",e.index);-1!==a&&(f=c.slice(a+1))}return{author:b,..."string"==typeof a.recipient?{recipient:a.recipient}:{},text:f.trim()||c.trim(),final:!d||"FINAL_ANSWER"===d}}function U(a,b,c){if(a)return b?`${a} (${b})`:a;let d=c.split("\n",1)[0]?.trim()||"";return d?d.slice(0,80):b||"subagent"}function V(a){try{let b=JSON.parse(a);if("string"!=typeof b?.agent_id||!b.agent_id)return null;return{agentId:b.agent_id,..."string"==typeof b.nickname?{nickname:b.nickname}:{}}}catch{return null}}function W(a){let b;try{b=JSON.parse(a)}catch{return[]}let c=b?.status;if(!c||"object"!=typeof c)return[];let d=[];for(let[a,b]of Object.entries(c)){if(!b||"object"!=typeof b)continue;let[c,e]=Object.entries(b)[0]??[];c&&d.push({agentId:a,status:c,message:"string"==typeof e?e:"",done:O.has(c)})}return d}function X(a){return a&&"object"==typeof a?Object.entries(a).flatMap(([a,b])=>{let c="string"==typeof b?.status?b.status:"";return c?[{agentId:a,status:c,message:"string"==typeof b?.message?b.message:"",done:O.has(c)}]:[]}):[]}function Y(a){return a.message||`(agent ${a.status})`}function Z(a,b){if(a===h)return P(b);if(a===l)return{todos:(Array.isArray(b.plan)?b.plan:[]).flatMap(a=>"string"!=typeof a?.step?[]:[{content:a.step,status:"string"==typeof a.status?a.status:"pending"}])};if(a===m&&"string"==typeof b.path){let{path:a,...c}=b;return{...c,file_path:b.path}}if(q(a)!==e.bash||"string"==typeof b.command||"string"!=typeof b.cmd)return b;let{cmd:c,...d}=b;return{...d,command:b.cmd}}let $=/^<image\b[^>]*>$/i,_=/<\/?image\b[^>]*>/gi,aa=/^data:(image\/(?:png|jpeg|webp|gif));base64,([\s\S]*)$/;function ab(a){return{text:(a?.filter(a=>"input_text"===a.type&&a.text&&!$.test(a.text.trim())).map(a=>a.text).join("")||"").replace(_,""),images:a?.filter(a=>"input_image"===a.type&&a.image_url).map(a=>{let b;return(b=a.image_url.match(aa))?{type:"base64",media_type:b[1],data:b[2]}:null}).filter(a=>null!==a)||[]}}}};
|
|
1
|
+
"use strict";exports.id=516,exports.ids=[516],exports.modules={40516:(a,b,c)=>{c.d(b,{$G:()=>O,$H:()=>h,BZ:()=>P,Bn:()=>m,C4:()=>e,F3:()=>H,Hq:()=>S,JD:()=>j,L8:()=>Y,RA:()=>d,U6:()=>p,Uk:()=>n,VW:()=>B,Y8:()=>o,Zj:()=>I,dR:()=>F,dr:()=>U,hO:()=>M,iN:()=>C,jB:()=>i,nE:()=>T,nq:()=>Q,o4:()=>K,p7:()=>R,q4:()=>E,tq:()=>N,zB:()=>$});let d="[Image]",e={bash:"Bash",applyPatch:"ApplyPatch",read:"Read",task:"Task",todo:"TodoWrite",webSearch:"WebSearch",webFetch:"WebFetch",imageGeneration:"Write"},f="mcp__",g=(a,b)=>`${f}${a}__${b}`,h="spawn_agent",i="wait_agent",j="agent_message",k="update_plan",l="view_image",m="exec",n=new Set(["apply_patch",m]);function o(a,b){return b?.startsWith(f)?`${b}__${a}`:"shell_command"===a||"exec_command"===a?e.bash:"apply_patch"===a?e.applyPatch:a===h?e.task:a===k?e.todo:a===l?e.read:a}function p(a,b){if(b?.type==="open_page"&&b.url)return{name:e.webFetch,input:{url:b.url},result:b.url};let c=b?.query||a||"",d=b?.queries?.length?b.queries:c?[c]:[];return{name:e.webSearch,input:{query:c},result:d.join("\n")}}function q(a){if(a.error?.message)return a.error.message;if(null===a.result||void 0===a.result)return"";if("string"==typeof a.result)return a.result;let b=a.result.content;if(Array.isArray(b)){let a=b.filter(a=>!!a&&"object"==typeof a).filter(a=>"string"==typeof a.text).map(a=>a.text).join("");if(a)return a}return JSON.stringify(a.result,null,2)}let r=/"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|`(?:\\.|[^`\\])*`/g,s={n:"\n",r:"\r",t:" ",b:"\b",f:"\f",v:"\v",0:"\0"};function t(a){if(a.startsWith('"'))try{return JSON.parse(a)}catch{}return a.slice(1,-1).replace(/\\(u\{[0-9a-fA-F]+\}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{2}|[\s\S])/g,(a,b)=>b.startsWith("u{")?String.fromCodePoint(parseInt(b.slice(2,-1),16)):b.startsWith("u")||b.startsWith("x")?String.fromCharCode(parseInt(b.slice(1),16)):s[b]??b)}let u=/^[A-Za-z_$][A-Za-z0-9_$]*/,v=/^(-?\d[\d_]*(?:\.\d*)?(?:[eE][+-]?\d+)?|true|false|null|undefined)/,w=a=>{for(;a.i<a.s.length&&/\s/.test(a.s[a.i]);)a.i++};function x(a){let b=a.s[a.i];if('"'!==b&&"'"!==b&&"`"!==b)return null;let c=a.i;for(a.i++;a.i<a.s.length;){let d=a.s[a.i];if("\\"===d){a.i+=2;continue}if(d===b)return a.i++,t(a.s.slice(c,a.i));a.i++}return null}function y(a){if("{"!==a.s[a.i])return null;a.i++;let b={};for(;;){if(w(a),"}"===a.s[a.i])return a.i++,{v:b};if(a.i>=a.s.length)return null;let c=null,d=a.s[a.i];if('"'===d||"'"===d||"`"===d)c=x(a);else{let b=u.exec(a.s.slice(a.i));b&&(c=b[0],a.i+=b[0].length)}if(null===c||(w(a),":"!==a.s[a.i]))return null;a.i++;let e=function a(b){w(b);let c=b.s[b.i];if(void 0===c)return null;if('"'===c||"'"===c||"`"===c){let a=x(b);return null===a?null:{v:a}}if("{"===c)return y(b);if("["===c){var d=b;if("["!==d.s[d.i])return null;d.i++;let c=[];for(;;){if(w(d),"]"===d.s[d.i])return d.i++,{v:c};if(d.i>=d.s.length)return null;let b=a(d);if(!b)return null;if(c.push(b.v),w(d),","===d.s[d.i]){d.i++;continue}if("]"===d.s[d.i])return d.i++,{v:c};return null}return}let e=v.exec(b.s.slice(b.i));if(!e)return null;b.i+=e[0].length;let f=e[0];if("true"===f)return{v:!0};if("false"===f)return{v:!1};if("null"===f||"undefined"===f)return{v:null};let g=Number(f.replace(/_/g,""));return Number.isNaN(g)?null:{v:g}}(a);if(!e)return null;if(b[c]=e.v,w(a),","===a.s[a.i]){a.i++;continue}if("}"===a.s[a.i])return a.i++,{v:b};return null}}function z(a,b){let c=a.indexOf("{",b);if(-1===c)return null;let d=y({s:a,i:c});return d&&d.v&&"object"==typeof d.v?d.v:null}let A=/tools\.([A-Za-z_$][A-Za-z0-9_$]*)\s*\(/g;function B(a){let b,c=function(a){let b;for(r.lastIndex=0;b=r.exec(a);){let a=t(b[0]);if(a.includes("*** Begin Patch"))return a}return null}(a);if(c)return{kind:"patch",patch:c};let d=-1===(b=a.indexOf("tools.exec_command("))?null:z(a,b);if(d)return{kind:"exec",command:"string"==typeof d.cmd?d.cmd:"",args:d};let e=function(a){let b;for(A.lastIndex=0;b=A.exec(a);){let c=b[1];if("exec_command"===c||"apply_patch"===c)continue;let d=z(a,b.index);if(d)return{tool:c,args:d}}return null}(a);return e?{kind:"other",tool:e.tool,args:e.args}:{kind:"unknown"}}function C(a){let b=B(a);return"patch"===b.kind?{name:e.applyPatch,input:function(a){let b,c=[],d=/^\*\*\* (Add|Update|Delete) File: (.+)$/gm;for(;b=d.exec(a);)c.push({path:b[2].trim(),kind:b[1].toLowerCase()});return{changes:c}}(b.patch)}:"exec"===b.kind?{name:e.bash,input:U("exec_command",b.args)}:"other"===b.kind?{name:o(b.tool),input:U(b.tool,b.args)}:{name:e.bash,input:{command:a}}}function D(a){let b=JSON.stringify(a)??"";return b.length<=4e3?b:`${b.slice(0,4e3)}… (${b.length} chars truncated)`}function E(a){if(null==a)return"";if("string"==typeof a)return a;if(Array.isArray(a))return a.map(E).join("");if("object"==typeof a){let b=a.text;return"string"==typeof b?b:!function(a){let{type:b,image_url:c}=a;return"string"==typeof c||"input_image"===b||"output_image"===b}(a)?D(a):d}return String(a)}function F(a){if(!a||"token_count"!==a.type)return null;let b=a.info;if(!b||"object"!=typeof b)return null;let c=b.last_token_usage;if(!c||"object"!=typeof c)return null;let d=a=>"number"==typeof c[a]?c[a]:void 0,e={...void 0!==d("input_tokens")?{input_tokens:d("input_tokens")}:{},...void 0!==d("output_tokens")?{output_tokens:d("output_tokens")}:{},...void 0!==d("cached_input_tokens")?{cache_read_input_tokens:d("cached_input_tokens")}:{},...void 0!==d("cache_write_input_tokens")?{cache_creation_input_tokens:d("cache_write_input_tokens")}:{}};return Object.keys(e).length>0?e:null}let G=new Set(["function_call","function_call_output","custom_tool_call","custom_tool_call_output"]);function H(a){if(!a||"string"!=typeof a.type||G.has(a.type))return null;let b="string"==typeof a.call_id?a.call_id:"";return b?{callId:b,name:"string"==typeof a.name&&a.name?a.name:a.type,input:function(a){let b=a.arguments;if(b&&"object"==typeof b&&!Array.isArray(b))return b;if("string"==typeof b&&b.trim()){try{let a=JSON.parse(b);if(a&&"object"==typeof a&&!Array.isArray(a))return a}catch{}return{arguments:b}}return"string"==typeof a.input&&a.input?{input:a.input}:{}}(a)}:null}function I(a){if(void 0!==a.output)return E(a.output);let{type:b,id:c,call_id:d,...e}=a;return Object.keys(e).length>0?D(e):""}let J=new Set(["completed","errored","interrupted","not_found","failed"]);function K(a,b){let c="string"==typeof a.message?a.message:"",d=L.test(c.trim()),e=d?"":c,f="string"==typeof a.agent_type?a.agent_type:"string"==typeof a.task_name?M(a.task_name):void 0;return{...f?{subagent_type:f}:{},description:P(b?.nickname,f,e),...d?{message_encrypted:!0}:{prompt:e},...b?.agentId?{agent_id:b.agentId}:{}}}let L=/^gAAAAA[A-Za-z0-9_-]{32,}={0,2}$/;function M(a){let b=a.split("/").filter(Boolean);return b[b.length-1]||a}function N(a){if(!a)return null;let b=a.item,c="sub_agent_activity"===a.type?{...a,callId:a.event_id}:b&&"SubAgentActivity"===b.type?{...b,callId:b.id}:null;if(!c)return null;let{callId:d,agent_thread_id:e}=c;return"string"==typeof d&&d&&"string"==typeof e&&e?{callId:d,agentThreadId:e,..."string"==typeof c.agent_path?{agentPath:c.agent_path}:{},..."string"==typeof c.kind?{kind:c.kind}:{}}:null}function O(a){if(!a||a.type!==j)return null;let b="string"==typeof a.author?a.author:"";if(!b)return null;let c=Array.isArray(a.content)?a.content.map(a=>"string"==typeof a?.text?a.text:"").join(""):"string"==typeof a.content?a.content:"",d=c.match(/^Message Type:\s*(\S+)/m)?.[1],e=c.match(/^Payload:[ \t]*$/m),f=c;if(e?.index!==void 0){let a=c.indexOf("\n",e.index);-1!==a&&(f=c.slice(a+1))}return{author:b,..."string"==typeof a.recipient?{recipient:a.recipient}:{},text:f.trim()||c.trim(),final:!d||"FINAL_ANSWER"===d}}function P(a,b,c){if(a)return b?`${a} (${b})`:a;let d=c.split("\n",1)[0]?.trim()||"";return d?d.slice(0,80):b||"subagent"}function Q(a){try{let b=JSON.parse(a);if("string"!=typeof b?.agent_id||!b.agent_id)return null;return{agentId:b.agent_id,..."string"==typeof b.nickname?{nickname:b.nickname}:{}}}catch{return null}}function R(a){let b;try{b=JSON.parse(a)}catch{return[]}let c=b?.status;if(!c||"object"!=typeof c)return[];let d=[];for(let[a,b]of Object.entries(c)){if(!b||"object"!=typeof b)continue;let[c,e]=Object.entries(b)[0]??[];c&&d.push({agentId:a,status:c,message:"string"==typeof e?e:"",done:J.has(c)})}return d}function S(a){return a&&"object"==typeof a?Object.entries(a).flatMap(([a,b])=>{let c="string"==typeof b?.status?b.status:"";return c?[{agentId:a,status:c,message:"string"==typeof b?.message?b.message:"",done:J.has(c)}]:[]}):[]}function T(a){return a.message||`(agent ${a.status})`}function U(a,b){if(a===h)return K(b);if(a===k)return{todos:(Array.isArray(b.plan)?b.plan:[]).flatMap(a=>"string"!=typeof a?.step?[]:[{content:a.step,status:"string"==typeof a.status?a.status:"pending"}])};if(a===l&&"string"==typeof b.path){let{path:a,...c}=b;return{...c,file_path:b.path}}if(o(a)!==e.bash||"string"==typeof b.command||"string"!=typeof b.cmd)return b;let{cmd:c,...d}=b;return{...d,command:b.cmd}}let V=/^<image\b[^>]*>$/i,W=/<\/?image\b[^>]*>/gi,X=/^data:(image\/(?:png|jpeg|webp|gif));base64,([\s\S]*)$/;function Y(a){return{text:(a?.filter(a=>"input_text"===a.type&&a.text&&!V.test(a.text.trim())).map(a=>a.text).join("")||"").replace(W,""),images:a?.filter(a=>"input_image"===a.type&&a.image_url).map(a=>{let b;return(b=a.image_url.match(X))?{type:"base64",media_type:b[1],data:b[2]}:null}).filter(a=>null!==a)||[]}}let Z=a=>{let b=a.changes;if(!b)return[];let c=a=>{if("string"==typeof a)return a;let b=(a?.kind&&"object"==typeof a.kind?a.kind.type:a?.kind)??a?.type;return"string"==typeof b?b:"update"};return Array.isArray(b)?b.map(a=>({path:a?.path||"",kind:c(a)})):Object.entries(b).map(([a,b])=>({path:a,kind:c(b)}))};function $(a){var b,c,f;let h=a.call_id||a.id||"";if(!h)return null;switch(!(b=a.type)?"":b.replace(/^([A-Z])/,a=>a.toLowerCase()).replace(/([a-z0-9])([A-Z])/g,"$1_$2").toLowerCase()){case"command_execution":return{id:h,name:e.bash,input:{command:"string"==typeof(c=a.command)?c:Array.isArray(c)?c.map(a=>{let b=String(a);return/[\s"'$`\\|&;<>()]/.test(b)?`'${b.replace(/'/g,"'\\''")}'`:b}).join(" "):""},result:a.aggregated_output||`(exit code: ${a.exit_code??"unknown"})`};case"file_change":let i;return{id:h,name:e.applyPatch,input:{changes:Z(a)},result:0===(i=Z(a)).length?"apply_patch":i.map(a=>`${a.kind} ${a.path}`.trim()).join("\n")};case"mcp_tool_call":return{id:h,name:g(a.server||"mcp",a.tool||"tool"),input:a.arguments||{},result:q(a)||`(${a.status||"completed"})`};case"web_search":{let{name:b,input:c,result:d}=p(a.query,a.action);return{id:h,name:b,input:c,result:d}}case"todo_list":{let b,c={todos:(a.items??[]).flatMap(a=>"string"==typeof a?.text?[{content:a.text,status:a.status||(a.completed?"completed":"pending")}]:[])};return{id:h,name:e.todo,input:c,result:(b=(f=c.todos).filter(a=>"completed"===a.status).length,`${b}/${f.length} completed`)}}case"image_view":return{id:h,name:e.read,input:{file_path:a.path||""},result:d};case"image_generation":return{id:h,name:e.imageGeneration,input:{file_path:a.savedPath||"",...a.revisedPrompt?{prompt:a.revisedPrompt}:{}},result:a.savedPath||`(${a.status||"completed"})`};case"dynamic_tool_call":return{id:h,name:g(a.namespace||"tool",a.tool||"call"),input:a.arguments||{},result:q(a)||`(${a.status||"completed"})`};default:return null}}}};
|