@props(['src' => null, 'name' => '?', 'size' => 9])

@if ($src)
    <img src="{{ $src }}" alt="{{ $name }}"
         class="h-{{ $size }} w-{{ $size }} shrink-0 rounded-full object-cover">
@else
    <span class="flex h-{{ $size }} w-{{ $size }} shrink-0 items-center justify-center rounded-full bg-brand-soft text-xs font-semibold text-brand">
        {{ strtoupper(mb_substr($name, 0, 1)) }}
    </span>
@endif
