{{-- Active inter-admin note alerts rendered immediately below the dashboard's welcome strip. The DashboardController has already: - filtered the collection to notes assigned to the current admin and not yet dismissed, - stamped first_seen_at on any row that was previously unseen (single bulk UPDATE, not one per note). The X button on each card POSTs to admin.admin-notes.dismiss via fetch — on success the card fades out; on failure the user lands on the page reload path. No JS framework dependency; vanilla DOM. --}} @if (! empty($alerts) && $alerts->isNotEmpty()) @once @push('styles') @endpush @endonce
@foreach ($alerts as $note)

{{ __('admin.admin_notes.alert.heading') }} {{ __('admin.admin_notes.priorities.' . $note->priority) }} {{ __('admin.admin_notes.alert.from', ['name' => $note->creator?->name ?: '—']) }}

{{ $note->note }}

{{-- Done: primary action — records `confirmed_at`, meaning the receiver actually completed the task in the note. --}} {{-- X: secondary action — records `dismissed_at`, a passive acknowledgement that hides the alert without claiming the task was completed. --}}
@endforeach
{{-- Shared confirmation modal — one instance for the whole page, used by both the X (dismiss) and the Done (confirm) buttons. The modal's title + prompt + endpoint are rewritten in JS at open time so the same DOM serves both intents. --}} @once @push('scripts') @endpush @endonce @endif