Skip to content

Commit 553675a

Browse files
authored
Merge pull request #1239 from firebase/@invertase/bb-30
2 parents ed32810 + 3e64ffb commit 553675a

File tree

2 files changed

+14
-26
lines changed

2 files changed

+14
-26
lines changed

packages/angular/src/lib/auth/forms/sign-up-auth-form.ts

Lines changed: 7 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -43,35 +43,23 @@ import {
4343
],
4444
template: `
4545
<form (submit)="handleSubmit($event)" class="fui-form">
46-
<fieldset>
47-
<fui-form-input
48-
name="email"
49-
tanstack-app-field
50-
[tanstackField]="form"
51-
label="{{ emailLabel() }}"
52-
></fui-form-input>
53-
</fieldset>
54-
<fieldset>
55-
<fui-form-input
56-
name="password"
57-
tanstack-app-field
58-
[tanstackField]="form"
59-
label="{{ passwordLabel() }}"
60-
></fui-form-input>
61-
</fieldset>
6246
@if (requireDisplayNameField()) {
6347
<fieldset>
6448
<fui-form-input
6549
name="displayName"
6650
tanstack-app-field
6751
[tanstackField]="form"
6852
label="{{ displayNameLabel() }}"
69-
></fui-form-input>
53+
/>
7054
</fieldset>
7155
}
72-
56+
<fieldset>
57+
<fui-form-input name="email" tanstack-app-field [tanstackField]="form" label="{{ emailLabel() }}" />
58+
</fieldset>
59+
<fieldset>
60+
<fui-form-input name="password" tanstack-app-field [tanstackField]="form" label="{{ passwordLabel() }}" />
61+
</fieldset>
7362
<fui-policies />
74-
7563
<fieldset>
7664
<fui-form-submit [state]="state()">
7765
{{ createAccountLabel() }}

packages/react/src/auth/forms/sign-up-auth-form.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,13 @@ export function SignUpAuthForm({ onBackToSignInClick, onSignUp }: SignUpAuthForm
9595
}}
9696
>
9797
<form.AppForm>
98+
{requireDisplayName ? (
99+
<fieldset>
100+
<form.AppField name="displayName">
101+
{(field) => <field.Input label={getTranslation(ui, "labels", "displayName")} />}
102+
</form.AppField>
103+
</fieldset>
104+
) : null}
98105
<fieldset>
99106
<form.AppField name="email">
100107
{(field) => <field.Input label={getTranslation(ui, "labels", "emailAddress")} type="email" />}
@@ -105,13 +112,6 @@ export function SignUpAuthForm({ onBackToSignInClick, onSignUp }: SignUpAuthForm
105112
{(field) => <field.Input label={getTranslation(ui, "labels", "password")} type="password" />}
106113
</form.AppField>
107114
</fieldset>
108-
{requireDisplayName ? (
109-
<fieldset>
110-
<form.AppField name="displayName">
111-
{(field) => <field.Input label={getTranslation(ui, "labels", "displayName")} />}
112-
</form.AppField>
113-
</fieldset>
114-
) : null}
115115
<Policies />
116116
<fieldset>
117117
<form.SubmitButton>{getTranslation(ui, "labels", "createAccount")}</form.SubmitButton>

0 commit comments

Comments
 (0)