// ...
use Filament\Actions\Action;
// ...
class LoginTwoFactor extends Page implements HasForms, HasActions
{
use InteractsWithForms;
use InteractsWithFormActions;
protected static string $layout = 'filament.layouts.login';
public function mount(): void
{
$this->form->fill();
}
public function resendAction(): Action
{
return Action::make('resend')
->label('Opnieuw versturen')
->color('info')
->action(function ($data) {
auth()->user->notify(app(SendOTP::class));
});
}
// ...
}
// ...
use Filament\Actions\Action;
// ...
class LoginTwoFactor extends Page implements HasForms, HasActions
{
use InteractsWithForms;
use InteractsWithFormActions;
protected static string $layout = 'filament.layouts.login';
public function mount(): void
{
$this->form->fill();
}
public function resendAction(): Action
{
return Action::make('resend')
->label('Opnieuw versturen')
->color('info')
->action(function ($data) {
auth()->user->notify(app(SendOTP::class));
});
}
// ...
}