%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /home/dordingu/public_html/hardkjarni/wp-content/plugins/gutenberg/build/edit-navigation/
Upload File :
Create Path :
Current File : /home/dordingu/public_html/hardkjarni/wp-content/plugins/gutenberg/build/edit-navigation/index.min.js.map

{"version":3,"file":"./build/edit-navigation/index.min.js","mappings":"0BAAA,OAOC,WACA,aAEA,IAAIA,EAAS,CAAC,EAAEC,eAEhB,SAASC,IAGR,IAFA,IAAIC,EAAU,GAELC,EAAI,EAAGA,EAAIC,UAAUC,OAAQF,IAAK,CAC1C,IAAIG,EAAMF,UAAUD,GACpB,GAAKG,EAAL,CAEA,IAAIC,SAAiBD,EAErB,GAAgB,WAAZC,GAAoC,WAAZA,EAC3BL,EAAQM,KAAKF,QACP,GAAIG,MAAMC,QAAQJ,IACxB,GAAIA,EAAID,OAAQ,CACf,IAAIM,EAAQV,EAAWW,MAAM,KAAMN,GAC/BK,GACHT,EAAQM,KAAKG,EAEf,OACM,GAAgB,WAAZJ,EACV,GAAID,EAAIO,WAAaC,OAAOC,UAAUF,SACrC,IAAK,IAAIG,KAAOV,EACXP,EAAOkB,KAAKX,EAAKU,IAAQV,EAAIU,IAChCd,EAAQM,KAAKQ,QAIfd,EAAQM,KAAKF,EAAIO,WArBD,CAwBnB,CAEA,OAAOX,EAAQgB,KAAK,IACrB,CAEqCC,EAAOC,SAC3CnB,EAAWoB,QAAUpB,EACrBkB,EAAOC,QAAUnB,QAKhB,KAFwB,EAAF,WACtB,OAAOA,CACP,UAFoB,OAEpB,YAIH,CAlDA,E,GCNIqB,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaL,QAGrB,IAAID,EAASG,EAAyBE,GAAY,CAGjDJ,QAAS,CAAC,GAOX,OAHAO,EAAoBH,GAAUL,EAAQA,EAAOC,QAASG,GAG/CJ,EAAOC,OACf,CCrBAG,EAAoBK,EAAKT,I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ACA,yEACAlS,KCLDkS,EAAAA,EAAAA,WACC,2BACA,6EACA9R,KsCuCDpW,EAAAA,EAAAA,UAAUK,EAAAA,OAAY8nB,YAAa,CAClC,CACC5oB,KAAM7D,EACNqB,KAAMpB,EACNysB,eAAgB,CAAEhnB,QAAQ,EAAMinB,WAAW,GAC3ChpB,OAAOsD,EAAAA,EAAAA,IAAI,mBACX2lB,uBAAuB,MAIzBtoB,EAAAA,EAAAA,UAAUuoB,EAAAA,OAAcC,yCACxBC,EAAAA,EAAAA,uBAECC,EAAAA,EAAAA,+CAED,CASAC,CAAa5S,IAEb6D,EAAAA,EAAAA,SACC,mBAACyN,GAAD,CAAWtR,SAAWA,IACtBvB,SAASoU,eAAgBxrB,GAE1B,C","sources":["webpack://wp/./node_modules/classnames/index.js","webpack://wp/webpack/bootstrap","webpack://wp/webpack/runtime/compat get default export","webpack://wp/webpack/runtime/define property getters","webpack://wp/webpack/runtime/hasOwnProperty shorthand","webpack://wp/webpack/runtime/make namespace object","webpack://wp/external window [\"wp\",\"element\"]","webpack://wp/external window [\"wp\",\"blocks\"]","webpack://wp/external window [\"wp\",\"blockLibrary\"]","webpack://wp/external window [\"wp\",\"data\"]","webpack://wp/external window [\"wp\",\"coreData\"]","webpack://wp/external window [\"wp\",\"i18n\"]","webpack://wp/./packages/edit-navigation/build-module/constants/@wordpress/edit-navigation/src/constants/index.js","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/reducer.js","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/utils.js","webpack://wp/external window \"lodash\"","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/transform.js","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/resolvers.js","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/selectors.js","webpack://wp/external window [\"wp\",\"notices\"]","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/constants.js","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/actions.js","webpack://wp/./packages/edit-navigation/build-module/store/@wordpress/edit-navigation/src/store/index.js","webpack://wp/./node_modules/@babel/runtime/helpers/esm/extends.js","webpack://wp/external window [\"wp\",\"hooks\"]","webpack://wp/external window [\"wp\",\"compose\"]","webpack://wp/external window [\"wp\",\"blockEditor\"]","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/add-navigation-editor-custom-appender.js","webpack://wp/external window [\"wp\",\"components\"]","webpack://wp/external window [\"wp\",\"primitives\"]","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/chevron-down.js","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-menu-entity.js","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-menu-entity-prop.js","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-navigation-editor.js","webpack://wp/external window [\"wp\",\"dom\"]","webpack://wp/external window [\"wp\",\"preferences\"]","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-selected-menu-id.js","webpack://wp/external window [\"wp\",\"apiFetch\"]","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-menu-locations.js","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-navigation-editor-root-block.js","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/index.js","webpack://wp/./packages/edit-navigation/build-module/components/block-placeholder/@wordpress/edit-navigation/src/components/block-placeholder/use-navigation-entities.js","webpack://wp/./packages/edit-navigation/build-module/components/block-placeholder/@wordpress/edit-navigation/src/components/block-placeholder/index.js","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/add-navigation-editor-placeholder.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/check.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/star-filled.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/star-empty.js","webpack://wp/external window [\"wp\",\"viewport\"]","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/close-small.js","webpack://wp/external window [\"wp\",\"deprecated\"]","webpack://wp/./packages/interface/build-module/store/@wordpress/interface/src/store/actions.js","webpack://wp/./packages/interface/build-module/store/@wordpress/interface/src/store/selectors.js","webpack://wp/./packages/interface/build-module/store/@wordpress/interface/src/store/reducer.js","webpack://wp/./packages/interface/build-module/store/@wordpress/interface/src/store/index.js","webpack://wp/./packages/interface/build-module/store/@wordpress/interface/src/store/constants.js","webpack://wp/external window [\"wp\",\"plugins\"]","webpack://wp/./packages/interface/build-module/components/complementary-area-context/@wordpress/interface/src/components/complementary-area-context/index.js","webpack://wp/./packages/interface/build-module/components/complementary-area-toggle/@wordpress/interface/src/components/complementary-area-toggle/index.js","webpack://wp/./packages/interface/build-module/components/complementary-area-header/@wordpress/interface/src/components/complementary-area-header/index.js","webpack://wp/./packages/interface/build-module/components/action-item/@wordpress/interface/src/components/action-item/index.js","webpack://wp/./packages/interface/build-module/components/complementary-area-more-menu-item/@wordpress/interface/src/components/complementary-area-more-menu-item/index.js","webpack://wp/./packages/interface/build-module/components/pinned-items/@wordpress/interface/src/components/pinned-items/index.js","webpack://wp/./packages/interface/build-module/components/complementary-area/@wordpress/interface/src/components/complementary-area/index.js","webpack://wp/./packages/interface/build-module/components/interface-skeleton/@wordpress/interface/src/components/interface-skeleton/index.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/more-vertical.js","webpack://wp/./packages/interface/build-module/components/more-menu-dropdown/@wordpress/interface/src/components/more-menu-dropdown/index.js","webpack://wp/external window [\"wp\",\"htmlEntities\"]","webpack://wp/./packages/edit-navigation/build-module/components/name-display/@wordpress/edit-navigation/src/components/name-display/index.js","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/add-menu-name-editor.js","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/disable-inserting-non-navigation-blocks.js","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/remove-edit-unsupported-features.js","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/remove-settings-unsupported-features.js","webpack://wp/external window [\"wp\",\"keyboardShortcuts\"]","webpack://wp/./packages/edit-navigation/build-module/components/add-menu/@wordpress/edit-navigation/src/components/add-menu/index.js","webpack://wp/./packages/edit-navigation/build-module/components/menu-switcher/@wordpress/edit-navigation/src/components/menu-switcher/index.js","webpack://wp/./packages/edit-navigation/build-module/components/layout/@wordpress/edit-navigation/src/components/layout/unselected-menu-state.js","webpack://wp/./packages/edit-navigation/build-module/components/error-boundary/@wordpress/edit-navigation/src/components/error-boundary/index.js","webpack://wp/./packages/edit-navigation/build-module/components/layout/@wordpress/edit-navigation/src/components/layout/shortcuts.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/cog.js","webpack://wp/./packages/edit-navigation/build-module/components/sidebar/@wordpress/edit-navigation/src/components/sidebar/sidebar-header.js","webpack://wp/./packages/edit-navigation/build-module/components/name-editor/@wordpress/edit-navigation/src/components/name-editor/index.js","webpack://wp/./packages/edit-navigation/build-module/components/sidebar/@wordpress/edit-navigation/src/components/sidebar/auto-add-pages.js","webpack://wp/./packages/edit-navigation/build-module/components/sidebar/@wordpress/edit-navigation/src/components/sidebar/menu-settings.js","webpack://wp/./packages/edit-navigation/build-module/components/sidebar/@wordpress/edit-navigation/src/components/sidebar/manage-locations.js","webpack://wp/./packages/edit-navigation/build-module/components/sidebar/@wordpress/edit-navigation/src/components/sidebar/delete-menu.js","webpack://wp/./packages/edit-navigation/build-module/components/sidebar/@wordpress/edit-navigation/src/components/sidebar/index.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/menu-actions.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/new-button.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/save-button.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/undo.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/redo.js","webpack://wp/external window [\"wp\",\"keycodes\"]","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/undo-button.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/redo-button.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/plus.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/inserter-toggle.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/external.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/tools-more-menu-group.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/more-menu.js","webpack://wp/./packages/edit-navigation/build-module/components/header/@wordpress/edit-navigation/src/components/header/index.js","webpack://wp/./packages/edit-navigation/build-module/components/notices/@wordpress/edit-navigation/src/components/notices/index.js","webpack://wp/./packages/edit-navigation/build-module/components/editor/@wordpress/edit-navigation/src/components/editor/index.js","webpack://wp/./packages/icons/build-module/library/@wordpress/icons/src/library/close.js","webpack://wp/./packages/edit-navigation/build-module/components/inserter-sidebar/@wordpress/edit-navigation/src/components/inserter-sidebar/index.js","webpack://wp/./packages/edit-navigation/build-module/components/layout/@wordpress/edit-navigation/src/components/layout/unsaved-changes-warning.js","webpack://wp/./packages/edit-navigation/build-module/components/layout/@wordpress/edit-navigation/src/components/layout/index.js","webpack://wp/./packages/edit-navigation/build-module/hooks/@wordpress/edit-navigation/src/hooks/use-menu-notifications.js","webpack://wp/external window [\"wp\",\"url\"]","webpack://wp/./packages/edit-navigation/build-module/utils/@wordpress/edit-navigation/src/utils/index.js","webpack://wp/./packages/edit-navigation/build-module/@wordpress/edit-navigation/src/index.js","webpack://wp/./packages/edit-navigation/build-module/filters/@wordpress/edit-navigation/src/filters/index.js"],"sourcesContent":["/*!\n  Copyright (c) 2018 Jed Watson.\n  Licensed under the MIT License (MIT), see\n  http://jedwatson.github.io/classnames\n*/\n/* global define */\n\n(function () {\n\t'use strict';\n\n\tvar hasOwn = {}.hasOwnProperty;\n\n\tfunction classNames() {\n\t\tvar classes = [];\n\n\t\tfor (var i = 0; i < arguments.length; i++) {\n\t\t\tvar arg = arguments[i];\n\t\t\tif (!arg) continue;\n\n\t\t\tvar argType = typeof arg;\n\n\t\t\tif (argType === 'string' || argType === 'number') {\n\t\t\t\tclasses.push(arg);\n\t\t\t} else if (Array.isArray(arg)) {\n\t\t\t\tif (arg.length) {\n\t\t\t\t\tvar inner = classNames.apply(null, arg);\n\t\t\t\t\tif (inner) {\n\t\t\t\t\t\tclasses.push(inner);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else if (argType === 'object') {\n\t\t\t\tif (arg.toString === Object.prototype.toString) {\n\t\t\t\t\tfor (var key in arg) {\n\t\t\t\t\t\tif (hasOwn.call(arg, key) && arg[key]) {\n\t\t\t\t\t\t\tclasses.push(key);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tclasses.push(arg.toString());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn classes.join(' ');\n\t}\n\n\tif (typeof module !== 'undefined' && module.exports) {\n\t\tclassNames.default = classNames;\n\t\tmodule.exports = classNames;\n\t} else if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) {\n\t\t// register as 'classnames', consistent with npm package name\n\t\tdefine('classnames', [], function () {\n\t\t\treturn classNames;\n\t\t});\n\t} else {\n\t\twindow.classNames = classNames;\n\t}\n}());\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"element\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"blocks\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"blockLibrary\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"data\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"coreData\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"i18n\"];","/**\n * \"Kind\" of the menu post.\n *\n * @type {string}\n */\nexport const MENU_KIND = 'root';\n\n/**\n * \"post type\" of the menu post.\n *\n * @type {string}\n */\nexport const MENU_POST_TYPE = 'menu';\n\n/**\n * \"Kind\" of the navigation post.\n *\n * @type {string}\n */\nexport const NAVIGATION_POST_KIND = 'root';\n\n/**\n * \"post type\" of the navigation post.\n *\n * @type {string}\n */\nexport const NAVIGATION_POST_POST_TYPE = 'navigationPost';\n\n/**\n * The scope name of the editor's complementary area.\n *\n * @type {string}\n */\nexport const SIDEBAR_SCOPE = 'core/edit-navigation';\n\n/**\n * The identifier of the editor's menu complementary area.\n *\n * @type {string}\n */\nexport const SIDEBAR_MENU = 'edit-navigation/menu';\n\n/**\n * The identifier of the editor's block complementary area.\n *\n * @type {string}\n */\nexport const SIDEBAR_BLOCK = 'edit-navigation/block-inspector';\n\n/**\n * The string identifier for the menu item's \"target\" attribute indicating\n * the menu item link should open in a new tab.\n *\n * @type {string}\n */\nexport const NEW_TAB_TARGET_ATTRIBUTE = '_blank';\n","/**\n * WordPress dependencies\n */\nimport { combineReducers } from '@wordpress/data';\n\n/**\n * Reducer tracking whether the inserter is open.\n *\n * @param {boolean|Object} state        Current state.\n * @param {Object}         action       Dispatched action.\n * @param {string}         action.type  String indicating action type.\n * @param {boolean}        action.value Flag indicating whether the panel should be open/close.\n */\nfunction blockInserterPanel( state = false, action ) {\n\tswitch ( action.type ) {\n\t\tcase 'SET_IS_INSERTER_OPENED':\n\t\t\treturn action.value;\n\t}\n\treturn state;\n}\n\nexport default combineReducers( {\n\tblockInserterPanel,\n} );\n","/**\n * A WP nav_menu_item object.\n * For more documentation on the individual fields present on a menu item please see:\n * https://core.trac.wordpress.org/browser/tags/5.7.1/src/wp-includes/nav-menu.php#L789\n *\n * Changes made here should also be mirrored in packages/block-library/src/navigation/map-menu-items-to-blocks.js.\n *\n * @typedef WPNavMenuItem\n *\n * @property {Object} title       stores the raw and rendered versions of the title/label for this menu item.\n * @property {Array}  xfn         the XFN relationships expressed in the link of this menu item.\n * @property {Array}  classes     the HTML class attributes for this menu item.\n * @property {string} attr_title  the HTML title attribute for this menu item.\n * @property {string} object      The type of object originally represented, such as 'category', 'post', or 'attachment'.\n * @property {string} object_id   The DB ID of the original object this menu item represents, e.g. ID for posts and term_id for categories.\n * @property {string} description The description of this menu item.\n * @property {string} url         The URL to which this menu item points.\n * @property {string} type        The family of objects originally represented, such as 'post_type' or 'taxonomy'.\n * @property {string} target      The target attribute of the link element for this menu item.\n */\n\n/**\n * Builds an ID for a new navigation post.\n *\n * @param {number} menuId Menu id.\n * @return {string} An ID.\n */\nexport const buildNavigationPostId = ( menuId ) =>\n\t`navigation-post-${ menuId }`;\n\n/**\n * Builds a query to resolve menu items.\n *\n * @param {number} menuId Menu id.\n * @return {Object} Query.\n */\nexport function menuItemsQuery( menuId ) {\n\treturn { menus: menuId, per_page: -1 };\n}\n\n/**\n * Get the internal record id from block.\n *\n * @typedef  {Object} Attributes\n * @property {string}     __internalRecordId The internal record id.\n * @typedef  {Object} Block\n * @property {Attributes} attributes         The attributes of the block.\n *\n * @param    {Block}      block              The block.\n * @return {string} The internal record id.\n */\nexport function getRecordIdFromBlock( block ) {\n\treturn block.attributes.__internalRecordId;\n}\n\n/**\n * Add internal record id to block's attributes.\n *\n * @param {Block}  block    The block.\n * @param {string} recordId The record id.\n * @return {Block} The updated block.\n */\nexport function addRecordIdToBlock( block, recordId ) {\n\treturn {\n\t\t...block,\n\t\tattributes: {\n\t\t\t...( block.attributes || {} ),\n\t\t\t__internalRecordId: recordId,\n\t\t},\n\t};\n}\n\n/**\n * Checks if a given block should be persisted as a menu item.\n *\n * @param {Object} block Block to check.\n * @return {boolean} True if a given block should be persisted as a menu item, false otherwise.\n */\nexport const isBlockSupportedInNav = ( block ) =>\n\t[ 'core/navigation-link', 'core/navigation-submenu' ].includes(\n\t\tblock.name\n\t);\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"lodash\"];","/**\n * External dependencies\n */\nimport { get } from 'lodash';\n\n/**\n * WordPress dependencies\n */\nimport { serialize, createBlock, parse } from '@wordpress/blocks';\n\n/**\n * Internal dependencies\n */\nimport { NEW_TAB_TARGET_ATTRIBUTE } from '../constants';\nimport {\n\taddRecordIdToBlock,\n\tgetRecordIdFromBlock,\n\tisBlockSupportedInNav,\n} from './utils';\n\n/**\n * A WP nav_menu_item object.\n * For more documentation on the individual fields present on a menu item please see:\n * https://core.trac.wordpress.org/browser/tags/5.7.1/src/wp-includes/nav-menu.php#L789\n *\n * Changes made here should also be mirrored in packages/edit-navigation/src/store/utils.js.\n *\n * @typedef WPNavMenuItem\n *\n * @property {Object} title       stores the raw and rendered versions of the title/label for this menu item.\n * @property {Array}  xfn         the XFN relationships expressed in the link of this menu item.\n * @property {Array}  classes     the HTML class attributes for this menu item.\n * @property {string} attr_title  the HTML title attribute for this menu item.\n * @property {string} object      The type of object originally represented, such as 'category', 'post', or 'attachment'.\n * @property {string} object_id   The DB ID of the original object this menu item represents, e.g. ID for posts and term_id for categories.\n * @property {string} description The description of this menu item.\n * @property {string} url         The URL to which this menu item points.\n * @property {string} type        The family of objects originally represented, such as 'post_type' or 'taxonomy'.\n * @property {string} target      The target attribute of the link element for this menu item.\n */\n\nexport function blockToMenuItem(\n\tblock,\n\tmenuItem,\n\tparentId,\n\tblockPosition,\n\tmenuId\n) {\n\tconst { menus, meta, _links, ...restMenuItem } = menuItem;\n\tmenuItem = restMenuItem;\n\tmenuItem.content = get( menuItem.content, 'raw', menuItem.content );\n\n\tlet attributes;\n\n\tif ( isBlockSupportedInNav( block ) ) {\n\t\tattributes = blockAttributesToMenuItem( block.attributes );\n\t} else {\n\t\tattributes = {\n\t\t\ttype: 'block',\n\t\t\tcontent: serialize( block ),\n\t\t};\n\t}\n\n\treturn {\n\t\t...menuItem,\n\t\t...attributes,\n\t\tcontent: attributes.content || '',\n\t\tid: getRecordIdFromBlock( block ),\n\t\tmenu_order: blockPosition + 1,\n\t\tmenus: menuId,\n\t\tparent: ! parentId ? 0 : parentId,\n\t\tstatus: 'publish',\n\t};\n}\n\n/**\n * Convert block attributes to menu item fields.\n *\n * Note that nav_menu_item has defaults provided in Core so in the case of undefined Block attributes\n * we need only include a subset of values in the knowledge that the defaults will be provided in Core.\n *\n * See: https://core.trac.wordpress.org/browser/tags/5.7.1/src/wp-includes/nav-menu.php#L438.\n *\n * @param {Object}  blockAttributes               the block attributes of the block to be converted into menu item fields.\n * @param {string}  blockAttributes.label         the visual name of the block shown in the UI.\n * @param {string}  blockAttributes.url           the URL for the link.\n * @param {string}  blockAttributes.description   a link description.\n * @param {string}  blockAttributes.rel           the XFN relationship expressed in the link of this menu item.\n * @param {string}  blockAttributes.className     the custom CSS classname attributes for this block.\n * @param {string}  blockAttributes.title         the HTML title attribute for the block's link.\n * @param {string}  blockAttributes.type          the type of variation of the block used (eg: 'Post', 'Custom', 'Category'...etc).\n * @param {number}  blockAttributes.id            the ID of the entity optionally associated with the block's link (eg: the Post ID).\n * @param {string}  blockAttributes.kind          the family of objects originally represented, such as 'post-type' or 'taxonomy'.\n * @param {boolean} blockAttributes.opensInNewTab whether or not the block's link should open in a new tab.\n * @return {WPNavMenuItem} the menu item (converted from block attributes).\n */\nexport const blockAttributesToMenuItem = ( {\n\tlabel = '',\n\turl = '',\n\tdescription,\n\trel,\n\tclassName,\n\ttitle: blockTitleAttr,\n\ttype,\n\tid,\n\tkind,\n\topensInNewTab,\n} ) => {\n\t// For historical reasons, the `core/navigation-link` variation type is `tag`\n\t// whereas WP Core expects `post_tag` as the `object` type.\n\t// To avoid writing a block migration we perform a conversion here.\n\t// See also inverse equivalent in `menuItemToBlockAttributes`.\n\tif ( type && type === 'tag' ) {\n\t\ttype = 'post_tag';\n\t}\n\n\treturn {\n\t\ttitle: label,\n\t\turl,\n\t\t...( description?.length && {\n\t\t\tdescription,\n\t\t} ),\n\t\t...( rel?.length && {\n\t\t\txfn: rel?.trim().split( ' ' ),\n\t\t} ),\n\t\t...( className?.length && {\n\t\t\tclasses: className?.trim().split( ' ' ),\n\t\t} ),\n\t\t...( blockTitleAttr?.length && {\n\t\t\tattr_title: blockTitleAttr,\n\t\t} ),\n\t\t...( type?.length && {\n\t\t\tobject: type,\n\t\t} ),\n\t\t...( kind?.length && {\n\t\t\ttype: kind?.replace( '-', '_' ),\n\t\t} ),\n\t\t// Only assign object_id if it's a entity type (ie: not \"custom\").\n\t\t...( id &&\n\t\t\t'custom' !== type && {\n\t\t\t\tobject_id: id,\n\t\t\t} ),\n\t\ttarget: opensInNewTab ? NEW_TAB_TARGET_ATTRIBUTE : '',\n\t};\n};\n\n/**\n * Convert a flat menu item structure to a nested blocks structure.\n *\n * @param {Object[]} menuItems An array of menu items.\n *\n * @return {WPBlock[]} An array of blocks.\n */\nexport function menuItemsToBlocks( menuItems ) {\n\tif ( ! menuItems ) {\n\t\treturn null;\n\t}\n\n\tconst menuTree = createDataTree( menuItems );\n\n\treturn mapMenuItemsToBlocks( menuTree );\n}\n\n/**\n * A recursive function that maps menu item nodes to blocks.\n *\n * @param {WPNavMenuItem[]} menuItems An array of WPNavMenuItem items.\n * @return {Object} Object containing innerBlocks and mapping.\n */\nfunction mapMenuItemsToBlocks( menuItems ) {\n\t// The menuItem should be in menu_order sort order.\n\tconst sortedItems = [ ...menuItems ].sort(\n\t\t( a, b ) => a.menu_order - b.menu_order\n\t);\n\n\tconst blocks = sortedItems.map( ( menuItem ) => {\n\t\tif ( menuItem.type === 'block' ) {\n\t\t\tconst [ block ] = parse( menuItem.content.raw );\n\n\t\t\tif ( ! block ) {\n\t\t\t\treturn createBlock( 'core/freeform', {\n\t\t\t\t\tcontent: menuItem.content,\n\t\t\t\t} );\n\t\t\t}\n\n\t\t\treturn block;\n\t\t}\n\t\tconst attributes = menuItemToBlockAttributes( menuItem );\n\n\t\t// If there are children recurse to build those nested blocks.\n\t\tconst nestedBlocks = menuItem.children?.length\n\t\t\t? mapMenuItemsToBlocks( menuItem.children )\n\t\t\t: [];\n\n\t\t// Create a submenu block when there are inner blocks, or just a link\n\t\t// for a standalone item.\n\t\tconst itemBlockName = nestedBlocks?.length\n\t\t\t? 'core/navigation-submenu'\n\t\t\t: 'core/navigation-link';\n\n\t\t// Create block with nested \"innerBlocks\".\n\t\treturn createBlock( itemBlockName, attributes, nestedBlocks );\n\t} );\n\n\treturn blocks.map( ( block, blockIndex ) =>\n\t\taddRecordIdToBlock( block, sortedItems[ blockIndex ].id )\n\t);\n}\n\n// A few parameters are using snake case, let's embrace that for convenience:\n/* eslint-disable camelcase */\n/**\n * Convert block attributes to menu item.\n *\n * @param {WPNavMenuItem} menuItem the menu item to be converted to block attributes.\n * @return {Object} the block attributes converted from the WPNavMenuItem item.\n */\nexport function menuItemToBlockAttributes( {\n\ttitle: menuItemTitleField,\n\txfn,\n\tclasses,\n\tattr_title,\n\tobject,\n\tobject_id,\n\tdescription,\n\turl,\n\ttype: menuItemTypeField,\n\ttarget,\n} ) {\n\t// For historical reasons, the `core/navigation-link` variation type is `tag`\n\t// whereas WP Core expects `post_tag` as the `object` type.\n\t// To avoid writing a block migration we perform a conversion here.\n\t// See also inverse equivalent in `blockAttributesToMenuItem`.\n\tif ( object && object === 'post_tag' ) {\n\t\tobject = 'tag';\n\t}\n\n\treturn {\n\t\tlabel: menuItemTitleField?.rendered || '',\n\t\t...( object?.length && {\n\t\t\ttype: object,\n\t\t} ),\n\t\tkind: menuItemTypeField?.replace( '_', '-' ) || 'custom',\n\t\turl: url || '',\n\t\t...( xfn?.length &&\n\t\t\txfn.join( ' ' ).trim() && {\n\t\t\t\trel: xfn.join( ' ' ).trim(),\n\t\t\t} ),\n\t\t...( classes?.length &&\n\t\t\tclasses.join( ' ' ).trim() && {\n\t\t\t\tclassName: classes.join( ' ' ).trim(),\n\t\t\t} ),\n\t\t...( attr_title?.length && {\n\t\t\ttitle: attr_title,\n\t\t} ),\n\t\t...( object_id &&\n\t\t\t'custom' !== object && {\n\t\t\t\tid: object_id,\n\t\t\t} ),\n\t\t...( description?.length && {\n\t\t\tdescription,\n\t\t} ),\n\t\t...( target === NEW_TAB_TARGET_ATTRIBUTE && {\n\t\t\topensInNewTab: true,\n\t\t} ),\n\t};\n}\n/* eslint-enable camelcase */\n\n/**\n * Creates a nested, hierarchical tree representation from unstructured data that\n * has an inherent relationship defined between individual items.\n *\n * For example, by default, each element in the dataset should have an `id` and\n * `parent` property where the `parent` property indicates a relationship between\n * the current item and another item with a matching `id` properties.\n *\n * This is useful for building linked lists of data from flat data structures.\n *\n * @param {Array}  dataset  linked data to be rearranged into a hierarchical tree based on relational fields.\n * @param {string} id       the property which uniquely identifies each entry within the array.\n * @param {*}      relation the property which identifies how the current item is related to other items in the data (if at all).\n * @return {Array} a nested array of parent/child relationships\n */\nfunction createDataTree( dataset, id = 'id', relation = 'parent' ) {\n\tconst hashTable = Object.create( null );\n\tconst dataTree = [];\n\n\tfor ( const data of dataset ) {\n\t\thashTable[ data[ id ] ] = {\n\t\t\t...data,\n\t\t\tchildren: [],\n\t\t};\n\t}\n\tfor ( const data of dataset ) {\n\t\tif ( data[ relation ] ) {\n\t\t\thashTable[ data[ relation ] ] = hashTable[ data[ relation ] ] || {};\n\t\t\thashTable[ data[ relation ] ].children =\n\t\t\t\thashTable[ data[ relation ] ].children || [];\n\t\t\thashTable[ data[ relation ] ].children.push(\n\t\t\t\thashTable[ data[ id ] ]\n\t\t\t);\n\t\t} else {\n\t\t\tdataTree.push( hashTable[ data[ id ] ] );\n\t\t}\n\t}\n\n\treturn dataTree;\n}\n","/**\n * WordPress dependencies\n */\nimport { createBlock } from '@wordpress/blocks';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { NAVIGATION_POST_KIND, NAVIGATION_POST_POST_TYPE } from '../constants';\nimport { buildNavigationPostId, menuItemsQuery } from './utils';\nimport { menuItemsToBlocks } from './transform';\n\n/**\n * Creates a \"stub\" navigation post reflecting the contents of menu with id=menuId. The\n * post is meant as a convenient to only exists in runtime and should never be saved. It\n * enables a convenient way of editing the navigation by using a regular post editor.\n *\n * Fetches all menu items, converts them into blocks, and hydrates a new post with them.\n *\n * @param {number} menuId The id of menu to create a post from\n * @return {void}\n */\nexport const getNavigationPostForMenu =\n\t( menuId ) =>\n\tasync ( { registry, dispatch } ) => {\n\t\tif ( ! menuId ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst stubPost = createStubPost( menuId );\n\t\t// Persist an empty post to warm up the state.\n\t\tdispatch( persistPost( stubPost ) );\n\n\t\t// Dispatch startResolution to skip the execution of the real getEntityRecord resolver - it would\n\t\t// issue an http request and fail.\n\t\tconst args = [\n\t\t\tNAVIGATION_POST_KIND,\n\t\t\tNAVIGATION_POST_POST_TYPE,\n\t\t\tstubPost.id,\n\t\t];\n\t\tregistry\n\t\t\t.dispatch( coreStore )\n\t\t\t.startResolution( 'getEntityRecord', args );\n\n\t\t// Now let's create a proper one hydrated using actual menu items.\n\t\tconst menuItems = await registry\n\t\t\t.resolveSelect( coreStore )\n\t\t\t.getMenuItems( menuItemsQuery( menuId ) );\n\n\t\tconst navigationBlock = createNavigationBlock( menuItems );\n\t\t// Persist the actual post containing the navigation block.\n\t\tconst builtPost = createStubPost( menuId, navigationBlock );\n\t\tdispatch( persistPost( builtPost ) );\n\n\t\t// Dispatch finishResolution to conclude startResolution dispatched earlier.\n\t\tregistry\n\t\t\t.dispatch( coreStore )\n\t\t\t.finishResolution( 'getEntityRecord', args );\n\t};\n\nconst createStubPost = ( menuId, navigationBlock = null ) => {\n\tconst id = buildNavigationPostId( menuId );\n\treturn {\n\t\tid,\n\t\tslug: id,\n\t\tstatus: 'draft',\n\t\ttype: 'page',\n\t\tblocks: navigationBlock ? [ navigationBlock ] : [],\n\t\tmeta: {\n\t\t\tmenuId,\n\t\t},\n\t};\n};\n\nconst persistPost =\n\t( post ) =>\n\t( { registry } ) => {\n\t\tregistry\n\t\t\t.dispatch( coreStore )\n\t\t\t.receiveEntityRecords(\n\t\t\t\tNAVIGATION_POST_KIND,\n\t\t\t\tNAVIGATION_POST_POST_TYPE,\n\t\t\t\tpost,\n\t\t\t\t{ id: post.id },\n\t\t\t\tfalse\n\t\t\t);\n\t};\n\n/**\n * Converts an adjacency list of menuItems into a navigation block.\n *\n * @param {Array} menuItems a list of menu items\n * @return {Object} Navigation block\n */\nfunction createNavigationBlock( menuItems ) {\n\tconst innerBlocks = menuItemsToBlocks( menuItems );\n\n\treturn createBlock(\n\t\t'core/navigation',\n\t\t{\n\t\t\torientation: 'vertical',\n\t\t},\n\t\tinnerBlocks\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { createRegistrySelector } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { NAVIGATION_POST_KIND, NAVIGATION_POST_POST_TYPE } from '../constants';\nimport { buildNavigationPostId } from './utils';\n\n/**\n * Returns a \"stub\" navigation post reflecting the contents of menu with id=menuId. The\n * post is meant as a convenient to only exists in runtime and should never be saved. It\n * enables a convenient way of editing the navigation by using a regular post editor.\n *\n * Related resolver fetches all menu items, converts them into blocks, and hydrates a new post with them.\n *\n * @param {number} menuId The id of menu to create a post from.\n * @return {null|Object} Post once the resolver fetches it, otherwise null\n */\nexport const getNavigationPostForMenu = createRegistrySelector(\n\t( select ) => ( state, menuId ) => {\n\t\t// When the record is unavailable, calling getEditedEntityRecord triggers a http\n\t\t// request via it's related resolver. Let's return nothing until getNavigationPostForMenu\n\t\t// resolver marks the record as resolved.\n\t\tif ( ! hasResolvedNavigationPost( state, menuId ) ) {\n\t\t\treturn null;\n\t\t}\n\t\treturn select( coreStore ).getEditedEntityRecord(\n\t\t\tNAVIGATION_POST_KIND,\n\t\t\tNAVIGATION_POST_POST_TYPE,\n\t\t\tbuildNavigationPostId( menuId )\n\t\t);\n\t}\n);\n\n/**\n * Returns true if the navigation post related to menuId was already resolved.\n *\n * @param {number} menuId The id of menu.\n * @return {boolean} True if the navigation post related to menuId was already resolved, false otherwise.\n */\nexport const hasResolvedNavigationPost = createRegistrySelector(\n\t( select ) => ( state, menuId ) => {\n\t\treturn select( coreStore ).hasFinishedResolution( 'getEntityRecord', [\n\t\t\tNAVIGATION_POST_KIND,\n\t\t\tNAVIGATION_POST_POST_TYPE,\n\t\t\tbuildNavigationPostId( menuId ),\n\t\t] );\n\t}\n);\n\n/**\n * Returns true if the inserter is opened.\n *\n * @param {Object} state Global application state.\n * @return {boolean} Whether the inserter is opened.\n */\nexport function isInserterOpened( state = false ) {\n\treturn !! state?.blockInserterPanel;\n}\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"notices\"];","/**\n * Module Constants\n */\nexport const STORE_NAME = 'core/edit-navigation';\n","/**\n * WordPress dependencies\n */\nimport { __, sprintf } from '@wordpress/i18n';\nimport { store as noticesStore } from '@wordpress/notices';\nimport { store as coreDataStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { STORE_NAME } from './constants';\nimport {\n\taddRecordIdToBlock,\n\tgetRecordIdFromBlock,\n\tisBlockSupportedInNav,\n} from './utils';\nimport { blockToMenuItem, menuItemToBlockAttributes } from './transform';\nimport { NAVIGATION_POST_KIND, NAVIGATION_POST_POST_TYPE } from '../constants';\n\n/**\n * Converts all the blocks into menu items and submits a batch request to save everything at once.\n *\n * @param {Object} post A navigation post to process\n * @return {Function} An action creator\n */\nexport const saveNavigationPost =\n\t( post ) =>\n\tasync ( { registry, dispatch } ) => {\n\t\tconst lock = await registry\n\t\t\t.dispatch( coreDataStore )\n\t\t\t.__unstableAcquireStoreLock( STORE_NAME, [ 'savingMenu' ], {\n\t\t\t\texclusive: true,\n\t\t\t} );\n\t\ttry {\n\t\t\tconst menuId = post.meta.menuId;\n\n\t\t\t// Save menu.\n\t\t\tawait registry\n\t\t\t\t.dispatch( coreDataStore )\n\t\t\t\t.saveEditedEntityRecord( 'root', 'menu', menuId, {\n\t\t\t\t\tthrowOnError: true,\n\t\t\t\t} );\n\n\t\t\t// Save menu items.\n\t\t\tconst updatedBlocks = await dispatch(\n\t\t\t\tbatchSaveMenuItems( post.blocks[ 0 ], menuId )\n\t\t\t);\n\n\t\t\t// Clear \"stub\" navigation post edits to avoid a false \"dirty\" state.\n\t\t\tregistry\n\t\t\t\t.dispatch( coreDataStore )\n\t\t\t\t.receiveEntityRecords(\n\t\t\t\t\tNAVIGATION_POST_KIND,\n\t\t\t\t\tNAVIGATION_POST_POST_TYPE,\n\t\t\t\t\tpost,\n\t\t\t\t\tundefined\n\t\t\t\t);\n\n\t\t\tconst updatedPost = {\n\t\t\t\t...post,\n\t\t\t\tblocks: [ updatedBlocks ],\n\t\t\t};\n\t\t\tregistry\n\t\t\t\t.dispatch( coreDataStore )\n\t\t\t\t.receiveEntityRecords(\n\t\t\t\t\tNAVIGATION_POST_KIND,\n\t\t\t\t\tNAVIGATION_POST_POST_TYPE,\n\t\t\t\t\tupdatedPost,\n\t\t\t\t\tundefined\n\t\t\t\t);\n\n\t\t\tregistry\n\t\t\t\t.dispatch( noticesStore )\n\t\t\t\t.createSuccessNotice( __( 'Navigation saved.' ), {\n\t\t\t\t\ttype: 'snackbar',\n\t\t\t\t} );\n\t\t} catch ( saveError ) {\n\t\t\tconst errorMessage = saveError\n\t\t\t\t? sprintf(\n\t\t\t\t\t\t/* translators: %s: The text of an error message (potentially untranslated). */\n\t\t\t\t\t\t__( \"Unable to save: '%s'\" ),\n\t\t\t\t\t\tsaveError.message\n\t\t\t\t  )\n\t\t\t\t: __( 'Unable to save: An error ocurred.' );\n\t\t\tregistry.dispatch( noticesStore ).createErrorNotice( errorMessage, {\n\t\t\t\ttype: 'snackbar',\n\t\t\t} );\n\t\t} finally {\n\t\t\tregistry\n\t\t\t\t.dispatch( coreDataStore )\n\t\t\t\t.__unstableReleaseStoreLock( lock );\n\t\t}\n\t};\n\n/**\n * Executes appropriate insert, update, and delete operations to turn the current\n * menu (with id=menuId) into one represented by the passed navigation block.\n *\n * @param {Object} navigationBlock The navigation block representing the desired state of the menu.\n * @param {number} menuId          Menu Id to process.\n * @return {Function} An action creator\n */\nconst batchSaveMenuItems =\n\t( navigationBlock, menuId ) =>\n\tasync ( { dispatch, registry } ) => {\n\t\t// Make sure all the existing menu items are available before proceeding.\n\t\tconst oldMenuItems = await registry\n\t\t\t.resolveSelect( coreDataStore )\n\t\t\t.getMenuItems( { menus: menuId, per_page: -1 } );\n\n\t\t// Insert placeholders for new menu items to have an ID to work with.\n\t\t// We need that in case these new items have any children. If so,\n\t\t// we need to provide a parent id that we don't have yet.\n\t\tconst navBlockWithRecordIds = await dispatch(\n\t\t\tbatchInsertPlaceholderMenuItems( navigationBlock )\n\t\t);\n\n\t\t// Update menu items. This is separate from deleting, because there\n\t\t// are no consistency guarantees and we don't want to delete something\n\t\t// that was a parent node before another node takes it place.\n\t\tconst navBlockAfterUpdates = await dispatch(\n\t\t\tbatchUpdateMenuItems( navBlockWithRecordIds, menuId )\n\t\t);\n\n\t\t// Delete menu items.\n\t\tconst deletedIds = oldMenuItems\n\t\t\t.map( ( { id } ) => id )\n\t\t\t.filter(\n\t\t\t\t( id ) =>\n\t\t\t\t\t! blocksTreeToList( navBlockAfterUpdates )\n\t\t\t\t\t\t.map( getRecordIdFromBlock )\n\t\t\t\t\t\t.includes( id )\n\t\t\t);\n\n\t\tawait dispatch( batchDeleteMenuItems( deletedIds ) );\n\n\t\treturn navBlockAfterUpdates;\n\t};\n\n/**\n * Creates a menu item for every block that doesn't have an associated menuItem.\n * Sends a batch request with one POST /wp/v2/menu-items for every created menu item.\n *\n * @param {Object} navigationBlock A navigation block to find created menu items in.\n * @return {Function} An action creator\n */\nconst batchInsertPlaceholderMenuItems =\n\t( navigationBlock ) =>\n\tasync ( { registry } ) => {\n\t\tconst blocksWithoutRecordId = blocksTreeToList(\n\t\t\tnavigationBlock\n\t\t).filter(\n\t\t\t( block ) =>\n\t\t\t\tisBlockSupportedInNav( block ) &&\n\t\t\t\t! getRecordIdFromBlock( block )\n\t\t);\n\n\t\tconst tasks = blocksWithoutRecordId.map(\n\t\t\t() =>\n\t\t\t\t( { saveEntityRecord } ) =>\n\t\t\t\t\tsaveEntityRecord( 'root', 'menuItem', {\n\t\t\t\t\t\ttitle: __( 'Menu item' ),\n\t\t\t\t\t\turl: '#placeholder',\n\t\t\t\t\t\tmenu_order: 1,\n\t\t\t\t\t} )\n\t\t);\n\n\t\tconst results = await registry\n\t\t\t.dispatch( coreDataStore )\n\t\t\t.__experimentalBatch( tasks );\n\n\t\t// Return an updated navigation block with all the IDs in.\n\t\tconst blockToResult = new Map(\n\t\t\tblocksWithoutRecordId.map( ( block, index ) => [\n\t\t\t\tblock,\n\t\t\t\tresults[ index ],\n\t\t\t] )\n\t\t);\n\t\treturn mapBlocksTree( navigationBlock, ( block ) => {\n\t\t\tif ( ! blockToResult.has( block ) ) {\n\t\t\t\treturn block;\n\t\t\t}\n\t\t\treturn addRecordIdToBlock( block, blockToResult.get( block ).id );\n\t\t} );\n\t};\n\n/**\n * Updates every menu item where a related block has changed.\n * Sends a batch request with one PUT /wp/v2/menu-items for every updated menu item.\n *\n * @param {Object} navigationBlock A navigation block to find updated menu items in.\n * @param {number} menuId          Menu ID.\n * @return {Function} An action creator\n */\nconst batchUpdateMenuItems =\n\t( navigationBlock, menuId ) =>\n\tasync ( { registry } ) => {\n\t\tconst allMenuItems = blocksTreeToAnnotatedList( navigationBlock );\n\t\tconst unsupportedMenuItems = allMenuItems\n\t\t\t.filter( ( { block } ) => ! isBlockSupportedInNav( block ) )\n\t\t\t.map( ( { block } ) => block.name );\n\t\tif ( unsupportedMenuItems.length ) {\n\t\t\twindow.console.warn(\n\t\t\t\tsprintf(\n\t\t\t\t\t// translators: %s: Name of block (i.e. core/legacy-widget)\n\t\t\t\t\t__(\n\t\t\t\t\t\t'The following blocks haven\\'t been saved because they are not supported: \"%s\".'\n\t\t\t\t\t),\n\t\t\t\t\tunsupportedMenuItems.join( '\", \"' )\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t\tconst updatedMenuItems = allMenuItems\n\t\t\t// Filter out unsupported blocks.\n\t\t\t.filter( ( { block } ) => isBlockSupportedInNav( block ) )\n\t\t\t// Transform the blocks into menu items.\n\t\t\t.map( ( { block, parentBlock, childIndex } ) =>\n\t\t\t\tblockToMenuItem(\n\t\t\t\t\tblock,\n\t\t\t\t\tregistry\n\t\t\t\t\t\t.select( coreDataStore )\n\t\t\t\t\t\t.getMenuItem( getRecordIdFromBlock( block ) ),\n\t\t\t\t\tgetRecordIdFromBlock( parentBlock ),\n\t\t\t\t\tchildIndex,\n\t\t\t\t\tmenuId\n\t\t\t\t)\n\t\t\t)\n\t\t\t// Filter out menu items without any edits.\n\t\t\t.filter( ( menuItem ) => {\n\t\t\t\t// Update an existing entity record.\n\t\t\t\tregistry\n\t\t\t\t\t.dispatch( coreDataStore )\n\t\t\t\t\t.editEntityRecord(\n\t\t\t\t\t\t'root',\n\t\t\t\t\t\t'menuItem',\n\t\t\t\t\t\tmenuItem.id,\n\t\t\t\t\t\tmenuItem,\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tundoIgnore: true,\n\t\t\t\t\t\t}\n\t\t\t\t\t);\n\n\t\t\t\treturn registry\n\t\t\t\t\t.select( coreDataStore )\n\t\t\t\t\t.hasEditsForEntityRecord( 'root', 'menuItem', menuItem.id );\n\t\t\t} );\n\n\t\t// Map the edited menu items to batch tasks.\n\t\tconst tasks = updatedMenuItems.map(\n\t\t\t( menuItem ) =>\n\t\t\t\t( { saveEditedEntityRecord } ) =>\n\t\t\t\t\tsaveEditedEntityRecord( 'root', 'menuItem', menuItem.id )\n\t\t);\n\n\t\tawait registry.dispatch( coreDataStore ).__experimentalBatch( tasks );\n\n\t\t// Throw on failure. @TODO failures should be thrown in core-data\n\t\tupdatedMenuItems.forEach( ( menuItem ) => {\n\t\t\tconst failure = registry\n\t\t\t\t.select( coreDataStore )\n\t\t\t\t.getLastEntitySaveError( 'root', 'menuItem', menuItem.id );\n\t\t\tif ( failure ) {\n\t\t\t\tthrow new Error( failure.message );\n\t\t\t}\n\t\t} );\n\n\t\t// Return an updated navigation block reflecting the changes persisted in the batch update.\n\t\treturn mapBlocksTree( navigationBlock, ( block ) => {\n\t\t\tif ( ! isBlockSupportedInNav( block ) ) {\n\t\t\t\treturn block;\n\t\t\t}\n\t\t\tconst updatedMenuItem = registry\n\t\t\t\t.select( coreDataStore )\n\t\t\t\t.getMenuItem( getRecordIdFromBlock( block ) );\n\n\t\t\treturn addRecordIdToBlock(\n\t\t\t\t{\n\t\t\t\t\t...block,\n\t\t\t\t\tattributes: menuItemToBlockAttributes( updatedMenuItem ),\n\t\t\t\t},\n\t\t\t\tupdatedMenuItem.id\n\t\t\t);\n\t\t} );\n\t};\n\n/**\n * Deletes multiple menu items.\n * Sends a batch request with one DELETE /wp/v2/menu-items for every deleted menu item.\n *\n * @param {Object} deletedIds A list of menu item ids to delete\n * @return {Function} An action creator\n */\nconst batchDeleteMenuItems =\n\t( deletedIds ) =>\n\tasync ( { registry } ) => {\n\t\tconst deleteBatch = deletedIds.map(\n\t\t\t( id ) =>\n\t\t\t\tasync ( { deleteEntityRecord } ) => {\n\t\t\t\t\tconst success = await deleteEntityRecord(\n\t\t\t\t\t\t'root',\n\t\t\t\t\t\t'menuItem',\n\t\t\t\t\t\tid,\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tforce: true,\n\t\t\t\t\t\t}\n\t\t\t\t\t);\n\t\t\t\t\t// @TODO failures should be thrown in core-data\n\t\t\t\t\tif ( ! success ) {\n\t\t\t\t\t\tthrow new Error( id );\n\t\t\t\t\t}\n\t\t\t\t\treturn success;\n\t\t\t\t}\n\t\t);\n\n\t\treturn await registry\n\t\t\t.dispatch( coreDataStore )\n\t\t\t.__experimentalBatch( deleteBatch );\n\t};\n\n/**\n * Turns a recursive list of blocks into a flat list of blocks annotated with\n * their child index and parent block.\n *\n * @param {Object} parentBlock A parent block to flatten\n * @return {Object} A flat list of blocks, annotated by their index and parent ID, consisting\n * \t\t\t\t\t\t\t    of all the input blocks and all the inner blocks in the tree.\n */\nfunction blocksTreeToAnnotatedList( parentBlock ) {\n\treturn ( parentBlock.innerBlocks || [] ).flatMap( ( innerBlock, index ) =>\n\t\t[ { block: innerBlock, parentBlock, childIndex: index } ].concat(\n\t\t\tblocksTreeToAnnotatedList( innerBlock )\n\t\t)\n\t);\n}\n\nfunction blocksTreeToList( parentBlock ) {\n\treturn blocksTreeToAnnotatedList( parentBlock ).map(\n\t\t( { block } ) => block\n\t);\n}\n\n/**\n * Maps one tree of blocks into another tree by invoking a callback on every node.\n *\n * @param {Object}   block       The root of the mapped tree.\n * @param {Function} callback    The callback to invoke.\n * @param {Object}   parentBlock Internal. The current parent block.\n * @param {number}   idx         Internal. The current child index.\n * @return {Object} A mapped tree.\n */\nfunction mapBlocksTree( block, callback, parentBlock = null, idx = 0 ) {\n\treturn {\n\t\t...callback( block, parentBlock, idx ),\n\t\tinnerBlocks: ( block.innerBlocks || [] ).map( ( innerBlock, index ) =>\n\t\t\tmapBlocksTree( innerBlock, callback, block, index )\n\t\t),\n\t};\n}\n\n/**\n * Returns an action object used to open/close the inserter.\n *\n * @param {boolean|Object} value                Whether the inserter should be\n *                                              opened (true) or closed (false).\n *                                              To specify an insertion point,\n *                                              use an object.\n * @param {string}         value.rootClientId   The root client ID to insert at.\n * @param {number}         value.insertionIndex The index to insert at.\n *\n * @return {Object} Action object.\n */\nexport function setIsInserterOpened( value ) {\n\treturn {\n\t\ttype: 'SET_IS_INSERTER_OPENED',\n\t\tvalue,\n\t};\n}\n","/**\n * WordPress dependencies\n */\nimport { createReduxStore, register } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport reducer from './reducer';\nimport * as resolvers from './resolvers';\nimport * as selectors from './selectors';\nimport * as actions from './actions';\nimport { STORE_NAME } from './constants';\n\n/**\n * Store definition for the edit navigation namespace.\n *\n * @see https://github.com/WordPress/gutenberg/blob/HEAD/packages/data/README.md#createReduxStore\n *\n * @type {Object}\n */\nexport const store = createReduxStore( STORE_NAME, {\n\treducer,\n\tselectors,\n\tresolvers,\n\tactions,\n} );\n\nregister( store );\n","export default function _extends() {\n  _extends = Object.assign || function (target) {\n    for (var i = 1; i < arguments.length; i++) {\n      var source = arguments[i];\n\n      for (var key in source) {\n        if (Object.prototype.hasOwnProperty.call(source, key)) {\n          target[key] = source[key];\n        }\n      }\n    }\n\n    return target;\n  };\n\n  return _extends.apply(this, arguments);\n}","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"hooks\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"compose\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"blockEditor\"];","/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { addFilter } from '@wordpress/hooks';\nimport { createHigherOrderComponent } from '@wordpress/compose';\nimport {\n\tInnerBlocks,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\n\nfunction CustomAppender() {\n\treturn <InnerBlocks.ButtonBlockAppender isToggle />;\n}\n\nfunction EnhancedNavigationBlock( { blockEdit: BlockEdit, ...props } ) {\n\tconst clientId = props.clientId;\n\tconst {\n\t\tnoBlockSelected,\n\t\tisSelected,\n\t\tisImmediateParentOfSelectedBlock,\n\t\tselectedBlockHasDescendants,\n\t} = useSelect(\n\t\t( select ) => {\n\t\t\tconst {\n\t\t\t\tgetClientIdsOfDescendants,\n\t\t\t\thasSelectedInnerBlock,\n\t\t\t\tgetSelectedBlockClientId,\n\t\t\t} = select( blockEditorStore );\n\t\t\tconst _isImmediateParentOfSelectedBlock = hasSelectedInnerBlock(\n\t\t\t\tclientId,\n\t\t\t\tfalse\n\t\t\t);\n\t\t\tconst selectedBlockId = getSelectedBlockClientId();\n\t\t\tconst _selectedBlockHasDescendants = !! getClientIdsOfDescendants( [\n\t\t\t\tselectedBlockId,\n\t\t\t] )?.length;\n\n\t\t\treturn {\n\t\t\t\tisSelected: selectedBlockId === clientId,\n\t\t\t\tnoBlockSelected: ! selectedBlockId,\n\t\t\t\tisImmediateParentOfSelectedBlock:\n\t\t\t\t\t_isImmediateParentOfSelectedBlock,\n\t\t\t\tselectedBlockHasDescendants: _selectedBlockHasDescendants,\n\t\t\t};\n\t\t},\n\t\t[ clientId ]\n\t);\n\n\tconst customAppender =\n\t\tnoBlockSelected ||\n\t\tisSelected ||\n\t\t( isImmediateParentOfSelectedBlock && ! selectedBlockHasDescendants )\n\t\t\t? CustomAppender\n\t\t\t: false;\n\n\treturn <BlockEdit { ...props } customAppender={ customAppender } />;\n}\n\nconst addNavigationEditorCustomAppender = createHigherOrderComponent(\n\t( BlockEdit ) => ( props ) => {\n\t\tif ( props.name !== 'core/navigation' ) {\n\t\t\treturn <BlockEdit { ...props } />;\n\t\t}\n\n\t\t// Use a separate component so that `useSelect` only run on the navigation block.\n\t\treturn <EnhancedNavigationBlock blockEdit={ BlockEdit } { ...props } />;\n\t},\n\t'withNavigationEditorCustomAppender'\n);\n\nexport default () =>\n\taddFilter(\n\t\t'editor.BlockEdit',\n\t\t'core/edit-navigation/with-navigation-editor-custom-appender',\n\t\taddNavigationEditorCustomAppender\n\t);\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"components\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"primitives\"];","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst chevronDown = (\n\t<SVG viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t<Path d=\"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z\" />\n\t</SVG>\n);\n\nexport default chevronDown;\n","/**\n * WordPress dependencies\n */\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n/**\n * Internal dependencies\n */\nimport { MENU_KIND, MENU_POST_TYPE } from '../constants';\n\nexport default function useMenuEntity( menuId ) {\n\tconst { editEntityRecord } = useDispatch( coreStore );\n\n\tconst menuEntityData = [ MENU_KIND, MENU_POST_TYPE, menuId ];\n\tconst { editedMenu, hasLoadedEditedMenu } = useSelect(\n\t\t( select ) => {\n\t\t\treturn {\n\t\t\t\teditedMenu:\n\t\t\t\t\tmenuId &&\n\t\t\t\t\tselect( coreStore ).getEditedEntityRecord(\n\t\t\t\t\t\t...menuEntityData\n\t\t\t\t\t),\n\t\t\t\thasLoadedEditedMenu: select( coreStore ).hasFinishedResolution(\n\t\t\t\t\t'getEditedEntityRecord',\n\t\t\t\t\t[ ...menuEntityData ]\n\t\t\t\t),\n\t\t\t};\n\t\t},\n\t\t[ menuId ]\n\t);\n\n\treturn {\n\t\teditedMenu,\n\t\tmenuEntityData,\n\t\teditMenuEntityRecord: editEntityRecord,\n\t\thasLoadedEditedMenu,\n\t};\n}\n","/**\n * WordPress dependencies\n */\nimport { useEntityProp } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { MENU_KIND, MENU_POST_TYPE } from '../constants';\n\n/**\n * Returns the value and setter for the specified\n * property of the menu.\n *\n * @param {string} prop   A Property name.\n * @param {string} menuId A menu ID.\n *\n * @return {[*, Function]} A tuple where the first item is the\n *                         property value and the second is the\n *                         setter.\n */\nexport default function useMenuEntityProp( prop, menuId ) {\n\treturn useEntityProp( MENU_KIND, MENU_POST_TYPE, prop, menuId );\n}\n","/**\n * WordPress dependencies\n */\nimport { __, sprintf } from '@wordpress/i18n';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { useState, useEffect } from '@wordpress/element';\nimport { store as noticesStore } from '@wordpress/notices';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { store as editNavigationStore } from '../store';\nimport { useSelectedMenuId } from './index';\nimport useMenuEntity from './use-menu-entity';\n\nconst getMenusData = ( select ) => {\n\tconst selectors = select( 'core' );\n\tconst params = { per_page: -1 };\n\treturn {\n\t\tmenus: selectors.getMenus( params ),\n\t\thasLoadedMenus: selectors.hasFinishedResolution( 'getMenus', [\n\t\t\tparams,\n\t\t] ),\n\t};\n};\nexport default function useNavigationEditor() {\n\tconst { deleteMenu: _deleteMenu } = useDispatch( coreStore );\n\tconst [ selectedMenuId, setSelectedMenuId ] = useSelectedMenuId();\n\tconst [ hasFinishedInitialLoad, setHasFinishedInitialLoad ] =\n\t\tuseState( false );\n\tconst { editedMenu, hasLoadedEditedMenu } = useMenuEntity( selectedMenuId );\n\tconst { menus, hasLoadedMenus } = useSelect( getMenusData, [] );\n\n\t/**\n\t * If the Menu being edited has been requested from API and it has\n\t * no values then it has been deleted so reset the selected menu ID.\n\t */\n\tuseEffect( () => {\n\t\tif ( hasLoadedEditedMenu && ! Object.keys( editedMenu )?.length ) {\n\t\t\tsetSelectedMenuId( null );\n\t\t}\n\t}, [ hasLoadedEditedMenu, editedMenu ] );\n\n\tconst { createErrorNotice, createInfoNotice } = useDispatch( noticesStore );\n\tconst isMenuBeingDeleted = useSelect(\n\t\t( select ) =>\n\t\t\tselect( coreStore ).isDeletingEntityRecord(\n\t\t\t\t'root',\n\t\t\t\t'menu',\n\t\t\t\tselectedMenuId\n\t\t\t),\n\t\t[ selectedMenuId ]\n\t);\n\tconst selectedMenuName =\n\t\tmenus?.find( ( { id } ) => id === selectedMenuId )?.name || '';\n\n\tuseEffect( () => {\n\t\tif ( hasLoadedMenus ) {\n\t\t\tsetHasFinishedInitialLoad( true );\n\t\t}\n\t}, [ hasLoadedMenus ] );\n\n\tconst navigationPost = useSelect(\n\t\t( select ) => {\n\t\t\tif ( ! selectedMenuId ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\treturn select( editNavigationStore ).getNavigationPostForMenu(\n\t\t\t\tselectedMenuId\n\t\t\t);\n\t\t},\n\t\t[ selectedMenuId ]\n\t);\n\n\tconst deleteMenu = async () => {\n\t\tconst didDeleteMenu = await _deleteMenu( selectedMenuId, {\n\t\t\tforce: true,\n\t\t} );\n\t\tif ( didDeleteMenu ) {\n\t\t\tsetSelectedMenuId( null );\n\t\t\tcreateInfoNotice(\n\t\t\t\tsprintf(\n\t\t\t\t\t// translators: %s: the name of a menu.\n\t\t\t\t\t__( '\"%s\" menu has been deleted' ),\n\t\t\t\t\tselectedMenuName\n\t\t\t\t),\n\t\t\t\t{\n\t\t\t\t\ttype: 'snackbar',\n\t\t\t\t\tisDismissible: true,\n\t\t\t\t}\n\t\t\t);\n\t\t} else {\n\t\t\tcreateErrorNotice( __( 'Menu deletion unsuccessful' ) );\n\t\t}\n\t};\n\n\treturn {\n\t\tmenus,\n\t\thasLoadedMenus,\n\t\thasFinishedInitialLoad,\n\t\tselectedMenuId,\n\t\tnavigationPost,\n\t\tisMenuBeingDeleted,\n\t\tselectMenu: setSelectedMenuId,\n\t\tdeleteMenu,\n\t\tisMenuSelected: !! selectedMenuId,\n\t};\n}\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"dom\"];","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"preferences\"];","/**\n * WordPress dependencies\n */\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { useCallback } from '@wordpress/element';\nimport { store as preferencesStore } from '@wordpress/preferences';\n\n/**\n * Returns selected menu ID and the setter.\n *\n * @return {[number, Function]} A tuple where first item is the\n *                              selected menu ID and second is\n *                              the setter.\n */\nexport default function useSelectedMenuId() {\n\tconst selectedMenuId =\n\t\tuseSelect(\n\t\t\t( select ) =>\n\t\t\t\tselect( preferencesStore ).get(\n\t\t\t\t\t'core/edit-navigation',\n\t\t\t\t\t'selectedMenuId'\n\t\t\t\t),\n\t\t\t[]\n\t\t) ?? null;\n\n\tconst { set } = useDispatch( preferencesStore );\n\tconst setSelectedMenuId = useCallback(\n\t\t( menuId ) => set( 'core/edit-navigation', 'selectedMenuId', menuId ),\n\t\t[ set ]\n\t);\n\n\treturn [ selectedMenuId, setSelectedMenuId ];\n}\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"apiFetch\"];","/**\n * WordPress dependencies\n */\nimport { useState, useEffect, useMemo, useCallback } from '@wordpress/element';\nimport apiFetch from '@wordpress/api-fetch';\n\n/**\n * External dependencies\n */\nimport { merge } from 'lodash';\n/**\n * Internal dependencies\n */\nimport { useMenuEntity, useSelectedMenuId } from './index';\n\nconst locationsForMenuId = ( menuLocationsByName, id ) =>\n\tObject.values( menuLocationsByName )\n\t\t.filter( ( { menu } ) => menu === id )\n\t\t.map( ( { name } ) => name );\n\nexport default function useMenuLocations() {\n\tconst [ menuLocationsByName, setMenuLocationsByName ] = useState( null );\n\n\tconst [ menuId ] = useSelectedMenuId();\n\tconst { editMenuEntityRecord, menuEntityData } = useMenuEntity( menuId );\n\tuseEffect( () => {\n\t\tlet isMounted = true;\n\n\t\tconst fetchMenuLocationsByName = async () => {\n\t\t\tconst newMenuLocationsByName = await apiFetch( {\n\t\t\t\tmethod: 'GET',\n\t\t\t\tpath: '/wp/v2/menu-locations',\n\t\t\t} );\n\n\t\t\tif ( isMounted ) {\n\t\t\t\tsetMenuLocationsByName( newMenuLocationsByName );\n\t\t\t}\n\t\t};\n\n\t\tfetchMenuLocationsByName();\n\t\treturn () => ( isMounted = false );\n\t}, [] );\n\n\tconst assignMenuToLocation = useCallback(\n\t\tasync ( locationName, newMenuId ) => {\n\t\t\tconst oldMenuId = menuLocationsByName[ locationName ].menu;\n\n\t\t\tconst newMenuLocationsByName = merge( menuLocationsByName, {\n\t\t\t\t[ locationName ]: { menu: newMenuId },\n\t\t\t} );\n\n\t\t\tsetMenuLocationsByName( newMenuLocationsByName );\n\n\t\t\tconst activeMenuId = newMenuId || oldMenuId;\n\t\t\teditMenuEntityRecord( ...menuEntityData, {\n\t\t\t\tlocations: locationsForMenuId(\n\t\t\t\t\tnewMenuLocationsByName,\n\t\t\t\t\tactiveMenuId\n\t\t\t\t),\n\t\t\t} );\n\t\t},\n\t\t[ menuLocationsByName ]\n\t);\n\n\tconst toggleMenuLocationAssignment = ( locationName, newMenuId ) => {\n\t\tconst idToSet =\n\t\t\tmenuLocationsByName[ locationName ].menu === newMenuId\n\t\t\t\t? 0\n\t\t\t\t: newMenuId;\n\t\tassignMenuToLocation( locationName, idToSet );\n\t};\n\n\tconst menuLocations = useMemo(\n\t\t() => Object.values( menuLocationsByName || {} ),\n\t\t[ menuLocationsByName ]\n\t);\n\n\treturn {\n\t\tmenuLocations,\n\t\tassignMenuToLocation,\n\t\ttoggleMenuLocationAssignment,\n\t};\n}\n","/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { store as blockEditorStore } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\n\nconst useNavigationEditorRootBlock = () => {\n\treturn useSelect( ( select ) => {\n\t\tconst { getBlockOrder } = select( blockEditorStore );\n\n\t\tconst lockedNavigationBlock = getBlockOrder()[ 0 ];\n\n\t\treturn {\n\t\t\tnavBlockClientId: lockedNavigationBlock,\n\t\t\tlastNavBlockItemIndex: getBlockOrder( lockedNavigationBlock )\n\t\t\t\t.length,\n\t\t};\n\t}, [] );\n};\n\nexport default useNavigationEditorRootBlock;\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { createContext } from '@wordpress/element';\n\nexport const untitledMenu = __( '(untitled menu)' );\nexport const IsMenuNameControlFocusedContext = createContext();\n\nexport { default as useMenuEntity } from './use-menu-entity';\nexport { default as useMenuEntityProp } from './use-menu-entity-prop';\nexport { default as useNavigationEditor } from './use-navigation-editor';\nexport { default as useMenuNotifications } from './use-menu-notifications';\nexport { default as useSelectedMenuId } from './use-selected-menu-id';\nexport { default as useMenuLocations } from './use-menu-locations';\nexport { default as useNavigationEditorRootBlock } from './use-navigation-editor-root-block';\n","/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore, useEntityRecords } from '@wordpress/core-data';\n\n/**\n * @typedef {Object} NavigationEntitiesData\n * @property {Array|undefined} pages                - a collection of WP Post entity objects of post type \"Page\".\n * @property {boolean}         isResolvingPages     - indicates whether the request to fetch pages is currently resolving.\n * @property {boolean}         hasResolvedPages     - indicates whether the request to fetch pages has finished resolving.\n * @property {Array|undefined} menus                - a collection of Menu entity objects.\n * @property {boolean}         isResolvingMenus     - indicates whether the request to fetch menus is currently resolving.\n * @property {boolean}         hasResolvedMenus     - indicates whether the request to fetch menus has finished resolving.\n * @property {Array|undefined} menusItems           - a collection of Menu Item entity objects for the current menuId.\n * @property {boolean}         hasResolvedMenuItems - indicates whether the request to fetch menuItems has finished resolving.\n * @property {boolean}         hasPages             - indicates whether there is currently any data for pages.\n * @property {boolean}         hasMenus             - indicates whether there is currently any data for menus.\n */\n\n/**\n * Manages fetching and resolution state for all entities required\n * for the Navigation block.\n *\n * @param {number} menuId the menu for which to retrieve menuItem data.\n * @return { NavigationEntitiesData } the entity data.\n */\nexport default function useNavigationEntities( menuId ) {\n\tconst {\n\t\trecords: menus,\n\t\tisResolving: isResolvingMenus,\n\t\thasResolved: hasResolvedMenus,\n\t} = useEntityRecords( 'root', 'menu', [ { per_page: -1 } ] );\n\n\tconst {\n\t\trecords: pages,\n\t\tisResolving: isResolvingPages,\n\t\thasResolved: hasResolvedPages,\n\t} = useEntityRecords( 'postType', 'page', {\n\t\tparent: 0,\n\t\torder: 'asc',\n\t\torderby: 'id',\n\t\tper_page: -1,\n\t} );\n\n\treturn {\n\t\tpages,\n\t\tisResolvingPages,\n\t\thasResolvedPages,\n\t\thasPages: !! ( hasResolvedPages && pages?.length ),\n\n\t\tmenus,\n\t\tisResolvingMenus,\n\t\thasResolvedMenus,\n\t\thasMenus: !! ( hasResolvedMenus && menus?.length ),\n\t\t...useMenuItemEntities( menuId ),\n\t};\n}\n\nfunction useMenuItemEntities( menuId ) {\n\tconst { menuItems, hasResolvedMenuItems = false } = useSelect(\n\t\t( select ) => {\n\t\t\tif ( ! menuId ) {\n\t\t\t\treturn {};\n\t\t\t}\n\n\t\t\tconst { getMenuItems, hasFinishedResolution } = select( coreStore );\n\t\t\tconst query = {\n\t\t\t\tmenus: menuId,\n\t\t\t\tper_page: -1,\n\t\t\t};\n\t\t\treturn {\n\t\t\t\tmenuItems: getMenuItems( query ),\n\t\t\t\thasResolvedMenuItems: hasFinishedResolution( 'getMenuItems', [\n\t\t\t\t\tquery,\n\t\t\t\t] ),\n\t\t\t};\n\t\t},\n\t\t[ menuId ]\n\t);\n\n\treturn {\n\t\tmenuItems,\n\t\thasResolvedMenuItems,\n\t};\n}\n","/**\n * WordPress dependencies\n */\nimport { createBlock } from '@wordpress/blocks';\nimport {\n\tPlaceholder,\n\tButton,\n\tDropdownMenu,\n\tMenuGroup,\n\tMenuItem,\n\tSpinner,\n} from '@wordpress/components';\nimport {\n\tforwardRef,\n\tuseCallback,\n\tuseState,\n\tuseEffect,\n} from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport { chevronDown } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport { useMenuEntityProp, useSelectedMenuId } from '../../hooks';\nimport useNavigationEntities from './use-navigation-entities';\nimport { menuItemsToBlocks } from '../../store/transform';\n\n/**\n * Convert pages to blocks.\n *\n * @param {Object[]} pages An array of pages.\n *\n * @return {WPBlock[]} An array of blocks.\n */\nfunction convertPagesToBlocks( pages ) {\n\tif ( ! pages?.length ) {\n\t\treturn null;\n\t}\n\n\treturn pages.map( ( { title, type, link: url, id } ) =>\n\t\tcreateBlock( 'core/navigation-link', {\n\t\t\ttype,\n\t\t\tid,\n\t\t\turl,\n\t\t\tlabel: ! title.rendered ? __( '(no title)' ) : title.rendered,\n\t\t\topensInNewTab: false,\n\t\t} )\n\t);\n}\n\nconst TOGGLE_PROPS = { variant: 'tertiary' };\nconst POPOVER_PROPS = { position: 'bottom center' };\n\nfunction BlockPlaceholder( { onCreate }, ref ) {\n\tconst [ selectedMenu, setSelectedMenu ] = useState();\n\tconst [ isCreatingFromMenu, setIsCreatingFromMenu ] = useState( false );\n\n\tconst [ selectedMenuId ] = useSelectedMenuId();\n\tconst [ menuName ] = useMenuEntityProp( 'name', selectedMenuId );\n\n\tconst {\n\t\tisResolvingPages,\n\t\tmenus,\n\t\tisResolvingMenus,\n\t\tmenuItems,\n\t\thasResolvedMenuItems,\n\t\tpages,\n\t\thasPages,\n\t\thasMenus,\n\t} = useNavigationEntities( selectedMenu );\n\n\tconst isLoading = isResolvingPages || isResolvingMenus;\n\n\tconst createFromMenu = useCallback( () => {\n\t\tconst { innerBlocks: blocks } = menuItemsToBlocks( menuItems );\n\t\tconst selectNavigationBlock = true;\n\t\tonCreate( blocks, selectNavigationBlock );\n\t}, [ menuItems, menuItemsToBlocks, onCreate ] );\n\n\tconst onCreateFromMenu = () => {\n\t\t// If we have menu items, create the block right away.\n\t\tif ( hasResolvedMenuItems ) {\n\t\t\tcreateFromMenu();\n\t\t\treturn;\n\t\t}\n\n\t\t// Otherwise, create the block when resolution finishes.\n\t\tsetIsCreatingFromMenu( true );\n\t};\n\n\tconst onCreateEmptyMenu = () => {\n\t\tonCreate( [] );\n\t};\n\n\tconst onCreateAllPages = () => {\n\t\tconst blocks = convertPagesToBlocks( pages );\n\t\tconst selectNavigationBlock = true;\n\t\tonCreate( blocks, selectNavigationBlock );\n\t};\n\n\tuseEffect( () => {\n\t\t// If the user selected a menu but we had to wait for menu items to\n\t\t// finish resolving, then create the block once resolution finishes.\n\t\tif ( isCreatingFromMenu && hasResolvedMenuItems ) {\n\t\t\tcreateFromMenu();\n\t\t\tsetIsCreatingFromMenu( false );\n\t\t}\n\t}, [ isCreatingFromMenu, hasResolvedMenuItems ] );\n\n\tconst selectableMenus = menus?.filter(\n\t\t( menu ) => menu.id !== selectedMenuId\n\t);\n\n\tconst hasSelectableMenus = !! selectableMenus?.length;\n\n\treturn (\n\t\t<Placeholder\n\t\t\tclassName=\"edit-navigation-block-placeholder\"\n\t\t\tlabel={ menuName }\n\t\t\tinstructions={ __(\n\t\t\t\t'This menu is empty. You can start blank and choose what to add,' +\n\t\t\t\t\t' add your existing pages, or add the content of another menu.'\n\t\t\t) }\n\t\t>\n\t\t\t<div className=\"edit-navigation-block-placeholder__controls\">\n\t\t\t\t{ isLoading && (\n\t\t\t\t\t<div ref={ ref }>\n\t\t\t\t\t\t<Spinner />\n\t\t\t\t\t</div>\n\t\t\t\t) }\n\t\t\t\t{ ! isLoading && (\n\t\t\t\t\t<div\n\t\t\t\t\t\tref={ ref }\n\t\t\t\t\t\tclassName=\"edit-navigation-block-placeholder__actions\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tvariant=\"tertiary\"\n\t\t\t\t\t\t\tonClick={ onCreateEmptyMenu }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ __( 'Start blank' ) }\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t{ hasPages ? (\n\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\tvariant={ hasMenus ? 'tertiary' : 'primary' }\n\t\t\t\t\t\t\t\tonClick={ onCreateAllPages }\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ __( 'Add all pages' ) }\n\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t) : undefined }\n\t\t\t\t\t\t{ hasSelectableMenus ? (\n\t\t\t\t\t\t\t<DropdownMenu\n\t\t\t\t\t\t\t\ttext={ __( 'Copy existing menu' ) }\n\t\t\t\t\t\t\t\ticon={ chevronDown }\n\t\t\t\t\t\t\t\ttoggleProps={ TOGGLE_PROPS }\n\t\t\t\t\t\t\t\tpopoverProps={ POPOVER_PROPS }\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ ( { onClose } ) => (\n\t\t\t\t\t\t\t\t\t<MenuGroup>\n\t\t\t\t\t\t\t\t\t\t{ selectableMenus.map( ( menu ) => {\n\t\t\t\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t\t\t\t<MenuItem\n\t\t\t\t\t\t\t\t\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tsetSelectedMenu(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tmenu.id\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tonCreateFromMenu();\n\t\t\t\t\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t\t\t\t\t\tonClose={ onClose }\n\t\t\t\t\t\t\t\t\t\t\t\t\tkey={ menu.id }\n\t\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t\t{ menu.name }\n\t\t\t\t\t\t\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\t</MenuGroup>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</DropdownMenu>\n\t\t\t\t\t\t) : undefined }\n\t\t\t\t\t</div>\n\t\t\t\t) }\n\t\t\t</div>\n\t\t</Placeholder>\n\t);\n}\n\nexport default forwardRef( BlockPlaceholder );\n","/**\n * WordPress dependencies\n */\nimport { addFilter } from '@wordpress/hooks';\nimport { createHigherOrderComponent } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport BlockPlaceholder from '../components/block-placeholder';\n\nconst addNavigationEditorPlaceholder = createHigherOrderComponent(\n\t( BlockEdit ) => ( props ) => {\n\t\tif ( props.name !== 'core/navigation' ) {\n\t\t\treturn <BlockEdit { ...props } />;\n\t\t}\n\t\treturn (\n\t\t\t<BlockEdit { ...props } customPlaceholder={ BlockPlaceholder } />\n\t\t);\n\t},\n\t'withNavigationEditorPlaceholder'\n);\n\nexport default () =>\n\taddFilter(\n\t\t'editor.BlockEdit',\n\t\t'core/edit-navigation/with-navigation-editor-placeholder',\n\t\taddNavigationEditorPlaceholder\n\t);\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst check = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z\" />\n\t</SVG>\n);\n\nexport default check;\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst starFilled = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M11.776 4.454a.25.25 0 01.448 0l2.069 4.192a.25.25 0 00.188.137l4.626.672a.25.25 0 01.139.426l-3.348 3.263a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.362.263l-4.138-2.175a.25.25 0 00-.232 0l-4.138 2.175a.25.25 0 01-.363-.263l.79-4.607a.25.25 0 00-.071-.222L4.754 9.881a.25.25 0 01.139-.426l4.626-.672a.25.25 0 00.188-.137l2.069-4.192z\" />\n\t</SVG>\n);\n\nexport default starFilled;\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst starEmpty = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path\n\t\t\tfillRule=\"evenodd\"\n\t\t\td=\"M9.706 8.646a.25.25 0 01-.188.137l-4.626.672a.25.25 0 00-.139.427l3.348 3.262a.25.25 0 01.072.222l-.79 4.607a.25.25 0 00.362.264l4.138-2.176a.25.25 0 01.233 0l4.137 2.175a.25.25 0 00.363-.263l-.79-4.607a.25.25 0 01.072-.222l3.347-3.262a.25.25 0 00-.139-.427l-4.626-.672a.25.25 0 01-.188-.137l-2.069-4.192a.25.25 0 00-.448 0L9.706 8.646zM12 7.39l-.948 1.921a1.75 1.75 0 01-1.317.957l-2.12.308 1.534 1.495c.412.402.6.982.503 1.55l-.362 2.11 1.896-.997a1.75 1.75 0 011.629 0l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39z\"\n\t\t\tclipRule=\"evenodd\"\n\t\t/>\n\t</SVG>\n);\n\nexport default starEmpty;\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"viewport\"];","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst closeSmall = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z\" />\n\t</SVG>\n);\n\nexport default closeSmall;\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"deprecated\"];","/**\n * WordPress dependencies\n */\nimport deprecated from '@wordpress/deprecated';\nimport { store as preferencesStore } from '@wordpress/preferences';\n\n/**\n * Set a default complementary area.\n *\n * @param {string} scope Complementary area scope.\n * @param {string} area  Area identifier.\n *\n * @return {Object} Action object.\n */\nexport const setDefaultComplementaryArea = ( scope, area ) => ( {\n\ttype: 'SET_DEFAULT_COMPLEMENTARY_AREA',\n\tscope,\n\tarea,\n} );\n\n/**\n * Enable the complementary area.\n *\n * @param {string} scope Complementary area scope.\n * @param {string} area  Area identifier.\n */\nexport const enableComplementaryArea =\n\t( scope, area ) =>\n\t( { registry, dispatch } ) => {\n\t\t// Return early if there's no area.\n\t\tif ( ! area ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst isComplementaryAreaVisible = registry\n\t\t\t.select( preferencesStore )\n\t\t\t.get( scope, 'isComplementaryAreaVisible' );\n\n\t\tif ( ! isComplementaryAreaVisible ) {\n\t\t\tregistry\n\t\t\t\t.dispatch( preferencesStore )\n\t\t\t\t.set( scope, 'isComplementaryAreaVisible', true );\n\t\t}\n\n\t\tdispatch( {\n\t\t\ttype: 'ENABLE_COMPLEMENTARY_AREA',\n\t\t\tscope,\n\t\t\tarea,\n\t\t} );\n\t};\n\n/**\n * Disable the complementary area.\n *\n * @param {string} scope Complementary area scope.\n */\nexport const disableComplementaryArea =\n\t( scope ) =>\n\t( { registry } ) => {\n\t\tconst isComplementaryAreaVisible = registry\n\t\t\t.select( preferencesStore )\n\t\t\t.get( scope, 'isComplementaryAreaVisible' );\n\n\t\tif ( isComplementaryAreaVisible ) {\n\t\t\tregistry\n\t\t\t\t.dispatch( preferencesStore )\n\t\t\t\t.set( scope, 'isComplementaryAreaVisible', false );\n\t\t}\n\t};\n\n/**\n * Pins an item.\n *\n * @param {string} scope Item scope.\n * @param {string} item  Item identifier.\n *\n * @return {Object} Action object.\n */\nexport const pinItem =\n\t( scope, item ) =>\n\t( { registry } ) => {\n\t\t// Return early if there's no item.\n\t\tif ( ! item ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst pinnedItems = registry\n\t\t\t.select( preferencesStore )\n\t\t\t.get( scope, 'pinnedItems' );\n\n\t\t// The item is already pinned, there's nothing to do.\n\t\tif ( pinnedItems?.[ item ] === true ) {\n\t\t\treturn;\n\t\t}\n\n\t\tregistry.dispatch( preferencesStore ).set( scope, 'pinnedItems', {\n\t\t\t...pinnedItems,\n\t\t\t[ item ]: true,\n\t\t} );\n\t};\n\n/**\n * Unpins an item.\n *\n * @param {string} scope Item scope.\n * @param {string} item  Item identifier.\n */\nexport const unpinItem =\n\t( scope, item ) =>\n\t( { registry } ) => {\n\t\t// Return early if there's no item.\n\t\tif ( ! item ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst pinnedItems = registry\n\t\t\t.select( preferencesStore )\n\t\t\t.get( scope, 'pinnedItems' );\n\n\t\tregistry.dispatch( preferencesStore ).set( scope, 'pinnedItems', {\n\t\t\t...pinnedItems,\n\t\t\t[ item ]: false,\n\t\t} );\n\t};\n\n/**\n * Returns an action object used in signalling that a feature should be toggled.\n *\n * @param {string} scope       The feature scope (e.g. core/edit-post).\n * @param {string} featureName The feature name.\n */\nexport function toggleFeature( scope, featureName ) {\n\treturn function ( { registry } ) {\n\t\tdeprecated( `dispatch( 'core/interface' ).toggleFeature`, {\n\t\t\tsince: '6.0',\n\t\t\talternative: `dispatch( 'core/preferences' ).toggle`,\n\t\t} );\n\n\t\tregistry.dispatch( preferencesStore ).toggle( scope, featureName );\n\t};\n}\n\n/**\n * Returns an action object used in signalling that a feature should be set to\n * a true or false value\n *\n * @param {string}  scope       The feature scope (e.g. core/edit-post).\n * @param {string}  featureName The feature name.\n * @param {boolean} value       The value to set.\n *\n * @return {Object} Action object.\n */\nexport function setFeatureValue( scope, featureName, value ) {\n\treturn function ( { registry } ) {\n\t\tdeprecated( `dispatch( 'core/interface' ).setFeatureValue`, {\n\t\t\tsince: '6.0',\n\t\t\talternative: `dispatch( 'core/preferences' ).set`,\n\t\t} );\n\n\t\tregistry\n\t\t\t.dispatch( preferencesStore )\n\t\t\t.set( scope, featureName, !! value );\n\t};\n}\n\n/**\n * Returns an action object used in signalling that defaults should be set for features.\n *\n * @param {string}                  scope    The feature scope (e.g. core/edit-post).\n * @param {Object<string, boolean>} defaults A key/value map of feature names to values.\n *\n * @return {Object} Action object.\n */\nexport function setFeatureDefaults( scope, defaults ) {\n\treturn function ( { registry } ) {\n\t\tdeprecated( `dispatch( 'core/interface' ).setFeatureDefaults`, {\n\t\t\tsince: '6.0',\n\t\t\talternative: `dispatch( 'core/preferences' ).setDefaults`,\n\t\t} );\n\n\t\tregistry.dispatch( preferencesStore ).setDefaults( scope, defaults );\n\t};\n}\n","/**\n * WordPress dependencies\n */\nimport { createRegistrySelector } from '@wordpress/data';\nimport deprecated from '@wordpress/deprecated';\nimport { store as preferencesStore } from '@wordpress/preferences';\n\n/**\n * Returns the complementary area that is active in a given scope.\n *\n * @param {Object} state Global application state.\n * @param {string} scope Item scope.\n *\n * @return {string | null | undefined} The complementary area that is active in the given scope.\n */\nexport const getActiveComplementaryArea = createRegistrySelector(\n\t( select ) => ( state, scope ) => {\n\t\tconst isComplementaryAreaVisible = select( preferencesStore ).get(\n\t\t\tscope,\n\t\t\t'isComplementaryAreaVisible'\n\t\t);\n\n\t\t// Return `undefined` to indicate that the user has never toggled\n\t\t// visibility, this is the vanilla default. Other code relies on this\n\t\t// nuance in the return value.\n\t\tif ( isComplementaryAreaVisible === undefined ) {\n\t\t\treturn undefined;\n\t\t}\n\n\t\t// Return `null` to indicate the user hid the complementary area.\n\t\tif ( ! isComplementaryAreaVisible ) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn state?.complementaryAreas?.[ scope ];\n\t}\n);\n\n/**\n * Returns a boolean indicating if an item is pinned or not.\n *\n * @param {Object} state Global application state.\n * @param {string} scope Scope.\n * @param {string} item  Item to check.\n *\n * @return {boolean} True if the item is pinned and false otherwise.\n */\nexport const isItemPinned = createRegistrySelector(\n\t( select ) => ( state, scope, item ) => {\n\t\tconst pinnedItems = select( preferencesStore ).get(\n\t\t\tscope,\n\t\t\t'pinnedItems'\n\t\t);\n\t\treturn pinnedItems?.[ item ] ?? true;\n\t}\n);\n\n/**\n * Returns a boolean indicating whether a feature is active for a particular\n * scope.\n *\n * @param {Object} state       The store state.\n * @param {string} scope       The scope of the feature (e.g. core/edit-post).\n * @param {string} featureName The name of the feature.\n *\n * @return {boolean} Is the feature enabled?\n */\nexport const isFeatureActive = createRegistrySelector(\n\t( select ) => ( state, scope, featureName ) => {\n\t\tdeprecated(\n\t\t\t`select( 'core/interface' ).isFeatureActive( scope, featureName )`,\n\t\t\t{\n\t\t\t\tsince: '6.0',\n\t\t\t\talternative: `select( 'core/preferences' ).get( scope, featureName )`,\n\t\t\t}\n\t\t);\n\n\t\treturn !! select( preferencesStore ).get( scope, featureName );\n\t}\n);\n","/**\n * WordPress dependencies\n */\nimport { combineReducers } from '@wordpress/data';\n\nexport function complementaryAreas( state = {}, action ) {\n\tswitch ( action.type ) {\n\t\tcase 'SET_DEFAULT_COMPLEMENTARY_AREA': {\n\t\t\tconst { scope, area } = action;\n\n\t\t\t// If there's already an area, don't overwrite it.\n\t\t\tif ( state[ scope ] ) {\n\t\t\t\treturn state;\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\t...state,\n\t\t\t\t[ scope ]: area,\n\t\t\t};\n\t\t}\n\t\tcase 'ENABLE_COMPLEMENTARY_AREA': {\n\t\t\tconst { scope, area } = action;\n\t\t\treturn {\n\t\t\t\t...state,\n\t\t\t\t[ scope ]: area,\n\t\t\t};\n\t\t}\n\t}\n\n\treturn state;\n}\n\nexport default combineReducers( {\n\tcomplementaryAreas,\n} );\n","/**\n * WordPress dependencies\n */\nimport { createReduxStore, register } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport * as actions from './actions';\nimport * as selectors from './selectors';\nimport reducer from './reducer';\nimport { STORE_NAME } from './constants';\n\n/**\n * Store definition for the interface namespace.\n *\n * @see https://github.com/WordPress/gutenberg/blob/HEAD/packages/data/README.md#createReduxStore\n *\n * @type {Object}\n */\nexport const store = createReduxStore( STORE_NAME, {\n\treducer,\n\tactions,\n\tselectors,\n} );\n\n// Once we build a more generic persistence plugin that works across types of stores\n// we'd be able to replace this with a register call.\nregister( store );\n","/**\n * The identifier for the data store.\n *\n * @type {string}\n */\nexport const STORE_NAME = 'core/interface';\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"plugins\"];","/**\n * WordPress dependencies\n */\nimport { withPluginContext } from '@wordpress/plugins';\n\nexport default withPluginContext( ( context, ownProps ) => {\n\treturn {\n\t\ticon: ownProps.icon || context.icon,\n\t\tidentifier:\n\t\t\townProps.identifier || `${ context.name }/${ ownProps.name }`,\n\t};\n} );\n","/**\n * WordPress dependencies\n */\nimport { Button } from '@wordpress/components';\nimport { useDispatch, useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { store as interfaceStore } from '../../store';\nimport complementaryAreaContext from '../complementary-area-context';\n\nfunction ComplementaryAreaToggle( {\n\tas = Button,\n\tscope,\n\tidentifier,\n\ticon,\n\tselectedIcon,\n\tname,\n\t...props\n} ) {\n\tconst ComponentToUse = as;\n\tconst isSelected = useSelect(\n\t\t( select ) =>\n\t\t\tselect( interfaceStore ).getActiveComplementaryArea( scope ) ===\n\t\t\tidentifier,\n\t\t[ identifier ]\n\t);\n\tconst { enableComplementaryArea, disableComplementaryArea } =\n\t\tuseDispatch( interfaceStore );\n\treturn (\n\t\t<ComponentToUse\n\t\t\ticon={ selectedIcon && isSelected ? selectedIcon : icon }\n\t\t\tonClick={ () => {\n\t\t\t\tif ( isSelected ) {\n\t\t\t\t\tdisableComplementaryArea( scope );\n\t\t\t\t} else {\n\t\t\t\t\tenableComplementaryArea( scope, identifier );\n\t\t\t\t}\n\t\t\t} }\n\t\t\t{ ...props }\n\t\t/>\n\t);\n}\n\nexport default complementaryAreaContext( ComplementaryAreaToggle );\n","/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { closeSmall } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport ComplementaryAreaToggle from '../complementary-area-toggle';\n\nconst ComplementaryAreaHeader = ( {\n\tsmallScreenTitle,\n\tchildren,\n\tclassName,\n\ttoggleButtonProps,\n} ) => {\n\tconst toggleButton = (\n\t\t<ComplementaryAreaToggle icon={ closeSmall } { ...toggleButtonProps } />\n\t);\n\treturn (\n\t\t<>\n\t\t\t<div className=\"components-panel__header interface-complementary-area-header__small\">\n\t\t\t\t{ smallScreenTitle && (\n\t\t\t\t\t<span className=\"interface-complementary-area-header__small-title\">\n\t\t\t\t\t\t{ smallScreenTitle }\n\t\t\t\t\t</span>\n\t\t\t\t) }\n\t\t\t\t{ toggleButton }\n\t\t\t</div>\n\t\t\t<div\n\t\t\t\tclassName={ classnames(\n\t\t\t\t\t'components-panel__header',\n\t\t\t\t\t'interface-complementary-area-header',\n\t\t\t\t\tclassName\n\t\t\t\t) }\n\t\t\t\ttabIndex={ -1 }\n\t\t\t>\n\t\t\t\t{ children }\n\t\t\t\t{ toggleButton }\n\t\t\t</div>\n\t\t</>\n\t);\n};\n\nexport default ComplementaryAreaHeader;\n","/**\n * WordPress dependencies\n */\nimport { ButtonGroup, Button, Slot, Fill } from '@wordpress/components';\nimport { Children } from '@wordpress/element';\n\nconst noop = () => {};\n\nfunction ActionItemSlot( {\n\tname,\n\tas: Component = ButtonGroup,\n\tfillProps = {},\n\tbubblesVirtually,\n\t...props\n} ) {\n\treturn (\n\t\t<Slot\n\t\t\tname={ name }\n\t\t\tbubblesVirtually={ bubblesVirtually }\n\t\t\tfillProps={ fillProps }\n\t\t>\n\t\t\t{ ( fills ) => {\n\t\t\t\tif ( ! Children.toArray( fills ).length ) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\t// Special handling exists for backward compatibility.\n\t\t\t\t// It ensures that menu items created by plugin authors aren't\n\t\t\t\t// duplicated with automatically injected menu items coming\n\t\t\t\t// from pinnable plugin sidebars.\n\t\t\t\t// @see https://github.com/WordPress/gutenberg/issues/14457\n\t\t\t\tconst initializedByPlugins = [];\n\t\t\t\tChildren.forEach(\n\t\t\t\t\tfills,\n\t\t\t\t\t( {\n\t\t\t\t\t\tprops: { __unstableExplicitMenuItem, __unstableTarget },\n\t\t\t\t\t} ) => {\n\t\t\t\t\t\tif ( __unstableTarget && __unstableExplicitMenuItem ) {\n\t\t\t\t\t\t\tinitializedByPlugins.push( __unstableTarget );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t\tconst children = Children.map( fills, ( child ) => {\n\t\t\t\t\tif (\n\t\t\t\t\t\t! child.props.__unstableExplicitMenuItem &&\n\t\t\t\t\t\tinitializedByPlugins.includes(\n\t\t\t\t\t\t\tchild.props.__unstableTarget\n\t\t\t\t\t\t)\n\t\t\t\t\t) {\n\t\t\t\t\t\treturn null;\n\t\t\t\t\t}\n\t\t\t\t\treturn child;\n\t\t\t\t} );\n\n\t\t\t\treturn <Component { ...props }>{ children }</Component>;\n\t\t\t} }\n\t\t</Slot>\n\t);\n}\n\nfunction ActionItem( { name, as: Component = Button, onClick, ...props } ) {\n\treturn (\n\t\t<Fill name={ name }>\n\t\t\t{ ( { onClick: fpOnClick } ) => {\n\t\t\t\treturn (\n\t\t\t\t\t<Component\n\t\t\t\t\t\tonClick={\n\t\t\t\t\t\t\tonClick || fpOnClick\n\t\t\t\t\t\t\t\t? ( ...args ) => {\n\t\t\t\t\t\t\t\t\t\t( onClick || noop )( ...args );\n\t\t\t\t\t\t\t\t\t\t( fpOnClick || noop )( ...args );\n\t\t\t\t\t\t\t\t  }\n\t\t\t\t\t\t\t\t: undefined\n\t\t\t\t\t\t}\n\t\t\t\t\t\t{ ...props }\n\t\t\t\t\t/>\n\t\t\t\t);\n\t\t\t} }\n\t\t</Fill>\n\t);\n}\n\nActionItem.Slot = ActionItemSlot;\n\nexport default ActionItem;\n","/**\n * WordPress dependencies\n */\nimport { check } from '@wordpress/icons';\nimport { MenuItem } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport ComplementaryAreaToggle from '../complementary-area-toggle';\nimport ActionItem from '../action-item';\n\nconst PluginsMenuItem = ( {\n\t// Menu item is marked with unstable prop for backward compatibility.\n\t// They are removed so they don't leak to DOM elements.\n\t// @see https://github.com/WordPress/gutenberg/issues/14457\n\t__unstableExplicitMenuItem,\n\t__unstableTarget,\n\t...restProps\n} ) => <MenuItem { ...restProps } />;\n\nexport default function ComplementaryAreaMoreMenuItem( {\n\tscope,\n\ttarget,\n\t__unstableExplicitMenuItem,\n\t...props\n} ) {\n\treturn (\n\t\t<ComplementaryAreaToggle\n\t\t\tas={ ( toggleProps ) => {\n\t\t\t\treturn (\n\t\t\t\t\t<ActionItem\n\t\t\t\t\t\t__unstableExplicitMenuItem={\n\t\t\t\t\t\t\t__unstableExplicitMenuItem\n\t\t\t\t\t\t}\n\t\t\t\t\t\t__unstableTarget={ `${ scope }/${ target }` }\n\t\t\t\t\t\tas={ PluginsMenuItem }\n\t\t\t\t\t\tname={ `${ scope }/plugin-more-menu` }\n\t\t\t\t\t\t{ ...toggleProps }\n\t\t\t\t\t/>\n\t\t\t\t);\n\t\t\t} }\n\t\t\trole=\"menuitemcheckbox\"\n\t\t\tselectedIcon={ check }\n\t\t\tname={ target }\n\t\t\tscope={ scope }\n\t\t\t{ ...props }\n\t\t/>\n\t);\n}\n","/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { Slot, Fill } from '@wordpress/components';\n\nfunction PinnedItems( { scope, ...props } ) {\n\treturn <Fill name={ `PinnedItems/${ scope }` } { ...props } />;\n}\n\nfunction PinnedItemsSlot( { scope, className, ...props } ) {\n\treturn (\n\t\t<Slot name={ `PinnedItems/${ scope }` } { ...props }>\n\t\t\t{ ( fills ) =>\n\t\t\t\tfills?.length > 0 && (\n\t\t\t\t\t<div\n\t\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t\tclassName,\n\t\t\t\t\t\t\t'interface-pinned-items'\n\t\t\t\t\t\t) }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ fills }\n\t\t\t\t\t</div>\n\t\t\t\t)\n\t\t\t}\n\t\t</Slot>\n\t);\n}\n\nPinnedItems.Slot = PinnedItemsSlot;\n\nexport default PinnedItems;\n","/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { Button, Panel, Slot, Fill } from '@wordpress/components';\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { __ } from '@wordpress/i18n';\nimport { check, starEmpty, starFilled } from '@wordpress/icons';\nimport { useEffect, useRef } from '@wordpress/element';\nimport { store as viewportStore } from '@wordpress/viewport';\n\n/**\n * Internal dependencies\n */\nimport ComplementaryAreaHeader from '../complementary-area-header';\nimport ComplementaryAreaMoreMenuItem from '../complementary-area-more-menu-item';\nimport ComplementaryAreaToggle from '../complementary-area-toggle';\nimport withComplementaryAreaContext from '../complementary-area-context';\nimport PinnedItems from '../pinned-items';\nimport { store as interfaceStore } from '../../store';\n\nfunction ComplementaryAreaSlot( { scope, ...props } ) {\n\treturn <Slot name={ `ComplementaryArea/${ scope }` } { ...props } />;\n}\n\nfunction ComplementaryAreaFill( { scope, children, className } ) {\n\treturn (\n\t\t<Fill name={ `ComplementaryArea/${ scope }` }>\n\t\t\t<div className={ className }>{ children }</div>\n\t\t</Fill>\n\t);\n}\n\nfunction useAdjustComplementaryListener(\n\tscope,\n\tidentifier,\n\tactiveArea,\n\tisActive,\n\tisSmall\n) {\n\tconst previousIsSmall = useRef( false );\n\tconst shouldOpenWhenNotSmall = useRef( false );\n\tconst { enableComplementaryArea, disableComplementaryArea } =\n\t\tuseDispatch( interfaceStore );\n\tuseEffect( () => {\n\t\t// If the complementary area is active and the editor is switching from a big to a small window size.\n\t\tif ( isActive && isSmall && ! previousIsSmall.current ) {\n\t\t\t// Disable the complementary area.\n\t\t\tdisableComplementaryArea( scope );\n\t\t\t// Flag the complementary area to be reopened when the window size goes from small to big.\n\t\t\tshouldOpenWhenNotSmall.current = true;\n\t\t} else if (\n\t\t\t// If there is a flag indicating the complementary area should be enabled when we go from small to big window size\n\t\t\t// and we are going from a small to big window size.\n\t\t\tshouldOpenWhenNotSmall.current &&\n\t\t\t! isSmall &&\n\t\t\tpreviousIsSmall.current\n\t\t) {\n\t\t\t// Remove the flag indicating the complementary area should be enabled.\n\t\t\tshouldOpenWhenNotSmall.current = false;\n\t\t\t// Enable the complementary area.\n\t\t\tenableComplementaryArea( scope, identifier );\n\t\t} else if (\n\t\t\t// If the flag is indicating the current complementary should be reopened but another complementary area becomes active,\n\t\t\t// remove the flag.\n\t\t\tshouldOpenWhenNotSmall.current &&\n\t\t\tactiveArea &&\n\t\t\tactiveArea !== identifier\n\t\t) {\n\t\t\tshouldOpenWhenNotSmall.current = false;\n\t\t}\n\t\tif ( isSmall !== previousIsSmall.current ) {\n\t\t\tpreviousIsSmall.current = isSmall;\n\t\t}\n\t}, [ isActive, isSmall, scope, identifier, activeArea ] );\n}\n\nfunction ComplementaryArea( {\n\tchildren,\n\tclassName,\n\tcloseLabel = __( 'Close plugin' ),\n\tidentifier,\n\theader,\n\theaderClassName,\n\ticon,\n\tisPinnable = true,\n\tpanelClassName,\n\tscope,\n\tname,\n\tsmallScreenTitle,\n\ttitle,\n\ttoggleShortcut,\n\tisActiveByDefault,\n\tshowIconLabels = false,\n} ) {\n\tconst { isActive, isPinned, activeArea, isSmall, isLarge } = useSelect(\n\t\t( select ) => {\n\t\t\tconst { getActiveComplementaryArea, isItemPinned } =\n\t\t\t\tselect( interfaceStore );\n\t\t\tconst _activeArea = getActiveComplementaryArea( scope );\n\t\t\treturn {\n\t\t\t\tisActive: _activeArea === identifier,\n\t\t\t\tisPinned: isItemPinned( scope, identifier ),\n\t\t\t\tactiveArea: _activeArea,\n\t\t\t\tisSmall: select( viewportStore ).isViewportMatch( '< medium' ),\n\t\t\t\tisLarge: select( viewportStore ).isViewportMatch( 'large' ),\n\t\t\t};\n\t\t},\n\t\t[ identifier, scope ]\n\t);\n\tuseAdjustComplementaryListener(\n\t\tscope,\n\t\tidentifier,\n\t\tactiveArea,\n\t\tisActive,\n\t\tisSmall\n\t);\n\tconst {\n\t\tenableComplementaryArea,\n\t\tdisableComplementaryArea,\n\t\tpinItem,\n\t\tunpinItem,\n\t} = useDispatch( interfaceStore );\n\n\tuseEffect( () => {\n\t\tif ( isActiveByDefault && activeArea === undefined && ! isSmall ) {\n\t\t\tenableComplementaryArea( scope, identifier );\n\t\t}\n\t}, [ activeArea, isActiveByDefault, scope, identifier, isSmall ] );\n\n\treturn (\n\t\t<>\n\t\t\t{ isPinnable && (\n\t\t\t\t<PinnedItems scope={ scope }>\n\t\t\t\t\t{ isPinned && (\n\t\t\t\t\t\t<ComplementaryAreaToggle\n\t\t\t\t\t\t\tscope={ scope }\n\t\t\t\t\t\t\tidentifier={ identifier }\n\t\t\t\t\t\t\tisPressed={\n\t\t\t\t\t\t\t\tisActive && ( ! showIconLabels || isLarge )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\taria-expanded={ isActive }\n\t\t\t\t\t\t\tlabel={ title }\n\t\t\t\t\t\t\ticon={ showIconLabels ? check : icon }\n\t\t\t\t\t\t\tshowTooltip={ ! showIconLabels }\n\t\t\t\t\t\t\tvariant={ showIconLabels ? 'tertiary' : undefined }\n\t\t\t\t\t\t/>\n\t\t\t\t\t) }\n\t\t\t\t</PinnedItems>\n\t\t\t) }\n\t\t\t{ name && isPinnable && (\n\t\t\t\t<ComplementaryAreaMoreMenuItem\n\t\t\t\t\ttarget={ name }\n\t\t\t\t\tscope={ scope }\n\t\t\t\t\ticon={ icon }\n\t\t\t\t>\n\t\t\t\t\t{ title }\n\t\t\t\t</ComplementaryAreaMoreMenuItem>\n\t\t\t) }\n\t\t\t{ isActive && (\n\t\t\t\t<ComplementaryAreaFill\n\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t'interface-complementary-area',\n\t\t\t\t\t\tclassName\n\t\t\t\t\t) }\n\t\t\t\t\tscope={ scope }\n\t\t\t\t>\n\t\t\t\t\t<ComplementaryAreaHeader\n\t\t\t\t\t\tclassName={ headerClassName }\n\t\t\t\t\t\tcloseLabel={ closeLabel }\n\t\t\t\t\t\tonClose={ () => disableComplementaryArea( scope ) }\n\t\t\t\t\t\tsmallScreenTitle={ smallScreenTitle }\n\t\t\t\t\t\ttoggleButtonProps={ {\n\t\t\t\t\t\t\tlabel: closeLabel,\n\t\t\t\t\t\t\tshortcut: toggleShortcut,\n\t\t\t\t\t\t\tscope,\n\t\t\t\t\t\t\tidentifier,\n\t\t\t\t\t\t} }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ header || (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t<strong>{ title }</strong>\n\t\t\t\t\t\t\t\t{ isPinnable && (\n\t\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\t\tclassName=\"interface-complementary-area__pin-unpin-item\"\n\t\t\t\t\t\t\t\t\t\ticon={\n\t\t\t\t\t\t\t\t\t\t\tisPinned ? starFilled : starEmpty\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tlabel={\n\t\t\t\t\t\t\t\t\t\t\tisPinned\n\t\t\t\t\t\t\t\t\t\t\t\t? __( 'Unpin from toolbar' )\n\t\t\t\t\t\t\t\t\t\t\t\t: __( 'Pin to toolbar' )\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tonClick={ () =>\n\t\t\t\t\t\t\t\t\t\t\t( isPinned ? unpinItem : pinItem )(\n\t\t\t\t\t\t\t\t\t\t\t\tscope,\n\t\t\t\t\t\t\t\t\t\t\t\tidentifier\n\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tisPressed={ isPinned }\n\t\t\t\t\t\t\t\t\t\taria-expanded={ isPinned }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t) }\n\t\t\t\t\t</ComplementaryAreaHeader>\n\t\t\t\t\t<Panel className={ panelClassName }>{ children }</Panel>\n\t\t\t\t</ComplementaryAreaFill>\n\t\t\t) }\n\t\t</>\n\t);\n}\n\nconst ComplementaryAreaWrapped =\n\twithComplementaryAreaContext( ComplementaryArea );\n\nComplementaryAreaWrapped.Slot = ComplementaryAreaSlot;\n\nexport default ComplementaryAreaWrapped;\n","/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { forwardRef, useEffect } from '@wordpress/element';\nimport { __unstableUseNavigateRegions as useNavigateRegions } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useMergeRefs } from '@wordpress/compose';\n\nfunction useHTMLClass( className ) {\n\tuseEffect( () => {\n\t\tconst element =\n\t\t\tdocument && document.querySelector( `html:not(.${ className })` );\n\t\tif ( ! element ) {\n\t\t\treturn;\n\t\t}\n\t\telement.classList.toggle( className );\n\t\treturn () => {\n\t\t\telement.classList.toggle( className );\n\t\t};\n\t}, [ className ] );\n}\n\nfunction InterfaceSkeleton(\n\t{\n\t\tfooter,\n\t\theader,\n\t\tsidebar,\n\t\tsecondarySidebar,\n\t\tnotices,\n\t\tcontent,\n\t\tdrawer,\n\t\tactions,\n\t\tlabels,\n\t\tclassName,\n\t\tshortcuts,\n\t},\n\tref\n) {\n\tconst navigateRegionsProps = useNavigateRegions( shortcuts );\n\n\tuseHTMLClass( 'interface-interface-skeleton__html-container' );\n\n\tconst defaultLabels = {\n\t\t/* translators: accessibility text for the nav bar landmark region. */\n\t\tdrawer: __( 'Drawer' ),\n\t\t/* translators: accessibility text for the top bar landmark region. */\n\t\theader: __( 'Header' ),\n\t\t/* translators: accessibility text for the content landmark region. */\n\t\tbody: __( 'Content' ),\n\t\t/* translators: accessibility text for the secondary sidebar landmark region. */\n\t\tsecondarySidebar: __( 'Block Library' ),\n\t\t/* translators: accessibility text for the settings landmark region. */\n\t\tsidebar: __( 'Settings' ),\n\t\t/* translators: accessibility text for the publish landmark region. */\n\t\tactions: __( 'Publish' ),\n\t\t/* translators: accessibility text for the footer landmark region. */\n\t\tfooter: __( 'Footer' ),\n\t};\n\n\tconst mergedLabels = { ...defaultLabels, ...labels };\n\n\treturn (\n\t\t<div\n\t\t\t{ ...navigateRegionsProps }\n\t\t\tref={ useMergeRefs( [ ref, navigateRegionsProps.ref ] ) }\n\t\t\tclassName={ classnames(\n\t\t\t\tclassName,\n\t\t\t\t'interface-interface-skeleton',\n\t\t\t\tnavigateRegionsProps.className,\n\t\t\t\t!! footer && 'has-footer'\n\t\t\t) }\n\t\t>\n\t\t\t{ !! drawer && (\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"interface-interface-skeleton__drawer\"\n\t\t\t\t\trole=\"region\"\n\t\t\t\t\taria-label={ mergedLabels.drawer }\n\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t>\n\t\t\t\t\t{ drawer }\n\t\t\t\t</div>\n\t\t\t) }\n\t\t\t<div className=\"interface-interface-skeleton__editor\">\n\t\t\t\t{ !! header && (\n\t\t\t\t\t<div\n\t\t\t\t\t\tclassName=\"interface-interface-skeleton__header\"\n\t\t\t\t\t\trole=\"region\"\n\t\t\t\t\t\taria-label={ mergedLabels.header }\n\t\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t\t>\n\t\t\t\t\t\t{ header }\n\t\t\t\t\t</div>\n\t\t\t\t) }\n\t\t\t\t<div className=\"interface-interface-skeleton__body\">\n\t\t\t\t\t{ !! secondarySidebar && (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tclassName=\"interface-interface-skeleton__secondary-sidebar\"\n\t\t\t\t\t\t\trole=\"region\"\n\t\t\t\t\t\t\taria-label={ mergedLabels.secondarySidebar }\n\t\t\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ secondarySidebar }\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) }\n\t\t\t\t\t{ !! notices && (\n\t\t\t\t\t\t<div className=\"interface-interface-skeleton__notices\">\n\t\t\t\t\t\t\t{ notices }\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) }\n\t\t\t\t\t<div\n\t\t\t\t\t\tclassName=\"interface-interface-skeleton__content\"\n\t\t\t\t\t\trole=\"region\"\n\t\t\t\t\t\taria-label={ mergedLabels.body }\n\t\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t\t>\n\t\t\t\t\t\t{ content }\n\t\t\t\t\t</div>\n\t\t\t\t\t{ !! sidebar && (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tclassName=\"interface-interface-skeleton__sidebar\"\n\t\t\t\t\t\t\trole=\"region\"\n\t\t\t\t\t\t\taria-label={ mergedLabels.sidebar }\n\t\t\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ sidebar }\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) }\n\t\t\t\t\t{ !! actions && (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tclassName=\"interface-interface-skeleton__actions\"\n\t\t\t\t\t\t\trole=\"region\"\n\t\t\t\t\t\t\taria-label={ mergedLabels.actions }\n\t\t\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ actions }\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) }\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t{ !! footer && (\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"interface-interface-skeleton__footer\"\n\t\t\t\t\trole=\"region\"\n\t\t\t\t\taria-label={ mergedLabels.footer }\n\t\t\t\t\ttabIndex=\"-1\"\n\t\t\t\t>\n\t\t\t\t\t{ footer }\n\t\t\t\t</div>\n\t\t\t) }\n\t\t</div>\n\t);\n}\n\nexport default forwardRef( InterfaceSkeleton );\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst moreVertical = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z\" />\n\t</SVG>\n);\n\nexport default moreVertical;\n","/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { DropdownMenu } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { moreVertical } from '@wordpress/icons';\n\nexport default function MoreMenuDropdown( {\n\tas: DropdownComponent = DropdownMenu,\n\tclassName,\n\t/* translators: button label text should, if possible, be under 16 characters. */\n\tlabel = __( 'Options' ),\n\tpopoverProps,\n\ttoggleProps,\n\tchildren,\n} ) {\n\treturn (\n\t\t<DropdownComponent\n\t\t\tclassName={ classnames(\n\t\t\t\t'interface-more-menu-dropdown',\n\t\t\t\tclassName\n\t\t\t) }\n\t\t\ticon={ moreVertical }\n\t\t\tlabel={ label }\n\t\t\tpopoverProps={ {\n\t\t\t\tposition: 'bottom left',\n\t\t\t\t...popoverProps,\n\t\t\t\tclassName: classnames(\n\t\t\t\t\t'interface-more-menu-dropdown__content',\n\t\t\t\t\tpopoverProps?.className\n\t\t\t\t),\n\t\t\t} }\n\t\t\ttoggleProps={ {\n\t\t\t\ttooltipPosition: 'bottom',\n\t\t\t\t...toggleProps,\n\t\t\t} }\n\t\t>\n\t\t\t{ ( onClose ) => children( onClose ) }\n\t\t</DropdownComponent>\n\t);\n}\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"htmlEntities\"];","/**\n * WordPress dependencies\n */\nimport { useContext } from '@wordpress/element';\nimport {\n\tToolbarGroup,\n\tToolbarButton,\n\t__experimentalText as Text,\n} from '@wordpress/components';\nimport { BlockControls } from '@wordpress/block-editor';\nimport { useDispatch } from '@wordpress/data';\nimport { store as interfaceStore } from '@wordpress/interface';\nimport { sprintf, __ } from '@wordpress/i18n';\nimport { decodeEntities } from '@wordpress/html-entities';\n\n/**\n * Internal dependencies\n */\nimport {\n\tuntitledMenu,\n\tuseSelectedMenuId,\n\tuseMenuEntityProp,\n\tIsMenuNameControlFocusedContext,\n} from '../../hooks';\nimport { SIDEBAR_SCOPE, SIDEBAR_MENU } from '../../constants';\n\nexport default function NameDisplay() {\n\tconst { enableComplementaryArea } = useDispatch( interfaceStore );\n\tconst [ menuId ] = useSelectedMenuId();\n\tconst [ name ] = useMenuEntityProp( 'name', menuId );\n\tconst [ , setIsMenuNameEditFocused ] = useContext(\n\t\tIsMenuNameControlFocusedContext\n\t);\n\n\tconst menuName = decodeEntities( name ?? untitledMenu );\n\n\treturn (\n\t\t<BlockControls>\n\t\t\t<ToolbarGroup>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\taria-label={ sprintf(\n\t\t\t\t\t\t// translators: %s: the name of a menu.\n\t\t\t\t\t\t__( `Edit menu name: %s` ),\n\t\t\t\t\t\tmenuName\n\t\t\t\t\t) }\n\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\tenableComplementaryArea( SIDEBAR_SCOPE, SIDEBAR_MENU );\n\t\t\t\t\t\tsetIsMenuNameEditFocused( true );\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<Text limit={ 24 } ellipsizeMode=\"tail\" truncate>\n\t\t\t\t\t\t{ menuName }\n\t\t\t\t\t</Text>\n\t\t\t\t</ToolbarButton>\n\t\t\t</ToolbarGroup>\n\t\t</BlockControls>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { addFilter } from '@wordpress/hooks';\nimport { createHigherOrderComponent } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport NameDisplay from '../components/name-display';\n\nconst addMenuNameEditor = createHigherOrderComponent(\n\t( BlockEdit ) => ( props ) => {\n\t\tif ( props.name !== 'core/navigation' ) {\n\t\t\treturn <BlockEdit { ...props } />;\n\t\t}\n\t\treturn (\n\t\t\t<>\n\t\t\t\t<NameDisplay />\n\t\t\t\t<BlockEdit { ...props } />\n\t\t\t</>\n\t\t);\n\t},\n\t'withMenuName'\n);\n\nexport default () =>\n\taddFilter(\n\t\t'editor.BlockEdit',\n\t\t'core/edit-navigation/with-menu-name',\n\t\taddMenuNameEditor\n\t);\n","/**\n * WordPress dependencies\n */\nimport { addFilter } from '@wordpress/hooks';\n/**\n * External dependencies\n */\nimport { set } from 'lodash';\n\nfunction disableInsertingNonNavigationBlocks( settings, name ) {\n\tif (\n\t\t! [\n\t\t\t'core/navigation',\n\t\t\t'core/navigation-link',\n\t\t\t'core/navigation-submenu',\n\t\t].includes( name )\n\t) {\n\t\tset( settings, [ 'supports', 'inserter' ], false );\n\t}\n\treturn settings;\n}\n\nexport default () =>\n\taddFilter(\n\t\t'blocks.registerBlockType',\n\t\t'core/edit-navigation/disable-inserting-non-navigation-blocks',\n\t\tdisableInsertingNonNavigationBlocks\n\t);\n","/**\n * WordPress dependencies\n */\nimport { addFilter } from '@wordpress/hooks';\nimport { createHigherOrderComponent } from '@wordpress/compose';\n\nconst removeNavigationBlockEditUnsupportedFeatures = createHigherOrderComponent(\n\t( BlockEdit ) => ( props ) => {\n\t\tif ( props.name !== 'core/navigation' ) {\n\t\t\treturn <BlockEdit { ...props } />;\n\t\t}\n\n\t\treturn (\n\t\t\t<BlockEdit\n\t\t\t\t{ ...props }\n\t\t\t\thasSubmenuIndicatorSetting={ false }\n\t\t\t\thasItemJustificationControls={ false }\n\t\t\t\thasColorSettings={ false }\n\t\t\t/>\n\t\t);\n\t},\n\t'removeNavigationBlockEditUnsupportedFeatures'\n);\n\nexport default () =>\n\taddFilter(\n\t\t'editor.BlockEdit',\n\t\t'core/edit-navigation/remove-navigation-block-edit-unsupported-features',\n\t\tremoveNavigationBlockEditUnsupportedFeatures\n\t);\n","/**\n * WordPress dependencies\n */\nimport { addFilter } from '@wordpress/hooks';\n\nfunction removeNavigationBlockSettingsUnsupportedFeatures( settings, name ) {\n\tif ( name !== 'core/navigation' ) {\n\t\treturn settings;\n\t}\n\n\treturn {\n\t\t...settings,\n\t\tsupports: {\n\t\t\tcustomClassName: false,\n\t\t\thtml: false,\n\t\t\tinserter: true,\n\t\t},\n\t\t// Remove any block variations.\n\t\tvariations: undefined,\n\t};\n}\n\nexport default () =>\n\taddFilter(\n\t\t'blocks.registerBlockType',\n\t\t'core/edit-navigation/remove-navigation-block-settings-unsupported-features',\n\t\tremoveNavigationBlockSettingsUnsupportedFeatures\n\t);\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"keyboardShortcuts\"];","/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { useState, useEffect } from '@wordpress/element';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { Button, TextControl, withNotices } from '@wordpress/components';\nimport { useFocusOnMount } from '@wordpress/compose';\nimport { __unstableStripHTML as stripHTML } from '@wordpress/dom';\nimport { store as noticesStore } from '@wordpress/notices';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { MENU_POST_TYPE, MENU_KIND } from '../../constants';\n\nfunction AddMenu( {\n\tclassName,\n\tonCreate,\n\ttitleText,\n\thelpText,\n\tfocusInputOnMount = false,\n\tnoticeUI,\n\tnoticeOperations,\n} ) {\n\tconst inputRef = useFocusOnMount( focusInputOnMount );\n\tconst [ menuName, setMenuName ] = useState( '' );\n\tconst [ isCreatingMenu, setIsCreatingMenu ] = useState( false );\n\tconst { createInfoNotice } = useDispatch( noticesStore );\n\tconst { saveMenu } = useDispatch( coreStore );\n\n\tconst { createErrorNotice, removeAllNotices } = noticeOperations;\n\n\tconst lastSaveError = useSelect( ( select ) => {\n\t\treturn select( coreStore ).getLastEntitySaveError(\n\t\t\tMENU_KIND,\n\t\t\tMENU_POST_TYPE\n\t\t);\n\t}, [] );\n\n\tuseEffect( () => {\n\t\tif ( lastSaveError ) {\n\t\t\tcreateErrorNotice( stripHTML( lastSaveError?.message ) );\n\t\t}\n\t}, [ lastSaveError ] );\n\n\tconst createMenu = async ( event ) => {\n\t\tevent.preventDefault();\n\n\t\tif ( ! menuName.length || isCreatingMenu ) {\n\t\t\treturn;\n\t\t}\n\n\t\tsetIsCreatingMenu( true );\n\n\t\t// Remove any existing notices.\n\t\tremoveAllNotices();\n\n\t\tconst menu = await saveMenu( { name: menuName } );\n\n\t\tsetIsCreatingMenu( false );\n\n\t\tif ( menu ) {\n\t\t\tcreateInfoNotice( __( 'Menu created' ), {\n\t\t\t\ttype: 'snackbar',\n\t\t\t\tisDismissible: true,\n\t\t\t} );\n\t\t\tif ( onCreate ) {\n\t\t\t\tonCreate( menu.id );\n\t\t\t}\n\t\t}\n\t};\n\n\treturn (\n\t\t<form\n\t\t\tclassName={ classnames( 'edit-navigation-add-menu', className ) }\n\t\t\tonSubmit={ createMenu }\n\t\t>\n\t\t\t{ noticeUI }\n\t\t\t{ titleText && (\n\t\t\t\t<h3 className=\"edit-navigation-add-menu__title\">\n\t\t\t\t\t{ titleText }\n\t\t\t\t</h3>\n\t\t\t) }\n\t\t\t<TextControl\n\t\t\t\tref={ inputRef }\n\t\t\t\tlabel={ __( 'Menu name' ) }\n\t\t\t\tvalue={ menuName }\n\t\t\t\tonChange={ setMenuName }\n\t\t\t\thelp={ helpText }\n\t\t\t/>\n\n\t\t\t<Button\n\t\t\t\tclassName=\"edit-navigation-add-menu__create-menu-button\"\n\t\t\t\ttype=\"submit\"\n\t\t\t\tvariant=\"primary\"\n\t\t\t\tdisabled={ ! menuName.length }\n\t\t\t\tisBusy={ isCreatingMenu }\n\t\t\t\t/* Button is disabled but still focusable. */\n\t\t\t\taria-disabled={ ! menuName.length || isCreatingMenu }\n\t\t\t>\n\t\t\t\t{ __( 'Create menu' ) }\n\t\t\t</Button>\n\t\t</form>\n\t);\n}\n\nexport default withNotices( AddMenu );\n","/**\n * WordPress dependencies\n */\nimport {\n\tMenuGroup,\n\tMenuItemsChoice,\n\tMenuItem,\n\tModal,\n} from '@wordpress/components';\nimport { useState } from '@wordpress/element';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { decodeEntities } from '@wordpress/html-entities';\n\n/**\n * Internal dependencies\n */\nimport AddMenu from '../add-menu';\n\nconst noop = () => {};\n\nexport default function MenuSwitcher( {\n\tmenus,\n\tselectedMenuId,\n\tonSelectMenu = noop,\n} ) {\n\tconst [ isModalVisible, setIsModalVisible ] = useState( false );\n\tconst openModal = () => setIsModalVisible( true );\n\tconst closeModal = () => setIsModalVisible( false );\n\n\treturn (\n\t\t<>\n\t\t\t<MenuGroup>\n\t\t\t\t<MenuItemsChoice\n\t\t\t\t\tvalue={ selectedMenuId }\n\t\t\t\t\tonSelect={ onSelectMenu }\n\t\t\t\t\tchoices={ menus.map( ( { id, name } ) => ( {\n\t\t\t\t\t\tvalue: id,\n\t\t\t\t\t\tlabel: decodeEntities( name ),\n\t\t\t\t\t\t'aria-label': sprintf(\n\t\t\t\t\t\t\t/* translators: %s: The name of a menu. */\n\t\t\t\t\t\t\t__( \"Switch to '%s'\" ),\n\t\t\t\t\t\t\tname\n\t\t\t\t\t\t),\n\t\t\t\t\t} ) ) }\n\t\t\t\t/>\n\t\t\t</MenuGroup>\n\t\t\t<MenuGroup hideSeparator>\n\t\t\t\t<MenuItem\n\t\t\t\t\tclassName=\"edit-navigation-menu-switcher__new-button\"\n\t\t\t\t\tonClick={ openModal }\n\t\t\t\t>\n\t\t\t\t\t{ __( 'Create a new menu' ) }\n\t\t\t\t</MenuItem>\n\t\t\t\t{ isModalVisible && (\n\t\t\t\t\t<Modal\n\t\t\t\t\t\ttitle={ __( 'Create a new menu' ) }\n\t\t\t\t\t\tclassName=\"edit-navigation-menu-switcher__modal\"\n\t\t\t\t\t\tonRequestClose={ closeModal }\n\t\t\t\t\t>\n\t\t\t\t\t\t<AddMenu\n\t\t\t\t\t\t\tonCreate={ ( menuId ) => {\n\t\t\t\t\t\t\t\tcloseModal();\n\t\t\t\t\t\t\t\tonSelectMenu( menuId );\n\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\thelpText={ __(\n\t\t\t\t\t\t\t\t'A short descriptive name for your menu.'\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t/>\n\t\t\t\t\t</Modal>\n\t\t\t\t) }\n\t\t\t</MenuGroup>\n\t\t</>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { Card, CardBody, NavigableMenu } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport AddMenu from '../add-menu';\nimport MenuSwitcher from '../menu-switcher';\n\nexport default function UnselectedMenuState( {\n\tonCreate,\n\tonSelectMenu,\n\tmenus,\n} ) {\n\tconst showMenuSwitcher = menus?.length > 0;\n\treturn (\n\t\t<div className=\"edit-navigation-empty-state\">\n\t\t\t{ showMenuSwitcher && <h4>{ __( 'Choose a menu to edit:' ) }</h4> }\n\t\t\t<Card>\n\t\t\t\t<CardBody>\n\t\t\t\t\t{ showMenuSwitcher ? (\n\t\t\t\t\t\t<NavigableMenu>\n\t\t\t\t\t\t\t<MenuSwitcher\n\t\t\t\t\t\t\t\tonSelectMenu={ onSelectMenu }\n\t\t\t\t\t\t\t\tmenus={ menus }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</NavigableMenu>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t<AddMenu\n\t\t\t\t\t\t\tonCreate={ onCreate }\n\t\t\t\t\t\t\ttitleText={ __( 'Create your first menu' ) }\n\t\t\t\t\t\t\thelpText={ __(\n\t\t\t\t\t\t\t\t'A short descriptive name for your menu.'\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\tfocusInputOnMount\n\t\t\t\t\t\t/>\n\t\t\t\t\t) }\n\t\t\t\t</CardBody>\n\t\t\t</Card>\n\t\t</div>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { Component } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport { Button } from '@wordpress/components';\nimport { Warning } from '@wordpress/block-editor';\n\nclass ErrorBoundary extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\n\t\tthis.reboot = this.reboot.bind( this );\n\n\t\tthis.state = {\n\t\t\terror: null,\n\t\t};\n\t}\n\n\tcomponentDidCatch( error ) {\n\t\tthis.setState( { error } );\n\t}\n\n\treboot() {\n\t\tif ( this.props.onError ) {\n\t\t\tthis.props.onError();\n\t\t}\n\t}\n\n\trender() {\n\t\tconst { error } = this.state;\n\t\tif ( ! error ) {\n\t\t\treturn this.props.children;\n\t\t}\n\n\t\treturn (\n\t\t\t<Warning\n\t\t\t\tclassName=\"navigation-editor-error-boundary\"\n\t\t\t\tactions={ [\n\t\t\t\t\t<Button\n\t\t\t\t\t\tkey=\"recovery\"\n\t\t\t\t\t\tonClick={ this.reboot }\n\t\t\t\t\t\tvariant=\"secondary\"\n\t\t\t\t\t>\n\t\t\t\t\t\t{ __( 'Attempt Recovery' ) }\n\t\t\t\t\t</Button>,\n\t\t\t\t] }\n\t\t\t>\n\t\t\t\t{ __(\n\t\t\t\t\t'The navigation editor has encountered an unexpected error.'\n\t\t\t\t) }\n\t\t\t</Warning>\n\t\t);\n\t}\n}\n\nexport default ErrorBoundary;\n","/**\n * WordPress dependencies\n */\nimport { useEffect } from '@wordpress/element';\nimport { useDispatch } from '@wordpress/data';\nimport {\n\tuseShortcut,\n\tstore as keyboardShortcutsStore,\n} from '@wordpress/keyboard-shortcuts';\nimport { __ } from '@wordpress/i18n';\nimport { store as coreStore } from '@wordpress/core-data';\n\nfunction NavigationEditorShortcuts( { saveBlocks } ) {\n\tuseShortcut( 'core/edit-navigation/save-menu', ( event ) => {\n\t\tevent.preventDefault();\n\t\tsaveBlocks();\n\t} );\n\n\tconst { redo, undo } = useDispatch( coreStore );\n\tuseShortcut( 'core/edit-navigation/undo', ( event ) => {\n\t\tundo();\n\t\tevent.preventDefault();\n\t} );\n\n\tuseShortcut( 'core/edit-navigation/redo', ( event ) => {\n\t\tredo();\n\t\tevent.preventDefault();\n\t} );\n\n\treturn null;\n}\n\nfunction RegisterNavigationEditorShortcuts() {\n\tconst { registerShortcut } = useDispatch( keyboardShortcutsStore );\n\tuseEffect( () => {\n\t\tregisterShortcut( {\n\t\t\tname: 'core/edit-navigation/save-menu',\n\t\t\tcategory: 'global',\n\t\t\tdescription: __( 'Save the navigation currently being edited.' ),\n\t\t\tkeyCombination: {\n\t\t\t\tmodifier: 'primary',\n\t\t\t\tcharacter: 's',\n\t\t\t},\n\t\t} );\n\t\tregisterShortcut( {\n\t\t\tname: 'core/edit-navigation/undo',\n\t\t\tcategory: 'global',\n\t\t\tdescription: __( 'Undo your last changes.' ),\n\t\t\tkeyCombination: {\n\t\t\t\tmodifier: 'primary',\n\t\t\t\tcharacter: 'z',\n\t\t\t},\n\t\t} );\n\t\tregisterShortcut( {\n\t\t\tname: 'core/edit-navigation/redo',\n\t\t\tcategory: 'global',\n\t\t\tdescription: __( 'Redo your last undo.' ),\n\t\t\tkeyCombination: {\n\t\t\t\tmodifier: 'primaryShift',\n\t\t\t\tcharacter: 'z',\n\t\t\t},\n\t\t} );\n\t}, [ registerShortcut ] );\n\n\treturn null;\n}\n\nNavigationEditorShortcuts.Register = RegisterNavigationEditorShortcuts;\n\nexport default NavigationEditorShortcuts;\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst cog = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path\n\t\t\tfillRule=\"evenodd\"\n\t\t\td=\"M10.289 4.836A1 1 0 0111.275 4h1.306a1 1 0 01.987.836l.244 1.466c.787.26 1.503.679 2.108 1.218l1.393-.522a1 1 0 011.216.437l.653 1.13a1 1 0 01-.23 1.273l-1.148.944a6.025 6.025 0 010 2.435l1.149.946a1 1 0 01.23 1.272l-.653 1.13a1 1 0 01-1.216.437l-1.394-.522c-.605.54-1.32.958-2.108 1.218l-.244 1.466a1 1 0 01-.987.836h-1.306a1 1 0 01-.986-.836l-.244-1.466a5.995 5.995 0 01-2.108-1.218l-1.394.522a1 1 0 01-1.217-.436l-.653-1.131a1 1 0 01.23-1.272l1.149-.946a6.026 6.026 0 010-2.435l-1.148-.944a1 1 0 01-.23-1.272l.653-1.131a1 1 0 011.217-.437l1.393.522a5.994 5.994 0 012.108-1.218l.244-1.466zM14.929 12a3 3 0 11-6 0 3 3 0 016 0z\"\n\t\t\tclipRule=\"evenodd\"\n\t\t/>\n\t</SVG>\n);\n\nexport default cog;\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { Button } from '@wordpress/components';\nimport { useDispatch } from '@wordpress/data';\nimport { store as interfaceStore } from '@wordpress/interface';\n\n/**\n * Internal dependencies\n */\nimport { SIDEBAR_BLOCK, SIDEBAR_MENU, SIDEBAR_SCOPE } from '../../constants';\n\nexport default function SidebarHeader( { sidebarName } ) {\n\tconst { enableComplementaryArea } = useDispatch( interfaceStore );\n\tconst openMenuSettings = () =>\n\t\tenableComplementaryArea( SIDEBAR_SCOPE, SIDEBAR_MENU );\n\tconst openBlockSettings = () =>\n\t\tenableComplementaryArea( SIDEBAR_SCOPE, SIDEBAR_BLOCK );\n\n\tconst [ menuAriaLabel, menuActiveClass ] =\n\t\tsidebarName === SIDEBAR_MENU\n\t\t\t? // translators: ARIA label for the Menu sidebar tab, selected.\n\t\t\t  [ __( 'Menu (selected)' ), 'is-active' ]\n\t\t\t: // translators: ARIA label for the Menu Settings Sidebar tab, not selected.\n\t\t\t  [ __( 'Menu' ), '' ];\n\n\tconst [ blockAriaLabel, blockActiveClass ] =\n\t\tsidebarName === SIDEBAR_BLOCK\n\t\t\t? // translators: ARIA label for the Block Settings Sidebar tab, selected.\n\t\t\t  [ __( 'Block (selected)' ), 'is-active' ]\n\t\t\t: // translators: ARIA label for the Block Settings Sidebar tab, not selected.\n\t\t\t  [ __( 'Block' ), '' ];\n\n\t/* Use a list so screen readers will announce how many tabs there are. */\n\treturn (\n\t\t<ul>\n\t\t\t<li>\n\t\t\t\t<Button\n\t\t\t\t\tonClick={ openMenuSettings }\n\t\t\t\t\tclassName={ `edit-navigation-sidebar__panel-tab ${ menuActiveClass }` }\n\t\t\t\t\taria-label={ menuAriaLabel }\n\t\t\t\t\t// translators: Data label for the Menu Settings Sidebar tab.\n\t\t\t\t\tdata-label={ __( 'Menu' ) }\n\t\t\t\t>\n\t\t\t\t\t{\n\t\t\t\t\t\t// translators: Text label for the Menu Settings Sidebar tab.\n\t\t\t\t\t\t__( 'Menu' )\n\t\t\t\t\t}\n\t\t\t\t</Button>\n\t\t\t</li>\n\t\t\t<li>\n\t\t\t\t<Button\n\t\t\t\t\tonClick={ openBlockSettings }\n\t\t\t\t\tclassName={ `edit-navigation-sidebar__panel-tab ${ blockActiveClass }` }\n\t\t\t\t\taria-label={ blockAriaLabel }\n\t\t\t\t\t// translators: Data label for the Block Settings Sidebar tab.\n\t\t\t\t\tdata-label={ __( 'Block' ) }\n\t\t\t\t>\n\t\t\t\t\t{\n\t\t\t\t\t\t// translators: Text label for the Block Settings Sidebar tab.\n\t\t\t\t\t\t__( 'Block' )\n\t\t\t\t\t}\n\t\t\t\t</Button>\n\t\t\t</li>\n\t\t</ul>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { TextControl } from '@wordpress/components';\nimport { useEffect, useRef, useContext } from '@wordpress/element';\nimport { decodeEntities } from '@wordpress/html-entities';\n\n/**\n * Internal dependencies\n */\nimport {\n\tIsMenuNameControlFocusedContext,\n\tuseMenuEntityProp,\n\tuseSelectedMenuId,\n} from '../../hooks';\n\nexport function NameEditor() {\n\tconst [ isMenuNameEditFocused, setIsMenuNameEditFocused ] = useContext(\n\t\tIsMenuNameControlFocusedContext\n\t);\n\n\tconst [ menuId ] = useSelectedMenuId();\n\tconst [ name, setName ] = useMenuEntityProp( 'name', menuId );\n\n\tconst inputRef = useRef();\n\tuseEffect( () => {\n\t\tif ( isMenuNameEditFocused ) inputRef.current.focus();\n\t}, [ isMenuNameEditFocused ] );\n\n\treturn (\n\t\t<TextControl\n\t\t\tref={ inputRef }\n\t\t\thelp={ __(\n\t\t\t\t'A short, descriptive name used to refer to this menu elsewhere.'\n\t\t\t) }\n\t\t\tlabel={ __( 'Name' ) }\n\t\t\tonBlur={ () => setIsMenuNameEditFocused( false ) }\n\t\t\tclassName=\"edit-navigation-name-editor__text-control\"\n\t\t\tvalue={ decodeEntities( name || '' ) }\n\t\t\tonChange={ setName }\n\t\t/>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { ToggleControl } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport { useMenuEntityProp } from '../../hooks';\n\nexport default function AutoAddPages( { menuId } ) {\n\tconst [ autoAddPages, setAutoAddPages ] = useMenuEntityProp(\n\t\t'auto_add',\n\t\tmenuId\n\t);\n\n\treturn (\n\t\t<ToggleControl\n\t\t\tlabel={ __( 'Add new pages' ) }\n\t\t\thelp={ __(\n\t\t\t\t'Automatically add published top-level pages to this menu.'\n\t\t\t) }\n\t\t\tchecked={ autoAddPages ?? false }\n\t\t\tonChange={ setAutoAddPages }\n\t\t/>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { PanelBody } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport { NameEditor } from '../name-editor';\nimport AutoAddPages from './auto-add-pages';\n\nexport default function MenuSettings( { menuId } ) {\n\treturn (\n\t\t<PanelBody title={ __( 'Menu settings' ) }>\n\t\t\t<NameEditor />\n\t\t\t<AutoAddPages menuId={ menuId } />\n\t\t</PanelBody>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __, sprintf } from '@wordpress/i18n';\nimport { useState } from '@wordpress/element';\nimport {\n\tButton,\n\tCheckboxControl,\n\tModal,\n\tPanelBody,\n\tSpinner,\n\tSelectControl,\n} from '@wordpress/components';\nimport { decodeEntities } from '@wordpress/html-entities';\nimport apiFetch from '@wordpress/api-fetch';\nimport { useDispatch } from '@wordpress/data';\nimport { store as noticesStore } from '@wordpress/notices';\n\n/**\n * Internal dependencies\n */\nimport { useMenuLocations } from '../../hooks';\n\nexport default function ManageLocations( {\n\tmenus,\n\tselectedMenuId,\n\tonSelectMenu,\n} ) {\n\tconst {\n\t\tmenuLocations,\n\t\tassignMenuToLocation,\n\t\ttoggleMenuLocationAssignment,\n\t} = useMenuLocations();\n\tconst [ isModalOpen, setIsModalOpen ] = useState( false );\n\tconst openModal = () => setIsModalOpen( true );\n\tconst closeModal = () => setIsModalOpen( false );\n\tconst { createSuccessNotice, createErrorNotice } =\n\t\tuseDispatch( noticesStore );\n\n\tconst validateBatchResponse = ( batchResponse ) => {\n\t\tif ( batchResponse.failed ) {\n\t\t\treturn false;\n\t\t}\n\n\t\tconst errorResponses = batchResponse.responses.filter( ( response ) => {\n\t\t\treturn 200 > response.status || 300 <= response.status;\n\t\t} );\n\n\t\treturn 1 > errorResponses.length;\n\t};\n\n\tconst handleUpdateMenuLocations = async () => {\n\t\tconst method = 'POST';\n\t\tconst batchRequests = menus.map( ( { id } ) => {\n\t\t\tconst locations = menuLocations\n\t\t\t\t.filter( ( menuLocation ) => menuLocation.menu === id )\n\t\t\t\t.map( ( menuLocation ) => menuLocation.name );\n\n\t\t\treturn {\n\t\t\t\tpath: `/wp/v2/menus/${ id }`,\n\t\t\t\tbody: {\n\t\t\t\t\tlocations,\n\t\t\t\t},\n\t\t\t\tmethod,\n\t\t\t};\n\t\t} );\n\n\t\tconst batchResponse = await apiFetch( {\n\t\t\tpath: 'batch/v1',\n\t\t\tdata: {\n\t\t\t\tvalidation: 'require-all-validate',\n\t\t\t\trequests: batchRequests,\n\t\t\t},\n\t\t\tmethod,\n\t\t} );\n\n\t\tconst isSuccess = validateBatchResponse( batchResponse );\n\n\t\tif ( isSuccess ) {\n\t\t\tcreateSuccessNotice( __( 'Menu locations have been updated.' ), {\n\t\t\t\ttype: 'snackbar',\n\t\t\t} );\n\t\t\tcloseModal();\n\t\t\treturn;\n\t\t}\n\n\t\tcreateErrorNotice(\n\t\t\t__( 'An error occurred while trying to update menu locations.' ),\n\t\t\t{ type: 'snackbar' }\n\t\t);\n\t};\n\n\tif ( ! menuLocations || ! menus?.length ) {\n\t\treturn <Spinner />;\n\t}\n\n\tif ( ! menuLocations.length ) {\n\t\treturn (\n\t\t\t<PanelBody title={ __( 'Theme locations' ) }>\n\t\t\t\t<p>{ __( 'There are no available menu locations.' ) }</p>\n\t\t\t</PanelBody>\n\t\t);\n\t}\n\n\tconst themeLocationCountTextMain = sprintf(\n\t\t// translators: Number of available theme locations.\n\t\t__(\n\t\t\t'Your current theme provides %d different locations to place menu.'\n\t\t),\n\t\tmenuLocations.length\n\t);\n\n\tconst themeLocationCountTextModal = sprintf(\n\t\t// translators: Number of available theme locations.\n\t\t__(\n\t\t\t'Your current theme supports %d different locations. Select which menu appears in each location.'\n\t\t),\n\t\tmenuLocations.length\n\t);\n\n\tconst menusWithSelection = menuLocations.map(\n\t\t( { name, description, menu } ) => {\n\t\t\tconst menuOnLocation = menus\n\t\t\t\t.filter( ( { id } ) => ! [ 0, selectedMenuId ].includes( id ) )\n\t\t\t\t.find( ( { id } ) => id === menu );\n\n\t\t\treturn (\n\t\t\t\t<li\n\t\t\t\t\tkey={ name }\n\t\t\t\t\tclassName=\"edit-navigation-manage-locations__checklist-item\"\n\t\t\t\t>\n\t\t\t\t\t<CheckboxControl\n\t\t\t\t\t\tclassName=\"edit-navigation-manage-locations__menu-location-checkbox\"\n\t\t\t\t\t\tchecked={ menu === selectedMenuId }\n\t\t\t\t\t\tonChange={ () =>\n\t\t\t\t\t\t\ttoggleMenuLocationAssignment( name, selectedMenuId )\n\t\t\t\t\t\t}\n\t\t\t\t\t\tlabel={ description }\n\t\t\t\t\t\thelp={\n\t\t\t\t\t\t\tmenuOnLocation &&\n\t\t\t\t\t\t\tsprintf(\n\t\t\t\t\t\t\t\t// translators: menu name.\n\t\t\t\t\t\t\t\t__( 'Currently using %s' ),\n\t\t\t\t\t\t\t\tdecodeEntities( menuOnLocation.name )\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}\n\t\t\t\t\t/>\n\t\t\t\t</li>\n\t\t\t);\n\t\t}\n\t);\n\n\tconst menuLocationCard = menuLocations.map( ( menuLocation ) => (\n\t\t<div\n\t\t\tkey={ menuLocation.name }\n\t\t\tclassName=\"edit-navigation-manage-locations__menu-entry\"\n\t\t>\n\t\t\t<SelectControl\n\t\t\t\tkey={ menuLocation.name }\n\t\t\t\tclassName=\"edit-navigation-manage-locations__select-menu\"\n\t\t\t\tlabel={ menuLocation.description }\n\t\t\t\tlabelPosition=\"top\"\n\t\t\t\tvalue={ decodeEntities( menuLocation.menu ) }\n\t\t\t\toptions={ [\n\t\t\t\t\t{ value: 0, label: __( 'Select a Menu' ), key: 0 },\n\t\t\t\t\t...menus.map( ( { id, name } ) => ( {\n\t\t\t\t\t\tkey: id,\n\t\t\t\t\t\tvalue: id,\n\t\t\t\t\t\tlabel: decodeEntities( name ),\n\t\t\t\t\t} ) ),\n\t\t\t\t] }\n\t\t\t\tonChange={ ( menuId ) => {\n\t\t\t\t\tassignMenuToLocation( menuLocation.name, Number( menuId ) );\n\t\t\t\t} }\n\t\t\t/>\n\t\t\t<Button\n\t\t\t\tvariant=\"secondary\"\n\t\t\t\tstyle={ {\n\t\t\t\t\tvisibility: !! menuLocation.menu ? 'visible' : 'hidden',\n\t\t\t\t} }\n\t\t\t\tclassName=\"edit-navigation-manage-locations__edit-button\"\n\t\t\t\tonClick={ () => (\n\t\t\t\t\tcloseModal(), onSelectMenu( menuLocation.menu )\n\t\t\t\t) }\n\t\t\t>\n\t\t\t\t{ __( 'Edit' ) }\n\t\t\t</Button>\n\t\t</div>\n\t) );\n\n\treturn (\n\t\t<PanelBody title={ __( 'Theme locations' ) }>\n\t\t\t<div className=\"edit-navigation-manage-locations__theme-location-text-main\">\n\t\t\t\t{ themeLocationCountTextMain }\n\t\t\t</div>\n\t\t\t<ul className=\"edit-navigation-manage-locations__checklist\">\n\t\t\t\t{ menusWithSelection }\n\t\t\t</ul>\n\t\t\t<Button\n\t\t\t\tvariant=\"secondary\"\n\t\t\t\tclassName=\"edit-navigation-manage-locations__open-menu-locations-modal-button\"\n\t\t\t\taria-expanded={ isModalOpen }\n\t\t\t\tonClick={ openModal }\n\t\t\t>\n\t\t\t\t{ __( 'Manage locations' ) }\n\t\t\t</Button>\n\t\t\t{ isModalOpen && (\n\t\t\t\t<Modal\n\t\t\t\t\tclassName=\"edit-navigation-manage-locations__modal\"\n\t\t\t\t\ttitle={ __( 'Manage locations' ) }\n\t\t\t\t\tonRequestClose={ closeModal }\n\t\t\t\t>\n\t\t\t\t\t<div className=\"edit-navigation-manage-locations__theme-location-text-modal\">\n\t\t\t\t\t\t{ themeLocationCountTextModal }\n\t\t\t\t\t</div>\n\t\t\t\t\t{ menuLocationCard }\n\t\t\t\t\t<Button\n\t\t\t\t\t\tclassName=\"edit-navigation-manage-locations__save-button\"\n\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\tonClick={ handleUpdateMenuLocations }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ __( 'Update' ) }\n\t\t\t\t\t</Button>\n\t\t\t\t</Modal>\n\t\t\t) }\n\t\t</PanelBody>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {\n\tButton,\n\tPanelBody,\n\t__experimentalConfirmDialog as ConfirmDialog,\n} from '@wordpress/components';\nimport { useState } from '@wordpress/element';\n\nexport default function DeleteMenu( { onDeleteMenu, isMenuBeingDeleted } ) {\n\tconst [ showConfirmDialog, setShowConfirmDialog ] = useState( false );\n\n\tconst handleConfirm = () => {\n\t\tsetShowConfirmDialog( false );\n\t\tonDeleteMenu();\n\t};\n\n\treturn (\n\t\t<PanelBody>\n\t\t\t<>\n\t\t\t\t<Button\n\t\t\t\t\tclassName=\"edit-navigation-inspector-additions__delete-menu-button\"\n\t\t\t\t\tvariant=\"secondary\"\n\t\t\t\t\tisDestructive\n\t\t\t\t\tisBusy={ isMenuBeingDeleted }\n\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\tsetShowConfirmDialog( true );\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t{ __( 'Delete menu' ) }\n\t\t\t\t</Button>\n\t\t\t\t<ConfirmDialog\n\t\t\t\t\tisOpen={ showConfirmDialog }\n\t\t\t\t\tonConfirm={ handleConfirm }\n\t\t\t\t\tonCancel={ () => setShowConfirmDialog( false ) }\n\t\t\t\t>\n\t\t\t\t\t{ __(\n\t\t\t\t\t\t'Are you sure you want to delete this navigation? This action cannot be undone.'\n\t\t\t\t\t) }\n\t\t\t\t</ConfirmDialog>\n\t\t\t</>\n\t\t</PanelBody>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { cog } from '@wordpress/icons';\nimport { useEffect } from '@wordpress/element';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport {\n\tBlockInspector,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\nimport {\n\tComplementaryArea,\n\tstore as interfaceStore,\n} from '@wordpress/interface';\nimport { useViewportMatch } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport SidebarHeader from './sidebar-header';\nimport MenuSettings from './menu-settings';\nimport ManageLocations from './manage-locations';\nimport DeleteMenu from './delete-menu';\nimport { SIDEBAR_BLOCK, SIDEBAR_MENU, SIDEBAR_SCOPE } from '../../constants';\n\nexport default function Sidebar( {\n\tmenuId,\n\tmenus,\n\tisMenuBeingDeleted,\n\tonDeleteMenu,\n\tonSelectMenu,\n} ) {\n\tconst isLargeViewport = useViewportMatch( 'medium' );\n\tconst { sidebar, hasBlockSelection, hasSidebarEnabled } = useSelect(\n\t\t( select ) => {\n\t\t\tconst _sidebar =\n\t\t\t\tselect( interfaceStore ).getActiveComplementaryArea(\n\t\t\t\t\tSIDEBAR_SCOPE\n\t\t\t\t);\n\n\t\t\tconst _hasSidebarEnabled = [ SIDEBAR_MENU, SIDEBAR_BLOCK ].includes(\n\t\t\t\t_sidebar\n\t\t\t);\n\n\t\t\treturn {\n\t\t\t\tsidebar: _sidebar,\n\t\t\t\thasBlockSelection:\n\t\t\t\t\t!! select( blockEditorStore ).getBlockSelectionStart(),\n\t\t\t\thasSidebarEnabled: _hasSidebarEnabled,\n\t\t\t};\n\t\t},\n\t\t[]\n\t);\n\tconst { enableComplementaryArea } = useDispatch( interfaceStore );\n\n\tuseEffect( () => {\n\t\tif ( ! hasSidebarEnabled ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( hasBlockSelection ) {\n\t\t\tenableComplementaryArea( SIDEBAR_SCOPE, SIDEBAR_BLOCK );\n\t\t} else {\n\t\t\tenableComplementaryArea( SIDEBAR_SCOPE, SIDEBAR_MENU );\n\t\t}\n\t}, [ hasBlockSelection, hasSidebarEnabled ] );\n\n\tlet sidebarName = sidebar;\n\tif ( ! hasSidebarEnabled ) {\n\t\tsidebarName = hasBlockSelection ? SIDEBAR_BLOCK : SIDEBAR_MENU;\n\t}\n\n\treturn (\n\t\t<ComplementaryArea\n\t\t\tclassName=\"edit-navigation-sidebar\"\n\t\t\t/* translators: button label text should, if possible, be under 16 characters. */\n\t\t\ttitle={ __( 'Settings' ) }\n\t\t\tcloseLabel={ __( 'Close settings' ) }\n\t\t\tscope={ SIDEBAR_SCOPE }\n\t\t\tidentifier={ sidebarName }\n\t\t\ticon={ cog }\n\t\t\tisActiveByDefault={ isLargeViewport }\n\t\t\theader={ <SidebarHeader sidebarName={ sidebarName } /> }\n\t\t\theaderClassName=\"edit-navigation-sidebar__panel-tabs\"\n\t\t\tisPinnable\n\t\t>\n\t\t\t{ sidebarName === SIDEBAR_MENU && (\n\t\t\t\t<>\n\t\t\t\t\t<MenuSettings menuId={ menuId } />\n\t\t\t\t\t<ManageLocations\n\t\t\t\t\t\tmenus={ menus }\n\t\t\t\t\t\tselectedMenuId={ menuId }\n\t\t\t\t\t\tonSelectMenu={ onSelectMenu }\n\t\t\t\t\t/>\n\t\t\t\t\t<DeleteMenu\n\t\t\t\t\t\tonDeleteMenu={ onDeleteMenu }\n\t\t\t\t\t\tisMenuBeingDeleted={ isMenuBeingDeleted }\n\t\t\t\t\t/>\n\t\t\t\t</>\n\t\t\t) }\n\t\t\t{ sidebarName === SIDEBAR_BLOCK && <BlockInspector /> }\n\t\t</ComplementaryArea>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {\n\tDropdownMenu,\n\t__experimentalText as Text,\n} from '@wordpress/components';\nimport { chevronDown } from '@wordpress/icons';\nimport { useMemo, useState } from '@wordpress/element';\nimport { decodeEntities } from '@wordpress/html-entities';\n\n/**\n * Internal dependencies\n */\nimport MenuSwitcher from '../menu-switcher';\nimport { useMenuEntityProp, useSelectedMenuId } from '../../hooks';\n\nexport default function MenuActions( { menus, isLoading } ) {\n\tconst [ selectedMenuId, setSelectedMenuId ] = useSelectedMenuId();\n\tconst [ menuName ] = useMenuEntityProp( 'name', selectedMenuId );\n\n\t// Use internal state instead of a ref to make sure that the component\n\t// re-renders when the popover's anchor updates.\n\tconst [ popoverAnchor, setPopoverAnchor ] = useState( null );\n\n\t// Memoize popoverProps to avoid returning a new object every time.\n\tconst popoverProps = useMemo(\n\t\t() => ( {\n\t\t\tclassName: 'edit-navigation-menu-actions__switcher-dropdown',\n\t\t\tposition: 'bottom center',\n\t\t\t// Use the title ref as the popover's anchor so that the dropdown is\n\t\t\t// centered over the whole title area rather than just on part of it.\n\t\t\tanchor: popoverAnchor,\n\t\t} ),\n\t\t[ popoverAnchor ]\n\t);\n\n\tif ( isLoading ) {\n\t\treturn (\n\t\t\t<div className=\"edit-navigation-menu-actions\">\n\t\t\t\t{ __( 'Loading…' ) }\n\t\t\t</div>\n\t\t);\n\t}\n\n\treturn (\n\t\t<div className=\"edit-navigation-menu-actions\">\n\t\t\t<div\n\t\t\t\tref={ setPopoverAnchor }\n\t\t\t\tclassName=\"edit-navigation-menu-actions__subtitle-wrapper\"\n\t\t\t>\n\t\t\t\t<Text\n\t\t\t\t\tsize=\"body\"\n\t\t\t\t\tclassName=\"edit-navigation-menu-actions__subtitle\"\n\t\t\t\t\tas=\"h2\"\n\t\t\t\t\tlimit={ 24 }\n\t\t\t\t\tellipsizeMode=\"tail\"\n\t\t\t\t\ttruncate\n\t\t\t\t>\n\t\t\t\t\t{ decodeEntities( menuName ) }\n\t\t\t\t</Text>\n\n\t\t\t\t<DropdownMenu\n\t\t\t\t\ticon={ chevronDown }\n\t\t\t\t\ttoggleProps={ {\n\t\t\t\t\t\tlabel: __( 'Switch menu' ),\n\t\t\t\t\t\tclassName:\n\t\t\t\t\t\t\t'edit-navigation-menu-actions__switcher-toggle',\n\t\t\t\t\t\tshowTooltip: false,\n\t\t\t\t\t\t__experimentalIsFocusable: true,\n\t\t\t\t\t} }\n\t\t\t\t\tpopoverProps={ popoverProps }\n\t\t\t\t>\n\t\t\t\t\t{ ( { onClose } ) => (\n\t\t\t\t\t\t<MenuSwitcher\n\t\t\t\t\t\t\tmenus={ menus }\n\t\t\t\t\t\t\tselectedMenuId={ selectedMenuId }\n\t\t\t\t\t\t\tonSelectMenu={ ( menuId ) => {\n\t\t\t\t\t\t\t\tsetSelectedMenuId( menuId );\n\t\t\t\t\t\t\t\tonClose();\n\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t/>\n\t\t\t\t\t) }\n\t\t\t\t</DropdownMenu>\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { Button, Modal } from '@wordpress/components';\nimport { useState } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport AddMenu from '../add-menu';\nimport { useSelectedMenuId } from '../../hooks';\n\nexport default function NewButton() {\n\tconst [ isModalOpen, setIsModalOpen ] = useState( false );\n\tconst [ , setSelectedMenuId ] = useSelectedMenuId();\n\n\treturn (\n\t\t<>\n\t\t\t<Button variant=\"tertiary\" onClick={ () => setIsModalOpen( true ) }>\n\t\t\t\t{ __( 'New menu' ) }\n\t\t\t</Button>\n\t\t\t{ isModalOpen && (\n\t\t\t\t<Modal\n\t\t\t\t\ttitle={ __( 'Create a new menu' ) }\n\t\t\t\t\tclassName=\"edit-navigation-menu-switcher__modal\"\n\t\t\t\t\tonRequestClose={ () => setIsModalOpen( false ) }\n\t\t\t\t>\n\t\t\t\t\t<AddMenu\n\t\t\t\t\t\thelpText={ __(\n\t\t\t\t\t\t\t'A short descriptive name for your menu.'\n\t\t\t\t\t\t) }\n\t\t\t\t\t\tonCreate={ ( menuId ) => {\n\t\t\t\t\t\t\tsetIsModalOpen( false );\n\t\t\t\t\t\t\tsetSelectedMenuId( menuId );\n\t\t\t\t\t\t} }\n\t\t\t\t\t/>\n\t\t\t\t</Modal>\n\t\t\t) }\n\t\t</>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { Button } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { store as editNavigationStore } from '../../store';\n\nexport default function SaveButton( { navigationPost } ) {\n\tconst { isDirty } = useSelect( ( select ) => {\n\t\tconst { __experimentalGetDirtyEntityRecords } = select( coreStore );\n\t\tconst dirtyEntityRecords = __experimentalGetDirtyEntityRecords();\n\n\t\treturn {\n\t\t\tisDirty: dirtyEntityRecords.length > 0,\n\t\t};\n\t}, [] );\n\n\tconst { saveNavigationPost } = useDispatch( editNavigationStore );\n\n\tconst disabled = ! isDirty || ! navigationPost;\n\n\treturn (\n\t\t<Button\n\t\t\tclassName=\"edit-navigation-toolbar__save-button\"\n\t\t\tvariant=\"primary\"\n\t\t\tonClick={ () => {\n\t\t\t\tsaveNavigationPost( navigationPost );\n\t\t\t} }\n\t\t\tdisabled={ disabled }\n\t\t>\n\t\t\t{ __( 'Save' ) }\n\t\t</Button>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst undo = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M18.3 11.7c-.6-.6-1.4-.9-2.3-.9H6.7l2.9-3.3-1.1-1-4.5 5L8.5 16l1-1-2.7-2.7H16c.5 0 .9.2 1.3.5 1 1 1 3.4 1 4.5v.3h1.5v-.2c0-1.5 0-4.3-1.5-5.7z\" />\n\t</SVG>\n);\n\nexport default undo;\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst redo = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M15.6 6.5l-1.1 1 2.9 3.3H8c-.9 0-1.7.3-2.3.9-1.4 1.5-1.4 4.2-1.4 5.6v.2h1.5v-.3c0-1.1 0-3.5 1-4.5.3-.3.7-.5 1.3-.5h9.2L14.5 15l1.1 1.1 4.6-4.6-4.6-5z\" />\n\t</SVG>\n);\n\nexport default redo;\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"keycodes\"];","/**\n * WordPress dependencies\n */\nimport { __, isRTL } from '@wordpress/i18n';\nimport { ToolbarButton } from '@wordpress/components';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { undo as undoIcon, redo as redoIcon } from '@wordpress/icons';\nimport { displayShortcut } from '@wordpress/keycodes';\nimport { store as coreStore } from '@wordpress/core-data';\n\nexport default function UndoButton() {\n\tconst hasUndo = useSelect(\n\t\t( select ) => select( coreStore ).hasUndo(),\n\t\t[]\n\t);\n\tconst { undo } = useDispatch( coreStore );\n\treturn (\n\t\t<ToolbarButton\n\t\t\ticon={ ! isRTL() ? undoIcon : redoIcon }\n\t\t\tlabel={ __( 'Undo' ) }\n\t\t\tshortcut={ displayShortcut.primary( 'z' ) }\n\t\t\t// If there are no undo levels we don't want to actually disable this\n\t\t\t// button, because it will remove focus for keyboard users.\n\t\t\t// See: https://github.com/WordPress/gutenberg/issues/3486\n\t\t\taria-disabled={ ! hasUndo }\n\t\t\tonClick={ hasUndo ? undo : undefined }\n\t\t/>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __, isRTL } from '@wordpress/i18n';\nimport { ToolbarButton } from '@wordpress/components';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { redo as redoIcon, undo as undoIcon } from '@wordpress/icons';\nimport { displayShortcut, isAppleOS } from '@wordpress/keycodes';\nimport { store as coreStore } from '@wordpress/core-data';\n\nexport default function RedoButton() {\n\tconst shortcut = isAppleOS()\n\t\t? displayShortcut.primaryShift( 'z' )\n\t\t: displayShortcut.primary( 'y' );\n\n\tconst hasRedo = useSelect(\n\t\t( select ) => select( coreStore ).hasRedo(),\n\t\t[]\n\t);\n\tconst { redo } = useDispatch( coreStore );\n\treturn (\n\t\t<ToolbarButton\n\t\t\ticon={ ! isRTL() ? redoIcon : undoIcon }\n\t\t\tlabel={ __( 'Redo' ) }\n\t\t\tshortcut={ shortcut }\n\t\t\t// If there are no undo levels we don't want to actually disable this\n\t\t\t// button, because it will remove focus for keyboard users.\n\t\t\t// See: https://github.com/WordPress/gutenberg/issues/3486\n\t\t\taria-disabled={ ! hasRedo }\n\t\t\tonClick={ hasRedo ? redo : undefined }\n\t\t/>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst plus = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z\" />\n\t</SVG>\n);\n\nexport default plus;\n","/**\n * WordPress dependencies\n */\nimport { store as blockEditorStore } from '@wordpress/block-editor';\nimport { Button, ToolbarItem } from '@wordpress/components';\nimport { _x } from '@wordpress/i18n';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { plus } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport { useNavigationEditorRootBlock } from '../../hooks';\nimport { store as editNavigationStore } from '../../store';\n\nfunction InserterToggle() {\n\tconst { navBlockClientId } = useNavigationEditorRootBlock();\n\n\tconst { isInserterOpened, hasInserterItems } = useSelect(\n\t\t( select ) => {\n\t\t\treturn {\n\t\t\t\thasInserterItems:\n\t\t\t\t\tselect( blockEditorStore ).hasInserterItems(\n\t\t\t\t\t\tnavBlockClientId\n\t\t\t\t\t),\n\t\t\t\tisInserterOpened:\n\t\t\t\t\tselect( editNavigationStore ).isInserterOpened(),\n\t\t\t};\n\t\t},\n\t\t[ navBlockClientId ]\n\t);\n\n\tconst { setIsInserterOpened } = useDispatch( editNavigationStore );\n\n\treturn (\n\t\t<ToolbarItem\n\t\t\tas={ Button }\n\t\t\tclassName=\"edit-navigation-header-inserter-toggle\"\n\t\t\tvariant=\"primary\"\n\t\t\tisPressed={ isInserterOpened }\n\t\t\tonMouseDown={ ( event ) => {\n\t\t\t\tevent.preventDefault();\n\t\t\t} }\n\t\t\tonClick={ () => setIsInserterOpened( ! isInserterOpened ) }\n\t\t\ticon={ plus }\n\t\t\t/* translators: button label text should, if possible, be under 16\n\t\t\t\t\tcharacters. */\n\t\t\tlabel={ _x(\n\t\t\t\t'Toggle block inserter',\n\t\t\t\t'Generic label for block inserter button'\n\t\t\t) }\n\t\t\tdisabled={ ! hasInserterItems }\n\t\t/>\n\t);\n}\n\nexport default InserterToggle;\n","/**\n * WordPress dependencies\n */\nimport { Path, SVG } from '@wordpress/primitives';\n\nconst external = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M18.2 17c0 .7-.6 1.2-1.2 1.2H7c-.7 0-1.2-.6-1.2-1.2V7c0-.7.6-1.2 1.2-1.2h3.2V4.2H7C5.5 4.2 4.2 5.5 4.2 7v10c0 1.5 1.2 2.8 2.8 2.8h10c1.5 0 2.8-1.2 2.8-2.8v-3.6h-1.5V17zM14.9 3v1.5h3.7l-6.4 6.4 1.1 1.1 6.4-6.4v3.7h1.5V3h-6.3z\" />\n\t</SVG>\n);\n\nexport default external;\n","/**\n * WordPress dependencies\n */\nimport { createSlotFill } from '@wordpress/components';\n\nconst { Fill: ToolsMoreMenuGroup, Slot } = createSlotFill(\n\t'EditNavigationToolsMoreMenuGroup'\n);\n\nToolsMoreMenuGroup.Slot = ( { fillProps } ) => (\n\t<Slot fillProps={ fillProps }>{ ( fills ) => fills }</Slot>\n);\n\nexport default ToolsMoreMenuGroup;\n","/**\n * WordPress dependencies\n */\nimport { MenuGroup, MenuItem, VisuallyHidden } from '@wordpress/components';\nimport { external } from '@wordpress/icons';\nimport { MoreMenuDropdown } from '@wordpress/interface';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport ToolsMoreMenuGroup from './tools-more-menu-group';\n\nexport default function MoreMenu() {\n\treturn (\n\t\t<MoreMenuDropdown>\n\t\t\t{ ( onClose ) => (\n\t\t\t\t<MenuGroup label={ __( 'Tools' ) }>\n\t\t\t\t\t<MenuItem\n\t\t\t\t\t\trole=\"menuitem\"\n\t\t\t\t\t\ticon={ external }\n\t\t\t\t\t\thref=\"https://github.com/WordPress/gutenberg/tree/trunk/packages/edit-navigation/docs/user-documentation.md\"\n\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t>\n\t\t\t\t\t\t{ __( 'Help' ) }\n\t\t\t\t\t\t<VisuallyHidden as=\"span\">\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t/* translators: accessibility text */\n\t\t\t\t\t\t\t\t__( '(opens in a new tab)' )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t</VisuallyHidden>\n\t\t\t\t\t</MenuItem>\n\t\t\t\t\t<ToolsMoreMenuGroup.Slot fillProps={ { onClose } } />\n\t\t\t\t</MenuGroup>\n\t\t\t) }\n\t\t</MoreMenuDropdown>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { NavigableToolbar } from '@wordpress/block-editor';\nimport { useViewportMatch } from '@wordpress/compose';\nimport { PinnedItems } from '@wordpress/interface';\n\n/**\n * Internal dependencies\n */\nimport MenuActions from './menu-actions';\nimport NewButton from './new-button';\nimport SaveButton from './save-button';\nimport UndoButton from './undo-button';\nimport RedoButton from './redo-button';\nimport InserterToggle from './inserter-toggle';\nimport MoreMenu from './more-menu';\n\nexport default function Header( {\n\tisMenuSelected,\n\tmenus,\n\tisPending,\n\tnavigationPost,\n} ) {\n\tconst isMediumViewport = useViewportMatch( 'medium' );\n\n\tif ( ! isMenuSelected ) {\n\t\treturn (\n\t\t\t<div className=\"edit-navigation-header\">\n\t\t\t\t<div className=\"edit-navigation-header__toolbar-wrapper\">\n\t\t\t\t\t<h1 className=\"edit-navigation-header__title\">\n\t\t\t\t\t\t{ __( 'Navigation' ) }\n\t\t\t\t\t</h1>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t);\n\t}\n\n\treturn (\n\t\t<div className=\"edit-navigation-header\">\n\t\t\t<div className=\"edit-navigation-header__toolbar-wrapper\">\n\t\t\t\t{ isMediumViewport && (\n\t\t\t\t\t<h1 className=\"edit-navigation-header__title\">\n\t\t\t\t\t\t{ __( 'Navigation' ) }\n\t\t\t\t\t</h1>\n\t\t\t\t) }\n\n\t\t\t\t<NavigableToolbar\n\t\t\t\t\tclassName=\"edit-navigation-header__toolbar\"\n\t\t\t\t\taria-label={ __( 'Document tools' ) }\n\t\t\t\t>\n\t\t\t\t\t<InserterToggle />\n\t\t\t\t\t{ isMediumViewport && (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<UndoButton />\n\t\t\t\t\t\t\t<RedoButton />\n\t\t\t\t\t\t</>\n\t\t\t\t\t) }\n\t\t\t\t</NavigableToolbar>\n\t\t\t</div>\n\n\t\t\t<MenuActions menus={ menus } isLoading={ isPending } />\n\n\t\t\t<div className=\"edit-navigation-header__actions\">\n\t\t\t\t{ isMediumViewport && <NewButton /> }\n\t\t\t\t<SaveButton navigationPost={ navigationPost } />\n\t\t\t\t<PinnedItems.Slot scope=\"core/edit-navigation\" />\n\t\t\t\t<MoreMenu />\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n","/**\n * External dependencies\n */\nimport { filter } from 'lodash';\n\n/**\n * WordPress dependencies\n */\nimport { NoticeList, SnackbarList } from '@wordpress/components';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { store as noticesStore } from '@wordpress/notices';\n\nexport default function EditNavigationNotices() {\n\tconst { removeNotice } = useDispatch( noticesStore );\n\tconst notices = useSelect(\n\t\t( select ) => select( noticesStore ).getNotices(),\n\t\t[]\n\t);\n\tconst dismissibleNotices = filter( notices, {\n\t\tisDismissible: true,\n\t\ttype: 'default',\n\t} );\n\tconst nonDismissibleNotices = filter( notices, {\n\t\tisDismissible: false,\n\t\ttype: 'default',\n\t} );\n\tconst snackbarNotices = filter( notices, {\n\t\ttype: 'snackbar',\n\t} );\n\n\treturn (\n\t\t<>\n\t\t\t<NoticeList\n\t\t\t\tnotices={ nonDismissibleNotices }\n\t\t\t\tclassName=\"edit-navigation-notices__notice-list\"\n\t\t\t/>\n\t\t\t<NoticeList\n\t\t\t\tnotices={ dismissibleNotices }\n\t\t\t\tclassName=\"edit-navigation-notices__notice-list\"\n\t\t\t\tonRemove={ removeNotice }\n\t\t\t/>\n\t\t\t<SnackbarList\n\t\t\t\tnotices={ snackbarNotices }\n\t\t\t\tclassName=\"edit-navigation-notices__snackbar-list\"\n\t\t\t\tonRemove={ removeNotice }\n\t\t\t/>\n\t\t</>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { BlockList, ObserveTyping, WritingFlow } from '@wordpress/block-editor';\nimport { Spinner } from '@wordpress/components';\n\nexport default function Editor( { isPending } ) {\n\treturn (\n\t\t<div className=\"edit-navigation-editor\">\n\t\t\t{ isPending ? (\n\t\t\t\t<Spinner />\n\t\t\t) : (\n\t\t\t\t<div className=\"editor-styles-wrapper\">\n\t\t\t\t\t<WritingFlow>\n\t\t\t\t\t\t<ObserveTyping>\n\t\t\t\t\t\t\t<BlockList />\n\t\t\t\t\t\t</ObserveTyping>\n\t\t\t\t\t</WritingFlow>\n\t\t\t\t</div>\n\t\t\t) }\n\t\t</div>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { SVG, Path } from '@wordpress/primitives';\n\nconst close = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z\" />\n\t</SVG>\n);\n\nexport default close;\n","/**\n * WordPress dependencies\n */\nimport { Button } from '@wordpress/components';\nimport { close } from '@wordpress/icons';\nimport {\n\t__experimentalLibrary as Library,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\nimport {\n\tuseViewportMatch,\n\t__experimentalUseDialog as useDialog,\n} from '@wordpress/compose';\nimport { useDispatch, useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { store as editNavigationStore } from '../../store';\nimport { useNavigationEditorRootBlock } from '../../hooks';\n\nconst SHOW_PREVIEWS = false;\n\nfunction InserterSidebar() {\n\tconst isMobileViewport = useViewportMatch( 'medium', '<' );\n\n\tconst { navBlockClientId, lastNavBlockItemIndex } =\n\t\tuseNavigationEditorRootBlock();\n\n\tconst { hasInserterItems, selectedBlockClientId } = useSelect(\n\t\t( select ) => {\n\t\t\treturn {\n\t\t\t\thasInserterItems:\n\t\t\t\t\tselect( blockEditorStore ).hasInserterItems(\n\t\t\t\t\t\tnavBlockClientId\n\t\t\t\t\t),\n\t\t\t\tselectedBlockClientId:\n\t\t\t\t\tselect( blockEditorStore ).getSelectedBlock()?.clientId,\n\t\t\t};\n\t\t},\n\t\t[ navBlockClientId ]\n\t);\n\n\tconst { setIsInserterOpened } = useDispatch( editNavigationStore );\n\n\tconst [ inserterDialogRef, inserterDialogProps ] = useDialog( {\n\t\tonClose: () => setIsInserterOpened( false ),\n\t} );\n\n\t// Only concerned with whether there are items to display. If not then\n\t// we shouldn't render.\n\tif ( ! hasInserterItems ) {\n\t\treturn null;\n\t}\n\n\tconst shouldInsertInNavBlock =\n\t\t! selectedBlockClientId || navBlockClientId === selectedBlockClientId;\n\n\treturn (\n\t\t<div\n\t\t\tref={ inserterDialogRef }\n\t\t\t{ ...inserterDialogProps }\n\t\t\tclassName=\"edit-navigation-layout__inserter-panel\"\n\t\t>\n\t\t\t<div className=\"edit-navigation-layout__inserter-panel-header\">\n\t\t\t\t<Button\n\t\t\t\t\ticon={ close }\n\t\t\t\t\tonClick={ () => setIsInserterOpened( false ) }\n\t\t\t\t/>\n\t\t\t</div>\n\t\t\t<div className=\"edit-navigation-layout__inserter-panel-content\">\n\t\t\t\t<Library\n\t\t\t\t\t// If the root Nav block is selected then any items inserted by the\n\t\t\t\t\t// global inserter should append after the last nav item. Otherwise\n\t\t\t\t\t// simply allow default Gutenberg behaviour.\n\t\t\t\t\trootClientId={\n\t\t\t\t\t\tshouldInsertInNavBlock ? navBlockClientId : undefined\n\t\t\t\t\t} // If set, insertion will be into the block with this ID.\n\t\t\t\t\t__experimentalInsertionIndex={\n\t\t\t\t\t\t// If set, insertion will be into this explicit position.\n\t\t\t\t\t\tshouldInsertInNavBlock\n\t\t\t\t\t\t\t? lastNavBlockItemIndex\n\t\t\t\t\t\t\t: undefined\n\t\t\t\t\t}\n\t\t\t\t\tshouldFocusBlock={ isMobileViewport }\n\t\t\t\t\tshowInserterHelpPanel={ SHOW_PREVIEWS }\n\t\t\t\t/>\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n\nexport default InserterSidebar;\n","/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { useEffect } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Warns the user if there are unsaved changes before leaving the editor.\n *\n * This is a duplicate of the component implemented in the editor package.\n * Duplicated here as edit-navigation doesn't depend on editor.\n *\n * @return {WPComponent} The component.\n */\nexport default function UnsavedChangesWarning() {\n\tconst isDirty = useSelect( ( select ) => {\n\t\tconst { __experimentalGetDirtyEntityRecords } = select( coreStore );\n\t\tconst dirtyEntityRecords = __experimentalGetDirtyEntityRecords();\n\t\treturn dirtyEntityRecords.length > 0;\n\t}, [] );\n\n\tuseEffect( () => {\n\t\t/**\n\t\t * Warns the user if there are unsaved changes before leaving the editor.\n\t\t *\n\t\t * @param {Event} event `beforeunload` event.\n\t\t *\n\t\t * @return {?string} Warning prompt message, if unsaved changes exist.\n\t\t */\n\t\tconst warnIfUnsavedChanges = ( event ) => {\n\t\t\tif ( isDirty ) {\n\t\t\t\tevent.returnValue = __(\n\t\t\t\t\t'You have unsaved changes. If you proceed, they will be lost.'\n\t\t\t\t);\n\t\t\t\treturn event.returnValue;\n\t\t\t}\n\t\t};\n\n\t\twindow.addEventListener( 'beforeunload', warnIfUnsavedChanges );\n\n\t\treturn () => {\n\t\t\twindow.removeEventListener( 'beforeunload', warnIfUnsavedChanges );\n\t\t};\n\t}, [ isDirty ] );\n\n\treturn null;\n}\n","/**\n * WordPress dependencies\n */\nimport {\n\tBlockEditorKeyboardShortcuts,\n\tBlockEditorProvider,\n\tBlockTools,\n\t__unstableUseBlockSelectionClearer as useBlockSelectionClearer,\n} from '@wordpress/block-editor';\nimport { useEntityBlockEditor } from '@wordpress/core-data';\nimport { Popover, SlotFillProvider, Spinner } from '@wordpress/components';\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { useEffect, useMemo, useState } from '@wordpress/element';\nimport {\n\tInterfaceSkeleton,\n\tComplementaryArea,\n\tstore as interfaceStore,\n} from '@wordpress/interface';\nimport { __ } from '@wordpress/i18n';\nimport { ShortcutProvider } from '@wordpress/keyboard-shortcuts';\nimport { PluginArea } from '@wordpress/plugins';\n\n/**\n * Internal dependencies\n */\nimport UnselectedMenuState from './unselected-menu-state';\nimport {\n\tIsMenuNameControlFocusedContext,\n\tuseNavigationEditor,\n\tuseMenuNotifications,\n} from '../../hooks';\nimport ErrorBoundary from '../error-boundary';\nimport NavigationEditorShortcuts from './shortcuts';\nimport Sidebar from '../sidebar';\nimport Header from '../header';\nimport Notices from '../notices';\nimport Editor from '../editor';\nimport InserterSidebar from '../inserter-sidebar';\nimport UnsavedChangesWarning from './unsaved-changes-warning';\nimport { store as editNavigationStore } from '../../store';\nimport {\n\tNAVIGATION_POST_KIND,\n\tNAVIGATION_POST_POST_TYPE,\n} from '../../constants';\n\nconst interfaceLabels = {\n\t/* translators: accessibility text for the navigation screen top bar landmark region. */\n\theader: __( 'Navigation top bar' ),\n\t/* translators: accessibility text for the navigation screen content landmark region. */\n\tbody: __( 'Navigation menu blocks' ),\n\t/* translators: accessibility text for the navigation screen settings landmark region. */\n\tsidebar: __( 'Navigation settings' ),\n\tsecondarySidebar: __( 'Block library' ),\n};\n\nexport default function Layout( { blockEditorSettings } ) {\n\tconst contentAreaRef = useBlockSelectionClearer();\n\tconst [ isMenuNameControlFocused, setIsMenuNameControlFocused ] =\n\t\tuseState( false );\n\tconst { saveNavigationPost } = useDispatch( editNavigationStore );\n\tconst savePost = () => saveNavigationPost( navigationPost );\n\n\tconst {\n\t\tmenus,\n\t\thasLoadedMenus,\n\t\thasFinishedInitialLoad,\n\t\tselectedMenuId,\n\t\tnavigationPost,\n\t\tisMenuBeingDeleted,\n\t\tselectMenu,\n\t\tdeleteMenu,\n\t\tisMenuSelected,\n\t} = useNavigationEditor();\n\n\tconst [ blocks, onInput, onChange ] = useEntityBlockEditor(\n\t\tNAVIGATION_POST_KIND,\n\t\tNAVIGATION_POST_POST_TYPE,\n\t\t{\n\t\t\tid: navigationPost?.id,\n\t\t}\n\t);\n\n\tconst { hasSidebarEnabled, isInserterOpened } = useSelect(\n\t\t( select ) => ( {\n\t\t\thasSidebarEnabled: !! select(\n\t\t\t\tinterfaceStore\n\t\t\t).getActiveComplementaryArea( 'core/edit-navigation' ),\n\t\t\tisInserterOpened: select( editNavigationStore ).isInserterOpened(),\n\t\t} ),\n\t\t[]\n\t);\n\n\tuseEffect( () => {\n\t\tif ( ! selectedMenuId && menus?.length ) {\n\t\t\tselectMenu( menus[ 0 ].id );\n\t\t}\n\t}, [ selectedMenuId, menus ] );\n\n\tuseMenuNotifications( selectedMenuId );\n\n\tconst hasMenus = !! menus?.length;\n\n\tconst isBlockEditorReady = !! (\n\t\thasMenus &&\n\t\tnavigationPost &&\n\t\tisMenuSelected\n\t);\n\n\treturn (\n\t\t<ErrorBoundary>\n\t\t\t<ShortcutProvider>\n\t\t\t\t<div\n\t\t\t\t\thidden={ ! isMenuBeingDeleted }\n\t\t\t\t\tclassName={ 'edit-navigation-layout__overlay' }\n\t\t\t\t/>\n\t\t\t\t<SlotFillProvider>\n\t\t\t\t\t<BlockEditorKeyboardShortcuts.Register />\n\t\t\t\t\t<NavigationEditorShortcuts.Register />\n\t\t\t\t\t<NavigationEditorShortcuts saveBlocks={ savePost } />\n\t\t\t\t\t<BlockEditorProvider\n\t\t\t\t\t\tvalue={ blocks }\n\t\t\t\t\t\tonInput={ onInput }\n\t\t\t\t\t\tonChange={ onChange }\n\t\t\t\t\t\tsettings={ {\n\t\t\t\t\t\t\t...blockEditorSettings,\n\t\t\t\t\t\t\ttemplateLock: 'all',\n\t\t\t\t\t\t} }\n\t\t\t\t\t\tuseSubRegistry={ false }\n\t\t\t\t\t>\n\t\t\t\t\t\t<IsMenuNameControlFocusedContext.Provider\n\t\t\t\t\t\t\tvalue={ useMemo(\n\t\t\t\t\t\t\t\t() => [\n\t\t\t\t\t\t\t\t\tisMenuNameControlFocused,\n\t\t\t\t\t\t\t\t\tsetIsMenuNameControlFocused,\n\t\t\t\t\t\t\t\t],\n\t\t\t\t\t\t\t\t[ isMenuNameControlFocused ]\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<InterfaceSkeleton\n\t\t\t\t\t\t\t\tclassName=\"edit-navigation-layout\"\n\t\t\t\t\t\t\t\tlabels={ interfaceLabels }\n\t\t\t\t\t\t\t\theader={\n\t\t\t\t\t\t\t\t\t<Header\n\t\t\t\t\t\t\t\t\t\tisMenuSelected={ isMenuSelected }\n\t\t\t\t\t\t\t\t\t\tisPending={ ! hasLoadedMenus }\n\t\t\t\t\t\t\t\t\t\tmenus={ menus }\n\t\t\t\t\t\t\t\t\t\tnavigationPost={ navigationPost }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tcontent={\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t<Notices />\n\t\t\t\t\t\t\t\t\t\t{ ! hasFinishedInitialLoad && (\n\t\t\t\t\t\t\t\t\t\t\t<Spinner />\n\t\t\t\t\t\t\t\t\t\t) }\n\n\t\t\t\t\t\t\t\t\t\t{ ! isMenuSelected &&\n\t\t\t\t\t\t\t\t\t\t\thasFinishedInitialLoad && (\n\t\t\t\t\t\t\t\t\t\t\t\t<UnselectedMenuState\n\t\t\t\t\t\t\t\t\t\t\t\t\tonSelectMenu={ selectMenu }\n\t\t\t\t\t\t\t\t\t\t\t\t\tonCreate={ selectMenu }\n\t\t\t\t\t\t\t\t\t\t\t\t\tmenus={ menus }\n\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t{ isBlockEditorReady && (\n\t\t\t\t\t\t\t\t\t\t\t<div\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"edit-navigation-layout__content-area\"\n\t\t\t\t\t\t\t\t\t\t\t\tref={ contentAreaRef }\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<BlockTools>\n\t\t\t\t\t\t\t\t\t\t\t\t\t<Editor\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tisPending={\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t! hasLoadedMenus\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t</BlockTools>\n\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tsidebar={\n\t\t\t\t\t\t\t\t\thasSidebarEnabled && (\n\t\t\t\t\t\t\t\t\t\t<ComplementaryArea.Slot scope=\"core/edit-navigation\" />\n\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tsecondarySidebar={\n\t\t\t\t\t\t\t\t\tisInserterOpened && <InserterSidebar />\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t{ isMenuSelected && (\n\t\t\t\t\t\t\t\t<Sidebar\n\t\t\t\t\t\t\t\t\tmenus={ menus }\n\t\t\t\t\t\t\t\t\tmenuId={ selectedMenuId }\n\t\t\t\t\t\t\t\t\tonSelectMenu={ selectMenu }\n\t\t\t\t\t\t\t\t\tonDeleteMenu={ deleteMenu }\n\t\t\t\t\t\t\t\t\tisMenuBeingDeleted={ isMenuBeingDeleted }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t</IsMenuNameControlFocusedContext.Provider>\n\t\t\t\t\t\t<UnsavedChangesWarning />\n\t\t\t\t\t</BlockEditorProvider>\n\t\t\t\t\t<Popover.Slot />\n\t\t\t\t\t<PluginArea />\n\t\t\t\t</SlotFillProvider>\n\t\t\t</ShortcutProvider>\n\t\t</ErrorBoundary>\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { useEffect } from '@wordpress/element';\nimport { __unstableStripHTML as stripHTML } from '@wordpress/dom';\nimport { store as noticesStore } from '@wordpress/notices';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { MENU_POST_TYPE, MENU_KIND } from '../constants';\n\nexport default function useMenuNotifications( menuId ) {\n\tconst { createErrorNotice } = useDispatch( noticesStore );\n\tconst lastDeleteError = useSelect(\n\t\t( select ) => {\n\t\t\treturn select( coreStore ).getLastEntityDeleteError(\n\t\t\t\tMENU_KIND,\n\t\t\t\tMENU_POST_TYPE,\n\t\t\t\tmenuId\n\t\t\t);\n\t\t},\n\t\t[ menuId ]\n\t);\n\n\tuseEffect( () => {\n\t\tif ( lastDeleteError ) {\n\t\t\tcreateErrorNotice( stripHTML( lastDeleteError?.message ), {\n\t\t\t\tid: 'edit-navigation-error',\n\t\t\t} );\n\t\t}\n\t}, [ lastDeleteError ] );\n}\n","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"url\"];","/**\n * WordPress dependencies\n */\nimport { normalizePath } from '@wordpress/url';\n\n/**\n * The purpose of this function is to create a middleware that is responsible for preloading menu-related data.\n * It uses data that is returned from the /wp/v2/menus endpoint for requests\n * to the /wp/v2/menu/<menuId> endpoint, because the data is the same.\n * This way, we can avoid making additional REST API requests.\n * This middleware can be removed if/when we implement caching at the wordpress/core-data level.\n *\n * @param {Object} preloadedData\n * @return {Function} Preloading middleware.\n */\nexport function createMenuPreloadingMiddleware( preloadedData ) {\n\tconst cache = Object.keys( preloadedData ).reduce( ( result, path ) => {\n\t\tresult[ normalizePath( path ) ] = preloadedData[ path ];\n\t\treturn result;\n\t}, /** @type {Record<string, any>} */ ( {} ) );\n\n\tlet menusDataLoaded = false;\n\tlet menuDataLoaded = false;\n\n\treturn ( options, next ) => {\n\t\tconst { parse = true } = options;\n\t\tif ( 'string' !== typeof options.path ) {\n\t\t\treturn next( options );\n\t\t}\n\n\t\tconst method = options.method || 'GET';\n\t\tif ( 'GET' !== method ) {\n\t\t\treturn next( options );\n\t\t}\n\n\t\tconst path = normalizePath( options.path );\n\t\tif ( ! menusDataLoaded && cache[ path ] ) {\n\t\t\tmenusDataLoaded = true;\n\t\t\treturn sendSuccessResponse( cache[ path ], parse );\n\t\t}\n\n\t\tif ( menuDataLoaded ) {\n\t\t\treturn next( options );\n\t\t}\n\n\t\tconst matches = path.match( /^\\/wp\\/v2\\/menus\\/(\\d+)\\?context=edit$/ );\n\t\tif ( ! matches ) {\n\t\t\treturn next( options );\n\t\t}\n\n\t\tconst key = Object.keys( cache )?.[ 0 ];\n\t\tconst menuData = cache[ key ]?.body;\n\t\tif ( ! menuData ) {\n\t\t\treturn next( options );\n\t\t}\n\n\t\tconst menuId = parseInt( matches[ 1 ] );\n\t\tconst menu = menuData.filter( ( { id } ) => id === menuId );\n\n\t\tif ( menu.length > 0 ) {\n\t\t\tmenuDataLoaded = true;\n\t\t\t// We don't have headers because we \"emulate\" this request.\n\t\t\treturn sendSuccessResponse(\n\t\t\t\t{ body: menu[ 0 ], headers: {} },\n\t\t\t\tparse\n\t\t\t);\n\t\t}\n\n\t\treturn next( options );\n\t};\n}\n\n/**\n * This is a helper function that sends a success response.\n *\n * @param {Object}  responseData An object with the menu data\n * @param {boolean} parse        A boolean that controls whether to send a response or just the response data\n * @return {Object} Resolved promise\n */\nfunction sendSuccessResponse( responseData, parse ) {\n\treturn Promise.resolve(\n\t\tparse\n\t\t\t? responseData.body\n\t\t\t: new window.Response( JSON.stringify( responseData.body ), {\n\t\t\t\t\tstatus: 200,\n\t\t\t\t\tstatusText: 'OK',\n\t\t\t\t\theaders: responseData.headers,\n\t\t\t  } )\n\t);\n}\n","/**\n * WordPress dependencies\n */\nimport { store as blocksStore } from '@wordpress/blocks';\nimport {\n\tregisterCoreBlocks,\n\t__experimentalRegisterExperimentalCoreBlocks,\n} from '@wordpress/block-library';\nimport { dispatch, useDispatch } from '@wordpress/data';\nimport { render, useMemo } from '@wordpress/element';\nimport {\n\t__experimentalFetchUrlData,\n\t__experimentalFetchLinkSuggestions as fetchLinkSuggestions,\n\tstore as coreStore,\n} from '@wordpress/core-data';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport { NAVIGATION_POST_KIND, NAVIGATION_POST_POST_TYPE } from './constants';\nimport { store as editNavigationStore } from './store';\nimport { addFilters } from './filters';\nimport Layout from './components/layout';\n\nfunction NavEditor( { settings } ) {\n\tconst { setIsInserterOpened } = useDispatch( editNavigationStore );\n\n\t// Allows the QuickInserter to toggle the sidebar inserter.\n\t// This is marked as experimental to give time for the quick inserter to mature.\n\tconst __experimentalSetIsInserterOpened = setIsInserterOpened;\n\n\t// Provide link suggestions handler to fetch search results for Link UI.\n\tconst __experimentalFetchLinkSuggestions = ( search, searchOptions ) => {\n\t\t// Bump the default number of suggestions.\n\t\t// See https://github.com/WordPress/gutenberg/issues/34283.\n\t\tsearchOptions.perPage = 10;\n\t\treturn fetchLinkSuggestions( search, searchOptions, settings );\n\t};\n\n\tconst editorSettings = useMemo( () => {\n\t\treturn {\n\t\t\t...settings,\n\t\t\t__experimentalFetchLinkSuggestions,\n\t\t\t__experimentalSetIsInserterOpened,\n\t\t\t__experimentalFetchRichUrlData: __experimentalFetchUrlData,\n\t\t};\n\t}, [\n\t\tsettings,\n\t\t__experimentalFetchLinkSuggestions,\n\t\t__experimentalSetIsInserterOpened,\n\t] );\n\n\treturn <Layout blockEditorSettings={ editorSettings } />;\n}\n\n/**\n * Setup and registration of editor.\n *\n * @param {Object} settings blockEditor settings.\n */\nfunction setUpEditor( settings ) {\n\taddFilters( ! settings.blockNavMenus );\n\n\t// Set up the navigation post entity.\n\tdispatch( coreStore ).addEntities( [\n\t\t{\n\t\t\tkind: NAVIGATION_POST_KIND,\n\t\t\tname: NAVIGATION_POST_POST_TYPE,\n\t\t\ttransientEdits: { blocks: true, selection: true },\n\t\t\tlabel: __( 'Navigation Post' ),\n\t\t\t__experimentalNoFetch: true,\n\t\t},\n\t] );\n\n\tdispatch( blocksStore ).__experimentalReapplyBlockTypeFilters();\n\tregisterCoreBlocks();\n\tif ( process.env.IS_GUTENBERG_PLUGIN ) {\n\t\t__experimentalRegisterExperimentalCoreBlocks();\n\t}\n}\n\n/**\n * Initalise and render editor into DOM.\n *\n * @param {string} id       ID of HTML element into which the editor will be rendered.\n * @param {Object} settings blockEditor settings.\n */\nexport function initialize( id, settings ) {\n\tsetUpEditor( settings );\n\n\trender(\n\t\t<NavEditor settings={ settings } />,\n\t\tdocument.getElementById( id )\n\t);\n}\n\nexport { createMenuPreloadingMiddleware as __unstableCreateMenuPreloadingMiddleware } from './utils';\n","/**\n * Internal dependencies\n */\nimport addNavigationEditorCustomAppender from './add-navigation-editor-custom-appender';\nimport addNavigationEditorPlaceholder from './add-navigation-editor-placeholder';\nimport addMenuNameEditor from './add-menu-name-editor';\nimport disableInsertingNonNavigationBlocks from './disable-inserting-non-navigation-blocks';\nimport removeEditUnsupportedFeatures from './remove-edit-unsupported-features';\nimport removeSettingsUnsupportedFeatures from './remove-settings-unsupported-features';\n\nexport const addFilters = (\n\tshouldAddDisableInsertingNonNavigationBlocksFilter\n) => {\n\taddNavigationEditorCustomAppender();\n\taddNavigationEditorPlaceholder();\n\taddMenuNameEditor();\n\tif ( shouldAddDisableInsertingNonNavigationBlocksFilter ) {\n\t\tdisableInsertingNonNavigationBlocks();\n\t}\n\tremoveEditUnsupportedFeatures();\n\tremoveSettingsUnsupportedFeatures();\n};\n"],"names":["hasOwn","hasOwnProperty","classNames","classes","i","arguments","length","arg","argType","push","Array","isArray","inner","apply","toString","Object","prototype","key","call","join","module","exports","default","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","n","getter","__esModule","d","a","definition","o","defineProperty","enumerable","get","obj","prop","r","Symbol","toStringTag","value","window","MENU_KIND","MENU_POST_TYPE","NAVIGATION_POST_KIND","NAVIGATION_POST_POST_TYPE","SIDEBAR_SCOPE","SIDEBAR_MENU","SIDEBAR_BLOCK","NEW_TAB_TARGET_ATTRIBUTE","combineReducers","blockInserterPanel","state","action","type","buildNavigationPostId","menuId","getRecordIdFromBlock","block","attributes","__internalRecordId","addRecordIdToBlock","recordId","isBlockSupportedInNav","includes","name","menuItemsToBlocks","menuItems","menuTree","dataset","id","relation","hashTable","create","dataTree","data","children","createDataTree","mapMenuItemsToBlocks","sortedItems","sort","b","menu_order","map","menuItem","parse","content","raw","createBlock","menuItemToBlockAttributes","nestedBlocks","itemBlockName","blockIndex","title","menuItemTitleField","xfn","attr_title","object","object_id","description","url","menuItemTypeField","target","label","rendered","kind","replace","trim","rel","className","opensInNewTab","getNavigationPostForMenu","async","registry","dispatch","stubPost","createStubPost","persistPost","args","coreStore","startResolution","resolveSelect","getMenuItems","menus","per_page","menuItemsQuery","navigationBlock","innerBlocks","orientation","createNavigationBlock","builtPost","finishResolution","slug","status","blocks","meta","post","receiveEntityRecords","createRegistrySelector","select","hasResolvedNavigationPost","getEditedEntityRecord","hasFinishedResolution","isInserterOpened","STORE_NAME","saveNavigationPost","lock","coreDataStore","__unstableAcquireStoreLock","exclusive","saveEditedEntityRecord","throwOnError","updatedBlocks","batchSaveMenuItems","updatedPost","noticesStore","createSuccessNotice","__","saveError","errorMessage","sprintf","message","createErrorNotice","__unstableReleaseStoreLock","oldMenuItems","navBlockWithRecordIds","batchInsertPlaceholderMenuItems","navBlockAfterUpdates","batchUpdateMenuItems","deletedIds","filter","blocksTreeToList","batchDeleteMenuItems","blocksWithoutRecordId","tasks","saveEntityRecord","results","__experimentalBatch","blockToResult","Map","index","mapBlocksTree","has","allMenuItems","blocksTreeToAnnotatedList","unsupportedMenuItems","console","warn","updatedMenuItems","parentBlock","childIndex","parentId","blockPosition","_links","restMenuItem","blockTitleAttr","split","blockAttributesToMenuItem","serialize","parent","blockToMenuItem","getMenuItem","editEntityRecord","undoIgnore","hasEditsForEntityRecord","forEach","failure","getLastEntitySaveError","Error","updatedMenuItem","deleteBatch","deleteEntityRecord","success","force","flatMap","innerBlock","concat","callback","idx","setIsInserterOpened","store","createReduxStore","reducer","selectors","resolvers","actions","_extends","assign","source","this","register","CustomAppender","InnerBlocks","isToggle","EnhancedNavigationBlock","blockEdit","BlockEdit","props","clientId","noBlockSelected","isSelected","isImmediateParentOfSelectedBlock","selectedBlockHasDescendants","useSelect","getClientIdsOfDescendants","hasSelectedInnerBlock","getSelectedBlockClientId","blockEditorStore","_isImmediateParentOfSelectedBlock","selectedBlockId","_selectedBlockHasDescendants","customAppender","addNavigationEditorCustomAppender","createHigherOrderComponent","SVG","viewBox","xmlns","Path","useMenuEntity","useDispatch","menuEntityData","editedMenu","hasLoadedEditedMenu","editMenuEntityRecord","useMenuEntityProp","useEntityProp","getMenusData","params","getMenus","hasLoadedMenus","useSelectedMenuId","selectedMenuId","preferencesStore","set","useCallback","locationsForMenuId","menuLocationsByName","values","menu","getBlockOrder","lockedNavigationBlock","navBlockClientId","lastNavBlockItemIndex","untitledMenu","IsMenuNameControlFocusedContext","createContext","useMenuItemEntities","hasResolvedMenuItems","query","TOGGLE_PROPS","variant","POPOVER_PROPS","position","forwardRef","ref","onCreate","selectedMenu","setSelectedMenu","useState","isCreatingFromMenu","setIsCreatingFromMenu","menuName","isResolvingPages","isResolvingMenus","pages","hasPages","hasMenus","records","isResolving","hasResolved","hasResolvedMenus","useEntityRecords","hasResolvedPages","order","orderby","useNavigationEntities","isLoading","createFromMenu","useEffect","selectableMenus","hasSelectableMenus","Placeholder","instructions","Spinner","Button","onClick","link","convertPagesToBlocks","DropdownMenu","text","icon","chevronDown","toggleProps","popoverProps","onClose","MenuGroup","MenuItem","addNavigationEditorPlaceholder","customPlaceholder","BlockPlaceholder","fillRule","clipRule","setDefaultComplementaryArea","scope","area","enableComplementaryArea","disableComplementaryArea","pinItem","item","pinnedItems","unpinItem","toggleFeature","featureName","deprecated","since","alternative","toggle","setFeatureValue","setFeatureDefaults","defaults","setDefaults","getActiveComplementaryArea","isComplementaryAreaVisible","complementaryAreas","isItemPinned","isFeatureActive","withPluginContext","context","ownProps","identifier","complementaryAreaContext","as","selectedIcon","ComponentToUse","interfaceStore","smallScreenTitle","toggleButtonProps","toggleButton","closeSmall","classnames","tabIndex","noop","ActionItem","Component","Fill","fpOnClick","Slot","ButtonGroup","fillProps","bubblesVirtually","fills","Children","initializedByPlugins","__unstableExplicitMenuItem","__unstableTarget","child","PluginsMenuItem","restProps","ComplementaryAreaMoreMenuItem","role","check","PinnedItems","ComplementaryAreaFill","ComplementaryAreaWrapped","withComplementaryAreaContext","closeLabel","header","headerClassName","isPinnable","panelClassName","toggleShortcut","isActiveByDefault","showIconLabels","isActive","isPinned","activeArea","isSmall","isLarge","_activeArea","viewportStore","isViewportMatch","previousIsSmall","useRef","shouldOpenWhenNotSmall","current","useAdjustComplementaryListener","isPressed","showTooltip","shortcut","starFilled","starEmpty","Panel","footer","sidebar","secondarySidebar","notices","drawer","labels","shortcuts","navigateRegionsProps","useNavigateRegions","element","document","querySelector","classList","useHTMLClass","mergedLabels","body","useMergeRefs","MoreMenuDropdown","DropdownComponent","moreVertical","tooltipPosition","NameDisplay","setIsMenuNameEditFocused","useContext","decodeEntities","BlockControls","ToolbarGroup","ToolbarButton","limit","ellipsizeMode","truncate","addMenuNameEditor","disableInsertingNonNavigationBlocks","settings","removeNavigationBlockEditUnsupportedFeatures","hasSubmenuIndicatorSetting","hasItemJustificationControls","hasColorSettings","removeNavigationBlockSettingsUnsupportedFeatures","supports","customClassName","html","inserter","variations","withNotices","titleText","helpText","focusInputOnMount","noticeUI","noticeOperations","inputRef","useFocusOnMount","setMenuName","isCreatingMenu","setIsCreatingMenu","createInfoNotice","saveMenu","removeAllNotices","lastSaveError","stripHTML","onSubmit","event","preventDefault","isDismissible","TextControl","onChange","help","disabled","isBusy","MenuSwitcher","onSelectMenu","isModalVisible","setIsModalVisible","closeModal","MenuItemsChoice","onSelect","choices","hideSeparator","Modal","onRequestClose","UnselectedMenuState","showMenuSwitcher","Card","CardBody","NavigableMenu","ErrorBoundary","constructor","super","reboot","bind","error","componentDidCatch","setState","onError","render","Warning","NavigationEditorShortcuts","saveBlocks","useShortcut","redo","undo","Register","registerShortcut","keyboardShortcutsStore","category","keyCombination","modifier","character","SidebarHeader","sidebarName","menuAriaLabel","menuActiveClass","blockAriaLabel","blockActiveClass","NameEditor","isMenuNameEditFocused","setName","focus","onBlur","AutoAddPages","autoAddPages","setAutoAddPages","ToggleControl","checked","MenuSettings","PanelBody","ManageLocations","menuLocations","assignMenuToLocation","toggleMenuLocationAssignment","setMenuLocationsByName","isMounted","newMenuLocationsByName","apiFetch","method","path","fetchMenuLocationsByName","locationName","newMenuId","oldMenuId","merge","locations","useMemo","idToSet","useMenuLocations","isModalOpen","setIsModalOpen","themeLocationCountTextMain","themeLocationCountTextModal","menusWithSelection","menuOnLocation","find","CheckboxControl","menuLocationCard","menuLocation","SelectControl","labelPosition","options","Number","style","visibility","batchRequests","batchResponse","validation","requests","failed","responses","response","DeleteMenu","onDeleteMenu","isMenuBeingDeleted","showConfirmDialog","setShowConfirmDialog","isDestructive","isOpen","onConfirm","onCancel","Sidebar","isLargeViewport","useViewportMatch","hasBlockSelection","hasSidebarEnabled","_sidebar","_hasSidebarEnabled","getBlockSelectionStart","cog","BlockInspector","MenuActions","setSelectedMenuId","popoverAnchor","setPopoverAnchor","anchor","size","__experimentalIsFocusable","NewButton","SaveButton","navigationPost","isDirty","__experimentalGetDirtyEntityRecords","editNavigationStore","UndoButton","hasUndo","isRTL","redoIcon","undoIcon","displayShortcut","RedoButton","isAppleOS","hasRedo","useNavigationEditorRootBlock","hasInserterItems","ToolbarItem","onMouseDown","plus","_x","ToolsMoreMenuGroup","createSlotFill","MoreMenu","external","href","VisuallyHidden","Header","isMenuSelected","isPending","isMediumViewport","NavigableToolbar","EditNavigationNotices","removeNotice","getNotices","dismissibleNotices","nonDismissibleNotices","snackbarNotices","NoticeList","onRemove","SnackbarList","Editor","WritingFlow","ObserveTyping","BlockList","isMobileViewport","selectedBlockClientId","getSelectedBlock","inserterDialogRef","inserterDialogProps","useDialog","shouldInsertInNavBlock","close","rootClientId","__experimentalInsertionIndex","shouldFocusBlock","showInserterHelpPanel","UnsavedChangesWarning","warnIfUnsavedChanges","returnValue","addEventListener","removeEventListener","interfaceLabels","Layout","blockEditorSettings","contentAreaRef","useBlockSelectionClearer","isMenuNameControlFocused","setIsMenuNameControlFocused","hasFinishedInitialLoad","selectMenu","deleteMenu","_deleteMenu","setHasFinishedInitialLoad","keys","isDeletingEntityRecord","selectedMenuName","useNavigationEditor","onInput","useEntityBlockEditor","lastDeleteError","getLastEntityDeleteError","useMenuNotifications","isBlockEditorReady","ShortcutProvider","hidden","SlotFillProvider","BlockEditorKeyboardShortcuts","BlockEditorProvider","templateLock","useSubRegistry","Provider","BlockTools","Popover","PluginArea","createMenuPreloadingMiddleware","preloadedData","cache","reduce","result","normalizePath","menusDataLoaded","menuDataLoaded","next","sendSuccessResponse","matches","match","menuData","parseInt","headers","responseData","Promise","resolve","Response","JSON","stringify","statusText","NavEditor","__experimentalSetIsInserterOpened","__experimentalFetchLinkSuggestions","search","searchOptions","perPage","fetchLinkSuggestions","editorSettings","__experimentalFetchRichUrlData","__experimentalFetchUrlData","initialize","shouldAddDisableInsertingNonNavigationBlocksFilter","blockNavMenus","addFilter","addEntities","transientEdits","selection","__experimentalNoFetch","blocksStore","__experimentalReapplyBlockTypeFilters","registerCoreBlocks","__experimentalRegisterExperimentalCoreBlocks","setUpEditor","getElementById"],"sourceRoot":""}

Zerion Mini Shell 1.0