diff --git a/src/app/components/settings-options/settings-options.component.html b/src/app/components/settings-options/settings-options.component.html index 77c4762..186700d 100644 --- a/src/app/components/settings-options/settings-options.component.html +++ b/src/app/components/settings-options/settings-options.component.html @@ -2,7 +2,8 @@ @for (n of options; track n) { @if (n == options.length) { - +

Se déconnecter

@@ -15,19 +16,22 @@
} @case (2) { - +

Modifier mes informations

} @case (3) { - +

Modifier mon mot de passe

} @case (4) { - +

Changer de désignation

diff --git a/src/app/components/settings-options/settings-options.component.ts b/src/app/components/settings-options/settings-options.component.ts index 658b7c0..e8f203c 100644 --- a/src/app/components/settings-options/settings-options.component.ts +++ b/src/app/components/settings-options/settings-options.component.ts @@ -1,12 +1,13 @@ -import {Component, inject} from '@angular/core'; +import {Component, inject, signal} from '@angular/core'; import {IonicModule, LoadingController, NavController} from "@ionic/angular"; -import {logOutOutline, chevronForwardOutline} from "ionicons/icons"; +import {logOutOutline, chevronForwardOutline, chevronBack} from "ionicons/icons"; import {addIcons} from "ionicons"; import {AuthManageService} from "../../services/auth-manage"; addIcons({ 'logout': logOutOutline, - 'chevron': chevronForwardOutline + 'chevron': chevronForwardOutline, + 'chevron-back': chevronBack }); @Component({ @@ -24,6 +25,22 @@ export class SettingsOptionsComponent { options = [1, 2, 3, 4, 5]; + profileState = signal(false); + passwordState = signal(false); + designationState = signal(false); + + updateProfileState(state: boolean) { + this.profileState.set(state); + } + + updatePasswordState(state: boolean) { + this.passwordState.set(state); + } + + updateDesignationState(state: boolean) { + this.designationState.set(state); + } + async logOut(){ const loading = await this.loadCtrl.create({ message: 'Déconnexion en cours...',