/
githubmirror
/
gutenberg
Обзор
Документация
Войти
/
githubmirror
/
gutenberg
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
trunk
packages/edit-post/src/utils/meta-boxes.js
19 строк
590 B
Renatho De Carli Rosa
Update Eslint JSDoc package, introducing JSDoc line alignment check (#25300)
09 июн 2021, 10:27
Не верифицирован
09 июн 2021, 10:27
a7e2895
Код
Авторство
О чём код?
/** * Function returning the current Meta Boxes DOM Node in the editor * whether the meta box area is opened or not. * If the MetaBox Area is visible returns it, and returns the original container instead. * * @param {string} location Meta Box location. * * @return {string} HTML content. */ export const getMetaBoxContainer = ( location ) => { const area = document.querySelector( `.edit-post-meta-boxes-area.is-${ location } .metabox-location-${ location }` ); if ( area ) { return area; } return document.querySelector( '#metaboxes .metabox-location-' + location ); };