diff --git a/lib/utils/settings.js b/lib/utils/settings.js index f67f55fe97..7b858c2284 100644 --- a/lib/utils/settings.js +++ b/lib/utils/settings.js @@ -338,4 +338,22 @@ export let legacyNoObservedAttributes = */ export const setLegacyNoObservedAttributes = function(noObservedAttributes) { legacyNoObservedAttributes = noObservedAttributes; -}; \ No newline at end of file +}; + +/** + * Setting to enable use of `adoptedStyleSheets` for sharing style sheets + * between component instances' shadow roots, if the app uses built Shady CSS + * styles. + */ +export let shareBuiltCSSWithAdoptedStyleSheets = + window.Polymer && window.Polymer.shareBuiltCSSWithAdoptedStyleSheets || false; + +/** + * Sets `shareBuiltCSSWithAdoptedStyleSheets` globally. + * + * @param {boolean} newValue enable or disable `shareBuiltCSSWithAdoptedStyleSheets` + * @return {void} + */ +export const setShareBuiltCSSWithAdoptedStyleSheets = function(value) { + shareBuiltCSSWithAdoptedStyleSheets = value; +};