File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -152,17 +152,21 @@ export class LionButton extends DelegateMixin(SlotMixin(LionLitElement)) {
152152 this . __teardownDelegation ( ) ;
153153 }
154154
155- /**
156- * Prevent click on the fake element and cause click on the native button.
157- */
158- __clickDelegationHandler ( oldEvent ) {
159- oldEvent . stopPropagation ( ) ;
155+ _redispatchClickEvent ( oldEvent ) {
160156 // replacing `MouseEvent` with `oldEvent.constructor` breaks IE
161157 const newEvent = new MouseEvent ( oldEvent . type , oldEvent ) ;
162158 this . __enforceHostEventTarget ( newEvent ) ;
163159 this . $$slot ( '_button' ) . dispatchEvent ( newEvent ) ;
164160 }
165161
162+ /**
163+ * Prevent click on the fake element and cause click on the native button.
164+ */
165+ __clickDelegationHandler ( e ) {
166+ e . stopPropagation ( ) ;
167+ this . _redispatchClickEvent ( e ) ;
168+ }
169+
166170 __enforceHostEventTarget ( event ) {
167171 try {
168172 // this is for IE11 (and works in others), because `Object.defineProperty` does not give any effect there
You can’t perform that action at this time.
0 commit comments