fix: login form

This commit is contained in:
Pranav Deshmukh
2025-02-23 22:02:57 +05:30
parent ef7a64c9eb
commit b0b9944c05
3 changed files with 5 additions and 3 deletions
@@ -17,9 +17,10 @@
<mat-label>{{ 'labels.inputs.Password' | translate }}</mat-label>
<input matInput type="{{ passwordInputType }}" formControlName="password" />
<button
type="button"
mat-button
*ngIf="loginForm.controls.password.value && !loading"
matSuffix
*ngIf="loginForm.controls.password.value && !loading"
mat-icon-button
(mousedown)="togglePasswordVisibility()"
(mouseup)="togglePasswordVisibility()"
@@ -28,7 +29,7 @@
<fa-icon *ngIf="passwordInputType === 'text'" icon="eye-slash"></fa-icon>
</button>
<mat-error *ngIf="loginForm.controls.password.hasError('required')">
{{ 'labels.inputs.Password' | translate }} <strong>{{ 'labels.commons.is required' | translate }}</strong>
{{ 'labels.inputs.Password' | translate }} <strong>{{ 'labels.commons.pass is required' | translate }}</strong>
</mat-error>
</mat-form-field>
@@ -68,7 +68,7 @@ export class LoginFormComponent implements OnInit {
* Changes the input type between 'password' and 'text'.
*/
togglePasswordVisbility() {
togglePasswordVisibility() {
this.passwordInputType = this.passwordInputType === 'password' ? 'text' : 'password';
}
+1
View File
@@ -772,6 +772,7 @@
"is": "is",
"Is": "is",
"is required": "is required",
"pass is required": "is required(min length 8)",
"least one uppercase": "least one uppercase",
"lowercase and special character": "lowercase and special character",
"must be": "must be",