[menu] only show on official mainnet with accelerator enabled
This commit is contained in:
		
							parent
							
								
									d1c9e8b56e
								
							
						
					
					
						commit
						0c1221dc07
					
				@ -1,10 +1,10 @@
 | 
				
			|||||||
<app-menu></app-menu>
 | 
					<app-menu *ngIf="servicesEnabled"></app-menu>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<ng-container *ngIf="{ val: network$ | async } as network">
 | 
					<ng-container *ngIf="{ val: network$ | async } as network">
 | 
				
			||||||
<header *ngIf="headerVisible" style="position: fixed; width: 100%; z-index: 100;">
 | 
					<header *ngIf="headerVisible" style="position: fixed; width: 100%; z-index: 100;">
 | 
				
			||||||
  <nav class="navbar navbar-expand-md navbar-dark bg-dark">
 | 
					  <nav class="navbar navbar-expand-md navbar-dark bg-dark">
 | 
				
			||||||
  <!-- Hamburger -->
 | 
					  <!-- Hamburger -->
 | 
				
			||||||
  <div class="profile_image_container" (click)="hamburgerClick()">
 | 
					  <div *ngIf="servicesEnabled" class="profile_image_container" (click)="hamburgerClick()">
 | 
				
			||||||
    <img *ngIf="userAuth" [src]="'/api/v1/services/account/image/' + userAuth.user.username" class="profile_image">
 | 
					    <img *ngIf="userAuth" [src]="'/api/v1/services/account/image/' + userAuth.user.username" class="profile_image">
 | 
				
			||||||
    <app-svg-images *ngIf="!userAuth" name="hamburger" height=40></app-svg-images>
 | 
					    <app-svg-images *ngIf="!userAuth" name="hamburger" height=40></app-svg-images>
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
				
			|||||||
@ -27,6 +27,7 @@ export class MasterPageComponent implements OnInit {
 | 
				
			|||||||
  networkPaths$: Observable<Record<string, string>>;
 | 
					  networkPaths$: Observable<Record<string, string>>;
 | 
				
			||||||
  footerVisible = true;
 | 
					  footerVisible = true;
 | 
				
			||||||
  userAuth: any | undefined;
 | 
					  userAuth: any | undefined;
 | 
				
			||||||
 | 
					  servicesEnabled = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  @ViewChild(MenuComponent)
 | 
					  @ViewChild(MenuComponent)
 | 
				
			||||||
  private menuComponent!: MenuComponent;
 | 
					  private menuComponent!: MenuComponent;
 | 
				
			||||||
@ -57,6 +58,7 @@ export class MasterPageComponent implements OnInit {
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
 | 
					    this.servicesEnabled = this.officialMempoolSpace && this.stateService.env.ACCELERATOR === true && this.stateService.network === '';
 | 
				
			||||||
    this.userAuth = JSON.parse(localStorage.getItem('auth') || '') ?? null;
 | 
					    this.userAuth = JSON.parse(localStorage.getItem('auth') || '') ?? null;
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user