From e91b6ac602c98dcf69e564db197a42d10dcbbcd9 Mon Sep 17 00:00:00 2001 From: Willie Date: Tue, 22 Sep 2026 00:45:58 +0800 Subject: [PATCH] fix(ui): turn a global MCP server off only for the project's Agents Turning a global server off from a project wrote the switch for every Agent the server reaches, so a project that uses OpenCode and Pi also got a Kilo Code file and an entry in Claude Code's off list. The switch now goes to the Agents the project itself uses. Claude Code keeps that off list in ~/.claude.json, the file that also holds the user-scope servers. The Sync page grouped both under the one path and said "Server entry will be removed", which read as deleting the global server when it only turns the server back on in one project. The off list is now its own group that names the project, and its rows say whether the server is turned off or back on there. Refs #289 --- ui/src/components/mcp/MCPPreview.tsx | 3 ++- ui/src/components/mcp/MCPProjectView.tsx | 9 +++++---- ui/src/components/mcp/mcpView.test.ts | 25 +++++++++++++++++++++++- ui/src/components/mcp/mcpView.ts | 21 ++++++++++++++++---- ui/src/components/sync/syncView.test.ts | 13 +++++++++++- ui/src/components/sync/syncView.ts | 10 +++++++--- ui/src/i18n/locales/de.json | 4 ++++ ui/src/i18n/locales/en.json | 4 ++++ ui/src/i18n/locales/es.json | 4 ++++ ui/src/i18n/locales/fa.json | 4 ++++ ui/src/i18n/locales/fr.json | 4 ++++ ui/src/i18n/locales/id.json | 4 ++++ ui/src/i18n/locales/ja.json | 4 ++++ ui/src/i18n/locales/ko.json | 4 ++++ ui/src/i18n/locales/pt-BR.json | 4 ++++ ui/src/i18n/locales/zh-CN.json | 4 ++++ ui/src/i18n/locales/zh-TW.json | 4 ++++ ui/src/pages/SyncPage.tsx | 1 + 18 files changed, 112 insertions(+), 14 deletions(-) diff --git a/ui/src/components/mcp/MCPPreview.tsx b/ui/src/components/mcp/MCPPreview.tsx index 3ec6d82ea..aa340ef71 100644 --- a/ui/src/components/mcp/MCPPreview.tsx +++ b/ui/src/components/mcp/MCPPreview.tsx @@ -34,11 +34,12 @@ export default function MCPPreview({ plan, onResolve, busy = false }: Props) {