Alert, Confirm, Loading etc is dark, overlap by overlay

Whay my component like Alert, Confirm, Loading, look overlap by overlay is dark in android device, in web is good.?

provide a piece of code where you are performing Alert, confirm, etc.
so that developers can help you…

ok, sorry, this is my code

logout() {;
        this.nunic.confirm('Yakin nih', () => {
            this.nunic.showLoading('Mohon tunggu', this.nav);
                resp => {
                    if (resp.status == true) {
                        // this.rootPage = LoginPage;
                }, error => {
        }, () => {
//            console.log('Tidak');
}, this.nav);


import { Injectable } from ‘@angular/core’;
import { Toast, Loading, App, Alert } from ‘ionic-angular’;

export class Nunic {
loading: any;
nav: any;

constructor(private app: App) {
    this.nav =;
toast(txt: string, nav: any = null) {
    let toast = Toast.create({
        message: txt + '...',
        duration: 3000,
        position: 'bottom'
    if (nav != null) {
    } else {
showLoading(txt: string, nav: any = null) {
    this.loading = Loading.create({
        content: txt,
        //spinner: 'dots'
    if (nav != null) {
    } else {
hideLoading() {
confirm(txt: string, okCallback: () => void, noCallback: () => void, nav: any = null) {
    //        console.log(this.nav);
    //        console.log(nav);
    let confirm = Alert.create({
        title: 'Konfirmasi',
        message: txt + ' ?',
        buttons: [
                text: 'Ya',
                handler: () => {
                text: 'Tidak',
                handler: () => {
    if (nav != null) {
    } else {


I think you have to put this.nunic.showLoading('Mohon tunggu', this.nav); this line after the;

the loading only show if Yes button clicked in confim, its impossible place it after close menu.

then you have to handle such thing in confirm’s ok button handler… i.e. when to show loading and when to not…

and if you are doing setRoot from alert then you have to first remove alert from stack then use setRoot

here is sample code

logOut() {
    let alert = Alert.create({
        title: 'Alert',
        subTitle: 'You want to logout',
        buttons: [{
            text: 'Ok',
            handler: () => {
                // 'this.nav.remove', removes the 'Alert' from the stack
                // and then 'this.nav.setRoot' to change the rootPage
                this.nav.remove().then(() => {
                    this.nav.setRoot(LoginPage, {}, {animate: true, direction: 'back'});

EDIT: from beta 11 update of ionic 2. There is no need to remove alert from navigation stack, because from beta 11 every overlay components having its own controller…

No effects guys, please see below picture :

In Web, OK

In Android Device, not ok :confused:

Don’t know about this behaviour… this does not happen with me.

below link may help you in a case of Loading component…

This could get fixed if you use Ionic 2 pre beta 11 ("ionic-angular": "nightly") and use the new controllers for them.

An example on how to upgrade your beta.10 to nightly and the new controllers:

Thanks for your help, i have not solved my problem :grin:

This my ionic info, should i update ?


That’s the version of your Ionic CLI, not your Ionic 2 project.

This is my ionic info from my project’s folder:

Cordova CLI: 6.2.0
Gulp version:  CLI version 3.9.1
Gulp local:   Local version 3.9.1
Ionic Framework Version: 2.0.0-beta.10-201607151701
Ionic CLI Version: 2.0.0-beta.32
Ionic App Lib Version: 2.0.0-beta.18
OS: Distributor ID:     Ubuntu Description:     Ubuntu 16.04.1 LTS 
Node Version: v5.12.0

Note the Ionic Framework Version: 2.0.0-beta.10-201607151701, that’s the version used by the project, specified on the package.json, which installs everything when you execute

npm install

This is my ionic info

The problem not resolved yet. And last night i have tried to other phone, the backdrop is normal, the loading or alert is works well, is issue about android version ? My Android is Jelly Bean.

I resolved the problem with install croswalk, maybe my android web view render not properly.