style : changes in login ui

This commit is contained in:
MathewFrancis 2025-06-20 13:05:35 +05:30
parent 273a28e450
commit 89685aab0d
4 changed files with 23 additions and 5 deletions

File diff suppressed because one or more lines are too long

View File

@ -75,7 +75,8 @@ body {
.input-box { .input-box {
width: 75%; width: 75%;
padding: 10px; /* height: 30px; */
padding: 15px;
margin-bottom: 15px; margin-bottom: 15px;
font-size: 16px; font-size: 16px;
border: 1px solid #ccc; border: 1px solid #ccc;

View File

@ -52,8 +52,15 @@
/> />
</div> </div>
<!-- Login Button -->
<button class="login-btn" (click)="onSubmit()">LOGIN</button> <button class="login-btn" (click)="onSubmit()">LOGIN</button>
<!-- 🔴 Login Error Message -->
<div class="error-message" *ngIf="loginError">
{{ loginError }}
</div>
<div class="numpad"> <div class="numpad">
<div class="row"> <div class="row">
<button (click)="onNumpadClick('0')">0</button> <button (click)="onNumpadClick('0')">0</button>

View File

@ -14,6 +14,8 @@ export class LoginComponent {
loginForm: FormGroup; loginForm: FormGroup;
focusedField: 'email' | 'password' | null = null; focusedField: 'email' | 'password' | null = null;
loginError: string | null = null; // <-- 🔴 ADD THIS LINE
@ViewChild('emailInput') emailInputRef!: ElementRef<HTMLInputElement>; @ViewChild('emailInput') emailInputRef!: ElementRef<HTMLInputElement>;
@ViewChild('passwordInput') passwordInputRef!: ElementRef<HTMLInputElement>; @ViewChild('passwordInput') passwordInputRef!: ElementRef<HTMLInputElement>;
@ -93,7 +95,15 @@ export class LoginComponent {
return; return;
} }
// const { email, password } = this.loginForm.value;
// // 🔴 Replace this with real auth logic
// if (email === '123456789012' && password === '123456') {
// this.loginError = null;
console.log('Login successful:', this.loginForm.value); console.log('Login successful:', this.loginForm.value);
this.router.navigate(['/landing']); this.router.navigate(['/landing']);
// } else {
// this.loginError = 'Invalid username or password'; // 🔴 Show error
// }
} }
} }