contactlab / contactlab-ui-components

DEPRECATED - Basic UI components for ContactLab UX design pattern library
http://contactlab.github.io/contactlab-pattern-library
Apache License 2.0
30 stars 8 forks source link

Fix `bubbles` property wherever #133

Closed LasaleFamine closed 7 years ago

LasaleFamine commented 7 years ago

We need to fix every dispatchEvent that contains the bubbles property.

Currently we have a situation like:

this.dispatchEvent(new CustomEvent('event-name'), {bubbles: true});

The correct way to pass the bubbles property is instead:

this.dispatchEvent(new CustomEvent('event-name', {bubbles: true, composed: true}));

Ref: EventInit

NOTE: the composed prop is necessary for Shadow-DOM: Handle and fire events