Skip to content

Commit

Permalink
Merge pull request #722 from kevindice/autofocus-yubikey-field
Browse files Browse the repository at this point in the history
Autofocus yubikey field
  • Loading branch information
moggers87 authored Apr 28, 2024
2 parents dfead94 + 8374a12 commit aed481d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion two_factor/plugins/yubikey/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ class YubiKeyAuthenticationForm(AuthenticationTokenForm):
# YubiKey generates a OTP of 44 characters (not digits). So if the
# user's primary device is a YubiKey, replace the otp_token
# IntegerField with a CharField.
otp_token = forms.CharField(label=_('YubiKey'), widget=forms.PasswordInput())
otp_token = forms.CharField(label=_('YubiKey'), widget=forms.PasswordInput(attrs={'autofocus': True}))

0 comments on commit aed481d

Please sign in to comment.