Skip to content

Commit f9ddbee

Browse files
Copilothotlong
andcommitted
fix: show "Step X" only when multiple actions exist, fix existing test regression
Co-authored-by: hotlong <50353452+hotlong@users.noreply.github.com>
1 parent 76995c8 commit f9ddbee

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

packages/plugin-workflow/src/AutomationBuilder.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -268,9 +268,9 @@ export const AutomationBuilder: React.FC<AutomationBuilderProps> = ({
268268
<div className="flex items-center gap-2">
269269
{ACTION_ICONS[action.type]}
270270
<span className="text-sm font-medium">
271-
{(automation.executionMode ?? 'sequential') === 'sequential' ? `Step ${idx + 1}` : `Action ${idx + 1}`}
271+
{automation.actions.length > 1 && (automation.executionMode ?? 'sequential') === 'sequential' ? `Step ${idx + 1}` : `Action ${idx + 1}`}
272272
</span>
273-
{idx > 0 && (automation.executionMode ?? 'sequential') === 'sequential' && (
273+
{idx > 0 && automation.actions.length > 1 && (automation.executionMode ?? 'sequential') === 'sequential' && (
274274
<Badge variant="outline" className="text-[10px] px-1">then</Badge>
275275
)}
276276
</div>

0 commit comments

Comments
 (0)