diff --git a/apps/client/src/app/components/header/header.component.html b/apps/client/src/app/components/header/header.component.html index 283e930e0..69d03acd1 100644 --- a/apps/client/src/app/components/header/header.component.html +++ b/apps/client/src/app/components/header/header.component.html @@ -1,14 +1,14 @@ - @if (user) { -
+ @if (user()) { + @@ -20,11 +20,11 @@ mat-button [class]="{ 'font-weight-bold': - currentRoute === internalRoutes.home.path || - currentRoute === internalRoutes.zen.path, + currentRoute() === internalRoutes.home.path || + currentRoute() === internalRoutes.zen.path, 'text-decoration-underline': - currentRoute === internalRoutes.home.path || - currentRoute === internalRoutes.zen.path + currentRoute() === internalRoutes.home.path || + currentRoute() === internalRoutes.zen.path }" [routerLink]="['/']" >OverviewPortfolioAccountsAdmin ControlResources @if ( - hasPermissionForSubscription && user?.subscription?.type === 'Basic' + hasPermissionForSubscription && user()?.subscription?.type === 'Basic' ) {
  • Pricing - @if (currentRoute !== routePricing && hasPromotion) { + @if (currentRoute() !== routePricing && hasPromotion()) { % } @@ -116,8 +116,8 @@ i18n mat-button [class]="{ - 'font-weight-bold': currentRoute === routeAbout, - 'text-decoration-underline': currentRoute === routeAbout + 'font-weight-bold': currentRoute() === routeAbout, + 'text-decoration-underline': currentRoute() === routeAbout }" [routerLink]="routerLinkAbout" >About @if ( - hasPermissionForSubscription && user?.subscription?.type === 'Basic' + hasPermissionForSubscription && user()?.subscription?.type === 'Basic' ) { - @if (user.subscription.offer.isRenewal) { + @if (user().subscription.offer.isRenewal) { Renew Plan } @else { Upgrade Plan @@ -199,7 +199,7 @@ >
    } - @if (user?.access?.length > 0) { + @if (user()?.access?.length > 0) { - @for (accessItem of user?.access; track accessItem) { + @for (accessItem of user()?.access; track accessItem) {
  • } - @if (user === null) { -
    + @if (user() === null) { + @@ -349,8 +349,8 @@ i18n mat-button [class]="{ - 'font-weight-bold': currentRoute === routeFeatures, - 'text-decoration-underline': currentRoute === routeFeatures + 'font-weight-bold': currentRoute() === routeFeatures, + 'text-decoration-underline': currentRoute() === routeFeatures }" [routerLink]="routerLinkFeatures" >FeaturesAbout Pricing - @if (currentRoute !== routePricing && hasPromotion) { + @if (currentRoute() !== routePricing && hasPromotion()) { % } @@ -396,8 +396,8 @@ i18n mat-button [class]="{ - 'font-weight-bold': currentRoute === routeMarkets, - 'text-decoration-underline': currentRoute === routeMarkets + 'font-weight-bold': currentRoute() === routeMarkets, + 'text-decoration-underline': currentRoute() === routeMarkets }" [routerLink]="routerLinkMarkets" >MarketsSign in - @if (currentRoute !== 'register' && hasPermissionToCreateUser) { + @if (currentRoute() !== 'register' && hasPermissionToCreateUser) {
  • (); + public readonly deviceType = input.required(); + public readonly hasPermissionToChangeDateRange = input.required(); + public readonly hasPermissionToChangeFilters = input.required(); + public readonly hasPromotion = input.required(); + public readonly hasTabs = input.required(); + public readonly info = input.required(); + public readonly pageTitle = input.required(); + public readonly user = input.required(); public readonly signOut = output(); @@ -174,42 +174,42 @@ export class GfHeaderComponent implements OnChanges { this.hasFilters = this.userService.hasFilters(); this.hasPermissionForAuthGoogle = hasPermission( - this.info?.globalPermissions, + this.info()?.globalPermissions, permissions.enableAuthGoogle ); this.hasPermissionForAuthOidc = hasPermission( - this.info?.globalPermissions, + this.info()?.globalPermissions, permissions.enableAuthOidc ); this.hasPermissionForAuthToken = hasPermission( - this.info?.globalPermissions, + this.info()?.globalPermissions, permissions.enableAuthToken ); this.hasPermissionForSubscription = hasPermission( - this.info?.globalPermissions, + this.info()?.globalPermissions, permissions.enableSubscription ); this.hasPermissionToAccessAdminControl = hasPermission( - this.user?.permissions, + this.user()?.permissions, permissions.accessAdminControl ); this.hasPermissionToAccessAssistant = hasPermission( - this.user?.permissions, + this.user()?.permissions, permissions.accessAssistant ); this.hasPermissionToAccessFearAndGreedIndex = hasPermission( - this.info?.globalPermissions, + this.info()?.globalPermissions, permissions.enableFearAndGreedIndex ); this.hasPermissionToCreateUser = hasPermission( - this.info?.globalPermissions, + this.info()?.globalPermissions, permissions.createUserAccount ); } @@ -269,7 +269,7 @@ export class GfHeaderComponent implements OnChanges { } protected onLogoClick() { - if (['home', 'zen'].includes(this.currentRoute)) { + if (['home', 'zen'].includes(this.currentRoute())) { this.layoutService.getShouldReloadSubject().next(); } }