parent
c71e2d4c48
commit
e4bb1d8947
@ -53,6 +53,9 @@ export class DownloadAppDirective implements OnInit {
|
|||||||
console.log(e);
|
console.log(e);
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
this.deferredPrompt = e;
|
this.deferredPrompt = e;
|
||||||
|
if (this.deferredPrompt) {
|
||||||
|
this.el.nativeElement.style.display = 'block';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@HostListener('window:appinstalled', ['$event'])
|
@HostListener('window:appinstalled', ['$event'])
|
||||||
@ -62,9 +65,6 @@ export class DownloadAppDirective implements OnInit {
|
|||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
// Stash the event so it can be triggered later.
|
// Stash the event so it can be triggered later.
|
||||||
this.deferredPrompt = e;
|
this.deferredPrompt = e;
|
||||||
if (this.deferredPrompt) {
|
|
||||||
this.el.nativeElement.style.display = 'block';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user