Document Preview Download {{-- ── Document header ── --}}
{{ $document->display_name }}
{{ $document->type->display_name ?? '—' }} · {{ $document->file_size }} · {{ pathinfo($document->file_name, PATHINFO_EXTENSION) ?: $kind }}
@unless($finished) @endunless
{{-- ── Viewer ── --}}
@switch($kind) @case('pdf') PDF document @break @case('image') Image @break @case('docx') Word document @break @case('legacy_doc') Legacy Word document @break @case('zip') Archive contents @break @case('audio') Audio @break @case('text') Text @break @default File @endswitch @if($kind === 'pdf' || $kind === 'zip')
@endif
@if($kind === 'zip')
{{-- Tree --}}
@if(count($zipEntries))
@foreach($zipEntries as $entry) @if($entry['is_dir'])
{{ $entry['name'] }}
@else @endif @endforeach
@else

This archive is empty or could not be read.

@endif
{{-- Inner-file viewer --}}

Select a file from the archive to preview it.

@else
Loading preview…
@endif
@push('scripts') {{-- docx-preview (client-side .docx → HTML; document bytes are fetched same-origin and never leave the server) --}} @endpush
{{-- ── WIP capture ── --}} @if($finished) @else
@endif