Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tab content become empty when change tabs. Happens only on iOS 14.5 upwards #467

Open
smartsanja2013 opened this issue Aug 4, 2021 · 0 comments

Comments

@smartsanja2013
Copy link

smartsanja2013 commented Aug 4, 2021

I am using ionic2-super-tabs v4.3.1. I have 3 tabs which is used inside a component (It is not for main navigation. Using as a segmented control). I have set a component as the Root.
For the first time page load, tab 0 is selected by default. Content of this tab is visible. When selecting the 2nd tab, the contents become empty. Also, when selecting the 1st tab again, it's content also become empty.
Issue is started to happen suddenly only on iOS v14.5 upwards. All other iOS versions and Android no issue.

ezgif com-gif-maker

Screenshot 2021-08-04 at 2 21 09 PM

Child page module

import { NgModule } from '@angular/core';
import { IonicPageModule } from 'ionic-angular';
import { ChartPage2 } from './chart2';


@NgModule({
  declarations: [
    ChartPage2,
  ],
  providers: [],
  imports: [
    IonicPageModule.forChild(ChartPage2),
  ],
})
export class ChartPageModule {}

Child page

import {Component} from '@angular/core';
import {IonicPage} from 'ionic-angular';

@IonicPage()
@Component({
  selector: 'page-chart2',
  templateUrl: 'chart2.html',
})
export class ChartPage2 {

  constructor(){
    console.log('RootPage init');
  }

  public onEnter(): void {
    console.info('Workaround: Tab1Component -> onEnter. Loaded state:');
    this.initView();
  }

  private initView(): void {
    console.log("Root page InitView")
  }
}

Child page html

<ion-content>
  <div class="taptoretry">
    <div style="font-weight: bold; color:black; font-size:110%; display: inline;color :rgb(70, 69, 69);">There is content in the root component.
    </div>
  </div>
</ion-content>

Anyone else facing similar kind of issue? Please share with me if anyone manage to fix this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant