/*! This file is auto-generated */ this.wp=this.wp||{},this.wp.editPost=function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=456)}({0:function(e,t){!function(){e.exports=this.wp.element}()},1:function(e,t){!function(){e.exports=this.wp.i18n}()},10:function(e,t){!function(){e.exports=this.wp.compose}()},101:function(e,t){!function(){e.exports=this.wp.viewport}()},102:function(e,t){var r,n,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function c(e){if(r===setTimeout)return setTimeout(e,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(e,0);try{return r(e,0)}catch(t){try{return r.call(null,e,0)}catch(t){return r.call(this,e,0)}}}!function(){try{r="function"==typeof setTimeout?setTimeout:o}catch(e){r=o}try{n="function"==typeof clearTimeout?clearTimeout:a}catch(e){n=a}}();var A,u=[],l=!1,s=-1;function m(){l&&A&&(l=!1,A.length?u=A.concat(u):s=-1,u.length&&q())}function q(){if(!l){var e=c(m);l=!0;for(var t=u.length;t;){for(A=u,u=[];++s1)for(var r=1;r=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}},150:function(e,t,r){"use strict";e.exports=function(e){var t,r={};return function e(t,r){var n;if(Array.isArray(r))for(n=0;ne.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0||(i[r]=e[r]);return i}r.d(t,"a",(function(){return n}))},438:function(e,t,r){"use strict";var n=r(0),i=r(7),o=Object(n.createElement)(i.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(n.createElement)(i.Path,{d:"M10.5 4v4h3V4H15v4h1.5a1 1 0 011 1v4l-3 4v2a1 1 0 01-1 1h-3a1 1 0 01-1-1v-2l-3-4V9a1 1 0 011-1H9V4h1.5zm.5 12.5v2h2v-2l3-4v-3H8v3l3 4z"}));t.a=o},456:function(e,t,r){"use strict";r.r(t),r.d(t,"reinitializeEditor",(function(){return gi})),r.d(t,"initializeEditor",(function(){return hi})),r.d(t,"PluginBlockSettingsMenuItem",(function(){return Oi})),r.d(t,"PluginDocumentSettingPanel",(function(){return Gn.a})),r.d(t,"PluginMoreMenuItem",(function(){return Ii})),r.d(t,"PluginPostPublishPanel",(function(){return Fn})),r.d(t,"PluginPostStatusInfo",(function(){return mn})),r.d(t,"PluginPrePublishPanel",(function(){return $n})),r.d(t,"PluginSidebar",(function(){return Yn})),r.d(t,"PluginSidebarMoreMenuItem",(function(){return bi})),r.d(t,"__experimentalFullscreenModeClose",(function(){return wr}));var n={};r.r(n),r.d(n,"openGeneralSidebar",(function(){return re})),r.d(n,"closeGeneralSidebar",(function(){return ne})),r.d(n,"openModal",(function(){return ie})),r.d(n,"closeModal",(function(){return oe})),r.d(n,"openPublishSidebar",(function(){return ae})),r.d(n,"closePublishSidebar",(function(){return ce})),r.d(n,"togglePublishSidebar",(function(){return Ae})),r.d(n,"toggleEditorPanelEnabled",(function(){return ue})),r.d(n,"toggleEditorPanelOpened",(function(){return le})),r.d(n,"removeEditorPanel",(function(){return se})),r.d(n,"toggleFeature",(function(){return me})),r.d(n,"switchEditorMode",(function(){return qe})),r.d(n,"togglePinnedPluginItem",(function(){return pe})),r.d(n,"hideBlockTypes",(function(){return de})),r.d(n,"updatePreferredStyleVariations",(function(){return Oe})),r.d(n,"__experimentalUpdateLocalAutosaveInterval",(function(){return Ie})),r.d(n,"showBlockTypes",(function(){return be})),r.d(n,"setAvailableMetaBoxesPerLocation",(function(){return ge})),r.d(n,"requestMetaBoxUpdates",(function(){return he})),r.d(n,"metaBoxUpdatesSuccess",(function(){return ve})),r.d(n,"__experimentalSetPreviewDeviceType",(function(){return je})),r.d(n,"setIsInserterOpened",(function(){return Ce}));var i={};r.r(i),r.d(i,"getEditorMode",(function(){return Ee})),r.d(i,"isEditorSidebarOpened",(function(){return Ke})),r.d(i,"isPluginSidebarOpened",(function(){return fe})),r.d(i,"getActiveGeneralSidebarName",(function(){return Se})),r.d(i,"getPreferences",(function(){return Me})),r.d(i,"getPreference",(function(){return Ze})),r.d(i,"isPublishSidebarOpened",(function(){return ze})),r.d(i,"isEditorPanelRemoved",(function(){return we})),r.d(i,"isEditorPanelEnabled",(function(){return Be})),r.d(i,"isEditorPanelOpened",(function(){return Ge})),r.d(i,"isModalActive",(function(){return Ye})),r.d(i,"isFeatureActive",(function(){return ke})),r.d(i,"isPluginItemPinned",(function(){return Qe})),r.d(i,"getActiveMetaBoxLocations",(function(){return We})),r.d(i,"isMetaBoxLocationVisible",(function(){return Le})),r.d(i,"isMetaBoxLocationActive",(function(){return De})),r.d(i,"getMetaBoxesPerLocation",(function(){return Ne})),r.d(i,"getAllMetaBoxes",(function(){return Pe})),r.d(i,"hasMetaBoxes",(function(){return Je})),r.d(i,"isSavingMetaBoxes",(function(){return xe})),r.d(i,"__experimentalGetPreviewDeviceType",(function(){return He})),r.d(i,"isInserterOpened",(function(){return Re}));var o={};r.r(o),r.d(o,"enableComplementaryArea",(function(){return It})),r.d(o,"disableComplementaryArea",(function(){return bt})),r.d(o,"pinItem",(function(){return ht})),r.d(o,"unpinItem",(function(){return vt}));var a={};r.r(a),r.d(a,"getActiveComplementaryArea",(function(){return jt})),r.d(a,"isItemPinned",(function(){return Ct}));var c=r(0),A=(r(83),r(6)),u=r(34),l=r(53),s=(r(121),r(101)),m=(r(92),r(291)),q=r(33),p=r(156);Object(q.addFilter)("editor.MediaUpload","core/edit-post/replace-media-upload",(function(){return p.MediaUpload}));var d=r(8),O=r(14),I=r(2),b=r(11),g=r(3),h=r(4),v=r(1),j=r(10),C=Object(j.compose)(Object(h.withSelect)((function(e,t){if(Object(b.hasBlockSupport)(t.name,"multiple",!0))return{};var r=e("core/block-editor").getBlocks(),n=Object(I.find)(r,(function(e){var r=e.name;return t.name===r}));return{originalBlockClientId:n&&n.clientId!==t.clientId&&n.clientId}})),Object(h.withDispatch)((function(e,t){var r=t.originalBlockClientId;return{selectFirst:function(){return e("core/block-editor").selectBlock(r)}}}))),y=Object(j.createHigherOrderComponent)((function(e){return C((function(t){var r=t.originalBlockClientId,n=t.selectFirst,i=Object(O.a)(t,["originalBlockClientId","selectFirst"]);if(!r)return Object(c.createElement)(e,i);var o=Object(b.getBlockType)(i.name),a=function(e){var t=Object(b.findTransform)(Object(b.getBlockTransforms)("to",e),(function(e){var t=e.type,r=e.blocks;return"block"===t&&1===r.length}));if(!t)return null;return Object(b.getBlockType)(t.blocks[0])}(i.name);return[Object(c.createElement)("div",{key:"invalid-preview",style:{minHeight:"60px"}},Object(c.createElement)(e,Object(d.a)({key:"block-edit"},i))),Object(c.createElement)(A.Warning,{key:"multiple-use-warning",actions:[Object(c.createElement)(g.Button,{key:"find-original",isSecondary:!0,onClick:n},Object(v.__)("Find original")),Object(c.createElement)(g.Button,{key:"remove",isSecondary:!0,onClick:function(){return i.onReplace([])}},Object(v.__)("Remove")),a&&Object(c.createElement)(g.Button,{key:"transform",isSecondary:!0,onClick:function(){return i.onReplace(Object(b.createBlock)(a.name,i.attributes))}},Object(v.__)("Transform into:")," ",a.title)]},Object(c.createElement)("strong",null,o.title,": "),Object(v.__)("This block can only be used once."))]}))}),"withMultipleValidation");Object(q.addFilter)("editor.BlockEdit","core/edit-post/validate-multiple-use/with-multiple-validation",y);var E=r(427),K=r(77),f=r(31);var S=Object(j.compose)(Object(h.withSelect)((function(e){return{editedPostContent:e("core/editor").getEditedPostAttribute("content")}})),Object(h.withDispatch)((function(e){return{createNotice:e("core/notices").createNotice}})),Object(j.ifCondition)((function(e){return e.editedPostContent.length>0})))((function(e){var t=e.createNotice,r=e.editedPostContent,n=Object(c.useRef)(),i=Object(j.useCopyOnClick)(n,r);return Object(c.useEffect)((function(){i&&t("info",Object(v.__)("All content copied."),{isDismissible:!0,type:"snackbar"})}),[i]),Object(c.createElement)(g.MenuItem,{ref:n},i?Object(v.__)("Copied!"):Object(v.__)("Copy all content"))}));var M=Object(h.withDispatch)((function(e){return{openModal:e("core/edit-post").openModal}}))((function(e){var t=e.openModal;return Object(c.createElement)(g.MenuItem,{onClick:function(){t("edit-post/manage-blocks")}},Object(v.__)("Block Manager"))})),Z=r(18);var z=Object(h.withDispatch)((function(e){return{openModal:e("core/edit-post").openModal}}))((function(e){var t=e.openModal;return Object(c.createElement)(g.MenuItem,{onClick:function(){t("edit-post/keyboard-shortcut-help")},shortcut:Z.displayShortcut.access("h")},Object(v.__)("Keyboard shortcuts"))})),w=Object(g.createSlotFill)("ToolsMoreMenuGroup"),B=w.Fill,G=w.Slot;B.Slot=function(e){var t=e.fillProps;return Object(c.createElement)(G,{fillProps:t},(function(e){return!Object(I.isEmpty)(e)&&Object(c.createElement)(g.MenuGroup,{label:Object(v.__)("Tools")},e)}))};var Y=B;function k(){var e=Object(h.useDispatch)("core/edit-post").toggleFeature;return Object(c.createElement)(g.MenuItem,{onClick:function(){return e("welcomeGuide")}},Object(v.__)("Welcome Guide"))}Object(K.registerPlugin)("edit-post",{render:function(){return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(Y,null,(function(e){var t=e.onClose;return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(M,{onSelect:t}),Object(c.createElement)(g.MenuItem,{role:"menuitem",href:Object(f.addQueryArgs)("edit.php",{post_type:"wp_block"})},Object(v.__)("Manage all reusable blocks")),Object(c.createElement)(z,{onSelect:t}),Object(c.createElement)(k,null),Object(c.createElement)(S,null),Object(c.createElement)(g.MenuItem,{role:"menuitem",icon:E.a,href:Object(v.__)("https://wordpress.org/support/article/wordpress-editor/"),target:"_blank",rel:"noopener noreferrer"},Object(v.__)("Help"),Object(c.createElement)(g.VisuallyHidden,{as:"span"},Object(v.__)("(opens in a new tab)"))))})))}});var Q=r(5),W=r(32),L=r(17);function D(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function N(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:P,r=arguments.length>1?arguments[1]:void 0;return e(t,r)}})])({panels:function(e,t){switch(t.type){case"TOGGLE_PANEL_ENABLED":var r=t.panelName;return N(N({},e),{},Object(Q.a)({},r,N(N({},e[r]),{},{enabled:!Object(I.get)(e,[r,"enabled"],!0)})));case"TOGGLE_PANEL_OPENED":var n=t.panelName,i=!0===e[n]||Object(I.get)(e,[n,"opened"],!1);return N(N({},e),{},Object(Q.a)({},n,N(N({},e[n]),{},{opened:!i})))}return e},features:function(e,t){return"TOGGLE_FEATURE"===t.type?N(N({},e),{},Object(Q.a)({},t.feature,!e[t.feature])):e},editorMode:function(e,t){return"SWITCH_MODE"===t.type?t.mode:e},hiddenBlockTypes:function(e,t){switch(t.type){case"SHOW_BLOCK_TYPES":return I.without.apply(void 0,[e].concat(Object(L.a)(t.blockNames)));case"HIDE_BLOCK_TYPES":return Object(I.union)(e,t.blockNames)}return e},preferredStyleVariations:function(e,t){switch(t.type){case"UPDATE_PREFERRED_STYLE_VARIATIONS":return t.blockName?t.blockStyle?N(N({},e),{},Object(Q.a)({},t.blockName,t.blockStyle)):Object(I.omit)(e,[t.blockName]):e}return e},localAutosaveInterval:function(e,t){switch(t.type){case"UPDATE_LOCAL_AUTOSAVE_INTERVAL":return t.interval}return e}});var x=Object(h.combineReducers)({isSaving:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"REQUEST_META_BOX_UPDATES":return!0;case"META_BOX_UPDATES_SUCCESS":return!1;default:return e}},locations:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_META_BOXES_PER_LOCATIONS":return t.metaBoxesPerLocation}return e}}),H=Object(h.combineReducers)({activeModal:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"OPEN_MODAL":return t.name;case"CLOSE_MODAL":return null}return e},metaBoxes:x,preferences:J,publishSidebarActive:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"OPEN_PUBLISH_SIDEBAR":return!0;case"CLOSE_PUBLISH_SIDEBAR":return!1;case"TOGGLE_PUBLISH_SIDEBAR":return!e}return e},removedPanels:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"REMOVE_PANEL":if(!Object(I.includes)(e,t.panelName))return[].concat(Object(L.a)(e),[t.panelName])}return e},deviceType:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Desktop",t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_PREVIEW_DEVICE_TYPE":return t.deviceType}return e},isInserterOpened:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_IS_INSERTER_OPENED":return t.value}return e}}),R=r(150),T=r.n(R),F=r(12),U=r(46),X=r(47),V=r.n(X),_=r(20),$=r.n(_),ee=$.a.mark(re),te=$.a.mark(ne);function re(e){return $.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(W.dispatch)("core/interface","enableComplementaryArea","core/edit-post",e);case 2:case"end":return t.stop()}}),ee)}function ne(){return $.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(W.dispatch)("core/interface","disableComplementaryArea","core/edit-post");case 2:case"end":return e.stop()}}),te)}function ie(e){return{type:"OPEN_MODAL",name:e}}function oe(){return{type:"CLOSE_MODAL"}}function ae(){return{type:"OPEN_PUBLISH_SIDEBAR"}}function ce(){return{type:"CLOSE_PUBLISH_SIDEBAR"}}function Ae(){return{type:"TOGGLE_PUBLISH_SIDEBAR"}}function ue(e){return{type:"TOGGLE_PANEL_ENABLED",panelName:e}}function le(e){return{type:"TOGGLE_PANEL_OPENED",panelName:e}}function se(e){return{type:"REMOVE_PANEL",panelName:e}}function me(e){return{type:"TOGGLE_FEATURE",feature:e}}function qe(e){return{type:"SWITCH_MODE",mode:e}}function pe(e){return{type:"TOGGLE_PINNED_PLUGIN_ITEM",pluginName:e}}function de(e){return{type:"HIDE_BLOCK_TYPES",blockNames:Object(I.castArray)(e)}}function Oe(e,t){return{type:"UPDATE_PREFERRED_STYLE_VARIATIONS",blockName:e,blockStyle:t}}function Ie(e){return{type:"UPDATE_LOCAL_AUTOSAVE_INTERVAL",interval:e}}function be(e){return{type:"SHOW_BLOCK_TYPES",blockNames:Object(I.castArray)(e)}}function ge(e){return{type:"SET_META_BOXES_PER_LOCATIONS",metaBoxesPerLocation:e}}function he(){return{type:"REQUEST_META_BOX_UPDATES"}}function ve(){return{type:"META_BOX_UPDATES_SUCCESS"}}function je(e){return{type:"SET_PREVIEW_DEVICE_TYPE",deviceType:e}}function Ce(e){return{type:"SET_IS_INSERTER_OPENED",value:e}}var ye=r(42);function Ee(e){return Ze(e,"editorMode","visual")}var Ke=Object(h.createRegistrySelector)((function(e){return function(){var t=e("core/interface").getActiveComplementaryArea("core/edit-post");return Object(I.includes)(["edit-post/document","edit-post/block"],t)}})),fe=Object(h.createRegistrySelector)((function(e){return function(){var t=e("core/interface").getActiveComplementaryArea("core/edit-post");return!!t&&!Object(I.includes)(["edit-post/document","edit-post/block"],t)}})),Se=Object(h.createRegistrySelector)((function(e){return function(){return e("core/interface").getActiveComplementaryArea("core/edit-post")}}));function Me(e){return e.preferences}function Ze(e,t,r){var n=Me(e)[t];return void 0===n?r:n}function ze(e){return e.publishSidebarActive}function we(e,t){return Object(I.includes)(e.removedPanels,t)}function Be(e,t){var r=Ze(e,"panels");return!we(e,t)&&Object(I.get)(r,[t,"enabled"],!0)}function Ge(e,t){var r=Ze(e,"panels");return!0===Object(I.get)(r,[t])||!0===Object(I.get)(r,[t,"opened"])}function Ye(e,t){return e.activeModal===t}function ke(e,t){return Object(I.get)(e.preferences.features,[t],!1)}var Qe=Object(h.createRegistrySelector)((function(e){return function(t){return e("core/interface").isItemPinned("core/edit-post",t)}})),We=Object(ye.a)((function(e){return Object.keys(e.metaBoxes.locations).filter((function(t){return De(e,t)}))}),(function(e){return[e.metaBoxes.locations]}));function Le(e,t){return De(e,t)&&Object(I.some)(Ne(e,t),(function(t){var r=t.id;return Be(e,"meta-box-".concat(r))}))}function De(e,t){var r=Ne(e,t);return!!r&&0!==r.length}function Ne(e,t){return e.metaBoxes.locations[t]}var Pe=Object(ye.a)((function(e){return Object(I.flatten)(Object(I.values)(e.metaBoxes.locations))}),(function(e){return[e.metaBoxes.locations]}));function Je(e){return We(e).length>0}function xe(e){return e.metaBoxes.isSaving}function He(e){return e.deviceType}function Re(e){return e.isInserterOpened}var Te;function Fe(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"==typeof e)return Ue(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ue(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,c=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){c=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw o}}}}function Ue(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,r=t.type,n=t.itemType,i=t.scope,o=t.item;return"SET_SINGLE_ENABLE_ITEM"===r&&n&&i?qt(qt({},e),{},Object(Q.a)({},n,qt(qt({},e[n]),{},Object(Q.a)({},i,o||null)))):e},multipleEnableItems:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,r=t.type,n=t.itemType,i=t.scope,o=t.item,a=t.isEnable;if("SET_MULTIPLE_ENABLE_ITEM"!==r||!n||!i||!o||Object(I.get)(e,[n,i,o])===a)return e;var c=e[n]||{},A=c[i]||{};return qt(qt({},e),{},Object(Q.a)({},n,qt(qt({},c),{},Object(Q.a)({},i,qt(qt({},A),{},Object(Q.a)({},o,a||!1))))))}}),dt=Object(h.combineReducers)({enableItems:pt});function Ot(e,t,r){return{type:"SET_SINGLE_ENABLE_ITEM",itemType:e,scope:t,item:r}}function It(e,t){return Ot("complementaryArea",e,t)}function bt(e){return Ot("complementaryArea",e,void 0)}function gt(e,t,r,n){return{type:"SET_MULTIPLE_ENABLE_ITEM",itemType:e,scope:t,item:r,isEnable:n}}function ht(e,t){return gt("pinnedItems",e,t,!0)}function vt(e,t){return gt("pinnedItems",e,t,!1)}function jt(e,t){return function(e,t,r){return Object(I.get)(e.enableItems.singleEnableItems,[t,r])}(e,"complementaryArea",t)}function Ct(e,t,r){return!1!==function(e,t,r,n){return Object(I.get)(e.enableItems.multipleEnableItems,[t,r,n])}(e,"pinnedItems",t,r)}Object(h.registerStore)("core/interface",{reducer:dt,actions:o,selectors:a,persist:["enableItems"]});var yt=r(161),Et=r(301),Kt=r(302),ft=r(159),St=Object(K.withPluginContext)((function(e,t){return{icon:t.icon||e.icon,identifier:t.identifier||"".concat(e.name,"/").concat(t.name)}}));var Mt=St((function(e){var t=e.as,r=void 0===t?g.Button:t,n=e.scope,i=e.identifier,o=e.icon,a=e.selectedIcon,A=Object(O.a)(e,["as","scope","identifier","icon","selectedIcon"]),u=r,l=Object(h.useSelect)((function(e){return e("core/interface").getActiveComplementaryArea(n)===i}),[i]),s=Object(h.useDispatch)("core/interface"),m=s.enableComplementaryArea,q=s.disableComplementaryArea;return Object(c.createElement)(u,Object(d.a)({icon:a&&l?a:o,onClick:function(){l?q(n):m(n,i)}},Object(I.omit)(A,["name"])))})),Zt=function(e){var t=e.smallScreenTitle,r=e.children,n=e.className,i=e.toggleButtonProps,o=Object(c.createElement)(Mt,Object(d.a)({icon:ft.a},i));return Object(c.createElement)(c.Fragment,null,Object(c.createElement)("div",{className:"components-panel__header interface-complementary-area-header__small"},t&&Object(c.createElement)("span",{className:"interface-complementary-area-header__small-title"},t),o),Object(c.createElement)("div",{className:st()("components-panel__header","interface-complementary-area-header",n),tabIndex:-1},r,o))};function zt(e){var t=e.scope,r=Object(O.a)(e,["scope"]);return Object(c.createElement)(g.Fill,Object(d.a)({name:"PinnedItems/".concat(t)},r))}zt.Slot=function(e){var t=e.scope,r=e.className,n=Object(O.a)(e,["scope","className"]);return Object(c.createElement)(g.Slot,Object(d.a)({name:"PinnedItems/".concat(t)},n),(function(e){return!Object(I.isEmpty)(e)&&Object(c.createElement)("div",{className:st()(r,"interface-pinned-items")},e)}))};var wt=zt;function Bt(e){var t=e.scope,r=e.children,n=e.className;return Object(c.createElement)(g.Fill,{name:"ComplementaryArea/".concat(t)},Object(c.createElement)(g.Animate,{type:"slide-in",options:{origin:"left"}},(function(){return Object(c.createElement)("div",{className:n},r)})))}var Gt=St((function(e){var t=e.children,r=e.className,n=e.closeLabel,i=void 0===n?Object(v.__)("Close plugin"):n,o=e.identifier,a=e.header,A=e.headerClassName,u=e.icon,l=e.isPinnable,s=void 0===l||l,m=e.panelClassName,q=e.scope,p=e.smallScreenTitle,d=e.title,O=e.toggleShortcut,I=e.isActiveByDefault,b=e.showIconLabels,j=void 0!==b&&b,C=Object(h.useSelect)((function(e){var t=e("core/interface"),r=t.getActiveComplementaryArea,n=t.isItemPinned,i=r(q);return{isActive:i===o,isPinned:n(q,o),activeArea:i,isSmall:e("core/viewport").isViewportMatch("< medium"),isLarge:e("core/viewport").isViewportMatch("large")}}),[o,q]),y=C.isActive,E=C.isPinned,K=C.activeArea,f=C.isSmall,S=C.isLarge;!function(e,t,r,n,i){var o=Object(c.useRef)(!1),a=Object(c.useRef)(!1),A=Object(h.useDispatch)("core/interface"),u=A.enableComplementaryArea,l=A.disableComplementaryArea;Object(c.useEffect)((function(){n&&i&&!o.current?(l(e),a.current=!0):a.current&&!i&&o.current?(a.current=!1,u(e,t)):a.current&&r&&r!==t&&(a.current=!1),i!==o.current&&(o.current=i)}),[n,i,e,t,r])}(q,o,K,y,f);var M=Object(h.useDispatch)("core/interface"),Z=M.enableComplementaryArea,z=M.disableComplementaryArea,w=M.pinItem,B=M.unpinItem;return Object(c.useEffect)((function(){I&&void 0===K&&!f&&Z(q,o)}),[K,I,q,o,f]),Object(c.createElement)(c.Fragment,null,E&&s&&Object(c.createElement)(wt,{scope:q},Object(c.createElement)(Mt,{scope:q,identifier:o,isPressed:y&&(!j||S),"aria-expanded":y,label:d,icon:j?yt.a:u,showTooltip:!j,isTertiary:j})),y&&Object(c.createElement)(Bt,{className:st()("interface-complementary-area",r),scope:q},Object(c.createElement)(Zt,{className:A,closeLabel:i,onClose:function(){return z(q)},smallScreenTitle:p,toggleButtonProps:{label:i,shortcut:O,scope:q,identifier:o}},a||Object(c.createElement)(c.Fragment,null,Object(c.createElement)("strong",null,d),s&&Object(c.createElement)(g.Button,{className:"interface-complementary-area__pin-unpin-item",icon:E?Et.a:Kt.a,label:E?Object(v.__)("Unpin from toolbar"):Object(v.__)("Pin to toolbar"),onClick:function(){return(E?B:w)(q,o)},isPressed:E,"aria-expanded":E}))),Object(c.createElement)(g.Panel,{className:m},t)))}));Gt.Slot=function(e){var t=e.scope,r=Object(O.a)(e,["scope"]);return Object(c.createElement)(g.Slot,Object(d.a)({name:"ComplementaryArea/".concat(t)},r))};var Yt=Gt;function kt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Qt(e){for(var t=1;t0?"mixed":"false",Object(c.createElement)("div",{role:"group","aria-labelledby":m,className:"edit-post-manage-blocks-modal__category"},Object(c.createElement)(g.CheckboxControl,{checked:q,onChange:a,className:"edit-post-manage-blocks-modal__category-title","aria-checked":l,label:Object(c.createElement)("span",{id:m},r)}),Object(c.createElement)(mr,{blockTypes:u,value:s,onItemChange:o}))}));var dr=Object(j.compose)([Object(j.withState)({search:""}),Object(h.withSelect)((function(e){var t=e("core/blocks"),r=t.getBlockTypes,n=t.getCategories,i=t.hasBlockSupport,o=t.isMatchingSearchTerm,a=(0,e("core/edit-post").getPreference)("hiddenBlockTypes"),c=Object(I.isArray)(a)&&a.length;return{blockTypes:r(),categories:n(),hasBlockSupport:i,isMatchingSearchTerm:o,numberOfHiddenBlocks:c}}))])((function(e){var t=e.search,r=e.setState,n=e.blockTypes,i=e.categories,o=e.hasBlockSupport,a=e.isMatchingSearchTerm,A=e.numberOfHiddenBlocks;return n=n.filter((function(e){return o(e,"inserter",!0)&&(!t||a(e,t))&&(!e.parent||Object(I.includes)(e.parent,"core/post-content"))})),Object(c.createElement)("div",{className:"edit-post-manage-blocks-modal__content"},Object(c.createElement)(g.TextControl,{type:"search",label:Object(v.__)("Search for a block"),value:t,onChange:function(e){return r({search:e})},className:"edit-post-manage-blocks-modal__search"}),!!A&&Object(c.createElement)("div",{className:"edit-post-manage-blocks-modal__disabled-blocks-count"},Object(v.sprintf)(Object(v._n)("%d block is disabled.","%d blocks are disabled.",A),A)),Object(c.createElement)("div",{tabIndex:"0",role:"region","aria-label":Object(v.__)("Available block types"),className:"edit-post-manage-blocks-modal__results"},0===n.length&&Object(c.createElement)("p",{className:"edit-post-manage-blocks-modal__no-results"},Object(v.__)("No blocks found.")),i.map((function(e){return Object(c.createElement)(pr,{key:e.slug,title:e.title,blockTypes:Object(I.filter)(n,{category:e.slug})})})),Object(c.createElement)(pr,{title:Object(v.__)("Uncategorized"),blockTypes:Object(I.filter)(n,(function(e){return!e.category}))})))}));var Or=Object(j.compose)([Object(h.withSelect)((function(e){return{isActive:(0,e("core/edit-post").isModalActive)("edit-post/manage-blocks")}})),Object(h.withDispatch)((function(e){return{closeModal:e("core/edit-post").closeModal}}))])((function(e){var t=e.isActive,r=e.closeModal;return t?Object(c.createElement)(g.Modal,{className:"edit-post-manage-blocks-modal",title:Object(v.__)("Block Manager"),closeLabel:Object(v.__)("Close"),onRequestClose:r},Object(c.createElement)(dr,null)):null})),Ir=function(e){var t=e.description,r=e.title,n=e.children;return Object(c.createElement)("section",{className:"edit-post-preferences-modal__section"},Object(c.createElement)("h2",{className:"edit-post-preferences-modal__section-title"},r),t&&Object(c.createElement)("p",{className:"edit-post-preferences-modal__section-description"},t),n)},br=r(116),gr=Object(j.compose)(Object(h.withSelect)((function(e){return{isChecked:e("core/editor").isPublishSidebarEnabled()}})),Object(h.withDispatch)((function(e){var t=e("core/editor"),r=t.enablePublishSidebar,n=t.disablePublishSidebar;return{onChange:function(e){return e?r():n()}}})),Object(s.ifViewportMatches)("medium"))(br.a),hr=Object(j.compose)(Object(h.withSelect)((function(e,t){var r=t.featureName;return{isChecked:(0,e("core/edit-post").isFeatureActive)(r)}})),Object(h.withDispatch)((function(e,t){var r=t.featureName;return{onChange:function(){return e("core/edit-post").toggleFeature(r)}}})))(br.a),vr=r(489),jr=r(490);function Cr(e){var t=e.willEnable,r=Object(c.useState)(!1),n=Object(F.a)(r,2),i=n[0],o=n[1];return Object(c.createElement)(c.Fragment,null,Object(c.createElement)("p",{className:"edit-post-preferences-modal__custom-fields-confirmation-message"},Object(v.__)("A page reload is required for this change. Make sure your content is saved before reloading.")),Object(c.createElement)(g.Button,{className:"edit-post-preferences-modal__custom-fields-confirmation-button",isSecondary:!0,isBusy:i,disabled:i,onClick:function(){o(!0),document.getElementById("toggle-custom-fields-form").submit()}},t?Object(v.__)("Enable & Reload"):Object(v.__)("Disable & Reload")))}var yr=Object(h.withSelect)((function(e){return{areCustomFieldsEnabled:!!e("core/editor").getEditorSettings().enableCustomFields}}))((function(e){var t=e.label,r=e.areCustomFieldsEnabled,n=Object(c.useState)(r),i=Object(F.a)(n,2),o=i[0],a=i[1];return Object(c.createElement)(br.a,{label:t,isChecked:o,onChange:a},o!==r&&Object(c.createElement)(Cr,{willEnable:o}))}));var Er=Object(h.withSelect)((function(e){var t=e("core/editor").getEditorSettings,r=e("core/edit-post").getAllMetaBoxes;return{areCustomFieldsRegistered:void 0!==t().enableCustomFields,metaBoxes:r()}}))((function(e){var t=e.areCustomFieldsRegistered,r=e.metaBoxes,n=Object(O.a)(e,["areCustomFieldsRegistered","metaBoxes"]),i=Object(I.filter)(r,(function(e){return"postcustom"!==e.id}));return t||0!==i.length?Object(c.createElement)(Ir,n,t&&Object(c.createElement)(yr,{label:Object(v.__)("Custom fields")}),Object(I.map)(i,(function(e){var t=e.id,r=e.title;return Object(c.createElement)(jr.a,{key:t,label:r,panelName:"meta-box-".concat(t)})}))):null}));var Kr=Object(j.compose)(Object(h.withSelect)((function(e){var t=e("core/editor").getEditedPostAttribute,r=(0,e("core").getPostType)(t("type"));return{isModalActive:e("core/edit-post").isModalActive("edit-post/preferences"),isViewable:Object(I.get)(r,["viewable"],!1)}})),Object(h.withDispatch)((function(e){return{closeModal:function(){return e("core/edit-post").closeModal()}}})))((function(e){var t=e.isModalActive,r=e.isViewable,n=e.closeModal;return t?Object(c.createElement)(g.Modal,{className:"edit-post-preferences-modal",title:Object(v.__)("Preferences"),closeLabel:Object(v.__)("Close"),onRequestClose:n},Object(c.createElement)(Ir,{title:Object(v.__)("General")},Object(c.createElement)(gr,{help:Object(v.__)("Review settings such as categories and tags."),label:Object(v.__)("Include pre-publish checklist")}),Object(c.createElement)(hr,{featureName:"mostUsedBlocks",help:Object(v.__)("Places the most frequent blocks in the block library."),label:Object(v.__)("Show most used blocks")})),Object(c.createElement)(Ir,{title:Object(v.__)("Keyboard")},Object(c.createElement)(hr,{featureName:"keepCaretInsideBlock",help:Object(v.__)("Aids screen readers by stopping text caret from leaving blocks."),label:Object(v.__)("Contain text cursor inside block.")})),Object(c.createElement)(Ir,{title:Object(v.__)("Appearance")},Object(c.createElement)(hr,{featureName:"reducedUI",help:Object(v.__)("Compacts options and outlines in the toolbar."),label:Object(v.__)("Reduce the interface")}),Object(c.createElement)(hr,{featureName:"focusMode",help:Object(v.__)("Highlights the current block and fades other content."),label:Object(v.__)("Spotlight mode")}),Object(c.createElement)(hr,{featureName:"showIconLabels",help:Object(v.__)("Shows text instead of icons in toolbar."),label:Object(v.__)("Display button labels")}),Object(c.createElement)(hr,{featureName:"themeStyles",help:Object(v.__)("Make the editor look like your theme."),label:Object(v.__)("Use theme styles")})),Object(c.createElement)(Ir,{title:Object(v.__)("Document settings"),description:Object(v.__)("Choose what displays in the panel.")},Object(c.createElement)(vr.a.Slot,null),r&&Object(c.createElement)(jr.a,{label:Object(v.__)("Permalink"),panelName:"post-link"}),Object(c.createElement)(u.PostTaxonomies,{taxonomyWrapper:function(e,t){return Object(c.createElement)(jr.a,{label:Object(I.get)(t,["labels","menu_name"]),panelName:"taxonomy-panel-".concat(t.slug)})}}),Object(c.createElement)(u.PostFeaturedImageCheck,null,Object(c.createElement)(jr.a,{label:Object(v.__)("Featured image"),panelName:"featured-image"})),Object(c.createElement)(u.PostExcerptCheck,null,Object(c.createElement)(jr.a,{label:Object(v.__)("Excerpt"),panelName:"post-excerpt"})),Object(c.createElement)(u.PostTypeSupportCheck,{supportKeys:["comments","trackbacks"]},Object(c.createElement)(jr.a,{label:Object(v.__)("Discussion"),panelName:"discussion-panel"})),Object(c.createElement)(u.PageAttributesCheck,null,Object(c.createElement)(jr.a,{label:Object(v.__)("Page attributes"),panelName:"page-attributes"}))),Object(c.createElement)(Er,{title:Object(v.__)("Additional panels"),description:Object(v.__)("Add extra areas to the editor.")})):null}));function fr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=Object(at.a)(e);if(t){var i=Object(at.a)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return Object(ot.a)(this,r)}}var Sr=function(e){Object(it.a)(r,e);var t=fr(r);function r(){var e;return Object(rt.a)(this,r),(e=t.apply(this,arguments)).state={historyId:null},e}return Object(nt.a)(r,[{key:"componentDidUpdate",value:function(e){var t=this.props,r=t.postId,n=t.postStatus,i=t.postType,o=t.isSavingPost,a=this.state.historyId;"trash"!==n||o?r===e.postId&&r===a||"auto-draft"===n||this.setBrowserURL(r):this.setTrashURL(r,i)}},{key:"setTrashURL",value:function(e,t){window.location.href=function(e,t){return Object(f.addQueryArgs)("edit.php",{trashed:1,post_type:t,ids:e})}(e,t)}},{key:"setBrowserURL",value:function(e){window.history.replaceState({id:e},"Post "+e,function(e){return Object(f.addQueryArgs)("post.php",{post:e,action:"edit"})}(e)),this.setState((function(){return{historyId:e}}))}},{key:"render",value:function(){return null}}]),r}(c.Component),Mr=Object(h.withSelect)((function(e){var t=e("core/editor"),r=t.getCurrentPost,n=t.isSavingPost,i=r();return{postId:i.id,postStatus:i.status,postType:i.type,isSavingPost:n()}}))(Sr),Zr=r(7),zr=Object(c.createElement)(Zr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(c.createElement)(Zr.Path,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"}));var wr=function(e){var t=e.showTooltip,r=Object(h.useSelect)((function(e){var t=e("core/editor").getCurrentPostType,r=e("core/edit-post").isFeatureActive,n=e("core/data").isResolving,i=e("core"),o=i.getEntityRecord,a=i.getPostType,c=o("root","__unstableBase",void 0)||{};return{isActive:r("fullscreenMode"),isRequestingSiteIcon:n("core","getEntityRecord",["root","__unstableBase",void 0]),postType:a(t()),siteIconUrl:c.site_icon_url}}),[]),n=r.isActive,i=r.isRequestingSiteIcon,o=r.postType,a=r.siteIconUrl;if(!n||!o)return null;var A=Object(c.createElement)(g.Icon,{size:"36px",icon:zr});return a?A=Object(c.createElement)("img",{alt:Object(v.__)("Site Icon"),className:"edit-post-fullscreen-mode-close_site-icon",src:a}):i&&(A=null),Object(c.createElement)(g.Button,{className:"edit-post-fullscreen-mode-close has-icon",href:Object(f.addQueryArgs)("edit.php",{post_type:o.slug}),label:Object(I.get)(o,["labels","view_items"],Object(v.__)("Back")),showTooltip:t},A)},Br=r(209);var Gr=function(){var e=Object(c.useRef)(),t=Object(h.useDispatch)("core/edit-post").setIsInserterOpened,r=Object(h.useSelect)((function(e){var t=e("core/block-editor"),r=t.hasInserterItems,n=t.getBlockRootClientId,i=t.getBlockSelectionEnd;return{hasFixedToolbar:e("core/edit-post").isFeatureActive("fixedToolbar"),isInserterEnabled:"visual"===e("core/edit-post").getEditorMode()&&e("core/editor").getEditorSettings().richEditingEnabled&&r(n(i())),isInserterOpened:e("core/edit-post").isInserterOpened(),isTextModeEnabled:"text"===e("core/edit-post").getEditorMode(),previewDeviceType:e("core/edit-post").__experimentalGetPreviewDeviceType(),showIconLabels:e("core/edit-post").isFeatureActive("showIconLabels"),isNavigationTool:e("core/block-editor").isNavigationMode(),hasReducedUI:e("core/edit-post").isFeatureActive("reducedUI")}}),[]),n=r.hasReducedUI,i=r.hasFixedToolbar,o=r.isInserterEnabled,a=r.isInserterOpened,l=r.isTextModeEnabled,s=r.previewDeviceType,m=r.showIconLabels,q=r.isNavigationTool,p=Object(j.useViewportMatch)("medium"),d=Object(j.useViewportMatch)("wide"),O=Object(j.useViewportMatch)("small","<"),I=Object(h.useDispatch)("core/block-editor").setNavigationMode,b=!p||"Desktop"!==s||i,C=b?Object(v.__)("Document and block tools"):Object(v.__)("Document tools"),y=function(e){I("edit"!==e)},E=Object(c.createElement)(c.Fragment,null,Object(c.createElement)(g.ToolbarItem,{as:u.TableOfContents,hasOutlineItemsDisabled:l,repositionDropdown:m&&!d,showTooltip:!m,isTertiary:m}),Object(c.createElement)(g.ToolbarItem,{as:A.BlockNavigationDropdown,isDisabled:l,showTooltip:!m,isTertiary:m}));return Object(c.createElement)(A.NavigableToolbar,{className:"edit-post-header-toolbar","aria-label":C},Object(c.createElement)("div",{className:"edit-post-header-toolbar__left"},Object(c.createElement)(g.ToolbarItem,{ref:e,as:g.Button,className:"edit-post-header-toolbar__inserter-toggle",isPrimary:!0,isPressed:a,onMouseDown:function(e){e.preventDefault()},onClick:function(){a?e.current.focus():t(!0)},disabled:!o,icon:Br.a,label:Object(v._x)("Add block","Generic label for block inserter button"),showTooltip:!m},m&&Object(v.__)("Add")),!n&&(d||!m)&&Object(c.createElement)(c.Fragment,null,p&&Object(c.createElement)(g.ToolbarItem,{as:A.ToolSelector,showTooltip:!m,isTertiary:m,disabled:l}),Object(c.createElement)(g.ToolbarItem,{as:u.EditorHistoryUndo,showTooltip:!m,isTertiary:m}),Object(c.createElement)(g.ToolbarItem,{as:u.EditorHistoryRedo,showTooltip:!m,isTertiary:m}),E),!n&&!d&&!O&&m&&Object(c.createElement)(g.DropdownMenu,{position:"bottom right",label:Object(v.__)("Tools")},(function(){return Object(c.createElement)("div",{className:"edit-post-header__dropdown"},Object(c.createElement)(g.MenuGroup,{label:Object(v.__)("Modes")},Object(c.createElement)(g.MenuItemsChoice,{value:q?"select":"edit",onSelect:y,choices:[{value:"edit",label:Object(v.__)("Edit")},{value:"select",label:Object(v.__)("Select")}]})),Object(c.createElement)(g.MenuGroup,{label:Object(v.__)("Edit")},Object(c.createElement)(u.EditorHistoryUndo,{showTooltip:!m,isTertiary:m}),Object(c.createElement)(u.EditorHistoryRedo,{showTooltip:!m,isTertiary:m})),Object(c.createElement)(g.MenuGroup,null,E))}))),b&&Object(c.createElement)("div",{className:"edit-post-header-toolbar__block-toolbar"},Object(c.createElement)(A.BlockToolbar,{hideDragHandle:!0})))},Yr=r(316);function kr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Qr(e){for(var t=1;t icon."),{InserterIconImage:Object(c.createElement)(Pn,{className:"edit-post-welcome-guide__inserter-icon"})})))},{image:Object(c.createElement)(Nn,null),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(v.__)("Learn how to use the block editor")),Object(c.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(v.__)("New to the block editor? Want to learn more about using it? "),Object(c.createElement)(g.ExternalLink,{href:Object(v.__)("https://wordpress.org/support/article/wordpress-editor/")},Object(v.__)("Here's a detailed guide."))))}]}):null}var xn=Object(g.createSlotFill)("PluginPostPublishPanel"),Hn=xn.Fill,Rn=xn.Slot,Tn=Object(j.compose)(Object(K.withPluginContext)((function(e,t){return{icon:t.icon||e.icon}})))((function(e){var t=e.children,r=e.className,n=e.title,i=e.initialOpen,o=void 0!==i&&i,a=e.icon;return Object(c.createElement)(Hn,null,Object(c.createElement)(g.PanelBody,{className:r,initialOpen:o||!n,title:n,icon:a},t))}));Tn.Slot=Rn;var Fn=Tn,Un=Object(g.createSlotFill)("PluginPrePublishPanel"),Xn=Un.Fill,Vn=Un.Slot,_n=Object(j.compose)(Object(K.withPluginContext)((function(e,t){return{icon:t.icon||e.icon}})))((function(e){var t=e.children,r=e.className,n=e.title,i=e.initialOpen,o=void 0!==i&&i,a=e.icon;return Object(c.createElement)(Xn,null,Object(c.createElement)(g.PanelBody,{className:r,initialOpen:o||!n,title:n,icon:a},t))}));_n.Slot=Vn;var $n=_n;function ei(e){var t,r=e.setEntitiesSavedStatesCallback,n=e.closeEntitiesSavedStates,i=e.isEntitiesSavedStatesOpen,o=Object(h.useDispatch)("core/edit-post"),a=o.closePublishSidebar,A=o.togglePublishSidebar,l=Object(h.useSelect)((function(e){return{publishSidebarOpened:e("core/edit-post").isPublishSidebarOpened(),hasActiveMetaboxes:e("core/edit-post").hasMetaBoxes(),isSavingMetaBoxes:e("core/edit-post").isSavingMetaBoxes(),hasNonPostEntityChanges:e("core/editor").hasNonPostEntityChanges()}}),[]),s=l.publishSidebarOpened,m=l.hasActiveMetaboxes,q=l.isSavingMetaBoxes,p=l.hasNonPostEntityChanges,d=Object(c.useCallback)((function(){return r(!0)}),[]);return t=s?Object(c.createElement)(u.PostPublishPanel,{onClose:a,forceIsDirty:m,forceIsSaving:q,PrePublishExtension:$n.Slot,PostPublishExtension:Fn.Slot}):p?Object(c.createElement)("div",{className:"edit-post-layout__toggle-entities-saved-states-panel"},Object(c.createElement)(g.Button,{isSecondary:!0,className:"edit-post-layout__toggle-entities-saved-states-panel-button",onClick:d,"aria-expanded":!1},Object(v.__)("Open save panel"))):Object(c.createElement)("div",{className:"edit-post-layout__toggle-publish-panel"},Object(c.createElement)(g.Button,{isSecondary:!0,className:"edit-post-layout__toggle-publish-panel-button",onClick:A,"aria-expanded":!1},Object(v.__)("Open publish panel"))),Object(c.createElement)(c.Fragment,null,Object(c.createElement)(u.EntitiesSavedStates,{isOpen:i,close:n}),!i&&t)}function ti(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=Object(at.a)(e);if(t){var i=Object(at.a)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return Object(ot.a)(this,r)}}function ri(e){e.stopPropagation()}var ni=Object(g.withFocusOutside)(function(e){Object(it.a)(r,e);var t=ti(r);function r(){return Object(rt.a)(this,r),t.apply(this,arguments)}return Object(nt.a)(r,[{key:"handleFocusOutside",value:function(e){this.props.onFocusOutside(e)}},{key:"render",value:function(){return this.props.children}}]),r}(c.Component)),ii=Object(g.withConstrainedTabbing)(Object(g.withFocusReturn)((function(e){return e.children})));function oi(e){var t=e.onClose,r=e.children,n=e.className;return Object(c.createElement)("div",{className:n,onKeyDown:function(e){e.keyCode===Z.ESCAPE&&t&&(e.stopPropagation(),t())},onMouseDown:ri},Object(c.createElement)(ni,{onFocusOutside:t},Object(c.createElement)(ii,null,r)))}var ai={leftSidebar:Object(v.__)("Block library"),header:Object(v.__)("Editor top bar"),body:Object(v.__)("Editor content"),sidebar:Object(v.__)("Editor settings"),actions:Object(v.__)("Editor publish"),footer:Object(v.__)("Editor footer")};var ci=function(){var e=Object(j.useViewportMatch)("medium","<"),t=Object(j.useViewportMatch)("huge",">="),r=Object(h.useDispatch)("core/edit-post"),n=r.openGeneralSidebar,i=r.closeGeneralSidebar,o=r.setIsInserterOpened,a=Object(h.useSelect)((function(e){return{hasFixedToolbar:e("core/edit-post").isFeatureActive("fixedToolbar"),sidebarIsOpened:!(!e("core/interface").getActiveComplementaryArea("core/edit-post")&&!e("core/edit-post").isPublishSidebarOpened()),isFullscreenActive:e("core/edit-post").isFeatureActive("fullscreenMode"),showMostUsedBlocks:e("core/edit-post").isFeatureActive("mostUsedBlocks"),isInserterOpened:e("core/edit-post").isInserterOpened(),mode:e("core/edit-post").getEditorMode(),isRichEditingEnabled:e("core/editor").getEditorSettings().richEditingEnabled,hasActiveMetaboxes:e("core/edit-post").hasMetaBoxes(),previousShortcut:e("core/keyboard-shortcuts").getAllShortcutRawKeyCombinations("core/edit-post/previous-region"),nextShortcut:e("core/keyboard-shortcuts").getAllShortcutRawKeyCombinations("core/edit-post/next-region"),showIconLabels:e("core/edit-post").isFeatureActive("showIconLabels"),hasReducedUI:e("core/edit-post").isFeatureActive("reducedUI")}}),[]),l=a.mode,s=a.isFullscreenActive,m=a.isRichEditingEnabled,q=a.sidebarIsOpened,p=a.hasActiveMetaboxes,d=a.hasFixedToolbar,O=a.previousShortcut,I=a.nextShortcut,b=a.hasBlockSelected,C=a.showMostUsedBlocks,y=a.isInserterOpened,E=a.showIconLabels,f=a.hasReducedUI,S=st()("edit-post-layout","is-mode-"+l,{"is-sidebar-opened":q,"has-fixed-toolbar":d,"has-metaboxes":p,"show-icon-labels":E});Object(c.useEffect)((function(){q&&!t&&o(!1)}),[q,t]),Object(c.useEffect)((function(){y&&!t&&i()}),[y,t]);var M=Object(c.useState)(!1),Z=Object(F.a)(M,2),z=Z[0],w=Z[1],B=Object(c.useCallback)((function(e){"function"==typeof z&&z(e),w(!1)}),[z]);return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(Pt,{isActive:s}),Object(c.createElement)(Mr,null),Object(c.createElement)(u.UnsavedChangesWarning,null),Object(c.createElement)(u.AutosaveMonitor,null),Object(c.createElement)(u.LocalAutosaveMonitor,null),Object(c.createElement)(rr,null),Object(c.createElement)(u.EditorKeyboardShortcutsRegister,null),Object(c.createElement)(Qn,null),Object(c.createElement)(g.FocusReturnProvider,null,Object(c.createElement)(Ht,{className:S,labels:ai,header:Object(c.createElement)(Xr,{setEntitiesSavedStatesCallback:w}),leftSidebar:"visual"===l&&y&&Object(c.createElement)(oi,{className:"edit-post-layout__inserter-panel-popover-wrapper",onClose:function(){return o(!1)}},Object(c.createElement)("div",{className:"edit-post-layout__inserter-panel"},Object(c.createElement)("div",{className:"edit-post-layout__inserter-panel-header"},Object(c.createElement)(g.Button,{icon:_t.a,onClick:function(){return o(!1)}})),Object(c.createElement)("div",{className:"edit-post-layout__inserter-panel-content"},Object(c.createElement)(A.__experimentalLibrary,{showMostUsedBlocks:C,showInserterHelpPanel:!0,onSelect:function(){e&&o(!1)}})))),sidebar:(!e||q)&&Object(c.createElement)(c.Fragment,null,!e&&!q&&Object(c.createElement)("div",{className:"edit-post-layout__toogle-sidebar-panel"},Object(c.createElement)(g.Button,{isSecondary:!0,className:"edit-post-layout__toogle-sidebar-panel-button",onClick:function(){return n(b?"edit-post/block":"edit-post/document")},"aria-expanded":!1},b?Object(v.__)("Open block settings"):Object(v.__)("Open document settings"))),Object(c.createElement)(Yt.Slot,{scope:"core/edit-post"})),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)(u.EditorNotices,null),("text"===l||!m)&&Object(c.createElement)($t,null),m&&"visual"===l&&Object(c.createElement)(tr,null),Object(c.createElement)("div",{className:"edit-post-layout__metaboxes"},Object(c.createElement)(Bn,{location:"normal"}),Object(c.createElement)(Bn,{location:"advanced"})),e&&q&&Object(c.createElement)(g.ScrollLock,null)),footer:!f&&!e&&m&&"visual"===l&&Object(c.createElement)("div",{className:"edit-post-layout__footer"},Object(c.createElement)(A.BlockBreadcrumb,null)),actions:Object(c.createElement)(ei,{closeEntitiesSavedStates:B,isEntitiesSavedStatesOpen:z,setEntitiesSavedStatesCallback:w}),shortcuts:{previous:O,next:I}}),Object(c.createElement)(Or,null),Object(c.createElement)(Kr,null),Object(c.createElement)(sr,null),Object(c.createElement)(Jn,null),Object(c.createElement)(g.Popover.Slot,null),Object(c.createElement)(K.PluginArea,null)))};function Ai(e){var t=e.postId;return function(e){var t=Object(h.useSelect)((function(e){return{hasBlockSelection:!!e("core/block-editor").getBlockSelectionStart(),isEditorSidebarOpened:e("core/edit-post").isEditorSidebarOpened()}}),[e]),r=t.hasBlockSelection,n=t.isEditorSidebarOpened,i=Object(h.useDispatch)("core/edit-post").openGeneralSidebar;Object(c.useEffect)((function(){n&&i(r?"edit-post/block":"edit-post/document")}),[r,n])}(t),function(e){var t=Object(h.useSelect)((function(e){return{newPermalink:e("core/editor").getCurrentPost().link}}),[e]).newPermalink,r=Object(c.useRef)();Object(c.useEffect)((function(){r.current=document.querySelector("#wp-admin-bar-preview a")||document.querySelector("#wp-admin-bar-view a")}),[e]),Object(c.useEffect)((function(){t&&r.current&&r.current.setAttribute("href",t)}),[t])}(t),null}function ui(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function li(e){for(var t=1;t0){var m=!0===e.allowedBlockTypes?Object(I.map)(a,"name"):e.allowedBlockTypes||[];e.allowedBlockTypes=I.without.apply(void 0,[m].concat(Object(L.a)(o)))}return e}},{key:"render",value:function(){var e=this.props,t=e.settings,r=e.hasFixedToolbar,n=e.focusMode,i=e.hasReducedUI,o=e.hasThemeStyles,a=e.post,A=e.postId,l=e.initialEdits,s=e.onError,m=e.hiddenBlockTypes,q=e.blockTypes,p=e.preferredStyleVariations,I=e.__experimentalLocalAutosaveInterval,b=e.setIsInserterOpened,h=e.updatePreferredStyleVariations,v=e.keepCaretInsideBlock,j=Object(O.a)(e,["settings","hasFixedToolbar","focusMode","hasReducedUI","hasThemeStyles","post","postId","initialEdits","onError","hiddenBlockTypes","blockTypes","preferredStyleVariations","__experimentalLocalAutosaveInterval","setIsInserterOpened","updatePreferredStyleVariations","keepCaretInsideBlock"]);if(!a)return null;var C=this.getEditorSettings(t,r,n,i,o,m,q,p,I,b,h,v);return Object(c.createElement)(c.StrictMode,null,Object(c.createElement)(qr.Provider,{value:t},Object(c.createElement)(g.SlotFillProvider,null,Object(c.createElement)(g.DropZoneProvider,null,Object(c.createElement)(u.EditorProvider,Object(d.a)({settings:C,post:a,initialEdits:l,useSubRegistry:!1},j),Object(c.createElement)(u.ErrorBoundary,{onError:s},Object(c.createElement)(Ai,{postId:A}),Object(c.createElement)(ci,null),Object(c.createElement)(g.KeyboardShortcuts,{shortcuts:ut})),Object(c.createElement)(u.PostLockedModal,null))))))}}]),r}(c.Component),qi=Object(j.compose)([Object(h.withSelect)((function(e,t){var r=t.postId,n=t.postType,i=e("core/edit-post"),o=i.isFeatureActive,a=i.getPreference,c=i.__experimentalGetPreviewDeviceType,A=e("core").getEntityRecord,u=e("core/blocks").getBlockTypes;return{hasFixedToolbar:o("fixedToolbar")||"Desktop"!==c(),focusMode:o("focusMode"),hasReducedUI:o("reducedUI"),hasThemeStyles:o("themeStyles"),post:A("postType",n,r),preferredStyleVariations:a("preferredStyleVariations"),hiddenBlockTypes:a("hiddenBlockTypes"),blockTypes:u(),__experimentalLocalAutosaveInterval:a("localAutosaveInterval"),keepCaretInsideBlock:o("keepCaretInsideBlock")}})),Object(h.withDispatch)((function(e){var t=e("core/edit-post");return{updatePreferredStyleVariations:t.updatePreferredStyleVariations,setIsInserterOpened:t.setIsInserterOpened}}))])(mi),pi=r(438),di=function(e,t){return!Array.isArray(t)||(r=e,n=t,0===Object(I.difference)(r,n).length);var r,n},Oi=function(e){var t=e.allowedBlocks,r=e.icon,n=e.label,i=e.onClick,o=e.small,a=e.role;return Object(c.createElement)(A.BlockSettingsMenuControls,null,(function(e){var A=e.selectedBlocks,u=e.onClose;return di(A,t)?Object(c.createElement)(g.MenuItem,{onClick:Object(j.compose)(i,u),icon:r||pi.a,label:o?n:void 0,role:a},!o&&n):null}))},Ii=Object(j.compose)(Object(K.withPluginContext)((function(e,t){return{icon:t.icon||e.icon,name:"core/edit-post/plugin-more-menu"}})))(Lt);function bi(e){return Object(c.createElement)(Dt,Object(d.a)({scope:"core/edit-post"},e))}function gi(e,t,r,n,i){Object(c.unmountComponentAtNode)(r);var o=gi.bind(null,e,t,r,n,i);Object(c.render)(Object(c.createElement)(qi,{settings:n,onError:o,postId:t,postType:e,initialEdits:i,recovery:!0}),r)}function hi(e,t,r,n,i){var o=document.getElementById(e),a=gi.bind(null,t,r,o,n,i);Object(m.registerCoreBlocks)(),"Standards"!==("CSS1Compat"===document.compatMode?"Standards":"Quirks")&&console.warn("Your browser is using Quirks Mode. \nThis can cause rendering issues such as blocks overlaying meta boxes in the editor. Quirks Mode can be triggered by PHP errors or HTML code appearing before the opening . Try checking the raw page source or your site's PHP error log and resolving errors there, removing any HTML before the doctype, or disabling plugins."),-1!==window.navigator.userAgent.indexOf("iPhone")&&window.addEventListener("scroll",(function(e){var t=document.getElementsByClassName("interface-interface-skeleton__body")[0];e.target===document&&(window.scrollY>100&&(t.scrollTop=t.scrollTop+window.scrollY),document.getElementsByClassName("is-mode-visual")[0]&&window.scrollTo(0,0))})),Object(c.render)(Object(c.createElement)(qi,{settings:n,onError:a,postId:r,postType:t,initialEdits:i}),o)}},46:function(e,t){!function(){e.exports=this.wp.a11y}()},47:function(e,t){!function(){e.exports=this.wp.apiFetch}()},489:function(e,t,r){"use strict";var n=r(0),i=r(3),o=r(490),a=Object(i.createSlotFill)("EnablePluginDocumentSettingPanelOption"),c=a.Fill,A=a.Slot,u=function(e){var t=e.label,r=e.panelName;return Object(n.createElement)(c,null,Object(n.createElement)(o.a,{label:t,panelName:r}))};u.Slot=A,t.a=u},490:function(e,t,r){"use strict";var n=r(10),i=r(4),o=r(116);t.a=Object(n.compose)(Object(i.withSelect)((function(e,t){var r=t.panelName,n=e("core/edit-post"),i=n.isEditorPanelEnabled;return{isRemoved:(0,n.isEditorPanelRemoved)(r),isChecked:i(r)}})),Object(n.ifCondition)((function(e){return!e.isRemoved})),Object(i.withDispatch)((function(e,t){var r=t.panelName;return{onChange:function(){return e("core/edit-post").toggleEditorPanelEnabled(r)}}})))(o.a)},5:function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}r.d(t,"a",(function(){return n}))},53:function(e,t){!function(){e.exports=this.wp.keyboardShortcuts}()},6:function(e,t){!function(){e.exports=this.wp.blockEditor}()},60:function(e,t,r){e.exports=function(e,t){var r,n,i=0;function o(){var o,a,c=r,A=arguments.length;e:for(;c;){if(c.args.length===arguments.length){for(a=0;a