Skip to content

Commit

Permalink
fix(modal): fix JavaScript error in IE11 (#2183)
Browse files Browse the repository at this point in the history
We hit babel/babel#7597 with our logic turning `NodeList` to an array,
but turned out it's not needed there.

Fixes #2068. 

Note: merging without reviewing on IE11 because designers are not set up with IE11. Will make an IE11 specific visual pass on all components & website after release.
  • Loading branch information
asudoh authored and shixiedesign committed Mar 22, 2019
1 parent a357196 commit 148c5c8
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/globals/js/mixins/init-component-by-launcher.js
Expand Up @@ -45,9 +45,7 @@ export default function(ToMix) {

if (launcher) {
event.delegateTarget = launcher; // eslint-disable-line no-param-reassign
const elements = [
...launcher.ownerDocument.querySelectorAll(launcher.getAttribute(effectiveOptions.attribInitTarget)),
];
const elements = launcher.ownerDocument.querySelectorAll(launcher.getAttribute(effectiveOptions.attribInitTarget));
if (elements.length > 1) {
throw new Error('Target widget must be unique.');
}
Expand Down

0 comments on commit 148c5c8

Please sign in to comment.