Skip to content

Commit bb69d01

Browse files
feat: enable autocomplete for one-time-code
Add HTML attributes to enable autofill by password managers.
1 parent 42edd0f commit bb69d01

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/app/cdk/two-factor-authentication-form/two-factor/two-factor-authentication-form.component.html

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<div class="input-container">
33
<mat-label
44
class="orc-font-small-print"
5+
for="totp"
56
i18n="@@ngOrcid.signin.2fa.label"
67
[ngClass]="{
78
error: isVerificationCodeInvalid
@@ -20,7 +21,11 @@
2021
formControlName="verificationCode"
2122
cdkFocusInitial
2223
appTrim
23-
autocomplete="off"
24+
autocomplete="one-time-code"
25+
id="totp"
26+
name="totp"
27+
pattern="[0-9]*"
28+
type="text"
2429
/>
2530
</mat-form-field>
2631
<ng-container *ngIf="!recoveryCode">

0 commit comments

Comments
 (0)