This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
Closed
Description
When there is a nested structure, e.g.
<div ng-click="action()">
<button my-click>mybutton</my-button>
<p>lipsum....</p>
</div>
where my-click
is a directive that have native click binding:
link: function(scope, el, attrs){
el.on('click', function(ev){
//...some other action
// ev.stopPropagation() won't work as ngTouch use event capture
});
}
The native click event won't call when click on the button. The click event is busted. The outer div has raised touchstart
and touchend
and thus busted all internal click event from nested element. You cannot stop the event propagation from button to div as it is capturing mode.