From: Simon Tang Date: Fri, 25 Oct 2019 11:15:40 +0000 (-0400) Subject: Inject styles into Shadow DOM when inside Shadow DOM (#5763) (#6556) X-Git-Tag: v2.9.0~1^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0b62f28f94633d121ee8c1b9103490025fc819d4;p=thirdparty%2FChart.js.git Inject styles into Shadow DOM when inside Shadow DOM (#5763) (#6556) --- diff --git a/src/platforms/platform.dom.js b/src/platforms/platform.dom.js index 66f956689..03f8486be 100644 --- a/src/platforms/platform.dom.js +++ b/src/platforms/platform.dom.js @@ -294,17 +294,22 @@ function removeResizeListener(node) { } } -function injectCSS(platform, css) { +/** + * Injects CSS styles inline if the styles are not already present. + * @param {HTMLDocument|ShadowRoot} rootNode - the node to contain the