diff --git a/CHANGELOG.md b/CHANGELOG.md index b6fa31743a..2e94e4a647 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,12 @@ +## [4.10.2](https://github.com/ionic-team/ionic/compare/v4.10.1...v4.10.2) (2019-10-08) + + +### Bug Fixes + +* **overlay:** ensure lifecycle events fire properly ([#19579](https://github.com/ionic-team/ionic/issues/19579)) ([a7b9642](https://github.com/ionic-team/ionic/commit/a7b9642)), closes [#19576](https://github.com/ionic-team/ionic/issues/19576) + + + ## [4.10.1](https://github.com/ionic-team/ionic/compare/v4.10.0...v4.10.1) (2019-10-07) diff --git a/angular/package.json b/angular/package.json index 07e8c01668..c261e07b6b 100644 --- a/angular/package.json +++ b/angular/package.json @@ -1,6 +1,6 @@ { "name": "@ionic/angular", - "version": "4.10.1", + "version": "4.10.2", "description": "Angular specific wrappers for @ionic/core", "keywords": [ "ionic", @@ -49,7 +49,7 @@ "css/" ], "dependencies": { - "@ionic/core": "4.10.1", + "@ionic/core": "4.10.2", "tslib": "^1.9.3" }, "peerDependencies": { diff --git a/core/package.json b/core/package.json index 89b47ea11b..8b6ae49f02 100644 --- a/core/package.json +++ b/core/package.json @@ -1,6 +1,6 @@ { "name": "@ionic/core", - "version": "4.10.1", + "version": "4.10.2", "description": "Base components for Ionic", "keywords": [ "ionic", diff --git a/core/src/components/modal/test/test.utils.ts b/core/src/components/modal/test/test.utils.ts index ab2d346c95..b336afc5c9 100644 --- a/core/src/components/modal/test/test.utils.ts +++ b/core/src/components/modal/test/test.utils.ts @@ -14,8 +14,16 @@ export const testModal = async ( }); const screenshotCompares = []; + const ionModalWillPresent = await page.spyOnEvent('ionModalWillPresent'); + const ionModalDidPresent = await page.spyOnEvent('ionModalDidPresent'); + const ionModalWillDismiss = await page.spyOnEvent('ionModalWillDismiss'); + const ionModalDidDismiss = await page.spyOnEvent('ionModalDidDismiss'); await page.click(selector); + + await ionModalWillPresent.next(); + await ionModalDidPresent.next(); + await page.waitForSelector(selector); let modal = await page.find('ion-modal'); @@ -25,6 +33,10 @@ export const testModal = async ( screenshotCompares.push(await page.compareScreenshot()); await modal.callMethod('dismiss'); + + await ionModalWillDismiss.next(); + await ionModalDidDismiss.next(); + await modal.waitForNotVisible(); screenshotCompares.push(await page.compareScreenshot('dismiss')); diff --git a/core/src/utils/overlays.ts b/core/src/utils/overlays.ts index 079e0c1686..b5d52d2cc6 100644 --- a/core/src/utils/overlays.ts +++ b/core/src/utils/overlays.ts @@ -221,7 +221,7 @@ const overlayAnimation = async ( /** * TODO: Remove AnimationBuilder */ - const hasCompleted = (typeof animationResult as any === 'boolean') ? animationResult : (animation as any).hasCompleted; + const hasCompleted = (typeof animationResult as any === 'undefined') ? true : (animation as any).hasCompleted; if (isAnimationBuilder) { animation.destroy(); } diff --git a/docs/package.json b/docs/package.json index 4291fbb5bf..8da9162af6 100644 --- a/docs/package.json +++ b/docs/package.json @@ -1,6 +1,6 @@ { "name": "@ionic/docs", - "version": "4.10.1", + "version": "4.10.2", "description": "Pre-packaged API documentation for the Ionic docs.", "main": "core.json", "files": [