mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-18 03:15:11 +00:00
feat: rehauled console (#3525)
* new console * move npm ci to angular build * rel path for assets * local grpc copy * login policy, rm clear views, features rel path * lock Co-authored-by: Livio Amstutz <[email protected]>
This commit is contained in:
co-authored by
Livio Amstutz
parent
00f7dbe875
commit
08ae39ae19
@@ -2,7 +2,7 @@ import { Injectable } from '@angular/core';
|
||||
import { AuthConfig, OAuthService } from 'angular-oauth2-oidc';
|
||||
import { BehaviorSubject, from, Observable } from 'rxjs';
|
||||
|
||||
import { StatehandlerService } from './statehandler.service';
|
||||
import { StatehandlerService } from './statehandler/statehandler.service';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root',
|
||||
@@ -10,14 +10,9 @@ import { StatehandlerService } from './statehandler.service';
|
||||
export class AuthenticationService {
|
||||
private authConfig!: AuthConfig;
|
||||
private _authenticated: boolean = false;
|
||||
private readonly _authenticationChanged: BehaviorSubject<
|
||||
boolean
|
||||
> = new BehaviorSubject(this.authenticated);
|
||||
private readonly _authenticationChanged: BehaviorSubject<boolean> = new BehaviorSubject(this.authenticated);
|
||||
|
||||
constructor(
|
||||
private oauthService: OAuthService,
|
||||
private statehandler: StatehandlerService,
|
||||
) { }
|
||||
constructor(private oauthService: OAuthService, private statehandler: StatehandlerService) {}
|
||||
|
||||
public initConfig(data: AuthConfig): void {
|
||||
this.authConfig = data;
|
||||
@@ -35,10 +30,7 @@ export class AuthenticationService {
|
||||
return from(this.oauthService.loadUserProfile());
|
||||
}
|
||||
|
||||
public async authenticate(
|
||||
partialConfig?: Partial<AuthConfig>,
|
||||
force: boolean = false,
|
||||
): Promise<boolean> {
|
||||
public async authenticate(partialConfig?: Partial<AuthConfig>, force: boolean = false): Promise<boolean> {
|
||||
if (partialConfig) {
|
||||
Object.assign(this.authConfig, partialConfig);
|
||||
}
|
||||
@@ -63,4 +55,3 @@ export class AuthenticationService {
|
||||
this._authenticationChanged.next(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user