UNPKG

@wordpress/edit-post

Version:
27 lines (22 loc) 829 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getMetaBoxContainer = void 0; /** * 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. */ var getMetaBoxContainer = function getMetaBoxContainer(location) { var area = document.querySelector(".edit-post-meta-boxes-area.is-".concat(location, " .metabox-location-").concat(location)); if (area) { return area; } return document.querySelector('#metaboxes .metabox-location-' + location); }; exports.getMetaBoxContainer = getMetaBoxContainer; //# sourceMappingURL=meta-boxes.js.map