Skip to content

Commit 4b26a30

Browse files
committed
feat(package): integration of firebase auth inngx-auth-firebaseui-register #323
1 parent b4ed0e4 commit 4b26a30

File tree

2 files changed

+29
-19
lines changed

2 files changed

+29
-19
lines changed

src/module/components/ngx-auth-firebaseui-register/ngx-auth-firebaseui-register.component.html

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -56,26 +56,26 @@
5656
</mat-form-field>
5757

5858
<!-- <div *ngIf="this.tosUrl || this.privacyPolicyUrl"-->
59-
<!-- <div-->
60-
<!-- class="terms"-->
61-
<!-- fxLayout="row" fxLayoutAlign="center center"-->
62-
<!-- [@animate]="{value:'*',params:{duration:'250ms',y:'100px'}}">-->
63-
<!-- <mat-checkbox aria-label="I read and accept" name="terms" required>-->
64-
<!-- <span>{{readAncAcceptText}}</span>-->
65-
<!-- <span>&nbsp;</span>-->
66-
<!-- <a target="_blank"-->
67-
<!-- [href]="this.tosUrl">-->
68-
<!-- Terms of Service and Conditions-->
69-
<!-- </a>-->
70-
<!-- </mat-checkbox>-->
71-
<!-- </div>-->
59+
<!-- <div-->
60+
<!-- class="terms"-->
61+
<!-- fxLayout="row" fxLayoutAlign="center center"-->
62+
<!-- [@animate]="{value:'*',params:{duration:'250ms',y:'100px'}}">-->
63+
<!-- <mat-checkbox aria-label="I read and accept" name="terms" required>-->
64+
<!-- <span>{{readAncAcceptText}}</span>-->
65+
<!-- <span>&nbsp;</span>-->
66+
<!-- <a target="_blank"-->
67+
<!-- [href]="this.tosUrl">-->
68+
<!-- Terms of Service and Conditions-->
69+
<!-- </a>-->
70+
<!-- </mat-checkbox>-->
71+
<!-- </div>-->
7272

73-
<button
74-
[disabled]="registerForm.invalid"
75-
aria-label="CREATE AN ACCOUNT"
76-
class="submit-button"
77-
[color]="colorAccent"
78-
mat-raised-button>
73+
<button mat-raised-button
74+
aria-label="CREATE AN ACCOUNT"
75+
class="submit-button"
76+
[color]="colorAccent"
77+
[disabled]="registerForm.invalid"
78+
(click)="createAccount()">
7979
{{createAccountButtonText}}
8080
</button>
8181
</form>

src/module/components/ngx-auth-firebaseui-register/ngx-auth-firebaseui-register.component.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,4 +129,14 @@ export class NgxAuthFirebaseuiRegisterComponent implements OnInit, OnDestroy {
129129
this._unsubscribeAll.next();
130130
this._unsubscribeAll.complete();
131131
}
132+
133+
async createAccount() {
134+
return await this.authProcess.signUp(
135+
this.registerForm.get('name').value,
136+
{
137+
email: this.registerForm.get('email').value,
138+
password: this.registerForm.get('password').value
139+
}
140+
)
141+
}
132142
}

0 commit comments

Comments
 (0)