Spaces:
Building
Building
Update flare-ui/src/app/components/login/login.component.ts
Browse files
flare-ui/src/app/components/login/login.component.ts
CHANGED
@@ -64,10 +64,12 @@ import { AuthService } from '../../services/auth.service';
|
|
64 |
<mat-error>Password is required</mat-error>
|
65 |
</mat-form-field>
|
66 |
|
67 |
-
|
68 |
-
<
|
69 |
-
|
70 |
-
|
|
|
|
|
71 |
|
72 |
<button
|
73 |
mat-raised-button
|
@@ -76,9 +78,13 @@ import { AuthService } from '../../services/auth.service';
|
|
76 |
class="full-width submit-button"
|
77 |
[disabled]="loading || !loginForm.valid"
|
78 |
>
|
79 |
-
|
80 |
-
|
81 |
-
|
|
|
|
|
|
|
|
|
82 |
</button>
|
83 |
</form>
|
84 |
</mat-card-content>
|
|
|
64 |
<mat-error>Password is required</mat-error>
|
65 |
</mat-form-field>
|
66 |
|
67 |
+
@if (error) {
|
68 |
+
<div class="error-message">
|
69 |
+
<mat-icon>error</mat-icon>
|
70 |
+
{{ error }}
|
71 |
+
</div>
|
72 |
+
}
|
73 |
|
74 |
<button
|
75 |
mat-raised-button
|
|
|
78 |
class="full-width submit-button"
|
79 |
[disabled]="loading || !loginForm.valid"
|
80 |
>
|
81 |
+
@if (loading) {
|
82 |
+
<mat-spinner diameter="20" class="button-spinner"></mat-spinner>
|
83 |
+
Logging in...
|
84 |
+
} @else {
|
85 |
+
<mat-icon>login</mat-icon>
|
86 |
+
Login
|
87 |
+
}
|
88 |
</button>
|
89 |
</form>
|
90 |
</mat-card-content>
|