From 0f7e4ed0f30e9dfbde129b5f3ae648a15946bcf5 Mon Sep 17 00:00:00 2001 From: Douglas Machado Date: Mon, 7 Nov 2022 22:48:02 -0300 Subject: [PATCH] fix(ios): tab page navigation when showing dialog messages (#10075) --- packages/core/ui/frame/index.ios.ts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/core/ui/frame/index.ios.ts b/packages/core/ui/frame/index.ios.ts index f18636e6d..7e8d59c58 100644 --- a/packages/core/ui/frame/index.ios.ts +++ b/packages/core/ui/frame/index.ios.ts @@ -118,7 +118,7 @@ export class Frame extends FrameBase { if (!this._currentEntry) { // Update action-bar with disabled animations before the initial navigation. this._updateActionBar(backstackEntry.resolvedPage, true); - this._ios.controller.pushViewControllerAnimated(viewController, animated); + this.pushViewControllerAnimated(viewController, animated); if (Trace.isEnabled()) { Trace.write(`${this}.pushViewControllerAnimated(${viewController}, ${animated}); depth = ${navDepth}`, Trace.categories.Navigation); } @@ -180,6 +180,17 @@ export class Frame extends FrameBase { } } + private pushViewControllerAnimated(viewController: UIViewController, animated: boolean) { + let transitionCoordinator = this._ios.controller.transitionCoordinator; + if (transitionCoordinator) { + transitionCoordinator.animateAlongsideTransitionCompletion(null, () => { + this._ios.controller.pushViewControllerAnimated(viewController, animated); + }); + } else { + this._ios.controller.pushViewControllerAnimated(viewController, animated); + } + } + public _goBackCore(backstackEntry: BackstackEntry) { super._goBackCore(backstackEntry); navDepth = backstackEntry[NAV_DEPTH];