diff --git a/app/components/mcp-market.tsx b/app/components/mcp-market.tsx index bbf0d4d45..0bd4a7dd6 100644 --- a/app/components/mcp-market.tsx +++ b/app/components/mcp-market.tsx @@ -140,7 +140,7 @@ export function McpMarketPage() { setUserConfig({}); } } - }, [editingServerId, config]); + }, [editingServerId, config, presetServers]); // 保存服务器配置 const saveServerConfig = async () => { @@ -405,22 +405,16 @@ export function McpMarketPage() { } else if (prop.type === "string") { const currentValue = userConfig[key as keyof typeof userConfig] || ""; return ( - -
- { - setUserConfig({ ...userConfig, [key]: e.target.value }); - }} - /> -
+ + { + setUserConfig({ ...userConfig, [key]: e.target.value }); + }} + /> ); }