feat: add delete functionality for condition branches in node forms and improve edge filtering in workflow normalization

This commit is contained in:
mlogclub
2026-06-28 10:07:00 +08:00
parent 325a860fee
commit 33c6647375
3 changed files with 50 additions and 12 deletions
@@ -274,15 +274,17 @@ function ConditionBranchesEditor({
className="h-8"
onChange={(event) => onChange({ ...branch, name: event.target.value })}
/>
<Button
type="button"
variant="ghost"
size="sm"
className="h-8 px-2 text-xs text-muted-foreground hover:text-destructive"
onClick={() => onDelete(branch.id)}
>
</Button>
{branch.default ? null : (
<Button
type="button"
variant="ghost"
size="sm"
className="h-8 px-2 text-xs text-muted-foreground hover:text-destructive"
onClick={() => onDelete(branch.id)}
>
</Button>
)}
</div>
<div className="space-y-1.5">