@forelse ($data as $res)
    <div class="entry col-md-6">
        <div class="grid-inner row align-items-center no-gutter">
            <div class="col-auto">
                <div class="entry-image">
                    <a href="{{ route('post', ['slug' => $res->slug]) }}"><img
                             src="{{ $res->thumbnail ? asset('storage/'.$res->thumbnail) : asset('default.jpg') }}" alt="Image"
                             onerror="this.src='{{ asset('default.jpg') }}'"></a>
                </div>
            </div>
            <div class="col ps-3">
                <div class="entry-title">
                    <h4 class="fw-medium"><a href="{{ route('post', ['slug' => $res->slug]) }}">{{ $res->judul }}</a>
                    </h4>
                </div>
                <div class="entry-meta">
                    <ul>
                        <li><i class="bi-clock"></i>{{ tanggal_indo($res->tanggal_publish) }}</li>
                        <li><i class="uil uil-user"></i>{{ $res->to_user->name }}</li>
                    </ul>
                </div>
            </div>
        </div>
    </div>
@empty
    <span>Belum Ada Data</span>
@endforelse