Why current target
on-tap is different using paper-button
with iron-icons
and paper-button
without iron-icons
?
<dom-module id="button-tap">
<template>
<paper-button on-tap="_getData">without icon</paper-button>
<paper-button on-tap="_getData"><iron-icon="icons:thumb-up"></iron-icon> with icon</paper-button>
</template>
</dom>
The current target
is paper-button
if not using iron-icons
(child element).
How can I get paper-button
as current target
if using a child element?
If you want to access the
paper-button
when its contents are clicked, use theEvent.currentTarget
(instead oftarget
):For example:
codepen