Skip to content

Commit 3119679

Browse files
mleokingmlynch
authored andcommitted
Let tapIgnoreEvent check data-tap-disabled.
This fix enables the data-tap-disabled tag to completely bypass tap handling for designated elements. This is a bug fix for #2132 http://forum.ionicframework.com/t/ionic-tap-event-conflicting-with-d3-event/7369 http://stackoverflow.com/questions/30113156/d3-zoom-in-ionic and more. Without this fix, the tap event handling of ionic conflicts with d3 and many other js libs.
1 parent 27fc24e commit 3119679

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Diff for: js/utils/tap.js

+4
Original file line numberDiff line numberDiff line change
@@ -472,6 +472,10 @@ function tapEnableTouchEvents() {
472472
function tapIgnoreEvent(e) {
473473
if (e.isTapHandled) return true;
474474
e.isTapHandled = true;
475+
476+
if(ionic.tap.isElementTapDisabled(e.target)){
477+
return true;
478+
}
475479

476480
if (ionic.scroll.isScrolling && ionic.tap.containsOrIsTextInput(e.target)) {
477481
e.preventDefault();

0 commit comments

Comments
 (0)