mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
test(modal): make sure enableBackdropDismiss works correctly
references #9185
This commit is contained in:
@@ -62,6 +62,10 @@ export class E2EPage {
|
||||
this.platforms = platform.platforms();
|
||||
}
|
||||
|
||||
push() {
|
||||
this.navCtrl.push(E2EPage);
|
||||
}
|
||||
|
||||
presentModal() {
|
||||
let modal = this.modalCtrl.create(ModalPassData, { userId: 8675309 });
|
||||
modal.present();
|
||||
@@ -77,7 +81,9 @@ export class E2EPage {
|
||||
}
|
||||
|
||||
presentModalChildNav() {
|
||||
this.modalCtrl.create(ContactUs).present();
|
||||
this.modalCtrl.create(ContactUs, null, {
|
||||
enableBackdropDismiss: false
|
||||
}).present();
|
||||
}
|
||||
|
||||
presentToolbarModal() {
|
||||
|
||||
@@ -2,6 +2,9 @@
|
||||
|
||||
<ion-navbar>
|
||||
<ion-title>Modals</ion-title>
|
||||
<ion-buttons end>
|
||||
<button ion-button (click)="push()">Push</button>
|
||||
</ion-buttons>
|
||||
</ion-navbar>
|
||||
|
||||
</ion-header>
|
||||
@@ -13,7 +16,10 @@
|
||||
<button ion-button (click)="presentModal()">Present modal, pass params</button>
|
||||
</p>
|
||||
<p>
|
||||
<button ion-button class="e2eOpenModal" (click)="presentModalChildNav()">Present modal w/ child ion-nav</button>
|
||||
<button ion-button class="e2eOpenModal" (click)="presentModalChildNav()">
|
||||
Present modal w/ child ion-nav
|
||||
<span style="font-size:0.5em; text-transform: none"> (enableBackdropDismiss: false)</span>
|
||||
</button>
|
||||
</p>
|
||||
<p>
|
||||
<button ion-button class="e2eOpenToolbarModal" (click)="presentToolbarModal()">Present modal w/ toolbar (and alert)</button>
|
||||
|
||||
Reference in New Issue
Block a user