1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-17 08:43:33 +00:00

Merge branch 'master' into feature-aopl-options

This commit is contained in:
Thomas Rittson
2021-05-14 10:55:14 +10:00
106 changed files with 10337 additions and 10121 deletions

View File

@@ -20,6 +20,7 @@ import {
} from 'jslib/abstractions';
import { EventService } from 'jslib/abstractions/event.service';
import { CipherRepromptType } from 'jslib/enums/cipherRepromptType';
import { EventType } from 'jslib/enums/eventType';
const CardAttributes: string[] = ['autoCompleteType', 'data-stripe', 'htmlName', 'htmlID', 'label-tag',
@@ -258,10 +259,17 @@ export default class AutofillService implements AutofillServiceInterface {
}
}
if (cipher.reprompt !== CipherRepromptType.None) {
return;
}
const copyTotpOnAutoFill = await this.totpService.isAutoCopyOnAutoFillEnabled();
const shouldCopyTotp = fromCommand || copyTotpOnAutoFill;
const totpCode = await this.doAutoFill({
cipher: cipher,
pageDetails: pageDetails,
skipTotp: !fromCommand,
skipTotp: !shouldCopyTotp,
skipLastUsed: !fromCommand,
skipUsernameOnlyFill: !fromCommand,
onlyEmptyFields: !fromCommand,