[ui] disable sign in button in global footer
This commit is contained in:
parent
c3d90d573f
commit
10819fda6d
@ -89,6 +89,7 @@ const defaultEnv: Env = {
|
|||||||
})
|
})
|
||||||
export class StateService {
|
export class StateService {
|
||||||
isBrowser: boolean = isPlatformBrowser(this.platformId);
|
isBrowser: boolean = isPlatformBrowser(this.platformId);
|
||||||
|
isMempoolSpaceBuild = window['isMempoolSpaceBuild'] ?? false;
|
||||||
network = '';
|
network = '';
|
||||||
lightning = false;
|
lightning = false;
|
||||||
blockVSize: number;
|
blockVSize: number;
|
||||||
|
@ -21,12 +21,12 @@
|
|||||||
<div class="selector">
|
<div class="selector">
|
||||||
<app-rate-unit-selector></app-rate-unit-selector>
|
<app-rate-unit-selector></app-rate-unit-selector>
|
||||||
</div>
|
</div>
|
||||||
<a *ngIf="servicesEnabled" class="btn btn-purple sponsor d-none d-sm-flex justify-content-center" [routerLink]="['/login' | relativeUrl]">
|
<a *ngIf="stateService.isMempoolSpaceBuild" class="btn btn-purple sponsor d-none d-sm-flex justify-content-center" [routerLink]="['/login' | relativeUrl]">
|
||||||
<span *ngIf="loggedIn" i18n="shared.my-account">My Account</span>
|
<span *ngIf="loggedIn" i18n="shared.my-account">My Account</span>
|
||||||
<span *ngIf="!loggedIn" i18n="shared.sign-in">Sign In</span>
|
<span *ngIf="!loggedIn" i18n="shared.sign-in">Sign In</span>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<a *ngIf="servicesEnabled" class="btn btn-purple sponsor d-flex d-sm-none justify-content-center ml-auto mr-auto mt-0 mb-2" [routerLink]="['/login' | relativeUrl]">
|
<a *ngIf="stateService.isMempoolSpaceBuild" class="btn btn-purple sponsor d-flex d-sm-none justify-content-center ml-auto mr-auto mt-0 mb-2" [routerLink]="['/login' | relativeUrl]">
|
||||||
<span *ngIf="loggedIn" i18n="shared.my-account">My Account</span>
|
<span *ngIf="loggedIn" i18n="shared.my-account">My Account</span>
|
||||||
<span *ngIf="!loggedIn" i18n="shared.sign-in">Sign In</span>
|
<span *ngIf="!loggedIn" i18n="shared.sign-in">Sign In</span>
|
||||||
</a>
|
</a>
|
||||||
|
@ -30,7 +30,6 @@ export class GlobalFooterComponent implements OnInit {
|
|||||||
loggedIn = false;
|
loggedIn = false;
|
||||||
urlSubscription: Subscription;
|
urlSubscription: Subscription;
|
||||||
isServicesPage = false;
|
isServicesPage = false;
|
||||||
servicesEnabled = false;
|
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
public stateService: StateService,
|
public stateService: StateService,
|
||||||
@ -45,7 +44,6 @@ export class GlobalFooterComponent implements OnInit {
|
|||||||
) {}
|
) {}
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
this.servicesEnabled = this.officialMempoolSpace && this.stateService.env.ACCELERATOR === true && this.stateService.network === '';
|
|
||||||
this.isServicesPage = this.router.url.includes('/services/');
|
this.isServicesPage = this.router.url.includes('/services/');
|
||||||
|
|
||||||
this.env = this.stateService.env;
|
this.env = this.stateService.env;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user