* My Document Setting Panel
*
* );
*
* registerPlugin( 'document-setting-test', { render: MyDocumentSettingTest } );
* ```
*
* @return {WPElement} The WPElement to be rendered.
*/
var PluginDocumentSettingPanel = Object(external_this_wp_compose_["compose"])(Object(external_this_wp_plugins_["withPluginContext"])(function (context, ownProps) {
return {
icon: ownProps.icon || context.icon,
panelName: "".concat(context.name, "/").concat(ownProps.name)
};
}), Object(external_this_wp_data_["withSelect"])(function (select, _ref2) {
var panelName = _ref2.panelName;
return {
opened: select('core/edit-post').isEditorPanelOpened(panelName),
isEnabled: select('core/edit-post').isEditorPanelEnabled(panelName)
};
}), Object(external_this_wp_data_["withDispatch"])(function (dispatch, _ref3) {
var panelName = _ref3.panelName;
return {
onToggle: function onToggle() {
return dispatch('core/edit-post').toggleEditorPanelOpened(panelName);
}
};
}))(plugin_document_setting_panel_PluginDocumentSettingFill);
PluginDocumentSettingPanel.Slot = plugin_document_setting_panel_Slot;
/* harmony default export */ var plugin_document_setting_panel = (PluginDocumentSettingPanel);
// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/components/sidebar/settings-sidebar/index.js
/**
* WordPress dependencies
*/
/**
* Internal dependencies
*/
var settings_sidebar_SettingsSidebar = function SettingsSidebar(_ref) {
var sidebarName = _ref.sidebarName;
return Object(external_this_wp_element_["createElement"])(sidebar, {
name: sidebarName,
label: Object(external_this_wp_i18n_["__"])('Editor settings')
}, Object(external_this_wp_element_["createElement"])(settings_header, {
sidebarName: sidebarName
}), Object(external_this_wp_element_["createElement"])(external_this_wp_components_["Panel"], null, sidebarName === 'edit-post/document' && Object(external_this_wp_element_["createElement"])(external_this_wp_element_["Fragment"], null, Object(external_this_wp_element_["createElement"])(post_status, null), Object(external_this_wp_element_["createElement"])(plugin_document_setting_panel.Slot, null), Object(external_this_wp_element_["createElement"])(last_revision, null), Object(external_this_wp_element_["createElement"])(post_link, null), Object(external_this_wp_element_["createElement"])(post_taxonomies, null), Object(external_this_wp_element_["createElement"])(featured_image, null), Object(external_this_wp_element_["createElement"])(post_excerpt, null), Object(external_this_wp_element_["createElement"])(discussion_panel, null), Object(external_this_wp_element_["createElement"])(page_attributes, null), Object(external_this_wp_element_["createElement"])(meta_boxes, {
location: "side"
})), sidebarName === 'edit-post/block' && Object(external_this_wp_element_["createElement"])(external_this_wp_components_["PanelBody"], {
className: "edit-post-settings-sidebar__panel-block"
}, Object(external_this_wp_element_["createElement"])(external_this_wp_blockEditor_["BlockInspector"], null))));
};
/* harmony default export */ var settings_sidebar = (Object(external_this_wp_compose_["compose"])(Object(external_this_wp_data_["withSelect"])(function (select) {
var _select = select('core/edit-post'),
getActiveGeneralSidebarName = _select.getActiveGeneralSidebarName,
isEditorSidebarOpened = _select.isEditorSidebarOpened;
return {
isEditorSidebarOpened: isEditorSidebarOpened(),
sidebarName: getActiveGeneralSidebarName()
};
}), Object(external_this_wp_compose_["ifCondition"])(function (_ref2) {
var isEditorSidebarOpened = _ref2.isEditorSidebarOpened;
return isEditorSidebarOpened;
}))(settings_sidebar_SettingsSidebar));
// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/components/sidebar/plugin-post-publish-panel/index.js
/**
* WordPress dependencies
*/
var plugin_post_publish_panel_createSlotFill = Object(external_this_wp_components_["createSlotFill"])('PluginPostPublishPanel'),
plugin_post_publish_panel_Fill = plugin_post_publish_panel_createSlotFill.Fill,
plugin_post_publish_panel_Slot = plugin_post_publish_panel_createSlotFill.Slot;
var plugin_post_publish_panel_PluginPostPublishPanelFill = function PluginPostPublishPanelFill(_ref) {
var children = _ref.children,
className = _ref.className,
title = _ref.title,
_ref$initialOpen = _ref.initialOpen,
initialOpen = _ref$initialOpen === void 0 ? false : _ref$initialOpen,
icon = _ref.icon;
return Object(external_this_wp_element_["createElement"])(plugin_post_publish_panel_Fill, null, Object(external_this_wp_element_["createElement"])(external_this_wp_components_["PanelBody"], {
className: className,
initialOpen: initialOpen || !title,
title: title,
icon: icon
}, children));
};
/**
* Renders provided content to the post-publish panel in the publish flow
* (side panel that opens after a user publishes the post).
*
* @param {Object} props Component properties.
* @param {string} [props.className] An optional class name added to the panel.
* @param {string} [props.title] Title displayed at the top of the panel.
* @param {boolean} [props.initialOpen=false] Whether to have the panel initially opened. When no title is provided it is always opened.
* @param {string|Element} [props.icon=inherits from the plugin] The [Dashicon](https://developer.wordpress.org/resource/dashicons/) icon slug string, or an SVG WP element, to be rendered when the sidebar is pinned to toolbar.
*
* @example