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

Initial work

This commit is contained in:
gbubemismith
2023-07-25 15:45:11 -04:00
parent ca5b033cfd
commit 7daf604e3a
12 changed files with 126 additions and 16 deletions

View File

@@ -39,6 +39,8 @@ export class TwoFactorComponent extends CaptchaProtectedComponent implements OnI
formPromise: Promise<any>;
emailPromise: Promise<any>;
identifier: string = null;
redirectPath: string;
sessionId: string;
onSuccessfulLogin: () => Promise<any>;
onSuccessfulLoginNavigate: () => Promise<any>;
@@ -74,6 +76,15 @@ export class TwoFactorComponent extends CaptchaProtectedComponent implements OnI
if (qParams.identifier != null) {
this.identifier = qParams.identifier;
}
if (qParams.redirectPath != null) {
this.redirectPath = qParams.redirectPath;
this.successRoute = this.redirectPath;
}
if (qParams.sessionId != null) {
this.sessionId = qParams?.sessionId;
}
});
if (this.needsLock) {
@@ -220,6 +231,7 @@ export class TwoFactorComponent extends CaptchaProtectedComponent implements OnI
this.router.navigate([this.successRoute], {
queryParams: {
identifier: this.identifier,
sessionId: this.sessionId,
},
});
}