1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-23 19:53:43 +00:00

handle registerRoute

This commit is contained in:
rr-bw
2024-08-30 15:40:23 -07:00
parent 9b28a0e01e
commit 2a58a69b08
2 changed files with 37 additions and 2 deletions

View File

@@ -48,7 +48,22 @@
<hr />
<!-- TODO-rr-bw: More here -->
<p class="tw-m-0 tw-text-sm">
{{ "newAroundHere" | i18n }}
<!-- Two notes:
(1) We check the value and validity of email so we don't send an invalid email to autofill
on load of register for both enter and mouse based navigation
(2) We use mousedown to trigger navigation so that the onBlur form validation does not fire
and move the create account link down the page on click which causes the user to miss actually
clicking on the link. Mousedown fires before onBlur.
-->
<a
[routerLink]="registerRoute$ | async"
[queryParams]="emailFormControl.valid ? { email: emailFormControl.value } : {}"
(mousedown)="goToRegister()"
>{{ "createAccount" | i18n }}</a
>
</p>
</ng-container>
<!-----------------------------------