Fix menu height
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good

This commit is contained in:
Willem Dantuma 2020-01-08 17:46:52 +01:00
parent 71e7467c17
commit 40429a67ef

View File

@ -33,13 +33,14 @@ export class SidePanelComponent implements OnChanges {
} }
setTop() { setTop() {
this.mobile = this.checkMobile() && ! this.left; this.mobile = this.left?false: this.checkMobile();
this.resizeTop = this.mobile?50:0; this.resizeTop = this.mobile?50:0;
this.top = (this.visible?this.resizeTop: (this.mobile? 100:0)) + "%"; this.top = (this.visible?this.resizeTop: (this.mobile? 100:0)) + "%";
} }
ngAfterViewInit() { ngAfterViewInit() {
this.parentHeight = this.element.nativeElement.offsetParent.clientHeight; this.parentHeight = this.element.nativeElement.offsetParent.clientHeight;
this.setTop();
} }
handleToggleClick(event) { handleToggleClick(event) {