Global footer fixes

This commit is contained in:
softsimon
2023-05-11 11:38:57 -05:00
parent 17dd02ed4e
commit 107746feec
5 changed files with 20 additions and 20 deletions

View File

@@ -20,6 +20,8 @@ export class MasterPageComponent implements OnInit {
urlLanguage: string;
subdomain = '';
networkPaths: { [network: string]: string };
networkPaths$: Observable<Record<string, string>>;
footerVisible = true;
constructor(
public stateService: StateService,
@@ -28,7 +30,7 @@ export class MasterPageComponent implements OnInit {
private navigationService: NavigationService,
) { }
ngOnInit() {
ngOnInit(): void {
this.env = this.stateService.env;
this.connectionState$ = this.stateService.connectionState$;
this.network$ = merge(of(''), this.stateService.networkChanged$);
@@ -36,6 +38,11 @@ export class MasterPageComponent implements OnInit {
this.subdomain = this.enterpriseService.getSubdomain();
this.navigationService.subnetPaths.subscribe((paths) => {
this.networkPaths = paths;
if (paths.mainnet.indexOf('docs') > -1) {
this.footerVisible = false;
} else {
this.footerVisible = true;
}
});
}
@@ -43,7 +50,7 @@ export class MasterPageComponent implements OnInit {
this.navCollapsed = !this.navCollapsed;
}
onResize(event: any) {
onResize(): void {
this.isMobile = window.innerWidth <= 767.98;
}
}