Skip to content

Commit

Permalink
add autocomplete one-time-code to input
Browse files Browse the repository at this point in the history
  • Loading branch information
markvaneijk committed Sep 29, 2024
1 parent 5dc1ad1 commit cdb1192
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/Http/Livewire/Auth/LoginTwoFactor.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ public function resend(): Action
->color('primary')
->extraAttributes(['class' => 'w-full text-xs'])
->link()
->disabled(fn () => ! $this->canResend())
->action(fn () => $this->handleResend());
->disabled(fn() => ! $this->canResend())
->action(fn() => $this->handleResend());
}

public function handleResend(): void
Expand Down Expand Up @@ -126,7 +126,10 @@ protected function getFormSchema(): array
return [
TextInput::make('code')
->required()
->extraInputAttributes(['name' => 'code'])
->extraInputAttributes([
'name' => 'code',
'autocomplete' => 'one-time-code',
])
->label(__('Code')),
TextInput::make('recovery_code')
->extraInputAttributes(['name' => 'recovery_code'])
Expand Down

0 comments on commit cdb1192

Please sign in to comment.