<?php

namespace App\Filament\Resources\SuratKeteranganAhliWarisResource\Pages;

use App\Filament\Resources\SuratKeteranganAhliWarisResource;
use Filament\Actions;
use Filament\Resources\Pages\ListRecords;
use Illuminate\Support\Facades\Auth;

class ListSuratKeteranganAhliWaris extends ListRecords
{
    protected static string $resource = SuratKeteranganAhliWarisResource::class;

    protected function getHeaderActions(): array
    {
        return [
            Actions\CreateAction::make()->visible(fn (): bool => Auth::user()->role !== 'kepala_desa'),
        ];
    }
}
