Notice: The Monaca & Onsen UI Community Forum is shutting down.

For Onsen UI bug reports, feature requests and questions, please use the Onsen UI GitHub issues page. For help with Monaca, please contact Monaca Support Team.

Thank you to all our community for your contributions to the forum. We look forward to hearing from you in the new communication channels.

Ons Tabbar multiple active on iPhone 8

  • The tabbar is working well on Android, web, iPad and older iPhones. However, on iPhone 8 I discover that when switching to a tab, the previous tab is not deactivated and I see a split screen of both tabs. Pressing the next tab then has 3 active tabs.

    On the postchange I notice that the event.index is the correct one pressed, but getActiveTabIndex() shows the previous tab index.

    Furthermore if I then log all tabbar__items that are active I find them all active.

    activeItems = document.getElementsByClassName(“tabbar__item active”);
    for(i=0; i<activeItems.length; i++){
    console.log(“ACTIVE:” + activeItems[i].getAttribute(‘page’));

    Using Onsen 2.10.8

    I have tried forcing the correct index with setActiveTab in the postchange if the event.index does not match the activeTab - this does not seem to work either (I guess it’s the same function called on click of the tab).

    So far only discovered on iPhone 8

    Any suggestions?

  • @hebbs

    I bypassed the issue for now by adding screen.orientation.lock(“portrait”) for that device type…