Skip to content

Commit 54bd538

Browse files
fix(agent): move advanced MCP option to bottom (#7389)
* fix(chat-deploy): restore output picker interactions * fix(pickers): restore modal interactions and surface workflows * fix(chat-deploy): surface child workflow outputs * fix(chat-deploy): distinguish subworkflow output navigation * fix(chat-deploy): keep selected outputs in place
1 parent 7e85965 commit 54bd538

1 file changed

Lines changed: 29 additions & 23 deletions

File tree

  • apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input

apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/tool-input.tsx

Lines changed: 29 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1252,29 +1252,6 @@ export const ToolInput = memo(function ToolInput({
12521252
<UnsupportedToolBadge message={UNSUPPORTED_MCP_TOOL_MESSAGE} />
12531253
) : undefined,
12541254
})
1255-
if (supportsAdvancedMcpServer) {
1256-
actionItems.push({
1257-
label: 'MCP Server (Advanced)',
1258-
value: 'action-mcp-server-advanced',
1259-
icon: Server,
1260-
onSelect: () => {
1261-
setStoreValue([
1262-
...selectedTools.map((tool) => ({ ...tool, isExpanded: false })),
1263-
{
1264-
type: MCP_SERVER_ADVANCED_TOOL_TYPE,
1265-
params: { serverId: '' },
1266-
isExpanded: true,
1267-
usageControl: 'auto',
1268-
},
1269-
])
1270-
setOpen(false)
1271-
},
1272-
disabled: isPreview || disabled || mcpUnsupported,
1273-
suffixElement: mcpUnsupported ? (
1274-
<UnsupportedToolBadge message={UNSUPPORTED_MCP_TOOL_MESSAGE} />
1275-
) : undefined,
1276-
})
1277-
}
12781255
}
12791256
if (actionItems.length > 0) {
12801257
groups.push({ items: actionItems })
@@ -1412,6 +1389,35 @@ export const ToolInput = memo(function ToolInput({
14121389
})
14131390
}
14141391

1392+
if (!permissionConfig.disableMcpTools && supportsAdvancedMcpServer) {
1393+
groups.push({
1394+
section: 'Advanced',
1395+
items: [
1396+
{
1397+
label: 'MCP Server (Advanced)',
1398+
value: 'action-mcp-server-advanced',
1399+
icon: Server,
1400+
onSelect: () => {
1401+
setStoreValue([
1402+
...selectedTools.map((tool) => ({ ...tool, isExpanded: false })),
1403+
{
1404+
type: MCP_SERVER_ADVANCED_TOOL_TYPE,
1405+
params: { serverId: '' },
1406+
isExpanded: true,
1407+
usageControl: 'auto',
1408+
},
1409+
])
1410+
setOpen(false)
1411+
},
1412+
disabled: isPreview || disabled || mcpUnsupported,
1413+
suffixElement: mcpUnsupported ? (
1414+
<UnsupportedToolBadge message={UNSUPPORTED_MCP_TOOL_MESSAGE} />
1415+
) : undefined,
1416+
},
1417+
],
1418+
})
1419+
}
1420+
14151421
return groups
14161422
}, [
14171423
open,

0 commit comments

Comments
 (0)