{{-- One list of steps and what closes it (an end card, or — after a condition — its two branches). Recursive: a condition includes this same partial for each branch. Expects: $seq, $path ('' for the top list, "steps.2.yes" for a branch), $readOnly, $flat, $describer. --}} @php $listPath = $path === '' ? 'steps' : $path.'.steps'; $steps = $seq['steps'] ?? []; $count = count($steps); $endsWithCondition = $count > 0 && ($steps[$count - 1]['type'] ?? '') === 'condition'; $kinds = ['action' => ['پیامک', 'bg-indigo-100 text-indigo-700'], 'wait' => ['انتظار', 'bg-sky-100 text-sky-700'], 'condition' => ['شرط', 'bg-amber-100 text-amber-700']]; @endphp
{{ $describer->describe($step) }}
@if (($step['type'] ?? '') === 'action' && ($step['config']['retry']['enabled'] ?? false))تلاش مجدد: تا {{ (int) ($step['config']['retry']['max_attempts'] ?? 0) }} بار
@endif{{ $branchLabel }}
@include('livewire.automation.workflows._sequence', ['seq' => $step[$branch], 'path' => $stepPath.'.'.$branch, 'readOnly' => $readOnly, 'flat' => $flat, 'describer' => $describer])