/
githubmirror
/
amphtml
Обзор
Документация
Войти
/
githubmirror
/
amphtml
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/builtins/amp-layout/amp-layout.js
31 строка
703 B
Jake Fried
Remove @nocollapse annotation which was closure-specific. (#37630)
10 фев 2022, 19:58
Не верифицирован
10 фев 2022, 19:58
058ef73
Код
Авторство
О чём код?
import {Layout_Enum, isLayoutSizeDefined} from '#core/dom/layout'; import {registerElement} from '#service/custom-element-registry'; import {buildDom} from './build-dom'; import {BaseElement} from '../../base-element'; export class AmpLayout extends BaseElement { /** @override */ static prerenderAllowed() { return true; } /** @override */ isLayoutSupported(layout) { return layout == Layout_Enum.CONTAINER || isLayoutSizeDefined(layout); } /** @override */ buildCallback() { buildDom(this.element); } } /** * @param {!Window} win Destination window for the new element. */ export function installLayout(win) { registerElement(win, 'amp-layout', AmpLayout); }