@php $record = $getRecord(); $badgeClass = match ($record->action) { 'created' => 'badge-created', 'updated' => 'badge-updated', 'deleted' => 'badge-deleted', default => 'badge-default', }; $dotClass = match ($record->action) { 'created' => 'dot-created', 'updated' => 'dot-updated', 'deleted' => 'dot-deleted', default => 'dot-default', }; $actionLabel = match ($record->action) { 'created' => class_basename($record->loggable_type ?? '') . ' Created', 'updated' => class_basename($record->loggable_type ?? '') . ' Updated', 'deleted' => class_basename($record->loggable_type ?? '') . ' Deleted', default => ucfirst($record->action), }; @endphp