@php $filePath = $getRecord()->data ?? '0'; $extension = pathinfo($filePath, PATHINFO_EXTENSION); @endphp @if (in_array($extension, ['pdf', 'jpg', 'jpeg', 'png'])) @if ($extension === 'pdf') @else File Preview @endif @else {{ $getRecord()->data }} @endif