fix(app): move reload agent away from close action

This commit is contained in:
Mohamed Boudra
2026-04-07 12:20:15 +07:00
parent 29b6f2a86f
commit 1900f43049
2 changed files with 16 additions and 13 deletions
@@ -135,17 +135,6 @@ export function buildWorkspaceTabMenuEntries(
void onCopyAgentId(agentId);
},
});
entries.push({
kind: "item",
key: "reload-agent",
label: "Reload agent",
icon: "rotate-cw",
tooltip: "Reload agent to update skills, MCPs or login status.",
testID: `${menuTestIDBase}-reload-agent`,
onSelect: () => {
void onReloadAgent(agentId);
},
});
entries.push({
kind: "separator",
key: "copy-separator",
@@ -185,6 +174,20 @@ export function buildWorkspaceTabMenuEntries(
void onCloseOtherTabs(tab.tabId);
},
});
if (tab.target.kind === "agent") {
const { agentId } = tab.target;
entries.push({
kind: "item",
key: "reload-agent",
label: "Reload agent",
icon: "rotate-cw",
tooltip: "Reload agent to update skills, MCPs or login status.",
testID: `${menuTestIDBase}-reload-agent`,
onSelect: () => {
void onReloadAgent(agentId);
},
});
}
entries.push({
kind: "item",
key: "close",