@php [$tone, $label] = match (true) { $order->status === 'canceled' => ['wd-pill-danger', 'Canceled'], $order->fulfillment_status === 'fulfilled' => ['wd-pill-success', 'Shipped'], $order->fulfillment_status === 'partially_fulfilled' => ['wd-pill-warning', 'Part shipped'], default => ['wd-pill-warning', 'In production'], }; @endphp {{ $label }} @if(($withPayment ?? false) && $order->status !== 'canceled') @if($order->payment_status === 'paid') Paid @elseif($order->isOverdue()) Overdue @elseif($order->payment_status === 'pending') Due {{ $order->payment_due_at?->format('d M') ?? 'now' }} @endif @endif