From 802b9dddd0f4c06a59c157db47d03e4c98a2f724 Mon Sep 17 00:00:00 2001 From: Paul Chavard Date: Fri, 29 Apr 2022 20:04:19 +0200 Subject: [PATCH] fix(js): event-target-polyfill should not patch Event --- patches/event-target-polyfill+0.0.3.patch | 24 +++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 patches/event-target-polyfill+0.0.3.patch diff --git a/patches/event-target-polyfill+0.0.3.patch b/patches/event-target-polyfill+0.0.3.patch new file mode 100644 index 000000000..fa987b8ef --- /dev/null +++ b/patches/event-target-polyfill+0.0.3.patch @@ -0,0 +1,24 @@ +diff --git a/node_modules/event-target-polyfill/index.js b/node_modules/event-target-polyfill/index.js +index 82f7f42..c7b65b7 100644 +--- a/node_modules/event-target-polyfill/index.js ++++ b/node_modules/event-target-polyfill/index.js +@@ -12,19 +12,6 @@ function isConstructor(fn) { + return true; + } + +-if (typeof root.Event !== "function" || !isConstructor(root.Event)) { +- root.Event = (function () { +- function Event(type, options) { +- this.bubbles = !!options && !!options.bubbles; +- this.cancelable = !!options && !!options.cancelable; +- this.composed = !!options && !!options.composed; +- this.type = type; +- } +- +- return Event; +- })(); +-} +- + if (typeof root.EventTarget === "undefined" || !isConstructor(root.Event)) { + root.EventTarget = (function () { + function EventTarget() {