fix back button

This commit is contained in:
Drew Ansbacher
2022-03-07 14:57:44 -07:00
committed by Drew Ansbacher
parent 8a7181a21c
commit 72cb451f5a

View File

@@ -5,6 +5,7 @@ import { Subscription } from 'rxjs'
import { copyToClipboard } from 'src/app/util/web.util'
import {
AlertController,
IonBackButtonDelegate,
IonContent,
ModalController,
NavController,
@@ -31,6 +32,8 @@ export class AppPropertiesPage {
unmasked: { [key: string]: boolean } = {}
running = true
@ViewChild(IonBackButtonDelegate, { static: false })
backButton: IonBackButtonDelegate
@ViewChild(IonContent) content: IonContent
subs: Subscription[] = []
@@ -45,6 +48,12 @@ export class AppPropertiesPage {
private readonly patch: PatchDbService,
) {}
ionViewDidEnter() {
this.backButton.onClick = () => {
history.back()
}
}
async ngOnInit() {
this.pkgId = this.route.snapshot.paramMap.get('pkgId')