"aria-current": page === currentPage ? 'step' : undefined
}, Object(external_wp_element_["createElement"])(build_module_button["a" /* default */], {
icon: Object(external_wp_element_["createElement"])(icons_PageControlIcon, {
isSelected: page === currentPage
"aria-label": Object(external_wp_i18n_["sprintf"])(
/* translators: 1: current page number 2: total number of pages */
Object(external_wp_i18n_["__"])('Page %1$d of %2$d'), page + 1, numberOfPages),
onClick: function onClick() {
return setCurrentPage(page);
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/guide/finish-button.js
function FinishButton(props) {
var ref = Object(external_wp_element_["useRef"])(); // Focus the button on mount if nothing else is focused. This prevents a
// focus loss when the 'Next' button is swapped out.
Object(external_wp_element_["useLayoutEffect"])(function () {
var ownerDocument = ref.current.ownerDocument;
var activeElement = ownerDocument.activeElement,
body = ownerDocument.body;
if (!activeElement || activeElement === body) {
return Object(external_wp_element_["createElement"])(build_module_button["a" /* default */], Object(esm_extends["a" /* default */])({}, props, {
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/guide/index.js
var children = _ref.children,
className = _ref.className,
contentLabel = _ref.contentLabel,
finishButtonText = _ref.finishButtonText,
onFinish = _ref.onFinish,
pages = _ref$pages === void 0 ? [] : _ref$pages;
var _useState = Object(external_wp_element_["useState"])(0),
_useState2 = Object(slicedToArray["a" /* default */])(_useState, 2),
currentPage = _useState2[0],
setCurrentPage = _useState2[1];
Object(external_wp_element_["useEffect"])(function () {
if (external_wp_element_["Children"].count(children)) {
external_wp_deprecated_default()('Passing children to <Guide>', {
alternative: 'the `pages` prop'
if (external_wp_element_["Children"].count(children)) {
pages = external_wp_element_["Children"].map(children, function (child) {
var canGoBack = currentPage > 0;
var canGoForward = currentPage < pages.length - 1;
var goBack = function goBack() {
setCurrentPage(currentPage - 1);
var goForward = function goForward() {
setCurrentPage(currentPage + 1);
if (pages.length === 0) {
return Object(external_wp_element_["createElement"])(modal, {
className: classnames_default()('components-guide', className),
contentLabel: contentLabel,
}, Object(external_wp_element_["createElement"])(keyboard_shortcuts, {
}), Object(external_wp_element_["createElement"])("div", {
className: "components-guide__container"
}, Object(external_wp_element_["createElement"])("div", {
className: "components-guide__page"
}, pages[currentPage].image, Object(external_wp_element_["createElement"])(PageControl, {
currentPage: currentPage,
numberOfPages: pages.length,
setCurrentPage: setCurrentPage
}), pages[currentPage].content, !canGoForward && Object(external_wp_element_["createElement"])(FinishButton, {
className: "components-guide__inline-finish-button",
}, finishButtonText || Object(external_wp_i18n_["__"])('Finish'))), Object(external_wp_element_["createElement"])("div", {
className: "components-guide__footer"
}, canGoBack && Object(external_wp_element_["createElement"])(build_module_button["a" /* default */], {
className: "components-guide__back-button",
}, Object(external_wp_i18n_["__"])('Previous')), canGoForward && Object(external_wp_element_["createElement"])(build_module_button["a" /* default */], {
className: "components-guide__forward-button",
}, Object(external_wp_i18n_["__"])('Next')), !canGoForward && Object(external_wp_element_["createElement"])(FinishButton, {
className: "components-guide__finish-button",
}, finishButtonText || Object(external_wp_i18n_["__"])('Finish')))));
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/guide/page.js
function GuidePage(props) {
Object(external_wp_element_["useEffect"])(function () {
external_wp_deprecated_default()('<GuidePage>', {
alternative: 'the `pages` prop in <Guide>'
return Object(external_wp_element_["createElement"])("div", props);
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/button/deprecated.js
function IconButton(_ref, ref) {
var labelPosition = _ref.labelPosition,
props = Object(objectWithoutProperties["a" /* default */])(_ref, ["labelPosition", "size", "tooltip", "label"]);
external_wp_deprecated_default()('wp.components.IconButton', {
alternative: 'wp.components.Button'
return Object(external_wp_element_["createElement"])(build_module_button["a" /* default */], Object(esm_extends["a" /* default */])({}, props, {
tooltipPosition: labelPosition,
showTooltip: tooltip !== undefined ? !!tooltip : undefined,
/* harmony default export */ var deprecated = (Object(external_wp_element_["forwardRef"])(IconButton));
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/menu-group/index.js
function MenuGroup(_ref) {
var children = _ref.children,
_ref$className = _ref.className,
className = _ref$className === void 0 ? '' : _ref$className,
var instanceId = Object(external_wp_compose_["useInstanceId"])(MenuGroup);
if (!external_wp_element_["Children"].count(children)) {
var labelId = "components-menu-group-label-".concat(instanceId);
var classNames = classnames_default()(className, 'components-menu-group');
return Object(external_wp_element_["createElement"])("div", {
}, label && Object(external_wp_element_["createElement"])("div", {
className: "components-menu-group__label",
}, label), Object(external_wp_element_["createElement"])("div", {
"aria-labelledby": label ? labelId : null
/* harmony default export */ var menu_group = (MenuGroup);
// EXTERNAL MODULE: ./node_modules/@wordpress/components/build-module/shortcut/index.js
var build_module_shortcut = __webpack_require__("Cw+6");
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/menu-item/index.js
* Renders a generic menu item for use inside the more menu.
* @param {Object} props Component props.
* @param {WPElement} props.children Element to render as child of button.
* @param {string} props.info Text to use as description for button text.
* @param {string} props.className Class to set on the container.
* @param {WPIcon} props.icon Button's `icon` prop.
* @param {string|Object} props.shortcut Shortcut's `shortcut` prop.
* @param {boolean} props.isSelected Whether or not the menu item is currently selected.
* @param {string} [props.role="menuitem"] ARIA role of the menu item.
* @param {Object} ref React Element ref.
* @return {WPComponent} The component to be rendered.
function MenuItem(_ref, ref) {
var children = _ref.children,
className = _ref.className,
shortcut = _ref.shortcut,
isSelected = _ref.isSelected,
role = _ref$role === void 0 ? 'menuitem' : _ref$role,
props = Object(objectWithoutProperties["a" /* default */])(_ref, ["children", "info", "className", "icon", "shortcut", "isSelected", "role"]);
className = classnames_default()('components-menu-item__button', className);
children = Object(external_wp_element_["createElement"])("span", {
className: "components-menu-item__info-wrapper"
}, Object(external_wp_element_["createElement"])("span", {
className: "components-menu-item__item"
}, children), Object(external_wp_element_["createElement"])("span", {
className: "components-menu-item__info"
if (icon && !Object(external_lodash_["isString"])(icon)) {
icon = Object(external_wp_element_["cloneElement"])(icon, {
className: 'components-menu-items__item-icon'
return Object(external_wp_element_["createElement"])(build_module_button["a" /* default */], Object(esm_extends["a" /* default */])({
ref: ref // Make sure aria-checked matches spec https://www.w3.org/TR/wai-aria-1.1/#aria-checked
"aria-checked": role === 'menuitemcheckbox' || role === 'menuitemradio' ? isSelected : undefined,
}, props), Object(external_wp_element_["createElement"])("span", {
className: "components-menu-item__item"
}, children), Object(external_wp_element_["createElement"])(build_module_shortcut["a" /* default */], {
className: "components-menu-item__shortcut",
}), icon && Object(external_wp_element_["createElement"])(components_build_module_icon["a" /* default */], {
/* harmony default export */ var menu_item = (Object(external_wp_element_["forwardRef"])(MenuItem));
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/menu-items-choice/index.js
function MenuItemsChoice(_ref) {
var _ref$choices = _ref.choices,
choices = _ref$choices === void 0 ? [] : _ref$choices,
_ref$onHover = _ref.onHover,
onHover = _ref$onHover === void 0 ? external_lodash_["noop"] : _ref$onHover,
onSelect = _ref.onSelect,
return choices.map(function (item) {
var isSelected = value === item.value;
return Object(external_wp_element_["createElement"])(menu_item, {
icon: isSelected && check["a" /* default */],
className: "components-menu-items-choice",
onClick: function onClick() {
onMouseEnter: function onMouseEnter() {
return onHover(item.value);
onMouseLeave: function onMouseLeave() {
// EXTERNAL MODULE: ./node_modules/@wordpress/components/build-module/scroll-lock/index.js
var scroll_lock = __webpack_require__("k8OV");
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/navigable-container/tabbable.js
function TabbableContainer(_ref, ref) {
var eventToOffset = _ref.eventToOffset,
props = Object(objectWithoutProperties["a" /* default */])(_ref, ["eventToOffset"]);
var innerEventToOffset = function innerEventToOffset(evt) {
var keyCode = evt.keyCode,
if (external_wp_keycodes_["TAB"] === keyCode) {
return shiftKey ? -1 : 1;
} // Allow custom handling of keys besides Tab.
// By default, TabbableContainer will move focus forward on Tab and
// backward on Shift+Tab. The handler below will be used for all other
// events. The semantics for `eventToOffset`'s return
// values are the following:
// - +1: move focus forward
// - -1: move focus backward
// - 0: don't move focus, but acknowledge event and thus stop it
// - undefined: do nothing, let the event propagate
return eventToOffset(evt);
return Object(external_wp_element_["createElement"])(navigable_container_container, Object(esm_extends["a" /* default */])({
stopNavigationEvents: true,
onlyBrowserTabstops: true,
eventToOffset: innerEventToOffset
/* harmony default export */ var tabbable = (Object(external_wp_element_["forwardRef"])(TabbableContainer));
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/navigation/constants.js
var SEARCH_FOCUS_DELAY = 100;
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/navigation/context.js
var NavigationContext = Object(external_wp_element_["createContext"])({
setActiveMenu: external_lodash_["noop"],
isMenuEmpty: external_lodash_["noop"],
getItem: external_lodash_["noop"],
addItem: external_lodash_["noop"],
removeItem: external_lodash_["noop"],
getMenu: external_lodash_["noop"],
addMenu: external_lodash_["noop"],
removeMenu: external_lodash_["noop"],
traverseMenu: external_lodash_["noop"],
isMenuEmpty: external_lodash_["noop"]
var context_useNavigationContext = function useNavigationContext() {
return Object(external_wp_element_["useContext"])(NavigationContext);
// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/navigation/styles/navigation-styles.js
function navigation_styles_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
var NavigationUI = styled_base_browser_esm("div", {