WordPress/wp-includes/js/dist/edit-post.min.js

7 lines
118 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*! This file is auto-generated */
this.wp=this.wp||{},this.wp.editPost=function(e){var t={};function n(c){if(t[c])return t[c].exports;var a=t[c]={i:c,l:!1,exports:{}};return e[c].call(a.exports,a,a.exports,n),a.l=!0,a.exports}return n.m=e,n.c=t,n.d=function(e,t,c){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:c})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var c=Object.create(null);if(n.r(c),Object.defineProperty(c,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(c,a,function(t){return e[t]}.bind(null,a));return c},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="dSQ2")}({"0dt7":function(e,t,n){"use strict";n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return l}));const c="core/edit-post",a="#wp-admin-bar-view a",l="#wp-admin-bar-preview a"},"1ZqX":function(e,t){e.exports=window.wp.data},"1iEr":function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"}));t.a=l},"2gm7":function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"}));t.a=l},"51Zz":function(e,t){e.exports=window.wp.dataControls},"6aBm":function(e,t){e.exports=window.wp.mediaUtils},"8oxB":function(e,t){var n,c,a=e.exports={};function l(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function r(e){if(n===setTimeout)return setTimeout(e,0);if((n===l||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:l}catch(e){n=l}try{c="function"==typeof clearTimeout?clearTimeout:o}catch(e){c=o}}();var i,s=[],u=!1,d=-1;function b(){u&&i&&(u=!1,i.length?s=i.concat(s):d=-1,s.length&&m())}function m(){if(!u){var e=r(b);u=!0;for(var t=s.length;t;){for(i=s,s=[];++d<t;)i&&i[d].run();d=-1,t=s.length}i=null,u=!1,function(e){if(c===clearTimeout)return clearTimeout(e);if((c===o||!c)&&clearTimeout)return c=clearTimeout,clearTimeout(e);try{c(e)}catch(t){try{return c.call(null,e)}catch(t){return c.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function O(){}a.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];s.push(new p(e,t)),1!==s.length||u||r(m)},p.prototype.run=function(){this.fun.apply(null,this.array)},a.title="browser",a.browser=!0,a.env={},a.argv=[],a.version="",a.versions={},a.on=O,a.addListener=O,a.once=O,a.off=O,a.removeListener=O,a.removeAllListeners=O,a.emit=O,a.prependListener=O,a.prependOnceListener=O,a.listeners=function(e){return[]},a.binding=function(e){throw new Error("process.binding is not supported")},a.cwd=function(){return"/"},a.chdir=function(e){throw new Error("process.chdir is not supported")},a.umask=function(){return 0}},Cg8A:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{fillRule:"evenodd",d:"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",clipRule:"evenodd"}));t.a=l},Civd:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M18 5.5H6a.5.5 0 00-.5.5v3h13V6a.5.5 0 00-.5-.5zm.5 5H10v8h8a.5.5 0 00.5-.5v-7.5zm-10 0h-3V18a.5.5 0 00.5.5h2.5v-8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"}));t.a=l},GRId:function(e,t){e.exports=window.wp.element},HSyU:function(e,t){e.exports=window.wp.blocks},"K+tz":function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.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"}));t.a=l},K9lf:function(e,t){e.exports=window.wp.compose},KEfo:function(e,t){e.exports=window.wp.viewport},Mmq9:function(e,t){e.exports=window.wp.url},NWDH:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(c.createElement)(a.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"}));t.a=l},OzlF:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(c.createElement)(a.Path,{d:"M13.8 5.2H3v1.5h10.8V5.2zm-3.6 12v1.5H21v-1.5H10.2zm7.2-6H6.6v1.5h10.8v-1.5z"}));t.a=l},Q4Sy:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z"}));t.a=l},QyPg:function(e,t){e.exports=window.wp.blockLibrary},RMJe:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"}));t.a=l},RxS6:function(e,t){e.exports=window.wp.keycodes},T40v:function(e,t,n){"use strict";n.d(t,"a",(function(){return we}));var c={};n.r(c),n.d(c,"openGeneralSidebar",(function(){return h})),n.d(c,"closeGeneralSidebar",(function(){return _})),n.d(c,"openModal",(function(){return f})),n.d(c,"closeModal",(function(){return v})),n.d(c,"openPublishSidebar",(function(){return y})),n.d(c,"closePublishSidebar",(function(){return w})),n.d(c,"togglePublishSidebar",(function(){return S})),n.d(c,"toggleEditorPanelEnabled",(function(){return k})),n.d(c,"toggleEditorPanelOpened",(function(){return P})),n.d(c,"removeEditorPanel",(function(){return T})),n.d(c,"toggleFeature",(function(){return x})),n.d(c,"switchEditorMode",(function(){return I})),n.d(c,"togglePinnedPluginItem",(function(){return C})),n.d(c,"hideBlockTypes",(function(){return B})),n.d(c,"updatePreferredStyleVariations",(function(){return N})),n.d(c,"__experimentalUpdateLocalAutosaveInterval",(function(){return M})),n.d(c,"showBlockTypes",(function(){return A})),n.d(c,"setAvailableMetaBoxesPerLocation",(function(){return L})),n.d(c,"requestMetaBoxUpdates",(function(){return R})),n.d(c,"metaBoxUpdatesSuccess",(function(){return D})),n.d(c,"metaBoxUpdatesFailure",(function(){return F})),n.d(c,"__experimentalSetPreviewDeviceType",(function(){return V})),n.d(c,"setIsInserterOpened",(function(){return U})),n.d(c,"setIsListViewOpened",(function(){return G})),n.d(c,"setIsEditingTemplate",(function(){return z})),n.d(c,"__unstableSwitchToTemplateMode",(function(){return q})),n.d(c,"__unstableCreateTemplate",(function(){return H})),n.d(c,"initializeMetaBoxes",(function(){return K}));var a={};n.r(a),n.d(a,"getEditorMode",(function(){return Q})),n.d(a,"isEditorSidebarOpened",(function(){return X})),n.d(a,"isPluginSidebarOpened",(function(){return Z})),n.d(a,"getActiveGeneralSidebarName",(function(){return $})),n.d(a,"getPreferences",(function(){return J})),n.d(a,"getPreference",(function(){return ee})),n.d(a,"isPublishSidebarOpened",(function(){return te})),n.d(a,"isEditorPanelRemoved",(function(){return ne})),n.d(a,"isEditorPanelEnabled",(function(){return ce})),n.d(a,"isEditorPanelOpened",(function(){return ae})),n.d(a,"isModalActive",(function(){return le})),n.d(a,"isFeatureActive",(function(){return oe})),n.d(a,"isPluginItemPinned",(function(){return re})),n.d(a,"getActiveMetaBoxLocations",(function(){return ie})),n.d(a,"isMetaBoxLocationVisible",(function(){return se})),n.d(a,"isMetaBoxLocationActive",(function(){return ue})),n.d(a,"getMetaBoxesPerLocation",(function(){return de})),n.d(a,"getAllMetaBoxes",(function(){return be})),n.d(a,"hasMetaBoxes",(function(){return me})),n.d(a,"isSavingMetaBoxes",(function(){return pe})),n.d(a,"__experimentalGetPreviewDeviceType",(function(){return Oe})),n.d(a,"isInserterOpened",(function(){return je})),n.d(a,"__experimentalGetInsertionPoint",(function(){return Ee})),n.d(a,"isListViewOpened",(function(){return ge})),n.d(a,"isEditingTemplate",(function(){return he})),n.d(a,"areMetaBoxesInitialized",(function(){return _e})),n.d(a,"getEditedPostTemplate",(function(){return fe}));var l=n("1ZqX"),o=n("51Zz"),r=n("YLtl");const i=Object(r.flow)([l.combineReducers,(s={editorMode:"visual",panels:{"post-status":{opened:!0}},hiddenBlockTypes:[],preferredStyleVariations:{},localAutosaveInterval:15},e=>function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s,n=arguments.length>1?arguments[1]:void 0;return e(t,n)})])({panels(e,t){switch(t.type){case"TOGGLE_PANEL_ENABLED":{const{panelName:n}=t;return{...e,[n]:{...e[n],enabled:!Object(r.get)(e,[n,"enabled"],!0)}}}case"TOGGLE_PANEL_OPENED":{const{panelName:n}=t,c=!0===e[n]||Object(r.get)(e,[n,"opened"],!1);return{...e,[n]:{...e[n],opened:!c}}}}return e},editorMode:(e,t)=>"SWITCH_MODE"===t.type?t.mode:e,hiddenBlockTypes(e,t){switch(t.type){case"SHOW_BLOCK_TYPES":return Object(r.without)(e,...t.blockNames);case"HIDE_BLOCK_TYPES":return Object(r.union)(e,t.blockNames)}return e},preferredStyleVariations(e,t){switch(t.type){case"UPDATE_PREFERRED_STYLE_VARIATIONS":return t.blockName?t.blockStyle?{...e,[t.blockName]:t.blockStyle}:Object(r.omit)(e,[t.blockName]):e}return e},localAutosaveInterval(e,t){switch(t.type){case"UPDATE_LOCAL_AUTOSAVE_INTERVAL":return t.interval}return e}});var s;const u=Object(l.combineReducers)({isSaving:function(){let 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":case"META_BOX_UPDATES_FAILURE":return!1;default:return e}},locations:function(){let 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},initialized:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"META_BOXES_INITIALIZED":return!0}return e}});var d=Object(l.combineReducers)({activeModal:function(){let 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:u,preferences:i,publishSidebarActive:function(){let 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(){let 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(r.includes)(e,t.panelName))return[...e,t.panelName]}return e},deviceType:function(){let 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},blockInserterPanel:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_IS_LIST_VIEW_OPENED":return!t.isOpen&&e;case"SET_IS_INSERTER_OPENED":return t.value}return e},listViewPanel:function(){let 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&&e;case"SET_IS_LIST_VIEW_OPENED":return t.isOpen}return e},isEditingTemplate:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_IS_EDITING_TEMPLATE":return t.value}return e}}),b=n("l3Sj"),m=n("U60i"),p=n("gdqT"),O=n("onLe"),j=n("jZUy"),E=n("axFQ"),g=n("jSdM");function*h(e){yield l.controls.dispatch(m.i,"enableComplementaryArea",we.name,e)}function*_(){yield l.controls.dispatch(m.i,"disableComplementaryArea",we.name)}function f(e){return{type:"OPEN_MODAL",name:e}}function v(){return{type:"CLOSE_MODAL"}}function y(){return{type:"OPEN_PUBLISH_SIDEBAR"}}function w(){return{type:"CLOSE_PUBLISH_SIDEBAR"}}function S(){return{type:"TOGGLE_PUBLISH_SIDEBAR"}}function k(e){return{type:"TOGGLE_PANEL_ENABLED",panelName:e}}function P(e){return{type:"TOGGLE_PANEL_OPENED",panelName:e}}function T(e){return{type:"REMOVE_PANEL",panelName:e}}function*x(e){yield l.controls.dispatch(m.i.name,"toggleFeature","core/edit-post",e)}function*I(e){yield{type:"SWITCH_MODE",mode:e},"visual"!==e&&(yield l.controls.dispatch(E.store,"clearSelectedBlock"));const t="visual"===e?Object(b.__)("Visual editor selected"):Object(b.__)("Code editor selected");Object(p.speak)(t,"assertive")}function*C(e){const t=yield l.controls.select(m.i,"isItemPinned","core/edit-post",e);yield l.controls.dispatch(m.i,t?"unpinItem":"pinItem","core/edit-post",e)}function B(e){return{type:"HIDE_BLOCK_TYPES",blockNames:Object(r.castArray)(e)}}function N(e,t){return{type:"UPDATE_PREFERRED_STYLE_VARIATIONS",blockName:e,blockStyle:t}}function M(e){return{type:"UPDATE_LOCAL_AUTOSAVE_INTERVAL",interval:e}}function A(e){return{type:"SHOW_BLOCK_TYPES",blockNames:Object(r.castArray)(e)}}function*L(e){yield{type:"SET_META_BOXES_PER_LOCATIONS",metaBoxesPerLocation:e}}function*R(){yield{type:"REQUEST_META_BOX_UPDATES"},window.tinyMCE&&window.tinyMCE.triggerSave();const e=yield l.controls.select(g.store,"getCurrentPost"),t=[!!e.comment_status&&["comment_status",e.comment_status],!!e.ping_status&&["ping_status",e.ping_status],!!e.sticky&&["sticky",e.sticky],!!e.author&&["post_author",e.author]].filter(Boolean),n=[new window.FormData(document.querySelector(".metabox-base-form")),...(yield l.controls.select(we,"getActiveMetaBoxLocations")).map(e=>new window.FormData((e=>{const t=document.querySelector(`.edit-post-meta-boxes-area.is-${e} .metabox-location-${e}`);return t||document.querySelector("#metaboxes .metabox-location-"+e)})(e)))],c=Object(r.reduce)(n,(e,t)=>{for(const[n,c]of t)e.append(n,c);return e},new window.FormData);t.forEach(e=>{let[t,n]=e;return c.append(t,n)});try{yield Object(o.apiFetch)({url:window._wpMetaBoxUrl,method:"POST",body:c,parse:!1}),yield l.controls.dispatch(we,"metaBoxUpdatesSuccess")}catch{yield l.controls.dispatch(we,"metaBoxUpdatesFailure")}}function D(){return{type:"META_BOX_UPDATES_SUCCESS"}}function F(){return{type:"META_BOX_UPDATES_FAILURE"}}function V(e){return{type:"SET_PREVIEW_DEVICE_TYPE",deviceType:e}}function U(e){return{type:"SET_IS_INSERTER_OPENED",value:e}}function G(e){return{type:"SET_IS_LIST_VIEW_OPENED",isOpen:e}}function z(e){return{type:"SET_IS_EDITING_TEMPLATE",value:e}}function*q(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];yield z(!0);const t=yield l.controls.select(we,"isFeatureActive","welcomeGuideTemplate");if(!t){const t=e?Object(b.__)("Custom template created. You're in template mode now."):Object(b.__)("Editing template. Changes made here affect all posts and pages that use the template.");yield l.controls.dispatch(O.store,"createSuccessNotice",t,{type:"snackbar"})}}function*H(e){const t=yield l.controls.dispatch(j.store,"saveEntityRecord","postType","wp_template",e),n=yield l.controls.select(g.store,"getCurrentPost");yield l.controls.dispatch(j.store,"editEntityRecord","postType",n.type,n.id,{template:t.slug})}let W=!1;function*K(){if(!(yield l.controls.select(g.store,"__unstableIsEditorReady")))return;const e=yield l.controls.select(g.store,"getCurrentPostType");if(W)return;window.postboxes.page!==e&&window.postboxes.add_postbox_toggles(e),W=!0;let t=yield l.controls.select(g.store,"isSavingPost"),n=yield l.controls.select(g.store,"isAutosavingPost");const c=yield l.controls.select(we,"hasMetaBoxes");return Object(l.subscribe)(()=>{const e=Object(l.select)(g.store).isSavingPost(),a=Object(l.select)(g.store).isAutosavingPost(),o=c&&t&&!e&&!n;t=e,n=a,o&&Object(l.dispatch)(we).requestMetaBoxUpdates()}),{type:"META_BOXES_INITIALIZED"}}var Y=n("pPDe");function Q(e){return ee(e,"editorMode","visual")}const X=Object(l.createRegistrySelector)(e=>()=>{const t=e(m.i).getActiveComplementaryArea("core/edit-post");return Object(r.includes)(["edit-post/document","edit-post/block"],t)}),Z=Object(l.createRegistrySelector)(e=>()=>{const t=e(m.i).getActiveComplementaryArea("core/edit-post");return!!t&&!Object(r.includes)(["edit-post/document","edit-post/block"],t)}),$=Object(l.createRegistrySelector)(e=>()=>e(m.i).getActiveComplementaryArea("core/edit-post"));function J(e){return e.preferences}function ee(e,t,n){const c=J(e)[t];return void 0===c?n:c}function te(e){return e.publishSidebarActive}function ne(e,t){return Object(r.includes)(e.removedPanels,t)}function ce(e,t){const n=ee(e,"panels");return!ne(e,t)&&Object(r.get)(n,[t,"enabled"],!0)}function ae(e,t){const n=ee(e,"panels");return!0===Object(r.get)(n,[t])||!0===Object(r.get)(n,[t,"opened"])}function le(e,t){return e.activeModal===t}const oe=Object(l.createRegistrySelector)(e=>(t,n)=>e(m.i).isFeatureActive("core/edit-post",n)),re=Object(l.createRegistrySelector)(e=>(t,n)=>e(m.i).isItemPinned("core/edit-post",n)),ie=Object(Y.a)(e=>Object.keys(e.metaBoxes.locations).filter(t=>ue(e,t)),e=>[e.metaBoxes.locations]);function se(e,t){return ue(e,t)&&Object(r.some)(de(e,t),t=>{let{id:n}=t;return ce(e,"meta-box-"+n)})}function ue(e,t){const n=de(e,t);return!!n&&0!==n.length}function de(e,t){return e.metaBoxes.locations[t]}const be=Object(Y.a)(e=>Object(r.flatten)(Object(r.values)(e.metaBoxes.locations)),e=>[e.metaBoxes.locations]);function me(e){return ie(e).length>0}function pe(e){return e.metaBoxes.isSaving}function Oe(e){return e.deviceType}function je(e){return!!e.blockInserterPanel}function Ee(e){const{rootClientId:t,insertionIndex:n,filterValue:c}=e.blockInserterPanel;return{rootClientId:t,insertionIndex:n,filterValue:c}}function ge(e){return e.listViewPanel}function he(e){return e.isEditingTemplate}function _e(e){return e.metaBoxes.initialized}const fe=Object(l.createRegistrySelector)(e=>()=>{const t=e(g.store).getEditedPostAttribute("template");if(t){var n;const c=null===(n=e(j.store).getEntityRecords("postType","wp_template"))||void 0===n?void 0:n.find(e=>e.slug===t);return c?e(j.store).getEditedEntityRecord("postType","wp_template",c.id):c}const c=e(g.store).getCurrentPost();return c.link?e(j.store).__experimentalGetTemplateForLink(c.link):null});var ve=n("0dt7");const ye={reducer:d,actions:c,selectors:a,controls:o.controls,persist:["preferences"]},we=Object(l.createReduxStore)(ve.a,ye);Object(l.registerStore)(ve.a,ye)},TSYQ:function(e,t,n){var c;
/*!
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
*/!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;t<arguments.length;t++){var c=arguments[t];if(c){var l=typeof c;if("string"===l||"number"===l)e.push(c);else if(Array.isArray(c)){if(c.length){var o=a.apply(null,c);o&&e.push(o)}}else if("object"===l)if(c.toString===Object.prototype.toString)for(var r in c)n.call(c,r)&&c[r]&&e.push(r);else e.push(c.toString())}}return e.join(" ")}e.exports?(a.default=a,e.exports=a):void 0===(c=function(){return a}.apply(t,[]))||(e.exports=c)}()},Tqx9:function(e,t){e.exports=window.wp.primitives},TvNi:function(e,t){e.exports=window.wp.plugins},U60i:function(e,t,n){"use strict";n.d(t,"b",(function(){return K})),n.d(t,"c",(function(){return G})),n.d(t,"d",(function(){return Y})),n.d(t,"e",(function(){return X})),n.d(t,"h",(function(){return q})),n.d(t,"f",(function(){return $})),n.d(t,"g",(function(){return ee})),n.d(t,"a",(function(){return V})),n.d(t,"i",(function(){return M}));var c={};n.r(c),n.d(c,"enableComplementaryArea",(function(){return y})),n.d(c,"disableComplementaryArea",(function(){return w})),n.d(c,"pinItem",(function(){return k})),n.d(c,"unpinItem",(function(){return P})),n.d(c,"toggleFeature",(function(){return T})),n.d(c,"setFeatureValue",(function(){return x})),n.d(c,"setFeatureDefaults",(function(){return I}));var a={};n.r(a),n.d(a,"getActiveComplementaryArea",(function(){return C})),n.d(a,"isItemPinned",(function(){return B})),n.d(a,"isFeatureActive",(function(){return N}));var l=n("wx14"),o=n("GRId"),r=n("TSYQ"),i=n.n(r),s=n("tI+e"),u=n("1ZqX"),d=n("l3Sj"),b=n("RMJe"),m=n("URob"),p=n("Xxwi"),O=n("KEfo"),j=n("bWcr"),E=n("YLtl");const g=Object(u.combineReducers)({features(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;if("SET_FEATURE_DEFAULTS"===t.type){const{scope:n,defaults:c}=t;return{...e,[n]:{...e[n],...c}}}return e}}),h=Object(u.combineReducers)({features(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;if("SET_FEATURE_VALUE"===t.type){const{scope:n,featureName:c,value:a}=t;return{...e,[n]:{...e[n],[c]:a}}}return e}}),_=Object(u.combineReducers)({singleEnableItems:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{type:t,itemType:n,scope:c,item:a}=arguments.length>1?arguments[1]:void 0;return"SET_SINGLE_ENABLE_ITEM"===t&&n&&c?{...e,[n]:{...e[n],[c]:a||null}}:e},multipleEnableItems:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{type:t,itemType:n,scope:c,item:a,isEnable:l}=arguments.length>1?arguments[1]:void 0;if("SET_MULTIPLE_ENABLE_ITEM"!==t||!n||!c||!a||Object(E.get)(e,[n,c,a])===l)return e;const o=e[n]||{},r=o[c]||{};return{...e,[n]:{...o,[c]:{...r,[a]:l||!1}}}}});var f=Object(u.combineReducers)({enableItems:_,preferenceDefaults:g,preferences:h});function v(e,t,n){return{type:"SET_SINGLE_ENABLE_ITEM",itemType:e,scope:t,item:n}}function y(e,t){return v("complementaryArea",e,t)}function w(e){return v("complementaryArea",e,void 0)}function S(e,t,n,c){return{type:"SET_MULTIPLE_ENABLE_ITEM",itemType:e,scope:t,item:n,isEnable:c}}function k(e,t){return S("pinnedItems",e,t,!0)}function P(e,t){return S("pinnedItems",e,t,!1)}function T(e,t){return function(n){let{select:c,dispatch:a}=n;const l=c.isFeatureActive(e,t);a.setFeatureValue(e,t,!l)}}function x(e,t,n){return{type:"SET_FEATURE_VALUE",scope:e,featureName:t,value:!!n}}function I(e,t){return{type:"SET_FEATURE_DEFAULTS",scope:e,defaults:t}}function C(e,t){return function(e,t,n){return Object(E.get)(e.enableItems.singleEnableItems,[t,n])}(e,"complementaryArea",t)}function B(e,t,n){return!1!==function(e,t,n,c){return Object(E.get)(e.enableItems.multipleEnableItems,[t,n,c])}(e,"pinnedItems",t,n)}function N(e,t,n){var c,a;const l=null===(c=e.preferences.features[t])||void 0===c?void 0:c[n];return!!(void 0!==l?l:null===(a=e.preferenceDefaults.features[t])||void 0===a?void 0:a[n])}const M=Object(u.createReduxStore)("core/interface",{reducer:f,actions:c,selectors:a,persist:["enableItems","preferences"],__experimentalUseThunks:!0});Object(u.registerStore)("core/interface",{reducer:f,actions:c,selectors:a,persist:["enableItems","preferences"],__experimentalUseThunks:!0});var A=n("TvNi"),L=Object(A.withPluginContext)((e,t)=>({icon:t.icon||e.icon,identifier:t.identifier||`${e.name}/${t.name}`}));var R=L((function(e){let{as:t=s.Button,scope:n,identifier:c,icon:a,selectedIcon:r,...i}=e;const d=t,b=Object(u.useSelect)(e=>e(M).getActiveComplementaryArea(n)===c,[c]),{enableComplementaryArea:m,disableComplementaryArea:p}=Object(u.useDispatch)(M);return Object(o.createElement)(d,Object(l.a)({icon:r&&b?r:a,onClick:()=>{b?p(n):m(n,c)}},Object(E.omit)(i,["name"])))}));var D=e=>{let{smallScreenTitle:t,children:n,className:c,toggleButtonProps:a}=e;const r=Object(o.createElement)(R,Object(l.a)({icon:j.a},a));return Object(o.createElement)(o.Fragment,null,Object(o.createElement)("div",{className:"components-panel__header interface-complementary-area-header__small"},t&&Object(o.createElement)("span",{className:"interface-complementary-area-header__small-title"},t),r),Object(o.createElement)("div",{className:i()("components-panel__header","interface-complementary-area-header",c),tabIndex:-1},n,r))};function F(e){let{name:t,as:n=s.Button,onClick:c,...a}=e;return Object(o.createElement)(s.Fill,{name:t},e=>{let{onClick:t}=e;return Object(o.createElement)(n,Object(l.a)({onClick:c||t?function(){(c||E.noop)(...arguments),(t||E.noop)(...arguments)}:void 0},a))})}F.Slot=function(e){let{name:t,as:n=s.ButtonGroup,fillProps:c={},bubblesVirtually:a,...l}=e;return Object(o.createElement)(s.Slot,{name:t,bubblesVirtually:a,fillProps:c},e=>{if(Object(E.isEmpty)(o.Children.toArray(e)))return null;const t=[];o.Children.forEach(e,e=>{let{props:{__unstableExplicitMenuItem:n,__unstableTarget:c}}=e;c&&n&&t.push(c)});const c=o.Children.map(e,e=>!e.props.__unstableExplicitMenuItem&&t.includes(e.props.__unstableTarget)?null:e);return Object(o.createElement)(n,l,c)})};var V=F;const U=e=>Object(o.createElement)(s.MenuItem,Object(E.omit)(e,["__unstableExplicitMenuItem","__unstableTarget"]));function G(e){let{scope:t,target:n,__unstableExplicitMenuItem:c,...a}=e;return Object(o.createElement)(R,Object(l.a)({as:e=>Object(o.createElement)(V,Object(l.a)({__unstableExplicitMenuItem:c,__unstableTarget:`${t}/${n}`,as:U,name:t+"/plugin-more-menu"},e)),role:"menuitemcheckbox",selectedIcon:b.a,name:n,scope:t},a))}function z(e){let{scope:t,...n}=e;return Object(o.createElement)(s.Fill,Object(l.a)({name:"PinnedItems/"+t},n))}z.Slot=function(e){let{scope:t,className:n,...c}=e;return Object(o.createElement)(s.Slot,Object(l.a)({name:"PinnedItems/"+t},c),e=>!Object(E.isEmpty)(e)&&Object(o.createElement)("div",{className:i()(n,"interface-pinned-items")},e))};var q=z;function H(e){let{scope:t,children:n,className:c}=e;return Object(o.createElement)(s.Fill,{name:"ComplementaryArea/"+t},Object(o.createElement)("div",{className:c},n))}const W=L((function(e){let{children:t,className:n,closeLabel:c=Object(d.__)("Close plugin"),identifier:a,header:l,headerClassName:r,icon:j,isPinnable:E=!0,panelClassName:g,scope:h,name:_,smallScreenTitle:f,title:v,toggleShortcut:y,isActiveByDefault:w,showIconLabels:S=!1}=e;const{isActive:k,isPinned:P,activeArea:T,isSmall:x,isLarge:I}=Object(u.useSelect)(e=>{const{getActiveComplementaryArea:t,isItemPinned:n}=e(M),c=t(h);return{isActive:c===a,isPinned:n(h,a),activeArea:c,isSmall:e(O.store).isViewportMatch("< medium"),isLarge:e(O.store).isViewportMatch("large")}},[a,h]);!function(e,t,n,c,a){const l=Object(o.useRef)(!1),r=Object(o.useRef)(!1),{enableComplementaryArea:i,disableComplementaryArea:s}=Object(u.useDispatch)(M);Object(o.useEffect)(()=>{c&&a&&!l.current?(s(e),r.current=!0):r.current&&!a&&l.current?(r.current=!1,i(e,t)):r.current&&n&&n!==t&&(r.current=!1),a!==l.current&&(l.current=a)},[c,a,e,t,n])}(h,a,T,k,x);const{enableComplementaryArea:C,disableComplementaryArea:B,pinItem:N,unpinItem:A}=Object(u.useDispatch)(M);return Object(o.useEffect)(()=>{w&&void 0===T&&!x&&C(h,a)},[T,w,h,a,x]),Object(o.createElement)(o.Fragment,null,E&&Object(o.createElement)(q,{scope:h},P&&Object(o.createElement)(R,{scope:h,identifier:a,isPressed:k&&(!S||I),"aria-expanded":k,label:v,icon:S?b.a:j,showTooltip:!S,variant:S?"tertiary":void 0})),_&&E&&Object(o.createElement)(G,{target:_,scope:h,icon:j},v),k&&Object(o.createElement)(H,{className:i()("interface-complementary-area",n),scope:h},Object(o.createElement)(D,{className:r,closeLabel:c,onClose:()=>B(h),smallScreenTitle:f,toggleButtonProps:{label:c,shortcut:y,scope:h,identifier:a}},l||Object(o.createElement)(o.Fragment,null,Object(o.createElement)("strong",null,v),E&&Object(o.createElement)(s.Button,{className:"interface-complementary-area__pin-unpin-item",icon:P?m.a:p.a,label:P?Object(d.__)("Unpin from toolbar"):Object(d.__)("Pin to toolbar"),onClick:()=>(P?A:N)(h,a),isPressed:P,"aria-expanded":P}))),Object(o.createElement)(s.Panel,{className:g},t)))}));W.Slot=function(e){let{scope:t,...n}=e;return Object(o.createElement)(s.Slot,Object(l.a)({name:"ComplementaryArea/"+t},n))};var K=W;var Y=e=>{let{isActive:t}=e;return Object(o.useEffect)(()=>{let e=!1;return document.body.classList.contains("sticky-menu")&&(e=!0,document.body.classList.remove("sticky-menu")),()=>{e&&document.body.classList.add("sticky-menu")}},[]),Object(o.useEffect)(()=>(t?document.body.classList.add("is-fullscreen-mode"):document.body.classList.remove("is-fullscreen-mode"),()=>{t&&document.body.classList.remove("is-fullscreen-mode")}),[t]),null},Q=n("K9lf");var X=Object(o.forwardRef)((function(e,t){let{footer:n,header:c,sidebar:a,secondarySidebar:r,notices:u,content:b,drawer:m,actions:p,labels:O,className:j,shortcuts:E}=e;const g=Object(s.__unstableUseNavigateRegions)(E);!function(e){Object(o.useEffect)(()=>{const t=document&&document.querySelector(`html:not(.${e})`);if(t)return t.classList.toggle(e),()=>{t.classList.toggle(e)}},[e])}("interface-interface-skeleton__html-container");const h={...{drawer:Object(d.__)("Drawer"),header:Object(d.__)("Header"),body:Object(d.__)("Content"),secondarySidebar:Object(d.__)("Block Library"),sidebar:Object(d.__)("Settings"),actions:Object(d.__)("Publish"),footer:Object(d.__)("Footer")},...O};return Object(o.createElement)("div",Object(l.a)({},g,{ref:Object(Q.useMergeRefs)([t,g.ref]),className:i()(j,"interface-interface-skeleton",g.className,!!n&&"has-footer")}),!!m&&Object(o.createElement)("div",{className:"interface-interface-skeleton__drawer",role:"region","aria-label":h.drawer},m),Object(o.createElement)("div",{className:"interface-interface-skeleton__editor"},!!c&&Object(o.createElement)("div",{className:"interface-interface-skeleton__header",role:"region","aria-label":h.header,tabIndex:"-1"},c),Object(o.createElement)("div",{className:"interface-interface-skeleton__body"},!!r&&Object(o.createElement)("div",{className:"interface-interface-skeleton__secondary-sidebar",role:"region","aria-label":h.secondarySidebar,tabIndex:"-1"},r),!!u&&Object(o.createElement)("div",{className:"interface-interface-skeleton__notices"},u),Object(o.createElement)("div",{className:"interface-interface-skeleton__content",role:"region","aria-label":h.body,tabIndex:"-1"},b),!!a&&Object(o.createElement)("div",{className:"interface-interface-skeleton__sidebar",role:"region","aria-label":h.sidebar,tabIndex:"-1"},a),!!p&&Object(o.createElement)("div",{className:"interface-interface-skeleton__actions",role:"region","aria-label":h.actions,tabIndex:"-1"},p))),!!n&&Object(o.createElement)("div",{className:"interface-interface-skeleton__footer",role:"region","aria-label":h.footer,tabIndex:"-1"},n))})),Z=n("VKE3");function $(e){let{as:t=s.DropdownMenu,className:n,label:c=Object(d.__)("Options"),popoverProps:a,toggleProps:l,children:r}=e;return Object(o.createElement)(t,{className:i()("interface-more-menu-dropdown",n),icon:Z.a,label:c,popoverProps:{position:"bottom left",...a,className:i()("interface-more-menu-dropdown__content",null==a?void 0:a.className)},toggleProps:{tooltipPosition:"bottom",...l}},e=>r(e))}var J=n("gdqT");function ee(e){let{scope:t,label:n,info:c,messageActivated:a,messageDeactivated:l,shortcut:r,feature:i}=e;const m=Object(u.useSelect)(e=>e(M).isFeatureActive(t,i),[i]),{toggleFeature:p}=Object(u.useDispatch)(M);return Object(o.createElement)(s.MenuItem,{icon:m&&b.a,isSelected:m,onClick:()=>{p(t,i),m?Object(J.speak)(l||Object(d.__)("Feature deactivated")):Object(J.speak)(a||Object(d.__)("Feature activated"))},role:"menuitemcheckbox",info:c,shortcut:r},n)}},URob:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.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"}));t.a=l},VKE3:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));t.a=l},Xxwi:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{fillRule:"evenodd",d:"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",clipRule:"evenodd"}));t.a=l},Y5n4:function(e,t,n){"use strict";n.d(t,"a",(function(){return u})),n.d(t,"c",(function(){return m})),n.d(t,"d",(function(){return E})),n.d(t,"e",(function(){return h})),n.d(t,"b",(function(){return _}));var c=n("GRId"),a=n("l3Sj"),l=n("tI+e"),o=n("1ZqX"),r=n("jSdM");var i=function(e){let{help:t,label:n,isChecked:a,onChange:o,children:r}=e;return Object(c.createElement)("div",{className:"edit-post-preferences-modal__option"},Object(c.createElement)(l.ToggleControl,{help:t,label:n,checked:a,onChange:o}),r)};function s(e){let{willEnable:t}=e;const[n,o]=Object(c.useState)(!1);return Object(c.createElement)(c.Fragment,null,Object(c.createElement)("p",{className:"edit-post-preferences-modal__custom-fields-confirmation-message"},Object(a.__)("A page reload is required for this change. Make sure your content is saved before reloading.")),Object(c.createElement)(l.Button,{className:"edit-post-preferences-modal__custom-fields-confirmation-button",variant:"secondary",isBusy:n,disabled:n,onClick:()=>{o(!0),document.getElementById("toggle-custom-fields-form").submit()}},t?Object(a.__)("Enable & Reload"):Object(a.__)("Disable & Reload")))}var u=Object(o.withSelect)(e=>({areCustomFieldsEnabled:!!e(r.store).getEditorSettings().enableCustomFields}))((function(e){let{label:t,areCustomFieldsEnabled:n}=e;const[a,l]=Object(c.useState)(n);return Object(c.createElement)(i,{label:t,isChecked:a,onChange:l},a!==n&&Object(c.createElement)(s,{willEnable:a}))})),d=n("K9lf"),b=n("T40v"),m=Object(d.compose)(Object(o.withSelect)((e,t)=>{let{panelName:n}=t;const{isEditorPanelEnabled:c,isEditorPanelRemoved:a}=e(b.a);return{isRemoved:a(n),isChecked:c(n)}}),Object(d.ifCondition)(e=>{let{isRemoved:t}=e;return!t}),Object(o.withDispatch)((e,t)=>{let{panelName:n}=t;return{onChange:()=>e(b.a).toggleEditorPanelEnabled(n)}}))(i);const{Fill:p,Slot:O}=Object(l.createSlotFill)("EnablePluginDocumentSettingPanelOption"),j=e=>{let{label:t,panelName:n}=e;return Object(c.createElement)(p,null,Object(c.createElement)(m,{label:t,panelName:n}))};j.Slot=O;var E=j,g=n("KEfo"),h=Object(d.compose)(Object(o.withSelect)(e=>({isChecked:e(r.store).isPublishSidebarEnabled()})),Object(o.withDispatch)(e=>{const{enablePublishSidebar:t,disablePublishSidebar:n}=e(r.store);return{onChange:e=>e?t():n()}}),Object(g.ifViewportMatches)("medium"))(i),_=Object(d.compose)(Object(o.withSelect)((e,t)=>{let{featureName:n}=t;const{isFeatureActive:c}=e(b.a);return{isChecked:c(n)}}),Object(o.withDispatch)((e,t)=>{let{featureName:n}=t;return{onChange:()=>e(b.a).toggleFeature(n)}}))(i)},YLtl:function(e,t){e.exports=window.lodash},Z23Y:function(e,t){e.exports=window.wp.warning},axFQ:function(e,t){e.exports=window.wp.blockEditor},bWcr:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.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"}));t.a=l},cjQ8:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.Path,{d:"M20 10.8H6.7l4.1-4.5-1.1-1.1-5.8 6.3 5.8 5.8 1.1-1.1-4-3.9H20z"}));t.a=l},dSQ2:function(e,t,n){"use strict";n.r(t),n.d(t,"reinitializeEditor",(function(){return Yt})),n.d(t,"initializeEditor",(function(){return Qt})),n.d(t,"PluginBlockSettingsMenuItem",(function(){return Ht})),n.d(t,"PluginDocumentSettingPanel",(function(){return jt.a})),n.d(t,"PluginMoreMenuItem",(function(){return Wt})),n.d(t,"PluginPostPublishPanel",(function(){return Ct})),n.d(t,"PluginPostStatusInfo",(function(){return et})),n.d(t,"PluginPrePublishPanel",(function(){return At})),n.d(t,"PluginSidebar",(function(){return Et})),n.d(t,"PluginSidebarMoreMenuItem",(function(){return Kt})),n.d(t,"__experimentalFullscreenModeClose",(function(){return me})),n.d(t,"__experimentalMainDashboardButton",(function(){return Ie})),n.d(t,"store",(function(){return S.a}));var c=n("GRId"),a=n("HSyU"),l=n("QyPg"),o=n("1ZqX"),r=n("U60i"),i=n("g56x"),s=n("6aBm");Object(i.addFilter)("editor.MediaUpload","core/edit-post/replace-media-upload",()=>s.MediaUpload);var u=n("wx14"),d=n("YLtl"),b=n("tI+e"),m=n("axFQ"),p=n("l3Sj"),O=n("K9lf");const j=Object(O.compose)(Object(o.withSelect)((e,t)=>{if(Object(a.hasBlockSupport)(t.name,"multiple",!0))return{};const n=e(m.store).getBlocks(),c=Object(d.find)(n,e=>{let{name:n}=e;return t.name===n});return{originalBlockClientId:c&&c.clientId!==t.clientId&&c.clientId}}),Object(o.withDispatch)((e,t)=>{let{originalBlockClientId:n}=t;return{selectFirst:()=>e(m.store).selectBlock(n)}})),E=Object(O.createHigherOrderComponent)(e=>j(t=>{let{originalBlockClientId:n,selectFirst:l,...o}=t;if(!n)return Object(c.createElement)(e,o);const r=Object(a.getBlockType)(o.name),i=function(e){const t=Object(a.findTransform)(Object(a.getBlockTransforms)("to",e),e=>{let{type:t,blocks:n}=e;return"block"===t&&1===n.length});if(!t)return null;return Object(a.getBlockType)(t.blocks[0])}(o.name);return[Object(c.createElement)("div",{key:"invalid-preview",style:{minHeight:"60px"}},Object(c.createElement)(e,Object(u.a)({key:"block-edit"},o))),Object(c.createElement)(m.Warning,{key:"multiple-use-warning",actions:[Object(c.createElement)(b.Button,{key:"find-original",variant:"secondary",onClick:l},Object(p.__)("Find original")),Object(c.createElement)(b.Button,{key:"remove",variant:"secondary",onClick:()=>o.onReplace([])},Object(p.__)("Remove")),i&&Object(c.createElement)(b.Button,{key:"transform",variant:"secondary",onClick:()=>o.onReplace(Object(a.createBlock)(i.name,o.attributes))},Object(p.__)("Transform into:")," ",i.title)]},Object(c.createElement)("strong",null,null==r?void 0:r.title,": "),Object(p.__)("This block can only be used once."))]}),"withMultipleValidation");Object(i.addFilter)("editor.BlockEdit","core/edit-post/validate-multiple-use/with-multiple-validation",E);var g=n("K+tz"),h=n("TvNi"),_=n("Mmq9"),f=n("onLe"),v=n("jSdM");function y(){const{createNotice:e}=Object(o.useDispatch)(f.store),t=Object(o.useSelect)(e=>()=>e(v.store).getEditedPostAttribute("content"),[]);const n=Object(O.useCopyToClipboard)(t,(function(){e("info",Object(p.__)("All content copied."),{isDismissible:!0,type:"snackbar"})}));return Object(c.createElement)(b.MenuItem,{ref:n},Object(p.__)("Copy all content"))}var w=n("RxS6"),S=n("T40v");var k=Object(o.withDispatch)(e=>{const{openModal:t}=e(S.a);return{openModal:t}})((function(e){let{openModal:t}=e;return Object(c.createElement)(b.MenuItem,{onClick:()=>{t("edit-post/keyboard-shortcut-help")},shortcut:w.displayShortcut.access("h")},Object(p.__)("Keyboard shortcuts"))}));const{Fill:P,Slot:T}=Object(b.createSlotFill)("ToolsMoreMenuGroup");P.Slot=e=>{let{fillProps:t}=e;return Object(c.createElement)(T,{fillProps:t},e=>!Object(d.isEmpty)(e)&&Object(c.createElement)(b.MenuGroup,{label:Object(p.__)("Tools")},e))};var x=P;function I(){const e=Object(o.useSelect)(e=>e(S.a).isEditingTemplate(),[]);return Object(c.createElement)(r.g,{scope:"core/edit-post",feature:e?"welcomeGuideTemplate":"welcomeGuide",label:Object(p.__)("Welcome Guide")})}Object(h.registerPlugin)("edit-post",{render:()=>Object(c.createElement)(c.Fragment,null,Object(c.createElement)(x,null,e=>{let{onClose:t}=e;return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(b.MenuItem,{role:"menuitem",href:Object(_.addQueryArgs)("edit.php",{post_type:"wp_block"})},Object(p.__)("Manage Reusable blocks")),Object(c.createElement)(k,{onSelect:t}),Object(c.createElement)(I,null),Object(c.createElement)(y,null),Object(c.createElement)(b.MenuItem,{role:"menuitem",icon:g.a,href:Object(p.__)("https://wordpress.org/support/article/wordpress-editor/"),target:"_blank",rel:"noopener noreferrer"},Object(p.__)("Help"),Object(c.createElement)(b.VisuallyHidden,{as:"span"},Object(p.__)("(opens in a new tab)"))))}))});var C=n("jZUy"),B=n("hF7m"),N={"t a l e s o f g u t e n b e r g":e=>{const{ownerDocument:t}=e.target;(t.activeElement.classList.contains("edit-post-visual-editor")||t.activeElement===t.body)&&(e.preventDefault(),window.wp.data.dispatch("core/block-editor").insertBlock(window.wp.blocks.createBlock("core/paragraph",{content:"🐡🐢🦀🐤🦋🐘🐧🐹🦁🦄🦍🐼🐿🎃🐴🐝🐆🦕🦔🌱🍇π🍌🐉💧🥨🌌🍂🍠🥦🥚🥝🎟🥥🥒🛵🥖🍒🍯🎾🎲🐺🐚🐮⌛️"})))}},M=n("TSYQ"),A=n.n(M);var L=Object(O.compose)(Object(o.withSelect)(e=>({isRichEditingEnabled:e(v.store).getEditorSettings().richEditingEnabled})),Object(o.withDispatch)(e=>({onExit(){e(S.a).switchEditorMode("visual")}})))((function(e){let{onExit:t,isRichEditingEnabled:n}=e;return Object(c.createElement)("div",{className:"edit-post-text-editor"},n&&Object(c.createElement)("div",{className:"edit-post-text-editor__toolbar"},Object(c.createElement)("h2",null,Object(p.__)("Editing code")),Object(c.createElement)(b.Button,{variant:"tertiary",onClick:t,shortcut:w.displayShortcut.secondary("m")},Object(p.__)("Exit code editor")),Object(c.createElement)(v.TextEditorGlobalKeyboardShortcuts,null)),Object(c.createElement)("div",{className:"edit-post-text-editor__body"},Object(c.createElement)(v.PostTitle,null),Object(c.createElement)(v.PostTextEditor,null)))})),R=n("cjQ8"),D=n("gdqT");var F=function(e){let{onClick:t=d.noop,small:n=!1}=e;const{shortcut:a,areAdvancedSettingsOpened:l}=Object(o.useSelect)(e=>({shortcut:e(B.store).getShortcutRepresentation("core/edit-post/toggle-sidebar"),areAdvancedSettingsOpened:"edit-post/block"===e(S.a).getActiveGeneralSidebarName()}),[]),{openGeneralSidebar:r,closeGeneralSidebar:i}=Object(o.useDispatch)(S.a),s=l?Object(p.__)("Hide more settings"):Object(p.__)("Show more settings");return Object(c.createElement)(b.MenuItem,{onClick:()=>{l?(i(),Object(D.speak)(Object(p.__)("Block settings closed"))):(r("edit-post/block"),Object(D.speak)(Object(p.__)("Additional settings are now available in the Editor block settings sidebar"))),t()},shortcut:a},!n&&s)};function V(e){let{children:t,contentRef:n,shouldIframe:a,styles:l,style:o}=e;const r=Object(m.__unstableUseMouseMoveTypingReset)();return a?Object(c.createElement)(m.__unstableIframe,{head:Object(c.createElement)(m.__unstableEditorStyles,{styles:l}),ref:r,contentRef:n,style:{width:"100%",height:"100%",display:"block"},name:"editor-canvas"},t):Object(c.createElement)(c.Fragment,null,Object(c.createElement)(m.__unstableEditorStyles,{styles:l}),Object(c.createElement)(m.WritingFlow,{ref:n,className:"editor-styles-wrapper",style:{flex:"1",...o},tabIndex:-1},t))}function U(e){let{styles:t}=e;const{deviceType:n,isTemplateMode:a,wrapperBlockName:l,wrapperUniqueId:r}=Object(o.useSelect)(e=>{const{isEditingTemplate:t,__experimentalGetPreviewDeviceType:n}=e(S.a),{getCurrentPostId:c,getCurrentPostType:a}=e(v.store),l=t();let o;return"wp_block"===a()?o="core/block":l||(o="core/post-content"),{deviceType:n(),isTemplateMode:l,wrapperBlockName:o,wrapperUniqueId:c()}},[]),i=Object(o.useSelect)(e=>e(S.a).hasMetaBoxes(),[]),s=Object(o.useSelect)(e=>{const{getSettings:t}=e(m.store);return t().supportsLayout},[]),{clearSelectedBlock:u}=Object(o.useDispatch)(m.store),{setIsEditingTemplate:d}=Object(o.useDispatch)(S.a),j={width:"100%",margin:0,display:"flex",flexFlow:"column",background:"white"},E={...j,borderRadius:"2px 2px 0 0",border:"1px solid #ddd",borderBottom:0},g=Object(m.__experimentalUseResizeCanvas)(n,a),h=Object(m.useSetting)("layout"),_="is-"+n.toLowerCase()+"-preview";let f,y=a?E:j;g&&(y=g),i||g||a||(f="40vh");const w=Object(c.useRef)(),k=Object(O.useMergeRefs)([w,Object(m.__unstableUseClipboardHandler)(),Object(m.__unstableUseCanvasClickRedirect)(),Object(m.__unstableUseTypewriter)(),Object(m.__unstableUseTypingObserver)(),Object(m.__unstableUseBlockSelectionClearer)()]),P=Object(m.__unstableUseBlockSelectionClearer)(),[,T]=Object(m.__experimentalUseNoRecursiveRenders)(r,l),x=Object(c.useMemo)(()=>a?{type:"default"}:s?h:void 0,[a,s,h]);return Object(c.createElement)(m.BlockTools,{__unstableContentRef:w,className:A()("edit-post-visual-editor",{"is-template-mode":a})},Object(c.createElement)(v.VisualEditorGlobalKeyboardShortcuts,null),Object(c.createElement)(b.__unstableMotion.div,{className:"edit-post-visual-editor__content-area",animate:{padding:a?"48px 48px 0":"0"},ref:P},a&&Object(c.createElement)(b.Button,{className:"edit-post-visual-editor__exit-template-mode",icon:R.a,onClick:()=>{u(),d(!1)}},Object(p.__)("Back")),Object(c.createElement)(b.__unstableMotion.div,{animate:y,initial:j,className:_},Object(c.createElement)(V,{shouldIframe:a||"Tablet"===n||"Mobile"===n,contentRef:k,styles:t,style:{paddingBottom:f}},s&&!a&&Object(c.createElement)(m.__experimentalLayoutStyle,{selector:".edit-post-visual-editor__post-title-wrapper, .block-editor-block-list__layout.is-root-container",layout:h}),!a&&Object(c.createElement)("div",{className:"edit-post-visual-editor__post-title-wrapper"},Object(c.createElement)(v.PostTitle,null)),Object(c.createElement)(T,null,Object(c.createElement)(m.BlockList,{className:a?"wp-site-blocks":void 0,__experimentalLayout:x}))))),Object(c.createElement)(m.__unstableBlockSettingsMenuFirstItem,null,e=>{let{onClose:t}=e;return Object(c.createElement)(F,{onClick:t})}))}var G=function(){const{getBlockSelectionStart:e}=Object(o.useSelect)(m.store),{getEditorMode:t,isEditorSidebarOpened:n,isListViewOpened:a}=Object(o.useSelect)(S.a),l=Object(o.useSelect)(e=>{const{richEditingEnabled:t,codeEditingEnabled:n}=e(v.store).getEditorSettings();return!t||!n},[]),{switchEditorMode:r,openGeneralSidebar:i,closeGeneralSidebar:s,toggleFeature:u,setIsListViewOpened:d}=Object(o.useDispatch)(S.a),{registerShortcut:b}=Object(o.useDispatch)(B.store);return Object(c.useEffect)(()=>{b({name:"core/edit-post/toggle-mode",category:"global",description:Object(p.__)("Switch between visual editor and code editor."),keyCombination:{modifier:"secondary",character:"m"}}),b({name:"core/edit-post/toggle-fullscreen",category:"global",description:Object(p.__)("Toggle fullscreen mode."),keyCombination:{modifier:"secondary",character:"f"}}),b({name:"core/edit-post/toggle-list-view",category:"global",description:Object(p.__)("Open the block list view."),keyCombination:{modifier:"access",character:"o"}}),b({name:"core/edit-post/toggle-sidebar",category:"global",description:Object(p.__)("Show or hide the settings sidebar."),keyCombination:{modifier:"primaryShift",character:","}}),b({name:"core/edit-post/next-region",category:"global",description:Object(p.__)("Navigate to the next part of the editor."),keyCombination:{modifier:"ctrl",character:"`"},aliases:[{modifier:"access",character:"n"}]}),b({name:"core/edit-post/previous-region",category:"global",description:Object(p.__)("Navigate to the previous part of the editor."),keyCombination:{modifier:"ctrlShift",character:"`"},aliases:[{modifier:"access",character:"p"}]}),b({name:"core/edit-post/keyboard-shortcuts",category:"main",description:Object(p.__)("Display these keyboard shortcuts."),keyCombination:{modifier:"access",character:"h"}})},[]),Object(B.useShortcut)("core/edit-post/toggle-mode",()=>{r("visual"===t()?"text":"visual")},{isDisabled:l}),Object(B.useShortcut)("core/edit-post/toggle-fullscreen",()=>{u("fullscreenMode")}),Object(B.useShortcut)("core/edit-post/toggle-sidebar",t=>{if(t.preventDefault(),n())s();else{const t=e()?"edit-post/block":"edit-post/document";i(t)}}),Object(B.useShortcut)("core/edit-post/toggle-list-view",()=>d(!a())),null};const z=[{keyCombination:{modifier:"primary",character:"b"},description:Object(p.__)("Make the selected text bold.")},{keyCombination:{modifier:"primary",character:"i"},description:Object(p.__)("Make the selected text italic.")},{keyCombination:{modifier:"primary",character:"k"},description:Object(p.__)("Convert the selected text into a link.")},{keyCombination:{modifier:"primaryShift",character:"k"},description:Object(p.__)("Remove a link.")},{keyCombination:{modifier:"primary",character:"u"},description:Object(p.__)("Underline the selected text.")}];function q(e){let{keyCombination:t,forceAriaLabel:n}=e;const a=t.modifier?w.displayShortcutList[t.modifier](t.character):t.character,l=t.modifier?w.shortcutAriaLabel[t.modifier](t.character):t.character;return Object(c.createElement)("kbd",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-key-combination","aria-label":n||l},Object(d.castArray)(a).map((e,t)=>"+"===e?Object(c.createElement)(c.Fragment,{key:t},e):Object(c.createElement)("kbd",{key:t,className:"edit-post-keyboard-shortcut-help-modal__shortcut-key"},e)))}var H=function(e){let{description:t,keyCombination:n,aliases:a=[],ariaLabel:l}=e;return Object(c.createElement)(c.Fragment,null,Object(c.createElement)("div",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-description"},t),Object(c.createElement)("div",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-term"},Object(c.createElement)(q,{keyCombination:n,forceAriaLabel:l}),a.map((e,t)=>Object(c.createElement)(q,{keyCombination:e,forceAriaLabel:l,key:t}))))};var W=function(e){let{name:t}=e;const{keyCombination:n,description:a,aliases:l}=Object(o.useSelect)(e=>{const{getShortcutKeyCombination:n,getShortcutDescription:c,getShortcutAliases:a}=e(B.store);return{keyCombination:n(t),aliases:a(t),description:c(t)}},[t]);return n?Object(c.createElement)(H,{keyCombination:n,description:a,aliases:l}):null};const K="edit-post/keyboard-shortcut-help",Y=e=>{let{shortcuts:t}=e;return Object(c.createElement)("ul",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-list",role:"list"},t.map((e,t)=>Object(c.createElement)("li",{className:"edit-post-keyboard-shortcut-help-modal__shortcut",key:t},Object(d.isString)(e)?Object(c.createElement)(W,{name:e}):Object(c.createElement)(H,e))))},Q=e=>{let{title:t,shortcuts:n,className:a}=e;return Object(c.createElement)("section",{className:A()("edit-post-keyboard-shortcut-help-modal__section",a)},!!t&&Object(c.createElement)("h2",{className:"edit-post-keyboard-shortcut-help-modal__section-title"},t),Object(c.createElement)(Y,{shortcuts:n}))},X=e=>{let{title:t,categoryName:n,additionalShortcuts:a=[]}=e;const l=Object(o.useSelect)(e=>e(B.store).getCategoryShortcuts(n),[n]);return Object(c.createElement)(Q,{title:t,shortcuts:l.concat(a)})};var Z=Object(O.compose)([Object(o.withSelect)(e=>({isModalActive:e(S.a).isModalActive(K)})),Object(o.withDispatch)((e,t)=>{let{isModalActive:n}=t;const{openModal:c,closeModal:a}=e(S.a);return{toggleModal:()=>n?a():c(K)}})])((function(e){let{isModalActive:t,toggleModal:n}=e;return Object(B.useShortcut)("core/edit-post/keyboard-shortcuts",n),t?Object(c.createElement)(b.Modal,{className:"edit-post-keyboard-shortcut-help-modal",title:Object(p.__)("Keyboard shortcuts"),closeLabel:Object(p.__)("Close"),onRequestClose:n},Object(c.createElement)(Q,{className:"edit-post-keyboard-shortcut-help-modal__main-shortcuts",shortcuts:["core/edit-post/keyboard-shortcuts"]}),Object(c.createElement)(X,{title:Object(p.__)("Global shortcuts"),categoryName:"global"}),Object(c.createElement)(X,{title:Object(p.__)("Selection shortcuts"),categoryName:"selection"}),Object(c.createElement)(X,{title:Object(p.__)("Block shortcuts"),categoryName:"block",additionalShortcuts:[{keyCombination:{character:"/"},description:Object(p.__)("Change the block type after adding a new paragraph."),ariaLabel:Object(p.__)("Forward-slash")}]}),Object(c.createElement)(Q,{title:Object(p.__)("Text formatting"),shortcuts:z})):null})),$=n("iClF"),J=n("2gm7"),ee=n("1iEr");var te=e=>{let{description:t,title:n,children:a}=e;return Object(c.createElement)("section",{className:"edit-post-preferences-modal__section"},Object(c.createElement)("h2",{className:"edit-post-preferences-modal__section-title"},n),t&&Object(c.createElement)("p",{className:"edit-post-preferences-modal__section-description"},t),a)},ne=n("Y5n4");var ce=Object(o.withSelect)(e=>{const{getEditorSettings:t}=e(v.store),{getAllMetaBoxes:n}=e(S.a);return{areCustomFieldsRegistered:void 0!==t().enableCustomFields,metaBoxes:n()}})((function(e){let{areCustomFieldsRegistered:t,metaBoxes:n,...a}=e;const l=Object(d.filter)(n,e=>{let{id:t}=e;return"postcustom"!==t});return t||0!==l.length?Object(c.createElement)(te,a,t&&Object(c.createElement)(ne.a,{label:Object(p.__)("Custom fields")}),Object(d.map)(l,e=>{let{id:t,title:n}=e;return Object(c.createElement)(ne.c,{key:t,label:n,panelName:"meta-box-"+t})})):null}));var ae=function(e){let{blockTypes:t,value:n,onItemChange:a}=e;return Object(c.createElement)("ul",{className:"edit-post-block-manager__checklist"},t.map(e=>Object(c.createElement)("li",{key:e.name,className:"edit-post-block-manager__checklist-item"},Object(c.createElement)(b.CheckboxControl,{label:Object(c.createElement)(c.Fragment,null,e.title,Object(c.createElement)(m.BlockIcon,{icon:e.icon})),checked:n.includes(e.name),onChange:Object(d.partial)(a,e.name)}))))};var le=Object(c.createContext)({});var oe=Object(O.compose)([O.withInstanceId,Object(o.withSelect)(e=>{const{getPreference:t}=e(S.a);return{hiddenBlockTypes:t("hiddenBlockTypes")}}),Object(o.withDispatch)((e,t)=>{const{showBlockTypes:n,hideBlockTypes:c}=e(S.a);return{toggleVisible(e,t){t?n(e):c(e)},toggleAllVisible(e){const a=Object(d.map)(t.blockTypes,"name");e?n(a):c(a)}}})])((function(e){let{instanceId:t,title:n,blockTypes:a,hiddenBlockTypes:l,toggleVisible:o,toggleAllVisible:r}=e;const i=Object(c.useContext)(le),{allowedBlockTypes:s}=i,u=Object(c.useMemo)(()=>!0===s?a:a.filter(e=>{let{name:t}=e;return Object(d.includes)(s||[],t)}),[s,a]);if(!u.length)return null;const m=Object(d.without)(Object(d.map)(u,"name"),...l),p="edit-post-block-manager__category-title-"+t,O=m.length===u.length;let j;return j=O?"true":m.length>0?"mixed":"false",Object(c.createElement)("div",{role:"group","aria-labelledby":p,className:"edit-post-block-manager__category"},Object(c.createElement)(b.CheckboxControl,{checked:O,onChange:r,className:"edit-post-block-manager__category-title","aria-checked":j,label:Object(c.createElement)("span",{id:p},n)}),Object(c.createElement)(ae,{blockTypes:u,value:m,onItemChange:o}))}));var re=Object(o.withSelect)(e=>{const{getBlockTypes:t,getCategories:n,hasBlockSupport:c,isMatchingSearchTerm:l}=e(a.store),{getPreference:o}=e(S.a),r=o("hiddenBlockTypes"),i=Object(d.isArray)(r)&&r.length;return{blockTypes:t(),categories:n(),hasBlockSupport:c,isMatchingSearchTerm:l,numberOfHiddenBlocks:i}})((function(e){let{blockTypes:t,categories:n,hasBlockSupport:a,isMatchingSearchTerm:l,numberOfHiddenBlocks:o}=e;const[r,i]=Object(c.useState)("");return t=t.filter(e=>a(e,"inserter",!0)&&(!r||l(e,r))&&(!e.parent||Object(d.includes)(e.parent,"core/post-content"))),Object(c.createElement)("div",{className:"edit-post-block-manager__content"},!!o&&Object(c.createElement)("div",{className:"edit-post-block-manager__disabled-blocks-count"},Object(p.sprintf)(Object(p._n)("%d block is hidden.","%d blocks are hidden.",o),o)),Object(c.createElement)(b.SearchControl,{label:Object(p.__)("Search for a block"),placeholder:Object(p.__)("Search for a block"),value:r,onChange:e=>i(e),className:"edit-post-block-manager__search"}),Object(c.createElement)("div",{tabIndex:"0",role:"region","aria-label":Object(p.__)("Available block types"),className:"edit-post-block-manager__results"},0===t.length&&Object(c.createElement)("p",{className:"edit-post-block-manager__no-results"},Object(p.__)("No blocks found.")),n.map(e=>Object(c.createElement)(oe,{key:e.slug,title:e.title,blockTypes:Object(d.filter)(t,{category:e.slug})})),Object(c.createElement)(oe,{title:Object(p.__)("Uncategorized"),blockTypes:Object(d.filter)(t,e=>{let{category:t}=e;return!t})})))}));function ie(e){let{as:t=b.Button,path:n,isBack:a=!1,...l}=e;const o=Object(b.__experimentalUseNavigator)();return Object(c.createElement)(t,Object(u.a)({onClick:()=>o.push(n,{isBack:a})},l))}function se(){const e=Object(O.useViewportMatch)("medium"),{closeModal:t}=Object(o.useDispatch)(S.a),{isModalActive:n,isViewable:a}=Object(o.useSelect)(e=>{const{getEditedPostAttribute:t}=e(v.store),{getPostType:n}=e(C.store),c=n(t("type"));return{isModalActive:e(S.a).isModalActive("edit-post/preferences"),isViewable:Object(d.get)(c,["viewable"],!1)}},[]),l=Object(o.useSelect)(t=>{const{getEditorSettings:n}=t(v.store),{getEditorMode:c,isFeatureActive:a}=t(S.a),l=c(),o=n().richEditingEnabled;return!a("reducedUI")&&e&&o&&"visual"===l},[e]),r=Object(c.useMemo)(()=>[{name:"general",tabLabel:Object(p.__)("General"),content:Object(c.createElement)(c.Fragment,null,e&&Object(c.createElement)(te,{title:Object(p.__)("Publishing"),description:Object(p.__)("Change options related to publishing.")},Object(c.createElement)(ne.e,{help:Object(p.__)("Review settings, such as visibility and tags."),label:Object(p.__)("Include pre-publish checklist")})),Object(c.createElement)(te,{title:Object(p.__)("Appearance"),description:Object(p.__)("Customize options related to the block editor interface and editing flow.")},Object(c.createElement)(ne.b,{featureName:"reducedUI",help:Object(p.__)("Compacts options and outlines in the toolbar."),label:Object(p.__)("Reduce the interface")}),Object(c.createElement)(ne.b,{featureName:"focusMode",help:Object(p.__)("Highlights the current block and fades other content."),label:Object(p.__)("Spotlight mode")}),Object(c.createElement)(ne.b,{featureName:"showIconLabels",help:Object(p.__)("Shows text instead of icons."),label:Object(p.__)("Display button labels")}),Object(c.createElement)(ne.b,{featureName:"themeStyles",help:Object(p.__)("Make the editor look like your theme."),label:Object(p.__)("Use theme styles")}),l&&Object(c.createElement)(ne.b,{featureName:"showBlockBreadcrumbs",help:Object(p.__)("Shows block breadcrumbs at the bottom of the editor."),label:Object(p.__)("Display block breadcrumbs")})))},{name:"blocks",tabLabel:Object(p.__)("Blocks"),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)(te,{title:Object(p.__)("Block interactions"),description:Object(p.__)("Customize how you interact with blocks in the block library and editing canvas.")},Object(c.createElement)(ne.b,{featureName:"mostUsedBlocks",help:Object(p.__)("Places the most frequent blocks in the block library."),label:Object(p.__)("Show most used blocks")}),Object(c.createElement)(ne.b,{featureName:"keepCaretInsideBlock",help:Object(p.__)("Aids screen readers by stopping text caret from leaving blocks."),label:Object(p.__)("Contain text cursor inside block")})),Object(c.createElement)(te,{title:Object(p.__)("Visible blocks"),description:Object(p.__)("Disable blocks that you don't want to appear in the inserter. They can always be toggled back on later.")},Object(c.createElement)(re,null)))},{name:"panels",tabLabel:Object(p.__)("Panels"),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)(te,{title:Object(p.__)("Document settings"),description:Object(p.__)("Choose what displays in the panel.")},Object(c.createElement)(ne.d.Slot,null),a&&Object(c.createElement)(ne.c,{label:Object(p.__)("Permalink"),panelName:"post-link"}),a&&Object(c.createElement)(ne.c,{label:Object(p.__)("Template"),panelName:"template"}),Object(c.createElement)(v.PostTaxonomies,{taxonomyWrapper:(e,t)=>Object(c.createElement)(ne.c,{label:Object(d.get)(t,["labels","menu_name"]),panelName:"taxonomy-panel-"+t.slug})}),Object(c.createElement)(v.PostFeaturedImageCheck,null,Object(c.createElement)(ne.c,{label:Object(p.__)("Featured image"),panelName:"featured-image"})),Object(c.createElement)(v.PostExcerptCheck,null,Object(c.createElement)(ne.c,{label:Object(p.__)("Excerpt"),panelName:"post-excerpt"})),Object(c.createElement)(v.PostTypeSupportCheck,{supportKeys:["comments","trackbacks"]},Object(c.createElement)(ne.c,{label:Object(p.__)("Discussion"),panelName:"discussion-panel"})),Object(c.createElement)(v.PageAttributesCheck,null,Object(c.createElement)(ne.c,{label:Object(p.__)("Page attributes"),panelName:"page-attributes"}))),Object(c.createElement)(ce,{title:Object(p.__)("Additional"),description:Object(p.__)("Add extra areas to the editor.")}))}],[a,e,l]),[i,s]=Object(c.useState)("preferences-menu"),{tabs:u,sectionsContentMap:m}=Object(c.useMemo)(()=>r.reduce((e,t)=>{let{name:n,tabLabel:c,content:a}=t;return e.tabs.push({name:n,title:c}),e.sectionsContentMap[n]=a,e},{tabs:[],sectionsContentMap:{}}),[r]),j=Object(c.useCallback)(e=>m[e.name]||null,[m]);if(!n)return null;let E;return E=e?Object(c.createElement)(b.TabPanel,{className:"edit-post-preferences__tabs",tabs:u,initialTabName:"preferences-menu"!==i?i:void 0,onSelect:s,orientation:"vertical"},j):Object(c.createElement)(b.__experimentalNavigatorProvider,{initialPath:"/"},Object(c.createElement)(b.__experimentalNavigatorScreen,{path:"/"},Object(c.createElement)(b.Card,{isBorderless:!0,size:"small"},Object(c.createElement)(b.CardBody,null,Object(c.createElement)(b.__experimentalItemGroup,null,u.map(e=>Object(c.createElement)(ie,{key:e.name,path:e.name,as:b.__experimentalItem,isAction:!0},Object(c.createElement)(b.__experimentalHStack,{justify:"space-between"},Object(c.createElement)(b.FlexItem,null,Object(c.createElement)(b.__experimentalTruncate,null,e.title)),Object(c.createElement)(b.FlexItem,null,Object(c.createElement)($.a,{icon:Object(p.isRTL)()?J.a:ee.a}))))))))),r.map(e=>Object(c.createElement)(b.__experimentalNavigatorScreen,{key:e.name+"-menu",path:e.name},Object(c.createElement)(b.Card,{isBorderless:!0,size:"large"},Object(c.createElement)(b.CardHeader,{isBorderless:!1,justify:"left",size:"small",gap:"6"},Object(c.createElement)(ie,{path:"/",icon:Object(p.isRTL)()?ee.a:J.a,isBack:!0,"aria-label":Object(p.__)("Navigate to the previous view")}),Object(c.createElement)(b.__experimentalText,{size:"16"},e.tabLabel)),Object(c.createElement)(b.CardBody,null,e.content))))),Object(c.createElement)(b.Modal,{className:"edit-post-preferences-modal",title:Object(p.__)("Preferences"),closeLabel:Object(p.__)("Close"),onRequestClose:t},E)}class ue extends c.Component{constructor(){super(...arguments),this.state={historyId:null}}componentDidUpdate(e){const{postId:t,postStatus:n,postType:c,isSavingPost:a}=this.props,{historyId:l}=this.state;"trash"!==n||a?t===e.postId&&t===l||"auto-draft"===n||!t||this.setBrowserURL(t):this.setTrashURL(t,c)}setTrashURL(e,t){window.location.href=function(e,t){return Object(_.addQueryArgs)("edit.php",{trashed:1,post_type:t,ids:e})}(e,t)}setBrowserURL(e){window.history.replaceState({id:e},"Post "+e,function(e){return Object(_.addQueryArgs)("post.php",{post:e,action:"edit"})}(e)),this.setState(()=>({historyId:e}))}render(){return null}}var de=Object(o.withSelect)(e=>{const{getCurrentPost:t,isSavingPost:n}=e(v.store),c=t();let{id:a,status:l,type:o}=c;return["wp_template","wp_template_part"].includes(o)&&(a=c.wp_id),{postId:a,postStatus:l,postType:o,isSavingPost:n()}})(ue),be=n("wduq");var me=function(e){let{showTooltip:t,icon:n,href:a}=e;const{isActive:l,isRequestingSiteIcon:r,postType:i,siteIconUrl:s}=Object(o.useSelect)(e=>{const{getCurrentPostType:t}=e(v.store),{isFeatureActive:n}=e(S.a),{getEntityRecord:c,getPostType:a,isResolving:l}=e(C.store),o=c("root","__unstableBase",void 0)||{};return{isActive:n("fullscreenMode"),isRequestingSiteIcon:l("getEntityRecord",["root","__unstableBase",void 0]),postType:a(t()),siteIconUrl:o.site_icon_url}},[]),u=Object(O.useReducedMotion)();if(!l||!i)return null;let m=Object(c.createElement)(b.Icon,{size:"36px",icon:be.a});const j={expand:{scale:1.7,borderRadius:0,transition:{type:"tween",duration:"0.2"}}};return s&&(m=Object(c.createElement)(b.__unstableMotion.img,{variants:!u&&j,alt:Object(p.__)("Site Icon"),className:"edit-post-fullscreen-mode-close_site-icon",src:s})),r&&(m=null),n&&(m=Object(c.createElement)(b.Icon,{size:"36px",icon:n})),Object(c.createElement)(b.__unstableMotion.div,{whileHover:"expand"},Object(c.createElement)(b.Button,{className:"edit-post-fullscreen-mode-close has-icon",href:null!=a?a:Object(_.addQueryArgs)("edit.php",{post_type:i.slug}),label:Object(d.get)(i,["labels","view_items"],Object(p.__)("Back")),showTooltip:t},m))},pe=n("OzlF"),Oe=n("Q4Sy");const je=e=>{e.preventDefault()};var Ee=function(){const e=Object(c.useRef)(),{setIsInserterOpened:t,setIsListViewOpened:n}=Object(o.useDispatch)(S.a),{isInserterEnabled:a,isInserterOpened:l,isTextModeEnabled:r,showIconLabels:i,isListViewOpen:s,listViewShortcut:u}=Object(o.useSelect)(e=>{const{hasInserterItems:t,getBlockRootClientId:n,getBlockSelectionEnd:c}=e(m.store),{getEditorSettings:a}=e(v.store),{getEditorMode:l,isFeatureActive:o,isListViewOpened:r}=e(S.a),{getShortcutRepresentation:i}=e(B.store);return{isInserterEnabled:"visual"===l()&&a().richEditingEnabled&&t(n(c())),isInserterOpened:e(S.a).isInserterOpened(),isTextModeEnabled:"text"===l(),showIconLabels:o("showIconLabels"),isListViewOpen:r(),listViewShortcut:i("core/edit-post/toggle-list-view")}},[]),d=Object(O.useViewportMatch)("medium"),j=Object(O.useViewportMatch)("wide"),E=Object(p.__)("Document tools"),g=Object(c.useCallback)(()=>n(!s),[n,s]),h=Object(c.createElement)(c.Fragment,null,Object(c.createElement)(b.ToolbarItem,{as:v.TableOfContents,hasOutlineItemsDisabled:r,repositionDropdown:i&&!j,showTooltip:!i,variant:i?"tertiary":void 0}),Object(c.createElement)(b.ToolbarItem,{as:b.Button,className:"edit-post-header-toolbar__list-view-toggle",icon:pe.a,disabled:r,isPressed:s,label:Object(p.__)("List View"),onClick:g,shortcut:u,showTooltip:!i})),_=Object(c.useCallback)(()=>{l?e.current.focus():t(!0)},[l,t]);return Object(c.createElement)(m.NavigableToolbar,{className:"edit-post-header-toolbar","aria-label":E},Object(c.createElement)("div",{className:"edit-post-header-toolbar__left"},Object(c.createElement)(b.ToolbarItem,{ref:e,as:b.Button,className:"edit-post-header-toolbar__inserter-toggle",variant:"primary",isPressed:l,onMouseDown:je,onClick:_,disabled:!a,icon:Oe.a,label:Object(p._x)("Toggle block inserter","Generic label for block inserter button"),showTooltip:!i},i&&(l?Object(p.__)("Close"):Object(p.__)("Add"))),(j||!i)&&Object(c.createElement)(c.Fragment,null,d&&Object(c.createElement)(b.ToolbarItem,{as:m.ToolSelector,showTooltip:!i,variant:i?"tertiary":void 0,disabled:r}),Object(c.createElement)(b.ToolbarItem,{as:v.EditorHistoryUndo,showTooltip:!i,variant:i?"tertiary":void 0}),Object(c.createElement)(b.ToolbarItem,{as:v.EditorHistoryRedo,showTooltip:!i,variant:i?"tertiary":void 0}),h)))};const ge=[{value:"visual",label:Object(p.__)("Visual editor")},{value:"text",label:Object(p.__)("Code editor")}];var he=function(){const{shortcut:e,isRichEditingEnabled:t,isCodeEditingEnabled:n,mode:a}=Object(o.useSelect)(e=>({shortcut:e(B.store).getShortcutRepresentation("core/edit-post/toggle-mode"),isRichEditingEnabled:e(v.store).getEditorSettings().richEditingEnabled,isCodeEditingEnabled:e(v.store).getEditorSettings().codeEditingEnabled,mode:e(S.a).getEditorMode()}),[]),{switchEditorMode:l}=Object(o.useDispatch)(S.a);if(!t||!n)return null;const r=ge.map(t=>t.value!==a?{...t,shortcut:e}:t);return Object(c.createElement)(b.MenuGroup,{label:Object(p.__)("Editor")},Object(c.createElement)(b.MenuItemsChoice,{choices:r,value:a,onSelect:l}))};function _e(){const{openModal:e}=Object(o.useDispatch)(S.a);return Object(c.createElement)(b.MenuItem,{onClick:()=>{e("edit-post/preferences")}},Object(p.__)("Preferences"))}var fe=function(){return Object(O.useViewportMatch)("medium")?Object(c.createElement)(b.MenuGroup,{label:Object(p._x)("View","noun")},Object(c.createElement)(r.g,{scope:"core/edit-post",feature:"fixedToolbar",label:Object(p.__)("Top toolbar"),info:Object(p.__)("Access all block and document tools in a single place"),messageActivated:Object(p.__)("Top toolbar activated"),messageDeactivated:Object(p.__)("Top toolbar deactivated")}),Object(c.createElement)(r.g,{scope:"core/edit-post",feature:"focusMode",label:Object(p.__)("Spotlight mode"),info:Object(p.__)("Focus on one block at a time"),messageActivated:Object(p.__)("Spotlight mode activated"),messageDeactivated:Object(p.__)("Spotlight mode deactivated")}),Object(c.createElement)(r.g,{scope:"core/edit-post",feature:"fullscreenMode",label:Object(p.__)("Fullscreen mode"),info:Object(p.__)("Work without distraction"),messageActivated:Object(p.__)("Fullscreen mode activated"),messageDeactivated:Object(p.__)("Fullscreen mode deactivated"),shortcut:w.displayShortcut.secondary("f")})):null};const ve={className:"edit-post-more-menu__content"};var ye=e=>{let{showIconLabels:t}=e;const n=Object(O.useViewportMatch)("large");return Object(c.createElement)(r.f,{className:"edit-post-more-menu",popoverProps:ve,toggleProps:{showTooltip:!t,...t&&{variant:"tertiary"}}},e=>{let{onClose:a}=e;return Object(c.createElement)(c.Fragment,null,t&&!n&&Object(c.createElement)(r.h.Slot,{className:t&&"show-icon-labels",scope:"core/edit-post"}),Object(c.createElement)(fe,null),Object(c.createElement)(he,null),Object(c.createElement)(r.a.Slot,{name:"core/edit-post/plugin-more-menu",label:Object(p.__)("Plugins"),as:b.MenuGroup,fillProps:{onClick:a}}),Object(c.createElement)(x.Slot,{fillProps:{onClose:a}}),Object(c.createElement)(b.MenuGroup,null,Object(c.createElement)(_e,null)))})};var we=Object(O.compose)(Object(o.withSelect)(e=>({hasPublishAction:Object(d.get)(e(v.store).getCurrentPost(),["_links","wp:action-publish"],!1),isBeingScheduled:e(v.store).isEditedPostBeingScheduled(),isPending:e(v.store).isCurrentPostPending(),isPublished:e(v.store).isCurrentPostPublished(),isPublishSidebarEnabled:e(v.store).isPublishSidebarEnabled(),isPublishSidebarOpened:e(S.a).isPublishSidebarOpened(),isScheduled:e(v.store).isCurrentPostScheduled()})),Object(o.withDispatch)(e=>{const{togglePublishSidebar:t}=e(S.a);return{togglePublishSidebar:t}}))((function(e){let{forceIsDirty:t,forceIsSaving:n,hasPublishAction:a,isBeingScheduled:l,isPending:o,isPublished:r,isPublishSidebarEnabled:i,isPublishSidebarOpened:s,isScheduled:u,togglePublishSidebar:d,setEntitiesSavedStatesCallback:b}=e;const m=Object(O.useViewportMatch)("medium","<");let p;return p=r||u&&l||o&&!a&&!m?"button":m||i?"toggle":"button",Object(c.createElement)(v.PostPublishButton,{forceIsDirty:t,forceIsSaving:n,isOpen:s,isToggle:"toggle"===p,onToggle:d,setEntitiesSavedStatesCallback:b})}));function Se(){const{hasActiveMetaboxes:e,isPostSaveable:t,isSaving:n,deviceType:a}=Object(o.useSelect)(e=>({hasActiveMetaboxes:e(S.a).hasMetaBoxes(),isSaving:e(S.a).isSavingMetaBoxes(),isPostSaveable:e(v.store).isEditedPostSaveable(),deviceType:e(S.a).__experimentalGetPreviewDeviceType()}),[]),{__experimentalSetPreviewDeviceType:l}=Object(o.useDispatch)(S.a);return Object(c.createElement)(m.__experimentalPreviewOptions,{isEnabled:t,className:"edit-post-post-preview-dropdown",deviceType:a,setDeviceType:l},Object(c.createElement)(b.MenuGroup,null,Object(c.createElement)("div",{className:"edit-post-header-preview__grouping-external"},Object(c.createElement)(v.PostPreviewButton,{className:"edit-post-header-preview__button-external",role:"menuitem",forceIsAutosaveable:e,forcePreviewLink:n?null:void 0,textContent:Object(c.createElement)(c.Fragment,null,Object(p.__)("Preview in new tab"),Object(c.createElement)(b.Icon,{icon:g.a}))}))))}const ke="__experimentalMainDashboardButton",{Fill:Pe,Slot:Te}=Object(b.createSlotFill)(ke),xe=Pe;xe.Slot=e=>{let{children:t}=e;const n=Object(b.__experimentalUseSlot)(ke);return Boolean(n.fills&&n.fills.length)?Object(c.createElement)(Te,{bubblesVirtually:!0}):t};var Ie=xe,Ce=n("NWDH");function Be(){const{clearSelectedBlock:e}=Object(o.useDispatch)(m.store),{setIsEditingTemplate:t}=Object(o.useDispatch)(S.a),{getEditorSettings:n}=Object(o.useSelect)(v.store),{updateEditorSettings:a,editPost:l}=Object(o.useDispatch)(v.store),{deleteEntityRecord:r}=Object(o.useDispatch)(C.store),{template:i}=Object(o.useSelect)(e=>{const{isEditingTemplate:t,getEditedPostTemplate:n}=e(S.a);return{template:t()?n():null}},[]);if(!i||!i.wp_id)return null;let s=i.slug;return null!=i&&i.title&&(s=i.title),Object(c.createElement)(b.MenuGroup,{className:"edit-post-template-top-area__second-menu-group"},Object(c.createElement)(b.MenuItem,{className:"edit-post-template-top-area__delete-template-button",isDestructive:!0,variant:"secondary","aria-label":Object(p.__)("Delete template"),onClick:()=>{if(window.confirm(Object(p.sprintf)(Object(p.__)("Are you sure you want to delete the %s template? It may be used by other pages or posts."),s))){e(),t(!1),l({template:""});const c=n(),o=Object(d.pickBy)(c.availableTemplates,(e,t)=>t!==i.slug);a({...c,availableTemplates:o}),r("postType","wp_template",i.id)}}},Object(p.__)("Delete template")))}function Ne(){const{template:e}=Object(o.useSelect)(e=>{const{getEditedPostTemplate:t}=e(S.a);return{template:t()}},[]),{editEntityRecord:t}=Object(o.useDispatch)(C.store),{getEditorSettings:n}=Object(o.useSelect)(v.store),{updateEditorSettings:a}=Object(o.useDispatch)(v.store);let l=Object(p.__)("Default");return null!=e&&e.title?l=e.title:e&&(l=e.slug),Object(c.createElement)(b.TextControl,{label:Object(p.__)("Title"),value:l,help:Object(p.__)('Give the template a title that indicates its purpose, e.g. "Full Width".'),onChange:c=>{const l=n(),o=Object(d.mapValues)(l.availableTemplates,(t,n)=>n!==e.slug?t:c);a({...l,availableTemplates:o}),t("postType","wp_template",e.id,{title:c})}})}function Me(){const{description:e}=Object(o.useSelect)(e=>{const{getEditedPostTemplate:t}=e(S.a);return{description:t().description}},[]);return e?Object(c.createElement)(b.__experimentalText,{size:"body"},e):null}var Ae=function(){const{template:e,isEditing:t,title:n}=Object(o.useSelect)(e=>{const{isEditingTemplate:t,getEditedPostTemplate:n}=e(S.a),{getEditedPostAttribute:c}=e(v.store),a=t();return{template:a?n():null,isEditing:a,title:c("title")?c("title"):Object(p.__)("Untitled")}},[]),{clearSelectedBlock:a}=Object(o.useDispatch)(m.store),{setIsEditingTemplate:l}=Object(o.useDispatch)(S.a);if(!t||!e)return null;let r=Object(p.__)("Default");return null!=e&&e.title?r=e.title:e&&(r=e.slug),Object(c.createElement)("div",{className:"edit-post-template-top-area"},Object(c.createElement)(b.Button,{className:"edit-post-template-post-title",isLink:!0,showTooltip:!0,label:Object(p.sprintf)(Object(p.__)("Edit %s"),n),onClick:()=>{a(),l(!1)}},n),Object(c.createElement)(b.Dropdown,{position:"bottom center",contentClassName:"edit-post-template-top-area__popover",renderToggle:e=>{let{onToggle:t}=e;return Object(c.createElement)(b.Button,{className:"edit-post-template-title",isLink:!0,icon:Ce.a,showTooltip:!0,onClick:t,label:Object(p.__)("Template Options")},r)},renderContent:()=>Object(c.createElement)(c.Fragment,null,e.has_theme_file?Object(c.createElement)(Me,null):Object(c.createElement)(Ne,null),Object(c.createElement)(Be,null))}))};var Le=function(e){let{setEntitiesSavedStatesCallback:t}=e;const{hasActiveMetaboxes:n,isPublishSidebarOpened:a,isSaving:l,showIconLabels:i,hasReducedUI:s}=Object(o.useSelect)(e=>({hasActiveMetaboxes:e(S.a).hasMetaBoxes(),isPublishSidebarOpened:e(S.a).isPublishSidebarOpened(),isSaving:e(S.a).isSavingMetaBoxes(),showIconLabels:e(S.a).isFeatureActive("showIconLabels"),hasReducedUI:e(S.a).isFeatureActive("reducedUI")}),[]),u=Object(O.useViewportMatch)("large"),d=A()("edit-post-header",{"has-reduced-ui":s});return Object(c.createElement)("div",{className:d},Object(c.createElement)(Ie.Slot,null,Object(c.createElement)(me,null)),Object(c.createElement)("div",{className:"edit-post-header__toolbar"},Object(c.createElement)(Ee,null),Object(c.createElement)(Ae,null)),Object(c.createElement)("div",{className:"edit-post-header__settings"},!a&&Object(c.createElement)(v.PostSavedState,{forceIsDirty:n,forceIsSaving:l,showIconLabels:i}),Object(c.createElement)(Se,null),Object(c.createElement)(v.PostPreviewButton,{forceIsAutosaveable:n,forcePreviewLink:l?null:void 0}),Object(c.createElement)(we,{forceIsDirty:n,forceIsSaving:l,setEntitiesSavedStatesCallback:t}),(u||!i)&&Object(c.createElement)(c.Fragment,null,Object(c.createElement)(r.h.Slot,{scope:"core/edit-post"}),Object(c.createElement)(ye,{showIconLabels:i})),i&&!u&&Object(c.createElement)(ye,{showIconLabels:i})))},Re=n("w95h");function De(){const{insertionPoint:e,showMostUsedBlocks:t}=Object(o.useSelect)(e=>{const{isFeatureActive:t,__experimentalGetInsertionPoint:n}=e(S.a);return{insertionPoint:n(),showMostUsedBlocks:t("mostUsedBlocks")}},[]),{setIsInserterOpened:n}=Object(o.useDispatch)(S.a),a=Object(O.useViewportMatch)("medium","<"),[l,r]=Object(O.__experimentalUseDialog)({onClose:()=>n(!1)});return Object(c.createElement)("div",Object(u.a)({ref:l},r,{className:"edit-post-editor__inserter-panel"}),Object(c.createElement)("div",{className:"edit-post-editor__inserter-panel-header"},Object(c.createElement)(b.Button,{icon:Re.a,onClick:()=>n(!1)})),Object(c.createElement)("div",{className:"edit-post-editor__inserter-panel-content"},Object(c.createElement)(m.__experimentalLibrary,{showMostUsedBlocks:t,showInserterHelpPanel:!0,shouldFocusBlock:a,rootClientId:e.rootClientId,__experimentalInsertionIndex:e.insertionIndex,__experimentalFilterValue:e.filterValue})))}var Fe=n("bWcr");function Ve(){const{setIsListViewOpened:e}=Object(o.useDispatch)(S.a),{clearSelectedBlock:t,selectBlock:n}=Object(o.useDispatch)(m.store);const a=Object(O.useFocusOnMount)("firstElement"),l=Object(O.useFocusReturn)();const r="edit-post-editor__list-view-panel-label-"+Object(O.useInstanceId)(Ve);return Object(c.createElement)("div",{"aria-labelledby":r,className:"edit-post-editor__list-view-panel",onKeyDown:function(t){t.keyCode!==w.ESCAPE||t.defaultPrevented||(t.preventDefault(),e(!1))}},Object(c.createElement)("div",{className:"edit-post-editor__list-view-panel-header"},Object(c.createElement)("strong",{id:r},Object(p.__)("List view")),Object(c.createElement)(b.Button,{icon:Fe.a,label:Object(p.__)("Close list view sidebar"),onClick:()=>e(!1)})),Object(c.createElement)("div",{className:"edit-post-editor__list-view-panel-content",ref:Object(O.useMergeRefs)([l,a])},Object(c.createElement)(m.__experimentalListView,{onSelect:async function(e){await t(),n(e,-1)},showNestedBlocks:!0,__experimentalFeatures:!0,__experimentalPersistentListViewFeatures:!0})))}var Ue=n("Cg8A");var Ge=e=>{let{sidebarName:t}=e;const{openGeneralSidebar:n}=Object(o.useDispatch)(S.a),a=()=>n("edit-post/document"),{documentLabel:l,isTemplateMode:r}=Object(o.useSelect)(e=>({documentLabel:e(v.store).getPostTypeLabel()||Object(p._x)("Document","noun"),isTemplateMode:e(S.a).isEditingTemplate()}),[]),[i,s]="edit-post/document"===t?[Object(p.sprintf)(Object(p.__)("%s (selected)"),l),"is-active"]:[l,""],[u,d]="edit-post/block"===t?[Object(p.__)("Block (selected)"),"is-active"]:[Object(p.__)("Block"),""],[m,O]="edit-post/document"===t?[Object(p.__)("Template (selected)"),"is-active"]:[Object(p.__)("Template"),""];return Object(c.createElement)("ul",null,!r&&Object(c.createElement)("li",null,Object(c.createElement)(b.Button,{onClick:a,className:"edit-post-sidebar__panel-tab "+s,"aria-label":i,"data-label":l},l)),r&&Object(c.createElement)("li",null,Object(c.createElement)(b.Button,{onClick:a,className:"edit-post-sidebar__panel-tab "+O,"aria-label":m,"data-label":Object(p.__)("Template")},Object(p.__)("Template"))),Object(c.createElement)("li",null,Object(c.createElement)(b.Button,{onClick:()=>n("edit-post/block"),className:"edit-post-sidebar__panel-tab "+d,"aria-label":u,"data-label":Object(p.__)("Block")},Object(p.__)("Block"))))};var ze=function(){return Object(c.createElement)(v.PostVisibilityCheck,{render:e=>{let{canEdit:t}=e;return Object(c.createElement)(b.PanelRow,{className:"edit-post-post-visibility"},Object(c.createElement)("span",null,Object(p.__)("Visibility")),!t&&Object(c.createElement)("span",null,Object(c.createElement)(v.PostVisibilityLabel,null)),t&&Object(c.createElement)(b.Dropdown,{position:"bottom left",contentClassName:"edit-post-post-visibility__dialog",renderToggle:e=>{let{isOpen:t,onToggle:n}=e;return Object(c.createElement)(b.Button,{"aria-expanded":t,className:"edit-post-post-visibility__toggle",onClick:n,variant:"tertiary"},Object(c.createElement)(v.PostVisibilityLabel,null))},renderContent:()=>Object(c.createElement)(v.PostVisibility,null)}))}})};function qe(){return Object(c.createElement)(v.PostTrashCheck,null,Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostTrash,null)))}var He=function(){const e=Object(c.useRef)();return Object(c.createElement)(v.PostScheduleCheck,null,Object(c.createElement)(b.PanelRow,{className:"edit-post-post-schedule",ref:e},Object(c.createElement)("span",null,Object(p.__)("Publish")),Object(c.createElement)(b.Dropdown,{popoverProps:{anchorRef:e.current},position:"bottom left",contentClassName:"edit-post-post-schedule__dialog",renderToggle:e=>{let{onToggle:t,isOpen:n}=e;return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(b.Button,{className:"edit-post-post-schedule__toggle",onClick:t,"aria-expanded":n,variant:"tertiary"},Object(c.createElement)(v.PostScheduleLabel,null)))},renderContent:()=>Object(c.createElement)(v.PostSchedule,null)})))};var We=function(){return Object(c.createElement)(v.PostStickyCheck,null,Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostSticky,null)))};var Ke=function(){return Object(c.createElement)(v.PostAuthorCheck,null,Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostAuthor,null)))};var Ye=function(){return Object(c.createElement)(v.PostSlugCheck,null,Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostSlug,null)))};var Qe=function(){return Object(c.createElement)(v.PostFormatCheck,null,Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostFormat,null)))};var Xe=function(){return Object(c.createElement)(v.PostPendingStatusCheck,null,Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostPendingStatus,null)))};const{Fill:Ze,Slot:$e}=Object(b.createSlotFill)("PluginPostStatusInfo"),Je=e=>{let{children:t,className:n}=e;return Object(c.createElement)(Ze,null,Object(c.createElement)(b.PanelRow,{className:n},t))};Je.Slot=$e;var et=Je;var tt=Object(O.compose)([Object(o.withSelect)(e=>{const{isEditorPanelRemoved:t,isEditorPanelOpened:n}=e(S.a);return{isRemoved:t("post-status"),isOpened:n("post-status")}}),Object(O.ifCondition)(e=>{let{isRemoved:t}=e;return!t}),Object(o.withDispatch)(e=>({onTogglePanel:()=>e(S.a).toggleEditorPanelOpened("post-status")}))])((function(e){let{isOpened:t,onTogglePanel:n}=e;return Object(c.createElement)(b.PanelBody,{className:"edit-post-post-status",title:Object(p.__)("Status & visibility"),opened:t,onToggle:n},Object(c.createElement)(et.Slot,null,e=>Object(c.createElement)(c.Fragment,null,Object(c.createElement)(ze,null),Object(c.createElement)(He,null),Object(c.createElement)(Qe,null),Object(c.createElement)(We,null),Object(c.createElement)(Xe,null),Object(c.createElement)(Ye,null),Object(c.createElement)(Ke,null),e,Object(c.createElement)(qe,null))))}));var nt=function(){return Object(c.createElement)(v.PostLastRevisionCheck,null,Object(c.createElement)(b.PanelBody,{className:"edit-post-last-revision__panel"},Object(c.createElement)(v.PostLastRevision,null)))};var ct=Object(O.compose)(Object(o.withSelect)((e,t)=>{const n=Object(d.get)(t.taxonomy,["slug"]),c=n?"taxonomy-panel-"+n:"";return{panelName:c,isEnabled:!!n&&e(S.a).isEditorPanelEnabled(c),isOpened:!!n&&e(S.a).isEditorPanelOpened(c)}}),Object(o.withDispatch)((e,t)=>({onTogglePanel:()=>{e(S.a).toggleEditorPanelOpened(t.panelName)}})))((function(e){let{isEnabled:t,taxonomy:n,isOpened:a,onTogglePanel:l,children:o}=e;if(!t)return null;const r=Object(d.get)(n,["labels","menu_name"]);return r?Object(c.createElement)(b.PanelBody,{title:r,opened:a,onToggle:l},o):null}));var at=function(){return Object(c.createElement)(v.PostTaxonomiesCheck,null,Object(c.createElement)(v.PostTaxonomies,{taxonomyWrapper:(e,t)=>Object(c.createElement)(ct,{taxonomy:t},e)}))};const lt=Object(o.withSelect)(e=>{const{getEditedPostAttribute:t}=e(v.store),{getPostType:n}=e(C.store),{isEditorPanelEnabled:c,isEditorPanelOpened:a}=e(S.a);return{postType:n(t("type")),isEnabled:c("featured-image"),isOpened:a("featured-image")}}),ot=Object(o.withDispatch)(e=>{const{toggleEditorPanelOpened:t}=e(S.a);return{onTogglePanel:Object(d.partial)(t,"featured-image")}});var rt=Object(O.compose)(lt,ot)((function(e){let{isEnabled:t,isOpened:n,postType:a,onTogglePanel:l}=e;return t?Object(c.createElement)(v.PostFeaturedImageCheck,null,Object(c.createElement)(b.PanelBody,{title:Object(d.get)(a,["labels","featured_image"],Object(p.__)("Featured image")),opened:n,onToggle:l},Object(c.createElement)(v.PostFeaturedImage,null))):null}));var it=Object(O.compose)([Object(o.withSelect)(e=>({isEnabled:e(S.a).isEditorPanelEnabled("post-excerpt"),isOpened:e(S.a).isEditorPanelOpened("post-excerpt")})),Object(o.withDispatch)(e=>({onTogglePanel:()=>e(S.a).toggleEditorPanelOpened("post-excerpt")}))])((function(e){let{isEnabled:t,isOpened:n,onTogglePanel:a}=e;return t?Object(c.createElement)(v.PostExcerptCheck,null,Object(c.createElement)(b.PanelBody,{title:Object(p.__)("Excerpt"),opened:n,onToggle:a},Object(c.createElement)(v.PostExcerpt,null))):null}));var st=Object(O.compose)([Object(o.withSelect)(e=>{const{isPermalinkEditable:t,getCurrentPost:n,isCurrentPostPublished:c,getPermalinkParts:a,getEditedPostAttribute:l,getEditedPostSlug:o}=e(v.store),{isEditorPanelEnabled:r,isEditorPanelOpened:i}=e(S.a),{getPostType:s}=e(C.store),{link:u}=n(),b=s(l("type")),m=a();return{postLink:u,isEditable:t(),isPublished:c(),isOpened:i("post-link"),isEnabled:r("post-link"),isViewable:Object(d.get)(b,["viewable"],!1),postSlug:Object(_.safeDecodeURIComponent)(o()),postTypeLabel:Object(d.get)(b,["labels","view_item"]),hasPermalinkParts:!!m,permalinkPrefix:null==m?void 0:m.prefix,permalinkSuffix:null==m?void 0:m.suffix}}),Object(O.ifCondition)(e=>{let{isEnabled:t,postLink:n,isViewable:c,hasPermalinkParts:a}=e;return t&&n&&c&&a}),Object(o.withDispatch)(e=>{const{toggleEditorPanelOpened:t}=e(S.a),{editPost:n}=e(v.store);return{onTogglePanel:()=>t("post-link"),editPermalink:e=>{n({slug:e})}}})])((function(e){let{isOpened:t,onTogglePanel:n,isEditable:a,postLink:l,permalinkPrefix:o,permalinkSuffix:r,editPermalink:i,postSlug:s,postTypeLabel:u}=e;const[d,m]=Object(c.useState)(!1);let O,j,E;return a&&(O=o&&Object(c.createElement)("span",{className:"edit-post-post-link__link-prefix"},o),j=s&&Object(c.createElement)("span",{className:"edit-post-post-link__link-post-name"},s),E=r&&Object(c.createElement)("span",{className:"edit-post-post-link__link-suffix"},r)),Object(c.createElement)(b.PanelBody,{title:Object(p.__)("Permalink"),opened:t,onToggle:n},a&&Object(c.createElement)("div",{className:"editor-post-link"},Object(c.createElement)(b.TextControl,{label:Object(p.__)("URL Slug"),value:d?"":s,autoComplete:"off",spellCheck:"false",onChange:e=>{i(e),e?d&&m(!1):d||m(!0)},onBlur:e=>{i(Object(v.cleanForSlug)(e.target.value)),d&&m(!1)}}),Object(c.createElement)("p",null,Object(p.__)("The last part of the URL.")," ",Object(c.createElement)(b.ExternalLink,{href:Object(p.__)("https://wordpress.org/support/article/writing-posts/#post-field-descriptions")},Object(p.__)("Read about permalinks")))),Object(c.createElement)("h3",{className:"edit-post-post-link__preview-label"},u||Object(p.__)("View post")),Object(c.createElement)("div",{className:"edit-post-post-link__preview-link-container"},Object(c.createElement)(b.ExternalLink,{className:"edit-post-post-link__link",href:l,target:"_blank"},a?Object(c.createElement)(c.Fragment,null,O,j,E):l)))}));var ut=Object(O.compose)([Object(o.withSelect)(e=>({isEnabled:e(S.a).isEditorPanelEnabled("discussion-panel"),isOpened:e(S.a).isEditorPanelOpened("discussion-panel")})),Object(o.withDispatch)(e=>({onTogglePanel:()=>e(S.a).toggleEditorPanelOpened("discussion-panel")}))])((function(e){let{isEnabled:t,isOpened:n,onTogglePanel:a}=e;return t?Object(c.createElement)(v.PostTypeSupportCheck,{supportKeys:["comments","trackbacks"]},Object(c.createElement)(b.PanelBody,{title:Object(p.__)("Discussion"),opened:n,onToggle:a},Object(c.createElement)(v.PostTypeSupportCheck,{supportKeys:"comments"},Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostComments,null))),Object(c.createElement)(v.PostTypeSupportCheck,{supportKeys:"trackbacks"},Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PostPingbacks,null))))):null}));var dt=function(){const{isEnabled:e,isOpened:t,postType:n}=Object(o.useSelect)(e=>{const{getEditedPostAttribute:t}=e(v.store),{isEditorPanelEnabled:n,isEditorPanelOpened:c}=e(S.a),{getPostType:a}=e(C.store);return{isEnabled:n("page-attributes"),isOpened:c("page-attributes"),postType:a(t("type"))}},[]),{toggleEditorPanelOpened:a}=Object(o.useDispatch)(S.a);if(!e||!n)return null;const l=Object(d.partial)(a,"page-attributes");return Object(c.createElement)(v.PageAttributesCheck,null,Object(c.createElement)(b.PanelBody,{title:Object(d.get)(n,["labels","attributes"],Object(p.__)("Page attributes")),opened:t,onToggle:l},Object(c.createElement)(v.PageAttributesParent,null),Object(c.createElement)(b.PanelRow,null,Object(c.createElement)(v.PageAttributesOrder,null))))};var bt=function(e){let{location:t}=e;const n=Object(c.useRef)(null),a=Object(c.useRef)(null);Object(c.useEffect)(()=>(a.current=document.querySelector(".metabox-location-"+t),a.current&&n.current.appendChild(a.current),()=>{a.current&&document.querySelector("#metaboxes").appendChild(a.current)}),[t]);const l=Object(o.useSelect)(e=>e(S.a).isSavingMetaBoxes(),[]),r=A()("edit-post-meta-boxes-area","is-"+t,{"is-loading":l});return Object(c.createElement)("div",{className:r},l&&Object(c.createElement)(b.Spinner,null),Object(c.createElement)("div",{className:"edit-post-meta-boxes-area__container",ref:n}),Object(c.createElement)("div",{className:"edit-post-meta-boxes-area__clear"}))};class mt extends c.Component{componentDidMount(){this.updateDOM()}componentDidUpdate(e){this.props.isVisible!==e.isVisible&&this.updateDOM()}updateDOM(){const{id:e,isVisible:t}=this.props,n=document.getElementById(e);n&&(t?n.classList.remove("is-hidden"):n.classList.add("is-hidden"))}render(){return null}}var pt=Object(o.withSelect)((e,t)=>{let{id:n}=t;return{isVisible:e(S.a).isEditorPanelEnabled("meta-box-"+n)}})(mt);function Ot(e){let{location:t}=e;const n=Object(o.useRegistry)(),{metaBoxes:a,areMetaBoxesInitialized:l,isEditorReady:r}=Object(o.useSelect)(e=>{const{__unstableIsEditorReady:n}=e(v.store),{getMetaBoxesPerLocation:c,areMetaBoxesInitialized:a}=e(S.a);return{metaBoxes:c(t),areMetaBoxesInitialized:a(),isEditorReady:n()}},[t]);return Object(c.useEffect)(()=>{r&&!l&&n.dispatch(S.a).initializeMetaBoxes()},[r,l]),l?Object(c.createElement)(c.Fragment,null,Object(d.map)(a,e=>{let{id:t}=e;return Object(c.createElement)(pt,{key:t,id:t})}),Object(c.createElement)(bt,{location:t})):null}var jt=n("xrib");function Et(e){let{className:t,...n}=e;const{postTitle:a,shortcut:l,showIconLabels:i}=Object(o.useSelect)(e=>({postTitle:e(v.store).getEditedPostAttribute("title"),shortcut:e(B.store).getShortcutRepresentation("core/edit-post/toggle-sidebar"),showIconLabels:e(S.a).isFeatureActive("showIconLabels")}),[]);return Object(c.createElement)(r.b,Object(u.a)({panelClassName:t,className:"edit-post-sidebar",smallScreenTitle:a||Object(p.__)("(no title)"),scope:"core/edit-post",toggleShortcut:l,showIconLabels:i},n))}var gt=function(){const[e,t]=Object(c.useState)(!1),[n,l]=Object(c.useState)(!1),[r,i]=Object(c.useState)(""),{template:s,supportsTemplateMode:u,defaultTemplate:m}=Object(o.useSelect)(e=>{var t,n;const{getCurrentPostType:c,getEditorSettings:a}=e(v.store),{getPostType:l}=e(C.store),{getEditedPostTemplate:o}=e(S.a),r=null!==(t=null===(n=l(c()))||void 0===n?void 0:n.viewable)&&void 0!==t&&t,i=a().supportsTemplateMode&&r;return{template:i&&o(),supportsTemplateMode:i,defaultTemplate:a().defaultBlockTemplate}},[]),{__unstableCreateTemplate:O,__unstableSwitchToTemplateMode:j}=Object(o.useDispatch)(S.a);if(!u)return null;const E=Object(p.__)("Custom Template");return Object(c.createElement)(c.Fragment,null,Object(c.createElement)("div",{className:"edit-post-template__actions"},!!s&&Object(c.createElement)(b.Button,{variant:"link",onClick:()=>j()},Object(p.__)("Edit")),Object(c.createElement)(b.Button,{variant:"link",onClick:()=>t(!0)},Object(p.__)("New"))),e&&Object(c.createElement)(b.Modal,{title:Object(p.__)("Create custom template"),closeLabel:Object(p.__)("Close"),onRequestClose:()=>{t(!1),i("")},overlayClassName:"edit-post-template__modal"},Object(c.createElement)("form",{onSubmit:async function(e){if(e.preventDefault(),n)return;l(!0);const c=null!=m?m:Object(a.serialize)([Object(a.createBlock)("core/group",{tagName:"header",layout:{inherit:!0}},[Object(a.createBlock)("core/site-title"),Object(a.createBlock)("core/site-tagline")]),Object(a.createBlock)("core/separator"),Object(a.createBlock)("core/group",{tagName:"main"},[Object(a.createBlock)("core/group",{layout:{inherit:!0}},[Object(a.createBlock)("core/post-title")]),Object(a.createBlock)("core/post-content",{layout:{inherit:!0}})])]);await O({slug:"wp-custom-template-"+Object(d.kebabCase)(r||E),content:c,title:r||E}),l(!1),t(!1),j(!0)}},Object(c.createElement)(b.Flex,{align:"flex-start",gap:8},Object(c.createElement)(b.FlexItem,null,Object(c.createElement)(b.TextControl,{label:Object(p.__)("Name"),value:r,onChange:i,placeholder:E,disabled:n,help:Object(p.__)('Describe the purpose of the template, e.g. "Full Width". Custom templates can be applied to any post or page.')}))),Object(c.createElement)(b.Flex,{className:"edit-post-template__modal-actions",justify:"flex-end",expanded:!1},Object(c.createElement)(b.FlexItem,null,Object(c.createElement)(b.Button,{variant:"tertiary",onClick:()=>{t(!1),i("")}},Object(p.__)("Cancel"))),Object(c.createElement)(b.FlexItem,null,Object(c.createElement)(b.Button,{variant:"primary",type:"submit",isBusy:n,"aria-disabled":n},Object(p.__)("Create")))))))};var ht=function(){const{isEnabled:e,isOpened:t,selectedTemplate:n,availableTemplates:a,fetchedTemplates:l,isViewable:r,template:i,supportsTemplateMode:s,canUserCreate:u}=Object(o.useSelect)(e=>{var t,n;const{isEditorPanelEnabled:c,isEditorPanelOpened:a,getEditedPostTemplate:l}=e(S.a),{getEditedPostAttribute:o,getEditorSettings:r,getCurrentPostType:i}=e(v.store),{getPostType:s,getEntityRecords:u,canUser:b}=e(C.store),m=i(),p=null!==(t=null===(n=s(m))||void 0===n?void 0:n.viewable)&&void 0!==t&&t,O=e(v.store).getEditorSettings().supportsTemplateMode&&p,j=u("postType","wp_template",{post_type:m}),E=Object(d.fromPairs)((j||[]).map(e=>{let{slug:t,title:n}=e;return[t,n.rendered]}));return{isEnabled:c("template"),isOpened:a("template"),selectedTemplate:o("template"),availableTemplates:r().availableTemplates,fetchedTemplates:E,template:O&&l(),isViewable:p,supportsTemplateMode:O,canUserCreate:b("create","templates")}},[]),m=Object(c.useMemo)(()=>({...a,...l}),[a,l]),{toggleEditorPanelOpened:O}=Object(o.useDispatch)(S.a),{editPost:j}=Object(o.useDispatch)(v.store);if(!e||!r||Object(d.isEmpty)(a)&&(!s||!u))return null;const E=Object(d.partial)(O,"template");let g=Object(p.__)("Template");var h;return i&&(g=Object(p.sprintf)(Object(p.__)("Template: %s"),null!==(h=null==i?void 0:i.title)&&void 0!==h?h:i.slug)),Object(c.createElement)(b.PanelBody,{title:g,opened:t,onToggle:E},Object(c.createElement)(b.SelectControl,{hideLabelFromVision:!0,label:Object(p.__)("Template:"),value:Object.keys(m).includes(n)?n:"",onChange:e=>{j({template:e||""})},options:Object(d.map)(m,(e,t)=>({value:t,label:e}))}),u&&Object(c.createElement)(gt,null))},_t=n("Civd");var ft=function(){const e=Object(o.useSelect)(e=>{const{getEditedPostTemplate:t}=e(S.a);return t()},[]);return e?Object(c.createElement)(b.PanelBody,null,Object(c.createElement)(b.Flex,{align:"flex-start",gap:"3"},Object(c.createElement)(b.FlexItem,null,Object(c.createElement)($.a,{icon:_t.a})),Object(c.createElement)(b.FlexBlock,null,Object(c.createElement)("h2",{className:"edit-post-template-summary__title"},(null==e?void 0:e.title)||(null==e?void 0:e.slug)),Object(c.createElement)("p",null,null==e?void 0:e.description)))):null};const vt=c.Platform.select({web:!0,native:!1});var yt=()=>{const{sidebarName:e,keyboardShortcut:t,isTemplateMode:n}=Object(o.useSelect)(e=>{let t=e(r.i).getActiveComplementaryArea(S.a.name);["edit-post/document","edit-post/block"].includes(t)||(e(m.store).getBlockSelectionStart()&&(t="edit-post/block"),t="edit-post/document");return{sidebarName:t,keyboardShortcut:e(B.store).getShortcutRepresentation("core/edit-post/toggle-sidebar"),isTemplateMode:e(S.a).isEditingTemplate()}},[]);return Object(c.createElement)(Et,{identifier:e,header:Object(c.createElement)(Ge,{sidebarName:e}),closeLabel:Object(p.__)("Close settings"),headerClassName:"edit-post-sidebar__panel-tabs",title:Object(p.__)("Settings"),toggleShortcut:t,icon:Ue.a,isActiveByDefault:vt},!n&&"edit-post/document"===e&&Object(c.createElement)(c.Fragment,null,Object(c.createElement)(tt,null),Object(c.createElement)(ht,null),Object(c.createElement)(jt.a.Slot,null),Object(c.createElement)(nt,null),Object(c.createElement)(st,null),Object(c.createElement)(at,null),Object(c.createElement)(rt,null),Object(c.createElement)(it,null),Object(c.createElement)(ut,null),Object(c.createElement)(dt,null),Object(c.createElement)(Ot,{location:"side"})),n&&"edit-post/document"===e&&Object(c.createElement)(ft,null),"edit-post/block"===e&&Object(c.createElement)(m.BlockInspector,null))};function wt(e){let{nonAnimatedSrc:t,animatedSrc:n}=e;return Object(c.createElement)("picture",{className:"edit-post-welcome-guide__image"},Object(c.createElement)("source",{srcSet:t,media:"(prefers-reduced-motion: reduce)"}),Object(c.createElement)("img",{src:n,width:"312",height:"240",alt:""}))}function St(){const{toggleFeature:e}=Object(o.useDispatch)(S.a);return Object(c.createElement)(b.Guide,{className:"edit-post-welcome-guide",contentLabel:Object(p.__)("Welcome to the block editor"),finishButtonText:Object(p.__)("Get started"),onFinish:()=>e("welcomeGuide"),pages:[{image:Object(c.createElement)(wt,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-canvas.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-canvas.gif"}),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(p.__)("Welcome to the block editor")),Object(c.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(p.__)("In the WordPress editor, each paragraph, image, or video is presented as a distinct “block” of content.")))},{image:Object(c.createElement)(wt,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-editor.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-editor.gif"}),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(p.__)("Make each block your own")),Object(c.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(p.__)("Each block comes with its own set of controls for changing things like color, width, and alignment. These will show and hide automatically when you have a block selected.")))},{image:Object(c.createElement)(wt,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-library.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-library.gif"}),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(p.__)("Get to know the block library")),Object(c.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(c.createInterpolateElement)(Object(p.__)("All of the blocks available to you live in the block library. Youll find it wherever you see the <InserterIconImage /> icon."),{InserterIconImage:Object(c.createElement)("img",{alt:Object(p.__)("inserter"),src:"data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 18 18' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='18' height='18' rx='2' fill='%231E1E1E'/%3E%3Cpath d='M9.22727 4V14M4 8.77273H14' stroke='white' stroke-width='1.5'/%3E%3C/svg%3E%0A"})})))},{image:Object(c.createElement)(wt,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-documentation.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-documentation.gif"}),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(p.__)("Learn how to use the block editor")),Object(c.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(p.__)("New to the block editor? Want to learn more about using it? "),Object(c.createElement)(b.ExternalLink,{href:Object(p.__)("https://wordpress.org/support/article/wordpress-editor/")},Object(p.__)("Here's a detailed guide."))))}]})}function kt(){const{toggleFeature:e}=Object(o.useDispatch)(S.a);return Object(c.createElement)(b.Guide,{className:"edit-post-welcome-guide",contentLabel:Object(p.__)("Welcome to the template editor"),finishButtonText:Object(p.__)("Get started"),onFinish:()=>e("welcomeGuideTemplate"),pages:[{image:Object(c.createElement)(wt,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-template-editor.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-template-editor.gif"}),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(p.__)("Welcome to the template editor")),Object(c.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(p.__)("Templates help define the layout of the site. You can customize all aspects of your posts and pages using blocks and patterns in this editor.")))}]})}function Pt(){const{isActive:e,isTemplateMode:t}=Object(o.useSelect)(e=>{const{isFeatureActive:t,isEditingTemplate:n}=e(S.a),c=n();return{isActive:t(c?"welcomeGuideTemplate":"welcomeGuide"),isTemplateMode:c}},[]);return e?t?Object(c.createElement)(kt,null):Object(c.createElement)(St,null):null}const{Fill:Tt,Slot:xt}=Object(b.createSlotFill)("PluginPostPublishPanel"),It=Object(O.compose)(Object(h.withPluginContext)((e,t)=>({icon:t.icon||e.icon})))(e=>{let{children:t,className:n,title:a,initialOpen:l=!1,icon:o}=e;return Object(c.createElement)(Tt,null,Object(c.createElement)(b.PanelBody,{className:n,initialOpen:l||!a,title:a,icon:o},t))});It.Slot=xt;var Ct=It;const{Fill:Bt,Slot:Nt}=Object(b.createSlotFill)("PluginPrePublishPanel"),Mt=Object(O.compose)(Object(h.withPluginContext)((e,t)=>({icon:t.icon||e.icon})))(e=>{let{children:t,className:n,title:a,initialOpen:l=!1,icon:o}=e;return Object(c.createElement)(Bt,null,Object(c.createElement)(b.PanelBody,{className:n,initialOpen:l||!a,title:a,icon:o},t))});Mt.Slot=Nt;var At=Mt;const{Fill:Lt,Slot:Rt}=Object(b.createSlotFill)("ActionsPanel");function Dt(e){let{setEntitiesSavedStatesCallback:t,closeEntitiesSavedStates:n,isEntitiesSavedStatesOpen:a}=e;const{closePublishSidebar:l,togglePublishSidebar:r}=Object(o.useDispatch)(S.a),{publishSidebarOpened:i,hasActiveMetaboxes:s,isSavingMetaBoxes:u,hasNonPostEntityChanges:d}=Object(o.useSelect)(e=>({publishSidebarOpened:e(S.a).isPublishSidebarOpened(),hasActiveMetaboxes:e(S.a).hasMetaBoxes(),isSavingMetaBoxes:e(S.a).isSavingMetaBoxes(),hasNonPostEntityChanges:e(v.store).hasNonPostEntityChanges()}),[]),m=Object(c.useCallback)(()=>t(!0),[]);let O;return O=i?Object(c.createElement)(v.PostPublishPanel,{onClose:l,forceIsDirty:s,forceIsSaving:u,PrePublishExtension:At.Slot,PostPublishExtension:Ct.Slot}):d?Object(c.createElement)("div",{className:"edit-post-layout__toggle-entities-saved-states-panel"},Object(c.createElement)(b.Button,{variant:"secondary",className:"edit-post-layout__toggle-entities-saved-states-panel-button",onClick:m,"aria-expanded":!1},Object(p.__)("Open save panel"))):Object(c.createElement)("div",{className:"edit-post-layout__toggle-publish-panel"},Object(c.createElement)(b.Button,{variant:"secondary",className:"edit-post-layout__toggle-publish-panel-button",onClick:r,"aria-expanded":!1},Object(p.__)("Open publish panel"))),Object(c.createElement)(c.Fragment,null,a&&Object(c.createElement)(v.EntitiesSavedStates,{close:n}),Object(c.createElement)(Rt,{bubblesVirtually:!0}),!a&&O)}const Ft={secondarySidebar:Object(p.__)("Block library"),header:Object(p.__)("Editor top bar"),body:Object(p.__)("Editor content"),sidebar:Object(p.__)("Editor settings"),actions:Object(p.__)("Editor publish"),footer:Object(p.__)("Editor footer")};var Vt=function(e){let{styles:t}=e;const n=Object(O.useViewportMatch)("medium","<"),a=Object(O.useViewportMatch)("huge",">="),{openGeneralSidebar:l,closeGeneralSidebar:i,setIsInserterOpened:s}=Object(o.useDispatch)(S.a),{mode:u,isFullscreenActive:d,isRichEditingEnabled:j,sidebarIsOpened:E,hasActiveMetaboxes:g,hasFixedToolbar:_,previousShortcut:f,nextShortcut:y,hasBlockSelected:w,isInserterOpened:k,isListViewOpened:P,showIconLabels:T,hasReducedUI:x,showBlockBreadcrumbs:I,isTemplateMode:C,documentLabel:N}=Object(o.useSelect)(e=>{const{getEditorSettings:t,getPostTypeLabel:n}=e(v.store),c=t(),a=n();return{isTemplateMode:e(S.a).isEditingTemplate(),hasFixedToolbar:e(S.a).isFeatureActive("fixedToolbar"),sidebarIsOpened:!(!e(r.i).getActiveComplementaryArea(S.a.name)&&!e(S.a).isPublishSidebarOpened()),isFullscreenActive:e(S.a).isFeatureActive("fullscreenMode"),isInserterOpened:e(S.a).isInserterOpened(),isListViewOpened:e(S.a).isListViewOpened(),mode:e(S.a).getEditorMode(),isRichEditingEnabled:c.richEditingEnabled,hasActiveMetaboxes:e(S.a).hasMetaBoxes(),previousShortcut:e(B.store).getAllShortcutKeyCombinations("core/edit-post/previous-region"),nextShortcut:e(B.store).getAllShortcutKeyCombinations("core/edit-post/next-region"),showIconLabels:e(S.a).isFeatureActive("showIconLabels"),hasReducedUI:e(S.a).isFeatureActive("reducedUI"),showBlockBreadcrumbs:e(S.a).isFeatureActive("showBlockBreadcrumbs"),documentLabel:a||Object(p._x)("Document","noun")}},[]),M=A()("edit-post-layout","is-mode-"+u,{"is-sidebar-opened":E,"has-fixed-toolbar":_,"has-metaboxes":g,"show-icon-labels":T});Object(c.useEffect)(()=>{E&&!a&&s(!1)},[E,a]),Object(c.useEffect)(()=>{k&&!a&&i()},[k,a]);const[R,D]=Object(c.useState)(!1),F=Object(c.useCallback)(e=>{"function"==typeof R&&R(e),D(!1)},[R]);return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(r.d,{isActive:d}),Object(c.createElement)(de,null),Object(c.createElement)(v.UnsavedChangesWarning,null),Object(c.createElement)(v.AutosaveMonitor,null),Object(c.createElement)(v.LocalAutosaveMonitor,null),Object(c.createElement)(G,null),Object(c.createElement)(v.EditorKeyboardShortcutsRegister,null),Object(c.createElement)(yt,null),Object(c.createElement)(r.e,{className:M,labels:Ft,header:Object(c.createElement)(Le,{setEntitiesSavedStatesCallback:D}),secondarySidebar:"visual"===u&&k?Object(c.createElement)(De,null):"visual"===u&&P?Object(c.createElement)(Ve,null):null,sidebar:(!n||E)&&Object(c.createElement)(c.Fragment,null,!n&&!E&&Object(c.createElement)("div",{className:"edit-post-layout__toggle-sidebar-panel"},Object(c.createElement)(b.Button,{variant:"secondary",className:"edit-post-layout__toggle-sidebar-panel-button",onClick:()=>l(w?"edit-post/block":"edit-post/document"),"aria-expanded":!1},w?Object(p.__)("Open block settings"):Object(p.__)("Open document settings"))),Object(c.createElement)(r.b.Slot,{scope:"core/edit-post"})),notices:Object(c.createElement)(v.EditorSnackbars,null),content:Object(c.createElement)(c.Fragment,null,Object(c.createElement)(v.EditorNotices,null),("text"===u||!j)&&Object(c.createElement)(L,null),j&&"visual"===u&&Object(c.createElement)(U,{styles:t}),!C&&Object(c.createElement)("div",{className:"edit-post-layout__metaboxes"},Object(c.createElement)(Ot,{location:"normal"}),Object(c.createElement)(Ot,{location:"advanced"})),n&&E&&Object(c.createElement)(b.ScrollLock,null)),footer:!x&&I&&!n&&j&&"visual"===u&&Object(c.createElement)("div",{className:"edit-post-layout__footer"},Object(c.createElement)(m.BlockBreadcrumb,{rootLabelText:N})),actions:Object(c.createElement)(Dt,{closeEntitiesSavedStates:F,isEntitiesSavedStatesOpen:R,setEntitiesSavedStatesCallback:D}),shortcuts:{previous:f,next:y}}),Object(c.createElement)(se,null),Object(c.createElement)(Z,null),Object(c.createElement)(Pt,null),Object(c.createElement)(b.Popover.Slot,null),Object(c.createElement)(h.PluginArea,null))},Ut=n("0dt7");function Gt(e){let{postId:t}=e;return(e=>{const{hasBlockSelection:t,isEditorSidebarOpened:n}=Object(o.useSelect)(e=>({hasBlockSelection:!!e(m.store).getBlockSelectionStart(),isEditorSidebarOpened:e(Ut.a).isEditorSidebarOpened()}),[e]),{openGeneralSidebar:a}=Object(o.useDispatch)(Ut.a);Object(c.useEffect)(()=>{n&&a(t?"edit-post/block":"edit-post/document")},[t,n])})(t),(e=>{const{newPermalink:t}=Object(o.useSelect)(e=>({newPermalink:e(v.store).getCurrentPost().link}),[e]),n=Object(c.useRef)();Object(c.useEffect)(()=>{n.current=document.querySelector(Ut.c)||document.querySelector(Ut.b)},[e]),Object(c.useEffect)(()=>{t&&n.current&&n.current.setAttribute("href",t)},[t])})(t),null}var zt=function(e){let{postId:t,postType:n,settings:l,initialEdits:r,onError:i,...s}=e;const{hasFixedToolbar:m,focusMode:p,hasReducedUI:O,hasThemeStyles:j,post:E,preferredStyleVariations:g,hiddenBlockTypes:h,blockTypes:_,__experimentalLocalAutosaveInterval:f,keepCaretInsideBlock:y,isTemplateMode:w,template:k}=Object(o.useSelect)(e=>{var c,l;const{isFeatureActive:o,getPreference:r,__experimentalGetPreviewDeviceType:i,isEditingTemplate:s,getEditedPostTemplate:u}=e(S.a),{getEntityRecord:d,getPostType:b,getEntityRecords:m}=e(C.store),{getEditorSettings:p}=e(v.store),{getBlockTypes:O}=e(a.store);let j;if(["wp_template","wp_template_part"].includes(n)){const e=m("postType",n,{wp_id:t});j=null==e?void 0:e[0]}else j=d("postType",n,t);const E=p().supportsTemplateMode,g=null!==(c=null===(l=b(n))||void 0===l?void 0:l.viewable)&&void 0!==c&&c;return{hasFixedToolbar:o("fixedToolbar")||"Desktop"!==i(),focusMode:o("focusMode"),hasReducedUI:o("reducedUI"),hasThemeStyles:o("themeStyles"),preferredStyleVariations:r("preferredStyleVariations"),hiddenBlockTypes:r("hiddenBlockTypes"),blockTypes:O(),__experimentalLocalAutosaveInterval:r("localAutosaveInterval"),keepCaretInsideBlock:o("keepCaretInsideBlock"),isTemplateMode:s(),template:E&&g?u():null,post:j}},[n,t]),{updatePreferredStyleVariations:P,setIsInserterOpened:T}=Object(o.useDispatch)(S.a),x=Object(c.useMemo)(()=>{const e={...l,__experimentalPreferredStyleVariations:{value:g,onChange:P},hasFixedToolbar:m,focusMode:p,hasReducedUI:O,__experimentalLocalAutosaveInterval:f,__experimentalSetIsInserterOpened:T,keepCaretInsideBlock:y};if(Object(d.size)(h)>0){const t=!0===l.allowedBlockTypes?Object(d.map)(_,"name"):l.allowedBlockTypes||[];e.allowedBlockTypes=Object(d.without)(t,...h)}return e},[l,m,p,O,h,_,g,f,T,P,y]),I=Object(c.useMemo)(()=>{const e=[],t=[];l.styles.forEach(n=>{n.__unstableType&&"theme"!==n.__unstableType?t.push(n):e.push(n)});const n=[...l.defaultEditorStyles,...t];return j&&e.length?l.styles:n},[l,j]);return E?Object(c.createElement)(c.StrictMode,null,Object(c.createElement)(B.ShortcutProvider,null,Object(c.createElement)(le.Provider,{value:l},Object(c.createElement)(b.SlotFillProvider,null,Object(c.createElement)(v.EditorProvider,Object(u.a)({settings:x,post:E,initialEdits:r,useSubRegistry:!1,__unstableTemplate:w?k:void 0},s),Object(c.createElement)(v.ErrorBoundary,{onError:i},Object(c.createElement)(Gt,{postId:t}),Object(c.createElement)(Vt,{styles:I}),Object(c.createElement)(b.KeyboardShortcuts,{shortcuts:N})),Object(c.createElement)(v.PostLockedModal,null)))))):null};const qt=(e,t)=>{return!Array.isArray(t)||(n=e,c=t,0===Object(d.difference)(n,c).length);var n,c};var Ht=e=>{let{allowedBlocks:t,icon:n,label:a,onClick:l,small:o,role:r}=e;return Object(c.createElement)(m.BlockSettingsMenuControls,null,e=>{let{selectedBlocks:i,onClose:s}=e;return qt(i,t)?Object(c.createElement)(b.MenuItem,{onClick:Object(O.compose)(l,s),icon:n,label:o?a:void 0,role:r},!o&&a):null})},Wt=Object(O.compose)(Object(h.withPluginContext)((e,t)=>({icon:t.icon||e.icon,name:"core/edit-post/plugin-more-menu"})))(r.a);function Kt(e){return Object(c.createElement)(r.c,Object(u.a)({__unstableExplicitMenuItem:!0,scope:"core/edit-post"},e))}function Yt(e,t,n,a,l){Object(c.unmountComponentAtNode)(n);const o=Yt.bind(null,e,t,n,a,l);Object(c.render)(Object(c.createElement)(zt,{settings:a,onError:o,postId:t,postType:e,initialEdits:l,recovery:!0}),n)}function Qt(e,t,n,i,s){const u=document.getElementById(e),d=Yt.bind(null,t,n,u,i,s);Object(o.dispatch)(r.i).setFeatureDefaults("core/edit-post",{fixedToolbar:!1,welcomeGuide:!0,mobileGalleryWarning:!0,fullscreenMode:!0,showIconLabels:!1,themeStyles:!0,showBlockBreadcrumbs:!0,welcomeGuideTemplate:!0}),Object(o.dispatch)(a.store).__experimentalReapplyBlockTypeFilters(),Object(l.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 <!DOCTYPE html>. 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",e=>{const 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)(zt,{settings:i,onError:d,postId:n,postType:t,initialEdits:s}),u)}},g56x:function(e,t){e.exports=window.wp.hooks},gdqT:function(e,t){e.exports=window.wp.a11y},hF7m:function(e,t){e.exports=window.wp.keyboardShortcuts},iClF:function(e,t,n){"use strict";var c=n("GRId");t.a=function(e){let{icon:t,size:n=24,...a}=e;return Object(c.cloneElement)(t,{width:n,height:n,...a})}},jSdM:function(e,t){e.exports=window.wp.editor},jZUy:function(e,t){e.exports=window.wp.coreData},l3Sj:function(e,t){e.exports=window.wp.i18n},onLe:function(e,t){e.exports=window.wp.notices},pPDe:function(e,t,n){"use strict";var c,a;function l(e){return[e]}function o(){var e={clear:function(){e.head=null}};return e}function r(e,t,n){var c;if(e.length!==t.length)return!1;for(c=n;c<e.length;c++)if(e[c]!==t[c])return!1;return!0}c={},a="undefined"!=typeof WeakMap,t.a=function(e,t){var n,i;function s(){n=a?new WeakMap:o()}function u(){var n,c,a,l,o,s=arguments.length;for(l=new Array(s),a=0;a<s;a++)l[a]=arguments[a];for(o=t.apply(null,l),(n=i(o)).isUniqueByDependants||(n.lastDependants&&!r(o,n.lastDependants,0)&&n.clear(),n.lastDependants=o),c=n.head;c;){if(r(c.args,l,1))return c!==n.head&&(c.prev.next=c.next,c.next&&(c.next.prev=c.prev),c.next=n.head,c.prev=null,n.head.prev=c,n.head=c),c.val;c=c.next}return c={val:e.apply(null,l)},l[0]=null,c.args=l,n.head&&(n.head.prev=c,c.next=n.head),n.head=c,c.val}return t||(t=l),i=a?function(e){var t,a,l,r,i,s=n,u=!0;for(t=0;t<e.length;t++){if(a=e[t],!(i=a)||"object"!=typeof i){u=!1;break}s.has(a)?s=s.get(a):(l=new WeakMap,s.set(a,l),s=l)}return s.has(c)||((r=o()).isUniqueByDependants=u,s.set(c,r)),s.get(c)}:function(){return n},u.getDependants=t,u.clear=s,s(),u}},"tI+e":function(e,t){e.exports=window.wp.components},w95h:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(c.createElement)(a.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"}));t.a=l},wduq:function(e,t,n){"use strict";var c=n("GRId"),a=n("Tqx9");const l=Object(c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(c.createElement)(a.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"}));t.a=l},wx14:function(e,t,n){"use strict";function c(){return(c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var c in n)Object.prototype.hasOwnProperty.call(n,c)&&(e[c]=n[c])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return c}))},xrib:function(e,t,n){"use strict";(function(e){var c=n("GRId"),a=n("tI+e"),l=n("K9lf"),o=n("TvNi"),r=n("1ZqX"),i=(n("Z23Y"),n("Y5n4")),s=n("T40v");const{Fill:u,Slot:d}=Object(a.createSlotFill)("PluginDocumentSettingPanel"),b=Object(l.compose)(Object(o.withPluginContext)((t,n)=>(void 0===n.name&&void 0!==e&&e.env,{icon:n.icon||t.icon,panelName:`${t.name}/${n.name}`})),Object(r.withSelect)((e,t)=>{let{panelName:n}=t;return{opened:e(s.a).isEditorPanelOpened(n),isEnabled:e(s.a).isEditorPanelEnabled(n)}}),Object(r.withDispatch)((e,t)=>{let{panelName:n}=t;return{onToggle:()=>e(s.a).toggleEditorPanelOpened(n)}}))(e=>{let{isEnabled:t,panelName:n,opened:l,onToggle:o,className:r,title:s,icon:d,children:b}=e;return Object(c.createElement)(c.Fragment,null,Object(c.createElement)(i.d,{label:s,panelName:n}),Object(c.createElement)(u,null,t&&Object(c.createElement)(a.PanelBody,{className:r,title:s,icon:d,opened:l,onToggle:o},b)))});b.Slot=d,t.a=b}).call(this,n("8oxB"))}});