Add device service migrate, use back-button
Some checks failed
FarmMaps.Develop/FarmMapsLib/pipeline/head There was a failure building this commit

This commit is contained in:
Willem Dantuma
2021-01-27 08:11:37 +01:00
parent 3e14157e87
commit dda82c8b09
15 changed files with 43 additions and 25 deletions

View File

@@ -1,4 +1,4 @@
<div class="back-button mb-2">
<div *ngIf="show()" class="back-button mb-2">
<i class="fal fa-arrow-left"></i>&nbsp;<span i18n="@FmBackButton">Back</span>
</div>

View File

@@ -1,5 +1,6 @@
import {Component, HostListener} from '@angular/core';
import {Location} from "@angular/common";
import { DeviceService} from '../../services/device.service';
@Component({
selector: 'fm-back-button',
@@ -13,6 +14,10 @@ export class BackButtonComponent {
this.location.back();
}
constructor(private location: Location) { }
constructor(private location: Location,private deviceService:DeviceService) { }
public show() {
return !this.deviceService.IsMobile();
}
}