Started login page
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
<form [formGroup]="loginForm">
|
||||
<ion-item>
|
||||
<ion-label>Pseudo</ion-label>
|
||||
<ion-input placeholder="Nom d'utilisateur" formControlName="username"></ion-input>
|
||||
</ion-item>
|
||||
|
||||
<ion-item>
|
||||
<ion-label>Mot de passe</ion-label>
|
||||
<ion-input type="password" placeholder="MotDePasse1234" formControlName="password">
|
||||
<ion-input-password-toggle slot="end"></ion-input-password-toggle>
|
||||
</ion-input>
|
||||
</ion-item>
|
||||
|
||||
<ion-button class="flex flex-col items-center justify-center mt-6">
|
||||
<p class="text-white font-bold m-0">Se connecter</p>
|
||||
</ion-button>
|
||||
</form>
|
||||
@@ -0,0 +1,24 @@
|
||||
import { Component } from '@angular/core';
|
||||
import {FormControl, FormGroup, ReactiveFormsModule, Validators} from "@angular/forms";
|
||||
import {IonButton, IonInput, IonInputPasswordToggle, IonItem, IonLabel} from "@ionic/angular/standalone";
|
||||
|
||||
@Component({
|
||||
selector: 'app-login-form',
|
||||
templateUrl: './login-form.component.html',
|
||||
styleUrls: ['./login-form.component.scss'],
|
||||
imports: [
|
||||
ReactiveFormsModule,
|
||||
IonButton,
|
||||
IonInput,
|
||||
IonInputPasswordToggle,
|
||||
IonItem,
|
||||
IonLabel
|
||||
]
|
||||
})
|
||||
export class LoginFormComponent {
|
||||
|
||||
loginForm: FormGroup = new FormGroup({
|
||||
username: new FormControl<string>(null, [Validators.required]),
|
||||
password: new FormControl<string>(null, [Validators.required])
|
||||
})
|
||||
}
|
||||
Reference in New Issue
Block a user