Ionic-framework: touch / click problem right after modals/popovers hide/close

Created on 25 Feb 2016  路  19Comments  路  Source: ionic-team/ionic-framework

Short description of the problem:

after closing or hiding popover or modal there is some ms that touch events not working
and this issue force ppl double click the screen else need wait some ms i dont know how much but close to 1sec

Ionic Version: 1.2.4 , ... , 1.3.1

Browser & Operating System: Android / Chrome
(ios not tested)

Most helpful comment

Ok i ve just run your code pen and i m having the same problem, i would really like the ionic team to fix it because it could really be annoying when using an app that the current modal closes itself for no reason after an alert/popup closes.

All 19 comments

I have experienced a similar problem on ios 9 (Safari) and ionic v2. After each page transition (even menu opening/closing) it takes 1-2 seconds till a click-event on a button can be triggered.

On android 5.x everything seems to be fine.

here the problem accure only with modals/popovers

Thanks for opening this issue! Would you mind giving us a code sample or codepen so that we could easily repro this issue? Also if you dont mind could you run ionic info and past the output here? Thanks again!

I've opened a new issue for my problem (https://github.com/driftyco/ionic/issues/5838), as this here is adressed to v1.

Hello! Thanks for opening an issue with us! Since it has been a little while since there was any activity on this issue i will be closing it, but feel free to respond back if your still having the issue! Thanks again!

an easy way to fix issue to close it

Hello @emps Im happy to reopen this issue (: It was closed due to there being no activity on the issue for a specific amount of time from the original poster. @agrt56 commented but just to let us know he opened another issue as this one was related to v1. Would you be able to provide a codepen or plunkr so that we can use it to repro this issue? Thanks!

yes i will make tomorrow morning codepen thanks

Hello (: Have you gotten a chance to make that codepen yet?

hii well i wanted to build an example right now but i see there is already one built
http://codepen.io/ionic/pen/GpCst
so the problem is there when u click on the more icon u get popover open and then press at backdrop to close it and imidiatly click on other tab u will see u will see click not working first 1sec as popover get close/hide same with modals

and its not tabs problem its any button or any element u will add there u cant click first 1sec after popover/modal get closed. its a big problem imo ppl cant wait they like touch screen

Want to add this only happens for me when I click back in the top left corner. If I swipe back, it's not a problem. Anyone else notice this behaviour as well?

this problem can be fixed if the backdrop will removed from the dom with no delay cause the first click is fired on the backdrop div

I have the same problem too, its still here in ionic 1.3.1
(a codepen to test with the last versions : http://codepen.io/anon/pen/KrxRXx )
Does anyone has a quickfix for this ?

It look like this commit was almost resolving the bug.

in my opinion the popup closes, then check the highest modal in the modalStack variable,
since the popup is closed, the highest modal is ... ...the parentModal, then the .remove() is applied on it. (not sure about that)

Ok i ve just run your code pen and i m having the same problem, i would really like the ionic team to fix it because it could really be annoying when using an app that the current modal closes itself for no reason after an alert/popup closes.

This issue was moved to driftyco/ionic-v1#198

I had similar problem in my ionic 2 application. I solved it by using "this.navCtrl.pop()" to close the modal insted of using "dismiss()" function.

Note: Do not use "this.setRoot()" function right after closing the modal

"devDependencies": { "@angular/tsc-wrapped": "^4.4.0-RC.0", "@ionic/app-scripts": "^2.1.3", "@ionic/cli-build-ionic-angular": "0.0.4", "@ionic/cli-plugin-ionic-angular": "1.4.1", "ionic": "3.12.0", "typescript": "2.3.4" },

Same issue with ionic 3.12 if you are using (tap)="methode()' instead of (click)="methode()"

tap on button will close the popover but click works fine

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Nick-The-Uncharted picture Nick-The-Uncharted  路  3Comments

danbucholtz picture danbucholtz  路  3Comments

MrBokeh picture MrBokeh  路  3Comments

RobFerguson picture RobFerguson  路  3Comments

giammaleoni picture giammaleoni  路  3Comments