Skip to content

Commit

Permalink
fix(utils.dom): fix utils.dom error
Browse files Browse the repository at this point in the history
In IE browser, If the reference element(slot="reference") under the popover component is a SVG element, an error will be reported.

[#21048](#21048)
  • Loading branch information
fw6 committed Jun 7, 2021
1 parent 29268a3 commit 4003da7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/dom.js
Expand Up @@ -91,7 +91,7 @@ export function addClass(el, cls) {
}
}
if (!el.classList) {
el.className = curClass;
el.setAttribute('class', curClass);
}
};

Expand All @@ -112,7 +112,7 @@ export function removeClass(el, cls) {
}
}
if (!el.classList) {
el.className = trim(curClass);
el.setAttribute('class', trim(curClass));
}
};

Expand Down

0 comments on commit 4003da7

Please sign in to comment.