@php
$dates = [
'Insurance expiry' => [$vehicle->insurance_expiry, $vehicle->insuranceExpiringSoon()],
'Registration expiry' => [$vehicle->registration_expiry, $vehicle->registration_expiry && $vehicle->registration_expiry->isPast()],
'Last service' => [$vehicle->last_service_date, false],
'Next service' => [$vehicle->next_service_date, $vehicle->needsService()],
];
@endphp
@foreach ($dates as $label => [$date, $warn])
{{ $label }}
{{ $date?->format('j M Y') ?? 'Not set' }}
@if ($warn)@endif
@endforeach
@if ($vehicle->notes)
Notes
{{ $vehicle->notes }}
@endif