mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-08-26 00:53:48 +00:00
* feat(cli): browse MCP server resources in the /mcp dialog The @server:uri resource reference (read + inject) shipped in #5544, but the /mcp management dialog only surfaced a numeric "Resources: N" count — there was no way to list a server's resource URIs, so a user who didn't already know a URI couldn't discover what to reference. Mirror the existing tools flow: add a "View resources" action on the server detail step that opens a resource list, plus a detail view showing each resource's URI, name, MIME type, size and description, along with the exact @server:uri reference to paste into a message. Gated on resourceCount > 0 (so untrusted folders, where MCP is never discovered, show nothing). Adds en/zh/zh-TW strings, unit tests for both new steps, and updates the MCP docs. * fix(cli): wire MCP resource browser into the extensions manager + dedupe ref builder Addresses review on #5635: - [Critical] ServerDetailStep is shared with the extensions manager (McpServerActionsView), which doesn't pass onViewResources — so the new "View resources" action rendered there as a dead no-op. Gate the action on the optional handler being present (and add it to the useMemo deps), and implement the resource subview in McpServerActionsView so extension MCP servers get the same browser as the /mcp dialog. - [Suggestion] Add a canonical buildMcpResourceRef() next to matchMcpServerPrefix() (its exact inverse) and use it for the @server:uri hint and the @server: autocomplete value, so the format has one source of truth; add a round-trip test. - [Suggestion] Cover previously-untested paths: ResourceListStep scroll window (15 items: row windowing + ↑/↓ + count), ResourceDetailStep size:0 and showName dedup, and ServerDetailStep action gating (incl. the dead-action regression). |
||
|---|---|---|
| .. | ||
| configuration | ||
| extension | ||
| features | ||
| ide-integration | ||
| reference | ||
| support | ||
| _meta.ts | ||
| common-workflow.md | ||
| integration-github-action.md | ||
| integration-jetbrains.md | ||
| integration-vscode.md | ||
| integration-zed.md | ||
| overview.md | ||
| quickstart.md | ||
| qwen-serve-deploy-local.md | ||
| qwen-serve.md | ||