Add JWT support for authentication handling

Integrate `@auth0/angular-jwt` for Token management. Update `app.config.ts` with `JwtModule` setup and token getter from cookies. Enhance `AuthService` to include token handling, fake login, and JWT validation using `JwtHelperService`. Introduce `JwtClaims` interface for structured token claims.
This commit is contained in:
2025-07-04 22:31:41 +02:00
parent dfea91d8ca
commit f0faa63ca7
5 changed files with 48 additions and 15 deletions
@@ -53,7 +53,8 @@ export class LoginDialogComponent {
return;
}
this.snackBar.open('Logging in...', '', {duration: 2000});
this.authService.login(this.loginForm.value.code).subscribe({
// this.authService.login(this.loginForm.value.code).subscribe({
this.authService.fakeLogin().subscribe({
next: (jwt) => {
this.dialogRef.close(jwt);
},