<x-ui.layout.page :title="__('me.documents.title')" page-icon="fe fe-file-text">
    <x-ui.table.table :columns="[
        ['label' => __('me.documents.type')],
        ['label' => __('me.documents.category')],
        ['label' => __('common.status')],
        ['label' => __('common.actions')],
    ]">
        @forelse ($documents as $document)
            <x-ui.table.row>
                <td>{{ $document->type->value }}</td>
                <td>{{ $document->category ?? '—' }}</td>
                <td>{{ $document->effectiveStatus() }}</td>
                <td>
                    <x-ui.buttons.secondary size="sm" :href="route('me.documents.download', $document)">
                        {{ __('common.download') }}
                    </x-ui.buttons.secondary>
                </td>
            </x-ui.table.row>
        @empty
            <x-ui.table.row><td colspan="4">{{ __('common.no_results') }}</td></x-ui.table.row>
        @endforelse
    </x-ui.table.table>
</x-ui.layout.page>
