Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Bug] [iOS] [Shell] Multiple PageAppearing/OnAppearing Issues #12055

Closed
DandiAndy opened this issue Sep 8, 2020 · 3 comments
Closed

[Bug] [iOS] [Shell] Multiple PageAppearing/OnAppearing Issues #12055

DandiAndy opened this issue Sep 8, 2020 · 3 comments
Labels
4.8.0 regression on 4.8.0 a/shell 🐚 i/regression in-progress This issue has an associated pull request that may resolve it! p/iOS 🍎 partner/cat 😻 t/bug 🐛

Comments

@DandiAndy
Copy link

Description

After the iOS OnAppearing lifecycle update in 4.8, the OnAppearing of pages in the Shell are called when they should not be. In the examples below the shell is build the following way:

Shell
-> FlyoutItem with FlyoutDisplayOptions="AsMultipleItems"
-----> Multiple Tabs
---------> Multiple ShellContents with Shell.TabBarIsVisible="False"

Each ShellContent has the same type of page that displays where OnAppearing is called from. Note that each page is loaded via ContentTemplate.

Steps to Reproduce

  1. Open the app.
  2. Navigate to another 'Tab 1, Page 2'.
  3. Navigate to 'Tab 2'.
  4. Put the app into the background.
  5. Bring it back to the foreground.

Expected Behavior

  • After Step 1, the app has called OnAppearing for 'Tab 1, Page 1' (and no other pages).
  • After Step 2, the app calls OnAppearing for 'Tab 1, Page 2'.
  • After Step 5, the app only called OnAppearing for the visible page ('Tab 2, Page 1').

Actual Behavior

  • After Step 1, the app has called OnAppearing for all pages under 'Tab 1'.
  • After Step 2, the app doesn't call OnAppearing for 'Tab 1, Page 2'.
  • After Step 5, the app calls OnAppearing for all pages under all previously loaded tabs (both Tab 1 and Tab 2).

Basic Information

  • Version with issue: 4.8.0.1364
  • Last known good version: 4.7
  • IDE: VS for Mac, Visual Studio
  • Platform Target Frameworks:
    • iOS: 13.7
  • Affected Devices: Tested on iPad (7th Generation)

Screenshots

Scenario 1: The App is Started

OnAppearingCalledEarlyAndNotOnNavigation

Note that all OnAppearing are called for the Children of Tab 1 when app starts. Additionally, navigating to one of those tabs loaded on app start doesn't call OnAppearing (until the second time navigating to the page).

Scenario 2: App Returned From Background

OnAppearingCalledForAllPagesAfterBackground

Note that all of the pages from all previously loaded tabs have OnAppearing called.

Reproduction Link

ShellBackgroundingBug.zip

@michaelburch
Copy link

I experienced this issue when using MSAL in a Shell application. OnAppearing was called repeatedly. Updating to 4.8.0.1534 solved it for me

@ErnieScott
Copy link

I can confirm what michaelburch mentioned: Updating to 4.8.0.1534 solved the problem

@jfversluis
Copy link
Member

Multiple reports of a fix. I have #14703 which seems related, in case people find this and think this is still not fixed. Please report there :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
4.8.0 regression on 4.8.0 a/shell 🐚 i/regression in-progress This issue has an associated pull request that may resolve it! p/iOS 🍎 partner/cat 😻 t/bug 🐛
Projects
None yet
Development

No branches or pull requests

6 participants