diff --git a/externs/webcomponents-externs.js b/externs/webcomponents-externs.js index ae141b4a90..9698b01b79 100644 --- a/externs/webcomponents-externs.js +++ b/externs/webcomponents-externs.js @@ -12,42 +12,48 @@ */ /* eslint-disable */ -var HTMLImports = { - /** - * @param {function()} callback - */ - whenReady(callback) {}, - /** - * @param {!Node} element - * @return {?HTMLLinkElement|?Document|undefined} - */ - importForElement(element) {} -}; +var HTMLImports = {}; + +/** + * @param {function()} callback + */ +HTMLImports.whenReady = function(callback) {}; + +/** + * @param {!Node} element + * @return {?HTMLLinkElement|?Document|undefined} + */ +HTMLImports.importForElement = function(element) {}; window.HTMLImports = HTMLImports; -var ShadyDOM = { - inUse: false, - flush() {}, - /** - * @param {!Node} target - * @param {function(Array, MutationObserver)} callback - * @return {MutationObserver} - */ - observeChildren(target, callback) {}, - /** - * @param {MutationObserver} observer - */ - unobserveChildren(observer) {}, - /** - * @param {Node} node - */ - patch(node) {}, - /** - * @param {!ShadowRoot} shadowroot - */ - flushInitial(shadowroot) {} -}; +var ShadyDOM = {}; + +ShadyDOM.inUse; + +ShadyDOM.flush = function() {}; + +/** + * @param {!Node} target + * @param {function(Array, MutationObserver)} callback + * @return {MutationObserver} + */ +ShadyDOM.observeChildren = function(target, callback) {}; + +/** + * @param {MutationObserver} observer + */ +ShadyDOM.unobserveChildren = function(observer) {}; + +/** + * @param {Node} node + */ +ShadyDOM.patch = function(node) {}; + +/** + * @param {!ShadowRoot} shadowroot + */ +ShadyDOM.flushInitial = function(shadowroot) {}; window.ShadyDOM = ShadyDOM; @@ -70,4 +76,4 @@ CustomElementRegistry.prototype.polyfillWrapFlushCallback = function(cb){}; /** * @param {string} cssText */ -CSSStyleSheet.prototype.replaceSync = function(cssText) {}; \ No newline at end of file +CSSStyleSheet.prototype.replaceSync = function(cssText) {};