* @param {!Window} win
(win)
| 919 | * @param {!Window} win |
| 920 | */ |
| 921 | function installRuntimeStylesPromise(win) { |
| 922 | if (win.document.querySelector('style[amp-runtime]')) { |
| 923 | // Already installed. |
| 924 | return; |
| 925 | } |
| 926 | const style = document.createElement('style'); |
| 927 | style.setAttribute('amp-runtime', ''); |
| 928 | style./*OK*/ textContent = ampDocCss + ampSharedCss; |
| 929 | win.document.head.appendChild(style); |
| 930 | } |
| 931 | |
| 932 | /** |
| 933 | * @param {!Window} win |
no test coverage detected