diff --git a/packages/builder/src/components/workflow/WorkflowBuilder/flowchart/FlowItem.svelte b/packages/builder/src/components/workflow/WorkflowBuilder/flowchart/FlowItem.svelte index b88ab36c54..ceed34924f 100644 --- a/packages/builder/src/components/workflow/WorkflowBuilder/flowchart/FlowItem.svelte +++ b/packages/builder/src/components/workflow/WorkflowBuilder/flowchart/FlowItem.svelte @@ -6,9 +6,9 @@ export let block let selected - $: selected = - $workflowStore.selectedBlock != null && - $workflowStore.selectedBlock.id === block.id + $: selected = $workflowStore.selectedBlock?.id === block.id + $: steps = $workflowStore.selectedWorkflow?.workflow?.definition?.steps ?? [] + $: blockIdx = steps.findIndex(step => step.id === block.id) function selectBlock() { onSelect(block) @@ -31,18 +31,24 @@ .replaceAll("}}", "}}") -
@@ -51,7 +57,7 @@