@php $items = $getItems(); $inline = $getInline(); $badge = null; $hasBadge = null; $isStyleInline = $getListStyle() == 'inline'; $isStyleList = $getListStyle() == 'list'; if ($isStyleList) { $hasBadge = false; $separator = null; $l1Class = 'divide-y divide-gray-200 overflow-hidden rounded-xl bg-white shadow-sm ring-1 ring-gray-950/5 dark:divide-white/10 dark:bg-gray-900 dark:ring-white/10'; $l2Class = 'flex items-center w-full p-3 gap-x-3 text-gray-700 outline-none transition duration-75 hover:bg-gray-100 focus:bg-gray-100 dark:text-gray-200 dark:hover:bg-white/5 dark:focus:bg-white/5'; } else { $badge = $getBadge(); $hasBadge = !empty($badge); $separator = $getSeparator(); $l1Class = 'flex flex-wrap items-center ' . ($hasBadge ? 'gap-1.5' : ''); $l2Class = 'flex items-center ' . ($hasBadge ? '' : 'gap-0.5'); $inline = false; } @endphp
@forelse ($items as $itemKey => $itemElement) @php $tagHref = $getItemUrl($itemElement); $tag = $tagHref ? 'a' : 'div'; $tagAttributes = $attributes->merge(['class' => $l2Class])->merge($getItemExtraAttributes($itemElement), escape: false); @endphp
@if ($hasBadge) <{{ $tag }} href="{{ $tagHref }}"> {{ $getItemLabel($itemElement) }} @else <{{ $tag }} href="{{ $tagHref }}"> @if ($icon = $getItemIcon($itemElement)) @endif <{{ $tag }} href="{{ $tagHref }}" class="inline-block truncate"> {{ $getItemLabel($itemElement) }}

{{ $getItemDescription($itemElement) }}

@endif @php $itemActions = $getItemActions($itemElement); @endphp @if ($itemActions)
@if (is_array($itemActions)) @foreach ($itemActions as $action) {{ $action }} @endforeach @else {{ $itemActions }} @endif
@endif
@if (!$loop->last && !$hasBadge) {{ $separator }} @endif @empty @if ($getEmptyStateEnabled()) @if ($isStyleList)

{{ $getEmptyStateHeading() }}

{{ $getEmptyStateDescription() }}

{{-- Content --}}
@else

{{ $getEmptyStateHeading() }}

@endif @endif @endforelse