feat(agent-manager): accept Cmd+Enter as confirm in delete worktree dialog (#515)

This commit is contained in:
Marius
2026-02-20 11:41:47 +01:00
committed by GitHub
parent 69f1ab3299
commit ca97194bae
@@ -469,9 +469,15 @@ const AgentManagerContent: Component = () => {
}
dialog.close()
}
const onKeyDown = (e: KeyboardEvent) => {
if (e.key === "Enter" && (e.metaKey || e.ctrlKey)) {
e.preventDefault()
doDelete()
}
}
dialog.show(() => (
<Dialog title="Delete Worktree" fit>
<div class="am-confirm">
<div class="am-confirm" onKeyDown={onKeyDown}>
<div class="am-confirm-message">
<Icon name="trash" size="small" />
<span>